sensor_get_buffer()

Retrieve a data buffer for an event that was signalled

Synopsis:

#include <sensor/sensor_api.h>
sensor_error_t sensor_get_buffer(sensor_handle_t handle,
                                 sensor_eventkey_t key,
                                 sensor_buffer_t *buffer)

Arguments:

handle
The handle that's returned from calling sensor_open().
key
The key returned by a call to the sensor_enable_event() function.
buffer
On success, gets filled with the information of the buffer that was retrieved.

Library:

libsensor

Returns:

SENSOR_EOK when the function successfully completes, otherwise another sensor_error_t value that provides the reason that the call failed.