A system for determining which key of a key-pad device is activated by an
algorithm that employs the same number of steps to make the determination
regardless of which key is pressed. In one embodiment, the algorithm
first determines if more than one key is pressed in more than one column.
The algorithm then determines which key has been pressed by adding key
values associated with each key on a row-by-row basis. Once the algorithm
calculates the added value, it then determines whether the added key
value exceeds a predetermined value to determine if more than one key has
been pressed in the rows. If the added value does not exceed the
predetermine value, then the added value is subtracted from another
predetermined value to give the key value that is transferred from the
device.