I had a cycloneVsoc board and I debugged the baremetal program I wrote, the project is based on the makefile and I tranfer the axf file to the bin file.
According to the guide of the Intel AN709, I need a correctly set SPL(first stage of Uboot) and using mkimage tool to change the bin file to a bin file with some special heads.
My plan is to put the spl and the bin with special head to the sdcard and let the board start from there.
I created an area called A2(dont know why, I may related to "SPL/TPL-> Partition Type on the MMC to load U-boot from" SECTION setting in Uboot menuconfig) as num = 2, and put the "u-boot-with-spl.sfp"(not the u-boot-spl.sfp in the spl file, but I dont know the difference). The section is 10M large.
And I created a FAT32 with 1024M size as num=1, I want to put the bin file into it and read/change the area through the windows host by a SD card reader.
In SPL, since I used the newest version of the SOCEDS, the BSP-editor settings didnt do anything any more. So I have to set the Uboot myself. I enable the FAT and SD/EMMC option and decide not to touch other settings.
For the bin file, I intend to use the mkimage to add the special head but I dont know two settings: -c the start address and -e the entry address. -c seems to be the physical address of the SD card and -e is -c address + 0x40(correct me if Im wrong).
So my questions are:
- How to set the SPL so that when it done it can find/load the bin file in the FAT32 area?
- How to get the correct address for the mkimage?
- Can spl choose which bin file is to loaded, if yes, how?
Thank you for your time and willing to help, please do have a nice day :)
Yours sincerely
Alex C