BM Dept., Govt. Engg. College, Gandhinagar Page 47
MOV TH1,#0FDh ;Count value for baud rate 9600
MOV SCON,#50h ;8 bit UART mode, REN enable
MOV R0,#20h ;Pointer to the RAM location
SETB TR1 ;Start timer 1 to generated baud rate.
next: MOV A,SBUF
HERE: JNB RI,HERE
CLR RI
MOV @R0,A
INC R0
SJMP next ;Repeat task
END
:: WORKSHEET ::
A. Modify program to display received data on the LCD connected at port P1. Assume
control lines of LCD RS, EN and WR are connected to P2.0, P2.1 and P2.2 respectively.
Memory
Location
HEX
code
Label Opcode Operands Comments
Comments to this Manuals