Example Code

Graphing Multiple Waveforms to a Single Waveform Graph

Code and Documents

Attachment

This Vi demonstrates how to add more than one waveform to the same Waveform Graph.

Through the usage of a for loop and a shift register, the waveform graph is updated once every second with a new graph 15 times.

Each graph is a sine wave created with a random frequency (0-5) and a random amplitude (0-5).

Front Panel

WaveformGraph_MultipleData_LV86_FP.PNG

Block Diagram

WaveformGraph_MultipleData_LV86_BD.PNG

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Ben Sisney
FlexRIO V&V Engineer
National Instruments
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Comments
StephenB
Active Participant
Active Participant
on

i would suggest just auto indexing the for loop. wouldnt need the array constant, the shift registers, or the build array. and you could move the waveform graph indicator out of the loop that way

Stephen B
Contributors