SlideShare a Scribd company logo
3
Most read
4
Most read
www.researchdesignlab.com Page 1
LCD Keypad Shield
LCD KEYPAD SHIELD
www.researchdesignlab.com Page 2
LCD Keypad Shield
Table of Contents
LCD KEYPAD SHIELD ................................................................................................................ 1
OVERVIEW ................................................................................................................................... 3
INTRODUCTION ...................................................................................................................... 3
FEATURES ................................................................................................................................ 3
APPLICATIONS........................................................................................................................ 4
CIRCUIT DIAGRAM ................................................................................................................ 4
ARDUINO CODE ...................................................................................................................... 5
OUTPUT..................................................................................................................................... 8
RELATED PRODUCTS ............................................................................................................ 9
www.researchdesignlab.com Page 3
LCD Keypad Shield
OVERVIEW
INTRODUCTION
One of the basic interfacing requirements for the hobbyists or electronics enthusiasts is I/P
(keypad) and O/P (LCD display) for prototype applications. This shield uses minimum number
I/O’s that is 4 bits for LCD data and 2 control signal lines for the same. A single analog pin (Pin
A0) is multiplexed to read 5 input key switches (Navigation keys). Each key has been pulled up
to a different voltage level, so a different voltage will be generated every time a user selects a
key. This voltage could be read by the analog pin A0 on the board. Hence saves the no of I/O
pins. The backlight of the LCD could be controlled by setting PWM (Pin D10) by adding a few
lines of code.
FEATURES
 16X2 Blue color back light LCD.
 A single Analog pin is multiplexed to read 5 input Keys.
 Optional PWM based Back light control.
 Stackable on UNO shield
 High quality PCB FR4 Grade with FPT Certified.
www.researchdesignlab.com Page 4
LCD Keypad Shield
APPLICATIONS
 Calculators
 Cameras
 Cash Registers
 Clock Radios
 Digital Meters
 Hand-held TV & Terminals
 Hand-held Data Collection
 Heart Monitoring Devices
CIRCUIT DIAGRAM
www.researchdesignlab.com Page 5
LCD Keypad Shield
ARDUINO CODE
/*
* Project name:
LCD KEYPAD Shield
* Copyright
(c) Researchdesignlab.com
* Description:
* Test configuration:
MCU: ATMEGA328
Dev.Board: Arduino uno
Oscillator: 16 MHz
Software: Arduino
*/
/*
The circuit:
* LCD RS pin to digital pin 12
* LCD Enable pin to digital pin 11
* LCD D4 pin to digital pin 5
* LCD D5 pin to digital pin 4
* LCD D6 pin to digital pin 3
* LCD D7 pin to digital pin 2
* LCD R/W pin to ground
* 10K resistor:
* ends to +5V and ground
* wiper to LCD VO pin (pin 3)
*/
// include the library code:
#include <LiquidCrystal.h>
int sensorValue = 0; // value read from the keypad
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(12, 11, 5, 4, 3, 2);
int sensorPin = A0;
void setup() {
// set up the LCD's number of columns and rows:
lcd.begin(16, 2);
www.researchdesignlab.com Page 6
LCD Keypad Shield
delay(2000);
}
void loop() {
lcd.clear(); // clear lcd display
lcd.setCursor(0, 0); // set the cursor to column 0, line 0
lcd.print("LCD KEYPAD Shield");
lcd.setCursor(0, 1); // set the cursor to column 0, line 1
// read the input on analog pin 0 of keypad :
sensorValue = analogRead(sensorPin);
// check if the keypad is pressed disply keypad on lcd using sensorValue .
if(sensorValue<=10)
lcd.print("RIGHT KEY");
else if((sensorValue<=492)&&(sensorValue>=482))
lcd.print("DOWN KEY");
else if((sensorValue<=325)&&(sensorValue>=315))
lcd.print("UP KEY");
else if((sensorValue<=595)&&(sensorValue>=585))
lcd.print("LEFT KEY");
else if((sensorValue<=765)&&(sensorValue>=755))
lcd.print("SELECT KEY");
else
lcd.print("NO KEY PRESSED");
delay(500);
}
SERIAL COMMUNICATION
const int analogInPin = A0; // Analog input pin that the potentiometer is
attached to
int sensorValue = 0; // value read from the pot
void setup() {
// initialize serial communications at 9600 bps:
Serial.begin(9600);
www.researchdesignlab.com Page 7
LCD Keypad Shield
delay(1000);
}
void loop() {
// read the analog in value:
sensorValue = analogRead(analogInPin);
// check if the keypad is pressed disply keypad on lcd using sensorValue .
if(sensorValue<=10)
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("RIGHT KEY");
}else if((sensorValue<=492)&&(sensorValue>=482))
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("DOWN KEY");
}
else if((sensorValue<=325)&&(sensorValue>=315))
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("UP KEY");
}
else if((sensorValue<=595)&&(sensorValue>=585))
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("LEFT KEY");
}else if((sensorValue<=765)&&(sensorValue>=755))
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("SELECT KEY");
}
else
www.researchdesignlab.com Page 8
LCD Keypad Shield
{
Serial.write(byte(0X01));
Serial.write(byte(0X80));
Serial.println("NO KEY PRESSED");
}
delay(1000);
}
OUTPUT
www.researchdesignlab.com Page 9
LCD Keypad Shield
RELATED PRODUCTS
RDL- UNO ATMEGA328 Development Board 4x4 Matrix Keypad
LCD Interfacing Module Graphical LCD

More Related Content

PDF
KDU Zebra - Manual do Dispositivo
UseZ
 
PDF
Openocd
Davide Platania
 
PDF
Dell SC4020 and SC9000 All Flash Solutions For MEDITECH Magic, CS 5.x and MT 6.x
Richard Fletcher
 
PDF
Dell Vostro 3568
LAPTOP TRẦN PHÁT
 
PDF
802801 gbm
David Reyes
 
PDF
13mkz
rukford1
 
PDF
13fusion1
rukford1
 
PDF
Dell Vostro 5480: Laptop văn phòng mỏng nhẹ
LAPTOP TRẦN PHÁT
 
KDU Zebra - Manual do Dispositivo
UseZ
 
Dell SC4020 and SC9000 All Flash Solutions For MEDITECH Magic, CS 5.x and MT 6.x
Richard Fletcher
 
Dell Vostro 3568
LAPTOP TRẦN PHÁT
 
802801 gbm
David Reyes
 
13mkz
rukford1
 
13fusion1
rukford1
 
Dell Vostro 5480: Laptop văn phòng mỏng nhẹ
LAPTOP TRẦN PHÁT
 

What's hot (12)

PDF
Zd12xx release notes_9.9
forum4user
 
PDF
Learn LCD Arduino-v1
handson28
 
PDF
PN985-MG3500-SDK-Guide
Sholeh Gregory
 
PDF
Dell Vostro 5459 - Laptops Trần Phát
LAPTOP TRẦN PHÁT
 
PDF
13fusionhybrid
rukford1
 
PDF
13mkzhybrid
rukford1
 
PDF
Dell Vostro 3671 datasheet
Mr Cuong
 
PDF
Dell Vostro 5581 Laptop giá rẻ chất lượng của Dell
LAPTOP TRẦN PHÁT
 
PDF
Dell vostro 5568 Laptops Trần Phát
LAPTOP TRẦN PHÁT
 
PDF
Dell alienware 17r4
LAPTOP TRẦN PHÁT
 
PDF
Zaavar
lesson54
 
Zd12xx release notes_9.9
forum4user
 
Learn LCD Arduino-v1
handson28
 
PN985-MG3500-SDK-Guide
Sholeh Gregory
 
Dell Vostro 5459 - Laptops Trần Phát
LAPTOP TRẦN PHÁT
 
13fusionhybrid
rukford1
 
13mkzhybrid
rukford1
 
Dell Vostro 3671 datasheet
Mr Cuong
 
Dell Vostro 5581 Laptop giá rẻ chất lượng của Dell
LAPTOP TRẦN PHÁT
 
Dell vostro 5568 Laptops Trần Phát
LAPTOP TRẦN PHÁT
 
Dell alienware 17r4
LAPTOP TRẦN PHÁT
 
Zaavar
lesson54
 
Ad

Similar to LCD Keypad Shield (20)

PDF
Arduino: Arduino lcd
SANTIAGO PABLO ALBERTO
 
PPTX
pertemuan-keenam-lcd-display-project.pptx
AgusYuwono7
 
PPTX
Lcd module interface with xilinx software using verilog
sumedh23
 
RTF
Lcd n PIC16F
hairilfaiz86
 
DOCX
Dam gate open close lpc prog
nikhil dixit
 
PDF
KVMSwitchTech's Manual- How to Use and Install 16 Ports 1U 19" Rackmount Moni...
kvmswitchtech
 
PDF
ILI6122.pdf
frank735071
 
PDF
ILI6122 data sheet
frank735071
 
PPTX
131080111003 mci
jokersclown57
 
PPTX
Arduino LCD 16x2.pptx
ssuser3d9a7f
 
PDF
Graphical LCD
Raghav Shetty
 
PPTX
ESD -DAY 24.pptx
BhagvatShukla
 
PDF
Infrared matrix-password-input-system-with-arduino
icstation
 
TXT
Atmega lcd programing_with_header_file
ABHISHEK MAURYA
 
PDF
Dfr0464 datasheet
franklinpaiva1000
 
PDF
Dgs3612 g cli_dna
maqc8321
 
PDF
Red rio
fitz2014
 
PDF
2022-BEKM 3453 - LCD and keypad.pdf
VNEX
 
PDF
Final Report
Susmit Sircar
 
PDF
Compaq c8000 laptop
usdima
 
Arduino: Arduino lcd
SANTIAGO PABLO ALBERTO
 
pertemuan-keenam-lcd-display-project.pptx
AgusYuwono7
 
Lcd module interface with xilinx software using verilog
sumedh23
 
Lcd n PIC16F
hairilfaiz86
 
Dam gate open close lpc prog
nikhil dixit
 
KVMSwitchTech's Manual- How to Use and Install 16 Ports 1U 19" Rackmount Moni...
kvmswitchtech
 
ILI6122.pdf
frank735071
 
ILI6122 data sheet
frank735071
 
131080111003 mci
jokersclown57
 
Arduino LCD 16x2.pptx
ssuser3d9a7f
 
Graphical LCD
Raghav Shetty
 
ESD -DAY 24.pptx
BhagvatShukla
 
Infrared matrix-password-input-system-with-arduino
icstation
 
Atmega lcd programing_with_header_file
ABHISHEK MAURYA
 
Dfr0464 datasheet
franklinpaiva1000
 
Dgs3612 g cli_dna
maqc8321
 
Red rio
fitz2014
 
2022-BEKM 3453 - LCD and keypad.pdf
VNEX
 
Final Report
Susmit Sircar
 
Compaq c8000 laptop
usdima
 
Ad

More from Raghav Shetty (20)

PDF
8 Channel Relay Board-Bluetooth
Raghav Shetty
 
PDF
4 Channel Relay Board 5V-Bluetooth Compatible for Arduino
Raghav Shetty
 
PDF
4 Channel Relay Board 12V-Compatible for Arduino
Raghav Shetty
 
PDF
8 Channel Relay Board-Rs485
Raghav Shetty
 
PDF
Xbee X-CTU Software
Raghav Shetty
 
PDF
Digitla Vibration Sensor
Raghav Shetty
 
PDF
Thermal Printer
Raghav Shetty
 
PDF
Digital Soil Moisture Sensor
Raghav Shetty
 
PDF
Micro SD Memory Card Interface for 5V MCU
Raghav Shetty
 
PDF
Micro SD Memory Card Interface for 3.3V MCU
Raghav Shetty
 
PDF
Regulated Power Supply
Raghav Shetty
 
PDF
PIC Project Board
Raghav Shetty
 
PDF
8 Channel Bi Directional Logic Level Converter
Raghav Shetty
 
PDF
L298 Motor Driver
Raghav Shetty
 
PDF
Joystick Shield
Raghav Shetty
 
PDF
Force Sensor
Raghav Shetty
 
PDF
Plastic REED Float Switch
Raghav Shetty
 
PDF
Flex Sensor
Raghav Shetty
 
