Resolving S7-1200 PROFINET Watchdog Faults with Keyence IV

David Krause11 min read
ProfibusSiemensTroubleshooting
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 Statement

An S7-1200 PLC (typical CPU 1214C DC/DC/DC or 1215C) acts as the PROFINET IO Controller for a mixed network that includes three Siemens SINAMICS V90 or SIMOTION DKE drives, a Siemens TP Comfort HMI, an ET200SP distributed I/O station, and four Keyence machine vision cameras (typically IV3-500CA, IV3-100CA, IV2-500, or CV-X series) reached via PROFINET. The PLC operates with a 200 ms OB1 cycle and runs without faults during production. The moment a technician launches Keyence IV Navigator on a service laptop and connects to any of the four cameras to inspect images or read result registers, the PLC writes the diagnostic event "IO device watchdog expired" for every camera and the ET200SP station. The PLC does not transition to STOP, but the five devices enter PROFINET channel-fault state and require either a power cycle of the affected cameras or a station reconnection through TIA Portal before the cyclic IO resumes.

The fault is not random. It reproduces on every connection attempt from IV Navigator and clears only when the IV Navigator session is closed and the cameras are re-parameterized or power-cycled. The behavior is a classic PROFINET stream-saturation / store-and-forward disruption symptom, amplified by the network topology that was wired in the panel.

Symptoms Checklist:
  • Diagnostic buffer entry: IO device watchdog expired for Keyence cameras and ET200SP.
  • SF (red) LED lit on the S7-1200 PROFINET port or on the affected devices.
  • Camera process image in the PLC tag table freezes or returns the last good value.
  • Fault appears within 1-3 s of IV Navigator opening a connection to a camera.
  • No fault when IV Navigator is closed and production runs.

Network Topology Analysis

PROFINET is a real-time Ethernet protocol that uses cut-through switching on most managed switches and store-and-forward on unmanaged switches. When one device in a daisy-chain stops forwarding PROFINET RT frames, every downstream device disappears from the IO Controller's view. The first diagnostic step is therefore to map the physical cabling.

Topology Behavior with IV Navigator Recommendation
Star (managed switch, e.g. SCALANCE XC-208) Faults should be isolated to the camera's port. Other PROFINET devices remain reachable. Preferred layout for IV-Navigator troubleshooting.
Daisy-chain via Keyence camera PROFINET ports One camera port disrupted by IV Navigator drops every downstream device (ET200SP, other cameras). Replace with star topology or place IV-Navigator target as last device in chain.
Daisy-chain with unmanaged switch Store-and-forward latency adds 10-200 ms per hop, exceeding watchdog on heavy traffic. Replace with managed SCALANCE switch or reduce update time / raise watchdog.

Confirm topology by physically tracing the PROFINET patch cables from the S7-1200 X1 port. If you find RJ45 jumpers between camera LAN ports and the ET200SP, you are running a daisy-chain. In that case, the IV Navigator connection to camera #1 can saturate camera #1's PROFINET forwarding queue, delaying frames to the ET200SP that sits downstream. When the ET200SP update time elapses without a fresh PROFINET frame, the IO Controller raises a watchdog fault. Cameras downstream of the first affected unit suffer the same fate.

Root Cause Analysis

Keyence IV Navigator is a discovery and configuration utility. When it starts a session, it performs high-rate TCP/UDP transfers to read images and logging data over the same physical Ethernet port that carries PROFINET RT. On many Keyence vision processors the LAN port is shared between PROFINET RT and standard IT traffic without QoS prioritization. The result is twofold:

  1. Forwarding latency spike: the camera's internal switch buffers a large image transfer, delaying the cut-through of cyclic PROFINET frames to the next downstream device.
  2. Multicast / broadcast amplification: IV Navigator sends SSDP and Keyence discovery packets that the camera may forward out of its PROFINET port, briefly overwhelming the daisy-chain segment.

If the IO Controller has a PROFINET watchdog shorter than the latency spike, the IO Controller interprets the missing cyclic frame as a station failure and raises IO device watchdog expired. The PROFINET specification (IEC 61784-2 / PROFIBUS Guideline "PROFINET IO") defines the watchdog as the maximum time the IO Controller will wait for fresh IO data before declaring the device failed. PROFINET IO Controllers typically derive the watchdog from the configured update time with a multiplier; Siemens TIA Portal exposes this directly.

Reference: Handling Broken PROFINET Connections (Delta Motion RMC Tools documentation) explains how PROFINET controllers handle configurable timeouts and how lost connections manifest as faults.

Reading the PLC Diagnostic Buffer in TIA Portal

Before changing anything, capture the exact diagnostic events. Open the project in TIA Portal V16 or later, perform "Go online" against the S7-1200, then:

  1. Expand Online & Diagnostics on the CPU.
  2. Open Diagnostics buffer.
  3. Filter for events containing "PROFINET IO", "Watchdog", or the device names.
  4. Export the buffer to a text file for the maintenance record.

The expected entries for this fault class are:

