At certain points in the code a call to a known good subroutine jumps into a .word disassembly and fails to execute

I have a subroutine that exercises the SPI interface and only at certain points in the code it won't execute the SPI subroutine and goes into the disassembly when single stepping to see what's going wrong. I presume it has something to do with the memory management, but I have not been able to fix it by playing around with those settings. 

Parents
  • Hello,

    Looking at your screenshot, there are some hints that suggests that you are using the Softdevice (Bluetooth Low Energy stack), is that correct?

    Do I understand you correct if you say that this only happens when you start stepping in a debug session? If that is the case, then this is caused because you can't do stepping while the softdevice is enabled*

    *You can, and you can use it to debug, but when you stop the execution, the Softdevice will not handle this very well. You can typically do some steps before the Softdevice realizes that it has missed several time critical operations, and then it stops the application. Is that what you are seeing?

    If that is the case, perhaps we can rather look into the problem that you had, that made you start trying to step through the code? Can you elaborate on that?

    Best regards,

    Edvin

Reply
  • Hello,

    Looking at your screenshot, there are some hints that suggests that you are using the Softdevice (Bluetooth Low Energy stack), is that correct?

    Do I understand you correct if you say that this only happens when you start stepping in a debug session? If that is the case, then this is caused because you can't do stepping while the softdevice is enabled*

    *You can, and you can use it to debug, but when you stop the execution, the Softdevice will not handle this very well. You can typically do some steps before the Softdevice realizes that it has missed several time critical operations, and then it stops the application. Is that what you are seeing?

    If that is the case, perhaps we can rather look into the problem that you had, that made you start trying to step through the code? Can you elaborate on that?

    Best regards,

    Edvin

Children
No Data
Related