Home Alarm with a 3 wire 4x3 analog keypad nearly done but need some help please

Jeremy,

Just use the center value between the max and min for each button in that sample code (sorry about the zero) and then look at the range of these values. There are 12 (effectively 13 values with the 0) so you are cutting the whole 1024 range into small sub-ranges. In the phi_interfaces library, there is a factor to decide the threshold of a match. Change that to maybe 20 so you will get more hits. The 2D array will not work with my library.

Open phi_interfaces.cpp and look for this line: if (diff<10)

Change 10 to 20. I should have defined a sensitivity=10 but didn't.