sensor_start()

Updated: April 19, 2023

Start streaming data from a sensor

Synopsis:

#include <sensor/sensor_api.h>
sensor_error_t sensor_start(sensor_handle_t handle,
                            struct timespec *time)

Arguments:

handle
The handle that's returned from calling sensor_open().
time
Optional absolute time at which to start streaming; if time is NULL, streaming will start immediately.

Library:

libsensor

Description:

This function starts streaming data from the given sensor. Any registered callbacks or events will be notified with the incoming streaming data after streaming has started.

Returns:

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