ARM Technical Support Knowledge Articles


Applies to: C51 C Compiler


Information in this article applies to:


I want to use Philips 87C528 microcontrollers which have 512 Bytes of Internal RAM inside. However, the linker only lets me specify an internal RAMSIZE of 256 bytes. Is there any way to change this limit?


The 8xC528 and numerous other Philips derivatives provide more than 256 bytes of on-chip memory. The problem is that this memory is not all DATA memory. In most cases it is configured as 256 bytes of DATA memory and the remainder is XDATA memory.

So, you must set linker's RAMSIZE directive to 256. The rest of the memory available on the chip will be in XDATA.

The reason you can't set the RAMSIZE to be larger than 256 is that the 8051 instructions that address internal memory only allow an 8-bit address. Therefore, the maximum size of internal memory is 256 bytes. And, that's what the 528 offers.

The additional 256 bytes of memory is accessed using the MOVX instruction. To use that memory in C, declare your variables with the XDATA memory specifier. Then, everything will work fine.


Article last edited on: 2006-10-24 09:48:56

Rate this article

Disagree? Move your mouse over the bar and click

Did you find this article helpful? Yes No

How can we improve this article?

Link to this article
Copyright © 2011 ARM Limited. All rights reserved. External (Open), Non-Confidential