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.

Debugger Core Group Does Not Reset CPU2



Hello,

I'm using F2837xD controlCARD and on-board XDS100v2 debugger.

With 'Group1' selected I click Suspend which works fine then CPU Reset, which does not work without error:

If I click on CPU2 then reset, it does not complain.

Is there a reason a group reset doesn't work please?

Thank you.

  • Hello,

    The interesting thing is that both cores look like they did get reset, despite the error. I tested this out by adding a GEL_TextOut call in the OnReset() GEL function for each core.

    Then when I grouped the cores and issued a group reset, I got:

    So both cores did get reset with a single group reset. Looking at the OnReset() call for each core, there is a lot of device initialization done. What I suspect is that when a reset attempted by both cores at the same time, there is some kind of conflict. 

    I will bring this thread to the device experts for clarification.

    Thanks

    ki 

  • Thanks Ki.

    The reason I'm suspicious that reset is not happening correctly in CPU2 is that the bootstrap code that initialises my global variables does not seem to be executed correctly after a Reset. Maybe I'm conflating two separate problems, not sure.

    I have second counters in each CPU. I Suspend the core Group 1 and each counter has 6 seconds:

    CPU1:

    CPU2:

    When I Restart the program, the globals are initialised:

    CPU1:

    CPU2:

    This works repeatedly.

    However, if I execute a Reset (with error message) followed by a Restart then CPU2 globals are not initialised:

    CPU1:

    CPU2:

    Now the CPU2 program will have unintended behaviour because my program starts from main but global values are values from the previous run.

    The only way I have found to recover and initialise CPU2 globals is to power down the microprocessor.

  • Another reason I don't think all is well with CPU2 reset. If I select the following for both CPUs:

    CPU2 does not run to main() on Reset, only CPU1:

  • I will look at this on Monday and get back to you.

  • Kier,

    I have requested device Reset expert to look at it. We should be able to get back to you in day or two.

  • Kier,

    Please note that whenever you reset CPU1, CPU2 also get reset, This is done in hardware itself. So when you are grouping and resetting, the reset may be happening two times for CPU2. If CPU2 reset in hardware happens after the one issued from CCS then I think that reset will not take CPU2 execution to main() because it's been initiated by HW. 

    So in this case I'll suggest to avoid the group select instead just reset CPU1 and that will reset both CPU.

    Hope this help.

    Regards,

    Vivek Singh

  • Hi Vivek,

    Thank you, that seems to be plausible.

    If you're saying that Reset at the Group level never works correctly for CPU2 I think it would be a lot clearer to the end user if CCS disabled the CPU Reset button when the Group is selected, wouldn't you agree? If so, please approach the CCS devs.

    Certainly when I Reset with just CPU1 selected, the red warning no longer appears in the console window however it still doesn't run to main() as mentioned in this topic:

    https://e2e.ti.com/support/tools/code-composer-studio-group/ccs/f/code-composer-studio-forum/1085103/cpu2-does-not-run-to-main-on-reset

    If you can solve this for me to, I'd be very grateful.

  • I think Group is generic CCS menu item but will check with team.

    Certainly when I Reset with just CPU1 selected, the red warning no longer appears in the console window however it still doesn't run to main() as mentioned in this topic:

    I don't think on HW reset  but let me confirm this with our CCS team and get back to you If you restart, does it work ok ?

    Regards,

    Vivek Singh

  • Kier,

    This is under investigation. I will provide any updates as I received them

    Thanks

    ki

  • If you're saying that Reset at the Group level never works correctly for CPU2 I think it would be a lot clearer to the end user if CCS disabled the CPU Reset button when the Group is selected, wouldn't you agree? If so, please approach the CCS devs.

    I filed a bug for this. Tracking link: https://sir.ext.ti.com/jira/browse/EXT_EP-10763

    Thanks

    ki