Feature Request - Phone Battery Level + other metrics

Low priority, but actually useful.. Just had a thought, phones last longer if you only charge to 80% battery..

Would be awesome if the phone reported battery level as a metric, this was you can then automate your battery charging.. I expect you can already do this on Android via Tasker, although building in to the app would skip a step..

.. Reporting on other metrics such as wi-fi network, incoming calls would also be an advantage, probably many others.. any other suggestions welcome

1 Like

I second this strongly!

For iOS anyway, they’re pretty restrictive. For example, I’m pretty sure an app has no knowledge of when calls are received. Like the ideas though... I just know Apple locks things down a lot.

Technically calls can be accessed as call blockers already do this, so at the very least there is notification of call, the calling number and control of the call. Whether apple will approve an app to access this information is another matter though I expect.. I guess that’s why we don’t have tasker on iOS

They won’t. It’s in their terms that you can only use that feature if your app is a call blocker.

1 Like

You can do some of this with the shortcut app and web calls.

1 Like

Ohhh, so you can! Will need to work out how to do it!

And one of the reasons I won't buy an iPhone. :grin:

There was an app on their App Store called Tasker that even used a VERY similar logo but it was a ToDo List app. Very deceptive!


I'd also like to see phone battery level implemented to do the same thing and charge a phone to 80%.
I had hoped to be able to do it with an app on the phone and get the phone itself to stop charging, but that's not possible, but using a smart outlet and knowing the phone battery level would be very easy to implement this.

Next I'll want the same for my laptop, but on a laptop it'll be very easy to have a python script looking at the battery state and call the Maker API, on a phone not so easy

If you have an a Android phone and pay the$4 for Tasker app, this is easily done.

1 Like

I bought tasked many years ago but stopped using it.
So with Tasker I'd get a "trigger" for when I'm at 80% and then do an API call?

Yessir! You can send the request to a Rule Machine endpoint or Maker API. Create a virtual Omni Sensor for your phone and you can store battery in it thru Maker API.

EDIT: The Driver Code for the Omni Sensor is available to modify so you can add battery capability and delete any capabilities that you don't need and save as new driver type.

1 Like

I've done exactly this only about a week ago, been meaning to post the setup. Will post it later today if it of any help. I simply turn a switch on and off when between 0 - 25% or 26 - 100%, but I want to eventually send the battery level value to a sensor. I'd read someone used a temperature sensor to store this as there is no battery level driver, but will look at the Omni sensor.

That might have been me :grin:

I did that before the Omni sensor code was made available.

1 Like

The Variable field in Omni Sensor let's you save text strings so you can save almost anything. I swapped messages on some thread where person was storing the current status of their robot vacuum whether charging, vacuuming, etc.

1 Like

for anyone looking at this it was very easy to get tasker set up for turning off my smart socket

I have 2 profiles

  • battery level between 85 and 100 which calls the charger off task
  • battery level between 0 and 75 (leaving a bit of hysteresis so that at 85 percent I don't keep turning the socket back on when it gets to 84 and then on and off again) this calls the charger on task

the tasks are very simple in that they just do a Http request and I put the url I got from the maker API

And obviously I added the socket to Maker API so I could control it.

1 Like