Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
12600 Discussions

Self-bootable Nios Ssytem (boot copier). How to calculate SOF image size?

Ftiglius
Beginner
1,743 Views

I'm following guidelines from https://www.intel.com/content/dam/www/programmable/us/en/pdfs/literature/hb/nios2/edh_ed_handbook.pdf to obtain a self-bootable FPGA SOC with NiosII, 64 Mb ecpq flash and a Nios application. Well, procedure is described with a lack... Bootcopier address in flash, that is equal Nios reset vector offest must be after SOF file. Well.. how to calculate size for SOF ??? I cannot find no info about it. So, I cannot know how many Flash is filled by SOF file!!! Do you someone help me? Thanks

0 Kudos
6 Replies
Nooraini_Y_Intel
Employee
739 Views

Hi Ftiglius,

 

Which FPGA device are you referring to? The .sof file(.rbf/.rpd bistream) size is fixed for all FPGA device. You can refer to the respective FPGA device datasheets and find a table that contain Uncompressed Configuration Bit Stream Size (bits). Then you should be able to estimate the total number of .sof files that can fit into the EPCQ64 flash device.

 

Regards,

Nooraini

 

 

 

0 Kudos
Ftiglius
Beginner
739 Views

Thanks, Nooraini! I'm using Cyclone V 5CSEBA4 , Quartus 18.1 standard licensed.

 

I find precise dimensions on flash convert generated .map info file.

It reports for uncompressed sof file 0x40_C542

So, I fixed my NIOSII-F offset vector address as 0x50_0000

 

First, I use first NiosII flash programmer utiliy on SBT ECLIPSE, but I received Error Code 8. (this method runs fine with old attempts with some cyclon based development board..)

 

Then, I follow strictly official guide "edh_ed_handbook.pdf" and I attempt to obtain a self-booting hardware from EPCQ64A: "on place" and "boot copier" options. These methods uses Quartus Flash convert utility, that allows to compose a JIC file (Flash Programmer, SOf File, Hex File).

Both files (SOF for FPGA) and ELF for nios runs fine loading then with Jtag. (I use an external SDRAM, tested with Nios QSYS system)

 

Then , I program the chain from QUARTUS FLASH PROGRAMMER on JTAG. It see correctly FPGA+FLASH Chain and program flash correctly.

 

But It's impossible to obtain a bootable system. FPGA starts correctly (Infact If I load the elf from Eclipse, Nios application runs fine).

 

Probably I must open a service request about this issue. Only difference from manual is on my external SDRAM instead ON CHIP RAM showed in the example, but addressing mode and qsys settings are the same..... .

 

This is hard problem for our factory! We havent a bootable system today.... :-(

 

(ON attach, TEst1 : nios flash programmer->error 8 and TEST2 ->quartus convert test boot copier: it runs but system cannot boot nios)QuartusConvert_BootCopier_Test.jpgprog flash with sof_elf files erro 8.jpg

 

 

0 Kudos
Nooraini_Y_Intel
Employee
739 Views
0 Kudos
APaci1
Novice
739 Views

YHes I and AApacione working on same group. The main issue was solved from Jumaah, he changed ECPQ controller from type II to standard one, reducing speed downto 25 Mhz. This is the main issue. We have found that ECPQ II type controller DOESNT' WORK with ECPQA64 Flash, probably intel should investigate to this issue and clarifiy it. We lost a bunch of time attempting to boot our system, we cannot think about a ECPQII original controller had problems. I confirm that ECPQ controller standard works fine on both single and quad settings, using standard MSEL pin setting I have tested it on two our PCB... results are ok on both. Boot runs correctly with MSEL standard and QUAD ECPQ controller standard set to 25 Mhz. !!

0 Kudos
Nooraini_Y_Intel
Employee
739 Views

Hi APaci1,

 

Apologize for the delay. It's good to know that our colleague, @FJumaah​ has helped your team to identify the root cause and resolve the issue to move forward with the design. We will take note and channel this ECPQ II type controller failure ECPQA64 flash issue to the appropriate engineering team for further investigation. Thank you for the feedback.

 

Regards,

Nooraini

0 Kudos
APaci1
Novice
739 Views

Thnaks to Intel for very strong support. We have found that ECPQ64A controller on CYCLONE V device cannot perform correcty nios boot (boot copier) both 25 or 50 mhz clks. Replacing it with standard ECPQ controller same HW boots succesfully at 25 Mhz

Regards!!

Filippo, Nando and Alessandro from AeCTECH R&D

0 Kudos
Reply