Freedom K64F: starting without debugger?

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

Freedom K64F: starting without debugger?

Jump to solution
875 Views
davenadler
Senior Contributor I

I have an application running on Freedom K64F (using Segger JLink, SDK2.1).
Application is stored in flash and runs absolutely fine under debugger.

I'd like the board to run the application when powered up without the debugger - but nothing happens.
I disabled EZport per Erich's blog https://mcuoneclipse.com/

pastedImage_1.png

Traces are cut to onboard debugger as detailed here: https://developer.mbed.org/questions/4658/FRDM-K64F-alternative-JTAG-Debugger/

So what am I missing?
Thanks!
Best Regards, Dave

0 Kudos
1 Solution
515 Views
davenadler
Senior Contributor I

The problem was caused by semi-hosting. This project used -specs=rdimon.specs to linker to support SWO output debug connection. The library support for SWO is too lame to notice no debugger attached, and hangs in the startup code awaiting a debugger connection prior entering main. Oddly, IIRC I used semi-hosting for a couple products I developed using NXP LPC11C14 and LPC Xpresso, and I don't recall seeing this problem before. Anyway, just adjust the linker options:
- Remove:  -specs=rdimon.specs
- Add:         -specs=nosys.specs

Hope that helps someone else,
Best Regards, Dave

View solution in original post

0 Kudos
4 Replies
516 Views
davenadler
Senior Contributor I

The problem was caused by semi-hosting. This project used -specs=rdimon.specs to linker to support SWO output debug connection. The library support for SWO is too lame to notice no debugger attached, and hangs in the startup code awaiting a debugger connection prior entering main. Oddly, IIRC I used semi-hosting for a couple products I developed using NXP LPC11C14 and LPC Xpresso, and I don't recall seeing this problem before. Anyway, just adjust the linker options:
- Remove:  -specs=rdimon.specs
- Add:         -specs=nosys.specs

Hope that helps someone else,
Best Regards, Dave

0 Kudos
515 Views
BlackNight
NXP Employee
NXP Employee

I would have a look at the RESET and NMI lines (is NMI disabled?).

The Reset line should have a pull-up (say 10k) with a capacitor (say 1uF).

I hope this helps,

Erich

0 Kudos
515 Views
davenadler
Senior Contributor I

I disabled NMI in FOPT as well, same behavior (hope I did this right):

pastedImage_1.png

Not sure I understand about the RESET line - I'm using the K64F Freedom board; shouldn't this be already set up?

Thanks Erich, Best Regards, Dave

0 Kudos
515 Views
BlackNight
NXP Employee
NXP Employee

Yes, on the FRDM-K64F the rest line has this already. That comment was a general one in case a custom board is used.

0 Kudos