Congrats on this PR!
I’m having trouble retrieving the charging states of my Zoe.
I want to create a scene that returns a Text value depending on the numeric value received from Node-RED.
The problem is that I can’t compare the variable (retrieved using the « Get last state » block) with a decimal value.
Indeed, here are the API values:
chargingStatus
Enum for battery-status charge state
NOT_IN_CHARGE = 0.0
WAITING_FOR_A_PLANNED_CHARGE = 0.1
CHARGE_ENDED = 0.2
WAITING_FOR_CURRENT_CHARGE = 0.3
ENERGY_FLAP_OPENED = 0.4
CHARGE_IN_PROGRESS = 1.0
# This next is more accurately "not charging" (<= ZE40) or "error" (ZE50).
CHARGE_ERROR = -1.0
UNAVAILABLE = -1.1
Thanks @mutmut,
In node-red, msg.payload is a number.
I tried in Gladys with the . and the , but in Gladys, it’s impossible to enter those characters in the comparison block.
Thanks @pierre-gilles,
I thought about that but I wanted to create a scene with multiple conditions in Gladys because I thought it was possible.
I find it a shame to have to go through node-red for anything other than retrieving values.
So I’ll handle that in node-red, too bad.