![]() |
LibDriver ADS1115
|
ads1115 interrupt driver modules More...
Enumerations | |
| enum | ads1115_pin_t { ADS1115_PIN_LOW = 0x00 , ADS1115_PIN_HIGH = 0x01 } |
| ads1115 pin enumeration definition More... | |
| enum | ads1115_compare_t { ADS1115_COMPARE_THRESHOLD = 0x00 , ADS1115_COMPARE_WINDOW = 0x01 } |
| ads1115 compare mode enumeration definition More... | |
| enum | ads1115_comparator_queue_t { ADS1115_COMPARATOR_QUEUE_1_CONV = 0x00 , ADS1115_COMPARATOR_QUEUE_2_CONV = 0x01 , ADS1115_COMPARATOR_QUEUE_4_CONV = 0x02 , ADS1115_COMPARATOR_QUEUE_NONE_CONV = 0x03 } |
| ads1115 comparator queue enumeration definition More... | |
Functions | |
| uint8_t | ads1115_set_alert_pin (ads1115_handle_t *handle, ads1115_pin_t pin) |
| set the alert pin active status | |
| uint8_t | ads1115_get_alert_pin (ads1115_handle_t *handle, ads1115_pin_t *pin) |
| get the alert pin active status | |
| uint8_t | ads1115_set_compare_mode (ads1115_handle_t *handle, ads1115_compare_t compare) |
| set the interrupt compare mode | |
| uint8_t | ads1115_get_compare_mode (ads1115_handle_t *handle, ads1115_compare_t *compare) |
| get the interrupt compare mode | |
| uint8_t | ads1115_set_comparator_queue (ads1115_handle_t *handle, ads1115_comparator_queue_t comparator_queue) |
| set the interrupt comparator queue | |
| uint8_t | ads1115_get_comparator_queue (ads1115_handle_t *handle, ads1115_comparator_queue_t *comparator_queue) |
| get the interrupt comparator queue | |
| uint8_t | ads1115_set_compare (ads1115_handle_t *handle, ads1115_bool_t enable) |
| enable or disable the interrupt compare | |
| uint8_t | ads1115_get_compare (ads1115_handle_t *handle, ads1115_bool_t *enable) |
| get the interrupt compare status | |
| uint8_t | ads1115_set_compare_threshold (ads1115_handle_t *handle, int16_t high_threshold, int16_t low_threshold) |
| set the interrupt compare threshold | |
| uint8_t | ads1115_get_compare_threshold (ads1115_handle_t *handle, int16_t *high_threshold, int16_t *low_threshold) |
| get the interrupt compare threshold | |
| uint8_t | ads1115_convert_to_register (ads1115_handle_t *handle, float s, int16_t *reg) |
| convert a adc value to a register raw data | |
| uint8_t | ads1115_convert_to_data (ads1115_handle_t *handle, int16_t reg, float *s) |
| convert a register raw data to a converted adc data | |
ads1115 interrupt driver modules
ads1115 comparator queue enumeration definition
Definition at line 153 of file driver_ads1115.h.
| enum ads1115_compare_t |
ads1115 compare mode enumeration definition
| Enumerator | |
|---|---|
| ADS1115_COMPARE_THRESHOLD | threshold compare interrupt mode |
| ADS1115_COMPARE_WINDOW | window compare interrupt mode |
Definition at line 144 of file driver_ads1115.h.
| enum ads1115_pin_t |
ads1115 pin enumeration definition
| Enumerator | |
|---|---|
| ADS1115_PIN_LOW | set pin low |
| ADS1115_PIN_HIGH | set pin high |
Definition at line 135 of file driver_ads1115.h.
| uint8_t ads1115_convert_to_data | ( | ads1115_handle_t * | handle, |
| int16_t | reg, | ||
| float * | s ) |
convert a register raw data to a converted adc data
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | reg | register raw data |
| [out] | *s | pointer to a converted adc value buffer |
Definition at line 1328 of file driver_ads1115.c.
| uint8_t ads1115_convert_to_register | ( | ads1115_handle_t * | handle, |
| float | s, | ||
| int16_t * | reg ) |
convert a adc value to a register raw data
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | s | converted adc value |
| [out] | *reg | pointer to a register raw buffer |
Definition at line 1259 of file driver_ads1115.c.
| uint8_t ads1115_get_alert_pin | ( | ads1115_handle_t * | handle, |
| ads1115_pin_t * | pin ) |
get the alert pin active status
| [in] | *handle | pointer to an ads1115 handle structure |
| [out] | *pin | pointer to a pin alert active status buffer |
Definition at line 456 of file driver_ads1115.c.
| uint8_t ads1115_get_comparator_queue | ( | ads1115_handle_t * | handle, |
| ads1115_comparator_queue_t * | comparator_queue ) |
get the interrupt comparator queue
| [in] | *handle | pointer to an ads1115 handle structure |
| [out] | *comparator_queue | pointer to an interrupt comparator queue |
Definition at line 702 of file driver_ads1115.c.
| uint8_t ads1115_get_compare | ( | ads1115_handle_t * | handle, |
| ads1115_bool_t * | enable ) |
get the interrupt compare status
| [in] | *handle | pointer to an ads1115 handle structure |
| [out] | *enable | pointer to a bool value buffer |
Definition at line 1143 of file driver_ads1115.c.
| uint8_t ads1115_get_compare_mode | ( | ads1115_handle_t * | handle, |
| ads1115_compare_t * | compare ) |
get the interrupt compare mode
| [in] | *handle | pointer to an ads1115 handle structure |
| [out] | *compare | pointer to an interrupt compare mode buffer |
Definition at line 538 of file driver_ads1115.c.
| uint8_t ads1115_get_compare_threshold | ( | ads1115_handle_t * | handle, |
| int16_t * | high_threshold, | ||
| int16_t * | low_threshold ) |
get the interrupt compare threshold
| [in] | *handle | pointer to an ads1115 handle structure |
| [out] | *high_threshold | pointer to an interrupt high threshold buffer |
| [out] | *low_threshold | pointer to an interrupt low threshold buffer |
Definition at line 1220 of file driver_ads1115.c.
| uint8_t ads1115_set_alert_pin | ( | ads1115_handle_t * | handle, |
| ads1115_pin_t | pin ) |
set the alert pin active status
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | pin | alert active status pin |
Definition at line 411 of file driver_ads1115.c.
| uint8_t ads1115_set_comparator_queue | ( | ads1115_handle_t * | handle, |
| ads1115_comparator_queue_t | comparator_queue ) |
set the interrupt comparator queue
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | comparator_queue | interrupt comparator queue |
Definition at line 657 of file driver_ads1115.c.
| uint8_t ads1115_set_compare | ( | ads1115_handle_t * | handle, |
| ads1115_bool_t | enable ) |
enable or disable the interrupt compare
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | enable | bool value |
Definition at line 1098 of file driver_ads1115.c.
| uint8_t ads1115_set_compare_mode | ( | ads1115_handle_t * | handle, |
| ads1115_compare_t | compare ) |
set the interrupt compare mode
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | compare | interrupt compare mode |
Definition at line 493 of file driver_ads1115.c.
| uint8_t ads1115_set_compare_threshold | ( | ads1115_handle_t * | handle, |
| int16_t | high_threshold, | ||
| int16_t | low_threshold ) |
set the interrupt compare threshold
| [in] | *handle | pointer to an ads1115 handle structure |
| [in] | high_threshold | interrupt high threshold |
| [in] | low_threshold | interrupt low threshold |
Definition at line 1181 of file driver_ads1115.c.