- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have a Cyclone10 LP evaluation kit that I'm using to try to develop a small test program. I can't seem to get the NIOS to boot successfully from the EPCQ128A flash although the FPGA is configuring.
If I create and the .sof file and .hex files as detailed in the manuals and program the flash with a .jic file the FPGA appears to configure correctly as the logic driven LED I have added flashes but there is no sign that the NIOS is running.
If I create a .jic file with a converted .hex file only and configure the FPGA with a .sof directly the NIOS runs. Also, if I program the flash with a .jic file converted from the .sof file and run the NIOS via Eclipse that also runs.
My problem appears to be in combining both files.
Background information:
The EPCQ is set up to download the firmware to 32k of onchip memory.
The NIOS reset vector is set to EPCQ and the exception vector to onchip memory.
I'm using the EPCQ_Controller2 IP in Qsys on Quartus 18.0.
In the BSP editor I've selected Enable_small_c_library.
In hal.linker all the options are deselected and all of the selectable linker regions are set to onchip memory.
I've done this before on a Cyclone III but used the NIOS II Flash programmer in Eclipse to program the flash device instead of creating a .jic file. This option isn't available to me for Cyclone10 as the programmer doesn't recognise the Cyclone10 as a valid device.
Does anyone know what I am missing here/doing wrong?
thanks
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Have you tested using .sof and elf files(Run As ->Nios II Hardware)?
Can you share the project file?
Best Regards,
Anand Raj Shankar
(This message was posted on behalf of Intel Corporation)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes it does run from a .sof programmed direct to the FPGA and runs using (Run As ->Nios II Hardware)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Anand,
the example design you posted for the Cyclone 10 LP board has been very helpful to make some headway booting from EPCQ. However, I was wondering if it would be possible for you to modify your example design to work with execute in place on the EPCQ device? I have tried modifying the example myself as per the AN-736(Nios execute in place) but unfortunately I am not managing to get the nios to come up correctly.
Cheers
MIke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
Thank you for the information in the post from above. I am having issues running the boot copier directly from EPCQ64 using the Cyclone 10LP FPGA Kit .
Following this post and attached zip folder C10LP_NIOS2.zip I have completed the following steps:
STEP 1: SET PARAMETERS WITHIN PLATFORM DESIGNER
1) Using Nios II/e
RESET VECTOR PARAMETERS:
- Reset Vector Memory : PERIPHERALS_EPCQ64.avl_mem
- Reset Vector offset : 0x 0008 0000 (.SOF Image size - 0x0003 B162)
- Reset Vector : 0x 0088 0000
EXCEPTION VECTOR PARAMETERS:
- Exception Vector Memory: PERIPHERALS_OCRAM.s1
- Exception Vector offset: 0x 0000 0020
- Exception Vector : 0x 0101 0020
2) Within the PERIPHERALS QSYS FILE:
OCRAM (On Chip RAM)
- s1 Data width : 32
- Total Memory Size : 40,500 bytes
- Initialize Memory Content - (Check marked - ENABLED - also tried with this option disabled)
Serial Flash Controller II Intel FPGA IP
- EPCQ64
STEP 2: Quartus Prime compile (re-attach SYSTEM.qip)
STEP 3: Start Eclipse IDE (setup project, import files from zip folder)
STEP 4: Start the BSP Editor
- Main Tab: hal.linker (ALL UNCHECKED)
- allow code at reset
- enable alt load
- enable alt load copy rodata
- enable alt load copy rwdata
- enable alt load copy exceptions
- Linker Script Tab
- Set all to OCRAM (.bss, .exceptions, .heap, .rodata, .rwdata, .stack, .text)
- .entry : only linker section set to EPCQ64_AVL_MEM
- CLICK GENERATE
STEP 5: Build Project ( successful compile)
STEP 6: Click Programmer, download .sof only (LED's now are illuminated on the board)
STEP 7: Run the Debug from Eclipse IDE
- LEDs are now toggling live
- NIOS II Console now showing hello world strings
- Successfully running
STEP 8: If reset pressed, SOF file erased, confirmed
STEP 9: Generate .HEX Files
- Make Target -> Build -> mem_init_generate -> Click Build (Generates the below)
- PERIPHERALS_EPCQ64.hex
- SYSTEM_PERIPHERALS_OCRAM.hex
STEP 10: Load .JIC using the Application Note (AN-736)
- TEST JIC with only .SOF and Flash loader
- Flash loader : 10CL025Y
- SOF Data Properties
- Page 0
- Select Start
- Start Address : 0x0
- SOF File Properties
- Compression checked (ENABLED)
STEP 11: Click Programmer, download .jic
STEP 12: Click on reset button on board - (LED's now are illuminated on the Cyclone 10LP Kit)
STEP 13: Run Program on Eclipse, Power Cycle, run program on Eclipse again to verify SOF is loaded properly
- program ran with no issues
----------------------------------------------------------------------------------------------------------------------------------------------------
Up to this point, the steps are clear. The next steps is where i see the issue where the code is not running upon reset. ----------------------------------------------------------------------------------------------------------------------------------------------------
For the next steps, I am executing the following steps:
STEP 14: Add hex file to JIC, under the Convert Programming Files tab
- Absolute Addressing
- Big Endian Selected
- Select file: mem_init -> PERIPHERALS_EPCQ64.hex (size 9.06KiB)
- Click Generate
- output file generated successfully
- SOF File and Flash Loader, loaded from previous step
STEP 15: Click Programmer, download new .jic (LED's now are illuminated on the Cyclone 10LP Kit)
STEP 16: Click on reset button on board - (LED's now are illuminated on the Cyclone 10LP Kit)
Note that if the code was running we should see the LEDs toggling as it is when i run the project.
LEDs are not toggling. So when I recompile, and run the debug it is now working again.
Questions:
1) From the steps above, I would assume that my .SOF and .ELF are properly being generated and running, What is unclear is why is my program not automatically loading after reset.
2) Am I missing any options within the BSP editor?
3) Is there anything missing from Platform Designer?
Thank you for your time and help in advance.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My apologies, the code is working now. I uncommented the printf("hello world") statement and that causes the LEDs to not toggle fully. Commenting it out fixed the issue.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page