5.11 Handoff Design for Firmware Development (SmartFusion 2 and IGLOO 2)
(Ask a Question)The following sections apply to SmartFusion 2 and IGLOO 2 devices only.
5.11.1 Software IDE Integration (SmartFusion 2 and IGLOO 2)
(Ask a Question)Libero SoC simplifies the task of transitioning between designing your FPGA to developing your embedded firmware.
Libero SoC manages the firmware for your FPGA hardware design, including:
- Firmware hardware abstraction layers required for your processor
- Firmware drivers for the processor peripherals that you use in your FPGA design
- Sample application projects are available for drivers that illustrate the proper usage of the APIs
To see which firmware drivers Libero SoC has found to be compatible with your design, open the Firmware View. From this view, you can change the configuration of your firmware, change to a different version, read driver documentation, and generate any sample projects for each driver.
Libero SoC manages the integration of your firmware with your preferred Software Development Environment, including SoftConsole, Keil, and IAR Embedded Workbench. The projects and workspaces for your selected development environment are generated automatically with the proper settings and flags so you can write your application immediately.
5.11.2 Viewing/Configuring Firmware Cores (SmartFusion 2 and IGLOO 2)
(Ask a Question)The Design Firmware tab allows you to select and configure firmware cores (drivers) for your Software IDE project. The tab lists the compatible firmware for the hardware you instantiated in your design.
To display the Design Firmware tab in the Design Flow tab, expand Create Design and double-click View/Configure Firmware Cores.
The Firmware table lists the compatible firmware and drivers based on the hardware peripherals used in your design. Each row represents a firmware core that is compatible with a hardware peripheral in your design. The following table describes the columns in the Firmware table.
Column | Description |
---|---|
Generate | Choose whether you want the files for this firmware core to be generated on disk and added to your Software IDE project. Click the checkbox to generate firmware for each peripheral in your design. |
Instance Name | Name of the firmware instance. This can help to identify firmware cores when you have multiple firmware cores with the same Vendor:Library:Name:Version (VLNV) in your design. |
Core Type | Name from the VLNV ID of the core. This name generally corresponds to the name of the hardware peripheral with which the firmware core is compatible. |
Version | Firmware core version. Use the drop-down menu to upgrade or choose a different version. |
Compatible Hardware Instance | Hardware instance in your design that is compatible with this firmware core. |
5.11.2.1 Downloading Firmware
(Ask a Question)Libero attempts to find compatible firmware located in the IP Vault located on your disk, as well as firmware in the IP Repository via the Internet.
If compatible firmware is found in the IP repository but not on your disk, the row will be italicized, indicating that it needs to be downloaded. To download all firmware cores necessary for your project peripherals, click the Download All Firmware icon in the vertical toolbar.
Libero IDE Fails to Connect to Default Repositories over the Internet
If Libero IDE fails to connect to the web repositories on a computer connected to the Internet, it typically means that the connection is being blocked by a network firewall or that the Internet connection is made via a proxy server. Verify that the URLs shown in your catalog options window are correct:
.- From the Libero IDE toolbar, go to Proxy tab. and click the
- Check the Use a Proxy Server check box.
- Enter the Proxy Server name on the network. In most cases, using the proxy server name solves the problem. If the server name does not work, enter the IP address of the proxy server.
5.11.2.2 Configuring Firmware
(Ask a Question)Firmware cores that have configurable options will have a wrench icon in the row. Click the wrench icon to configure the firmware core.
It is important that you check the configuration of your firmware cores if they have configurable options. They might have options that target your software IDE (Keil, IAR, or SoftConsole), or your processor, that are vital configuration options for the system to work properly.
5.11.2.3 Generating Firmware
(Ask a Question)Click the UI control icon to export the firmware drivers and software IDE project for your project. The firmware drivers are generated into <project>\firmware and the software workspace is exported to <project>\<toolchain>.
<toolchain> could be SoftConsole, IAR, or Keil, depending on your software IDE. The firmware drivers are also copied into the <toolchain> folder.
5.11.2.4 Changing Firmware Core Versions
(Ask a Question)You can manually change to the latest version by selecting the drop-down in the Version column.
There will often be multiple versions of a firmware cores available for a particular peripheral. The MSS Configurator selects the latest compatible version for a new design.
However, once the firmware is added to your design, Libero will not automatically change to the latest version if one becomes available.
5.11.2.5 Generating Sample Projects
(Ask a Question)Firmware cores are packaged with sample projects that demonstrate their usage. They are packaged for specific tool chains, such as Keil, IAR, and SoftConsole
- Right-click the firmware core
- Choose Generate Sample Project
- Select your IDE tool chain (such as Keil) and choose from the list of available samples.
You will be prompted to select the destination folder for the sample project.
Once this project is generated you can use it as a starting point in your Software IDE tool or use the example project as a reference on how to use the firmware driver.
5.11.2.6 Fabric Peripherals
(Ask a Question)Libero SoC also attempts to find compatible firmware for soft (fabric) peripherals that you have added in your top- level SmartDesign if that top-level is Set as Root.
To set your top-level design as a root, right-click your top-level design in the Design Hierarchy and choose Set as Root. The root component appears in bold.
The following figure shows CoreGPIO, CorePWM, and CoreUARTapb soft cores that are added into your top-level SmartDesign.
5.11.3 Exporting Firmware (SmartFusion 2 and IGLOO 2)
(Ask a Question)When your design is completed, you can export the design firmware configuration using the Export Firmware tool. The firmware configuration contains:
- Register configuration files for MSS, FDDR, and SERDES blocks instantiated in your design. This information, along with the SmartFusion 2 CMSIS firmware core, must be compiled with your application to have proper Peripheral Initialization when the Cortex-M3 boots.
- Firmware drivers compatible with the hard and soft peripherals instantiated in your design.
- In the Libero SoC Design Flow window, under Handoff Design for Firmware Development, double-click Export Firmware. The Export Firmware dialog box appears.
- Complete the fields in the dialog box.
- Click OK.
Field | Description |
---|---|
Location | Location where you want the firmware configuration files to be exported. When you export the firmware, Libero SoC creates a Firmware folder to store all the drivers and register configuration files. |
Software IDE: <selected Software Tool Chain> | Libero SoC creates the firmware project for the IDE tool of your
choice and stores the projects in the folder
SoftConsole/IAR/Keil (per your
choice) . |
Export hardware configuration and firmware drivers | This option is selected by default. This setting exports register configuration files for MSS, FDDR, and SERDES blocks instantiated in your design. CMSIS and other firmware drivers must be generated using the stand-alone Firmware Catalog executable. These options are available to support SoftConsole 4.0 flow. |
Create software project including hardware configuration and firmware drivers |
To enable you to manage your firmware project separately from
Libero’s automatically generated firmware data, the created software
workspace contains two software projects:
To build your workspace, have the To open your exported firmware projects, start your third-party development tool (SoftConsole, Keil, or IAR) outside Libero SoC and point it to the exported firmware workspace. |
5.11.3.1 TCL Command
(Ask a Question)export_firmware \
-export_dir
{D:\Designs\software_drivers} \
-create_project 1
\
-software_ide {Keil}
5.11.3.2 Version Supported
(Ask a Question)Libero SoC v11.7 and later supports the following versions of third-party development tools:
- SoftConsole v4.0
- SoftConsole v3.4
- IAR EWARM
- Keil