Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Ethernet

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

Ethernet (Layer 1/Layer2)

I. Introduction:

Ethernet is a widely used technology for local area networks (LANs) that facilitates
communication between devices. Here are some key points about Ethernet:

1. Definition: Ethernet is a set of networking technologies that defines how data is


transmitted over a wired network. It is the most common LAN technology.

2. Standardization: Ethernet standards are defined by the Institute of Electrical and


Electronics Engineers (IEEE) under the 802.3 protocol.

3. Physical Medium: Ethernet typically uses twisted pair cables (like Cat5e, Cat6) or fiber
optic cables for data transmission. Wireless variants exist (Wi-Fi), but traditional Ethernet
is wired.

4. Data Transmission: Ethernet transmits data in packets. Each packet contains a header
with source and destination MAC addresses, along with the actual data payload.

5. Speed: Ethernet has evolved through various standards, with speeds ranging from 10
Mbps (10BASE-T) to 100 Gbps (100GBASE-SR). Common speeds today are 100 Mbps
(Fast Ethernet), 1 Gbps (Gigabit Ethernet), and 10 Gbps (10-Gigabit Ethernet).

6. Topology: Ethernet networks can be set up in di erent topologies, including star, bus, and
ring. The star topology is the most common in modern networks, where devices connect
to a central switch or hub.

7. Collision Detection: Early Ethernet used a method called Carrier Sense Multiple Access
with Collision Detection (CSMA/CD) to manage data transmission and prevent packet
collisions. Modern Ethernet, particularly with switches, largely eliminates collisions.

8. Network Switches: Ethernet networks often use switches to direct data packets to
specific devices rather than broadcasting to all devices on the network, enhancing
e iciency.

9. Interoperability: Ethernet is compatible with various network protocols, allowing for


diverse devices and applications to communicate seamlessly.

10. Applications: Ethernet is used in home networks, corporate networks, data centers, and
industrial applications due to its reliability and scalability.

Ethernet continues to evolve, with ongoing developments aimed at increasing speed, e iciency,
and the ability to support more devices in larger networks.

II. OSI model

The OSI (Open Systems Interconnection) model is a conceptual framework used to understand
and implement network communication between di erent systems. It divides the
communication process into seven layers, each with a specific function. Here are the details of
each layer:

1. Physical Layer (Layer 1)


 Function: Responsible for the transmission of raw binary data over a physical medium
(e.g., cables, radio frequencies).

 Components: Cables, switches, network adapters, and other physical transmission


hardware.

 Protocols/Technologies: Ethernet (physical aspects), USB, Bluetooth, etc.

2. Data Link Layer (Layer 2)

 Function: Provides node-to-node data transfer and handles error correction from the
physical layer.

 Components: Network interfaces, switches, MAC (Media Access Control) addresses.

 Protocols: Ethernet (data link aspects), PPP (Point-to-Point Protocol), Frame Relay.

3. Network Layer (Layer 3)

 Function: Responsible for routing data packets between devices across di erent
networks.

 Components: Routers, logical addressing (e.g., IP addresses).

 Protocols: IP (Internet Protocol), ICMP (Internet Control Message Protocol), OSPF (Open
Shortest Path First).

4. Transport Layer (Layer 4)

 Function: Ensures reliable data transfer with error checking and flow control, segmenting
data for transport.

 Components: Ports and sockets.

 Protocols: TCP (Transmission Control Protocol), UDP (User Datagram Protocol).

5. Session Layer (Layer 5)

 Function: Manages and controls the dialog between two computers, establishing,
maintaining, and terminating connections.

 Protocols: NetBIOS, RPC (Remote Procedure Call), PPTP (Point-to-Point Tunneling


Protocol).

6. Presentation Layer (Layer 6)

 Function: Translates data between the application layer and the network, handling data
encryption, compression, and conversion.

 Protocols/Technologies: SSL/TLS (encryption), MIME (Multipurpose Internet Mail


Extensions).

7. Application Layer (Layer 7)

 Function: Provides end-user services and interfaces directly with the application
software.
 Protocols: HTTP (Hypertext Transfer Protocol), FTP (File Transfer Protocol), SMTP (Simple
Mail Transfer Protocol), DNS (Domain Name System).

Summary

Each layer of the OSI model serves as an independent set of functions that interact with the layers
directly above and below it, enabling a modular approach to network design and troubleshooting.

III. Ethernet from the perspective of OSI model:

Ethernet primarily operates at the Data Link Layer (Layer 2) and the Physical Layer (Layer 1) of
the OSI model.

1. Physical Layer (Layer 1)

 Function: Defines the hardware standards for the physical connection, such as cables,
connectors, and transmission methods.

 Ethernet Role: Specifies how bits are transmitted over a medium (e.g., copper wires, fiber
optics), including standards like 10BASE-T, 100BASE-TX, 1000BASE-T, etc., for di erent
speeds and cable types.

2. Data Link Layer (Layer 2)

 Function: Manages node-to-node data transfer, ensuring data frames are reliably
transferred between devices on the same network.

 Ethernet Role: Defines the structure of Ethernet frames, including source and
destination MAC addresses, frame size, and error-checking mechanisms (CRC).

 The Data Link layer for Ethernet is divided into two sublayers:

 MAC (Media Access Control): Manages access to the physical medium,


handles frame synchronization, and prevents collisions.

 LLC (Logical Link Control): Provides flow and error control, though it's
less prominent in Ethernet as MAC handles most functions.

These two layers allow Ethernet to establish a reliable link between devices, transmitting data
packets over the physical network and ensuring accurate delivery.

IV. Ethernet Frame:

An Ethernet frame has a specific structure that helps in organizing and transmitting data over a
network. Here’s a breakdown of each field in a standard Ethernet frame:

1. Preamble (7 bytes)

 Purpose: A sequence of alternating 1s and 0s used for synchronization. It allows receiving


devices to prepare for an incoming frame.

 Value: 7 bytes (56 bits) of alternating 1s and 0s.

2. Start Frame Delimiter (SFD) (1 byte)

 Purpose: Marks the end of the preamble and indicates the start of the frame.
 Value: 1 byte (10101011 in binary).

3. Destination MAC Address (6 bytes)

 Purpose: The unique MAC address of the receiving device or destination.

 Value: 6 bytes, specifying the address to which the frame is sent.

4. Source MAC Address (6 bytes)

 Purpose: The unique MAC address of the sending device or source.

 Value: 6 bytes, identifying the device that sent the frame.

5. EtherType / Length (2 bytes)

 Purpose: Defines either the type of protocol (e.g., IPv4, IPv6, ARP) or the length of the
payload data in bytes.

 Value: 2 bytes. If value > 1536 (0x0600), it indicates EtherType; if ≤ 1500, it indicates
length.

6. Payload / Data (46–1500 bytes)

 Purpose: Contains the actual data being transmitted, which could be an IP packet or
other higher-level protocol data.

 Size: Minimum of 46 bytes and a maximum of 1500 bytes. If the data is less than 46 bytes,
padding is added to meet the minimum.

7. Frame Check Sequence (FCS) (4 bytes)

 Purpose: Provides error-checking using a CRC (Cyclic Redundancy Check) to ensure the
frame’s integrity. The sender computes the CRC and attaches it to the frame; the receiver
verifies it to check for errors.

 Value: 4 bytes.

Summary of Ethernet Frame Fields

Field Size Description

Preamble 7 bytes Synchronization for the receiver

SFD 1 byte Indicates start of frame

Destination MAC 6 bytes MAC address of destination device

Source MAC 6 bytes MAC address of sending device

EtherType/Length 2 bytes Protocol type or data length

Payload/Data 46-1500 bytes Data being transmitted, with padding if needed

FCS 4 bytes CRC for error checking


This structure enables reliable communication between devices on an Ethernet network by
defining clear boundaries, addressing, and error-checking mechanisms.

V. Error Detection

Error checking mechanisms using polynomial division are essential in digital communication to
ensure data integrity. The most common method using polynomial division is Cyclic
Redundancy Check (CRC). Here’s a detailed breakdown of how this mechanism works:

1. Basic Concept
 In CRC, data is treated as a large binary number (or polynomial) that is divided by a fixed
binary divisor, known as the generator polynomial.
 The remainder from this division is called the CRC code and is appended to the original
data to form a transmitted frame.
 On the receiver's side, the received data (data + CRC) is divided by the same generator
polynomial. If the remainder is zero, the data is assumed to be error-free; otherwise, an
error is detected.
2. Polynomial Representation
 Data bits are represented as coe icients of a polynomial. For example, the binary
sequence 1101 is represented as x3+x2+1 (skipping terms with zero coe icients).
 The generator polynomial is a fixed polynomial chosen to detect specific types of errors.
Common examples include:
o CRC-8: x8+x2+x+1
o CRC-16: x16+x15+x2+1
o CRC-32: x32+x26+x23+…+1
3. Division Process (Sender Side)
 The original data polynomial D(x) is appended with zeros corresponding to the degree of
the generator polynomial G(x).
 This modified data is divided by G(x) using binary long division, where operations are
performed using XOR instead of subtraction.
 The remainder R(x)from this division is the CRC code. It is appended to the original data
to form the transmitted frame T(x)=D(x)*xk + R(x) , where k is the degree of G(x).
4. Division Process (Receiver Side)
 The received frame T(x) is divided by the same generator polynomial G(x).
 If the remainder R′(x) is zero, it indicates that the received data is error-free.
 If R′(x) is non-zero, this suggests that an error occurred during transmission.
5. Error Detection Capabilities
CRC can detect:
 Single-bit errors: A CRC with a generator polynomial G(x) having nonzero coe icients for
both x0 (constant term) and xk (highest degree) can detect any single-bit error.
 Double-bit errors: Most generator polynomials can detect double-bit errors as long as it
has at least three terms.
 Odd number of errors: A polynomial with x + 1 as a factor ensures detection of all odd
numbers of errors.
 Burst errors: CRCs are particularly e ective at detecting burst errors (i.e., sequences of
consecutive bit errors) up to the length of the generator polynomial.
6. Example Calculation
Suppose we are transmitting the 4-bit data 1101 using a generator polynomial
G(x)=x3+x+1 (binary: 1011).
Step-by-step CRC Calculation:
1. Append 3 zeros to 1101 (because G(x) is of degree 3): 1101000.
2. Divide 1101000 by 1011 using binary long division.
3. Compute the remainder after division (e.g., 011).
4. Transmit 1101 + 011 = 1101011.
Verification:
 The receiver takes 1101011 and divides it by 1011.
 If the remainder is zero, the data is considered valid.
7. Properties of Generator Polynomials
The e ectiveness of CRC depends on the choice of the generator polynomial:
 Length: A longer generator polynomial (e.g., 32-bit) can detect more complex error
patterns.
 Structure: Polynomials with specific characteristics can be used to ensure detection of
common error types, such as burst errors of a certain length.
8. Benefits and Limitations
Benefits:
 High error-detection capability with low computational overhead.
 Widely implemented in hardware for fast real-time error checking.
Limitations:
 CRCs can only detect errors, not correct them.
 The method might not detect errors if the error pattern matches the generator polynomial.

In summary, CRC is an e ective error detection mechanism that leverages polynomial


division to ensure data integrity in digital communication. The choice of generator polynomial
determines the type and extent of error patterns that can be detected.

VI. Ethernet encoding:

In Ethernet, encoding techniques translate binary data (1s and 0s) into electrical signals or
voltage levels to transmit data over a physical medium

1. 10 Mbps Ethernet (10BASE-T)

The encoding and signaling techniques are simple. Here’s a breakdown of the techniques
involved:

 Standard: 10BASE-T refers to Ethernet over twisted-pair cabling, typically Cat3 or better,
with a maximum length of 100 meters between devices.

 Speed: 10 Mbps (megabits per second).

 Duplex: Supports both half-duplex and full-duplex modes, though half-duplex was more
common in early implementations.

a) Encoding and Signaling Techniques

1. Manchester Encoding:

 Encoding Scheme: 10BASE-T uses Manchester encoding, which is a type of bi-


phase-level encoding.

 Signal Representation:

 Each bit is represented by a transition within a single clock cycle.


 A 0 is represented by a transition from high to low.

 A 1 is represented by a transition from low to high.

 Clock Synchronization: Manchester encoding embeds the clock signal within


the data signal, which helps synchronize the sender and receiver. This ensures
that the receiver can accurately interpret the incoming bits without a separate
clock channel.

 Bandwidth Usage: The encoding scheme doubles the frequency of the signal
compared to the data rate. For 10 Mbps data transmission, the signal requires a
20 MHz bandwidth.

2. Signal Characteristics:

 Baseband Transmission: 10BASE-T transmits signals using baseband


transmission, meaning the entire bandwidth of the medium is used to carry
Ethernet frames without modulation onto higher carrier frequencies.

 Voltage Levels: Manchester encoding uses two voltage levels to represent data,
typically 0V and a positive voltage (e.g., +5V or +2.5V).

b) Advantages and Limitations of Manchester Encoding:

 Advantages:

 Clock Recovery: The embedded clock signal makes it easier for the receiver to
stay synchronized with the transmitter, ensuring reliable data transfer.

 Simplicity: Manchester encoding is simple to implement in hardware and


provides clear signal transitions.

 Limitations:

 Bandwidth Ine iciency: Because Manchester encoding requires a transition for


every bit, the signal bandwidth is twice the data rate (e.g., 20 MHz for 10 Mbps).
This makes it less bandwidth-e icient compared to more advanced encoding
schemes used in faster Ethernet standards.
 Higher Power Consumption: The frequent transitions result in higher power
usage compared to encoding schemes with fewer transitions.

c) Summary:

