LoRa-BLE-Sensor
|
This is a library for sensor data configurations and collection. This is manages the sensor type, pin configuration, and reading of sensor data. More...
Classes | |
struct | pulse_context_t |
Functions | |
int | sensor_reading_setup (sensor_reading_config_t *config, enum sensor_types sensor_type) |
Setup sensor for sensor_type with hardware configuration. | |
enum sensor_types | get_sensor_reading_setup (sensor_reading_config_t *config) |
Get the sensor type set for a hardware configuration. | |
float | get_sensor_voltage_reading (sensor_reading_config_t *config) |
Get the sensor voltage reading for a given sensor, takes into account the VOLTAGE_READ_DIVIDER_HIGH and VOLTAGE_READ_DIVIDER_LOW values. | |
float | get_sensor_current_reading (sensor_reading_config_t *config) |
Get the sensor current reading for a given sensor in milliamperes, takes into account the CURRENT_READ_RESISTOR. | |
int | get_sensor_pulse_count (sensor_reading_config_t *config) |
Get the current number of pulses captured on since initialization or last reset. | |
int | reset_sensor_pulse_count (sensor_reading_config_t *config) |
Reset the pulse count for a given sensor to 0. | |
Variables | |
enum sensor_types | sensor_setups [SENSOR_INDEX_LIMIT] |
This is a library for sensor data configurations and collection. This is manages the sensor type, pin configuration, and reading of sensor data.
float get_sensor_current_reading | ( | sensor_reading_config_t * | config | ) |
Get the sensor current reading for a given sensor in milliamperes, takes into account the CURRENT_READ_RESISTOR.
config | sensor hardware configuration |
int get_sensor_pulse_count | ( | sensor_reading_config_t * | config | ) |
Get the current number of pulses captured on since initialization or last reset.
config | sensor hardware configuration |
enum sensor_types get_sensor_reading_setup | ( | sensor_reading_config_t * | config | ) |
Get the sensor type set for a hardware configuration.
config | sensor hardware configuration |
float get_sensor_voltage_reading | ( | sensor_reading_config_t * | config | ) |
Get the sensor voltage reading for a given sensor, takes into account the VOLTAGE_READ_DIVIDER_HIGH and VOLTAGE_READ_DIVIDER_LOW values.
config | sensor hardware configuration |
int reset_sensor_pulse_count | ( | sensor_reading_config_t * | config | ) |
Reset the pulse count for a given sensor to 0.
config | sensor hardware configuration |
int sensor_reading_setup | ( | sensor_reading_config_t * | config, |
enum sensor_types | sensor_type | ||
) |
Setup sensor for sensor_type with hardware configuration.
config | sensor hardware configuration |
sensor_type | type of sensor to be set to |