-
Notifications
You must be signed in to change notification settings - Fork 4
Closed
Description
I'm trying to troubleshoot a potential hardware issue.
When I power the ESP32-C6 Things Plus board via a usb cable (no battery connected- the Fuel Gauge reports back 4.0 +/- a 0.1V and provides a SOC. Code is below
Based on the schematic it looks like the fuel gauge should only receive power when the battery is connected. When the battery and USB cable are connected, the SOC & Voltage do not change.
Could this be a potential mosfet failure, or is there another explanation?
using the following code
#include <Wire.h>
#include <SparkFun_MAX1704x_Fuel_Gauge_Arduino_Library.h>
SFE_MAX1704X lipo(MAX1704X_MAX17048);
void setup() {
Serial.begin(115200);
Wire.begin();
if (!lipo.begin()) {
Serial.println("MAX17048 not detected");
while (1)
;
}
lipo.quickStart();
lipo.setThreshold(20);
digitalWrite(RGB_BUILTIN, HIGH); // Turn the RGB LED white
}
void loop() {
Serial.println(lipo.getVoltage());
Serial.println(lipo.getSOC());
delay(1000);
}
Metadata
Metadata
Assignees
Labels
No labels