SLAAEM2 October   2024 AM2434

 

  1.   1
  2.   Abstract
  3.   Trademarks
  4. 1Introduction
    1. 1.1 Real-Time Communication in Factories
    2. 1.2 Industrial Protocols
    3. 1.3 Serial and Ethernet-Based Communication Protocols
  5. 2Industrial Protocols
    1. 2.1 Ethernet-Based Communication Protocols
    2. 2.2 Network Topologies
    3. 2.3 OSI Layer Model
    4. 2.4 Industrial Ethernet System Block diagram
      1. 2.4.1 Two-Port Device
      2. 2.4.2 One-Port Controller
    5. 2.5 Ethernet Physical Layer (PHY)
    6. 2.6 Media Access Controller (MAC)
      1. 2.6.1 Device MAC
      2. 2.6.2 Controller MAC
    7. 2.7 Industrial Protocol Stacks
    8. 2.8 Industrial Communication Software Development Kit (SDK)
    9. 2.9 EtherCAT Device Example Using the AM243x Processor
  6. 3Conclusion

Device MAC

For a device, many times a three-port switch is used. A three-port switch refers to two physical ports, and one port that is connected to the host CPU over a shared memory interface.

The three-port switch does receive and transmit industrial Ethernet packets on the two physical ports. It makes forwarding decisions when receiving an Ethernet telegram from port one, to either put it into the shared RAM interface for the host CPU, or to send it out on Port two. Or it does both, putting the Ethernet frame into the shared RAM and forwarding it, in case the Ethernet frame is a broadcast frame.

Industrial Ethernet MAC for devices for industrial Ethernet typically work in one of the following frame processing modes shown in Table 2-3.

Table 2-3 Frame Processing Modes
MAC Frame Processing Mode Description Example
One-the-fly The Ethernet frame is getting processed by the MAC while it is getting received. The MAC can extract bytes of the Ethernet frame, or insert bytes into the Ethernet frame without altering the length. The MAC does update the CRC checksum at the end of the frame to reflect any modifications.
Typical port to port delay is less than 1µs in 100Mbps.
EtherCAT device
Cut-through The MAC receives the first couple of bytes of the Ethernet frame, typically 16 to 32 bytes. The MAC then analysis the destination MAC and Ethernet frame type to derive a forwarding decision. Once the destination port of the frame has been determined, the frame is getting forwarded, while the reception of the remainder of the packet is still ongoing.
The port 1 to port 2 delay depends on the Ethernet speed and is in the range of 1.5µs at Gbit speed and 4µs for 100Mbit speed.
PROFINET and EtherNet/IP
Store-and-forward This is a legacy MAC mode that is supported by many network interface cards (NIC) found in standard PCs.
The MAC receives the complete Ethernet frame and then only performs the forwarding decision.
Because of this, the port 1 to port 2 delay depends on the size of the Ethernet frame. At Gbit the forwarding delay is 12.5µs, for 100Mbit it is 125µs.
Standard Ethernet network cards

Table 2-4 shows additional MAC features that some industrial protocol use.

Table 2-4 MAC Features
MAC Mode Description Example
Time Triggered Send (TTS) This is a specific mode in the MAC to precisely time a transmission during the process cycle time.
The MAC pre-loads the Ethernet frame into the transmit FIFO together with a transmission time. Once the transmission time expires, the MAC starts the transmission. This method is used for imitating a specific mode time slot in a time synchronized architecture, as well as for time synchronization
EtherCAT controller, Profinet IRT, TSN
Time stamping The MAC captures time stamping for an received ethernet frame or an transmitted Ethernet frame. Timestamping occurs in the MAC. There are also Ethernet PHYs that include 1588 timestamping protocol.
IEEE1588 can be also done in the Ethernet stack on the processor side, or in the industrial Ethernet MAC.
IEEE 1588, Profinet PTCP, TSN gPTP,