NTURT Zephyr v0.0.1
NTURT common library for Zephyr RTOS
Loading...
Searching...
No Matches
sensor_axis.h File Reference
#include <zephyr/device.h>
#include <zephyr/drivers/sensor.h>
#include <zephyr/sys/util.h>
+ Include dependency graph for sensor_axis.h:

Macros

#define SENSOR_AXIS_SETTINGS_ROOT   "sensor_axis"
 Settings root path for sensor_axis.
 

Typedefs

typedef void(* sensor_axis_sensor_raw_cb_t) (const struct device *dev, const struct sensor_value *val, void *user_data)
 Sensor axis sensor raw callback type.
 

Functions

void sensor_axis_sensor_set_raw_cb (const struct device *dev, sensor_axis_sensor_raw_cb_t cb, void *user_data)
 Set callback function for raw sensor value, use NULL to reset.
 
void sensor_axis_sensor_min_get (const struct device *dev, struct sensor_value *val)
 Get sensor setpoint that will report minimum value.
 
void sensor_axis_sensor_max_get (const struct device *dev, struct sensor_value *val)
 Get sensor setpoint that will report maximum value.
 
void sensor_axis_sensor_min_set (const struct device *dev, const struct sensor_value *val)
 Set sensor setpoint that will report minimum value.
 
void sensor_axis_sensor_max_set (const struct device *dev, const struct sensor_value *val)
 Set sensor setpoint that will report maximum value.
 
int sensor_axis_sensor_min_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Use current sensor value as setpoint that will report minimum value.
 
int sensor_axis_sensor_max_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Use current sensor value as setpoint that will report maximum value.
 
int sensor_axis_sensor_center_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Use current sensor value as setpoint that will report center value. Use with sensor_axis_sensor_range_set_curr for setting the center point and the range.
 
int sensor_axis_sensor_range_set_curr (const struct device *dev, int times, k_timeout_t interval, bool is_min)
 Use current sensor value as setpoint that will be used as range. Use with sensor_axis_sensor_center_set_curr for setting the center point and the range.
 
int sensor_axis_channel_min_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Similar to sensor_axis_sensor_min_set_curr but applies to all underlying sensors of a channel.
 
int sensor_axis_channel_max_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Similar to sensor_axis_sensor_max_set_curr but applies to all underlying sensors of a channel.
 
int sensor_axis_channel_center_set_curr (const struct device *dev, int times, k_timeout_t interval)
 Similar to sensor_axis_sensor_center_set_curr but applies to all underlying sensors of a channel.
 
int sensor_axis_channel_range_set_curr (const struct device *dev, int times, k_timeout_t interval, bool is_min)
 Similar to sensor_axis_sensor_range_set_curr but applies to all underlying sensors of a channel.