how to ........sequentially control two lights with one switch

Thread Starter

firosekhan

Joined Apr 13, 2016
15
Hi,
Recently, i brought a dual LED ceiling light. It has 2 independent lights. Center one is 6W white light and on rim it has 2W blue light. It operates from regular switch. Sequence is as follows
(White light = light A and Blue light = light B)

This is one complete Cycle

1st On -> Light A ON, Light B OFF
1st Off -> Light A OFF, Light B OFF

2nd On -> Light A OFF, Light B ON
2nd Off -> Light A OFF, Light B OFF

3rd On -> Light A ON, Light B ON
3rd Off -> Light A OFF, Light B OFF
Cycle repeats...

I want to have such controller to use with other appliances as these can be really helpful, where you have conceal wiring. Please suggest what/how to make such controller.
 

Marley

Joined Apr 4, 2016
311
Obviously it "remembers" the last state while the power is off. I expect it has a simple micro-controller inside with flash memory.
So you need a simple micro-controller and support circuits.
 

AnalogKid

Joined Aug 1, 2013
8,217
It's a great idea, but probably harder to turn into a generic device controller than you think. For one thing, it is controlling low voltage LED lights with the controller integrated into the LED power supply, not a line-powered controller switching AC power to two unknown devices such as table lamps or fans.

About that flash memory... I agree that if it always picks up where it left off in the rotation no matter how much time there is between switch action, then flash or EEPROM is needed. But if it is the case that the switch controller resets to the beginning of the cycle if it is off for a long time, then no flash and no uC are needed. I'll try to explain...

If the switching action is modified like this:
1st On -> Light A ON, Light B OFF
1st Off -> Light A OFF, Light B OFF

2nd On -> Light A OFF, Light B ON
2nd Off -> Light A OFF, Light B OFF

2 hour delay

3rd On -> > > What?

If, after a 2 hour Off delay, the 3rd cycle is as in post #1 with Light A ON, Light B ON, then non-volatile memory is needed. But if the cycle resets itself during an Off period of, say, 2 seconds, so that the 3rd On would in fact be a 1st On, then all you need is 1.9 seconds of holdup. I think this is a better way to go because you can reset the cycle back to the start with less switch action. A variation of this idea is going on in another thread.

ak
 

Thread Starter

firosekhan

Joined Apr 13, 2016
15
dl324, inspite it is designed for 12V led, it can be turned into generic usable controller by using 12V relays.

Thanks for all your replies. Since, the item is readily available in the market and in very compact form, i expect there must be some feasible solution to make this. Waiting for the right solution...............
 

Picbuster

Joined Dec 2, 2013
983
dl324, inspite it is designed for 12V led, it can be turned into generic usable controller by using 12V relays.

Thanks for all your replies. Since, the item is readily available in the market and in very compact form, i expect there must be some feasible solution to make this. Waiting for the right solution...............
Make a counter use bit 0 and bit 1 to drive the lights use fet's for led's and relays to switch mains power.
that's all. (pwr-on is all off)
 
If u are run a light switches the blank wire form the switch via the light box directly connected on the light terminal and the white wire from the supply wire.
 

GopherT

Joined Nov 23, 2012
8,012
Picbuster Can you please elaborate the details.........Thanks

Something like this.

You have 6 discrete states. You need three control bits (8 max). Therefore you need the NAND gate to reset the counter when it reaches the 7th state so you stay in the first 6.


The mosfet drives the coil of the relay so you can have Control of AC Mains powered lights or other devices.

Add a capacitor parallel with the switch for debouncing.

Use CD4000 components if you want to do automotive and run 12 v.

image.jpg
 

Picbuster

Joined Dec 2, 2013
983
See GopherT 's schematic
if you use a 74ls93 then nand gate is in the chip (pin 2 & 3)
There is some optimizing possible but this will save you one fet.
 

Thread Starter

firosekhan

Joined Apr 13, 2016
15
Hey GopherT and Picbuster, Thanks for the detailed info. Schematic looks practically feasible. Definitely will give it a try and come up with the result.
 

Thread Starter

firosekhan

Joined Apr 13, 2016
15
Now the question is how it will retain the status because every alternate click is power off. Without power how it will latch the status???
 

GopherT

Joined Nov 23, 2012
8,012
Now the question is how it will retain the status because every alternate click is power off. Without power how it will latch the status???
The bottom output of the counter (Q0) alternates on/off with each press. That means Q0 alternately turns on/off the N-channel mosfet with each press.
 

GopherT

Joined Nov 23, 2012
8,012
It cycles as follows.

From counter = 0 to counter = binary 5. (6 total states). It starts with both off and then both on, then all off, B, off, A, off then repeat. User can stop at any point.

image.jpg image.jpg image.jpg image.jpg image.jpg image.jpg image.jpg
 

dacflyer

Joined Nov 19, 2010
31
i remember years ago you could buy a module like this.. was for a light kit, and all you had to use was your ordinary house light switch..just flick it for which mode you wanted it.
i'll do some searching and see if i can find something and post it here..
it is like a 2 circuit fan light switch, but electronic in nature..
 

Jony130

Joined Feb 17, 2009
5,089
This circuit (using only HFE 4017) will also do the job
1u.png

But if I had to build such a circuit I will use a micro-controller (ATtiny13 or smaller).
 
Top