I am working with iMXRT1060 and have a SPI NOR Flash connected to FlexSPI. I want to boot from this memory and in the delopment stage I don't need any security. I have created a simple image in IAR tool chain and now are trying to make file for SPI NOR for booting from it. During the boot stage I hope that the image will be copied to the ITCM address 0x0000 and started.
As I understood for this purpose I can use elftosb.exe utility using as input my created image file in S-Recod or ELF format, simple .BD file and after launching the utility I will get the output binary or .srec file, which I can program to the SPI NOR Flash using any Flash programmer.
Am I correct?
I have found the very simple .BD file:
--------- itcm.bd -------------
flags = 0x00;
# Note: This is an example address, it can be any non-zero address in ITCM region
startAddress = 0x400;
ivtOffset = 0x400;
initialLoadSize = 0x1000;
# Note: This is required if the default entrypoint is not the Reset_Handler
# Please set the entryPointAddress to the base address of vector table
// entryPointAddress = 0x1400;
elfFile = extern(0);
I copy my elf file in the folder with elftosb.exe and I launch
elftosb.exe -f imx -V -c itcm.bd -o out.srec
As a result output file is empty (the file length is 0).
- why does the output file have zero length?
- how does "elftosb.exe" undestand the input file name and where it lays (how can I specify the input name)?
- can I use not elf but srec file format as input file?
Thanks and regards,