geeekpi / upsplus

UPS Plus is a new generation of UPS power management module. It is an improved version of the original UPS prototype. It has been fixed the bug that UPS could not charge and automatically power off during work time. It can not only perform good battery power management, but also provide stable voltage output and RTC functions. At the same time,it support for FCP, AFC, SFCP fast charge protocol, support BC1.2 charging protocol, support battery terminal current/voltage monitoring and support two-way monitoring of charge and discharge. It can provide programmable PVD function. Power Voltage Detector (PVD) can be used to detect if batteries voltage is below or above configured voltage. Once this function has been enabled, it will monitoring your batteries voltage, and you can control whether or not shut down Raspberry Pi via simple bash script or python script. This function will protect your batteries from damage caused by excessive discharge. It can provide Adjustable data sampling Rate. This function allows you to adjust the data sampling rate so that you can get more detailed battery information and also it will consume some power. The data sampling information can communicate with the upper computer device through the I2C protocol. UPS Plus supports the OTA firmware upgrade function. Once there is a new firmware update, it is very convenient for you to upgrade firmware for UPS Plus. The firmware upgrade can be completed only by connecting to the Internet,and execute a python script. Support battery temperature monitoring and power-down memory function. UPS Plus can be set to automatically start the Raspberry Pi after the external power comes on. The programmable shutdown and forced restart function will provide you with a remote power-off restart management method. That means you don’t need to go Unplug the power cable or press the power button to cut off the power again. You can set the program to disconnect the power supply after a few seconds after the Raspberry Pi is shut down properly. And you can also reconnect the power supply after a forced power failure to achieve a remote power-off and restart operation. Once it was setting up, you don't need to press power button to boot up your device which is very suitable for smart home application scenarios.
https://wiki.52pi.com/index.php?title=UPS_Plus_SKU:_EP-0136
MIT License
73 stars 25 forks source link

UPS disharge batteries to 0V and goes in power loop when back to AC is on and battery voltage < 3V #82

Open Siegurd01 opened 3 years ago

Siegurd01 commented 3 years ago

Hi!, I found 2 big problems in the UPS:

  1. If leave UPS in off state UPS continue to discharge the battery on itself (pogo output 0.42 Volts). So after some days the battery discharges to 0 Volts with is competently unacceptable behavior for UPS and damages Li-Ion battery dramatically.
  2. Then, if you want to power the UPS with external source and Back to AC register is HIGH it charge the battery with low current and when battery voltage is ~2.6v UPS tries to start (pogo voltage is ~2.6V), But the charging current is too low to power the Rpi board (Rpi starts endless reboot) so Rpi discharges the battery and the process loops. So no battery charging and no power to Rpi... Helps only disassemble the Raspberry so the UPS could charge the batteries, and only after 3.0V (on batteries) the board can power up Pri and continue to charge batteries to 100% with high current.

To solve second problem you can add check for battery voltage before UPS start. It may be user programed function. For example if battery voltage if below 3V UPS does not start and it will wait until battery charges to 3V and only then start up if Back to AC register is HIGH.

First problem can be solved by using monitor (BD4730) in battery line. It will "cut off" battery when battery voltage if below 3V with only 46 µA consumption on itself.
изображение from https://zelenyugol.ru/en/obogrevateli/zashchita-akb-avtomobilya-ot-glubokogo-razryada-ustroistva-zashchity/

UPD: I update UPS firmware in October 2021

fmonaca commented 3 years ago

This is exactly what I experienced as well, rendering this UPS unusable for me. Everytime I leave it off for a couple of days, it cannot turn on again as it enters the loop the OP mentioned. Not enough power to boot the RPI and thee RPI discharges the batteries.

Siegurd01 commented 3 years ago

And still no answers from developer. I wrote on Youtube, emal, Aliexpress store... But. I created hardware fix. And in 3 weeks the components should arrive and I solder this fix up. I will inform if that helps.

ngiaimocentrak commented 2 years ago

I still have this issue and would really appreciate to have some sort of feedback that would help stop this from happening. This is almost the perfect product for my use case and would love to use it more but this is really unfortunate.

galtobellojr commented 2 years ago

I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge.

Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off.

ArjenR49 commented 2 years ago

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply.

The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker.

If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard.

Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading.

Arjen Raateland (On The Road)

Op vr 17 jun. 2022 23:56 schreef galtobellojr @.***>:

I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge.

Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1159221324, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

ArjenR49 commented 2 years ago

Look into the role of register 0x19, restart upon return of AC, and 0x1A.

If your control script, when the battery voltage drops too low, initiates a shutdown of the OS, but then sets 0x19 to 0 instead of 1 as usual, and 0x1A to 60, the ups will make the pi shut down first, then after 60 seconds cut the power to the pi, and then I will just sit and wait for the operator (lights off). This assumes you operate the ups without AC power present except for charging when the pi is not in use.

If you choose 3200 mV for the protection voltage and the control script applies a margin of 200 mV, the pi will shut down when voltage is 3400 mV. There should still be left power left to keep the ups's MCU and other circuits powered for some time.

Then recharge the batteries in the UPS and start the pi again by pushing the button.

You'll need to launch the control script as a Cron job @reboot.

Does this sound like a plan? I think you cannot expect a ups to work without a controlling program.

Arjen (On The Road)

Op za 18 jun. 2022 03:37 schreef A. A. J. Raateland < @.***>:

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply.

The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker.

If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard.

Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading.

Arjen Raateland (On The Road)

Op vr 17 jun. 2022 23:56 schreef galtobellojr @.***>:

I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge.

Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1159221324, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

ArjenR49 commented 2 years ago

P.S. instead of 0x1A read 0x18! You would need to use the counter without restart ...

Arjen (On The Road)

Op za 18 jun. 2022 14:41 schreef A. A. J. Raateland < @.***>:

Look into the role of register 0x19, restart upon return of AC, and 0x1A.

If your control script, when the battery voltage drops too low, initiates a shutdown of the OS, but then sets 0x19 to 0 instead of 1 as usual, and 0x1A to 60, the ups will make the pi shut down first, then after 60 seconds cut the power to the pi, and then I will just sit and wait for the operator (lights off). This assumes you operate the ups without AC power present except for charging when the pi is not in use.

If you choose 3200 mV for the protection voltage and the control script applies a margin of 200 mV, the pi will shut down when voltage is 3400 mV. There should still be left power left to keep the ups's MCU and other circuits powered for some time.

Then recharge the batteries in the UPS and start the pi again by pushing the button.

You'll need to launch the control script as a Cron job @reboot.

Does this sound like a plan? I think you cannot expect a ups to work without a controlling program.

Arjen (On The Road)

Op za 18 jun. 2022 03:37 schreef A. A. J. Raateland < @.***>:

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply.

The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker.

If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard.

Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading.

Arjen Raateland (On The Road)

Op vr 17 jun. 2022 23:56 schreef galtobellojr @.***>:

I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge.

Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1159221324, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

ngiaimocentrak commented 2 years ago

I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge.

Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off.

I have found that the USB output ports of the UPS itself are still powered even if the UPS has been turned off by pressing the button and the Pi has shutdown as well. I checked this by plugging in a USB current tester to the USB output port of the UPS and found it powered on the tester, drawing 5.12V and pulling a few hundred mA. If you have anything plugged in there, that is probably what is draining the batteries to 0V even after shutting off the Pi at the protection voltage.

ngiaimocentrak commented 2 years ago

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply. The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker. If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard. Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading. Arjen Raateland (On The Road) Op vr 17 jun. 2022 23:56 schreef galtobellojr @.>: I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge. Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off. — Reply to this email directly, view it on GitHub <#82 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.>

The comment about the FW version is interesting. I did not update it from what I got it from originally so I do not know what it is on. Are there any patch notes to describe some of the changes?

The main thing I am trying to prevent is the UPS still providing voltage and current at its USB outputs when powered down. This is causing the batteries to drain to super low voltages. I do have the control script enabled setting the protection voltage to automatically shut down at 3300 mV with a 200 mV buffer - and it does shut down correctly. When I test the voltage of the batteries some hours past when it automatically shut down, they are down to 1.2V or lower. I have a device that is plugged into the USB out that draws a few hundred mA so I want the USB ports to stop providing current while shut down.

When I try to plug the AC back in - the Pi and UPS go into a boot loop as there is not enough voltage to power on properly and it never charges (and has corrupted at least 1 SD card). If I could delay the back to AC from trying to power up the Pi until the UPS is sufficiently charged, that would be a solution as well if preventing the USB ports from providing power is not possible.

