I have to believe that someone has already figured this out, but I am a little bit stumped.
I am using WebVisu, and I want to display a time stamp from the Controller on a WebVisu screen. The time stamp in the controller is UTC, but I need to display this time as the local time, based on the timezone on the user's PC.
How do I do this? I am using Codesys 3.5 SP 15.
In the Oscat Basic library there is a function block called UTC_TO_LTIME that should be what you're looking for. It does allow for daylight savings time changes so you'll need to know if for a given timestamp if DST is active. Also in Oscat Basic is another function block called DST that will check for a given UTC if DST is active. It seems mislabelled in the documentation I have as DT2_TO_SDT.
Log in to post a comment.