Resolving Module Driver Generation Errors for Third-Party GSD Slaves in PCS 7
To resolve compilation errors during module driver generation in SIMATIC PCS 7 V9.0 when using a third-party PROFIBUS DP slave (such as a Pilz PNOZ mc3p configured via GSD), disable automatic driver generation for that specific device in HW Config. The PCS 7 driver generator only generates diagnostic blocks (such as MOD_D1 or MOD_D8) for Siemens ET 200 distributed I/O and certified Siemens field devices with known diagnostic structures. Third-party GSD files lack these driver definitions, causing the compiler to abort. In HW Config, uncheck 'Generate module drivers' in the slave's object properties, and wire its I/O addresses directly to application logic in CFC.
Table of Contents
- Why Generate Module Drivers Fails on Third-Party GSD Devices
- How PCS 7 Module Driver Generation Works
- Step-by-Step Procedure to Disable Module Drivers for Third-Party Slaves
- Siemens Native vs Third-Party GSD Device Integration Matrix
- Verification
- Limitations and Operational Precautions
- Engineer FAQ
- Technical References
- Related Articles
- Related Tags
Why Generate Module Drivers Fails on Third-Party GSD Devices
In SIMATIC PCS 7, compiling CFC charts with Generate module drivers enabled triggers an automated mechanism that scans the HW Config station topology. For every hardware module, it inserts specialized diagnostic and channel driver blocks into the automation program:
- Distributed I/O racks receive diagnostic managers (
RACK,OB_DIAG1). - I/O modules receive hardware monitors (
MOD_D1,MOD_D8). - Field signals receive channel drivers (
Pcs7DiIn,Pcs7AnIn).
This driver generation engine relies on XML rule sets and block templates stored in \Siemens\Step7\S7DATA\MODDRV. These rules are tailored specifically for Siemens hardware families (e.g., ET 200M, ET 200SP, ET 200iSP). Third-party PROFIBUS DP slaves—such as the Pilz PNOZ mc3p configurable safety system communication module—are defined by standard General Station Description (GSD) files. These GSD files contain standard PROFIBUS DP parameters but lack Siemens-proprietary diagnostic structures. When the PCS 7 driver generator encounters an active GSD slave without matching MODDRV rules, it encounters an unresolvable hardware exception and aborts compilation with an error, regardless of whether GSD v1.0 or v1.5 is used.
How PCS 7 Module Driver Generation Works
The module driver generator performs three core tasks:
- Diagnostic Interconnection: It links module diagnostic status bytes to the AS alarm system, posting system messages when a rack failure, module pull/plug, or wire break occurs.
- Signal Quality Code (Quality Code/ST): It evaluates fieldbus health and generates quality code bytes (e.g.
16#80Good,16#00Bad) passed to APL blocks. - Address Assignment: It wires physical logical base addresses (LADDR) to driver block inputs.
Because third-party devices do not adhere to the ET 200 diagnostic byte layout, attempting to force Siemens driver generation on a third-party GSD slave is architecturally invalid.
Step-by-Step Procedure to Disable Module Drivers for Third-Party Slaves
To resolve the compilation failure while maintaining clean integration of the third-party slave, follow these steps:
- Disable Module Driver Generation in HW Config:
- Open HW Config in SIMATIC Manager.
- Locate the third-party PROFIBUS DP slave (e.g., Pilz PNOZ mc3p) on the DP master system.
- Double-click the slave or right-click and select Object Properties.
- Navigate to the Operating Parameters or Module Drivers tab.
- Uncheck the option: Generate module drivers (or deselect 'Generate module driver for this module').
- If individual sub-modules or I/O slots exist under the slave, open their properties and ensure module driver generation is deselected for each slot.
- Click OK, then perform Station -> Save and Compile. - Configure Direct Signal Interconnection in CFC:
- Open your CFC chart.
- Do not use PCS 7 channel drivers (Pcs7DiIn) that expect module diagnostic connections (DataXChg).
- Instead, wire peripheral I/O words (e.g.,IW 512,QW 512) directly to standard logic blocks, custom conversion FBs, or usePcs7DiInwithModeconfigured manually and diagnostic inputs left unconnected. - Execute Clean CFC Compilation:
- Open CFC and select Chart -> Compile -> Charts as Program....
- Check Generate module drivers (this remains necessary for your Siemens ET 200 stations).
- The compiler will process all Siemens stations while skipping the third-party GSD slave, concluding with 0 errors.
Siemens Native vs Third-Party GSD Device Integration Matrix
The following table compares configuration requirements between native Siemens distributed I/O and third-party GSD field slaves:
6ES7153-2BA10-0XB0)MOD_D1, MOD_D8, RACKIW/QW)SFC13 (DPNRM_DG)[!NOTE]
Commercial Accuracy Notice: Third-party fieldbus integration relies on standard PROFIBUS DP protocols and standard > STEP 7 / PCS 7 engineering tools. No supplementary Siemens runtime software packages or third-party license options are > required. When specifying distributed I/O stations, compare third-party communication interfaces against standard Siemens > ET 200M (6ES7153-2BA10-0XB0) or ET 200SP (6ES7155-6AU01-0BN0) solutions based on system architecture requirements.
Verification
Verify that the compilation error is resolved and field data communicates properly:
- CFC Compilation Log: Compile the CFC program (Entire program with Generate module drivers checked). Verify that compilation completes with 0 Errors and 0 Warnings regarding unsupported driver modules.
- AS Download and Online Test: Download changes to the controller. Go online in CFC and inspect the input word connected to the Pilz PNOZ mc3p. Verify that safety relay status bits toggle in response to field safety device actuation.
- Diagnostic Verification: Verify that the PROFIBUS master communication LED (
BF/ Bus Fault) remains extinguished on both the CPU and the Pilz communication module.
Limitations and Operational Precautions
Keep the following operational limitations in mind when integrating third-party GSD devices without module drivers:
- No Automated WinCC System Alarms: Because
MOD_D1diagnostic blocks are not generated, a communication failure or internal fault in the third-party slave will not automatically trigger a WinCC Maintenance Station alarm. - Implementing Custom Device Monitoring: If fieldbus disconnection monitoring is required, implement a custom watchdog or call
SFC13(DPNRM_DG) orSFC51(RDSYSST) in a cyclic OB to monitor station health. - Address Area Constraints: Ensure the peripheral addresses assigned to the third-party GSD slave reside within the configured process image partition (PIP) of the cyclic OB executing the reading CFC chart.
Engineer FAQ
Why didn't updating the GSD file from v1.0 to v1.5 fix the compilation error?
GSD files only define standard PROFIBUS communication parameters for STEP 7. They do not supply Siemens PCS 7 module driver templates (MODDRV), which are proprietary to Siemens and not part of the standard GSD specification.
Can I still use APL channel drivers (Pcs7DiIn) with a third-party GSD slave?
Yes, but you must decouple the channel driver from the hardware diagnostic engine. Set the input parameter Mode manually and leave the diagnostic interconnection pins unconnected.
How can I monitor if the third-party PROFIBUS slave goes offline?
Use system function SFC51 (RDSYSST) with SSL ID 16#0292 or call SFC13 (DPNRM_DG) to query the DP slave diagnostic status. If the slave stops responding, set a bad quality code to alert operators on WinCC.
Does disabling module drivers affect other Siemens ET 200 stations in the project?
No. Disabling module driver generation in the properties of the third-party slave affects only that specific device. The CFC compiler continues to generate full module drivers for all other Siemens stations.
Technical References
- SIMATIC PCS 7 V9.0 Driver Generator Function Manual (Entry ID 109754988)
- SIMATIC PCS 7 CFC for S7 Engineering Manual (Entry ID 109754983)
- PROFIBUS DP Slave Integration in SIMATIC STEP 7 (Entry ID 109751826)
- Pilz PNOZ mc3p Communication Module Operating Manual (Pilz Doc 21255-EN)
Related Articles
- Configuring Module Driver Generation Rules and Exceptions in PCS 7
- Integrating Third-Party Modbus and PROFIBUS Field Devices in PCS 7
- Acyclic Diagnostic Data Reading Using SFC13 and SFC51 in S7-400
- Configuring APL Channel Drivers with Manual Quality Code Settings
Related Tags
- Module Drivers
- Third-Party GSD
- PROFIBUS DP
- Pilz PNOZ
- CFC Compilation Error
- HW Config