Updated: October 28, 2024 |
Retrieve an enumerated list of interim data available on the device
#include <sensor/sensor_interim_data.h>
sensor_error_t sensor_get_supported_interim_data(uint32_t num_asked, uint32_t *num_supported, sensor_interim_data_info_t *data_info)
On success, this function writes an array of information on each supported interim data instance into data_info.
The data_info argument must point to an array which has at least num_asked elements allocated. To find the required size for this array, you can invoke this function with num_asked set to zero or data_info set to NULL. The required array size is then written into the memory pointed to by num_supported. You can then allocate an array of this size and invoke this function again with num_asked set to the value previously written into num_supported and data_info pointing to the allocated array.
SENSOR_EOK when the function successfully completes, otherwise another sensor_error_t value that provides the reason that the call failed.