We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi! I'm desperate! I have a ADuC824 with 4 MB of flash memory attached using the 824's feature of being able to access upto 16MB of external memory. I'm trying to use the flash as external memory. However I cannot get out of the 64K XDATA limit. Even using the examples and using far I cannot write/read more than 64K. What I need is a way of creating a pointer to 4MB of XDATA. If is use "char XDATA *BASE_ADDR" then I only get to use 64K and "far *BASE_ADDR" doesn't work. Can anyone help? All the best Andrew Manning
For accessing 16MB memory on the ADuC microcontroller series you need to enable the extended Linker LX51 when you select the device. This enables also the 'far' memory type at the compiler level. You should also check the folder: Keil\C51\EXAMPLES\FarMemory\16MB RAM on ADuC812 This example shows you how to access 16MB memory that is mapped in the extended xdata space of that device.
Hi! The example is fine but it doesn't show how to access the 16MB of memory. Ideally I'd like to create an array of 4MB but the following line:- char far ADDR[0x3FFFFF]; Gives the warning warning C219: Long constant truncated to int which I presume won't work. Any suggesstion please? All the best Andrew Manning
Due to the address arithmetic implemented on the 8051, far memory objects are limited to a maximum size of 64KB. However, take a look to the Philips 80C51MX application note that describes way to bypass the 64KB address limitation. Therefore refer to: http://www.keil.com/appnotes/docs/apnt_160.asp
Hi! How do I use the 'EXTERN' keyword? ATB