Section 6: Instrument programming
Model 2651A High Power System SourceMeter® Instrument Reference Manual
6-52
2651A-901-01 Rev. A / March 2011
An attempted TSP-Link reset will fail if any of the following conditions are true:
•
Two or more instruments in the system have the same node number
•
There are no other instruments connected to the unit performing the reset (only if the expected
number of nodes was not provided in the reset call)
•
One or more of the units in the system is not powered on
•
If the actual number of nodes is less than the expected number
The programming example below illustrates a TSP-Link reset operation and displays its state:
tsplink.reset()
print(tsplink.state)
If the reset is successful,
online
will be output to indicate that communications with all nodes have
been established.
Using the expanded system
Accessing nodes
A TSP-Link
®
reset()
command populates the node table. Each unit in the system corresponds to
an entry in this table. Each entry is indexed by the node number of the unit. The variable
node[
N
]
(where
N
is the node number) is used to access any node in the system. For example, node 1 is
represented as entry
node[1]
in the node table.
Each of these entries is a table holding all of the logical instruments (and associated commands)
shared by the corresponding unit (see Logical instruments for more details). Source-measure unit
(SMU) A on node 1, therefore, could be accessed as
node[1].smua
.
The variable
localnode
is an alias for
node[
N
]
, where
N
is the node number of the node on which
the code is running. For example, if node 1 is running the code,
localnode
can be used instead of
node[1]
.
The following programming examples illustrate how to access instruments in the TSP-Link system
(shown in TSP-Link connections):
•
Any of the following three commands can be used to reset SMU A of node 1 (which, in this
example, is the master). The other nodes in the system are not affected.
smua.reset()
localnode.smua.reset()
node[1].smua.reset()
•
The following command will reset the SMU A of node 4, which is a subordinate. The other nodes
are not affected.
node[4].smua.reset()