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.

Can't Flash and debug past 0x2800

Well I'm dead in the water with CC4.  It seems like I can not flash and debug past 0x2800.  No Idea??  I'm using CCS4 version 4.1.2.00027 with a SDX510 USB from Spectrum Digital, programming and debugging a LM3S6918IQC50A2DD

Everything works fine until my code goes above 0x2800.  At that point I get the following errors:

Error: CORTEX_M3_0: Flash Programmer: Timed out while writing to Flash memory
Error: CORTEX_M3_0: Trouble Writing Memory Block at 0x0 on Page 0 of Length 0x2820 

If the length go below 0x2800 it works fine.  I looked at the gel files and all is correct.
0x2800 is 10,240K decimel, so it isn't past the 16K code limit, but have a license

At this point I can not program any more.
  • CCS experts can respond and provide feedback on this, but this is my thought process:

    I have seen this issue before with a XDS510 emulator, but I will ask a few questions to get some clarification:
    1. I believe that this is your own board. Is that correct? Have you tried testing this on a TI eval board like the one below using this emulator:
    http://focus.ti.com/docs/toolsw/folders/print/eks-lm3s6965.html

    2. I am not sure what’s available as far as debugging is concerned on your board, but is there a USB/FTDI interface to debug/program, like our Eval boards?

    3. If there is one, can you try programming a binary file via USB and the LM Flash programmer to help isolate the issue:
    http://focus.ti.com/docs/toolsw/folders/print/lmflashprogrammer.html

    4. Our evaluation boards can also be used as emulators to the final target board via JTAG. The lowest cost solution is:
    http://focus.ti.com/docs/toolsw/folders/print/ek-lm3s811.html

    5. Please see this wiki article on useful info about CCS and XDS510 emulator setup:
    http://processors.wiki.ti.com/index.php/Stellaris_support_in_CCS

  • Hi Scott,

    Please try updating to the latest version of CCS.  We have seen problems with older versions with some of our older parts.

    Let me know how this goes.

    -David

  • Looks like the problem has a solution.

    While debugging code, a While(1) loop was added after enabling a couple interupts.  The error came after compling with optimizations turned off, then starting a Program/Debug session.  Once the While(1) loop was removed, everything worked.  This didn't seem to affect meaningful While loops.

    Try to repeat error by:

    1.) Turn off optimizations

    2.) Enable a timer interrupt

    3.) Enable a UART interrupt

    4.) Add any code in the vector routine

    5.) Add While(1) after interupts are enabled

    6.) Add more code after While(1) loop

    7.)  Compile and launch a Program/Debug session to see error occur.

    8.) Remove While(1) and repeat steps to see error go away.

    Question:  Is there a complier setting for keeping dead code during a compile?