Bugzilla – Bug 1677
The annotation of YansWifiPhy needs correction
Last modified: 2013-05-27 07:53:42 UTC
on src/wifi/model/yans-wifi-phy.h line 74 * Channel center frequency = Channel starting frequency + 5 MHz * (nch - 1) but as IEEE 802.11-2007 17.3.8.3.2 defines Channel center frequency = Channel starting frequency + 5 × nch (MHz) where nch = 0,1,…200 I don't know why here is nch-1. on src/wifi/model/yan-wifi-phy.c line 112 "Delay between two short frames transmitted on different frequencies. NOTE: Unused now.", but on line 363 m_state->SwitchToChannelSwitching (m_channelSwitchDelay); here m_channelSwitchDelay is used actually. because I think annotation is very important, so I want to correct them. If I misunderstood here, sorry to report this.
Hi Junling, thanks for your bug report! You're right in both cases: about the formula for the channel frequency, in fact YansWifiPhy::GetChannelFrequencyMhz () implements the formula as you reported. About ChannelSwitchDelay, the comment is clearly obsolete. Would you mind creating a patch updating the attribute descriptions and the comments in the code as needed?
Created attachment 1603 [details] update comments for yans-wifi-phy
Thanks! Just pushed: changeset: 9818:cfb12f56257a tag: tip user: Junling Bu <linlinjavaer@gmail.com> date: Mon May 27 13:45:39 2013 +0200 summary: fixed Bug 1677 - The annotation of YansWifiPhy needs correction