Model 2601B-PULSE System SourceMeter Instrument Reference Manual Section 11: TSP command reference
2601B-PULSE-901-01A April 2020 11-171
Details
A new parity setting takes effect when the command to change it is processed.
Allow ample time for the command to be processed before attempting to communicate with the
instrument again. If possible, set parity from one of the other command interfaces or from the
front panel.
The reset function has no effect on parity.
Example
serial.parity = serial.PARITY_NONE
Also see
RS-232 interface operation (on page 2-32)
serial.baud (on page 11-168)
serial.databits (on page 11-169)
serial.flowcontrol (on page 11-170)
serial.read()
This function reads available characters (data) from the serial port.
Usage
data = serial.read(maxchars)
A string that consists of all data read from the serial port
An integer that specifies the maximum number of characters to read
Details
This function reads available characters from the serial port. It does not wait for new characters to
arrive. As long as maxchars is less than 200 characters, all characters that are received by the serial
port (before the serial.read() command is executed) are returned. If too many characters are
received between calls to this function, the RS-232 buffers will overflow and some characters may
be lost.
Call this function as many times as necessary to receive the required number of characters. For
optimal performance, use a small delay between repeated calls to this function.
The data returned is the raw data stream read from the port. No characters, such as control
characters or terminator characters, are interpreted.
If you attempt to use this function when the serial port is enabled as a command interface, a settings
conflict error is generated.