[ns] Can a node receive a packet while carrier sensing?
Shen Ren
isc10487 at nus.edu.sg
Tue Nov 16 05:40:48 PST 2004
it discard the packet if the channel is busy. as u could see right starting at the swtich sentence
int
Mac802_11::check_pktCTRL()
{
struct hdr_mac802_11 *mh;
double timeout;
if(pktCTRL_ == 0)
return -1;
if(tx_state_ == MAC_CTS || tx_state_ == MAC_ACK)
return -1;
mh = HDR_MAC802_11(pktCTRL_);
switch(mh->dh_fc.fc_subtype) {
/*
* If the medium is not IDLE, don't send the CTS.
*/
case MAC_Subtype_CTS:
if(!is_idle()) {
discard(pktCTRL_, DROP_MAC_BUSY); pktCTRL_ = 0;
return 0;
}
SET_TX_STATE(MAC_CTS);
/*
* timeout: cts + data tx time calculated by
* adding cts tx time to the cts duration
* minus ack tx time -- this timeout is
* a guess since it is unspecified
* (note: mh->dh_duration == cf->cf_duration)
*/
timeout = txtime(ETHER_CTS_LEN, basicRate_)
+ DSSS_MaxPropagationDelay // XXX
+ sec(mh->dh_duration)
+ DSSS_MaxPropagationDelay // XXX
- sifs_
- txtime(ETHER_ACK_LEN, basicRate_);
break;
/*
* IEEE 802.11 specs, section 9.2.8
* Acknowledments are sent after an SIFS, without regard to
* the busy/idle state of the medium.
*/
case MAC_Subtype_ACK:
SET_TX_STATE(MAC_ACK);
timeout = txtime(ETHER_ACK_LEN, basicRate_);
break;
default:
fprintf(stderr, "check_pktCTRL:Invalid MAC Control subtype\n");
exit(1);
}
TRANSMIT(pktCTRL_, timeout);
return 0;
}
-----Original Message-----
From: ns-users-bounces at ISI.EDU on behalf of Athanasia Tsertou
Sent: Tue 11/16/2004 7:26 PM
To: ns-users at ISI.EDU
Cc:
Subject: [ns] Can a node receive a packet while carrier sensing?
Hello everyone,
I have a technical question regarding the IEEE 802.11 standard. Suppose that we
have the following situation.
A >---------------------< B >---------------------< C
A sends an RTS to B which is received correctly. Now, during the SIFS period
that B waits before answering with a CTS, C decides to transmit an RTS packet.
The standard says that due to Carrier Sensing B will find the channel busy and
will not send a CTS back to A. My question is: What does sensing really mean?
Does it mean that B actually receives the RTS from C correctly, so after
RTS+SIFS it responds to C with a CTS?
Thank you in advance
Athanasia
--
Athanasia Tsertou
Signals and Systems Group
School of Engineering and Electronics
The University of Edinburgh
King's Buildings, Mayfield Rd,Edinburgh EH9 3JL
More information about the Ns-users
mailing list