I have a RF motion sensor that sends the code “13679510” when motion is detected.
How can I set a binary sensor template to be ON every time the sensor sends the code and go off if after 10 seconds I do not receive that code?
I tried this, but it’s always on:
hello there @PetrolHead, actually it wouldn’t work I guess.
That’s because the RF receiver keeps receiving random number/codes on the 433 Mhz frequency.
Only when I receive that code it means that some motion has been detected, so the binary sensor goes “ON”.
If i remove the delay off, after 1 second or 2 I will receive some different other code that will trigger the binary sensor “OFF”, but I don’t want it to go off for at least 10 seconds. If in those 10 seconds I receive the “Motion Detected” code again, the binary code remains “ON” for other 10 seconds.
I’ll try to change the != with == just for test purpouse anyway
At the moment I am using a timer but the binary sensor template used in that way would be perfect if you have many RF Motion Sensor in the house, so you have not to use a timer for every single one