Understanding the Real-World Implications of Carrier Sense

Frequently Asked Questions

1. How do you actually turn off the carrier sensing in the madwifi driver?

Use the openhal Linux port from: http://pdos.csail.mit.edu/~jbicket/openhal/ and modify the value for AR5K_INIT_CARR_SENSE_EN in ah.h.

This mechanism came after our paper. Thus, we didn't disable carrier sense in our experiments. Instead, we disable random backoff, which synchronizes transmission times so that the cards don't hear each others' transmissions. This forces the cards' transmissions to collide, even though the cards are well within radio range of each other, thus giving an effect as if carrier sense has been disabled.

We've set up the experiment in our paper so that each sender has a backlog of packets to send and each sender transmits packets of the same length. In the begining, the transmissions are not synchronized so one of the senders transmits first while the other defers due to carrier sense. After the first transmission, both senders senses the carrier to be free at the same time. Because random backoff is disabled, both senders delays the same amount of time, during which the carrier is sensed-free. After this delay, both senders transmit at the exact same time and also finish the transmission at the same time (due to same packet length). Thus, all subsequent transmissions are perfectly synchronized, resulting in collisions of transmissions that overlap exactly with one another.

So ironically, we rely on carrier sense to (synchronize the cards after the first transmission) to give the effect of disabling carrier sense.

To force collisions as described above, we disabled random backoff. One can do this by OR-ing the following flag in the ath_attach function defined in the if_ath.c file of the MADWiFi driver:

qInfo.tqi_qflags |= TXQ_FLAG_BACKOFF_DISABLE