NUC977
flash spi
1. 設定PA0、PA1成USB啟動
2. 開啟CONFIG_ENV_IS_IN_SPI_FLASH並編譯UBoot程式
$ vim include/configs/nuc970_evb.h 48 #define CONFIG_SYS_USE_SPIFLASH 49 #define CONFIG_SYS_USE_NANDFLASH 50 #define CONFIG_SYS_NO_FLASH // that is, no *NOR* flash 51 //#define CONFIG_ENV_IS_IN_NAND 52 #define CONFIG_ENV_IS_IN_SPI_FLASH 53 //#define CONFIG_ENV_IS_IN_MMC
3. 編輯env.txt
$ vim spi_env.txt bootcmd=sf probe 0 18000000; sf read 0x7fc0 0x200000 0x1bc3d8; bootm 0x7fc0 baudrate=115200 bootdelay=3 ethact=emac ethaddr=00:00:00:11:66:88 stderr=serial stdin=serial stdout=serial
4. 燒錄至SPI
$ sudo nuwriter -m spi -d NUC977DK62Y.ini -e 0xffffffff $ sudo nuwriter -m spi -d NUC977DK62Y.ini -t env -a 0x80000 -w spi_env.txt -v $ sudo nuwriter -m spi -d NUC977DK62Y.ini -t uboot -a 0xE00000 -w u-boot.bin -v $ sudo nuwriter -m spi -d NUC977DK62Y.ini -t data -a 0x200000 -w arch/arm/boot/uImage -v
5. 設定PA0、PA1成SPI啟動