From 21d6da674d13811074f65de6255c52d59f6afbb2 Mon Sep 17 00:00:00 2001
From: Ramakrishnan Muthukrishnan <ram@rkrishnan.org>
Date: Thu, 4 Aug 2022 13:22:45 +0530
Subject: [PATCH] rigctl: RIT - remove hard coding of rit increment

---
 rigctl.c | 16 ++++------------
 1 file changed, 4 insertions(+), 12 deletions(-)

diff --git a/rigctl.c b/rigctl.c
index a12075a..bf8bec2 100644
--- a/rigctl.c
+++ b/rigctl.c
@@ -2201,12 +2201,8 @@ gboolean parse_extended_cmd(char *command, CLIENT *client) {
     case 'U': // ZZRU
       // increments RIT Frequency
       if (command[4] == ';') {
-        if (vfo[VFO_A].mode == modeCWL || vfo[VFO_A].mode == modeCWU) {
-          vfo[VFO_A].rit += 10;
-        } else {
-          vfo[VFO_A].rit += 50;
-        }
-        vfo_update();
+	  vfo[VFO_A].rit += rit_increment;
+	  vfo_update();
       } else if (command[9] == ';') {
         vfo[VFO_A].rit = atoi(&command[4]);
         vfo_update();
@@ -3494,12 +3490,8 @@ int parse_cmd(void *data) {
     case 'D': // RD
       // decrements RIT Frequency
       if (command[2] == ';') {
-        if (vfo[VFO_A].mode == modeCWL || vfo[VFO_A].mode == modeCWU) {
-          vfo[VFO_A].rit -= 10;
-        } else {
-          vfo[VFO_A].rit -= 50;
-        }
-        vfo_update();
+	  vfo[VFO_A].rit -= rit_increment;
+	  vfo_update();
       } else if (command[7] == ';') {
         vfo[VFO_A].rit = atoi(&command[2]);
         vfo_update();
-- 
2.45.2