This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Loading TMS320VC5410A Memory Using A XDS510USB Emulator From CCSv4

Other Parts Discussed in Thread: TMS320VC5410A

Sir,

    Trying to load TMS320VC5410A memory from a XDS510USB emulator with the C5400 tutorial program "Hello World" in Code Composer Studio v4.

    Loads program ok in memory from 0x1400 upwards.

    But comes up with error:

                                                    "Error adding memory map range: End address is beyond target memory length"

                                                     "Trouble writing memory block at ff80 on Page 0 of length 0x64.

                                                      "Error 0x80000002/-1052. Fatal Error during: Memory."

    Seems it's unable to load the vectors reset code starting at 0xff80"

    I can see the loaded code using the dissaembly feature in Code Composer Studio v4. But the memory locations starting at 0xff80 are blank.

    The MC\MP pin is set LOW. Should it be set HIGH?

    Any ideas gratefully received,

               Mark Bowser

  • Hi Mark,

    You are right in using MP/MC = 0. However, 0xFF80 is mapped to onchip ROM and hence you cannot write to this location. You should place your vector table in onchip RAM and modify IPTR field in the PMST register after bootup.

    Please refer to section 3.1.7.1 in the VC5410A datasheet (sprs139i.pdf). I have also attached an example command linker file that reserves 0x7F80 with length 0x80 for vectors in onchip RAM. You can then use " .sect " directive before the vector table code to map your vector table to this section ex. "    .sect     "vectors" in the case of the attached example command linker file.

     

    Regards,

    Sunil Kamath

    /* '5410 */
    /* MP/MC = 0, OVLY = 1, DROM = 1 */
    MEMORY
    {
      PAGE 0:  /* program memory */
        DARAM0:  origin = 000080h, length = 00700h 
          STCK:  origin = 000780h, length = 00080h
        DARAM1:  origin = 000800h, length = 00800h
        DARAM2:  origin = 01000h, length = 00050h   
        DARAM3:  origin = 01050h, length = 00050h   
        DARAM4:  origin = 01100h, length = 00050h    
        DARAM5:  origin = 01150h, length = 00100h   
        DARAM6:  origin = 01250h, length = 00050h
        DARAM7:  origin = 01300h, length = 00100h
        DARAM8:  origin = 01400h, length = 00600h
        SARAM0:  origin = 002000h, length = 02000h
        SARAM1:  origin = 004000h, length = 02000h
        SARAM2:  origin = 006000h, length = 01000h 
          VECS:  origin = 007F80h, length = 00080h
          ROM0:  origin = 00C000h, length = 03F80h
        SARAM3:  origin = 018000h, length = 02000h
        SARAM4:  origin = 01A000h, length = 02000h
        SARAM5:  origin = 01C000h, length = 02000h
        SARAM6:  origin = 01E000h, length = 02000h
    
      PAGE 1:  /* data memory */
          MMRS:  origin = 00000h, length = 00060h
          SPAD:  origin = 00060h, length = 00020h
        DARAM0:  origin = 00080h, length = 00700h 
        DARAM1:  origin = 00800h, length = 00800h
        DARAM2:  origin = 01000h, length = 00050h   
        DARAM3:  origin = 01050h, length = 00050h   
        DARAM4:  origin = 01100h, length = 00050h    
        DARAM5:  origin = 01150h, length = 00100h   
        DARAM6:  origin = 01250h, length = 00050h
        DARAM7:  origin = 01300h, length = 00100h
        DARAM8:  origin = 01400h, length = 00600h
        SARAM0:  origin = 02000h, length = 02000h
        SARAM1:  origin = 04000h, length = 02000h
        SARAM2:  origin = 06000h, length = 01000h
        SARAM3:  origin = 08000h, length = 02000h
        SARAM4:  origin = 0A000h, length = 02000h
        SARAM5:  origin = 0C000h, length = 02000h
        SARAM6:  origin = 0E000h, length = 02000h
    }
    
    SECTIONS
    {
       vectors: > VECS   PAGE 0        /* note IPTR = 001000000 */
         .text: > SARAM0 PAGE 0 
         stack: > STCK   PAGE 0 
          .bss: > DARAM0 PAGE 0
       
    }
    

  • Hi Sumil,

          Thanks! Your suggestion worked about re-locating the memory. 

          However i still have an issue with it trying to load a memory location at 0x80001024: EXT_PC

          EXT_PC is probably External Program Counter

          This is clearly out of range of the internal TMS320VC5410A memory. It comes up with the error:

             C54xx: Error adding memory map range: End address is beyond target memory length

     

     

           C54xx: GEL Output: C5410A_Init Complete.

           C54xx: Trouble Writing Register EXT_PC: Error 0x80001024/-1052 Fatal Error during: Register, Execution, Target, Device drive:

          Any suggestions,

                 Thanks, Mark Bowser.