LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Most efficient way to extract the amplitude of a signal and display on an intensity graph

Hi All,

I am having difficulty to display the amplitude of an voltage signal (voltage picked up by NI DAQ card).

what I am trying: Voltage signal (Dynamic data type)--> 2D array of dynamic data type (using 2 nested for loops) --> normal 2D array with scalar values --> intensity graph

I have difficulty to convert the dynamic 2D array to scalar 2D arry.

I only want to extract the amplitude of the imcoming signal.. any body can give some advice? thanks in advance..


Charlie
0 Kudos
Message 1 of 4
(3,165 Views)
Hi Charlie,
 
Have you tried using the Amplitude and Levels Express vi? It is located in the Functions Palette»Programming»Analog Waveform»Waveform Measurements»Amp & Level.
Regards,

Hillary E
National Instruments
0 Kudos
Message 2 of 4
(3,141 Views)
Hi Hillary,

Thanks for your reply. 🙂

Yes, I did tried to use Amplitude and Levels Express vi, it should be the one I am looking for, but I found it not work in my case, I need to put the value of amplitudes into a 2D array.

If I use
Amplitude and Levels Express vi, it will give me a 3D array, I have found the solution, just convert the dynamic data to single scalar. (see pic attached)



Anybody can help me to solve the following 2 problems:

1. The speed of this program is too low, i think ii due to the DAQ assistant in the 2 for loops (for creating 2D array), it should be able to re-write using DAQmx (as "centerbolt" told me), I am working on this now, if anybody can help, I will appreciate that.

2. Is there any other way to creat the 2D array (for purpose of increasing speed also).

Thanks,

Charlie
0 Kudos
Message 3 of 4
(3,124 Views)
Hi Charlie,
 
1. You can create the DAQmx code from your DAQ Assistant by right clicking on the DAQ Assistant and select Generate NI-DAQmx Code. You might still need to modify some of the to your exact application. (You might find context help (Ctrl+H) useful.)
 
2. You can also create arrays using the Array Palette (in the Functions»Programming Palette). There is a lot in LabVIEW help as well (Help»Search the LabVIEW Help...»Index Tab» array or arrays. You might to particularly look at "arrays, inserting elements programmatically".
Regards,

Hillary E
National Instruments
0 Kudos
Message 4 of 4
(3,106 Views)