Main Content

Model Configuration Parameters for Android Devices

Hardware Implementation Pane Overview

Configuration Parameters > Hardware Implementation

  1. On the Modeling tab of the toolstrip, select Model Settings.

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

  3. Set the Hardware board parameter to Android Device.

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

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

Operating System Options

ParameterDescriptionDefault Value

Base Rate Task Priority

Sets the static priority of the base rate task in the operating system.

40

Build Options

ParameterDescriptionDefault Value

Build Action

Defines how Simulink® responds when you build your model.

Build, load, and run

Device Options

ParameterDescriptionDefault Value

Device

Device where the packaged Android® application gets deployed.

No devices detected

App Options

ParameterDescriptionDefault Value

App Options

Defines the unique Android application package name.

com.example

Create Android library module for Simulink model

Integrate algorithm into an existing Android application using Android Studiodisabled

Create 64 bit library as well

Generate 64-bit APK for Android application disabled

Serial port properties

ParameterDescriptionDefault Value
Baud rate

Set the baud rate of the serial port on the Android device.

9600

MQTT properties

ParameterDescriptionDefault Value
Broker serviceMQTT broker service providerThingSpeak
Broker addressMQTT broker web addressssl://mqtt3.thingspeak.com
PortMQTT broker port number8883
UsernameMQTT client username<empty>
PasswordMQTT client password<empty>
Client IDMQTT client identification number<empty>

Dashboard properties

ParameterDescriptionDefault Value
Dashboard block typeSelect the type of Dashboard blocks that you want to deploy on the Android device.Regular
IP address typeSelect the IP address that the web server uses to host the dashboard.Device address
WebSocket portEnter the port number for the WebSocket server.8000
HTTP portEnter the port number for the HTTP server.8888
Generated UI layout on device to be

Specify size of the application containing the UI components on the Android device screen.

Fit to Screen

External Mode

ParameterDescriptionDefault Value

Communication Interface

Transport layer used to exchange data between host computer and hardware.

TCP/IP

Run external mode in a background thread

Force the external mode engine in the generated code to execute in a background task.

disabled

Port

Serial port on the device.

17725

Verbose

Enable view of the external mode execution progress and updates in the Diagnostic Viewer.

disabled