Interactive SourceMeter® Instrument Reference Manual Section 8:
2461-901-01 A/November 2015 8-275
Example
trigger.model.setblock(4, trigger.BLOCK_BRANCH_COUNTER, 10, 2)
print(trigger.model.getbranchcount(4))
When the trigger model reaches this block, the trigger model returns to block 2. This repeats 10 times.
An example of the return if the trigger model has reached this block 5 times is:
Also see
trigger.model.getbranchcount() (on page 8-259)
trigger.model.setblock() — trigger.BLOCK_RESET_BRANCH_COUNT (on page 8-295)
trigger.model.setblock() — trigger.BLOCK_BRANCH_DELTA
This function defines a trigger model block that goes to a specified block if the difference of two measurements
meets preset criteria.
Type TSP-Link accessible Affected by Where saved Default value
Instrument reset
Usage
trigger.model.setblock(blockNumber, trigger.BLOCK_BRANCH_DELTA, targetDifference,
branchToBlock)
trigger.model.setblock(blockNumber, trigger.BLOCK_BRANCH_DELTA, targetDifference,
branchToBlock, measureBlock)
The sequence of the block in the trigger model
The value against which the block compares the difference
The block number of the trigger model block to execute when
the difference between the measurements is less than or equal
The block number of the measure or digitize block that makes
the measurements to be compared; if this is 0 or undefined, the
trigger model uses the previous measure or digitize block
Details
This block calculates the difference between the last two measurements from a measure or digitize
block. It subtracts the most recent measurement from the previous measurement.
The difference between the measurements is compared to the target difference. If the difference is
less than the target difference, the trigger model goes to the specified branching block. If the
difference is more than the target difference, the trigger model proceeds to the next block in the
trigger block sequence.