Tsp-Net Compared To Tsp-Link To Communicate With Tsp-Enabled Devices - Keithley 3700A Series Reference Manual

System switch/multimeter
Hide thumbs Also See for 3700A Series:
Table of Contents

Advertisement

Section 10: Instrument programming
Example script
The following example demonstrates how to connect to a remote device that is not TSP
and send and receive data from this device:
-- Set tspnet timeout to 5 s.
tspnet.timeout = 5
-- Establish connection to another device with IP address 192.168.1.51
-- at port 1394.
id_instr = tspnet.connect("192.168.1.51", 1394, "*rst\r\n")
-- Print the device ID from connect string.
print("ID is: ", id_instr)
-- Set the termination character to CRLF. You must do this
-- for each connection after the connection has been made.
tspnet.termination(id_instr, tspnet.TERM_CRLF)
-- Send the command string to the connected device.
tspnet.write(id_instr, "login admin\r\n")
-- Read the data available, then print it.
tspnet.write(id_instr, "*idn?\r\n")
print("instrument write/read returns: ", tspnet.read(id_instr))
-- Disconnect all existing TSP-Net sessions.
tspnet.reset()
This example produces a return such as:
ID is:
1
instrument write/read returns:
instrument write/read returns:
3700AS,04089762,1.6.3d
TSP-Net compared to TSP-Link to communicate with TSP-enabled
devices
The TSP-Link
communication occurs between the Series 3700A and another TSP-enabled instrument.
One of the advantages of using the TSP-Link network interface is that TSP-Link connections have
three trigger lines that are available to each device on the TSP-Link network. You can use any one of
the trigger lines to perform hardware triggering between devices on the TSP-Link network. Refer to
Hardware trigger modes
However, if the distance between the Series 3700A and the TSP-enabled device is longer than
15 feet, use TSP-Net commands.
10-66
®
network interface is the preferred communication method for most applications where
(on page 5-31) for details.
Series 3700A System Switch/Multimeter Reference Manual
SUCCESS: Logged in
KEITHLEY INSTRUMENTS,MODEL
®
enabled,
3700AS-901-01 Rev. D/June 2018

Advertisement

Table of Contents
loading

Table of Contents