A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
lr-wpan-mac-base.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2023 Tokushima University, Japan.
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation;
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
12 *
13 * You should have received a copy of the GNU General Public License
14 * along with this program; if not, write to the Free Software
15 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 *
17 * Author: Alberto Gallegos Ramonet <alramonet@is.tokushima-u.ac.jp>
18 */
19
20#ifndef LR_WPAN_MAC_BASE_H
21#define LR_WPAN_MAC_BASE_H
22
23#include <ns3/callback.h>
24#include <ns3/mac16-address.h>
25#include <ns3/mac64-address.h>
26#include <ns3/nstime.h>
27#include <ns3/object.h>
28#include <ns3/packet.h>
29#include <ns3/ptr.h>
30
31#include <cstdint>
32
33namespace ns3
34{
35namespace lrwpan
36{
37
38/**
39 * \ingroup lr-wpan
40 *
41 * The status of a confirm or an indication primitive as a result of a previous request.
42 * Represent the value of status in IEEE 802.15.4-2011 primitives.
43 * (Tables 6, 12, 18, 20, 31, 33, 35, 37, 39, 47)
44 *
45 * Status codes values only appear in IEEE 802.15.4-2006, Table 78
46 * See also NXP JN5169 IEEE 802.15.4 Stack User Guide
47 * (Table 6: Status Enumerations and Section 6.1.23)
48 *
49 */
50enum class MacStatus : std::uint8_t
51{
52 SUCCESS = 0, //!< The operation was completed successfully.
53 FULL_CAPACITY = 0x01, //!< PAN at capacity. Association Status field (std. 2006, Table 83)
54 ACCESS_DENIED = 0x02, //!< PAN access denied. Association Status field (std. 2006, Table 83)
55 COUNTER_ERROR = 0xdb, //!< The frame counter of the received frame is invalid.
56 IMPROPER_KEY_TYPE = 0xdc, //!< The key is not allowed to be used with that frame type.
57 IMPROPER_SECURITY_LEVEL = 0xdd, //!< Insufficient security level expected by the recipient.
58 UNSUPPORTED_LEGACY = 0xde, //!< Deprecated security used in IEEE 802.15.4-2003
59 UNSUPPORTED_SECURITY = 0xdf, //!< The security applied is not supported.
60 BEACON_LOSS = 0xe0, //!< The beacon was lost following a synchronization request.
61 CHANNEL_ACCESS_FAILURE = 0xe1, //!< A Tx could not take place due to activity in the CH.
62 DENIED = 0xe2, //!< The GTS request has been denied by the PAN coordinator.
63 DISABLE_TRX_FAILURE = 0xe3, //!< The attempt to disable the transceier has failed.
64 SECURITY_ERROR = 0xe4, // Cryptographic process of the frame failed(FAILED_SECURITY_CHECK).
65 FRAME_TOO_LONG = 0xe5, //!< Frame more than aMaxPHYPacketSize or too large for CAP or GTS.
66 INVALID_GTS = 0xe6, //!< Missing GTS transmit or undefined direction.
67 INVALID_HANDLE = 0xe7, //!< When purging from TX queue handle was not found.
68 INVALID_PARAMETER = 0xe8, //!< Primitive parameter not supported or out of range.
69 NO_ACK = 0xe9, //!< No acknowledgment was received after macMaxFrameRetries.
70 NO_BEACON = 0xea, //!< A scan operation failed to find any network beacons.
71 NO_DATA = 0xeb, //!< No response data were available following a request.
72 NO_SHORT_ADDRESS = 0xec, //!< Failure due to unallocated 16-bit short address.
73 OUT_OF_CAP = 0xed, //!< (Deprecated) See IEEE 802.15.4-2003
74 PAN_ID_CONFLICT = 0xee, //!< PAN id conflict detected and informed to the coordinator.
75 REALIGMENT = 0xef, //!< A coordinator realigment command has been received.
76 TRANSACTION_EXPIRED = 0xf0, //!< The transaction expired and its information discarded.
77 TRANSACTION_OVERFLOW = 0xf1, //!< There is no capacity to store the transaction.
78 TX_ACTIVE = 0xf2, //!< The transceiver was already enabled.
79 UNAVAILABLE_KEY = 0xf3, //!< Unavailable key, unknown or blacklisted.
80 UNSUPPORTED_ATTRIBUTE = 0xf4, //!< SET/GET request issued with a non supported ID.
81 INVALID_ADDRESS = 0xf5, //!< Invalid source or destination address.
82 ON_TIME_TOO_LONG = 0xf6, //!< RX enable request fail due to syms. longer than Bcn. interval
83 PAST_TIME = 0xf7, //!< Rx enable request fail due to lack of time in superframe.
84 TRACKING_OFF = 0xf8, //!< This device is currently not tracking beacons.
85 INVALID_INDEX = 0xf9, //!< A MAC PIB write failed because specified index is out of range.
86 LIMIT_REACHED = 0xfa, //!< PAN descriptors stored reached max capacity.
87 READ_ONLY = 0xfb, //!< SET/GET request issued for a read only attribute.
88 SCAN_IN_PROGRESS = 0xfc, //!< Scan failed because already performing another scan.
89 SUPERFRAME_OVERLAP = 0xfd //!< Coordinator superframe and this device superframe tx overlap.
90};
91
92/**
93 * \ingroup lr-wpan
94 *
95 * table 80 of 802.15.4
96 */
98{
102 EXT_ADDR = 3
104
105/**
106 * \ingroup lr-wpan
107 *
108 * Table 30 of IEEE 802.15.4-2011
109 */
111{
115 MLMESCAN_ORPHAN = 0x03
117
118/**
119 * \ingroup lr-wpan
120 *
121 * MCPS-DATA.request params. See 7.1.1.1
122 */
124{
125 AddressMode m_srcAddrMode{SHORT_ADDR}; //!< Source address mode
126 AddressMode m_dstAddrMode{SHORT_ADDR}; //!< Destination address mode
127 uint16_t m_dstPanId{0}; //!< Destination PAN identifier
128 Mac16Address m_dstAddr; //!< Destination address
129 Mac64Address m_dstExtAddr; //!< Destination extended address
130 uint8_t m_msduHandle{0}; //!< MSDU handle
131 uint8_t m_txOptions{0}; //!< Tx Options (bitfield)
132};
133
134/**
135 * \ingroup lr-wpan
136 *
137 * MLME-START.request params. See 802.15.4-2011 Section 6.2.12.1
138 */
140{
141 uint16_t m_PanId{0}; //!< Pan Identifier used by the device.
142 uint8_t m_logCh{11}; //!< Logical channel on which to start using the
143 //!< new superframe configuration.
144 uint32_t m_logChPage{0}; //!< Logical channel page on which to start using the
145 //!< new superframe configuration.
146 uint32_t m_startTime{0}; //!< Time at which to begin transmitting beacons (Used by Coordinator
147 //!< not PAN Coordinators). The time is specified in symbols.
148 uint8_t m_bcnOrd{15}; //!< Beacon Order, Used to calculate the beacon interval, a value of 15
149 //!< indicates no periodic beacons will be transmitted.
150 uint8_t m_sfrmOrd{15}; //!< Superframe Order, indicates the length of the CAP in time slots.
151 bool m_panCoor{false}; //!< On true this device will become coordinator.
152 bool m_battLifeExt{false}; //!< Flag indicating whether or not the Battery life extension (BLE)
153 //!< features are used.
154 bool m_coorRealgn{false}; //!< True if a realignment request command is to be transmitted prior
155 //!< changing the superframe.
156};
157
158/**
159 * \ingroup lr-wpan
160 *
161 * MLME-SCAN.request params. See IEEE 802.15.4-2011 Section 6.2.10.1 Table 30
162 */
164{
165 MlmeScanType m_scanType{MLMESCAN_PASSIVE}; //!< Indicates the type of scan performed as
166 //!< described in IEEE 802.15.4-2011 (5.1.2.1).
167 uint32_t m_scanChannels{0x7FFF800}; //!< The channel numbers to be scanned.
168 //!< Default: (0x7FFF800 = Ch11-Ch26)
169 //!< 27 LSB (b0,b1,...,b26) = channels
170 uint8_t m_scanDuration{14}; //!< The factor (0-14) used to calculate the length of time
171 //!< to spend scanning.
172 //!< scanDurationSymbols =
173 //!< [aBaseSuperframeDuration * (2^m_scanDuration + 1)].
174 uint32_t m_chPage{0}; //!< The channel page on which to perform scan.
175};
176
177/**
178 * \ingroup lr-wpan
179 *
180 * MLME-ASSOCIATE.request params. See 802.15.4-2011 Section 6.2.2.1
181 */
183{
184 uint8_t m_chNum{11}; //!< The channel number on which to attempt association.
185 uint32_t m_chPage{0}; //!< The channel page on which to attempt association.
186 uint8_t m_coordAddrMode{SHORT_ADDR}; //!< The coordinator addressing mode for this
187 //!< primitive and subsequent MPDU.
188 uint16_t m_coordPanId{0}; //!< The identifier of the PAN with which to associate.
189 Mac16Address m_coordShortAddr; //!< The short address of the coordinator
190 //!< with which to associate.
191 Mac64Address m_coordExtAddr; //!< The extended address of the coordinator
192 //!< with which to associate.
193 uint8_t m_capabilityInfo{0}; //!< Specifies the operational capabilities
194 //!< of the associating device (bitmap).
195};
196
197/**
198 * \ingroup lr-wpan
199 *
200 * MLME-ASSOCIATE.response params. See 802.15.4-2011 6.2.2.3.
201 */
203{
204 Mac64Address m_extDevAddr; //!< The extended address of the device requesting association
205 Mac16Address m_assocShortAddr; //!< The short address allocated by the coordinator on successful
206 //!< assoc. FF:FF = Unsuccessful
208 MacStatus::ACCESS_DENIED}; //!< The status of the association
209 //!< attempt (As defined on Table 83 IEEE 802.15.4-2006)
210};
211
212/**
213 * \ingroup lr-wpan
214 *
215 * MLME-ORPHAN.response params. See 802.15.4-2011 Section 6.2.7.2
216 */
218{
219 Mac64Address m_orphanAddr; //!< The address of the orphaned device.
220 Mac16Address m_shortAddr; //!< The short address allocated.
221 bool m_assocMember{false}; //!< T = allocated with this coord | F = otherwise
222};
223
224/**
225 * \ingroup lr-wpan
226 *
227 * MLME-SYNC.request params. See 802.15.4-2011 Section 6.2.13.1
228 */
230{
231 uint8_t m_logCh{11}; //!< The channel number on which to attempt coordinator synchronization.
232 bool m_trackBcn{false}; //!< True if the mlme sync with the next beacon and attempts to track
233 //!< future beacons. False if mlme sync only the next beacon.
234};
235
236/**
237 * \ingroup lr-wpan
238 *
239 * MLME-POLL.request params. See 802.15.4-2011 Section 6.2.14.1
240 */
242{
243 AddressMode m_coorAddrMode{SHORT_ADDR}; //!< The addressing mode of the coordinator
244 //!< to which the pool is intended.
245 uint16_t m_coorPanId{0}; //!< The PAN id of the coordinator to which the poll is intended.
246 Mac16Address m_coorShortAddr; //!< Coordinator short address.
247 Mac64Address m_coorExtAddr; //!< Coordinator extended address.
248};
249
250/**
251 * \ingroup lr-wpan
252 *
253 * IEEE 802.15.4-2006 PHY and MAC PIB Attribute Identifiers Table 23 and Table 86.
254 * Note: Attribute identifiers use standardized values.
255 */
257{
258 pCurrentChannel = 0x00, //!< RF channel used for transmissions and receptions.
259 pCurrentPage = 0x04, //!< The current channel page.
260 macAckWaitDuration = 0x40, //!< Maximum number of symbols to wait for an acknowledgment.
261 macAssociationPermit = 0x41, //!< Indication of whether a coordinator is allowing association.
262 macAutoRequest = 0x42, //!< Indication of whether a device automatically sends a data request
263 //!< command if its address is listed in a beacon frame.
264 macBattLifeExt = 0x43, //!< Indication of whether BLE, through the reduction of coordinator
265 //!< receiver operation time during the CAP, is enabled.
266 macBattLifeExtPeriods = 0x44, //!< In BLE mode, the number of backoff periods during which the
267 //!< the receiver is enabled after the IFS following a beacon.
268 macBeaconPayload = 0x45, //!< The contents of the beacon payload.
269 macBeaconPayloadLength = 0x46, //!< The length in octets of the beacon payload.
270 macBeaconOrder = 0x47, //!< Specification of how often the coordinator transmits its beacon.
271 macBeaconTxTime = 0x48, //!< The time that the device transmitted its last beacome frame,
272 //!< in symbol periods.
273 macBsn = 0x49, //!< The sequence number added to the transmitted beacon frame.
274 macCoordExtendedAddress = 0x4a, //!< The 64-bit address of the coordinator through which
275 //!< the device is associated.
276 macCoordShortAddress = 0x4b, //!< The 16-bit short address assigned to the coordinator through
277 //!< which the device is associated. 0xFFFE = Ext address mode
278 //!< 0xFFFF = Unknown.
279 macDSN = 0x4c, //!< The sequence number added to the transmitted data or MAC command frame.
280 macGTSPermit = 0x4d, //!< True if the PAN coordinator is to accept GTS requests.
281 macMaxCSMABackoff = 0x4e, //!< The maximum number of backoffs the CSMA-CA algorithm
282 //!< will attempt before declaring a channel access failure.
283 macMinBE = 0x4f, //!< The minimum value of the backoff exponent (BE) in the CSMA-CA algorithm.
284 macExtendedAddress = 0x6f, //!< The extended address of the device (64 bit address). The id
285 //!< is not compliant for 2003 and 2006 versions, but this attribute
286 //!< is later on added to the Pib attributes in 2011 and subsequent
287 //!< editions of the standard.
288 macPanId = 0x50, //!< The 16-bit identifier of the Personal Area Network (PAN).
289 macPromiscuousMode = 0x51, //!< Indication of whether the MAC sublayer is in a promiscuous
290 //!< mode. True indicates that the MAC sublayer accepts all frames.
291 macRxOnWhenIdle = 0x52, //!< Indication of whether the MAC is enabled during idle periods.
292 macShortAddress = 0x53, //!< The short address of the device (16 bit address).
293 macSuperframeOrder = 0x54, //!< The length of the active portion of the outgoing superframe,
294 //!< including the beacon frame.
295 macTransactionPersistenceTime = 0x55, //!< The maximum time (in unit periods) that a
296 //!< transaction is stored by a coordinator and
297 //!< indicated in its beacon.
298 macMaxFrameRetries = 0x59, //!< The maximum number of retries allowed after a transmission
299 //!< failure.
300 macResponseWaitTime = 0x5a, //!< The maximum time in multiples of aBaseSuperframeDuration, a
301 //!< device shall wait for a response command frame to be
302 //!< available following a request command frame.
303 unsupported = 255
304 // TODO: complete other MAC pib attributes
306
307/**
308 * \ingroup lr-wpan
309 *
310 * IEEE802.15.4-2011 PHY PIB Attributes Table 52 in section 6.4.2
311 */
312struct MacPibAttributes : public SimpleRefCount<MacPibAttributes>
313{
314 Ptr<Packet> macBeaconPayload; //!< The contents of the beacon payload.
315 uint8_t macBeaconPayloadLength{0}; //!< The length in octets of the beacon payload.
316 Mac16Address macShortAddress; //!< The 16 bit mac short address
317 Mac64Address macExtendedAddress; //!< The EUI-64 bit address
318 uint16_t macPanId{0xffff}; //!< The identifier of the PAN
319 uint8_t pCurrentChannel{11}; //!< The current logical channel in used in the PHY
320 uint8_t pCurrentPage{0}; //!< The current logical page in use in the PHY
321 // TODO: complete other MAC pib attributes
322};
323
324/**
325 * \ingroup lr-wpan
326 *
327 * MCPS-DATA.confirm params. See 7.1.1.2
328 */
330{
331 uint8_t m_msduHandle{0}; //!< MSDU handle
333 //!< of the last MSDU transmission
334};
335
336/**
337 * \ingroup lr-wpan
338 *
339 * MCPS-DATA.indication params. See 7.1.1.3
340 */
342{
343 uint8_t m_srcAddrMode{SHORT_ADDR}; //!< Source address mode
344 uint16_t m_srcPanId{0}; //!< Source PAN identifier
345 Mac16Address m_srcAddr; //!< Source address
346 Mac64Address m_srcExtAddr; //!< Source extended address
347 uint8_t m_dstAddrMode{SHORT_ADDR}; //!< Destination address mode
348 uint16_t m_dstPanId{0}; //!< Destination PAN identifier
349 Mac16Address m_dstAddr; //!< Destination address
350 Mac64Address m_dstExtAddr; //!< Destination extended address
351 uint8_t m_mpduLinkQuality{0}; //!< LQI value measured during reception of the MPDU
352 uint8_t m_dsn{0}; //!< The DSN of the received data frame
353};
354
355/**
356 * \ingroup lr-wpan
357 *
358 * MLME-ASSOCIATE.indication params. See 802.15.4-2011 6.2.2.2.
359 */
361{
362 Mac64Address m_extDevAddr; //!< The extended address of the device requesting association
363 uint8_t capabilityInfo{0}; //!< The operational capabilities of
364 //!< the device requesting association.
365 uint8_t lqi{0}; //!< The link quality indicator of the received associate request command
366 //!< (Not officially supported in the standard but found in implementations)
367};
368
369/**
370 * \ingroup lr-wpan
371 *
372 * MLME-COMM-STATUS.indication params. See 802.15.4-2011 Section 6.2.4.2 Table 18
373 */
375{
376 uint16_t m_panId{0}; //!< The PAN identifier of the device from which the frame was received or
377 //!< to which the frame was being sent.
378 uint8_t m_srcAddrMode{SHORT_ADDR}; //!< The source addressing mode for this primitive
379 Mac16Address m_srcShortAddr; //!< The short address of the entity from which the frame causing
380 //!< the error originated.
381 Mac64Address m_srcExtAddr; //!< The extended address of the entity from which the frame causing
382 //!< the error originated.
383 uint8_t m_dstAddrMode{SHORT_ADDR}; //!< The destination addressing mode for this primitive.
384 Mac16Address m_dstShortAddr; //!< The short address of the device for
385 //!< which the frame was intended.
386 Mac64Address m_dstExtAddr; //!< The extended address of the device for
387 //!< which the frame was intended.
388 MacStatus m_status{MacStatus::INVALID_PARAMETER}; //!< The communication status
389};
390
391/**
392 * \ingroup lr-wpan
393 *
394 * MLME-ORPHAN.indication params. See 802.15.4-2011 Section 6.2.7.1
395 */
397{
398 Mac64Address m_orphanAddr; //!< The address of the orphaned device.
399};
400
401/**
402 * \ingroup lr-wpan
403 *
404 * MLME-START.confirm params. See 802.15.4-2011 Section 6.2.12.2
405 */
407{
409 //!< a MLME-start.request
410};
411
412/**
413 * \ingroup lr-wpan
414 *
415 * PAN Descriptor, Table 17 IEEE 802.15.4-2011
416 */
418{
419 AddressMode m_coorAddrMode{SHORT_ADDR}; //!< The coordinator addressing mode corresponding
420 //!< to the received beacon frame.
421 uint16_t m_coorPanId{0xffff}; //!< The PAN ID of the coordinator as specified in
422 //!< the received beacon frame.
423 Mac16Address m_coorShortAddr; //!< The coordinator short address as specified in the coordinator
424 //!< address mode.
425 Mac64Address m_coorExtAddr; //!< The coordinator extended address as specified in the
426 //!< coordinator address mode.
427 uint8_t m_logCh{11}; //!< The current channel number occupied by the network.
428 uint8_t m_logChPage{0}; //!< The current channel page occupied by the network.
429 uint16_t m_superframeSpec{0}; //!< The superframe specification as specified in the received
430 //!< beacon frame.
431 bool m_gtsPermit{false}; //!< TRUE if the beacon is from the PAN coordinator
432 //!< that is accepting GTS requests.
433 uint8_t m_linkQuality{0}; //!< The LQI at which the network beacon was received.
434 //!< Lower values represent lower LQI.
435 Time m_timeStamp; //!< Beacon frame reception time. Used as Time data type in ns-3 to avoid
436 //!< precision problems.
437};
438
439/**
440 * \ingroup lr-wpan
441 *
442 * MLME-SCAN.confirm params. See IEEE 802.15.4-2011 Section 6.2.10.2
443 */
445{
446 MacStatus m_status{MacStatus::INVALID_PARAMETER}; //!< The status of the scan request.
447 uint8_t m_scanType{MLMESCAN_PASSIVE}; //!< Indicates the type of scan
448 //!< performed (ED,ACTIVE,PASSIVE,ORPHAN).
449 uint32_t m_chPage{0}; //!< The channel page on which the scan was performed.
450 std::vector<uint8_t> m_unscannedCh; //!< A list of channels given in the request which
451 //!< were not scanned (Not valid for ED scans).
452 uint8_t m_resultListSize{0}; //!< The number of elements returned in the appropriate
453 //!< result list. (Not valid for Orphan scan).
454 std::vector<uint8_t> m_energyDetList; //!< A list of energy measurements, one for each
455 //!< channel searched during ED scan
456 //!< (Not valid for Active, Passive or Orphan Scans)
457 std::vector<PanDescriptor> m_panDescList; //!< A list of PAN descriptor, one for each beacon
458 //!< found (Not valid for ED and Orphan scans).
459};
460
461/**
462 * \ingroup lr-wpan
463 *
464 * MLME-ASSOCIATE.confirm params. See 802.15.4-2011 Section 6.2.2.4
465 */
467{
468 Mac16Address m_assocShortAddr; //!< The short address used in the association request
470 //!< a MLME-associate.request
471};
472
473/**
474 * \ingroup lr-wpan
475 *
476 * MLME-BEACON-NOTIFY.indication params. See 802.15.4-2011 Section 6.2.4.1, Table 16
477 */
479{
480 uint8_t m_bsn{0}; //!< The beacon sequence number.
481 PanDescriptor m_panDescriptor; //!< The PAN descriptor for the received beacon.
482 uint32_t m_sduLength{0}; //!< The number of octets contained in the beacon payload.
483 Ptr<Packet> m_sdu; //!< The set of octets comprising the beacon payload.
484};
485
486/**
487 * \ingroup lr-wpan
488 *
489 * MLME-SYNC-LOSS.indication params. See 802.15.4-2011 Section 6.2.13.2, Table 37
490 */
492{
493 MacStatus m_lossReason{MacStatus::PAN_ID_CONFLICT}; //!< The reason for the lost
494 //!< of synchronization.
495 uint16_t m_panId{0}; //!< The PAN identifier with which the device lost synchronization or to
496 //!< which it was realigned.
497 uint8_t m_logCh{11}; //!< The channel number on which the device lost synchronization or to
498 //!< which it was realigned.
499};
500
501/**
502 * \ingroup lr-wpan
503 *
504 * MLME-SET.confirm params. See 802.15.4-2011 Section 6.2.11.2
505 */
507{
509 //!< the request to write
510 //!< the PIB attribute.
511 MacPibAttributeIdentifier id; //!< The id of the PIB attribute that was written.
512};
513
514/**
515 * \ingroup lr-wpan
516 *
517 * MLME-START.confirm params. See 802.15.4-2011 Section 6.2.14.2
518 */
520{
522 //!< status resulting from a
523 //!< MLME-poll.request.
524};
525
526/**
527 * \ingroup lr-wpan
528 *
529 * This callback is called after a McpsDataRequest has been called from
530 * the higher layer. It returns a status of the outcome of the
531 * transmission request
532 */
534
535/**
536 * \ingroup lr-wpan
537 *
538 * This callback is called after a Mcps has successfully received a
539 * frame and wants to deliver it to the higher layer.
540 *
541 * \todo for now, we do not deliver all of the parameters in section
542 * 802.15.4-2006 7.1.1.3.1 but just send up the packet.
543 */
545
546/**
547 * \ingroup lr-wpan
548 *
549 * This callback is called after a Mlme has successfully received a command
550 * frame and wants to deliver it to the higher layer.
551 *
552 * Security related parameters and not handle.
553 * See 802.15.4-2011 6.2.2.2.
554 */
556
557/**
558 * \ingroup lr-wpan
559 *
560 * This callback is called by the MLME and issued to its next higher layer following
561 * a transmission instigated through a response primitive.
562 *
563 * Security related parameters and not handle.
564 * See 802.15.4-2011 6.2.4.2
565 */
567
568/**
569 * \ingroup lr-wpan
570 *
571 * This callback is called by the MLME and issued to its next higher layer following
572 * the reception of a orphan notification.
573 *
574 * Security related parameters and not handle.
575 * See 802.15.4-2011 6.2.7.1
576 */
578
579/**
580 * \ingroup lr-wpan
581 *
582 * This callback is called after a MlmeStartRequest has been called from
583 * the higher layer. It returns a status of the outcome of the
584 * transmission request
585 */
587
588/**
589 * \ingroup lr-wpan
590 *
591 * This callback is called after a MlmeScanRequest has been called from
592 * the higher layer. It returns a status of the outcome of the scan.
593 */
595
596/**
597 * \ingroup lr-wpan
598 *
599 * This callback is called after a MlmeAssociateRequest has been called from
600 * the higher layer. It returns a status of the outcome of the
601 * association request
602 */
604
605/**
606 * \ingroup lr-wpan
607 *
608 * This callback is called after a Mlme has successfully received a
609 * beacon frame and wants to deliver it to the higher layer.
610 *
611 * \todo for now, we do not deliver all of the parameters in section
612 * 802.15.4-2006 6.2.4.1 but just send up the packet.
613 */
615
616/**
617 * \ingroup lr-wpan
618 *
619 * This callback is called to indicate the loss of synchronization with
620 * a coordinator.
621 *
622 * \todo for now, we do not deliver all of the parameters in section
623 * See IEEE 802.15.4-2011 6.2.13.2.
624 */
626
627/**
628 * \ingroup lr-wpan
629 *
630 * This callback is called after a MlmeSetRequest has been called from
631 * the higher layer to set a PIB. It returns a status of the outcome of the
632 * write attempt.
633 */
635
636/**
637 * \ingroup lr-wpan
638 *
639 * This callback is called after a MlmeGetRequest has been called from
640 * the higher layer to get a PIB. It returns a status of the outcome of the
641 * write attempt.
642 */
645
646/**
647 * \ingroup lr-wpan
648 *
649 * This callback is called after a Mlme-Poll.Request has been called from
650 * the higher layer. It returns a status of the outcome of the
651 * transmission request
652 */
654
655/**
656 * \ingroup netdevice
657 *
658 * \brief Lr-wpan MAC layer abstraction
659 *
660 * This class defines the interface functions (primitives) used by a IEEE 802.15.4-2011 compliant
661 * MAC layer. Any lr-wpan MAC should extend from this class and implement the
662 * behavior of the basic MAC interfaces (primitives).
663 *
664 */
665class LrWpanMacBase : public Object
666{
667 public:
668 /**
669 * \brief Get the type ID.
670 * \return the object TypeId
671 */
672 static TypeId GetTypeId();
673 ~LrWpanMacBase() override;
674
675 /**
676 * IEEE 802.15.4-2006, section 7.1.1.1
677 * MCPS-DATA.request
678 * Request to transfer a MSDU.
679 *
680 * \param params the request parameters
681 * \param p the packet to be transmitted
682 */
684
685 /**
686 * IEEE 802.15.4-2006, section 7.1.14.1
687 * MLME-START.request
688 * Request to allow a PAN coordinator to initiate
689 * a new PAN or beginning a new superframe configuration.
690 *
691 * \param params the request parameters
692 */
693 virtual void MlmeStartRequest(MlmeStartRequestParams params) = 0;
694
695 /**
696 * IEEE 802.15.4-2011, section 6.2.10.1
697 * MLME-SCAN.request
698 * Request primitive used to initiate a channel scan over a given list of channels.
699 *
700 * \param params the scan request parameters
701 */
702 virtual void MlmeScanRequest(MlmeScanRequestParams params) = 0;
703
704 /**
705 * IEEE 802.15.4-2011, section 6.2.2.1
706 * MLME-ASSOCIATE.request
707 * Request primitive used by a device to request an association with
708 * a coordinator.
709 *
710 * \param params the request parameters
711 */
713
714 /**
715 * IEEE 802.15.4-2011, section 6.2.2.3
716 * MLME-ASSOCIATE.response
717 * Primitive used to initiate a response to an MLME-ASSOCIATE.indication
718 * primitive.
719 *
720 * \param params the associate response parameters
721 */
723
724 /**
725 * IEEE 802.15.4-2011, section 6.2.13.1
726 * MLME-SYNC.request
727 * Request to synchronize with the coordinator by acquiring and,
728 * if specified, tracking beacons.
729 *
730 * \param params the request parameters
731 */
732 virtual void MlmeSyncRequest(MlmeSyncRequestParams params) = 0;
733
734 /**
735 * IEEE 802.15.4-2011, section 6.2.14.2
736 * MLME-POLL.request
737 * Prompts the device to request data from the coordinator.
738 *
739 * \param params the request parameters
740 */
741 virtual void MlmePollRequest(MlmePollRequestParams params) = 0;
742
743 /**
744 * IEEE 802.15.4-2011, section 6.2.7.2
745 * MLME-ORPHAN.response
746 * Primitive used to initiatte a response to an MLME-ORPHAN.indication
747 * primitive.
748 *
749 * \param params the orphan response parameters
750 */
752
753 /**
754 * IEEE 802.15.4-2011, section 6.2.11.1
755 * MLME-SET.request
756 * Attempts to write the given value to the indicated PIB attribute.
757 *
758 * \param id the attributed identifier
759 * \param attribute the attribute value
760 */
762
763 /**
764 * IEEE 802.15.4-2006, section 7.1.6.1
765 * MLME-GET.request
766 * Request information about a given PIB attribute.
767 * Note: The PibAttributeIndex parameter is not included because
768 * attributes that represent tables are not supported.
769 *
770 * \param id the attribute identifier
771 */
773
774 /**
775 * Set the callback for the confirmation of a data transmission request.
776 * The callback implements MCPS-DATA.confirm SAP of IEEE 802.15.4-2006,
777 * section 7.1.1.2.
778 *
779 * \param c the callback
780 */
782
783 /**
784 * Set the callback for the indication of an incoming data packet.
785 * The callback implements MCPS-DATA.indication SAP of IEEE 802.15.4-2006,
786 * section 7.1.1.3.
787 *
788 * \param c the callback
789 */
791
792 /**
793 * Set the callback for the indication of an incoming associate request command.
794 * The callback implements MLME-ASSOCIATE.indication SAP of IEEE 802.15.4-2011,
795 * section 6.2.2.2.
796 *
797 * \param c the callback
798 */
800
801 /**
802 * Set the callback for the indication to a response primitive.
803 * The callback implements MLME-COMM-STATUS.indication SAP of IEEE 802.15.4-2011,
804 * section 6.2.4.2.
805 *
806 * \param c the callback
807 */
809
810 /**
811 * Set the callback for the indication to the reception of an orphan notification.
812 * The callback implements MLME-ORPHAN.indication SAP of IEEE 802.15.4-2011,
813 * section 6.2.7.1.
814 *
815 * \param c the callback
816 */
818
819 /**
820 * Set the callback for the confirmation of a data transmission request.
821 * The callback implements MLME-START.confirm SAP of IEEE 802.15.4-2006,
822 * section 7.1.14.2.
823 *
824 * \param c the callback
825 */
827
828 /**
829 * Set the callback for the confirmation of a data transmission request.
830 * The callback implements MLME-SCAN.confirm SAP of IEEE 802.15.4-2011,
831 * section 6.2.10.2.
832 *
833 * \param c the callback
834 */
836
837 /**
838 * Set the callback for the confirmation of a data transmission request.
839 * The callback implements MLME-ASSOCIATE.confirm SAP of IEEE 802.15.4-2011,
840 * section 6.2.2.4.
841 *
842 * \param c the callback
843 */
845
846 /**
847 * Set the callback for the indication of an incoming beacon packet.
848 * The callback implements MLME-BEACON-NOTIFY.indication SAP of IEEE 802.15.4-2011,
849 * section 6.2.4.1.
850 *
851 * \param c the callback
852 */
854
855 /**
856 * Set the callback for the loss of synchronization with a coordinator.
857 * The callback implements MLME-SYNC-LOSS.indication SAP of IEEE 802.15.4-2011,
858 * section 6.2.13.2.
859 *
860 * \param c the callback
861 */
863
864 /**
865 * Set the callback for the confirmation of an attempt to write an attribute.
866 * The callback implements MLME-SET.confirm SAP of IEEE 802.15.4-2011,
867 * section 6.2.11.2
868 *
869 * \param c the callback
870 */
872
873 /**
874 * Set the callback for the confirmation of an attempt to read an attribute.
875 * The callback implements MLME-GET.confirm SAP of IEEE 802.15.4-2011,
876 * section 6.2.5.2
877 *
878 *\param c the callback
879 */
881
882 /**
883 * Set the callback for the confirmation of a data transmission request.
884 * The callback implements MLME-POLL.confirm SAP of IEEE 802.15.4-2011,
885 * section 6.2.14.2
886 *
887 * \param c the callback
888 */
890
891 protected:
892 /**
893 * This callback is used to report data transmission request status to the
894 * upper layers.
895 * See IEEE 802.15.4-2006, section 7.1.1.2.
896 */
898
899 /**
900 * This callback is used to notify incoming packets to the upper layers.
901 * See IEEE 802.15.4-2006, section 7.1.1.3.
902 */
904
905 /**
906 * This callback is used to indicate the reception of an association request command.
907 * See IEEE 802.15.4-2011, section 6.2.2.2
908 */
910
911 /**
912 * This callback is instigated through a response primitive.
913 * See IEEE 802.15.4-2011, section 6.2.4.2
914 */
916
917 /**
918 * This callback is used to indicate the reception of a orphan notification command.
919 * See IEEE 802.15.4-2011, section 6.2.7.1
920 */
922
923 /**
924 * This callback is used to report the start of a new PAN or
925 * the begin of a new superframe configuration.
926 * See IEEE 802.15.4-2006, section 7.1.14.2.
927 */
929
930 /**
931 * This callback is used to report the result of a scan on a group of channels for the
932 * selected channel page.
933 * See IEEE 802.15.4-2011, section 6.2.10.2.
934 */
936
937 /**
938 * This callback is used to report the status after a device request an association with
939 * a coordinator.
940 * See IEEE 802.15.4-2011, section 6.2.2.4.
941 */
943
944 /**
945 * This callback is used to notify incoming beacon packets to the upper layers.
946 * See IEEE 802.15.4-2011, section 6.2.4.1.
947 */
949
950 /**
951 * This callback is used to indicate the loss of synchronization with a coordinator.
952 * See IEEE 802.15.4-2011, section 6.2.13.2.
953 */
955
956 /**
957 * This callback is used to report the result of an attribute writing request
958 * to the upper layers.
959 * See IEEE 802.15.4-2011, section 6.2.11.2.
960 */
962
963 /**
964 * This callback is used to report the result of an attribute read request
965 * to the upper layers.
966 * See IEEE 802.15.4-2011, section 6.2.5.2
967 */
969
970 /**
971 * This callback is used to report the status after a device send data command request to
972 * the coordinator to transmit data.
973 * See IEEE 802.15.4-2011, section 6.2.14.2.
974 */
976};
977
978} // namespace lrwpan
979} // namespace ns3
980
981#endif /* LR_WPAN_MAC_BASE_H*/
This class can contain 16 bit addresses.
Definition: mac16-address.h:44
an EUI-64 address
Definition: mac64-address.h:46
A base class which provides memory management and object aggregation.
Definition: object.h:89
Smart pointer class similar to boost::intrusive_ptr.
Definition: ptr.h:77
A template-based reference counting class.
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:105
a unique identifier for an interface.
Definition: type-id.h:59
Lr-wpan MAC layer abstraction.
void SetMcpsDataConfirmCallback(McpsDataConfirmCallback c)
Set the callback for the confirmation of a data transmission request.
virtual void MlmePollRequest(MlmePollRequestParams params)=0
IEEE 802.15.4-2011, section 6.2.14.2 MLME-POLL.request Prompts the device to request data from the co...
MlmeOrphanIndicationCallback m_mlmeOrphanIndicationCallback
This callback is used to indicate the reception of a orphan notification command.
MlmeGetConfirmCallback m_mlmeGetConfirmCallback
This callback is used to report the result of an attribute read request to the upper layers.
MlmeAssociateIndicationCallback m_mlmeAssociateIndicationCallback
This callback is used to indicate the reception of an association request command.
virtual void McpsDataRequest(McpsDataRequestParams params, Ptr< Packet > p)=0
IEEE 802.15.4-2006, section 7.1.1.1 MCPS-DATA.request Request to transfer a MSDU.
MlmeSetConfirmCallback m_mlmeSetConfirmCallback
This callback is used to report the result of an attribute writing request to the upper layers.
virtual void MlmeOrphanResponse(MlmeOrphanResponseParams params)=0
IEEE 802.15.4-2011, section 6.2.7.2 MLME-ORPHAN.response Primitive used to initiatte a response to an...
MlmePollConfirmCallback m_mlmePollConfirmCallback
This callback is used to report the status after a device send data command request to the coordinato...
MlmeCommStatusIndicationCallback m_mlmeCommStatusIndicationCallback
This callback is instigated through a response primitive.
virtual void MlmeSyncRequest(MlmeSyncRequestParams params)=0
IEEE 802.15.4-2011, section 6.2.13.1 MLME-SYNC.request Request to synchronize with the coordinator by...
virtual void MlmeGetRequest(MacPibAttributeIdentifier id)=0
IEEE 802.15.4-2006, section 7.1.6.1 MLME-GET.request Request information about a given PIB attribute.
void SetMlmeSyncLossIndicationCallback(MlmeSyncLossIndicationCallback c)
Set the callback for the loss of synchronization with a coordinator.
McpsDataConfirmCallback m_mcpsDataConfirmCallback
This callback is used to report data transmission request status to the upper layers.
virtual void MlmeScanRequest(MlmeScanRequestParams params)=0
IEEE 802.15.4-2011, section 6.2.10.1 MLME-SCAN.request Request primitive used to initiate a channel s...
virtual void MlmeAssociateResponse(MlmeAssociateResponseParams params)=0
IEEE 802.15.4-2011, section 6.2.2.3 MLME-ASSOCIATE.response Primitive used to initiate a response to ...
void SetMlmeOrphanIndicationCallback(MlmeOrphanIndicationCallback c)
Set the callback for the indication to the reception of an orphan notification.
McpsDataIndicationCallback m_mcpsDataIndicationCallback
This callback is used to notify incoming packets to the upper layers.
virtual void MlmeStartRequest(MlmeStartRequestParams params)=0
IEEE 802.15.4-2006, section 7.1.14.1 MLME-START.request Request to allow a PAN coordinator to initiat...
MlmeScanConfirmCallback m_mlmeScanConfirmCallback
This callback is used to report the result of a scan on a group of channels for the selected channel ...
void SetMlmeCommStatusIndicationCallback(MlmeCommStatusIndicationCallback c)
Set the callback for the indication to a response primitive.
void SetMlmeAssociateConfirmCallback(MlmeAssociateConfirmCallback c)
Set the callback for the confirmation of a data transmission request.
virtual void MlmeAssociateRequest(MlmeAssociateRequestParams params)=0
IEEE 802.15.4-2011, section 6.2.2.1 MLME-ASSOCIATE.request Request primitive used by a device to requ...
MlmeAssociateConfirmCallback m_mlmeAssociateConfirmCallback
This callback is used to report the status after a device request an association with a coordinator.
void SetMlmeStartConfirmCallback(MlmeStartConfirmCallback c)
Set the callback for the confirmation of a data transmission request.
void SetMlmePollConfirmCallback(MlmePollConfirmCallback c)
Set the callback for the confirmation of a data transmission request.
static TypeId GetTypeId()
Get the type ID.
MlmeSyncLossIndicationCallback m_mlmeSyncLossIndicationCallback
This callback is used to indicate the loss of synchronization with a coordinator.
void SetMlmeScanConfirmCallback(MlmeScanConfirmCallback c)
Set the callback for the confirmation of a data transmission request.
void SetMlmeGetConfirmCallback(MlmeGetConfirmCallback c)
Set the callback for the confirmation of an attempt to read an attribute.
MlmeBeaconNotifyIndicationCallback m_mlmeBeaconNotifyIndicationCallback
This callback is used to notify incoming beacon packets to the upper layers.
void SetMcpsDataIndicationCallback(McpsDataIndicationCallback c)
Set the callback for the indication of an incoming data packet.
void SetMlmeBeaconNotifyIndicationCallback(MlmeBeaconNotifyIndicationCallback c)
Set the callback for the indication of an incoming beacon packet.
virtual void MlmeSetRequest(MacPibAttributeIdentifier id, Ptr< MacPibAttributes > attribute)=0
IEEE 802.15.4-2011, section 6.2.11.1 MLME-SET.request Attempts to write the given value to the indica...
void SetMlmeSetConfirmCallback(MlmeSetConfirmCallback c)
Set the callback for the confirmation of an attempt to write an attribute.
MlmeStartConfirmCallback m_mlmeStartConfirmCallback
This callback is used to report the start of a new PAN or the begin of a new superframe configuration...
void SetMlmeAssociateIndicationCallback(MlmeAssociateIndicationCallback c)
Set the callback for the indication of an incoming associate request command.
MacPibAttributeIdentifier
IEEE 802.15.4-2006 PHY and MAC PIB Attribute Identifiers Table 23 and Table 86.
AddressMode
table 80 of 802.15.4
MlmeScanType
Table 30 of IEEE 802.15.4-2011.
MacStatus
The status of a confirm or an indication primitive as a result of a previous request.
@ macCoordShortAddress
The 16-bit short address assigned to the coordinator through which the device is associated.
@ macPanId
The 16-bit identifier of the Personal Area Network (PAN).
@ pCurrentChannel
RF channel used for transmissions and receptions.
@ macBsn
The sequence number added to the transmitted beacon frame.
@ macShortAddress
The short address of the device (16 bit address).
@ macSuperframeOrder
The length of the active portion of the outgoing superframe, including the beacon frame.
@ macAutoRequest
Indication of whether a device automatically sends a data request command if its address is listed in...
@ macBeaconOrder
Specification of how often the coordinator transmits its beacon.
@ macAckWaitDuration
Maximum number of symbols to wait for an acknowledgment.
@ macRxOnWhenIdle
Indication of whether the MAC is enabled during idle periods.
@ macBeaconPayloadLength
The length in octets of the beacon payload.
@ macPromiscuousMode
Indication of whether the MAC sublayer is in a promiscuous mode.
@ macBeaconTxTime
The time that the device transmitted its last beacome frame, in symbol periods.
@ macMaxCSMABackoff
The maximum number of backoffs the CSMA-CA algorithm will attempt before declaring a channel access f...
@ pCurrentPage
The current channel page.
@ macMinBE
The minimum value of the backoff exponent (BE) in the CSMA-CA algorithm.
@ macExtendedAddress
The extended address of the device (64 bit address).
@ macBattLifeExtPeriods
In BLE mode, the number of backoff periods during which the the receiver is enabled after the IFS fol...
@ macGTSPermit
True if the PAN coordinator is to accept GTS requests.
@ macBattLifeExt
Indication of whether BLE, through the reduction of coordinator receiver operation time during the CA...
@ macResponseWaitTime
The maximum time in multiples of aBaseSuperframeDuration, a device shall wait for a response command ...
@ macMaxFrameRetries
The maximum number of retries allowed after a transmission failure.
@ macAssociationPermit
Indication of whether a coordinator is allowing association.
@ macDSN
The sequence number added to the transmitted data or MAC command frame.
@ macCoordExtendedAddress
The 64-bit address of the coordinator through which the device is associated.
@ macTransactionPersistenceTime
The maximum time (in unit periods) that a transaction is stored by a coordinator and indicated in its...
@ macBeaconPayload
The contents of the beacon payload.
@ CHANNEL_ACCESS_FAILURE
CHANNEL_ACCESS_FAILURE.
Definition: lr-wpan-mac.h:80
@ TRANSACTION_OVERFLOW
There is no capacity to store the transaction.
@ NO_BEACON
A scan operation failed to find any network beacons.
@ TX_ACTIVE
The transceiver was already enabled.
@ INVALID_GTS
Missing GTS transmit or undefined direction.
@ UNSUPPORTED_ATTRIBUTE
SET/GET request issued with a non supported ID.
@ NO_SHORT_ADDRESS
Failure due to unallocated 16-bit short address.
@ PAST_TIME
Rx enable request fail due to lack of time in superframe.
@ ACCESS_DENIED
PAN access denied.
@ BEACON_LOSS
The beacon was lost following a synchronization request.
@ PAN_ID_CONFLICT
PAN id conflict detected and informed to the coordinator.
@ DISABLE_TRX_FAILURE
The attempt to disable the transceier has failed.
@ LIMIT_REACHED
PAN descriptors stored reached max capacity.
@ TRACKING_OFF
This device is currently not tracking beacons.
@ READ_ONLY
SET/GET request issued for a read only attribute.
@ ON_TIME_TOO_LONG
RX enable request fail due to syms.
@ TRANSACTION_EXPIRED
The transaction expired and its information discarded.
@ SCAN_IN_PROGRESS
Scan failed because already performing another scan.
@ FRAME_TOO_LONG
Frame more than aMaxPHYPacketSize or too large for CAP or GTS.
@ OUT_OF_CAP
(Deprecated) See IEEE 802.15.4-2003
@ IMPROPER_KEY_TYPE
The key is not allowed to be used with that frame type.
@ DENIED
The GTS request has been denied by the PAN coordinator.
@ IMPROPER_SECURITY_LEVEL
Insufficient security level expected by the recipient.
@ INVALID_ADDRESS
Invalid source or destination address.
@ INVALID_HANDLE
When purging from TX queue handle was not found.
@ REALIGMENT
A coordinator realigment command has been received.
@ FULL_CAPACITY
PAN at capacity.
@ COUNTER_ERROR
The frame counter of the received frame is invalid.
@ SUCCESS
The operation was completed successfully.
@ UNSUPPORTED_LEGACY
Deprecated security used in IEEE 802.15.4-2003.
@ NO_ACK
No acknowledgment was received after macMaxFrameRetries.
@ SUPERFRAME_OVERLAP
Coordinator superframe and this device superframe tx overlap.
@ UNAVAILABLE_KEY
Unavailable key, unknown or blacklisted.
@ UNSUPPORTED_SECURITY
The security applied is not supported.
@ NO_DATA
No response data were available following a request.
@ INVALID_INDEX
A MAC PIB write failed because specified index is out of range.
@ INVALID_PARAMETER
Primitive parameter not supported or out of range.
Every class exported by the ns3 library is enclosed in the ns3 namespace.
IEEE802.15.4-2011 PHY PIB Attributes Table 52 in section 6.4.2.
Mac16Address macShortAddress
The 16 bit mac short address.
uint16_t macPanId
The identifier of the PAN.
uint8_t macBeaconPayloadLength
The length in octets of the beacon payload.
uint8_t pCurrentChannel
The current logical channel in used in the PHY.
Mac64Address macExtendedAddress
The EUI-64 bit address.
Ptr< Packet > macBeaconPayload
The contents of the beacon payload.
uint8_t pCurrentPage
The current logical page in use in the PHY.
MacStatus m_status
The status of the last MSDU transmission.
MCPS-DATA.indication params.
uint8_t m_mpduLinkQuality
LQI value measured during reception of the MPDU.
uint16_t m_dstPanId
Destination PAN identifier.
uint8_t m_dsn
The DSN of the received data frame.
Mac16Address m_srcAddr
Source address.
Mac64Address m_dstExtAddr
Destination extended address.
Mac64Address m_srcExtAddr
Source extended address.
Mac16Address m_dstAddr
Destination address.
uint8_t m_dstAddrMode
Destination address mode.
uint16_t m_srcPanId
Source PAN identifier.
uint8_t m_srcAddrMode
Source address mode.
AddressMode m_dstAddrMode
Destination address mode.
Mac16Address m_dstAddr
Destination address.
Mac64Address m_dstExtAddr
Destination extended address.
uint16_t m_dstPanId
Destination PAN identifier.
AddressMode m_srcAddrMode
Source address mode.
uint8_t m_txOptions
Tx Options (bitfield)
MLME-ASSOCIATE.confirm params.
Mac16Address m_assocShortAddr
The short address used in the association request.
MacStatus m_status
The status of a MLME-associate.request.
MLME-ASSOCIATE.indication params.
uint8_t lqi
The link quality indicator of the received associate request command (Not officially supported in the...
Mac64Address m_extDevAddr
The extended address of the device requesting association.
uint8_t capabilityInfo
The operational capabilities of the device requesting association.
MLME-ASSOCIATE.request params.
Mac64Address m_coordExtAddr
The extended address of the coordinator with which to associate.
uint8_t m_coordAddrMode
The coordinator addressing mode for this primitive and subsequent MPDU.
uint8_t m_capabilityInfo
Specifies the operational capabilities of the associating device (bitmap).
Mac16Address m_coordShortAddr
The short address of the coordinator with which to associate.
uint8_t m_chNum
The channel number on which to attempt association.
uint32_t m_chPage
The channel page on which to attempt association.
uint16_t m_coordPanId
The identifier of the PAN with which to associate.
MLME-ASSOCIATE.response params.
Mac16Address m_assocShortAddr
The short address allocated by the coordinator on successful assoc.
MacStatus m_status
The status of the association attempt (As defined on Table 83 IEEE 802.15.4-2006)
Mac64Address m_extDevAddr
The extended address of the device requesting association.
MLME-BEACON-NOTIFY.indication params.
PanDescriptor m_panDescriptor
The PAN descriptor for the received beacon.
uint32_t m_sduLength
The number of octets contained in the beacon payload.
uint8_t m_bsn
The beacon sequence number.
Ptr< Packet > m_sdu
The set of octets comprising the beacon payload.
MLME-COMM-STATUS.indication params.
uint8_t m_dstAddrMode
The destination addressing mode for this primitive.
uint16_t m_panId
The PAN identifier of the device from which the frame was received or to which the frame was being se...
Mac64Address m_srcExtAddr
The extended address of the entity from which the frame causing the error originated.
MacStatus m_status
The communication status.
Mac16Address m_srcShortAddr
The short address of the entity from which the frame causing the error originated.
Mac16Address m_dstShortAddr
The short address of the device for which the frame was intended.
uint8_t m_srcAddrMode
The source addressing mode for this primitive.
Mac64Address m_dstExtAddr
The extended address of the device for which the frame was intended.
MLME-ORPHAN.indication params.
Mac64Address m_orphanAddr
The address of the orphaned device.
MLME-ORPHAN.response params.
bool m_assocMember
T = allocated with this coord | F = otherwise.
Mac64Address m_orphanAddr
The address of the orphaned device.
Mac16Address m_shortAddr
The short address allocated.
MLME-START.confirm params.
MacStatus m_status
The confirmation status resulting from a MLME-poll.request.
uint16_t m_coorPanId
The PAN id of the coordinator to which the poll is intended.
Mac16Address m_coorShortAddr
Coordinator short address.
AddressMode m_coorAddrMode
The addressing mode of the coordinator to which the pool is intended.
Mac64Address m_coorExtAddr
Coordinator extended address.
std::vector< uint8_t > m_unscannedCh
A list of channels given in the request which were not scanned (Not valid for ED scans).
uint32_t m_chPage
The channel page on which the scan was performed.
std::vector< uint8_t > m_energyDetList
A list of energy measurements, one for each channel searched during ED scan (Not valid for Active,...
MacStatus m_status
The status of the scan request.
std::vector< PanDescriptor > m_panDescList
A list of PAN descriptor, one for each beacon found (Not valid for ED and Orphan scans).
uint8_t m_resultListSize
The number of elements returned in the appropriate result list.
uint8_t m_scanType
Indicates the type of scan performed (ED,ACTIVE,PASSIVE,ORPHAN).
MlmeScanType m_scanType
Indicates the type of scan performed as described in IEEE 802.15.4-2011 (5.1.2.1).
uint32_t m_scanChannels
The channel numbers to be scanned.
uint8_t m_scanDuration
The factor (0-14) used to calculate the length of time to spend scanning.
uint32_t m_chPage
The channel page on which to perform scan.
MacStatus m_status
The result of the request to write the PIB attribute.
MacPibAttributeIdentifier id
The id of the PIB attribute that was written.
MLME-START.confirm params.
MacStatus m_status
The status of a MLME-start.request.
MLME-START.request params.
bool m_battLifeExt
Flag indicating whether or not the Battery life extension (BLE) features are used.
uint8_t m_logCh
Logical channel on which to start using the new superframe configuration.
uint32_t m_logChPage
Logical channel page on which to start using the new superframe configuration.
bool m_coorRealgn
True if a realignment request command is to be transmitted prior changing the superframe.
uint8_t m_bcnOrd
Beacon Order, Used to calculate the beacon interval, a value of 15 indicates no periodic beacons will...
bool m_panCoor
On true this device will become coordinator.
uint8_t m_sfrmOrd
Superframe Order, indicates the length of the CAP in time slots.
uint16_t m_PanId
Pan Identifier used by the device.
uint32_t m_startTime
Time at which to begin transmitting beacons (Used by Coordinator not PAN Coordinators).
MLME-SYNC-LOSS.indication params.
uint16_t m_panId
The PAN identifier with which the device lost synchronization or to which it was realigned.
uint8_t m_logCh
The channel number on which the device lost synchronization or to which it was realigned.
MacStatus m_lossReason
The reason for the lost of synchronization.
uint8_t m_logCh
The channel number on which to attempt coordinator synchronization.
bool m_trackBcn
True if the mlme sync with the next beacon and attempts to track future beacons.
PAN Descriptor, Table 17 IEEE 802.15.4-2011.
uint16_t m_coorPanId
The PAN ID of the coordinator as specified in the received beacon frame.
uint8_t m_logCh
The current channel number occupied by the network.
Time m_timeStamp
Beacon frame reception time.
bool m_gtsPermit
TRUE if the beacon is from the PAN coordinator that is accepting GTS requests.
Mac16Address m_coorShortAddr
The coordinator short address as specified in the coordinator address mode.
uint16_t m_superframeSpec
The superframe specification as specified in the received beacon frame.
AddressMode m_coorAddrMode
The coordinator addressing mode corresponding to the received beacon frame.
uint8_t m_linkQuality
The LQI at which the network beacon was received.
uint8_t m_logChPage
The current channel page occupied by the network.
Mac64Address m_coorExtAddr
The coordinator extended address as specified in the coordinator address mode.