Search Projects

Final year degree project for engineers DAC0800 based project circuit diagram and interfacing with pic mirocontroller Final year projects based on microcontrollers on programmable peripheral interface 8255
Microcontroller based different projects abstract and source code
PIC 16f877 microcontroller projects Motion control
PIC16f877 motor controller and other light projects
Tutorials of microcontroller PIC16f877, A step by step easy to use self learning rapidex

Friday, August 26, 2011

moving message on LCD using PIC microcontroller 16f84

This post is about the scrolling the moving message from right to left on LCD screen using microcontroller PIC1684. The ciruit diagram of moving message display is shown below. The code of this project is written in proton basic compiler.


moving message on LCD using PIC microcontroller 16f84 move message from left to right moving message on LCD using PIC microcontroller 16f84 scrol text from right to left scroll text


'****************************************************************
'* Name : LCD scrolling text.BAS *
'* Author : [Dr.Rana] *
'* Date : 8/25/2011 *
'* Version : 1.0 *
'* Notes : Moveing message on LCD 16 character 2 line *
'* : *
'****************************************************************
Device 16F84A
Declare LCD_Interface 4
' 4-line or 8-line interface is required by the LCD.
Declare LCD_Lines 4
' Inform the compiler as to how many lines the LCD has

Dim SCROL As Word
' this viarable is for indexing the characters on LCD
Dim ASCII As Byte
' second index variable for LCD locations
Dim CHAR1 As Byte
'temparary variable in RAM
PORTB=0
PORTA=0
DelayMS 500
' to stabilized microcontroller

PRINT_MESSAGE_LCD_scrol:
For SCROL= 0 To 800
Cursor 1,1
For ASCII=0 To 15
' 0 TO 16 MAKES A TOTAL OF 16 LOCATION IN THE LCD (FOR LCD = 16 CHARS)

CHAR1 = LRead TEXT1 + (ASCII+ SCROL)
' Read memory location LABEL + LOOP
Print CHAR1
Next ASCII
Cursor 2,1
For ASCII=0 To 15

' 0 TO 16 MAKES A TOTAL OF 16 LOCATION IN THE LCD (FOR LCD = 16 CHARS)

CHAR1 = LRead TEXT2 + (ASCII+ SCROL)

' Read memory location LABEL + LOOP

Print CHAR1
Next ASCII
DelayMS 250

' DELAY IN ORDER TO SEE THE TEXT IN THE LCD

Next SCROL
GoTo PRINT_MESSAGE_LCD_scrol

TEXT1:
LData " This is moving message example on LCD, the text will be scrol from right to left on LCD at first line "
TEXT2:
LData " This example is written in IC BASIC Proton. and two line scroling is being performed here"
GoTo PRINT_MESSAGE_LCD_scrol

This program is tested in proteus ISIS and works fine.
The crystal frequency for microcontroller PIC 16f84 is 4MHz.
The text is scroll from right to left at both lines of LCD.
The user can change their own message in the program and recompile the basic code to hex file. Then using suitable programmer for PIC16f84 and burn the hex file of moving message display into the microcontroller.

0 comments:

Post a Comment

Hi: This is PICINF.blogspot.com comments section. Here you are requested to write your question or problems in detail. Write the question in such a way that, it have all necessary information, sothat i can understand and reply.If you want to send pictures and codes then e-mail me (rghkk@hotmail.com).Thanks.