Siemens HMI Logging Cycle Reduce from 1 s to 100 ms in TIA Portal

David Krause12 min read
HMI / SCADASiemensTechnical Reference
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Siemens HMI Logging Cycle: Reduce from 1 s to 100 ms in TIA Portal

Reducing the HMI tag logging cycle from the default 1 s to 100 ms in TIA Portal is technically possible on most Comfort Panels and WinCC Runtime systems, but it carries severe penalties: CPU communication load, HMI scan-time degradation, and rapid exhaustion of the on-device log database. This reference walks through the exact configuration steps, the two separate cycle parameters you must change (acquisition vs. logging), the hardware-dependent entry limits, and the firm rules enforced in WinCC Unified V20 where 100 ms and 250 ms cannot be used for cyclic logging at all.

Overview: Two Independent Cycle Parameters

Engineers commonly confuse the acquisition cycle of an HMI tag with the logging cycle of a log. They are configured in different editors and serve different purposes:

Parameter Editor Location Effect Minimum (Comfort/Advanced) Minimum (Unified V20)
Acquisition cycle HMI Tags > Properties > Settings How often the HMI polls/refreshes the tag value from the PLC 100 ms 100 ms
Logging cycle Logs > Properties > Cycle How often a sampled value is written to the log database 1 s (cyclic mode) 500 ms (allowed), 100 ms and 250 ms explicitly blocked

To achieve sub-second logging, both values must be aligned. Setting the acquisition cycle to 100 ms while leaving the logging cycle at 1 s only refreshes the tag in memory; the log will still see 1 s samples.

Critical: In WinCC Unified V20, the cycles 100 ms and 250 ms are not permitted for cyclic logging, and no multiple of these values is allowed. The smallest cyclic logging cycle is 500 ms. Source: Siemens TIA Portal Help – Configuring Logging Tags (RT Unified).

Prerequisites

  1. Installed TIA Portal (V15.1 or later for Comfort Panels; V17 or later recommended for WinCC Unified; V20 for the V20 restriction set).
  2. Configured HMI device (TP1200 Comfort, TP1500 Comfort, or a WinCC Runtime PC station) connected to an S7-1200 / S7-1500 / S7-300 / S7-400 controller via PROFINET or MPI/PROFIBUS.
  3. An HMI tag already created (DB word, input word, or internal tag) and a configured data log.
  4. Engineering access to the HMI project on the engineering station (project write-protected lifted).
  5. For WinCC Unified: a Unified Comfort Panel (MTP700/1000/1200/1500/1900/2200) or Unified PC runtime.

Step-by-Step: Change the Acquisition Cycle to 100 ms (Comfort / Advanced)

Method 1 – Properties Pane

  1. Open the TIA Portal project and expand the HMI station in the project tree.
  2. Open HMI Tags and select the target tag (e.g., "MotorSpeed").
  3. Press Alt+Enter or open the Properties inspector.
  4. Switch to the Settings tab.
  5. Change Acquisition cycle from 1 s to 100 ms.
  6. Compile the HMI station (Right-click > Compile > Software (only)) and download to the panel.

Method 2 – Tag Table Grid View

  1. In the HMI tag editor, switch from the default detail view to the Show all tags grid view.
  2. Scroll the grid to the right until the Acquisition cycle column appears.
  3. Click the cell for the target tag and type 100 ms.
  4. Confirm with Enter and download the project.
Tip: To bulk-edit multiple tags, multi-select rows with Shift+Click or Ctrl+A and use the Properties > Settings multi-edit view. This is the recommended approach when a fast acquisition rate must be applied to a sensor array.

Step-by-Step: Configure the Logging Cycle

  1. Expand the HMI station > Logs in the project tree.
  2. Open (or create) the data log that contains the target tag as a logging tag.
  3. Select the logging tag inside the log and open Properties > Settings.
  4. Set Trigger to one of the three modes:
    • Cyclic – logged at fixed intervals; minimum 1 s on Comfort/Advanced.
    • On Change – logged only when the value changes by more than a configured delta.
    • On Demand – logged only when a script or function triggers the write.
  5. For Cyclic mode on Comfort/Advanced, enter the cycle in seconds (e.g., 1). For sub-second logging you must either change to On Change with a tight delta or use the LogTag function block.
  6. Compile and download.

Logging Modes and Their Effect on Effective Sample Rate

Mode Behavior Effective Sample Rate Use Case
Cyclic Writes one record per cycle = cycle parameter (1 s minimum on Comfort, 500 ms minimum on Unified) Trend logging, compliance archives
On Change Writes when the tag deviates by more than the configured delta since the last logged value Bounded by the acquisition cycle (100 ms floor) Process events, alarms, slow-changing analog values
On Demand Writes when a VBScript / function calls the log write User-defined, can be sub-cycle Recipe steps, operator-triggered snapshots

For 100 ms logging on Comfort Panels, the only viable configuration is Cyclic on the acquisition side at 100 ms + On Change on the logging side. If the source tag actually changes every 100 ms, the log will record one entry every 100 ms, which fills the log database extremely quickly.

