INET Framework for OMNeT++/OMNEST
inet::physicallayer::Ieee802154UWBIRMode Class Reference

#include <Ieee802154UWBIRMode.h>

Public Types

enum  UWBPRF { PRF_OFF, NOMINAL_4_M, NOMINAL_16_M, NOMINAL_64_M }
 
enum  Ranging { NON_RANGING, ALL_RANGING, PHY_HEADER_ONLY }
 
enum  UWBPreambleSymbolRepetitions { PSR_SHORT = 16, PSR_DEFAULT = 64, PSR_MEDIUM = 1024, PSR_LONG = 4096 }
 
enum  DataRate {
  DATA_RATE_0, DATA_RATE_1, DATA_RATE_2, DATA_RATE_3,
  DATA_RATE_4
}
 

Public Member Functions

int s (int n) const
 
int getHoppingPos (int sym) const
 

Public Attributes

int channel
 
UWBPRF prf
 
Ranging ranging
 
UWBPreambleSymbolRepetitions NSync
 
int CLength
 
int spreadingdL
 
int Ncpb
 
bps bitrate
 
int nbPulsesPerBurst
 
double sync_symbol_duration
 
double data_symbol_duration
 
double shift_duration
 
double pulse_duration
 
double burst_duration
 
double preambleLength
 
Hz centerFrequency
 
Hz bandwidth
 

Static Public Attributes

static const double maxPulse = 1
 Total triangular pulse peak energy in mW (0 dBm / 50 MHz over 500 MHz) More...
 
static const double mandatory_pulse = 0.000000002003203125
 
static const short C31 [8][31]
 
static const short Ci = 5
 
static const short shortSFD [8] = { 0, 1, 0, -1, 1, 0, 0, -1 }
 
static const int MaxPSDULength = 128
 Maximum size of message that is accepted by the Phy layer (in bytes). More...
 
static const int maxS = 20000
 
static short s_array [maxS] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 }
 
static int last_s = 15
 
static const Ieee802154UWBIRMode cfg_mandatory_4M
 
static const Ieee802154UWBIRMode cfg_mandatory_16M
 

Member Enumeration Documentation

Enumerator
DATA_RATE_0 
DATA_RATE_1 
DATA_RATE_2 
DATA_RATE_3 
DATA_RATE_4 
68  {
70  };
Definition: Ieee802154UWBIRMode.h:69
Definition: Ieee802154UWBIRMode.h:69
Definition: Ieee802154UWBIRMode.h:69
Definition: Ieee802154UWBIRMode.h:69
Definition: Ieee802154UWBIRMode.h:69
Enumerator
NON_RANGING 
ALL_RANGING 
PHY_HEADER_ONLY 
58  {
60  };
Definition: Ieee802154UWBIRMode.h:59
Definition: Ieee802154UWBIRMode.h:59
Enumerator
PSR_SHORT 
PSR_DEFAULT 
PSR_MEDIUM 
PSR_LONG 
63  {
64  PSR_SHORT = 16, PSR_DEFAULT = 64, PSR_MEDIUM = 1024, PSR_LONG = 4096
65  };
Definition: Ieee802154UWBIRMode.h:64
Definition: Ieee802154UWBIRMode.h:64
Definition: Ieee802154UWBIRMode.h:64
Definition: Ieee802154UWBIRMode.h:64
Enumerator
PRF_OFF 
NOMINAL_4_M 
NOMINAL_16_M 
NOMINAL_64_M 
53  {
55  };
Definition: Ieee802154UWBIRMode.h:54
Definition: Ieee802154UWBIRMode.h:54
Definition: Ieee802154UWBIRMode.h:54
Definition: Ieee802154UWBIRMode.h:54

Member Function Documentation

int inet::physicallayer::Ieee802154UWBIRMode::getHoppingPos ( int  sym) const

Referenced by inet::physicallayer::Ieee802154UWBIRReceiver::decode(), and inet::physicallayer::Ieee802154UWBIRTransmitter::generateIEEE802154AUWBSignal().

