LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Iterative reading from spreadsheet

Solved!
Go to solution

I have not been given the details yet, but have been asked to write a SCADA system in Labview with a capability I have never thought of before- they want the ability to load the created data files and re-create process runs.

 

I will be making a 1 Hz sampling system for them, but am not sure as to how many channels or run duration to get file size estimates.  I have included the basic idea I have for making an "instant replay" VI, but am not sure if there are better ways to handle the data in terms of memory optimization.  At what sized file should I become concerned?  Is there a better way?  Thank you!

Download All
0 Kudos
Message 1 of 3
(2,090 Views)
Solution
Accepted by topic author bgalfond

I would start to worry when the file size approaches the size of your available memory.  However, your code could be greatly simplified by using Read Delimited Spreadsheet to read the SCADA data and using a For loop to index the rows from the Spreadsheet file.  I used an indicator, "Show Row", but you probably should consider using a sub-VI to read and format the data from each row in an appropriate way.  The For loop will naturally exit when it processes all the rows -- if you want to stop early, add a Conditional Stop, as shown.

Simplified SCADA Replay.png

 

Bob Schor

Message 2 of 3
(2,047 Views)

Formatting should not be a problem, as I will be making the VI writing the file, so that should work well.  I had thought to use the while loop just because I was mimicking how the data file was created, the for loop does look much cleaner and I will try it that way, thank you!

0 Kudos
Message 3 of 3
(2,023 Views)