Basic Function Principles
The ET2000 is ready to operate when it is shipped. No hardware settings need to be made. The ET2000 is inserted into an Ethernet line, and then mirrors all the Ethernet frames via a 1 Gbit port to a PC that records the data. The ET2000 does not have any memory of its own, which means that using a 1 Gbit uplink connection is obligatory.
The ET2000 attaches a time stamp to every recorded frame. The time stamps can be used to analyze the network traffic closely. The acquisition moment is the "Start of frame". (SoF)
Commissioning – hardware
- Connect the ET2000 in accordance with the labels to a 24 V DC power supply.
- LEDs 3 and 4 light up (see LED Status).
- Connect the 1 Gbit/s uplink to a network port on your PC; this must also be capable of operating at 1 Gbit. The operation at a 100MBit-Port is not possible.
- Now pass the network traffic that is to be analyzed through one of the four lines (channels) in the ET2000. All four channels can be used simultaneously. The respective activity LED indicates data traffic. The left one of the ports (IN) is to be understood as the input in forward direction, the port on the right (OUT) is the output, s. Fig. "Top view ET2000".
Mirrored frames (from firmware 02) For optimum application of the ET2000 in an EtherCAT network, the ET2000 operates as follows: if only one port is connected on a channel, the ET2000 mirrors all the incoming frames back to this port. This function makes it possible for an EtherCAT branch to continue operating without losing any frames even during the connection process. In networks that are not designed to cope with mirrored frames, this function can result in a conflict! This can, for instance, occur on manageable switches with loopback monitoring. In order to avoid this effect, the network device that can process the reflected frames must be connected first to the ET2000. |
Application in Proninet IRT systems The delay of a single frame while passing a line of the ET2000 is around typ. 540 +/- 40 ns. You have to consider this if Profinet IRT systems are implemented. |
Application example in the EtherCAT System
Fig. "Exemplary connection of the ET2000" exemplifies the usage in a EtherCAT system for recording the protocol data.
Commissioning - software
16 bytes of data are added to every Ethernet frame captured by the ET2000, containing information about the port used, the data integrity and the time stamp. This addendum is attached on the user data as a postfix, the data format is a so called ESL (EtherCAT Switch Link). The point of receiving time of the EtherCAT frame at the ET2000 (Start of Frame, SoF) is captured as a 64 bit time stamp value and is contained in the user data. It is this extended frame that is now transmitted to the PC over the 1 Gbit uplink connection. The continuously incoming Ethernet frames could be recorded there by suitable software. This software is not included in the scope of supply but can, for instance, be downloaded free of charge from the Internet. For currently best performance, at least "Wireshark" version 1.0.2 is suitable.
During sending the ET2000 creates a new checksum/CRC and a new header.
- Operation without ESL evaluation
The parser ..\Wireshark\plugins\ethercat.dll integrated in Wireshark > 1.0.2 as standard only decodes EtherCAT frames and makes them readable. The additional 16-byte data (ESL) are referred to as padding byte. It is not possible to filter the information that they contain. - Operation with ESL evaluation
The ESL information can be decoded by replacing ethercat.dll with a version that can be downloaded from the Beckhoff website:
- CRC Error in the original frame
- Alignment Error
- Time stamp of ET2000
Display of EtherCAT frames with ESL information In the case described above Wireshark can only display Ethernet frames sent by the ET2000, i.e. frames containing ESL information! To enable reading of Ethernet frames without ESL information, delete/rename ethercat.dll and restart Wireshark. |
Only software for Windows operating systems will be considered in these instructions.
Operation without ESL time stamp evaluation
Generally speaking, any appropriate software, such as Microsoft Network Monitor (NetMon), or Wireshark/Etherreal Network Analyser can be used to record the Ethernet frames. It may be necessary to use additional tools in order to analyze the information contained in the frames, and such tools are not necessarily available for any software whatsoever. The further processes are therefore described using the Wireshark network analysis software as an example.
Etherreal vs. Wireshark At present, Etherreal, unlike Wireshark, is not being further developed. Wireshark is the continuation and further development of the well-known Etherreal network analysis program, under a new name. Both are available free, and both (as well as NetMon) can be automated with scripts. |
- Install the current version of Wireshark (www.wireshark.org) on your PC. Wireshark thus provides the user interface and the data management for the recorded frames. The current WinPcap driver will be installed at the same time, if it does not already exist. This takes the Ethernet frames from the network port at the PC, and passes them on to Wireshark.
- Following installation, select Wireshark, choose Capture --> Interfaces to select the 1 Gbit network port to which the ET2000 is transmitting, and start recording.
Process data Large quantities of data can sometimes accumulate in a very short time, depending on the EtherCAT cycle time and process data range |
Fig. "Screenshot of a Wireshark recording" shows a log of EtherCAT frames from the TwinCAT EtherCAT master; in the windows underneath, the content of a frame is broken down (if possible). The "Time" column shows the time at which the frame transmitted by the ET2000 arrived at the PC's Gbit port. Because this involves passage through a number of Windows protocol layers, the accuracy of these values must be considered carefully.
Operation with ESL/time stamp evaluation
If no other actions are taken, the data in the "Time" column gives the approximate arrival time of the Ethernet frame transmitted by the ET2000 on the PC's Gbit port. This value may deviate significantly from the pass-through time of the original frames through the ET2000. Evaluation of the time stamp added by the ET2000 requires a Wireshark extension made available by Beckhoff for Wireshark version 1.0.2 and above. This is a modified EtherCAT parser "ethercat.dll", which ensures that Wireshark can break down an Ethernet frame with EtherCAT datagrams into its components (see Fig. "Screenshot of a Wireshark recording").
Replacing the standard ethercat.dll enables Wireshark to read the ESL information, although Ethernet frames not containing ESL will no longer be recorded.
This dll file is available for download (Link) from the Beckhoff Website. The Wireshark installation already contains a EtherCAT.dll, as the case may be, this file does not support the ESL protocol yet. Once the existing Ethercat.dll in folder Wireshark/plugins/<build>/ has been replaced, this dissector (for breakdown) can be activated under Edit/Preferences (see Fig. "Activation of the ESL Dissector in "Wireshark""). The "Time" column of the Wireshark interface then displays the time stamp applied by the ET2000; otherwise the time at which the frame arrived at the PC's Gbit port is displayed.
File versions EtherCAT.dll • before release 1.0.2: modification of the WinPcap´driver necessary no support. • from release 1.0.2: download (Link) • from release 1.2.0: download (Link) • from release 1.6: already integrated in Wireshark, no futher re-installation necessary. |
The display resolution can be increased up to 1 ns under View/TimeDisplayFormat/.
Additional data (16 bytes) The ET2000 adds 16 additional bytes of data to the mirrored frame that is transferred to the recording PC. If the original frame already had the maximum length permitted by the Ethernet standard of 1500 bytes, it is possible that the PC's Gbit port might discard the frame, as it is now 1516 bytes long. It may be necessary to change settings for JumboPackets in the driver properties of the network port. |
Constitution of the16 additional bytes of data
The 16 byte additional data of the ET2000 have the following meaning (in serialization), see Fig. "From the ET2000 appended additional data in the ESL (EtherCAT Switch Link) protocol":
6 Byte | Identifier 01 01 05 10 00 00 (symbolic MAC address) |
---|---|
1 Byte | Port designation 0 ..7 of arriving frame
|
1 Byte | bit 0..2 reserved, |
8 Byte | Timestamp in ns (accuracy: 10 ns) - x000003EF4FDB83E0 (reading direction backwards) |
ET2000 extensions This is not a final description. Future development can cause a modification of the constitution of the additional data. In this case a corresponding version of the "ethercat.dll" will be provided on the Beckhoff website (http://www.beckhoff.com) |
Compensation of the minimal Ethernet frame length If there are only little process data in the EtherCAT protocol, e.g. in a small network with only a few participants, the rate of the user data is correspondingly low. Therefore, the EtherCAT frame is filled up with dummy bytes (x00) between the regular end of the frame and the ET2000 extension (16 bytes), to reach the minimal Ethernet frame length. |
Alignment error The ESL header indicates an alignment error if the recorded frame did not end on a byte boundary. The last byte of the frame data before the ESL header has to be ignored if the alignment error bit is set. |
Analysing EtherCAT datagrams
Fig. "Screenshot of a Wireshark recording" shows a log of EtherCAT frames from the TwinCAT EtherCAT master. Frame 348 is highlighted, and its content is broken down in the fields underneath. In the lower section of the central window, the EtherCAT datagrams contained in frame 348 are broken down with explanations.
Parser A specific parser is required in the <Wireshark installation directory>\plugins\<Version> directory for every network protocol that is to be analysed. These parsers can usually be obtained from the respective user organizations. |
Parser versions for Microsoft NetMon, Wireshark and Etherreal are available at present. Copy it to the directory mentioned above, and start Wireshark again. Wireshark can now display the EtherCAT datagrams as in Fig. "Screenshot of a Wireshark recording" .
Examples for filter settings and their effect
- "(esl.crcerror == 1) or malformed": Ethernet frames identified by the ET2000 as defective are displayed
- "ecat.adp==0x03ed and (ecat.ado==0x120 or ecat.ado==0x130)": State transitions of the EtherCAT slave are checked 0x03EDhex/1005d.
- "ecat_mailbox": only mailbox commands are displayed
- "((ecat.cmd==4)&&(frame.number>110)): all FPRD datagrams from the 110th Ethernet frame are displayed.
Please refer to the separate example.