LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Time and date stamp

Solved!
Go to solution

Hello. I am trying to add a time/date stamp to my inputs to LV. There are some comments here that I went through but they didn't seem to fit my application. With each tick of the timer I am collecting 5 inputs. Whate I would like is for the final column to have a time/date stamp. I have tried using the Vi's which seem appropriate for this however, they dind't have the affect I had hoped. All I want is for each tick of the clock and a sample is collected, to have he time stamp corresponding to that data.

 

Thank you

0 Kudos
Message 1 of 21
(3,684 Views)

Do you have a sample of your code you could share?

 

It sounds like you have specific ticks that you know the time between, so you have a value for "dt". And I'm sure you can figure out a value for "t0", so with your data you could create a waveform. I think that's what you're looking for, but I would need more information to be sure.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 2 of 21
(3,672 Views)

@James.M wrote:

Do you have a sample of your code you could share?

 

It sounds like you have specific ticks that you know the time between, so you have a value for "dt". And I'm sure you can figure out a value for "t0", so with your data you could create a waveform. I think that's what you're looking for, but I would need more information to be sure.


I like the timestamp idea better because I think it would produce something that more accurately describes the data.  I think that it would be better to get actual time than calculated time.  (By "calculated" I mean using the desired the time period as a base by which to calculate the time.)

 

Maybe some of our gurus could weigh in with their thoughts?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 3 of 21
(3,657 Views)

@ceilingwalker wrote:

final column to have a time/date stamp


I missed that part of the post. So yeah, he just wants a seperate timestamp for each data point for some sort of table of info, or datafile. Either way, we need more information I think.

 

ceilingwalker, what's your end goal?

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 4 of 21
(3,649 Views)

A little digging and I found this previous post, which points towards just adding a timestamp directly to go with each data point collected.

 

ceilingwalker, use the Get Timestamp In Seconds VI each time you collect a data point. Format the timestamp in to a string that you want to log to file using Format Date/Time String, or Get Date/Time String.

 

You'll have to format your array of DBLs in to strings to go along with it, or write the data seperately, but that should be all of hte information you need to add timestamps to you data file.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 5 of 21
(3,642 Views)

The stamp I am looking for would be a real time clock, to stamp every time a sample is put on a spreadsheet. Thank you

0 Kudos
Message 6 of 21
(3,622 Views)

Yes, refer to my post above.

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 7 of 21
(3,619 Views)

Interesting.  If it's a realtime clock, maybe James' first idea would be better.  Or at least the idea of basing the times on multiples of the desired time period, if not creating an actual waveform.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 8 of 21
(3,612 Views)

I'm willing to put money on it, he doesn't mean Realtime real time. lol

Cheers


--------,       Unofficial Forum Rules and Guidelines                                           ,--------

          '---   >The shortest distance between two nodes is a straight wire>   ---'


Message 9 of 21
(3,607 Views)

I am having trouble trying to add the get date/time to the spreadsheat. I continually get a broken arrow.

0 Kudos
Message 10 of 21
(3,576 Views)