MCUXpressso IDE v10.1.0
When enable "Select RTOS plugin", debug a FreeRTOS demo under SDK,
it crash when run the code "pxCurrentTCB = pxNewTCB; "in line 981 of tasks.c file ,
Thank you very much!
You get that error because your PC is now 0x0. Look in you registers view and the stack to see what's gone wrong with your program.
Can you post the text (not a screenshot) from the JlinkServer log in the Console View of the IDE? (See the MCUXpresso IDE v10.1 User Guide, section 16.8, "The Console View" for details of how to do this).
One thing that seems to crop up generally when the SEGGER FreeRTOS plugin goes wrong is to check the definition of "configTASK_RETURN_ADDRESS" in the FreeRTOSConfig.h file in your project, and potentially try adding the following line to the FreeRTOSConfig.h:
#define configTASK_RETURN_ADDRESS 0
MCUXpresso IDE Support
Hello LPCx support,
Thanks for your reply.
I test adding the below code, while the same error.
#define configTASK_RETURN_ADDRESS 0 I attached logs, please have a look. BTW, I run the hello demo under SDK, nothing changed. Thanks a lot.
Looking at your files, I don't see anything wrong or special. I have used as well the v620g version of the Segger software, and was not able to reproduce it.
A few thoughts:
- what happens if you stop/debug with the Segger kernel awareness is that it reads from the RTOS symbols and iterates the list of tasks/stacks to show it in the debug view. For this the plugin reads from memory and reads some blocks of memory. So if your stack/varables are at the end or close to an illegal address range, that might cause a problem. The question is: does it happen to just with this project or in general?
- it might be something very specific in your application. Does it happen with any of the SDK examples? E.g. the FreeRTOS generic example for the K64F board too (which works fine on my side)?
- Otherwise I really think it could be something with your application. Then it would be the best if you could share it?
I hope this helps,
I have the same error on my side.
MCUXpresso IDE v10.1.1_606 /MCUXpresso IDE v10.1.0
I test the below three demos of SDK_2.x_FRDM-K64 , all the same.
Happening this error once enable "Select RTOS plugin"
I take a vedio about it ,please have a look at my attachment .
Thanks very much!
Can it be related to the same problem I discovedered (Freertos task aware debug with Jlink probe with relocated application)?
yes, it could, if you are using relactated code. But I don't think this is this the case here?
I see from your J-Link server log that you are running SEGGER's v620g software. It might be worth installing the latest version of SEGGER's J-Link software and seeing if that helps. (SEGGER make new releases very regularly, so the version we ship with the IDE quickly becomes "old".) The current version at the time of writing is v6.22g which you can download from: SEGGER - The Embedded Experts - Downloads - J-Link / J-Trace
For more background info on this, including details of how the IDE decides which SEGGER software install to use, see section 3.8.1, "SEGGER software installation" of the MCUXpresso IDE v10.1 User Guide.
We are still unable to replicate this problem using MCUXpresso IDE v10.1.1 on Windows7 with either SEGGER software v620g or v622e with a FRDM-K64 here. Note though that we did get a firmware update of our probe between these two versions - so in both cases our probe has "Firmware: J-Link V10 compiled Dec 12 2017 16:37:47".
Exactly which SDK and version are you using? [Check the Installed SDKs view in the IDE for both SDK Version and Manifest Version.]
And are you using a "real" SEGGER J-Link debug probe (we have tested with a J-Link+ here), or are you perhaps using OpenSDA J-Link firmware?
Can you successfully use the FreeRTOS support provided by P&E and/or LinkServer(CMSIS-DAP / DAP-Link) debug connections? If necessary you can get the firmware for those for the OpenSDA probe fromvarious Kinetis eval board's from http://www.nxp.com/opensda)
Thanks for all of you support.
1. I use the on board debugger OpenSDA, I just download the latest firmware , is the same .
2. The P&E can work well . (While there isn't the selection of "Select RTOS plugin")
3. I just find that, after crash, continue run ,it seems it can work .
And if didn't set breakpoint on lin 981 pxCurrentTCB = pxNewTCB; , it also can work well.
I take a video about the two cases,
I have basically the same problem, but on KDS 3.2.0:
GDB behaving abnormally (won't stop at breakpoints) - J-Link/Flasher related - SEGGER Forum
Retrieving data ...