Carrier sense multiple access collision
detect (CSMA/CD) describes the Ethernet access method. In Ethernet,
multiple
access is the terminology for many stations attaching
to the same cable and having the opportunity to transmit. No station has
any priority over any other station. However, the stations do need to
take turns, as defined by the access algorithm.
Carrier sense refers to the process of listening
before speaking. The Ethernet device wishing to communicate looks for
energy on the media (an electrical carrier). If a carrier exists, the
cable is in use and the device must wait to transmit. Many Ethernet
devices maintain a counter of how many times they have to defer a
transmission. Some devices call the counter a deferral or back-off
counter. If the deferral counter exceeds a threshold value of 15
retries, the device attempting to transmit assumes that it will never
get access to the cable to transmit the packet. In this situation, the
source device discards the frame. This might happen if there are too
many devices on the network, implying that there is not enough bandwidth
available.
When two or more devices, on the same segment, attempt
to transmit at the same time, a collision occurs. The devices that were
transmitting can sense that a collision has occurred because the power
level on the cable exceeds a certain mark. When stations detect that a
collision has occurred, the participants generate a collision
enforcement signal. The enforcement signal lasts as
long as the smallest frame size. In the case of Ethernet, that equates
to 64 bytes. This ensures that all stations know about the collision and
that no other station attempts to transmit during the collision event.
If a station experiences too many consecutive collisions, the station
stops attempting to transmit the frame. Some workstations display an
error message to the user; the exact message differs from platform to
platform, but every workstation attempts to convey to the user that it
was unable to send data for one reason or another.