Steve Church

9S08QG8 detecting keys using ACMP function of ADC

Discussion created by Steve Church on May 4, 2007
Latest reply on May 9, 2007 by bigmac
I'm using a resistor chain with the bottom tap into PTA0 to detect a series of 7 switches, shorting each tap point to VSS to give different analogue levels into PTA0. I want to use the automatic compare function to trigger an interrupt so I can register a key press. I have made a resistor chain  totalling about 140kohms (need to reduce standby current then in sleep mode) and am finding that the voltages produced dont come anywhere near what I expect. Has anyone used this method of key detection, and what resistor values were used? I'm assuming its something to do with the input impedance of the ADC channel affecting the resistor chain value.

Steve

Outcomes