This paper records some problems encountered in the use of Nios and related causes analysis and solutions, make a summary convenient for later review. I also hope to help the siege lions with the same problems. This article has been updated for a long time, encountered on the write down.
I use the software version: Quartusii 13.0SP1,NIOS13.0SP1
[TIPS] Some basic settings of Nios Engineering
Here's a brief introduction to some of the actions I've used in using Nios to ensure that the number of errors in the entire use process is reduced.
- Qsys, custom IP Core, option to add the path of v files in tools
- Nios, add include paths in project->properities to prevent occurrences of variables not found after include
- When downloading the elf program, Run config Zhong two ignore options box
[ERROR] Qsys adding custom IP cores when synthetic errors
Most of the time we need to use a custom IP core to do what we need to do, and the procedure is to add a well-written v file to the new components->files and then synthesize it.
- Error occurrence: Pop-up error box, comprehensive failure.
- Error reason location: The written v file has a syntax error.
- Corresponding modification processing: Check the written v file to find out where the error is. When the project is not big, you can use a simple method, the written v file is set to the top-level file and then compile, according to the prompt error to make changes, after the compilation passed the Qsys will not have the error generated.
[ERROR] Nios program elf File download failed
- Error occurs: Downloading the SOF file after downloading elf file failed
- Error reason location: check of Nios core clock in Qsys
- Corresponding modification processing: Check the clock that modifies the Nios core in Qsys and correct it to the correct value.
[ERROR] Insufficient RAM resources on chip
- Error occurs: Compile failed in Nios, prompt to change error
- Error reason location:
- The on-chip RAM resource space is not allocated enough
- Incorrect BSP settings
- Corresponding modification processing:
- Check whether the configuration space of On-chip RAM in Qsys is set too small, if it is larger (the maximum value can be quartusii to see the device information).
- If the resources in the Qsys are still compiled and not passed, open the BSP Editor, tick
enable_small_library
, 忘记了后面补充,囧
.
[ERROR] Nios Interrupt Continuous Trigger
- Error occurrence: Continuous trigger interrupt after program download
- Error reason location:
- After entering the interrupt, you need to jump out of the interrupt before
- Qsys the choice of the Nios core is correct, select the compact type can
- Corresponding modification processing:
- Break out after execution of an operation, i.e. interrupt signal (can be read or write register)
- Qsys Nios Core selection is simple, complex type need to consider some additional knowledge, no use of the scene for the time being
[ERROR] Nios download After curing the re-power program fails to function properly
- Error phenomenon: Elf and sof file after the download power failure Restart program does not function properly, after the online write Nios normal, re-cure power restart is still abnormal.
- Error reason location:
- The output in the suspect Nios printf () caused some registers to block, but was not actually determined to be this reason
- This exception is still caused by JTAG mode in the final location of BSP editor
- Corresponding modification processing:
- Change the stderr, stdin, stdout in the BSP editor from Jtag_uart to none, and then rebuild the BSP file again to compile the project again, and be sure to compile the project again .
Original Nios Small Knowledge Summary