Specifications

202 Chapter 11
Error Handling
Using the Error Queue
Using the Error Queue
The error queue contains the error numbers and messages of any errors that have occurred,
which could provide very useful information depending on the circumstances. Use the
following GPIB command to read the error queue.
SYST:ERR? on page 517
Also, the following GPIB command can be used to obtain the number of errors in the
queue.
SYST:ERR:COUN? on page 518
The error queue can be used in the following ways.
1. Based on the information from the error queue, you can decide how to branch a
program. By reading the error queue, you can easily determine whether an error has
occurred; if no error has occurred, an error number of 0 and an error message of “No
error” are returned. The error queue can also be used to set a program to perform error
handling only when a certain type of error occurs.
2. If an error is detected using SRQ, the error queue can be used to investigate the type of
error. For how to use SRQ, refer to
Example 11-1.