Model Configuration Parameters for Simulink Support Package for Arduino Hardware

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 a value such as Arduino Pro.

  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).

See Also

Hardware board

Select the hardware board upon which to run your model.

Changing this parameter updates the dialog box display so that it displays parameters that are relevant to your hardware board.

To install support for a hardware board, start the Support Package Installer by selecting Get Hardware Support Packages. Alternatively, in the MATLAB® Command Window, enter supportPackageInstaller.

After installing support for a hardware board, reopen the Configuration Parameters dialog box and select the hardware board.

Settings

Default: None if the specified system target file is ert.tlc, realtime.tlc, or autosar.tlc. Otherwise, the default is Determine by Code Generation system target file.

None

No hardware board is specified. The system target file specified for the model is ert.tlc, realtime.tlc, or autosar.tlc.

Determine by Code Generation system target file

Specifies that the system target file setting determines the hardware board.

Get Hardware Support Packages

Invokes the Support Package Installer. After you install a hardware support package, the list includes relevant hardware board names.

Hardware board name

Specifies the hardware board to use to implement the system this model represents.

Tips

  • When you select a hardware board, parameters for board settings appear in the dialog box display.

  • After you select a hardware board, you can select a device vendor and type.

Dependencies

The Device vendor and Device type parameter values reflect available device support for the selected hardware board.

When you select a hardware board, the selection potentially changes the Toolchain parameter value and other configuration parameter values. For example, if you change the hardware board selection to ARM Cortex-A9 (QEMU), the Toolchain parameter value changes to a supported toolchain, such as Linaro Toolchain v4.8.

Command-Line Information

Parameter: HardwareBoard
Type: character array
Default: 'Determine by Code Generation system target file'

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo impact

See Also

Build Options

ParameterDescriptionDefault Value
Build Options

Option to specify whether you want only build or build, load, and run actions during code generation.

Build, load, and run

Host-board connection

ParameterDescriptionDefault Value
Set host COM portOptions to either automatically detect or manually set the COM port your computer uses to communicate with the hardware board.Automatically
Set COM port numberThe port on the computer that connects the Arduino® hardware to the computer.1
Bootloader COM portThe port on the computer that connects the Arduino bootloader to the computer.2

Simulink IO

ParameterDescriptionDefault Value
Enable Simulink IOOption to enable Simulink IO during Normal mode simulationSelected

Overrun detection

ParameterDescriptionDefault Value
Enable overrun detectionOption to enable overrun detectionNot selected

Analog input channel properties

ParameterDescriptionDefault Value
Analog input reference voltage

Option to set the reference voltage used to measure inputs to the ANALOG IN pins.

Default

Serial port properties

ParameterDescriptionDefault Value
Serial 0 baud rate, Serial 1 baud rate, Serial 2 baud rate, Serial 3 baud rate

Options to set the baud rate of the serial port on the Arduino hardware.

9600

I2C properties

ParameterDescriptionDefault Value
I2C Bus speed (Hz)

Option to specify the rate of data communication between the peripherals connected by the I2C bus.

100000

SPI properties

ParameterDescriptionDefault Value
SPI clock out frequency (in MHz)

Option to select a value from the list of master clock frequency to obtain an SPI clock frequency.

4000
SPI mode

Options to set an SPI mode for data transmission.

Mode 0 – Clock Polarity 0, Clock Phase 0
Bit order

Options to select the bit order for transmissions.

MSB first

Ethernet shield properties

ParameterDescriptionDefault Value
Use static IP address and disable DHCP

Option to disable the DHCP.

Selected
IP address (Ethernet shield)

The IP address of the Arduino Ethernet shield.

192.168.0.20
MAC address

The machine address of the Arduino Ethernet shield.

DE:AD:BE:EF:FE:ED

WiFi properties

ParameterDescriptionDefault Value
WiFi hardwareSelect the WiFi hardware that you use for Wi-Fi connectivity.WiFi shield
Use static IP address and disable DHCP

Option to disable the DHCP.

Not selected
IP address

Enter the IP address of the Arduino WiFi shield.

192.168.1.20
Service set identifier (SSID)The SSID of your network. yourNetwork
WiFi encryption

The WiFi encryption of the network to which you are connected.

None
WEP key

The WEP key of the network.

D0D0DEADF00DABBADEAFBEADED
WEP key index

The WEP key index of the network.

0
WPA passwordThe WPA password of the network. secretPassword
Hardware Serial PortSelect the port on the Arduino board that is connected to ESP8266.Serial 0

ThingSpeak properties

ParameterDescriptionDefault Value
Connect to custom ThingSpeak serverThe option to connect to the custom ThingSpeak server. Otherwise, the ThingSpeak block connects to the default address of 184.106.153.149 through port 80.Selected
Server IP address

Specify the IP address of the custom ThingSpeak server.

184.106.153.149
Port

Specify the port number through which the ThingSpeak block connects to the ThingSpeak server.

80

External mode

ParameterDescriptionDefault Value
Communication interface

Options that you can select for the ThingSpeak block to connect to the ThingSpeak server.

Serial — For AVR-based boards.

XCP on Serial — For ARM-based boards.

Logging buffer size (in bytes)Specify the memory buffer size for external mode communication.2048
VerboseThe option to view the External Mode execution progress and updates in the Diagnostic Viewer or in the MATLAB Command Window. Not selected