I was just simulating my code in Keil. When I write to external memory, I don't see anything happen in the memory window. I am using cypress FX2 as the chip. Here's my code: Just writing FF to location E000h
MOV A, #0FFH MOV DPTR, #0E000H MOVX @DPTR, A
I don't see anything happen at 0E000h in the memory window.
Have you got memory mapped to a region encompassing that location?
Do you have to manually refresh the window?
Does the chip have SFRs, etc, that have to be properly configured to allow external memory access? If so, have you correctly configured them?
I don't see any option for refreshing the window. The EZUSB Tech ref manual says, you should be able to access these registers with a MOVX instruction.
I can't see the bytes being stored at Exxx memory location during simulation. But it does work. I just put some bytes at Exxx and loaded them to Accumulator. I do see the correct bytes in the Accumulator.
cypress FX2
I have a vague recollection (never used the FX2) that the FX2 does not have that much XRAM, try at e.g. address 0x200.
If, indeed, you have an external RAM attached to tha chip then the above works if you do not have a hardware problem
Erik
Erik,
FX2 has data RAM starting from E000h to FFFFh. That's where all the USB registers and End point registers are located.
X2 has data RAM starting from E000h to FFFFh. That's where all the USB registers and End point registers are located.
That's kinda self-contradictory. Either you have RAM there, or you have registers. But not both at the same time.
E000 to E1FF is data RAM. E200 to FFFF are USB registers with some reserved space.