Main Content

C28x SCI Transmit

Transmit data from target via serial communication interface (SCI) to host

  • Library:
  • Embedded Coder Support Package for Texas Instruments C2000 Processors / C2802x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C2803x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C2805x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C2806x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C280x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C281x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C2833x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / C2834x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F2807x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F2837xD

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F2837xS

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F2838x/ C28x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F28004x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F28002x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F28003x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F28M35x / C28x

    Embedded Coder Support Package for Texas Instruments C2000 Processors / F28M36x / C28x

  • C28x SCI Transmit block

Description

The SCI Transmit block transmits scalar or vector data using the specified SCI hardware module. The sampling rate and data type are inherited from the input port.

A model can only contain one SCI Transmit block for each module. The C28x processor has four SCI modules — A, B, C, and D. The number of SCI modules available varies depending on the processor selected. You can configure the SCI modules by navigating to Hardware Implementation > Target hardware resources. Verify that these settings meet the requirements of your application. Verify that these settings meet the requirements of your application.

Note

  • Fixed-point inputs are not supported by this block, but you can use a Data Type Conversion (Simulink) block to convert the fixed-point format to native data type. In the Data Type Conversion block, set the Input and output to have equal parameter to Stored Integer (SI).

  • Serial External mode with similar SCI module blocks results in conflict check error.

The block outputs data either in blocking mode or in non-blocking mode. In blocking mode, the model blocks the execution while it waits if transmit FIFO is full. In non-blocking mode, the model runs continuously. To set the block in blocking mode, select the Wait until previous data transmitted option.

Ports

Input

expand all

Input data written to the serial communication bus.

If the input port of SCI Transmit is of variable data size and If the length of variable data is 0, then the block will transmit only the header and terminator.

Data Types: int8 | uint8 | int16 | uint16 | int32 | uint32 | single

Output

expand all

The port outputs 0 if the data is transmitted at a given time step. Otherwise, it outputs value 1, indicating that transmit FIFO is full and data transmission is not successful.

Dependencies

To enable this port, select the Output status parameter.

Data Types: uint8 | uint16

Parameters

expand all

The SCI module used for communication.

The data located at the beginning of the sent data package, which is not part of the data being transmitted, and indicates the start of data. The additional package header must be represented using ASCII characters. Use a string or a number (0–255). You must add single quotes around strings entered for this parameter, but the quotes are not sent or included in the total byte count. To specify a null value (no package header), enter two single quotes only.

The data type of header is not related to the data type mentioned on the block.

Note

Match additional package headers or terminators with those specified in the host SCI Receive block.

The data located at the end of the sent data package, which is not part of the data being transmitted, and indicates the end of data. The additional package terminator must be represented using ASCII characters. Use a string or a number (0–255). You must put single quotes around strings entered in this field, but the quotes are not sent or included in the total byte count. To specify a null value (no package terminator), enter two single quotes only.

The data type of terminator is not related to the data type mentioned on the block.

  • on — When you select this parameter, the transmit operation runs in the blocking mode. In this mode, if transmit FIFO is full then it will wait for previous data to be transmitted and verifies if space is available in the FIFO to transmit the current data.

    A task overrun occurs if the target hardware is still waiting for the requested data to be sent when the next transmit operation is scheduled to begin. To fix overruns increase the time step by using the Sample time parameter.

  • off — When you clear this parameter, the transmit operation runs in the non-blocking mode. In this mode, if the block is still transmitting the data received in the previous time step, the data at the input port in the current time step is dropped.

    In either mode, if the block is yet to establish the connection between the transmitting and receiving hosts. or if the connection is lost, the data at the input port is dropped.

Select this option to display the transmit status during data transmission.

When you select the Output status parameter, the block configures an output port. The port on the block is labeled as Status, indicating that the block outputs the status of the transmit operation at the output port.