|
static int | value (int type) |
| Returns a reading from the sensor.
|
|
static int | configure (int type, int enable) |
| Configuration function for the battery monitor sensor.
|
|
static int | status (int type) |
| Returns the status of the sensor.
|
|
Driver for the on-chip battery voltage and chip temperature sensor.
◆ configure()
static int configure |
( |
int | type, |
|
|
int | enable ) |
|
static |
Configuration function for the battery monitor sensor.
- Parameters
-
type | Activate, enable or disable the sensor. See below |
enable | If |
When type == SENSORS_HW_INIT we turn on the hardware When type == SENSORS_ACTIVE and enable==1 we enable the sensor When type == SENSORS_ACTIVE and enable==0 we disable the sensor
Definition at line 96 of file batmon-sensor.c.
References configure().
Referenced by configure().
◆ status()
static int status |
( |
int | type | ) |
|
|
static |
Returns the status of the sensor.
- Parameters
-
type | SENSORS_ACTIVE or SENSORS_READY |
- Returns
- 1 if the sensor is enabled
Definition at line 124 of file batmon-sensor.c.
◆ value()
static int value |
( |
int | type | ) |
|
|
static |
Returns a reading from the sensor.
- Parameters
-
type | BATMON_SENSOR_TYPE_TEMP or BATMON_SENSOR_TYPE_VOLT |
- Returns
- The value as returned by the respective CC26xxware function
Definition at line 67 of file batmon-sensor.c.