LEFT | RIGHT |
(no file at all) | |
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) 2010 TELEMATICS LAB, DEE - Politecnico di Bari | 3 * Copyright (c) 2010 TELEMATICS LAB, DEE - Politecnico di Bari |
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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 | 48 |
49 | 49 |
50 | 50 |
51 /** | 51 /** |
52 * Duration of the data portion of a UL subframe. | 52 * Duration of the data portion of a UL subframe. |
53 * Equals to "TTI length - 1 symbol length for SRS - margin". | 53 * Equals to "TTI length - 1 symbol length for SRS - margin". |
54 * The margin is 1 nanosecond and is intended to avoid overlapping simulator | 54 * The margin is 1 nanosecond and is intended to avoid overlapping simulator |
55 * events. The duration of one symbol is TTI/14 (rounded). In other words, | 55 * events. The duration of one symbol is TTI/14 (rounded). In other words, |
56 * duration of data portion of UL subframe = 1 ms * (13/14) - 1 ns. | 56 * duration of data portion of UL subframe = 1 ms * (13/14) - 1 ns. |
57 */ | 57 */ |
58 static const Time UL_DATA_DURATION = NanoSeconds (1e6 - 71429 - 1); | 58 static const Time UL_DATA_DURATION = NanoSeconds (1000000 - 71429 - 1); |
59 | 59 |
60 /** | 60 /** |
61 * Delay from subframe start to transmission of SRS. | 61 * Delay from subframe start to transmission of SRS. |
62 * Equals to "TTI length - 1 symbol for SRS". | 62 * Equals to "TTI length - 1 symbol for SRS". |
63 */ | 63 */ |
64 static const Time UL_SRS_DELAY_FROM_SUBFRAME_START = NanoSeconds (1e6 - 71429);· | 64 static const Time UL_SRS_DELAY_FROM_SUBFRAME_START = NanoSeconds (1000000 - 7142
9);· |
65 | 65 |
66 | 66 |
67 | 67 |
68 | 68 |
69 //////////////////////////////////////// | 69 //////////////////////////////////////// |
70 // member SAP forwarders | 70 // member SAP forwarders |
71 //////////////////////////////////////// | 71 //////////////////////////////////////// |
72 | 72 |
73 /// UeMemberLteUePhySapProvider class | 73 /// UeMemberLteUePhySapProvider class |
74 class UeMemberLteUePhySapProvider : public LteUePhySapProvider | 74 class UeMemberLteUePhySapProvider : public LteUePhySapProvider |
(...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
461 NS_LOG_FUNCTION (this); | 461 NS_LOG_FUNCTION (this); |
462 return m_subChannelsForReception; | 462 return m_subChannelsForReception; |
463 } | 463 } |
464 | 464 |
465 | 465 |
466 Ptr<SpectrumValue> | 466 Ptr<SpectrumValue> |
467 LteUePhy::CreateTxPowerSpectralDensity () | 467 LteUePhy::CreateTxPowerSpectralDensity () |
468 { | 468 { |
469 NS_LOG_FUNCTION (this); | 469 NS_LOG_FUNCTION (this); |
470 LteSpectrumValueHelper psdHelper; | 470 LteSpectrumValueHelper psdHelper; |
| 471 //cast found to void, to suppress 'psdHelper' set but not used |
| 472 //compiler warning |
| 473 (void)psdHelper; |
471 Ptr<SpectrumValue> psd = psdHelper.CreateTxPowerSpectralDensity (m_ulEarfcn, m
_ulBandwidth, m_txPower, GetSubChannelsForTransmission ()); | 474 Ptr<SpectrumValue> psd = psdHelper.CreateTxPowerSpectralDensity (m_ulEarfcn, m
_ulBandwidth, m_txPower, GetSubChannelsForTransmission ()); |
472 | 475 |
473 return psd; | 476 return psd; |
474 } | 477 } |
475 | 478 |
476 void | 479 void |
477 LteUePhy::GenerateCtrlCqiReport (const SpectrumValue& sinr) | 480 LteUePhy::GenerateCtrlCqiReport (const SpectrumValue& sinr) |
478 { | 481 { |
479 NS_LOG_FUNCTION (this); | 482 NS_LOG_FUNCTION (this); |
480 ·· | 483 ·· |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
601 m_pssList.clear (); | 604 m_pssList.clear (); |
602 | 605 |
603 } // end of if (m_pssReceived) | 606 } // end of if (m_pssReceived) |
604 | 607 |
605 } // end of void LteUePhy::GenerateCtrlCqiReport (const SpectrumValue& sinr) | 608 } // end of void LteUePhy::GenerateCtrlCqiReport (const SpectrumValue& sinr) |
606 | 609 |
607 void | 610 void |
608 LteUePhy::GenerateDataCqiReport (const SpectrumValue& sinr) | 611 LteUePhy::GenerateDataCqiReport (const SpectrumValue& sinr) |
609 { | 612 { |
610 // Not used by UE, CQI are based only on RS | 613 // Not used by UE, CQI are based only on RS |
| 614 NS_UNUSED (sinr); |
611 } | 615 } |
612 | 616 |
613 void | 617 void |
614 LteUePhy::GenerateMixedCqiReport (const SpectrumValue& sinr) | 618 LteUePhy::GenerateMixedCqiReport (const SpectrumValue& sinr) |
615 { | 619 { |
616 NS_LOG_FUNCTION (this); | 620 NS_LOG_FUNCTION (this); |
| 621 NS_UNUSED (sinr); |
617 | 622 |
618 NS_ASSERT (m_state != CELL_SEARCH); | 623 NS_ASSERT (m_state != CELL_SEARCH); |
619 NS_ASSERT (m_cellId > 0); | 624 NS_ASSERT (m_cellId > 0); |
620 | 625 |
621 SpectrumValue mixedSinr = (m_rsReceivedPower * m_paLinear); | 626 SpectrumValue mixedSinr = (m_rsReceivedPower * m_paLinear); |
622 if (m_dataInterferencePowerUpdated) | 627 if (m_dataInterferencePowerUpdated) |
623 { | 628 { |
624 // we have a measurement of interf + noise for the denominator | 629 // we have a measurement of interf + noise for the denominator |
625 // of SINR = S/(I+N) | 630 // of SINR = S/(I+N) |
626 mixedSinr /= m_dataInterferencePower; | 631 mixedSinr /= m_dataInterferencePower; |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
713 | 718 |
714 // CREATE DlCqiLteControlMessage | 719 // CREATE DlCqiLteControlMessage |
715 Ptr<DlCqiLteControlMessage> msg = Create<DlCqiLteControlMessage> (); | 720 Ptr<DlCqiLteControlMessage> msg = Create<DlCqiLteControlMessage> (); |
716 CqiListElement_s dlcqi; | 721 CqiListElement_s dlcqi; |
717 std::vector<int> cqi; | 722 std::vector<int> cqi; |
718 if (Simulator::Now () > m_p10CqiLast + m_p10CqiPeriodicity) | 723 if (Simulator::Now () > m_p10CqiLast + m_p10CqiPeriodicity) |
719 { | 724 { |
720 cqi = m_amc->CreateCqiFeedbacks (newSinr, m_dlBandwidth); | 725 cqi = m_amc->CreateCqiFeedbacks (newSinr, m_dlBandwidth); |
721 | 726 |
722 int nLayer = TransmissionModesLayers::TxMode2LayerNum (m_transmissionMode)
; | 727 int nLayer = TransmissionModesLayers::TxMode2LayerNum (m_transmissionMode)
; |
723 int nbSubChannels = cqi.size (); | 728 int nbSubChannels = static_cast<int> (cqi.size ()); |
724 double cqiSum = 0.0; | 729 double cqiSum = 0.0; |
725 int activeSubChannels = 0; | 730 int activeSubChannels = 0; |
726 // average the CQIs of the different RBs | 731 // average the CQIs of the different RBs |
727 for (int i = 0; i < nbSubChannels; i++) | 732 for (int i = 0; i < nbSubChannels; i++) |
728 { | 733 { |
729 if (cqi.at (i) != -1) | 734 if (cqi.at (i) != -1) |
730 { | 735 { |
731 cqiSum += cqi.at (i); | 736 cqiSum += cqi.at (i); |
732 activeSubChannels++; | 737 activeSubChannels++; |
733 } | 738 } |
734 NS_LOG_DEBUG (this << " subch " << i << " cqi " << cqi.at (i)); | 739 NS_LOG_DEBUG (this << " subch " << i << " cqi " << cqi.at (i)); |
735 } | 740 } |
736 dlcqi.m_rnti = m_rnti; | 741 dlcqi.m_rnti = m_rnti; |
737 dlcqi.m_ri = 1; // not yet used | 742 dlcqi.m_ri = 1; // not yet used |
738 dlcqi.m_cqiType = CqiListElement_s::P10; // Peridic CQI using PUCCH wideba
nd | 743 dlcqi.m_cqiType = CqiListElement_s::P10; // Peridic CQI using PUCCH wideba
nd |
739 NS_ASSERT_MSG (nLayer > 0, " nLayer negative"); | 744 NS_ASSERT_MSG (nLayer > 0, " nLayer negative"); |
740 NS_ASSERT_MSG (nLayer < 3, " nLayer limit is 2s"); | 745 NS_ASSERT_MSG (nLayer < 3, " nLayer limit is 2s"); |
741 for (int i = 0; i < nLayer; i++) | 746 for (int i = 0; i < nLayer; i++) |
742 { | 747 { |
743 if (activeSubChannels > 0) | 748 if (activeSubChannels > 0) |
744 { | 749 { |
745 dlcqi.m_wbCqi.push_back ((uint16_t) cqiSum / activeSubChannels); | 750 dlcqi.m_wbCqi.push_back ((uint8_t) (cqiSum / activeSubChannels)); |
746 } | 751 } |
747 else | 752 else |
748 { | 753 { |
749 // approximate with the worst case -> CQI = 1 | 754 // approximate with the worst case -> CQI = 1 |
750 dlcqi.m_wbCqi.push_back (1); | 755 dlcqi.m_wbCqi.push_back (1); |
751 } | 756 } |
752 } | 757 } |
753 //NS_LOG_DEBUG (this << " Generate P10 CQI feedback " << (uint16_t) cqiSum
/ activeSubChannels); | 758 //NS_LOG_DEBUG (this << " Generate P10 CQI feedback " << (uint16_t) cqiSum
/ activeSubChannels); |
754 dlcqi.m_wbPmi = 0; // not yet used | 759 dlcqi.m_wbPmi = 0; // not yet used |
755 // dl.cqi.m_sbMeasResult others CQI report modes: not yet implemented | 760 // dl.cqi.m_sbMeasResult others CQI report modes: not yet implemented |
756 } | 761 } |
757 else if (Simulator::Now () > m_a30CqiLast + m_a30CqiPeriodicity) | 762 else if (Simulator::Now () > m_a30CqiLast + m_a30CqiPeriodicity) |
758 { | 763 { |
759 cqi = m_amc->CreateCqiFeedbacks (newSinr, GetRbgSize ()); | 764 cqi = m_amc->CreateCqiFeedbacks (newSinr, GetRbgSize ()); |
760 int nLayer = TransmissionModesLayers::TxMode2LayerNum (m_transmissionMode)
; | 765 int nLayer = TransmissionModesLayers::TxMode2LayerNum (m_transmissionMode)
; |
761 int nbSubChannels = cqi.size (); | 766 int nbSubChannels = static_cast<int> (cqi.size ()); |
762 int rbgSize = GetRbgSize (); | 767 int rbgSize = GetRbgSize (); |
763 double cqiSum = 0.0; | 768 double cqiSum = 0.0; |
764 int cqiNum = 0; | 769 int cqiNum = 0; |
765 SbMeasResult_s rbgMeas; | 770 SbMeasResult_s rbgMeas; |
766 //NS_LOG_DEBUG (this << " Create A30 CQI feedback, RBG " << rbgSize << " c
qiNum " << nbSubChannels << " band " << (uint16_t)m_dlBandwidth); | 771 //NS_LOG_DEBUG (this << " Create A30 CQI feedback, RBG " << rbgSize << " c
qiNum " << nbSubChannels << " band " << (uint16_t)m_dlBandwidth); |
767 for (int i = 0; i < nbSubChannels; i++) | 772 for (int i = 0; i < nbSubChannels; i++) |
768 { | 773 { |
769 if (cqi.at (i) != -1) | 774 if (cqi.at (i) != -1) |
770 { | 775 { |
771 cqiSum += cqi.at (i); | 776 cqiSum += cqi.at (i); |
772 } | 777 } |
773 // else "nothing" no CQI is treated as CQI = 0 (worst case scenario) | 778 // else "nothing" no CQI is treated as CQI = 0 (worst case scenario) |
774 cqiNum++; | 779 cqiNum++; |
775 if (cqiNum == rbgSize) | 780 if (cqiNum == rbgSize) |
776 { | 781 { |
777 // average the CQIs of the different RBGs | 782 // average the CQIs of the different RBGs |
778 //NS_LOG_DEBUG (this << " RBG CQI " << (uint16_t) cqiSum / rbgSiz
e); | 783 //NS_LOG_DEBUG (this << " RBG CQI " << (uint16_t) cqiSum / rbgSiz
e); |
779 HigherLayerSelected_s hlCqi; | 784 HigherLayerSelected_s hlCqi; |
780 hlCqi.m_sbPmi = 0; // not yet used | 785 hlCqi.m_sbPmi = 0; // not yet used |
781 for (int i = 0; i < nLayer; i++) | 786 for (int j = 0; j < nLayer; j++) |
782 { | 787 { |
783 hlCqi.m_sbCqi.push_back ((uint16_t) cqiSum / rbgSize); | 788 hlCqi.m_sbCqi.push_back ((uint8_t) (cqiSum / rbgSize)); |
784 } | 789 } |
785 rbgMeas.m_higherLayerSelected.push_back (hlCqi); | 790 rbgMeas.m_higherLayerSelected.push_back (hlCqi); |
786 cqiSum = 0.0; | 791 cqiSum = 0.0; |
787 cqiNum = 0; | 792 cqiNum = 0; |
788 } | 793 } |
789 } | 794 } |
790 dlcqi.m_rnti = m_rnti; | 795 dlcqi.m_rnti = m_rnti; |
791 dlcqi.m_ri = 1; // not yet used | 796 dlcqi.m_ri = 1; // not yet used |
792 dlcqi.m_cqiType = CqiListElement_s::A30; // Aperidic CQI using PUSCH | 797 dlcqi.m_cqiType = CqiListElement_s::A30; // Aperidic CQI using PUSCH |
793 //dlcqi.m_wbCqi.push_back ((uint16_t) cqiSum / nbSubChannels); | 798 //dlcqi.m_wbCqi.push_back ((uint16_t) cqiSum / nbSubChannels); |
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
947 HarqProcessInfoList_t harqInfoList = m_harqPhyModule->GetHarqProcessIn
foUl (m_rnti, 0); | 952 HarqProcessInfoList_t harqInfoList = m_harqPhyModule->GetHarqProcessIn
foUl (m_rnti, 0); |
948 PhyTransmissionStatParameters params; | 953 PhyTransmissionStatParameters params; |
949 params.m_cellId = m_cellId; | 954 params.m_cellId = m_cellId; |
950 params.m_imsi = 0; // it will be set by DlPhyTransmissionCallback in L
teHelper | 955 params.m_imsi = 0; // it will be set by DlPhyTransmissionCallback in L
teHelper |
951 params.m_timestamp = Simulator::Now ().GetMilliSeconds () + UL_PUSCH_T
TIS_DELAY; | 956 params.m_timestamp = Simulator::Now ().GetMilliSeconds () + UL_PUSCH_T
TIS_DELAY; |
952 params.m_rnti = m_rnti; | 957 params.m_rnti = m_rnti; |
953 params.m_txMode = 0; // always SISO for UE | 958 params.m_txMode = 0; // always SISO for UE |
954 params.m_layer = 0; | 959 params.m_layer = 0; |
955 params.m_mcs = dci.m_mcs; | 960 params.m_mcs = dci.m_mcs; |
956 params.m_size = dci.m_tbSize; | 961 params.m_size = dci.m_tbSize; |
957 params.m_rv = harqInfoList.size (); | 962 params.m_rv = static_cast<uint8_t> (harqInfoList.size ()); |
958 params.m_ndi = dci.m_ndi; | 963 params.m_ndi = dci.m_ndi; |
959 params.m_ccId = m_componentCarrierId; | 964 params.m_ccId = m_componentCarrierId; |
960 m_ulPhyTransmission (params); | 965 m_ulPhyTransmission (params); |
961 // pass the info to the MAC | 966 // pass the info to the MAC |
962 m_uePhySapUser->ReceiveLteControlMessage (msg); | 967 m_uePhySapUser->ReceiveLteControlMessage (msg); |
963 } | 968 } |
964 else if (msg->GetMessageType () == LteControlMessage::RAR) | 969 else if (msg->GetMessageType () == LteControlMessage::RAR) |
965 { | 970 { |
966 Ptr<RarLteControlMessage> rarMsg = DynamicCast<RarLteControlMessage> (
msg); | 971 Ptr<RarLteControlMessage> rarMsg = DynamicCast<RarLteControlMessage> (
msg); |
967 if (rarMsg->GetRaRnti () == m_raRnti) | 972 if (rarMsg->GetRaRnti () == m_raRnti) |
968 { | 973 { |
969 for (std::list<RarLteControlMessage::Rar>::const_iterator it = rar
Msg->RarListBegin (); it != rarMsg->RarListEnd (); ++it) | 974 for (std::list<RarLteControlMessage::Rar>::const_iterator rit = ra
rMsg->RarListBegin (); rit != rarMsg->RarListEnd (); ++rit) |
970 { | 975 { |
971 if (it->rapId != m_raPreambleId) | 976 if (rit->rapId != m_raPreambleId) |
972 { | 977 { |
973 // UL grant not for me | 978 // UL grant not for me |
974 continue; | 979 continue; |
975 } | 980 } |
976 else | 981 else |
977 { | 982 { |
978 NS_LOG_INFO ("received RAR RNTI " << m_raRnti); | 983 NS_LOG_INFO ("received RAR RNTI " << m_raRnti); |
979 // set the uplink bandwidht according to the UL grant | 984 // set the uplink bandwidht according to the UL grant |
980 std::vector <int> ulRb; | 985 std::vector <int> ulRb; |
981 for (int i = 0; i < it->rarPayload.m_grant.m_rbLen; i++) | 986 for (int i = 0; i < rit->rarPayload.m_grant.m_rbLen; i++) |
982 { | 987 { |
983 ulRb.push_back (i + it->rarPayload.m_grant.m_rbStart); | 988 ulRb.push_back (i + rit->rarPayload.m_grant.m_rbStart)
; |
984 } | 989 } |
985 | 990 |
986 QueueSubChannelsForTransmission (ulRb); | 991 QueueSubChannelsForTransmission (ulRb); |
987 // pass the info to the MAC | 992 // pass the info to the MAC |
988 m_uePhySapUser->ReceiveLteControlMessage (msg); | 993 m_uePhySapUser->ReceiveLteControlMessage (msg); |
989 // reset RACH variables with out of range values | 994 // reset RACH variables with out of range values |
990 m_raPreambleId = 255; | 995 m_raPreambleId = 255; |
991 m_raRnti = 11; | 996 m_raRnti = 11; |
992 } | 997 } |
993 } | 998 } |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1151 else | 1156 else |
1152 { | 1157 { |
1153 NS_LOG_LOGIC (this << " UE - UL NOTHING TO SEND"); | 1158 NS_LOG_LOGIC (this << " UE - UL NOTHING TO SEND"); |
1154 } | 1159 } |
1155 } | 1160 } |
1156 } // m_configured | 1161 } // m_configured |
1157 | 1162 |
1158 // trigger the MAC | 1163 // trigger the MAC |
1159 m_uePhySapUser->SubframeIndication (frameNo, subframeNo); | 1164 m_uePhySapUser->SubframeIndication (frameNo, subframeNo); |
1160 | 1165 |
1161 m_subframeNo = subframeNo; | 1166 m_subframeNo = static_cast<uint8_t> (subframeNo); |
1162 ++subframeNo; | 1167 ++subframeNo; |
1163 if (subframeNo > 10) | 1168 if (subframeNo > 10) |
1164 { | 1169 { |
1165 ++frameNo; | 1170 ++frameNo; |
1166 subframeNo = 1; | 1171 subframeNo = 1; |
1167 } | 1172 } |
1168 | 1173 |
1169 // schedule next subframe indication | 1174 // schedule next subframe indication |
1170 Simulator::Schedule (Seconds (GetTti ()), &LteUePhy::SubframeIndication, this,
frameNo, subframeNo); | 1175 Simulator::Schedule (Seconds (GetTti ()), &LteUePhy::SubframeIndication, this,
frameNo, subframeNo); |
1171 } | 1176 } |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1267 m_dlConfigured = false; | 1272 m_dlConfigured = false; |
1268 m_ulConfigured = false; | 1273 m_ulConfigured = false; |
1269 | 1274 |
1270 SwitchToState (SYNCHRONIZED); | 1275 SwitchToState (SYNCHRONIZED); |
1271 } | 1276 } |
1272 | 1277 |
1273 void | 1278 void |
1274 LteUePhy::DoSetDlBandwidth (uint8_t dlBandwidth) | 1279 LteUePhy::DoSetDlBandwidth (uint8_t dlBandwidth) |
1275 { | 1280 { |
1276 NS_LOG_FUNCTION (this << (uint32_t) dlBandwidth); | 1281 NS_LOG_FUNCTION (this << (uint32_t) dlBandwidth); |
1277 if (m_dlBandwidth != dlBandwidth or !m_dlConfigured) | 1282 if (m_dlBandwidth != dlBandwidth || !m_dlConfigured) |
1278 { | 1283 { |
1279 m_dlBandwidth = dlBandwidth; | 1284 m_dlBandwidth = dlBandwidth; |
1280 | 1285 |
1281 static const int Type0AllocationRbg[4] = { | 1286 static const int Type0AllocationRbg[4] = { |
1282 10, // RGB size 1 | 1287 10, // RGB size 1 |
1283 26, // RGB size 2 | 1288 26, // RGB size 2 |
1284 63, // RGB size 3 | 1289 63, // RGB size 3 |
1285 110 // RGB size 4 | 1290 110 // RGB size 4 |
1286 }; // see table 7.1.6.1-1 of 36.213 | 1291 }; // see table 7.1.6.1-1 of 36.213 |
1287 for (int i = 0; i < 4; i++) | 1292 for (uint8_t i = 0; i < 4; i++) |
1288 { | 1293 { |
1289 if (dlBandwidth < Type0AllocationRbg[i]) | 1294 if (dlBandwidth < Type0AllocationRbg[i]) |
1290 { | 1295 { |
1291 m_rbgSize = i + 1; | 1296 m_rbgSize = i + 1; |
1292 break; | 1297 break; |
1293 } | 1298 } |
1294 } | 1299 } |
1295 | 1300 |
1296 m_noisePsd = LteSpectrumValueHelper::CreateNoisePowerSpectralDensity (m_dl
Earfcn, m_dlBandwidth, m_noiseFigure); | 1301 m_noisePsd = LteSpectrumValueHelper::CreateNoisePowerSpectralDensity (m_dl
Earfcn, m_dlBandwidth, m_noiseFigure); |
1297 m_downlinkSpectrumPhy->SetNoisePowerSpectralDensity (m_noisePsd); | 1302 m_downlinkSpectrumPhy->SetNoisePowerSpectralDensity (m_noisePsd); |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1345 // a guard time is needed for the case where the SRS periodicity is changed dy
namically at run time | 1350 // a guard time is needed for the case where the SRS periodicity is changed dy
namically at run time |
1346 // if we use a static one, we can have a 0ms guard time | 1351 // if we use a static one, we can have a 0ms guard time |
1347 m_srsStartTime = Simulator::Now () + MilliSeconds (0); | 1352 m_srsStartTime = Simulator::Now () + MilliSeconds (0); |
1348 NS_LOG_DEBUG (this << " UE SRS P " << m_srsPeriodicity << " RNTI " << m_rnti <
< " offset " << m_srsSubframeOffset << " cellId " << m_cellId << " CI " << srcCi
); | 1353 NS_LOG_DEBUG (this << " UE SRS P " << m_srsPeriodicity << " RNTI " << m_rnti <
< " offset " << m_srsSubframeOffset << " cellId " << m_cellId << " CI " << srcCi
); |
1349 } | 1354 } |
1350 | 1355 |
1351 void | 1356 void |
1352 LteUePhy::DoSetPa (double pa) | 1357 LteUePhy::DoSetPa (double pa) |
1353 { | 1358 { |
1354 NS_LOG_FUNCTION (this << pa); | 1359 NS_LOG_FUNCTION (this << pa); |
1355 m_paLinear = pow (10,(pa/10)); | 1360 m_paLinear = static_cast<double> (pow (10,(pa/10))); |
1356 } | 1361 } |
1357 | 1362 |
1358 void· | 1363 void· |
1359 LteUePhy::SetTxMode1Gain (double gain) | 1364 LteUePhy::SetTxMode1Gain (double gain) |
1360 { | 1365 { |
1361 SetTxModeGain (1, gain); | 1366 SetTxModeGain (1, gain); |
1362 } | 1367 } |
1363 | 1368 |
1364 void· | 1369 void· |
1365 LteUePhy::SetTxMode2Gain (double gain) | 1370 LteUePhy::SetTxMode2Gain (double gain) |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1460 State oldState = m_state; | 1465 State oldState = m_state; |
1461 m_state = newState; | 1466 m_state = newState; |
1462 NS_LOG_INFO (this << " cellId=" << m_cellId << " rnti=" << m_rnti | 1467 NS_LOG_INFO (this << " cellId=" << m_cellId << " rnti=" << m_rnti |
1463 << " UePhy " << ToString (oldState) | 1468 << " UePhy " << ToString (oldState) |
1464 << " --> " << ToString (newState)); | 1469 << " --> " << ToString (newState)); |
1465 m_stateTransitionTrace (m_cellId, m_rnti, oldState, newState); | 1470 m_stateTransitionTrace (m_cellId, m_rnti, oldState, newState); |
1466 } | 1471 } |
1467 | 1472 |
1468 | 1473 |
1469 } // namespace ns3 | 1474 } // namespace ns3 |
LEFT | RIGHT |