From 002b9b0f65cdd4631e63d5f30b795b798ea6181e Mon Sep 17 00:00:00 2001
From: Wilson Thong <wilsonthong@astri.org>
Date: Tue, 28 Mar 2017 10:42:04 +0800
Subject: [PATCH] #222 fix incorrect PUCCH format when sending SR in TDD

---
 openair1/SCHED/phy_procedures_lte_ue.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/openair1/SCHED/phy_procedures_lte_ue.c b/openair1/SCHED/phy_procedures_lte_ue.c
index 776de2335d..adfe0e7581 100644
--- a/openair1/SCHED/phy_procedures_lte_ue.c
+++ b/openair1/SCHED/phy_procedures_lte_ue.c
@@ -633,7 +633,13 @@ PUCCH_FMT_t get_pucch_format(lte_frame_type_t frame_type,
       }
       if(SR_payload == 1)
       {
-          return pucch_format1;
+          if (frame_type == FDD) {
+              return pucch_format1;
+          } else if (frame_type == TDD) {
+              return pucch_format1b;
+          } else {
+	      AssertFatal(1==0,"Unknown frame_type");
+          }
       }
   }
   else
-- 
GitLab