Series 3700A System Switch/Multimeter Reference Manual Section 11: TSP command reference
3700AS-901-01 Rev. D/June 2018 11-439
tspnet.write(deviceID, "*idn?\r\n")
print("write/read returns:", tspnet.read(deviceID))
Send the "*idn?\r\n" message to the instrument connected as deviceID.
Display the response that is read from deviceID (based on the *idn? message).
Also see
tspnet.connect() (on page 11-434)
tspnet.readavailable() (on page 11-439)
tspnet.timeout (on page 11-441)
tspnet.write() (on page 11-445)
tspnet.readavailable()
This function checks to see if data is available from the remote device.
Usage
bytesAvailable = tspnet.readavailable(connectionID)
The number of bytes available to be read from the connection
The connection ID returned from tspnet.connect()
Details
This command checks to see if any output data is available from the device. No data is read from the
instrument. This allows TSP scripts to continue to run without waiting on a remote command to finish.
Example
ID = tspnet.connect("192.0.2.1")
tspnet.write(ID, "*idn?\r\n")
repeat bytes = tspnet.readavailable(ID) until bytes > 0
print(tspnet.read(ID))
tspnet.disconnect(ID)
Send commands that will create data.
Wait for data to be available.
Also see
tspnet.connect() (on page 11-434)
tspnet.read() (on page 11-438)