A newer version of this document is available. Customers should click here to go to the newest version.
5.1.1. Initializing a Intel® Simics® Project and Deploying a Virtual Platform
After the Intel® Simics® simulator is installed, you must initialize a Intel® Simics® project. Initializing a Intel® Simics® project prepares a directory for use by Intel® Simics® Simulator. You can create a new directory or use an existing directory as a Intel® Simics® project directory. You must initialize a Intel® Simics® project before you can do anything else in the Intel® Simics® project directory. However, you can also initialize a Intel® Simics® Project in conjunction with deploying a Intel® Simics® virtual platform.
During the project initialization, some trampoline files are created. These trampoline files correspond to executable files that are linked to files under the Intel® Simics® simulator installation directory. ./simics and ./simics-gui files are examples of trampoline files.
If you reinitialize a Intel® Simics® project, the virtual platforms are not deployed because files created when deploying a virtual platform already exist.
After the Intel® Simics® project initialized, you can deploy the virtual platform. Deploying a virtual platform initializes the Intel® Simics® project directory as a Intel® Simics® simulator workspace and copies all the files required to enable the virtual platform to the Intel® Simics® project directory. These files can include .simics scripts, Python components, DML models, and documentation.
Use the simics_intelfpga_cli command (in the <simics_installdir>/simics/bin directory) to both initialize a project and deploy a virtual platform. The following command options are typically used when you initialize a project and deploy a virtual platform:
Argument | Description |
---|---|
--help | Shows the description of the command and arguments supported. |
--list-platforms | Lists all virtual platforms available. |
--deploy | Deploys a specific virtual platform initializing the current directory as a Intel® Simics® simulator workspace and copies all required files to the directory (components required by the virtual platform and the target script itself). |
--reinitialize | Reinitializes an existing directory. This option only initializes the current directory as a Intel® Simics® simulator workspace, but it does not copy files to this directory. This is expected to be used when required files already exist. |
--force | Forces deploy if files already exist. |
--pltaform-info | Gives detailed information on a platform. |
The typical flow of initializing a project and deploying a virtual platform is as follows:
- Create a project directory and change directories to it:
mkdir <projectDir> cd <projectDir>
- List the available platforms:
<simics_installdir>/simics/bin/simics_intelfpga_cli --list-platforms
- Initialize the project directory and deploy a virtual platform:
<simics_installdir>/simics/bin/simics_intelfpga_cli --deploy <virtual_platform>
This command creates the target script corresponding to the virtual platform selected ( <virtual_platform>.simics) in the <projectDir>/targets/<virtual_platform> directory.
If you only want to reinitialize the project directory without the platform deployment, run the following command:
<installDir>/simics/bin/simics_intelfpga_cli --reinitialize
- Customize the virtual platform. Component that you can customize are described later.
- Build the virtual platform:
make
Note: The Linux system must support make and gcc commands as indicated in Installing the Intel Simics Simulator for Intel FPGAs on Linux* Systems. - Run the simulation with target script (.simics):
./simics <projectDir>/targets/<virtual_platform>/<virtual_platform>.simics
./simics-gui <projectDir>/targets/<virtual_platform>/<virtual_platform>.simics