LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Export digital table to excel

Hi,

 

I wrote a code where I read U16 numbers from a FIFO and write it to a digital table. I would like to save the data to excel for further processing. But when I right click on the table and try to export, the "export data to excel" option is grayed out. The only two option available are "export simplified image" which is of no use to me, and "export data to clipboard". How do I export to excel? If I can not, how do I access the data in clipboard and maybe copy from there to excel?

 

Thanks,

Anindya

0 Kudos
Message 1 of 5
(2,978 Views)

You could save it as a text file that you can open in excel using the write to spreadsheet.vi.

0 Kudos
Message 2 of 5
(2,974 Views)

Microsoft Excel does not know about the LabVIEW data format called "Digital Data".  How did you want these data to be saved to Excel?  Were you wanting to save the 16-bit unsigned integers aa (say) multiple rows of a single column?  Were you wanting to save 16 columns of booleans representing each bit of the U16 entries as rows?  Once you decide what the Excel file should look like, you can figure out how to write the U16 array of data (just don't convert it to a format that Excel doesn't recognize before trying to write it).

 

BS

Message 3 of 5
(2,944 Views)

Hi Bob,

 

thanks for the reply. I would like to store each column of data seperately. This U16 number represents data from 16 channels, interleaved. After storing it to somewhere I would do some conversion i.e. digital to analog conversion and check FFT for signal distortion. Is that possible? If not, how can I access the data from clipboard and save it somewhere?

0 Kudos
Message 4 of 5
(2,925 Views)

I've attached a snippet of one possible way to proceed.

Create Digital Array.png

As you can see, I "made up" data (an array of I16) that has 5 numbers.  The For loop converts it into an array of bits -- the first function makes an array of 16 booleans, the Reverse 1D array puts the least-precision bit on the right (for ease of viewing -- you probably should omit this, but it "looks funny" when you examine the output array) and the last function turns it into 0's and 1's.  What comes out is an array of 16 columns and 5 rows, all with 0 or 1 as entries.  Such an array is easily written to Excel.

 

You mentioned something about D/A conversion -- are these bits the "raw bits" from a streaming A/D converter?  Usually A/D converters, at least those with which I am familiar, give you, say, an array of I16 values at each sample point, so if you had a 16-channel A/D converter running at, say, 1KHz, you'd get an array of 16 I16's every millisecond.  If you wanted to do an FFT on, say, Channel 0, you'd isolate the initial column of the 2D array resulting the sampling (1000 points/second) and hand that to your FFT routine.

 

BS

0 Kudos
Message 5 of 5
(2,849 Views)