Merge remote-tracking branch 'origin/develop-nr' into nr_prach
Conflicts: cmake_targets/CMakeLists.txt cmake_targets/build_oai executables/nr-ru.c executables/nr-softmodem.c nfapi/open-nFAPI/nfapi/public_inc/nfapi_nr_interface.h openair1/PHY/INIT/nr_init.c openair1/PHY/NR_UE_ESTIMATION/nr_ue_measurements.c openair1/PHY/NR_UE_TRANSPORT/nr_dlsch_decoding.c openair1/PHY/NR_UE_TRANSPORT/nr_transport_proto_ue.h openair1/PHY/TOOLS/Makefile openair1/PHY/TOOLS/lte_dfts.c openair1/PHY/TOOLS/nr_phy_scope.c openair1/SCHED_NR/phy_procedures_nr_common.c openair1/SCHED_NR/phy_procedures_nr_gNB.c openair1/SCHED_NR_UE/phy_procedures_nr_ue.c openair1/SIMULATION/NR_PHY/dlschsim.c openair1/SIMULATION/NR_PHY/dlsim.c openair1/SIMULATION/NR_PHY/pbchsim.c openair1/SIMULATION/NR_PHY/pucchsim.c openair1/SIMULATION/NR_PHY/ulschsim.c openair1/SIMULATION/NR_PHY/ulsim.c openair2/COMMON/rrc_messages_types.h openair2/GNB_APP/RRC_nr_paramsvalues.h openair2/GNB_APP/gnb_config.c openair2/GNB_APP/gnb_paramdef.h openair2/LAYER2/NR_MAC_gNB/config.c openair2/LAYER2/NR_MAC_gNB/mac_proto.h openair2/NR_PHY_INTERFACE/NR_IF_Module.c openair2/RRC/NR/MESSAGES/asn1_msg.c openair2/RRC/NR/MESSAGES/asn1_msg.h
This commit is contained in:
@@ -50,7 +50,7 @@ int NRRIV2PRBOFFSET(int locationAndBandwidth,int N_RB) {
|
||||
else return(N_RB-tmp2);
|
||||
}
|
||||
|
||||
int PRBalloc_to_locationanbandwidth(int NPRB,int RBstart) {
|
||||
int PRBalloc_to_locationandbandwidth(int NPRB,int RBstart) {
|
||||
return(275*(NPRB-1)+RBstart);
|
||||
}
|
||||
|
||||
@@ -108,3 +108,20 @@ uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
int get_subband_size(int NPRB,int size) {
|
||||
// implements table 5.2.1.4-2 from 36.214
|
||||
//
|
||||
//Bandwidth part (PRBs) Subband size (PRBs)
|
||||
// < 24 N/A
|
||||
//24 – 72 4, 8
|
||||
//73 – 144 8, 16
|
||||
//145 – 275 16, 32
|
||||
|
||||
if (NPRB<24) return(1);
|
||||
if (NPRB<72) return (size==0 ? 4 : 8);
|
||||
if (NPRB<144) return (size==0 ? 8 : 16);
|
||||
if (NPRB<275) return (size==0 ? 16 : 32);
|
||||
AssertFatal(1==0,"Shouldn't get here, NPRB %d\n",NPRB);
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
|
||||
* contributor license agreements. See the NOTICE file distributed with
|
||||
* this work for additional information regarding copyright ownership.
|
||||
* The OpenAirInterface Software Alliance licenses this file to You under
|
||||
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
|
||||
* except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.openairinterface.org/?page_id=698
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*-------------------------------------------------------------------------------
|
||||
* For more information about the OpenAirInterface (OAI) Software Alliance:
|
||||
* contact@openairinterface.org
|
||||
*/
|
||||
|
||||
/* \file config_ue.c
|
||||
* \brief common utility functions for NR (gNB and UE)
|
||||
* \author R. Knopp,
|
||||
* \date 2019
|
||||
* \version 0.1
|
||||
* \company Eurecom
|
||||
* \email: knopp@eurecom.fr
|
||||
* \note
|
||||
* \warning
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include "assertions.h"
|
||||
|
||||
int NRRIV2BW(int locationAndBandwidth,int N_RB);
|
||||
int NRRIV2PRBOFFSET(int locationAndBandwidth,int N_RB);
|
||||
int PRBalloc_to_locationandbandwidth(int NPRB,int RBstart);
|
||||
extern uint16_t nr_target_code_rate_table1[29];
|
||||
extern uint16_t nr_target_code_rate_table2[28];
|
||||
extern uint16_t nr_target_code_rate_table3[29];
|
||||
extern uint16_t nr_tbs_table[93];
|
||||
uint8_t nr_get_Qm(uint8_t Imcs, uint8_t table_idx);
|
||||
uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx);
|
||||
int get_subband_size(int NPRB,int size);
|
||||
Reference in New Issue
Block a user