110 {
111  //int m = 3; // or 5 with 4M
112  int pos = 0;
113  int kNcpb = sym * Ncpb;
114  switch (prf) {
115  case NOMINAL_4_M:
116  pos = s(kNcpb) + 2 * s(1 + kNcpb) + 4 * s(2 + kNcpb) + 8 * s(3 + kNcpb) + 16 * s(4 + kNcpb);
117  break;
118  case NOMINAL_16_M:
119  pos = s(kNcpb) + 2 * s(1 + kNcpb) + 4 * s(2 + kNcpb);
120  break;
121  case NOMINAL_64_M:
122  pos = s(kNcpb);
123  break;
124  case PRF_OFF:
125  default:
126  ASSERT(0==1); // unimplemented or invalid PRF value
127  break;
128  }
129  // ASSERT(pos > -1 && pos < 8); // TODO: update to reflect number of hopping pos for current config
130  return pos;
131 }
UWBPRF prf
Definition: Ieee802154UWBIRMode.h:73
Definition: Ieee802154UWBIRMode.h:54
Definition: Ieee802154UWBIRMode.h:54
int s(int n) const
Definition: Ieee802154UWBIRMode.cc:98
int Ncpb
Definition: Ieee802154UWBIRMode.h:78
Definition: Ieee802154UWBIRMode.h:54
Definition: Ieee802154UWBIRMode.h:54
int inet::physicallayer::Ieee802154UWBIRMode::s ( int  n) const

Referenced by getHoppingPos().

99 {
100  ASSERT(n < maxS);
101  for (; last_s < n; last_s = last_s + 1) {
102  // compute missing values as necessary
103  s_array[last_s] = (s_array[last_s - 14] + s_array[last_s - 15]) % 2;
104  }
105  ASSERT(s_array[n] == 0 || s_array[n] == 1);
106  return s_array[n];
107 }
static int last_s
Definition: Ieee802154UWBIRMode.h:48
static const int maxS
Definition: Ieee802154UWBIRMode.h:46
static short s_array[maxS]
Definition: Ieee802154UWBIRMode.h:47

Member Data Documentation

bps inet::physicallayer::Ieee802154UWBIRMode::bitrate
const short inet::physicallayer::Ieee802154UWBIRMode::C31
static
Initial value:
= {
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
{ -1, 0, +1, -1, 0, 0, +1, +1, +1, -1, +1, 0, 0, 0, -1, +1, 0, +1, +1, +1, 0, -1, 0, +1, 0, 0, 0, 0, -1, 0, 0 },
{ +1, +1, 0, 0, +1, 0, 0, -1, -1, -1, +1, -1, 0, +1, +1, -1, 0, 0, 0, +1, 0, +1, 0, -1, +1, 0, +1, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 },
{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0 },
}

Referenced by inet::physicallayer::Ieee802154UWBIRTransmitter::generateSFD(), and inet::physicallayer::Ieee802154UWBIRTransmitter::generateSyncPreamble().

const Ieee802154UWBIRMode inet::physicallayer::Ieee802154UWBIRMode::cfg_mandatory_16M
static
Initial value:
= {
3,
31,
16,
16,
bps(850000),
16,
993.6E-9,
1023.64E-9,
512.82E-9,
2.003E-9,
32.05E-9,
71.5E-6,
MHz(4492.8),
MHz(499.2)
}

Referenced by inet::physicallayer::Ieee802154UWBIRReceiver::initialize(), and inet::physicallayer::Ieee802154UWBIRTransmitter::initialize().

const Ieee802154UWBIRMode inet::physicallayer::Ieee802154UWBIRMode::cfg_mandatory_4M
static
Initial value:
= {
3,
31,
64,
4,
bps(850000),
4,
3974.36E-9,
1023.64E-9,
512.82E-9,
2.003E-9,
8.01E-9,
286.2E-6,
MHz(4492.8),
MHz(499.2)
}
int inet::physicallayer::Ieee802154UWBIRMode::channel
const short inet::physicallayer::Ieee802154UWBIRMode::Ci = 5
static
int inet::physicallayer::Ieee802154UWBIRMode::last_s = 15
static

Referenced by s().

const double inet::physicallayer::Ieee802154UWBIRMode::mandatory_pulse = 0.000000002003203125
static
const int inet::physicallayer::Ieee802154UWBIRMode::MaxPSDULength = 128
static

Maximum size of message that is accepted by the Phy layer (in bytes).

Referenced by inet::physicallayer::Ieee802154UWBIRTransmitter::getMaxFrameDuration().

const double inet::physicallayer::Ieee802154UWBIRMode::maxPulse = 1
static
const int inet::physicallayer::Ieee802154UWBIRMode::maxS = 20000
static

Referenced by s().

int inet::physicallayer::Ieee802154UWBIRMode::nbPulsesPerBurst
int inet::physicallayer::Ieee802154UWBIRMode::Ncpb

Referenced by getHoppingPos().

UWBPRF inet::physicallayer::Ieee802154UWBIRMode::prf
Ranging inet::physicallayer::Ieee802154UWBIRMode::ranging
short inet::physicallayer::Ieee802154UWBIRMode::s_array = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 }
static

Referenced by s().

const short inet::physicallayer::Ieee802154UWBIRMode::shortSFD = { 0, 1, 0, -1, 1, 0, 0, -1 }
static
double inet::physicallayer::Ieee802154UWBIRMode::sync_symbol_duration

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