AnsweredAssumed Answered

K22 detect if in jtag debug mode

Question asked by Ruben Jonsson on Mar 14, 2016
Latest reply on Mar 16, 2016 by Ruben Jonsson

Is there an easy way to detect if the program in a K22 is running from the debugger over the JTAG interface or if it is started standalone?

I have added some LEDs to the jtag interface pins which I want to use when not running from the debugger. I could check the _DEBUG define at compile time to enable the GPIOs instead of the JTAG interface but I would rather be able to do this at runtime so it works with any build.