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

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
12/15/06 17:14
Read: times


 
#129559 - Initialization
Responding to: ???'s previous message
Look at the following diagram for initialization. You'll notice they send the #38h (function set) more than once.



Your program only sends #38h once.

	ACALL	ZERO		; fill P1 and P3 with 0
	ACALL	TIMER_75MS	; wait 75 milliseconds
	MOV	LCDdata,#38h	; set display on, two lines
	ACALL	ENABLE		; send command to LCD
	ACALL	TIMER_75MS	; wait again
	MOV	LCDdata,#0Fh	; set display on, cursor on, blink on
	ACALL	ENABLE		; enable command
	ACALL	TIMER_1MS	; wait
	MOV	LCDdata,#01h	; display clear
	ACALL	ENABLE		; enable
	ACALL	TIMER_30MS
	MOV	LCDdata,06h	; entry mod set = increment mode
	ACALL	ENABLE
	ACALL	TIMER_30MS	; end of initialization
	SETB	RS		; I set the bus for data, from now i ;can send DATA
	ACALL	ENABLE
	ACALL	TIMER_30MS
	MOV	LCDdata,'a'
	ACALL	ENABLE
	ACALL	TIMER_30MS
	MOV	LCDdata,'A'
	ACALL	ENABLE
LOOP:
	NOP
	AJMP LOOP

END


Jon

List of 14 messages in thread
TopicAuthorDate
LCD+error            01/01/70 00:00      
   sure, about what            01/01/70 00:00      
      LCD+error            01/01/70 00:00      
         Initialization            01/01/70 00:00      
            Thank you            01/01/70 00:00      
               Post all of your display code            01/01/70 00:00      
               Oops... try this            01/01/70 00:00      
   LCD+error            01/01/70 00:00      
      usually it's the program, not the hardware            01/01/70 00:00      
         99% SOLVED            01/01/70 00:00      
            Are you still...            01/01/70 00:00      
            strange coding            01/01/70 00:00      
            Sorry for mistake            01/01/70 00:00      
   fortunately happy end            01/01/70 00:00      

Back to Subject List