Updating only M-core firmware on i.MX 8ULP without flash.bin using SWUpdate

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

Updating only M-core firmware on i.MX 8ULP without flash.bin using SWUpdate

916 次查看
dhruvinrajpura
Contributor III

Hi

I've successfully ported SWUpdate to my i.MX 8ULP platform, and full system updates are working correctly. However, I'm now looking to implement a more targeted update mechanism that can update just the M-core (Cortex-M33) firmware without touching the bootloader or replacing the entire flash.bin.
Current Setup

Looking at the i.MX 8ULP boot structure, the M-core image is located at a specific offset within flash.bin. From the Makefile:
MCU_SSRAM_ADDR ?= 0x1ffc2000
M33_IMAGE_XIP_OFFSET ?= 0x31000
My Question
Is it possible to update only the M-core firmware on i.MX 8ULP using SWUpdate without having to replace the entire flash.bin? Specifically:

Can I safely extract the M-core image from flash.bin and update just that portion using SWUpdate's raw handler with the appropriate offset?
What would be the correct approach in the sw-description file? Should I use something like:

images: (
    {
        filename = "m33_core_image.bin.gz";
        compressed = "zlib";
        device = "/dev/mmcblk0boot0";
        offset = "196K";  // Is this offset (0x31000) correct for directly updating the M-core?
        installed-directly = true;
    }
)

Are there any special precautions or additional steps needed to ensure the M-core update doesn't corrupt the container structure or bootloader?
Has anyone successfully implemented M-core-only updates on i.MX 8ULP or similar NXP platforms with SWUpdate?

Any examples, guidance, or cautions would be greatly appreciated. I'd like to avoid trial and error with the boot partitions to prevent bricking the device.
Thanks in advance!
@Zhiming_Liu 

标签 (1)
0 项奖励
回复
2 回复数

784 次查看
AldoG
NXP TechSupport
NXP TechSupport

Hello,

We have not tested this on our side so can't be completely sure if it is done correctly or not.

Your work so far looks correct, just please note that 1st container offset is 0x1000 when boot device is flexspi0 nor flash, actually the m33_image.bin is in 0x31000 + 0x1000 = 0x32000

Also, are you booting on single boot or dual boot?
In case of need to update M33 image constantly maybe considering using dual boot would be best on your use case.

Best regards/Saludos,
Aldo.

0 项奖励
回复

775 次查看
dhruvinrajpura
Contributor III

Hi @AldoG 
I am using dual boot and I have tried with 32000 offset also swupdate is successful but device is getting currupted. I need to flash the new image in order to get it back. Do you have any other methode to do so?
Can you check the same on the i.MX 8ULP 9x9 EVK?

Thank you : )

0 项奖励
回复