烧写Linux系统 - AutopilotPi/AutoPilotPi-Hardware GitHub Wiki
SDNAND 烧写linux系统
-
基本原理可以参考挖坑网的这个帖子:https://whycan.com/t_2449.html
-
通过sunxi-fel将 uboot、os 和 rootfs 下载到V3s的内存中,然后通过uboot引导os 启动,在系统启动后,通过g_mass_storage 驱动,将sdnand 挂载为U盘
- (第一次使用V3s需要)解压tools下的zadig-2.3.zip,运行 选择 Options, List All Devices,选择v3s, 点击安装驱动
- 解压tools下的烧写工具v3s_s3_fel_autorun_linux_uart0_pb8_pb9_20190501.zip, 执行download.bat(windows下)将临时linux烧写到v3s的内存中,烧写完成后会自动重启
-
进入linux后,执行
echo peripheral > /sys/devices/platform/soc/1c19000.usb/musb-hdrc.1.auto/mode , 切换OTG为外设模式(默认是host模式)
-
通过win32imager 或者 dd 将image烧写到sdnand中
-
Image下载地址:
- 纯净 Image(仅包括linux): https://pan.baidu.com/s/1gBZYLi8RAsrEOR9An9XUpw 提取码: p88h
- 带PX4的Image: https://pan.baidu.com/s/1KEFMRTnNrShanPzrjBlUlg 提取码:c3jh
- 自己编译内核,自己打包Image,参考
- 编译u-boot,内核 https://whycan.com/t_561.html
- 打包Image:https://blog.huangzzk.info/archives/361
trouble shoot
- 如果出现image烧写到一般失败,则可能会出现无法再用上述操作进入FEL模式了,此时可以通过uboot 的mmc 命令,将前8K空间清除,这样上电时检测不到bios,还是会进入FEL模式