24 #include <ns3/abort.h>
109 int16_t valFp = (int16_t)(val * 8);
117 double valD = ((int16_t)val) / 8.0;
132 0, 10, 12, 14, 17, 19, 22, 26, 31, 36, 42, 49, 57, 67, 78, 91,
133 107, 125, 146, 171, 200, 234, 274, 321, 376, 440, 515, 603,
134 706, 826, 967, 1132, 1326, 1552, 1817, 2127, 2490, 2915, 3413,
135 3995, 4677, 5476, 6411, 7505, 8787, 10287, 12043, 14099, 16507,
136 19325, 22624, 26487, 31009, 36304, 42502, 49759, 58255,
137 68201, 79846, 93749, 109439, 128125, 150000, 150000
205 NS_ASSERT_MSG (range <= 97,
"value " << range <<
" is out of range");
206 return (
double) range - 141.0;
213 double range = std::min( std::max (std::floor(dbm + 141), 0.0), 97.0);
214 return (uint8_t) range;
221 NS_ASSERT_MSG (range <= 34,
"value " << (uint16_t) range <<
" is out of range");
222 return ((
double) range - 40.0)*0.5;
229 double range = std::min (std::max (std::floor (db*2 + 40), 0.0), 34.0);
230 return (uint8_t) range;
static uint16_t double2fpS11dot3(double val)
static double QuantizeRsrp(double v)
#define NS_ASSERT(condition)
#define NS_LOG_COMPONENT_DEFINE(name)
bool operator<(const Room &a, const Room &b)
#define NS_ABORT_MSG_UNLESS(cond, msg)
Abnormal program termination if cond is false.
static double RsrqRange2Db(uint8_t range)
static uint8_t BufferSize2BsrId(uint32_t val)
static double getMinFpS11dot3Value()
static uint8_t TxMode2LayerNum(uint8_t txMode)
static double QuantizeRsrq(double v)
#define NS_ASSERT_MSG(condition, message)
static double fpS11dot3toDouble(uint16_t val)
Parameters for configuring the UE.
static uint8_t Dbm2RsrpRange(double dbm)
static uint32_t BsrId2BufferSize(uint8_t val)
bool operator==(const EventId &a, const EventId &b)
static uint8_t Db2RsrqRange(double db)
uint32_t BufferSizeLevelBsrTable[64]
static double RsrpRange2Dbm(uint8_t range)