
Section 8: TSP command reference
Model 2461 Interactive SourceMeter® Instrument Reference Manual
8-296
2461-901-01 A/November 2015
Example
trigger.model.load("Empty")
trigger.model.setblock(1, trigger.BLOCK_BUFFER_CLEAR)
trigger.model.setblock(2, trigger.BLOCK_MEASURE)
trigger.model.setblock(3, trigger.BLOCK_BRANCH_COUNTER, 5, 2)
trigger.model.setblock(4, trigger.BLOCK_DELAY_CONSTANT, 1)
trigger.model.setblock(5, trigger.BLOCK_BRANCH_COUNTER, 3, 2)
trigger.model.setblock(6, trigger.BLOCK_RESET_BRANCH_COUNT, 3)
trigger.model.initiate()
waitcomplete()
print(defbuffer1.n)
Reset trigger model settings.
Clear
defbuffer1
at the beginning of the trigger model.
Loop and take 5 readings.
Delay a second.
Loop three more times back to block 2.
Reset block 3 to 0.
Start the trigger model and wait for measurements to complete.
Print the number of readings in the buffer.
Output:
15
Also see
trigger.model.getbranchcount()
(on page 8-259)
trigger.model.setblock() — trigger.BLOCK_BRANCH_COUNTER
(on page 8-274)
trigger.model.setblock() — trigger.BLOCK_SOURCE_OUTPUT
This function defines a trigger block that turns the output source on or off.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Function
Yes
Restore configuration
Instrument reset
Power cycle
Configuration script
Not applicable
Usage
trigger.model.setblock(
blockNumber
, trigger.BLOCK_SOURCE_OUTPUT,
state
)
blockNumber
The sequence of the block in the trigger model
state
Turn the source off:
smu.OFF
Turn the source on:
smu.ON
Details
The source output block determines if the output source is turned on or off when the trigger model
reaches this block.
This block does not determine the settings of the output source (such as the output voltage level and
source delay). The source settings are determined by either the present settings of the instrument or
by a source configuration list.
When you list trigger blocks, this block is listed as
SOURCE_OUTPUT
.