keypad
Posted: Mon Mar 19, 2007 2:02 pm
Im trying a simple setup to make my keypad work.
I've got the following datasheet for my keypad:
http://www.farnell.com/datasheets/73830.pdf
And with my 16f88 PIC I've created the following (europe symbols as far as i know
). I've got my output LED's on port A and my input from my keypad on port B.
![Image](http://www.lassestaal.dk/keypad.JPG)
My programming sounds like:
While 1
{
Keypad0.GetkeypadNumber --> number (result stored in number)
output "number" --> PORT A
}
Where my Keypad0 is set to PORT B with the following:
Collum 1: Bit 0
Collum 2: Bit 1
Collum 3: Bit 2
Row 1: Bit 4
Row 2: Bit 5
Row 3: Bit 6
Row 4: Bit 7
As far as i know im doing everything correct, but I have the problem that no key returns the correct value and keys "1,2,6,9,*,0" isnt doing anything. I've tried to replace the PIC and the keypad none of that worked, and i've tried to switch the pins arround to see what that did, it changed the output from the working keys but the rest still wont work.
Im quite lost here
Any know what i should do to make this work?
I've got the following datasheet for my keypad:
http://www.farnell.com/datasheets/73830.pdf
And with my 16f88 PIC I've created the following (europe symbols as far as i know
![Smile :)](./images/smilies/icon_smile.gif)
My programming sounds like:
While 1
{
Keypad0.GetkeypadNumber --> number (result stored in number)
output "number" --> PORT A
}
Where my Keypad0 is set to PORT B with the following:
Collum 1: Bit 0
Collum 2: Bit 1
Collum 3: Bit 2
Row 1: Bit 4
Row 2: Bit 5
Row 3: Bit 6
Row 4: Bit 7
As far as i know im doing everything correct, but I have the problem that no key returns the correct value and keys "1,2,6,9,*,0" isnt doing anything. I've tried to replace the PIC and the keypad none of that worked, and i've tried to switch the pins arround to see what that did, it changed the output from the working keys but the rest still wont work.
Im quite lost here
Any know what i should do to make this work?