s32k3 flash swap requirements?

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

s32k3 flash swap requirements?

跳至解决方案
410 次查看
victory
Contributor III

Hi Nxp,

    for S32K3 flash swap function, i don't know is there any limitation for it,

1.  is it MUST need hse fw? if not ,is there any simple code example available?

2. if hse fw is MUST, is ab-swap fw needed, or full-mem also works?

thanks.

0 项奖励
回复
1 解答
386 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi @victory 

to be able to perform AB swap, it is necessary to install HSE AB Swap firmware and then call HSE service HSE_SRV_ID_ACTIVATE_PASSIVE_BLOCK.

It won't work with Full Mem version of the firmware and it won't work without the firmware.

You can take a look at HSE examples here:

https://www.nxp.com/webapp/Download?colCode=S32K3_HSE_DemoExamples

Search for function HSE_ActivatePassiveBlock.

Or absolute minimalist code without any drivers is to:

Write value 0x00000051 (that the ID of HSE_SRV_ID_ACTIVATE_PASSIVE_BLOCK service) somewhere to non-cacheable (this is important because Messaging Unit does not see cached data) SRAM memory (not DTCM). And then write address of this value to Messaging Unit MU0, TR1 register. That's all. If you receive response 0x55A5AA33 (that's HSE_SRV_RSP_OK) in RR1 register, the operation was successful.

Regards,

Lukas

在原帖中查看解决方案

0 项奖励
回复
2 回复数
387 次查看
lukaszadrapa
NXP TechSupport
NXP TechSupport

Hi @victory 

to be able to perform AB swap, it is necessary to install HSE AB Swap firmware and then call HSE service HSE_SRV_ID_ACTIVATE_PASSIVE_BLOCK.

It won't work with Full Mem version of the firmware and it won't work without the firmware.

You can take a look at HSE examples here:

https://www.nxp.com/webapp/Download?colCode=S32K3_HSE_DemoExamples

Search for function HSE_ActivatePassiveBlock.

Or absolute minimalist code without any drivers is to:

Write value 0x00000051 (that the ID of HSE_SRV_ID_ACTIVATE_PASSIVE_BLOCK service) somewhere to non-cacheable (this is important because Messaging Unit does not see cached data) SRAM memory (not DTCM). And then write address of this value to Messaging Unit MU0, TR1 register. That's all. If you receive response 0x55A5AA33 (that's HSE_SRV_RSP_OK) in RR1 register, the operation was successful.

Regards,

Lukas

0 项奖励
回复
375 次查看
victory
Contributor III
thanks your explanation.
0 项奖励
回复