LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Write to Measurement File time column wrong starting value

I am using Write tp Measurement File express VI.  I select to write one time column.  The values writtent in the time column start from a value that does not seem to correspond to anything in the program -- sometimes as much as 2-3 days before the saving begins.

Can I force the starting value  of time to something, or get it to write the time since we started saving, or something predictable?

0 Kudos
Message 1 of 9
(3,610 Views)
  • Include code whenever available.  Asking somebody to troubleshoot your software without any code is like asking your mechanic to fix your car without taking your car to him.

Source

 

I don't recommend using the Write Express VI.  I recommend using the File I/O primatives because they allow for much more control over what gets written and how.  Still I would expect the Express VI to be able to write time properly so I'd assume there is some kind of bug with the data being given to the function.  Post some code so we can see what is going on.

0 Kudos
Message 2 of 9
(3,606 Views)

Even compressed, the code is much too large to send and I would not expect someone to dig through my very large program.  I was hoping someone knew how to control the time column; there is no external connection or property that I can find.

0 Kudos
Message 3 of 9
(3,594 Views)

On top of what Hooovahh said, very few people actually use the express vi's.

 

I believe the Express vi's are for making quick and simple demo programs to show what LabView can do, like in the LabView "seminar" sales pitches.

 

They have no real use other than that, at least I have not found them useful for anything.

 

Use "Write to Spreadsheet File" or "Write Text File" to make a program that does exactly what you want it to do when you want it to do it.

 

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 9
(3,586 Views)
You can certainly post something. The Write to Measurement File records the time data that you pass to it so it is evidently wrong. You haven't even explained where the data is coming from. The phrase garbage in, garbage out ring a bell?
0 Kudos
Message 5 of 9
(3,582 Views)

@RTSLVU wrote:

 

They have no real use other than that, at least I have not found them useful for anything. 


The exception in my mind when discussing Windows programs (FPGA has some neat express VIs) is the Elapsed Timer VI, and possibly the File Dialog express VIs.  You will find those in my application, just not that often.  I also only view those as an Icon so it looks like a normal subVI.  Oh here is a neat function on your block diagram that takes up about 6 times as much space as a normal subVI isn't that nice?  

0 Kudos
Message 6 of 9
(3,575 Views)

Hi Hoard,

 

As stated above, Express VIs should be avoided when possible. They are meant for very simple, quick tasks and should not be used in large scale applications. It is very odd that the timestamp is off in the Express VI. However, you can use the Write to Spreadsheet File VI to write data to file with a timestamp. Please see the attached sample program for an example of how to do this.

0 Kudos
Message 7 of 9
(3,500 Views)

Of course, the reason to use the Express VI is that it handles things like writing the header, limiting the maximum file length and so on that have to be done by my program otherwise.  Since it is inclujded in Labview one expects it to work!

 

It appears that the reason for the time stamp problem is that something got changed in another routine that causes one of the waveforms to be empty and rather than an error, it picked up a bad t0 value.  As expected, ultimately the error is in my program and not the routine.

0 Kudos
Message 8 of 9
(3,467 Views)

@Hoard wrote:

As expected, ultimately the error is in my program and not the routine.


Glad to hear you discovered the problem.  In the future you can convert an Express VI into a normal SubVI, you can right click it and select Open Front Panel.  This will mean you need to save the VI, but this gives you the ability to write custom code, and see how the express VI works.  Usually this means really ugly code, and lots of nested VIs so tred lightly.

0 Kudos
Message 9 of 9
(3,463 Views)