Overview
This example dynamically updates the sample rate of the analog input and output tasks through the use of an external clock source.
Description
The external clock source, in this case, is an onboard counter. A possible modification of the code would be to fix the Samples to Read input of the DAQmx Read to 1/10th of the sample rate in order to simplify the UI and reduce the chance of buffer overflow and timeout errors. For quick testing specify, Using AI0 as your input physical channel, AO0 as your output physical channel and Ctr0 as your Clock.
Requirements
- LabVIEW 2012 (or compatible)
- NI-DAQ 12.0 (or compatible)
Steps to Implement or Execute Code
- Select the device or physical Channels you pick.
- Enter the sample parameters such as minimum and maximum value and sample rate.
- Run the program
Additional Information or References
VI Snippet
**This document has been updated to meet the current required format for the NI Code Exchange.**