Resolving UTC and Timezone Synchronization Offsets for PCS 7 DBA and OPC Alarms in WinCC
A persistent time difference (such as a 4 hour 30 minute offset) between CPU 410-5H alarms and OPC tags integrated via PCS 7 Database Automation (DBA) in WinCC occurs due to conflicting UTC versus Local Time base configurations. Native S7-400 CPUs transmit alarms timestamped in coordinated universal time (UTC), which WinCC converts to local display time. If an external OPC server transmits timestamps already adjusted for local time or an incorrect Windows timezone, WinCC re-applies the local timezone offset, causing double-offset errors. To fix this: configure the external OPC server and DBA station to transmit pure UTC timestamps, verify Windows timezone and daylight saving settings, and harmonize the AlarmControl time base properties in @alarmnew.pdl.
Table of Contents
- Executive Summary
- Architecture and Fundamental Mechanics
- Step-by-Step Implementation Procedure
- Verification
- Limitations and Operational Precautions
- Engineer FAQ
- Technical References
- Related Articles
- Related Tags
Executive Summary
In hybrid process architectures where SIMATIC PCS 7 supervises both native SIMATIC controllers (CPU 410-5H) and third-party subsystems via PCS 7 Database Automation (DBA) or OPC DA/UA, consistent event timestamping is vital for chronological alarm auditing and root cause analysis. Commissioning engineers frequently encounter an anomaly where alarms from native S7-400 controllers display the correct local time, but alarms originating from DBA-imported OPC tags show a fixed negative offset (e.g., lagging by 4 hours and 30 minutes) in the WinCC alarm view (@alarmnew.pdl). This divergence arises from mismatched time base handling between the OPC source, the Windows operating system timezone, and WinCC Alarm Logging runtime conversion.
Architecture and Fundamental Mechanics
Timestamp processing across distributed PCS 7 networks operates through precise architectural layers:
-
Native PCS 7 AS Timestamping: Standard PCS 7 controllers (S7-400, CPU 410-5H) maintain their system clocks in Coordinated Universal Time (UTC) via central time synchronization (e.g., NTP or SICLOCK). When an
ALARM_8Pblock triggers, the AS attaches an absolute UTC timestamp. WinCC receives the UTC timestamp and, using the OS Client's Windows timezone setting, dynamically converts it to Local Time for operator display. -
The PCS 7 DBA Architecture: PCS 7 DBA (Database Automation) integrates third-party PLCs, package units, and OPC servers into the PCS 7 OS. DBA generates tag structures and alarm configurations in the WinCC CS database. When external OPC tags generate alarms, the timestamp is dictated by the OPC Server's timestamping mode.
-
The Root Cause of Time Skew: If the third-party OPC server applies its local PC timezone before sending timestamps to WinCC, or if the OPC server's host clock has an incorrect timezone offset (such as UTC+4:30), a conflict occurs:
- If WinCC expects UTC and applies the local timezone offset to an alarm that was already in local time, the timestamp shifts.
- If the WinCC AlarmControl (@alarmnew.pdl) has its internalTimebaseproperty set to UTC while the external tag is tagged with a local timestamp containing a 4.5-hour timezone bias, the displayed time will be exactly 4 hours and 30 minutes slower than expected. -
WinCC AlarmControl Timebase Property: The WinCC AlarmControl object in
@alarmnew.pdlpossesses aTimebaseproperty configurable to:Local Time Zone of Server,Local Time Zone of Client, orCoordinated Universal Time (UTC). Inconsistent timebase definitions between native and DBA message classes result in visual discrepancies.
Step-by-Step Implementation Procedure
To harmonize alarm timestamps across native AS and DBA OPC sources, execute the following configuration steps:
-
Verify AS Controller Time of Day:
- In SIMATIC Manager Component View, right-click the CPU 410-5H and selectPLC -> Set Time of Day.
- Verify that the Module time matches UTC time and that synchronization is configured via the central plant clock. -
Configure External OPC Server Timestamping Mode:
- Open the configuration interface of the third-party OPC server providing the DBA tags.
- Locate the timestamping setting. Ensure the OPC server is configured to deliver timestamps in UTC, not Local Time.
- Verify that the host PC running the OPC server has its Windows clock and timezone configured accurately. -
Inspect DBA Project Settings:
- OpenPCS 7 DBA.
- Open the target controller or OPC source properties.
- Under theAlarmsorTime Synchronizationsettings, confirm that the time base is explicitly set toUTC.
- Recompile the DBA project to update the WinCC Tag Management and Alarm Logging databases. -
Configure WinCC AlarmControl in Graphics Designer:
- In WinCC Explorer on the Engineering Station, open Graphics Designer.
- Open@alarmnew.pdl(and@alarm.pdl).
- Select theWinCC AlarmControlobject and open its Properties.
- Navigate to theTime Baseproperty tab.
- EnsureTime Baseis set toLocal Time of Client(or harmonized toUTCif plant policy requires uniform UTC logging across all consoles).
- Save the PDL and download changes to the OS servers.
Verification
Verify alarm timestamp alignment across all subsystems:
-
Simultaneous Alarm Test: Trigger a test alarm simultaneously from the native CPU 410-5H and from the DBA OPC source.
-
Alarm List Audit: Open the incoming alarm list (
@alarmnew.pdl) on a WinCC OS Client. Confirm that both alarms display identical timestamps within millisecond tolerances, with zero hours or minutes of offset. -
Short-Term Archive Verification: Inspect the WinCC Alarm Logging archive table. Verify that underlying stored timestamps are recorded in absolute UTC across all message blocks.
Limitations and Operational Precautions
Never attempt to correct timezone offsets by artificially altering the Windows system clock on individual PC clients, as this will corrupt SQL Server historical data archiving, WinCC Redundancy synchronization, and SIMATIC Logon audit trails. All PCs and AS controllers in a PCS 7 plant must synchronize to a single authoritative central NTP time master.
Engineer FAQ
Why is the time difference exactly 4 hours and 30 minutes?
4 hours and 30 minutes is the standard offset for specific time zones (such as UTC+4:30 in Iran/Afghanistan). If an OPC server or PC host was configured in that timezone while WinCC expected UTC, the full 4.5-hour offset is manifested in the alarm list.
Why do faceplate tags show the correct time while the alarm list is offset?
Real-time tags in faceplates are evaluated cyclically based on current PC client time when displayed. Alarms, however, carry historical timestamps generated at the source and processed through WinCC Alarm Logging's timebase conversion.
What is the recommended timebase for PCS 7 systems?
Siemens strongly mandates UTC for all AS controllers, OS servers, and database archives. Conversion to local time should only occur visually at the WinCC client display layer.
Can DBA automatically convert local OPC timestamps to UTC?
DBA expects the underlying OPC source to adhere to the OPC DA/UA standard, which mandates UTC. If the source transmits local timestamps, the OPC server configuration must be adjusted to disable local pre-conversion.
Does changing the AlarmControl timebase require compiling the OS?
No. Adjusting the Timebase property in @alarmnew.pdl is a graphic configuration change; it only requires saving the picture and downloading graphics or updating the picture cache.
Technical References
- SIMATIC PCS 7 Time Synchronization System Manual
- SIMATIC PCS 7 DBA (Database Automation) Configuration Manual
- WinCC V7.5 Alarm Logging Configuration Manual
Related Articles
- Central NTP and Legacy System Services Time Synchronization in PCS 7 V8.1
- Configuring 1 ms High-Precision Time Stamping with ET 200SP HA and DTS 4138S
- Troubleshooting Named Connection Disconnects on Standby/Partner WinCC OS Servers After Restart
Related Tags
- Time Synchronization
- DBA
- OPC DA
- Alarm Logging
- UTC
- CPU 410-5H