Electron not charging connected battery

Hi!

There are certainly a lot of similar sounding posts in this forum, but I haven’t seen any that touch on this issue directly. I submitted a support ticket to Particle, but wanted to share with the community to see if anyone else has had success digging into this problem (and hopefully finding a workaround!).


I’ve been seeing an issue intermittently across at least 6 devices in our “fleet” of 50 Electron units over the past year. In scenarios I have not yet been able to reproduce, the Electron will not charge the connected LiPo battery until the USB connector has been unplugged and plugged back in a number of times. Obviously this is a big headache when these service-critical devices are deployed and can only be charged overnight. To remedy this challenge I have actually built in an external 500mA charger onto the backplane board in future builds and will disable onboard PMIC charging… but I really don’t love this solution.

I finally caught a device which was doing this in the shop and was able to dig in a little deeper (though by no means did I resolve the issue). Here’s the process I went through, in as much detail as possible:

  • Noticed charge light was not illuminated on the Electron, despite being plugged in to a 5V,2A wall charger overnight
  • Measured battery voltage with a multimeter (probed the BAT pin on the device) and saw it was around 3.25V
  • Plugged unit into my laptop with a charge monitor and confirmed negligible current was going to the device
  • Wrote a test program to output all available fuel gauge and PMIC data:
     PMIC pmic;
     FuelGauge fuel;
     void setup() {
         Cellular.off();
         pmic.enableCharging();
         Serial.begin(9600);
     }
     void loop() {
         Serial.print("System Status Register: "); 
         Serial.println(pmic.getSystemStatus());
         Serial.print("Fault Register: ");         
         Serial.println(pmic.getFault());
         Serial.print("Charge Timer Register: ");  
         Serial.println(pmic.readChargeTermRegister());
         Serial.print("Minimum System Voltage: "); 
         Serial.println(pmic.getMinimumSystemVoltage());
         Serial.print("Charge Voltage Value: ");   
         Serial.println(pmic.getChargeVoltageValue());
         Serial.print("Charge Voltage: ");         
         Serial.println(pmic.getChargeVoltage());
         Serial.print("Charge Current: ");         
         Serial.println(pmic.getChargeCurrent());
         Serial.print("Battery Voltage: ");        
         Serial.println(fuel.getVCell());
         Serial.print("Battery Value: ");          
         Serial.println(fuel.getSoC());
         delay(5000);
     }
  • NOTE: When I loaded this firmware onto the device, I had not noticed the build environment was set to Device OS v1.0.0 (the Device OS running on the Electron at the time was 0.8.0-rc.4). The issue persisted across the automatic Device OS update (and we have seen it with devices running v0.7.0)
  • The script reported back the following:
    System Status Register: 0
    Fault Register: 0
    Charge Timer Register: 138
    Minimum System Voltage: 3500
    Charge Voltage Value: 4112
    Charge Voltage: 154
    Charge Current: 96
    Battery Voltage: 3.27
    Battery Value: 0.02
    • So, what’s curious is the Status Register, which (referring to the BQ24195 datasheet) is indicating VBUS is unknown. However, I was still able to program the Electron
  • At this point, out of curiosity, I unplugged the battery while leaving the Electron plugged into USB. All power to the board extinguished. Thinking it may be a micro USB connector issue, I measured the voltage to the VUSB/VBUS pin with a multimeter and it measured at 5V. So 5V is presumably still getting to the PMIC.
  • With the battery still unplugged, I unplugged and plugged in the USB connector (from my laptop) several times. Suddenly, the board revived. The charge LED rapidly blinked for a few seconds and then turned off (which I think is odd, because that light should keep blinking until a battery is connected)
  • I opened the Serial Monitor again and got the following:
    System Status Register: 69
    Fault Register: 0
    Charge Timer Register: 138
    Minimum System Voltage: 3500
    Charge Voltage Value: 4112
    Charge Voltage: 155
    Charge Current: 96
    Battery Voltage: 0.05
    Battery Value: 57.26
    • This appears to be normal, other than that I would have expected to see a Charge Fault
  • Now I unplugged USB, plugged in the battery, and plugged USB back in. The charge light turned on, and I saw 500mA of current being drawn from my USB port. Looking at the serial monitor once again:
    System Status Register: 109
    Fault Register: 0
    Charge Timer Register: 138
    Minimum System Voltage: 3500
    Charge Voltage Value: 4112
    Charge Voltage: 154
    Charge Current: 96
    Battery Voltage: 3.34
    Battery Value: 0.01
    • This all looks to be nominal

Any notes on this behaviour and how to work around it (e.g. a consistent way to reproduce it, and/or a consistent way to resolve it) would be greatly appreciated!

Thank you!

Jonathan

2 Likes

I’ve got a similar issue. My Electron is connected to USB and the red charging light is on solid. However the voltage reads 3.34v and the % reads 0.08. Yet when I unplug the USB, the Electron remains powered (from the battery which should be nearly dead). I’ve noticed this before, but am becoming more concerned because it now appears that the fuel gauge data is not correct. Is this a known problem; bad battery, or??

How many charging cycles have you had on that device?
Also how much current can your USB power source drive?
Try putting your device into standby by double clicking the SETUP button and let it charge for a few hours, then test again.

Thanks for the very fast reply!

It’s a fairly new unit - had it 3 weeks, so very few charging cycles as I’m still doing development testing.

After I wrote the post, it eventually went to 0% and the unit went to a rapid red flashing light. I swapped batteries and now have the Electron battery on a direct charger on the USB. The LiPo I now have on the Electron is charging at a normal rate - started at 3.88, 31.69% and is now at 3.88, 33.41%. What’s dd about this is that I take a reading every 30 seconds. The voltage remains the same at 3.88v, but the %% keeps going up. Or maybe that’s normal because the voltage of a LiPo is 3.7V.

I removed the Electron battery from the direct USB charger and plugged it back in to the Electron. It started at 3.15v, 31.26% and is declining from there… now at 3.07V and 15.43%.

So, it charges on a direct connection to the computer USB, but discharges when connected on the Electron. While another battery charges just fine on the Electron. I’m confused…

I use a MacBook Pro (since 2012) and have done a significant amount of development on Arduino-type boards, using LiPo batteries and never had any problems. Not sure, off hand, how much current it can drive, but I regularly use it to charge 2500mAh LiPo’s without any problem.