This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

No subject

sir i am using keil uvision 3 and i am using windows 7 ultimate when i generate a hex file for the following code:
MOV A,#38H ;INIT LCD 2 LINES 5X7 MATRIX

ACALL COMMAND ;ISSUE COMMAND

MOV A,#0EH ;LCD ON, CURSOR ON

ACALL COMMAND ;ISSUE COMMAND

MOV A,#01H ;CLEAR LCD COMMAND

ACALL COMMAND ;ISSUE COMMAND

MOV A,#06H ;SHIFT CURSOR RIGHT

ACALL COMMAND ;ISSUE COMMAND

MOV A,#80H;CURSOR: LINE 1, POS.6

ACALL COMMAND;ISSUE COMMAND

MOV TMOD,#20H ;TIMER 1, MODE 2

MOV TH1,#0fdh ;9600 BAUD @ 11.0592MHZ

MOV SCON,#50H ;8 BIT, 1 STOP BIT

SETB TR1 ;START TIMER 1

SCAN: JNB RI,SCAN ;WAIT FOR CHAR. TO COME IN MOV A,SBUF ;SAVE INCOME BYTE IN B ACALL DATA_DISPLAY ;DISPLAY DATA CLR RI ;TO SHOW THAT WE RECEIVED THE BYTE SJMP SCAN ;FETCH NEXT BYTE COMMAND: ACALL READY MOV P0,A CLR P1.5 ; rs=0 for command CLR P1.6 ; read write=0 SETB P1.7 ; enable=0 CLR P1.7 RET DATA_DISPLAY: ACALL READY MOV P0,A SETB P1.5 ;rs=1 CLR P1.6 ;write

SETB P1.7 ;enable=1 CLR P1.7 ;enable=0 RET READY: SETB P0.7 CLR P1.5 SETB P1.6 BACK: CLR P1.7 SETB P1.7 JB P0.7,BACK RET END

i am getting the followin hex code:
:100000007438112A740E112A7401112A7406112AE7
:100010007480112A758920758DFD759850D28E30A7
:1000200098FDE5991137C29880F51144F580C29585
:10003000C296D297C297221144F580D295C296D229
:1000400097C29722D287C295D296C297D29720871D
:02005000F92293
:00000001FF

actually when i dump the hex code into 89c51 ic this code is not working
and i am sure that there are no errors in the code when i
have created the hex code for the same above program in my friends system who uses
windows vista home premium it generates the following hex code:
:03000000020052A9
:0C005200787FE4F6D8FD758107020000FD
:100000007438112A740E112A7401112A7406112AE7
:100010007480112A758920758DFD759850D28E30A7
:1000200098FDE5991137C29880F51144F580C29585
:10003000C296D297C297221144F580D295C296D229
:1000400097C29722D287C295D296C297D29720871D
:02005000F92293
:00000001FF
this hex code works fine in 89c51 ic and i get the output tooo
so whats the problem sir

0