Although its sole purpose is to go Bing!, the concept of such a machine appealed to me for no particular reason. Besides, I had a few electronic parts that I needed to test so I figured that a machine that goes Bing! was just as good as any.
The requirements for my design were the following.
- The machine must go Bing! when there is someone nearby only.
- The machine must be running autonomously and use very little power. No PC or fancy image analysis algorithm must be used.
For the part that goes Bing!, I had a spare 5~12V buzzer on hand, so I figured I'd use that. But a buzzer isn't something that goes Bing! in itself; a direct current would only make the membrane go to one of its limit and produce a single 'click' sound. What I needed to use was some kind of oscillator so that the current would oscillate and make the buzzer's membrane do the same.
My first idea was to build a simple RC oscillator using an operational amplifier chip and a few resistors/capacitors. As I realized I was fresh out of capacitors (yeah, believe it or not there is such a thing as running out of capacitors) I had to change my design and transgress one of my original objectives that I had set. Without capacitors, you just can't build an oscillator. My final solution is to use an ATMEGA-328 chip (for those who care to know, it is an Arduino Duemilanove board with a 328 chip instead of a 168) and do the oscillation with a pulse-width modulated (PWM) signal. It takes much more current than it should, compared to a simple oscillating circuit, but fear not, I've ordered a bunch of capacitors. As soon as I'm re-stocked, I'll revisit the design.
Pictured above is the final assembled machine. I've even thrown in a few extra goodies, namely a SD card reader so I can record every time the machine goes Bing!, and a neat little LED.
Wiring wise, the project was absolutely trivial to assemble. Had I built myself the oscillator, there would be much to talk about in this blog post, but things being what they are, I managed to wire the whole thing using a simple prototyping board and a few wires.
I'll certainly revisit this project in a near future, as I plan to build some day a homebrewed home automation system. I've already ordered a bunch of 5VDC-120VAC relays and 315Mhz transmitters that I intend to put to good use, and intrusion detection will certainly be part of the whole.
No comments:
Post a Comment