I'm new to working with U-boot. I have a microZed board that I'm trying to figure out how to erase flash and write new boot.bin, rootfs.jffs2 and image.ub files into flash. In my u-boot environment here are what I feel are relevant environmental variables:
boot_img=BOOT.BIN
bootenvsize=0x20000
bootenvstart=0x260000
bootsize=0x260000
bootstart=0x0
clobstart=0x01000000
eraseenv=sf probe 0 && sf erase ${bootenvstart} ${bootenvsize}
install_boot=sf probe 0 && sf erase ${bootstart} ${bootsize} && sf write ${clobstart} ${bootstart} ${filesize}
load_boot=tftpboot ${clobstart} ${boot_img}
sd_update_boot=echo Updating boot from SD; mmcinfo && fatload mmc 0:1 ${clobstart} ${boot_img} && run install_boot
update_boot=setenv img boot; setenv psize ${bootsize}; setenv installcmd "install_boot"; run load_boot test_img; setenv img; setenv pd
I see that a few of these environmental variables are erasing and writing. I'm just not sure which one to run? eraseenv? install_boot? update_boot? Each one is targeting a different memory start location with different sizes. I'm not sure how to proceed.