Go Down

Topic: Turn on the lights when gate opens - magnetic contact switch (Read 2136 times) previous topic - next topic

d82k

Dear all,
I would like to make my garden light to turn on when the gate opens. I used to have a pir motion sensor attached to my lighting system but unfortunately it is not always working.
For this reason I was thinking to take the pir away and use a small arduino with a magnetic contact switch (together with a light sensor) that drives a relay. When the switch is open and the sunlight is low the lights turned on for a couple of minute.
What do you think? Do you have better ideas?

I would do that using a arduino uno, but since it is a very simple thing, can I use a simple ATTiny85 also to do that?
thank you,
dk

johnwasser


I would do that using a arduino uno, but since it is a very simple thing, can I use a simple ATTiny85 also to do that?


The ATtiny85 could certainly do it but because that's not a standard Arduino it complicates the process quite a bit.  You should use a real Arduino if you want to keep it "a very simple thing".  If you are short on physical space you can use a small Arduino like the Arduino Nano.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

JohnHoward

I think I'd just mount a mechanical switch that closes it's contacts when the gate opens.  Some things don't require software.

marque


I think I'd just mount a mechanical switch that closes it's contacts when the gate opens.  Some things don't require software.


--When the switch is open and the sunlight is low the lights turned on for a couple of minute.--

Simple answers are not always simple solutions.

I think the type of switch depends on the situation and construction of the gate. Do you want the lights of from the moment you open the gate or when you close it?


Go Up