??? 05/31/04 13:58 Read: times |
#71501 - RE: How can I do MOVX in C? Responding to: ???'s previous message |
You can access very easily the external memory by using the XBYTE , as some one has already suggested, but here i have given the detail,
when using XBYTE, there must be the declaration of header file as following on the top of C program. #include <ABSACC.H> after that you can use XBYTE as below. XBYTE [0x8001] = 0xFF ; to write at external address P1 = XBYTE [0x5001] ; to read from external address the above statements will produce the following code by using keil compiler, ------------------------------------------------------ ; XBYTE [0x8001] = 0xFF ; MOV DPTR,#08001H MOV A,#0FFH MOVX @DPTR,A ; P1 = XBYTE [0x5001] ; MOV DPTR,#05001H MOVX A,@DPTR MOV P1,A ----------------------------------------------------- thanks |
Topic | Author | Date |
How can I do MOVX in C? | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
use pointers | 01/01/70 00:00 | |
RE: use pointers - VERY CAREFULLY! | 01/01/70 00:00 | |
RE: use pointers | 01/01/70 00:00 | |
RE: use pointers | 01/01/70 00:00 | |
It all depends on the compiler... | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
What C? | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
RE: How can I do MOVX in C? | 01/01/70 00:00 | |
Thanks | 01/01/70 00:00 | |
RE: Keil | 01/01/70 00:00 | |
RE: How can I do MOVX in C?![]() | 01/01/70 00:00 |