I am experiencing a 5-hour time sync issue between a B&R PLC and an Ignition Perspective Gateway. Initially, a specific "Trigger Timestamp" tag was showing a 5-hour offset. To "fix" this, the HMI clock on the PLC was manually adjusted by 5 hours. While this made that specific tag value look correct, all other tags being logged to the Historian and plotted on XY Charts are now 5 hours off.
Im assuming this is because the timestamp from OPC is still using the PLC actual time no the offset set by the HMI. The problem is I have no other way of access to the PLC program. Is there a way to adjust this within Ignition perspective or the gateway?
I'm not sure how your "Trigger Timestamp" tag is configured. If its value is being read from the PLC, I'm not sure why the timestamp for that has a different offset than the other tags on the PLC. Are you reading the value of that tag differently than you are the other tags?
In 8.3, you can configure the preferred timestamp source, which may or may not be useful depending on how much you care about the source timestamp. OPC UA Connections | Ignition User Manual
Let me lay out the background first off.
I am using 8.3.(w/e)
Hitting the Project button, then go to Project Properties, then under “Project” go to “Designer” it will give you “Timezone Behavior”. I have mine set as “Gateway Timezone”.
Under “Perspective Property Editor” when you hit the webpage linker button for page configs, my gateway timezone is “Etc/UTC”.
I am using a tag “Current_Time” that pulls the direct time from the gateway itself:
{[System]Gateway/CurrentDateTime}
Which is 5 hours ahead of my actual time on EST. Normally the Gateway should be pulling the time from your “Server/System/W/E” itself. I am using Ubuntu Server (Something something 2026(not worried about what it is but you get the jist)), with my UI_Time set as UTC and my local time set correctly to my current timezone.
From all of this! i get to where we need to be. i pull direct information from sql using the getdate() (Which this is sql server timeYes i know) i’ve had to pull data from an ORacle server as well and to do that properly i need to know the current time, turn it into oracle time and then use that to match against my query.
So from all of the playing around and trying to point myself to the correct time (And changing all of the timezone stuff through the gateway/local server/forcing designer) my best way to actually get the correct timer… was the addHours(now(0), -5) as an expression.
TLDR;
use expressions to set time makes life easy, gateway/server gets wonky depending on who sets up your server/what rights you have to correct time servers.