GxDmmGetACMath

Purpose

Gets the AC function math type

Syntax

GxDmmGetACMath (nHandle, pdwMathType, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle for a GX2065 board.
pdwMathType
PDWORD
Gets the math function applied the raw measurement in any of the AC measurement functions.
  1. GXDMM_AC_MATH_RMS – Sets the AC math type to RMS (root mean square).
  2. GXDMM_AC_MATH_AVG – Sets the AC Math type to Average. This math operation will take the average (arithmetic mean) of all the DAQ samples taken.
  3. GXDMM_AC_MATH_PP – Sets the AC math type to Peak to Peak. The DMM will return the difference between the largest value recorded and the smallest value recorded.
  4. GXDMM_AC_MATH_PKAMP – Sets the AC math type to Peak amplitude. The DMM will return the absolute maximum value recorded (positive or negative) subtracted by the arithmetic mean.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

When the DMM is in any of the AC functions (VAC AC Coupled, VAC DC Coupled, IAC AC Coupled, or IAC DC Coupled), an internal DAQ is used to acquire up to 8192 samples of data at up to 2MS/s. A math operation (from the types listed above) is applied to the samples to generate a final measurement result. Use the GxDmmSetACMinFrequency function to set the lowest expected frequency.

Example

The following example sets the AC math type to RMS:

 

SHORT nHandle, nStatus;

DWORD dwACMathType;

GxDmmGetACMath (nHandle, &dwACMathType, &nStatus);

 

See Also

GxDmmSetACMath, GxDmmSetACMinFrequency, GxDmmGetACMinFrequency, GxDmmGetAutoRange, GxDmmSetFunction, GxDmmGetFunction, GxDmmSetRange, GxDmmGetRange, GxDmmGetErrorString