Motion sensor and too high lux after light goes from on to off

Hi!

I’ve made a simple automation where the light goes on as soon as it is dark and it will also extend as long as there is motion. My problem is, however, that if I got right into the motion sensor once the light switches off, it often has still the high lux value from the time the light was still on. This results in the light not being switched on.

I never had this problem when I used the motion and lux sensing directly using the Philips Hue app. Is there a simple way to fix this?

I’ve watched the lux sensor of the hue motion sensor during the whole process:

As soon as the light goes on, the lux goes up to about 100
when no motion is detected, the light goes off and the lux stays at 100
it will then take a few minutes till it goes down to 1 lux again (during nighttime) if there is no motion detected.
If, however, motion is detected no light goes on as it still sees the old 100lux but then updates immediately the lux to 1.

So the problem is that after the light goes off, that the lux are no updates to the new state. the only update happens if there is new motion detected or after a few minutes.

Is there any way to force a lux update, after the light goes off?

Maybe there is something wrong in my node red flow:0db59b148edd0ea364a44e643fc72d35370b8420_2_690x168

As none of the nodes you are using are loaded in Node-RED by default it would be useful if you specified which nodes you are using (these generally start node-red-contrib- )

I'm sorry, I forgot to mention that I'm using it with Home Assistant. The nodes are from "node-red-contrib-home-assistant-websocket".

so Homeassistant is being too slow posting the values?
I’d probably start by posting the question on their forum

no, it is no home assistants fault. the problem is that the lux value stays high after the light went off for several minutes. only if there is motion again, there is an update for the lux value again.

I think I have to find a workaround for this like saving the lux value when the light first goes off and use again this value if there is motion again with a timeout after a few minutes. (this is the time that the hue sensor will post a new lux value on its own).

I just don't know if this is the correct way to do this or if this is too complicated and maybe there is a better way.