A Discrete-Event Network Simulator
API
lr-wpan-net-device.cc
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:
19  * Tom Henderson <thomas.r.henderson@boeing.com>
20  * Tommaso Pecorella <tommaso.pecorella@unifi.it>
21  * Margherita Filippetti <morag87@gmail.com>
22  */
23 #include "lr-wpan-net-device.h"
24 #include "lr-wpan-phy.h"
25 #include "lr-wpan-csmaca.h"
26 #include "lr-wpan-error-model.h"
27 #include <ns3/abort.h>
28 #include <ns3/node.h>
29 #include <ns3/log.h>
30 #include <ns3/spectrum-channel.h>
31 #include <ns3/pointer.h>
32 #include <ns3/boolean.h>
33 #include <ns3/mobility-model.h>
34 #include <ns3/packet.h>
35 
36 
37 namespace ns3 {
38 
39 NS_LOG_COMPONENT_DEFINE ("LrWpanNetDevice");
40 
41 NS_OBJECT_ENSURE_REGISTERED (LrWpanNetDevice);
42 
43 TypeId
45 {
46  static TypeId tid = TypeId ("ns3::LrWpanNetDevice")
47  .SetParent<NetDevice> ()
48  .SetGroupName ("LrWpan")
49  .AddConstructor<LrWpanNetDevice> ()
50  .AddAttribute ("Channel", "The channel attached to this device",
51  PointerValue (),
53  MakePointerChecker<SpectrumChannel> ())
54  .AddAttribute ("Phy", "The PHY layer attached to this device.",
55  PointerValue (),
58  MakePointerChecker<LrWpanPhy> ())
59  .AddAttribute ("Mac", "The MAC layer attached to this device.",
60  PointerValue (),
63  MakePointerChecker<LrWpanMac> ())
64  .AddAttribute ("UseAcks", "Request acknowledgments for data frames.",
65  BooleanValue (true),
68  ;
69  return tid;
70 }
71 
73  : m_configComplete (false)
74 {
75  NS_LOG_FUNCTION (this);
76  m_mac = CreateObject<LrWpanMac> ();
77  m_phy = CreateObject<LrWpanPhy> ();
78  m_csmaca = CreateObject<LrWpanCsmaCa> ();
79  CompleteConfig ();
80 }
81 
83 {
84  NS_LOG_FUNCTION (this);
85 }
86 
87 
88 void
90 {
91  NS_LOG_FUNCTION (this);
92  m_mac->Dispose ();
93  m_phy->Dispose ();
94  m_csmaca->Dispose ();
95  m_phy = 0;
96  m_mac = 0;
97  m_csmaca = 0;
98  m_node = 0;
99  // chain up.
101 
102 }
103 
104 void
106 {
107  NS_LOG_FUNCTION (this);
108  m_phy->Initialize ();
109  m_mac->Initialize ();
111 }
112 
113 
114 void
116 {
117  NS_LOG_FUNCTION (this);
118  if (m_mac == 0
119  || m_phy == 0
120  || m_csmaca == 0
121  || m_node == 0
122  || m_configComplete)
123  {
124  return;
125  }
126  m_mac->SetPhy (m_phy);
127  m_mac->SetCsmaCa (m_csmaca);
128  m_mac->SetMcpsDataIndicationCallback (MakeCallback (&LrWpanNetDevice::McpsDataIndication, this));
129  m_csmaca->SetMac (m_mac);
130 
132  if (!mobility)
133  {
134  NS_LOG_WARN ("LrWpanNetDevice: no Mobility found on the node, probably it's not a good idea.");
135  }
136  m_phy->SetMobility (mobility);
137  Ptr<LrWpanErrorModel> model = CreateObject<LrWpanErrorModel> ();
138  m_phy->SetErrorModel (model);
139  m_phy->SetDevice (this);
140 
141  m_phy->SetPdDataIndicationCallback (MakeCallback (&LrWpanMac::PdDataIndication, m_mac));
142  m_phy->SetPdDataConfirmCallback (MakeCallback (&LrWpanMac::PdDataConfirm, m_mac));
143  m_phy->SetPlmeEdConfirmCallback (MakeCallback (&LrWpanMac::PlmeEdConfirm, m_mac));
144  m_phy->SetPlmeGetAttributeConfirmCallback (MakeCallback (&LrWpanMac::PlmeGetAttributeConfirm, m_mac));
145  m_phy->SetPlmeSetTRXStateConfirmCallback (MakeCallback (&LrWpanMac::PlmeSetTRXStateConfirm, m_mac));
146  m_phy->SetPlmeSetAttributeConfirmCallback (MakeCallback (&LrWpanMac::PlmeSetAttributeConfirm, m_mac));
147 
148  m_csmaca->SetLrWpanMacStateCallback (MakeCallback (&LrWpanMac::SetLrWpanMacState, m_mac));
149  m_phy->SetPlmeCcaConfirmCallback (MakeCallback (&LrWpanCsmaCa::PlmeCcaConfirm, m_csmaca));
150  m_configComplete = true;
151 }
152 
153 void
155 {
156  NS_LOG_FUNCTION (this);
157  m_mac = mac;
158  CompleteConfig ();
159 }
160 
161 void
163 {
164  NS_LOG_FUNCTION (this);
165  m_phy = phy;
166  CompleteConfig ();
167 }
168 
169 void
171 {
172  NS_LOG_FUNCTION (this);
173  m_csmaca = csmaca;
174  CompleteConfig ();
175 }
176 
177 void
179 {
180  NS_LOG_FUNCTION (this << channel);
181  m_phy->SetChannel (channel);
182  channel->AddRx (m_phy);
183  CompleteConfig ();
184 }
185 
188 {
189  // NS_LOG_FUNCTION (this);
190  return m_mac;
191 }
192 
195 {
196  NS_LOG_FUNCTION (this);
197  return m_phy;
198 }
199 
202 {
203  NS_LOG_FUNCTION (this);
204  return m_csmaca;
205 }
206 void
207 LrWpanNetDevice::SetIfIndex (const uint32_t index)
208 {
209  NS_LOG_FUNCTION (this << index);
210  m_ifIndex = index;
211 }
212 
213 uint32_t
215 {
216  NS_LOG_FUNCTION (this);
217  return m_ifIndex;
218 }
219 
222 {
223  NS_LOG_FUNCTION (this);
224  return m_phy->GetChannel ();
225 }
226 
227 void
229 {
230  NS_LOG_FUNCTION (this);
231  m_linkUp = true;
232  m_linkChanges ();
233 }
234 
235 void
237 {
238  NS_LOG_FUNCTION (this);
239  m_linkUp = false;
240  m_linkChanges ();
241 }
242 
245 {
246  NS_LOG_FUNCTION (this);
247  return m_phy->GetChannel ();
248 }
249 
250 void
252 {
253  NS_LOG_FUNCTION (this);
255  {
256  m_mac->SetShortAddress (Mac16Address::ConvertFrom (address));
257  }
259  {
260  uint8_t buf[6];
262  addr.CopyTo (buf);
263  Mac16Address addr16;
264  addr16.CopyFrom (buf+4);
265  m_mac->SetShortAddress (addr16);
266  uint16_t panId;
267  panId = buf[0];
268  panId <<= 8;
269  panId |= buf[1];
270  m_mac->SetPanId (panId);
271  }
272  else
273  {
274  NS_ABORT_MSG ("LrWpanNetDevice::SetAddress - address is not of a compatible type");
275  }
276 }
277 
278 Address
280 {
281  NS_LOG_FUNCTION (this);
282 
283  if (m_mac->GetShortAddress () == Mac16Address ("00:00"))
284  {
285  return m_mac->GetExtendedAddress ();
286  }
287 
288  Mac48Address pseudoAddress = BuildPseudoMacAddress (m_mac->GetPanId (), m_mac->GetShortAddress ());
289 
290  return pseudoAddress;
291 }
292 
293 bool
294 LrWpanNetDevice::SetMtu (const uint16_t mtu)
295 {
296  NS_ABORT_MSG ("Unsupported");
297  return false;
298 }
299 
300 uint16_t
302 {
303  NS_LOG_FUNCTION (this);
304  // Maximum payload size is: max psdu - frame control - seqno - addressing - security - fcs
305  // = 127 - 2 - 1 - (2+2+2+2) - 0 - 2
306  // = 114
307  // assuming no security and addressing with only 16 bit addresses without pan id compression.
308  return 114;
309 }
310 
311 bool
313 {
314  NS_LOG_FUNCTION (this);
315  return m_phy != 0 && m_linkUp;
316 }
317 
318 void
320 {
321  NS_LOG_FUNCTION (this);
323 }
324 
325 bool
327 {
328  NS_LOG_FUNCTION (this);
329  return true;
330 }
331 
332 Address
334 {
335  NS_LOG_FUNCTION (this);
336 
337  Mac48Address pseudoAddress = BuildPseudoMacAddress (m_mac->GetPanId (), Mac16Address::GetBroadcast ());
338 
339  return pseudoAddress;
340 }
341 
342 bool
344 {
345  NS_LOG_FUNCTION (this);
346  return true;
347 }
348 
349 Address
351 {
352  NS_ABORT_MSG ("Unsupported");
353  return Address ();
354 }
355 
356 Address
358 {
359  NS_LOG_FUNCTION (this << addr);
360 
361  Mac48Address pseudoAddress = BuildPseudoMacAddress (m_mac->GetPanId (), Mac16Address::GetMulticast (addr));
362 
363  return pseudoAddress;
364 }
365 
366 bool
368 {
369  NS_LOG_FUNCTION (this);
370  return false;
371 }
372 
373 bool
375 {
376  NS_LOG_FUNCTION (this);
377  return false;
378 }
379 
380 bool
381 LrWpanNetDevice::Send (Ptr<Packet> packet, const Address& dest, uint16_t protocolNumber)
382 {
383  // This method basically assumes an 802.3-compliant device, but a raw
384  // 802.15.4 device does not have an ethertype, and requires specific
385  // McpsDataRequest parameters.
386  // For further study: how to support these methods somehow, such as
387  // inventing a fake ethertype and packet tag for McpsDataRequest
388  NS_LOG_FUNCTION (this << packet << dest << protocolNumber);
389 
390  if (packet->GetSize () > GetMtu ())
391  {
392  NS_LOG_ERROR ("Fragmentation is needed for this packet, drop the packet ");
393  return false;
394  }
395 
396  McpsDataRequestParams m_mcpsDataRequestParams;
397 
398  Mac16Address dst16;
399  if (Mac48Address::IsMatchingType (dest))
400  {
401  uint8_t buf[6];
402  dest.CopyTo (buf);
403  dst16.CopyFrom (buf+4);
404  }
405  else
406  {
407  dst16 = Mac16Address::ConvertFrom (dest);
408  }
409  m_mcpsDataRequestParams.m_dstAddr = dst16;
410  m_mcpsDataRequestParams.m_dstAddrMode = SHORT_ADDR;
411  m_mcpsDataRequestParams.m_dstPanId = m_mac->GetPanId ();
412  m_mcpsDataRequestParams.m_srcAddrMode = SHORT_ADDR;
413  // Using ACK requests for broadcast destinations is ok here. They are disabled
414  // by the MAC.
415  if (m_useAcks)
416  {
417  m_mcpsDataRequestParams.m_txOptions = TX_OPTION_ACK;
418  }
419  m_mcpsDataRequestParams.m_msduHandle = 0;
420  m_mac->McpsDataRequest (m_mcpsDataRequestParams, packet);
421  return true;
422 }
423 
424 bool
425 LrWpanNetDevice::SendFrom (Ptr<Packet> packet, const Address& source, const Address& dest, uint16_t protocolNumber)
426 {
427  NS_ABORT_MSG ("Unsupported");
428  // TODO: To support SendFrom, the MACs McpsDataRequest has to use the provided source address, instead of to local one.
429  return false;
430 }
431 
432 Ptr<Node>
434 {
435  NS_LOG_FUNCTION (this);
436  return m_node;
437 }
438 
439 void
441 {
442  NS_LOG_FUNCTION (this);
443  m_node = node;
444  CompleteConfig ();
445 }
446 
447 bool
449 {
450  NS_LOG_FUNCTION (this);
451  return true;
452 }
453 
454 void
456 {
457  NS_LOG_FUNCTION (this);
458  m_receiveCallback = cb;
459 }
460 
461 void
463 {
464  // This method basically assumes an 802.3-compliant device, but a raw
465  // 802.15.4 device does not have an ethertype, and requires specific
466  // McpsDataIndication parameters.
467  // For further study: how to support these methods somehow, such as
468  // inventing a fake ethertype and packet tag for McpsDataRequest
469  NS_LOG_WARN ("Unsupported; use LrWpan MAC APIs instead");
470 }
471 
472 void
474 {
475  NS_LOG_FUNCTION (this);
476  // TODO: Use the PromiscReceiveCallback if the MAC is in promiscuous mode.
477  m_receiveCallback (this, pkt, 0, BuildPseudoMacAddress (params.m_srcPanId, params.m_srcAddr));
478 }
479 
480 bool
482 {
484  return false;
485 }
486 
488 LrWpanNetDevice::BuildPseudoMacAddress (uint16_t panId, Mac16Address shortAddr) const
489 {
490  NS_LOG_FUNCTION (this);
491 
492  uint8_t buf[6];
493 
494  buf[0] = panId >> 8;
495  // Make sure the U/L bit is set
496  buf[0] |= 0x02;
497  buf[1] = panId & 0xff;
498  buf[2] = 0;
499  buf[3] = 0;
500  shortAddr.CopyTo (buf+4);
501 
502  Mac48Address pseudoAddress;
503  pseudoAddress.CopyFrom (buf);
504 
505  return pseudoAddress;
506 }
507 
508 int64_t
510 {
511  NS_LOG_FUNCTION (stream);
512  int64_t streamIndex = stream;
513  streamIndex += m_csmaca->AssignStreams (stream);
514  streamIndex += m_phy->AssignStreams (stream);
515  NS_LOG_DEBUG ("Number of assigned RV streams: " << (streamIndex - stream));
516  return (streamIndex - stream);
517 }
518 
519 } // namespace ns3
virtual bool Send(Ptr< Packet > packet, const Address &dest, uint16_t protocolNumber)
static bool IsMatchingType(const Address &address)
uint16_t m_dstPanId
Destination PAN identifier.
Definition: lr-wpan-mac.h:248
virtual uint16_t GetMtu(void) const
virtual void SetNode(Ptr< Node > node)
virtual void DoInitialize(void)
Initialize() implementation.
Definition: object.cc:353
virtual void AddLinkChangeCallback(Callback< void > callback)
#define NS_LOG_FUNCTION(parameters)
If log level LOG_FUNCTION is enabled, this macro will output all input parameters separated by "...
AttributeValue implementation for Boolean.
Definition: boolean.h:36
#define NS_ABORT_MSG(msg)
Unconditional abnormal program termination with a message.
Definition: abort.h:50
#define NS_OBJECT_ENSURE_REGISTERED(type)
Register an Object subclass with the TypeId system.
Definition: object-base.h:45
void PlmeGetAttributeConfirm(LrWpanPhyEnumeration status, LrWpanPibAttributeIdentifier id, LrWpanPhyPibAttributes *attribute)
IEEE 802.15.4-2006 section 6.2.2.6 PLME-GET.confirm Get attributes per definition from Table 23 in se...
uint32_t GetSize(void) const
Returns the the size in bytes of the packet (including the zero-filled initial payload).
Definition: packet.h:852
bool m_useAcks
Configure the NetDevice to request MAC layer acknowledgments when sending packets using the Send() AP...
virtual Address GetBroadcast(void) const
Mac16Address m_dstAddr
Destination address.
Definition: lr-wpan-mac.h:249
static Mac16Address ConvertFrom(const Address &address)
ReceiveCallback m_receiveCallback
Upper layer callback used for notification of new data packet arrivals.
static TypeId GetTypeId(void)
Get the type ID.
TracedCallback m_linkChanges
Trace source for link up/down changes.
virtual uint32_t GetIfIndex(void) const
Ptr< const AttributeAccessor > MakeBooleanAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method...
Definition: boolean.h:85
void PlmeCcaConfirm(LrWpanPhyEnumeration status)
IEEE 802.15.4-2006 section 6.2.2.2 PLME-CCA.confirm status.
virtual bool SupportsSendFrom(void) const
void CopyFrom(const uint8_t buffer[2])
#define NS_LOG_COMPONENT_DEFINE(name)
Define a Log component with a specific name.
Definition: log.h:205
virtual void SetReceiveCallback(NetDevice::ReceiveCallback cb)
virtual bool SendFrom(Ptr< Packet > packet, const Address &source, const Address &dest, uint16_t protocolNumber)
virtual Address GetAddress(void) const
This method indirects to LrWpanMac::SetShortAddress ()
virtual void SetPromiscReceiveCallback(PromiscReceiveCallback cb)
void CopyTo(uint8_t buffer[2]) const
virtual void DoDispose(void)
Destructor implementation.
Definition: object.cc:346
#define NS_LOG_FUNCTION_NOARGS()
Output the name of the function.
virtual void DoDispose(void)
Destructor implementation.
virtual bool IsBridge(void) const
Return true if the net device is acting as a bridge.
Network layer to device interface.
uint8_t m_msduHandle
MSDU handle.
Definition: lr-wpan-mac.h:251
a polymophic address class
Definition: address.h:90
Ptr< LrWpanPhy > GetPhy(void) const
Get the PHY used by this NetDevice.
channel
Definition: third.py:92
mobility
Definition: third.py:108
virtual void SetAddress(Address address)
This method indirects to LrWpanMac::SetShortAddress ()
phy
Definition: third.py:93
virtual Ptr< Channel > GetChannel(void) const
void SetPhy(Ptr< LrWpanPhy > phy)
Set the PHY to be used by the MAC and this NetDevice.
int64_t AssignStreams(int64_t stream)
Assign a fixed random variable stream number to the random variables used by this model...
void SetLrWpanMacState(LrWpanMacState macState)
CSMA-CA algorithm calls back the MAC after executing channel assessment.
Keep track of the current position and velocity of an object.
Ptr< LrWpanMac > m_mac
The MAC for this NetDevice.
void PlmeEdConfirm(LrWpanPhyEnumeration status, uint8_t energyLevel)
IEEE 802.15.4-2006 section 6.2.2.4 PLME-ED.confirm status and energy level.
TX_OPTION_ACK.
Definition: lr-wpan-mac.h:59
void CopyTo(uint8_t buffer[6]) const
virtual void SetIfIndex(const uint32_t index)
void SetChannel(Ptr< SpectrumChannel > channel)
Set the channel to which the NetDevice, and therefore the PHY, should be attached to...
Ptr< LrWpanCsmaCa > m_csmaca
The CSMA/CA implementation for this NetDevice.
Ptr< const AttributeAccessor > MakePointerAccessor(T1 a1)
Create an AttributeAccessor for a class data member, or a lone class get functor or set method...
Definition: pointer.h:227
virtual void DoInitialize(void)
Initialize() implementation.
virtual bool IsMulticast(void) const
mac
Definition: third.py:99
void LinkDown(void)
Mark NetDevice link as down.
void PdDataConfirm(LrWpanPhyEnumeration status)
IEEE 802.15.4-2006 section 6.2.1.2 Confirm the end of transmission of an MPDU to MAC.
uint8_t m_txOptions
Tx Options (bitfield)
Definition: lr-wpan-mac.h:252
void SetMac(Ptr< LrWpanMac > mac)
Set the MAC to be used by this NetDevice.
static Mac48Address ConvertFrom(const Address &address)
void PdDataIndication(uint32_t psduLength, Ptr< Packet > p, uint8_t lqi)
IEEE 802.15.4-2006 section 6.2.1.3 PD-DATA.indication Indicates the transfer of an MPDU from PHY to M...
Definition: lr-wpan-mac.cc:994
Ptr< T > GetObject(void) const
Get a pointer to the requested aggregated Object.
Definition: object.h:470
LrWpanAddressMode m_srcAddrMode
Source address mode.
Definition: lr-wpan-mac.h:246
static Mac16Address GetBroadcast(void)
bool m_linkUp
Is the link/device currently up and running?
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Hold objects of type Ptr<T>.
Definition: pointer.h:36
Mac48Address BuildPseudoMacAddress(uint16_t panId, Mac16Address shortAddr) const
Builds a "pseudo 48-bit address" from the PanId and Short Address The form is PanId : 0x0 : 0x0 : Sho...
address
Definition: first.py:44
LrWpanAddressMode m_dstAddrMode
Destination address mode.
Definition: lr-wpan-mac.h:247
Ptr< LrWpanPhy > m_phy
The PHY for this NetDevice.
void CompleteConfig(void)
Configure PHY, MAC and CSMA/CA.
Ptr< SpectrumChannel > DoGetChannel(void) const
Attribute accessor method for the "Channel" attribute.
an EUI-48 address
Definition: mac48-address.h:43
uint32_t m_ifIndex
The interface index of this NetDevice.
Mac16Address m_srcAddr
Source address.
Definition: lr-wpan-mac.h:274
This class can contain 16 bit addresses.
Definition: mac16-address.h:41
void CopyFrom(const uint8_t buffer[6])
void McpsDataIndication(McpsDataIndicationParams params, Ptr< Packet > pkt)
The callback used by the MAC to hand over incoming packets to the NetDevice.
virtual ~LrWpanNetDevice(void)
Describes an IPv6 address.
Definition: ipv6-address.h:49
Ipv4 addresses are stored in host order in this class.
Definition: ipv4-address.h:41
virtual bool IsPointToPoint(void) const
Return true if the net device is on a point-to-point link.
Network layer to device interface.
Definition: net-device.h:95
#define NS_LOG_WARN(msg)
Use NS_LOG to output a message of level LOG_WARN.
Definition: log.h:265
void LinkUp(void)
Mark NetDevice link as up.
Ptr< LrWpanCsmaCa > GetCsmaCa(void) const
Get the CSMA/CA implementation used by this NetDevice.
#define NS_LOG_DEBUG(msg)
Use NS_LOG to output a message of level LOG_DEBUG.
Definition: log.h:273
Ptr< const AttributeChecker > MakeBooleanChecker(void)
Definition: boolean.cc:121
Ptr< Node > m_node
The node associated with this NetDevice.
virtual Ptr< Node > GetNode(void) const
#define NS_LOG_ERROR(msg)
Use NS_LOG to output a message of level LOG_ERROR.
Definition: log.h:257
void PlmeSetTRXStateConfirm(LrWpanPhyEnumeration status)
IEEE 802.15.4-2006 section 6.2.2.8 PLME-SET-TRX-STATE.confirm Set PHY state.
MCPS-DATA.request params.
Definition: lr-wpan-mac.h:236
virtual bool IsLinkUp(void) const
virtual Address GetMulticast(Ipv4Address multicastGroup) const
Make and return a MAC multicast address using the provided multicast group.
static Mac16Address GetMulticast(Ipv6Address address)
Returns the multicast address associated with an IPv6 address according to RFC 4944 Section 9...
static bool IsMatchingType(const Address &address)
Ptr< LrWpanMac > GetMac(void) const
Get the MAC used by this NetDevice.
bool m_configComplete
True if MAC, PHY and CSMA/CA where successfully configured and the NetDevice is ready for being used...
void SetCsmaCa(Ptr< LrWpanCsmaCa > csmaca)
Set the CSMA/CA implementation to be used by the MAC and this NetDevice.
a unique identifier for an interface.
Definition: type-id.h:58
TypeId SetParent(TypeId tid)
Set the parent TypeId.
Definition: type-id.cc:923
void PlmeSetAttributeConfirm(LrWpanPhyEnumeration status, LrWpanPibAttributeIdentifier id)
IEEE 802.15.4-2006 section 6.2.2.10 PLME-SET.confirm Set attributes per definition from Table 23 in s...
Callback< R, Ts... > MakeCallback(R(T::*memPtr)(Ts...), OBJ objPtr)
Build Callbacks for class method members which take varying numbers of arguments and potentially retu...
Definition: callback.h:1642
virtual bool SetMtu(const uint16_t mtu)
uint16_t m_srcPanId
Source PAN identifier.
Definition: lr-wpan-mac.h:273
virtual bool IsBroadcast(void) const
MCPS-DATA.indication params.
Definition: lr-wpan-mac.h:270
uint32_t CopyTo(uint8_t buffer[MAX_SIZE]) const
Copy the address bytes into a buffer.
Definition: address.cc:82
void ConnectWithoutContext(const CallbackBase &callback)
Append a Callback to the chain (without a context).
virtual bool NeedsArp(void) const