You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to use debugbreak.h in a "SEGGER Embedded Studio for ARM (Nordic Edition)" project, built using the NRF Connect SDK (NCS), which ultimately uses the arm-none-eabi gcc toolchain. I happen to be targeting an nRF9160.
It built, but the resulting code was considered an "invalid opcode" and would cause a hard-fault if executed. So while the debugger would be triggered, there was no useful program counter, stack frame or other debuggable information.
I believe the path that gets built in that environment is this one:
It looks like this may be useful on other platforms too. I don't know why the environment detection in debugbreak didn't work in the first place, so I'm not sure how you'd merge it. But if you're interested, I can do some experimentation to help you figure it out.
The text was updated successfully, but these errors were encountered:
I tried to use
debugbreak.h
in a "SEGGER Embedded Studio for ARM (Nordic Edition)" project, built using the NRF Connect SDK (NCS), which ultimately uses thearm-none-eabi
gcc toolchain. I happen to be targeting an nRF9160.It built, but the resulting code was considered an "invalid opcode" and would cause a hard-fault if executed. So while the debugger would be triggered, there was no useful program counter, stack frame or other debuggable information.
I believe the path that gets built in that environment is this one:
In the end, this alternate did work. I derived it from some other mysterious Nordic library, where it is referred to as
NRF_BREAKPOINT
:It looks like this may be useful on other platforms too. I don't know why the environment detection in
debugbreak
didn't work in the first place, so I'm not sure how you'd merge it. But if you're interested, I can do some experimentation to help you figure it out.The text was updated successfully, but these errors were encountered: