Stop/start charging based on battery level when home

I actually use the exact same setup for a long time - just never thought about pushing it to HA in addition to only send some local notification messages. Usually HA has some delay of sometimes few minutes so I didn’t have an actual need for this shortcut adaption. But it doesn’t harm so thx :slight_smile:

this is almost instantaneous for me
 maybe you have some delay due to other issues?
Whis a second automation rule i can keep it charged between 80-100% if i’m away for long time.

Anyway no battery drain and no need to check notifications on my phone.
Home that helps :slight_smile:

how in the hole of holy mother jezus can i make this work for my laptop battery? i got home assistant installed somehow, got my tapo switch to finaly show up in home assistant devices list but can’t get home assistant to actually do the command I set. I have bluestacks running as well with home assistant mobile app so that is how i figured i would trick it to think my laptop is the phone but no dice. nothing happens at any battery level. would really appreciate some help

can you see the laptop battery changing during use (discharging)?

not in bluestacks no. im not sure in home assistant wherei could see that if you meant it in that invironment

you should install home assistant companion app on your laptop
 not bluestack

how do i do that without bluestacks? the home assistant companion app
is an
app. runs on android or ios. my laptop runs windows 8. i don’t get it. [not trying to be a wiseass]

Oh windows
 I don’t think they released a windows companion app. So no battery or other sensors are generated.

Read more here WTH is there no Home Assistant app for Windows - #8 by nickrout

Try https://iotlink.gitlab.io/

EDIT: I just tried that and it works a treat!

Very cool project!

Right, got everything installed from IoT Link to MQTT and Tapo smart plug integrated with HACS. I can see the discharge level of the battery. But when i run this automation it still only works SOMETIMES after which it just won’t anymore. I don’t know what I’m doing wrong. I have it set to start charge at 64% and stop at 85%
but then sometimes it starts at 64% but doesn’t stop at 85%.

running win 8.1 if that matters, not win 10

the blueprint of @vorion (:battery: Turn off phone charging after the phone is charged helped sort out the problem where the turning off switch wasn’t working at the set battery level; basically I am running both blueprints now :laughing: i use raazvan’s blueprint which works for starting up the switch at certain battery discharge level and then voiron’s will shut it down at certain charged level.

Worked for a couple days but now MQTT broker can not read battery level anymore, just reads ‘unknown’. I don’t understand, nothing has been changed yet it no longer works even though it did earlier. Configuration file, login, IP address all the same as before.

Hello, for my part it does not work. At least not completely, I don’t know what prevents the command from working properly, but when my smartphone discharges at the given percentage, my plug turns on well, but when it charges and reaches the given percentage or exceeds it, my plug does not turn off
 Does anyone have an idea?

Hello

Doesn’t work at all

Shame !

Bonjour Ă  tous
j’ai mis en place l’activation du chargement de ma tablette murale et l’arrĂȘt automatique via le blueprint ci dessous mon alimentation est gĂ©rĂ© par un boitier sonoff


voila les détails de ma configuration blueprint
voilĂ  celle de la carte
et volĂ  l’historique du chargement et arrĂȘt de la tablette
j’espùre que cela pourra aider certains d’entres vous.

English please.

hello
I do not speak English.
Google is your friend
do as I use it.
translated by google translate

The rules are English only. I don’t make the rules.

Hello Nicku,
ok I understand my Chrome is in automatic translation that’s why I didn’t pay attention.