Program Theory - Agilent Technologies 75000 Series B Configuration Manual

Installing the mainframe and plug-in modules
Hide thumbs Also See for 75000 Series B:
Table of Contents

Advertisement

The second error:
DVM ERROR " Query UNTERMINATED"
is ignored because the process of querying for errors caused it. A "
Query UNTERMINATED
" error occurs
any time a second query command (i.e., a command with a " ?" in it) occurs before the data from the first is
retrieved.

Program Theory

Now that you have seen how to use this Debugging, ERROR and TIMEOUT handling program, the
following explains some of the theory and mechanics of how it works.
Checking the Error Queue
In any VXI SCPI instrument, command errors such as syntax errors accumulate in the instrument's error
queue. When an error is present in a command that is received, no action on that command is executed other
than logging a message into the instrument error queue. Reading the error queue is critical because no
visible indication of an error may be generated.
When the error queue has an error in it, the task is to discover which command caused it. Since most
commands set parameters, when a command has a error, this parameter is not executed. A very effective
debugging technique is to query previously sent commands for their current setting. When a queried setting
doesn't match what you intended it to be, you have just located the error.
Using TIMEOUTS
Checking for errors after every command will find most errors. However, this decreases your overall
system performance even after all bugs have been removed. Most errors in a program causes your
application program to " hang up" . Thus, TIMEOUTs are an excellent indication that an error has occurred.
A strategy of checking for errors at the end of your program (or whenever your program hangs up)
produces a program with no speed penalty and is very effective at finding errors.
This debugging technique is automated by the program "RN13_RMB". The shell program traps IBASIC
ERRORS and TIMEOUTS. It then queries for instrument errors, and if any occur, it reads and prints out
the queries to its entire command set. It also does the error query at the very end of your application
program. Use this information to compare the Agilent E1326 DMM state with the intended parameters.
For rapid debugging, you need to see program flow, program variables, instrument errors and instrument
states. Making this all visible and easily accessible is the main advantage of a good DEBUGGING, ERROR
and TIMEOUT handling shell such as "RN13_RMB".
Debugging VXI SCPI Programs C-9

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

E1301bE1300b

Table of Contents