Final year degree project for engineers Final year projects based on microcontrollers
Microcontroller based different projects abstract and source code
AT89s51 microcontroller projects Motion control
at89c2051 motor controller and other light projects
Tutorials of microcontroller 8051, A step by step easy to use self learning rapidex
Click Here to Advertise on My Blog

Tuesday, January 12, 2010

Alpha numeric LCD interface with micro-controller

How to control the standard Hitachi-44780 LCD using an 8051 microcontroller family.

Signals Processing and control automation

↑ Grab this Headline Animator



In This Project the main components used will be as follows:
1. LCD, alpha numeraic, 4 line 40 characters
2. Microcontroller At89s52, any other from this list can be used(8051, at89s51,at20c8051,etc)
LCD:
The LCD is a large alpha numeric type lcd of 4 lines and 40 characters means (4*40). The PIN configrurations is as follows:
P2.0 through P2.4: LCD DB[4:7] ;Bi-directional data/command pins. Alphanumeric characters are sent in ASCII format.
P2.5: LCD RS; Register Select -> Command Register is selectedRS = 1 -> Data Register is selected
P2.6: LCD E1 Enable (Latch data) for first controller
P2.4: LCD E2 Enable (Latch data) for second controller
E: Used to latch the data present on the data pins. A high-to-low edge is needed to latch the data
R/W: Read or Write 0 -> Write, 1 -> Read
8 data pins D7:D0
VEE : contrast control, a variable resistor of 10k between VCC and ground is used to control VEE voltages for contrast.

Display Data RAM (DDRAM) of LCD
Display data RAM (DDRAM) is where you send the characters (ASCII code) you want to see on the LCD screen. It stores display data represented in 8-bit character codes. Its capacity is 80 characters (bytes).
Busy Flag (BF) of LCD
When the busy flag is 1, the LCD is in the internal operation mode, and the next instruction will not be accepted. When RS = 0 and R/W = 1 the busy flag is output to DB7 (MSB of LCD data bus).
Please note that : The next instruction must be written after ensuring that the busy flag is 0.
LCD Commands
The LCD’s internal controller accept several commands and modify the display accordingly on getting the commands. These commands would be like these:
– Clear screen– Return home– Shift display right/left etc.

The other Instruction s are as follows, which are used when and where required in the code or program. the code is in decimal and then hexadecimal.

  1. Function set (8-bit interface, 2 lines, 5*7 Pixels) Decimal=56, HEX =38
  2. Function set (8-bit interface, 1 line, 5*7 Pixels) 48 ,30
  3. Function set (4-bit interface, 2 lines, 5*7 Pixels) 40, 28
  4. Function set (4-bit interface, 1 line, 5*7 Pixels) 32, 20
  5. Scroll display one character right (all lines) 28 ,1E
  6. Scroll display one character left (all lines) 24, 18
  7. Home (move cursor to top/left character position) 2, 02
  8. Move cursor one character left 16, 10
  9. Move cursor one character right 20, 14
  10. Turn on visible underline cursor 14 ,0E
  11. Turn on visible blinking-block cursor 15 ,0F
  12. Make cursor invisible 12 ,0C
  13. Blank the display (without clearing) 8 ,08
  14. Restore the display (with cursor hidden) 12 ,0C
  15. Clear Screen 1 01
  16. Set cursor position (DDRAM address) 128 + addr ,80+ addr
  17. Set pointer in character-generator RAM (CG RAM address) 64 + addr, 40+ addr

Program for LCD 4line and 40characters in keil c51 is as follows:

// 02/01/2010an example program in c
// for lcd of four line and 40 characters on each line
#include //at89x51.h for registers of 8051
#include// intrins.h for nop
unsigned int delayy;sbit lcd_en1 = P2^6;
sbit lcd_rs = P2^5;sbit lcd_en2 = P2^4;sbit lcd_d7 = P2^3;//4 bit connection
sbit lcd_d6 = P2^2;sbit lcd_d5 = P2^1;sbit lcd_d4 = P2^0;
void delay(n);
void initializelcd(void);
void lcd_send_byte(unsigned char godata,bit w,bit e);
void gotoxy(unsigned char x, unsigned char y,bit ec);
void printlcd(unsigned char *ch,bit el);
void clrlcd(bit ed);
void main(){
delay(10); initializelcd(); delay(10000); gotoxy(0,0,0);
delay(15000); clrlcd(0); delay(1000);
printlcd("Welcome Date = 27/5/2007 Time = 11:59pm",0); delay(5000);
gotoxy(0,1,0); delay(9000);
printlcd("Testing of a four line lcd",0); delay(10000);
gotoxy(0,0,1); delay(9000);
printlcd("Developed By Dr. Rana",1); delay(10000);
gotoxy(0,1,1); delay(9000);
printlcd(" Pakistan. ",1); delay(15000);
while(1) { ; } }
void initializelcd(void)
{ delay(16000); lcd_en1 = 1;lcd_en2 = 1;
lcd_send_byte(0x38,0,0); delay(1000);
lcd_en1 = 0;lcd_en2 = 0;
delay(1000); lcd_en1 = 1;lcd_en2 = 1;
lcd_send_byte(0x38,0,0); delay(1000);
lcd_en1 = 0;lcd_en2 = 0; delay(1000);
lcd_en1 = 1;lcd_en2 = 1; lcd_send_byte(0x38,0,0);
delay(1000); lcd_en1 = 0;lcd_en2 = 0;
delay(1000); lcd_en1 = 1;lcd_en2 = 1; lcd_send_byte(0x20,0,0);
delay(1000); lcd_en1 = 0;lcd_en2 = 0;
delay(1000); lcd_en1 = 1;lcd_en2 = 1; lcd_send_byte(0x0c,0,0);
delay(500); lcd_send_byte(0x01,0,0);
delay(500); lcd_send_byte(0x06,0,0);
delay(500); lcd_send_byte(0x1c,0,0);
delay(500); lcd_send_byte(0x01,0,0);
delay(500); lcd_en1 = 0;lcd_en2 = 0;
}
void delay(n)
int n;
{
int i;
for (i=0;i

Other microcontroller based projects search here on this microcontroller51 blog in different posts:
data acquisition system heart rate monitor data acquisition heart rate counter display atmega ad converter 8051 projects 7 segment display temperature controller adc0804 at89c51 temperature sensor max232 circuit moving display board stepper motor digital to analog converter adc sample digital speedometer 8051 development board light sensor intafacing with microcontroller and data acquisition and control adc0808 interfacing 8051 different types of display interfacing with microcontrollers display board interfacing with micrcontroller frequency or pulse rate calculator using AT89c51 seven segment display interfacing with microcontroller 8051 power control system door security project using microcontroller 8051 family motor controller using microcontroller at89s52 dimmer project based on microcontroller and lcd interface circuit diagram pwm dimmer lcd connexion with 8051 circuit

15 comments:

  1. Good post and this post helped me alot in my college assignement. Thank you seeking your information.

    ReplyDelete
  2. I truly believe that we have reached the point where technology has become one with our world, and I am fairly certain that we have passed the point of no return in our relationship with technology.


    I don't mean this in a bad way, of course! Societal concerns aside... I just hope that as technology further advances, the possibility of transferring our memories onto a digital medium becomes a true reality. It's one of the things I really wish I could experience in my lifetime.


    (Posted on Nintendo DS running [url=http://www.leetboss.com/video-games/r4i-r4-sdhc-nintendo-ds]R4i[/url] DS SPPost)

    ReplyDelete
  3. Are these vedios games developed by using microcontroller say 8051 ?

    ReplyDelete
  4. I thing these games donot use microcontrollers? are they are not vedio microcontroller games.

    ReplyDelete
  5. My friend and I were recently discussing about how we as a society are so hooked onto electronics. Reading this post makes me think back to that debate we had, and just how inseparable from electronics we have all become.


    I don't mean this in a bad way, of course! Societal concerns aside... I just hope that as memory gets less expensive, the possibility of copying our memories onto a digital medium becomes a true reality. It's a fantasy that I dream about all the time.


    (Posted on Nintendo DS running [url=http://does-the-r4-r4i-work-with-the-new-ds.onsugar.com/Does-R4i-R4-actually-work-7232282]R4[/url] DS Ting2)

    ReplyDelete
  6. Well I to but I contemplate the post should prepare more info then it has.

    ReplyDelete
  7. good, i just made lots of new emo backgrounds in my blog
    http://www.emo-backgrounds.info

    ReplyDelete
  8. Hy,
    I am student of FACULTY OF TECHNICAL SCIENCES,Novi Sad,Serbia
    I have to do frequency counter project on 8052 and I think that yours project Programmable Frequency meter can help me....
    So if it is not problem can you send me full project files?

    Thanks in advance...
    Regards from Serbia

    ReplyDelete
  9. Thanks! This helped a bunch! I've read a couple
    rather confusing blogs lately, this cleared up some confusion I had.

    ReplyDelete
  10. Perfect!Great! This helped a lot! I've read several
    rather confusing blogs lately, this cleared up a lot confusion I had.

    ReplyDelete
  11. Perfect!Great! This helped so much! I've read a few
    rather confusing blogs lately, this cleared up a lot confusion I had.

    ReplyDelete
  12. Genial fill someone in on and this fill someone in on helped me alot in my college assignement. Thank you on your information.

    ReplyDelete
  13. Растаможка Киев, Одесса
    Консультации ВЭД
    Дима Литейный
    logisticskiev7@yandex.ru
    +38 093 318 1567

    ReplyDelete
  14. If possible please write full code for Alpha numeric LCD interface with microcontroller

    ReplyDelete
  15. please the full code for Alpha numeric LCD interface with micro-controller
    my email : Ghazali-y@hotmail.com

    ReplyDelete

Please note that my helps are not for free.
So, send me your problems and pay money for solution.ok
This is www.microcontroller51.blogspot.com comments section. Here you are requested to write your questions and problems about the microcontroller and electronics projects. Write the questions or comments in such a way that, it have all necessary information, so that i can understand and reply.If you want to send pictures and codes then e-mail me (rghkk@hotmail.com).Thanks.
All comments will be highly appriciated.

Blogroll

  • 8051 Projects
  • Microcontroller based different projects abstract and source code
    AT89s51 microcontroller projects Motion control
    at89c2051 motor controller and other light projects
    Tutorials of microcontroller 8051, A step by step easy to use self learning rapidex

    Microcontroller Forum

    Recent Comments

    About

    rs 232 and microcontrollers , 8051 intelligent robotic car gsm based digital notice board microcontroller projects+steppermotor driver, frequency counter project,TSOP1738 interfacing with AT89C51 data microcontroller 8051:data aquisition and control syatems, microcontroller interface boards, programmable interface controller ready program for rs232 interface in vb6 ,circuit diagram of car parking system for the 8051 microcontroller simple led project using 8051 with assembly language,creating a c interface between a pic and humidity sensor heart beat sensor circuit diagram,t6963 asm 89c51 free schematic,dac08,heart beat monitor with microcontroller 8051.ppt,pressure sensor digitizer,adc0802 +avr +source* -datasheet,i need project explanation of 80c51 microcontrolled based calculator,metro train prototype mini project,lcm interface circuits with 8051 microcontroller ,micro controller application example in industry ,direct logic examples sensor de presion humidity and temperature circuit ,pwm measure microcontroller ,ge sonosite diadnostic picture final project report on weather acquisition system ,82c55a to rs232 ,pc based heart beat pulse monitor microcontroller strobe led project using assemby programming 8051 motor control,ethernet microcontroller interface circuit design for temperature humidity sensor, line follower dengan mikro controller at89s51,"interface a temperature sensor lm35 with 8051 ic using an amplifier and adc 0804 ic ",lift8051 microcontroller code,dac08,heart beat sensor circuit diagram,8051 lcd,pc parelle port projects,solution de connectivité ethernet microcontroleur,t6963 asm 89c51 free schematic,89c51 microcontroller interfacing with adc 0808 data sheet,control port data port lcd,dac-08 ,stepper motor connector,moving message circuit diagrams,stepper motor configuration,c++ lesson at the at89c51,car parking design 8051,dac-08,pc to pc communication using ir transceiver with 8051 and TSOP,8051 micro controller circuit diagram,vb6 rs232,similarities and differences between the 8051 and the atmel,u-shaped photo sensor,dac0800 proteus,how to display adc data on graphic lcd,mcs51 car data acquisition,mcs51 digital automotive gauge,lcd tachometer project with pic 16f877a and micro c,lm324 analog to digital proteus,pc based data acquisition system project,max232 serial programming,max232 serial programming,mcs 8051 and glcd display models installed to run this sample.,The microcontroller AT 89S51 is serially programmed using the software ATMEL,ds1307 89c51 alarm code,16f877a pressure sensor,multiplexed port system of 8051,rs232 micro controller used in closed circuits programmed with vb,8051 heart monitor,pulse rate counter circuit diagram using micro controller,ethernet microcontroller interface circuit design for temperature humidity sensor,project schematic dac0800,industrial robot controller based on '51 microcontroller family,connect lm35 to adc, adc to 8051 and two 7-segment displays to 8051,8051 rs232 serial communication code in c,project with block diagram & circuit diagram of temperature & light monitoring & controlling,main theme of 80c51 microcontroller based calculator,solenoid valve interface with microcontroller,schematic line follower mikrokontroler at89s51,home monitoring system using 8051 c programming,zero crossing triac power control pump,gambar diagram serial port,t6963 asm 89c51 free schematic,address counter lcd interface,t6963c circuit,Electronic meters for power calculation of electricity consumption,adc0808 intel 8051,microcontroller and lcd interface,inductive proximity sensor connect microcontroller,8051, data logger 24c16,interfacing remote to microcontroller pic16f877a.h,pictures for memory orgnization of at89c51 micro controller,frequency counter with atmel flow chart,serial optical microcontroller,pulse width measurement,software codes using keil c compiler for final year projects,micro 7448 7 segment,seminar ppt-8051in automobiles,mcs 51 lcd asm interface a temp. sensor lm35 ic with 8051 using an amplifier and adc0804 with sehematic diagram?,lcd 8051,"stepper motor wires,"what is zero crossing" diac,8051 8255 chip helps,interface a dc motor with 8051 microcontroller to control the speed using a dac with diagram?,keil c51 uploading data from computer,manometer sensor i2c,temperature control using pwm and 89c51,1-wire command 8051 + assembly,keil c51 uploading data from computer,adc converter assembly program,c code for lm35 by use microprocessor,dc motor control site:www.the-crankshaft.info,micro controller clock,microcontroller valve,pdf form of electronic mini project circuit diagram based om sensor,speed detection circuits of high speed vechicles using controller 8051 and sensors,stepper motor wire, interfacing of 8051 with 4511,microcontroller lpc2148 based noise control algorithm for external signals,pin diagram of adc,mini ECG schematic diagram,interfacing of 8051 with 4511,1-wire slave,data acquisition using 8051,definition and description of automatic irrigation system,microcontroller lpc2148 based noise control algorithm,using 89c51 heart bit monitoring system,SPI INTERFACE diagrama de recorrido de sensor de latido de corazón, t6963 asm 89c51 libre esquemático, dac08, monitor de latido de corazón con microregulador 8051.ppt, digitizador de sensor de presión, adc0802 avr source*-datasheet, tengo que proyectar la explicación de 80c51 microcontroló la calculadora basada, prototipo de tren de metro proyecto mini Интерфейс Двигатель постоянного тока с 8051 микроконтроллер для управления скоростью с помощью ЦАП с диаграммой?, Keil C51 загрузки данных с вашего компьютера, манометр i2c датчик контроля температуры использованием ШИМ и 89C51 8051 + 0,1 командной провода сборки, Keil C51 загрузки данных с вашего компьютера , ADC программе сборки преобразователя, C код для использования микропроцессора LM35, DC сайте управления двигателем: www.the-crankshaft.info, микро часы контроллера, микроконтроллера клапан, PDF форме электронных схем проекта мини 如何显示图形LCD,汽车数据采集MCS51的,MCS51的车载数字仪表,转速表项目液晶与ADC日期石化16F877A微型和C,变形LM324的模拟到数字的,基于PC的数据采集系统项目,编程序列的MAX232,串行编程的MAX232,单片机8051 Glcd显示模式,安装运行此示例。中,AT 89S51单片机串行编程软件使用ATMEL公司と液晶グラフィックLCDを、車のデータ集録MCS51、MCS51自動車デジタルゲージ、タコプロジェクトの表示方法のADCの日付は、デジタル、PCベースのデータ集録システムプロジェクト、プログラミングMAX232と、MAX232のシリアルプログラミングシリアル、16F877Aは、マイクロおよびcプロテウスLM324アナログ写真mcsの8051 Glcdディスプレイモデルは、このサンプルを実行するためにインストールされています。は、AT 89S51マイクロコントローラは、シリアルソフトウェアをアトメル使用してプログラムされている lm324 voltage capacity,microcontroller 8051,.bas code rs232 to at89c2051 dot matrix,4 digits 7 segment led circuit 8051, generating frequency using 8051 circuit diagram,how to write controller by c,6 pin electrical clip,8051 based projects using keil software,8051 serial communication to pc, 8255 led driver images developing an acquisition and control system how can we measure reactance using 8051 controller i2c 8051 humidity sensor i2c 8051 humidity sensor sht,microcontroller 8051 rotabit GPS and GSM based Car locator,Send and Receive SMS Keil C code,Play music with 8051 microcontroller,LED dot matrix display using AT89C52 Interfacing GPS with 8051,Wireless keyboard with AT89S52 and nRF2401 RF module ,snake game,led lc meter snake game,LCD display,stepper motor inter facing using 8051 Top Downloads this MonthC51 code for interfacing GPS,8051 based Taximeter,GPS and GSM based Car locator, electonic code lock Send and Receive SMS Keil C code,Play music with 8051 microcontroller LED dot matrix display using AT89C52,120V light bulb on/off LCD Graphic display with AT89s51,Interfacing GPS with 8051,AT89C2051 temperature and humidity using SHT11,Ultrasonic distance meter using AT89S52 Top downloads16x128 Dot matrix moving message display,Digital Capacitance meter using AT89S52,countdown timer LCD Graphic display with AT89s51,PS2 keyboard interfacing with LCD display LED dot matrix display using AT89C52,16x64 dot-matrix LED display with Time,H bridge GPS with AT89s52 and graphics display,8051 based Taximeter,Moving message display Ultrasonic distance meter using AT89S52,simple digital voltmeter with c programming GPS with 8051 digital alaram clock 8x8 Running Texts Display sooxma technologies ,embedded systems projects at home ,interfacing 8051 with gsm modem , projects for enginnering students , android bluetooth "controller area network" ,speedometer as motor vehicle safety system microcontroller ,robotic project,prepaid electricity live monitoring ,ieee papers on gps navigation for the blind , gsm-based prepaid electricity system temperature sensor using 8051,lm324 and lm35,Temperature level monitoring in boilers using 8051 microcontroller,experiment board in instrumentation and control through the PC parallel port,TSOP 1738 interfacing with AT89C51 ,TSOP1738 interfacing with AT89C51 pdf ,solenod valve ,8051project.com ,Temperature controller using DS1820 and LCD displayTemperature controller using DS1820 and LCD display ,Interfacings of Automatic room light controller with visitor counter ,automatic plant irrigation ,TSOP1738 interfacing with AT89C51 synopsis of Lcd interfacer using 8051 microcontroller mini project with circuit diagram 8x8 led display interfacing with microcontroller data acuasition system pwm based speed control of ac motor using 8051 controller with abstract heart rate pic sms based digital notice board real time clock using 8051 microcontroller vb lpt stepermotor assembly code for lcd connected to 8051 mini project on temp controleer with ckt diagram free download 6 wires stepper motor adc0804 lpt assemply language programs with 8051 automatic-plant-watering switch buzzer diagram arrows with pic16f84 forward reverse swr meter frequency control with microcontroller esquematic electronic detector high voltage ic principle diagram 89s51 interface between gps and microcontroller velocity +adc interfacing automatic car parking system circuit triac used with pwm designing pressure sensor as student project microcontroller to drive motors interfacing adc 0809 to 89c51 videos pic microcontroller projects, level gauge 6 wire stepper motor wiring connection home monitoring system with temperature sensing and motion control using pic atmega control board sample code isolation amplifier circuit diagram using 4n33 microcontroller web emulators air fue; rartio meter with pic mcu project with schematic circuit diagram of 8086 microprocessor project microcontroller at89c51 based voting machine moving message oxygen transducer servo symbol list of components in automated carparking simple interfacing projects with microcontroller 8051 microcontroller based moving message display temperature indicator circuit using microcontroller lcd interfacing with 8051 pdf temperature sensor 8051 lcd automatic plant irrigation at89c2051 temperature how to add effect on asm display with 89s52 vhdl ttl module heart beat monitor with wave on lcd 8051 based moving message display : 89c51 micro controller led matrix www.the basic programming of edsim 8051(design of lift using flow chart) automated irrigation controle system using 8051 circut dia gram 8051 memory organization circuit layout of an automayic irrigation system ir led and ldr based heartbeat monitor with display on computer