User Manual
Lesson 11 Membrane Switch Module
Overview
In this project, we will go over how to integrate a keyboard with an MEGA2560 R3
board so that the MEGA2560 R3 can read the keys being pressed by a user.
Keypads are used in all types of devices, including cell phones, fax machines,
microwaves, ovens, door locks, etc. They're practically everywhere. Tons of
electronic devices use them for user input.
So knowing how to connect a keypad to a microcontroller such as an MEGA2560 R3
board is very valuable for building many different types of commercial products.
At the end when all is connected properly and programmed, when a key is pressed,
it shows up at the Serial Monitor on your computer. Whenever you press a key, it
shows up on the Serial Monitor. For simplicity purposes, we start at simply showing
the key pressed on the computer.
For this project, the type of keypad we will use is a matrix keypad. This is a keypad
that follows an encoding scheme that allows it to have much less output pins than
there are keys. For example, the matrix keypad we are using has 16 keys (0-9, A-D,
*, #), yet only 8 output pins. With a linear keypad, there would have to be 17 output
pins (one for each key and a ground pin) in order to work. The matrix encoding
scheme allows for less output pins and thus much less connections that have to
make for the keypad to work. In this way, they are more efficient than linear
keypads, being that they have less wiring.
Component Required:
(1) x Elegoo Mega2560 R3
(1) x Membrane switch module
(8) x M-M wires (Male to Male jumper wires)
85 / 223










