LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Analog Input NI 9225

hello everybody 
I need your help please

If you please can any one give me a code to show the network waveform

I'm working on NI cRIO-9063 with NI 9225 to present the network sinusoidal waveform

I tried to use (the analog input - getting started - scan mode example in the example finder) to show the sinusoidal waveform of the electrical network (as Oscilloscope) I tried many ways but useless 
the network waveform was as in the figure below ...

 

test.PNG

0 Kudos
Message 1 of 8
(2,740 Views)

What is a "network waveform"?

 

You've got some issues with your code, you seem to be reading from some variables 1 sample at a time. What rate are you scanning the data and putting into those variables (I assume a RIO is set for scan mode?) and what is the frequency of your waveform?

 

If you want to measure sine waves, you need to be acquiring at least several times faster than the frequency of the wave, and perhaps even 10 times or more faster.  You need to capture the data as a series of points or a waveform where the time between the points is consistent, and send that data over to your VI doing the display as an array, not at a single point at a time based on some slow scan engine clock.  You should be looking at DMA FIFO transfers.

 

If you had a attached your entire project and VI files, it would be easier to help rather than just a screenshot of a relatively simple VI.

0 Kudos
Message 2 of 8
(2,711 Views)

thank you for reply 

 

I mean by "network waveform" the electrical grid which is 220Vrms and 50Hz

yes it's set for scan mode and this is an example in the labview example finder

indeed yes i wanna measure sine waves, but how can i acquire several times faster than the wave frequency ??? "send that data over to your VI doing the display as an array, not at a single point at a time based on some slow scan engine clock. --- how can I do that ?"

I tried to attach the project but there is a problem , if you please you can see this project in the example finder "analog input-getting started-scan mode" and here another pictures for the whole code ,,, thank you in advance 
test1.PNG

0 Kudos
Message 3 of 8
(2,658 Views)

Do you know how fast the scan engine is?  For a 50 Hz signal, you probably want to acquire at around 500 Hz.  I really doubt the scan engine is that fast.  I can't tell from your chart since there is no timing information on it, but since it looks like a triangle wave, I'd say you are no faster than 100 Hz, and perhaps slower than that.

 

Try looking at the example called Streaming Data (DMA).  That acqures data on the FPGA at a higher rate, then transfers that to your user interface VI through a DMA FIFO.

 

As for your actual code, I don't know why you couldn't attach.  You should have been able to put it into a zip file and attach that.  (A real .zip,  not .7z or .rar or any other formats.)

0 Kudos
Message 4 of 8
(2,623 Views)

thanks a lot for your answer and following 
I solved the problem by adjusting the scan period in the scan engine and I got the sinusoidal waveform >>> I will attach the code as zip file 

but I have another question if you please how can I use this signal as input in multi-resolution analysis express VI (MRA-DWT)  since this VI deals with signal (waveform DBL) and the signal is analog which reads a data continuously one by one ! do you have a solution ?

 

0 Kudos
Message 5 of 8
(2,585 Views)

I didn't even try if I can use MRA-DWT express VI in RT or not 
I will try it and let you know

0 Kudos
Message 6 of 8
(2,579 Views)

@Mohammed86 wrote:

thanks a lot for your answer and following 
I solved the problem by adjusting the scan period in the scan engine and I got the sinusoidal waveform >>> I will attach the code as zip file 

but I have another question if you please how can I use this signal as input in multi-resolution analysis express VI (MRA-DWT)  since this VI deals with signal (waveform DBL) and the signal is analog which reads a data continuously one by one ! do you have a solution ?

 


I have no idea what that even means.

0 Kudos
Message 7 of 8
(2,559 Views)

have you ever used the advanced signal processing ?

0 Kudos
Message 8 of 8
(2,532 Views)