From d6e0153b40caddf32f173de9a143f0ecbc259d5b Mon Sep 17 00:00:00 2001 From: Andre Puschmann Date: Sat, 25 Apr 2020 21:07:04 +0200 Subject: [PATCH] sci: add SCI format 1 transmission format flag --- lib/include/srslte/phy/phch/sci.h | 5 +++++ lib/src/phy/phch/sci.c | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/lib/include/srslte/phy/phch/sci.h b/lib/include/srslte/phy/phch/sci.h index 97c316dfc..8316c6a83 100644 --- a/lib/include/srslte/phy/phch/sci.h +++ b/lib/include/srslte/phy/phch/sci.h @@ -92,6 +92,11 @@ typedef struct SRSLTE_API { // Retransmission index (1 bit) bool retransmission; + // Transmission format (1 bit) + // 1 means transmission format including rate-matching and TBS scaling + // 0 means transmission format including puncturing and no TBS-scaling + uint32_t transmission_format; + } srslte_sci_t; SRSLTE_API int diff --git a/lib/src/phy/phch/sci.c b/lib/src/phy/phch/sci.c index 34648e8b8..c09c18395 100644 --- a/lib/src/phy/phch/sci.c +++ b/lib/src/phy/phch/sci.c @@ -156,7 +156,8 @@ int srslte_sci_format1_unpack(srslte_sci_t* q, uint8_t* input) q->riv = srslte_bit_pack(&input, (uint32_t)ceil(log2(((q->num_sub_channel) * (q->num_sub_channel + 1) / 2)))); q->time_gap = srslte_bit_pack(&input, 4); q->mcs_idx = srslte_bit_pack(&input, 5); - q->retransmission = srslte_bit_pack(&input, 1); + q->retransmission = srslte_bit_pack(&input, 1); + q->transmission_format = srslte_bit_pack(&input, 1); // Sanity check if (q->mcs_idx >= 29) { @@ -184,11 +185,12 @@ void srslte_sci_info(const srslte_sci_t* q, char* str, uint32_t len) n = srslte_print_check(str, SRSLTE_SCI_MSG_MAX_LEN, n, - ", priority=%i, res_rsrv=%i, t_gap=%i, rtx=%i\n", + ", priority=%i, res_rsrv=%i, t_gap=%i, rtx=%i, txformat=%d\n", q->priority, q->resource_reserv, q->time_gap, - q->retransmission); + q->retransmission, + q->transmission_format); } }