Any advise on these 2 solutions would be great. Thank you for your time.

ArjenR49 commented 2 years ago

If you're into electronics, you could build a switch contraption in a usb cable you cut in two and connect the ends to a small PCB. Interrupt only the +5 V line in the PCB. Using a power FET with a low resistance in the ON state and a suitably low gate threshold voltage in the +5V line you could disconnect power to the usb peripheral when the pi is off.

You probably need some level shifting between +5 V or +3,3 V on the pi and the gate of the power FET. A single BJT may fit that position.

I don't think it's all that difficult to find suitable components. Build it one step at a time and test as you go.

I didn't find any commercial product to do this, which doesn't mean such a product doesn't exist.

When the UPS cuts power to the pi, the voltage on the +5 V and +3,3 V pin of the pi goes to zero and that should provide suitable timing for switching the usb peripheral off as well.

Arjen (On The Road)

Op wo 22 jun. 2022 00:42 schreef ngiaimocentrak @.***>:

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply. The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker. If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard. Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading. Arjen Raateland (On The Road) Op vr 17 jun. 2022 23:56 schreef galtobellojr @.

>: … <#m-5209456298656092683> I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge. Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off. — Reply to this email directly, view it on GitHub <#82 (comment) https://github.com/geeekpi/upsplus/issues/82#issuecomment-1159221324>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.>

The comment about the FW version is interesting. I did not update it from what I got it from originally so I do not know what it is on. Are there any patch notes to describe some of the changes?

The main thing I am trying to prevent is the UPS still providing voltage and current at its USB outputs when powered down. This is causing the batteries to drain to super low voltages. I do have the control script enabled setting the protection voltage to automatically shut down at 3300 mV with a 200 mV buffer - and it does shut down correctly. When I test the voltage of the batteries some hours past when it automatically shut down, they are down to 1.2V or lower. I have a device that is plugged into the USB out that draws a few hundred mA so I want the USB ports to stop providing current while shut down.

When I try to plug the AC back in - the Pi and UPS go into a boot loop as there is not enough voltage to power on properly and it never charges (and has corrupted at least 1 SD card). If I could delay the back to AC from trying to power up the Pi until the UPS is sufficiently charged, that would be a solution as well if preventing the USB ports from providing power is not possible.

Any advise on these 2 solutions would be great. Thank you for your time.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1162395880, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNRKVOJKPSSUBROSQN3VQIZK7ANCNFSM5GGJQSZQ . You are receiving this because you commented.Message ID: @.***>

ArjenR49 commented 2 years ago

PS. if my suggestion works, and you're adventurous, you could build the circuit to interrupt the +5 V to the usb connectors on the UPS board itself. You might even be able to use a single circuit for both usb ports. You'd have to solder reliably to PCB traces on the UPS board, though, and find out where exactly the +5 V is routed to the usb ports on the UPS and cut the trace or traces. 52pi could/should have included such a power switch on the UPS. Perhaps with a jumper to choose whether to cut power to the peripherals or leave it connected when the pi is powered down. Or controlled by the f/w.

Arjen (On The Road)

Op wo 22 jun. 2022 11:23 schreef A. A. J. Raateland < @.***>:

If you're into electronics, you could build a switch contraption in a usb cable you cut in two and connect the ends to a small PCB. Interrupt only the +5 V line in the PCB. Using a power FET with a low resistance in the ON state and a suitably low gate threshold voltage in the +5V line you could disconnect power to the usb peripheral when the pi is off.

You probably need some level shifting between +5 V or +3,3 V on the pi and the gate of the power FET. A single BJT may fit that position.

I don't think it's all that difficult to find suitable components. Build it one step at a time and test as you go.

I didn't find any commercial product to do this, which doesn't mean such a product doesn't exist.

When the UPS cuts power to the pi, the voltage on the +5 V and +3,3 V pin of the pi goes to zero and that should provide suitable timing for switching the usb peripheral off as well.

Arjen (On The Road)

Op wo 22 jun. 2022 00:42 schreef ngiaimocentrak @.***

:

Short answer: a ups is intended for keeping a computer running even though there's loss of external power. In case the interruption takes too long and the battery voltage drops too much, a control program is supposed to detect that, halt the computer and switch off power. Then usually restart the computer when external power returns. It's not a battery power supply. The UPS plus by Geeekpi is not too well documented IMO and may require a lot of work to get it to reliably do what you think it should do. Documentation is in English, but likely written by a Chinese speaker. If the UPS doesn't reliably do what you think it should, you loose control of the computer and you'll have to get physical access to it which may be burdensome, or if indeed it manages to allow the batteries to go totally dead, you may have a fire hazard. Also the way it operates has changed a lot going from f/w version 3 to version 10. So old comments may be misleading. Arjen Raateland (On The Road) Op vr 17 jun. 2022 23:56 schreef galtobellojr @.

>: … <#m_-4906248457797540155m-5209456298656092683_> I've wanted to use this as an "attached battery" for some projects. Pull it off the shelf, stick in an SD card, run it portable, then plug in to recharge. Only the batteries run down to 0V in a week or two when not on AC power. So while I've not had the (more pressing and troubling) problem of continued reboots, the question still remains of what's drawing down the batteries when unplugged and powered off. — Reply to this email directly, view it on GitHub <#82 (comment) https://github.com/geeekpi/upsplus/issues/82#issuecomment-1159221324>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ https://github.com/notifications/unsubscribe-auth/ANCBKNTNDFRXMVZXEP5V7CDVPTQ7LANCNFSM5GGJQSZQ . You are receiving this because you are subscribed to this thread.Message ID: @.>

The comment about the FW version is interesting. I did not update it from what I got it from originally so I do not know what it is on. Are there any patch notes to describe some of the changes?

The main thing I am trying to prevent is the UPS still providing voltage and current at its USB outputs when powered down. This is causing the batteries to drain to super low voltages. I do have the control script enabled setting the protection voltage to automatically shut down at 3300 mV with a 200 mV buffer - and it does shut down correctly. When I test the voltage of the batteries some hours past when it automatically shut down, they are down to 1.2V or lower. I have a device that is plugged into the USB out that draws a few hundred mA so I want the USB ports to stop providing current while shut down.

When I try to plug the AC back in - the Pi and UPS go into a boot loop as there is not enough voltage to power on properly and it never charges (and has corrupted at least 1 SD card). If I could delay the back to AC from trying to power up the Pi until the UPS is sufficiently charged, that would be a solution as well if preventing the USB ports from providing power is not possible.

Any advise on these 2 solutions would be great. Thank you for your time.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1162395880, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNRKVOJKPSSUBROSQN3VQIZK7ANCNFSM5GGJQSZQ . You are receiving this because you commented.Message ID: @.***>

ngiaimocentrak commented 2 years ago

While that may be a bit beyond me at this time, I do have a lot of hardware engineering resources so I may be able to get something like that done. Shame it isn't on the board itself or a firmware related thing. Thank you.

ArjenR49 commented 2 years ago

What you would need is a P-channel MOSFET, a small signal NPN transistor and two resistors. Minimum. Choose the MOSFET for low on resistance and low gate threshold, 3 V.

Arjen (On The Road)

Op wo 22 jun. 2022 17:08 schreef ngiaimocentrak @.***>:

While that may be a bit beyond me at this time, I do have a lot of hardware engineering resources so I may be able to get something like that done. Shame it isn't on the board itself or a firmware related thing. Thank you.

— Reply to this email directly, view it on GitHub https://github.com/geeekpi/upsplus/issues/82#issuecomment-1163149776, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANCBKNQSKFUVXMS3W5MG2SDVQMM7BANCNFSM5GGJQSZQ . You are receiving this because you commented.Message ID: @.***>

galtobellojr commented 2 years ago

Apologies for not responding sooner, but:

The scenario I described is experienced when the UPS is shut down and disconnected from power.

I have some small experience with UPSes over several decades, some with but most without interface to the powered devices (such as the power-strip-style for home use, as well as those in large raised-floor environments with diesel backup).

None, in my experience, discharged themselves when powered down and no A/C.

I mention this now after reading comments regarding 5V still available at the USB when shutdown, because:

This whole problem saddens me, as the UPS device would fit my use cases if it didn't require battery removal when shutdown.

ngiaimo commented 2 years ago

Apologies for not responding sooner, but:

