Status Byte And Service Request Commands; Serial Poll Programming Example - Keithley 2750 User Manual

Multimeter/switch system
Hide thumbs Also See for 2750:
Table of Contents

Advertisement

Model 2750 Multimeter/Switch System User's Manual

Status byte and service request commands

The commands to program and read the Status Byte Register and Service Request Enable
Register are listed in
"Programming enable registers," page
NOTE
Table 11-2
Status byte and service request enable register commands
Command
*STB?
*SRE <NRf>
*SRE?
Note: *CLS and STATus:PRESet have no effect on the Service Request Enable Register.
Programming example — set MSS (B6) when error occurs
The second command in the following sequence enables EAV (error available). When an
invalid command is sent (line 3), bits B2 (EAV) and B6 (MSS) of the Status Byte Register
set to 1. The last command reads the Status Byte Register. Keep in mind that you have to
address the Model 2750 to talk after sending a query command. To determine the exact
nature of the error, you will have to read the Error Queue (see
*CLS
*SRE 4
*XYZ
*STB?

Serial poll programming example

This example is written specifically for the KPCI-488.2 GPIB card and QuickBasic/
VisualBasic with the appropriate IEEE libraries. Other types of cards and/or languages
may have different function calls that are equivalent to the initialize(), transmit(), send(),
srq, and spoll() calls used below.
SRQ when buffer fills with 500, 1000, 1500, and 1750 readings
The following program will store 2000 readings in the buffer. When the buffer fills with
500 readings (quarter full), an SRQ will occur and a message will be displayed on the
computer to indicate that event. An SRQ and message will also occur when the 1000th
(half full), 1500th (three-quarter full), 1750th (buffer notify), and 2000th (full) reading is
stored.
Table
11-2. For details on programming and reading registers, see
To reset the bits of the Service Request Enable Register to 0, use 0 as the param-
eter value for the *SRE command (*SRE 0).
Read Status Byte Register.
Program the Service Request Enable Register
(0 to 255).
Read the Service Request Enable Register.
11-5, and
"Reading registers," page
Description
' Clear Error Queue
' Enable EAV.
' Generate error.
' Read Status Byte Register.
Status Structure
11-6.
"Queues," page
11-20).
11-9

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents