2082791_en-US

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

2082791_en-US

2082791_en-US

S32K344 Bootloader. Deinit Mcu

I am implementing a bootloader in S32K344 and encountering some issues after the jump to the application firmware.
1 - I have verified that the jump is occurring correctly, but there are problems during the MCU initialization, its goes to HardFault. However, this does not always happen; often, the jump to the production firmware occurs without any issues. The times when this problem occurs are during the following sections of the MCU initialization:

myst_0-1744923213359.png

The peripherals that the bootloader initialize uses are:
MCU, OsIf, Siul2_Port_Ip_Init, IntCtrl_Ip, Gpt, Spi, Sbc_fs26, Wdg_43_fs26, Lpuart_Uart, flash_c40.

The deinit function in bootloader:

myst_1-1744923213384.png

How do I perform deinitialization in MCU functions?
Is there any additional step I need to take? Perhaps in the .mex?

2) I use the PTE13 port as an input. I have already used the solution of disabling the LMBCTLEN register, and it worked in the production firmware. However, when the production firmware is initialized by the bootloader, this register remains selected. In other words, the MCU initialization in the bootloader is not redone when I call Mcu_Init / Mcu_InitClock / Mcu_SetMode at production firmware. What do I suposto do?

3) As with question 2, the same issue is occurring with the PTA24 and PTA25 pins. In the production firmware, they have been configured correctly and work normally. However, when initialized by the bootloader, the SOSC source configuration is lost. What do I suposto do?

myst_2-1744923213388.png


Re: S32K344 Bootloader. Deinit Mcu

Sorry for delay.
The solution was put the same config from .mex of bootloader fw on application fw. Don't initialize MUC in application fw, only initialize in the bootloader fw.
A tip: Don't put optimization on Startup_Code

Re: S32K344 Bootloader. Deinit Mcu

Hello, @danielmartynek 

I'm glad your reply. 
1. We going to identify the fault exception. When we identify, I will reply here.
2 & 3. RTD 5.0

Re: S32K344 Bootloader. Deinit Mcu

Hi @myst,

1.

It is important to identify the fault exception. There can be many possible root caused.

Follow these documents:

https://community.nxp.com/t5/S32K-Knowledge-Base/Example-S32K312-HARDFAULT-Handling-Interrupt-DS3-5-...

https://community.nxp.com/t5/S32K-Knowledge-Base/How-To-Debug-A-Fault-Exception-On-ARM-Cortex-M-V7M-...
https://community.nxp.com/t5/S32K-Knowledge-Base/Fault-handling-on-S32K14x/ta-p/1114447

2 & 3.

Which RTD revision is this?


Thanks,

BR, Daniel



タグ(1)
評価なし
バージョン履歴
最終更新日:
‎11-21-2025 06:40 PM
更新者: