Enable "Select RTOS plugin" failed

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

Enable "Select RTOS plugin" failed

2,190 Views
Fan_xy
Contributor III

Hello ,

MCUXpressso IDE v10.1.0

Kinetis

Jlink debug

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 ,

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

Thank you very much!

11 Replies

1,583 Views
lpcxpresso_supp
NXP Employee
NXP Employee

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)

Regards,

MCUXpresso IDE Support

0 Kudos

1,583 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello ,

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,

Best regards,

Alice

1,583 Views
brunoalbrecht
Contributor III
0 Kudos

1,583 Views
lpcxpresso_supp
NXP Employee
NXP Employee

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.

Regards,

MCUXpresso IDE Support

0 Kudos

1,583 Views
lpcxpresso_supp
NXP Employee
NXP Employee

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

Regards,

MCUXpresso IDE Support

0 Kudos

1,583 Views
Fan_xy
Contributor III

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.

0 Kudos

1,583 Views
BlackNight
NXP Employee
NXP Employee

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,

Erich

0 Kudos

1,583 Views
biafra
Senior Contributor I

Hi Erich,

Can it be related to the same problem I discovedered (https://community.nxp.com/thread/467627‌)?

Many Thanks

Biafra

1,583 Views
BlackNight
NXP Employee
NXP Employee

Hi Biafra,

yes, it could, if you are using relactated code. But I don't think this is this the case here?

Erich

1,583 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello Erich, 

I have the same error on my side.

Win10 /win7

MCUXpresso IDE v10.1.1_606 /MCUXpresso IDE v10.1.0

FRDM-K64 board

I test the below three demos of SDK_2.x_FRDM-K64 , all the same.

pastedImage_1.png

Happening   this error once enable "Select RTOS plugin"

pastedImage_2.png

I take a vedio about it ,please have a look at my attachment .

Thanks very much!

BR

Alice

0 Kudos

1,583 Views
converse
Senior Contributor V

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.

0 Kudos