Service Request Enable Register; Using Service Request (Srq) And Serial Poll; Using Status Byte Query (*Stb); Using Message Available (Mav) Bit - Lakeshore 642 User Manual

Electromagnet power supply
Table of Contents

Advertisement

5.1.4.4.2

Service Request Enable Register

The Service Request Enable Register is programmed by the user and determines which summary bits of the Status Byte
may set bit 6 (RQS/MSS) to generate a Service Request. Enable bits are logically ANDed with the corresponding
summary bits, see Figure 5-6. Whenever a summary bit is set by an event register and its corresponding enable bit is set
by the user, bit 6 will set to generate a service request. The Service Request Enable command (*SRE) programs the
Service Request Enable Register and the query command (*SRE?) reads it. Reading the Service Request Enable Register
will not clear it. The register may be cleared by the user by sending *SRE 0.
5.1.4.4.3

Using Service Request (SRQ) and Serial Poll

When a Status Byte summary bit (or MAV bit) is enabled by the Service Request Enable Register and goes from 0 to 1,
bit 6 (RQS/MSS) of the status byte will be set. This will send a service request (SRQ) interrupt message to the bus
controller. The user program may then direct the bus controller to serial Poll the instruments on the bus to identify which
one requested service (the one with bit 6 set in its status byte).
Serial polling will automatically clear RQS of the Status Byte Register. This allows subsequent serial polls to monitor bit
6 for an SRQ occurrence generated by other event types. After a serial poll, the same event or any event that uses the
same Status Byte summary bit, will not cause another SRQ unless the event register that caused the first SRQ has been
cleared, typically by a query of the event register.
The serial poll does not clear MSS. The MSS bit stays set until all enabled Status Byte summary bits are cleared,
typically by a query of the associated event register, refer to Paragraph 5.1.4.4.4.
The programming example in Table 5-3 initiates an SRQ when a command error is detected by the instrument.
Command or Operation
*ESR?
*ESE 32
*SRE 32
*ABC
Monitor bus
Initiate Serial Poll
*ESR?
5.1.4.4.4
Using Status Byte Query (*STB?)
The Status Byte Query (*STB?) command is similar to a Serial Poll except it is processed like any other instrument
command. The *STB? command returns the same result as a Serial Poll except that the Status Byte bit 6 (RQS/MSS) is
not cleared. In this case bit 6 is considered the MSS bit. Using the *STB? command does not clear any bits in the Status
Byte Register.
5.1.4.4.5

Using Message Available (MAV) Bit

Status Byte summary bit 4 (MAV) indicates that data is available to read into your bus controller. This message may be
used to synchronize information exchange with the bus controller. The bus controller can, for example, send a query
command to the Model 642 and then wait for MAV to set. If the MAV bit has been enabled to initiate an SRQ, the user's
program can direct the bus controller to look for the SRQ leaving the bus available for other use. The MAV bit will be
clear whenever the output buffer is empty.
Computer Interface Operation
Lake Shore Model 642 Electromagnet Power Supply User's Manual
Table 5-3. Programming Example to Generate an SRQ
Read and clear the Standard Event Status Register.
Enable the Command Error (CME) bit in the Standard Event Status Register
Enable the Event Summary Bit (ESB) to set the RQS
Send improper command to instrument to generate a command error
Monitor the bus until the Service Request interrupt (SRQ) is sent.
Serial Poll the bus to determine which instrument sent the interrupt and clear the RQS bit
in the Status Byte.
Read and clear the Standard Event Status Register allowing an SRQ to be generated on
another command error.
Description
5-13

Advertisement

Table of Contents
loading

Table of Contents