
10-10
Status Structure
Model 6487 Reference Manual
Programming example — set MSS (B6) when error occurs
The first command of the following sequence enables EAV (error available). When an
invalid command is sent (line 4), bits B2 (EAV) and B6 (MSS) of the status byte register
set to 1. The last command reads the status byte register using the binary format (which
directly indicates which bits are set). The command to select format (FORMat:SREGister)
is documented in
. To determine the exact nature of the error, you will have to
read the error queue (see
*CLS
' Clear Error Queue.
*SRE 4
' Enable EAV.
FORM:SREG BIN
' Select binary format.
BadCommand
' Generate error.
*STB?
' Read Status Byte Register.
Status register sets
, there are four status register sets in the status structure of the
Model 6487: standard event status, operation event status, measurement event status, and
questionable event status.
Register bit descriptions
Standard event status
The used bits of the standard event register (
) are described as follows:
•
Bit B0, operation complete (OPC)
— Set bit indicates that all pending selected
device operations are completed and the Model 6487 is ready to accept new com-
mands. This bit only sets in response to the *OPC? query command. See
for details on *OPC and *OPC?.
•
Bit B2, query error (QYE)
— Set bit indicates that you attempted to read data
from an empty output queue.
•
Bit B3, device-dependent error (DDE)
— Set bit indicates that an instrument
operation did not execute properly due to some internal condition.
•
Bit B4, execution error (EXE)
— Set bit indicates that the Model 6487 detected
an error while trying to execute a command.
•
Bit B5, command error (CME)
— Set bit indicates that a command error has
occurred.
Command errors include:
— IEEE-488.2 syntax error — The Model 6487 received a message that does not fol-
low the defined syntax of the IEEE-488.2 standard.
— Semantic error — The Model 6487 received a command that was misspelled or
received an optional IEEE-488.2 command that is not implemented.
— The instrument received a Group Execute Trigger (GET) inside a program message.