Skip to content

Commit

Permalink
Control Power after suspended
Browse files Browse the repository at this point in the history
  • Loading branch information
jheredianet authored and fetzu committed Oct 20, 2023
1 parent f3aaf7c commit c7373e3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions teslamate_mqtt2abrp.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,8 @@ def updateABRP():
str_now = current_datetime.strftime("%Y-%m-%d %H:%M:%S")
msg = str_now + ": Car is " + state
if(state == "parked" or state == "online" or state == "suspended" or state=="asleep" or state=="offline"): #if parked, update every 30 cylces/seconds
#if data["power"] != 0: #Sometimes after charging it keeps the last Power and not refresh any more until new drive or charge.
# data["power"] = 0
if data["power"] != 0: #Sometimes after charging it keeps the last Power and not refresh any more until new drive or charge.
data["power"] = 0.0
if "kwh_charged" in data:
del data["kwh_charged"]
if(i%30==0 or i>30):
Expand Down

0 comments on commit c7373e3

Please sign in to comment.