??? 03/13/04 08:10 Read: times |
#66630 - RE: I need help Responding to: ???'s previous message |
Hello,
I will show you how it work : (I put table after subroutine LookUp!) ACCESS_INDEX equ 864 ACCESS_COUNT equ 864 main: MOV R6, #HIGH(ACCESS_INDEX) ;R6=03 (hex) MOV R7, #LOW(ACCESS_INDEX) ;R7=60 (hex) ; ; Subruotine LOOKUP3: mov a, #low(table) ; A=8B (hex) add a, r7 ; A=EB (hex) mov dpl, a ; DPTR=00EB mov a, #high(table) ; A=03 addc a, r6 ; A=03 mov dph, a ; DPTR=03EB clr a ; A=00 movc A, @A+DPTR ; A=00 (hex)??? A(should)= 4B RET table: DB #04Bh Where is the error??? |
Topic | Author | Date |
C Programe for 8051 | 01/01/70 00:00 | |
Reading List | 01/01/70 00:00 | |
RE: Reading List | 01/01/70 00:00 | |
RE: C Programe for 8051 | 01/01/70 00:00 | |
Sorry for the new thread | 01/01/70 00:00 | |
I need help | 01/01/70 00:00 | |
Learning 'C' | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: C table lookup | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help | 01/01/70 00:00 | |
RE: I need help![]() | 01/01/70 00:00 |