WcState
The variables under WcState (working counter state) use a working counter to indicate whether the EtherCAT slave takes part in the cyclic process data traffic successfully and error-free.
The variable WcState of an EtherCAT slaves should therefore always be evaluated.
The variables are only displayed, if the EtherCAT slave is added via an EtherCAT master in TwinCAT.

The following table shows which values the WcState variable can assume:
Value |
Description |
---|---|
0 |
Valid real-time communication in the last cycle |
1 |
Invalid real-time communication |
Invalid real-time communication may affect the process data of the other EtherCAT slaves in the same SyncUnit:
- In the event of an invalid WcState, outputs can still be switched by the PLC, in order to ensure a safe state of the system.
- Inputs freezes and show the last valid value. This means that old values are displayed, if the WcState assumed the value 1.
The variable InputToggle indicates whether a new valid telegram was received. The value is incremented by one after each successful cycle.