Contiki-NG
|
Files | |
file | batmon-sensor.c |
Driver for the CC13xx/CC26xx AON battery monitor. | |
file | batmon-sensor.h |
Header file for the CC13xx/CC26xx battery monitor. | |
Functions | |
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.
|
static |
Configuration function for the battery monitor sensor.
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 95 of file batmon-sensor.c.
References configure(), and value().
Referenced by configure().
|
static |
Returns the status of the sensor.
type | SENSORS_ACTIVE or SENSORS_READY |
Definition at line 123 of file batmon-sensor.c.
|
static |
Returns a reading from the sensor.
type | BATMON_SENSOR_TYPE_TEMP or BATMON_SENSOR_TYPE_VOLT |
Definition at line 68 of file batmon-sensor.c.
References value().
Referenced by configure(), and value().