Technical data

100 Agilent Infiniium 90000 Series Oscilloscopes Programmer's Reference
6 Status Reporting
Status Byte Register
The Status Byte Register is the summary- level register in the status
reporting structure. It contains summary bits that monitor activity in the
other status registers and queues. The Status Byte Register is a live
register. That is, its summary bits are set and cleared by the presence and
absence of a summary bit from other event registers or queues.
If the Status Byte Register is to be used with the Service Request Enable
Register to set bit 6 (RQS/MSS) and to generate an SRQ, at least one of
the summary bits must be enabled, then set. Also, event bits in all other
status registers must be specifically enabled to generate the summary bit
that sets the associated summary bit in the Status Byte Register.
You can read the Status Byte Register using either the *STB? common
command query or the GPIB serial poll command. Both commands return
the decimal- weighted sum of all set bits in the register. The difference
between the two methods is that the serial poll command reads bit 6 as
the Request Service (RQS) bit and clears the bit which clears the SRQ
interrupt. The *STB? query reads bit 6 as the Master Summary Status
(MSS) and does not clear the bit or have any effect on the SRQ interrupt.
The value returned is the total bit weights of all of the bits that are set at
the present time.
The use of bit 6 can be confusing. This bit was defined to cover all
possible computer interfaces, including a computer that could not do a
serial poll. The important point to remember is that if you are using an
SRQ interrupt to an external computer, the serial poll command clears bit
6. Clearing bit 6 allows the oscilloscope to generate another SRQ interrupt
when another enabled event occurs.
The only other bit in the Status Byte Register affected by the *STB? query
is the Message Available bit (bit 4). If there are no other messages in the
Output Queue, bit 4 (MAV) can be cleared as a result of reading the
response to the *STB? query.
If bit 4 (weight = 16) and bit 5 (weight = 32) are set, a program would
print the sum of the two weights. Since these bits were not enabled to
generate an SRQ, bit 6 (weight = 64) is not set.
Example 1 This example uses the *STB? query to read the contents of the
oscilloscope's Status Byte Register when none of the register's summary
bits are enabled to generate an SRQ interrupt.
Dim varStbValue As Variant
myScope.WriteString ":SYSTEM:HEADER OFF;*STB?" 'Turn headers off
varStbValue = myScope.ReadNumber
Debug.Print "Status Byte Register, Read: 0x" + Hex(varStbValue)