|
|
|
@ -152,6 +152,8 @@ static int check_softbits(
|
|
|
|
|
{
|
|
|
|
|
int ret = SRSLTE_SUCCESS;
|
|
|
|
|
|
|
|
|
|
if (!pdsch_ue->llr_is_8bit && !tb_cw_swap) {
|
|
|
|
|
|
|
|
|
|
// Generate sequence
|
|
|
|
|
srslte_sequence_pdsch(&pdsch_ue->tmp_seq,
|
|
|
|
|
rnti,
|
|
|
|
@ -161,11 +163,8 @@ static int check_softbits(
|
|
|
|
|
pdsch_cfg->grant.tb[tb].nof_bits);
|
|
|
|
|
|
|
|
|
|
// Scramble
|
|
|
|
|
if (pdsch_ue->llr_is_8bit) {
|
|
|
|
|
srslte_scrambling_sb_offset(&pdsch_ue->tmp_seq, pdsch_ue->e[tb], 0, pdsch_cfg->grant.tb[tb].nof_bits);
|
|
|
|
|
} else {
|
|
|
|
|
srslte_scrambling_s_offset(&pdsch_ue->tmp_seq, pdsch_ue->e[tb], 0, pdsch_cfg->grant.tb[tb].nof_bits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int16_t* rx = pdsch_ue->e[tb];
|
|
|
|
|
uint8_t* rx_bytes = pdsch_ue->e[tb];
|
|
|
|
|
for (int i = 0, k = 0; i < pdsch_cfg->grant.tb[tb].nof_bits / 8; i++) {
|
|
|
|
@ -178,7 +177,7 @@ static int check_softbits(
|
|
|
|
|
if (memcmp(pdsch_ue->e[tb], pdsch_enb->e[tb], pdsch_cfg->grant.tb[tb].nof_bits / 8) != 0) {
|
|
|
|
|
ret = SRSLTE_ERROR;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
return ret;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -514,8 +513,6 @@ int main(int argc, char **argv) {
|
|
|
|
|
tb,
|
|
|
|
|
subframe,
|
|
|
|
|
pdsch_res[tb].crc);
|
|
|
|
|
srslte_vec_fprint_byte(stdout, (uint8_t*)pdsch_tx.e[tb], pdsch_cfg.grant.tb[tb].nof_bits / 8);
|
|
|
|
|
srslte_vec_fprint_byte(stdout, (uint8_t*)pdsch_rx.e[tb], pdsch_cfg.grant.tb[tb].nof_bits / 8);
|
|
|
|
|
} else {
|
|
|
|
|
for (int byte = 0; byte < pdsch_cfg.grant.tb[tb].tbs / 8; byte++) {
|
|
|
|
|
if (data_tx[tb][byte] != data_rx[tb][byte]) {
|
|
|
|
|