PDF
Serial EEPROM
Raghav Shetty
 
PDF
DTMF Decoder Shield for Arduino
Raghav Shetty
 
8 Channel Relay Board-Bluetooth
Raghav Shetty
 
4 Channel Relay Board 5V-Bluetooth Compatible for Arduino
Raghav Shetty
 
4 Channel Relay Board 12V-Compatible for Arduino
Raghav Shetty
 
8 Channel Relay Board-Rs485
Raghav Shetty
 
Xbee X-CTU Software
Raghav Shetty
 
Digitla Vibration Sensor
Raghav Shetty
 
Thermal Printer
Raghav Shetty
 
Digital Soil Moisture Sensor
Raghav Shetty
 
Micro SD Memory Card Interface for 5V MCU
Raghav Shetty
 
Micro SD Memory Card Interface for 3.3V MCU
Raghav Shetty
 
Regulated Power Supply
Raghav Shetty
 
PIC Project Board
Raghav Shetty
 
8 Channel Bi Directional Logic Level Converter
Raghav Shetty
 
L298 Motor Driver
Raghav Shetty
 
Joystick Shield
Raghav Shetty
 
Force Sensor
Raghav Shetty
 
Plastic REED Float Switch
Raghav Shetty
 
Flex Sensor
Raghav Shetty
 
Serial EEPROM
Raghav Shetty
 
DTMF Decoder Shield for Arduino
Raghav Shetty
 

Recently uploaded (20)

PDF
AI-Cloud-Business-Management-Platforms-The-Key-to-Efficiency-Growth.pdf
Artjoker Software Development Company
 
PDF
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
PPTX
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
PDF
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Security features in Dell, HP, and Lenovo PC systems: A research-based compar...
Principled Technologies
 
PDF
Make GenAI investments go further with the Dell AI Factory
Principled Technologies
 
PPTX
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
PDF
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
PDF
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
PPTX
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
PDF
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
PPTX
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
PDF
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
PPTX
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
PDF
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
PDF
Data_Analytics_vs_Data_Science_vs_BI_by_CA_Suvidha_Chaplot.pdf
CA Suvidha Chaplot
 
PDF
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
PDF
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 
PDF
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 
AI-Cloud-Business-Management-Platforms-The-Key-to-Efficiency-Growth.pdf
Artjoker Software Development Company
 
GDG Cloud Munich - Intro - Luiz Carneiro - #BuildWithAI - July - Abdel.pdf
Luiz Carneiro
 
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Security features in Dell, HP, and Lenovo PC systems: A research-based compar...
Principled Technologies
 
Make GenAI investments go further with the Dell AI Factory
Principled Technologies
 
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
Data_Analytics_vs_Data_Science_vs_BI_by_CA_Suvidha_Chaplot.pdf
CA Suvidha Chaplot
 
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 
Tea4chat - another LLM Project by Kerem Atam
a0m0rajab1
 

