From 0091a1e17ae7c174dd9c655b020eda8b551dd3d6 Mon Sep 17 00:00:00 2001 From: Reed Nightingale Date: Tue, 21 Apr 2020 21:10:24 -0700 Subject: [PATCH] Update includes, and make VFO switch explicit --- ubitx_cat.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/ubitx_cat.cpp b/ubitx_cat.cpp index 27d9707..a034bc5 100644 --- a/ubitx_cat.cpp +++ b/ubitx_cat.cpp @@ -1,7 +1,8 @@ #include -#include "settings.h" -#include "ubitx.h" #include "nano_gui.h" +#include "scratch_space.h" +#include "settings.h" +#include "tuner.h" /** * The CAT protocol is used by many radios to provide remote control to comptuers through @@ -336,11 +337,12 @@ void processCATCommand2(byte* cmd) { case 0x81: //toggle the VFOs response[0] = 0; - if (VFO_A == globalSettings.activeVfo) - switchVFO(VFO_B); - else - switchVFO(VFO_A); - //menuVfoToggle(1); // '1' forces it to change the VFO + if (Vfo_e::VFO_A == globalSettings.activeVfo){ + globalSettings.activeVfo = Vfo_e::VFO_B; + } + else{ + globalSettings.activeVfo = Vfo_e::VFO_A; + } Serial.write(response,1); updateDisplay(); break;