S32K311 with HSE Installed: Software Crash and MCU Reset, Debugger Unable to Attach Hello NXP Team, Background: MCU: S32K311 AUTOSAR RTD MCAL: SW32K3_S32M27x_RTD_R21-11_6.0.0_QLP01 HSE FW (Full Memory): s32k3x1_hse_fw_0.12.0_2.55.0_pb250225.bin Full Investigation Report attached in PDF Main Issue The software crashes and the MCU resets in Clock_Ip_DistributePll(). In addition, the debugger is sometimes unable to attach. When I tried to hot-attach the debugger, the reset reason was sometimes reported as HSE_CLK_FAIL. Can you check mainly the above procedure, IVT and DCF records and additionally information why this issue is occurring and its solution, Please let us know if any additionally information is needed. Could you please check the HSE installation procedure, IVT configuration, and DCF records, and advise why this issue is occurring and how it can be resolved? Please let us know if any additional information is required. Best regards, Shubham Pardeshi Re: S32K311 with HSE Installed: Software Crash and MCU Reset, Debugger Unable to Attach Hello @davidtosenovjan Our software consists of FBL and APPL, and both use the same Functional reset mechanism. When APPL initiates the reset, the issue is not observed. When FBL initiates the reset, the software crashes during APPL startup inside Clock_Ip_DistributePll(). Initially, we added a check for HSE_STATUS_INIT_OK after Mcu_InitClock() and before Mcu_DistributePllClock(). This prevented the crash. However, it took approximately 20 seconds for HSE_STATUS_INIT_OK to be set, after which the actual APPL startup continued. Today, we moved the HSE_STATUS_INIT_OK check to an earlier stage, before Mcu_Init() in APPL, as shown in the attached screenshot. Shubham_MQ_0-1784123821324.png With this sequence, HSE_STATUS_INIT_OK is set almost immediately, and the crash is no longer observed. Could you please clarify the following? Why does this issue occur only when the reset is initiated by FBL, even though FBL and APPL use the same reset mechanism? Why does HSE_STATUS_INIT_OK take approximately 20 seconds when checked after Mcu_InitClock(), but become available almost immediately when checked before Mcu_Init()? Why is the HSE_STATUS_INIT_OK check not required in FBL, but appears to be required during APPL startup? Please provide a clear root-cause explanation and the recommended initialization sequence. We need to ensure that the current solution is robust and will not cause any issues in production. Please let us know if any additional details or clock configuration details are required. Best regards, Shubham Pardeshi Re: S32K311 with HSE Installed: Software Crash and MCU Reset, Debugger Unable to Attach Mentioned 70 and 20 seconds are times from reset to HSE_STATUS_INIT_OK. So basically only boot time is included, correct?
Does it behave the same way on every device?
查看全文