Srq Method - Keysight N432A Programming Manual

Thermistor power meter
Hide thumbs Also See for N432A:
Table of Contents

Advertisement

1
N432A Remote Operation

SRQ method

When a bit of the Status register is set and has been enabled to assert SRQ (*SRE
command), the N432A sets the GPIB SRQ line true. This interrupt can be used to
interrupt your program, suspend its current operation, and find out what service
the N432A requires. Refer to your PC and language manuals for information on
how to program the PC to respond to the interrupt.
To allow any of the Status register bits to set the SRQ line true, you must enable
the appropriate bit(s) with the *SRE command, for example, if your application
requires an interrupt whenever a message is available in the output queue (Status
register bit 4, decimal value 16). To enable bit 4 to assert SRQ, use command
*SRE 16.
You can determine which bits are enabled in the Status register using *SRE?.
NOTE
This command returns the decimal-weighted sum of all the bits.
Procedure
– Send a bus device clear message.
– Clear the event registers with the *CLS (clear status) command.
– Set the *ESE (standard event register) and *SRE (status byte register) enable
– Enable the IEEE-488 SRQ interrupt of your bus controller.
Examples
The following two examples are written in HP BASIC and illustrate possible uses
for SRQ. In both cases, it is assumed that the N432A has been zeroed.
Example 1
10
20
30
40
50
60
70
100
masks.
! Program to generate an SRQ when a channel A sensor
! connect or disconnect occurs
!
ASSIGN @Pm TO 713
ON ON INTR 7 GOTO Srq_i! Define service request handler
CLEAR @Pm
OUTPUT @Pm;"*CLS;*RST" ! Clear registers and reset meter
! Power meter GPIB address
! Selective device clear
Keysight N432A Programming Guide

Advertisement

Table of Contents
loading

Table of Contents