Forum Discussion
Altera_Forum
Honored Contributor
8 years ago --- Quote Start --- Hello Austin, I've been reading the boot types and I still didn't find a solution for bare-metal application. My goal is to load up a design into FPGA (with the .rbf file) and then load my binary bare-metal application for ARM-A9. Today what I could do is to generate the preloader (preloader-mkpimage.bin) and my FPGA raw files to program (.rbf) but I couldn't find some tutorial of how to generate the u-boot.scr and u-boot.script to program FPGA and load the binary. =/ Btw, if I understood right to loadup the design and boot some bare-metal app you need and SD/MMC with: Partitions: fat32: ------ u-boot.img ------ u-boot.scr ------ baremetalapp.bin ------ soc_design.rbf a2: ------ preloader-mkpimage.bin Am I right about this? --- Quote End --- I already can generate the binary bare metal with the mkimge header with the command: $(MKIMAGE) -A arm -T standalone -C none -a 0x100040 -e 0 -n "baremetal image" -d $(BIN) $(IMG) but when I try to run the u-boot.scr the output fails to run, my script is: u-boot.script: fatload mmc 0:1 $fpgadata soc_system.rbf; fpga load 0 $fpgadata $filesize; run bridge_enable_handoff; fatload mmc 0:1 0x00100040 hello-mkimage.bin; go 0x00100040; $(MKIMAGE) -A arm -T standalone -C none -a 0x100040 -e 0 -n "uboot script" -d u-boot.script u-boot.scr And the output is: U-Boot 2013.01.01 (Feb 14 2018 - 16:14:30) CPU : Altera SOCFPGA Platform BOARD : Altera SOCFPGA Cyclone V Board I2C: ready DRAM: 1 GiB MMC: ALTERA DWMMC: 0 *** Warning - bad CRC, using default environment In: serial Out: serial Err: serial Skipped ethaddr assignment due to invalid EMAC address in EEPROM Net: mii0 Warning: failed to set MAC address Hit any key to stop autoboot: 0 reading u-boot.scr 228 bytes read in 5 ms (43.9 KiB/s) # # Executing script at 02000000 Bad image type reading zImage ** Unable to read file zImage ** reading socfpga.dtb ** Unable to read file socfpga.dtb ** Bad Linux ARM zImage magic!