ARM Technical Support Knowledge Articles

IN-SYSTEM FLASH PROGRAMMING WITH ROM SIZE > 64KB

Applies to: C51 C Compiler

Answer


Information in this article applies to:


QUESTION

I want to write code for in-system Flash programming on a Dallas DS80C390 or DS80C400 device. I have been trying the example project that comes with C51: IN-SYSTEM FLASH PROGRAMMING (PART 2).

It works well in Code ROM Size Large: 64K program (configured under Project -> Options for Target -> Target). But when I change the Code Rom Size to Contiguous Mode: 512 KB or 16MB program", I get linker errors like:

*** ERROR L127: UNRESOLVED EXTERNAL SYMBOL
    SYMBOL:  _CODE_FLASHMEM_L_
    MODULE:  Srom.obj (SROM)

I want to use the internal 4kB SRAM of the device at 400000h for the Flash programming algorithm (stored in flash 0h - 80000h than copied to 400000h). Does the LX51 linker not support the contiguous mode with the SROM functionality?

ANSWER

The LX51 linker fully supports contiguous mode. However, you need to change all CODE_ references to ECODE_ since the memory class ECODE is used in the contiguous mode.

Another potential problem is that you should avoid far * pointer references since they generate calls to the C run-time library which may not be present at run time.

See the Attached Files section below to download an example demonstrating how to use the SROM memory classes for the Dallas DS80C400.

MORE INFORMATION

SEE ALSO

Article last edited on: 2005-07-15 10:10:29

Rate this article

[Bad]
|
|
[Good]
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