tbs as uint32_t
This commit is contained in:
@@ -593,7 +593,7 @@ typedef struct {
|
||||
uint16_t coding_rate;
|
||||
uint8_t modulation;
|
||||
uint8_t modulation_order;
|
||||
uint16_t transport_block_size;
|
||||
uint32_t transport_block_size;
|
||||
uint8_t nb_re_dmrs;
|
||||
uint8_t time_alloc_list_flag;
|
||||
uint8_t time_alloc_list;
|
||||
|
||||
@@ -54,8 +54,6 @@ uint32_t nr_compute_tbs(uint16_t Qm,
|
||||
// Intermediate number of information bits
|
||||
Ninfo = (nb_re * R * Qm * Nl)>>scale;
|
||||
|
||||
//printf("Ninfo %lf nbp_re %d nb_re %d mcs %d Qm %d, R %d\n", Ninfo, nbp_re, nb_re,mcs, Qm, R);
|
||||
|
||||
if (Ninfo <=3824) {
|
||||
n = max(3, floor(log2(Ninfo)) - 6);
|
||||
Np_info = max(24, (Ninfo>>n)<<n);
|
||||
@@ -86,6 +84,7 @@ uint32_t nr_compute_tbs(uint16_t Qm,
|
||||
}
|
||||
|
||||
}
|
||||
//printf("Ninfo %d nbp_re %d nb_re %d Qm %d, R %d, tbs %d\n", Ninfo, nbp_re, nb_re, Qm, R, nr_tbs);
|
||||
return nr_tbs;
|
||||
}
|
||||
|
||||
|
||||
@@ -184,7 +184,8 @@ void nr_get_tbs_dl(nfapi_nr_dl_config_dlsch_pdu *dlsch_pdu,
|
||||
uint16_t N_RE_prime = NR_NB_SC_PER_RB*N_sh_symb - N_PRB_DMRS - N_PRB_oh;
|
||||
LOG_D(MAC, "N_RE_prime %d for %d symbols %d DMRS per PRB and %d overhead\n", N_RE_prime, N_sh_symb, N_PRB_DMRS, N_PRB_oh);
|
||||
|
||||
uint16_t R, TBS=0;
|
||||
uint16_t R;
|
||||
uint32_t TBS=0;
|
||||
uint8_t table_idx, Qm;
|
||||
|
||||
/*uint8_t mcs_table = config.pdsch_config.mcs_table.value;
|
||||
|
||||
Reference in New Issue
Block a user