06-18-2009 05:10 AM
I collect measurement values in equal time intervals starting from some time. I would like to present them on the StripChart. Each point on the StripChart should be marked on the X-axis by the time stamp expressed in Coordinated Universal Time. Therefore, I made up, that when I get the first measurement I get also the current UTC time and set the X-axis offset on this time and the gain on the value of the interval. Unfortunately, I don’t know how to get the current UTC time in the format accepted by the function which sets the offset?
Solved! Go to Solution.
06-18-2009 12:22 PM
If you're using CVI 9.0 or later, there are several functions in the Programmer's Toolbox that allow you to convert between several time formats (look for "Time Conversions" in the function tree). I'm not sure which format you currently have, but the format that you need to have is UIL Time. This is the format returned by the GetCurrentDateTime function in the UI Library (which unfortunately is in local time, so you can't use it).
If you have an older version of CVI, then you'll need to obtain the individual time elements from your UTC representation, and then build a UIL Time using the MakeDateTime function.
Luis
06-18-2009 12:28 PM