This article applies to:
This sample demonstrates a live drawing of an AnalogIn waveform. To run the sample, wire an Analog Output to an Analog Input.
The experiment uses the AnalogOutLoadWaveform method to create a Sine wave that is looped back to the selected AnalogIn channel. For example, if AnalogOut 2 is wired to AnalogIn 2, then 2 would be selected during the StartupInfo parameters.
The Sine wave is played at 3.83Hz so it can be easily seen on screen. The Amplitude and Offset are set to 0.5 so that it remains centered on screen around virtual ground. Since the Output source will not be greater than 3.3V, Analog Output 2 is used as the default for greater precision (as Analog Input 1 has a protection diode).
If the frequency is changed in the experiment, the horizontal seconds per division will need to be adjusted as well.
NOTE: AnalogOutWaveForm is a function of the AnalogOut. Please see the Chronos Operator Manual for more information.