21
Development System EasydsPIC6
MikroElektronika
page
15.0. 4x4 Keypad
The
4x4
keypad is a standard alphanumeric keypad connected to the microcontroller port PORTB. The performance of this keypad is
based on the ‘scan and sense’ principle where pins RB8, RB9, RB10 and RB11 are configured as inputs connected to pull-down resistors.
Pins RB4, RB5, RB6 and RB7 are configured as outputs and generate a logic one (1) . Pressing any button will cause a logic one (1) to
be applied to input pins. Push button detection is performed from within the software. For example, by pressing button 6, a logic one (1)
will appear on the RB10 pin. In order to determine which of the push buttons is pressed, a logic one (1) is applied to each of the following
output pins RB4, RB5, RB6 and RB7.
Figure 15-3
: Keypad 4x4 and microcontroller connection schematic
Keypad 4x4 is connected to the microcontroller
via port PORTB
Figure 15-1:
Keypad 4x4
Figure 15-2:
Keypad 4x4 performance