I obtained my boot0.img file from one of the functioning Ubuntu SD cards I have by doing:
dd if=/dev/sdof=boot0.bin bs=8k skip=1 count=4
I am trying to use the 2017.05 U-Boot distribution. This builds for the PC2 in the usual way, but does not yield an SPL. The only clue about what to do with the image it builds is in the file u-boot-2017.05/board/sunxi/README.pine64). I tried using this scheme, and it fails (see the console messages below). Searching on the error messages (which come from boot0.img) led me to this highly relevant discussion on the U-Boot list:
The following comments are most pertinent:The H5 boot0 changed quite a lot, so the A64 runes don't work anymore. The way the different meta data of the firmware parts (ATF, U-Boot, arisc) are stored is different. I really couldn't be bothered to rev-eng and hack this dead end (again). And since we have the SPL code working already this time, I thought we just go with the proper stuff.My messages are:
HELLO! BOOT0 is starting! boot0 commit : 8 boot0 version : 4.0 set pll start set pll end rtc[0] value = 0x00000000 rtc[1] value = 0x00000000 rtc[2] value = 0x00000000 rtc[3] value = 0x00000000 rtc[4] value = 0x00000000 rtc[5] value = 0x00000000 DRAM BOOT DRIVE INFO: V0.6 the chip id is 0x00000001 the chip id is 0x00000001 the chip id is 0x00000001 the chip id is 0x00000001 the chip id is 0x00000001 axp not exist DRAM CLK =672 MHZ DRAM Type =3 (2:DDR2,3:DDR3,6:LPDDR2,7:LPDDR3) DRAM zq value: 0x003b3bf9 DRAM SIZE =1024 M DRAM simple test OK. dram size =1024 card no is 0 sdcard 0 line count 4 [mmc]: mmc driver ver 2016-03-15 20:40 [mmc]: sdc0 spd mode error, 2 [mmc]: Wrong media type 0x00000000 [mmc]: ***Try SD card 0*** [mmc]: HSSDR52/SDR25 4 bit [mmc]: 50000000 Hz [mmc]: 15193 MB [mmc]: ***SD/MMC 0 init OK!!!*** PANIC : sunxi_flash_init() error --2--,toc1 magic error PANIC : sunxi_flash_init() error --2--,toc1 magic error PANIC : sunxi_flash_init() error --0-- Ready to disable icache.
Tom's electronics pages / [email protected]