Jump to content

Battery fault (expanding battery) / replacement


Recommended Posts

21 minutes ago, mbecroft said:

Which ROM are you running? I can confirm it works perfectly on LineageOS 11 December 20th release. (everything except "idle mode").

I also run LineageOS 11 December 20th release.

22 minutes ago, mbecroft said:

When I installed ACC (which I did via Magisk, but in theory this is not required), it defaulted to something like max charge up to 75%.

I have also installed it through Magisk but my problems may came from my faulty USB port, sometimes it does a charge/not charge/charge switch because of mechanical problems and when I see "slow charging" on screen, I know it won't charge even if LED shows charging.

Anyway, I have not tried AccA yet, I may try to find it but what I really need very soon is a new USB board or if it will fail, I may try to replace the connector... but that would only work if I have the very same connector in hand...

Otherwise, I would think Ampere is reading sysfs battery information, but it does not show a constant maximal capacity for me.
Currently it shows 2500 mAh (79% left), but I also saw 2000 mAh and 4400 mAh, the latter was close to depleted state and it showed different values in almost every run...

 

Link to post
Share on other sites
35 minutes ago, Rob. S. said:
2 hours ago, mbecroft said:

I suggest everyone who notes setting the charging rate and voltage with ACC is not working, try again on latest LineageOS. It is working perfectly for me on 20th December LoS.

I confirm that it works with my phone, too! (It's been a while that I tried and found it to not work, there were a few updates for both LineageOS and ACC in the meantime.) 

It's does not follow my voltage and current limits exactly, but it generally does what it says it does.

Addition: I have a strong suspicion that the "AccuBattery" app which I've been running just to see battery health changes over time interferes with the current and  voltage limiter function in ACC. After disabling it, ACC follows my limits more closely...

Link to post
Share on other sites
1 hour ago, Rob. S. said:

Addition: I have a strong suspicion that the "AccuBattery" app which I've been running just to see battery health changes over time interferes with the current and  voltage limiter function in ACC. After disabling it, ACC follows my limits more closely...

Another addition: There still is something wrong when I set limits not only for current, but also for voltage. AccA then reports the battery state as 'Charging (tapered)', and even though displayed current and voltage look plausible, the displayed battery level does not increase. 

In my case today it stayed at 49% for hours. Only after disabling the voltage limit, the battery level jumped in a few big leaps within a minute or so to 81% (even though my charge limit is 75%).

Looks like with an active voltage limit, the operating system is no longer informed about increasing battery levels.

Link to post
Share on other sites
32 minutes ago, Rob. S. said:

the battery level jumped in a few big leaps within a minute or so to 81%

Remember that the percentage is not an a measurement, but an estimate the phone tries to calculate as an educated guess. And if something (here for good reasons) is messing with the charging system, no big surprise that the estimate system gets a bit confused. See the sketch from this ancient post.

LiIonGuessing.png

  • Like 2
Link to post
Share on other sites
1 minute ago, EskeRahn said:

Remember that the percentage is not an a measurement, but an estimate the phone tries to calculate as an educated guess. And if something (here for good reasons) is messing with the charging system, no big surprise that the estimate system gets a bit confused

Indeed...

Still, I would expect this to work, with ACC being as widely used as it seems to be... 

My impression is that, with the voltage limit activated, the estimating process is lacking some input it normally would get while charging. Like the fact that the phone even is charging. (When I disable the voltage limit and only keep the current limit, the battery state changes from "Charging (Tapered)" to "Charging (Fast)"...)

  • Like 1
Link to post
Share on other sites
6 minutes ago, Rob. S. said:

My impression is that, with the voltage limit activated, the estimating process is lacking some input it normally would get while charging. Like the fact that the phone even is charging. (When I disable the voltage limit and only keep the current limit, the battery state changes from "Charging (Tapered)" to "Charging (Fast)"...)

Ok, now I'm seeing strange behaviour even without a voltage limit, with the battery level display becoming erratic... I guess for the time being I'll be reverting to my low-power chargers... 

Link to post
Share on other sites
18 minutes ago, EskeRahn said:

Remember that the percentage is not an a measurement, but an estimate the phone tries to calculate as an educated guess

Generally, charge estimation based on voltage is very inaccurate if we are speaking about Li-Ion-like batteries but old phones used this prediction.

However, there are "battery fuel gauge" ICs which a modern phone should use and it measures incoming/outgoing charge of the battery (charge / discharge quantity). It may have a very good prediction based on charge/discharge current, voltage, elapsed time, predicted battery degradation, etc.

...so it is much more complicated than simply measuring battery voltage what would be very inacurate if we are speaking about accurate percents...

Through sysfs, we are most probably speaking with such fuel gauge / power management-related kernel module which speaks with appropriate electrical circuit...

  • Like 1
  • Thanks 1
Link to post
Share on other sites

In case you have root, you can take a look at /sys/class/power_supply/...

Just open any of the files inside the sub-directories of power_supply as text file to get an idea what it does. Some files can be read to get information about the hardware, like the battery voltage. Other files can be written to, to control the hardware. After some trial & error, you should have an idea which files are important to control the charging process. I guess this is also how ACC works.

With apps like Automate or Tasker, you can run different scripts/commands to control the charge process in different scenarios. It might be possible to only use the connected power supply in your car to run the phone, without charging the battery (by setting /sys/class/power_supply/battery/charging_enabled to 0?). In this case, use your car's Bluetooth connection, or an NFC tag, to trigger the respective script in/with Automate or Tasker. Since the Android system, or installed apps, may influence the charging behaviour, make sure to run your battery control script/commands e.g. every 10 seconds, as long as a certain power supply is connected.

Since /sys is a virtual file system, you cannot screw up the software. But you can damage your hardware, e.g. by setting voltage_max to 4500000 (4.5V). The Pro1 should have an independent charging and battery protection circuit to prevent overcharging, or charging when the battery is too cold/hot, but you shouldn't rely on that.

Also, think of battery "chargers" as power supplies. The actual charger is inside the phone itself. Some power supplies communicate with the phone hardware to negotiate voltage and current, others don't. Cheap or badly designed power supplies come without a current limiter, or the current limit is set too high. In this case, the power supply will provide as much current as the phone "requests", and the power supply may overheat ... and melt. DiodeGoneWild on YouTube tests and disassembles many dogy power supplies (and he has a cute cat!). An overheating power supply can melt the (crappy) insulation of its transformer windings and connect the 220V input voltage directly to its USB port. This is pretty scary and it actually kills people ...

  • Like 3
Link to post
Share on other sites
13 minutes ago, daniel.schaaaf said:

Since /sys is a virtual file system, you cannot screw up the software. But you can damage your hardware, e.g. by setting voltage_max to 4500000 (4.5V). The Pro1 should have an independent charging and battery protection circuit to prevent overcharging, or charging when the battery is too cold/hot, but you shouldn't rely on that.

I really hope kernel module (which provides sysfs virtual files) checks for too high given voltage limits (not checked).

Link to post
Share on other sites
54 minutes ago, daniel.schaaaf said:

In case you have root, you can take a look at /sys/class/power_supply/...

For those with GNU/Linux-chroots: UPower provides a friendly interface to display the information from that sysfs tree. E.g.

rostkatze:~ # upower -e
/org/freedesktop/UPower/devices/battery_battery                                 
/org/freedesktop/UPower/devices/line_power_dc                                   
/org/freedesktop/UPower/devices/battery_main                                    
/org/freedesktop/UPower/devices/line_power_pc_port                              
/org/freedesktop/UPower/devices/line_power_usb                                  
/org/freedesktop/UPower/devices/battery_bms                                     
/org/freedesktop/UPower/devices/battery_parallel                                
/org/freedesktop/UPower/devices/DisplayDevice                                   
rostkatze:~ # upower -i /org/freedesktop/UPower/devices/battery_bms
  native-path:          bms
  power supply:         yes
  updated:              Mon 03 Jan 2022 11:14:56 CET (72 seconds ago)
  has history:          yes
  has statistics:       yes
  battery
    present:             yes
    rechargeable:        yes
    state:               discharging
    warning-level:       none
    energy:              9.7981 Wh
    energy-empty:        0 Wh
    energy-full:         12.7248 Wh
    energy-full-design:  12.6632 Wh
    energy-rate:         0.146093 W
    voltage:             4.07616 V
    time to empty:       2.8 days
    percentage:          77%
    temperature:         21 degrees C
    capacity:            100%
    icon-name:          'battery-full-symbolic'
  History (rate):
    1641204896  0.146   discharging

Root is still needed of course.

Edited by claude0001
  • Like 2
Link to post
Share on other sites
  • 2 weeks later...

Hey guys,

Just as a minor update, I've been running ACC / AccA for a while now and it continues to work great. Charging current limit is rock-solid and will definitely prevent fast-charging if you don't want it.

As others have noted, tweaking the PMIC settings may mess with the battery "fuel gauge." If you use more extreme settings, the more it may be messed up. Charging current limit is straight-forward and won't mess with the fuel gauge much/at all, as it works by measuring current in and out.

One thing that will seriously mess up the fuel gauge is the max charge voltage. I've set charge voltage to 4.3V (instead of default 4.4) as another way to reduce stress on the battery). This does not mess with things too much, but setting the charge voltage significantly lower is not only probably not useful, but really messes with the power subsystem and battery percentage. Not recommended.

There is overlap between the max charge % setting and the charge voltage setting. You could have no % charge limit, but at (say) 4.3V, the cell will actually never be "fully" charged.

Another poster suggested tweaking the charge_enable in sysfs to turn charging on and off. This would be equivalent to ACC's "battery idle mode." I've not tested this yet, and it depends on the power subsystem design whether it will work/have any effect. If it does, then ACC should be updated to use it. Otherwise as suggested, you could control it with a tasker or other automated shell script. If I give this a try next few days, will report.

Summing up, ACC has worked perfectly for me so far to (a) completely prevent unwanted fast-charging and (b) treat the battery a bit more gently by not charging and floating it at the absolute max all the time. Also, my repaired battery continues to perform perfectly. IMHO ACC or equivalent is an essential tool to avoid unnecessarily battery wear and extend the life of the battery.

Edited by mbecroft
  • Like 4
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

Terms