Host Serial Setup

Configure COM ports for the host-side Host Serial Receive and Host Serial Transmit blocks

  • Library:
  • Motor Control Blockset / Protection and Diagnostics

Description

The Host Serial Setup block is a stand-alone block that standardizes the COM port settings used by the Host Serial Receive and Host Serial Transmit blocks.

Setting the COM port configurations globally by using the Host Serial Setup block avoids conflicts (for example, the Host Serial Transmit block cannot use COM1 with settings different than those the COM1 settings used by the Host Serial Receive block). You need to set configurations only once for each COM port.

Parameters

expand all

Select an available serial port that you want to configure. By default no port is selected and this field displays 'Please_select_a_port'. Use a configured port in the Host Serial Transmit and Host Serial Receive blocks. Both transmit and receive blocks must have a configured serial configuration. If you use multiple serial ports in your simulation, you must configure each port using a separate serial setup block.

Enter the rate at which the model transmits the bits through the serial interface.

Enter the number of bits that the model uses to indicate the end of a byte.

Specify how you want to check parity bits in the data bits that the model transmits through the serial port.

  • none - Model does not perform parity check.

  • odd - Model sets the parity bit to 0 if the number of ones in a given set of bits is even.

  • even - Model sets the parity bit to 1 if the number of ones in a given set of bits is odd.

Enter values greater than or equal to zero (seconds). When the COM port involved is using the protocol mode, this value indicates how long the transmitting side waits for an acknowledgement from the receiving side or how long the receiving side waits for data.

The system displays a warning message if the time-out exceeds, every n number of seconds, where n is the Timeout value.

Specify the byte order as either LittleEndian or BigEndian. If byte order is LittleEndian, the model stores the first byte in the first memory address. If byte order is BigEndian, the model stores the last byte in the first memory address. You should configure the byte order to an appropriate value for your model before performing a read or write operation.