61#define PWR_MNGMT_ADDR 0x7F
64#define PM_ENABLE_PORT_BASE GPIO_PORT_TO_BASE(PM_ENABLE_PORT)
65#define PM_ENABLE_PIN_MASK GPIO_PIN_MASK(PM_ENABLE_PIN)
82 PM_EXTERNAL_REFERENCE,
100#define BATT_CHARGED_VAL 0
101#define BATT_UNCHARGED_VAL 1
103#define PM_REFERENCE_INTERNAL 0
104#define PM_REFERENCE_EXTERNAL 1
111#define PM_SOFT_SHTDN_INTERVAL 5720
113#define PM_SOFT_SHTDN_0_5_SEC 8
114#define PM_SOFT_SHTDN_1_SEC 17
115#define PM_SOFT_SHTDN_1_4_SEC 25
116#define PM_SOFT_SHTDN_5_7_SEC 100
117#define PM_SOFT_SHTDN_30_SEC 524
118#define PM_SOFT_SHTDN_1_MIN 1049
119#define PM_SOFT_SHTDN_5_MIN 5245
120#define PM_SOFT_SHTDN_10_MIN 10490
121#define PM_SOFT_SHTDN_1_H 62937
122#define PM_SOFT_SHTDN_24_H 1510490
123#define PM_SOFT_SHTDN_7_DAYS 10573427
124#define PM_SOFT_SHTDN_14_DAYS 21146853
125#define PM_SOFT_SHTDN_28_DAYS 42383709
126#define PM_SOFT_SHTDN_TEST 0xCC00FFEE
133} pm_charge_current_states;
138#define PM_VBAT_MULT (float)-181.9
139#define PM_VBAT_OFF (float)1294.72
Header file with register and macro declarations for the cc2538 GPIO module.
uint32_t pm_get_timeout(void)
Gets the current timeout value configured in power management module.
int8_t pm_get_voltage(uint16_t *state)
Reads the voltage of the external battery if connected to VIN pin.
int8_t pm_reset_system(void)
Restarts the on-board low-power PIC, provoking a board reset.
int8_t pm_enable(void)
Initializes the Power Management driver.
int8_t pm_get_fw_ver(uint8_t *fwver)
Gets the current firmware version of power management module.
uint32_t pm_get_num_cycles(void)
Gets current cycles.
int8_t pm_shutdown_now(uint8_t type)
Disconnects the board battery and enter shutdown mode PM_SOFT/HARD_SLEEP_CONFIG.
int8_t pm_set_timeout(uint32_t time)
Configure Internal Timeout for Hard and Soft shutdown modes.