From: John Melton G0ORX <john.d.melton@googlemail.com>
Date: Fri, 6 Mar 2020 11:08:46 +0000 (+0000)
Subject: Fixed MOX and TUNE not working for protocol 1 and protocol 2
X-Git-Url: https://git.rkrishnan.org/frontends/simplejson/(%5B%5E?a=commitdiff_plain;h=64e73249e78d3102a6ac9aee561ba58b34c45c1d;p=pihpsdr.git

Fixed MOX and TUNE not working for protocol 1 and protocol 2
---

diff --git a/radio.c b/radio.c
index a26e8d1..08d37e6 100644
--- a/radio.c
+++ b/radio.c
@@ -1301,7 +1301,7 @@ static void rxtx(int state) {
 void setMox(int state) {
   if(!can_transmit) return;
 #ifdef SOAPYSDR
-  if(!transmitter->local_microphone) return;
+  if(protocol==SOAPYSDR_PROTOCOL && !transmitter->local_microphone) return;
 #endif
   vox_cancel();  // remove time-out
   if(mox!=state) {
@@ -1378,7 +1378,9 @@ void setTune(int state) {
   int i;
 
   if(!can_transmit) return;
-  if(!transmitter->local_microphone) return;
+#ifdef SOAPYSDR
+  if(protocol==SOAPYSDR_PROTOCOL && !transmitter->local_microphone) return;
+#endif
 
   // if state==tune, this function is a no-op