MCPcopy Create free account
hub / github.com/BruceDevices/firmware / GetVbatData

Method GetVbatData

lib/utility/AXP192.cpp:203–209  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

201//----------coulomb_end_at_here----------
202
203uint16_t AXP192::GetVbatData(void) {
204 uint16_t vbat = 0;
205 uint8_t buf[2];
206 ReadBuff(0x78, 2, buf);
207 vbat = ((buf[0] << 4) + buf[1]); // V
208 return vbat;
209}
210
211uint16_t AXP192::GetVinData(void) {
212 uint16_t vin = 0;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected