Battery Buddy

Rating: 
4.90476
Your rating: None Average: 4.9 (42 votes)

Fully discharging a battery and charging it back to full charge again wears it out sooner than you might expect. Battery Buddy can help you increase the battery lifetime by automatically pausing and resuming charging. You can set alerts for low and full enough charge levels, too.

New! Version 4.3.0 adds support for PineTab, developed by nephros! Thank you!

New! Version 4.2.0 adds support for setting maximum charge current for selected devices.

New! Version 4.1.0 adds initial support for Jolla Tablet.

Important: Sailjail support is enabled in Battery Buddy 4.0.0-1, which means it requires at least Sailfish OS 4.3 to work properly. For Sailfish OS 3.3 and up you should be able to use Battery Buddy 3.17-1. For older versions Battery Buddy 3.15-1 should work fine. For Sailfish OS 2.2 you have to download the legacy build.

The application comes with a service component that takes care of charger control and alerts. This means that the application doesn't have to be opened for alerts and limits to work - which is against Jolla Store policy, and hence worth mentioning here. You can control the service from the application (start/stop and enable/disable on boot).

There is now a logging option, which can be accessed via the Settings page pulley menu, with three logging options. You can copy the log contents, too, so submitting the service log for debugging purposes is now a lot more convenient! Using --verbose and --debug flags still work as before.

Please note that the charger control mechanism may not work for every device out there. So far it has been successfully tested with the following devices:

  • F(x)tec Pro¹
  • Fairphone 2
  • Jolla Phone
  • Pine64 PineTab
  • Sony Xperia 10 / 10 II / 10 III
  • Sony Xperia X / X Compact
  • Sony Xperia XA2 / XA2 Plus / XA2 Ultra
  • Sony Xperia Z3 Compact Tablet

Please let me know if it works for your device, or if it doesn't work!

Bug reports and translations are most welcome!

If you like my work and would like to support me, you can now buy me a coffee.

Source code can be found in GitHub.

Screenshots: 
Application versions: 
AttachmentSizeDate
File harbour-batterybuddy-3.16.2-1.aarch64.rpm128.95 KB24/11/2021 - 23:09
File harbour-batterybuddy-3.16.2-1.armv7hl.rpm125.24 KB24/11/2021 - 23:09
File harbour-batterybuddy-3.16.2-1.i486.rpm134.58 KB24/11/2021 - 23:09
File harbour-batterybuddy-3.17.0-1.aarch64.rpm129.5 KB20/03/2022 - 00:52
File harbour-batterybuddy-3.17.0-1.armv7hl.rpm126.65 KB20/03/2022 - 00:52
File harbour-batterybuddy-3.17.0-1.i486.rpm135.81 KB20/03/2022 - 00:52
File harbour-batterybuddy-4.0.0-1.aarch64.rpm127.77 KB20/03/2022 - 21:53
File harbour-batterybuddy-4.0.0-1.armv7hl.rpm124.93 KB20/03/2022 - 21:53
File harbour-batterybuddy-4.0.0-1.i486.rpm134.15 KB20/03/2022 - 21:53
File harbour-batterybuddy-4.1.0-1.aarch64.rpm174.43 KB28/08/2022 - 01:34
File harbour-batterybuddy-4.1.0-1.armv7hl.rpm172.03 KB28/08/2022 - 01:34
File harbour-batterybuddy-4.1.0-1.i486.rpm181.84 KB28/08/2022 - 01:34
File harbour-batterybuddy-4.1.1-1.aarch64.rpm174.7 KB28/08/2022 - 10:45
File harbour-batterybuddy-4.1.1-1.armv7hl.rpm172.31 KB28/08/2022 - 10:45
File harbour-batterybuddy-4.1.1-1.i486.rpm182.25 KB28/08/2022 - 10:45
File harbour-batterybuddy-4.2.2-1.aarch64.rpm177.35 KB01/01/2023 - 02:59
File harbour-batterybuddy-4.2.2-1.armv7hl.rpm174.72 KB01/01/2023 - 02:59
File harbour-batterybuddy-4.2.2-1.i486.rpm184.81 KB01/01/2023 - 02:59
File harbour-batterybuddy-4.2.3-1.aarch64.rpm179.55 KB04/03/2023 - 16:28
File harbour-batterybuddy-4.2.3-1.armv7hl.rpm176.99 KB04/03/2023 - 16:28
File harbour-batterybuddy-4.2.3-1.i486.rpm187.25 KB04/03/2023 - 16:28
File harbour-batterybuddy-4.2.4-1.aarch64.rpm179.8 KB05/03/2023 - 12:30
File harbour-batterybuddy-4.2.4-1.armv7hl.rpm177.11 KB05/03/2023 - 12:30
File harbour-batterybuddy-4.2.4-1.i486.rpm187.22 KB05/03/2023 - 12:30
File harbour-batterybuddy-4.2.5-1.aarch64.rpm182.66 KB05/03/2023 - 12:51
File harbour-batterybuddy-4.2.5-1.armv7hl.rpm180.05 KB05/03/2023 - 12:51
File harbour-batterybuddy-4.2.5-1.i486.rpm190.07 KB05/03/2023 - 12:51
File harbour-batterybuddy-4.3.0-1.aarch64.rpm177.52 KB17/04/2023 - 20:02
File harbour-batterybuddy-4.3.0-1.armv7hl.rpm175.28 KB17/04/2023 - 20:02
File harbour-batterybuddy-4.3.0-1.i486.rpm185.39 KB17/04/2023 - 20:02
File harbour-batterybuddy-4.3.1-1.aarch64.rpm177.67 KB22/04/2023 - 16:48
File harbour-batterybuddy-4.3.1-1.armv7hl.rpm175.31 KB22/04/2023 - 16:48
File harbour-batterybuddy-4.3.1-1.i486.rpm185.54 KB22/04/2023 - 16:48
File harbour-batterybuddy-4.3.2-1.aarch64.rpm178.04 KB25/04/2023 - 08:48
File harbour-batterybuddy-4.3.2-1.armv7hl.rpm175.3 KB25/04/2023 - 08:48
File harbour-batterybuddy-4.3.2-1.i486.rpm185.55 KB25/04/2023 - 08:48
Changelog: 

