Maker Pro
Maker Pro

First ever project, How do I make randomness???

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
Hi everyone, I have next to no experience with electronics or anything like it but I would like to do a simple (I hope) project, and would really appreciate some advice.

Basically I want to make a box with three pairs of light bulbs and an on / off switch. When the switch is turned on, I would like one bulb from each pair to be randomly activated. Here is a basic drawing of what I am looking for:


Untitled.png
Is this possible with simple materials like a circuit board and resistors and all of that? or do I need some sort of computer to create the randomness? I really don't even know where to start and would really appreciate a push in the right direction.

Thanks, John.
 

KMoffett

Jan 21, 2009
723
Joined
Jan 21, 2009
Messages
723
True randomness is difficult. It might be possible to drive each pair of lamps with with a LM555 astable oscillator. Each 555 would be operating at a different frequency. With the switch off, all three pairs would be continuously alternating between the two lamps, fast enough so that the eye's persistence's of vision (>30Hz) would not see the flashing. When the switch is turned on, all the 555s stop in their current state.

Ken
 

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
Thanks for the response Ken, what you described would work for my purposes. It doesn't have to be actual randomness, just seem like it.

I did some reading about this 555 timer and got the impression that it had one output and could turn a current on and off? Could I then use that oscillating output to operate a relay switch that sent power to one lamp when it was on, and the other when it was off?

I appreciate the help because I am just trying to use logic and Google to figure this out, haha.

Thanks again
 

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
Upon further research, it sounds like I should use a transistor instead of a relay switch due to the high frequency.

This is quite the learning process.
 

KMoffett

Jan 21, 2009
723
Joined
Jan 21, 2009
Messages
723
Are these incandescent lamps or LED's? The 555 can output up to 200mA.
The output of the 555 can pull a load high or low to turn it on. Just depends on what the lamp is connected to. In this case you connect your lamps in series. One lamp in connected to the +supply and the other is connected to common. The junction of the two lamps is connected to the 555's output. When the output goes high, the upper lamp is shorted out and the lower lamp is lit.When the output goes low, the lower lamp is shorted out and the upper lamp is lit.

Ken
 

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
I was originally planning on reusing some incandescent bulbs that I have, but I would rather buy a few small LEDs if it would make this simpler to build.

Thanks for bearing with me as I figure this out. What do you mean by one of the lamps being connected to common?

-John
 

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
Thanks Ken, I've been staring at this diagram trying to decipher it for the last hour, that should give you an idea of how familiar I am with electrical diagrams :rolleyes:

So I take it that I don't need a transistor as long as I keep the output of the 555 low enough to not fry it (200mA). I just need to figure out how to set up these three 555's to oscillate very fast and output the correct amperage to run the LEDs. Which I am reading is controlled by the resistors and capacitor that I hook up to it.

And then I need to figure out how to fit the switch in that would freeze all of the LEDs in their current state. Or would it be three switches.

I'm really wishing that I had taken electronics instead of woodshop in high school.
 

KMoffett

Jan 21, 2009
723
Joined
Jan 21, 2009
Messages
723
Just threw this together and replaced the lamps with LEDs and resistors.

555 Astable Temp2.gif

Ken
 
Last edited:

johnreb23

Mar 20, 2015
6
Joined
Mar 20, 2015
Messages
6
This is awesome!

Thanks so much Ken, I never would have been able to figure all of this out on my own.

I'll be sure to post pictures once I put this together, and I'm sure I'll have a question or two along the way. It's always fun to learn something new and I really appreciate your help.

Thanks again, John
 

KMoffett

Jan 21, 2009
723
Joined
Jan 21, 2009
Messages
723
John,

Happy to help along the way. But, now you will have to be my resource for woodworking questions. ;)

Ken
 
Top