Resource Impact and Performance Budget

When the acquisition cycle is reduced from 1 s to 100 ms, the HMI performs 10× as many reads. The following penalties apply:

  • Communication load: Each acquisition reads one or more variables from the PLC over PROFINET/MPI. With 50 tags at 100 ms, the panel issues 500 read requests per second. On a Comfort Panel with a 100 Mbit/s PROFINET port and an S7-1200, this can saturate the asymmetric S7 communication slot and increase PLC cycle time by 5–15 %.
  • HMI scan time: The script and tag-processing pass of the HMI runs longer. A Comfort Panel whose scan time drifts above 80 % CPU will begin to drop scheduled tasks (screen refresh, alarm acks).
  • Log database I/O: Writing 10 records per second to the internal SQLite store on a Comfort Panel is the upper limit of what the flash controller can sustain without wear-leveling thrashing.
  • Data loss risk: If the HMI scan cannot complete a log write before the next acquisition tick, the panel raises a LogOverflow event and the record is dropped silently.

Storage Capacity: The 20,000-Entry Hard Limit

Comfort Panels and most WinCC Runtime Advanced targets have a fixed log database of 20,000 entries per log on devices such as the TP1200 Comfort. The math is unforgiving:

Logging Rate Single Tag Duration 5 Tags, 1 Entry / Cycle 10 Tags, 1 Entry / Cycle
1 s 5 h 33 min 1 h 6 min 33 min 20 s
500 ms 2 h 46 min 33 min 16 min 40 s
100 ms 33 min 20 s 6 min 40 s 3 min 20 s

Formula: Duration (s) = 20,000 × Cycle (s) / Tags. For example, 10 tags at 100 ms: 20,000 × 0.1 / 10 = 200 s = 3 min 20 s. If you need a longer history window, you must either raise the cycle, reduce tag count, or export to a CSV/SQL database via a script.

Circular logging: TIA Portal supports circular logging, where the oldest entries are overwritten once the 20,000 entry cap is reached. Configure this under Log Properties > Mode > Circular log. The concept is documented generically for transactional databases in the ScienceDirect circular logging overview; on a Comfort Panel the overwrite is non-atomic and can corrupt up to one record during power loss.

LogTag Function Block: Programmatic Logging

The LogTag function block (found in the WinCC HMI libraries under Logs > Logging tags) lets you log a value from a script. Functionally, it writes a single record to the log the moment the block is evaluated, regardless of the cyclic / on-change settings. The block:

  • Accepts the log name, the tag name, and the value to log.
  • Is invoked from a VBScript on the HMI, typically on a scheduled task or on a tag value change event.
  • Allows sub-1 s logging on Comfort Panels because it is not bound to the 1 s minimum of the cyclic logging trigger.

Example VBScript on a Comfort Panel scheduled task (100 ms tick):

Sub Log_OnTime(ByVal Item)
  Dim val
  val = SmartTags("MotorSpeed")
  LogTag "ProcessLog", "MotorSpeed", val
End Sub

The LogTag call does not replace the cyclic log mode; it supplements it. The script path bypasses the 1 s cyclic floor, so 100 ms logging is achievable on a TP1200 Comfort as long as the resource budget permits.

Limitation: LogTag still costs one database write per call. The same 20,000-entry ceiling applies. With 10 tags invoked from a 100 ms script tick, you reach 100 records/s, exhausting the log in 200 s.

WinCC Unified V20: Where 100 ms and 250 ms Are Blocked

WinCC Unified (V17, V18, V19, V20) is the current-generation HMI runtime. Its logging architecture is centralized: the cycle is configured on the logging tag itself, not on a separate acquisition cycle alone. As of V20 documentation:

  • 100 ms and 250 ms are not permitted for cyclic logging.
  • Multiples of 100 ms and 250 ms (e.g., 200 ms, 300 ms, 400 ms) are also not permitted.
  • The valid sub-second cycles are 500 ms, then 1 s, 2 s, 5 s, 10 s, and so on.

On Unified, the only legal way to get below 500 ms is to use the On Change trigger with a small delta, or to script the write via the Unified JavaScript API:

let log = HMIRuntime.Logging.createLog("ProcessLog", "MyStorage");
log.addColumn("MotorSpeed");
setInterval(() => {
  const v = Tags("MotorSpeed").Read();
  log.write([v]);
}, 100);

On Unified Comfort Panels, the underlying SQLite store has a similar fixed capacity to Comfort Panels, so the 100 ms write rate from setInterval fills the log in minutes regardless of how the writes are triggered.

WinCC Runtime Professional: The Only Sustainable Sub-Second Logger

For applications that genuinely need 100 ms logging over hours, days, or weeks, the only Siemens-supported runtime with the necessary performance and storage is WinCC Runtime Professional (TIA Portal > WinCC Professional). Differences vs. Comfort/Advanced:

