LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to correctly get timestamp on compactRIO?

Solved!
Go to solution

I'm trying to log time for each data point I write to a text file on a cRIO-9056 using LV2020. However, after formatting the timestamp the hours and minutes aren't making much sense. I thought by going into MAX and setting the time on the cRIO and saving it would fix any sort of time issue? Using format into string gives me 24hr time, but the minutes don't match up? Weird

 

Code

crio time code.png

Values displayed

crio time values.png

 

cRIO time settings in MAX

max time settings.png

0 Kudos
Message 1 of 3
(1,123 Views)

Ok sorry, I just caught the issue with the minutes. I was using lower case and that was the month of the year lol. But that still doesn't explain why after formatting the time I get 5pm instead of 10am?

0 Kudos
Message 2 of 3
(1,121 Views)
Solution
Accepted by topic author David99999

Alright, it was something really simple and stupid. I changed the time in NI MAX and saved it, but I still needed to restart the cRIO in order for the changes to take affect. Everything is good now. Leaving this here in case someone stumbles onto this in the future 🙂

 

max time settings 2.png

0 Kudos
Message 3 of 3
(1,096 Views)