Using relay with room light

I would like to control the light bulb in my room with a relay. The light bulb is mounted into a lamp holder and is on the ceiling of my room. I am pretty familiar with how to use a relay, but my question is how difficult would it be to connect the light bulb and it's power supply to the relay?
The light bulb setup looks something like this:

Any help would be great. :slight_smile:

Hi,
Where does the light plug in now?
What switches it on and off?

The light is still plugged into a fixture on the ceiling and is switched on/off with a standard light switch.

It is powered with the house's electricity.

Realistically, there are several engineering & construction challenges and pre-made home automation solution like [u]this[/u] with a compatible [u]timer/controller[/u] is the best solution.

These switches have momentary manual on-off (or dimming) switches so they can work manually or remotely. So for example, you can turn it off automatically or remotely and then walk into the room and turn it on like a normal light switch.

But if you want to do it yourself -

The best place to put the relay is in the wall box where the switch is.

You will need constant power to your relay and circuitry. There are a couple of different ways to wire a switch. Sometimes there are just 2 wires for the switch (plus a ground), but no constant power. If that's the case, you'll have to get power somewhere else or you may have put the relay and control circuit in the ceiling and you'll have to leave the wall-switch on all the time or bypass it.

If you've got constant power and neutral into the switch box you can put everything in the switch box (if you can fit it in there.)

Thanks, I like the idea of using a switch like that, and I think I will use one of those :slight_smile:

What the plan is, is to switch the light on/off depending on if someone is in the room using a PIR sensor with Arduino. So, would it be possible to use the receiving end of the switch, since it can be remotely controlled, and use the Arduino to send a signal to this switch?

They make wall switches with motion detectors built in. A ripoff in terms of price for what you get, but then again they're all fancy with their UL certifications and whatnot lol.

Control the light at the switch. I use a 16A dual coil latching relay because it draws no power to hold either position once switched. I modified a plain Decora switch with a spring from a ball point pen to make it a momentary style switch, and used the contacts to work as a button on the microcontroller instead of controlling the mains directly (those run through the relay now).

Ok, thanks for the idea

But is it still achievable to do it this way:

So, would it be possible to use the receiving end of the switch, since it can be remotely controlled, and use the Arduino to send a signal to this switch?

What do you mean by 'receiving end of the switch'? What can be remotely controlled?

INTP:
What do you mean by 'receiving end of the switch'? What can be remotely controlled?

This should answer your questions:

DVDdoug:
Realistically, there are several engineering & construction challenges and pre-made home automation solution like [u]this[/u] with a compatible [u]timer/controller[/u] is the best solution.

These switches have momentary manual on-off (or dimming) switches so they can work manually or remotely. So for example, you can turn it off automatically or remotely and then walk into the room and turn it on like a normal light switch.

It doesn't. It's like you're asking if a commercial product will work. Yes, it will.
Still have no idea what "receiving end of the switch" means. Those were your words.

What I mean by that, is because this switch can be controlled remotely with some kind of remote, I was thinking if I could use the switch's remote capability with Arduino.