s32k312 HSE AB SWAP

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

s32k312 HSE AB SWAP

227 Views
ruller
Contributor I

hi:

I am currently using the AB swap function with HSE on the S32K312.

For example, the program is currently running from Partition A. During the first update, we erase/program the flash in Partition B, and then call the HSE interface to enable Partition B. At this point, no reset is performed.

During the second update, we still erase/program the flash in Partition B. However, if power is lost during the programming process and the device is powered on again, the program fails to run.

I would like to ask: if we enable Secure Boot, can we use SMR and Secure Recovery Mode to implement software-based switching/jumping between Partition A and Partition B?

0 Kudos
Reply
1 Reply

184 Views
VaneB
NXP TechSupport
NXP TechSupport

Hi @ruller 

Take a look at the thread How to enable the rollback function of HSE AB_SWAP on S32K3? It has some suggestions around rollback and recovery that might help with your implementation.

 

BR, VaneB

0 Kudos
Reply
%3CLINGO-SUB%20id%3D%22lingo-sub-2389535%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3Es32k312%20HSE%20AB%20SWAP%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2389535%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3Ehi%3A%3C%2FP%3E%3CP%3EI%20am%20currently%20using%20the%20AB%20swap%20function%20with%20HSE%20on%20the%20S32K312.%3C%2FP%3E%3CP%3EFor%20example%2C%20the%20program%20is%20currently%20running%20from%20Partition%20A.%20During%20the%20first%20update%2C%20we%20erase%2Fprogram%20the%20flash%20in%20Partition%20B%2C%20and%20then%20call%20the%20HSE%20interface%20to%20enable%20Partition%20B.%20At%20this%20point%2C%20no%20reset%20is%20performed.%3C%2FP%3E%3CP%3EDuring%20the%20second%20update%2C%20we%20still%20erase%2Fprogram%20the%20flash%20in%20Partition%20B.%20However%2C%20if%20power%20is%20lost%20during%20the%20programming%20process%20and%20the%20device%20is%20powered%20on%20again%2C%20the%20program%20fails%20to%20run.%3C%2FP%3E%3CP%3EI%20would%20like%20to%20ask%3A%20if%20we%20enable%20Secure%20Boot%2C%20can%20we%20use%20SMR%20and%20Secure%20Recovery%20Mode%20to%20implement%20software-based%20switching%2Fjumping%20between%20Partition%20A%20and%20Partition%20B%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2389924%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20s32k312%20HSE%20AB%20SWAP%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2389924%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F261717%22%20target%3D%22_blank%22%3E%40ruller%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETake%20a%20look%20at%20the%20thread%20%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2FS32K%2FHow-to-enable-the-rollback-function-of-Hse-AB-SWAP-on-S32K3%2Ftd-p%2F2145179%22%20target%3D%22_blank%22%3EHow%20to%20enable%20the%20rollback%20function%20of%20HSE%20AB_SWAP%20on%20S32K3%3F%3C%2FA%3E%20It%20has%20some%20suggestions%20around%20rollback%20and%20recovery%20that%20might%20help%20with%20your%20implementation.%3C%2FP%3E%0A%3CBR%20%2F%3E%0A%3CP%3EBR%2C%20VaneB%3C%2FP%3E%3C%2FLINGO-BODY%3E