Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

LCD clock display

Status
Not open for further replies.

monkeyxp

New Member
how to give a timing that is exactly same as clock? should i use 3.579545MHz crystal?
Can any body tell me how to interface LCD using 4-bit mode, i know how to use 8-bit mode or you can give me some information. I do my own research...
:shock:
 
Check out www.8052.com for tutorial on interfacing LCD with 8051. Both in 4-bit and 8-bit mode. It also has tutorial for software RTC using internal Timer of 8051.
 
If i was doing this, i would use a TMR0 register, (okay, i love these) on an interupt been triggered every second, set to incriment some fileregisters, test on overflow from 60, imcremint mins, test again, inc hours, etc.

The main loop of the code itself would constantly be updating the LCD HD44780 is soooooooooooooooo easy. and i left out some "o"s showing my contempt for any one that buys a maxtrix orbital etc. </RANT>

So HD44780 is very forgiving about timing when comunicating with it, so just keep spaming the values in the file register to the LCD (use a lookup table to convert 60d into the correct two byte ASCII codes). The TMR0 overflow interupt would interupt each time on exactly a second.

(using a pre-scaler its easy to get a crystal that will do this for you, better to go for the slower side for better accuracy).
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top