Event ID Text Meaning
0x031E IO device failure Station no longer reachable on PROFINET.
0x031F IO device returns Station reconnected after fault.
0x0342 PROFINET IO: Watchdog expired Cyclic frame missed within configured watchdog.
0x0351 Channel fault Submodule diagnostic alarm raised.
0x0251 OB86 start information Rack failure OB invoked.

Confirm the OB86 entry: if the project does not contain OB86, the CPU still records the event but cannot run user-defined recovery logic. Many S7-1200 projects are delivered without OB86 because the default behaviour (just logging and continuing) is "good enough" during bench commissioning. It is not good enough in a 24/7 cell.

PROFINET Watchdog Time Configuration

Open the device properties of each camera and the ET200SP in the TIA Portal project tree. Under PROFINET Interface > Real Time Settings > Watchdog, you will find either an explicit "Watchdog time" field (TIA V17+) or a "Update time" field with an implicit 3x multiplier on older releases.

Parameter Default Recommended for shared IV-Navigator port
Send clock (TIA V16+) 1 ms 1 ms
Update time 4 ms 8 ms
Watchdog factor (default 3) x3 x6
Effective watchdog 12 ms 48 ms
Reduction ratio 1 1
Rule of thumb: The PROFINET watchdog must be at least 3x the configured update time and should exceed the worst-case forwarding delay introduced by any daisy-chain segment. A 200 ms OB1 cycle provides plenty of margin; a 1 ms cyclic interrupt OB would not.

Steps in TIA Portal:

  1. Select the Keyence camera in the device view.
  2. Open Properties > PROFINET Interface > Real Time Settings.
  3. Set Update time to 8 ms.
  4. Set Watchdog time to 48 ms (or set factor = 6 if only the factor field is available).
  5. Compile and download the device configuration.
  6. Repeat for the ET200SP head module (IM 155-6 PN HF or ST).

Reference: SIMATIC S7-1200 Programmable Controller System Manual (entry ID 109741593) documents the PROFINET interface and update-time/watchdog interaction on CPUs 1211C through 1217C.

Keyence IV Navigator PROFINET Behavior

IV Navigator communicates with IV3, IV2, and CV-X controllers using the Keyence MC Protocol or a proprietary TCP service on port 8500/8501 (varies by firmware). It is not PROFINET-aware; it treats the vision controller as a generic Ethernet node. If the vision controller is configured with a "PROFINET only" firewall profile on firmware 1.20 or later, IV Navigator traffic is allowed but the PROFINET frames share the same hardware queue.

The IV3 controller (firmware 1.30 and later) has a configurable parameter PROFINET QoS priority. Enable QoS priority = 6 on the camera and QoS priority = 6 on every SCALANCE switch port used by PROFINET. This places the cyclic PROFINET frames in the highest-priority queue and deprioritises IV Navigator image downloads. If the camera firmware does not expose QoS, isolate IV Navigator on a separate VLAN or a dedicated management port on the SCALANCE switch.

Recommended switch port settings on SCALANCE XC-208 / XR-100WG:

  • Broadcast limiter = 64 pkts/s.
  • Multicast filtering: enable IGMP snooping; permit only the PROFINET multicast MAC 01-0E-CF-00-00-00.
  • QoS queue mapping: VLAN priority 6 -> queue 3 (highest).
  • Disable flow control on PROFINET ports.

Implementing OB86 for Rack Failure

Without OB86 the CPU cannot execute a recovery routine; it only logs the event. Adding OB86 lets the program acknowledge the failure, raise a process flag, and attempt a station reconnect via SFB52 "RDREC" / SFB53 "WRREC" on the PROFINET interface.

Create OB86 (Rack failure) in TIA Portal with the following STL skeleton:


// OB86 - Rack / Station failure
// LOST: LADDR contains PROFINET IO system ID
IF #OB86_EV_CLASS = B#16#38 THEN  // outgoing event (failure)
    #StationFailure := TRUE;
    // Evaluate slot / device
    CASE #OB86_MDL_ADDR OF
        100: #Cam1_Fault := TRUE;   // Keyence IV3 #1
        101: #Cam2_Fault := TRUE;
        102: #Cam3_Fault := TRUE;
        103: #Cam4_Fault := TRUE;
        200: #ET200SP_Fault := TRUE;
    END_CASE;
ELSE                              // B#16#39 incoming (return)
    #StationFailure := FALSE;
    CASE #OB86_MDL_ADDR OF
        100: #Cam1_Fault := FALSE;
        101: #Cam2_Fault := FALSE;
        102: #Cam3_Fault := FALSE;
        103: #Cam4_Fault := FALSE;
        200: #ET200SP_Fault := FALSE;
    END_CASE;
END_IF;

Pair OB86 with OB82 (Diagnostic Interrupt) to capture submodule-level faults such as channel diagnostics from a Keyence camera that loses its trigger input. LADDR in OB82 yields the logical address of the failing submodule; this can be wired to the HMI alarm log for the maintenance team.

Device Health Monitoring Logic

Even with the watchdog relaxed, production code must not blindly write into the process image of a camera that is currently in PROFINET fault. Every camera and the ET200SP should publish a "Device_OK" tag derived from the IO Controller's status bits.

