Page 3
Logic Analysis System. This guide Programming and focuses on how to program the system Documentation Conventions over the HP-IB interface, but also briefly explains how to use the RS-232-C and Message Communication LAN interfaces. The Logic Analysis and System Functions System cannot be programmed over the 16505 interface.
Page 4
Part 3 Part 3, chapter 15, contains program examples of actual tasks that show you how to get started in programming the HP 16500C/ 16501A Logic Analysis System at the mainframe level. The complexity of your programs and the tasks they accomplish are limited only by your imagination.
Contents Part 1 General Information 1 Introduction to Programming Introduction 1–2 Talking to the Logic Analysis System 1–3 Talking to Individual System Modules 1–4 Initialization 1–4 Instruction Syntax 1–6 Output Command 1–6 Device Address 1–7 Instructions 1–7 Instruction Terminator 1–8 Header Types 1–9 Duplicate Keywords 1–10 Query Usage 1–11...
Page 6
Password Protection and File Protection 4–4 Permission Levels: Control and Data 4–4 Controlling the HP 16500C 4–5 Echoing Commands 4–6 Copying Command Files 4–7 Writing to \system\program from a Program 4–8 Sending Commands to the HP 16500C Socket 4–11 Lockout Command 4–13 Contents–2...
Page 7
Service Request Enable Register 7–4 Bit Definitions 7–4 Key Features 7–6 Serial Poll 7–8 Parallel Poll 7–9 Polling HP-IB Devices 7–11 Configuring Parallel Poll Responses 7–11 Conducting a Parallel Poll 7–12 Disabling Parallel Poll Responses 7–13 HP-IB Commands 7–13 Contents–3...
Page 11
Contents Part 3 Programming Examples 15 Programming Examples Transferring the Mainframe Configuration 15–3 Checking for Intermodule Measurement Completion 15–6 Sending Queries to the Logic Analysis System 15–7 Getting ASCII Data with PRINt? ALL Query 15–9 Reading the disk with the CATalog? ALL query 15–10 Reading the Disk with the CATalog? Query 15–11 Printing to the disk 15–12 Index...
Page 13
Part 1 1 Introduction to Programming 1-1 2 Programming Over HP-IB 2-1 3 Programming Over RS-232-C 3-1 4 Programming Over LAN 4-1 5 Programming and Documentation Conventions 5-1 6 Message Communication and System Functions 6-1 7 Status Reporting 7-1 8 Error Messages 8-1...
The programming instructions explained in this book conform to IEEE Std 488.2-1987, "IEEE Standard Codes, Formats, Protocols, and Common Commands." These programming instructions provide a means of remotely controlling the HP 16500C Logic Analysis System. There are three general categories of use. You can: •...
"host" language available on your controller. The host language’s input statements are used to read in responses from the system. For example, HP 9000 Series 300 BASIC uses the OUTPUT statement for sending commands and queries to the system.
Talking to Individual System Modules Talking to Individual System Modules Talking to individual system modules within the HP 16500C Logic Analysis System is done by preceding the module commands with the SELECT command and the number of the slot in which the desired module is installed.
Page 19
This BASIC statement would load the configuration file "DEFAULT " (if it exists) into the system. OUTPUT XXX;":MMEMORY:LOAD:CONFIG ’DEFAULT ’" Example This program demonstrates a simple HP BASIC command structure used to program the Logic Analysis System. 10 CLEAR XXX !Initialize instrument interface 20 OUTPUT XXX;":SYSTEM:HEADER ON"...
Output Command The output command depends on the language you choose to use. Throughout this guide, HP 9000 Series 300 BASIC 6.2 is used in the programming examples, except where noted. If you use another language, you will need to find the equivalents of BASIC Commands, like OUTPUT, ENTER and CLEAR in order to convert the examples.
OUTPUT. The examples in this manual use a generic address of XXX. When writing programs, the number you use will depend on the protocol you use, in addition to the actual address. If you are using HP-IB, see chapter 2, "Programming Over HP-IB." If you are using RS-232-C, see chapter 3, "Programming Over RS-232-C."...
Introduction to Programming Instruction Terminator When you look up a query in this programmer’s reference, you’ll find a paragraph labeled "Returned Format" under the one labeled "Query." The syntax definition by "Returned Format" will always show the instruction header in square brackets, like [:SYSTem:MENU], which means the text between the brackets is optional.
Introduction to Programming Header Types Header Types There are three types of headers: simple command, compound command, and common command. Simple Command Header Simple command headers contain a single keyword. START and STOP are examples of simple command headers. The syntax is: <function><terminator>...
Introduction to Programming Duplicate Keywords Common Command Header Common command headers control IEEE 488.2 functions within the logic analyzer such as clear status. The syntax is: *<command header><terminator> No white space or separator is allowed between the asterisk and the command header.
Introduction to Programming Query Usage Query Usage Logic analysis system instructions that are immediately followed by a question mark (?) are queries. After receiving a query, the Logic Analysis System parser places the response in the output buffer. The output message remains in the buffer until it is read or until another instruction is issued.
Introduction to Programming Program Header Options Program Header Options Program headers can be sent using any combination of uppercase or lowercase ASCII characters. System responses, however, are always returned in uppercase. Both program command and query headers may be sent in either long form (complete spelling), short form (abbreviated spelling), or any combination of long form and short form.
Introduction to Programming Parameter Data Types Parameter Data Types There are three main types of data which are used in parameters. The types are numeric, string, and keyword. A fourth type, block data, is used only for a few instructions: the DATA and SETup instructions in the SYSTem subsystem (see chapter 11);...
Page 28
Introduction to Programming Parameter Data Types You may not specify a base in conjunction with either exponents or unit suffixes. Additionally, negative numbers must be expressed in decimal. When a syntax definition specifies that a number is an integer, that means that the number should be whole.
Introduction to Programming Selecting Multiple Subsystems Selecting Multiple Subsystems You can send multiple program commands and program queries for different subsystems within the same selected module on the same line by separating each command with a semicolon. The colon following the semicolon enables you to enter a new subsystem.
Receiving Information from the Logic Analysis System After receiving a query (logic analysis system instruction followed by a question mark), the system interrogates the requested function and places the answer in its output queue. The answer remains in the output queue until it is read or until another command is issued. When read, the message is transmitted across the bus to the designated listener (typically a controller).
Introduction to Programming Response Header Options Response Header Options The format of the returned ASCII string depends on the current settings of the SYSTEM HEADER and LONGFORM commands. The general format is <instruction_header><space><data><terminator> The header identifies the data that follows (the parameters) and is controlled by issuing a :SYSTEM:HEADER ON/OFF command.
Introduction to Programming Response Data Formats Response Data Formats Both numbers and strings are returned as a series of ASCII characters, as described in the following sections. Keywords in the data are returned in the same format as the header, as specified by the LONGform command. Like the headers, the keywords will always be in uppercase.
String Variables String Variables Because there are so many ways to code numbers, the HP 16500C Logic Analysis System handles almost all data as ASCII strings. Depending on your host language, you may be able to use other types when reading in responses.
Introduction to Programming Numeric Base Example The following example shows logic analyzer module data being returned to a string variable with headers off: 10 OUTPUT XXX;":SYSTEM:HEADER OFF" 20 DIM Rang$[30] 30 OUTPUT XXX;":SELECT 2:MACHINE1:TWAVEFORM:RANGE?" 40 ENTER XXX;Rang$ 50 PRINT Rang$ 60 END After running this program, the controller displays: +1.00000E-05 Numeric Base...
Introduction to Programming Definite-Length Block Response Data Example The following example shows logic analyzer module data being returned to a numeric variable. 10 OUTPUT XXX;":SYSTEM:HEADER OFF" 20 OUTPUT XXX;":SELECT 2:MACHINE1:TWAVEFORM:RANGE?" 30 ENTER XXX;Rang 40 PRINT Rang 50 END This time the format of the number (whether or not exponential notation is used) is dependent upon your host language.
Introduction to Programming Multiple Queries For example, for transmitting 80 bytes of data, the syntax would be: Figure 1-2 Definite-length Block Response Data The "8" states the number of digits that follow, and "00000080" states the number of bytes to be transmitted, which is 80. Multiple Queries You can send multiple queries to the system within a single program message, but you must also read them back within a single program message.
Otherwise the headers may cause misinterpretation of returned data. Example The following program message in HP BASIC is used to read the query :SYSTEM:HEADERS?;LONGFORM? into multiple numeric variables: ENTER XXX; Result1, Result2...
Page 40
Introduction This section describes the interface functions and some general concepts of HP-IB. In general, these functions are defined by IEEE 488.1 (HP-IB standard). They deal with general bus management issues, as well as messages which can be sent over the bus as bus commands.
Programming Over HP-IB Interface Capabilities Interface Capabilities The interface capabilities of the HP 16500C, as defined by IEEE 488.1 are SH1, AH1, T5, TE0, L3, LE0, SR1, RL1, PP0, DC1, DT1, C0, and E2. Command and Data Concepts The HP-IB has two modes of operation: command mode and data mode. The bus is in command mode when the ATN line is true.
The default is always "7" for HP-IB controllers. Instrument Address (Selects the Instrument) Each instrument on the HP-IB port must have a unique instrument address between decimals 0 and 30. The device address passed with the program message must include not only the correct instrument address, but also the correct interface select code.
Programming Over HP-IB Bus Commands Bus Commands The following commands are IEEE 488.1 bus commands (ATN true). IEEE 488.2 defines many of the actions which are taken when these commands are received by the system. Device Clear The device clear (DCL) or selected device clear (SDC) commands clear the input and output buffers, reset the parser, clear any pending commands, and clear the Request-OPC flag.
Page 46
Introduction This chapter describes the interface functions and some general concepts of RS-232-C. The RS-232-C interface on this instrument is Hewlett-Packard’s implementation of EIA Recommended Standard RS-232-C, Interface Between Data Terminal Equipment and Data Communications Equipment Employing Serial Binary Data Interchange.
Programming Over RS-232-C Interface Operation Interface Operation The HP 16500C Logic Analysis System can be programmed by a controller over RS-232-C using either a minimum three-wire or extended hardwire interface. The operation and exact connections for these interfaces are described in more detail in the following sections. When you are controlling...
Programming Over RS-232-C Minimum Three-Wire Interface with Software Protocol Minimum Three-Wire Interface with Software Protocol With a three-wire interface, the software (as compared to interface hardware) controls the data flow between the Logic Analysis System and the controller. Because the three-wire interface provides no hardware means to control data flow between the controller and the Logic Analysis System, only XON/OFF can control this data flow.
Programming Over RS-232-C Extended Interface with Hardware Handshake Extended Interface with Hardware Handshake With the extended interface, both the software and the hardware can control the data flow between the Logic Analysis System and the controller. The Logic Analysis System uses the following connections on its RS-232-C interface for extended interface communication: •...
Cable Examples HP 9000 Series 300 Figure 3-1 is an example of how to connect the HP 16500C Logic Analysis System to the HP 98628A Interface card of an HP 9000 series 300 controller. For more information on cabling, refer to the reference manual for your specific controller.
Figure 3-2 shows the schematic of a 9-pin female to 25-pin male cable. The following HP cables support this configuration: • HP 24542G, DB-9(F) to DB-25(M), 3 meter • HP 24542H, DB-9(F) to DB-25(M), 3 meter, shielded • HP 45911-60009, DB-9(F) to DB-25(M), 1.5 meter Figure 3-2 9-pin (F) to 25-pin (M) Cable...
Data bits are the number of bits sent and received per character that represent the binary code of that character. Characters consist of either 7 or 8 bits, depending on the application. The HP 16500C Logic Analysis System supports 8-bit only.
Programming Over RS-232-C RS-232-C Bus Addressing The controller and the HP 16500C Logic Analysis System must be in the same bit mode to properly communicate over the RS-232-C. This means that the controller must have the capability to send and receive 8-bit data.
Programming Over RS-232-C Lockout Command Lockout Command To lockout the front-panel controls, use the SYSTem command LOCKout. When this function is on, all controls (except the power switch) are entirely locked out. Local control can only be restored by sending the :LOCKout OFF command.
Page 56
LAN. There are no commands needed for controlling the connection, and no special cabling issues. This chapter assumes you have already set up your LAN, and concentrates on how to control the HP 16500C from a host computer. 4–2...
The HP 16500C must be turned on and completely booted up before you can mount the system to your network. Once power is applied to the system and the System Configuration menu is displayed, allow an additional 15 seconds before attempting to connect to the system.
If these files are deleted, the HP 16500C will not operate the next time it is rebooted. If you do delete any of these files, copy them from the flexible disks labeled "16500 Operating System"...
Sockets If you are programming in C or another language that supports sockets, you can write strings directly to the HP 16500C system. Socket connections are automatically control users, so if someone else is already connected to the logic analysis system as control user you will not be able to connect. You can also directly connect to the parser socket using telnet, and send commands interactively.
HP 16500C system, echo a text string containing the command to the file location \system\program In order to send commands to the HP 16500C system parser, you must be connected to the system as the control user. Example To run the logic analyzer and acquire data, at the DOS prompt enter: c:>echo :START >...
Copying Command Files To control the HP 16500C system with longer sets of commands, you can first type the commands into an ASCII file. You then copy the file to the HP 16500 program file, at location . Files copied to this file location \system\program are passed on to the HP 16500C system’s command parser.
Your operating system may buffer the commands before sending them to the HP 16500C system. To prevent this, you may need to empty the buffer after each command. In C, you can use the command to empty the buffer.
Page 63
Writing to \system\program from a Program Example The following example in C opens the file and sends \system\program several commands and queries. Responses to queries appear as text strings . The HP 16500C has been NFS-mounted in the \system\program \users directory. #include <stdio.h> #include <unistd.h>...
Page 64
Programming Over LAN Writing to \system\program from a Program /*Send command strings to the HP16500*/ file = fopen("/users/system/program", "w"); putstr(file, "*rst\n"); putstr(file, ":sel 4\n"); putstr(file, ":mach1:twav:range 1 s\n"); putstr(file, ":start\n"); putstr(file, ":mach1:twav:range 100 ns\n"); fclose(file); sleep(2); file = fopen("/users/system/program", "r"); while (getstr(file, receive_str) == 0);...
The HP 16500C system socket port identification number is 5025. You can also connect directly to the parser socket and type commands directly to the HP 16500. The second example uses telnet to connect to the parser socket. Example The following C program opens a socket and sends a query to request the instrument’s identity.
Page 66
( "%s\n", receiveBuffer ); close ( sockfd ); Example This example uses telnet to connect directly to the HP 16500 parser socket. To remotely interact with the logic analyzer, enter: telnet [symbolic name or IP address] 5025 You must specify the HP 16500 parser socket address 5025. You can now type commands directly to the HP 16500 system.
Programming Over LAN Lockout Command Lockout Command To lockout the front-panel controls, use the SYSTem command LOCKout. When this function is on, all controls (except the power switch) are entirely locked out. Local control can only be restored by sending the :LOCKout OFF command.
Page 70
Introduction This chapter covers the programming conventions used in programming the instrument, as well as the documentation conventions used in this manual. This chapter also contains a detailed description of the command tree and command tree traversal. 5–2...
Programming and Documentation Conventions Truncation Rule Truncation Rule The truncation rule for the keywords used in headers and parameters is: • If the long form has four or fewer characters, there is no change in the short form. When the long form has more than four characters the short form is just the first four characters, unless the fourth character is a vowel.
The first is when the query is parsed by the instrument and the second is when the controller addresses the instrument to talk so that it may read the response. The HP 16500C Logic Analysis System will buffer responses to a query when it is parsed.
Programming and Documentation Conventions Notation Conventions and Definitions on the entry line. Any combination of commands and arguments that can be generated by following the lines in the proper direction is syntactically correct. An argument is optional if there is a path around it. When there is a rectangle which contains the word "space,"...
The Command Tree The Command Tree The command tree (figure 5-1) shows all commands in the HP 16500C Logic Analysis System and the relationship of the commands to each other. You should notice that the common commands are not actually connected to the other commands in the command tree.
Page 75
Programming and Documentation Conventions The Command Tree Figure 5-1 HP 16500C Command Tree 5–7...
MMEMORY and INITIALIZE is the location of the parser when this compound header is parsed. The following examples are written using HP BASIC 6.2 on a HP 9000 Series 300 Controller. The quoted string is placed on the bus, followed by a carriage return and linefeed (CRLF).
Page 77
Programming and Documentation Conventions Tree Traversal Rules Example In the first line of this example, the subsystem selector is implied for the STORE command in the compound command. The STORE command must be in the same program message as the INITIALIZE command, since the <program message terminator>...
Command Set Organization Command Set Organization The command set for the HP 16500C Logic Analysis System mainframe is divided into 6 separate groups as shown in figure 5-1. The command groups are: common commands, mainframe commands, and 4 sets of subsystem commands.
Page 79
Programming and Documentation Conventions Subsystems Table 5-1 Alphabetic Command Cross-Reference Command Subsystem Command Subsystem Command Subsystem *CLS Common DATA SYSTem PORTEDGE INTermodule *ESE Common DELete INTermodule PORTLEV INTermodule *ESR Common DOWNload MMEMory PRINt SYSTem *IDN Common DRIVe TGTctrl PULSe TGTctrl *IST Common SYSTem...
Program Examples The program examples in chapter 15, "Programming Examples," were written on an HP 9000 Series 300 controller using the HP BASIC 6.2 language. The programs always assume a generic address for the HP 16500C Logic Analysis System of 707. The shorter examples given in the reference sections use a generic address of XXX.
Page 82
IEEE 488.2 Standard in ANSI/IEEE Std 488.2-1987, IEEE Standard Codes, Formats, Protocols, and Common Commands. The HP 16500C Logic Analysis System is designed to be compatible with other Hewlett-Packard IEEE 488.2 compatible instruments. Instruments that are compatible with IEEE 488.2 must also be compatible with IEEE 488.1 (HP-IB bus standard);...
Page 83
Message Communication and System Functions Protocols Protocols The protocols of IEEE 488.2 define the overall scheme used by the controller and the instrument to communicate. This includes defining when it is appropriate for devices to talk or listen, and what happens when the protocol is not followed.
Message Communication and System Functions Protocols Protocol Overview The instrument and controller communicate using program messages and response messages. These messages serve as the containers into which sets of program commands or instrument responses are placed. Program messages are sent by the controller to the instrument, and response messages are sent from the instrument to the controller in response to a query message.
Message Communication and System Functions Syntax Diagrams Protocol Exceptions If an error occurs during the information exchange, the exchange may not be completed in a normal manner. Some of the protocol exceptions are shown below. Command Error A command error will be reported if the instrument detects a syntax error or an unrecognized command header.
Page 86
Message Communication and System Functions Syntax Diagrams Figure 6-1 Example syntax diagram 6–6...
Message Communication and System Functions Syntax Overview Syntax Overview This overview is intended to give a quick glance at the syntax defined by IEEE 488.2. It will help you understand many of the things about the syntax you need to know. IEEE 488.2 defines the blocks used to build messages which are sent to the instrument.
Page 88
Message Communication and System Functions Syntax Overview Figure 6-2 <program message> Parse Tree 6–8...
Page 89
Message Communication and System Functions Syntax Overview Upper/Lower Case Equivalence Upper and lower case letters are equivalent. The mnemonic SINGLE has the same semantic meaning as the mnemonic single. <white space> <white space> is defined to be one or more characters from the ASCII set of 0 –...
Page 90
Message Communication and System Functions Syntax Overview Suffix Unit The suffix units that the instrument will accept are shown in table 6-2. Table 6-2 <suffix unit> Suffix Referenced Unit Volt Second Example To specify 3 ns, you might enter in your program. 3E-9 S 6–10...
Page 92
This chapter describes the status registers, status bytes and status bits defined by IEEE 488.2 and discusses how they are implemented in the HP 16500C Logic Analysis System. Also in this chapter is a sample set of steps you might use to perform a serial poll over HP-IB.
Page 93
Status Reporting Figure 7-1 Status Byte Structures and Concepts 7–3...
Status Reporting Event Status Register Event Status Register The Event Status Register is an IEEE 488.2 defined register. The bits in this register are "latched." That is, once an event happens which sets a bit, that bit will only be cleared if the register is read. Service Request Enable Register The Service Request Enable Register is an 8-bit register.
Page 95
PON - power on Indicates power has been turned on. URQ - user request Always returns a 0 from the HP 16500C Logic Analysis System. CME - command error Indicates whether the parser detected an error. EXE - execution error Indicates whether a parameter was out of range, or inconsistent with current settings.
Status Reporting Key Features LCL - remote to local Indicates whether a remote to local transition has occurred. MSB - module summary bit Indicates that an enable event in one of the module Status registers has occurred. Key Features A few of the most important features of Status Reporting are listed in the following paragraphs.
Page 97
Status Reporting Key Features Figure 7-2 Service Request Enabling 7–7...
This example will show how to use the service request by conducting a serial poll of all instruments on the HP-IB bus. In this example, assume that there are two instruments on the bus: the Logic Analysis System at address 7 and a printer at address 1.
After the serial poll is completed, the RQS bit in the Status Byte Register of the HP 16500C Logic Analysis System will be reset if it was set. Once a bit in the Status Byte Register is set, it will remain set until the status is cleared with a *CLS command, or the instrument is reset.
Page 100
Status Reporting Parallel Poll Figure 7-3 Parallel Poll Data Structure 7–10...
Configuring Parallel Poll Responses Certain devices, including the HP 16500C Logic Analysis System, can be remotely programmed by a controller to respond to a parallel poll. A device which is currently configured for a parallel poll responds to the poll by placing its current status on one of the bus data lines.
Status Reporting Conducting a Parallel Poll The value of Mask (any numeric expression can be specified) is first rounded and then used to configure the device’s parallel response. The least significant 3 bits (bits 0 through 2) of the expression are used to determine which data line the device is to respond on (place its status on).
(which have the parallel poll configure capability) are disabled. HP-IB Commands The following paragraphs describe actual HP-IB commands which can be used to perform the functions of the BASIC commands shown in the previous examples. Parallel Poll Unconfigure Command The parallel poll unconfigure command (PPU) resets all parallel poll devices to the idle state (unable to respond to a parallel poll).
Page 104
The parallel poll enable secondary command (PPE) configures the devices which have received the PPC command to respond to a parallel poll on a particular HP-IB DIO line with a particular level. Parallel Poll Disable Command The parallel poll disable secondary command (PPD) disables the devices which have received the PPC command from responding to the parallel poll.
Error Messages Execution Errors Execution Errors –200 Can not do (generic execution error) –201 Not executable in local mode –202 Settings lost due to return-to-local or power on –203 Trigger ignored –211 Legal command, but settings conflict –212 Argument out of range –221 Busy doing something else –222 Insufficient capability or configuration –232 Output buffer full or overflow...
Page 114
• *OPT *WAI Common commands can be received and processed by the HP 16500C Logic Analysis System, whether they are sent over the bus as separate program messages or within other program messages. If an instrument subsystem has been selected and a common command is received by the instrument, the system will remain in the selected subsystem.
Page 115
Common Commands Example This program message initializes the disk, selects the module in slot A, then stores the file. In this example, :MMEMORY must be sent again in order to re-enter the memory subsystem and store the file. ":MMEMORY:INITIALIZE;:SELECT 1;:MMEMORY:STORE ’FILE ’, ’DESCRIPTION’"...
Page 116
Common Commands Figure 9-1 Common Commands Syntax Diagram 9–4...
Common Commands *CLS (Clear Status) Table 9-1 Common Command Parameter Values Parameter Values mask An integer, 0 through 255. pre_mask An integer, 0 through 65535. *CLS (Clear Status) Command *CLS The *CLS common command clears all event status registers, queues, and data structures, including the device defined error queue and status byte.
Common Commands *ESE (Event Status Enable) *ESE (Event Status Enable) Command *ESE <mask> The *ESE command sets the Standard Event Status Enable Register bits. The Standard Event Status Enable Register contains a bit to enable the status indicators detailed in table 9-2. A 1 in any bit position of the Standard Event Status Enable Register enables the corresponding status in the Standard Event Status Register.
Common Commands *ESR (Event Status Register) Table 9-2 Standard Event Status Enable Register Bit Position Bit Weight Enables PON - Power On URQ - User Request CME - Command Error EXE - Execution Error DDE - Device Dependent Error QYE - Query Error RQC - Request Control OPC - Operation Complete *ESR (Event Status Register)
Page 120
Common Commands *ESR (Event Status Register) Table 9-3 shows the Standard Event Status Register. The table details the meaning of each bit position in the Standard Event Status Register and the bit weight. When you read Standard Event Status Register, the value returned is the total bit weight of all the bits that are high at the time you read the byte.
An *IDN? query must be the last query in a message. Any queries after the *IDN? in the program message are ignored. Returned Format HEWLETT-PACKARD,16500C,0,REV <revision code> Four digit-code in the format XX.XX representing the current ROM revision. <revision code>...
Page 122
Common Commands *IST (Individual Status) Figure 9-2 *IST Data Structure 9–10...
An overlapped command is a command that allows execution of subsequent commands while the device operations initiated by the overlapped command are still in progress. The overlapped commands for the HP 16500C are STARt and STOP. Example OUTPUT XXX;"*OPC"...
System. The last five parameters list the installed software for the modules in slot A through E for an HP 16500C mainframe. When an HP 16501A Expansion frame is connected, there will be ten parameters after the INTERMODULE for modules in slots A through J.
An integer from 0 to 65535. <pre_mask> Example This example allows the HP 16500C to generate an IST when a message is available in the output queue. When a message is available, the MAV (Message Available) bit in the Status Byte Register will be high.
MSB - Module Summary *RST (Reset) The *RST command is not implemented on the HP 16500C. The HP 16500C will accept this command, but the command has no affect on the system. The *RST command is generally used to place the system in a predefined state.
Common Commands *SRE (Service Request Enable) *SRE (Service Request Enable) Command *SRE <mask> The *SRE command sets the Service Request Enable Register bits. The Service Request Enable Register contains a mask value for the bits to be enabled in the Status Byte Register. A one in the Service Request Enable Register will enable the corresponding bit in the Status Byte Register.
Common Commands *STB (Status Byte) Table 9-5 HP 16500C Service Request Enable Register Bit Position Bit Weight Enables 15-8 not used not used MSS - Master Summary Status (always 0) ESB - Event Status MAV - Message Available LCL- Local...
Common Commands *TRG (Trigger) Table 9-6 The Status Byte Register Bit Position Bit Weight Bit Name Condition not used 0 = instrument has no reason for service 1 = instrument is requesting service 0 = no event status conditions have occurred 1 = an enabled event status condition has occurred 0 = no output messages are ready 1 = an output message is ready...
Common Commands *TST (Test) *TST (Test) Query *TST? The *TST query returns the results of the power-up self-test. The result of that test is a 9-bit mapped value which is placed in the output queue. A one in the corresponding bit means that the test failed and a zero in the corresponding bit means that the test passed.
An overlapped command is a command that allows execution of subsequent commands while the device operations initiated by the overlapped command are still in progress. Some examples of overlapped commands for the HP 16500C are STARt and STOP. Example OUTPUT XXX;"*WAI"...
Page 134
Introduction Mainframe commands control the basic operation of the instrument for both the HP 16500C mainframe alone or with the HP 16501A expansion frame connected. Mainframe commands can be called at anytime, and from any module. The only difference in mainframe commands with an HP 16501A connected is the number of slots and modules.
Page 137
An integer enable_value An integer from 0 to 255 index An integer from 0 to 5 for an HP 16500C alone or from 0 to 10 with an HP 16501A connected An integer from 1 through 31 month An integer from 1 through 12...
Mainframe Commands BEEPer BEEPer Command :BEEPer [{ON|1}|{OFF|0}] The BEEPer command sets the beeper mode, which turns the beeper sound of the instrument on and off. When BEEPer is sent with no argument, the beeper will be sounded without affecting the current mode. Example OUTPUT XXX;":BEEPER"...
CAPability CAPability Query :CAPability? The CAPability query returns the IEEE 488.1 "Interface Requirements for Devices" capability sets implemented in the device. Table 10-2 lists the capability sets implemented in the HP 16500C. Returned Format [:CAPability] IEEE488,1987,SH1,AH1,T5,L4,SR1,RL1,PP1,DC1, DT1,C0,E2<NL> Example OUTPUT XXX;":CAPABILITY?"...
:CARDcage? The CARDcage query returns a series of integers which identify the modules that are installed in the mainframe. For an HP 16500C alone, the first five numbers returned are the card identification numbers (–1 means no card is in the slot). The remaining five numbers returned indicate the module assignment (that is, the slot containing the master card of the module) for each card.
Page 141
HP 16530A 400 MSa/s Oscilloscope Timebase Card HP 16531A Oscilloscope Acquisition Card HP 16532A 1GSa/s Oscilloscope Card HP 16533A or HP 16534A 32K GSa/s Oscilloscope Card HP 16535A MultiProbe 2-Output Module HP 16520A Pattern Generator Master Card HP 16521A Pattern Generator Expansion Card...
CESR register and contains the combined status of all of the MESE (Module Event Status Enable) registers of the HP 16500C. Table 10-4 lists the bit values for the CESE register. An integer from 0 to 65535 <value>...
The CESR query returns the contents of the Combined Event Status register. This register contains the combined status of all of the MESRs (Module Event Status Registers) of the HP 16500C System. Table 10-5 lists the bit values for the CESR register.
Page 144
Mainframe Commands CESR (Combined Event Status Register) Table 10-5 HP 16500C Combined Event Status Register Bit Weight Bit Name Condition 11-15 not used 1024 Module J 0 = No new status 1 = Status to report Module I 0 = No new status...
The EOI command specifies whether the last byte of a reply from the HP 16500C is to be sent with the EOI bus control line set true. If EOI is turned off, the logic analyzer responses will not be IEEE 488.2 compliant.
Mainframe Commands LOCKout LOCKout Command :LOCKout {{ON|1}|{OFF|0}} The LOCKout command locks out or restores front panel operation. When this function is on, all controls (except the power switch) are entirely locked out. Example OUTPUT XXX;":LOCKOUT ON" Query :LOCKout? The LOCKout query returns the current status of the LOCKout command. Returned Format [:LOCKout] {0|1}<NL>...
(defaults to 0). Table 10-6 lists the module parameters. The mainframe menus and parameters are listed in table 10-7. Selects module or system. An integer from –2 through 5 for HP 16500C only <module> or an integer from –2 through 10 with an HP 16501A connected.
MESR register. The <N> index specifies the module, and the parameter specifies the enable value. For the HP 16500C alone, the <N> index 0 through 5 refers to system and modules 1 through 5 respectively. With an HP 16501A connected, the <N> index 6 through 10 refers to modules 6 through 10 respectively.
Page 149
Status Enable register bits, bit weights, and what each bit masks for the mainframe. Returned Format [:MESE<N>] <enable_value><NL> Example OUTPUT XXX;":MESE1?" Table 10-8 HP 16500C Mainframe (Intermodule) Module Event Status Enable Register Bit Position Bit Weight Enables not used not used not used...
:MESR<N>? The MESR query returns the contents of the Module Event Status register. The <N> index specifies the module. For the HP 16500C alone, the <N> index 0 through 5 refers to system and modules 1 through 5 respectively. With an HP 16501A connected, the <N> index 6 through 10 refers to modules 6 through 10 respectively.
Mainframe Commands RMODe RMODe Command :RMODe {SINGle|REPetitive} The RMODe command specifies the run mode for the selected module (or Intermodule). If the selected module is in the intermodule configuration, then the intermodule run mode will be set by this command. After specifying the run mode, use the STARt command to start the acquisition.
Mainframe Commands RTC (Real-time Clock) RTC (Real-time Clock) Command :RTC <day>,<month>,<year>,<hour>,<minute>,<second> The real-time clock command allows you to set the real-time clock to the current date and time. integer from 1 to 31 <day> integer from 1 to 12 <month> integer from 1990 to 2089 <year>...
The appropriate module (or system) must be selected before any module (or system) specific commands can be sent. SELECT 0 selects System, SELECT 1 through 5 selects modules A through E in an HP 16500C only. SELECT 1 through 10 selects modules A through J when an HP 16501A is connected.
Page 154
Mainframe Commands SELect Figure 10-2 Only available when an HP 16501A is connected Select Command Tree 10–22...
Mainframe Commands SETColor SETColor Command :SETColor {<color>,<hue>,<sat>,<lum>|DEFault} The SETColor command is used to change one of the color selections on the CRT, or to return to the default screen colors. Four parameters are sent with the command to change a color: •...
Mainframe Commands STARt Query :SETColor? <color> The SETColor query returns the hue, saturation, and luminosity values for a specified color. Returned Format [:SETColor] <color>,<hue>,<sat>,<lum><NL> Example OUTPUT XXX;":SETCOLOR? 3" STARt Command :STARt The STARt command starts the selected module (or Intermodule) running in the specified run mode (see RMODe).
Mainframe Commands STOP STOP Command :STOP The STOP command stops the selected module (or Intermodule). If the specified module is in the Intermodule configuration, then the Intermodule run will be stopped. The STOP command is an overlapped command. An overlapped command is a command that allows execution of subsequent commands while the device operations initiated by the overlapped command are still in progress.
XWINdow ON command opens a window. If no display is specified, the display already stored in the HP 16500C X Window Settings menu is used. If a display is specified, that one is used. The specified display also is stored in non-volatile memory in the HP 16500C.
Page 160
HP 16500C mainframe. Refer to figure 11-1 and table 11-1 for the SYSTem Subsystem commands syntax diagram. The SYSTem Subsystem commands are: •...
Page 161
SYSTem Subsystem Figure 11-1 System Subsystem Commands Syntax Diagram 11–3...
Page 162
SYSTem Subsystem Table 11-1 SYSTem Parameter Values Parameter Values block_data Data in IEEE 488.2 format. string A string of up to 68 alphanumeric characters. pathname A string of up to 10 alphanumeric characters for LIF in the following form: NNNNNNNNNN A string of up to 64 alphanumeric characters for DOS in one of the following forms: NNNNNNNN.NNN when the file resides in the present working...
SYSTem Subsystem DATA DATA Command :SYSTem:DATA <block_data> The DATA command allows you to send and receive acquired data to and from a controller in block form. This helps saving block data for: • Reloading the logic analysis system • Processing data later in the logic analysis system •...
SYSTem Subsystem DSP (Display) Query :SYSTem:DATA? The SYSTem:DATA query returns the block data. The data sent by the SYSTem:DATA query reflects the configuration of the selected module when the last acquisition was performed. Any changes made since then through either front-panel operations or programming commands do not affect the stored data.
STRing, then the error is returned in the following form: <error_number>,<error message string> A complete list of error messages for the HP 16500C logic analysis system is shown in chapter 8, "Error Messages." If no errors are present in the error queue, a zero (No Error) is returned.
SYSTem Subsystem HEADer HEADer Command :SYSTem:HEADer {{ON|1}|{OFF|0}} The HEADer command tells the instrument whether or not to output a header for query responses. When HEADer is set to ON, query responses will include the command header. Example OUTPUT XXX;":SYSTEM:HEADER ON" Query :SYSTem:HEADer? The HEADer query returns the current state of the HEADer command.
SYSTem Subsystem LONGform LONGform Command :SYSTem:LONGform {{ON|1}|{OFF|0}} The LONGform command sets the long form variable, which tells the instrument how to format query responses. If the LONGform command is set to OFF, command headers and arguments are sent from the instrument in the abbreviated form.
SYSTem Subsystem PRINt PRINt Commands :SYSTem:PRINt ALL[,DISK, <pathname>[,<msus>]] :SYSTem:PRINt PARTial,<start>,<end> [,DISK, <pathname>[,<msus>]] :SYSTem:PRINt SCReen[,DISK, <pathname> [,<msus>], {BTIF|CTIF|PCX|EPS}] The PRINt command initiates a print of the screen or listing buffer over the current PRINTER communication interface to the printer or to a file on the disk.
Page 169
PRINT? ALL is only available in menus that have the "Print All" option available on the front panel. For more information, refer to the HP 16500C Logic Analysis System User’s Reference .
SYSTem Subsystem SETup SETup Command :SYSTem:SETup <block_data> The :SYSTem:SETup command configures the logic analysis system as defined by the block data sent by the controller. This chapter describes briefly the syntax of the Setup command and query for the mainframe. Because of the capabilities and importance of the Setup command and query for individual modules, a complete chapter is dedicated to it in each of the module Programmer’s Guides.
Page 171
SYSTem Subsystem SETup Query :SYSTem:SETup? The SYSTem:SETup query returns a block of data that contains the current configuration to the controller. Returned Format [:SYSTem:SETup] <block_data><NL> Example See the Programmer’s Guide for the selected module for an example. 11–13...
Page 174
Introduction The MMEMory (mass memory) subsystem commands provide access to both the hard and flexible disk drives. The HP 16500C Logic Analysis System supports the DOS (Disk Operating System) format on the hard drive and both DOS and LIF (Logical Information Format) on the flexible drive.
Page 178
An integer, refer to table 12-2. block_data Data in IEEE 488.2 format. module An integer, –2 through 5 for the HP 16500C alone or –2 through 10 with the HP 16501A connected. ia_name A string of up to 10 alphanumeric characters for LIF in the following form: "NNNNNNNNNN"...
MMEMory Subsystem AUToload AUToload Command :MMEMory:AUToload {{OFF|0}|{<auto_file>}}[,<msus>] The AUToload command controls the autoload feature which designates a set of configuration files to be loaded automatically the next time the instrument is turned on. The OFF parameter (or 0) disables the autoload feature. A string parameter may be specified instead to represent the desired autoload file.
Query :MMEMory:CATalog? [[ALL|FULL][,<msus>]] The FULL option is available with version 1.01 or higher of the HP 16500C operating system only. Version 1.00 does not recognize this option. The CATalog query returns the directory of the disk in one of three block data formats.
OUTPUT XXX;":MMEMory:CD ’\SYSTEM\SOURCE_DIR\DIR’, INTernal0" The slash (/) character in DOS path names will be automatically translated to the backslash character (\) on the disk; therefore, any flexible DOS disk used in the HP 16500C will be compatible in DOS computers. 12–9...
MMEMory Subsystem COPY COPY Command :MMEMory:COPY <name>[,<msus>],<new_name>[,<msus>] The COPY command copies one file to a new file. Wildcards are supported. The two <name> parameters are the filenames. The first pair of parameters specifies the source file. The second pair specifies the destination. An error is generated if the source file doesn’t exist, or if the destination file already exists.
MMEMory Subsystem DOWNload Example To copy the contents of "FILE1" to "FILE2": OUTPUT XXX;":MMEMORY:COPY ’FILE1’,’FILE2’" To copy the contents of "FILE1" on the hard disk to "FILE2" on the flexible disk: OUTPUT XXX;":MMEMORY:COPY ’FILE1’,INTERNAL0,’FILE2’,INTERNAL1" To copy the contents of a LIF flexible disk to the hard disk: OUTPUT XXX;":MMEM:COPY ’*’,INT1,’\’,INT0"...
Page 184
HP 16500A/B/C System Configuration –16127 HP 16510A/B Configuration –16096 HP 16511B Configuration –16097 HP 16515A (Master) and 16516A (Expander) Configuration –16126 HP 16517A (Master) and 16518A (Expander) Configuration –16123 HP 16520A (Master) and 16521A (Expander) Configuration –16106 HP 16522A Configuration –16102...
Command :MMEMory:IDENtify? [<msus>] The IDENtify query is available with version 1.01 or higher of the HP 16500C operating system only. Version 1.00 does not recognize this query. The IDENtify query returns the serial number of the disk in the specified drive.
MMEMory Subsystem INITialize INITialize Command :MMEMory:INITialize [{LIF|DOS}[,<msus>]] The INITialize command formats the disk in DOS (Disk Operating System) on the hard drive or either DOS or LIF (Logical Information Format) on the flexible drive. If no format is specified, then the initialize command will format the disk in the DOS format.
\NAME_DIR\FILENAME when it does not reside in the current directory Mass Storage Unit specifier. INTernal0 for the hard disk drive and <msus> INTernal1 for the flexible disk drive. An integer, –2 through 5 for the HP 16500C alone. –2 through 10 with the <module> HP 16501A connected. Example OUTPUT XXX;":MMEMORY:LOAD:CONFIG ’FILE...
Mass Storage Unit specifier. INTernal0 for the hard disk drive and <msus> INTernal1 for the flexible disk drive. An integer, 1 through 5 for the HP 16500C alone. 1 through 10 with an HP <module> 16501A connected. Although the parser will accept the values –1 and –2, they will generate a disk error.
OUTPUT XXX;":MMEM:MKD ’\SYSTEM\NEW.DIR’,INT0 " The slash (/) character in DOS path names will be automatically translated to the backslash character (\) on the disk; therefore, any flexible DOS disk used in the HP 16500C will be compatible in DOS computers. 12–17...
MMEMory Subsystem MSI (Mass Storage Is) MSI (Mass Storage Is) Command :MMEMory:MSI [<msus>] The MSI command selects a default mass storage device. INTernal0 selects the hard disk drive and INTernal1 selects the flexible disk drive. Once the MSI is selected it remains the default drive until another MSI command is sent to the system.
MMEMory Subsystem PACK PACK Command :MMEMory:PACK [<msus>] The PACK command packs the files on the LIF disk the disk in the drive. If a DOS disk is in the drive when the PACK command is sent, no action is taken. Mass Storage Unit specifier.
MMEMory Subsystem PURGe PURGe Command :MMEMory:PURGe <name>[,<msus>] The PURGe command deletes files and directories from the disk in the specified drive. The PURge command only purges directories when the directory is empty. If the PURge command is sent with a directory name and the directory contains files, the message "Directory contains files"...
MMEMory Subsystem PWD (Present Working Directory) PWD (Present Working Directory) Query :MMEMory:PWD? [<msus>] The PWD query returns the present working directory for the specified drive. If the <msus> option is not sent, the present working directory will be returned for the current drive. Returned Format [:MMEMory:PWD] <directory>,<msus><NL>...
MMEMory Subsystem REName REName Command :MMEMory:REName <name>[,<msus>],<new_name> The REName command renames a file on the drive. The <name> parameter specifies the filename to be changed and the <new_name> parameter specifies the new filename. You cannot use REName to move a file from one drive to the other.
The appropriate module designator "_X" is added to all files when they are stored. "_X" refers to either an __ (double underscore) for the system or an _(A through E) for an HP 16500C alone or an _(A through J) with an HP 16501A connected.
The contents of the file are sent out of the instrument in block data form. This command should only be used for HP 16550A configuration files. A string of up to 10 alphanumeric characters for LIF in the following form: <name>...
MMEMory Subsystem VOLume VOLume Query :MMEMory:VOLume? [<msus>] The VOLume query returns the volume type of the disk. The volume types are DOS or LIF. Question marks (???) are returned if there is no disk, if the disk is not formatted, or if a disk has a format other than DOS or LIF. Mass Storage Unit specifier.
Page 200
Introduction The INTermodule subsystem commands specify intermodule arming from the rear-panel input BNC (ARMIN) or to the rear-panel output BNC (ARMOUT). Refer to figure 13-1 and table 13-1 for the INTermodule Subsystem commands syntax diagram. The INTermodule commands are: • DELete •...
Table 13-1 INTermodule Parameter Values Parameter Value module An integer, 1 through 5 for HP 16500C alone. 1 through 10 with the HP 16501A connected. user_lev A real number from –4.0 to +5.0 volts in 0.02 volt increments index An integer, 1 through 5 for HP 16500C alone. 1 through 10 with the HP 16501A connected.
Group Run. The <module> parameter sent with the delete command refers to the slot location of the module. An integer, 1 through 5 for HP 16500C alone. 1 through 10 with the HP <module> 16501A connected.
INTermodule Subsystem HTIMe HTIMe Query :INTermodule:HTIMe? The HTIMe query returns a value representing the internal hardware skew in the Intermodule configuration. If there is no internal skew, 9.9E37 is returned. The internal hardware skew is only a display adjustment for time-correlated waveforms.
INTermodule Subsystem INPort INPort Command :INTermodule:INPort {{ON|1}|{OFF|0}} The INPort command causes intermodule acquisitions to be armed from the Port In, the same as Group Run Armed from PORT IN in the Intermodule menu. A value of 0 removes Port In from the Group Run. In version 1.02 and later of the operating system software, you can set Group Run with OR TRIGGER by setting INPort to 2.
A through E for the HP 16500C alone and 1 through 10 corresponds to slot location of modules A through J when an HP 16501A is connected. An integer, 1 through 5 for HP 16500C alone. 1 through 10 with the HP <module> 16501A connected.
The OUTDrive command sets the Port Out BNC to put out either a normal (TTL-type) or open-collector signal. This corresponds to the Output field in the PORT IN/OUT Setup menu under the Intermodule menu. See Also The HP 16500C User’s Reference for more information about open collector signals. Example OUTPUT XXX;":INTERMODULE:OUTDRIVE NORMAL"...
The OUTType command sets the Port Out BNC signal type. This command has the same effect as setting the Type field in the PORT IN/OUT Setup menu under the Intermodule menu. See Also The HP 16500C User’s Reference for more information about Port Out signal types. Example OUTPUT XXX;":INTERMODULE:OUTTYPE LATCHED"...
INTermodule Subsystem PORTEDGE PORTEDGE Command :INTermodule:PORTEDGE <edge_spec> This command does not obey the truncation rules. The PORTEDGE command sets the Port In BNC to respond to either a rising edge of falling edge for a trigger from an external source. The threshold level of the input signal is set by the PORTLEV command.
INTermodule Subsystem PORTLEV PORTLEV Command :INTermodule:PORTLEV {TTL|ECL|<user_lev>} This command does not obey the truncation rules. The PORTLEV (port level) command sets the threshold level at which the input BNC responds and produces an intermodule trigger. The preset levels are TTL and ECL. The user-defined level is –4.0 volts to +5.0 volts. If a value outside this range is specified, the value is set to the extreme in the direction exceeded and no error message is generated.
(1 through 5 corresponds to the slot location of the modules A through E for the HP 16500C alone and 1 through 10 to slot location of modules A through J when an HP 16501A is connected). The <setting>...
1 to 10. 1 through 10 correspond to slots A through J. An integer, −1 through 5 for an HP 16500C alone. −1 through 10 with an <module>...
Page 214
INTermodule Subsystem TREE Query :INTermodule:TREE? The TREE? query returns a string that represents the intermodule tree. A −1 means the module is not in the intermodule tree, a 0 value means the module is armed from the Intermodule run button (Group run), and a positive value indicates the module is being armed by another module with the slot location 1 to 10.
Query :INTermodule:TTIMe? The TTIMe query returns five values for the HP 16500C alone or ten with an HP 16501A connected representing the absolute intermodule trigger time for all of the modules in the Intermodule configuration. The first value is the trigger time for the module in slot A, the second value is for the module in slot B, the third value is for slot C, etc.
Page 218
Introduction The TGTctrl subsystem commands specify the signals put out by the Target Control Port. Refer to figure 14-1 and table 14-1 for the TGTctrl Subsystem commands syntax diagram. The TGTctrl commands are: • • AVAILable • BITS • CURSTate •...
TGTctrl Subsystem :TGTctrl Table 14-1 TGTctrl Parameter Values Parameter Value An integer, 0 through 7, indicating signal bits An integer, 0 though 255 state An integer, 0 through 7 name A string of up to 14 characters :TGTctrl Selector :TGTctrl This command does not obey the truncation rule.
TGTctrl Subsystem Query :TGTctrl:ALL<N>? The ALL query returns all parameters of the signal specified by <N>. These values may be individually queried using other commands in the TGTctrl subsystem. An integer, 0 through 7. <N> Returned Format [:TGTctrl:ALL<N>] <on>,<name>,<type>,<bits>,<drive>,<last>, <current>,<state0>,<state1>,<state2>,<state3>,<state4>, <state5>,<state6>,<state7><nl>...
An integer, 0 through 255. <bits> Example For example, if your HP BASIC program contains a line OUTPUT XXX;":TGTCTRL:AVAILABLE?" and the value returned is 248, you have 1111 1000 in binary. The binary value lets you know that bits 0 through 2 are in use, but bits 3 through 7 are available.
TGTctrl Subsystem BITS BITS Command :TGTctrl:BITS<N> <mask> The BITS command assigns bits to a signal. A 1 in the mask’s bit position assigns the bit to the signal. The mask overwrites any previous assignments. An integer, 0 through 7, specifying signal. <N>...
TGTctrl Subsystem CURSTate CURSTate Query :TGTctrl:CURSTate<N>? This command does not obey the truncation rule. The CURSTate query returns the current state of the specified signal. For toggle and pulse signals, this will be either 0 or 1. For sequence signals, it will be between 0 and the last state.
TGTctrl Subsystem LASTstate LASTstate Command :TGTctrl:LASTstate<N> <state> The LASTstate command sets a signal’s last state. LASTstate has no effect unless the signal type is sequence. An integer, 0 through 7, specifying signal. <N> An integer, 1 through 7. <state> Example OUTPUT XXX;":TGTCTRL:LAST2 4"...
TGTctrl Subsystem NAMe NAMe Command :TGTctrl:NAMe<N> <name> The LASTstate command sets a signal name. An integer, 0 through 7, specifying signal. <N> A string of up to 14 characters. <name> Example OUTPUT XXX;":TGTCTRL:NAME0 ’Reset’" Query :TGTctrl:NAMe<N>? The NAMe query returns the name of the specified signal. The default names are SIGNAL 0 through SIGNAL 7.
TGTctrl Subsystem PULse PULse Command :TGTctrl:PULse<N> This command does not obey the truncation rule. The PULse command pulses the specified signal. If the signal type is toggle or sequence, it sets the signal to the next state. This command works the same as STEP and TOGgle.
TGTctrl Subsystem SIGSTatus SIGSTatus Query :TGTctrl:SIGSTatus<N>? This command does not obey the truncation rule. The SIGSTatus query returns two values. The first is the current state on the target control lines assigned to the signal. The second is an activity indicator on the signal.
TGTctrl Subsystem STATEs STATEs Command :TGTctrl:STATEs<N> <value_0>[,<value_1>, <value_2>,<value_3>,<value_4>,<value_5>,<value_6>, <value_7>] This command does not obey the truncation rule. The STATEs command sets the state values of the specified signal. The value is interpreted as a packed bitmask. You can specify up to 8 values on the command line.
TGTctrl Subsystem STEP STEP Command :TGTctrl:STEP<N> The STEP command sets the specified signal to the next state. If the signal type is pulse, it briefly pulses the signal. STEP can be used with any type of signal. This command has the same effect as PULse and TOGgle. An integer, 0 through 7, specifying signal.
TGTctrl Subsystem TYPe TYPe Command :TGTctrl:TYPe<N> {{TOGgle|0} | {PULse|1} | {SEQuence|2}} The TYPe command sets the signal type for the specified signal. It does not turn on the signal. An integer, 0 through 7, specifying signal. <N> Example OUTPUT XXX;":TGT:TYP2 SEQ" Query :TGTctrl:TYPe<N>? The TYPe query returns the current type of the signal.
Page 236
Introduction This chapter contains short, usable, and tested program examples that cover the most frequently requested examples. The examples are written in HP BASIC 6.2. • Transferring the mainframe configuration between the mainframe and the controller • Checking for intermodule measurement completion •...
SYSTem:DATA? command and query is only useful for modules. ! ****************** SETUP COMMAND AND QUERY EXAMPLE ******************** for the HP 16500C/16501A Logic Analysis System ! ********************* CREATE TRANSFER BUFFER ************************* ! Create a buffer large enough for the block data.
Page 238
Programming Examples Transferring the Mainframe Configuration ! *********************** SEND THE SETUP QUERY ************************** OUTPUT 707;":SYSTEM:HEADER ON" OUTPUT 707;":SYSTEM:LONGFORM ON" OUTPUT @Comm;"SELECT 0" OUTPUT @Comm;":SYSTEM:SETUP?" ! ******************** ENTER THE BLOCK SETUP HEADER ********************* ! Enter the block setup header in the proper format. ENTER @Comm USING "#,B";Byte PRINT CHR$(Byte);...
Page 239
! transfer. STATUS @Buff,5;Streg 1000 1010 ! ****************** TRANSFER SETUP TO THE HP 16500C ******************** 1020 ! Transfer the setup from the buffer to the HP 16500C mainframe. 1030 1040 TRANSFER @Buff TO @Comm;COUNT Numbytes,WAIT 1050 1060 ! ********************** RESTORE BUFFER POINTERS ***********************...
Programming Examples Checking for Intermodule Measurement Completion Checking for Intermodule Measurement Completion This program can be appended to or inserted into another program when you need to know when an intermodule measurement is complete. If it is at the end of a program it will tell you when measurement is complete. If you insert it into a program, it will halt the program until the current measurement is complete.
OUTPUT 707;":SYSTEM:HEADER ON" OUTPUT 707;":SYSTEM:LONGFORM ON" ! ************************************************************* ! Select the mainframe. ! Always a 0 for the HP 16500C/16501A mainframe. OUTPUT 707;":SELECT 0" ! **************************************************************** ! Dimension a string in which the query response will be entered. DIM Query$[100] ! **************************************************************** 15–7...
Page 242
Programming Examples Sending Queries to the Logic Analysis System ! Send the query. In this example the MENU? query is sent. ! queries except the SYSTem:DATA and SYSTem:SETup can be sent with ! this program. OUTPUT 707;"MENU?" ! **************************************************************** ! The two lines that follow transfer the query response from the ! query buffer to the controller and then print the response.
You must select the proper menu. The only menus that allow you to use the PRINt? ALL query are the disk menu and listing menus. ****** ASCII DATA ******* ! This program gets the hard disk directory from the HP 16500C mainframe in ASCII form by using the PRINT? ALL query. !**************************************************************** DIM Block$[32000] OUTPUT 707;"EOI ON"...
Programming Examples Reading the disk with the CATalog? ALL query Reading the disk with the CATalog? ALL query The following example program reads the catalog of the currently selected disk drive. The CATALOG? ALL query returns the entire 70-character field. Because DOS directory entries are 70 characters long, you should use the CATALOG? ALL query with DOS disks.
Programming Examples Reading the Disk with the CATalog? Query Reading the Disk with the CATalog? Query This example program uses the CATALOG? query without the ALL option to read the catalog of the currently selected disk drive. However, if you do not use the ALL option, the query only returns a 51-character field.
Programming Examples Printing to the disk Printing to the disk This program prints acquired data to a disk file. The file can be either on a LIF or DOS disk. If you print the file to a flexible disk in the DOS format, you will be able to view the file on a DOS compatible computer using any number of file utility programs.
Page 252
This Hewlett-Packard This is the first edition of the Hewlett-Packard edition and of any changed product has a warranty HP 16500C/16501A specifically disclaims the pages to that edition. against defects in material Programmer’s Guide. implied warranties of...