TCL command in Libero SOC [Microsemi] to generate the IP cores

actelfpgaliberomicrosemi-fpga

Does anybody knows the TCL command to generate the IP cores in a design for the Libero Soc tool of Microsemi (v11.4 SP1)?

So the IP core (e.g. a FIFO) is configured and in the design. However, the output files has still to be generated before the synthesis and implementation can be run.

I'm missing this TCL command because I would like to run everything in batch mode.
Exporting the GUI instructions to a TCL file is not generating that line of code :-9

Best Answer

This is an old question, but I couldn't find this information anywhere so I think it's helpful to add it here!

In Libero you can go to File -> Export Script File... and export a Tcl script with the commands that have been run in your current project - importing files, creating IP etc. If you create an IP core and then export the script file, you will see the basic building block for instantiating the IP, although none of your configuration options will be shown.

The following is what I got for instantiating a BIBUF, for example. Almost there, but not quite!

create_design -id {Actel:SgCore:IO:1.0.101} -design_name {sram_bidir} -config_file {} -params {} -inhibit_configurator 0

You can see the -params{} field in this command. This is what you use to configure the core, but annoyingly it's always empty in the exported script!

At least for the cores I have used, I have not found any documentation on the parameter names. Instead, I navigate my file explorer to the component definition in the Libero project directory structure: e.g.

[project's root folder] -> component -> work -> sram_bidir

In this folder there is a ".cxf" file, which is basically an XML file with all the core's parameters defined. The parameters for the core are those contained in the <configurableElement> tag e.g. for the BIBUF:

<configurableElement referenceId="IO_TYPE" value="BIBUF"/>

This information can then be used to configure the core in the Tcl command as follows:

create_design -id {Actel:SgCore:IO:1.0.101} -design_name {sram_bidir} -config_file {} -params {IO_TYPE:BIBUF} -params {WIDTH:32} -inhibit_configurator 0

It's a bit trial and error, but I have gotten several cores working this way.

Related Topic