diff --git a/ChangeLog.txt b/ChangeLog.txt
index b4b583e..e05d515 100644
--- a/ChangeLog.txt
+++ b/ChangeLog.txt
@@ -3,7 +3,7 @@ CatRadio
(+ New, * Updated, - Removed)
1.4.1 - 2024-xx-xx
- + CW memory keyer for Yaesu
+ + CW memory keyer
+ Check hamlib version on startup
1.4.0 - 2024-03-17
diff --git a/mainwindow.ui b/mainwindow.ui
index c295014..65ab79a 100644
--- a/mainwindow.ui
+++ b/mainwindow.ui
@@ -1892,6 +1892,9 @@
2
+
+ 2
+
-
@@ -1912,6 +1915,9 @@
4
+
+ 4
+
-
@@ -1919,6 +1925,9 @@
3
+
+ 3
+
-
@@ -1946,6 +1955,9 @@
1
+
+ 1
+
-
@@ -1953,6 +1965,9 @@
5
+
+ 5
+
-
diff --git a/rigcommand.cpp b/rigcommand.cpp
index 7f09396..164f65b 100644
--- a/rigcommand.cpp
+++ b/rigcommand.cpp
@@ -96,7 +96,7 @@ void quick_split ()
rigCmd.split = 1;
}
-//* Send CW keyer message 1-5, Yaesu only
+//* Send CW keyer message 1-5
void send_cw_mem (int memory)
{
rigSet.cwMem = (char)(memory + '0');
@@ -173,7 +173,7 @@ ant_t antstr (QString antString)
return ant;
}
-//* Convert meter type string to hamlib number
+ //* Convert Submeter combo box string into hamlib RIG_LEVEL constant
unsigned long long levelmeterstr (QString meterString)
{
unsigned long long levelMeter;
diff --git a/rigcommand.h b/rigcommand.h
index 2eccd05..a91a505 100644
--- a/rigcommand.h
+++ b/rigcommand.h
@@ -34,4 +34,4 @@ agc_level_e levelagcvalue (int agcValue);
agc_level_e levelagcstr (QString agcString);
value_t valueagclevel (agc_level_e agcLevel);
ant_t antstr (QString antString);
-unsigned long long levelmeterstr (QString meterString); //Convert Submeter combo box string into Hamlib RIG_LEVEL constant
+unsigned long long levelmeterstr (QString meterString);
diff --git a/rigdaemon.cpp b/rigdaemon.cpp
index 97b6905..a8af4b2 100644
--- a/rigdaemon.cpp
+++ b/rigdaemon.cpp
@@ -116,9 +116,10 @@ void RigDaemon::rigUpdate(RIG *my_rig)
rigCmd.ptt = 0;
}
- if (rigCmd.cwSend)
+ if (rigCmd.cwSend && (rigGet.mode == RIG_MODE_CW || rigGet.mode == RIG_MODE_CWN || rigGet.mode == RIG_MODE_CWR))
{
- rig_send_morse(my_rig, RIG_VFO_CURR, &rigSet.cwMem);
+ retcode = rig_send_morse(my_rig, RIG_VFO_CURR, &rigSet.cwMem);
+ //if (retcode == RIG_OK) rigGet.ptt = RIG_PTT_ON; //assume PPT on if send_morse is ok
rigCmd.cwSend = 0;
}
@@ -141,6 +142,12 @@ void RigDaemon::rigUpdate(RIG *my_rig)
//***** Priority Poll execution *****
else
{
+ //* PTT
+ ptt_t retptt;
+ retcode = rig_get_ptt(my_rig, RIG_VFO_CURR, &retptt);
+ if (retcode == RIG_OK) rigGet.ptt = retptt;
+
+ //* VFO
freq_t retfreq;
retcode = rig_get_freq(my_rig, RIG_VFO_CURR, &retfreq); //get VFO Main
if (retcode == RIG_OK) rigGet.freqMain = retfreq;
@@ -150,11 +157,6 @@ void RigDaemon::rigUpdate(RIG *my_rig)
if (retcode == RIG_OK) rigGet.freqSub = retfreq;
}
- //* PTT
- ptt_t retptt;
- retcode = rig_get_ptt(my_rig, RIG_VFO_CURR, &retptt);
- if (retcode == RIG_OK) rigGet.ptt = retptt;
-
//* Meter
if (rigGet.ptt == 1 || rigSet.ptt == 1)
{
@@ -819,7 +821,7 @@ void RigDaemon::rigUpdate(RIG *my_rig)
}
//* CW
- if ((indexCmd == 19 && !rigGet.ptt && rigCom.fullPoll) || indexCmd == 0) //&& mode=CW
+ if ((indexCmd == 19 && !rigGet.ptt && rigCom.fullPoll && (rigGet.mode == RIG_MODE_CW || rigGet.mode == RIG_MODE_CWN || rigGet.mode == RIG_MODE_CWR)) || indexCmd == 0)
{
if (rig_has_get_func(my_rig, RIG_FUNC_FBKIN)) rig_get_func(my_rig, RIG_VFO_CURR, RIG_FUNC_FBKIN, &rigGet.bkin); //Break-in
if (rig_has_get_func(my_rig, RIG_FUNC_APF)) rig_get_func(my_rig, RIG_VFO_CURR, RIG_FUNC_APF, &rigGet.apf); //Audio Peak Filter