2600AS-901-01 Rev. B / September 2008
Return to
19-213
Series 2600A System SourceMeter® Instruments Reference Manual
Section 19: Remote Commands
tsplink.readbit
Function
Reads the state of a TSP-Link synchronization line.
TSP-Link
accessibility
This function can be accessed from a remote TSP-Link node.
Usage
data = tsplink.readbit(n)
data
A custom variable that stores the state of the
synchronization
line.
n
Synchronization line to be read (1 - 3).
Remarks
• Returns a value of 0 if the line is low and a 1 if the line is high.
Details
See
TSP-Link synchronization lines
.
Also see
Example
Assume line 3 is set high, and it is then read:
data = tsplink.readbit(3)
print(data)
Output:
1.00
tsplink.readport
Function
Reads the TSP-Link synchronization lines as a digital I/O port.
TSP-Link
accessibility
This function can be accessed from a remote TSP-Link node.
Usage
data = tsplink.readport()
Remarks
• The binary equivalent of the returned value indicates the input pattern on the
I/O port
.
The least
significant bit of the binary number corresponds to line 1 and bit 3 corresponds to line 3. For
example, a returned value of 2 has a binary equivalent of 010. Line 2 is high (1), and the other 2
lines are low (0).
Details
See
TSP-Link synchronization lines
.
Also see
Example
Assume line 2 is set high, and the digio I/O port reads:
data = tsplink.readport()
print(data)
Output:
2.00
(binary 010)