HP 53181A Programming Manual
HP 53181A Programming Manual

HP 53181A Programming Manual

Frequency counter
Hide thumbs Also See for 53181A:

Advertisement

HP 53181A
Frequency Counter
Programming
Guide

Advertisement

Table of Contents
loading

Summary of Contents for HP 53181A

  • Page 1 Programming Guide HP 53181A Frequency Counter...
  • Page 3 Programming Guide This guide describes how to program the HP 53181A 225 MHz Frequency Counter. The information in this guide applies to instruments having the number prefix listed below, unless accompanied by a “Manual Updating Changes” package indicating otherwise. SERIAL PREFIX NUMBER:...
  • Page 4 © Copyright Hewlett-Packard Certification Safety Considerations Safety Considerations Company 1994, 1995,1997 and Warranty (contd) General Certification All Rights Reserved. This product and related Reproduction, adaptation, or Hewlett-Packard Company documentation must be reviewed translations without prior written certifies that this product met its for familiarization with this permission is prohibited, except published specification at the...
  • Page 5: Table Of Contents

    Programming Your Counter for Remote Operation Introduction 3-2 Chapter Summary 3-2 Where to Find Some Specific Information 3-2 Where to Find HP BASIC Programming Examples 3-3 Where to Find QuickBASIC Programming Examples 3-3 Where to Find Turbo C Programming Examples 3-3...
  • Page 6 Contents Configuring the HP-IB 3-4 To Set the HP-IB Mode and Address 3-4 To Connect the Counter to a Computer 3-6 Remote/Local Operation 3-6 Overview of Command Types and Formats 3-7 Common Command Format 3-7 SCPI Command and Query Format 3-7...
  • Page 7 Commands for Enabling and Disabling the Display 3-47 How to Program the Counter to Synchronize Measurements 3-48 Synchronizing Measurement Completion 3-48 Resetting the Counter and Clearing the HP-IB Interface 3-48 Using the *WAI Command 3-48 Using the *OPC? Command 3-49...
  • Page 8 To Perform Limit Testing (HP BASIC) 3-65 To Measure the Statistics of 50 Measurements(HP BASIC) 3-66 To Use Limits to Filter Data Before Measuring Stats (HP BASIC) 3-68 To Read and Store Calibration Information (HP BASIC) 3-70 To Optimize Throughput (HP BASIC) 3-71...
  • Page 9 Contents Commands Reference Introduction 4-2 :ABORt 4-4 :CALCulate Subsystems 4-5 :CALCulate[1] Subsystem 4-7 :CALCulate[1]:DATA? 4-7 :CALCulate[1]:FEED "[:]SENSe[1]" 4-8 :CALCulate[1]:IMMediate 4-8 :CALCulate[1]:IMMediate:AUTO 4-9 :CALCulate[1]:MATH Subtree 4-9 :CALCulate[1]:MATH[:EXPRession]:CATalog? 4-9 :CALCulate[1]:MATH[:EXPRession][:DEFine]? 4-10 :CALCulate[1]:MATH[:EXPRession]:NAME SCALE_OFFSET 4-10 :CALCulate[1]:MATH[:EXPRession]:SELect SCALE_OFFSET 4-10 :CALCulate[1]:MATH:STATe 4-10 :CALCulate2 Subsystem 4-11 :CALCulate2:FEED "[:]CALCulate[1]"...
  • Page 10 Contents :CALCulate3 Subsystem 4-19 :CALCulate3:AVERage Subtree 4-19 :CALCulate3:AVERage:ALL? 4-19 :CALCulate3:AVERage:CLEar 4-20 :CALCulate3:AVERage:COUNt 4-20 :CALCulate3:AVERage:COUNt:CURRent? 4-21 :CALCulate3:AVERage[:STATe] 4-21 :CALCulate3:AVERage:TYPE 4-22 :CALCulate3:DATA? 4-22 :CALCulate3:FEED "[:]CALCulate[1]" 4-23 :CALCulate3:LFILter Subtree 4-23 :CALCulate3:LFILter:LOWer[:DATA] 4-23 :CALCulate3:LFILter:STATe 4-24 :CALCulate3:LFILter:UPPer[:DATA] 4-24 :CALCulate3:PATH? 4-25 :CALibration Subsystem 4-26 :CALibration[:ALL]? 4-26 :CALibration:COUNt? 4-26 :CALibration:DATA 4-27 :CALibration:SECurity Subtree 4-28...
  • Page 11 Contents :DISPlay Subsystem 4-36 :DISPlay:ENABle 4-36 :DISPlay:MENU[:STATe] OFF 4-36 :DISPlay[:WINDow]:TEXT:FEED "[:]CALCulate2" | "[:]CALCulate3" 4-37 :DISPlay[:WINDow]:TEXT:MASK 4-38 :DISPlay[:WINDow]:TEXT:RADix 4-39 :FETCh Subsystem 4-40 :FORMat Subsystem 4-41 :FORMat[:DATA] 4-41 Group Execute Trigger(GET) 4-42 :HCOPy Subsystem 4-43 :HCOPy:CONTinuous 4-43 :INITiate Subsystem 4-44 :INITiate:AUTO 4-44 :INITiate:CONTinuous 4-44 :INITiate[:IMMediate] 4-46 :INPut[1] Subsystem 4-48...
  • Page 12 Contents :READ 4-57 :MEASure[:SCALar][:VOLTage]:FREQuency? 4-59 :MEASure[:SCALar][:VOLTage]:FREQuency:RATio? 4-61 :MEASure[:SCALar][:VOLTage]:MAXimum? 4-62 :MEASure[:SCALar][:VOLTage]:MINimum? 4-62 :MEASure[:SCALar][:VOLTage]:PERiod? 4-63 :MEASure[:SCALar][:VOLTage]:PTPeak? 4-64 Using :MEAsure 4-65 Using :CONFigure with :READ? 4-66 Using :CONFigure with :INITiate and :FETCh? 4-66 :MEMory Subsystem 4-68 :MEMory:DELete:MACRo 4-68 :MEMory:FREE:MACRo? 4-68 :MEMory:NSTates? 4-68 [:SENSe] Subsystem 4-69 [:SENSe]:DATA? ["[:]SENSe[1]"] 4-69 [:SENSe]:EVENt[1] Subtree 4-69 [:SENSe]:EVENt[1]:HYSTeresis:RELative 4-69...
  • Page 13 Contents [:SENSe]:ROSCillator Subtree 4-79 [:SENSe]:ROSCillator:EXTernal:CHECk 4-79 [:SENSe]:ROSCillator:EXTernal:FREQuency? 4-79 [:SENSe]:ROSCillator:SOURce 4-80 [:SENSe]:ROSCillator:SOURce:AUTO 4-80 :STATus Subsystem 4-82 :STATus:OPERation Subtree 4-82 :STATus:OPERation:CONDition? 4-82 :STATus:OPERation:ENABle 4-83 :STATus:OPERation[:EVENt]? 4-83 :STATus:OPERation:NTRansition 4-84 :STATus:OPERation:PTRansition 4-84 :STATus:PRESet 4-85 :STATus:QUEStionable Subtree 4-86 :STATus:QUEStionable:CONDition? 4-86 :STATus:QUEStionable:ENABle 4-87 :STATus:QUEStionable[:EVENt]? 4-87 :STATus:QUEStionable:NTRansition 4-88 :STATus:QUEStionable:PTRansition 4-88 :SYSTem Subsystem 4-90 :SYSTem:COMMunicate Subtree 4-90...
  • Page 14 Contents *CAL?(Calibration Query) 4-99 *CLS(Clear Status Command) 4-100 *DDT(Define Device Trigger Command) 4-101 *DMC(Define Macro Command) 4-102 *EMC(Enable Macro Command) 4-103 *EMC?(Enable Macro Query) 4-103 *ESE(Standard Event Status Enable Command) 4-104 *ESE?(Standard Event Status Enable Query) 4-104 *ESR?(Event Status Register Query) 4-106 *GMC?(Get Macro Contents Query) 4-107 *IDN?(Identification Query) 4-108 *LMC?(Learn Macro Query) 4-109...
  • Page 15 Contents Errors Introduction 5-2 Displaying Errors 5-2 Reading an Error 5-2 Error Queue 5-3 Error Types 5-4 No Error 5-4 Command Error 5-4 Execution Error 5-5 Device- or Counter-Specific Error 5-5 Query Error 5-6 Index xiii...
  • Page 16 Contents...
  • Page 17: Before You Start

    Before You Start ...
  • Page 18: Introduction

    SCPI standard. If you have programmed any HP instruments that have been released over the last few years, you will have seen a general trend toward the techniques specified in the SCPI standard.
  • Page 19: Getting Started

    Counter. (In Chapter 3, “Programming Your Counter for Remote Operation,” there are programming examples provided in HP BASIC, Microsoft ® QuickBASIC, and Borland ® Turbo C.) However, whatever language you use, command strings that control the...
  • Page 20: Learning To Program The Counter

    Command Maps” in Chapter 2. • Read Chapter 3, “Programming Your Counter for Remote Operation,” for an overview of the SCPI concepts as they relate to the HP 53181A Frequency Counter. Look at the flowcharts, which illustrate some of the decisions you must make when programming the Counter.
  • Page 21: Applications

    Before You Start ... How to Use This Guide • Review the summary tables in Chapter 2, “Commands Summary.” If this chapter contains sufficient information to get you started, write some programs to explore the Counter's capabilities. If you need additional information on any command, refer to the applicable command description in Chapter 4, “Commands Reference.”...
  • Page 22: Programming Guide Contents

    As previously mentioned, this guide also assumes you are familiar with the front- panel operation of the Counter. See the HP 53181A Operating Guide for detailed information about front-panel operation. Knowing how to control the Counter from the front panel and understanding the measurements you wish to perform makes the...
  • Page 23: Related Documentation

    This section contains a list of documentation related to the use of the Counter. Additional information that you may find useful can be found in the following publications: 1. HP 53181A 225 MHz Frequency Counter Operating Guide (HP Part Number 53181-90001) 2. Beginner's Guide to SCPI (HP Part Number H2325-90001, July 1990 Edition).
  • Page 24 This HP BASIC manual contains a good non-technical description of the HP- IB (IEEE 488.1) interface in Chapter 12, “The HP-IB Interface.” Subsequent revisions of HP BASIC may use a slightly different title for this manual or chapter. This manual is the best reference on I/O for HP BASIC programmers.
  • Page 25 Commands Summary A Quick Reference...
  • Page 26: Commands Summary Introduction

    1 The section titled “ Front Panel to SCPI Command Maps,” provides maps that show the front-panel keys and their corresponding (or related) SCPI commands. 2 The section titled “ HP 53181A Command Summary,” lists the IEEE 488.2 Common and the SCPI Subsystem commands in Tables 2-1 and 2-2, respectively.
  • Page 27: Front Panel To Scpi Command Maps

    “Parameter Form” column in Table 2-2), you must send the quotation marks with the command. Refer to the section titled “Using HP BASIC” in Chapter 3 (page 3- 60) of this guide for details on how to use double quotes or single quotes to enclose...
  • Page 28 Commands Summary Front Panel to SCPI Command Maps __________________________ Channel 2 is optional. Figure 2-1. Input Channels Conditioning Keys to SCPI Command Map (Part 1 of 2)
  • Page 29 Commands Summary Front Panel to SCPI Command Maps [:SENSe]:EVENt:LEVel[:ABSolute]:AUTO ON|OFF b 1 . [:SENSe]:EVENt:LEVel[:ABSolute] <numeric_value> [V] b 2 . [:SENSe]:EVENt:LEVel:RELative <numeric_value> [PCT] [:SENSe]:EVENt:SLOPe POSitive | NEGative d 1 . [:SENSe]:EVENt:HYSTeresis:RELative 100 d 2 . [:SENSe]:EVENt:HYSTeresis:RELative 50 d 3 . [:SENSe]:EVENt:HYSTeresis:RELative 0 :INPut:IMPedance <numeric_value>...
  • Page 30 Commands Summary Front Panel to SCPI Command Maps Figure 2-2. Instrument Control, Utility, Recall, and Save & Print Keys to SCPI Command Map (Part 1 of 2)
  • Page 31 Commands Summary Front Panel to SCPI Command Maps *IDN? No command c 1 . [:SENSe]:ROSCillator:SOURce INTernal c 2 . [:SENSe]:ROSCillator:SOURce EXTernal c 3 . [:SENSe]:ROSCillator:SOURce:AUTO ON No command (See Calibration menu, Figure 2-6) No command No command *TST? :SYSTem:COMMunicate:SERial:TRANsmit:BAUD <numeric_value> :SYSTem:COMMunicate:SERial:TRANsmit:PARity[:TYPE] EVEN | ODD | NONE :SYSTem:COMMunicate:SERial:TRANsmit:PACE XON | NONE...
  • Page 32 Commands Summary Front Panel to SCPI Command Maps Figure 2-3. MEASURE Keys to SCPI Command Map (Part 1 of 2) [:SENSe]:FUNCtion[:ON] "[:][XNONe:]FREQuency [1]"...
  • Page 33 Commands Summary Front Panel to SCPI Command Maps [:SENSe]:FUNCtion[:ON] "[:][XNONe:]PERiod [1]" [:SENSe]:FUNCtion[:ON] "[:][XNONe:]FREQuency:RATio [1,2]" [:SENSe]:FUNCtion[:ON] "[:][XNONe:]FREQuency:RATio 2,1" [:SENSe]:FUNCtion[:ON] "[:][XNONe:]VOLTage:MINimum [1]" [:SENSe]:FUNCtion[:ON] "[:][XNONe:]VOLTage:MAXimum [1]" [:SENSe]:FUNCtion[:ON] "[:][XNONe:]FREQuency 2" Since the primary purpose of these front-panel keys is to change the function, the corresponding [:SENSe]:FUNCtion[:ON] command is listed in the menu map above.
  • Page 34 Commands Summary Front Panel to SCPI Command Maps Frequency, Period, Ratio Auto Arming: GATE: AUTO Digits Arming: GATE: DIGITS DIGITS: <digits> Time Arming: GATE: TIME TIME: <time> External Arming: GATE: EXTERNL START: POS STOP: AUTO STOP: STOP: TIME TIME: <time> Figure 2-4.
  • Page 35 Commands Summary Front Panel to SCPI Command Maps Frequency, Period, Ratio Auto Arming: [:SENSe]:FREQuency:ARM[:STARt]:SOURce IMMediate [:SENSe]:FREQuency:ARM:STOP:SOURce IMMediate Digits Arming: [:SENSe]:FREQuency:ARM[:STARt]:SOURce IMMediate [:SENSe]:FREQuency:ARM:STOP:SOURce DIGits [:SENSe]:FREQuency:ARM:STOP:DIGits <numeric_value> Time Arming: [:SENSe]:FREQuency:ARM[:STARt]:SOURce IMMediate [:SENSe]:FREQuency:ARM:STOP:SOURce TIMer [:SENSe]:FREQuency:ARM:STOP:TIMer <numeric_value> [S] External Arming: [:SENSe]:FREQuency:ARM[:STARt]:SOURce EXTernal [:SENSe]:FREQuency:ARM[:STARt]:SLOPe POSitive | NEGative h 1 .
  • Page 36 Commands Summary Front Panel to SCPI Command Maps Figure 2-5. LIMITS and MATH Keys to SCPI Command Map (Part 1 of 2) 2-12...
  • Page 37 Commands Summary Front Panel to SCPI Command Maps :CALCulate2:LIMit:UPPer[:DATA] <numeric_value> [HZ | S] :CALCulate2:LIMit:LOWer[:DATA] <numeric_value> [HZ | S] :CALCulate2:LIMit:STATe OFF | ON b 1 . :INITiate:AUTO OFF b 2 . :INITiate:AUTO ON :CALCulate2:LIMit:DISPlay GRAPh | NUMBer :DISPlay[:WINDow]:TEXT:FEED "CALC3" :CALCulate3:AVERage:TYPE MAXimum | MINimum | SDEViation | MEAN :DISPlay[:WINDow]:TEXT:FEED "CALC2"...
  • Page 38 Commands Summary Front Panel to SCPI Command Maps Figure 2-6. Display Digits and Calibration Menu to SCPI Command Maps 2-14...
  • Page 39 Commands Summary Front Panel to SCPI Command Maps :DISPlay[:WINDow]:TEXT:MASK <numeric_value> :CALibration:SECurity:STATe? :DIAGnostic:CALibration:INPut1:OFFSet:AUTO ONCE :DIAGnostic:CALibration:INPut1:GAIN:AUTO ONCE :DIAGnostic:CALibration:ROSCillator:AUTO ONCE c 1 . :CALibration:SECurity:CODE <new_code> :CALibration:SECurity:STATe ON, <present_code> c 2 . :CALibration:SECurity:STATe OFF, <present_code> :CALibration:COUNt? No command The Calibration Menu is accessed by holding the Scale & Offset key and cycling NOTE POWER key.
  • Page 40: Hp 53181A Command Summary

    SCPI Conformance Information The SCPI commands used in the HP 53181A are in conformance with the SCPI Standard Version 1992.0 . The SCPI command set consists of the following: • Common commands as defined in IEEE 488.2-1987— listed and summarized in Table 2-1.
  • Page 41: Ieee 488.2 Common Commands

    Commands Summary HP 53181A Command Summary IEEE 488.2 Common Commands The Common Commands are general purpose commands that are common to all instruments (as defined in IEEE 488.2). Common Commands are easy to recognize because they all begin with an “*” (for example, *RST, *IDN?, *OPC ). These commands are generally not related to measurement configuration.
  • Page 42 Commands Summary HP 53181A Command Summary Table 2-1. IEEE 488.2 Common Commands Mnemonic Command Name Function *CAL? Calibration Causes the Counter to perform an internal interpolator self- calibration and returns a response that indicates whether or not the instrument completed the self-calibration without error.
  • Page 43 Commands Summary HP 53181A Command Summary Table 2-1. IEEE 488.2 Common Commands (Continued) Mnemonic Command Name Function *OPT? Option Identification Query Identifies the options installed in the Counter. Deletes all macros previously defined using the *PMC Purge Macro Command *DMC command.
  • Page 44: Hp 53181A Scpi Subsystem Commands

    The category of “New” consists of commands that could be: • SCPI approved but are not yet in the SCPI manual • HP approved and submitted for SCPI approval. • Not approved at all. The “New” commands operate as defined in this guide.
  • Page 45: Scale_Offset

    :FAIL? Query only. Returns a 0 or 1 to indicate if the last tested measurement passed or failed the limit test. 0 = pass; 1 = fail. Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments...
  • Page 46 MEAN :DATA? Query only. Returns statistic result specified by :CALC3:AVER:TYPE. :FEED "[:]CALCulate[1]" Sets the data flow to be fed into the CALCulate3 block. Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments 2-22...
  • Page 47 Commands Summary HP 53181A Command Summary :CALCulate3 (Cont.) :LFILter Subtree. Limit FILter for statistics. :LOWer Subtree. [:DATA] <numeric_value> [HZ | S] Sets the statistics filter lower limit. :STATe <Boolean> Sets the statistics filter enable. :UPPer Subtree. [:DATA] <numeric_value> [HZ | S] Sets the statistics filter upper limit.
  • Page 48 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments :DIAGnostic :CALibration (Cont.) :ROSCillator Subtree. ROSCillator is an abbreviation for Reference OSCillator. :AUTO ONCE | OFF ONCE calibrates the timebase. This command is usable only if the instrument contains the medium or high stability oscillator option.
  • Page 49 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments :INITiate Subsystem. Controls the initiation of measurements. :AUTO <Boolean> AUTO ON enables the Counter to automatically stop measuring on a limit test failure. AUTO OFF disables the automatic stop.
  • Page 50 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments Measurement Instructions* :CONFigure[:SCALar]:<function> See <parameters> and Configures instrument to perform <source_list> in table on the next specified measurement. page. Returns function configured by the last :CONF or :CONFigure? :MEAS command.
  • Page 51 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments :MEMory Subsystem. Manages instrument memory. Subtree. :DELete Event; no query. Deletes the macro with :MACRo <string> the name specified by the string parameter.
  • Page 52 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments [:SENSe] (Cont.) :EVENt2 Subtree. Queries the characteristics of the “ trigger event” for channel 2 input. :LEVel Subtree. [:ABSolute]? Query only. Returns the channel 2 input trigger level.
  • Page 53 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments [:SENSe] (Cont.) :FUNCtion Subtree. Selects the <sensor function> to be sensed by the instrument. [:ON] <sensor_function> (See below) Sets the <sensor function> to be sensed by the instrument.
  • Page 54 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments :STATus Subsystem. Controls the SCPI-defined (Operation and Questionable) status-reporting structures. :OPERation Subtree. :CONDition? Query only.Queries the Operation Condition Status Register. :ENABle <non-decimal numeric>...
  • Page 55 Commands Summary HP 53181A Command Summary Table 2-2. HP 53181A SCPI Command Summary (Continued) Keyword/Syntax Parameter Form Std/ Comments :SYSTem Subsystem. Collects the functions that are not related to instrument performance. :COMMunicate Subtree. Collects together configuration of control/communication interfaces. :SERial Subtree.
  • Page 56: Scale_Offset

    (Use *CLS to clear the status event registers and the SCPI error queue.) The states of commands affected by the *RST command are described in Table 2-3. Table 2-4 lists commands that are unaffected by *RST. Table 2-3. HP 53181A *RST State Command Header Parameter State :CALCulate[1]:FEED "[:]SENSe[1]"...
  • Page 57 Commands Summary *RST Response Table 2-3. HP 53181A *RST State (Continued) Command Header Parameter State :HCOPy:CONTinuous <Boolean> :INITiate:AUTO <Boolean> :INITiate:CONTinuous <Boolean> :INPut:ATTenuation 1 | 10 :INPut:COUPling AC | DC :INPut:FILTer[:LPASs]:STATe <Boolean> :INPut:IMPedance <numeric_value> [OHM] 1E6 OHM [:SENSe]:EVENt:HYSTeresis:RELative <numeric_value> [PCT] 100 PCT [:SENSe]:EVENt:LEVel[:ABSolute]:AUTO <Boolean>...
  • Page 58 Commands Summary *RST Response Table 2-4. Unaffected by *RST Item OPC? :CALibration:COUNt? :CALibration:DATA :CALibration:SECurity:CODE :CALibration:SECurity:STATe :DISPlay[:WINDow]:TEXT:RADix :STATus:OPERation:ENABle :STATus:OPERation:NTRansition :STATus:OPERation:PTRansition :STATus:QUEStionable:ENABle :STATus:QUEStionable:NTRansition :STATus:QUEStionable:PTRansition :SYSTem:COMMunicate:SERial:CONTrol:DTR :SYSTem:COMMunicate:SERial:TRANsmit:BAUD :SYSTem:COMMunicate:SERial:TRANsmit:PACE :SYSTem:COMMunicate:SERial:TRANsmit:PARity[:TYPE] :SYSTem:ERRor? (Error Queue) HP-IB Address 2-34...
  • Page 59 Programming Your Counter for Remote Operation...
  • Page 60 • Writing SCPI Programs pg. 3-56 • Programming Examples pg. 3-59 Where to Find Some Specific Information • To Set the HP-IB Mode and Address pg. 3-4 • To Connect the Counter to a Computer pg. 3-6 • Remote/Local Operation pg.
  • Page 61 Programming Your Counter for Remote Operation Introduction Where to Find HP BASIC Programming Examples • Easiest Way to Make a Measurement pg. 3-61 • To Make a Frequency Measurement pg. 3-63 • To Perform Limit Testing pg. 3-64 • To Measure the Statistics of 50 Measurements pg.
  • Page 62 To select the talk/listen operating mode, set the Counter's HP-IB address from 0 to 30. Refer to the following section titled “To Set the HP- IB Mode and Address” for instructions on how to set an HP-IB address from the front-panel.
  • Page 63 Press the appropriate arrow keys until HP-IB: 15 is displayed. c. Go on to step 4. 3b To set the HP-IB mode to “TALK,” perform the following: a. Press s key. HP-IB: 03 is displayed. Note that “0” digit appears and is highlighted,...
  • Page 64 Programming Your Counter for Remote Operation Configuring the HP-IB To Connect the Counter to a Computer Connect the Counter to a computer by simply installing an HP-IB cable (such as an HP 10833A cable) between the two units as shown in Figure 3-1.
  • Page 65 Overview of Command Types and Formats Overview of Command Types and Formats There are two types of HP 53181A programming commands: IEEE 488.2 Common Commands and Standard Commands for Programmable Instruments (SCPI). The IEEE 488.2 Common Commands control and manage communications between the HP 53181A and the controller or personal computer.
  • Page 66 (or keywords with colon separators), program data, and terminators . These elements are sent to the Counter over the HP-IB as a sequence of ASCII data messages. Examples of a typical Common Command and Subsystem Command are: OUTPUT 712;"...
  • Page 67 The command syntax shows most keywords as a mixture of upper and lower case letters. Upper case letters indicate the abbreviated spelling for the command. For better program readability, you may send the entire keyword. The HP 53181A accepts either command form and is not case sensitive.
  • Page 68 Programming Your Counter for Remote Operation Elements of SCPI Commands Optional Keyword Optional keywords are those which appear in square brackets ([ ]) in the command syntax. (Note that the brackets are not part of the command and are not sent to the Counter.) Suppose you send a second level keyword without the preceding optional keyword.
  • Page 69 A string parameter is delimited by either single quotes or double quotes. Within the quotes, any characters in the ASCII 7-bit code may be specified. The following HP BASIC program statement sends a command containing a <string> parameter: <non-decimal OUTPUT 703;"FUNC ‘FREQ’"...
  • Page 70 Programming Your Counter for Remote Operation Elements of SCPI Commands Parameter Separator If you send more than one parameter with a single command, you must separate adjacent parameters with a comma . Query Parameters All selectable <numeric value> parameters can be queried to return the minimum or maximum values they are capable of being set to by sending a MINimum or MAXimum parameter after the “?.”...
  • Page 71 Programming Your Counter for Remote Operation Elements of SCPI Commands Suffix Multipliers Table 3-2 lists the suffix multipliers that can be used with suf fix elements (except PCT and DEG). Table 3-2. Suffix Multipliers DEFINITION MNEMONIC NAME 1E18 1E15 PETA 1E12 TERA GIGA...
  • Page 72 Program Messages are a combination of one or more properly formatted SCPI Commands. Program messages always go from a computer to the Counter. They are sent to the Counter over the Counter's HP-IB as a sequence of ASCII data messages. Program Message Syntax Figure 3-4 shows the simplified syntax of a program message.
  • Page 73 Programming Your Counter for Remote Operation Using Multiple Commands :INP:COUP AC;:INP:IMP 50 The “:” must be present to distinguish another root level command. For example: :INP:COUP AC;:INIT:CONT OFF is equivalent to sending: :INP:COUP AC :INIT:CONT OFF If the “:”(which is following the “;” and is in front of INIT) is omitted, the Counter assumes that the second command is “:INP:INIT:CONT OFF”...
  • Page 74 After receiving a query, the Counter interrogates the requested configuration and places the response in its HP-IB output queue. The output message remains in the queue until it is read or another command is issued. When read, the message is transmitted across the HP-IB to the computer.
  • Page 75 Programming Your Counter for Remote Operation Overview of Response Message Formats NOTE: <new line> = ASCII character decimal 10 ^END = EOI asserted concurrent with last byte ; = multiple response separator (ASCII character decimal 59) , = data separator within a response (ASCII character decimal 44) Figure 3-5.
  • Page 76 Programming Your Counter for Remote Operation Overview of Response Message Formats Response Message Data Types Table 3-3 contains explanations of response data types. Table 3-3. Response Message Data Types Type Description <NR1> This numeric representation has an implicit radix point. The maximum number of characters in <NR1>...
  • Page 77 Programming Your Counter for Remote Operation Overview of Response Message Formats Table 3-3. Response Message Data Types (Continued) Type Description <Boolean> A single ASCII-encoded byte, 0 or 1, is returned for the query of settings that use <Boolean> parameters. <literal> ASCII-encoded bytes corresponding to the short form of the literal used as the command parameter.
  • Page 78 Status Reporting Status Reporting The HP 53181A status registers conform to the SCPI and IEEE 488.2 standards. Figure 3-6 shows all the status system register groups and queues in the Counter. This is a high level drawing that does not show all the registers that are contained in each group .
  • Page 79 Programming Your Counter for Remote Operation Status Reporting Figure 3-6. HP 53181A SCPI Status Reporting Summary Functional Diagram 3-21...
  • Page 80 Programming Your Counter for Remote Operation Status Reporting Status Byte Register and Service Request Enable Register Figure 3-7. Status Byte and Service Request Enable 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 as shown in Figure 3-7.
  • Page 81 Programming Your Counter for Remote Operation Status Reporting Table 3-3. Status Byte Register WEIGHT SYMBOL DESCRIPTION Not used Not used Not used Questionable Data/Signal Status Register Summary Bit Message Available Summary Bit Standard Event Status Register Summary Bit RQS/MSS Request Service/Master Status Summary Bit Operation Status Register Summary Bit A detailed description of each bit in the Status Byte Register follows: •...
  • Page 82 Programming Your Counter for Remote Operation Status Reporting • Bit 5 (ESB) summarizes the Standard Event Status Register. This bit indicates whether or not one of the enabled Standard Event Status Register events have occurred since the last reading or clearing of the Standard Event Status Register.
  • Page 83 Programming Your Counter for Remote Operation Status Reporting Standard Event Status Register Group Figure 3-8. Standard Event Status Reporting Standard Event Status Register The Standard Event Status Register contains bits that monitor specific IEEE 488.2- defined events as shown in Figure 3-8. Use *ESR? to read this register.
  • Page 84 Programming Your Counter for Remote Operation Status Reporting Table 3-4. Standard Event Status Register WEIGHT SYMBOL DESCRIPTION Operation Complete (RQC) Not used because this instrument cannot request permission to become active IEEE 488.1 controller-in-charge. Query Error Device-Specific Error Execution Error Command Error (URQ) Not used because this instrument does not...
  • Page 85 Programming Your Counter for Remote Operation Status Reporting the TRIGger:COUNt:AUTO is ON, and statistics are enabled, and the function is set to Voltage Peaks, then the pending operation condition is set TRUE when a block of measurements is initiated. The pending operation condition is set FALSE when the block of measurements completes;...
  • Page 86 Programming Your Counter for Remote Operation Status Reporting The Standard Event Status Enable Register selects which events in the Standard Event Status Register are reflected in the ESB summary bit (bit 5) of the Status Byte Register as shown in Figure 3-8. Use *ESE to write to this register and *ESE? to read this register.
  • Page 87 Programming Your Counter for Remote Operation Status Reporting Figure 3-9. Operation and Questionable Status Reporting Model 3-29...
  • Page 88 Programming Your Counter for Remote Operation Status Reporting Condition Register A condition register continuously monitors the hardware and firmware status of the Counter. There is no latching or buffering for this register; it is updated in real time. Reading a condition register does not change its contents. To read the condition registers use: :STATus:OPERation:CONDition? :STATus:QUEStionable:CONDition?
  • Page 89 Programming Your Counter for Remote Operation Status Reporting :STATus:OPERation:PTRansition :STATus:OPERation:NTRansition :STATus:QUEStionable:PTRansition :STATus:QUEStionable:NTRansition To read the transition filter registers use: :STATus:OPERation:PTRansition? :STATus:OPERation:NTRansition? :STATus:QUEStionable:PTRansition? :STATus:QUEStionable:NTRansition? Event Register An event register captures changes in conditions. An event register bit (event bit) shall be set TRUE when an associated event occurs. These bits, once set, are “sticky.”...
  • Page 90 A detailed description of each bit in the Operation Status Register follows: • Bit 0 (Calibrating) is a condition bit which indicates the Counter is currently performing a (front-panel invoked or HP-IB invoked) calibration. The condition bit is TRUE (one) during a calibration and FALSE (zero) otherwise.
  • Page 91 This bit monitors both explicit and automatic reference changes. Explicit reference changes occur when you select internal or external using the front- panel Utility menu or the HP-IB command, [:SENS]:ROSC:SOUR. Automatic reference changes occur when the Counter is configured to select the reference (automatically) by detecting whether or not an external reference is being supplied.
  • Page 92 Programming Your Counter for Remote Operation Status Reporting Table 3-7 lists the Questionable Data/Signal Status Register bits and briefly describes each bit. 3-34...
  • Page 93 Programming Your Counter for Remote Operation Status Reporting Table 3-7. Questionable Data/Signal Status Register WEIGHT DESCRIPTION Not used Not used Time (Period) Not used Not used Frequency (only Frequency; not Frequency Ratio) Not used Not used Calibration Error Not used 1024 Out of Limit Event 11-13...
  • Page 94 • Bit 7 is not used. • Bit 8 (Calibration Error) is an event bit which indicates that one of the following has occurred: 1) an HP-IB invoked calibration failed, 2) a front- panel invoked calibration failed, 3) an automatic interpolator calibration failed during the measurement cycle, or 4) an automatic measurement calibration failed during the measurement cycle.
  • Page 95 Programming Your Counter for Remote Operation Command Settings for Optimizing Throughput Command Settings for Optimizing Throughput This section lists the commands which enable the Counter to transfer data at the fastest possible rate. See the “To Optimize Throughput” sample programs on pages 3-70 , 3-86, and 3-97.
  • Page 96 Programming Your Counter for Remote Operation Command Settings for Optimizing Throughput Disable checking of external source if using external reference oscillator: [:SENSe]:ROSCillator:EXTernal:CHECk OFF (See Note below.) Disable automatic interpolator calibration :DIAGnostic:CALibration:INTerpolator:AUTO OFF (See Note below.) Disable display :DISPlay:ENABle OFF (See Note below.) Disable printing: :HCOPy:CONTinuous OFF Disable post-processing (math, limit testing, statistics)
  • Page 97 (Frequency Time Arming .001). You only have to change the function in the program to generate the numbers in the table. Table 3-8. Typical Optimizing Throughput Results in Measurements per Second IBM PC Compatible HP 82324A HP 9000 Series 300 486/25 MHz Basic Language Model 360 Function HP 82335A Card...
  • Page 98 The first three groups all have event registers that can be fed into the Status Byte Register. The Status Byte Register can be used to assert the SRQ line of the HP-IB and thus alert the computer that the Counter needs attention. The following examples show how each of the register groups can be used.
  • Page 99 Example 3 The default operation of the Counter is for automatic interpolator calibration to occur before every measurement. To optimize throughput over the HP-IB, the automatic calibration can be disabled. When it is disabled, the most recent calibration values are used. These values may not be the optimal values for a particular temperature or other environmental condition.
  • Page 100 Programming Your Counter for Remote Operation How to Program the Counter for Status Reporting Questionable Data Status Register :STAT:QUES:PTR 100; NTR 0 Detect transition from non-questionable to questionable data. :STAT:QUES:ENABLE 100 Enable to detect for auto cal off. *SRE 8 Assert SRQ on Questionable Summary bit.
  • Page 101 Programming Your Counter for Remote Operation How to Program the Counter for Status Reporting Figure 3-10. Status Reporting Flowchart (1 of 2) 3-43...
  • Page 102 Programming Your Counter for Remote Operation How to Program the Counter for Status Reporting Figure 3-10. Status Reporting Flowchart (2 of 2) 3-44...
  • Page 103 Programming Your Counter for Remote Operation How to Program the Counter to Display Results How to Program the Counter to Display Results Configuring the Counter's Display The Counter has five different display modes: 1. Non-scaled/offset results - frequency, period, or ratio. This display mode is used on power-up.
  • Page 104 Programming Your Counter for Remote Operation How to Program the Counter to Display Results Commands for Displaying Scaled/Offset Results The following lines will enable Math (scale/offset). It is assumed that the values for scale and offset are already set. If not, the default value for scale is 1 and for offset is 0.
  • Page 105 Commands for Enabling and Disabling the Display The Counter display can be turned on or off. The normal condition is for the display to be on. To achieve maximum HP-IB throughput, the display must be disabled. :DISP:ENABLE OFF Disable the display, all segments off.
  • Page 106 3. Using the *OPC command to assert SRQ The following discussion shows how to use all three methods. Resetting the Counter and Clearing the HP-IB Interface Before attempting any programming, it is a good idea to set the Counter to a known state.
  • Page 107 Programming Your Counter for Remote Operation How to Program the Counter to Synchronize Measurements :CALC3:AVERAGE ON Enable statistics. :CALC3:AVERAGE:COUNT 50 Base statistics on 50 measurements. :TRIG:COUNT:AUTO ON On INIT, take 50 measurements. :INIT Start 50 measurements. *WAI Wait until 50 measurements are complete before Counter executes another command.
  • Page 108 Ask for statistics. Using the *OPC Command to Assert SRQ This method is recommended when the Counter is on the HP-IB with many other instruments, any of which can assert SRQ. The commands *OPC, *ESE 1 and *SRE 32 are used to assert the SRQ line to alert the computer that the Counter has completed a measurement.
  • Page 109 How to Program the Counter for Math/Limit Operations Updating Math and Limit Results Over HP-IB When using the Limits or Math capabilities from the front panel, the default (power-up) operation is for results to be automatically updated whenever a value is updated in either the Limit or Scale&Offset menu.
  • Page 110 The section in this chapter titled “How to Program the Counter to Display Results” uses the :CALC:IMM technique to make sure the results are properly displayed. Using the Scale and Offset Over HP-IB Using the scale and offset values over the bus is different from setting any other value.
  • Page 111 Programming Your Counter for Remote Operation How to Program the Counter to Define Macros How to Program the Counter to Define Macros A macro is a user defined command that can be used to replace one or many Counter commands. There are two good reasons to use macros in place of other commands: 1.
  • Page 112 :DISP:MENU 0;TEXT:FEED 'CALC2';:CALC2:LIM:STAT 1;DISP GRAP; :CALC:IMM Programming examples using macros are provided in the following section titled “Programming Examples.” The first macro program listing (starting on page 3- 73) uses HP BASIC for an HP 9000 series 300 computer. The second Macro program 3-54...
  • Page 113 How to Program the Counter to Define Macros listing (starting on page 3- 88) is for an IBM PC (or clone) and HP 82335A/B card. Both are softkey driven and can be used to define macros, enable or disable macros, determine what macros are available and purge macros.
  • Page 114 Programming Your Counter for Remote Operation Writing SCPI Programs Writing SCPI Programs Figure 3-11 is a general summation of how to write SCPI programs . It shows a typical sequence you might go through in the process of writing a program. You do not have to follow this exact sequence, but it will help you to become familiar with the Counter's capabilities and to direct you to sections of the guide which will be useful while writing programs.
  • Page 115 Programming Your Counter for Remote Operation Writing SCPI Programs Figure 3-11. SCPI Programming Flowchart (Sheet 1 of 2) 3-57...
  • Page 116 Programming Your Counter for Remote Operation Writing SCPI Programs Figure 3-11. SCPI Programming Flowchart (Sheet 2 of 2) 3-58...
  • Page 117 Programming Your Counter for Remote Operation Programming Examples Programming Examples In this section, you will see how to program the HP 53181A to make many common measurements. Examples are provided in the following programming languages: • HP BASIC • Microsoft ® QuickBASIC (version 4.5) •...
  • Page 118 1. Easiest Way to Make a Measurement (HP BASIC only) 2. To Make a Frequency Measurement 3. To Perform Limit Testing (HP BASIC and QuickBASIC only) 4. To Measure the Statistics of 50 Measurements (HP BASIC and QuickBASIC only) 5. To Use Limits to Filter Data Before Measuring Statistics.
  • Page 119 Programming Your Counter for Remote Operation Programming Examples Easiest Way to Make a Measurement (HP BASIC) 10 ! This program shows how to use the MEASure group of instructions to 20 ! quickly and easily make any of the counter's measurements.
  • Page 120 570 ! CONF can be used to configure a measurement. Additional commands 580 ! can then be issued to fine tune the measurement setup. The READ? command Easiest Way to Make a Measurement (HP BASIC) (Continued) 590 ! than reads the result. In the following example, a frequency measurement...
  • Page 121 Programming Your Counter for Remote Operation Programming Examples To Make a Frequency Measurement (HP BASIC) 10 ! This program sets up the counter to make 10 frequency 20 ! measurements on channel 1, using a 0.1 second gate time. 30 ! The results are displayed on the computer CRT.
  • Page 122 Programming Your Counter for Remote Operation Programming Examples To Perform Limit Testing (HP BASIC) 10 ! This program sets up the counter to make period measurements 20 ! indefinitely until an out of limits measurement occurs. 30 ! The upper limit is 1 usec and the lower limit is 500 nsec.
  • Page 123 Programming Your Counter for Remote Operation Programming Examples To Measure the Statistics of 50 Measurements (HP BASIC) ! This program instructs the counter to take 50 period measurements. ! The counter is put into SINGLE measurement mode. The number of ! measurements to take is programmed using ":CALC3:AVER:COUNT 50"...
  • Page 124 Programming Your Counter for Remote Operation Programming Examples 550 Get_averages: ! Data ready Serial_poll=SPOLL(703) OUTPUT @Count;":CALC3:AVERAGE:TYPE MAX;:CALC3:DATA?" ENTER @Count;Maximum$ To Measure the Statistics of 50 Measurements (HP BASIC) (Continued) OUTPUT @Count;":CALC3:AVERAGE:TYPE MIN;:CALC3:DATA?" ENTER @Count;Minimum$ OUTPUT @Count;":CALC3:AVERAGE:TYPE MEAN;:CALC3:DATA?" ENTER @Count;Mean$ OUTPUT @Count;":CALC3:AVERAGE:TYPE SDEV;:CALC3:DATA?" ENTER @Count;Sdev$ PRINT PRINT "Serial Poll = ";Serial_poll...
  • Page 125 Programming Your Counter for Remote Operation Programming Examples To Use Limits to Filter Data Before Measuring Stats (HP BASIC) ! This program instructs the counter to determine the statistics of ! 50 Period measurements that are within the limits defined by the ! variables "Upper"...
  • Page 126 Programming Your Counter for Remote Operation Programming Examples ! must happen in order to To Use Limits to Filter Data Before Measuring Stats (HP BASIC) (Continued) ! see the limit graph. OUTPUT @Count;":CALC2:LIM:LOWER ";Lower ! Set the limits lower limit OUTPUT @Count;":CALC2:LIM:UPPER ";Upper...
  • Page 127 ! Array to hold calibration data DIM Err_string$[255] ! Array to hold error message CLEAR SCREEN ASSIGN @Count TO 703 ! Assign I/O path for HP 53181A CLEAR @Count OUTPUT @Count;"*RST" ! Reset the HP 53181A OUTPUT @Count;"*CLS" ! Clear event registers and error queue OUTPUT @Count;"*SRE 0"...
  • Page 128 Programming Your Counter for Remote Operation Programming Examples To Optimize Throughput (HP BASIC) ! This program shows how to set up the counter to transfer data at the ! fastest possible rate. Note that the arming mode is AUTO. This mode ! provides the least resolution of all arming modes.
  • Page 129 Programming Your Counter for Remote Operation Programming Examples ! increases throughput. When ! high throughput is not needed, ! the expected value is not 3-71...
  • Page 130 Programming Your Counter for Remote Operation Programming Examples To Optimize Throughput (HP BASIC) (Continued) ! required. FOR I=1 TO 200 TRIGGER @Count ! Trigger the counter and read ENTER @Count;A$(I) NEXT I FOR I=1 TO 10 ! Print first 10 measurements...
  • Page 131 Programming Your Counter for Remote Operation Programming Examples To Use Macros (HP BASIC) USER 1 KEYS ON KEY 1 LABEL " Macro Free ",1 CALL Macro_free ON KEY 2 LABEL " Enable Macros",1 CALL Macro_enable ON KEY 3 LABEL " Display Macros",1 CALL Display_macros ON KEY 4 LABEL "...
  • Page 132 Programming Your Counter for Remote Operation Programming Examples Length=LEN(Macro$) Num_char=INT(LGT(Length))+1 ! Determine # of characters for header Header$="#"&VAL$(Num_char) 3-74...
  • Page 133 Programming Your Counter for Remote Operation Programming Examples To Use Macros (HP BASIC) (Continued) Send$="*DMC "&CHR$(39)&Name$&CHR$(39)&","&Header$&VAL$(Length)&Macro$ OUTPUT 703;Send$ SUBEND SUB Macro_query ! Ask for the definition of a macro. DIM Name$[25],Macro$[255] CLEAR SCREEN CALL Display_macros LINPUT "Enter the name of the macro you want to see",Name$ IF Name$=""...
  • Page 134 'Data is sent in ASCII format to preseve resolution. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS' 'Required by HP 82335A DIM SHARED source AS LONG 'Address and select code DIM i AS INTEGER...
  • Page 135 'The out of limit period is sent in ASCII format to preserve resolution. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS' 'Required by HP 82335A DIM SHARED source AS LONG 'Address and select code DIM period AS STRING * 23...
  • Page 136 Programming Your Counter for Remote Operation Programming Examples Loophere: 'Wait here until out of limit IF complete THEN GOTO endprogram 'If already serviced out of limit GOTO Loophere 'then end program To Perform Limit Testing (QuickBASIC) (Continued) limitfail: complete = 1 'Test bit CALL IOSPOLL(source&, statusbyte) 'Check status byte.
  • Page 137 'Note that the *OPC command must be sent at the start of every measurement. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS' 'Required by HP 82335A DIM SHARED source AS LONG 'Address and select code DIM samples AS INTEGER...
  • Page 138 Programming Your Counter for Remote Operation Programming Examples CALL sendhp(":FREQ:ARM:STAR:SOUR IMM") 'These 3 lines enable using CALL sendhp(":FREQ:ARM:STOP:SOUR TIM") 'time arming with a 0.01 second To Measure the Statistics of 50 Measurements (QuickBASIC) (Continued) CALL sendhp(":FREQ:ARM:STOP:TIM .01") 'gate time CALL sendhp(":DISP:TEXT:FEED " + CHR$(34) + "CALC3" + CHR$(34)) 'Display stats CALL sendhp(":CALC3:AVER:TYPE SDEV") 'Display the standard deviation CALL sendhp(":CALC3:AVER ON")
  • Page 139 'filters, an SRQ can be generated when statistics are complete. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS' 'Required by HP 82335A DIM SHARED source AS LONG 'Address and select code DIM status AS INTEGER...
  • Page 140 Programming Your Counter for Remote Operation Programming Examples CALL sendhp(":STAT:OPER:NTR 256") 'When stats are complete, the bit CALL sendhp(":STAT:OPER:PTR 0") 'will go from high to low, so a 'negative transition is needed to 3-82...
  • Page 141 Programming Your Counter for Remote Operation Programming Examples To Use Limits to Filter Data Before Measuring Stats (QuickBASIC) (Continued) 'enable the bit that is summarized 'in the Status Byte Register. CALL sendhp("*SRE 128") 'This is the bit from the Operation 'Status register that is summarized 'in the Status Byte Register.
  • Page 142 Programming Your Counter for Remote Operation Programming Examples SUB sendhp (code$) CALL iooutputs(source, code$, LEN(code$)) END SUB 3-84...
  • Page 143 'the counter. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS' 'Required by HP 82335A DIM SHARED source AS LONG 'Address and select code DIM CALDATA AS STRING * 61 'Strings to be read source&...
  • Page 144 'quickly, but at the least resolution the counter can provide. 'See the program comments for details. 'Requires an HP 82335A/B HPIB interface card to a PC. 'The data is sent in ASCII format to preserve resolution. 'The SUB sendhp sends commands to the counter DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS'...
  • Page 145 Programming Your Counter for Remote Operation Programming Examples 'calibration. The most recent 'calibration factors will be 'used in the calculation for 'frequency To Optimize Throughput (QuickBASIC) (Continued) CALL sendhp("*DDT #15FETC?") 'Define trigger as fetc? CALL sendhp(":DISP:ENABLE OFF") 'Turn off the display CALL sendhp("READ:FREQUENCY?") 'Read the expected frequency CALL IOENTERS(source&, freqstring(1), maxelem%, actual%)
  • Page 146 'This program is useful for writing macros for the counter. Softkeys 'are available at the bottom of the computer screen to help determine 'the status of the macros. 'The SUB sendhp sends commands to the HP 53181A DECLARE SUB sendhp (code$) REM $INCLUDE: 'QBSETUP.BAS'...
  • Page 147 Programming Your Counter for Remote Operation Programming Examples ON KEY(9) GOSUB sendmacro ON KEY(10) GOSUB quit loophere: GOTO loophere 'Wait for function key to be pressed To Use Macros (QuickBASIC) (Continued) availablememory: 'Display available macro memory CALL sendhp(":MEM:FREE:MACRO?") CALL IOENTER(source&, freemacro) PRINT "Available macro memory = ";...
  • Page 148 Programming Your Counter for Remote Operation Programming Examples RETURN sendmacro: GOSUB displaymacro INPUT "Enter the name of the macro to send ", namemacro$ IF namemacro$ = "" THEN RETURN sendhp (namemacro$) RETURN To Use Macros (QuickBASIC) (Continued) definemacro: 'Define a macro INPUT "Enter the name of the macro to be defined ", namemacro$ INPUT "Enter the commands to be sent ", commandmacro$ length = LEN(commandmacro$)
  • Page 149 #include "CFUNC.H" void sendhp(char *); /* function to send command to counter */ /* global data */ long ctr=703; /* Counter is at address 03. HP-IB is at select code 7 error; void main() long isc=7; /* Select code 7 */ int state=1;...
  • Page 150 Programming Your Counter for Remote Operation Programming Examples 3-92...
  • Page 151 Programming Your Counter for Remote Operation Programming Examples To Make a Frequency Measurement (Turbo C) (Continued) /* Function to send command to HP 53181A */ void sendhp(hpib_cmd) char *hpib_cmd; char hpcmd[80]; /* Variables used by function */ int length; strcpy(hpcmd,hpib_cmd);...
  • Page 152 *); /* function to send command to counter */ /* global data */ long ctr=703; /* Counter is at address 03. HP-IB is at select code 7 */ error; void main() long isc=7; /* Select code 7 */ int condition=1;...
  • Page 153 Programming Your Counter for Remote Operation Programming Examples so a negative transition is needed to enable the bit that is summarized in the Status Byte register. */ To Use Limits to Filter Data Before Measuring Statistics (Turbo C) (Continued) sendhp("*SRE 128"); /* This is the bit from the Operation Status register that is summarized in the Status Byte Register */...
  • Page 154 Programming Your Counter for Remote Operation Programming Examples /* Function to send command to HP 53131A */ void sendhp(hpib_cmd) char *hpib_cmd; To Use Limits to Filter Data Before Measuring Statistics (Turbo C) (Continued) char hpcmd[80]; /* Variables used by function */ int length;...
  • Page 155 /* HP-IB library function prototypes */ void sendhp(char *); /* function to send command to counter */ /* global data */ long ctr=703; /* Counter is at address 03. HP-IB is at select code 7 */ error; void main() long isc=7;...
  • Page 156 Programming Your Counter for Remote Operation Programming Examples calibration values are used in the calculation of frequency */ 3-98...
  • Page 157 /* Trigger the counter and */ IOENTERS(ctr,freq[i],&length); /* read the data */ printf("Measurement complete. Press a key to continue.\n"); getch(); /* Function to send command to HP 53131A */ void sendhp(hpib_cmd) char *hpib_cmd; char hpcmd[80]; /* Variables used by function */ int length;...
  • Page 158 Programming Your Counter for Remote Operation Programming Examples 3-100...
  • Page 159 Commands Reference A Dictionary...
  • Page 160 This chapter describes the SCPI Subsystem commands and the IEEE 488.2 Common commands for the HP 53181A 225 MHz Frequency Counter. The information in this chapter will help you program the Counter over the HP-IB. The commands are presented in alphabetical order.
  • Page 161 Counter. • unless otherwise noted, the command is sequential (not overlapped). See Chapter 3 in this guide for details regarding command syntax, parameter types, and query response types. See the HP 53181A Operating Guide, Table 2-6, for power-up values.
  • Page 162 Commands Reference :ABORt :ABORt This command is an event that causes the Counter to abort, as quickly as possible, any measurement in progress. The :ABORt command is not complete until the current measurement is stopped. The execution of an ABORt command sets false any Pending Operation Flags that were set true by initiation of measuring.
  • Page 163 Commands Reference :CALCulate Subsystems :CALCulate Subsystems Three :CALCulate subsystems (:CALCulate[1], :CALCulate2, and :CALCulate3) perform post-acquisition data processing and data transfer of the corresponding results. Functions in the SENSe subsystem are related to data acquisition, while the :CALCulate systems operate on the data acquired by a SENSe function as shown in Figure 4-1.
  • Page 164 Commands Reference :CALCulate Subsystems Figure 4-1. The CALCulate Subsystems...
  • Page 165 Commands Reference :CALCulate[1] Subsystem :CALCulate[1] Subsystem Performs post-acquisition math (scale/offset) processing (on the data aquired by a SENSe function) and data transfer of the scaled/offset result. See the :TRACe subsystem for commands used to set the scale and offset. Not until :CALCulate[1]:MATH:STATe is set to ON will any of the :CALCulate[1] NOTE settings or :TRACe[:DATA] settings be used.
  • Page 166 Commands Reference :CALCulate[1] Subsystem :CALCulate[1]:FEED "[:]SENSe[1]" Sets or queries the data flow to be fed into the CALCulate[1] block. Since the Counter can only sense one function at a time, there is only one valid parameter. The string "SENS" is returned. Query Response Comments *RST: "SENSe[1]"...
  • Page 167 Commands Reference :CALCulate[1] Subsystem :CALCulate[1]:IMMediate:AUTO <Boolean> Sets or queries whether post-processing (recalculation) will automatically occur whenever any changes are made to the :CALCulate[1|2] subsystems. With :CALC:IMM:AUTO set to OFF, :CALCulate[1|2] only produces new results when new SENSe data is acquired or when the :CALCulate:IMMediate command is received.
  • Page 168 Commands Reference :CALCulate[1] Subsystem :CALCulate[1]:MATH[:EXPRession][:DEFine]? Queries equation used for math operation. Query Response A sequence of ASCII-encoded bytes: ("SENS" * SCALE + OFFSET) terminated with a new line and EOI. • Query only. Comments • This query should be the la st query in a terminated program message; otherwise, error -440 is generated.
  • Page 169: Calculate2 Subsystem

    Commands Reference :CALCulate2 Subsystem :CALCulate2 Subsystem This subsystem performs post-acquisition limit testing and data transfer. Not until :CALCulate2:LIMit:STATe is set to ON will any of the :CALCulate2 NOTE settings be used. :CALCulate2:FEED "[:]CALCulate[1]" Sets or queries the data flow to be fed into the CALCulate2 block. Query Response The string "CALC"...
  • Page 170: Calculate2:Immediate:auto

    Commands Reference :CALCulate2 Subsystem :CALCulate2:IMMediate:AUTO <Boolean> Sets or queries whether post-processing (recalculation) will automatically occur whenever any changes are made to the :CALCulate[1|2] subsystems. With :CALC2:IMM:AUTO set to OFF, CALCulate[1|2] only produces new results when new SENSe data is acquired or when the CALCulate2:IMMediate command is received.
  • Page 171: Calculate2:Limit:clear:auto

    Commands Reference :CALCulate2 Subsystem :CALCulate2:LIMit:CLEar:AUTO <Boolean> Sets or queries if the limit test results are to be cleared with each :INITiate[:IMMediate] and :INITiate:CONTinuous ON operation. • Single ASCII-encoded byte, 0 or 1. Query Response • A value of 0 indicates OFF; a value of 1 indicates ON. •...
  • Page 172: Calculate2:Limit:fail

    Commands Reference :CALCulate2 Subsystem A sequence of ASCII-encoded bytes: GRAP or NUMB Query Response • *RST: NUMBer Comments • This command updates the display mode immediately. The display update is independent of :CALC2:IMM:AUTO state. • See the section titled “How to Program the Counter to Display Results” in Chapter 3 for programming examples.
  • Page 173: Calculate2:Limit:fcount:lower

    Commands Reference :CALCulate2 Subsystem :CALCulate2:LIMit:FCOunt:LOWer? Queries the number of limit test failures (that is, the Fail COunt) at the lower limit. • Numeric data transferred as ASCII bytes in <NR1> format. Query Response • If CALC2:LIM:STATe is OFF, 0 is returned and error -221 is generated. •...
  • Page 174 Commands Reference :CALCulate2 Subsystem Sets or queries the lower limit used for limit testing. When the result is less than the lower limit, a fail is reported; when the result is equal to the lower limit, a fail is not reported. If math is enabled (:CALC:MATH:STATe ON), the limit value specified should take into account that the limit testing is on measurements that have been scaled and offset.
  • Page 175: Calculate2:Limit:pcount[:Total]

    Commands Reference :CALCulate2 Subsystem :CALCulate2:LIMit:PCOunt[:TOTal]? Queries the total Pass COunt (that is, the number of measurements that passed the limit test). • Numerical data transferred as ASCII bytes in <NR1> format. Query Response • If CALC2:LIM:STATe is OFF, 0 is return ed and error -221 is generated. •...
  • Page 176: Calculate2:Limit:upper[:Data]

    Commands Reference :CALCulate2 Subsystem :CALCulate2:LIMit:UPPer[:DATA] <numeric_value> [HZ | S] Sets or queries the upper limit used for limit testing. When the result is greater than the upper limit, a fail is reported; when the result is equal to the upper limit, a fail is not reported. If math is enabled (:CALC:MATH:STATe ON), the limit value specified should take into account that the limit testing is on measurements that have been scaled and offset.
  • Page 177 Commands Reference :CALCulate3 Subsystem :CALCulate3 Subsystem This subsystem performs post-acquisition statistics computation and data transfer. Not until :CALCulate3:LFILter:STATe is set to ON will any of the NOTE :CALCulate3:LFILter settings be used. Not until :CALCulate3:AVERage[:STATe] is set to ON will any of the :CALCulate3:AVERage settings be used.
  • Page 178 Commands Reference :CALCulate3 Subsystem • If the current measurement is Voltage Peaks, Not a Number 9.91E37 is returned and error -221 is generated. • Query only. Comments • The last calculated result remains valid until a new computation is made or a relevant instrument state is modified.
  • Page 179 Commands Reference :CALCulate3 Subsystem Related Stats Front-Panel keys :CALCulate3:AVERage:COUNt:CURRent? Queries the current count (that is, the number of data values collected for statistical computation). • Numeric data transferred as ASCII bytes in <NR1> format. Query Response • Range is 0 to 1,000,000. •...
  • Page 180 Commands Reference :CALCulate3 Subsystem Related Stats Front-Panel keys :CALCulate3:AVERage:TYPE MAXimum | MINimum | SDEViation | SCALar or MEAN Selects which statistical result will appear: • in the :CALC3:DATA? response, and • on the front-panel display when :DISP[:WIND]:TEXT:FEED is set to "CALC3".
  • Page 181 Commands Reference :CALCulate3 Subsystem • If the current measurement is Voltage Peaks, Not a Number 9.91E37 is returned and error -221 is generated. • Query only. Comments • The last calculated result remains valid until a new computation is made or a relevant instrument state is modified.
  • Page 182 Commands Reference :CALCulate3 Subsystem • *RST: 0.0000000000 Comments • This command couples :CALC2:LIM:LOW to the same value. • Updating the lower limit value causes the limit counts (:CALC2:LIM:FCO, :CALC2:LIM:PCO) to be cleared. • The front panel menu item is not always able to display all of the significant digits of this value.
  • Page 183 Commands Reference :CALCulate3 Subsystem <numeric_value> -9.9999990000E+12 to -1.0000000000E-13, 0.0000000000, +1.0000000000E-13 Range to +9.9999990000E+12. <numeric_value> 11 digits Resolution Query Response Numeric data transferred as ASCII bytes in <NR3> format with eleven significant digits. • *RST: 0.0000000000 Comments • This command couples :CALC2:LIM:UPP to the same value. •...
  • Page 184 Commands Reference :CALibration Subsystem :CALibration Subsystem :CALibration[:ALL]? This query causes an internal interpolator self-calibration . • Numeric data transferred as ASCII bytes in <NR1> format. Query Response • A value of zero indicates the calibration completed without error. A value of one indicates the calibration completed with error.
  • Page 185 Commands Reference :CALibration Subsystem Scale & Offset / POWER (Calibration Menu) Related Front-Panel :CALibration:DATA <arbitrary block> Sets or queries the calibration data (input gain, input offset, and reference oscillator). Before performing calibration, it is a good idea to query (:CAL:DATA?) and store the current calibration values in your program or on a disk in case an error occurs during the calibration process.
  • Page 186 Commands Reference :CALibration Subsystem :CALibration:SECurity Subtree This subtree provides capabilities related to the security of the Counter's calibration factors. :CALibration:SECurity:CODE <NRf> Sets the calibration security code . To change the security code , the Counter must first be unsecured. To unsecure the Counter, use the :CALibration:SECurity:STATe command.
  • Page 187 Commands Reference :CALibration Subsystem • The calibration state is stored in non-volatile memory, and is unaffected by Comments power-on, save/recall, and *RST. • The security code is set to 53181 (the model number of the instrument) when the Counter is shipped from the factory. If you forget your security code, you can reset the security code to the model-number default by resetting all of the non-volatile memory to a default state.
  • Page 188 Commands Reference :CONFigure Subsystem :CONFigure Subsystem Refer to the Measurement Instructions section in this chapter for a description of :CONFigure. 4-30...
  • Page 189 Commands Reference Device Clear Device Clear The full capability of the Device Clear IEEE 488.1 interface function is implemented in the Counter. This function allows a device to be initialized to a cleared state. The device-dependent effect is described below. In response to either the Device Clear message or the Selected Device Clear message, the Counter: •...
  • Page 190 Commands Reference :DIAGnostic Subsystem :DIAGnostic Subsystem This subsystem controls the remote calibration of the Counter. All of the calibration values, with the exception of the interpolator values, are stored in non-volatile memory and are unaffected by power-on, save/recall, and *RST. Any of the commands which perform a calibration, with the exception of the interpolator calibration, will generate error -221 if the user tries to execute a calibration while the Counter is secured.
  • Page 191 Commands Reference :DIAGnostic Subsystem :DIAGnostic:CALibration:INPut[1]:OFFSet:AUTO ONCE | OFF Calibrates the channel 1 input trigger OFFSet when the ONCE parameter is used. Before sending this command, BE SURE to disconnect any input signal from channel 1. Query Response A sequence of ASCII-encoded bytes: OFF •...
  • Page 192 Commands Reference :DIAGnostic Subsystem Before sending this command, connect 10 MHz to channel 1. Query Response A sequence of ASCII-encoded bytes: OFF • This command is available only if the ins trument contains the medium or high Comments stability oscillator option; otherwise, error -241 is generated. •...
  • Page 193 Commands Reference :DIAGnostic Subsystem :DIAGnostic:MEASure:RESolution? Queries the resolution of the current measurement . For most measurements, the resolution of the result produced is defined by a single equation published in the instrument specifications. For Frequency and Period measurements, the specification calls out two formulas for resolution, and explains the conditions in which each applies.
  • Page 194 Commands Reference :DISPlay Subsystem :DISPlay Subsystem This subsystem controls the selection and presentation of textual information on the Counter's display. This information includes measurement results. :DISPlay is independent of, and does not modify, how data is returned to the controller. See the section titled “How to Program the Counter to Display Results”...
  • Page 195 Commands Reference :DISPlay Subsystem :DISPlay[:WINDow]:TEXT:FEED "[:]CALCulate2" | "[:]CALCulate3" Sets or queries what data flow is fed into the display. Choose from the following <data_handle> strings: • "[:]CALCulate2"— should be used to direct any result other than the statistics to the result display Specifically this would select one of the following results for the result display: –...
  • Page 196 The remaining most significant display digits are displayed, while the "masked" digits are represented by an underscore ( __ ). This setting affects how measurement results are displayed; HP-IB query results are unaffected by this setting.
  • Page 197 Commands Reference :DISPlay Subsystem Sets or queries the character used to separate integral and fractional portions of a displayed number. To conform to the numerical convention used in the USA, specify decimal point with DPOint. To conform to the numerical convention used in many other countries, specify COMMa.
  • Page 198 Commands Reference :FETCh Subsystem :FETCh Subsystem Refer to the Measurement Instructions section in this chapter for a description of :FETCh. 4-40...
  • Page 199 Commands Reference :FORMat Subsystem :FORMat Subsystem This subsystem sets the data format for transferring numeric information. This data format is used for response data by those commands that are specifically designated to be affected by the :FORMat subsystem. :FORMat[:DATA] ASCii | REAL Sets or queries the data format type.
  • Page 200 Commands Reference Group Execute Trigger (GET) Group Execute Trigger (GET) The full capability of the Group Execute Trigger IEEE 488.1 interface function is implemented in the Counter. This function permits the Counter to have its operation initiated over the Bus. The device-dependent result of this triggering is described in the following paragraph.
  • Page 201 Commands Reference :HCOPy Subsystem :HCOPy Subsystem :HCOPy:CONTinuous <Boolean> Enables or disables printing results. When :HCOPy:CONTinuous is enabled (:HCOP:CONT ON), the Counter prints each measurement. If statistics is enabled (:CALC3:AVER[:STAT] ON), all statistics (standard deviation, mean, minimum, and maximum ) will be printed in addition to the individual measurements.
  • Page 202 Commands Reference :INITiate Subsystem :INITiate Subsystem This subsystem controls the initiation of a measurement. :INITiate:AUTO <Boolean> Sets or queries if the Counter should stop measurements or continue measuring (go on) when a measurement exceeds the user-entered limits. AUTO ON configures the Counter to automatically stop measuring (set :INIT:CONT to OFF) on a limit test failure (that is, out-of-limit results are detected).
  • Page 203 Commands Reference :INITiate Subsystem – reports the negative status condition (NOT Computing Statistics) to bit 8 of Operation Status Register. • When :CALC2:LIM:CLE:AUTO is ON, the Counter performs the following whenever the :INIT:CONT ON command is sent: – invalidates the limit data, –...
  • Page 204 Commands Reference :INITiate Subsystem Related Front-Panel Keys :INITiate[:IMMediate] This event command causes the instrument to initiate either a single measurement or a block of measurements. When :TRIG:COUN:AUTO is OFF, or :CALC3:AVER[:STAT] is OFF, or [:SENS]:FUNC[:ON] is any Voltage Peaks function, then :INIT[:IMM] initiates a single measurement.
  • Page 205 Commands Reference :INITiate Subsystem • When [:SENS]:EVEN:LEV[:ABS]:AUTO is ON and channel 1 is a measurement channel, the Counter performs an auto-trigger on channel 1 whenever the :INIT[:IMM] command is executed. Related Stop/Single Front-Panel Keys 4-47...
  • Page 206 Commands Reference :INPut[1] Subsystem :INPut[1] Subsystem This subsystem controls the characteristics of the Counter's input ports. :INPut1 corresponds to the channel 1 input port. :INPut[1]:ATTenuation 1 | 10 Sets or queries the input attenuation . Query Response Numeric data transferred as ASCII bytes in <NR1> format. Comments *RST: 1 Related...
  • Page 207 Commands Reference :INPut[1] Subsystem :INPut[1]:FILTer[:LPASs]:FREQuency? Queries the cutoff frequency of the low-pass filter. • Numeric data transferred as ASCII bytes in <NR3> format with six significant Query Response digits. • A value of 100E+3 is returned. Comments Units are Hertz. :INPut[1]:IMPedance <numeric_value>...
  • Page 208 Commands Reference :INPut2 Subsystem :INPut2 Subsystem This subsystem queries the characteristics of the Counter's channel 2 input port. These commands are only available if Option 015, Option 030, or Option 050 is installed. :INPut2:COUPling? Queries the channel 2 input coupling . Query Response A sequence of ASCII-encoded bytes: AC Comments...
  • Page 209 Commands Reference :MEASure Subsystem :MEASure Subsystem Refer to the Measurement Instructions section in this chapter for a description of :MEASure. 4-51...
  • Page 210 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) The purpose of these commands is to acquire data using a set of high-level instructions. These commands are structured to allow you to trade off interchangeability with fine control of the measurement process. The :MEASure query provides a complete capability where the instrument is configured, a measurement is taken, and the results are stored in the Output Queue in one operation.
  • Page 211 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) (@1) to specify channel 1, whereas a two-channel function (such as Ratio) would use (@1), (@2) to specify a measurement between Channel 1 and Channel 2. If the instrument receives a parameter which is unexpected, it shall process the command, ignoring the unexpected parameter, and set the “Command Warning”...
  • Page 212 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Queries the function configured by the last :CONFigure or :MEASure query. If the instrument state has changed through commands other than :CONFigure or :MEASure query, the instrument will not track these changes, and the query response will not reflect these changes.
  • Page 213 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) :FETCh[[:SCALar]:<function>]? This query returns the measurement taken by the :INITiate (or :MEASure query or :READ?) commands. When [:SCALar]:<function> is specified, the instrument will retrieve the specified result if it matches the current measurement type or can be derived from the current measurement type.
  • Page 214 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) This query provides a complete measurement sequence: configuration, measurement initiation, and query for result. It is used when the generic measurement is acceptable and fine adjustment of Counter settings is unnecessary. Parameters (other than <source_list>) may be defaulted from the right by omitting them, or anywhere by substituting the keyword DEFault.
  • Page 215 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) allowed to provide fine adjustments to the instrument state by issuing the corresponding commands between the :CONFigure and :READ?. When [:SCALar]:<function> is specified, the instrument will retrieve the specified result if it matches the current measurement type or can be derived from the current measurement type.
  • Page 216 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) • Result will be formatted according to :FORMat[:DATA] ASCii | REAL Query Response setting. • When ASCii format is used, numeric data is transferred as ASCII bytes in <NR3> format. The number of significant digits will range from 1 to 15, depending on the measurement resolution.
  • Page 217 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Descriptions of the Measurement Functions— <function> This sub-section provides a description of each measurement function (that is, [:VOLTage]:FREQuency, [:VOLTage]:FREQuency:RATio, [:VOLTage]:PERiod, etc.) that can be used with either the :MEASure query or :CONFigure command. In each of the following command lines, the MEASure command is used with the measurement function commands.
  • Page 218 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) default: value which indicates 4 digits of resolution for the specified <expected_value> Ch2 <expected_value> range, Option 030: 100 MHz to 3.00 GHz range, Option 015: 100 MHz to 1.50 GHz resolution: <expected_value> should be within 10% of input frequency for optimum arming configuration default: 500 MHz...
  • Page 219 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Descriptions of the Measurement Functions— <function> (Cont.) :MEASure[:SCALar][:VOLTage]:FREQuency:RATio? [<expected_value>[,<resolution>]] [, (@1), (@2) | (@2), (@1) ] Measures Frequency Ratio between two inputs. The measurement arming mode is set to “digits.” The Counter uses the <expected_value>...
  • Page 220 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) resolution: <resolution> should use a mantissa of 1.0 and be an even power of 10 default: value which indicates 4 digits of resolution for the specified <expected_value> <source_list> range: (@1), (@2) | (@2), (@1) default: (@1), (@2) :MEASure[:SCALar][:VOLTage]:MAXimum? [(@1)]...
  • Page 221 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Descriptions of the Measurement Functions— <function> (Cont.) :MEASure[:SCALar][:VOLTage]:PERiod? [<expected_value>[,<resolution>]][, (@1)|(@2)] Measures Period . The measurement arming mode is set to “digits.” The Counter uses the <expected_value> and <resolution> parameters to configure the number of digits of resolution arming setting.
  • Page 222 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Descriptions of the Measurement Functions— <function> (Cont.) :MEASure[:SCALar][:VOLTage]:PERiod? (Continued) Ch2 <expected_value> range, Option 030: 0.33 ns to 10.0 ns range, Option 015: 0.66 ns to 10.0 ns resolution: <expected_value> should be within 10% of input period for optimum arming configuration default: 2 ns...
  • Page 223 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) Descriptions of the Measurement Functions— <function> (Cont.) How to Use the Measurement Instruction Commands The Measure Instruction commands have a different level of compatibility and flexibility than other commands. The parameters used with commands from the Measure Instruction describe the signal you are going to measure.
  • Page 224 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) How to Use the Measurement Instruction Commands (Cont.) Using :CONFigure with :READ? The :CONFigure command causes the instrument to choose default settings for the specified measurement. :READ? starts the measurement and queries the result. This sequence operates in the same way as the :MEASure query, but now it is possible to insert commands between :CONFigure and :READ? to specify a particular setting.
  • Page 225 Commands Reference Measurement Instructions (:CONFigure, :FETCh, :MEASure, :READ) How to Use the Measurement Instruction Commands (Cont.) :SENS:EVEN:LEV 0V to set the trigger level to 0 Volts. :INITIATE to start the measurement. :FETCH? to query for result. 4-67...
  • Page 226 Commands Reference :MEMory Subsystem :MEMory Subsystem This subsystem manages the instrument's memory . The MEMory capabilities of an instrument are not part of the instrument state, and are not affected by reset (*RST) or recall (*RCL). In this instrument, the macro capabilities will not survive a power cycle, but the *SAV/*RCL states will.
  • Page 227 Commands Reference [:SENSe] Subsystem [:SENSe] Subsystem The [:SENSe] subsystem commands are divided into several sections. Each section or subtree deals with controls that directly affect instrument-specific settings and not those related to the signal-oriented characteristics. [:SENSe]:DATA? ["[:]SENSe[1]"] Queries the current measurement result data of the :SENSe subsystem (no scale or offset applied).
  • Page 228 Commands Reference [:SENSe] Subsystem 0, 50, or 100 PCT <numeric_value> Range Query Response Numeric data transferred as ASCII bytes in <NR1> format. Comments *RST: 0 PCT (least noise immunity) Related Trigger/Sensitivity Front-Panel Keys [:SENSe]:EVENt[1]:LEVel[:ABSolute] <numeric_value> [V] Sets or queries the level at the center of the hysteresis window. The actual trigger event is at the top of the hysteresis window (for POSitive slope) or at the bottom of the hysteresis window (for NEGative slope).
  • Page 229 Commands Reference [:SENSe] Subsystem [:SENSe]:EVENt[1]:LEVel[:ABSolute]:AUTO <Boolean> Sets or queries the “auto-trigger ” enable. When AUTO is set to ON, the Counter automatically measures and computes a trigger level which corresponds to the auto-trigger percentage (specified with [:SENS]:EVEN[1]:LEV:REL) of the specified channel. While the enable is set to ON, the Counter will measure and compute the measurement channel trigger level each time :INIT or :INIT:CONT ON is executed.
  • Page 230 Commands Reference [:SENSe] Subsystem • *RST: 50 PCT Comments • Only applies when [:SENS]:EVEN[1]:LEV[:ABS]:AUTO is ON. Related Trigger/Sensitivity Front-Panel Keys [:SENSe]:EVENt[1]:SLOPe POSitive | NEGative Sets or queries which edge of the input signal will be considered an event for Frequency, Period, and Frequency Ratio measurements . With the POSitive slope selected, a signal going from one voltage level to a more positive level, regardless of polarity, will define the event at the upper hysteresis limit.
  • Page 231 Commands Reference [:SENSe] Subsystem [:SENSe]:EVENt2:SLOPe? Queries which edge of channel 2 input port will be considered an event. Query Response A sequence of ASCII-encoded bytes: POS [:SENSe]:FREQuency Subtree This subtree controls the Frequency, Frequency Ratio, and Period measuring capabilities of the instrument. [:SENSe]:FREQuency:ARM Subtree This subtree is used to synchronize the Frequency, Frequency Ratio, and Period start...
  • Page 232 Commands Reference [:SENSe] Subsystem [:SENSe]:FREQuency:ARM[:STARt]:SOURce IMMediate |EXTernal Sets or queries the start arm for Frequency, Frequency Ratio, and Period measurements. Query Response A sequence of ASCII-encoded bytes: IMM or EXT Comments *RST: IMMediate Related Gate & ExtArm Front-Panel Keys [:SENSe]:FREQuency:ARM:STOP:DIGits <numeric_value> Sets or queries the resolution in terms of digits used in arming Frequency, Period, and Ratio measurements.
  • Page 233 Commands Reference [:SENSe] Subsystem [:SENSe]:FREQuency:ARM:STOP:SLOPe POSitive | NEGative Sets or queries the slope of the external stop arm signal used in external arming Frequency, Frequency Ratio, and Period measurements. Query Response A sequence of ASCII-encoded bytes: POS or NEG • *RST: NEGative Comments •...
  • Page 234 Commands Reference [:SENSe] Subsystem • *RST: 100E-3 S Comments • Only applies when [:SENS]:FREQ:ARM:STOP:SOUR TIM is selected. Related Gate & ExtArm Front-Panel Keys [:SENSe]:FREQuency:EXPected[1|2] <numeric_value> [HZ] Sets or queries the approximate frequency of a signal you expect to measure. Providing this value enables the Counter to eliminate a pre-measurement step, saving measurement time and enabling more accurate arming.
  • Page 235 Commands Reference [:SENSe] Subsystem [:SENSe]:FREQuency:EXPected[1|2]:AUTO ON The command, which only allows the ON parameter, configures the Counter to perform, as necessary, a pre-measurement step to automatically determine the approximate frequency of the measurement signal(s). This applies to the following measurement functions: Frequency, Period, and Ratio. The query indicates whether or not the above described pre-measurement step is enabled.
  • Page 236 Commands Reference [:SENSe] Subsystem • The string "<function> <channel>[,<channel>]" is returned. Query Response • The string omits d efault nodes (XNONe) and uses short form mnemonics. If the channel specifier(s) are set to default value(s), no channel specifier is returned in response.
  • Page 237 Commands Reference [:SENSe] Subsystem [:SENSe]:ROSCillator Subtree This subtree controls the Reference Oscillator . [:SENSe]:ROSCillator:EXTernal:CHECk ON | OFF | ONCE Sets or queries the enable for “checking” the validity and presence of the external reference. When CHECk is ON and external has been explicitly selected ([:SENS]:ROSC:SOUR is EXT and [:SENS]:ROSC:SOUR:AUTO is OFF), the Counter checks the external reference signal to ensure that the frequency is 1, 5, or 10 MHz and that the reference is present at measurement completion.
  • Page 238 Commands Reference [:SENSe] Subsystem Query only. Comments [:SENSe]:ROSCillator:SOURce INTernal | EXTernal Sets or queries current reference timebase. INTernal indicates the timebase is the internal reference. EXTernal indicates the signal at the external reference input (located on the rear panel of the Counter; In connector) is the reference timebase.
  • Page 239 Commands Reference [:SENSe] Subsystem • *RST: ON Comments • Explicitly selecting a reference oscillator (with [:SENS]:ROSC:SOUR INT|EXT) sets AUTO to OFF. • This value is unaffected by save/recal l. Related Utility/POWER Front-Panel Keys 4-81...
  • Page 240 Commands Reference :STATus Subsystem :STATus Subsystem The :STATus subsystem commands allow you to specify or examine the status of the Operation Status Register group and the Questionable Data/Signal Register group. :STATus:OPERation Subtree The :STATus:OPERation subtree commands allow you to examine the status of the Counter monitored by the Operation Status Register group, shown in Figure 4-2.
  • Page 241 Commands Reference :STATus Subsystem Comments The Operation Condition Status Register is cleared at power-on. :STATus:OPERation:ENABle <non-decimal numeric> | <NRf> Sets or queries the Operation Event Status Enable Register. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the Operation Event Status Enable Register.
  • Page 242 Commands Reference :STATus Subsystem The Operation Event Status Register is cleared by *CLS, by Comments :STAT:OPER[:EVEN]?, and at power-on. :STATus:OPERation:NTRansition <non-decimal numeric> | <NRf> Sets or queries the negative transition filter for the Operation status reporting structure. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the negative transition filter.
  • Page 243 Commands Reference :STATus Subsystem • At power-on and STAT:PRES, the positive transition filter is preset such that each bit is a 1 (TRUE). • This value is unaffected by *RST and save/recall. :STATus:PRESet This event command presets the enable registers and transition filters associated with the Operation and Questionable status reporting structures.
  • Page 244 Commands Reference :STATus Subsystem :STATus:QUEStionable Subtree The :STATus:QUEStionable subtree commands allow you to examine the status of the Counter monitored by the Questionable Data/Signal Status Register group, shown in Figure 4-3. The Questionable Status group consists of a condition register, two transition registers, an event register, and an enable register.
  • Page 245 Commands Reference :STATus Subsystem :STATus:QUEStionable:ENABle <non-decimal numeric> | <NRf> Sets or queries the Questionable Data Event Status Enable Register. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the Questionable Data Event Status Enable Register.
  • Page 246 Commands Reference :STATus Subsystem Sets or the negative transition filter for the Questionable Data status reporting structure. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the negative transition filter.
  • Page 247 Commands Reference :STATus Subsystem Query Response Numeric data transferred as ASCII bytes in <NR1> format. • At power-on and :STAT:PRES, the positive transition filter is preset such that Comments each bit is a 1 (TRUE). • This value is unaffected by *RST and save/recall. 4-89...
  • Page 248 Commands Reference :SYSTem Subsystem :SYSTem Subsystem This subsystem collects together the capabilities that are not related to instrument performance. :SYSTem:COMMunicate Subtree The :SYSTem:COMMunicate subtree collects together the configuration of the control/communication interfaces. The :SYSTem:COMMunicate:SERial subtree controls the physical configuration of the RS-232C port.
  • Page 249 Commands Reference :SYSTem Subsystem A sequence of ASCII-encoded bytes: IBF, ON, or LIM Query Response • This value is stored in non-volatile memory. It is unaffected by power-on, Comments save/recall, and *RST. • The start and stop thresholds are not user configurable. Related Utility/POWER Front-Panel...
  • Page 250 Commands Reference :SYSTem Subsystem :SYSTem:COMMunicate:SERial:TRANsmit:PARity[:TYPE] EVEN | ODD | NONE Sets or queries the parity scheme. Query Response A sequence of ASCII-encoded bytes: EVEN, ODD, or NONE • This value is stored in non-volatile memory. It is unaffected by power-on, Comments save/recall, and *RST.
  • Page 251 Commands Reference :SYSTem Subsystem • The queue is cleared (emptied) on *CLS, power-on, or upon reading the last Comments error from queue. • If the Error Queue overflows, the last error in the queue is replaced with the error -350, "Queue overflow". Any time the queue overflows, the least recent errors remain in the queue and the most recent error is discarded.
  • Page 252 Commands Reference :SYSTem Subsystem :SYSTem:KEY <numeric_value> This command simulates the pressing or a front-panel key. The <numeric_value> is a key code value. This command puts an entry in the Key Queue (just as any front-panel key press does). The length of the Key Queue is 500. The keys and their corresponding key codes are listed in the following table.
  • Page 253 Commands Reference :SYSTem Subsystem • At*RST and power-on, the Key Queue is cleared (emptied). Comments • The Key Queue is unaffected by save/recall. • Key commands are squential, but only in terms of processing other key commands or getting into the Key Queue. The operation performed by the key command is not guaranteed to be complete before processing of the next non- key command.
  • Page 254 Commands Reference :TRACe Subsystem :TRACe Subsystem This subsystem provides access to the scale and offset values. The :TRACe subsystem used in conjunction with the :CALCulate[1] subsystem, scales and offsets measurement results. :TRACe:CATalog? Queries list of intrinsic constants. The Counter has two constants, scale and offset. Query Response A comma-separated list of strings: "SCALE", "OFFSET"...
  • Page 255 Commands Reference :TRACe Subsystem Scale & Offset Related Front-Panel Keys :TRACe[:DATA] SCALE, <numeric_value> :TRACe[:DATA] SCALE, <arbitrary block> :TRACe[:DATA]? SCALE Sets or queries the scale value. <numeric_value> -9.999999E+12 to -1.000000E-13, 0.000000, +1.000000E-13 to +9.999999E+12. Range <numeric_value> 7 digits Resolution • Response will be formatted according to :FORMat[:DATA] ASCii | REAL Query Response setting.
  • Page 256 Commands Reference :TRIGger Subsystem :TRIGger Subsystem This subsystem enables synchronization of instrument actions with specified internal or external events. :TRIGger:COUNt:AUTO <Boolean> Sets or queries the control over the number of measurements made when :INITiate[:IMMediate] is performed. When :TRIG:COUN:AUTO is OFF, then :INIT[:IMM] initiates a single measurement.
  • Page 257 Commands Reference *CAL? (Calibration Query) *CAL? (Calibration Query) This query causes an internal interpolator self-calibration. • Numeric data transferred as ASCII bytes in <NR1> format. Query Response • A value of zero indicates the calibration completed without error. A value of one indicates the calibration completed with error.
  • Page 258 Commands Reference *CLS (Clear Status Command) *CLS (Clear Status Command) Clears all event registers summarized in the status byte (Standard Event Status Register, Operation Event Status Register, and Questionable Data Event Status Register) and clears the Error Queue. The *CLS command will not clear data memories or any other settings.
  • Page 259 Commands Reference *DDT <arbitrary block> (Define Device Trigger Command) *DDT <arbitrary block> (Define Device Trigger Command) Sets or queries the command that the device will execute when it receives the IEEE 488.1 Group Execute Trigger (GET) interface message (page 4- 42) or a *TRG common command.
  • Page 260 Commands Reference *DMC <string>, <arbitrary block> (Define Macro Command) *DMC <string>, <arbitrary block> (Define Macro Command) This command assigns a sequence of zero or more commands/queries to a macro label. The sequence is executed when the label is received as a command or query. The <string>...
  • Page 261 Commands Reference *EMC <NRf> (Enable Macro Command) *EMC <NRf> (Enable Macro Command) *EMC? (Enable Macro Query) Sets or queries the Enable for defined MaCros . Macro definitions are not affected by this command. One use of this command is to turn off macro expansion in order to execute an instrument-specific command with the same name as a macro.
  • Page 262 Commands Reference *ESE <NRf> (Standard Event Status Enable Command) *ESE <NRf> (Standard Event Status Enable Command) *ESE? (Standard Event Status Enable Query) Sets or queries the Standard Event Status Enable Register, shown in Figure 4-4. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the Standard Event Status Enable Register.
  • Page 263 Commands Reference *ESE? (Standard Event Status Enable Query) • This value is unaffected by *RST and save/recall. 4-105...
  • Page 264 Commands Reference *ESR? (Event Status Register Query) *ESR? (Event Status Register Query) Queries the Standard Event Status Register, shown in Figure 4-5. This event register captures changes in conditions, by having each event bit correspond to a specific condition in the instrument. An event becomes TRUE when the associated condition makes the defined transition.
  • Page 265 Commands Reference *GMC? <string> (Get Macro Contents Query) *GMC? <string> (Get Macro Contents Query) Queries the current definition of a macro. The <string> parameter must be a currently defined macro label. • Definite length block. Query Response • The query response is a <definite length block> containing the command/query sequence which is executed when the macro label is received.
  • Page 266 (Identification Query) Queries the Counter identification. Query Response A sequence of ASCII-encoded bytes: HEWLETT-PACKARD, 53181A,0,XXXX terminated with a new line and EOI. XXXX represents the firmware date code . Comments This query should be the last query in a terminated program message; otherwise, error -440 is generated.
  • Page 267 Commands Reference *LMC? (Learn Macro Query) *LMC? (Learn Macro Query) Queries the currently defined macro labels. • A sequence of one or more strings separated by commas. Query Response • If no macros are defined, the response is a null string (two consecutive double quote marks).
  • Page 268 Commands Reference *OPC (Operation Complete Command) *OPC (Operation Complete Command) This event command enables the OPC bit (bit 0) in the Standard Event Status Register to be set upon the transition of the measurement cycle from measuring to idle. See the section titled “Standard Event Status Register Group,” page 3-25, in Chapter 3 of this guide for a detailed description of the Standard Event Status Register's Operation Complete bit.
  • Page 269 Commands Reference *OPC? (Operation Complete Query) *OPC? (Operation Complete Query) This query produces a response upon the transition of the measurement cycle from measuring to idle. This allows synchronization between a controller and the instrument using the MAV bit in the Status Byte Register or a read of the Output Queue.
  • Page 270 Commands Reference *OPT? (Option Identification Query) *OPT? (Option Identification Query) Queries the instrument to identify any installed options. The following options can be installed in the instrument: • Option 001, Medium Stability Oven Timebase • Option 010, High Stability Oven Timebase •...
  • Page 271 Commands Reference *PMC (Purge Macro Command) *PMC (Purge Macro Command) The Purge MaCros command deletes all macros previously defined using the *DMC command. 4-113...
  • Page 272 Commands Reference *RCL <NRf> (Recall Command) *RCL <NRf> (Recall Command) This command restores the state of the instrument from a copy stored in local non- volatile memory. Before the recall occurs the current state of the instrument is automatically saved to register 0. <NRf>...
  • Page 273 Commands Reference *RCL <NRf> (Recall Command) :SYSTem:COMMunicate:SERial:TRANsmit:BAUD :SYSTem:COMMunicate:SERial:TRANsmit:P ACE :SYSTem:COMMunicate:SERial:TRANsmit:PARity[:TYPE] :SYSTem:ERRor? (error queue) :SYSTem:KEY? (key queue) :SYSTem:KEY:LOG? (key queue) HP-IB Address 4-115...
  • Page 274 Commands Reference *RST (Reset Command) *RST (Reset Command) This event command performs an instrument reset . The reset performs the following: • sets instrument settings to their *RST states, • disables macros, • places instrument in “Operation Complete Idle State” and “Operation Complete Query Idle State,”...
  • Page 275 Commands Reference *SAV <NRf> (Save Command) *SAV <NRf> (Save Command) This command stores the current state of the instrument in local non-volatile memory . The current instrument state is saved in register 0 when *RCL or front-panel recall is executed. <NRf>...
  • Page 276 Commands Reference *SAV <NRf> (Save Command) :SYSTem:COMMunicate:SERial:CONTrol:DTR :SYSTem:COMMunicate:SERial:TRANsmit:BAUD :SYSTem:COMMunicate:SERial:TRANsmit:PACE :SYSTem:COMMunicate:SERial:TRANsmit:PARity[:TYPE] HP-IB Address Error Queue Key Queue 4-118...
  • Page 277 Commands Reference *SRE <NRf> (Service Request Enable Command) *SRE <NRf> (Service Request Enable Command) *SRE? (Service Request Enable Query) Sets or queries the Service Request Enable Register , shown in Figure 4-6. The parameter and query response value, when rounded to an integer value and expressed in base 2 (binary), represents the bit values of the Service Request Enable Register.
  • Page 278 Commands Reference *STB? (Status Byte Query) *STB? (Status Byte Query) Queries the Status Byte Register , shown in Figure 4-7. This register is cleared at power-on. This query does not directly alter the Status Byte Register (including the MSS/RQS bit) or anything related to the generation of SRQ. Figure 4-7.
  • Page 279 Commands Reference *TRG (Trigger Command) *TRG (Trigger Command) This command is the device-specific analog of the IEEE 488.1 Group Execute Trigger (GET) interface message (page 4- 42), and has exactly the same effect. The *TRG command will perform the action defined by the *DDT command (page 4-101).
  • Page 280 Commands Reference *TST? (Self-Test Query) *TST? (Self-Test Query) This query causes an internal self-test and the response indicates whether any errors were detected. Error -330 is generated when the self-test fails. • Numeric data transferred as ACSII bytes in <NR1> format. Query Response •...
  • Page 281 Commands Reference *WAI (Wait-to-Continue Command) *WAI (Wait-to-Continue Command) This command prevents the instrument from executing any further commands or queries until the measurement cycle transitions from measuring to idle. The only way to cancel this “holdoff” is by device clear or power-on. (*RST and *CLS have no affect on *WAI operation.) See the section titled “Using the *WAI Command,”...
  • Page 282 Commands Reference *WAI (Wait-to-Continue Command) 4-124...
  • Page 283 Errors...
  • Page 284 Displaying Errors When an HP-IB error is detected, the HP-IB XXX message will appear on the front- panel display, where XXX indicates the error number found in Table 5-2. If an error occurs while the Counter is in remote, the front-panel Remote indicator flashes until the error queue is read or cleared.
  • Page 285 Errors Error Queue 10 ASSIGN @Cntr TO 703 20 !Assign path name 30 DIM Err_string$[255] 40 !Creates array for error string 50 REPEAT 60 !Repeats until error queue is empty OUTPUT @Cntr;"SYST:ERR?" !Read error number and string ENTER @Cntr;Err_num,Err_string$ !Enter error number and string PRINT Err_num,Err_string$ !Print error number and string 130 UNTIL Err_num = 0...
  • Page 286 Errors Error Types Error Types Error numbers are categorized by type as shown in Table 5-1. Each and every error is listed in Table 5-2. Table 5-1. Error Types Error Number Error Type No Error − 100 to − 199 Command Errors −...
  • Page 287 Errors Error Types • A Group Execute Trigger (GET) was entered into the input buffer inside of an IEEE 488.2 program message. Events that generate command errors do not generate execution errors, device- specific errors, or query errors. Execution Error An <error number>...
  • Page 288 Errors Error Types Query Error An <error number> in the range [ − 400 to − 499] indicates that the output queue control of the Counter has detected a problem with the message exchange protocol. The occurrence of any error in this class should cause the query error bit (bit 2) in the Event Status Register to be set.
  • Page 289 Errors Error Types Table 5-2. Errors Number Error String Cause No error The error queue is empty. Every error in the queue has been read (:SYSTem:ERRor? query) or the queue was cleared by power-on or *CLS. -100 Command error This is the generic syntax error used if the Counter cannot detect more specific errors.
  • Page 290 Errors Error Types Table 5-2. Errors (Continued) Number Error String Cause -151 Invalid string data A string data element was expected but was invalid for some reason. For example, an END message was received before the terminal quote character. A string data element was encountered but was not allowed by the Counter at -158 String data not allowed this point in parsing.
  • Page 291 Power-on self test detected this hardware failure. Self-test failed; EEPROM failure Power-on self test detected this hardware failure. Self-test failed; HP-IB failure Power-on self test detected this hardware failure. Self-test failed; QSPI failure Power-on self test detected this hardware failure.
  • Page 292 Errors Error Types -420 Query UNTERMINATED Indicates that a condition causing an UNTERMINATED Query error occurred. For example, the Counter was addressed to talk and an incomplete program message was received. -430 Query DEADLOCKED Indicates that a condition causing a DEADLOCKED Query error occurred. For example, both input buffer and output buffer are full and the Counter cannot continue.
  • Page 293 <numeric value>, 3-12 throughput, 3-37 9.91E37, 3-18 common command format, 3-7 syntax, 3-8 abbreviated commands, 3-9 common commands address, HP-IB, 3-4 definition, 2-17 Applications, 1-5 summary list, 2-18 arbitrary block, 3-11 syntax, 2-17 arming, 2-10 Common Commands Summary ASCII, 4-41...
  • Page 294 5-2 using, 4-66 list, 5-7 CONFigure with READ messages, 5-7 using, 4-66 query, 3-27, 4-92, 5-6 configuring the HP-IB, 3-4 queue, 5-3 conformance type, 5-4 IEEE488.1, 3-7 errors list, 5-7 IEEE488.2, 2-16, 2-17, 3-7 ESB, 3-23, 3-24...
  • Page 295 4-42 key queue, 4-94 Group Execute Trigger, GET, 4-42 keyword, 3-10 optional, 3-10 separator, 3-9 How to Use This Guide, 1-3 HP 53131A/132A SCPI Subsystem Commands, 2-20 Learning to Program the HP Basic, using, 3-60 Counter, 1-4 HP-IB level, 4-71...
  • Page 296 Index math, 4-7 enable, 4-10 offset/scale, 4-7 offest, scale, 4-7 OHM, 3-12 offset, 4-10 OPC, 3-26 scale, 4-10 operation complete, 4-110 math/limit operations, 3-51 operation complete status bit, 3-26 MAV, 3-23 operation status register MAXimum, 3-12 group, 3-28, 3-32 maximum, 4-19 optimizing throughput, 3-37 maximum value, 3-11 Optimizing Throughput Results for Different...
  • Page 297 Index program the Counter for math/limit operations, 3-51 radix, 3-18 program the Counter for status reporting, 3- ratio, 4-77 ratio, frequency, 4-61 program the Counter to define reading an error, 5-2 macros, 3-54 REAL, 4-41 program the Counter to display recall, 4-114 results, 3-45 reference oscillator...
  • Page 298 SCPI programs, how to write, 3-57 summary of all registers, 3-20 SDCL, 4-31 stop, 3-10 security code, 4-28 string, 3-11, 3-19 security state, 4-28 HP BASIC, 3-60 selected device clear, 4-31 parameters, 3-60 self-calibration, 4-26 subsystem command self-test, internal, 4-122 syntax, 3-8...
  • Page 299 Index :CALibration:STATus?, 4-34 :SYSTem, 4-90 :MEASure:RESolution?, 4-35 :SYSTem:COMMunicate, 4-90 :CALibration:ROSCillator: :SYSTem:ERRor?, 4-92 AUTO, 4-34 :SYSTem:KEY, 4-94 :DISPlay, 4-36 :SYSTem:KEY:LOG?, 4-95 :DISPlay:[WINDow]:TEXT: :SYSTem:VERSion?, 4-95 FEED, 4-37, 4-38 :TRACe, 4-96 :DISPlay:ENABle, 4-36 :TRACe:CATalog?, 4-96 :DISPlay:MENU[:STATe], 4-36 :TRACe[:DATA] OFFSET, 4-96 :DISPlay[:WINDow]:TEXT: :TRACe[:DATA] SCALE, 4-97 RADix, 4-39 :TRIGger, 4-98 :DISPlay[:WINDow]:TEXT:...
  • Page 300 Turbo C, using, 3-61 Unaffected by *RST, 2-34 units, 3-12 unsecure, 4-28 using internal reference status bit, 3-32, 3-33 using the scale and offset over HP-IB, 3-52 V, 3-12 version, SCPI, 4-95 voltage maximum, 4-77 minimum, 4-77 voltage maximum, 4-62...
  • Page 301 For more information, call your local HP sales office listed in your telephone directory or an HP regional office listed below for the location of your nearest sales office. United States of America: In Europe, Africa and Middle East, please call your local...
  • Page 303 REMEDIES. HP SHALL NOT THE PROTECTIVE from type test. Buyer shall prepay shipping GROUNDING CONDUCTOR BE LIABLE FOR ANY charges to HP and HP shall pay DIRECT, INDIRECT, (INSIDE OR OUTSIDE THE GERAeUSCHEMISSION shipping charges to return the INSTRUMENT) OR SPECIAL, INCIDENTAL, OR product to Buyer.
  • Page 305 Printed in U.S.A. June 1997 Printed on recycled paper Manual Part Number: 53181-90002 RR DONNELLY PREPRINT COVER (BACK)

Table of Contents