NS3 部分类简单说明

1.class DcaTxop : public Dcf

/**
 * \brief handle packet fragmentation and retransmissions.
 * \ingroup wifi
 *
 * This class implements the packet fragmentation and
 * retransmission policy. It uses the ns3::MacLow and ns3::DcfManager
 * helper classes to respectively send packets and decide when
 * to send them. Packets are stored in a ns3::WifiMacQueue until
 * they can be sent.
 *
 * The policy currently implemented uses a simple fragmentation
 * threshold: any packet bigger than this threshold is fragmented
 * in fragments whose size is smaller than the threshold.
 *
 * The retransmission policy is also very simple: every packet is
 * retransmitted until it is either successfully transmitted or
 * it has been retransmitted up until the ssrc or slrc thresholds.
 *
 * The rts/cts policy is similar to the fragmentation policy: when
 * a packet is bigger than a threshold, the rts/cts protocol is used.
 */

简要说明:处理包的分组和重传
该类继承包分组和重传策略。它使用ns3::MacLow and ns3::DcfManager帮助类分别完成发送包和决定何时发送包。包被存储在ns3::WifiMacQueue中,止到发送出去。
当前使用的策略使用一个简单的分组阈值:任何大于该阈值的片将被分成小于该阈值的分组。
重传策略也非常简单:每一个包竟被重传止到被成功传输或者已经被重传达到了ssrc or slrc阈值。
rts/cts策略与分组碎片策略相似:当一个包大于阈值时,将使用rts/cts协议。

2.class MacRxMiddle

/**
 * \ingroup wifi
 *
 * This class handles duplicate detection and recomposition of fragments.
 */

该类处理重复探测和分组片的重排。

3. class MacTxMiddle

/**
 * \ingroup wifi
 *
 * Handles sequence numbering of IEEE 802.11 data frames
 */

处理802.11数据帧的序列号

4. class MacLow : public Object

/**
 * \ingroup wifi
 * \brief handle RTS/CTS/DATA/ACK transactions.
 */

处理RTS/CTS/DATA/ACK交互

5. class DcfManager

/**
 * \brief Manage a set of ns3::DcfState
 * \ingroup wifi
 *
 * Handle a set of independent ns3::DcfState, each of which represents
 * a single DCF within a MAC stack. Each ns3::DcfState has a priority
 * implicitely associated with it (the priority is determined when the
 * ns3::DcfState is added to the DcfManager: the first DcfState to be
 * added gets the highest priority, the second, the second highest
 * priority, and so on.) which is used to handle "internal" collisions.
 * i.e., when two local DcfState are expected to get access to the
 * medium at the same time, the highest priority local DcfState wins
 * access to the medium and the other DcfState suffers a "internal"
 * collision.
 */

简要说明:处理一系列ns3::DcfState
处理一系列独立的ns3::DcfState,每一个都代表一个在MAC栈中的单独的DCF。每一个ns3::DcfState都有一个隐式关联与他的优先级(当ns3::DcfState被添加到DcfManager,这个优先级被决定:第一个添加的DcfState具有最高优先级,第二个具有第二高优先级,以此类推)。这个优先级被用于处理“内部的”的碰撞。例如,当两个本地DcfState期望在同一时间访问介质,最高优先级本地DcfState赢得访问介质权限,其他DcfState遭遇一个“内部的”碰撞。

6. class WifiRemoteStationManager : public Object

/**
 * \ingroup wifi
 * \brief hold a list of per-remote-station state.
 *
 * \sa ns3::WifiRemoteStation.
 */

保存一系列per-remote-station state

7. class EdcaTxopN : public Dcf

/**
 * \ingroup wifi
 * This queue contains packets for a particular access class.
 * possibles access classes are:
 *
 *   -AC_VO : voice, tid = 6,7         ^
 *   -AC_VI : video, tid = 4,5         |
 *   -AC_BE : best-effort, tid = 0,3   |  priority
 *   -AC_BK : background, tid = 1,2    |
 *
 * For more details see section 9.1.3.1 in 802.11 standard.
 */

这个队列包含了一个具体的访问类的包。可能的访问类是:
-AC_VO : voice, tid = 6,7 ^
-AC_VI : video, tid = 4,5 |
-AC_BE : best-effort, tid = 0,3 | priority
-AC_BK : background, tid = 1,2 |
获取更多细节,请看802.11标准的9.1.3.1节

8. enum TypeOfStation

/**
 * Enumeration for type of station
 */

枚举station的类型:
STA,
AP,
ADHOC_STA,
MESH,
HT_STA,
HT_AP,
HT_ADHOC_STA,
OCB

9. class WifiMode

/**    
 * \brief represent a single transmission mode
 * \ingroup wifi 
 *
 * A WifiMode is implemented by a single integer which is used
 * to lookup in a global array the characteristics of the
 * associated transmission mode. It is thus extremely cheap to
 * keep a WifiMode variable around.
 *
 * \see attribute_WifiMode
 */  

简要说明:代表一个单独的传输模式
一个WiFi模式是由用于在一个全局数组来查找相关的传输模式的特性的单个整数来实现的。这是极其因此便宜*保持无线模式变量左右。

10. enum WifiModulationClass

/**
 * This enumeration defines the modulation classes per
 * (Table 9-4 "Modulation classes"; IEEE 802.11-2012).
 */

该枚举类定义了每个调制类

11. class WifiModeFactory

/**
 * \brief create WifiMode class instances and keep track of them.
 *
 * This factory ensures that each WifiMode created has a unique name
 * and assigns to each of them a unique integer.
 */

简要说明:创建WifiMode类实例,并对他们保持跟踪。
这个工厂类保证每一个被创建的WifiMode有一个唯一的名字,并给每一个分配一个唯一的整数。

12. class MacLowDcfListener

/**
 * \brief listen to NAV events
 * \ingroup wifi
 *
 * This class is typically connected to an instance of ns3::Dcf
 * and calls to its methods are forwards to the corresponding
 * ns3::Dcf methods.
 */

简要说明:监听NAV事件
该来一般与一个ns3::Dcf实例关联在一起,它的方法调用是转发到相应的ns3::Dcf方法。

13. class MacLowAggregationCapableTransmissionListener

/**
 * \ingroup wifi
 * \brief listen for block ack events.
 */

监听块ACK事件

14. class MacLowTransmissionParameters

/**
 * \brief control how a packet is transmitted.
 * \ingroup wifi
 *
 * The ns3::MacLow::StartTransmission method expects
 * an instance of this class to describe how the packet
 * should be transmitted.
 */

简要说明:控制一个包如何传输
ns3::MacLow::StartTransmission方法预料该来的实例,描述一个包如何被传输的。

15. class WifiTxVector

/**
 * This class mimics(模仿) the TXVECTOR which is to be
 * passed to the PHY in order to define the parameters which are to be
 * used for a transmission. See IEEE 802.11-2007 15.2.6 "Transmit PLCP",
 * and also 15.4.4.2 "PMD_SAP peer-to-peer service primitive(原始的)
 * parameters".
 *
 * If this class is constructed with the constructor that takes no
 * arguments, then the client must explicitly(明确的) set the mode and
 * transmit power level parameters before using them.  Default
 * member initializers(初始化) are provided for the other parameters, to
 * conform to a non-MIMO/long guard configuration, although these
 * may also be explicitly set after object construction.
 *
 * When used in a infrastructure context, WifiTxVector values should be
 * drawn from WifiRemoteStationManager parameters since rate adaptation
 * is responsible for picking the mode, number of streams, etc., but in
 * the case in which there is no such manager (e.g. mesh), the client
 * still needs to initialize at least the mode and transmit power level
 * appropriately.
 *
 * \note the above reference is valid for the DSSS PHY only (clause
 * 15). TXVECTOR is defined also for the other PHYs, however they
 * don't include the TXPWRLVL explicitly in the TXVECTOR. This is
 * somewhat strange, since all PHYs actually have a
 * PMD_TXPWRLVL.request primitive. We decide to include the power
 * level in WifiTxVector for all PHYs, since it serves better our
 * purposes, and furthermore it seems close to the way real devices
 * work (e.g., madwifi).
 */

该类模仿了TXVECTOR,它将被传递到PHY,这是为了定义一次传输所用的参数。请看IEEE 802.11-2007 15.2.6 "Transmit PLCP"和 15.4.4.2 "PMD_SAP peer-to-peer service primitive(原始的)parameters".
如果该类使用没有参数的构造器构建,则客户端必须在使用它们之前明确的设置模式和传输能量水平参数。提供了其他参数来完成默认的成员初始化,确保一个non-MIMO /long guard configuration,尽管这些可能在对象创建之后来明确的设置。

16. struct Item

 /**
   * A struct that holds information about a packet for putting
   * in a packet queue.
   */
    结构体包含三个元素:
     * \param packet
     * \param hdr
     * \param tstamp

结构体,保存了一个包的信号,该包存放在包队列中。

 /**
   * typedef for packet (struct Item) queue.
   */
  typedef std::list<struct Item> PacketQueue;包队列

17. class InterferenceHelper

/**
 * \ingroup wifi
 * \brief handles interference calculations
 */

简要说明:处理干扰计算

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
  • 序言:七十年代末,一起剥皮案震惊了整个滨河市,随后出现的几起案子,更是在滨河造成了极大的恐慌,老刑警刘岩,带你破解...
    沈念sama阅读 157,924评论 4 360
  • 序言:滨河连续发生了三起死亡事件,死亡现场离奇诡异,居然都是意外死亡,警方通过查阅死者的电脑和手机,发现死者居然都...
    沈念sama阅读 66,902评论 1 290
  • 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
    开封第一讲书人阅读 107,716评论 0 239
  • 文/不坏的土叔 我叫张陵,是天一观的道长。 经常有香客问我,道长,这世上最难降的妖魔是什么? 我笑而不...
    开封第一讲书人阅读 43,783评论 0 203
  • 正文 为了忘掉前任,我火速办了婚礼,结果婚礼上,老公的妹妹穿的比我还像新娘。我一直安慰自己,他们只是感情好,可当我...
    茶点故事阅读 52,166评论 3 286
  • 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
    开封第一讲书人阅读 40,510评论 1 216
  • 那天,我揣着相机与录音,去河边找鬼。 笑死,一个胖子当着我的面吹牛,可吹牛的内容都是我干的。 我是一名探鬼主播,决...
    沈念sama阅读 31,784评论 2 311
  • 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
    开封第一讲书人阅读 30,476评论 0 196
  • 序言:老挝万荣一对情侣失踪,失踪者是张志新(化名)和其女友刘颖,没想到半个月后,有当地人在树林里发现了一具尸体,经...
    沈念sama阅读 34,196评论 1 241
  • 正文 独居荒郊野岭守林人离奇死亡,尸身上长有42处带血的脓包…… 初始之章·张勋 以下内容为张勋视角 年9月15日...
    茶点故事阅读 30,459评论 2 243
  • 正文 我和宋清朗相恋三年,在试婚纱的时候发现自己被绿了。 大学时的朋友给我发了我未婚夫和他白月光在一起吃饭的照片。...
    茶点故事阅读 31,978评论 1 258
  • 序言:一个原本活蹦乱跳的男人离奇死亡,死状恐怖,灵堂内的尸体忽然破棺而出,到底是诈尸还是另有隐情,我是刑警宁泽,带...
    沈念sama阅读 28,321评论 2 252
  • 正文 年R本政府宣布,位于F岛的核电站,受9级特大地震影响,放射性物质发生泄漏。R本人自食恶果不足惜,却给世界环境...
    茶点故事阅读 32,964评论 3 235
  • 文/蒙蒙 一、第九天 我趴在偏房一处隐蔽的房顶上张望。 院中可真热闹,春花似锦、人声如沸。这庄子的主人今日做“春日...
    开封第一讲书人阅读 26,046评论 0 8
  • 文/苍兰香墨 我抬头看了看天上的太阳。三九已至,却和暖如春,着一层夹袄步出监牢的瞬间,已是汗流浃背。 一阵脚步声响...
    开封第一讲书人阅读 26,803评论 0 193
  • 我被黑心中介骗来泰国打工, 没想到刚下飞机就差点儿被人妖公主榨干…… 1. 我叫王不留,地道东北人。 一个月前我还...
    沈念sama阅读 35,530评论 2 271
  • 正文 我出身青楼,却偏偏与公主长得像,于是被迫代替她去往敌国和亲。 传闻我的和亲对象是个残疾皇子,可洞房花烛夜当晚...
    茶点故事阅读 35,420评论 2 265

推荐阅读更多精彩内容

  • ns3-model-library.pdf wifi-model 翻译 wifi-model 33.1 Desig...
    shawn168阅读 11,717评论 0 9
  • 1. Java基础部分 基础部分的顺序:基本语法,类相关的语法,内部类的语法,继承相关的语法,异常的语法,线程的语...
    子非鱼_t_阅读 31,293评论 18 399
  • 国家电网公司企业标准(Q/GDW)- 面向对象的用电信息数据交换协议 - 报批稿:20170802 前言: 排版 ...
    庭说阅读 10,493评论 6 13
  • Spring Cloud为开发人员提供了快速构建分布式系统中一些常见模式的工具(例如配置管理,服务发现,断路器,智...
    卡卡罗2017阅读 134,097评论 18 139
  • 2014年八月初的某一天,我站在凤凰山上,吹着高处的风,望着山脚下如积木般的村落,好像这一刻我拥有了一切,山下万物...
    夏梦梦的诗阅读 459评论 0 1