Public Member Functions | Protected Attributes

MacToNetwControlInfo Class Reference
[baseUtils - utilities for base MiXiMmacLayer - MAC layer modulesnetwLayer - network layer modules]

Stores control information from mac to upper layer. More...

#include <MacToNetwControlInfo.h>

List of all members.

Public Member Functions

 MacToNetwControlInfo (long lastHop, double ber=0, double rssi=0)
 Initializes with the passed last hop address and bit error rate.
double getBitErrorRate () const
 Returns the bit error rate for this packet.
virtual void setBitErrorRate (double ber)
 Sets the bit error rate for this control infos packet.
long getLastHopMac () const
 Returns the MAC address of the packets last hop.
virtual void setLastHopMac (long lastHop)
 Sets the MAC address of the packets last hop.
virtual const double getRSSI ()
 Returns the packets received signal strength.
void setRSSI (double _rssi)
 Sets the packets received signal strength.

Protected Attributes

double bitErrorRate
 The bit error rate for this packet.
long lastHopMac
 MAC address of the last hop of this packet.
double rssi
 The received signal strength for this packet.

Detailed Description

Stores control information from mac to upper layer.

Holds the bit error rate of the transmission as well as the MAC address of the last hop.

Author:
Karl Wessel

Definition at line 33 of file MacToNetwControlInfo.h.


Member Function Documentation

virtual const double MacToNetwControlInfo::getRSSI (  )  [inline, virtual]

Returns the packets received signal strength.

Returns:
The received signal strength

Definition at line 94 of file MacToNetwControlInfo.h.

References rssi.

                                 {
    return rssi;
  }

virtual void MacToNetwControlInfo::setBitErrorRate ( double  ber  )  [inline, virtual]

Sets the bit error rate for this control infos packet.

Parameters:
ber The bit error rate

Definition at line 69 of file MacToNetwControlInfo.h.

References bitErrorRate.

Referenced by CSMA802154::decapsMsg().

                                           {
    bitErrorRate = ber;
  }

virtual void MacToNetwControlInfo::setLastHopMac ( long  lastHop  )  [inline, virtual]

Sets the MAC address of the packets last hop.

Parameters:
lastHop The last hops MAC address

Definition at line 85 of file MacToNetwControlInfo.h.

References lastHopMac.

                                           {
    lastHopMac = lastHop;
  }

void MacToNetwControlInfo::setRSSI ( double  _rssi  )  [inline]

Sets the packets received signal strength.

Parameters:
_rssi The received signal strength

Definition at line 102 of file MacToNetwControlInfo.h.

References rssi.

Referenced by CSMA802154::decapsMsg().

                             {
    rssi = _rssi;
  }


The documentation for this class was generated from the following file: