Commit 6fc37985 authored by Hongzhi Wang's avatar Hongzhi Wang

update dlsch available bits

parent fac57fd7
...@@ -53,5 +53,5 @@ uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx); ...@@ -53,5 +53,5 @@ uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx);
/** \brief Computes available bits G. /** \brief Computes available bits G.
@param nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs */ @param nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs */
uint32_t nr_get_G(uint16_t nb_rb, uint16_t nb_symb_sch,uint8_t nb_re_dmrs,uint16_t length_dmrs); uint32_t nr_get_G(uint16_t nb_rb, uint16_t nb_symb_sch,uint8_t nb_re_dmrs,uint16_t length_dmrs,uint8_t Qm);
...@@ -286,7 +286,7 @@ int nr_dlsch_encoding(PHY_VARS_gNB *gNB, ...@@ -286,7 +286,7 @@ int nr_dlsch_encoding(PHY_VARS_gNB *gNB,
//printf("Encoder: A: %d frame.subframe %d.%d \n",A, frame,subframe); //printf("Encoder: A: %d frame.subframe %d.%d \n",A, frame,subframe);
mod_order = get_nr_Qm(dlsch->harq_processes[harq_pid]->mcs); mod_order = get_nr_Qm(dlsch->harq_processes[harq_pid]->mcs);
G = nr_get_G(nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs); G = nr_get_G(nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs,mod_order);
Tbslbrm = nr_compute_tbs(28,nb_rb,frame_parms->symbols_per_slot,0,0, dlsch->harq_processes[harq_pid]->Nl); Tbslbrm = nr_compute_tbs(28,nb_rb,frame_parms->symbols_per_slot,0,0, dlsch->harq_processes[harq_pid]->Nl);
......
...@@ -80,8 +80,8 @@ uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx) { ...@@ -80,8 +80,8 @@ uint32_t nr_get_code_rate(uint8_t Imcs, uint8_t table_idx) {
} }
} }
uint32_t nr_get_G(uint16_t nb_rb, uint16_t nb_symb_sch,uint8_t nb_re_dmrs,uint16_t length_dmrs) { uint32_t nr_get_G(uint16_t nb_rb, uint16_t nb_symb_sch,uint8_t nb_re_dmrs,uint16_t length_dmrs, uint8_t Qm) {
uint32_t G; uint32_t G;
G = ((12*nb_symb_sch)-(nb_re_dmrs*length_dmrs))*nb_rb; G = ((12*nb_symb_sch)-(nb_re_dmrs*length_dmrs))*nb_rb*Qm;
return(G); return(G);
} }
...@@ -261,7 +261,7 @@ uint32_t nr_dlsch_decoding(PHY_VARS_NR_UE *phy_vars_ue, ...@@ -261,7 +261,7 @@ uint32_t nr_dlsch_decoding(PHY_VARS_NR_UE *phy_vars_ue,
A = harq_process->TBS; A = harq_process->TBS;
ret = dlsch->max_ldpc_iterations; ret = dlsch->max_ldpc_iterations;
harq_process->G = nr_get_G(nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs); harq_process->G = nr_get_G(nb_rb, nb_symb_sch, nb_re_dmrs, length_dmrs, harq_process->Qm);
G = harq_process->G; G = harq_process->G;
//get_G(frame_parms,nb_rb,dlsch->rb_alloc,mod_order,num_pdcch_symbols,phy_vars_ue->frame,subframe); //get_G(frame_parms,nb_rb,dlsch->rb_alloc,mod_order,num_pdcch_symbols,phy_vars_ue->frame,subframe);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment