切换芯片
![](data/attach/1904/1fkn5ukjzpuwfnia8jbz5h27qzglbwfx.jpg)
每个芯片的权限不同,如下面的有些功能不能用
1 烧写UBOOT
选择好以下参数:
![](data/attach/1904/x6p02i1g1p72i806fzejxiqou2qewal4.jpg)
点击烧写,若提示找不到串口就先关闭软件,先叉串口,再打开软件
串口已经连接,请给单板上电,若已经上电,请断电后重新上电。
![](data/attach/1904/x0anz48icj69m1gjc02yrvx78oghtbbd.jpg)
正在下载:
![](https://img-blog.csdnimg.cn/20190225154131920.png)
最后烧写成功:
![](https://img-blog.csdnimg.cn/20190225153646285.png)
从/home/aston/sambashare/Hi3518E_SDK_V1.0.3.0/osdrv/pub/image_uclibc复制下面三个文件到/tftpboot/中
![](https://img-blog.csdnimg.cn/20190225161920893.png)
虚拟机上把网络该为192.168.1.141,最后重启虚拟机
然后在uboot中ping 192.168.1.141,如果不能ping通就再重启一下
![](https://img-blog.csdnimg.cn/20190225165011604.png)
设置serverip
set serverip 192.168.1.141
构建分区:
分区名 分区大小 起始地址 截至地址
bootloader 1M 0x00000000 0x00100000
kernel 3M 0x00100000 0x00400000
rootfs 12M 0x00400000 0x01000000
2 烧写kernel
tftp更新并重新烧写kernel的命令序列:
mw.b 0x82000000 ff 0x300000
tftp 0x82000000 uImage_hi3518ev200
sf probe 0 //选择第几块spiflash
sf erase 0x100000 0x300000
sf write 0x82000000 0x100000 0x300000
//spiflash 写 sdram的地址 spiflash的地址 烧写的大小
3 烧写rootfs
tftp更新并重新烧写rootfs的命令序列:
mw.b 0x82000000 ff 0xc00000
tftp 0x82000000 rootfs_hi3518ev200_64k.jffs2
sf probe 0
sf erase 0x400000 0xc00000
sf write 0x82000000 0x400000 0xc00000
设置bootcmd和bootargs
set bootcmd 'sf probe 0;sf read 0x82000000 0x100000 0x300000;bootm 0x82000000'
set bootargs mem=32M console=ttyAMA0,115200 root=/dev/mtdblock2 rootfstype=jffs2 mtdparts=hi_sfc:1024K(boot),3072K(kernel),12288K(rootfs)
mem=32M:海思SOC中有64M内存,给MPP分配32M,给内核分配了32M
root=/dev/mtdblock2:根文件系统是在第二个分区
mtdparts=hi_sfc:表示分区表,内核也有分区表,但是我们如果要修改,很不方便,可以通过设置这个参数来指定分区表
最后输入reset,启动成功