A Discrete-Event Network Simulator
Home
Tutorials ▼
English
Portuguese
Docs ▼
Wiki
Manual
Models
Develop ▼
API
Bugs
API
src
lr-wpan
model
lr-wpan-mac-header.h
Go to the documentation of this file.
1
/* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
2
/*
3
* Copyright (c) 2011 The Boeing Company
4
*
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License version 2 as
7
* published by the Free Software Foundation;
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17
*
18
* Author: kwong yin <kwong-sang.yin@boeing.com>
19
*/
20
21
/*
22
* the following classes implements the 802.15.4 Mac Header
23
* There are 4 types of 802.15.4 Mac Headers Frames, and they have these fields
24
*
25
* Headers Frames : Fields
26
* -------------------------------------------------------------------------------------------
27
* Beacon : Frame Control, Sequence Number, Address Fields+, Auxiliary Security Header++.
28
* Data : Frame Control, Sequence Number, Address Fields++, Auxiliary Security Header++.
29
* Acknowledgment : Frame Control, Sequence Number.
30
* Command : Frame Control, Sequence Number, Address Fields++, Auxiliary Security Header++.
31
*
32
* + - The Address fields in Beacon frame is made up of the Source PAN Id and address only and size
33
* is 4 or 8 octets whereas the other frames may contain the Destination PAN Id and address as
34
* well. (see specs).
35
* ++ - These fields are optional and of variable size
36
*/
37
38
#ifndef LR_WPAN_MAC_HEADER_H
39
#define LR_WPAN_MAC_HEADER_H
40
41
#include <ns3/header.h>
42
#include <ns3/mac16-address.h>
43
#include <ns3/mac64-address.h>
44
45
46
namespace
ns3
{
47
48
53
class
LrWpanMacHeader
:
public
Header
54
{
55
56
public
:
57
61
enum
LrWpanMacType
62
{
63
LRWPAN_MAC_BEACON
= 0,
64
LRWPAN_MAC_DATA
= 1,
65
LRWPAN_MAC_ACKNOWLEDGMENT
= 2,
66
LRWPAN_MAC_COMMAND
= 3,
67
LRWPAN_MAC_RESERVED
68
};
69
73
enum
AddrModeType
74
{
75
NOADDR
= 0,
76
RESADDR
= 1,
77
SHORTADDR
= 2,
78
EXTADDR
= 3
79
};
80
84
enum
KeyIdModeType
85
{
86
IMPLICIT
= 0,
87
NOKEYSOURCE
= 1,
88
SHORTKEYSOURCE
= 2,
89
LONGKEYSOURCE
= 3
90
};
91
92
LrWpanMacHeader
(
void
);
93
99
LrWpanMacHeader
(
enum
LrWpanMacType
wpanMacType,
// Data, ACK, Control MAC Header must have
100
uint8_t seqNum);
// frame control and sequence number.
101
// Beacon MAC Header must have frame control,
102
// sequence number, source PAN Id, source address.
103
104
~LrWpanMacHeader
(
void
);
105
110
enum
LrWpanMacType
GetType
(
void
)
const
;
115
uint16_t
GetFrameControl
(
void
)
const
;
116
121
bool
IsSecEnable
(
void
)
const
;
122
127
bool
IsFrmPend
(
void
)
const
;
128
133
bool
IsAckReq
(
void
)
const
;
134
139
bool
IsPanIdComp
(
void
)
const
;
140
145
uint8_t
GetFrmCtrlRes
(
void
)
const
;
146
151
uint8_t
GetDstAddrMode
(
void
)
const
;
156
uint8_t
GetFrameVer
(
void
)
const
;
161
uint8_t
GetSrcAddrMode
(
void
)
const
;
162
167
uint8_t
GetSeqNum
(
void
)
const
;
168
173
uint16_t
GetDstPanId
(
void
)
const
;
178
Mac16Address
GetShortDstAddr
(
void
)
const
;
183
Mac64Address
GetExtDstAddr
(
void
)
const
;
188
uint16_t
GetSrcPanId
(
void
)
const
;
193
Mac16Address
GetShortSrcAddr
(
void
)
const
;
198
Mac64Address
GetExtSrcAddr
(
void
)
const
;
199
204
uint8_t
GetSecControl
(
void
)
const
;
209
uint32_t
GetFrmCounter
(
void
)
const
;
210
215
uint8_t
GetSecLevel
(
void
)
const
;
220
uint8_t
GetKeyIdMode
(
void
)
const
;
225
uint8_t
GetSecCtrlReserved
(
void
)
const
;
226
231
uint32_t
GetKeyIdSrc32
(
void
)
const
;
236
uint64_t
GetKeyIdSrc64
(
void
)
const
;
241
uint8_t
GetKeyIdIndex
(
void
)
const
;
242
247
bool
IsBeacon
(
void
)
const
;
252
bool
IsData
(
void
)
const
;
257
bool
IsAcknowledgment
(
void
)
const
;
262
bool
IsCommand
(
void
)
const
;
263
268
void
SetType
(
enum
LrWpanMacType
wpanMacType);
269
274
void
SetFrameControl
(uint16_t frameControl);
275
279
void
SetSecEnable
(
void
);
280
284
void
SetSecDisable
(
void
);
285
289
void
SetFrmPend
(
void
);
290
294
void
SetNoFrmPend
(
void
);
295
299
void
SetAckReq
(
void
);
300
304
void
SetNoAckReq
(
void
);
305
309
void
SetPanIdComp
(
void
);
310
314
void
SetNoPanIdComp
(
void
);
315
320
void
SetFrmCtrlRes
(uint8_t res);
325
void
SetDstAddrMode
(uint8_t addrMode);
330
void
SetFrameVer
(uint8_t ver);
335
void
SetSrcAddrMode
(uint8_t addrMode);
336
341
void
SetSeqNum
(uint8_t seqNum);
342
343
/* The Source/Destination Addressing fields are only set if SrcAddrMode/DstAddrMode are set */
349
void
SetSrcAddrFields
(uint16_t panId,
Mac16Address
addr);
355
void
SetSrcAddrFields
(uint16_t panId,
Mac64Address
addr);
361
void
SetDstAddrFields
(uint16_t panId,
Mac16Address
addr);
367
void
SetDstAddrFields
(uint16_t panId,
Mac64Address
addr);
368
369
/* Auxiliary Security Header is only set if Sec Enable (SecU) field is set to 1 */
374
void
SetSecControl
(uint8_t secLevel);
379
void
SetFrmCounter
(uint32_t frmCntr);
380
385
void
SetSecLevel
(uint8_t secLevel);
390
void
SetKeyIdMode
(uint8_t keyIdMode);
391
396
void
SetSecCtrlReserved
(uint8_t res);
397
398
/* Variable length will be dependent on Key Id Mode*/
403
void
SetKeyId
(uint8_t keyIndex);
409
void
SetKeyId
(uint32_t keySrc, uint8_t keyIndex);
415
void
SetKeyId
(uint64_t keySrc, uint8_t keyIndex);
416
421
static
TypeId
GetTypeId
(
void
);
422
virtual
TypeId
GetInstanceTypeId
(
void
)
const
;
423
424
void
Print
(std::ostream &os)
const
;
425
uint32_t
GetSerializedSize
(
void
)
const
;
426
void
Serialize
(
Buffer::Iterator
start
)
const
;
427
uint32_t
Deserialize
(
Buffer::Iterator
start
);
428
429
430
private
:
431
/* Frame Control 2 Octets */
432
/* Frame Control field - see 7.2.1.1 */
433
uint8_t
m_fctrlFrmType
;
434
uint8_t
m_fctrlSecU
;
435
uint8_t
m_fctrlFrmPending
;
436
uint8_t
m_fctrlAckReq
;
437
uint8_t
m_fctrlPanIdComp
;
438
uint8_t
m_fctrlReserved
;
439
uint8_t
m_fctrlDstAddrMode
;
440
uint8_t
m_fctrlFrmVer
;
441
uint8_t
m_fctrlSrcAddrMode
;
442
443
/* Sequence Number */
444
uint8_t
m_SeqNum
;
445
446
/* Addressing fields */
447
uint16_t
m_addrDstPanId
;
448
Mac16Address
m_addrShortDstAddr
;
449
Mac64Address
m_addrExtDstAddr
;
450
uint16_t
m_addrSrcPanId
;
451
Mac16Address
m_addrShortSrcAddr
;
452
Mac64Address
m_addrExtSrcAddr
;
453
454
/* Auxiliary Security Header - See 7.6.2 - 0, 5, 6, 10 or 14 Octets */
455
// uint8_t m_auxSecCtrl; // 1 Octet see below
456
uint32_t
m_auxFrmCntr
;
457
458
/* Security Control fields - See 7.6.2.2 */
459
uint8_t
m_secctrlSecLevel
;
460
uint8_t
m_secctrlKeyIdMode
;
461
// = 0 - Key is determined implicitly
462
// from originator and recipient
463
// = 1 - 1 Octet Key Index
464
// = 2 - 1 Octet Key Index and 4 oct Key src
465
// = 3 - 1 Octet Key Index and 8 oct Key src
466
467
uint8_t
m_secctrlReserved
;
468
469
union
470
{
471
uint32_t
m_auxKeyIdKeySrc32
;
472
uint64_t
m_auxKeyIdKeySrc64
;
473
};
474
475
uint8_t
m_auxKeyIdKeyIndex
;
476
477
};
//LrWpanMacHeader
478
479
};
// namespace ns-3
480
481
#endif
/* LR_WPAN_MAC_HEADER_H */
ns3::Header
Protocol header serialization and deserialization.
Definition:
header.h:42
ns3::LrWpanMacHeader::SetNoFrmPend
void SetNoFrmPend(void)
Set the Frame Control field "Frame Pending" bit to false.
Definition:
lr-wpan-mac-header.cc:332
ns3::LrWpanMacHeader::GetFrmCounter
uint32_t GetFrmCounter(void) const
Get the Auxiliary Security Header - Frame Counter Octects.
Definition:
lr-wpan-mac-header.cc:213
ns3::LrWpanMacHeader::~LrWpanMacHeader
~LrWpanMacHeader(void)
Definition:
lr-wpan-mac-header.cc:59
ns3::LrWpanMacHeader::GetSeqNum
uint8_t GetSeqNum(void) const
Get the frame Sequence number.
Definition:
lr-wpan-mac-header.cc:156
ns3::LrWpanMacHeader::SetSecDisable
void SetSecDisable(void)
Set the Frame Control field "Security Enabled" bit to false.
Definition:
lr-wpan-mac-header.cc:318
ns3::LrWpanMacHeader::m_fctrlDstAddrMode
uint8_t m_fctrlDstAddrMode
Frame Control field Bit 10-11 = 0 - No DstAddr, 2 - ShtDstAddr, 3 - ExtDstAddr.
Definition:
lr-wpan-mac-header.h:439
ns3::LrWpanMacHeader::m_fctrlSecU
uint8_t m_fctrlSecU
Frame Control field Bit 3 = 0 - no AuxSecHdr , 1 - security enabled AuxSecHdr present.
Definition:
lr-wpan-mac-header.h:434
ns3::LrWpanMacHeader::GetShortDstAddr
Mac16Address GetShortDstAddr(void) const
Get the Destination Short address.
Definition:
lr-wpan-mac-header.cc:170
ns3::LrWpanMacHeader::EXTADDR
Definition:
lr-wpan-mac-header.h:78
ns3::LrWpanMacHeader::GetShortSrcAddr
Mac16Address GetShortSrcAddr(void) const
Get the Source Short address.
Definition:
lr-wpan-mac-header.cc:189
ns3::LrWpanMacHeader::SHORTADDR
Definition:
lr-wpan-mac-header.h:77
ns3::LrWpanMacHeader::GetSerializedSize
uint32_t GetSerializedSize(void) const
Definition:
lr-wpan-mac-header.cc:563
ns3::LrWpanMacHeader::SetKeyId
void SetKeyId(uint8_t keyIndex)
Set the Key Index.
Definition:
lr-wpan-mac-header.cc:460
ns3::LrWpanMacHeader::GetFrameControl
uint16_t GetFrameControl(void) const
Get the Frame control field.
Definition:
lr-wpan-mac-header.cc:89
visualizer.core.start
def start()
Definition:
core.py:1844
ns3::LrWpanMacHeader::IsData
bool IsData(void) const
Returns true if the header is a data.
Definition:
lr-wpan-mac-header.cc:265
ns3::LrWpanMacHeader::SetNoPanIdComp
void SetNoPanIdComp(void)
Set the Frame Control field "PAN ID Compression" bit to false.
Definition:
lr-wpan-mac-header.cc:359
ns3::LrWpanMacHeader::KeyIdModeType
KeyIdModeType
The addressing mode types, see IEEE 802.15.4-2006, Table 80.
Definition:
lr-wpan-mac-header.h:84
ns3::LrWpanMacHeader::SetNoAckReq
void SetNoAckReq(void)
Set the Frame Control field "Ack. Request" bit to false.
Definition:
lr-wpan-mac-header.cc:346
ns3::LrWpanMacHeader::m_secctrlReserved
uint8_t m_secctrlReserved
Auxiliary security header - Security Control field - Bit 5-7.
Definition:
lr-wpan-mac-header.h:467
ns3::LrWpanMacHeader::m_secctrlKeyIdMode
uint8_t m_secctrlKeyIdMode
Auxiliary security header - Security Control field - Bit 3-4 will indicate size of Key Id...
Definition:
lr-wpan-mac-header.h:460
ns3::LrWpanMacHeader::m_addrShortDstAddr
Mac16Address m_addrShortDstAddr
Dst Short addr (0 or 2 Octets)
Definition:
lr-wpan-mac-header.h:448
ns3::LrWpanMacHeader::AddrModeType
AddrModeType
The addressing mode types, see IEEE 802.15.4-2006, Table 80.
Definition:
lr-wpan-mac-header.h:73
ns3::LrWpanMacHeader::SetSeqNum
void SetSeqNum(uint8_t seqNum)
Set the Sequence number.
Definition:
lr-wpan-mac-header.cc:392
ns3::LrWpanMacHeader
Represent the Mac Header with the Frame Control and Sequence Number fields.
Definition:
lr-wpan-mac-header.h:53
ns3::LrWpanMacHeader::IsCommand
bool IsCommand(void) const
Returns true if the header is a command.
Definition:
lr-wpan-mac-header.cc:281
ns3::LrWpanMacHeader::GetKeyIdSrc64
uint64_t GetKeyIdSrc64(void) const
Get the Auxiliary Security Header - Key Identifier - Key Source (4 Octects)
Definition:
lr-wpan-mac-header.cc:243
ns3::LrWpanMacHeader::GetDstPanId
uint16_t GetDstPanId(void) const
Get the Destination PAN ID.
Definition:
lr-wpan-mac-header.cc:163
ns3::LrWpanMacHeader::m_addrDstPanId
uint16_t m_addrDstPanId
Dst PAN id (0 or 2 Octets)
Definition:
lr-wpan-mac-header.h:447
ns3::LrWpanMacHeader::LRWPAN_MAC_RESERVED
LRWPAN_MAC_RESERVED.
Definition:
lr-wpan-mac-header.h:67
ns3::LrWpanMacHeader::m_fctrlFrmPending
uint8_t m_fctrlFrmPending
Frame Control field Bit 4.
Definition:
lr-wpan-mac-header.h:435
ns3::LrWpanMacHeader::LrWpanMacType
LrWpanMacType
The possible MAC types, see IEEE 802.15.4-2006, Table 79.
Definition:
lr-wpan-mac-header.h:61
ns3::LrWpanMacHeader::m_addrSrcPanId
uint16_t m_addrSrcPanId
Src PAN id (0 or 2 Octets)
Definition:
lr-wpan-mac-header.h:450
ns3::LrWpanMacHeader::SetAckReq
void SetAckReq(void)
Set the Frame Control field "Ack. Request" bit to true.
Definition:
lr-wpan-mac-header.cc:339
ns3::LrWpanMacHeader::SetFrmCounter
void SetFrmCounter(uint32_t frmCntr)
Set the auxiliary security header "Frame Counter" octet.
Definition:
lr-wpan-mac-header.cc:436
ns3::LrWpanMacHeader::GetFrameVer
uint8_t GetFrameVer(void) const
Get the Frame Version of Frame control field.
Definition:
lr-wpan-mac-header.cc:143
ns3::Buffer::Iterator
iterator in a Buffer instance
Definition:
buffer.h:98
ns3::LrWpanMacHeader::SetSrcAddrFields
void SetSrcAddrFields(uint16_t panId, Mac16Address addr)
Set Source address fields.
Definition:
lr-wpan-mac-header.cc:398
ns3::LrWpanMacHeader::LRWPAN_MAC_BEACON
LRWPAN_MAC_BEACON.
Definition:
lr-wpan-mac-header.h:63
ns3::Mac64Address
an EUI-64 address
Definition:
mac64-address.h:43
ns3::LrWpanMacHeader::SetKeyIdMode
void SetKeyIdMode(uint8_t keyIdMode)
Set the Security Control field "Key Identifier Mode" bits (2 bits)
Definition:
lr-wpan-mac-header.cc:448
ns3::LrWpanMacHeader::IsPanIdComp
bool IsPanIdComp(void) const
Check if PAN ID Compression bit of Frame Control is enabled.
Definition:
lr-wpan-mac-header.cc:125
ns3::LrWpanMacHeader::IsFrmPend
bool IsFrmPend(void) const
Check if Frame Pending bit of Frame Control is enabled.
Definition:
lr-wpan-mac-header.cc:113
ns3::LrWpanMacHeader::m_auxKeyIdKeySrc32
uint32_t m_auxKeyIdKeySrc32
Auxiliary security header - Key Source (4 Octets)
Definition:
lr-wpan-mac-header.h:471
ns3::LrWpanMacHeader::NOADDR
Definition:
lr-wpan-mac-header.h:75
ns3::LrWpanMacHeader::SetSecCtrlReserved
void SetSecCtrlReserved(uint8_t res)
Set the Security Control field "Reserved" bits (3 bits)
Definition:
lr-wpan-mac-header.cc:454
ns3::LrWpanMacHeader::SetSecEnable
void SetSecEnable(void)
Set the Frame Control field "Security Enabled" bit to true.
Definition:
lr-wpan-mac-header.cc:311
ns3::LrWpanMacHeader::GetDstAddrMode
uint8_t GetDstAddrMode(void) const
Get the Dest.
Definition:
lr-wpan-mac-header.cc:137
ns3::LrWpanMacHeader::m_auxKeyIdKeySrc64
uint64_t m_auxKeyIdKeySrc64
Auxiliary security header - Key Source (8 Octets)
Definition:
lr-wpan-mac-header.h:472
ns3::LrWpanMacHeader::LRWPAN_MAC_DATA
LRWPAN_MAC_DATA.
Definition:
lr-wpan-mac-header.h:64
ns3::LrWpanMacHeader::GetType
enum LrWpanMacType GetType(void) const
Get the header type.
Definition:
lr-wpan-mac-header.cc:65
ns3::LrWpanMacHeader::m_addrExtDstAddr
Mac64Address m_addrExtDstAddr
Dst Ext addr (0 or 8 Octets)
Definition:
lr-wpan-mac-header.h:449
ns3::LrWpanMacHeader::LRWPAN_MAC_COMMAND
LRWPAN_MAC_COMMAND.
Definition:
lr-wpan-mac-header.h:66
ns3::LrWpanMacHeader::SetFrameVer
void SetFrameVer(uint8_t ver)
Set the Frame version.
Definition:
lr-wpan-mac-header.cc:378
ns3::LrWpanMacHeader::m_SeqNum
uint8_t m_SeqNum
Sequence Number (1 Octet)
Definition:
lr-wpan-mac-header.h:444
ns3::LrWpanMacHeader::IsAcknowledgment
bool IsAcknowledgment(void) const
Returns true if the header is an ack.
Definition:
lr-wpan-mac-header.cc:273
ns3::LrWpanMacHeader::GetInstanceTypeId
virtual TypeId GetInstanceTypeId(void) const
Get the most derived TypeId for this Object.
Definition:
lr-wpan-mac-header.cc:494
ns3::LrWpanMacHeader::GetSecLevel
uint8_t GetSecLevel(void) const
Get the Auxiliary Security Header - Security Control - Security Level bits.
Definition:
lr-wpan-mac-header.cc:219
ns3::LrWpanMacHeader::GetKeyIdMode
uint8_t GetKeyIdMode(void) const
Get the Auxiliary Security Header - Security Control - Key Identifier Mode bits.
Definition:
lr-wpan-mac-header.cc:225
ns3::LrWpanMacHeader::SetType
void SetType(enum LrWpanMacType wpanMacType)
Set the Frame Control field "Frame Type" bits.
Definition:
lr-wpan-mac-header.cc:289
ns3::LrWpanMacHeader::GetExtSrcAddr
Mac64Address GetExtSrcAddr(void) const
Get the Source Extended address.
Definition:
lr-wpan-mac-header.cc:194
ns3::LrWpanMacHeader::SetFrmCtrlRes
void SetFrmCtrlRes(uint8_t res)
Set the Frame Control field "Reserved" bits.
Definition:
lr-wpan-mac-header.cc:365
ns3::LrWpanMacHeader::IMPLICIT
Definition:
lr-wpan-mac-header.h:86
ns3::LrWpanMacHeader::SetPanIdComp
void SetPanIdComp(void)
Set the Frame Control field "PAN ID Compression" bit to true.
Definition:
lr-wpan-mac-header.cc:353
ns3
Every class exported by the ns3 library is enclosed in the ns3 namespace.
ns3::LrWpanMacHeader::GetSrcAddrMode
uint8_t GetSrcAddrMode(void) const
Get the Source Addressing Mode of Frame control field.
Definition:
lr-wpan-mac-header.cc:149
ns3::LrWpanMacHeader::m_auxKeyIdKeyIndex
uint8_t m_auxKeyIdKeyIndex
Auxiliary security header - Key Index (1 Octet)
Definition:
lr-wpan-mac-header.h:475
ns3::LrWpanMacHeader::m_addrShortSrcAddr
Mac16Address m_addrShortSrcAddr
Src Short addr (0 or 2 Octets)
Definition:
lr-wpan-mac-header.h:451
ns3::LrWpanMacHeader::SetDstAddrMode
void SetDstAddrMode(uint8_t addrMode)
Set the Destination address mode.
Definition:
lr-wpan-mac-header.cc:371
ns3::LrWpanMacHeader::m_fctrlPanIdComp
uint8_t m_fctrlPanIdComp
Frame Control field Bit 6 = 0 - no compression, 1 - using only DstPanId for both Src and DstPanId...
Definition:
lr-wpan-mac-header.h:437
ns3::LrWpanMacHeader::IsAckReq
bool IsAckReq(void) const
Check if Ack.
Definition:
lr-wpan-mac-header.cc:119
ns3::Mac16Address
This class can contain 16 bit addresses.
Definition:
mac16-address.h:41
ns3::LrWpanMacHeader::m_addrExtSrcAddr
Mac64Address m_addrExtSrcAddr
Src Ext addr (0 or 8 Octets)
Definition:
lr-wpan-mac-header.h:452
ns3::LrWpanMacHeader::GetKeyIdSrc32
uint32_t GetKeyIdSrc32(void) const
Get the Auxiliary Security Header - Key Identifier - Key Source (2 Octects)
Definition:
lr-wpan-mac-header.cc:237
ns3::LrWpanMacHeader::m_secctrlSecLevel
uint8_t m_secctrlSecLevel
Auxiliary security header - Security Control field - Bit 0-2.
Definition:
lr-wpan-mac-header.h:459
ns3::LrWpanMacHeader::LRWPAN_MAC_ACKNOWLEDGMENT
LRWPAN_MAC_ACKNOWLEDGMENT.
Definition:
lr-wpan-mac-header.h:65
ns3::LrWpanMacHeader::NOKEYSOURCE
Definition:
lr-wpan-mac-header.h:87
ns3::LrWpanMacHeader::SetDstAddrFields
void SetDstAddrFields(uint16_t panId, Mac16Address addr)
Set Destination address fields.
Definition:
lr-wpan-mac-header.cc:414
ns3::LrWpanMacHeader::GetSrcPanId
uint16_t GetSrcPanId(void) const
Get the Source PAN ID.
Definition:
lr-wpan-mac-header.cc:181
ns3::LrWpanMacHeader::RESADDR
Definition:
lr-wpan-mac-header.h:76
ns3::LrWpanMacHeader::SetSecControl
void SetSecControl(uint8_t secLevel)
Set the auxiliary security header "Security Control" octet.
Definition:
lr-wpan-mac-header.cc:428
ns3::LrWpanMacHeader::IsBeacon
bool IsBeacon(void) const
Returns true if the header is a beacon.
Definition:
lr-wpan-mac-header.cc:257
ns3::LrWpanMacHeader::IsSecEnable
bool IsSecEnable(void) const
Check if Security Enabled bit of Frame Control is enabled.
Definition:
lr-wpan-mac-header.cc:107
ns3::LrWpanMacHeader::Deserialize
uint32_t Deserialize(Buffer::Iterator start)
Definition:
lr-wpan-mac-header.cc:711
ns3::LrWpanMacHeader::SetFrmPend
void SetFrmPend(void)
Set the Frame Control field "Frame Pending" bit to true.
Definition:
lr-wpan-mac-header.cc:325
ns3::LrWpanMacHeader::GetSecControl
uint8_t GetSecControl(void) const
Get the Auxiliary Security Header - Security Control Octect.
Definition:
lr-wpan-mac-header.cc:201
ns3::LrWpanMacHeader::SetFrameControl
void SetFrameControl(uint16_t frameControl)
Set the whole Frame Control field.
Definition:
lr-wpan-mac-header.cc:296
ns3::LrWpanMacHeader::SetSrcAddrMode
void SetSrcAddrMode(uint8_t addrMode)
Set the Source address mode.
Definition:
lr-wpan-mac-header.cc:385
ns3::LrWpanMacHeader::Print
void Print(std::ostream &os) const
Definition:
lr-wpan-mac-header.cc:500
ns3::LrWpanMacHeader::GetTypeId
static TypeId GetTypeId(void)
Get the type ID.
Definition:
lr-wpan-mac-header.cc:484
ns3::LrWpanMacHeader::m_fctrlReserved
uint8_t m_fctrlReserved
Frame Control field Bit 7-9.
Definition:
lr-wpan-mac-header.h:438
ns3::LrWpanMacHeader::m_auxFrmCntr
uint32_t m_auxFrmCntr
Auxiliary security header - Frame Counter (4 Octets)
Definition:
lr-wpan-mac-header.h:456
ns3::LrWpanMacHeader::m_fctrlSrcAddrMode
uint8_t m_fctrlSrcAddrMode
Frame Control field Bit 14-15 = 0 - No SrcAddr, 2 - ShtSrcAddr, 3 - ExtSrcAddr.
Definition:
lr-wpan-mac-header.h:441
ns3::LrWpanMacHeader::m_fctrlFrmVer
uint8_t m_fctrlFrmVer
Frame Control field Bit 12-13.
Definition:
lr-wpan-mac-header.h:440
ns3::LrWpanMacHeader::m_fctrlAckReq
uint8_t m_fctrlAckReq
Frame Control field Bit 5.
Definition:
lr-wpan-mac-header.h:436
ns3::LrWpanMacHeader::Serialize
void Serialize(Buffer::Iterator start) const
Definition:
lr-wpan-mac-header.cc:643
ns3::LrWpanMacHeader::SHORTKEYSOURCE
Definition:
lr-wpan-mac-header.h:88
ns3::LrWpanMacHeader::GetKeyIdIndex
uint8_t GetKeyIdIndex(void) const
Get the Auxiliary Security Header - Key Identifier - Key Index.
Definition:
lr-wpan-mac-header.cc:250
ns3::LrWpanMacHeader::m_fctrlFrmType
uint8_t m_fctrlFrmType
Frame Control field Bit 0-2 = 0 - Beacon, 1 - Data, 2 - Ack, 3 - Command.
Definition:
lr-wpan-mac-header.h:433
ns3::LrWpanMacHeader::LrWpanMacHeader
LrWpanMacHeader(void)
Definition:
lr-wpan-mac-header.cc:29
ns3::LrWpanMacHeader::SetSecLevel
void SetSecLevel(uint8_t secLevel)
Set the Security Control field "Security Level" bits (3 bits)
Definition:
lr-wpan-mac-header.cc:442
ns3::TypeId
a unique identifier for an interface.
Definition:
type-id.h:58
ns3::LrWpanMacHeader::GetFrmCtrlRes
uint8_t GetFrmCtrlRes(void) const
Get the Reserved bits of Frame control field.
Definition:
lr-wpan-mac-header.cc:131
ns3::LrWpanMacHeader::GetSecCtrlReserved
uint8_t GetSecCtrlReserved(void) const
Get the Auxiliary Security Header - Security Control - Reserved bits.
Definition:
lr-wpan-mac-header.cc:231
ns3::LrWpanMacHeader::GetExtDstAddr
Mac64Address GetExtDstAddr(void) const
Get the Destination Extended address.
Definition:
lr-wpan-mac-header.cc:175
ns3::LrWpanMacHeader::LONGKEYSOURCE
Definition:
lr-wpan-mac-header.h:89
Generated on Wed Nov 7 2018 10:01:58 for ns-3 by
1.8.14