How Power Varies With Wavelength - Agilent Technologies 8163A Programming Manual

Lightwave multimeter lightwave measurement system lightwave multichannel system
Hide thumbs Also See for 8163A:
Table of Contents

Advertisement

How Power Varies with Wavelength

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <visa.h>
/* function prototypes for this examples*/
/* function for a simple error handling explained in example 1 */
void checkError(ViSession session, ViStatus err_status );
void main (void)
{
ViStatus
ViSession
/
ViSession
ViChar
ViChar
ViReal64 wavelength; /* used to hold the wavelength of the tunable laser source */
ViReal64 wavelength_max; /*used to hold the maximum wavelength of the tunable
laser source*/
ViInt32 i;
ViInt32 cmdDone;
errStatus = viOpenDefaultRM (&defaultRM);
if(errStatus < VI_SUCCESS)
{
printf("Failed to open VISA Resource manager\n");
exit(errStatus);
}
errStatus = viOpen (defaultRM, "GPIB::20::INSTR", VI_NULL,VI_NULL,&vi);
Agilent 8163A Lightwave Multimeter, Agilent 8164A Lightwave Measurement System, & Agilent 8166A Lightwave Multichannel
System, Third Edition
How Power Varies with
Wavelength
This example shows how the measured power depends on wavelength.
Install a Power Sensor in Slot 1 and a Tunable Laser Source in Slot 2 and
connect the Tunable Laser Source output to the Power Sensor input,
before executing this example.
errStatus;
/* returned error code from visa call */
defaultRM;
/* default visa resource manager variable*
vi;
/* current session handle */
replyBuf[256]; /*buffer holding answers of the instrument */
c;
/* used in the keyboard wait loop */
/* loop counter */
/* return value for OPC command */
VISA Programming Examples
147

Advertisement

Table of Contents
loading

This manual is also suitable for:

8164a8166a

Table of Contents