Set Up Input Buffer Function (4301); Flush Input Buffer Function (4302) - GE VersaMax PLC User Manual

Table of Contents

Advertisement

238
GFK-1503E
For public disclosure
Caution

12.4.5 Set Up Input Buffer Function (4301)

This function can be used to change the size of the internal memory buffer where input
data will be placed as it is received. By default, the buffer is set to a maximum of 2K
bytes. As data is received from the serial port it is placed in the input buffer. If the buffer
becomes full, any additional data received from the serial port is discarded and the
Overflow Error bit in the Port Status word (See Read Port Status Function) is set.
12.4.5.1 Retrieving Data from the Buffer
Data can be retrieved from the buffer using the Read String or Read Bytes function. It is
not directly accessible from the application program.
If data is not retrieved from the buffer in a timely fashion, some characters may be lost.
12.4.5.2 Example Command Block for the Set Up Input Buffer
Function
VALUE
(decimal)
address
0002
address +1
0000
address +2
0008
address +3
0000
address +4
0000
address +5
0000
address +6
4301
address +7
0064
12.4.5.3 Operating Notes
It is not possible to set the buffer length to zero. If zero is entered as the buffer length, the
buffer size will be set to the 2K bytes default.
If a length greater than 2K bytes is specified, an error is generated.

12.4.6 Flush Input Buffer Function (4302)

This operation empties the input buffer of any characters received through the serial port
but not yet retrieved using a read command. All such characters are lost.
If this COMMREQ is sent when a Write Bytes
(4401) COMMREQ is transmitting a string from a
serial port, transmission is halted. The position
within the string where the transmission is halted is
indeterminate. In addition, the final character
received by the device the CPU is sending to is also
indeterminate.
VALUE
(hexadecimal)
Data block length
0002
0000
NOWAIT mode
Status word memory type (%R)
0008
Status word address minus 1 (%R0001)
0000
0000
Not used
0000
Not used
Setup input buffer command
10CD
Buffer length (in words)
0040
MEANING
VersaMax PLC User Manual

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents