MCXN236 safety IEC60730B example bebug failed

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

MCXN236 safety IEC60730B example bebug failed

1,588件の閲覧回数
seanwu
Contributor IV

Dear sir, 

I want to test IECB60730B example in NCXN236 SDK 2.16.000 on FRDM-MCXN236.

But it can' t download firmware to debug like below.

Please hlep to check the issue.

seanwu_0-1739754384494.png

 

Thanks. BR,

Sean Wu.

Weikeng.

 

ラベル(1)
0 件の賞賛
返信
8 返答(返信)

1,568件の閲覧回数
Celeste_Liu
NXP Employee
NXP Employee

Hello @seanwu ,

Thanks for your post. 

I've indeed reproduced your problem. The cause is that it lacks the default flash driver settings. I'll submit a Jira ticket to the SDK team.

You can solve it in this way.
Manually add the "MCXNxx.cfx" file in the GUI flash tool, and then you can download it normally, but it's only effective for a single time.

Celeste_Liu_0-1739853468156.png

Celeste_Liu_1-1739853485474.png

If you want to set the default flash driver for it, you can do it in the following way.

Celeste_Liu_2-1739853513648.png

If this works, then even if you don't set the GUI flash driver, it should also work.

Hope it can help you.

 

BRs,

Celeste

 

--------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!
--------------------------------------------------------------------------------------------------------------------

0 件の賞賛
返信

1,539件の閲覧回数
seanwu
Contributor IV

Dear Celeste,

Can you debug the example? I tried to debug the example, but it will crash like below.

And I found it will crash after SPC_SetActiveModeDCDCRegulatorConfig(SPC0, &dcdcOpt);

Could you please help to check the issue?

seanwu_0-1739928372762.png

Thanks. BR,

Sean Wu

タグ(1)
0 件の賞賛
返信

1,513件の閲覧回数
Celeste_Liu
NXP Employee
NXP Employee

Hello @seanwu ,

I've conducted a test on my end, and the debugging process went smoothly without any issues. From the error message you provided, it's difficult to get useful information. I'm wondering if the same problem would occur if you switched to a different demo, like the simplest hello_world example in the SDK.
Here's a list of the IDE and SDK I'm using for your reference:
IDE: MCUXPresso v24.9[build25]

SDK: 2.16.000

Screenshot 2025-02-20 111048.png

You might also want to try the following steps:
1. Replace the board.
2. Restart MCUXpresso.
3. Switch to a new workspace.

BRs,

Celeste

0 件の賞賛
返信

1,489件の閲覧回数
seanwu
Contributor IV

Hi @Celeste_Liu ,

I tried other examples like led, hello world, FlexIO SPI... Thy can work well. Just the IEC example debug failed. My MCUxpresso is 24.12.148, and SDK is 2.16.00.

Thanks.

BR,

Sean Wu

タグ(1)
0 件の賞賛
返信

1,484件の閲覧回数
Celeste_Liu
NXP Employee
NXP Employee

Hello @seanwu ,

Prompted by another colleague from your company, I found that there are two versions of MCXN236, Rev B and Rev C. I used Rev B before and there was no problem. I've indeed reproduced your issue when using Rev C. In short, it seems that there is really something wrong with the demo. I'll submit this problem to our internal team. 

Sorry for the inconvenience. I'll let you know if there is any progress with the problem.

BRs,

Celeste

0 件の賞賛
返信

1,420件の閲覧回数
seanwu
Contributor IV

Dear @Celeste_Liu ,

Thanks for your help.

BR,

Sean Wu

タグ(1)
0 件の賞賛
返信

1,252件の閲覧回数
Celeste_Liu
NXP Employee
NXP Employee

Hello @seanwu ,

Hope you are doing well. Sorry for keeping you waiting for so long. Here is the update about this issue:

This issue can be fixed by modifying start.c file. The modified part disables aGDET and dGDET the same way as standard SDK startup file for this device does. This solved the described issue on FRDM-MCXN236 RevC.

Add the following code after line 38 in startup/start.c.

 

#if defined(MCXN236_H_)
    /* Disable aGDET trigger the CHIP_RESET */
    ITRC0->OUT_SEL[4][0] = (ITRC0->OUT_SEL[4][0] & ~ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN9_SELn_MASK) | (ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN9_SELn(0x2));
    ITRC0->OUT_SEL[4][1] = (ITRC0->OUT_SEL[4][1] & ~ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN9_SELn_MASK) | (ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN9_SELn(0x2));
    
    /* Disable aGDET interrupt and reset */
    SPC0->ACTIVE_CFG |= SPC_ACTIVE_CFG_GLITCH_DETECT_DISABLE_MASK;
    SPC0->GLITCH_DETECT_SC &= ~SPC_GLITCH_DETECT_SC_LOCK_MASK;
    SPC0->GLITCH_DETECT_SC = 0x3C;
    SPC0->GLITCH_DETECT_SC |= SPC_GLITCH_DETECT_SC_LOCK_MASK;

    /* Disable dGDET trigger the CHIP_RESET */
    ITRC0->OUT_SEL[4][0] = (ITRC0->OUT_SEL[4][0] & ~ ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN0_SELn_MASK) | (ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN0_SELn(0x2));
    ITRC0->OUT_SEL[4][1] = (ITRC0->OUT_SEL[4][1] & ~ ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN0_SELn_MASK) | (ITRC_OUTX_SEL_OUTX_SELY_OUT_SEL_IN0_SELn(0x2));
    GDET0->GDET_ENABLE1 = 0;
    GDET1->GDET_ENABLE1 = 0;
#endif

 

 

Screenshot 2025-03-14 103543.png

This issue is expected to be fixed in version 25.09. Hope it can help you. 

BRs,

Celeste

 

--------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the "ACCEPT AS SOLUTION" button. Thank you!
--------------------------------------------------------------------------------------------------------

0 件の賞賛
返信

1,161件の閲覧回数
seanwu
Contributor IV

Dear @Celeste_Liu ,

Thanks for your greate help. It can work.

Thanks.

BR,

Sean Wu

0 件の賞賛
返信