Model Configuration Simulink Coder Support Package for STMicroelectronics Nucleo Boards

Hardware Implementation Pane Overview

  1. In the Simulink® Editor, select Simulation > Model Configuration Parameters.

  2. In the Configuration Parameter dialog box, click Hardware Implementation.

  3. Set the Hardware board parameter to one of the Nucleo boards, for eg.STM32 Nucleo F302R8.

  4. The parameter values under Hardware board settings are automatically populated to their default values.

    You can optionally adjust these parameters for your particular use case.

  5. Click Apply to apply the changes.

For more information on selecting a hardware support package and general configuration settings, see Hardware Implementation Pane (Simulink).

Build options


Build action

Defines how Embedded Coder® responds when you build your model.

Set host drive

The option to copy the generated output bin file automatically or manually to a drive.


The drive on which to copy the generated output bin file manually.



CPU Clock (MHz)

The CPU clock frequency in MHz.



Bus speed (in Hz)

Defines the rate of data communication between the peripherals connected by the I2C bus.
Serial clock (SCL) pin

Sets serial clock (SCL) pin.

Serial data (SDA) pin

Sets serial data (SDA) pin.



Bus speed (in Hz)

Master output slave input (MOSI) pinThe pin that connects the master output to the slave input.
Master input slave input (MISO) pinThe pin that connects the slave output to the master input.
Clock (SCK) pinThe clock pin for SPI communication.


Baudrate (in Hz)

Defines how fast the data is sent over a serial line.

Receive pin

Sets the receiving pin of UART.

Transmit pin

Sets the transmitting pin of UART.

Data bits length

Sets the number of data bits to transmit.


Sets the type of parity checking to identify low-level errors.

Stop bits

Sets the number of stop bits to indicate end of a packet.



PIL communication interface

The serial interface used for PIL communication
Serial portThe serial port for PIL communication

External mode

Build Options

Communication interfaceThe option is used for running your model in External mode with serial communication
Serial portThe serial port used by the target hardware
VerboseThe option to view the External mode execution progress and the updates in Diagnostic Viewer or MATLAB Command Window