NXP MCU 技术论坛
直播中

王鹏

7年用户 1240经验值
私信 关注
[问答]

无法通过lwip_httpsrv_ota_enet示例是怎么回事?

但是我无法通过 lwip_httpsrv_ota_enet 示例。在转向自定义 PCBa 之前,想在我的开发板上演示以下内容:

  • 闪存常驻第二个引导加载程序
  • 能够通过以太网闪存应用程序
首先,构建和刷新 mcuboot_opensource 示例似乎按预期工作。
J-Link>loadfile MCUXpressoIDE_11.6.1_8255\\workspace\\evkmimxrt1064_mcuboot_opensource\\Release\\evkmimxrt1064_mcuboot_opensource.bin 0x70000000
\'loadfile\': Performing implicit reset & halt of MCU.
ResetTarget() start
ResetTarget() end
AfterResetTarget() start
AfterResetTarget() end
Downloading file [MCUXpressoIDE_11.6.1_8255\\workspace\\evkmimxrt1064_mcuboot_opensource\\Release\\evkmimxrt1064_mcuboot_opensource.bin]...
J-Link: Flash download: Bank 0 @ 0x70000000: 1 range affected (65536 bytes)
J-Link: Flash download: Total: 0.760s (Prepare: 0.222s, Compare: 0.113s, Erase: 0.235s, Program & Verify: 0.169s, Restore: 0.019s)
J-Link: Flash download: Program & Verify speed: 378 KB/s
O.K.当尝试随后刷新 lwip_httpsrv_ota_enet 应用程序时,我对使用“直接方法”感兴趣


a) 使用外部工具将已签名的应用程序映像编程到主应用程序分区(直接方法)
b) 通过调试器启动应用程序,使用已签名的映像执行 OTA 更新,重置电路板并让引导加载程序执行更新(间接方法) )
在尝试直接方法时,我首先对图像进行签名:
(venve) nxp_sdk\\middleware\\mcuboot_opensource\\scripts>python imgtool.py sign
    --key nxp_sdk\\boards\\evkmimxrt1064\\mcuboot_opensource\\keys\\sign-rsa2048-priv.pem
    --align 4 --header-size 0x400 --pad-header --slot-size 0x200000
    --max-sectors 800 --version \"1.0\" MCUXpressoIDE_11.6.1_8255\\workspace\\evkmimxrt1064_mcuboot_opensource\\Release\\evkmimxrt1064_mcuboot_opensource.bin http_ota_signed.bin
然后我闪现这个签名图像:
J-Link>loadfile http_ota_signed.bin 0x70040000
\'loadfile\': Performing implicit reset & halt of MCU.
ResetTarget() start
ResetTarget() end
AfterResetTarget() start
AfterResetTarget() end
Downloading file [http_ota_signed.bin]...
J-Link: Flash download: Bank 0 @ 0x70000000: 1 range affected (65536 bytes)
J-Link: Flash download: Total: 0.503s (Prepare: 0.045s, Compare: 0.022s, Erase: 0.228s, Program & Verify: 0.188s, Restore: 0.018s)
J-Link: Flash download: Program & Verify speed: 340 KB/s
O.K.
看起来 sbl 接受它作为可引导图像,但图像在加载时崩溃。
hello sbl.
Bootloader Version 1.9.0
Primary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Secondary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Boot source: none
Swap type: none
Bootloader chainload address offset: 0x40000
Reset_Handler address offset: 0x40400
Jumping to the image


hello sbl.
Bootloader Version 1.9.0
Primary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Secondary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Boot source: none
Swap type: none
Bootloader chainload address offset: 0x40000
Reset_Handler address offset: 0x40400
Jumping to the image


hello sbl.
Bootloader Version 1.9.0
Primary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Secondary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3
Boot source: none
Swap type: none
Bootloader chainload address offset: 0x40000
Reset_Handler address offset: 0x40400
Jumping to the image
我希望有人可以帮助我指明正确的方向。这可能是我构建的 lwip_httpsrv_ota 应用程序的问题,还是我签名和闪烁的方式?如果有帮助,附上我签名和未签名的 bin 文件。


更多回帖

发帖
×
20
完善资料,
赚取积分