4. Configuration
195
Table 4-128. Serial Function Blocks Data types
SERIAL_CFG
This function block is used to configure and initialize the desired serial port. After the block is called,
every RX and TX queue associated to the serial ports and the RX and TX FIFO are restarted.
Figure 4-93. Serial Configuration Block
This variable, when true, enables the function
block use.
Select the serial port, as described in the
SERIAL_PORT data type.
This structure defines the serial port
configuration parameters, as described in the
SERIAL_PARAMETERS data type.
Table 4-129 Serial_CFG Input Parameters
This variable is true when the block is
completely executed. It is false otherwise.
This variable is true while the block is being
executed. It is false otherwise.
This variable is true when the block
concludes the execution with an error. It is
false otherwise. It is connected to the variable
DONE, as its status is showed after the block
conclusion.
In case the ERROR variable is true, the
STATUS structure will show the error found
during the block execution. The possible
states, already described in the
SERIAL_STATUS data type, are:
- NO_ERROR
- ILLEGAL_SERIAL_PORT
- ILLEGAL_SERIAL_MODE,
- ILLEGAL_BAUDRATE
- ILLEGAL_DATA_BITS
- ILLEGAL_PARITY
- ILLEGAL_STOP_BITS
- ILLEGAL_HANDSHAKE
- ILLEGAL_UART_RX_THRESHOLD
- PORT_BUSY
- HW_ERROR_UART
HW_ERROR_REMOTE
- DCD_INTERRUPT_NOT_ALLOWED
- CTS_INTERRUPT_NOT_ALLOWED
- DSR_INTERRUPT_NOT_ALLOWED
Table 4-130. Output Parameters Serial_CFG