Carrier Sense Multiple Access (CSMA) is a probabilistic network protocol for the data link (MAC) layer. A node that wants to transmit a data packet performs a channel cleanliness assessment procedure, that is, it listens for noise in the transmission medium for a predetermined period of time. If the transmission medium is judged clean, the node may transmit a data packet. Otherwise, if another transmission is performed, the node is “suspended”, that is, it waits a certain amount of time before the packet sending procedure is again undertaken.
In practice, a modification of this CSMA / CD technology that supports collision recognition is more common. There is also CSMA / CA technology that tries to avoid collisions.
Appearance History
An early network like ALOHAnet , operating in Hawaii since 1970 , used a radio channel and a satellite-mounted repeater (hence the word “carrier” in the method name), as well as a relatively simple CSMA access method without collision detection. In networks such as Ethernet and Fast Ethernet , the clock acts as a carrier, “mixed” with the transmitted data in such a way as to ensure reliable synchronization at the receiving end. This is achieved through the organization (if necessary) of additional forced signal transitions between two (as in the Manchester II code) or three electric levels (as in the 8B6T type code used in the 100BASE-T4 segment based on four unshielded twisted pairs).
CSMA Types
- 1-persistent CSMA
When the station is ready to transmit data, it listens to the channel. If the channel is free, the frame is transmitted. If the channel is busy, then the station waits until the channel is free, then immediately starts transmitting data. In the event of a collision, the station waits for a random time interval, then again listens to the channel and, if it is free, tries to transmit the frame again.
- Unstable CSMA
When the station is ready to transmit data, it listens to the channel. If the channel is free, the frame is transmitted. If the channel is busy, then the station waits for a random time interval, and then listens to the line again. When a collision occurs, the station does the same as in the case of 1-persistent CSMA.
- p-persistent CSMA
This protocol is used in discrete channels. When the station is ready to transmit, it polls the channel. If the channel is free, it starts with transmission with probability p . With a 1-p probability, she refuses to transmit and waits for the start of the next measure. The process is repeated until a frame is transmitted or another station starts transmitting. In the latter case, the station does the same as in the event of a collision : it waits for a random time interval, after which it starts all over again. If during the first listening to the channel it is busy, the station waits for the next time interval, after which the same algorithm is applied.
See also
- CSMA / CA
- CSMA / CD
- Distributed coordination function
- Alohnet
- Arbitration (in data transfer)