Wednesday, September 21, 2011
MAX6818-Based Debounced Breadboard Keypad
This is usually solved by implementing some sort of low-pass filter, to convert the multiple fast edges into a single, slightly slower edge. This can be done in software, or even just using a simple RC filter with a Schmitt trigger to clean up the slow rise time. That being said, it's always a pain for every project to have to wire up a bunch of capacitors and resistors, or copy-paste in the exact debounce software every time I want a button, so I designed this button module which can plug into a breadboard and have eight debounced buttons right away.
The MAX6818 is quite nice, in that it implements a 40ms low-pass filter on eight button inputs, has internal pull-up resistors, has an open-collector pin-change interrupt, and even tri-state outputs so you can share the buttons with other devices on an 8-bit bus. I brought everything out to a 0.1" edge connector, which when populated with male header can plug straight into a breadboard. I also added a solder jumper, such that you can hard-wire enable the outputs if you aren't interested in tri-state capabilities.
Unfortunately, I didn't bother checking component costs until after I finished the design. The Maxim debouncer chip is more than $8! Considering this can be implemented with a 50 cent 74HC14 chip, this thing really is just a waste of money, unless you're only planning on using it yourself, in which case you can sample the part from Maxim.
If you do order them from someplace like Dorkbot or ITead and end up with spares, I would be interested in buying one or two of the copies off you, just to have something to do with my MAX6818 samples.
Posted by Kenneth Finnegan at 6:00 PM