From 11:00 PM CST Friday, Apr 11th - 1:30 PM CST Saturday, Apr 12th, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabWindows/CVI

Content Type
Programming Language
Current manual

TDMS_CreateStrainGageScalingInfo

TDMS_CreateStrainGageScalingInfo

int TDMS_CreateStrainGageScalingInfo (TDMSAnyHandle handle, TDMSStrainGaugeConfig configuration, double poissonRatio, double gageResistance, double leadWireResistance, double initialBridgeVoltage, double gageFactor, double voltageExcitation, int inputSource, int *scaleID);

Purpose

Creates strain gage scaling information for one or more channels. Strain is the amount of deformation of a body due to an applied force. Specifically, strain is the fractional change in length.

Once scaling information has been created for a channel, TDMS_GetDataType will report the type of the channel as TDMS_Double and TDMS_GetDataValues will return the scaled data values. The read functions in the Advanced Synchronous and Asynchronous I/O class will still return the unscaled data values.

(Linux) This function is not supported.

Parameters

Input
Name Type Description
handle TDMSAnyHandle A file, channel group, or channel handle. The scaling information is stored as properties of the specified file, channel group, or channel.

If you pass a channel handle, the scaling information will apply only to that channel. If you pass a channel group handle, the scaling information will apply to all channels in that channel group. If you pass a file handle, the scaling information will apply to all channels in that file. If scaling information has been created at multiple levels, the scaling information at the most specific level will take precedence. For example, scaling information on a channel will take precedence over scaling information on the containing channel group or the containing file.
configuration TDMSStrainGaugeConfig The bridge configuration for the strain gages.
Value Description
TDMS_StrainGageConfigFullBridgeI Full Bridge I
TDMS_StrainGageConfigFullBridgeII Full Bridge II
TDMS_StrainGageConfigFullBridgeIII Full Bridge III
TDMS_StrainGageConfigHalfBridgeI Half Bridge I
TDMS_StrainGageConfigHalfBridgeII Half Bridge II
TDMS_StrainGageConfigQuarterBridgeI Quarter Bridge I
TDMS_StrainGageConfigQuarterBridgeII Quarter Bridge II
poissonRatio double The ratio of lateral strain to axial strain in the material you are measuring.
gageResistance double 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 also must be the same as the nominal gage resistance. Refer to the sensor documentation to determine this value.
leadWireResistance double The amount of resistance, in ohms, in the lead wires. Ideally, this value is the same for all leads.
initialBridgeVoltage double The output voltage of the bridge, in volts, in the unloaded condition. This function 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.
gageFactor double Specifies 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.
voltageExcitation double The amount of excitation, in volts, that the sensor requires. Refer to the sensor documentation to determine this value.
inputSource int The scale ID representing the scaling information that will be applied before the scaling information added by this function is applied. Pass -1 if no scaling information should be applied first. When you pass -1 the scaling information added by this function will replace any existing scaling information for the specified file, channel group, or channel.

You can use this parameter to combine multiple scales to create a compound scale. You do this by passing the value of the scaleID output parameter from one scaling function as the value of the inputSource input parameter of another scaling function.
Output
Name Type Description
scaleID int A scale ID representing the scaling information created by this function. If you passed a value other than -1 for the inputSource parameter, then this scale ID represents the cumulative scaling information represented by that parameter plus the scaling information created by this function.

You only need this value if you want to pass it as the value of the inputSource parameter to another scaling function. If you do not need this value you can pass NULL for this parameter.

Return Value

Name Type Description
status int Return value indicating whether the function was successful. Unless otherwise stated, zero represents successful execution and a negative number represents the error code.

Error codes are defined in cvi\include\cvitdms.h.

Additional Information

Library: TDM Streaming Library

Include file: cvitdms.h

LabWindows/CVI compatibility: LabWindows/CVI 2013 and later

© 2016 National Instruments. All rights reserved.

Was this information helpful?

Help us improve your future ni.com experience.

What are you trying to do?

Submit