mynewt-mcumgr-cli icon indicating copy to clipboard operation
mynewt-mcumgr-cli copied to clipboard

Image upload does not work over UDP - Zephyr smp_svr sample

Open rlevano77 opened this issue 3 years ago • 1 comments

I am trying to setup the zephyr samples/subsys/mgmt/mcumgr/smp_svr using UDP I am using Windows 11 and Golang v1.18.4 After I added mcuboot to my atsame54_xpro board. I built the smp_svr with UDP support using : west build -p auto -b myboard -d build-signed -- -DCONFIG_MCUBOOT_SIGNATURE_KEY_FILE=\"bootloader/mcuboot/root-rsa-2048.pem\" -DOVERLAY_CONFIG=overlay-udp.conf

mcuboot reconigze the image : Booting Zephyr OS build zephyr-v3.1.0-812-g88ca3aca98c0
I: Starting bootloader I: Primary image: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3 I: Scratch: magic=unset, swap_type=0x1, copy_done=0x3, image_ok=0x3 I: Boot source: primary slot I: Swap type: none I: Bootloader chainload address offset: 0x10000 I: Jumping to the first image slot [00:00:00.255,000] mdio_sam: transfer timedout MDIO [00:00:00.510,000] mdio_sam: transfer timedout MDIO [00:00:00.765,000] mdio_sam: transfer timedout MDIO Booting Zephyr OS build zephyr-v3.1.0-812-g88ca3aca98c0
[00:00:01.020,000] mdio_sam: transfer timedout MDIO [00:00:01.020,000] eth_sam: MAC: 02:04:25:4b:d0:b9 [00:00:01.020,000] eth_sam: Queue 0 activated [00:00:06.069,000] phy_mii: PHY (0) Link speed 100 Mb, full duplex [00:00:06.069,000] eth_sam: Link up [00:00:06.070,000] smp_udp_sample: Network connected [00:00:06.070,000] smp_sample: build time: Jul 20 2022 06:19:25 [00:00:06.070,000] smp_udp: Started (IPv4)

I tested the udp connection and works ok : `$ mcumgr --conntype udp --connstring=[192.168.1.71]:1337 echo hello hello

$ mcumgr --conntype udp --connstring=[192.168.1.71]:1337 image list Images: image=0 slot=0 version: 0.0.0 bootable: true flags: active confirmed hash: 5fbc81f7d0f5e5de22f254746bc977ce8836bf364e576f4f03c418bd1451679c Split status: N/A (0)`

But when I try to upload an image I only see $ mcumgr --conntype udp --connstring=[192.168.1.71]:1337 image upload build-signed/zephyr/zephyr.signed.bin 0 B / 71.88 KiB [------------------------------------------------------------------------------------------------------------------------------------------------------------] 0.00% and nothing uploads.

rlevano77 avatar Jul 22 '22 00:07 rlevano77

Could I ask which method do you use to connect to the IP 192.168.1.71?

L1amaGod avatar Oct 18 '23 07:10 L1amaGod