ComBuffer
The ComBuffer data structure is a data buffer that decouples the hardware-dependent communication blocks from the hardware-independent blocks. Data buffers of type ComBuffer are never directly written or read by the user, but are merely used as intermediate storage for the communication blocks.
TYPE ComBuffer
STRUCT
Buffer : ARRAY[0..300] OF BYTE;
RdIdx : INT;
WrIdx : INT;
Count : INT; (* Number of characters in the ring buffer *)
FreeByte : INT; (* Number of free spaces in the ring buffer *)
Error : INT; (* Interface error code *)
blocked : BOOL;
END_STRUCT
END_TYPE