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.

Emulator connection terminated with random error message in F28335 project

Other Parts Discussed in Thread: TMS320F28335, TMS320F28069, CONTROLSUITE

Hi,

I'm running a TMS320F28335 on a custom board as part of an inverter. The software is a non-bios project (which was adapted from an older F2812-project) and runs fine. But I've got a serious debugging problem, which is as follows: The DSP is loaded with code (everything in internal or external RAM) and run in real-time mode. Everything is ok so far. As I want to check some variables I use the watch window and a breakpoint in main, which is configured to update all windows.
1) If the breakpoint is enabled and I activate the PWM-outputs (which is done via custom hardware and GPIOs), I get one of the following error messages (no guarantee for completion) and most of the time the connection from Code Composer Studio 3.3 to the F28335 breaks down. Sometimes also main() is stopped.
The  error messages:
 

Failed to remove the debug state from the target before disconnecting. There may still be breakpoint opcodes embedded in program memory. It is recommended that you reset the emulator before you connect and reload your program before you continue debugging.

Error: Error 0x20000024/-1156 Severe Error during: Register, Execution, Lost processor clock. Device may be operating in a low-power mode. Do you want to bring it out of this mode?

Can't Run Target CPU: Error 0x80000022/-1041 Fatal Error during: Memory, Execution, Device driver: Problem with the Emulation Controller. It is recommended to RESET EMULATOR. This will disconnect each target from the emulator. The targets should then be power cycled or hard reset followed by an emureset and reconnect to each target.

Error: Error 0x20000020/-2064 Severe Error during: Execution, Cannot read processor status.

Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-2042 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

Can't Run Target CPU: Error 0x20001020/-1135 Severe Error during: Execution, Target, Unrecoverable emulation error

Trouble Reading PC Register: Error 0x00000004/-1137 Error during: Register, It appears that the target is being held in reset. This may be due to Wait-In-Reset (WIR) configuration set by the EMU0=0 and EMU1=1 pin settings. If this is the case, DISCONNECT all CONNECTED devices including icepick and then select RETRY to clear the WIR configuration. If this is a multi-core system, the master CPU may not be releasing the DSP/MCU from reset. Please check your configuration in CC_setup and/or your GEL file to ensure that nothing is blocking the DSP/MCU from being released from reset

Error: Error 0xA0001020/-1041 Error during: Execution, Target, Device driver: Problem with the Emulation Controller. It is recommended to RESET EMULATOR. This will disconnect each target from the emulator. The targets should then be power cycled or hard reset followed by an emureset and reconnect to each target.

Can't Run Target CPU: Error 0x00000022/-1156 Error during: Memory, Execution, Lost processor clock. Device may be operating in a low-power mode. Do you want to bring it out of this mode?

Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-1066 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

Can't Run Target CPU: Error 0x00000028/-1066 Error during: Break Point, Execution, Cannot set/verify breakpoint at 0x0000E103

Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-1066 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

Can't Run Target CPU: Error 0x00000020/-2134 Error during: Execution, Execution error.



2) If I deactivate the breakpoint and start the PWM, it seems that everything works fine (at least the interrupts work), but I fear that main might be stopped as well at some point after I activated the PWM-outputs. After the start of the PWM it's possible to activate the breakpoint without termination the connection instantly, though it definitely happens after some time (seconds ... minutes). 

The debugger is a Spectrum Digital XDS510pp Plus (DC-decoupled via the Spectrum Digital SPI110LV)...

As I couldn't find any information about those error messages, I though somebody here might have a hint or an idea how to solve this.

 

