EmbDev.net

Forum: ARM programming with GCC/GNU tools Problem of debugging without flash


Author: XuFangbo (Guest)
Posted on:

Rate this post
0 useful
not useful
Hi

Thanks in advance for reading my post.

I am doing a project with a platform without any flash memory. This 
platform has the AM3517 processor. Before using this platform, I 
simulate it in craneboard. What I did is that I locate all sections to 
ram, Here is my linker scriptfile.

/*********************************************************************** 
********
**
** Sample linker definition file for NP30.
**
************************************************************************ 
********
*/

EXTERN(_start)

ENTRY(_start)


MEMORY
{
   vectors   : org = 0x4020ffc4,   len = 0x003C
   intram    : org = 0x40200040,   len = 0x3800
   sdram     : org = 0x80000000,   len = 0x100000

}

SECTIONS
{
   .boot             : { __BOOT_START = .; *(.boot) __BOOT_END = .; . = 
ALIGN( 4 ); }> vectors

   .startup          : { __BOOT_START = .; *(.boot) __BOOT_END = .; . = 
ALIGN( 4 ); } > intram

   .text             : { __TEXT_START = .; *(.text) __TEXT_END = .; . = 
ALIGN( 4 ); } > sdram

   .rdata            : { __RDATA_START = .; *(.rodata) *(.rodata.str1.2) 
*(.rodata.str1.4) *(.rdata_4) *(.rdata_2) *(.rdata_1) __RDATA_END = .; . 
= ALIGN( 4 ); } > sdram

   .data             : { __DATA_START = .; *(.data_4) *(.data_2) 
*(.data_1) *(.data) __DATA_END = .; . = ALIGN( 4 ); } > sdram

   .bss    (NOLOAD)  : { __BSS_START = .; *(.bss_4) *(.bss_2) *(.bss_1) 
*(.bss) *(COMMON) __BSS_END = .; . = ALIGN( 16384 ); } > sdram

   .mmutable (NOLOAD): { __MMUTABLE_END = .; . += 0x4000; 
__MMUTABLE_START = .; . = ALIGN( 16384 ); } > sdram

   .sysstack         : { __SYSSTACK_END = .; . += 0x200; 
__SYSSTACK_START = .; . = ALIGN( 4 ); } > intram

   .irqstack         : { __IRQSTACK_END = .; . += 0xE0; __IRQSTACK_START 
= .; . = ALIGN( 4 ); } > intram

   .fiqstack         : { __FIQSTACK_END = .; . += 0x80; __FIQSTACK_START 
= .; . = ALIGN( 4 ); } > intram

   .abtstack         : { __ABTSTACK_END = .; . += 0x80; __ABTSTACK_START 
= .; . = ALIGN( 4 ); } > intram

   .svcstack         : { __SVCSTACK_END = .; . += 0x80; __SVCSTACK_START 
= .; . = ALIGN( 4 ); } > intram

   .undstack         : { __UNDSTACK_END = .; . += 0x80; __UNDSTACK_START 
= .; . = ALIGN( 4 ); } > intram

}


However, in the map file, I found that section 
.debug_*,.comment,.attributes are still located to the address which 
starts with 0x00000000, and this is the address where the flash is 
mapped. I add three lines in order to relocate these sections:

   .comment              : { *(.comment) ; . = ALIGN( 4 ); } > sdram

   .attributes     : { *(.ARM.attributes) ; . = ALIGN( 4 ); } > sdram

   .debug                : { *(.debug*) ; . = ALIGN( 4 ); } > sdram

and I Checked the .out file using "file" command, it says "Reading 
symbols from XXX.out, <no debugging symbols found>....done".


Can someone help me? Thanks

Reply

Entering an e-mail address is optional. If you want to receive reply notifications by e-mail, please log in.

Rules — please read before posting

  • Post long source code as attachment, not in the text
  • Posting advertisements is forbidden.

Formatting options

  • [c]C code[/c]
  • [avrasm]AVR assembler code[/avrasm]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]




Bild automatisch verkleinern, falls nötig
Note: the original post is older than 6 months. Please don't ask any new questions in this thread, but start a new one.