We have a DualLite board that won't be easily accessible where we may need to put it into serial download mode for software upgrades. Is there any way to do this through software? There's a recovery button on the board, but we'd like the upgrades to be automated (also access to this button requires taking off a cover).
已解决! 转到解答。
Hi Patrick,
If you are able to get into the U-boot prompt then you can do:
=> bmode usb
resetting ...
(USB download mode is entered).
You can then load u-boot.imx via USB using imx_usb_loader:
On the PC host: sudo ./imx_usb u-boot.imx
Then you will see U-boot messages on console.
Regards,
Fabio Estevam
Hi Patrick,
If you are able to get into the U-boot prompt then you can do:
=> bmode usb
resetting ...
(USB download mode is entered).
You can then load u-boot.imx via USB using imx_usb_loader:
On the PC host: sudo ./imx_usb u-boot.imx
Then you will see U-boot messages on console.
Regards,
Fabio Estevam
FYI, this command is broken within the mainline U-Boot if a bootable qspi flash is connected to the SOC since the version 2016.11.
The CFG1 value is now equal to 0x10 (QSPI boot) instead of 0x01:
git.denx.de Git - u-boot.git/blob - arch/arm/cpu/armv7/mx6/soc.c
Hi,
I am using the SOC iMX6UL.
The commit that broke this feature is this one:
http://git.denx.de/?p=u-boot.git;a=commit;h=81c4eccb55ccbe4a7bb4016b23738c3c57dc364d
I reverted back to the value 0x01 and it works well.
2017.05 and 2017.07 have the same code for bmode usb.
Hi Joel,
Could you please report this problem to the U-Boot list (u-boot@lists.denx.de ) with the folks of the offending commit on Cc?
Thanks
Just to elaborate, I found this code in arch/arm/cpu/armv7/mx6/soc.c:
void boot_mode_apply(unsigned cfg_val)
{
unsigned reg;
struct src *psrc = (struct src *)SRC_BASE_ADDR;
writel(cfg_val, &psrc->gpr9);
reg = readl(&psrc->gpr10);
if (cfg_val)
reg |= 1 << 28;
else
reg &= ~(1 << 28);
writel(reg, &psrc->gpr10);
}
/*
* cfg_val will be used for
* Boot_cfg4[7:0]:Boot_cfg3[7:0]:Boot_cfg2[7:0]:Boot_cfg1[7:0]
* After reset, if GPR10[28] is 1, ROM will copy GPR9[25:0]
* to SBMR1, which will determine the boot device.
*/
cfg_val is 0x01 in the case of "bmode usb". None of these bits are documented in the RM, BTW.
Hi Patrick
one can look at SDK file system_util.c:
/* enter the ROM Serial Download Protocol */
hab_rvt_failsafe();
"MX6_PLATFORM_SDK "
Best regards
igor