4x4 Keypad OBEX question
ti85
Posts: 44
in Propeller 1
I have a question about Beau's 4x4 keypad reader obex. Looking through his code he talks about using a pin's capacitive to read the keypad. He does this by changing the states of all pins. First setting them to low output, then setting them to input. Then one pin at a time is made high output at a time. I'm not sure that I follow all those state changes.
My understanding is that you would set 4 pins as inputs. Use a pull up or pull down setup (I'm going to probably use a pull down setup) on those pins. Then you would set 4 pins as outputs. Then to read to keypad you would set the output pins high one at a time, at the same time reading the input pins. Is that correct and will my setup work with leads that are over 1 to 2 feet long? Is Beau's setup only to avoid using the extra pull up/down resistors?
My understanding is that you would set 4 pins as inputs. Use a pull up or pull down setup (I'm going to probably use a pull down setup) on those pins. Then you would set 4 pins as outputs. Then to read to keypad you would set the output pins high one at a time, at the same time reading the input pins. Is that correct and will my setup work with leads that are over 1 to 2 feet long? Is Beau's setup only to avoid using the extra pull up/down resistors?
Comments
Tom, I think I will try your driver. It only requires the pull down resistors? How reliable are the pin reads and do you think two feets leads will be okay?
Beau, thank you for the explanation. That makes perfect sense