____________________________________________________________________________________________________
However, active matrix is still a superior technology. ____________________________________________________________________________________________________ Content for the tab VIDEO
Pin No
Function
Name
1
Ground (0V)
Ground
2
Supply voltage; 5V (4.7V – 5.3V)
Vcc
3
Contrast adjustment; through a variable resistor
VEE
4
Selects command register when low; and data register when high
Register Select(RS)
5
Low to write to the register; High to read from the register
Read/write(RW)
6
Sends data to data pins when a high to low pulse is given
Enable(E)
7
8-bit data pins
DB0
8
DB1
9
DB2
10
DB3
11
DB4
12
DB5
13
DB6
14
DB7
15
Backlight VCC (5V)
Led+
16
Backlight Ground (0V)
Led-(GND)
Click Here : understanding of LCD module and its interfacing
1. Program of interfacing lcd with 8051
/******************************************************
IDE :- Keil
DEVELOPED BY:- FIRMWARE DEVELOPER (www.firmcodes.com)
WHAT PROGRAM DO:- DISPLAY ON LCD "WELCOME TO FIRMCODES.COM"
******************************************************/
#include<reg51.h>
sfr lcd=0x90; // data of lcd at port 2
sbit rs=P3^0; // rs pin at P3.0
sbit rw=P3^1; // rw pin at P3.1
sbit en=P3^2; // en pin at P3.2
void delay(); // for delay
void cmd(); // lcd in command mode
void display(); // lcd is in display mode
void main()
{
while(1)
{
// LCD INITIALIZE START
lcd=0x38;
cmd();
lcd=0x0e;
cmd();
lcd=0x01;
cmd();
lcd=0x06;
cmd();
lcd=0x80;
cmd();
// LCD INITIALIZE END
// DATA DISPLAYING ON LCD
lcd='W';
display();
lcd='E';
display();
lcd='L';
display();
lcd='C';
display();
lcd='O';
display();
lcd='M';
display();
lcd='E';
display();
lcd=' ';
display();
lcd='T';
display();
lcd='O';
display();
lcd=0xc0; //NEXT LINE COMMAND
cmd();
lcd='F';
display();
lcd='I';
display();
lcd='R';
display();
lcd='M';
display();
lcd='C';
display();
lcd='O';
display();
lcd='D';
display();
lcd='E';
display();
lcd='S';
display();
lcd='.';
display();
lcd='C';
display();
lcd='O';
display();
lcd='M';
display();
}
}
void cmd()
{
unsigned char i;
rs=0;
rw=0;
en=1;
for(i=0;i<2;i++);
en=0;
delay();
}
void display()
{
unsigned char i;
rs=1;
rw=0;
en=1;
for(i=0;i<2;i++);
en=0;
delay();
}
void delay()
{
unsigned int i,j;
for(i=0;i<100;i++)
for(j=0;j<153;j++);
}
PROTEUS File for SIMULATION(Password Of RAR file is :-firmcodes.com)