Adding Additional Settling Time
- 업데이트 날짜:2025-11-20
- 1분 (읽기 시간)
Some applications, such as high temperature or vibration measurements, may require additional settling time to acquire accurate measurements.
Setting the Settling Time
You can change the default settling time of a switch by using the niSwitch Property Node or the niSwitch_SetAttributeViReal64 function and NISWITCH_ATTR_SETTLING_TIME attribute.
In LabVIEW:
- Add the niSwitch Property Node to the block diagram.
- Click the property node and select Module Characteristics»Settling Time.
- Right-click the Settling Time property and select Change to Write.
- Right-click the Settling Time property and create a constant.
- Set the constant to the amount of time (in seconds) to wait for settling.
In C:
- Create a new ViSession named switchSession using the niswitchinit function.
- Create a ViReal64 variable named settlingTime and set the value to the desired new settling time in seconds.
- Call the function niSwitchCheckErr(niSwitch_SetAttributeViReal64(switchSession, VI_NULL, NISWITCH_ATTR_SETTLING_TIME, settlingTime));
Note If you set the settling time of a switch module below the default
settling time, NI-SWITCH coerces the value to the default settling time.
Checking the Settling Time
You can check the default settling time of a switch by using the niSwitch Property Node or the niSwitch_CheckAttributeViReal64 function and NISWITCH_ATTR_SETTLING_TIME attribute.
In LabVIEW:
- Add the niSwitch Property Node to the block diagram.
- Click the property node and select Module Characteristics»Settling Time.
- Right-click the Settling Time property and create an indicator.
In C:
- Create a new ViSession named switchSession using the niswitchinit function.
- Create a ViReal64 variable named settlingTime. Its value in seconds will be returned in the next step.
- Call the function niSwitchCheckErr(niSwitch_GetAttributeViReal64(switchSession, VI_NULL, NISWITCH_ATTR_SETTLING_TIME, &settlingTime));