
Appendix C: Status model
Model 2461 Interactive SourceMeter® Instrument Reference Manual
C-18
2461-901-01 A/November 2015
Status model programming examples
The following examples illustrate how to generate an SRQ using the status model.
SRQ when the SMU reaches its source limit
This example demonstrates how to generate a service request (SRQ) when the source-measure unit
(SMU) detects it has reached its source limit. After configuring the status model, in this example the
source will be configured to output current and measure voltage. If the output terminals of the SMU
are left open when running this example, the SMU will reach its source limit and generate an SRQ.
Using SCPI commands:
*RST
STAT:CLE
STAT:OPER:MAP 0, 5080, 5081
STAT:OPER:ENAB 1
*SRE 128
SOUR:FUNC CURR
SOUR:CURR:RANG 1e-3
SOUR:CURR 1e-3
SOUR:CURR:VLIM 1
SENS:FUNC "VOLT"
OUTP ON
READ?
OUTP OFF
Using TSP commands:
reset()
-- Clear the status byte
status.clear()
-- Map the event numbers
-- Map bit 0 of operational status register to set on reaching the
-- source limit (5080) and clear on dropping below the source
-- limit (5081)
status.operation.setmap(0, 5080, 5081)
-- Enable bit 0 to flow through to the status byte.
status.operation.enable = 1
-- Enable the Operational Summary Bit to set the Master
-- Summary Bit/RQS
status.request_enable = status.OSB
-- This code will make SMU reach V limit if output terminals are open
smu.source.func = smu.FUNC_DC_CURRENT
smu.source.range = 1e-3
smu.source.level = 1e-3
smu.source.vlimit.level = 1
smu.measure.func = smu.FUNC_DC_VOLTAGE
smu.source.output = smu.ON
print(smu.measure.read())
smu.source.output = smu.OFF