Mac and PHY process the least two layers of OSI Layer-7 network structure.
(1) PHY is responsible for electrical signal conversion, line status, data hard coding, etc.When sending data, phy receives data from MAC (for phy, there is no frame concept, and for it, it is data regardless of the address, data or CRC ), increase every 4 bits1-bit check error code, convert parallel data into serial stream data, and then according to the physical layer encoding rules (10based-t NRZ encoding or 100based-t Manchester encoding)Data Encoding, and then the analog signal to send the data. Otherwise.
(2) Mac is responsible for frame group, CRC verification, interface with IP protocol layer, addressing mechanism, etc.The data link layer chip in the ethernet card is called the Mac controller. Many NICs work together. The relationship between them is that the PCI bus is connected to the Mac bus, and the Mac is connectedPHY and PHY are connected to the network cable (of course they are not directly connected, and there is also a transformer device ).
(3) Media independent interface (MII) is a media-independent interface. 40 needles. The MII is similar to the 10 Mbps Ethernet connection Unit Interface (AUI ). The MII layer defines the standard electrical and mechanical interfaces between the 100base-t Mac and various physical layers. This standard interface is similar to the AuI in the classic Ethernet, which allows the manufacturer to manufacture products irrelevant to the media and wiring, use an external Mau to connect to the actual physical cable. The electrical signals of MII and AuI are different. The AuI signal is strong and can drive 50 meters of cables. The MII signal is digital and can only drive 0.5 meters of cables. MII uses a 40-core small connector similar to a SCSI connector.