From: John Melton G0ORX Date: Sun, 10 Nov 2019 14:12:21 +0000 (+0000) Subject: fixed change to vfo.c vfo_step that lost SAT and RSAT code. X-Git-Url: https://git.rkrishnan.org/%5B/listings/flags/status?a=commitdiff_plain;h=5d22341ed00147a47c2c76e66367bd185276c2bc;p=pihpsdr.git fixed change to vfo.c vfo_step that lost SAT and RSAT code. --- diff --git a/vfo.c b/vfo.c index 876046e..c73c47a 100644 --- a/vfo.c +++ b/vfo.c @@ -556,6 +556,29 @@ void vfo_step(int steps) { } else { vfo[id].frequency=(vfo[id].frequency/step +steps)*step; } + + int sid=id==0?1:0; + switch(sat_mode) { + case SAT_NONE: + break; + case SAT_MODE: + // A and B increment and decrement together + if(vfo[sid].ctun) { + vfo[sid].ctun_frequency=vfo[sid].ctun_frequency+(steps*step); + } else { + vfo[sid].frequency=vfo[sid].frequency+(steps*step); + } + break; + case RSAT_MODE: + // A increments and B decrements or A decrments and B increments + if(vfo[sid].ctun) { + vfo[sid].ctun_frequency=vfo[sid].ctun_frequency-(steps*step); + } else { + vfo[sid].frequency=vfo[sid].frequency-(steps*step); + } + break; + } + receiver_frequency_changed(active_receiver); #ifdef INCLUDED BANDSTACK_ENTRY* entry=bandstack_entry_get_current();