Bugzilla – Bug 706
Backoff counting when starting NS.
Last modified: 2010-01-13 07:49:37 EDT
You need to log in before you can comment on or make changes to this bug.
Created an attachment (id=621) [details] Proposed fix. When the packet is received, DcaTxop must start backoff immediately, but when we initiate our simulation, the backoff is not counted. So, I suppose to add starting backoff in constructor of DcaTxop and in SetMinCw method, because inside constructor MinCw may be incorrect.
The risk is that m_cw will not be initialized correctly when the constructor is invoked. I suspect that the best way to do this would be to use the Object::DoStart method I introduced a couple of days ago and move the code you introduced here instead: void DcaTxop::DoStart (void) { // XXX... start backoff // chainup Dcf::DoStart (); } And, then, you need to make sure that the MAC layer which creates the DcaTxop class calls its Start method: void NqapWifiMac::DoStart (void) { m_beaconDca->Start (); m_dca->Start (); // chainup WifiMac::DoStart (); } and the same modification in all other WifiMac subclasses.
Created an attachment (id=684) [details] Fix with DoStart
If you have tested this and it works, please, commit.
changeset 5903 395e17028faf