52#ifndef CONFIG_ADS101X_I2C_ADDRESS
53#define CONFIG_ADS101X_I2C_ADDRESS (0x48)
178 int16_t low_limit, int16_t high_limit);
Low-level GPIO peripheral driver interface definitions.
int ads101x_set_mux_gain(const ads101x_t *dev, uint8_t mux_gain)
Set mux and gain.
void(* ads101x_alert_cb_t)(void *)
ADS101x/111x alert callback.
int ads101x_set_alert_parameters(const ads101x_alert_t *dev, int16_t low_limit, int16_t high_limit)
Set the alert parameters.
int ads101x_init(ads101x_t *dev, const ads101x_params_t *params)
Initialize an ADS101x/111x ADC device (ADC only)
int ads101x_enable_alert(ads101x_alert_t *dev, ads101x_alert_cb_t cb, void *arg)
Enable alert interrupt.
struct ads101x ads101x_t
ADS101x/111x device descriptor.
int ads101x_alert_init(ads101x_alert_t *dev, const ads101x_alert_params_t *params)
Initialize an ADS101x/111x alert device.
struct ads101x_alert_params ads101x_alert_params_t
ADS101x/111x alert params.
struct ads101x_params ads101x_params_t
ADS101x/111x params.
struct ads101x_alert ads101x_alert_t
ADS101x/111x alert device descriptor.
int ads101x_read_raw(const ads101x_t *dev, int16_t *raw)
Read a raw ADC value.
@ ADS101X_NODATA
no data available
@ ADS101X_NOI2C
I2C communication failed.
@ ADS101X_OK
everything was fine
@ ADS101X_NODEV
no ADS101X device found on the bus
uint_fast8_t i2c_t
Default i2c_t type definition.
Low-level I2C peripheral driver interface definition.
ADS101x/111x alert params.
int16_t high_limit
alert high value
int16_t low_limit
alert low value
gpio_t alert_pin
alert pin (GPIO_UNDEF if not connected)
ADS101x/111x alert device descriptor.
ads101x_alert_cb_t cb
alert callback
void * arg
alert callback param
ads101x_alert_params_t params
device driver configuration
uint8_t mux_gain
Mux and gain boolean settings.
ADS101x/111x device descriptor.
ads101x_params_t params
device driver configuration