[Ns-developers] 802.11 CW growth

Timo Bingmann timo.bingmann at student.kit.edu
Mon Feb 23 02:14:55 PST 2009


Hello guys,

>From dcf-manager.cc:
void 
DcfState::UpdateFailedCw (void)
{
  uint32_t cw = m_cw;
  cw *= 2;
  cw = std::min (m_cwMax, cw);
  m_cw = cw;
}

Am I mistaken or is there a +1 missing here?
I believe newCW = min(maxCW, 2 * (oldCW + 1) - 1)
= min(maxCW, 2 * oldCW + 1)

The usual CW sequence should be 7, 15, 31, 63, ...

Greetings
Timo



More information about the Ns-developers mailing list