Hi! I’m trying to make my motion sensor (Hue) and vibration (Xiaomi/Aqara) sensor to work together to count how many times my cat has visited the litterbox.
Been using only the vibration sensor which works fine together with custom:mini-graph-card in lovelace. But, right now it counts when I empty the litterbox as a visit. So I’ve placed a Hue Motion sensor on the wall. Which works perfect in an automation, now it only tells me to empty the litterbox when the cat has visited instead of doing it all the time the litterbox is touched.
This is the code I’m using to display when the litterbox has been visited by my cat. What should I add to the code below to only count when “binary_sensor.hue_motion_sensor_3_motion” hasn’t felt any motion?
Wow, that was all I needed. Thank you metbril, I really appreciate it.
For anyone interested in doing the same thing as me, I’ve included my code for the card. There might be some unnecessary code since I’m not that good. But at least it works