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

Table of Contents

Advertisement

/*
*
Function name:
*
Parameters:
none
*
Return value:
*
Description:
This routine requests the system setup known as a
* learnstring. The learnstring is read from the oscilloscope and stored in a file
*
called Learn2.
*/
void store_learnstring( void )
{
FILE *fp;
unsigned char setup[MAX_LRNSTR]={0};
int actualcnt = 0;
write_IO(":SYSTem:SETup?");
actualcnt = read_IO(setup, MAX_LRNSTR);
fp = fopen( "learn2","wb");
if ( fp != NULL )
{
fwrite( setup,sizeof(unsigned char),(int)actualcnt,fp);
printf("Learn string stored in file Learn2\n");
fclose( fp );
}
else
printf("Error in file open\n");
}/* end store_learnstring */
/*
*
Function name:
*
Parameters:
none
*
Return value:
* Description: This routine places the oscilloscope into local mode to allow the
*
customer to change the system setup.
*/
void change_setup( void )
{
printf("Please adjust setup and press ENTER to continue.\n");
getchar();
} /* end change_setup */
store_learnstring
none
change_setup
none
learnstr.c Sample Program
/* request learnstring */
Sample Programs
6-25

Advertisement

Table of Contents
loading

Table of Contents