A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Documentation ▼
Installation
Manual
Models
Contributing
Wiki
Development ▼
API Docs
Issue Tracker
Merge Requests
API
Loading...
Searching...
No Matches
lr-wpan-constants.h
Go to the documentation of this file.
1
/*
2
* Copyright (c) 2011 The Boeing Company
3
*
4
* SPDX-License-Identifier: GPL-2.0-only
5
*
6
* Authors:
7
* Gary Pei <guangyu.pei@boeing.com>
8
* kwong yin <kwong-sang.yin@boeing.com>
9
* Tom Henderson <thomas.r.henderson@boeing.com>
10
* Sascha Alexander Jopen <jopen@cs.uni-bonn.de>
11
* Erwan Livolant <erwan.livolant@inria.fr>
12
* Alberto Gallegos Ramonet <ramonet@fc.ritsumei.ac.jp>
13
*/
14
15
#ifndef LR_WPAN_CONSTANTS_H
16
#define LR_WPAN_CONSTANTS_H
17
18
#include <cstdint>
19
20
namespace
ns3
21
{
22
namespace
lrwpan
23
{
24
25
/**
26
* \defgroup LrWpanConstants LR-WPAN common parameters
27
* \ingroup lr-wpan
28
*
29
* Contains common parameters about LR-WPAN that can be reused in multiple files.
30
* These parameters are defined in the IEEE 802.15.4-2011 standard and adopt the
31
* same names as in the standard.
32
*
33
* @{
34
*/
35
36
///////////////////
37
// PHY constants //
38
///////////////////
39
40
/**
41
* The maximum packet size accepted by the PHY.
42
* See Table 22 in section 6.4.1 of IEEE 802.15.4-2006
43
*/
44
constexpr
uint32_t
aMaxPhyPacketSize
{127};
45
46
/**
47
* The turnaround time in symbol periods for switching the transceiver from RX to TX or
48
* vice-versa.
49
* See Table 22 in section 6.4.1 of IEEE 802.15.4-2006
50
*/
51
constexpr
uint32_t
aTurnaroundTime
{12};
52
53
///////////////////
54
// MAC constants //
55
///////////////////
56
57
/**
58
* The minimum number of octets added by the MAC sublayer to the PSDU.
59
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
60
*/
61
constexpr
uint32_t
aMinMPDUOverhead
{9};
62
63
/**
64
* Length of a superframe slot in symbols. Defaults to 60 symbols in each superframe slot.
65
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
66
*/
67
constexpr
uint32_t
aBaseSlotDuration
{60};
68
69
/**
70
* Number of a superframe slots per superframe. Defaults to 16.
71
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
72
*/
73
constexpr
uint32_t
aNumSuperframeSlots
{16};
74
75
/**
76
* Length of a superframe in symbols. Defaults to aBaseSlotDuration * aNumSuperframeSlots in
77
* symbols.
78
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
79
*/
80
constexpr
uint32_t
aBaseSuperframeDuration
{
aBaseSlotDuration
*
aNumSuperframeSlots
};
81
82
/**
83
* The number of consecutive lost beacons that will cause the MAC sublayer of a receiving device to
84
* declare a loss of synchronization.
85
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
86
*/
87
constexpr
uint32_t
aMaxLostBeacons
{4};
88
89
/**
90
* The maximum size of an MPDU, in octets, that can be followed by a Short InterFrame Spacing (SIFS)
91
* period.
92
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
93
*/
94
constexpr
uint32_t
aMaxSIFSFrameSize
{18};
95
96
/**
97
* Number of symbols per CSMA/CA time unit, default 20 symbols.
98
*/
99
constexpr
uint32_t
aUnitBackoffPeriod
{20};
100
101
/**
102
* The maximum number of octets added by the MAC sublayer to the MAC payload o a a beacon frame.
103
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
104
*/
105
constexpr
uint32_t
aMaxBeaconOverhead
{75};
106
107
/**
108
* The maximum size, in octets, of a beacon payload.
109
* See IEEE 802.15.4-2011, section 6.4.1, Table 51.
110
*/
111
constexpr
uint32_t
aMaxBeaconPayloadLength
{
aMaxPhyPacketSize
-
aMaxBeaconOverhead
};
112
113
/** @} */
114
115
}
// namespace lrwpan
116
}
// namespace ns3
117
118
#endif
// LR_WPAN_CONSTANTS_H
uint32_t
ns3::lrwpan::aMaxSIFSFrameSize
constexpr uint32_t aMaxSIFSFrameSize
The maximum size of an MPDU, in octets, that can be followed by a Short InterFrame Spacing (SIFS) per...
Definition
lr-wpan-constants.h:94
ns3::lrwpan::aNumSuperframeSlots
constexpr uint32_t aNumSuperframeSlots
Number of a superframe slots per superframe.
Definition
lr-wpan-constants.h:73
ns3::lrwpan::aMaxLostBeacons
constexpr uint32_t aMaxLostBeacons
The number of consecutive lost beacons that will cause the MAC sublayer of a receiving device to decl...
Definition
lr-wpan-constants.h:87
ns3::lrwpan::aMaxBeaconPayloadLength
constexpr uint32_t aMaxBeaconPayloadLength
The maximum size, in octets, of a beacon payload.
Definition
lr-wpan-constants.h:111
ns3::lrwpan::aMaxPhyPacketSize
constexpr uint32_t aMaxPhyPacketSize
The maximum packet size accepted by the PHY.
Definition
lr-wpan-constants.h:44
ns3::lrwpan::aUnitBackoffPeriod
constexpr uint32_t aUnitBackoffPeriod
Number of symbols per CSMA/CA time unit, default 20 symbols.
Definition
lr-wpan-constants.h:99
ns3::lrwpan::aTurnaroundTime
constexpr uint32_t aTurnaroundTime
The turnaround time in symbol periods for switching the transceiver from RX to TX or vice-versa.
Definition
lr-wpan-constants.h:51
ns3::lrwpan::aBaseSuperframeDuration
constexpr uint32_t aBaseSuperframeDuration
Length of a superframe in symbols.
Definition
lr-wpan-constants.h:80
ns3::lrwpan::aMinMPDUOverhead
constexpr uint32_t aMinMPDUOverhead
The minimum number of octets added by the MAC sublayer to the PSDU.
Definition
lr-wpan-constants.h:61
ns3::lrwpan::aBaseSlotDuration
constexpr uint32_t aBaseSlotDuration
Length of a superframe slot in symbols.
Definition
lr-wpan-constants.h:67
ns3::lrwpan::aMaxBeaconOverhead
constexpr uint32_t aMaxBeaconOverhead
The maximum number of octets added by the MAC sublayer to the MAC payload o a a beacon frame.
Definition
lr-wpan-constants.h:105
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
src
lr-wpan
model
lr-wpan-constants.h
Generated on Fri Nov 8 2024 13:59:02 for ns-3 by
1.11.0