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.

TMS570 DK flashing issue

Other Parts Discussed in Thread: UNIFLASH, HALCOGEN

Hi there!
 I'm trying to flash a TMS570 DK but suddenly, the flashing do not works how it should... I tryed to find some solution, but I only found out discontinued discutions...

Actually I tried with more than one tools to flash. The answers are:

CCS UniFlash:

[17:09:18] Start operations on multiple programs on the target core...
[17:09:18] Loading program: C:\workspace\W5\p2\Debug\p2.out
[17:09:18] WARNING >> CortexR4: Loader: One or more sections of your program falls into a memory region that is not writable.  These regions will not actually be written to the target.  Check your linker configuration and/or memory map.
[17:09:24] ERROR >> CortexR4: File Loader: Data verification failed at address 0x00000000 Please verify target memory and memory map.
[17:09:24] ERROR >> CortexR4: GEL: File: C:\workspace\W5\p2\Debug\p2.out: a data verification error occurred, file load failed.
[17:09:25] File: C:\workspace\W5\p2\Debug\p2.out: a data verification error occurred, file load failed.
[17:09:25] Programs operation finished.

CCSv5.5.0:

CortexR4: GEL Output:     Memory Map Setup for Flash @ Address 0x0CortexR4: Loader: One or more sections of your program falls into a memory region that is not writable.  These regions will not actually be written to the target.  Check your linker configuration and/or memory map.


I only want to mention that until today all worked fine.

2234.1.zip

I also added the *.gel files and the sys_link.cmd file. I saw that is useful... :)


I would like to specify that in CSS (v4, v5, v6) on the flashing tab (in Debug) I have no AutomaticECC nor something else...

Thanks in advance. Mihai.

  • Also, I will add a log file that I understand it is helpful. It is the CCS log file from Debug Server Log. I still have no idea why I can not flash the target...

    5037.CCS5.log

  • Mihai,

    I'm looking in to your case, can you also pls post your .map file as well as the .out file that you are trying to flash.

    I believe you are attempting to erase the flash before programming, can you pls try doing an erase only (no programming) and let us know if you are able to successfully erase the part ?

  • Hi,
    I'm sending here the whole workspace in whitch I build from the scratch two projects with HALCoGen v. 04.01.00 (to which I sent attached a screen capture). I added only the code from blinky example, so it is a quite easy project, which not involve anything special. The tool I used is CSS4. I also attached the message from CCS UniFlash 3.1.0 from the erasing attempt, the configuration file (t1.ccxml) and the log file.

    Thanks!

    3583.W4.zip

  • Hi,

    I did try your project from my side and it successfully connected, erased  and programmed as well.

    I'm using CCSV6 on the same target.

    Do you remember what was the last code that successfully got programmed on to this device ? Is there any code already running in this device ?

  • I was trying to move some code from Keil uVision project, Blinky. And I tried to move the assemble code also, because there was two asm functions. When you have to initialize the EMIF part, there are 2 asm functions that are used. I think that the problem actually started then. I will send you the code in a attachment...

    void MPU_setRegion (unsigned int region,unsigned int base_addr, unsigned int access, unsigned int size) {
    	asm("MCR p15, #0, r0, c6, c2, #0");
    	asm("MCR p15, #0, r1, c6, c1, #0");
    	asm("MCR p15, #0, r2, c6, c1, #4");
    	asm("MCR p15, #0, r3, c6, c1, #2");
    	asm("BX  lr");
    }
    
    void MPU_enable(void) {
    	asm("MRC p15, #0, r1, c1, c0, #0");
    	asm("ORR r1, r1, #0x1");
    	asm("DMB");
    	asm("MCR p15, #0, r1, c1, c0, #0");
    	asm("ISB");
    	asm("BX  lr");
    }
    

  • Mihai,

    I do not need the code for now, as I can already see what might be going wrong.

    There is a fair chance that the MPU was configured wrong, which restricts the CPU to access the required space for erasing/programming. No sooner the device is powered ON, the code in flash starts to execute the existing code which configures your MPU wrongly and restricts any further access.

    I'll suggest you the below workaround to test.

    Try to use uniflash and attempt erase. Before you hit the erase, press and hold Reset switch available on the board and once Uniflash attempts to communicate to the device, try removing the reset. you can make a few tries by removing the reset at different time intervals. This is to make sure the tool connects and halts the target using the debug interface before the MPU configuration code is executed.

    Let me know if this works ?