From: John Melton - G0ORX/N6LYT <john.d.melton@googlemail.com>
Date: Mon, 14 Nov 2016 08:59:07 +0000 (+0000)
Subject: fixed noise burst switching from tx to rx
X-Git-Url: https://git.rkrishnan.org/pf/content/en/install.html?a=commitdiff_plain;h=ebcfaffd524e21beb68b4db0b6e0344cb3fb3e77;p=pihpsdr.git

fixed noise burst switching from tx to rx
---

diff --git a/pihpsdr b/pihpsdr
index b8c4ae2..0589e56 100755
Binary files a/pihpsdr and b/pihpsdr differ
diff --git a/radio.c b/radio.c
index d1890ae..f556fcf 100644
--- a/radio.c
+++ b/radio.c
@@ -229,6 +229,28 @@ int getSampleRate() {
 
 void setMox(int state) {
   if(mox!=state) {
+    if(state) {
+      // switch to tx
+      SetChannelState(CHANNEL_RX0,0,1);
+      mox=state;
+      if(protocol==NEW_PROTOCOL) {
+        schedule_high_priority(3);
+      }
+      SetChannelState(CHANNEL_TX,1,0);
+#ifdef FREEDV
+      if(mode==modeFREEDV) {
+        freedv_reset_tx_text_index();
+      }
+#endif
+    } else {
+      SetChannelState(CHANNEL_TX,0,1);
+      mox=state;
+      if(protocol==NEW_PROTOCOL) {
+        schedule_high_priority(3);
+      }
+      SetChannelState(CHANNEL_RX0,1,0);
+    }
+/*
     mox=state;
     if(protocol==NEW_PROTOCOL) {
       schedule_high_priority(3);
@@ -245,6 +267,7 @@ void setMox(int state) {
       SetChannelState(CHANNEL_TX,0,1);
       SetChannelState(CHANNEL_RX0,1,0);
     }
+*/
   }
 }
 
diff --git a/release/pihpsdr.tar b/release/pihpsdr.tar
index 025e292..545d0a6 100644
Binary files a/release/pihpsdr.tar and b/release/pihpsdr.tar differ
diff --git a/release/pihpsdr/pihpsdr b/release/pihpsdr/pihpsdr
index b8c4ae2..0589e56 100755
Binary files a/release/pihpsdr/pihpsdr and b/release/pihpsdr/pihpsdr differ