Thanks

  • Hello,

    I am having an almost identical issue using CCS4 and the TMS320F28335.  So far, TI has not had any ideas about this.

    Have you had any luck in resolving this issue?  I would love to know what, if anything, you figured out....  Please respond  via email at this address additionally if you can.

    cyril@moogmusic.com

     

    Thanks

     

     

     

    JoeHu said:

    Hi,

    I'm running a TMS320F28335 on a custom board as part of an inverter. The software is a non-bios project (which was adapted from an older F2812-project) and runs fine. But I've got a serious debugging problem, which is as follows: The DSP is loaded with code (everything in internal or external RAM) and run in real-time mode. Everything is ok so far. As I want to check some variables I use the watch window and a breakpoint in main, which is configured to update all windows.
    1) If the breakpoint is enabled and I activate the PWM-outputs (which is done via custom hardware and GPIOs), I get one of the following error messages (no guarantee for completion) and most of the time the connection from Code Composer Studio 3.3 to the F28335 breaks down. Sometimes also main() is stopped.
    The  error messages:
     

    Failed to remove the debug state from the target before disconnecting. There may still be breakpoint opcodes embedded in program memory. It is recommended that you reset the emulator before you connect and reload your program before you continue debugging.

    Error: Error 0x20000024/-1156 Severe Error during: Register, Execution, Lost processor clock. Device may be operating in a low-power mode. Do you want to bring it out of this mode?

    Can't Run Target CPU: Error 0x80000022/-1041 Fatal Error during: Memory, Execution, Device driver: Problem with the Emulation Controller. It is recommended to RESET EMULATOR. This will disconnect each target from the emulator. The targets should then be power cycled or hard reset followed by an emureset and reconnect to each target.

    Error: Error 0x20000020/-2064 Severe Error during: Execution, Cannot read processor status.

    Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-2042 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

    Can't Run Target CPU: Error 0x20001020/-1135 Severe Error during: Execution, Target, Unrecoverable emulation error

    Trouble Reading PC Register: Error 0x00000004/-1137 Error during: Register, It appears that the target is being held in reset. This may be due to Wait-In-Reset (WIR) configuration set by the EMU0=0 and EMU1=1 pin settings. If this is the case, DISCONNECT all CONNECTED devices including icepick and then select RETRY to clear the WIR configuration. If this is a multi-core system, the master CPU may not be releasing the DSP/MCU from reset. Please check your configuration in CC_setup and/or your GEL file to ensure that nothing is blocking the DSP/MCU from being released from reset

    Error: Error 0xA0001020/-1041 Error during: Execution, Target, Device driver: Problem with the Emulation Controller. It is recommended to RESET EMULATOR. This will disconnect each target from the emulator. The targets should then be power cycled or hard reset followed by an emureset and reconnect to each target.

    Can't Run Target CPU: Error 0x00000022/-1156 Error during: Memory, Execution, Lost processor clock. Device may be operating in a low-power mode. Do you want to bring it out of this mode?

    Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-1066 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

    Can't Run Target CPU: Error 0x00000028/-1066 Error during: Break Point, Execution, Cannot set/verify breakpoint at 0x0000E103

    Trouble Removing Breakpoint with the Action "Update All Windows" at 0xe103: Error 0x00000008/-1066 Error during: Break Point, Cannot set/verify breakpoint at 0x0000E103

    Can't Run Target CPU: Error 0x00000020/-2134 Error during: Execution, Execution error.



    2) If I deactivate the breakpoint and start the PWM, it seems that everything works fine (at least the interrupts work), but I fear that main might be stopped as well at some point after I activated the PWM-outputs. After the start of the PWM it's possible to activate the breakpoint without termination the connection instantly, though it definitely happens after some time (seconds ... minutes). 

    The debugger is a Spectrum Digital XDS510pp Plus (DC-decoupled via the Spectrum Digital SPI110LV)...

    As I couldn't find any information about those error messages, I though somebody here might have a hint or an idea how to solve this.

     

    Thanks

  • I'm sorry, but I haven't been able to resolve this issue yet.

  • The 2833x family has what is called emulation security logic.  This will kill the JTAG port if you try to step through secure code.  Is it possible that the CSM is locked and you have stopped in secure memory when this occurs? 

  • Hallo Lori,

    the breakpoint which should interrupt the program is located within a while(1)-loop in main(). main() is located in RAML6 (non secure L6 SARAM - 0xE000 ). CSM has never been activated. So I guess we'll have to look for something else.... Anyhow, thank you for the answer.

    Regards

    Johannes

  • Hi,

     I have similar issues with my system as well using the PWM's on the '334. I'm curious to know which emulator pod you are using as I've been told by Ti that the problem is with my pod. I have trouble believing it's the pod since the same pod works fine with my '2407 and '2808 projects.

     One thing I found that would seem to point to a software issue with CC or the emulator drivers (and NOT my pod) is when I get the error messages and resulting crash, I close CC, wait a few seconds, then restart CC everything seems to run fine. I sometimes need to do this 2 or 3 times, then everything runs fine for many many hours.

    Hopefully if enough people pipe up about this issue Ti will take some action to try to find and correct the problem. It's more of a nuisance now that I know the "work around" by closing and restarting CC.

    Regards,
    Bob

     

     

  • Same issue here.

    Tried both XDS510LC emulator and on-board eZDSP 28335 (Spectrum Digital) with same effect.

  • Anyone at Ti care to address this problem?

  • To JoeHu:

    Here are my thoughts:

    If I understand your post correctly, then you use a custom board, you place a breakpoint in you main code and then you enable the PWM outputs by setting some GPIO lines. So what happens to your PWMs when the breakpoin gets hit? I guess they will be frozen, because there is no more code executed to modify width and/or period. In best case the last PWM pattern is repeated as long as you do not resume the execution. I do not know the hardware of the PWM part of your custom board, but could it be, that the board consumes too much current in this breakpoint situation? This could cause the breakdown of the power supply both for the DSP and the JTAG system.

    I personally would never use breakpoints in a PWM power switching system. What I would do is use the realtime emulation system in polite mode. This allows you to monitor certain variables, memory locations etc. without halting or delaying any realtime related modules (code, PWMs,etc. ).  In this test scenario there is no stress for power output lines, the current consumtion is identical.

    Hope this helps

    Regards

     

  • Hi Frank,

     I think you missed the problem. The problem is the emulator crashes/disconnects. It certainly looks like a driver issue, because in my instance, if I close/reload the CCS application, everthing MAY run fine for a while. Sometimes it requires multiple close/restarts of CCS before it will work for a while without crashing/disconnecting.

    Thanks,

    Bob

  • Hi to all,

    I also have some issues with disconnecting emulator from target. Problem dissappear when I shielded cable behind emulator and target board.

     

    Tomas

  • Hi Tomas,

     Can you please provide more detail on how you shielded the cable? It's not clear what you mean by behind emulator and target board. This is a real problem for me and I would like to get it corrected as I waste a lot of time closing and restarting CCS when it crashes.

    Thanks,

    Bob

  • Hi Bob,

    I have one XDS100v1 class emulator build by my own, this emulator is connected to target board (eZdsp28F12 kit) by flat 14-wire cable. When this cable was unshielded, then CCS disconnect from kit very often in random manner. I decide to cover cable with copper tape, then disconnecting disappear. Copper tape is grounded on emulator side.

  • Hi!

    I am working with the kit edzTMSF28335 and with the example FOC sensorless

    I am having a similar error message :

    Trouble Writing Memory Block at 0xc013 on Page 1 of Length 0x1:
    Error 0x00000002/-1142
    Error during: Memory,
    Processor blocked debug accesses. An operation was attempted while
    the CPU was in a non-debuggable context. To continue to honor the debug
    context, press Cancel. To force debug access, press Rude Retry.

    This is in the debug sesion, when I try to change a variable from watch window.

    You said something of the emulation security logic, how can I unlock the emulator?

  • Lori,

    I got the similar problem. I use eZDSP28335 and CCS5.5 for my development. My firmware might have bugs. After I downloaded it to the eZDSP28335 board at the first time, it can run, but with problem. When I try to download the code second time , I got the error message

    Error connecting to the target: Error 0x80000206/-1156 Fatal Error during: Memory, Register, OCS, Lost processor clock. Device may be operating in a low-power mode.  Do you want to bring it out of this mode?

    Then it repeats again and again even I closed CCS and reset the emulator with SdConfigEx. Does anyone have the solution for it?

    By the way, is there any way I can erase the program on flash memory inside the DSP?

    Regards,

    Yaoxin Qian 

  • Hi everyone,

    I use TMS320F28069 Evaluation kit, just purchased it, I try to run the FlashLed example following the instructions from System Framework Overview Guide, and setting the right MCU in the settings but I got the following error:

    Error enabling realtime mode: Error 0x00000020/-2134

    I have installed the evaluation version of CCS v4.2.1.00004

    I really don't understand why I got this problem on a brand new Eval kit....

    Any suggestions?

    Thanks

    Risto

  • Hello Risto,

    I suggest you to install CCSv5 (5.4 or 5.4) because many people can help you more with the latest CCS.

    And download the latest controlSuite (If you have not had it yet).

    Try to run the example from this controlSuite to your board.

    Good luck!

    Best regards,

    Maria

  • Hi Maria,

    I have installed the new CCS and control suite and everything is working properly now. I did this yesterday, sorry didnt have time to post that the problem is solved.

    Thank you very much for your help.

    Best regards,

    Risto

  • Hi,


    Same errors here.

    "Severe Error during: Register, Execution, Unrecoverable emulation error." and lots of different random errors while connection, flashing and handling brakepoints. Sometimes it runs fine but most of the time it keeps failing and suggesting to reset my target and reset the JTAG. Sometimes I manage to get it working by first single-step through my code, until somewhere in main and then it MAY keep working for a while.


    My board is nothing, its an in-house made development board with all GPIO made available on header boxes. JTAG stuff like TCK_Return is placed a centimeter from the CPU pins. I've reduced the JTAG clock to 1MHz in the spectrum digital config tool, but it keeps failing. I don't believe it's an target issue, I think it's an driver issue or something in CCS5 not handling well.

    Realtime mode or normal debug mode doesn't make a difference.

    Is there already a solution available, before I start throwing things out of my window?

  • Tjarco,

    This sounds like a JTAG or (less likely) a reset issue.

    Can you upload the JTAG part of your design? Specifically I'll be looking at things like whether a pull-down is placed on TRSTn and if so what value, etc.

    Also what device are you using?

    In general, it's best to start a new E2E thread on new issues because often posts made to closed items tend to not be seen by as many eyes.


    Thank you,
    Brett

  • Hi Bret,

    Well it was in fact the 1V8 core regulator dropping below 1V5 after enabling and initializing more and more code modules. Measurements in reset state were fine (1V8) but misleading.

    So the JTAG resets were caused by a power failure.

    I had copied a design for F2808 to a new F28334 project, but the last one draws higher currents ;)

    Best regards,

    Tjarco