Agilent Technologies Infiniium 8000A Programmer's Reference Manual page 111

Table of Contents

Advertisement

/*
*
Function name: create_SRQ
*
Parameters:
*
Return value:
* Description: This routine sends two illegal commands to the oscilloscope which
* will generate an SRQ and will place two error strings in the error queue. The
* oscilloscope ID is requested to allow time for the SRQ to be generated. The ID
*
string will contain a leading character which is the response placed in
*
the output queue by the interrupted query.
*/
void create_SRQ( void )
{
char buf[256] = { 0 };
int bytes_read = 0;
#ifdef AGILENT
// Setup the Agilent interrupt handler
ionsrq( scope, srq_agilent );
#else
// Setup the National interrup handler
ibnotify( scope, RQS, srq_national, NULL );
#endif
// Generate command error - send illegal header
write_IO(":CHANnel:DISPlay OFF");
srq_asserted = TRUE;
while( srq_asserted )
{
// Do nothing until the interrupt has finished
}
} /* end create_SRQ() */
Generating a Service Request
The following function is demonstrated in the "gen_srq.c" sample program.
none
none
// read buffer for id string
Sample Programs
Sample C Programs
6-17

Advertisement

Table of Contents
loading

Table of Contents