Drivers: skip initialization if bq27220 is unresponsive (#435)

This commit is contained in:
あく
2021-04-30 07:47:02 +03:00
committed by GitHub
parent 724b738048
commit eb82748d50
2 changed files with 9 additions and 4 deletions

View File

@@ -66,8 +66,10 @@ typedef struct {
uint16_t DOD100;
} ParamCEDV;
/** Initialize Driver */
void bq27220_init(const ParamCEDV* cedv);
/** Initialize Driver
* @return true on success, false otherwise
*/
bool bq27220_init(const ParamCEDV* cedv);
/** Get battery voltage in mV or error */
uint16_t bq27220_get_voltage();