Getting started
This section covers the ways to get started using IAR Embedded Workbench with ModusToolbox™ software.
Create new application
Creating an application includes several steps:
Step 1: Open Project Creator tool
The ModusToolbox™ Project Creator tool is used to create applications based on code examples and template applications. By default, the tool is installed in the following directory:
<install-path>/ModusToolbox/tools_<version>/project-creator
The tool is provided in GUI form and as a command line interface. For more details, refer to the
Project Creator user guide
.
You can open the tool from the Windows
Start
menu, or by launching the executable in the installation directory.
Note:
You can also launch the Project Creator tool from the ModusToolbox™ Dashboard. Refer to the
Dashboard user guide
for more details.
Step 2: Choose Board Support Package (BSP)
When the Project Creator tool opens, expand one of the BSP categories under
Kit Name
and select an appropriate kit; see the description for it on the right.
For this example, select the
CY8CKIT-062S2-43012
kit. The following image is an example; the precise list of boards available in this version will reflect the platforms available for development.

Step 3: Select application
Click
Next >
to open the Select Application page.
This page displays example applications, which demonstrate different features available on the selected BSP. In this case, the CY8CKIT-062S2-43012 provides the PSOC™ 62 MCU and the AIROC™ CYW43012 Wi-Fi & Bluetooth® combo chip. You can create examples for PSOC™ 6 MCU resources such as CAPSENSE™ and QSPI, as well as numerous examples for other capabilities.
Click
Browse…
next to
Application(s) Root Path
to create or specify a folder where the application will be created.
Pull down the
Target IDE
menu, and select IAR Embedded Workbench.
Under the
Template Application
column, expand
Getting Started
and select Hello World from the list. This example exercise uses the PSOC™ 6 MCU to blink an LED.
Note:
The actual application names available might vary.
Type a name for your application and/or BSP or leave the default name. Do not use spaces. Also, do not use common illegal characters, such as:
* . " ‘ / \ [ ] : ; | = ,
Step 4: Create application
Click
Create
to start creating the application. The tool displays various messages.
When the process completes, a message states that the application was created. Click
Close
to exit the Project Creator tool.
Export existing application
If you have a ModusToolbox™ application that was created for another IDE or for the command line, you can export that application to be used in IAR. Open a terminal window in the application directory, and run the command
make ewarm CY_IDE_PRJNAME=[project-name] TOOLCHAIN=IAR
.
Note:
For applications that were created using core-make-3.0 or older, you must use the
make ewarm8
command instead.
This sets the
TOOLCHAIN
to IAR in the Embedded Workbench configuration files but
not
in the ModusToolbox™ application's Makefile. Therefore, builds inside IAR Embedded Workbench will use the IAR toolchain, while builds in the ModusToolbox™ environment will continue to use the toolchain that was previously specified in the Makefile. You can edit the Makefile's
TOOLCHAIN
variable if you also want ModusToolbox™ builds to use the IAR toolchain.
See
Configure and build the application
for instructions and information about various flags.
Open application in IAR Embedded Workbench
After creating or exporting an application, an IAR project connection file (.ipcf) appears in the ModusToolbox™ application/project directory This an XML file that contains the hierarchy of all the files and directories from the original ModusToolbox™ application. For example:
Hello_World.ipcf
Note:
If you are working with a multi-core or multi-project application, .ipcf files are created in the sub-project directories. See
Create IAR workspace and projects
for instructions instead.
Start IAR Embedded Workbench.
If you have a previous Embedded Workbench workspace (.eww) open, close it and create a new one inside the ModusToolbox™ application directory.
On the main menu, select
Project > Create New Project > Empty project
and click
OK
.
Browse to the ModusToolbox™ application directory, enter a desired IAR Embedded Workbench project (.
ewp
) name, and click
Save
.
Select
Project > Add Project Connection
and on the dialog ensure that "IAR Project Connection File" is selected; click
OK
.
On the Select IAR Project Connection File dialog, select the .
ipcf
file and click
Open
:
After the project has been created, select
File > Save Workspace
. Then if needed, enter a desired workspace name (.
eww
).
Note:
If you subsequently add more files and libraries in the ModusToolbox™ environment, you need to run "make ewarm" again to update the .ipcf file in the IAR Embedded Workbench project. For example:
make ewarm TOOLCHAIN=IAR CY_IDE_PRJNAME=Hello_World
If you don't use the
CY_IDE_PRJNAME
option, the generated ipcf file will revert to the original code example name, and it will not update your application.
If you don't care about staying connected to the ModusToolbox™ tools that generate the project files, you can delete the .ipcf file from the workspace and restart IAR Embedded Workbench.
If you want to make changes in IAR Embedded Workbench, you need to do that at the workspace level using the
Add
option. These additions will not be included in the .ipcf file.