DAQmxCreateAIStrainGageChan

NI-DAQmx C Functions

DAQmxCreateAIStrainGageChan

int32 DAQmxCreateAIStrainGageChan (TaskHandle taskHandle, const char physicalChannel[], const char nameToAssignToChannel[], float64 minVal, float64 maxVal, int32 units, int32 strainConfig, int32 voltageExcitSource, float64 voltageExcitVal, float64 gageFactor, float64 initialBridgeVoltage, float64 nominalGageResistance, float64 poissonRatio, float64 leadWireResistance, const char customScaleName[]);

Purpose

Creates channel(s) to measure strain and adds the channel(s) to the task you specify with taskHandle.

Parameters

Input
Name Type Description
taskHandle TaskHandle The task to which to add the channels that this function creates.
physicalChannel const char [] The names of the physical channels to use to create virtual channels. You can specify a list or range of physical channels.
nameToAssignToChannel const char [] The name(s) to assign to the created virtual channel(s). If you do not specify a name, NI-DAQmx uses the physical channel name as the virtual channel name. If you specify your own names for nameToAssignToChannel, you must use the names when you refer to these channels in other NI-DAQmx functions.
If you create multiple virtual channels with one call to this function, you can specify a list of names separated by commas. If you provide fewer names than the number of virtual channels you create, NI-DAQmx automatically assigns names to the virtual channels.
minVal float64 The minimum value, in units, that you expect to measure.
maxVal float64 The maximum value, in units, that you expect to measure.
units int32 The units to use to return the measurement.
Name Description
DAQmx_Val_Strain Strain
DAQmx_Val_FromCustomScale Units specified by a custom scale. Use customScaleName to specify a custom scale.
strainConfig int32 The strain gage bridge configuration.
Value Description
DAQmx_Val_FullBridgeI Four active gages with two pairs subjected to equal and opposite strains.
DAQmx_Val_FullBridgeII Four active gages with two aligned with maximum principal strain and two Poisson gages in adjacent arms.
DAQmx_Val_FullBridgeIII Four active gages with two aligned with maximum principal strain and two Poisson gages in opposite arms.
DAQmx_Val_HalfBridgeI Two active gages with one aligned with maximum principal strain and one Poisson gage.
DAQmx_Val_HalfBridgeII Two active gages with equal and opposite strains.
DAQmx_Val_QuarterBridgeI Single active gage.
DAQmx_Val_QuarterBridgeII Single active gage and one dummy gage.
voltageExcitSource int32 The source of excitation.
Value Description
DAQmx_Val_Internal Use the built-in excitation source of the device. You must use voltageExcitVal to specify the amount of excitation.
DAQmx_Val_External Use an excitation source other than the built-in excitation source of the device. You must use voltageExcitVal to specify the amount of excitation.
DAQmx_Val_None Supply no excitation to the channel. You cannot use this value if the sensor requires excitation.
voltageExcitVal float64 The amount of excitation, in volts, that the sensor requires.
gageFactor float64 The sensitivity of the strain gages and relates the change in electrical resistance to the change in strain. Each gage in the bridge must have the same gage factor. Refer to the sensor documentation to determine this value.
initialBridgeVoltage float64 The bridge output voltage in the unloaded condition. NI-DAQmx subtracts this value from any measurements before applying scaling equations. Perform a voltage measurement on the bridge with no strain applied to determine this value.
nominalGageResistance float64 The resistance, in ohms, of the gages in an unstrained position. Each gage in the bridge must have the same nominal gage resistance. The resistance across arms of the bridge that do not have strain gages must also be the same as the nominal gage resistance. Refer to the sensor documentation to determine this value.
poissonRatio float64 The ratio of lateral strain to axial strain in the material in which you measure strain.
leadWireResistance float64 The amount, in ohms, of resistance in the lead wires. Ideally, this value is the same for all leads.
customScaleName const char [] The name of a custom scale to apply to the channel. To use this parameter, you must set units to DAQmx_Val_FromCustomScale. If you do not set units to DAQmx_Val_FromCustomScale, you must set customScaleName to NULL.

Return Value

Name Type Description
status int32 The error code returned by the function in the event of an error or warning. A value of 0 indicates success. A positive value indicates a warning. A negative value indicates an error.