1) Give a description of the problem
So I’m very very new to webcore so I apologize in advance if this question is silly, and I’m sure there are way simpler ways to write this piston. I made a piston that works with a motion sensor, a contact sensor, and a virtual switch. After the motion sensor activates and then stays off and turns the lights off, it doesn’t turn back on again when motion is detected.
2) What is the expected behaviour?
When I walk into the bathroom, the motion sensor should detect my motion and turn the lights on (Whether a virtual switch is active or not determines the brightness). Then, when the motion sensor stays inactive for a certain time, the lights should turn off. Then, whenever motion is detected again, it should immediately turn the lights on again.
3) What is happening/not happening?
The issue lies when the motion sensor stays inactive and turns the lights off. For about fifteen seconds or so after the motion sensor turns the lights off, it won’t recognize any additional motion to turn the lights off. However, there is a contact sensor that turns the lights on automatically if it’s closed and turns them off if it’s open, and that works completely fine.
So with that piston, switch 5 is a virtual switch that I use to determine whether or not I’m sleeping or not. That way, if I get up in the middle of the night and walk in, the lights won’t go on full blast, but rather at one percent. The contact sensor is on the door, so when it’s closed (in a situation where I’m showering, etc.), then the lights will remain on indefinitely.
Any advice will really be appreciated. This is literally my third day using webcore, and I’m very new to all of this. I figured this would be the best place to start.
Stay safe everyone!