10BASE-T (10 Mbps Ethernet) uses Manchester encoding, which is robust for ensuring reliable
data transfer and synchronization but requires more bandwidth than modern encoding schemes.
This technique laid the groundwork for Ethernet communication and remains simple and
e ective for low-speed network communication.

2. 100 Mbps (Fast Ethernet)

The encoding method used is 4B/5B with MLT-3 signaling.

Here’s a breakdown of the encoding process for 100 Mbps Fast Ethernet:

a) 4B/5B Encoding

 Purpose: Converts 4-bit data blocks into 5-bit symbols to ensure su icient transitions in
the signal, which helps with synchronization and reduces long runs of zeros that can
cause issues in signal recovery.

 Process: Each 4-bit group (nibble) of binary data is mapped to a 5-bit code. For example:

 0000 maps to 11110

 0001 maps to 01001

 1111 maps to 11111

 Result: The 4B/5B encoding expands data by 25%, but ensures there are no long runs of
zeros, aiding in clock recovery.

b) Multilevel Transmission - 3 (MLT-3) Signaling

 Purpose: Converts the 5-bit encoded data into electrical signals for transmission over
twisted-pair cables, using three voltage levels: +V, 0, and -V.

 Operation:

 MLT-3 alternates between +V, 0, and -V to represent data changes.

 A transition only occurs if a binary 1 is present; binary 0 results in no change in the


signal level.

 This approach reduces the signal’s frequency, limiting electromagnetic


interference (EMI) and allowing for e icient transmission at 100 Mbps.

Example: Putting It All Together

If the original data stream is 0000 0001:

 First, the 4-bit nibbles are converted using 4B/5B encoding:

 0000 becomes 11110

 0001 becomes 01001


 The resulting 10-bit sequence 11110 01001 is then sent using MLT-3 signaling.

In summary, 4B/5B encoding ensures reliable transitions and signal synchronization, while MLT-
3 reduces EMI by lowering the frequency of signal changes. Together, they provide e icient, high-
speed data transmission over Ethernet at 100 Mbps.

3. 1Gbps/10Gbps

These higher-speed Ethernet standards require more advanced encoding and modulation
techniques to handle the increased data rates. Here’s how these standards di er:

a) 1 Gbps Ethernet (1000BASE-T)

 1000BASE-T uses a combination of PAM-5 (Pulse Amplitude Modulation with 5


levels) and echo cancellation.

 PAM-5: Transmits data using 5 distinct voltage levels per signal. Each level
represents more than 1 bit per symbol, allowing data to be transmitted e iciently
over all four wire pairs simultaneously.

 Parallel Transmission: 1000BASE-T splits the data stream and sends it over all
four pairs of wires in a twisted-pair cable, achieving full-duplex transmission.
Each pair carries 250 Mbps, combining to achieve 1 Gbps.

 Advanced Signal Processing: Techniques like echo cancellation and crosstalk


mitigation are used to ensure that each pair can transmit and receive data
simultaneously without interference.

b) 10 Gbps Ethernet (10GBASE-T)

 Encoding Technique: 10GBASE-T uses PAM-16 (Pulse Amplitude Modulation with 16


levels) in combination with advanced digital signal processing (DSP).

 PAM-16: This encoding method represents data using 16 distinct voltage levels,
allowing more data to be transmitted per symbol than simpler modulation
schemes like PAM-5.

 Modulation Complexity: The use of 16 levels increases the complexity but


enables higher data rates.

 Full-Duplex and All Four Pairs: Similar to 1000BASE-T, 10GBASE-T transmits data over
all four twisted-pair cable pairs simultaneously, with sophisticated DSP used to handle
echo cancellation, crosstalk suppression, and other signal integrity challenges.

Why 4B/5B Encoding and MLT-3 Are Not Used:

 E iciency: The 4B/5B encoding used in 100BASE-TX results in a 25% increase in


bandwidth usage due to the overhead of mapping 4-bit data to 5-bit symbols. While it’s
adequate for 100 Mbps, it is not e icient for gigabit or higher data rates.

 Signaling Limitations: MLT-3 signaling works well for 100 Mbps but can't support the
bandwidth needed for 1 Gbps or higher. It operates at a lower frequency and uses simpler
modulation, making it unsuitable for the high data throughput of modern Ethernet
standards.
Summary:

 100 Mbps (100BASE-TX): Uses 4B/5B encoding and MLT-3 signaling.

 1 Gbps (1000BASE-T): Uses PAM-5 modulation and advanced DSP techniques like echo
cancellation.

 10 Gbps (10GBASE-T): Uses PAM-16 modulation with even more advanced DSP for
higher data rates and signal processing.

These higher-speed Ethernet standards have evolved to include more complex modulation and
signal processing methods that support the higher bandwidth and maintain signal integrity over
twisted-pair cabling.

You might also like