MOULDLKnowledge BaseElectrical Knowledge Base3D Model DownloadsMembership
中文版Model Store »
Knowledge Base › Electrical Knowledge Base › How do you create and use watch tables in TIA Portal?
HomeModels
Table of contents

On this page

PLC & Programming (100 articles)

Quick Reference

  • PLC & Programming
  • Electrical & Electronic Basics (monthly)(每月更新中)
  • Electrical Control & Drawings (monthly)(每月更新中)
  • Drives & Actuators (monthly)(每月更新中)
  • Sensors & Detection (monthly)(每月更新中)
  • Industrial Communication & Networks (monthly)(每月更新中)
  • HMI & Host Systems (monthly)(每月更新中)
  • Industrial Robots & Motion Control (monthly)(每月更新中)
  • Mechatronic System Integration (monthly)(每月更新中)
  • Fault Diagnosis & Standards (monthly)(每月更新中)

How do you create and use watch tables in TIA Portal?

A watch table is the main online debugging tool in TIA Portal: it gathers the addresses, variables and status bits you care about into one table, shows their current values online, and lets you force or modify them when necessary. It answers the question "once the program is running, what state is this point actually in", which is far more efficient than staring at the program line by line.

How a watch table differs from a status table

A watch table lists variables as rows, showing address, format, monitor value, modify value and comment, and suits keeping an eye on a set of key points over time. A status table orders variables by program execution, showing the actual value and status within each scan, and suits tracking down sequential logic. Both work online, but for different purposes: use a watch table to find "the value is wrong", a status table to find "the sequence is wrong".

Steps to create a watch table

Open the Monitor and Force Tables folder in the project tree, add a watch table and name it; then enter addresses or symbolic names row by row, or right-click a variable in the program editor and choose to add it to a watch table so the address comes across automatically and typing errors are avoided. When creating the rows, keep straight whether you use absolute addresses or symbolic addressing: with symbols, renaming in the program affects the watch table, while absolute addresses are unaffected but less readable.

Setting the display format and comments

A row can switch between display formats such as binary, decimal, hexadecimal and floating point; binary reads best for status bits, decimal or float for analog values. A comment on each row stating what the point is for helps a great deal when several people debug together. Choosing the wrong format does not change the actual value, only makes the reading hard to interpret, so it is worth taking a moment to settle on consistent formats.

Online monitoring, modify values and force values

Once connected, click online and the table immediately shows the current value of each variable. To change an output or parameter temporarily you can write a modify value once, write it repeatedly over a set number of cycles, or use force to pin the point. The three differ in scope: monitoring is read-only, modify value affects addresses the program can write, and force has the highest priority and can override the program logic, which is exactly why it is the most dangerous — cancel it the moment you are finished.

Snapshots, trends and export

You can store a batch of current values as a snapshot and later compare it with fresh online values to see whether parameters have been altered, or open a trend view and plot analog or counter values as a curve to watch how they change. A watch table can also be exported as a table file for the record, which makes it easy to keep the key data from a debugging session for later review.

Common operations, their meaning and where to use them at a glance

OperationMeaningWhere to use itRisk
Online monitoringRead-only display of current valuesRoutine observationBarely any risk
Modify value (once)Written once, then the program takes overSetting a temporary setpointMay be overwritten at once by the program
Modify value (continuous)Re-written cyclicallyDebugging an analog setpointLeaves long-term interference if not cancelled
ForcePins a pin regardless of program logicVerifying actuator movementHighest priority, most dangerous
UnforceRestores normal program controlMust be done when debugging endsNeglecting it leaves a hidden hazard
SnapshotSaves a batch of current valuesBefore-and-after comparisonNeeds manual comparison
Trend viewPlots values as a curveWatching dynamic changeSampling interval is limited
Export tableSaves to a file for the recordDebug record and handoverContains addresses, mind confidentiality
Switch display formatChanges the presentationStatus bits and analog valuesDoes not change the actual value

Notes

The contents of a watch table are saved with the project, and editing the program without a backup may lose them; it is worth naming the debugging tables clearly and keeping them separately. Online monitoring and modification require a connection to the CPU, set up the same way for real hardware and a simulated CPU. When several people debug one CPU, agree in advance on how force and modify values are used so you do not interfere with one another.

References

The conventions for variables, data types and online access in PLC programming languages follow GB/T 15969.3 (identical to IEC 61131-3); the electrical safety preconditions around monitoring and forcing, and the electrical connection, protection and earthing of the equipment, follow GB 5226.1 and the equivalent international standard IEC 60204-1. The exact function names and menu paths are as stated in the manufacturer's manual.

Points to watch

⚠️ Three common traps:
(1) Forgetting to unforce when debugging ends, so an output stays pinned and the program can no longer control that point;
(2) Using force instead of modify value to verify a movement, overriding the program logic and causing a mechanical collision;
(3) Believing that switching the display format changes the value, and changing the basis of a decision for nothing.

Online monitoring and modification may only be carried out by personnel with the necessary rights and under controlled conditions, and any forcing that affects moving mechanisms must wait until the machine is stopped and no one is in the danger zone. Before debugging ends, check every forced point and clear them all, keeping a record.

Related reading

Related 3D models: Ready to build it? Download free 3D models & CAD drawings at MOULDL »
MOULDL · Electrical Knowledge Base · free self-study reference for electrical & automation engineers, 3D CAD models at MOULDL