Inspiration

I was constantly running into the same problem - my phone battery would drop to 1% by the end of the day. I didn’t want to charge it overnight, since that’s not great for battery health, but I also couldn’t risk waking up with a dead phone. Over time, the batteries on several of my phones died, and I had to stop using them altogether. This inspired me to build something that could help solve this problem.

What it does

Battery Saver is an Android app that monitors your phone’s battery level in the background and notifies you when it’s the right time to plug your phone in. You can set a target time (like before you go to sleep), and the app reminds you in advance so your phone can reach full charge safely, without having to stay plugged in overnight.

How I built it

The app was built using Flutter and Dart. It uses the workmanager plugin to schedule periodic background tasks that take battery snapshots every 15 minutes. These snapshots are stored using shared_preferences, and flutter_local_notifications is used to send timely charging reminders. The app also includes a simple visualization of recent battery levels.

What we learned

I learned how to work with Dart isolates, background execution on Android, and the quirks of battery monitoring.

Built With

Share this project:

Updates