GxDmmSetTriggerMode

Purpose

Sets the trigger mode

Syntax

GxDmmSetTriggerMode (nHandle, dwTriggerMode, dwCountOrInterval, pnStatus)

Parameters

Name
Type
Comments
nHandle
SHORT
Handle for a GX2065 board.
dwTriggerMode
DWORD
Returns the measurement in terms of digits of resolution.
0.  GXDMM_TRIGGER_CONTINUOUS – The DMM will take readings as fast as possible. Measurements can be read by calling GxDmmRead or GxDmmReadEx (get the measurements from the DMM as fast as possible without buffering).
1.  GXDMM_TRIGGER_TIMER – A programmable timer is used to trigger a measurement. The timer period in seconds is passed in using the dwCountOrInterval parameter.
2.  GXDMM_TRIGGER_EXTERNAL – The PXI Bus is used to trigger a measurement
3.  GXDMM_TRIGGER_SOFTWARE – A Software Trigger will trigger a measurement
4.  GXDMM_TRIGGER_ARRAY – Trigger a continuous burst of measurements and store them in the onboard buffer memory. The measurements can be retrieved at a later time by calling GxDmmReadArray. The number of measurements is specified in the dwCountOrInterval parameter.
dwCountOrInterval
DWORD
Specify the number of measurements to take when in Trigger Array mode or specify the Timer Rate in seconds if in Trigger Timer mode. If another Trigger Mode is selected, this parameter is ignored.
pnStatus
PSHORT
Returned status: 0 on success, negative number on failure.

Comments

The Trigger Reading mode determines the trigger source used to initiate a measurement.

When using the Trigger Array trigger mode, call GxDmmReadArray to retrieve the measurements after they have been completed. GxDmmGetReadArrayStatus can be used to check on the status of measurement array operation (if it has completed or not). Any pending measurement operation can be cancelled by calling GxDmmAbortReading.

Use GxDmmSetExternalTriggers to configure PXI Trigger Line, PXI STAR trigger and LINK triggers when setting the trigger mode to GXDMM_TRIGGER_EXTERNAL.

GXDMM_TRIGGER_ARRAY mode is applicable only be the following measurements functions:

2.       GXDMM_FUNCTION_VAC_AC_CPL – Voltage AC, AC Coupled Mode

3.       GXDMM_FUNCTION_IAC_AC_CPL – Current AC, AC Coupled Mode

4.       GXDMM_FUNCTION_VAC_DC_CPL – Voltage AC, DC Coupled Mode

5.       GXDMM_FUNCTION_IAC_DC_CPL – Current AC, DC Coupled Mode

Example

The following example sets the trigger mode to continuous:

 

SHORT nHandle, nStatus;

 

GxDmmSetTriggerMode (nHandle, GXDMM_TRIGGER_CONTINUOUS, 0, &nStatus);

 

See Also

GxDmmGetTriggerMode, GxDmmSetExternalTriggers, GxDmmGetExternalTriggers, GxDmmReadArray, GxDmmGetReadArrayStatus, GxDmmAbortReading, GxDmmSetRange, GxDmmGetRange, GxDmmSetFunction, GxDmmGetFunction, GxDmmGetErrorString