Page 1 of 1

How can I activate a door solenoid for 30 sec?

Posted: Sunday 23 June 2019 17:49
by kxtronic
Hi all,

I have Domoticz running for a couple of months already and the light in our living room turns on relative to sunset and turns off at 23:00. My system runs on a Raspberry and the light is controlled by a GPIO pin that connects to a relay that switches AC power on/off to the lamp. Very nice :-)

Now I would like to create a switch (or another object) to activate a door solenoid for 30 secs. I would use another GPIO pin with a relay that switches power to the solenoid. Ideally I would go to Domoticz using my mobile or laptop, click on a switch in the dashboard and the solenoid would activate for 30 sec and then turn off by itself.

I have been googling and reading forum posts but could not find an answer to this problem.

Any suggestions?

Thanks!

Re: How can I activate a door solenoid for 30 sec?

Posted: Sunday 23 June 2019 23:14
by kxtronic
Solved!

It is so easy that I didn't see it...

Just set the On Delay of the switch to 0 and the Off delay to 30 (or whatever).

I had wrongly assumed that the "Off delay" meant go off x seconds after the command.