How to detect Debugging during runtime

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

How to detect Debugging during runtime

519件の閲覧回数
leg7911
Contributor II

Hi,
I wonder how to detect (from runtime code) if debug probe is attached / debugging have place.

Or from other side. I'm using semihost to put some debug info. However when I start the procesor w/o debuger, it stucks (i gues hard fault) - is it normal or I should change some settings?
If there was a way to detect, I could avoid debug "printf" when no probe is attached.

lpc11e35

ラベル(1)
0 件の賞賛
1 返信

428件の閲覧回数
lpcxpresso_supp
NXP Employee
NXP Employee

There is some background information on this at : How to detect if LPClink is attached ? 

If using MCUXpresso IDE, then for SDK based projects, an appropriate hard fault handler to deal with semihosting when the debugger is not attached is automatically generated (based on the original from the very old forum thread above). Although this file is not included in projects based on preinstalled parts like LPC11e35, the same file should be useable - I've attached it for reference.

Regards,

MCUXpresso IDE Support

0 件の賞賛