4.3.2-1

  • Fix maximum charge current setting

4.3.1-1

  • Update Polish translation (thanks, wetab73)
  • Update translation files in the repository

4.3.0-1

  • Add PineTab support (thanks, nephros)
  • Add Russian translation (I checked this time!) (thanks, sprainbrains)

4.2.5-1

  • Fixup! Include all translation files (include Slovak)

4.2.4-1

  • Fixup! Battery health is not displayed correctly

4.2.3-1

  • Add Slovak translation (thanks, okruhliak)
  • Update Swedish translation (thanks, eson57)
  • Add Support for AC Charger detection (thanks, nephros)
  • Be more efficient with handling file paths in constructors
  • Fix package dependencies

4.2.2-1

  • Replaces broken 4.2.0 and 4.2.1 releases
  • Restart the permission service on update
  • Properly read and set max current values on first startup
  • Add setting maximum charge current

4.1.1-1

  • Fixup! Use correct colors in battery graphic
  • Fixup! Enable low battery animation
  • Move all subpages to MainPage pull down menu
  • Update Swedish translation (thanks, eson57)
  • Update Polish translation (thanks, wetab73)
  • Update copyrights

4.1.0-1

  • Initial Jolla Tablet support (beta)
  • Redesign the logo and battery graphic
  • Search for control files using loops
  • Don't try to use non-existent files
  • Remove unused signals from service
  • Update Swedish translation (thanks, eson57)
  • Use ColumnView to show the log contents with formatting (thanks, nephros!)
  • Log charging/discharging current
  • Log temperature changes with resolution of one degree Celsius
  • Assume the charge current value always changes
  • Print correct log file name
  • Invert the charge current sign if necessary
  • Print changelog at the end of the build script
  • Use custom ImageButton in About page
  • Remove unused files
  • Rename internal logging functions for clarity
  • Built with Sailfish OS SDK 3.9 for 4.4.0.68

4.0.0-1

  • Enable sandboxing with appropriate permissions (GUI only)
  • Use QML DBusInterface for user service manipulation
  • Drop support for SFOS 4.2 and older
  • Clean up systemd service handling during install/update/uninstall
  • Built with Sailfish OS SDK 3.8 for 4.3.0.12

3.17.0-1

  • Disable sandboxing
  • Fix install/upgrade/uninstall scriptlets
  • Service binary consumes less resources
  • Don't try to close notifications if they are not open

3.16.2-1

  • Fix .spec bin file path (thanks, leon and nephros)
  • Built with Sailfish OS SDK 3.7 for 4.3.0.12

Full changelog in GitHub.

Comments

Historyscholar's picture

Can you update Chinese translation?I have update it.

direc85's picture

I just merged a small update yesterday, did you mean that?

I added one new string ("Current:" as in electric current) so there's not that much to update this time :)

moses_s's picture

Bug: I second the last commentor and confirm that on the Sony Xperia 10 Plus (mine is the dual-sim model i4213) there is a bug since the Sailfish 3.4 updade (I am running v3.4.0.24 Pallas-Yllastunturi). The app does not stop the charging of the phone once "Pause charging limit" setting is met. By the way, thanks a lot for a great, great app, direc85!

direc85's picture

Thanks, this should be now fixed in 3.8-1.

zipotron's picture

Hello! I just want to report a regression bug, since the last two updates, when the charge reach the 'stop charging limit', is true that charge don't rice more but seams that charging doesn't stop, and before was stopping and discharging until the low limit. I hope the report is useful for improve this amazing app.

direc85's picture

Sorry for the delay, but it should be fixed in 3.8-1. Can you test it?

PawelSpoon's picture

Works now well on xperia 10 !

direc85's picture

Great! Thanks for the update!

rob_k's picture

Yes, solved after reboot. Thanks!

rob_k's picture

Battery Buddy makes a pling sound when charging from 75% every minute, even though my settings are 89%, 5 minutes. Great app nonetheless! It's up to date, so 3.5-2 I guess.

rob_k's picture

This is still the case (or again). My XA2 has a new installation of Pallas 3.4.0.24. The Dutch weather app WelkWeer did not work after installation, and it appeared that Jolla has changed some things deep down. For instance, I do no longer have a user nemo but defaultuser instead. And the directory /run/state is no longer there.

So, I am up to date with Battery Buddy. My settings are:
- Start background service: on
- Automatic charging control: on, 89% and 65%
- Notification both off, settings at 89% and 30%, both intervals at 10:00

Still, after plugging in the power USB cable, I get a notification when battery level reaches 75%, and I get it every minute. What can be the cause of this?

direc85's picture

Hi, and thanks for reporting.

There has always been something unreliable about delivering changes from the GUI to the daemon. I have improved it a few fimes, but it's still not that reliable, it seems. The glorious state of Works For Me (TM) is not good enough - I'll see what I can do. (Well, if you lads and lasses have good ideas, please share them.)

About 3.4.0.24: It seems that I completely forgot that `nemo`isn't the default user, but `defaultuser` instead (pun not inteded actually). This requires rethinking some areas around the same config changes, and I think using DBus would be The Right Thing (TM) to do, but I'll have to learn that first.

I'm quite busy at the time, so this will take some time.I opened tickets in GitHub. I'll open a ticket regarding this in GitHub.

direc85's picture

Try stopping and starting the service using the buttons, or reboot the device.

Historyscholar's picture

Can you update Chinese translation?

direc85's picture

Updated and released in 3.5-2, as well as the French translation!

stickedlabel's picture

Looks like after last system update the service is unable to start. I installed BB after taking last system update of SFOS 3.4

direc85's picture

Thanks for commenting.

I only did rather quick testing, and didn't notice that some parts of the application doesn't work anymore. On my Xperia XA2 Ultra, charge control still works, but stopping/starting the service using the buttons don't work anymore. It looks like the services are both up and running just fine, but I need to double check that.

Edit: Oh shoot, SFOS 3.4 is now a) updated b) released to all. I really gotta bump this up!

oxygenh's picture

I have same trouble.

enrish's picture

That was a quick implementation. Thanks!!!

zipotron's picture

Hi Derec! amazing improvement the daemon, just report a bug, plus the issue that if your battery is charged more than the lower boundary of charging regime and you plug the phone because you what to charge is not going a charge... there is another issue, if you deactivate the daemon, when restart is active again, could be nice to remember the active status and boot.
 Thanks!!!!

direc85's picture

Thanks! I actually forgot to check if the service is running or not when starting the app, fixing that soon!

There really should be a setting for enabling or disabling the service at boot, good idea! Fixing that soon, too!

enrish's picture

Thanks. I see, under the hood it's quite complicated, but the solution you described would be nice, hope it will turn out.
As for the feedback here is more: just now i run again into the ' connected but not charging issue'... This time I tried to press the 'Pause' button in the app (it was not already paused as 'Resume' was greyed out) then 'Resume' again and it started charging. So no need to reboot the phone...

enrish's picture

Hi Direc, I have just noticed the daemon implementation in the last update. While it's handy and requested by many, it'd be nice to have a toggle to disable it, a bit like in Depecher.
Some people like to have as little daemons running as possible, even just for battery life.
More importantly, if something goes wrong with the app and it interferes with charging, it would be nice to be able to turn it off.

Two days ago I connected the phone to the charger and the status was 'connected' but not charging. I closed battery buddy, disconnected and reconnected, the system icon was showing the charger was connected but the battery wasn't charging. I thought the cable was broken and moved it a bit, but nothing worked until I restarted the phone. So now I guess it might have been the daemon underneath that got 'stuck' and kept charging disabled... and restarting the phone stopped the daemon.
Anyway, thanks once more for this very essential app!

direc85's picture

Thanks for the feedback!

Originally there was only a one-shot daemon to fix the file permissions issue regarding charger control, and that always ran at boot. One solution could be to bring that back, and then run the current daemon in user context. That way - I think - it would be possible to create the UI elements to stop and start the service.

I have been thinking about that one for a while, I'll create an issue about it in GitHub.

objectifnul's picture

Service restart doesn't help (J1 phone): "Could not find any zN.M subdirs!"

direc85's picture

That specific message is ambience-related, and you can fix it by creating the said dir :)

objectifnul's picture

Okay, but the link ambience-batterybuddy is beyond my understanding.

nephros's picture

Yes, service restart seems to fix the misfiring alerts.

objectifnul's picture

Works fine with my XperiaX but not with my Jolla phone:
When I execute /usr/bin/harbour-batterybuddy-daemon in fingerterm, I get a "Segmentation error".

direc85's picture

It might be that the daemon loses touch with the config file. I'll see what I can do about it.

Pages