Debugging interrupt callback with MQX Lite crashes

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Debugging interrupt callback with MQX Lite crashes

Jump to solution
837 Views
davidsherman
Senior Contributor I

Not sure if this is specific to KDS, MQX-Lite, or OpenSDA, but if I stick a breakpoint inside an interrupt callback while debugging an MQX-Lite application in KDS using OpenSDA, it hits the breakpoint and crashes.  No continuing at that point, I can't examine variables or do much of anything.  If I remove the breakpoint, the callback works fine and does what it should.  This is on a FRDM-KE06 with KDS 1.0.1 beta.  KDS stays alive, but I have to stop the debugger and cycle power on the FRDM-KE06 to restart.

Labels (1)
0 Kudos
1 Solution
437 Views
BlackNight
NXP Employee
NXP Employee

Hi David,

not sure if your problem is the same thing what I was facing recently?

In my case the debugger was blocked in some cases while debugging an interrupt service routine.

The solution was to add

set backtrace limit 20

to the GDB options. this is described too in the KDS V1.1.0 release notes:

  • ENGR00316447, SO66: Breakpoints inside ISR: The debugger is sometimes confused when hitting a breakpoint inside an interrupt service routine / exception handler and produces a lot of memory reads and output, effectively blocking debug operation. The issue seems to be related to some assembly instructions (https://community.freescale.com/thread/327560)
    Workaround: Add
    set backtrace limit 20
    to the gdb list of 'Command' in the debug/launch configuration (the value of 20 is an arbitrary number, but should be a small number), see https://community.freescale.com/thread/327560.

Erich

View solution in original post

0 Kudos
3 Replies
438 Views
BlackNight
NXP Employee
NXP Employee

Hi David,

not sure if your problem is the same thing what I was facing recently?

In my case the debugger was blocked in some cases while debugging an interrupt service routine.

The solution was to add

set backtrace limit 20

to the GDB options. this is described too in the KDS V1.1.0 release notes:

  • ENGR00316447, SO66: Breakpoints inside ISR: The debugger is sometimes confused when hitting a breakpoint inside an interrupt service routine / exception handler and produces a lot of memory reads and output, effectively blocking debug operation. The issue seems to be related to some assembly instructions (https://community.freescale.com/thread/327560)
    Workaround: Add
    set backtrace limit 20
    to the gdb list of 'Command' in the debug/launch configuration (the value of 20 is an arbitrary number, but should be a small number), see https://community.freescale.com/thread/327560.

Erich

0 Kudos
437 Views
davidsherman
Senior Contributor I

Yes!  This seems to be the same problem.  I added that line to the debugger options, and this seems to fix it completely.  Much appreciated!

0 Kudos
437 Views
trytohelp
NXP Employee
NXP Employee

Hi David,

It seems the problem has been logged in Service request too under the 1-1596204421 number.

I will check with the owner of this SR.


Have a great day,
Pascal

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos