The media access control (MAC) is
responsible for managing protocol access to the physical network medium. The main
functions consist of:
- Addressing: Each device on the
Ethernet network has a unique MAC address, a 48-bit identifier used to
distinguish devices on a network. The MAC makes sure that data packets are
delivered to the correct device.
- Frame Delimiting: The MAC
sublayer defines the frame structure used for data transmission. An Ethernet
frame includes a preamble, destination MAC address, source MAC address,
type/length field, data payload and frame check sequence (FCS).
- Media Access Control: The MAC
sublayer controls how devices access the shared communication medium. Industrial
Ethernet MAC derive here from standard Ethernet MAC, and even implement specific
operation modes like on-the-fly processing and cut-though data processing. Those
methods are explained later in this section.
- Error Detection: The MAC sublayer
includes mechanism for detecting errors in receive frames, typically using the
Frame Check Sequence (FCS). If an error is detected, the frame is typically
discarded and upper layer is getting notified.
- Frame Transmission and Reception:
The MAC sublayer handles the actual transmission and reception of frames over
the network medium (layer 1). This makes sure that frames are properly
formatted, addressed, and send at the correct time. Some IE protocols have
different transmission phases, one phase for real-time data (process data), and
second one for non-real-time data (standard Ethernet frames). This transmission
phases are time multiplexed and referred to as cycle time.