LCD Keypad Shield

  • 1. www.researchdesignlab.com Page 1 LCD Keypad Shield LCD KEYPAD SHIELD
  • 2. www.researchdesignlab.com Page 2 LCD Keypad Shield Table of Contents LCD KEYPAD SHIELD ................................................................................................................ 1 OVERVIEW ................................................................................................................................... 3 INTRODUCTION ...................................................................................................................... 3 FEATURES ................................................................................................................................ 3 APPLICATIONS........................................................................................................................ 4 CIRCUIT DIAGRAM ................................................................................................................ 4 ARDUINO CODE ...................................................................................................................... 5 OUTPUT..................................................................................................................................... 8 RELATED PRODUCTS ............................................................................................................ 9
  • 3. www.researchdesignlab.com Page 3 LCD Keypad Shield OVERVIEW INTRODUCTION One of the basic interfacing requirements for the hobbyists or electronics enthusiasts is I/P (keypad) and O/P (LCD display) for prototype applications. This shield uses minimum number I/O’s that is 4 bits for LCD data and 2 control signal lines for the same. A single analog pin (Pin A0) is multiplexed to read 5 input key switches (Navigation keys). Each key has been pulled up to a different voltage level, so a different voltage will be generated every time a user selects a key. This voltage could be read by the analog pin A0 on the board. Hence saves the no of I/O pins. The backlight of the LCD could be controlled by setting PWM (Pin D10) by adding a few lines of code. FEATURES  16X2 Blue color back light LCD.  A single Analog pin is multiplexed to read 5 input Keys.  Optional PWM based Back light control.  Stackable on UNO shield  High quality PCB FR4 Grade with FPT Certified.
  • 4. www.researchdesignlab.com Page 4 LCD Keypad Shield APPLICATIONS  Calculators  Cameras  Cash Registers  Clock Radios  Digital Meters  Hand-held TV & Terminals  Hand-held Data Collection  Heart Monitoring Devices CIRCUIT DIAGRAM
  • 5. www.researchdesignlab.com Page 5 LCD Keypad Shield ARDUINO CODE /* * Project name: LCD KEYPAD Shield * Copyright (c) Researchdesignlab.com * Description: * Test configuration: MCU: ATMEGA328 Dev.Board: Arduino uno Oscillator: 16 MHz Software: Arduino */ /* The circuit: * LCD RS pin to digital pin 12 * LCD Enable pin to digital pin 11 * LCD D4 pin to digital pin 5 * LCD D5 pin to digital pin 4 * LCD D6 pin to digital pin 3 * LCD D7 pin to digital pin 2 * LCD R/W pin to ground * 10K resistor: * ends to +5V and ground * wiper to LCD VO pin (pin 3) */ // include the library code: #include <LiquidCrystal.h> int sensorValue = 0; // value read from the keypad // initialize the library with the numbers of the interface pins LiquidCrystal lcd(12, 11, 5, 4, 3, 2); int sensorPin = A0; void setup() { // set up the LCD's number of columns and rows: lcd.begin(16, 2);
  • 6. www.researchdesignlab.com Page 6 LCD Keypad Shield delay(2000); } void loop() { lcd.clear(); // clear lcd display lcd.setCursor(0, 0); // set the cursor to column 0, line 0 lcd.print("LCD KEYPAD Shield"); lcd.setCursor(0, 1); // set the cursor to column 0, line 1 // read the input on analog pin 0 of keypad : sensorValue = analogRead(sensorPin); // check if the keypad is pressed disply keypad on lcd using sensorValue . if(sensorValue<=10) lcd.print("RIGHT KEY"); else if((sensorValue<=492)&&(sensorValue>=482)) lcd.print("DOWN KEY"); else if((sensorValue<=325)&&(sensorValue>=315)) lcd.print("UP KEY"); else if((sensorValue<=595)&&(sensorValue>=585)) lcd.print("LEFT KEY"); else if((sensorValue<=765)&&(sensorValue>=755)) lcd.print("SELECT KEY"); else lcd.print("NO KEY PRESSED"); delay(500); } SERIAL COMMUNICATION const int analogInPin = A0; // Analog input pin that the potentiometer is attached to int sensorValue = 0; // value read from the pot void setup() { // initialize serial communications at 9600 bps: Serial.begin(9600);
  • 7. www.researchdesignlab.com Page 7 LCD Keypad Shield delay(1000); } void loop() { // read the analog in value: sensorValue = analogRead(analogInPin); // check if the keypad is pressed disply keypad on lcd using sensorValue . if(sensorValue<=10) { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("RIGHT KEY"); }else if((sensorValue<=492)&&(sensorValue>=482)) { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("DOWN KEY"); } else if((sensorValue<=325)&&(sensorValue>=315)) { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("UP KEY"); } else if((sensorValue<=595)&&(sensorValue>=585)) { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("LEFT KEY"); }else if((sensorValue<=765)&&(sensorValue>=755)) { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("SELECT KEY"); } else
  • 8. www.researchdesignlab.com Page 8 LCD Keypad Shield { Serial.write(byte(0X01)); Serial.write(byte(0X80)); Serial.println("NO KEY PRESSED"); } delay(1000); } OUTPUT
  • 9. www.researchdesignlab.com Page 9 LCD Keypad Shield RELATED PRODUCTS RDL- UNO ATMEGA328 Development Board 4x4 Matrix Keypad LCD Interfacing Module Graphical LCD