Chapter 3 Programming Your Universal Counter for Remote Operation

Programming Examples

To Use Limits to Filter Data Before Measuring Stats (QuickBASIC) (Continued)

PRINT "Status byte = ", statusbyte

CALL sendhp(":CALC3:AVERAGE:TYPE MIN;:CALC3:DATA?") 'Ask for all the stats CALL IOENTERS(source&, minimum, maxelem%, actual%)

CALL sendhp(":CALC3:AVERAGE:TYPE MAX;:CALC3:DATA?") CALL IOENTERS(source&, maximum, maxelem%, actual%) CALL sendhp(":CALC3:AVERAGE:TYPE MEAN;:CALC3:DATA?") CALL IOENTERS(source&, mean, maxelem%, actual%) CALL sendhp(":CALC3:AVERAGE:TYPE SDEV;:CALC3:DATA?") CALL IOENTERS(source&, sdev, maxelem%, actual%)

PRINT

 

PRINT "Minimum Period

= ", minimum

PRINT "Maximum Period

= ", maximum

PRINT "Mean Period

= ", mean

PRINT "Standard Deviation = ", sdev

RETURN

endprogram:

END

SUB sendhp (code$)

CALL iooutputs(source, code$, LEN(code$))

END SUB

3-84

Programming Guide

Page 152
Image 152
HP 132A, 53131A manual Print Minimum Period