The scenario I described is experienced when the UPS is shut down and disconnected from power.

  • Rpi & UPS running on A/C; blue lights & log indicate batteries fully charged.
  • Shutdown RPi & UPS normally, not set to autostart.
  • All lights off on RPi & UPS.
  • Unplug from A/C power. Nothing is connected to any USB, camera, video port. Only the bare RPi mounted to UPS.
  • Come back in a few days & attempt to start, expecting batteries to still be fully charged. Nada.
  • Remove batteries & test: They show 0V.

I have some small experience with UPSes over several decades, some with but most without interface to the powered devices (such as the power-strip-style for home use, as well as those in large raised-floor environments with diesel backup).

None, in my experience, discharged themselves when powered down and no A/C.

I mention this now after reading comments regarding 5V still available at the USB when shutdown, because:

  • I'm suspecting that if true (not yet verified on my setup), it makes sense that the batteries are drained to unsafe (0V) levels over time. Just providing 5V to the empty USB would do this in time. "Off" should mean OFF, IMHO.
  • Any circuit added between USB jack & connected devices, intended to interrupt power to the external device when UPS is off, will only delay the inevitable. (If I've misread, and the circuitry actually kills the onboard USB circuitry, then mea culpa...)

This whole problem saddens me, as the UPS device would fit my use cases if it didn't require battery removal when shutdown.

Yeap - I actually was able to get a board that does that created. I plug it into both USB ports, then I plug my peripherals in to the new board. It passes through the current when at 5V (device powered on) and blocks it when the device is powered off (4.2V or less) using a comparator. I can confirm that the voltage supplied to the USBs when powered off is equivalent to the voltage the batteries are currently at.

You are right though - it delays the inevitable. For me, this should be okay as my system should be running most of the time and I just need the batteries + drain time to be long enough to get power back on. This should almost always be the case, but it could unfortunately still get too low and cause the boot loop issue. For storage, I am going to be using battery pull tabs.

It is a shame - this device is perfect for my use case in almost every way if not for this issue. I don't know why the battery power is connected directly to the USB ports even when the board is powered off, real annoying.

galtobellojr commented 2 years ago

@ngiaimo Are you using firmware v10? I've not tried it, but if what I've read is correct and it's increased the reboot time from 30sec to 10min, that may address your unending boot loop. I'm thinking that the unexplained (from what I've read) increase to 10min should give the batteries more charge before a boot-and-undervolt-shutdown. If not on the first loop, consecutive undervolt-shutdown-charge-10min-reboot cycles should get you up solid.

This is mere speculation from my reading; I'm not in a position to test just now, so YMMV. But if you're not on v10 it might be worth trying.

My attempt through Amazon asking about the battery drain was met with a "check your charger" reply, and so I have up on that avenue of inquiry ..

ngiaimo commented 2 years ago

@galtobellojr oh wow - that might do it. I am using whatever firmware came with them at this time so I will look into updating the firmware if it isn't on v10. If that can prevent the boot loops, that would make me feel so much better. Thanks, I will pop back and let you know the result!

galtobellojr commented 2 years ago

As I said, I've not tried it, but the complaints about 30s vs 10m had me thinking.

Looking forward to your experiences...

wiebel commented 2 years ago

The complete drainage of the batteries is indeed a show stopper. would be great if that could be fixed.

zanes83 commented 1 year ago

May I know if there is any further development for this issue?

Currently using UPLSPLUS EP 0136 firmware 10

Situation

Battery depleted below 3.00Vdc,

Is there progress of solution rather than removing load to charge it first? Or is that how an UPS should work?

Or is the UPS EP0136 can be programmed, so that it will focused on charging battery until Protection Level achieved only will turn on the load from Ups?

Thank you

Zanes

ngiaimo commented 1 year ago

Hey @zanes83 - I have been searching for that answer for ages and I reached out to their support email and could not convey the information to the one responding in a way that they actually provided useful information...they just did not seem to grasp what I was asking.

I do not have a good work around for this still - the only solution I have used is to have an external board plugged into the USB ports that prevent any current from flowing if less than 5V are coming out of the ports - indicating that it is no longer on. This helps prevent getting to the state where the battery gets too low to boot, but if it gets that far after time still (the external board draws a tiny amount of current but can add up over time), then we can still run into this issue with the boot loop.

I would love an easy solution as you said - do not power anything (USB ports or Pi) if the voltage is too low still. Desperately hoping for an answer.

zanes83 commented 1 year ago

Hi @ngiaimo

Through the supplier, managed to get in touch with someone who can respond on the issues raised.

Was informed that currently they are doing the operation of reproducing the issue. Currently in the test hoping to reproduce the problem encountered, and provide a solution at firmware level using OTA update to eliminate the BUG.

Had a total of 3 Pi damaged due to this issue, hopefully they will be able to get it done soon. fingers crossed

Besides, did raised another issue to them that the Shutdown Countdown will only count if removed power source and the timer will pause/halt when power had been reconnected.

I will update here if there is any good news received.

Cheers!

ngiaimo commented 1 year ago

@zanes83

Wow, that is great! It would be amazing if fixed.

Also, I literally just ran into the issue with being plugged in to AC and it not turning off as expected. That is also awesome if it is fixed as well. Appreciate you also putting in the effort. Please update if you hear anything!

sfatula commented 1 year ago

Dumb me. Left on a trip, thought, you never know, maybe storms whatever so I think I'll leave the power input to the UPS disconnected to protect ot while I am gone. Came back, you guessed it, won't boot! Came here to discover the issue and remedy as I don't have a charger for the batteries other than the UPS! Won't do that again! Since it's part of a case they make, a lot of effort to disconnect.

zanes83 commented 1 year ago

@ngiaimo

Good day pal

I had just received an email that there is a firmware update to resolve the issue. Gonna test it first. You may give it a shot and hope it works!

ngiaimo commented 1 year ago

@ngiaimo

Good day pal

I had just received an email that there is a firmware update to resolve the issue. Gonna test it first. You may give it a shot and hope it works!

Yooo! Good stuff! Please update with your results and I will look to run my own tests tomorrow. Thanks!

galtobellojr commented 1 year ago

@ngiaimo

Good day pal

I had just received an email that there is a firmware update to resolve the issue. Gonna test it first. You may give it a shot and hope it works!

Another owner hoping for good news. Just unpacked the very-dead pi/ups combo and am looking to try the new firmware as well. First, though, I have to reacquaint myself with everything (old memories die young...)

The two issues I consider mandatory to be fixed:
1) Batteries should not drain when unit is shut down, at least not at the present rate. Power failures in this area (Long Island, NY, USA) have exceeded several days, and a pair of 3000mAh batteries at full charge should be drained in that time. 2) There's a stored value for "empty voltage", and it makes no sense for the UPS to try to power anything until that value is exceeded. (Though my experience with li-ion batteries is thin, it's enough to consider there may be no way for a UPS to charge 0V batteries safely, in which case I'd expect to display a warning indicator and stay off.)

While I understand it's likely impossible to eliminate all current draw while in standby, what I've seen here leaves a too-short standby time before batteries are scarily depleted, and then manual intervention before power restoration.

To reiterate: While I agree that a UPS ideally communicates state with its load, that is not what I consider essential for a UPS. My bare essentials require the load to be: Protected from over- or under-voltages; Remain powered for some period after mains failure; Reasonably shut down after that period (notifying the load if possible, just a "plug pull" if not); and Restore load power safely once mains restored (and batteries reasonably charged). This is what I've experienced with inexpensive "power strip" types of UPSes over the years, as well as the data center installations.

I'm backing a Kickstarter "battery charger/power supply" that's undergoing production testing now; attaches via pogo pins, and claims "<100uA current draw when not in use" which should indeed last over a year on standby. I'll see how that performs.

galtobellojr commented 1 year ago

Finally got around to putting the UPS Plus onto the bench and spending some time with it.

Initially was encouraged to find the off-state power draw of a Raspberry Pi 4 was around 120uA. The thrill didn't last long, though. I metered the current draw from two 3000mAh 18650 cells, and when all is shutdown the current draw is around 17.5mA. If my math is correct, 17.5mA should drain 6000mAh cells in about two weeks? Which matches my experience.

Been awhile since I've done much bench work, but the numbers reflect my experience. After a day or so of mains outage, batteries will have drain to the point of shutdown, but then, in that drained state, will continue to have about 500mAh more drawn daily.

Hopefully the new firmware will allow rebooting such a drained setup, since one is guaranteed to have batteries well below the cutoff voltage when power returns after some hours/days. Either preventing repowering the load until a minimum battery voltage is reached, or programmatically distinguishing between "low battery" on the way down (shutdown) and the way up (hang on!).

I am disappointed.

sfatula commented 1 year ago

So, is there a firmware update and if so, what is the version?