S32 Design Studio (S32DS) for ARM supports IAR Plugin, and the user can use IAR specific features in S32DS with IAR toolchain for ARM.
This document describes the way to convert S32DS project to IAR EW based project using project exporting wizard in S32DS. This guidance is based on the NXP S32K144 microcontroller, and compatible with S32K14x / S32K11x family.
The version of each IDE which is used for this document is as follows:
S32 Design Studio for Arm 208.R1
IAR Embedded Workbench for ARM 18.104.22.16831
1. Install IAR Plugin using IAR Embedded Workbench plugin manager on S32DS
- Help - Install New Software
- Put "IAR Embedded Workbench for Eclipse " as the repository for new installation of software.
- Help - IAR Embedded Workbench Plugin Manager
- Install IAR Plugin which is matched with your IAR version.
2. Create S32DS Project
- File - New - S32DS Application Project
- The tool chain should be chosen as IAR Toolchain. Be noted that the IAR 7.x toolchain is different from the IAR 8.x.
- The project is created as follows.
3. Export S32DS Application Project
- File - Export
- Choose S32 Design Studio - Project Info Export Wizard
- Now "ProjectInfo.xml" was created. "ProjectInfo.xml" should be used for creating a project in the IAR EW.
4. Create IAR EW Project
- The way to create IAR project as described below. The snapshots are based on IAR EW 8.32.1. Details may vary.
5. Connect the Project
- Use the menu - Project - Add Project Connection, and choose "Freescale Processor Expert".
- Select the "ProjectInfo.xml" file which was created at step #3.
Now, the project which had been created in IAR was connected to the S32DS project.
The created IAR project should be modified if the user wants to use the project with S32DS SDK to build and debug under IAR EW environment as follows.
1. Modify the Linker configuration and remove ProjectInfo.xml
- Remove "ProjectInfo.xml"
- Linker configuration from the project Options
Even though the user modified the linker configuration, a definition in IAR EW for "device_registers.h" from SDK will cause build error when trying building the project.
This error will be eliminated by inserting Chip specific definition into IAR project. If you take a look into the "device_register.h", you can find the definition as follows.
2. Define symbols
- Right mouse click on the Project name - Options
- Write the symbols referred from "device_register.h". The symbols may vary (e.g., CPU_S32K146, CPU_S32K142, ...).
3. Build and Debugger configuration
- Options - Debugger
- I used PE micro's OpenSDA on S32K144EVB for this document. After choosing debugger and clicking Download and Debug (Ctrl+D), you can see the P&E Configuration Manager as follows. Just choose appropriate configuration, and select the correct part number of S32K by clicking Select New Device.
Finally, you can download and debug the converted IAR EW project with S32DS SDK.