Exporting Tags from AS to OS via 'Compile OS' (Transfer AS/OS Connection Data) Offline Prior to Physical Commissioning
In SIMATIC PCS 7 and Step 7 with the AS-OS Engineering option, tags and alarms configured in the Automation Station (CFC charts and DBs) can be completely compiled and transferred into the WinCC OS Server database without establishing any physical network connections to the PLC hardware. By configuring the AS hardware and CFC logic in SIMATIC Manager and executing the 'Compile OS' (Transfer AS/OS Connection Data) wizard with the 'Entire OS' option selected, the engineering station compiles the AS symbol table, block attributes (such as 'S7_m_c := true'), and message structures entirely offline into the local WinCC CS project file (.mcp), enabling complete graphics design and tag simulation before physical hardware arrives.
Table of Contents
- Mechanism of Offline AS-OS Tag and Message Transfer
- Prerequisites for AS-OS Compilation Without Physical Controllers
- Step-by-Step Procedure: Transfer AS/OS Connection Data Wizard
- Simulating Transferred Tags in WinCC Prior to Site Commissioning
- Comparison of Compilation Scopes (Entire OS vs Changes Only)
- Verification
- Limitations and Operational Precautions
- Engineer FAQ
- Technical References
- Related Articles
- Related Tags
Mechanism of Offline AS-OS Tag and Message Transfer
A foundational feature of the totally integrated SIMATIC PCS 7 engineering environment is the automated propagation of process data from the controller layer to the operator visualization layer. In traditional SCADA systems, engineers must manually export CSV tag files from the PLC and import them into the HMI database, creating high risks of typographical errors and address mismatches.
In PCS 7, this integration is executed by the AS-OS Engineering package through the Compile OS utility. The compiler reads the compiled CFC charts, data blocks, and symbol tables residing in the Step 7 project database on the Engineering Station (ES) hard drive. It translates block parameters possessing the S7_m_c (S7 Operator Control and Monitoring) attribute directly into WinCC tag management structures, creates alarm definitions in WinCC Alarm Logging, and configures archive parameters—all completely offline without sending a single telegram to physical controllers.
Prerequisites for AS-OS Compilation Without Physical Controllers
Before executing the offline AS-OS transfer, the following engineering prerequisites must be completed inside the SIMATIC Manager project on the ES:
- Hardware Configuration: The S7-400 / CPU 410 station must be configured in HW Config, and the hardware must be saved and compiled (
Save and Compile). An IP address and subnet mask must be assigned to the communication interface. - CFC Chart Generation: CFC charts containing standard or APL library blocks (e.g.,
MotL,VlvL,MonAnL) must be created. Any custom blocks must haveS7_m_c := trueassigned to the block and target I/O pins. - CFC Chart Compilation: The CFC charts must be compiled on the ES using menu Chart > Compile > As Program. This generates the internal S7 data blocks (DBs) and symbol addresses within the offline offline program container.
- NetPro Connection: An S7 Connection must be configured between the WinCC application in the PC Station and the S7-400 CPU in NetPro.
Step-by-Step Procedure: Transfer AS/OS Connection Data Wizard
To transfer tags into the WinCC OS project offline:
- In SIMATIC Manager Component View, right-click the target WinCC OS Station object and select Compile (or select the Multiproject and choose PLC > Compile and Download Objects).
- In the introductory screen of the 'Compile OS' wizard, click Next.
- Select the target OS and click Next.
- In the 'Select the network connection' dialog, choose the configured S7 connection (e.g.,
Named connectionorIndustrial Ethernet). - In the 'Select the S7 programs' window, verify that the checkboxes for all required AS controllers are selected.
- Under 'Scope', select Entire OS (required for the initial offline build) and check With memory reset.
- Under 'Data to be compiled', select Tags and messages and Picture Tree.
- Click Compile. The compiler will generate WinCC tag groups, raw data tags for alarm logging, and structure tags inside the WinCC
.mcpdatabase.
Simulating Transferred Tags in WinCC Prior to Site Commissioning
Once the compilation finishes, the engineering team can design graphic displays, configure faceplates, and simulate plant operations long before controller hardware is powered on:
- Tag Management Verification: Open WinCC Explorer on the ES. Navigate to Tag Management > SIMATIC S7 Protocol Suite > Named Connections. Verify that tag groups matching the AS hierarchy contain all process values (
.PV_Out,.Command,.Status1). - S7-PLCSIM Simulation: Launch S7-PLCSIM on the ES, download the AS hardware and CFC charts to the virtual controller, and start the WinCC OS in Runtime. All block icons and faceplates will animate and respond to mouse clicks identically to a live physical plant.
- WinCC Tag Simulator: Alternatively, activate the built-in WinCC Tag Simulator tool to drive sinusoidal or ramp values into specific analog process tags without running PLCSIM.
Comparison of Compilation Scopes (Entire OS vs Changes Only)
The following table compares the two primary OS compilation options available in SIMATIC Manager:
Verification
Verify that the offline tag export completed successfully:
1. In SIMATIC Manager, check the OS Compilation log for '0 errors' and '0 warnings'.
2. Open the WinCC project in WinCC Explorer; expand Tag Management and verify that the tag count matches the expected number of CFC block attributes.
3. Open Alarm Logging in WinCC; confirm that all ALARM_8P message texts, message classes, and event states generated by the CFC blocks are fully populated.
4. Open Graphics Designer, place a standard APL block icon, and connect it to a compiled tag; verify that the tag browser displays the complete AS hierarchy path.
Limitations and Operational Precautions
Performing an 'Entire OS' compilation on a live production plant interrupts operator monitoring and requires deactivating the WinCC server. However, during the offline engineering phase, 'Entire OS with memory reset' should ALWAYS be used to ensure no stale database fragments remain. Remember that changing block parameter names or chart names in CFC without recompiling the OS will result in broken @pg_ faceplate links and yellow tag status flags in runtime.
Engineer FAQ
Can I compile the OS if I only have Step 7 and WinCC without a full PCS 7 license?
Yes, provided the 'AS-OS Engineering' add-on package is installed. This package provides the compiler DLLs and SIMATIC Manager integration required to transfer DB tags to WinCC in standard Step 7 environments.
Why are some CFC block inputs not appearing in WinCC Tag Management after compilation?
Only block parameters assigned the system attribute S7_m_c := 'true' are exported to WinCC. In CFC, open block properties, check the I/O table, and ensure the target parameter has the 'OCM' (Operator Control and Monitoring) checkbox checked.
Do I need to compile the CFC charts before compiling the OS?
Yes. The OS compiler reads the generated instance data blocks (DBs) created during CFC compilation. If you modify a CFC chart and compile the OS without compiling CFC first, the OS will contain outdated tag addresses.
Technical References
- SIMATIC Process Control System PCS 7 Operator Station Configuration Manual
- SIMATIC PCS 7 CFC for S7 / S7-SCL Programming Guide
- WinCC: Communication System Manual
Related Articles
- Resolving OS Compilation Startup Failure and Immediate s7uvmapx.exe Termination in PCS 7
- Identifying PCS 7 Auto-Generated Tags and Implementing Standard APL Status Monitoring
- Resolving Generic OS Compilation Failures 'Error occurred compiling the object' in SIMATIC PCS 7
Related Tags
- OS Compilation
- AS-OS Engineering
- Tag Management
- Offline Engineering
- WinCC