Sopcinfo path Change, Nios project how to do?

Source: Internet
Author: User

Operating System: Win7 bit

Development Environment: Quartus II 14.0 (64-bit) + Nios II EDS 14.0

When using Quartus, sometimes due to backup considerations, or download other people's hardware engineering from the Internet, the hardware engineering catalog will change, resulting in Nios project can not find sopcinfo files, so that the next software development can not be done. The cumbersome approach is to create a new Nios project, and then add the original Nios project source file to the new project. This is cumbersome, and new projects need to recompile the BSP project, causing unnecessary trouble. Compare here to introduce a simpler method.

For example:

Original Hardware engineering catalog (the directory where the Sopcinfo file is located) D:\_prj\altera\de2_70_nios_vganios Project Catalog D:\_prj\altera\de2_70_nios_vga\software

After the change:

New Hardware Engineering directory (the directory where the new Sopcinfo file is located) e:\_prjbak\altera\de2_70_nios_vga\
New NIOS Engineering Catalogue E:\_prjbak\altera\de2_70_nios_vga\software

1. Finding problems

Start NIOS ECLIPSE and switch workspace to the new NIOS project directory, which is e:\_prjbak\altera\de2_70_nios_vga\software. At this point, if you compile the original project directly, you will be prompted to find the Sopcinfo file:



[VGA Build Complete]

At this point, if you view the BSP information, you will be prompted that BSP cannot find the Sopcinfo file and the SOPC design, the CPU and other information will not be found

2, solve the problem

Open the settings.bsp file for the BSP project, which is an XML-formatted configuration file. It is found that the BSP generation path and the SOPC design file path indicated by the Bspgeneratedlocation node and the Sopcdesignfile node are the original software engineering path and the hardware engineering path respectively:

1 <?xml version= "1.0" encoding= "UTF-8"?> 2 <sch:settings xmlns:sch= "http://www.altera.com/embeddedsw/bsp/ Schema "> 3         <BspType>hal</BspType> 4         <BspVersion>default</BspVersion> 5         <bspgeneratedtimestamp>2013-4-22 10:52:05</bspgeneratedtimestamp> 6         < Bspgeneratedunixtimestamp>1366599125093</bspgeneratedunixtimestamp> 7         <BspGeneratedLocation> D:\_prj\altera\de2_70_nios_vga\software\vga_bsp</bspgeneratedlocation> 8         <BspSettingsFile> Settings.bsp</bspsettingsfile> 9         <sopcdesignfile>d:\_prj\altera\de2_70_nios_vga\de2_70_ sopc.sopcinfo</sopcdesignfile>10         <jdifile>default</jdifile>11         <Cpu>cpu</Cpu >12         <schemaversion>1.9</schemaversion>13         <Setting>
...

Icon:

This will modify it to a new software engineering and hardware engineering path. Modified settings.bsp File:

1 <?xml version= "1.0" encoding= "UTF-8"?> 2 <sch:settings xmlns:sch= "http://www.altera.com/embeddedsw/bsp/ Schema "> 3         <BspType>hal</BspType> 4         <BspVersion>default</BspVersion> 5         <bspgeneratedtimestamp>2013-4-22 10:52:05</bspgeneratedtimestamp> 6         < Bspgeneratedunixtimestamp>1366599125093</bspgeneratedunixtimestamp> 7         <BspGeneratedLocation> E:\_prjbak\altera\de2_70_nios_vga\software\vga_bsp</bspgeneratedlocation> 8         <BspSettingsFile> Settings.bsp</bspsettingsfile> 9         <sopcdesignfile>e:\_prjbak\altera\de2_70_nios_vga\de2_70_ sopc.sopcinfo</sopcdesignfile>10         <jdifile>default</jdifile>11         <Cpu>cpu</Cpu >12         <schemaversion>1.9</schemaversion>13         <Setting>
...

Icon:

The red part is modified. Save. Then regenerate the BSP

Check the BSP information again and the new Sopcinfo file has been identified.

Recompile the original project (if you want to clean the original project and BSP project first), you can complete the compilation and build the executable file Elf

========================

Note: This method is adapted to the Quartu II 10.0/nios IDE 10.0 version, and for the Quartu II 10.0/nios IDE 10.0, the syslib configuration file System.stf file was modified. This file is similar to SETTINGS.BSP and is also an XML file:

 1 <?xml version= "1.0" encoding= "UTF-8" standalone= "no"?> 2 <stf> 3 <project ptf= "E:\Sample_SOPC\nios_s     YSTEM.PTF "target=" Nios II System Library "> 4 </project> 5 <cpu name=" Cpu_0 "> 6 </cpu> 7 <os_spec clean_exit= "yes" direct_drivers= "no" exception_stack= "no" instruction_emulation= "no" name= "None" ( single-threaded) "no_c_plus_plus=" no "no_exit=" no "profiling=" no "small_footprint=" no "sopc_component_dir=" Altera_ Hal "stack_checking=" no "stderr=" Jtag_uart_0 "stdin=" Jtag_uart_0 "stdout=" Jtag_uart_0 "> 8 <sys_defines> 9 &lt ;d efine name= "alt_max_fd" quote= "no" value= "all"/>10 <define name= "ALT_SYS_CLK" quote= "no" value= "None"/>11 <define name= "ALT_TIMESTAMP_CLK" quote= "no" value= "None"/>12 </sys_defines>13 <make_macros>14 < Macro Name= "Alt_sim_optimize" quote= "no" value= "0"/>15 </make_macros>16 </os_spec>17 <link_spec Aut o_gen_script= "yes" >18 <script name= "None"">19 <section memory=" Onchip_memory2_0 "name=". Text "/>20 <section memory=" Onchip_memory2_0 "name=". Rod ATA "/>21 <section memory=" Onchip_memory2_0 "name=". Rwdata "/>22 </script>23 </link_spec>24 </ Stf>

Only the third line of project PTF node content is changed to the PTF file path for the new hardware project.

Sopcinfo path Change, Nios project how to do?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.