IMDTouchKnowledge BaseShop main store

Troubleshooting

Why a WinCC Professional Button Does Not Write to the PLC

HMI and touchscreens Published 7 min read

Short answer

A pressed button proves only that the screen handled the pointer event. Diagnose in order: the Professional runtime connection, the tag binding, then the command duration — a bit set on press and reset on release can be shorter than the tag's 2-second default update cycle, so the PLC never observes it. The fix is to let PLC logic clear the request after evaluating it.

On this page
  1. What the pressing button actually proves
  2. Check the runtime connection first
  3. Follow the tag from button to PLC memory
  4. Why the write can vanish between press and release
  5. Timing a 2-second tag cycle against a press-and-release pulse
  6. Stop the PLC from consuming or overwriting the command
  7. Pass/fail checks in order
  8. Questions asked

A WinCC Professional button that visibly presses but never changes the PLC bit is a write-path fault, not a graphics fault. Work it in one order: first the Professional runtime's connection to the controller, then the tag binding from the button event to PLC memory, then the duration of the command itself — a bit set on press and reset on release can be shorter than the tag's default 2-second update cycle, so the controller never observes it. The fact that the same screens work in a WinCC Advanced project proves the PLC logic; it proves nothing about this runtime's connection, because a connection is a project resource and two projects never share one.

What the pressing button actually proves #

The press animation is local runtime feedback. It proves the screen object received the pointer event; it does not prove that the runtime resolved the HMI tag, reached the controller, or completed the write. The red circle proves only that its appearance condition evaluates false. Establish one test path before touching the button again: monitor the mapped PLC variable online, and put a numeric display of that same variable on the screen. Pick a variable that PLC logic does not continuously overwrite during the test.

Observation while testing What it proves Next step
HMI display follows a PLC-side change Read path and tag binding work Test the write event
PLC value changes, circle stays red The circle's tag or expression is wrong Fix the animation binding
Neither reads nor writes Connection or endpoint fault Check the runtime connection
Write appears only on a long hold Pulse shorter than the update cycle Remove the release reset

Check the runtime connection first #

A running controller simulation and a running runtime screen prove nothing about each other. In a simulation setup on TIA Portal V21, each participant — the simulated controller, the Professional runtime, and the process simulation driving the conveyor — must target the same simulated controller through the same computer interface and addressing.

  1. Open the connection the HMI tags use and confirm it names the controller you are actually running — in a simulation setup, the simulated one, not a physical CPU.
  2. Confirm the affected tags actually use that connection, not one left over from an earlier edit.
  3. Compile the HMI project and read the compile output for tag or connection errors.
  4. Restart the runtime after changing connection data, so the running runtime loads the rebuilt configuration.

If the runtime reports it cannot reach the controller at all, work through Fix WinCC Professional runtime not connecting to the S7-1500 before anything else. A different failure — the runtime command staying disabled rather than failing silently — has its own cause, covered in Why the WinCC V13 Professional runtime command stays disabled.

Do not carry conclusions over from the Advanced project because the screens look identical. Visually identical objects can reference different tags on different connections.

Follow the tag from button to PLC memory #

The binding is the complete mapping: button event to HMI tag, HMI tag through a connection to the PLC variable. A correct-looking tag name proves nothing if its connection, address, or data type differs.

  1. Open the button's press event and write down the exact HMI tag it writes.
  2. Open that tag and verify its connection, the PLC variable it maps to, and a Boolean-compatible data type.
  3. Open the circle's animation and write down the tag and expression that decide red versus green.
  4. Decide deliberately whether the button and the circle use one variable or separate command and status variables; do not inherit the choice from a copied screen.
  5. Keep numeric displays of the command and status values on screen during commissioning — color conditions hide mistakes that numbers show.

Two errors account for most "button dead, circle red" reports: the button writes a command tag while you monitor an unrelated status bit, and the circle is bound to a state no PLC logic ever sets. If green is meant to say running, PLC logic must produce that bit; it will not appear merely because the runtime started.

Why the write can vanish between press and release #

WinCC event and script writes are asynchronous. Scripted writes such as SetTagChar() queue the operation and return immediately, and the value transfers during subsequent cycle processing. The tag's update cycle is set on the tag itself in the HMI tag configuration, and its default is 2 seconds.

Now the pulse: the press event sets the bit and the release event resets it. A normal tap finishes well inside one 2-second cycle, so the set and the reset are both pending before the tag's next cycle. Whether the controller ever observes a 1 then depends on queue order you do not control, and even a brief 1 can fall between the PLC's observation points. The deterministic fix is not faster pressing — it is a longer command: delete the release reset, let the request stay set, and let PLC logic clear it after evaluating it. That is the request-and-acknowledgment handshake: the HMI latches a request, the PLC detects it, acts on its permissives, and clears the request or raises a separate acknowledgment the circle can display.

Timing a 2-second tag cycle against a press-and-release pulse #

Inputs: the tag's update cycle is 2 s, the documented default set on the tag; the press event sets the bit at t = 0 s; the release event resets it, and a normal tap releases inside the first cycle; for a guarantee, count on queued values becoming available at cycle boundaries — 2 s, 4 s, 6 s.

Rule in words: a command is guaranteed observable at the controller only when the bit stays set across at least one full cycle boundary; measure the hold in whole cycles.

Arithmetic:

  • Hold of one cycle: 2 s. The set and the reset are both pending at the 2 s boundary. No guaranteed window.
  • Hold of two cycles: 2 s + 2 s = 4 s. The set is available at the 2 s boundary, the reset cannot arrive before the 4 s boundary, and the guaranteed window is 4 s − 2 s = 2 s of a set bit at the controller.
  • A PLC scan cycle is orders of magnitude shorter than 2 s, so one full window is always caught by the program and by online monitoring.

Result: press the start button and hold it for 4 s — two default cycles.

Decision: if the bit appears in the controller on the 4 s hold but not on a normal tap, connection and binding are good and event duration is the fault — remove the release reset and hand the reset to PLC logic. If the bit never appears even on a 4 s hold, return to the connection and binding checks. The rule scales with your configured cycle: hold for two full cycles. One safety note: a latched start command is a real machine start, so do the maintained-command test on the bench or with actuators isolated.

Stop the PLC from consuming or overwriting the command #

A valid write can still look ineffective when the program writes the same variable every scan. Search the whole program for every assignment to the command variable — sets, resets, moves, initializations, sequence actions — by cross-referencing the variable, not by reading only the rung you expect to consume it. Keep the roles separate:

  • The HMI latches a request.
  • PLC logic decides from permissives whether to act.
  • A status variable reports the result.
  • The circle binds to that status or to the acknowledgment, never to the request — a circle driven by the request shows green even when the start command was rejected.

When the write target is shared with a physical input, the same symptom has its own cause, covered in Why an HMI button press dies in RUN mode on a shared input.

Pass/fail checks in order #

  1. Connection: change the monitored PLC variable from the PLC side. Pass when the HMI numeric display follows without navigating away or restarting anything.
  2. Binding: force or toggle the mapped variable. Pass when the numeric display and the circle both react according to the configured expression.
  3. Duration: press the button and hold 4 s, two default cycles. Pass when the variable is 1 at the controller for the whole hold.
  4. Reset ownership: with the release reset deleted, PLC logic clears the request after evaluating it, and the next press works the same way.
  5. Status: the request produces the PLC acknowledgment, and the circle follows that status rather than the request.

Work the list top to bottom and stop at the first failure; every check below it is meaningless until the one above passes.

Questions asked

Why does the same screen work in WinCC Advanced but not in Professional?

Because the working Advanced project proves the PLC logic only. Its connection, tags and runtime are separate project resources, and nothing in the Professional project inherits them. Open the connection the Professional tags actually use and verify it names the controller you are running — in a simulation setup, the simulated one — then compile the HMI project and restart the runtime.

How long should I hold the button to test whether the write works?

Hold it for two full tag update cycles. With the 2-second default that is 4 seconds: the set becomes available at the first 2-second boundary and the reset cannot arrive before the second, giving the controller a guaranteed 2-second window to observe the bit. If the bit appears on the long hold but not on a normal tap, event duration is the fault.

Should the button reset the bit on release?

No. Hand the reset to PLC logic: let the program detect the request, evaluate permissives, and then clear the request or raise an acknowledgment. Resetting on release makes the command length depend on operator press time and tag timing, which is exactly the race that makes the write disappear.

Why does the circle stay red when the runtime and the PLC both run?

Because red only means the circle's appearance condition evaluates false. Usually the animation is bound to a status bit that no PLC logic ever sets — for example a project-started state — or to a different variable than the one being monitored. Bind the circle to a status or acknowledgment variable the PLC actually produces, and verify it with a numeric display.

Where is the tag's update cycle set, and can it be changed?

It is a property of the HMI tag in the tag configuration, and the default is 2 seconds. Cycles that drive regularly repeated runtime actions can also be defined as your own in the Cycles editor. Whatever cycle you configure, the test rule scales with it: hold the button for two full cycles.

Keep reading

  • Troubleshooting

    Why an HMI Writes the Wrong PLC Value Above 9

    When an HMI display and its PLC register agree up to 9 but the PLC then reads 16 for a setting of 10, 25 for 19 and 32 for 20, the HMI tag is encoding BCD into a binary register. Set the tag data type to Signed Int 16, download, and step through the full range to confirm both numbers match.

    HMI and touchscreens

  • Troubleshooting

    Why an HMI Macro PLC Tag Is Missing From the PLC Program

    Only the second quoted string in a macro line is a candidate PLC tag, and it resolves against the HMI Address Tag Library, which maps the name to a controller address. Unquoted names are macro-local variables that never reach the controller. If no HMI unit sits in the data path, trace the real consumer from the controller's cross-reference and Ethernet client list.

    HMI and touchscreens

  • Troubleshooting

    Stop a PanelView Timed Write Corrupting SLC Clock Registers

    The PanelView's time-status write transmits a two-digit year, so S:37 drops from 2006 to 6 after every update. Point the time and date status tags at an integer file and let ladder logic add 16#2000 to the year before moving the set into S:37 through S:42, or clear the tag entries on the Status Tags tab of the Terminal Setup dialog to stop the write completely.

    HMI and touchscreens