Switches in Local Networks

Now let’s learn what switches are and how to use them in a local network.

A switch enables the connection of multiple devices to the same network.

Note each network interface to the switch has its own dedicated PHY responsible for driving the signals on each wire.

switch.JPG

The uplink port on a switch is the same as the regular ports except that the Tx and Rx signals are reversed. This means a crossover cable is not required to connect one switch to another. Most new switches have Auto-MDIX interfaces which automatically switch the Tx and Rx signals if needed.

Switches Inside Routers

Most routers for home and small business have a built-in switch.

switch_router.JPG

Switches use MAC Addresses

We’ve seen how routers use IP addresses to address hosts on the network. Switches don’t have the intelligence to use IP addresses. They instead use something called a MAC address.

switch_mac.JPG

A switch uses a Media Access Controller or MAC to forward and filter data based on a host’s MAC address, not its IP address.

The Media Access Controller (MAC) controls Layer 2 network functions. It forwards and filters frames based on their MAC addresses.

Every network host has two addresses:
1) IP Address (Layer 3 virtual address)
2) MAC Address (Layer 2 physical address)

A switch has a Media Access Controller, but no MAC address. It is transparent to the network. It is never the final destination for network traffic, so it doesn’t need a MAC address. A router on the other hand has two MAC addresses, one used for the local network or LAN, and one used for the Internet or WAN.

Switches are referred to as Layer 2 devices because they work with Layer 2 (MAC) addresses only. routers are referred to as Layer 3 devices because they work with Layer 3 (IP) addresses only.

The MAC is responsible for generating the frames that will be sent to the network, and receiving frames that come in from the network. Frames that are received on a network node that don’t contain the node’s MAC address or MAC broadcast address (FF:FF:FF:FF:FF:FF) are not forwarded up to Layer 3.

The MAC allows multiple devices to access the same physical network using CSMA/CD (Carrier Sense Multiple Access/ with Collision Detection (Ethernet)), or CSMA/CA (with Collision Avoidance (WLAN)).

20th Annual
Microchip MASTERs Conference 2016
Register now - Deadline: July 29

JW Marriott Desert Ridge Resort-Phoenix, AZ

© 2016 Microchip Technology, Inc.
Information contained on this site regarding device applications and the like is provided only for your convenience and may be superseded by updates. It is your responsibility to ensure that your application meets with your specifications. MICROCHIP MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND WHETHER EXPRESS OR IMPLIED, WRITTEN OR ORAL, STATUTORY OR OTHERWISE, RELATED TO THE INFORMATION, INCLUDING BUT NOT LIMITED TO ITS CONDITION, QUALITY, PERFORMANCE, MERCHANTABILITY OR FITNESS FOR PURPOSE. Microchip disclaims all liability arising from this information and its use. Use of Microchip devices in life support and/or safety applications is entirely at the buyer's risk, and the buyer agrees to defend, indemnify and hold harmless Microchip from any and all damages, claims, suits, or expenses resulting from such use. No licenses are conveyed, implicitly or otherwise, under any Microchip intellectual property rights.