Implementation pattern in SCL:


FUNCTION_BLOCK "FB_Cam_Health"
VAR_INPUT
    i_Trigger     : BOOL;   // Heartbeat from camera output bit
END_VAR
VAR_OUTPUT
    o_Device_OK   : BOOL;
    o_LastSeen    : DTL;
END_VAR
VAR
    s_TOF         : TON;    // 500 ms timer
END_VAR

BEGIN
    s_TOF(IN := i_Trigger, PT := T#500MS);
    IF s_TOF.Q THEN
        o_Device_OK := FALSE;
    ELSE
        o_Device_OK := TRUE;
        o_LastSeen := RD_SYS_T();
    END_IF;
END_FUNCTION_BLOCK

Use the standard PROFINET status word at the device's input start address. Bit 0 (IO Controller view: bit 0 of the first input byte) toggles every cycle; missing toggles for >500 ms indicate the device is no longer exchanging data. Wrap any camera-specific FB call in IF #Cam1_OK THEN ... END_IF; to prevent uninitialised process image from corrupting inspection results.

Verification Procedure

  1. With the updated TIA Portal project downloaded and the S7-1200 in RUN, observe the diagnostic buffer for 5 minutes. It must be free of watchdog events.
  2. Start IV Navigator on the service laptop, connect to camera #1, browse an image, and stay connected for at least 60 s. The diagnostic buffer must remain clean for the other three cameras and the ET200SP.
  3. Disconnect IV Navigator. Repeat for camera #2, #3, #4 in succession.
  4. Force a worst-case load: trigger a "Save all images" from IV Navigator while the line is running. The PLC should record no IO device watchdog events.
  5. Power-cycle camera #1. The diagnostic buffer must show OB86 outgoing (B#16#38) followed by incoming (B#16#39) within 10 s of reconnection.
  6. Confirm on the HMI that Cam1_Device_OK through Cam4_Device_OK toggle correctly on plug / unplug.

If the buffer still records 0x0342 after step 2, revisit the topology: a daisy-chain cannot be fixed by watchdog tuning alone. Re-cable to a star with SCALANCE XC-208 or place the IV-Navigator service laptop on a separate, non-PROFINET VLAN that routes only via the SCALANCE management port.

Field-Proven Best Practices

  • Never connect IV Navigator on a daisy-chain segment while production runs. Use a managed switch and isolate the engineering port.
  • Set the PLC OB1 cycle (200 ms in this case) to be at least 10x the worst PROFINET update time to avoid cyclic inconsistencies during camera image bursts.
  • Always install OB82, OB83, OB85, and OB86 in production S7-1200 projects. OBs are not optional safety features; they are the only mechanism for controlled degradation.
  • Document the LADDR mapping of every PROFINET device in a constant DB so OB86 can resolve the failing slot to a friendly name on the HMI.
  • Lock IV Navigator to a fixed IP and reserve that IP in the SCALANCE DHCP pool only during maintenance windows.

Why does the ET200SP fault even though I never connect IV Navigator to it?

The ET200SP shares the same PROFINET segment. In a daisy-chain topology, when the first camera's forwarding latency spikes due to an IV Navigator image download, the ET200SP's cyclic PROFINET frame is delayed beyond the configured watchdog. The IO Controller raises a station failure for the ET200SP regardless of whether IV Navigator targeted it.

What is the default PROFINET watchdog on an S7-1200?

TIA Portal sets the watchdog to three times the update time. With the default 1 ms update time, the effective watchdog is 3 ms. With an 8 ms update time it becomes 24 ms. The watchdog field is accessible under Device Properties > PROFINET Interface > Real Time Settings and should be raised to 48 ms or higher when non-PROFINET traffic shares the segment.

Can OB86 automatically reconnect a Keyence camera?

OB86 only signals the fault; it does not perform a physical reconnect. To reinitialise the camera's PROFINET stack you must trigger SFB52 RDREC / SFB53 WRREC on the camera's slot, or remove/reinsert the device in the IO Controller's port. Most field installations rely on OB86 to set a flag and let the operator cycle power, but automatic re-parameterisation is possible through the TIA Portal "Reconnect station" PLC instruction in V17 and later.

Is it safe to keep IV Navigator running during production?

No. IV Navigator generates image traffic on the same Ethernet port that carries PROFINET RT. Even with QoS prioritisation and a star topology, the additional load increases the probability of jitter and cyclic-frame loss. Run IV Navigator only during maintenance windows, ideally on a separate VLAN or via the SCALANCE port that is excluded from the PROFINET broadcast domain.

Which firmware versions on IV3 cameras support QoS prioritisation?

Keyence IV3 firmware 1.30 and later exposes the QoS priority parameter under Communication > PROFINET. Earlier firmware (1.10, 1.20) treats PROFINET as best-effort and cannot prioritise cyclic frames over image transfers. Update the camera firmware through the Keyence IV Navigator updater before relying on QoS to fix the watchdog fault.

Back to blog