Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
03/20/09 05:22
Read: times


 
#163671 - Problem with scrolling display.
hello everyone...i am using 20x4 line LCD. In this I would be displaying strings listed below and then i would scroll them to left character by character and once all characters are shifted new string appears. This process is repitative. The problem is when first set is displayed the scrolling is fast its hardly visible..then the first 2 lines of set 1 are displayed again..on which set2 lines are overwritten. I am not understanding why this is happening..can anyone help me...



org 0000h
sjmp start1
org 0003h
;ljmp isr_ex0
org 0013h
;ljmp isr_ex1
org 0030h
start1: mov sp,#30h

mov a,#38h
acall comnwrt
acall delay
mov a,#0Eh
acall comnwrt
acall delay
mov a,#01h
acall comnwrt
acall delay

mov tcon,#00000101b
;DEFAULT DISPLAY
welc:
;mov ie,#00000101b

mov dptr,#wel
mov r0,#80h
acall disp_str

mov dptr,#col
mov r0,#0c0h
acall disp_str

mov dptr,#dad
mov r0,#94h
acall disp_str

mov dptr,#mom
mov r0,#0d4h
acall disp_str
acall delay

;***************************************
mov r1,#20
left_disp:
mov a,#18h
acall comnwrt
acall delay
djnz r1,left_disp
;***************************************

;***************************************
;Code modified to clear LCD screen.

;mov a,#01h
;acall comnwrt
;acall delay

;***************************************

mov dptr,#mesg
mov r0,#0c0h
acall disp_str
acall delay

mov dptr,#sis
mov r0,#94h
acall disp_str
acall delay

mov dptr,#bro
mov r0,#0d4h
acall disp_str
acall delay

;***************************************
mov r1,#20
left_disp1:
mov a,#18h
acall comnwrt
acall delay
djnz r1,left_disp1
;***************************************


;***************************************
;Code modified to clear LCD Screen.

;mov a,#01h
;acall comnwrt
;acall delay
;***************************************

mov dptr,#prof0
mov r0,#80h
acall disp_str
acall delay

mov dptr,#prof1
mov r0,#0c0h
acall disp_str
acall delay

mov dptr,#prof2
mov r0,#94h
acall disp_str
acall delay

mov dptr,#prof3
mov r0,#0d4h
acall disp_str
acall delay

;***************************************
mov r1,#20
left_disp2:
mov a,#18h
acall comnwrt
acall delay
djnz r1,left_disp2
;***************************************


;***************************************
;Code modified to clear LCD Screen.

;mov a,#01h
;acall comnwrt
;acall delay
;***************************************

;mov ie,#10000101b
;mov a,#07h
;acall comnwrt
;acall delay
sjmp welc


;FETCHING CHARACTERS


disp_str:mov r1,#20
nextch:mov a,r0
acall comnwrt
acall delay
mov a,#00h
movc a,@a+dptr
acall datawrt
acall delay
inc dptr
inc r0
djnz r1,nextch
ret

;COMMAND SUBROUTINE

comnwrt:mov p1,a
clr p2.0
clr p2.1
setb p2.2
acall delay
clr p2.2
ret


datawrt:mov p1,a
setb p2.0
clr p2.1
setb p2.2
acall delay
clr p2.2
ret


;DELAY FOR LCD
delay:mov r3,#50
here2:mov r4,#255
here:djnz r4,here
djnz r3,here2
ret

;LOOK UP TABLE FOR DISPLAY

;Set1
wel: db'**WELCOME TO********'
col: db'*****Fr C.R.I.T*******'
dad: db'***EXTC DEPARTMENT***'
mom: db'*****SEM VI***************'

;Set2
mesg:db 'MOVING MESSAGE DISPLAY'
sis: db'****PRESENTED BY****'
bro: db'****GROUP MEMBERS****'

;Set3
prof0:db'*******MACA PATAA******'
prof1:db'***PRANAVL TABAZANE*****'
prof2:db'****ANIRUDH PURS****'
prof3:db'***SHYAMSUR SADVI****'

end


List of 2 messages in thread
TopicAuthorDate
Problem with scrolling display.            01/01/70 00:00      
   For a start...            01/01/70 00:00      

Back to Subject List