Carrier Sense Multiple Access is a networking protocol that listens to network signals on the carrier/medium before transmitting any data. CSMA is implemented in Ethernet networks with more than one computer or network device attached to it. CSMA is part of the Media Access Control (MAC) protocol.
Carrier Sense Multiple Access/Collision Detection (CSMA/CD)
Carrier Sense Multiple Access/Collision Detection (CSMA/CD) is the most widely used transmission method used in half-duplex Ethernet networks. On Ethernet, any device can attempt to send a frame at any time. Each device senses whether the line is idle and therefore available to be used. If it is, the device begins to transmit its first frame. If another device has tried to send at the same time, a collision is said to occur and the frames are discarded. Each device then waits a random amount of time and retries until successful in getting its transmission sent.
Carrier Sense Multiple Access with Collision Avoidance
CSMA/CA (Carrier Sense Multiple Access/Collision Avoidance) is a method for carrier transmission in 802.11 networks. CMSA/CA uses a method similar to CSMA/CD to detect if the media is clear. CMSA/CA also uses additional techniques. This method does not detect collisions but attempts prevent collisions before happen. Each device that transmits includes the time duration that it needs for the transmission. All other wireless devices receive this information and know how long the medium will be unavailable.
In CSMA/CA, when a node receives a traffic that is to be sent, it checks to be sure that the channel is clear (no other node is transmitting at the time). If the channel is clear, then the packet is sent. If the channel is not clear, the node waits for a randomly chosen period of time and then checks again to see if the channel is clear. This period of time is called the backoff factor and is counted down by a backoff counter. If the channel is clear when the backoff counter reaches zero, the node transmits the packet. If the channel is not clear when the backoff counter reaches zero, the backoff factor is set again, and the process is repeated. Carrier sense multiple access with collision avoidance (CSMA/CA) is, the least popular of the access methods. This access method is now used with WLANs.