That example unfortunately does not work well with some measurement types. Specifically with a capacitance measurement, it takes some time for the DMM to configure properly to take accurate capacitance measurements. We can avoid this problem by having multiple "blocks" of tests. Each block is dedicated to a measurement type. In this example, a top-level VI calls into subsequent blocks (Resistance and Capacitance). Each block opens/closes a new session to the DMM/Switch. Each block performs hardware-timed DMM/Switch Handshaking.
This example could be made more robust by implementing a for loop around the SubVI and passing an array of clusters (the cluster element has all of the SubVI device and channel information).
NI LabVIEW 2012 (or compatible)
NI DMM (4065,4070,4071,4072 and others)
NI Switch (compatible with the NI-Switch driver)
Steps to Implement or Execute Code
Open both niSwitch DMM Switch Handshaking copies and configure DMM and Switch parameters in the respective SubVIs
Open Main VI (or NI DMM Multiple Measurement Types&Scanning 2012 NI Verified.vi contained in the .zip file) and execute.
To add more measurement types, simply add more copies of the SubVI to the sequence
Additional Information or References
Main VI Block Diagram
niSwitch DMM Handshaking C SubVI Front Panel
niSwitch DMM Handshaking C SubVI Block Diagram
**This document has been updated to meet the current required format for the NI Code Exchange.**