how to have a 14m2 read from a 12 button hex keypad

tesladude

New Member
So I am making a combination garage door opener and the program was perfect, but I had it set up to use a 12 button keypad with 13pins (a common)
so clicking a button would make a 14m2 button high, nice and simple! But I can not find a 13pin keypad ANYWHERE at least nowhere where I don't have to pay 3x more than it costs in shipping. But I have found the 7pin hex keypads like this

https://www.sparkfun.com/products/8653

But how can I get the 14m2 to read connections between pins like this?
 

lbenson

Senior Member
I'm not sure what you mean by "hex" keypad in this instance, since hex would be 16 keys, not 12.

The device you refer to shows 9 pads, but only 7 of them are connected, so it's a standard 12-key keypad. The datasheet document on the Sparkfun page looks pretty good. Keypads have often been covered. Here is one recent thread on using a single input line with ADC to read the key presses: http://www.picaxeforum.co.uk/showthread.php?24850-Converting-a-digital-keypad-to-an-ADC-keypad

If you're ambitious, note especially AllyCat's post 37, which provides resistor values for getting even steps on the ADC, which allows a simple mathematical computation on the ADC read to give you the key which was pressed.

You can search on "keypad" to find other instances of use with the picaxe.
 

westaust55

Moderator
We do not know how many IO you have for the keypad but as you were looking for a 13 pin type initially I assume you have at least 7 IO available. In this cas you can use a scanning method with a 4 x 3 matrix keypad as per this REV ED Datasheet for a keypad lock kit.
http://www.picaxe.com/docs/chi008.pdf
 

geoff07

Senior Member
Or you can use some resistors to make a potential divider, with an adc input to determine the row by powering the columns in turn and reading the output voltage, different for each row, which could save some pins.
 

ValueAdd

Senior Member
Or you can use some resistors to make a potential divider, with an adc input to determine the row by powering the columns in turn and reading the output voltage, different for each row, which could save some pins.
That is what lbenson suggested at post 2 with a link to allycat's info.
 
Top