Programming Examples

3. Frequency Profiling

Frequency profiling visualizes frequency variations for a certain time. This program gives an output file called:

PROFILE.DAT. If this file is imported to a spreadsheet program, such as Excel, you can create a graph like the one in the figure below.

Figure 4-2This figure is the results of frequency profiling on a sweep generator.

#include

“decl.h”

#include

<stdio.h>

#include

<process.h>

#include <string.h>

main ()

 

{

 

int

Counter, i;

char

ArmString[80],

InString[80];

double

ArmDelay;

FILE

*ofp;

if (ofp = fopen(“PROFILE.DAT”, “w”)) { Counter = ibfind(“DEV10");

/*Enable arming, etc.*/

ibwrt(Counter, “:TRIG:COUN 1; :ARM:COUN 1", 25);

4-16 ‘C’ for National Instruments PC-IIA, Frequency Profiling

Page 56
Image 56
Fluke PM6681R, PM6685R manual 16 ‘C’ for National Instruments PC-IIA, Frequency Profiling, File, Ofp