change battery measurement, add battery monitor
This commit is contained in:
@@ -3,6 +3,8 @@
|
||||
|
||||
#define PMU_EVENT_AXP_INT _BV(0)
|
||||
|
||||
#define PMU_BATTERY_CAP 380
|
||||
|
||||
/*
|
||||
* @brief setup pmu: axp202
|
||||
*
|
||||
@@ -15,5 +17,14 @@
|
||||
* @param ttgo pointer to an TTGOClass
|
||||
*/
|
||||
void pmu_loop( TTGOClass *ttgo );
|
||||
/*
|
||||
*
|
||||
* @brief get the charge of battery in percent
|
||||
*
|
||||
* @param ttgo pointer to an TTGOClass
|
||||
*
|
||||
* @return charge in percent
|
||||
*/
|
||||
uint32_t pmu_get_byttery_percent( TTGOClass *ttgo );
|
||||
|
||||
#endif // _PMU_H
|
||||
Reference in New Issue
Block a user