EasyManuals Logo
Home>Agilent Technologies>Test Equipment>86100C

Agilent Technologies 86100C Programmer's Guide

Agilent Technologies 86100C
366 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #79 background imageLoading...
Page #79 background image
2-25
Sample Programs
C Programming Examples
int start=clock(),stop;
char Msk_hits1[16],Crss_pct1[16],Ext_rat1[16],buff[32];
char Msk_hits2[16],Crss_pct2[16],Ext_rat2[16];
write_IO("CHANnel1:DISPlay ON");//turn on channel one
write_IO("CHANnel3:DISPlay ON, APPEnd");//turn on channel three
write_IO("RUN"); //start acquistion
write_IO("AUToscale"); //Autoscale
write_IO("CALibrate:SKEW:AUTO");//auto deskew the two channels
write_IO("*OPC?"); //query for completion
read_IO(buff,5); //read completion response
write_IO("MTESt:LOAD \"STM016_OC48.msk\"");//load OC-48 mask
write_IO("MTESt:SOURce CHANnel1");//set mask test channel1
write_IO("MTESt:START"); //start mask test
write_IO("MTESt:COUNt:FSAMples?");//query the number of failed samples
Msk_hits1[read_IO(Msk_hits1, 15)]=0;//get the number of mask hits
write_IO("MTESt:SOURce CHANnel3");//mask test channel3
write_IO("MTESt:TEST ON"); //start mask test
write_IO("MTESt:COUNt:FSAMples?");//query the number of failed samples
Msk_hits2[read_IO(Msk_hits2, 15)]=0;//get the number of mask hits
write_IO("MEASure:CGRade:SOURce CHANnel1"); //measure Channel 1
write_IO("MEASure:CGRade:CROSsing?");//query the crossing percentage
Crss_pct1[read_IO(Crss_pct1,15)]=0;//get the crossing percentage
write_IO("MEASure:CGRade:ERATio? DECibel");//query the extinction ratio
Ext_rat1[read_IO(Ext_rat1,15)]=0;//get the extinction ratio
write_IO("MEASure:CGRade:SOURce CHANnel3"); //measure Channel 1
write_IO("MEASure:CGRade:CROSsing?");//query the crossing percentage
Crss_pct2[read_IO(Crss_pct2,15)]=0;//get the crossing percentage
write_IO("MEASure:CGRade:ERATio? DECibel");//query the extinction ratio
Ext_rat2[read_IO(Ext_rat2,15)]=0;//get the extinction ratio
stop = clock();
//display the results
printf("Channel 1:\n Mask hits:%s Crossing %%:%s Extinction Ratio:%s\n",
Msk_hits1,Crss_pct1,Ext_rat1);
printf("Channel 3:\n Mask hits:%s Crossing %%:%s Extinction Ratio:%s\n",
Msk_hits2,Crss_pct2,Ext_rat2);
return (stop-start); //return the total run time
return 1;
}//acquireParallel()

Other manuals for Agilent Technologies 86100C

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Agilent Technologies 86100C and is the answer not in the manual?

Agilent Technologies 86100C Specifications

General IconGeneral
BrandAgilent Technologies
Model86100C
CategoryTest Equipment
LanguageEnglish

Related product manuals