User manual
Section 13: Instrument Control Library (ICL) Series 3700 System Switch/Multimeter Reference Manual
13-300 3700S-901-01 Rev. C / July 2008
tspnet functions and attributes
Use the tspnet commands to control, identify, and communicate with TSP
TM
devices. You can use these commands with Keithley Instruments and non-
Keithley Intruments devices.
tspnet.clear()
Function
Device read clear buffer.
Usage
tspnet.clear(<connection id>)
connection id: Integer value used as a handle for other tspnet commands
Remarks
This command clears any pending output data available from the device. No data is
returned to the caller. No data is processed.
Errors:
Invalid Specified Connection
Example
tspnet.write(mydevice, 'print([[hello]])')
print(tspnet.readavailable(mydevice))
Output
6.00000000e+000
tspnet.clear(mydevice)
print(tspnet.readavailable(mydevice))
Output
0.00000000e+000
tspnet.connect()
Function
Device connection.
Usage
To connect to any remote device on the LAN:
<connection id> = tspnet.connect([<ip address>, [<port
number>, <initialize string>]])
To connect to a TSP-enabled remote device on the LAN:
<connection id> = tspnet.connect([<ip address>,
[<password>])
connection id: Integer value used as a handle for other tspnet commands
ip address: String variable for passing the IP address
port number: Optional integer value of the port number
initialize string: String type for the initialization string to send