Forum Discussion
Hi,
Thanks for your feedback. You may need to conver .axf to a Raw Binary .bin file before program it.
you can use fromelf or arm-none-eabi-objcopy to convert it.
- arm-none-eabi-objcopy -O binary application.axf application.bin
- copy your application.bin to the board.
- execute the program.
Hope it helps.
- keloke982 months ago
New Contributor
Hello,
Thank you for your reply, I followed your steps but not sure if it was the right way because it is still not working.
- Generated the .bin and copied inside sd card
- Stopped uboot and launched the application in uboot by:
Hit any key to stop autoboot: 0 => fatload mmc 0:1 0x00100040 application_example_v1_1.bin 67752 bytes read in 6 ms (10.8 MiB/s) => go 0x00100040 ## Starting application at 0x00100040 ... U-Boot SPL 2021.04 (Sep 02 2021 - 08:43:37 +0000)As you can see uboot restarts again without printing anything, this i the makefile configuration in the Altera-SoCFPGA-HardwareLib-16550-CV-GNU example (modified the lines to aim to arria10 instead of cyclone V) :
COMPILER ?= GNU #COMPILER ?= ARMCC #MEMORY ?= ddr MEMORY ?= ocr #SEMIHOSTED ?= 1 SEMIHOSTED ?= 0 ADD_CFLAGS_GNU := ADD_CFLAGS_ARMCC := EXAMPLE_SRC := main.c alt_16550_buffer.c alt_16550_prompt.c echo_prompt.c launcher_prompt.c memory_prompt.c ELF := application.axf # These parameters can be overriden # LINKER_SCRIPT # HWLIBS_SRC # SAFECLIB_SRC include Makefile.incIsn't there another easier way to do this without license?
- KianHinT_altera2 months ago
Frequent Contributor
Hi,
I think the reason why it didn't work is because
#MEMORY ?= ddr
MEMORY ?= ocr
For Arria 10 OCR address starts from 0xFFE00000, https://www.intel.com/content/www/us/en/programmable/hps/arria-10/hps.html#topic/sfo1429891236418.html
either try changing back to DDR or use the 0xFFE00000 address (if your application bin is smaller than 256KB) as OCRAM is quite small.
As the design is based on cyclone V, memory address might be different as well, eg Arria 10 Devkit uses UART1 so you might need to change the address to 0xFFC02100
Could you try Radu suggestion as well, and also just wanted to understand, is there any reason you wanted to use baremetal to show uart printout or whether to just boot into linux and running the hello world example?