I’ve got the new IKEA motion sensor E1745.
With this motion sensor there isn’t a physical switch anymore to change the timeout in which the state of occupancy goes to false.
It’s now default to 3 minutes.
So I’m trying to edit this with Home Assistant.
The topic payload of the ikea motion sensor is:
zigbee2mqtt:info 7/29/2019, 9:56:30 PM MQTT publish: topic 'zigbee2mqtt/xxxxxx', payload '{"occupancy":true,"linkquality":39,"battery":87}'
In Node-red I’ve created a test flow with node-dashboard.
The function contains the following:
varEntity = msg.data.entity_id;
msg.payload = { "entity_id":varEntity }
msg.payload.data = {"occupancy": false}
return msg;
I can see in my debug from the function, that the output is correct:
msg.payload : Object
object
entity_id: "xxxxxx"
data: object
occupancy: false
But the output of the “get current state” sensor is still:
msg.payload : string[2]
"on"
Could it be that it’s simply not possible to force change the occupancy state?