LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Fill excel file with FFT data

Hi people !

 

I have trouble for fill spreadsheet with data who come from my vi.

The aim is to see on excel the same graph than my VI graph FFT.

 

Despite my search impossible to find a working method to do that.

Join to this post, spreadsheet with my raw data after record.

 

FFT graph view :

Capture.JPG

 

VI view :Capture.JPG

 

See you very soon !

0 Kudos
Message 1 of 10
(6,489 Views)

Hi P1GOU1, 

Here is a simple VI that get the FFT from a waveform and load it into a CSV file (you can just select your file as you want depending if you have the repport generation toolkit or not). 

Here is the result: 

FFT2Excel.png

fft4Excel.PNG

If you are french and using a french version of Excel, here are some points you might strugle with:

the separator is a ; not a , 

the point in floating number doesn't work, we need a comma. [Ctrl-h] to find every point and replace with a comma worked perfectly on my side. 

 

Best regards,

A. CAILLOT

0 Kudos
Message 2 of 10
(6,437 Views)

@caillotantoine wrote:

Hi P1GOU1, 

Here is a simple VI that get the FFT from a waveform and load it into a CSV file


You probably want to use the actual f0, and df to generate the frequency (x) values of the first column.

0 Kudos
Message 3 of 10
(6,435 Views)

Indeed, it depends on the waveform. However, in this case, it is not needed and the frequency is already correct. (sinewave at 440Hz is already found at 440Hz). 

0 Kudos
Message 4 of 10
(6,433 Views)

It's impossible for me to view correctly my graph in excel with your method 😞

 

My waveform is a periodic square signal, of 1Hz (signal of test).

0 Kudos
Message 5 of 10
(6,414 Views)

Hi P1GOU1, 

may you show us your result and your code? 

 

Thanks, 

Antoine

0 Kudos
Message 6 of 10
(6,397 Views)

Hi !

Here my code :

 

Capture.JPG

 

And, my datas results in attached file.

Ty Antoine !

0 Kudos
Message 7 of 10
(6,385 Views)

Hi P1GOU1, 

I had a look, it doesn't seem so wrong. 

By the way, I advice you to use the FFT power spectrum in Waveform>Analog Wfm>Measurements. 

here is my code (in 2012 format, I don't know your LabVIEW version) and my result.

Best, 

Antoine

 

fft2excel.png

 

Download All
0 Kudos
Message 8 of 10
(6,380 Views)

You can see graph fft on excel with your results ?

 

If you can, could you show me ?

0 Kudos
Message 9 of 10
(6,372 Views)

Hi Antoine !

Ok the problem for see my graph was in Excel setup, it's ok now ty.

 

My aim now is to save higher fft harmonic (frequency and magnitude) for each acquisition in Excel spreadsheet in two column, so one line by acquisition.

 

But i'm big noob for generation report.

0 Kudos
Message 10 of 10
(6,363 Views)