Chapter 3 Programming Your Universal Counter for Remote Operation
Elements of SCPI Commands
Programming Guide
3-97
To Optimize Throughput (Turbo C) (Continued)
sendhp(":ROSC:SOURCE INT"); /* Use internal oscillator. If
you want to use an external
timebase, you must select it
and turn off the automatic
detection using:
:ROSC:EXT:CHECK OFF */
sendhp(":DIAG:CAL:INT:AUTO OFF"); /* Disable automatic interpolater
calibration. The most recent
calibration values are used in
the calculation of frequency */
sendhp(":DISP:ENABLE OFF"); /* Turn off the counter display */
sendhp(":HCOPY:CONT OFF");
sendhp(":CALC:MATH:STATE OFF"); /* Disable any post processing */
sendhp(":CALC2:LIM:STATE OFF");
sendhp(":CALC3:AVER:STATE OFF");
sendhp("*DDT #15FETC?"); /* Define the Trigger command. This
means the command FETC? does not
need to be sent for every
measurement, decreasing the
number of bytes transferred over
the bus */
sendhp(":INIT:CONT ON"); /* Put the counter in Run mode */
sendhp("FETCH:FREQ?"); /* Fetch the frequency to be */
IOENTER(ctr,&exp_freq); /* for the expected frequency */
strcpy(destination,":FREQ:EXP1 "); /* Copy string */
sprintf(&destination[strlen(destination)],"%e",exp_freq); /* Append
expected frequency value */
sendhp(destination); /* Send the expected frequency */
/* This number must be within 10%
of the Ch 1 input frequency.
Using this greatly increases
throughput, but is not
recommended for signals that
change by more than 10% */
puts("Transferring and processing data\n");
for (i=1; i<=readings ;i++)
{
IOTRIGGER(ctr); /* Trigger the counter and */
IOENTERS(ctr,freq[i],&length); /* read the data */
}
printf("Measurement complete. Press a key to continue.\n");
getch();
}
Summary of Contents for 53131A
Page 1: ...Programming Guide HP 53131A 132A 225 MHz Universal Counter ...
Page 2: ......
Page 13: ...1 1 Before You Start ...
Page 24: ...Chapter 1 Before You Start Related Documentation 1 12 Programming Guide ...
Page 25: ...2 2 Command Summary A Quick Reference ...
Page 68: ...Chapter 2 Command Summary RST Response 2 44 Programming Guide ...
Page 69: ...3 3 Programming Your Universal Counter for Remote Operation ...
Page 167: ...4 4 Command Reference A Dictionary ...
Page 310: ...Chapter 4 Command Reference WAI Wait to Continue Command 4 144 Programming Guide ...
Page 311: ...5 5 Errors ...
Page 329: ......
Page 330: ...H Manual Part Number 53131 90044 Printed in U S A NOVEMBER 1996 ...