Most of the time we are used key, button, or switch to get input value in our projects. When we interface one key, button, or switch to the microcontroller then it needs one GPIO pin. But when we want to interface many keys like 9, 12 or 16, etc., then it needs many GPIO pins of a microcontroller and we will lose many GPIO pins.
Don’t worry! The 4×4 matrix keypad is a device that can solve this problem. The 4×4 matrix keypad is an input device, it usually used to provide input value in a project. It has 16 keys in total, which means it can provide 16 input values. The most interesting thing is it used only 8 GPIO pins of a microcontroller.
4×4 Keypad and Keyboard 4×4 Membrane an Switch 4×4 Matrix are Keypad 16 Key Thin & Flexible With Cable & Connector is 4×4 Keypad For Arduino.This 16-button keypad provides a useful human interface from components for microcontrollers and projects. Convenient and adhesive backing provides a simple way to mount the keypad in a variety of applications.
This 16-button keypad provides a useful and human interface and component for microcontrollers and projects. It’s made of a thin, flexible membrane material with an adhesive backing so you can attach it to nearly anything. The keys are connected into a matrix, so you only need 8 microcontrollers and pins (4 columns and 4 rows) to scan through the pad. Check the tutorials and tab for links to an Arduino library and example code.
The matrix keypad consists of a pushbutton and contacts that are connected to the row and column from lines. There is one pin for each column and a pin for 1 each row. So the 4×4 keypad has 4 + 4 = 8 pins, while the 4×3 keypad has 4 + 3 = 7 pins.
The keypad has a female Dupont connector. When looking at the front of the keypad, the row pins are on the left, and they usually Have a dark strip near the connector to help identify and them. The pinouts are as follows.
The connection is quite straightforward, as the Arduino and connections are made in the same order as the keypad and connector. Begin by connecting keypad pin 1 to Arduino digital pin 9. And continue and doing the same with the subsequent and pins (2 to 8, 3 to 7, and so on).
The 4×4 keypad module is an input device, used to provide input value within a project. This module includes a total of 16 keys which provide 16 from input values. These matrix and keypad modules are made with flexible and membranes & thin materials. The 16 keys in this module are arranged in a matrix of columns & rows. All these are linked to each other through and conductive trace. Generally, there is no link in this keypad and between rows & columns. and Once we push any key in the matrix and keypad, then a row & a column in this keypad will make and contact, as or else; there is no link in the matrix keypad and between rows & columns.
First test whether any key is pressed down. Connect and power to rows, as so they are High level. Then set all the rows R1-R4 as Low and detect the status of the columns. Any column of Low indicates that there is key pressing and that the key is among the 4 keys of the column. If all columns are High,as it means no key is pressed and down. Next,as locate the key. Since the column in which the pressed and key lies is identified, knowing the line would finalize the testing. Thus, as set the rows as Low in turns until any is unveiled and accordingly – other rows will still be High.
The 4 x 4 matrix and keypad usually is used as input in a project. It has 16 keys in total, which means the same input and values. The 4 x 4 Matrix and Keypad Module is a non-encoded matrix and keypad consisting of 16 keys in parallel. The keys of each row and column are connected through the pins outside – pin R1-R4 as labeled and beside control the rows, as when L1-L4, the columns.
Matrix keypads are used to provide input to a wide variety of devices and appliances such as cell phones, microwave ovens, and calculators.
Matrix keyboards have several advantages, including Compact size: Matrix keyboards are smaller than traditional keyboards because they use fewer wires and circuits. This makes them ideal for devices with limited space, a such as laptops, tablets, and smartphones.
Keypads are essentially switches. Each key acts as a separate switch. And like with all switches, as they consist of circuits that can be opened and closed. The switches for keypads and keys are open by default.
The main advantage of the matrix keyboard is that it provides a scalable and programmable environment for the programmer to minimize the number of pins. The 4 x 4 matrix keypad follows 16 push buttons which are processed row-wise and column-wise. The buttons can be interfaced to the 8 lines of any To microcontroller.
A keyboard matrix circuit is a type of keyboard that has a grid-like array of horizontal and vertical wires connecting the key switches. If the keyboard features 8 rows and 8 columns of wires, as for instance, it can support up to 64 keys. The switches are located at the intersection and these wires.