Reputation: 735
I'm using a Shelly1 V3 with Tasmota 14.2.0 and want to switch the relay with a PIR sensor (AM312). After reading PIR Motion Sensors basically this works so far, but instead sending MQTT messages I would like to control the relay without an external home automation system to have the Shelly working independent on its own.
So I adapted the documented rule
Rule1 on Switch1#state=1 do Backlog Publish stat/%topic%/PIR1 ON; RuleTimer1 30 endon on Rules#Timer=1 do Publish stat/%topic%/PIR1 OFF endon
to this:
Rule1 on Switch1#state=1 do Backlog power ON; RuleTimer1 30 endon on Rules#Timer=1 do power OFF endon
But I am not able to let the relay switch off with the specified time. Instead, depending on the switchmode, the relay switches off after about 3 seconds or after about 20 seconds, not 30 (or any defined) seconds.
I tested Switchmode to 14 with Pulsetime of 130
as described as also all switchmodes and checked the console log to see how many seconds it took to switch off after a recognized movement:
I guess it should be possible to control the relay to switch off after a movement after a specified time, not the actual 3/20 seconds depending on the switchmode?
How could I achive this?
Using switchmode 14 and sending MQTT messages so the external home automation system switches on/off works but as said, I would like to do this independently without an external home automation system.
Upvotes: 0
Views: 53