hero image
Our Products
NXP Semiconductors NV

Startup Guide: Trying out the FRDM-A-S32K312

NXP Semiconductors NV
NXP Semiconductors NV
  • NXP Semiconductors NV
  • NEXT Mobility

This book outlines the procedures for setting up the development environment for NXP's automotive evaluation board, FRDM-A-S32K312.
The first half will explain how to install the development environment and related packages. The second half will show you the steps to obtain sample code from Application Code Hub and run it on the evaluation board.
*FRDM: This is the name of an evaluation board provided by NXP, and is pronounced "Freedom".

Overview of this initiative

FRDM Automotive allows you to obtain a complete set of software required for your target board (S32 Design Studio, RTD, communication stack, etc.) as a "bundle" through their Automotive Software Package Manager.

Prerequisites
  • You must have an NXP account.
  • Target board: FRDM-A-S32K312

FRDM-A-S32K312 overview

The FRDM-A-S32K312 is an evaluation board equipped with NXP's automotive microcontroller S32K312 (Arm Cortex-M7, 120 MHz, 2 MB Program Flash, 172-pin HDQFP). It also features CAN TRANSCEIVER (TJA1463), LIN TRANSCEIVER (TJA1022), and a system basis chip (SBC: FS26).
Because it has an onboard debugger (K26), you can program and debug using only a USB Type-C CABLES and a PC. It also has a 10-pin Arm Cortex debug CONNECTORS, so you can connect an external debugger for debugging.

In addition, it features a DC JACKS for external POWER SUPPLIES input, an RGB LED for operation confirmation, two user push buttons, and a RESET button. Furthermore, it supports Arduino header-compatible pinouts, allowing for the connection and evaluation of various expansion boards.

Figure 1 FRDM-A-S32K312

NXP Getting Started Guide and Sign In

Open the Start Guide page

Open the "Getting Started with the General-Purpose Automotive FRDM S32K312 Development Board" page on the NXP website. Follow the steps, such as "1. Package Contents," and then go to the Automotive Software Package Manager via the S32K3 FRDM Automation Bundle link on the "2.1 Software Installation" page (a sign-in screen will appear if you are not signed in).
Automotive Software Package Manager is a web tool for generating software bundles to install.

Figure 2 FRDM S32K312 Start Guide Page

Figure 3: Software acquisition screen

Enter your email address

On the "Sign in to your NXP account" screen, enter your registered email address and click "CONTINUE".

Figure 4: Sign-in screen (enter email address)

Enter your password

Enter your password and click "SIGN IN". Check the "Keep me signed in" option if necessary (uncheck it on shared PCs).

Figure 5 Password entry screen

Enter the one-time password code.

Enter the one-time password code displayed in your smartphone's authentication app (Authenticator) into the "Verification Code" field and click "VERIFY".

Figure 6 One-time password displayed in the authentication app

Figure 7 Entering the One-Time Password Code

*If an error message is displayed, please enter the one-time password again.
*The one-time password code is updated every 30 seconds. Please enter the latest code.

Figure 8 When an error occurs

Having trouble signing in?

Please refer to the "My NXP Account FAQ" for helpful information on how to create an NXP account, troubleshooting if you can't sign in, multi-factor authentication, and more.

Bundle generation (Automotive Software Package Manager)

After signing in, the Automotive Software Package Manager will open.
*If you see the message "Please wait while your session is being created," please wait until the session creation is complete.

Figure 9: Display during session creation

Select a device and bundle

On the left side, under DEVICES, check the box for General-Purpose MCUs > S32K3.
On the right side, under SDK, BUNDLES AND USE CASES, check the box for "FRDM Automotive Board Installation Package," and then click "GENERATE BUNDLE INSTALLER" at the bottom of the screen.

Figure 10: Selection between S32K3 and FRDM Automotive Board Installation Package

Check the package contents.

In "Review package selection," review and select the packages to add to the bundle. In this example, we select Real-Time Drivers 7.0.0 QLP03 and S32 Design Studio and Configuration Tools 3.6.5 and click "NEXT" (FreeMASTER, LIN Stack, FreeRTOS, TCP/IP Stack, etc. are also available as selections).

Figure 11: Review package selection

Enter export control information.

In the Export Control Export Compliance Project Inquiry form, enter the product/project type (e.g., Automotive) and application (e.g., development and evaluation of in-vehicle ECUs), and then click "SUBMIT EXPORT CONTROL".

Figure 12 Export Compliance Project Inquiry Input

Confirmation of passing export control checks

The message "The following packages have passed export control checks." will appear, and once the selected packages (Real-Time Drivers 7.0.0 QLP03, S32 Design Studio and Configuration Tools 3.6.5) are listed, click "NEXT".

Figure 13 Confirmation of passing export control checks.

I agree to the license.

Read the entire "License Agreement" and click "I ACCEPT THE TERMS OF THE LICENSE AGREEMENT" at the bottom of the page (you cannot click this until you scroll to the bottom).

Figure 14 Agreeing to the Bundle Generation License Agreement

Click "DONE" in "Generate bundle installer".

Figure 15 Generate bundle installer screen

Wait for the bundle to be generated.

A message will appear in the lower left corner of the screen saying, "Your bundle is being created. This may take a few moments. You'll be notified when it's ready." The download will start automatically when it's ready.

Figure 16 Display during bundle generation

Check the downloaded files.

After a short while, "NXP_Multi_Installer_XX.XX.XX.XXXXXX_setup.exe" and "NXP_Multi_Installer_XX.XX.XX.XXXXXX_User_Manual.pdf" will be saved to your "Downloads" folder.
*The XX.XX.XX.XXXXXX part of the file name represents the date and time of download.

Figure 17 Download folder

*If the download does not start automatically, please click the link in the lower left corner of the screen that says "If your download does not start automatically, please click here to download it manually."

Figure 18: What to do if the download does not start automatically

Download and install using NXP Multi Installer

What is NXP Multi Installer?

NXP Multi Installer is a tool for installing necessary software, such as Real-Time Drivers (RTDs), using software bundles generated by the Automotive Software Package Manager.

Start the setup wizard.

When you run the downloaded NXP_Multi_Installer_XX.XX.XX.XXXXXX_setup.exe, the "Welcome to the NXP Multi Installer Setup Wizard" will appear. Click "Next >".
*As shown in the wizard, the download link within the bundle has an expiration date (approximately 2 hours). If the expiration date has passed, please regenerate the bundle using the Package Manager.

Figure 19 Starting the Setup Wizard (NXP Multi Installer Setup Wizard)

Review the License Agreement (LA_OPT_NXP_Software_License) and click "I Agree".

Figure 20: Agreeing to the Installer's License Agreement

On the "Choose Components" screen, select the configuration you want to install. Select "Full" under "Select the type of install," make sure that "Real-Time Drivers" and "S32 Design Studio and Configuration Tools" under S32K3 → Bundles are checked, and then click "Next >".

Figure 21 Selecting Installation Configuration (Choose Components)

On the "Choose Download Location" screen, specify the folder where you want to download the package. If the default folder is acceptable, leave it as is. If you want to change it, select the desired location using "Browse..." and then click "Next >".

Figure 22 Specifying the download destination folder (Choose Download Location)

On the "Ready to Download the Packages" screen, click "Download". If you want the executable file to launch automatically after downloading, check the box for "Launch executable files after download". We will check this box this time.

Figure 23 Confirmation of download start (Ready to Download the Packages)

The download and installation of each package (S32 Design Studio 3.6.5 main program, Real-Time Drivers (RTD)) will be performed automatically.

Figure 24 Package download and installation in progress.

In the Advanced Configuration, the S32 Design Studio itself is installed first.
*This process will take some time to complete.

Figure 25: Installation of S32 Design Studio

Next, Real-Time Drivers (RTD) v7.0.0 will be installed.

Figure 26 Installation of Real-Time Drivers (RTD)

Once "Completed" is displayed on the "Advanced Configuration" screen, click "Next >".
*The log will contain [FAILED], but since FreeMASTER was not downloaded this time, we will proceed to the next step.

Figure 27 Advanced Configuration (Completed)

After the "Download Complete" screen displays "Download of the packages completed successfully," click "Next >" to exit the wizard.

Figure 28 Confirmation of Download Completion

Click "Finish" on the "Completing the NXP Multi Installer Setup Wizard" screen to exit the wizard.

Figure 29 Successful Completion

Precautions

  • *The download link for the bundle will expire after a certain period of time (approximately 2 hours) from the time of generation. If you plan to install after some time has passed, please regenerate the bundle from the Package Manager's History page.

Starting and initial setup of S32 Design Studio

Launch S32 Design Studio

Search for "S32 Design Studio" in the Start menu and launch it.

Specify your workspace (where settings and projects are saved) under "Select a directory as workspace" and click "Launch". If you always want to use the same location, check "Use this as the default and do not ask again".

Figure 30 Workspace Selection

Precautions

  • Please do not include Japanese characters (full-width characters) in your workspace path.
  • Please place your workspace in the shortest possible path (ideally, a path length of less than 200 characters).
  • Please use a folder on your local drive, not one stored under cloud storage such as OneDrive or Google Drive.
  • Network drives and folders where background syncing is performed may cause build errors or project corruption.

Recommended examples

C:\Users\(username)\workspaceS32DS.3.6.5
S32 Design Studio will launch and the "WELCOME TO S32 DESIGN STUDIO IDE" screen will be displayed.

Figure 31: Initial startup of S32 Design Studio IDE

If "S32DS Extensions and Updates" appears, click "Cancel" to close it.
* "S32DS Extensions and Updates" is a feature for installing and updating additional features and software packages (RTDs, plugins, etc.) in S32 Design Studio.
In this procedure, the necessary packages have already been installed using NXP Multi Installer, so you do not need to perform any additional installations from this screen.

Figure 32 S32DS Extensions and Updates (Close with Cancel)

Click the "x" to the right of "Getting Started".

Figure 33 Close the Getting Started tab.

Figure 34: Main screen of S32 Design Studio IDE

Connection method

Now, connect the S32K312 development board to your computer. Use the included USB-C CABLES or a PD-compatible CABLES. The following steps are excerpts from "3. Connection" in the Start Guide for the General Purpose Automotive FRDM S32K312 Development Board.

Figure 35 Connection

Power is supplied via the J9 USB-C CONNECTORS on the board. To supply power from the USB-C CONNECTORS (J9), ensure that jumpers J19 and J20 are in position 1-2.

Figure 36 Jumper settings

After checking the jumper settings, plug the USB-C TERMINALS into the J9 CONNECTORS. If you are debugging using the onboard S32K3 debugger, connect the USB-C CABLES to the same J9 CONNECTORS.

Figure 37 USB CONNECTORS

The PC and USB-C CABLES are connected. When power is supplied to the board, the red LED (D9: status indicator for the onboard debugger OpenSDA) lights up, indicating that power is supplied and the debugger is ready.

Figure 38 After connecting the USB CONNECTORS

Get sample code from Application Code Hub

Open Application Code Hub from S32 Design Studio.

Application Code Hub (ACH) is a collection of sample code provided by NXP. You can obtain sample projects for microcontrollers and evaluation boards and use them for functional evaluation and application development.
This is the screen you see immediately after launching S32 Design Studio. Import your project from the "Dashboard" panel in the lower left.

Figure 39 shows the S32 Design Studio screen (the Dashboard is in the lower left).

Figure 40 is a magnified view of the Dashboard in the lower left of the image above. Select "Import Project from Application Code Hub" under "Create or Import Project".

Figure 40 Selecting "Import Project from Application Code Hub" (Dashboard)

Search for sample code

Specify S32K for Device Families and S32 Design Studio IDE for Toolchains, then search for "S32K312". From the list, select "Controlling LEDs with GPIO".

Figure 41: List of projects in Application Code Hub (Search for S32K312)

Check the contents of the sample code.

The "Controlling LEDs with GPIO" description will be displayed. It will include information such as the target board (FRDM-A-S32K312), category, peripherals used (SIUL2 / Clock), and toolchain (S32 Design Studio IDE), so please check the details.

Figure 42 Details of the "Controlling LEDs with GPIO" project

After reviewing the contents of the project to be imported, "Controlling LEDs with GPIO," click "GitHub link," then click "Next >" to start cloning.

Figure 43 Project cloning started

Importing a project into S32 Design Studio

Import as an Eclipse project

In the import wizard, proceed by clicking "Next >" on the default settings unless otherwise specified. Select "Import existing Eclipse projects" and proceed by clicking "Next >", then select the project in the repository (Controlling LEDs with GPIO), and finally click "Finish".

Figure 44 Branch Selection for Cloning

Figure 45 Specifying the clone destination (Local Destination)

Figure 46 Import Wizard Selection (Import existing Eclipse projects)

Figure 47 Confirmation and completion of the project to be imported (Finish)

The project will be added to the Project Explorer on the left.

Figure 48 Projects added to Project Explorer

Note: Check the content from your browser.

The same information can also be viewed in a browser. Access the Application Code Hub (mcuxpresso.nxp.com/appcodehub) from NXP's Getting Started Guide, section 4, "Build and Run," and then refine your search using Device Families and Toolchains.

Figure 49 Getting Started "4. Build and Run"

Figure 50 Sample code search in Application Code Hub (browser)

Figure 51 Explanation of sample code (Controlling LEDs with GPIO) (browser)

Code generation and build

Update the code and build the project.

Right-click the project in Project Explorer and select "Update Code and Build Project". This will generate the configuration (Pins / Clocks / Peripherals) and update the source code, then build the project with the active configuration (e.g., Debug_FLASH).

Figure 52 Update Code and Build Project (right-click menu)

Figure 53 Configuration generation in progress

If you see "Build Finished. 0 errors" or similar in the Console, the build was successful.

Figure 54 Build complete (Console: 0 errors, 0 warnings)

When you encounter build errors...

If your build does not complete with 0 errors, please check the following. Here are some common causes and solutions.

  • ① If the RTD (Real-Time Drivers) are not installed or are of a different version, errors will occur during code generation and building if the version of the RTD referenced by the project does not match the RTD installed in S32 Design Studio. Please select and install the RTD using the Automotive Software Package Manager.
  • ② Missing generated code files (Update Code not executed): If you build before generating the configuration, the expected header/source files (e.g., StandardTypes.h) will not be found, resulting in a "No such file or directory" error. Right-click on the project and select "Update Code and Build Project" (Figure 52) to complete code generation before building. *

*Reference: NXP Community “S32K344 Build fail: Missing Include Paths (Std_Types.h) with RTD 7.0.0”

Flash writing and debug execution

Open debug configuration

Open the "Run" → "Debug Configurations" menu. Select the debug configuration for this project (e.g., FRDM_A_S32K312_GPIO_BLINKY_Debug_FLASH_PNE) and click "Debug".

Figure 55 Open Debug Configurations (Run menu)

Figure 56 Debug Configurations (List of debug configurations)

When debugging is started with the FRDM-A-S32K312 connected via USB, an .elf file is written to the flash memory.

Figure 57 Debug configuration Main tab (running in Debug mode)

Figure 58 Progress display during debug startup preparation (Progress Information)

Click "Switch".

Figure 59 Confirm Perspective Switch (Click Switch)

Program execution

When debugging is started, the program stops at the beginning of main().

Figure 60: Stopped at the breakpoint in main()

Clicking the "Resume" button will execute the program.

Figure 61 Resume button on the debug control toolbar

When you run the program, the LED will blink periodically.

Figure 62 LED ON

Figure 63 LED OFF

Debugging will now end.

After confirming that it is working correctly, click the Terminate button (red square button) on the debug control toolbar to end debugging.

Figure 64 Debugging Termination

When you encounter a debugging error...

If you encounter any of the following errors, it may indicate that the evaluation board is not properly connected.

  • Please ensure that the PC and the evaluation board are connected via a USB CABLES.
  • In some cases, the connection may fail due to a broken USB CABLES, so please try replacing it with a different USB CABLES.
  • The driver may not be working for some reason, so please restart your PC.
  • If it still doesn't work, please try uninstalling and then reinstalling S32 Design Studio.

Figure 65 Example of a debug startup error (Problem Occurred)

Summary

By using the FRDM Automotive software bundle, you can efficiently obtain and install a complete development environment including S32 Design Studio and RTD. Following the procedures in this manual, you can complete the installation of S32 Design Studio and RTD, and build the development environment for FRDM-A-S32K312.

If you are interested, please feel free to Inquiry Nexty Electronics.

Related Product Information 

Link to Related Technical Columns