Diagnostics and Error Correction

If the devices do not function, then the following troubleshooting options are available:

  • Check the issued errors in the logger.

  • Execute the Scan for Devices command again. When you select the Show differences to project option, the differences between the project and the physical devices are displayed.

    When the configuration is identical, all devices are displayed in green. When there are differences, the devices are displayed in red. You can use the buttons in the middle of the dialog to align the real configuration with the project configuration. Click OK to accept the changed configuration into the project.

    When the in and out port on the slave is interchanged, the entire topology shifts. This makes the order of the devices in the Scan Devices dialog appear oddly distorted from the actual layout. Devices which are connected after a specific slave are displayed before this slave in the Scan Devices dialog.

    If no slaves are found while scanning the devices, then check the network cables and the power supply of the devices. It is also possible that the wrong network adapter is selected in the EtherCAT Master configuration. The results of the scan are displayed in the logger.

  • Additional diagnostic information is displayed on the status page of the EtherCAT Master. If the entry LostFrameCount displays values unequal to 0, then packets will be lost. Possible causes:

    • EMV problems

    • Connection problems

    • Unstable power supply of the devices

    • Delayed reception of the network messages by the operating system (for example, for priorities in the Linux system) or the processor has reached the performance limit

    You can click the Acknowledge button to reset the values to 0.

  • If the network cable is interrupted, then all devices in the tree are displayed in red. An error message is displayed on the General tab of the EtherCAT Master and in the logger of the controller.

  • When the Automatically restart slaves option is selected, the stack starts the slaves automatically as soon as the network connection is restored.

  • Otherwise the master can be or has to be restarted from the application. For this purpose, automatically generated function blocks are available for the master and each slave.

  • Optional devices: An optional device is displayed in gray in the device tree, although it is physically present. The identification in the project is not identical to the identification stored in the device. Either the alias address does not match or the DIP or rotary switches do not match the data in the configuration. You can use the Scan for Devices command to retrieve and modify the stored addresses in the device.

See also

Extended Diagnostics for Error Checking

In expert mode, additional tabs are displayed in the editor. By enabling expert mode for slaves, you can, for example, display a CoE online page. This view displays all available CoE objects, as long as they are defined in the ESI file. It is also possible to load the object dictionary and its values online from the respective device if this function is supported by the slave. In case of problems with the devices, you can also perform a diagnosis with the respective objects.

You can use the function block ReadMemory to read any memory address of a slave. This allows you to check the various error registers of a slave.

See also

Diagnostics in the application

You can use the library CAA Device Diagnosis to perform a generic diagnosis of the devices in your project. You can find an example in the CODESYS Store.

See also