How should I operate 25 light bulbs

Page 2 - Seeking answers? Join the AnandTech community: where nearly half-a-million members share solutions and discuss the latest tech.

Atheus

Diamond Member
Jun 7, 2005
7,313
2
0
Originally posted by: SRoode
The easiest (and cheapest) way is to pick up two 5-position rotary switches. These are pretty easy to get, mostly they are used in guitars. With 5 positions on each switch, you can get 25 distinct positions total, without needing any solid state circuitry.

Something like this:
http://cgi.ebay.com/PCK-5-ALPHA-5-POSIT...8QQssPageNameZWDVWQQrdZ1QQcmdZViewItem

That's what I'd do - if I didn't need instant access and especially if money was a concern.
 

dullard

Elite Member
May 21, 2001
25,476
3,974
126
Originally posted by: Mark R
Basically, connect one switch so that the positive connects to its 'common', and connect the other so that the negative connects to its 'common'.

Then you build a grid - connect the rows to the 'positions' on one switch and the columns to the 'positions' on teh other switch.

Connect a bulb from each column to each row (5 rows, 5 columns = 25 bulbs).
img128050732770886250.jpg
Ok, I see that now. You need the bulbs between the switches:
[*]Live -> Switch -> Bulb -> Switch -> Neutral.
I was trying to do it with the bulbs after the switches:
[*]Live -> Switch -> Switch -> Bulb -> Neutral.
And of course, I couldn't figure it out. Thanks for the help.

I ended up doing something similar to what you posted above with decoders and MOSFETs. The devices are in three rows of 8, with one extra. So instead of two decoders which are 4->16, I got three decoders which are 3->8. That way, I can just dial in the row and column. I hope they work. If not, it was a $1 total investment for the decoders.

I also looked around, and those MOSFETs that you linked appear to be right near the cheapest, so I ordered those exact ones.

I have one question though. Do decoder input pins and MOSFET input pins need to be connected to ground through a large resistor? I've worked with logic gates a little in the past and they needed to be grounded to function. Thus, I assume these components will also need grounding. Is that assumption correct?
 

SRoode

Senior member
Dec 9, 2004
243
0
0
Originally posted by: Mark R
Originally posted by: dullard
SRoode: could you possibly draw a circuit diagram for that (even a crude one)? Conceptually, you have 5*5=25 combinations. But, how do you possibly wire them up so that the electricity has memory of the first switch?

Basically, connect one switch so that the positive connects to its 'common', and connect the other so that the negative connects to its 'common'.

Then you build a grid - connect the rows to the 'positions' on one switch and the columns to the 'positions' on teh other switch.

Connect a bulb from each column to each row (5 rows, 5 columns = 25 bulbs).
img128050732770886250.jpg

That's it! Thanks for the assistance Mark.

 

Mark R

Diamond Member
Oct 9, 1999
8,513
16
81
Originally posted by: dullard
I have one question though. Do decoder input pins and MOSFET input pins need to be connected to ground through a large resistor? I've worked with logic gates a little in the past and they needed to be grounded to function. Thus, I assume these components will also need grounding. Is that assumption correct?

Normally, you'd connect the each decoder input pins permanently to +5V via a 47 kOhm resistor. Then connect the switch between the input and ground.

Use a 7805 regulator chip if you don't have 5V available.

You should be able to just connect the MOSFETs directly to the output of the decoders. Connect the MOSFET source direct to 0V, connect the gate to the decoder, and connect the drain to the lamp. The other end of the lamp can be connected to +24V.

The MOSFET's gate is very static sensitive. Once hooked up, it should be adequately protected - but if you want to be sure connect a resistor between gate and source (10k - 1000kOhm is fine). Similarly, never connect the gate to the 24V supply - you may damage it.

Actually - I've just thought, the decoders might be 'active low'. If this is the case, the MOSFETs will be on by default, and off when selected. If this happens, put an inverter between the decoder and the MOSFET. 7404 chips will do the job nicely.
 

dullard

Elite Member
May 21, 2001
25,476
3,974
126
Decoders and MOSFETs came in today.

Hooked up eight of them.

Worked perfectly. :D

Thanks everyone for the help. Hopefully by Tuesday I'll have the current drivers and digital potentiometers (so I can adjust each component individually).
 

dullard

Elite Member
May 21, 2001
25,476
3,974
126
Originally posted by: mercanucaribe
Wouldn't it be easier to have 25 switches?
Not when the computer has 24 digital outputs and you have other needs for some of them.
 

Mark R

Diamond Member
Oct 9, 1999
8,513
16
81
Originally posted by: mercanucaribe
Wouldn't it be easier to have 25 switches?

Yes, but he wants to guarantee one, and only one, switched on at a time.

I suppose radio buttons would do - but I don't know if you can even get them these days.

Of course, a microcontroller/MOSFETs would be the best way - immense flexibility in type of switching/controls (e.g. rotary encoders, push buttons, etc.), it could even dim the lights with very high efficiency, and with no additional components, as well.

However, the learning curve for microcontrollers is relatively steep - so for someone without experience, it's definitely not the easiest way.