Hi
I have a problem with the emulation through
Code Composer Studio. So, far I have used the simulator when developing my
software for the TMS320VC5510 DSP. Now I want to emulate to eliminate the last
few bugs that I have in my program. I use the XDS510PP Plus emulator, and it
seems to work ok against the DSP on our hardware.
The loading of my program is not correct.
Writing to the registers in io-space does not work, this actually changes the
same address in data memory.
I think the problem is that I have to specify a
memory map to CCS. This was not necessary in the simulator. I have made a
gel-file which corresponds to my memory settings in my project linker command
file, but I get an error message when loading the program.
Error message:
Load failed. A section of your program falls
into a memory region that is not writable. Check your linker configuration
and/or memory map
The error comes when CCS tries to load the
.const section, but it also seems to give the same error on the .cinit section.
I also get the same error message when using the same gel-file in the
simulator.
I have made all memory writable in the
gel-file. So, I do not understand why I get this message.
My linker command file:
MEMORY
{ PAGE 0: MMR (RW) : origin = 0000000h, length = 00000c0h/* Memory mapped registers */ MBOX (RW) : origin = 00000C0h, length = 0000100h/* Message boxes DSP and SA */ DARAM0 (RWI): origin = 00001C0h, length = 0003E40h /* Variable space */ FFT (RW) : origin = 0004000h, length = 0004004h /* FFT data here */ DARAM1 (RW) : origin = 0008004h, length = 0007FFCh /* Time series space */ SARAM0 (RWIX): origin = 0010000h, length = 0008900h /* Program code space */ VECS
(RWIX) : origin = 0018900h, length = 100h /* Interrupt vector
table space */
SARAM1 (RW) : origin = 0018A00h, length = 0037600h /* Time series
space */
PDROM (X) : origin = 0ff8000h, length = 07f00h /* On-chip ROM
*/
PAGE 1: IOSPACE (RW): origin = 00000h, length = 20000h /* Io space */ } SECTIONS { .mboxes : {} > MBOX PAGE 0 /* Messages DSP-SA placed here */ .outdata : {} > DARAM0 PAGE 0 .bss : {} > DARAM0 PAGE 0 /* Uninitialized data section */ .stack : {} > DARAM0 PAGE 0 /* Stack sections */ .sysstack : {} > DARAM0 PAGE 0 .sysmem : {} > DARAM0 PAGE 0 .data : {} > DARAM0 PAGE 0 .fftdata : {} > FFT PAGE 0, align(2048) /* Data for FFT/IFFT here */ .samples1 : {} > DARAM1 PAGE 0 /* First time series samples here */ .text :
{ H_Startup.obj (.text)
mac32.obj(.text) fir2s4.obj(.text) firadjust.obj(.text) prepare.obj(.text) A_Processing.obj(.text) A_ProcessingOpt.obj(.text) *(.text)} > SARAM0 PAGE 0 /* Code section */ .const : {} > SARAM0 PAGE 0 /* Constant section */ .cinit : {} > SARAM0 PAGE 0 /* Initialisation section */ .switch : {} > SARAM0 PAGE 0 .vectors : {} > VECS PAGE 0, align(256) .samples2 : {} > SARAM1 PAGE 0 /* Time series samples here */ } My gel_file with memory map
setting:
StartUp()
{ C5510_Mem_Map_Init(); GEL_TextOut("C5510 GEL StartUp Complete.\n"); } hotmenu C5510_Mem_Map_Init()
{ GEL_MapOn(); GEL_MapReset(); GEL_MapAdd(0x000000,1,0x000060,1,1); /* DARAM0 -
MMR regs */
GEL_MapAdd(0x000060,1,0x007FA0,1,1); /* DARAM0 - Data space */ GEL_MapAdd(0x010000,0,0x008900,1,1); /* SARAM0 - Program space */ GEL_MapAdd(0x018900,0,0x000100,1,1); /* SARAM0 - Interrupt vectors */ GEL_MapAdd(0x00C500,1,0x01BB00,1,1); /* SARAM1 - Data space */ GEL_MapAdd(0x000000,2,0x3C00,1,1); /* IO
space */
} Best regards
Torgeir Jakobsen Senior Engineer, Technology Department Aanderaa Instruments AS e-mail: t...@aanderaa.no web: www.aanderaa.com phone; +47 55 10 99 00 direct: +47 55 10 99 77 fax: +47 55 10 99 10 -- This e-mail has been protected by Song Networks' virus-scan service: http://www.securemail.no |
CCS memory map setting
Started by ●September 11, 2003