Back to FabImage Library website
You are here: Start » Function Reference » Serial Port » SerialPort_Read_Deprecated
Header: | STD.h |
---|---|
Namespace: | fil |
Reads characters in binary mode from serial port.
Syntax
void fil::SerialPort_Read_Deprecated ( SerialPortState& ioState, ftl::Conditional<ftl::Array<int> >& outData )
Parameters
Name | Type | Default | Description | |
---|---|---|---|---|
ioState | SerialPortState& | Object used to maintain state of the function. | ||
![]() |
outData | Conditional<Array<int> >& | Conditionally returns non empty array of character values, when any data available. |
Description
This filter is deprecated. Use SerialPort_WriteBuffer instead.
Filter reads all data from input port buffer.
Filter perform non-blocking reading form buffer and will return NIL when no data was read.
Remarks
Using the SerialPort_Config filter is necessary before using the SerialPort_Read_Deprecated filter.
Filter SerialPort_Config does not guarantee that input buffer will be empty.
Errors
Using filters reading from serial port without previous configuration will cause "SerialPort not initialized" error.
See Also
- SerialPort_Config – Configures the serial port.
- SerialPort_ReadBuffer – Reads raw binary data from serial port.
- SerialPort_ReadByte – Reads one character in binary mode from serial port.
- SerialPort_ReadChar – Reads single character from serial port.
- SerialPort_ReadString – Reads string characters from serial port.
- SerialPort_ReadStringUntil – Reads the string from the serial port to encounter a string delimiter.