mirror of https://github.com/PentHertz/srsLTE.git
Fixed errors for phy_dl_test and pdsch test
This commit is contained in:
parent
4627737c87
commit
46724c336d
|
@ -67,7 +67,7 @@ option(ENABLE_SRSENB "Build srsENB application" ON)
|
|||
option(ENABLE_SRSEPC "Build srsEPC application" ON)
|
||||
option(DISABLE_SIMD "disable simd instructions" OFF)
|
||||
|
||||
option(ENABLE_GUI "Enable GUI (using srsGUI)" ON)
|
||||
option(ENABLE_GUI "Enable GUI (using srsGUI)" OFF)
|
||||
option(ENABLE_UHD "Enable UHD" ON)
|
||||
option(ENABLE_BLADERF "Enable BladeRF" ON)
|
||||
option(ENABLE_SOAPYSDR "Enable SoapySDR" ON)
|
||||
|
|
|
@ -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]) {
|
||||
|
|
|
@ -686,6 +686,12 @@ int main(int argc, char **argv) {
|
|||
free(data_rx[i]);
|
||||
}
|
||||
}
|
||||
if (enb_dl) {
|
||||
free(enb_dl);
|
||||
}
|
||||
if (ue_dl) {
|
||||
free(ue_dl);
|
||||
}
|
||||
|
||||
if (ret) {
|
||||
printf("Error\n");
|
||||
|
|
Loading…
Reference in New Issue