Using Wireshark to Capture EtherCAT Network Packets

Updated Jun 24, 2026

Environment

Hardware

  • Ethernet Cable
  • PXI EtherCAT Interface Module
  • C Series EtherCAT Interface Module

Software

  • LabVIEW Full
  • LabVIEW Real-Time Module

Driver

  • NI-Industrial Communications for EtherCAT

Programming Language

  • LabVIEW G

Overview

 

This article will walk you through capturing EtherCAT network packets using WireShark when unexpected behaviors are observed. You will need to ensure that you have the following software and hardware present in your setup.

 

  • Wireshark installed on your PC
  • Ethernet Hub or Switch hardware present
  • EtherCAT Master with at least two Ethernet ports (CompactRIO or PXI Real-Time Controller)
  • NI-Industrial Communications for EtherCAT driver installed on both your PC and the Real-Time Controller

Steps

 

  1. Create a LabVIEW Project with the Real-Time controller and the EtherCAT Slave
  2. Connect the Wireshark PC ethernet adapter, EtherCAT slave IN port, and the EtherCAT Master adapters to the network hub/switch
  3. Connect the Host PC directly to the EtherCAT Master's Ethernet port as shown



  4. If you only care about EtherCAT traffic, do not connect the hub/switch to any other network or network devices. It is preferable to leave the hub/switch only connected to the Wireshark PC, EtherCAT slave, and EtherCAT Master so that you have less traffic to look through, as shown. Connecting other devices to the EtherCAT network could also interfere with EtherCAT communication.
  5. Disable any firewalls that might prevent Wireshark from performing a full capture on all ports.
  6. If you can't see the slave after connecting everything as described above, configure the network switch to be limited to 100 Mbit/s, as the link speed negotiation may cause issues.
  7. Once all the preparatory steps are complete, open Wireshark and begin capture. 
  8. Run your EtherCAT VI to begin communication
  9. You will see the ECAT packets transmitted over the network in the WireShark instance.


  10. Complete the steps necessary to trigger the unexpected behavior so that the relevant packets are captured in the trace.
  11. Stop the capture session, and save the trace files.