LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Datalogging application

Solved!
Go to solution

Im working on a datalogging app that looks at the signal from a load cell for 10s, calulates the max, min, and average values of the data acquired during the 10s then writes this data to a spreadsheet file along with the start time, and stop time. I also want to write data immediatly if two succesive data points are greater than 5% of eachother. Im mostly having trouble figuring out how to write the header to the spreadsheet. I want the end result to be like this.

 

 

spreadsheet.jpg

 

this is what im getting

 

spreadsheet2.jpg

0 Kudos
Message 1 of 6
(2,759 Views)

I modified my VI, now its formatted correctly but the data gets rounded to whole numbers when i convert it into a string. Is there a way around this?

 

spreadsheet3.jpg

0 Kudos
Message 2 of 6
(2,753 Views)

Use Number to fractional string instead of number to decimal string.


CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
Message 3 of 6
(2,744 Views)

@.:aCe:. wrote:

Use Number to fractional string instead of number to decimal string.


thanks. Everything looks fine now. One more thing, how can i modify my program to write the data to the file as its availabe instead of writing the array all at once?

0 Kudos
Message 4 of 6
(2,732 Views)
Solution
Accepted by topic author http

I think its probably better the way you are doing it right now as you are only accessing the disk just once. Storing it in array would be typically be RAM, so this would be faster.

But if writing data as it is available is your requirement, try the example (C:\Program Files\National Instruments\LabVIEW 2011\examples\file\smplfile.llb\Write to Text File.vi) which ships with LabVIEW.

 

 

 


CLA CTAChampionI'm attending the GLA Summit!
Subscribe to the Test Automation user group: UK Test Automation Group
Message 5 of 6
(2,727 Views)

@.:aCe:. wrote:

I think its probably better the way you are doing it right now as you are only accessing the disk just once. Storing it in array would be typically be RAM, so this would be faster.

But if writing data as it is available is your requirement, try the example (C:\Program Files\National Instruments\LabVIEW 2011\examples\file\smplfile.llb\Write to Text File.vi) which ships with LabVIEW.

 

 

 


 

That makes sense, ill just leave it like it is.

0 Kudos
Message 6 of 6
(2,713 Views)