LEFT | RIGHT |
1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ | 1 /* -*- Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */ |
2 /* | 2 /* |
3 * Copyright (c) 2011,2012 Centre Tecnologic de Telecomunicacions de Catalunya (
CTTC) | 3 * Copyright (c) 2011,2012 Centre Tecnologic de Telecomunicacions de Catalunya (
CTTC) |
4 * | 4 * |
5 * This program is free software; you can redistribute it and/or modify | 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 | 6 * it under the terms of the GNU General Public License version 2 as |
7 * published by the Free Software Foundation; | 7 * published by the Free Software Foundation; |
8 * | 8 * |
9 * This program is distributed in the hope that it will be useful, | 9 * This program is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 · | 71 · |
72 | 72 |
73 void | 73 void |
74 DownlinkLteGlobalPathlossDatabase::UpdatePathloss (std::string context,· | 74 DownlinkLteGlobalPathlossDatabase::UpdatePathloss (std::string context,· |
75 Ptr<SpectrumPhy> txPhy,· | 75 Ptr<SpectrumPhy> txPhy,· |
76 Ptr<SpectrumPhy> rxPhy,· | 76 Ptr<SpectrumPhy> rxPhy,· |
77 double lossDb) | 77 double lossDb) |
78 { | 78 { |
79 NS_LOG_FUNCTION (this << lossDb); | 79 NS_LOG_FUNCTION (this << lossDb); |
80 uint16_t cellId = txPhy->GetDevice ()->GetObject<LteEnbNetDevice> ()->GetCellI
d (); | 80 uint16_t cellId = txPhy->GetDevice ()->GetObject<LteEnbNetDevice> ()->GetCellI
d (); |
81 uint16_t imsi = static_cast<uint16_t>(rxPhy->GetDevice ()->GetObject<LteUeNetD
evice> ()->GetImsi ()); | 81 uint64_t imsi = rxPhy->GetDevice ()->GetObject<LteUeNetDevice> ()->GetImsi (); |
82 m_pathlossMap[cellId][imsi] = lossDb; | 82 m_pathlossMap[cellId][imsi] = lossDb; |
83 } | 83 } |
84 | 84 |
85 | 85 |
86 void | 86 void |
87 UplinkLteGlobalPathlossDatabase::UpdatePathloss (std::string context,· | 87 UplinkLteGlobalPathlossDatabase::UpdatePathloss (std::string context,· |
88 Ptr<SpectrumPhy> txPhy,· | 88 Ptr<SpectrumPhy> txPhy,· |
89 Ptr<SpectrumPhy> rxPhy,· | 89 Ptr<SpectrumPhy> rxPhy,· |
90 double lossDb) | 90 double lossDb) |
91 { | 91 { |
92 NS_LOG_FUNCTION (this << lossDb); | 92 NS_LOG_FUNCTION (this << lossDb); |
93 uint16_t imsi = static_cast<uint16_t>(txPhy->GetDevice ()->GetObject<LteUeNetD
evice> ()->GetImsi ()); | 93 uint64_t imsi = txPhy->GetDevice ()->GetObject<LteUeNetDevice> ()->GetImsi (); |
94 uint16_t cellId = rxPhy->GetDevice ()->GetObject<LteEnbNetDevice> ()->GetCellI
d (); | 94 uint16_t cellId = rxPhy->GetDevice ()->GetObject<LteEnbNetDevice> ()->GetCellI
d (); |
95 m_pathlossMap[cellId][imsi] = lossDb; | 95 m_pathlossMap[cellId][imsi] = lossDb; |
96 } | 96 } |
97 | 97 |
98 | 98 |
99 | 99 |
100 } // namespace ns3 | 100 } // namespace ns3 |
LEFT | RIGHT |