Section 15: Status model
Programming enable and transition registers
A command to program an event enable or transition register is sent with a parameter value that
determines the state (0 or 1) of each bit in the appropriate register. The bit positions of the register
(see the following tables) indicate the binary parameter value and decimal equivalent. To program
one of the registers, send the decimal value for the bits to be set. The registers are discussed further
in
Enable and transition registers
Bit
Binary value
Decimal
Weights
Bit
Binary value
Decimal
Weights
When using a numeric parameter, registers are programmed by including the appropriate mask value.
For example:
*ese 1169
status.standard.enable = 1169
To convert from decimal to binary, use the information shown in the above figure. For example, to set
bits B0, B4, B7, and B10, use a decimal value of 1169 for the mask parameter
(1169 = 1 + 16 + 128 + 1024).
Reading registers
Any register in the status structure can be read either by sending the common command query
(where applicable), or by including the script command for that register in either the print() or
print(tostring()) command. The print() command outputs a numeric value; the
print(tostring()) command outputs the string equivalent. For example, any of the following
commands requests the Service Request Enable Register value:
*SRE?
print(tostring(status.request_enable))
print(status.request_enable)
The response message is a decimal value that indicates which bits in the register are set. That value
can be converted to its binary equivalent using the information in Programming enable and transition
registers. For example, for a decimal value of 37 (binary value of 100101), bits B5, B2, and B0 are
set.
15-14
Model 2651A High Power System SourceMeter® Instrument Reference Manual
(on page 15-19).
B7
B6
B5
0/1
0/1
0/1
128
64
32
7
6
5
(2
)
(2
)
(2
)
B15
B14
B13
0/1
0/1
0/1
32,768
16,384
8,192
15
14
13
(2
)
(2
)
(2
)
B4
B3
B2
0/1
0/1
0/1
16
8
4
4
3
2
(2
)
(2
)
(2
)
B12
B11
B10
0/1
0/1
0/1
4,096
2,048
1,024
12
11
10
(2
)
(2
)
(2
)
2651A-901-01 Rev. C October 2021
B1
B0
0/1
0/1
2
1
1
0
(2
)
(2
)
B9
B8
0/1
0/1
512
256
9
8
(2
)
(2
)
Need help?
Do you have a question about the Keithley 2651A and is the answer not in the manual?