Aspect WinCC Runtime Advanced / Comfort WinCC Runtime Professional
Logging cycle (cyclic) 1 s minimum 500 ms minimum (WinCC Professional tags); 100 ms achievable via archive configuration
Log storage 20,000 entries cap on panel flash SQL Server / file archive; effectively unlimited
Concurrent fast tags Dozens before scan time suffers Hundreds to thousands
Recommended HMI hardware TP1200, TP1500, TP2200 Comfort WinCC Professional PC station, IPC547G, IPC1047, etc.

If the engineering requirement is "100 ms logging for a continuous shift on a machine tool," the design must include a Professional runtime, a SQL back end, and ideally a network-attached historian. Trying to force 100 ms logging on a Comfort Panel results in 15–20 minutes of usable history at best.

Diagnostic and Verification

  1. After download, open the panel's Log Viewer on the HMI.
  2. Verify the recorded timestamps. With a 100 ms cycle and 3 tags, expect entries spaced 100 ms apart with the same timestamp differing only by tick index.
  3. Open the HMI's Control Panel > Performance (or hmiruntimeinfo on Unified) and confirm the scan time is below 70 % of the configured cycle budget.
  4. Check the LogOverflow counter via the internal tag @LogOverflow; a non-zero value indicates dropped records.
  5. Cross-validate the HMI log with a parallel S7 trace or a Wireshark capture of the PROFINET frames to confirm the 100 ms cadence is real and not smoothed by the panel.

Troubleshooting Matrix

Symptom Likely Cause Action
Log shows 1 s entries despite 100 ms acquisition cycle Logging trigger is still set to Cyclic 1 s Change logging trigger to On Change with delta = smallest step, or use LogTag script
Tag value on HMI lags PLC by > 1 s Acquisition cycle still 1 s Open Tag > Properties > Settings and lower acquisition cycle to 100 ms
HMI scan time jumps to > 90 % after enabling 100 ms logging Too many tags at fast cycle Group tags: keep critical ones at 100 ms, move non-critical to 500 ms or 1 s
WinCC Unified rejects 100 ms cycle in validation 100 ms and 250 ms blocked in V20 Switch to 500 ms cyclic, or use On Change / script write
Log database reaches 20,000 entries and stops Sequential (non-circular) log Enable circular logging under Log Properties
Gaps in log timestamps (e.g., 100, 300, 500 ms) LogOverflow / scan-time overrun Reduce tag count at 100 ms, switch some to 500 ms, or move to WinCC Professional
PLC scan time increases when HMI logging at 100 ms PROFINET slot saturation by HMI reads Use Multiplexing or raise acquisition cycle to 250 ms for non-critical tags
LogTag script does not write records Log/column not configured, or log name typo Verify the log exists under Logs and that the column matches the tag name in the script

Recommended Best Practices

  1. Do not log at 100 ms on Comfort Panels unless the log duration is < 20 minutes. The on-device storage is the binding constraint.
  2. For longer history, move the log to WinCC Professional with a SQL back end. 100 ms sustained logging is only realistic on Professional.
  3. On WinCC Unified V20, accept 500 ms as the cyclic floor unless you switch to script-based writes. Trying to force 100 ms in the TIA Portal cycle picker will fail validation.
  4. Tag count > 50 at 100 ms is a code smell. Profile the HMI scan time; if it is > 70 %, the panel is saturated.
  5. Prefer On Change with a small delta over Cyclic for analog values that change slowly. This dramatically reduces both CPU and storage cost.
  6. Always enable circular logging unless a hard regulatory requirement demands a finite, append-only audit log.
  7. Document the cycle in the tag comment so future engineers know why a tag is at 100 ms and not the default 1 s.

FAQ

Can the Siemens HMI logging cycle be reduced below 1 s on a Comfort Panel?

Yes, but only by using the On Change trigger on the logging tag or by calling the LogTag function block from a VBScript scheduled at the desired rate. The Cyclic logging trigger has a hard minimum of 1 s on Comfort / WinCC Advanced panels.

What is the minimum cyclic logging cycle in WinCC Unified V20?

500 ms. The cycles 100 ms and 250 ms are explicitly not permitted for cyclic logging on Unified V20, and no multiple of these values is allowed either. The 100 ms rate can be obtained only by scripting the write, not by configuring the cycle parameter.

How many log entries does a TP1200 Comfort store?

20,000 entries per log. At 100 ms with a single tag, this fills the log in 33 min 20 s. With 10 tags at 100 ms, the log is exhausted in 3 min 20 s. Enable circular logging for continuous use.

Why does my TP1200 scan time spike after changing the acquisition cycle to 100 ms?

The HMI now issues 10× as many read requests to the PLC and performs 10× as many log writes. With 50+ tags at 100 ms, the panel can exceed 80 % scan time and start dropping log records. Reduce the number of fast tags or move to WinCC Professional.

When should I move from Comfort Panel to WinCC Runtime Professional?

Move when you need 100 ms logging for more than ~15 minutes, more than ~50 tags at sub-second rates, or a SQL/ historian back end. Comfort / Advanced panels are designed for short, operator-visible trends, not for long-term high-speed historian data.

Back to blog