Commit graph

12709 commits

Author SHA1 Message Date
Nate Bargmann
d042479a9f
Hamlib 4.7.1 release 2026-04-15 15:20:01 -05:00
Nate Bargmann
b173cab3bc
Update NEWS for additional warning fix 2026-04-14 22:19:47 -05:00
George Baltz N3GB
d4b0eb2df8
Fix compiler warning
(cherry picked from commit 1236b6991b)
2026-04-14 22:17:38 -05:00
Nate Bargmann
228e9461e2
Update NEWS for quelling clang warning 2026-04-14 13:59:17 -05:00
Nate Bargmann
2fbcd70a04
Quell clang warning on Debian Stable
The clang compiler generated the following warning on Debian Stable
(13):

  CC       ftx1/ftx1.lo
../../../hamlib/rigs/yaesu/ftx1/ftx1.c:1020:24: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
 1020 |         [LVL_KEYSPD] = { .min = { .i = 4 }, .max = { .i = 60 }, .step = { .i = 1 } },
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../hamlib/rigs/yaesu/level_gran_yaesu.h:12:25: note: previous initialization is here
   12 |         [LVL_KEYSPD]  = { .min = { .i = 4 },           .max = { .i = 60 },   .step = { .i = 1 } },
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.

Per George Baltz this should have generated a warning with GCC but did
not.  Commenting for now "just in case".
2026-04-14 13:45:23 -05:00
Nate Bargmann
b234d789d1
Update NEWS for FTX-1 bandwisth fixes 2026-04-13 20:50:44 -05:00
KJ5HST
7932d4b59e
ftx1: wire SH bandwidth command into set_mode/get_mode (#2027)
The FTX-1 driver delegates mode handling to newcat_set_mode /
newcat_get_mode, which previously had no FTX-1 branch in the
bandwidth helpers. Effects:

  * rig_get_mode always returned passband=0 for the FTX-1
  * rig_set_mode silently dropped the width argument

Add dedicated is_ftx1 branches to newcat_set_rx_bandwidth and
newcat_get_rx_bandwidth, and extend the SH command-string builder
to emit the 7-char SH00NN; form for FTX-1.

The bandwidth table is per FTX-1 CAT Operation Reference Manual
Table 5 (doc 2508-C). It is deliberately kept separate from the
FT-710 / FTDX10 branch because the SSB column diverges at codes
12/13/14: FTX-1 uses 2250/2400/2450 Hz where FT-710 uses
2200/2300/2400 Hz. Sharing the branch would silently misreport
2400 Hz on the FTX-1 -- exactly the canonical SSB filter.

PSK is included in the CW/DATA/RTTY case group because Table 5
groups it there, and live probing of firmware v1.12 confirmed PSK
mode defaults to SH code 19 (the DATA default) rather than an SSB
code.

Verified end-to-end against a live FTX-1 (fw v1.12) at 115200 bps:
USB 2400/2700/2250/2450/3000, CW 500/2400, PKTUSB 3000, AM 9000,
FM 16000 all round-trip correctly through rig_set_mode /
rig_get_mode, with raw-CAT SH reads confirming the corrected code
mapping (2250->SH12, 2400->SH13, 2450->SH14).

(cherry picked from commit b429b2a35b)
2026-04-13 20:18:28 -05:00
Nate Bargmann
037a3e232e
Update NEWS for K3/K3S low power calculation fix 2026-04-11 21:22:40 -05:00
Nate Bargmann
8ba5fd2f3c
Fix RF Power output reading in low power mode
As reported by Tom, W2YF:

https://sourceforge.net/p/hamlib/mailman/message/59309943/

In low power mode, <= 12 Watts, the power was incorrectly reported too
high by a factor of 10.

Also use a lower value of divisor to achieve a reported power level
closer to the actual value.
2026-04-11 18:35:30 -05:00
Nate Bargmann
fda9092c89
Update NEWS for FT-710 fixes 2026-04-11 10:01:18 -05:00
George Baltz N3GB
40a8c82967
Fix FT-710 newcat_get_rx_bandwidth()
Found after fixing set (issue #2021)
Also fix typo in FT-950 code.

(cherry picked from commit 506c3ea770)
2026-04-11 09:58:20 -05:00
George Baltz N3GB
7fef4c3933
Use the correct SH command in newcat_set_rx_bandwidth() and simft710.c
FT-710 CAT Operations Manual says the FT-710 has 2 leading zeroes (P1
  & P2), not just 1.

Fix missing "== 0"

(cherry picked from commit bf5bea4012)
2026-04-11 08:20:03 -05:00
George Baltz N3GB
6eff8d01a5
Make sure simft710.c rejects RF command
No roofing filters on this rig.
Clean out includes of rig.h and misc.c

(cherry picked from commit 31d1635cf3)
2026-04-11 08:19:47 -05:00
George Baltz N3GB
e8430e9943
Fix some obvious errors in newcat.c
Try a few shots in the dark for issues #2021 & #2024

Acknowledge that the FT-710 does NOT have an "RF" command.
Don't call newcat_set_roofing_filter_for_width() if there are
  no roofing filters available.
Fix runaway search for matching roofing filters; use count as there
  are no end entries the filter table.

I really can't test these(no hardware), but just looking at the code
  and the traces from the issues above it's evident that these things
  are broken. This may not fix everything, and may even break in new ways,
  but it may make the actual problems a bit easier to find.

(cherry picked from commit 1fa3444884)
2026-04-11 08:19:31 -05:00
Nate Bargmann
8cde902c7c
Add RIG_MODEL_PRC138 to test_Hamlib_class.py
Reported by Walter Fey:
4f4507fa8c (commitcomment-182142320)
2026-04-11 08:10:16 -05:00
Nate Bargmann
c13e11530e
Update NEWS to add new rig model PRC-138 2026-04-10 21:53:43 -05:00
Nate Bargmann
fff7810f0a
Fixes to PR #2028
Add Android.mk.
Add header files to Makefile.am
Replace .rig_model member with RIG_MODEL() macro in prc138_caps
structure.

(cherry picked from commit 452544e08c)
2026-04-10 19:59:35 -05:00
Rega57
ad3e839acf
Warning fixed long long
Line 353 debug long long function

(cherry picked from commit a27c1a22fd)
2026-04-10 19:58:26 -05:00
Rega57
489fe24d2a
Initial comment with GPL added
Initial comment with GPL added

(cherry picked from commit c7c45f2997)
2026-04-10 19:58:02 -05:00
Rega57
fb2d24e3c6
Update harris.c
Replaced italian comments and logs with english text.

(cherry picked from commit c3df0fc251)
2026-04-10 19:56:05 -05:00
Rega57
2df5128251
Add support for Harris PRC-138
This is the first implementation of basic funtionality of Harris PRC-138.

(cherry picked from commit f880cac0ad)
2026-04-10 19:52:36 -05:00
Nate Bargmann
459023b2bb
Update NEWS for Icom and Yaesu fixes
Set release date to 15 Apr 2026.
2026-04-03 10:29:51 -05:00
George Baltz N3GB
7fb567333c
Fix attenuator limit in level_gran_yaesu.h
Since the individual attenuator steps are checked in newcat.c, let
  the max value through rig_check_level.  Fixes issue #2023

Also noticed a typo in the kludge for reinitializing structure data. This
  meant there was no LVL_KEYSPD data for Yaesu rigs for over a year.

(cherry picked from commit 30d0be546b)
2026-04-03 10:25:42 -05:00
George Baltz N3GB
66cc6d8ac6
Update IC-9700
Also mentioned in issue #2018

(cherry picked from commit 0b2f36f0a6)
2026-03-29 21:07:47 -05:00
George Baltz N3GB
9f610e6c63
Clean up IC-7000, IC-7100, and IC-9100
Replace clock routines in ic7100.c

(cherry picked from commit 48dc2d2bc8)
2026-03-29 21:07:32 -05:00
George Baltz N3GB
9ea4409f71
Tidy up more Icom rigs.
Use icom_*_clock() in ic-7800
Make more local data static
Fix some more bad parameters in extcmds.

(cherry picked from commit 688762df27)
2026-03-29 21:07:11 -05:00
George Baltz N3GB
b4afe37fcf
Fixes for IC-705 and IC-905
Add clock set/get to both rigs.
Add custom extcmds for IC-905
Fix RIG_LEVEL_USB_AF for IC-705 so it sets AF gain, not IF gain.
Make local data items static.

(cherry picked from commit 3d68d50a5b)
2026-03-29 21:06:56 -05:00
George Baltz N3GB
d4a2568c53
First uses of icom_[gs]et_clock
Removes ic7300_[gs]_clock and rigs/icom/ic7300.h
Make ic785x.c less dependent on other rigs.

(cherry picked from commit faed43703b)
2026-03-29 21:05:51 -05:00
George Baltz N3GB
36ccee9bf7
Add generalized routines for Icom clock handling
Relies or new structure in priv_caps to find values of 0x1A 0x05
  subcommands for date, time, and offset data.

Also sets offset first, so later values are stored relative to the new one,
  not whatever was there before.

(cherry picked from commit 1512278872)
2026-03-29 21:05:28 -05:00
Nate Bargmann
fdb413ebdb
Quell warning from MinGW; update NEWS for simplecat
MinGW generated the following warning:

Making install in rigs/simplecat
  CC       simplecat.lo
simplecat.c: In function 'simplecat_transaction':
simplecat.c:94:17: warning: the comparison will always evaluate as 'true' for the address of 'state' will never be NULL [-Waddress]
   94 |     if (!rig || !STATE(rig))
      |                 ^
In file included from simplecat.c:27:
../../include/hamlib/rig.h:2672:22: note: 'state' declared here
 2672 |     struct rig_state state;         /*!< Rig state */
      |                      ^~~~~
  CCLD     libhamlib-simplecat.la

This warning is due to the changes to the state structure in Hamlib 5+.
2026-03-26 08:09:40 -05:00
Dhiru Kholia
3cf97b5a5b
Add support for rigs using the 'Simple CAT' protocol
See 'rigs/simplecat/SIMPLE_CAT_PROTOCOL.md' for the protocol spec.

Notes:

- Memory correctness checks were done using Valgrind.

- Tested with wsjtx-3.1.0_improved_PLUS_260228.tgz (with mods) and
  Bunzee Labs' DDX HF Digital Transceiver

  https://bunzee-labs.com/products/ddx

Tested on:

- Ubuntu Linux
- macOS Tahoe
- Windows 11

(cherry picked from commit debe6fcaf9)
2026-03-26 07:25:09 -05:00
Nate Bargmann
7ff995e0b8
Update NEWS for adding TS-850 get_split_vfo 2026-03-15 22:00:50 -05:00
Elisamuel Resto
963c57f326
kenwood: add get_split_vfo to TS-850 backend
(cherry picked from commit c2fea0147c)
2026-03-15 21:57:43 -05:00
Nate Bargmann
c21afd05e9
Update NEWS for K3/K4 added SWR level support 2026-03-15 16:58:48 -05:00
Nate Bargmann
6ee1142a8d
Add RIG_LEVEL_SWR to K3_LEVEL_ALL
Per mailing list discussion opened by Tom, W2YF, this addresses the
report that SWR readout is missing on the K4.  I confirmed it is also
missing on the K3 and this patch enables it in WSJT-X Improved 3.1.0
Plus as packaged for Debian Stable backports.

George, N3GB, suggested that K3_LEVEL_ALL did not include RIG_LEVEL_SWR
and indeed that was the bug that prevented the SWR value from being read
in WSJT-X.  Tom confirmed that the K4 also works correctly with WSJT-X.
2026-03-15 16:51:14 -05:00
Nate Bargmann
29c56af0d6
Update NEWS for Flrig power off & GCC 16 warning 2026-03-14 17:48:18 -05:00
George Baltz N3GB
490491645a
Avoid warnings from gcc-16
gcc-16 adds warnings about using strncpy() to copy into a buffer with
  size equal to the max count, possibly creating an unterminated string.
  Since we don't care about the contents here and both buffers are the
  same size, just do a byte copy.

(cherry picked from commit b6a25c8a83)
2026-03-14 17:30:47 -05:00
Phil GM3ZZA
1f51f1661d
Add Power Off to Flrig backend 2026-03-13 12:49:55 -05:00
Nate Bargmann
f189bcfadf
Update NEWS for FTX-1 fixes 2026-03-11 07:32:27 -05:00
KJ5HST
3cb1eb9288
fix: eliminate clarifier read-then-write race condition (Bug 3.1)
The CF command requires both RX and TX CLAR enables in one write.
Previously, set_rx_clar read TX state then wrote both, creating a
window where an external actor could change TX between read and write.
Same pattern in set_tx_clar with RX state.

Fix: cache both RX/TX CLAR enable states in newcat_priv_data. The get
functions refresh the cache on every read. The set functions use the
cached sibling state instead of reading from the radio, eliminating the
race window. Cold-start fallback reads from radio if no cache exists.

(cherry picked from commit 12ef996131)
2026-03-11 07:22:50 -05:00
KJ5HST
56938d122a
fix: use calibration tables for SWR and ALC meter scaling
Replace naive /100.0f divisor with rig_raw2val_float() using the
FTX1_SWR_CAL and FTX1_ALC_CAL calibration tables added in the
previous commit. This matches how newcat handles meter values for
other Yaesu radios and produces correct SWR ratios and 0.0-1.0
normalized ALC values from raw 0-255 RM readings.

(cherry picked from commit 280664b02e)
2026-03-11 07:22:38 -05:00
KJ5HST
6b8be5f8e9
fix: add meter calibration tables for SWR, ALC, COMP, VD, and ID meters
Uses Yaesu default values as initial calibration data. Tables are
defined explicitly in ftx1.h so they can be replaced with FTX-1-specific
values after hardware verification.

(cherry picked from commit 6127d79f7b)
2026-03-11 07:22:26 -05:00
KJ5HST
3db6ccd447
fix: correct MS meter switch mapping for FTX-1
The MS command comment had wrong type codes (claimed 0=S-meter, but CAT
manual p.20 shows 0=PO, 1=COMP, 2=ALC, 3=VDD, 4=ID, 5=SWR). More
critically, set/get were passing raw CAT codes instead of translating
to/from Hamlib RIG_METER_* bitmask values. Added ftx1_meter_to_cat()
and ftx1_cat_to_meter() conversion functions matching the FTX-1's
unique ordering (differs from FT-891/991 newcat mapping).

(cherry picked from commit 55c3c08541)
2026-03-11 07:22:15 -05:00
KJ5HST
3f65b08219
fix: correct NR level range and SH width documentation per CAT manual
HW-1: SH (Width) command is read-write per CAT manual Table 5, not
read-only as previously commented. Width codes are mode-dependent.

HW-2: NR level range is 00-10 per CAT manual p.23, not 00-15. This
changes the float scaling (0.0-1.0 now maps to 0-10 radio levels).

(cherry picked from commit 7fee722032)
2026-03-11 07:22:02 -05:00
KJ5HST
bdeab27027
fix: close 4 Hamlib coverage gaps in FTX-1 driver
- Gap 3: Remove RIG_LEVEL_COMP intercept from get_level — was returning
  RM3 meter reading instead of PL setting. Falls through to newcat now.
- Gap 1: Wire send_voice_mem callback to newcat_send_voice_mem (PB cmd)
- Gap 2: Wire set_clock/get_clock callbacks to newcat (DT cmd)
- Gap 4: Add RIG_LEVEL_BKIN_DLYMS to rig_caps and dispatchers, using
  existing ftx1_set_cw_delay_ms/ftx1_get_cw_delay_ms helpers

(cherry picked from commit 0cb408cb68)
2026-03-11 07:21:51 -05:00
KJ5HST
18efbc6c52
fix: add RFPOWER_METER, RFPOWER_METER_WATTS, and COMP_METER to FTX-1 rig caps
These read-only meter levels (RM5=PO, RM3=COMP) were missing from
has_get_level. The get_level dispatcher already falls through to
newcat's RM handler. Also wire up rfpower_meter_cal so the FTX-1
specific calibration table is used instead of the Yaesu default.

(cherry picked from commit 53f3e56598)
2026-03-11 07:21:40 -05:00
KJ5HST
6989c97bf9
fix: restore VD_METER and ID_METER to FTX-1 rig caps
These read-only meter levels (RM7=ID, RM8=VDD) were in the original
driver but got dropped from has_get_level during the refactor into
the ftx1/ subdirectory. The get_level dispatcher already falls through
to newcat's handler which sends the correct RM commands.

(cherry picked from commit 43e62fc448)
2026-03-11 07:21:05 -05:00
KJ5HST
7046122b65
fix: correct FBKIN/SBKIN break-in mode detection and control (Bug 1.3)
BI command is binary (0=off, 1=on) with no mode parameter. The
distinction between semi and full break-in is determined by the SD
delay value: SD00 (30ms) = full/QSK, higher = semi.

Previously FBKIN set passed mode=2 to ftx1_set_breakin() which always
rejected it (-RIG_EINVAL), and FBKIN get checked mode==2 which never
matched since BI only returns 0 or 1.

Fix: add ftx1_set_cw_delay_ms()/ftx1_get_cw_delay_ms() helpers that
work directly in milliseconds. FBKIN enables break-in and sets minimum
delay (QSK). SBKIN enables break-in and bumps delay to 250ms if
currently at QSK. Get path reads both BI state and SD delay to
determine which mode is active.

(cherry picked from commit dcf65df72a)
2026-03-11 07:20:49 -05:00
KJ5HST
c72bb1e29b
fix: convert BKINDL between Hamlib tenths-of-dots and SD codes (Bug 2.2)
SD command uses the same non-linear 00-33 codes as VD. Added lookup
table and closest-code search in ftx1_cw.c. Set/get now convert via
milliseconds using dot10ths_to_millis/millis_to_dot10ths with the
current keyspeed (WPM). Updated level granularity to {30, 3000, 1}
matching standard Yaesu convention.

(cherry picked from commit 61df5612f7)
2026-03-11 07:20:34 -05:00
KJ5HST
2eb7524b4f
fix: convert VOXDELAY between Hamlib tenths-of-seconds and VD codes (Bug 2.1)
Add lookup table for FTX-1 VD command's non-linear code-to-millisecond
mapping. Set path converts tenths-of-seconds to ms and finds closest VD
code. Get path converts VD code to ms then to tenths-of-seconds. Update
level granularity from raw 0-33 to Hamlib units 0-300.

(cherry picked from commit 111c865513)
2026-03-11 07:20:22 -05:00