HAL_RpmsgMcmgrInit() Program runaway

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

HAL_RpmsgMcmgrInit() Program runaway

5,096 Views
Taiyi
Contributor I

Hello!

      I have a new KW45 circuit board here, just started debugging. The program runs here, and the single step is out of control. What hardware is affected by this code?

 

企业微信截图_1690162880470.png

Best Regards.

0 Kudos
Reply
12 Replies

4,975 Views
Gavin_Jia
NXP TechSupport
NXP TechSupport

Hi @Taiyi ,

I apologize for the late reply. After our internal discussion, this issue should be expected. Let me just confirm that the board works fine when not using step-by-step, right?

There are NBU and Cortex-M33 inside KW45, when we use IDE for single-step debugging, we only step-by-step debug the CM33 core. At the same time, NBU is always running at full speed. 

This will cause problems with the synchronization between multiple cores. That is what you observed, the second core has not started. Therefore, it may be necessary to only add few breakpoints where necessary, and then run to the breakpoint, rather than complete single-step debugging. At the same time, in such a critical position, print may be required for necessary inspection.

Hope it could help!

 

Best regards,

Gavin

0 Kudos
Reply

4,965 Views
Taiyi
Contributor I

企业微信截图_16905267949410.pngWhen the program is not single-step debugging, the board runs abnormally, that is, the program runs near the breakpoint. When I run the program with the DEMO board, the running state is normal when I run the breakpoint at these locations. I suspect that the NBU upgrade is not carried out. I tried to upgrade the NBU but found that it was not successful. I want to know how I can tell if the M3 core is working properly. I feel that the M3 core is not working properly. Also, how do I upgrade NBU, using EVK development board to upgrade their own circuit board NBU, I have tried unsuccessfully.

0 Kudos
Reply

4,941 Views
Gavin_Jia
NXP TechSupport
NXP TechSupport

Hi @Taiyi ,

Sorry I am confused about your operation process. Could you help me check them?

Update NBU:

-- On NXP EVK board, success.

-- On custom board(without micro-usb port and Boot_CFG switch), using SPI as a bridge between evk and custom board, fail.

 

Single step debug:

-- On NXP EVK board (after NBU is updated successfully), it was observed that the second core did not start and was stuck. But running at full speed is fine. --> This is what I mentioned before as expected.

-- On custom board: Due to the failure to update the NBU, no phenomenon was observed. Until the NBU is updated, single-step debugging will get stuck and running at full speed will fail as well.

 

Is my understanding correct? let me know if there is something wrong.

 

Best regards,

Gavin

 

0 Kudos
Reply

4,924 Views
Taiyi
Contributor I

HELLO!

            Running at full speed is not normal, and all the tasks in the code are not running. The NBU update did not succeed, so the program did not run, and the single step debugging was also problematic. I suspect that NBU did not update the program, which caused the program to run.

0 Kudos
Reply

4,904 Views
Gavin_Jia
NXP TechSupport
NXP TechSupport

Hi @Taiyi ,

Thanks for your quick confirmation.

Regarding updating the NBU on the kw45, there are currently only two ways to do it:

  1. First one is let KW45 enter into ISP mode, then use spsdk/blhost(usually runs in PC side) to negotiate ROM bootloader.

  2. Second method: customer application code can use CAN or other interface to receive the NBU image into internal Flash, then make a reset, the ROM bootloader will copy NBU image from internal Flash to M3's Flash depend on the configuration of the OTA update table. But the problem is user have to reserve 256K flash for NBU image storage, 256K is too large for customer to reserve, especially when they are using 512K flash chip version. About this method, please refer to this AN.

Since the kw45 is still a relatively new product, we know that both methods are somewhat limited. In products after the kw45, we will offer more convenient ways to operate.

 

Best regards,

Gavin

0 Kudos
Reply

4,878 Views
Taiyi
Contributor I
Hello ! Is serial port OK for the second NBU upgrade method? What configurations need to be done on the software? Need to upgrade with OTAP? Does it have to be converted to SREC file for upgrade?
0 Kudos
Reply

4,894 Views
Taiyi
Contributor I

HI企业微信截图_16905267949410.png企业微信截图_16908777169118.png

Thank you for your approach.

I'll try the second method. In the first method, I used the micro USB port of the EVK circuit board to connect two external keys, RESET and BOOT_CFG.SPI, from the J12 port of the EVK circuit board to my own circuit board. At the same time, the RESET and BOOT_CFG of the EVK board are disabled, and the VBOARD voltage is up to 3.3V. This update recognizes the chip, but the download was unsuccessful.

I am considering whether it is possible to change the circuit on the EVK board to disable the SPI of the EVK board KW45, so as to connect to the SPI on my own board.The current situation is that the SPI of two chips (EVK board and own board) is connected together.

0 Kudos
Reply

1,689 Views
ebadia
Contributor III

Hello,

 

We have exactly the same issue with our own board. Could you finally flash the NBU? How?

0 Kudos
Reply

5,053 Views
Gavin_Jia
NXP TechSupport
NXP TechSupport

Hi @Taiyi ,

 

Thanks for contacting NXP support.

Just to confirm, did you update NBU before loading this demo? It is necessary to work with the matching NBU image for the SDK version of the application you are working with. Prior to loading any wireless SDK example, please update your NBU image.

The Getting Started with the KW45B41Z Evaluation Kit describes the first steps to work with your device. Section 3.3 Updating NBU for Wireless Examples depicts how to update the NBU using SPSDK command line tool (installation of SPSDK is described in Section 2.4). Please, make sure to have Python 3.7+ installed.

Could you please try these steps and let me know your findings?

 

Best regards,

Gavin

0 Kudos
Reply

5,017 Views
Taiyi
Contributor I

Hi!

    I tried this upgrade, in the KW45B41Z-EVK this development board can make the NBU upgrade successfully. But I am using the board designed by myself to upgrade NBU, there is no microUSB port, there is no related reset case and BOOT_CFG button, please tell me how to upgrade NBU. I tried to connect the board to EVK J12 port for NBU upgrade, but it seems to have failed. Do I need to make some connections to the power supply of the EVK board to ensure the NBU upgrade of the external circuit board with J12 port? What am I supposed to do now?

   In addition, how do I determine my chip version? The silk screen of the chip has the words 2P43C, and I should upgrade the NBU of that version. Looking forward to your reply。EVK BoardEVK BoardHomemade circuit boardHomemade circuit board

企业微信截图_16903520385744.png企业微信截图_16903389689125.png

0 Kudos
Reply

5,093 Views
Taiyi
Contributor I

Taiyi_0-1690163485881.png

When the program runs here, it's out of control. What could possibly be the cause?

0 Kudos
Reply

5,066 Views
Taiyi
Contributor I

企业微信截图_16901912742486.png

This board is the first time to use, do you need to upgrade flash? Also, the status value of the variable in the picture has not changed, which may be caused by something?

0 Kudos
Reply