-The Keypad library allows your uno to read a matrix type keypad. 4×4 numeric keypads are most widely used in project which requires user or operator to give command to system or to feed in some data.
- Keyboard for the pin interface.4X4 design, 10 numeric keys, 4 English keys,2 function keys. There is a switch connecting each row and column. So the combinations of rows and columns makes up the 16 inputs.
- Circuit board is PCB double-panel
There is a switch connecting each row and column. So the combinations of rows and columns makes up the 16 inputs. So, try to imagine this.
Initially all the switch are open (not connected). When you pressed either one buttons, the switch is now closed (connected). As you can see, now there is a connection between the row and column.
Now we know how a matrix keypad works, but how do we relate it with our microcontroller ? So we connect the first 4 pins to the column as INPUT. The other 4 pins is connected to the row as OUTPUT. The input meant that is the input to the microcontroller while output is the output from the microcontroller.
Note that the input to the microcontroller has to connect to pull high resistor, or you can use the internal pull up from Arduino itself. For a 4×4 matrix keypad, usually it has 8 pins on it.
How do we know which pins are associate to which rows and columns?
A digital multimeter (DMM) would ease your job. Turn your DMM to connectivity mode. Now put one of your meter probe to the first pin and the other one to the fifth pin. Try to press the button and see which button would gives you the “beep” sound.
Next, try to probe to the sixth pin and press other button. Keep trying and you would understand the connection behind the keypad. Finally we have reached to the software part. To use a keypad with uno, its pretty simple with the help of Keypad.h library.
Package Included :
1 X Matrix keypad 4 X 4