|ARM Technical Support Knowledge Articles|
Applies to: C51 C Compiler
Information in this article applies to:
If you set XDATALEN in the STARTUP.A51 file to anything over FF00H, a warning is generated when an attempt is made to assemble the file. How do I fix this?
Also, how do you initialize location FFFFH in XDATA?
The warning indicates that a value is being truncated, and can easily be fixed. Remove the following section from the STARTUP.A51 file:
IF (LOW (XDATALEN)) <> 0 MOV R6,#(HIGH XDATALEN) +1 ELSE MOV R6,#HIGH (XDATALEN) ENDIF
and replace it with:
IF (LOW (XDATALEN)) <> 0 MOV R6,#LOW ((HIGH XDATALEN) +1) ELSE MOV R6,#HIGH (XDATALEN) ENDIF
It is not possible to initialize location FFFFH in XDATA. In order to do that, you would have to specify an XDATALEN of 10000H which is a 17-bit value. You can modify the STARTUP.A51 file yourself to workaround this problem, or you may initialize that particular location explicitly, either in the STARTUP.A51 file or in your project.
Article last edited on: 2005-07-15 13:15:38
Did you find this article helpful? Yes No
How can we improve this article?