Monday, May 11, 2009

Gameshow Style 'Buzzer'

Are You Ready To Play!!!!!

Although it doesn't actually buzz, I'm still calling it a buzzer. This project was commissioned by my mom. She runs a youth group back home, and they play a game like 'Jeopardy' and needed a way to definitively tell who buzzed in first. This project was proposed about a year and a half ago, and at the time the only micro controllers I had around were some PIC 18f452, and they run ~$8 each. Also they are overkill for something this simple. So I had a choice to use a uC or to try to use analog IC's. I chose to build an analog circuit, but if I had to do it again, I'd probably use a simple, cheap PIC just to avoid the hassle of wiring up this circuit by hand. Although, with a printed circuit board, the analog solution would have been great.



The circuit is fairly simple. The heart is a 555 timer set to oscillate. The frequency can be set by setting R10, R11 and C1 (the frequency isn't critical, so I think I put it in the few KHz range). The timer clocks a few D-type flip flops, allowing their values to update. At the input of the flip-flop are the switches, for this project I used some arcade buttons I had lying around because they are big and durable. The switch triggers the flip flop (Q'), which lights up the LEDs at the switch and at the controller indicating what button was hit. The other flip-flop output (Q) triggers some OR gates, which disables the 555 timer, stopping the flip-flop clock and preventing any other buttons from lighting an LED. A master reset button on the controller clears the flip-flops, in turn clearing the LEDs and restarting the oscillator. By using a toggle switch here, the flip-flops can be kept in a reset state, disabling all of the buttons. This allows the person in control to keep people from chiming in early, say if you want them to wait for a question to finish being asked.



There is a slight chance that two people (or more) hit the button at exactly the same time, in which case both (or more) of the flip-flops will be triggered before the clock is disabled. At 10KHz, the best case scenario is that the buttons have to be pressed within 1 clock period (100 us) of each other for this to happen. Accounting for flip-flop and gate delays would probably add a few 10's of ns to this number. In practice this hasn't been an issue. But if it is, increasing the clock frequency should reduce the probability of simultaneous triggering.

An added bonus of the analog solution, is the relaxation of conditioned voltage. I'm running this circuit of 4 AA batteries, which is 5~6V. depending on how fresh the batteries are. With 6V and a uC, this would need to be regulated down to 5V or below to protect the uC. With the analog solution, the chips are typically rated +/- ~15V or more, so regulating the power supply is not needed, provided it's a DC source within the range. The 555 timer is insensitive to supply voltage, so the frequency is stable as battery life decreases.

No comments: