Resolving STEP 7 HW Config Error 256:31 Orphaned I/O Addresses

David Krause11 min read
SiemensTIA PortalTroubleshooting
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

Problem Overview

When compiling or saving a SIMATIC STEP 7 project that uses a software controller such as WinLC RTX with a PROFINET IO system, the Hardware Configuration editor (HW Config) returns the message "Unable to find corresponding object" during Save and Compile. The error references an input or output address (for example, IW 1640) that points to a PROFINET IO device which has already been removed from the project, but whose symbolic or absolute address assignment still remains in the OFFLINE database of the S7 program.

The full Siemens error identification is:

  • Error Number: 256 : 31
  • Module: S7HWCNFX (HW Config / NetPro for PROFINET)
  • Error Text: "This object was not found."
  • Cause Class: Consistency error between S7 program blocks and HW Config OFFLINE database

This fault class is not a runtime fault on the controller. It is a station inconsistency detected at compile time inside the engineering tool. Left unresolved, it blocks project save/compile cycles, prevents downloading the HW Config, and can cascade into further NetPRO errors at GoOnline. The error is documented in the Siemens Knowledge Base entry referenced by the historical entry ID 770453 / attachment step7_errorcode_e.pdf.

Important: This error class affects STEP 7 V5.x projects (SIMATIC Manager, HW Config, NetPro). It does not apply to TIA Portal projects, which use a unified data model and do not exhibit this specific orphaned-address symptom.

Technical Background: PROFINET IO Address Model in STEP 7

STEP 7 V5.x maintains two parallel representations of every IO device in the station:

  1. Hardware view (HW Config / NetPro) — the graphical topology holding the IO device, its slots, and the slot-level I/O addresses (input/output byte offsets in the process image).
  2. Program view (S7 program blocks, symbol table, system data) — the absolute or symbolic references to those addresses inside LAD/FBD/STL/SCL code, DBs, FB multi-instances, and the system data blocks (SDB) generated at compile time.

When a PROFINET device is deleted from HW Config, STEP 7 attempts to invalidate all referencing symbols and address slots. In normal operation, Compile and Save rewrites the SDBs and strips orphan references. Failure modes that produce error 256:31 include:

  • Manual deletion of a device without subsequent Save and Compile.
  • Project copy / archive-restore on a different STEP 7 version that drops slot-level bindings.
  • WinLC RTX offline/online synchronization interruption that aborts a partial SDB rewrite.
  • Import of a partial substation that contains program references but lacks the IO device subtree.

PROFINET slot addressing in STEP 7 follows the convention I [device_offset + slot_offset] and Q [device_offset + slot_offset]. The address IW 1640 is therefore a 16-bit word input mapped into the process image partition (PIP) starting at byte 1640 — a high address that strongly indicates a removed IO device whose head slot used a deep device offset.

Affected Products and Versions

Component Confirmed Versions Status
STEP 7 (SIMATIC Manager) V5.4 SP3 / V5.4 SP4 / V5.4 SP5 / V5.5 / V5.5 SP1 / V5.5 SP2 / V5.5 SP3 / V5.5 SP4 Affected
HW Config / NetPro bundled with STEP 7 above Affected
WinLC RTX V10.4 and later, paired with STEP 7 V5.4+ Affected (typical trigger platform)
S7-PCT (Port Configuration Tool) V3.x used for PN IO port assignment Not directly implicated
STEP 7 (TIA Portal) V13 / V14 / V15 / V15.1 / V16 / V17 / V18 Not affected by this error class
S7-300 / S7-400 CPU firmware All PROFINET-capable firmware versions Runtime unaffected; only the engineering tool flags the error

The fault originates entirely inside the engineering database (*.s7p / s7proj archive) and does not indicate a hardware failure on the controller or the PROFINET device.

Root Cause Analysis

The internal consistency check performed during Save and Compile enumerates every absolute and symbolic I/O access in the OFFLINE program and validates that a corresponding slot exists in the HW Config OFFLINE tree. When the count fails to match, the function returns error 256 : 31.

The underlying data model:

  • The program blocks carry symbol-table entries mapping names such as Motor1_Feedback to IW 1640.
  • The HW Config stores slot descriptors binding IW 1640 to a specific PROFINET device/module at a given slot index.
  • When the device is deleted from HW Config, only the graphical node is removed. The symbol-table binding and the orphaned absolute address remain in the program until a full compile regenerates the SDBs.

The trigger condition is therefore: orphaned address reference surviving past device deletion. Siemens' official error catalogue lists the cause as: "The assignments in the OFFLINE database with regard to the HW configuration are no longer consistent."

Diagnostic Procedure

Before applying the fix, validate the error with the built-in consistency tools so that the report is reproducible and complete.

Step 1 — Open HW Config

  1. Launch SIMATIC Manager.
  2. Select the affected station (for example, SIMATIC PC Station(1) hosting WinLC RTX).
  3. Double-click Hardware to open HW Config.

Step 2 — Run Station Consistency Check

  1. From the HW Config menu select Station → Consistency Check.
  2. HW Config enumerates the entire station including PROFINET IO subnets.
  3. Click Detail in the result dialog to display the complete error number and the failing object identifier.

The Detail view reveals the precise device, slot, and address that the compiler cannot resolve. Typical output:

Error 256:31
Object not found: PROFINET IO Device [EtherNet/IP_Interface_1] Slot 0
Referencing address: IW 1640
Action: Reorganize station or remove referencing symbol

Step 3 — Run Block Consistency Check (S7 Program)

  1. Return to SIMATIC Manager.
  2. Select the S7 Program container of the affected station.
  3. Right-click → Check Block Consistency… (or menu Edit → Check Block Consistency).
  4. The compiler scans every FB/FC/OB/DB and lists any block referencing the orphan address.

Capture the full diagnostic output before proceeding — it is useful if escalation to Siemens Technical Support is required.

Resolution Method 1 — Reorganize with Ctrl+Alt+F11 (Recommended)

This is the lowest-risk resolution. It forces HW Config to rebuild the station's slot-to-address mapping without deleting any program blocks.

  1. With the affected station open in HW Config, press the keyboard combination Ctrl + Alt + F11.
  2. HW Config prompts: "Reorganize station?" Click Yes.
  3. The tool walks every slot, reassigns the process-image addresses, and rebuilds the SDB container.
  4. Re-run Station → Consistency Check. The 256:31 error should no longer appear.
  5. Save with Ctrl + S and close HW Config.

Behind the scenes, this shortcut invokes the same code path as File → Save As with Reorganization, but operates on the currently open station rather than writing a new project file. It is safe to invoke repeatedly and does not alter program logic.

Tip: If the keyboard shortcut appears unresponsive, ensure HW Config has window focus (not the symbol editor or a docked toolbox). On non-US keyboards, the F11 key may require a function-lock toggle.

Resolution Method 2 — Save As With Reorganization

Used when the project archive itself must be rebuilt, for example before passing the project to a colleague or migrating to a newer STEP 7 version.

  1. In SIMATIC Manager select File → Save As….
  2. Tick the option With reorganization (slow) in the save dialog.
  3. Choose a destination folder (or overwrite the existing *.s7p).
  4. Confirm. STEP 7 rewrites the entire project archive, repacking the station and program folders.

Reorganization rewrites the internal sequential file structure of the STEP 7 database and physically removes orphan entries. It is the same engine that runs during Ctrl+Alt+F11, but applied project-wide.

Resolution Method 3 — Manual Address Cleanup

Use this method only when reorganization does not clear the error, which can occur if a device deletion left a dangling slot descriptor in NetPro. The process removes the orphaned references by hand.

  1. Open NetPro (double-click PROFINET IO System in SIMATIC Manager).
  2. Select PROFINET IO → Station → Properties for the affected controller.
  3. Note any IO devices marked with a red ✕ — those are missing or mismatched.
  4. Open HW Config and identify the head slot of each orphan device. Right-click the slot → Delete only if the corresponding program access has already been removed.
  5. Open the Symbol Table (S7 Program → Symbols) and remove or repoint every symbol that resolves to IW 1640 (or whichever address the diagnostic listed).
  6. Inside any block (FB/FC/OB/DB) that references the orphan address, replace the access with a valid substitute or a constant default.
  7. Run Check Block Consistency followed by Save and Compile.
Warning: Manual cleanup modifies program logic. Always create a backup copy (File → Save As…) before editing symbols or blocks. Document every change in a project revision log.

Resolution Method 4 — Restore From Clean Archive

If consistency remains broken after reorganization and manual cleanup, restore the most recent archive that compiled cleanly.

  1. Locate the last known-good *.s7p or *.zip archive (version-controlled or from a backup).
  2. In SIMATIC Manager, select File → Retrieve… and open the archive into a fresh folder.
  3. Verify: Station → Consistency Check must report zero errors before any further changes.
  4. Reapply only the changes that were made between the last good archive and the broken version, verifying compile at each step.

Restoration is the safest approach when multiple error classes coexist (for example, 256:31 plus additional SDB generation faults).

Verification Procedure

After applying any of the four resolution methods, validate the project with the following sequence.

  1. Compile station: HW Config → Station → Save and Compile. No error dialog should appear.
  2. Consistency check: HW Config → Station → Consistency Check. Detail pane must show no 256:31 entries.
  3. Block consistency: SIMATIC Manager → S7 Program → Check Block Consistency. Compile must finish with zero errors.
  4. Cross-reference: Open the symbol table and verify the previously orphan address (IW 1640) either no longer appears or is bound to a currently configured device slot.
  5. Download test (offline only): With the PLC in STOP, perform PLC → Download from HW Config. The SDB transfer must complete without error.
  6. Online diagnostic: After download, PLC → Module Information → Diagnostic Buffer must show clean startup with no SDB-error entries.

If all six steps pass, the project is consistent and the error is cleared.

Prevention and Best Practices

  • Always Save and Compile after deleting an IO device. This regenerates SDBs and clears orphan references in a single step.
  • Maintain a version-controlled project archive. Save As… with reorganization at every major milestone.
  • Run Check Block Consistency after every offline edit. Even small edits to FB/FC code that touch absolute addresses can reintroduce inconsistencies.
  • Avoid deleting devices directly from NetPro. Use HW Config instead, where the slot reassignment wizard validates downstream references.
  • Document address assignments. Maintain an external Excel or database mapping each PROFINET device to its slot offset, head address, and program symbols.
  • Use symbolic addressing wherever possible. Symbol-table bindings are easier to re-point than absolute address references scattered through code.
  • Periodic project reorganization: Run Ctrl+Alt+F11 on every station at least once per major project revision.

Related Errors and Edge Cases

Error Code Meaning Distinguishing Feature
256 : 31 Object not found (HW Config) Orphan address reference after device deletion
256 : 26 Address already assigned Slot conflict between two devices
256 : 34 Slot configuration invalid Module type does not match GSD file
SF LED + diagnostic buffer entry W#16#8001 SDB generation error Generated after download; offline compile succeeds
SF LED + W#16#8042 Module failure Physical PROFINET device problem (not engineering)
0xFFFE in module diagnostics Substitute failure Slot missing IO device on bus

If after applying Ctrl+Alt+F11 the user receives a different error (such as 256:26), the root cause is a slot overlap rather than an orphan address and manual slot reassignment is required. If the project compiles cleanly offline but the diagnostic buffer shows W#16#8001 after download, the issue is on the live PROFINET bus and not in the engineering database.

Escalation Path

If none of the four resolution methods clears the error, escalate through the official Siemens support channels:

  1. Generate a Service Request file: SIMATIC Manager → Help → Support Request (or Station → Support Request in HW Config).
  2. Attach the consistency-check detail log and the project archive (after Save As with Reorganization).
  3. Submit the SR via the Siemens Industry Online Support portal with reference to error code 256:31 and the entry ID 770453.

Siemens Technical Support typically responds within standard service-level windows for product-tier accounts; enterprise customers with active service contracts receive priority routing.

FAQ

What does STEP 7 error 256:31 "Unable to find corresponding object" mean?

It is a compile-time consistency fault indicating that the S7 program references an I/O address (such as IW 1640) for which no PROFINET IO device slot exists in HW Config. Siemens documents the cause as: "The assignments in the OFFLINE database with regard to the HW configuration are no longer consistent." It occurs after an IO device has been removed but the program still references its address space.

What is the fastest fix for error 256:31 in HW Config?

Open the affected station in HW Config and press Ctrl + Alt + F11, then confirm the reorganization prompt. This forces HW Config to rebuild the slot-to-address mapping and regenerate the system data blocks without requiring manual address cleanup or block edits.

Does this error occur in TIA Portal projects?

No. TIA Portal uses a unified data model between the device configuration and the program blocks, so the orphan-address symptom (256:31) does not appear. The error is specific to STEP 7 V5.x (SIMATIC Manager / HW Config / NetPro) and is most commonly reported when working with WinLC RTX on PROFINET IO systems.

How can I locate every program reference to the orphan address?

Open the S7 Program in SIMATIC Manager and run "Check Block Consistency…" from the Edit menu, then inspect the symbol table (S7 Program → Symbols) for entries resolving to the offending address. The cross-reference function (Options → Cross-Reference) lists every block access to a given address.

Will reorganizing with Ctrl+Alt+F11 delete my program logic?

No. Ctrl + Alt + F11 only reorganizes the hardware view's slot-to-address mapping and the system data blocks; it does not modify any FB, FC, OB, DB, or symbol-table entry. After reorganization, rerun Check Block Consistency to confirm that no program logic was altered.

Back to blog