HP VXI manual SRE mask, Sre?, Stb?, Tst?

Page 32

The output queue

The Service Request Enable Register

The Standard Event Status Enable Register

The power-on flag

Calibration data

Protected user data

*SRE <mask>

Service Request Enable. When a service request event occurs, it sets a corresponding bit in the Status Byte Register (this happens whether or not the event has been enabled (unmasked) by *SRE). The *SRE command allows you to identify which of these events will assert a service request (SRQ). When an event is enabled by *SRE and that event occurs, it sets a bit in the Status Byte Register and issues an SRQ to the computer. You enable an event by specifying its decimal weight for <mask>. To enable more than one event, specify the sum of the decimal weights.

Example *SRE 160

Enables bits 5 & 7. Respective weights

 

are 32 + 128 = 160.

*SRE?

Status Register Enable Query. Returns the weighted sum of all enabled (unmasked) events (those enabled to assert SRQ) in the Status Byte Register.

Example *SRE?

Sends Status Register Enable query.

*STB?

Status Byte Register Query. Returns the weighted sum of all set bits in the Status

Byte Register.

Comments You can read the Status Byte Register using either the *STB? command or by doing a SICL ireadstb function call. There are some subtle differences between *STB? and ireadstb. You can use either method to read the state of bits 0-5 and bit 7. Bit 6 is treated differently depending on whether you use *STB? or ireadstb. In general, use ireadstb inside interrupt service routines, not *STB?.

Example *STB?

Sends Status Byte Register query.

*TST?

Self-Test.Causes an instrument to execute an internal self-test and returns a response showing the results of the self-test. A zero response indicates that self-test passed. A value other than zero indicates a self-test failure or error.

Example *TST?

Execute self-test, return response.

32 Command Reference

Chapter 3

Image 32
Contents Contents Comments Example QUEStionableEVENt? Printing History This Page Intentionally Left Blank Introduction Introduction Chapter About this Chapter General Status Register ModelCondition Register Transition Filter Event Register An Example SequencePage Required Status Groups Status Byte Register Standard Event Group Status Byte Bit DefinitionsStandard Operation Status Group Questionable Data Group Handling SRQs Using MAV to Determine When Data is Available Status System Programming ExamplesExample Program SRQ Icloseid Example Program Deverrmask Qryerrmask Chapter Programming the Status System Programming the Status System Chapter Command Reference OPERation CONDition? OPERationENABleSTATus OPERationENABle? PRESetOPERationEVENt? QUEStionable CONDition?QUEStionableEVENt? QUEStionableENABleQUEStionableENABle? STATQUESEVEN? Common Command Reference CLSEMC? ESE maskESE? ESR?LRN? IDN?LMC? OPC OPC?PMC RSTSRE mask SRE?STB? TST?WAI Command Reference Chapter