Porównaj commity

...

1660 Commity

Autor SHA1 Wiadomość Data
Mike Black W9MDB a9c31b16fc Fix k3.c vfo_op -- was missing a break statement 2024-05-17 12:32:19 -05:00
Mike Black W9MDB 03f0bca7dc Fix auto tune function for Elecraft rigs 2024-05-16 16:40:40 -05:00
Mike Black W9MDB cd453b5b71 Reduce verbose level on debug to VERBOSE instead of ERR in newcat.c 2024-05-14 10:27:39 -05:00
Michael Black 9e816e37ff
Merge pull request #1551 from Hamlib/revert-1539-libgpiod
Revert "Refactoring GPIO push-to-talk logic to use libgpiod rather than the d…"
2024-05-12 14:37:50 -05:00
Michael Black efbe365701
Revert "Refactoring GPIO push-to-talk logic to use libgpiod rather than the d…" 2024-05-12 14:37:23 -05:00
Michael Black c06255d364
Merge pull request #1539 from aschuhardt/libgpiod
Refactoring GPIO push-to-talk logic to use libgpiod rather than the d…
2024-05-12 11:41:31 -05:00
Mike Black W9MDB 1988b7cf4f Update simelecraft.c 2024-05-11 17:31:38 -05:00
Mike Black W9MDB ee6b89d45b Fix currvfo warning message in kenwood.c 2024-05-11 17:30:10 -05:00
Mike Black W9MDB 3c4b1a83f8 Change IC7100 so x25x26 always and update icom.c to detect probably better 2024-05-11 12:51:25 -05:00
Mike Black W9MDB 37df9e93bd Add RIG_OP_TUNE to Elecraftc K2 -- update docs a bit 2024-05-11 07:55:32 -05:00
Mike Black W9MDB 2d30291caa Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-05-11 07:52:41 -05:00
Mike Black W9MDB 64a119367d Add RIG_OP_TUNE to Elecraft KX2 K3 KX3 K4 2024-05-11 07:52:11 -05:00
Mike Black W9MDB d71f7a9385 Add RIG_OP_TUNE to Elecraft K2 KX2 K3 KX3 K4 2024-05-11 07:42:20 -05:00
Mike Black W9MDB 09fbc4cb64 Restore Xiegu G90 x25/x26 command detection. Works find on Base 1.79 App 1.80
https://github.com/Hamlib/Hamlib/issues/1547
2024-05-09 17:09:40 -05:00
Christoph Nadig 8221961de2
Fix for setting power on Elecraft TRXs
(currently the power set is off by a factor of 10 if no PA is attached).
I also included a change to k3_max_power to take the current band into
account again. These values have changed in firmware upgrades in the
past but have been stable for quite a while now, so I think they should
be considered again.

Best Regards,
Chris, HB9ZHK
2024-05-08 15:56:56 -05:00
Mike Black W9MDB 02a5f70200 Update some things for G90 2024-05-07 16:47:32 -05:00
Mike Black W9MDB e9fa4de2ae Disable TARGETABLE for G90 due to firmware bug
https://github.com/Hamlib/Hamlib/issues/1547
2024-05-06 06:58:52 -05:00
Mike Black W9MDB fd69cb0487 Have icom rigs fallback to old get mode when x26 has beeen disabled
https://github.com/Hamlib/Hamlib/issues/1547
2024-05-06 06:35:40 -05:00
Mike Black W9MDB 85d9d8d62c Make ignoring morse handler more generic 2024-05-05 22:17:17 -05:00
Mike Black W9MDB fadf83a42c Update kenwood.h version 2024-05-05 17:28:29 -05:00
Mike Black W9MDB 95f2e9b546 Change Xeigu G90 to not use 0x25/x26 since it misbehaves on latest firmware and is not documented either 2024-05-05 17:19:22 -05:00
Mike Black W9MDB c2b8f2b4fe Improve SDRCONSOLE behavior 2024-05-05 16:03:50 -05:00
Mike Black W9MDB 42c900cb8a Fix default filter_width in icom.c 2024-05-04 22:57:25 -05:00
Mike Black W9MDB 9bcb4c4771 Fix micom set_freq to read ack back and get freq offsets 2024-05-04 17:36:02 -05:00
Mike Black W9MDB 44317e542b Make ft891 power level work like ft991 which supposedly is the same according to JA1NLX 2024-05-04 08:44:19 -05:00
Mike Black W9MDB 424a34c504 More work on micom get_freq 2024-05-03 17:16:25 -05:00
Mike Black W9MDB 74c96da18a Fix micom get_freq 2024-05-03 07:52:55 -05:00
Mike Black W9MDB cc9bb6f0b5 Another attempt at micom get/set freq 2024-05-02 08:20:02 -05:00
Mike Black W9MDB a5fa04f884 Add another flush to micom.c 2024-05-01 16:33:17 -05:00
Mike Black W9MDB 85f7886286 Another attempt at micom set_freq 2024-05-01 16:29:48 -05:00
Mike Black W9MDB baeb484ddf Change micom to odd parity 2024-05-01 08:34:01 -05:00
Mike Black W9MDB 4e600a9ed6 For Micom see if setting transmit freq is all we need -- setting Rx freq, then Tx isn't working 2024-04-30 22:41:06 -05:00
Mike Black W9MDB 8002d47050 Fix micom set_freq for correct checksum 2024-04-30 17:28:37 -05:00
Mike Black W9MDB 105c6b8d39 Add simmicom.c 2024-04-30 17:28:03 -05:00
Mike Black W9MDB d683955811 Fix set_freq for micom.c 2024-04-30 10:39:30 -05:00
Mike Black W9MDB e67c80f121 Add get_freq and set_freq for micom 2024-04-29 23:40:35 -05:00
Michael Black 594df4b31d
Merge pull request #1544 from N0NB/update_win_build_scripts
Sync local build scripts with main repository
2024-04-28 17:06:20 -05:00
Nate Bargmann 8f1b6851e7
Sync local build scripts with main repository
Updates for including libgcc* provided by MinGW in Debian 11 and Debian
12 (untested).

Include other updates added to the build virtual machine along the way.
2024-04-28 16:23:35 -05:00
Nate Bargmann c7635ee3b1
Merge pull request #1543 from N0NB/update_win_build_scripts
REALLY include README.md in archive
2024-04-28 15:49:15 -05:00
Nate Bargmann 94d753860b
REALLY include README.md in archive
Teach me not to test before committing and pushing...
2024-04-28 15:47:08 -05:00
Nate Bargmann 7b44297543
Merge pull request #1542 from N0NB/update_win_build_scripts
Distribute README.md instead of README
2024-04-28 15:36:03 -05:00
Nate Bargmann abee6a3cb9
Distribute README.md instead of README
README.md has replaced README as the main introductory file.
2024-04-28 15:31:16 -05:00
Mike Black W9MDB d47fb672c8 Fix serial port type for Micom 2024-04-28 11:44:05 -05:00
Mike Black W9MDB 2638eeb774 Fix ptt type for Micom 2/3 and change from Motorola to Micom 2024-04-28 11:33:23 -05:00
Mike Black W9MDB 92e82a25d2 Fix possible null argument in rig_test_2038 2024-04-26 17:35:18 -05:00
Mike Black W9MDB fe0d47acef Fix motorola Makefile.am 2024-04-24 12:33:14 -05:00
Mike Black W9MDB 86afa90739 Add Android.mk for motorola 2024-04-24 12:21:30 -05:00
Mike Black W9MDB 25f58afb72 Update motorola 2024-04-24 12:07:10 -05:00
Mike Black W9MDB d7e0b214f7 Add fake freq set/get for micom 2024-04-24 12:06:36 -05:00
Mike Black W9MDB e9a9424eed Adding motorola rig 2024-04-24 12:06:00 -05:00
Mike Black W9MDB 93bd44c3d5 Update simts890.c 2024-04-23 11:19:24 -05:00
Mike Black W9MDB b182ca2d51 Fix kachina set_ptt 2024-04-22 22:47:18 -05:00
Mike Black W9MDB 6a98b0b9cb Rest of commit -- if setting FM width to other than 7000/10000/15000 cache will show requested width until next poll
https://github.com/Hamlib/Hamlib/issues/1533
2024-04-22 17:48:59 -05:00
Mike Black W9MDB c70502ea34 Fix IC7300/9700 FM filter set -- now honors FM widths of 7000,10000, and 15000 2024-04-22 17:32:48 -05:00
Mike Black W9MDB f8a67d716e Some progress getting SB4100 to work
https://github.com/Hamlib/Hamlib/issues/1541
2024-04-22 11:27:29 -05:00
Mike Black W9MDB 2b27553155 Make rig_flush_force in rig.c timeout immediately
https://github.com/Hamlib/Hamlib/issues/1541
2024-04-22 11:26:57 -05:00
Mike Black W9MDB 08aac88377 Add set_ptt for kachina 505dsp 2024-04-20 15:09:09 -05:00
Mike Black W9MDB c31497918f Add VFO Ops to rigmatrix.c and colorize things a bit 2024-04-19 16:42:10 -05:00
Mike Black W9MDB d9b57bc7a8 Align dummy rigs 2024-04-19 16:41:37 -05:00
Mike Black W9MDB 90545a192e Hopefully fix Barrett 4100 protocol 2024-04-19 10:34:20 -05:00
Mike Black W9MDB dce80d264a Update FLRig version 2024-04-18 11:28:38 -05:00
Mike Black W9MDB 4c111da0d1 Add small delay when setting VFO in FLRig to allow GUI to catch up 2024-04-18 11:22:41 -05:00
Mike Black W9MDB d9b589d254 Fix unflushed data in get_lock 2024-04-18 11:22:25 -05:00
Mike Black W9MDB 95b0af114f Fix rigmatrix.c with new non-const rig_caps 2024-04-15 14:49:49 -05:00
Mike Black W9MDB 9e42ca2052 Add IC756 IC756PROII and IC756PROIII to execeptions on get/set_mode 2024-04-15 08:13:55 -05:00
Mike Black W9MDB 331143fa17 Change TS890 to use SF command for mode get/set 2024-04-13 22:50:38 -05:00
Mike Black W9MDB a6ad5f0928 Fix TS890 set_vfo in set_mode 2024-04-13 15:23:53 -05:00
Mike Black W9MDB b42aa75dd8 astyle kenwood.c 2024-04-13 07:36:02 -05:00
Mike Black W9MDB 6cfdb9d4ed Fix TS890 set_mode 2024-04-13 06:44:18 -05:00
Mike Black W9MDB bddd7e1a7d Fix github build for using libgpsd 2024-04-11 11:27:11 -05:00
Mike Black W9MDB 35b0bb086b Fix fortify warning in misc.c 2024-04-11 09:06:21 -05:00
Addison Schuhardt cf91e96333 Refactoring GPIO push-to-talk logic to use libgpiod rather than the deprecated/broken sysfs method.
TODO: I'm not familiar with autoconf to set up linking to libgpiod correctly, so I'd like to ask someone else to do that.
Fixes #1538
2024-04-11 00:17:15 -07:00
Mike Black W9MDB 0ba199448b Make TS890S behave like TS990S for mode on VFOB 2024-04-09 17:14:48 -05:00
Mike Black W9MDB 3dac2efb48 Update simts890.c 2024-04-06 15:42:46 -05:00
Mike Black W9MDB 63fa818fd7 Add PARM_AFIF_LAN and PARM_AFIF_ACC for IC-9700
Add PARM_WLAN for IC-705
Fix parm selection/printout for the AFIF labels
2024-04-04 08:21:23 -05:00
Mike Black W9MDB 878243aff3 Fix FLRig 'w' and 'W' command reply display 2024-04-04 07:53:06 -05:00
Michael Black 00ceb6e72f
Merge pull request #1537 from eli-schwartz/c99-porting
tests: fix compilation with modern compilers
2024-04-03 17:05:53 -05:00
Eli Schwartz 279362f403
tests: fix compilation with modern compilers
GCC 14 and clang 16, after 20+ years, finally enforce c99 language
requirements. Previously, to keep old code compiling, the use of K&R C
constructs was simply allowed despite the standard, and so users could
accidentally use those constructs without realizing it or being warned.

Now, the compiler fatally errors out when encountering the problematic
code. This can also be observed in older versions of the compiler by
using the following flags:

```
-Werror=implicit-function-declaration -Werror=implicit-int -Werror=int-conversion -Werror=incompatible-pointer-types
```

In hamlib's case, the use of a function without declaring it is illegal.
It's also a very simple fix though -- the standard header which declared
the stdlib exit() function was forgotten and never included. Simply add
the missing include, and make the source code automatically compliant.

Bug: https://bugs.gentoo.org/923108
2024-04-03 17:25:31 -04:00
Mike Black W9MDB 9a7dda25c8 w command now recognizes ; and 0xfd as valid endings for faster response instead of timeout
Stacking commands with w and W works e.g. FA;FB;
Still need to allow for hex values with simple form "xfe xfe...." instead of "\0xfe \0xfe..." -- more in-line with FLRig format
https://github.com/Hamlib/Hamlib/issues/1536
2024-04-02 16:26:27 -05:00
Mike Black W9MDB 41de3425d2 Fix hamlib_version in netrigctl_open and blank agc_levels from FLRig 2024-03-31 12:22:02 -05:00
Mike Black W9MDB a4cd6deb9d Update simic7000.c 2024-03-31 12:21:55 -05:00
Mike Black W9MDB de71976044 Fix CPU usage with rigctlcom in sleep.c
Hopefully doesn't affect other things too much
2024-03-30 23:40:59 -05:00
Mike Black W9MDB 59fca440a5 Fix rigctld CPU usage when client impolitely disconnects 2024-03-30 17:21:29 -05:00
Mike Black W9MDB 7b8f263b21 Reduce verbosity in netrigctl.c 2024-03-30 10:06:08 -05:00
Mike Black W9MDB 0353fdcae0 Reduce debug in flrig 2024-03-29 22:23:36 -05:00
Mike Black W9MDB e2b5a3bcb5 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-03-29 17:10:07 -05:00
Mike Black W9MDB 00dbd6a6df Fix rigctlcom.s IF command for CW Skimmer use and others that might use IF command 2024-03-29 17:09:38 -05:00
Michael Black ce4e9bfdf0
Merge pull request #1532 from GeoBaltz/rp8
More pointer conversions
2024-03-28 15:46:13 -05:00
George Baltz N3GB 9f997d799d Fix incorrect port read for elevation
Add missing port parameters for rotp2
Remove funky character(^B) from simrotorez.c so `file` and `more` think it
  is plain text.

Dunno if this works on the real H/W, but at least the simulator can get
  and set az/el position without errors.
2024-03-28 16:26:21 -04:00
Mike Black W9MDB 55d5f8b64a Really fix FLRig get_bwA return code 2024-03-26 16:59:57 -05:00
Mike Black W9MDB 0a0118b797 Fix FLrig get_bwA and get_bwB to return cached value if FLRig returns empty value 2024-03-26 16:25:20 -05:00
George Baltz N3GB 295ad74757 Add macros for amplifier and rotator state pointers. 2024-03-26 02:08:33 -04:00
George Baltz N3GB 2d0b8b807d Pointerize all state references in rigs/kenwood/* 2024-03-26 02:08:33 -04:00
George Baltz N3GB 4b436479d1 More pointers to state 2024-03-26 02:08:33 -04:00
George Baltz N3GB 406b947134 More pointers to state 2024-03-26 02:08:33 -04:00
George Baltz N3GB 53b01d829e Start converting rigs/* to use pointers to state 2024-03-26 02:08:33 -04:00
Mike Black W9MDB 896230beed Fix bandwidth set for FLRig 2024-03-25 22:26:58 -05:00
Mike Black W9MDB 8ebffd20b6 Fix get_vfo_info compatibility with Log4OM
https://github.com/Hamlib/Hamlib/issues/1531
2024-03-25 17:50:39 -05:00
Mike Black W9MDB dc375c6d00 Fix rig_get_split_vfo -- was almost always using cache 2024-03-25 14:46:26 -05:00
Mike Black W9MDB 624e00dcb4 Fix FLRig reading of bandwith when FIXED or "k" is read back 2024-03-25 11:29:18 -05:00
Mike Black W9MDB 31ea63b2f3 Fix IC7300 bandwidth reading for AM/BM ....still need to fix setting bandwidth for AM/FM 2024-03-25 10:23:40 -05:00
Mike Black W9MDB c3429084fb Allow FLRig to use "k" values for bandwidth 2024-03-25 10:22:48 -05:00
Michael Black 12ae80c0c5
Merge pull request #1529 from DJ3CE/k3kx3_swr
Add SWR get_level to K3 (KX3, KX2)
2024-03-24 22:36:03 -05:00
Cedric DJ3CE 7a7b52b89c Add SWR get_level to K3 (KX3, KX2)
Capabilities, level_gran and k3_get_level
2024-03-25 01:49:02 +01:00
Mike Black W9MDB 1881b2e206 Fix FT1000MP rig_set_freq to set cache 2024-03-23 11:52:26 -05:00
Mike Black W9MDB 1b3481ba95 Fix FT-1000MP get_freq 2024-03-23 09:57:35 -05:00
Mike Black W9MDB f51e7ef760 Add SDRConsole rig entry since TS-2000 is now hardware flow control by default 2024-03-23 08:46:56 -05:00
Mike Black W9MDB 2feb4cc65c Fix IC7700 get_mode_without_data 2024-03-21 17:04:37 -05:00
Mike Black W9MDB 538d41b9e8 Fix Xiegu X6100
https://github.com/Hamlib/Hamlib/issues/1499
2024-03-19 17:51:03 -05:00
Mike Black W9MDB 9331f9e5f4 Fix TS890S to not give an error for STRENGTH or WATTS but return 0 as appropriate 2024-03-19 16:19:52 -05:00
Mike Black W9MDB 68bcae6ee8 Some improvements on codan rigs 2024-03-18 17:24:07 -05:00
Mike Black W9MDB 1de9a5cede Fix compile warning on rig_debug messages
https://github.com/Hamlib/Hamlib/issues/1525
2024-03-17 09:01:58 -05:00
Mike Black W9MDB 0e572f631b Update simft897.c 2024-03-17 08:53:53 -05:00
Mike Black W9MDB 84d5f367f6 Fix compile warning on testrig.c 2024-03-15 22:51:19 -05:00
Mike Black W9MDB 6d257841a6 Fix some memory leaks in rigctl_parse.c 2024-03-15 16:46:14 -05:00
Mike Black W9MDB 8449ac3c43 Update simulators 2024-03-15 07:29:03 -05:00
Mike Black W9MDB 1045620313 Return error on bad read_icom_frame 2024-03-15 07:27:19 -05:00
Mike Black W9MDB b9e59f205e Fix compile error
https://github.com/Hamlib/Hamlib/issues/1524
2024-03-14 22:43:10 -05:00
Mike Black W9MDB 6220da1eaf Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-03-14 17:10:39 -05:00
Mike Black W9MDB f119f5976a Fix build warning
https://github.com/Hamlib/Hamlib/issues/1524
2024-03-14 17:10:23 -05:00
Mike Black W9MDB 96ec37a276 Fix build warning 2024-03-14 17:09:36 -05:00
Michael Black 789d863f97
Merge pull request #1523 from GeoBaltz/rp7
Convert all cache references to pointers
2024-03-10 09:04:26 -05:00
George Baltz N3GB c7665cb7d1 All struct rig_cache referenced converted to pointers. 2024-03-09 21:23:01 -05:00
George Baltz N3GB aa0d83df95 Use pointers for all cache references in rigs/* 2024-03-09 14:25:59 -05:00
George Baltz N3GB 609065775c Update some of rigs/* to use pointer to cache
Issue #536
2024-03-08 21:00:19 -05:00
Mike Black W9MDB 5ab1122139 Add freq_skip for use with rigs that do not have targetable VFO
Hopefully this allows them to work with gpredict.
However...setting frequency on TX/RX transition could take up to 1 second depending on gpredict polling rate.
https://github.com/Hamlib/Hamlib/issues/1493
2024-03-08 17:09:47 -06:00
Mike Black W9MDB 24135bd7d7 Fix compile error for MUTEX_CHECK when HAVE_PTHREAD is false 2024-03-08 16:55:33 -06:00
Mike Black W9MDB b358cdbd2e Fix usb_port.c to use new libusb format for pid:vid 2024-03-05 15:57:10 -06:00
Mike Black W9MDB f3b8330331 Update simft450.c 2024-03-05 07:24:44 -06:00
Mike Black W9MDB 6121197687 Fix spelling error in Makefile.am 2024-03-04 15:42:46 -06:00
Mike Black W9MDB 15a2b5a0dc Fix segfault on rigctl -m 2 -u
https://github.com/Hamlib/Hamlib/issues/1520
2024-03-04 12:23:00 -06:00
Mike Black W9MDB b9df1c7bda Add simft450.c 2024-03-04 08:38:00 -06:00
Mike Black W9MDB 4f3e40f3c6 Add simic910.c 2024-03-03 22:45:43 -06:00
Mike Black W9MDB bafb88432a Fix return value for rig_send_raw 2024-03-03 22:40:43 -06:00
Mike Black W9MDB 2212c47ad7 Update NEWS 2024-03-03 22:40:24 -06:00
Mike Black W9MDB f122f6422b Fix Icom switching to VFO mode when starting up in memory mode
https://github.com/Hamlib/Hamlib/issues/1431
2024-03-03 22:39:49 -06:00
Mike Black W9MDB 0868edbd65 Add simxiegux6100 2024-03-03 15:19:56 -06:00
Mike Black W9MDB dc38d19449 Slow freq events to 4 per second 2024-03-03 12:23:33 -06:00
Mike Black W9MDB c74b3c10c6 Add AM and AMD modes to flrig and bandwidth 2024-03-02 16:16:46 -06:00
Mike Black W9MDB a96a97ae3c Return 10,000 for bandwidth for Flrig when "FIXED" is returned 2024-03-02 15:58:41 -06:00
Mike Black W9MDB 7831dfc311 Icom async packets now work when ci-v echo is on.
async packets are handled individually and not flushed anymore
2024-03-01 16:41:44 -06:00
Mike Black W9MDB bb9b1f1783 Fix some printf problems for mingw64 2024-03-01 15:41:47 -06:00
Mike Black W9MDB 12404aa8a6 Ignore ICOM transceive frames 2024-03-01 12:56:20 -06:00
Michael Black cef2525d0f
Merge pull request #1522 from GeoBaltz/rp6
Convert all port references to pointers
2024-03-01 11:45:44 -06:00
George Baltz N3GB 728db84c0c Finish tests/* 2024-03-01 12:27:26 -05:00
George Baltz N3GB 07f8023d17 Convert tests/* to pointers 2024-03-01 12:27:26 -05:00
George Baltz N3GB 55db73894f Add STATE to the list of pointers
Definitely a long term item.
2024-03-01 12:27:26 -05:00
Mike Black W9MDB 0fdc78c604 Update github actions 2024-03-01 10:11:06 -06:00
Mike Black W9MDB 0f74a23b14 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-03-01 09:43:26 -06:00
Mike Black W9MDB 7f02c35562 Add CONTRIBUTING.md 2024-03-01 08:31:31 -06:00
Michael Black a8f7da8fc4
Create CODE_OF_CONDUCT.md 2024-03-01 08:22:03 -06:00
Mike Black W9MDB c15f5b0da0 Update codeql for deprecated items 2024-03-01 08:16:57 -06:00
Mike Black W9MDB c6371a14a1 Fix 'G' command vfo_ops
https://github.com/Hamlib/Hamlib/issues/1518
2024-02-29 22:37:16 -06:00
Mike Black W9MDB 65d2023b95 Allow FT1000MP to set vfoA when MEM is active 2024-02-29 15:55:42 -06:00
Mike Black W9MDB c68ef118e9 Add mutex for rig_send_morse and when locked use cache
for rig_get_freq, rig_get_mode, rig_get_vfo, and rig_get_split_vfo
Might need to add more down the road
https://github.com/Hamlib/Hamlib/issues/1514
2024-02-28 23:04:47 -06:00
Mike Black W9MDB 25ee5d65d5 Fix rigctld vfo_ops
https://github.com/Hamlib/Hamlib/issues/1518
2024-02-28 17:30:41 -06:00
Mike Black W9MDB eaae02ef00 Update simdft1000.c 2024-02-28 17:24:21 -06:00
Mike Black W9MDB 45db5d32c3 Remove debug for rig_strparm to reduce verbosity 2024-02-28 17:23:46 -06:00
Mike Black W9MDB 7bda13f0e0 Fix ft1000d.c get_freq for current vfo
Fix ft1000mp.c get_freq to use cached value
2024-02-28 15:09:02 -06:00
Mike Black W9MDB b65997a249 astyle netrigctl.c 2024-02-26 07:36:25 -06:00
Mike Black W9MDB 7ee8c358cd Fix mingw 64-bit and another attempt for 32-bit
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-24 12:08:26 -06:00
Mike Black W9MDB 5f92b19ef4 Revert "Sync github"
This reverts commit 5089949f10.
2024-02-24 11:10:41 -06:00
Mike Black W9MDB 5089949f10 Sync github 2024-02-24 11:09:54 -06:00
Mike Black W9MDB 83f5655a9f Fix PKTAM in kenwood.c
https://github.com/Hamlib/Hamlib/issues/1502
2024-02-24 06:51:32 -06:00
Mike Black W9MDB 1b2f6a84f7 Add USB-D1/D2/D3 LSB-D1/D2/D3 to new modes and Flrig
https://github.com/Hamlib/Hamlib/issues/1502
2024-02-23 12:27:55 -06:00
Mike Black W9MDB 9f87279b0b Update simts990.c 2024-02-22 09:23:25 -06:00
Mike Black W9MDB c1f8b091ab Update simts990.c to work with FLRig 2024-02-22 08:02:41 -06:00
Michael Black 3967e41fcf
Merge pull request #1513 from GeoBaltz/rp5
Convert amplifiers/ and rotators/ to use pointers
2024-02-22 08:00:15 -06:00
Mike Black W9MDB 2849a75676 Another attempt to fix 32-bit mingw build for 2038
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-21 17:24:15 -06:00
Mike Black W9MDB fff8e83c11 Add simxeigux6100.c 2024-02-20 12:07:30 -06:00
Mike Black W9MDB c23948c8f4 Update simxiegug90.c 2024-02-20 12:06:34 -06:00
Mike Black W9MDB 911692c715 Remove some debug from rigctlcom.c 2024-02-20 12:05:51 -06:00
Mike Black W9MDB db6dc92513 Fix left shift warning 2024-02-19 16:33:13 -06:00
George Baltz N3GB 8ff07c47f9 Finish rotators/ 2024-02-19 13:06:53 -05:00
George Baltz N3GB f247ee2088 Convert first part of rotators/ 2024-02-19 13:06:53 -05:00
George Baltz N3GB 878117ab1f Convert all port references in amplifiers/ to pointers. 2024-02-19 13:06:53 -05:00
Mike Black W9MDB 8cc6ce1319 Fix rigctlcom.c for Icom rigs and those that don't have get_vfo 2024-02-19 11:46:16 -06:00
Mike Black W9MDB 91ec3afcda Fix get_vfo for Icom rigs in rigctlcom.c 2024-02-19 10:42:25 -06:00
Mike Black W9MDB 1657a0e673 Fix rigctlcom.c 2024-02-19 10:34:15 -06:00
Mike Black W9MDB 81dae00ea0 Fix ID read for Xiegu rigs and add x25x26 possible
https://github.com/Hamlib/Hamlib/issues/1499
2024-02-18 22:25:19 -06:00
Mike Black W9MDB 0902b32c45 Remove debug statement causing warning on mingw64 2024-02-16 17:05:07 -06:00
Mike Black W9MDB 34d8b0eec3 Update simts590.c 2024-02-16 09:17:50 -06:00
Mike Black W9MDB 1ea597b6e1 Move time_t test later so 32-bit check of 64-bit functions can work
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-15 09:25:39 -06:00
Mike Black W9MDB 4cadea95f8 Astyle cal.c 2024-02-15 09:25:27 -06:00
Mike Black W9MDB 7caef5398e Return exact value for rig_raw2val when appropriate 2024-02-15 09:24:58 -06:00
Mike Black W9MDB 5d83ac767b Update SDRUno information 2024-02-15 09:08:42 -06:00
Mike Black W9MDB c471884122 Fix TS590 and TS890 RIG_LEVEL_RFPOWER_METER_WATTS 2024-02-14 16:35:34 -06:00
Mike Black W9MDB 47fcf999f0 Reduce debug error level for rig_test_2038 2024-02-14 08:59:52 -06:00
Mike Black W9MDB f12d653f6c Try to fix MINGW time_t
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-14 07:55:42 -06:00
Mike Black W9MDB e1f2342982 Promote all BETA to STABLE
Promot all ALPHA to BETA
2024-02-14 07:11:20 -06:00
Mike Black W9MDB 972d792a4f Round watt values to whole number >= 10 and 1 decimal place < 10 2024-02-13 16:39:59 -06:00
Michael Black 2b22a42e73
Merge pull request #1511 from GeoBaltz/fix11
Clean up ts890.c & simts890.c
2024-02-13 16:15:23 -06:00
George Baltz N3GB 45e097d3a4 Update simts890.c
Make IF return RX/TX status
Document IF data, reformat IF & SF commands
2024-02-13 13:11:24 -05:00
George Baltz N3GB 59aaf1f4c3 Minor cleanup of ts890.c
Simplify out-of-range check
Mute possible cppcheck squawk
Round power to whole watts
2024-02-13 13:11:24 -05:00
Mike Black W9MDB 59217b560a Add 2038 test for MINGW __time64_t 2024-02-13 11:17:09 -06:00
Mike Black W9MDB 8d33869ca2 Show glibs version if available for 2038 test
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-12 10:48:07 -06:00
Mike Black W9MDB a8cfff8bd3 Try adding _TIME_BITS=64 to see if 32-bit build works with it
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-11 15:57:10 -06:00
Mike Black W9MDB 916049b0a5 Icom rigs can now use filter_usbd, filter_cw, and filter_usb set-conf options to set filter for USBD/LSBD, USB/LSB, and CW/CWR modes
e.g. --set-conf=filter_usbd=2,filter_cw=1,filter_usb=3
https://github.com/Hamlib/Hamlib/issues/1507
2024-02-11 12:23:24 -06:00
Mike Black W9MDB 6844722faa Add libusb version info to find_and_open_device 2024-02-11 08:02:33 -06:00
Mike Black W9MDB f5d6be3b3e Fix a dependency check for bindings 2024-02-08 09:59:52 -06:00
Mike Black W9MDB 59e4ba1cdc Add TIME_BITS debug 2024-02-07 12:27:12 -06:00
Mike Black W9MDB 64c470a4e7 Make hamlib_settings error show the real error 2024-02-05 15:00:26 -06:00
Michael Black 3dd8c97b54
Merge pull request #1508 from GeoBaltz/rp4
Convert all rigs/*/*.c to use pointers for ports
2024-02-05 11:10:56 -06:00
George Baltz N3GB e26e6cd7f2 Convert rigs/yaesu
No more code references to raw port structures in rigs/*
2024-02-05 11:28:31 -05:00
George Baltz N3GB 12552bff64 Do rigs/tuner/, rigs/uniden/, rigs/winradio/ & rigs/wj/
This leaves only rigs/yaesu
2024-02-05 11:28:31 -05:00
George Baltz N3GB a2abc25416 Convert rigs/mds/, rigs/skanti/, rigs/tapr/ and rigs/tentec/ 2024-02-05 11:28:31 -05:00
George Baltz N3GB eb94ce2b94 Convert rigs/loew/, rigs/pcr/, rigs/prm80/, rigs/racal/ and rigs/rs/ 2024-02-05 11:28:31 -05:00
George Baltz N3GB 464eea58e7 Convert rigs/icom/, rigs/kit/ 2024-02-05 11:28:31 -05:00
George Baltz N3GB c7ab5c44af Convert rigs/flexradio, rigs/gomspace, rigs/jrc, rigs/kachina 2024-02-05 11:28:31 -05:00
George Baltz N3GB 1e552b557f Convert rigs/dummy/ 2024-02-05 11:28:31 -05:00
George Baltz N3GB f777179bc8 Convert rigs/dorji, rigs/drake, rigs/elad. 2024-02-05 11:28:31 -05:00
George Baltz N3GB 23d5d53248 Port rigs/anytone/, rigs/barrett/ and rigs/codan/
Fixup git rebase SMerge error.
2024-02-05 11:28:31 -05:00
George Baltz N3GB 02f0ad067a Start converting rigs/*
This commit does rigs/adat/, rigs/alinco/ and rigs/aor/.
2024-02-05 11:28:31 -05:00
George Baltz N3GB 4a1fa678ea Play catchup with split/VFO revision.
Fix typos in rebase fixups.
2024-02-05 11:28:30 -05:00
George Baltz N3GB b1d85e5aa1 Update dcdport usage in tests/*.c
Issue #1445
2024-02-05 11:28:30 -05:00
George Baltz N3GB 1532a7d8dc Convert rot_conf.c and amp_conf.c to pointers
Consolidate some assignments to make deprecation easier.
Issues #1445, #487
2024-02-05 11:28:30 -05:00
George Baltz N3GB 3eb41c6400 Cache pointers for src/rig.c
Issue #1420 again.
2024-02-05 11:28:30 -05:00
George Baltz N3GB 96ee58436a Convert a few more cache pointers
More of issue #1420
2024-02-05 11:28:30 -05:00
George Baltz N3GB bf8bf51bf4 Convert some cache references to pointers
Affects issue #1420
2024-02-05 11:28:30 -05:00
Mike Black W9MDB 6bfccb3e92 Add filternum option for Icom rigs so WJST-X can use hamlib_settings.json to set default filter
https://github.com/Hamlib/Hamlib/issues/1507
2024-02-04 16:53:41 -06:00
Mike Black W9MDB d42d505d22 Icom rigs will now recognize the current even if the user is twiddling buttons
https://github.com/Hamlib/Hamlib/issues/1507
2024-02-04 15:56:34 -06:00
Mike Black W9MDB 1093349564 Fix TIME_BITS_64 2024-02-03 23:35:56 -06:00
Mike Black W9MDB d77b0df702 Fix Icom rigs filter -- mode set will now keep the same filter as currently set 2024-02-03 23:29:09 -06:00
Mike Black W9MDB 8757271437 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-02-03 23:26:58 -06:00
Mike Black W9MDB ab8835e87e See if _TIME_BITS_64 works on 32-bit bit builds to fix 2038 problem.
https://github.com/Hamlib/Hamlib/issues/1478
2024-02-03 23:24:07 -06:00
Mike Black W9MDB 9bfb0f5f71 Fix bandlist nullification 2024-02-03 23:23:25 -06:00
Michael Black dab7cf1ee6
Merge pull request #1506 from GeoBaltz/fix10
Fix icom_set_powerstat() to correctly save&restore rp->retry, rp->tim…
2024-02-03 16:45:39 -06:00
George Baltz N3GB 904dfef9b9 Fix icom_set_powerstat() to correctly save&restore rp->retry, rp->timeout_retry
Also convert icom.c to pointer use.
2024-02-03 15:46:11 -05:00
Mike Black W9MDB 0adaebd100 Update comment in rig.h 2024-02-03 12:44:48 -06:00
Mike Black W9MDB 09a9075844 Fix Yaesu BANDSELECT
Rigs must have the bands listed in the backend to work properly
https://github.com/Hamlib/Hamlib/issues/1504
2024-02-03 12:40:58 -06:00
Mike Black W9MDB ade62105a3 Don't set bandwidth on TS590 when RIG_PASSBAND_NOCHANGE is the width
https://github.com/Hamlib/Hamlib/issues/1505
2024-02-03 11:05:12 -06:00
Mike Black W9MDB cff4faba53 Update rigctl.1 2024-02-02 15:54:29 -06:00
Michael Black 697c090935
Merge pull request #1501 from GeoBaltz/fix9
Add calibration table for RFPOWER_METER_WATTS in ts890.c
2024-02-01 16:50:48 -06:00
George Baltz N3GB b6dc6110a6 Bring simts890.c a little closer to the real thing
Still needs more work.
2024-02-01 17:34:47 -05:00
George Baltz N3GB 4ef5bd4142 Add calibration table for TS-890S RFPOWER_METER_WATTS
Make sure we only get RFPOWER_WATTS during xmit, and STRENGTH during receive; else return -RIG_ENAVAIL.
2024-02-01 17:34:47 -05:00
Mike Black W9MDB a03a79c864 Add tone_enable in more places to cover all set_split_freq cases 2024-02-01 15:48:01 -06:00
Mike Black W9MDB 7436e4395f Add FUNC_TONE tone_enable to icom_set_split_freq too 2024-02-01 15:41:36 -06:00
Mike Black W9MDB 7310f370c1 IC705 remove get_powerstat -- doesn't work
Icom do not get width for FM or FMN -- doesn't work
Add tone_enable option to overcome bug in IC-705 where changing freq turns off TONE
2024-02-01 15:35:19 -06:00
Mike Black W9MDB d9bae6f46f Add simxiegux108g 2024-02-01 12:39:07 -06:00
Mike Black W9MDB 434f399d12 Update simulators 2024-02-01 12:38:12 -06:00
Mike Black W9MDB 68fca2c73d Some more places where band_index needs updating 2024-01-31 17:43:10 -06:00
Mike Black W9MDB 75a4d324de Update band_index in newcat.c when BS is executed 2024-01-31 17:39:49 -06:00
Mike Black W9MDB c969405c26 Fix rigctlsync for FT991
2efc2069f5 (commitcomment-138121815)
2024-01-31 17:30:36 -06:00
Michael Black 2707863209
Merge pull request #1498 from GeoBaltz/fix8
Make simulator match the Real World(TM)
2024-01-31 16:38:26 -06:00
George Baltz N3GB 35e49ffdfc Make simulator match the Real World(TM)
Add missing P4
Repair RIG_LEVEL_STRENGTH
2024-01-31 12:37:14 -05:00
Mike Black W9MDB 4fe6ea7cc4 Remove unused variables 2024-01-31 10:32:00 -06:00
Mike Black W9MDB fff1bbc8cd Add RFPOWER_METER_WATTS to TS890
https://github.com/Hamlib/Hamlib/issues/1497
2024-01-31 10:29:46 -06:00
Mike Black W9MDB b4ec8a427c Fix return value in test_2038
https://github.com/Hamlib/Hamlib/issues/1492
2024-01-30 11:02:05 -06:00
Michael Black 25a8d65860
Merge pull request #1495 from wvolz/flex6k-add-rfpower
flex6xxx Add get and set RFPOWER level capability
2024-01-30 06:47:26 -06:00
Warren Volz 1ea95c94ee flex6xxx add ability to set rfpower level 2024-01-29 23:22:47 -07:00
Warren Volz 9f6ca84572 flex6xxx add rfpower level 2024-01-29 16:37:58 -07:00
Mike Black W9MDB 8d59c9302f Change test_2038 routine to return error on time_t size==4
Seems ctime might be seg faulting on the test
https://github.com/Hamlib/Hamlib/issues/1492
2024-01-29 07:52:56 -06:00
Mike Black W9MDB 793bc1a0dc Update simic9700.c 2024-01-28 12:56:01 -06:00
Mike Black W9MDB d29caa7cad Add debug and null check to test_2038 to see if it solves 32-bit segfault
https://github.com/Hamlib/Hamlib/issues/1492
2024-01-28 09:46:09 -06:00
Mike Black W9MDB 267f30d16b Fix compile warning in rig.c 2024-01-28 09:44:41 -06:00
Mike Black W9MDB 6ef2c457e4 Update newcat.c date 2024-01-27 22:22:34 -06:00
Mike Black W9MDB 2efc2069f5 FT-991 now uses BS band select when setting frequencies
This allows band memory to recall information -- in particular the tune function
Works in both split and non-split mode
https://github.com/Hamlib/Hamlib/issues/1490
2024-01-27 16:08:38 -06:00
Mike Black W9MDB 703d86a025 Add example of band_changed.c 2024-01-27 07:31:01 -06:00
Mike Black W9MDB c8e33010f6 Fix 12M band for rig_get_band 2024-01-26 16:58:51 -06:00
Mike Black W9MDB 7fba4c012d Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-01-26 15:41:28 -06:00
Michael Black 10c002c13f
Merge pull request #1488 from GeoBaltz/rp3
Update NEWS with pointer conversion macros.
2024-01-26 15:19:44 -06:00
George Baltz N3GB a0f8251b64 Update NEWS with pointer conversion macros. 2024-01-26 14:23:30 -05:00
Mike Black W9MDB 9ed13add01 Update test2038.c
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-24 16:13:54 -06:00
Mike Black W9MDB fabfe61a45 Add rig_test_2038 to rig_init so it will show on all systems
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-24 15:48:05 -06:00
Mike Black W9MDB d8a9968fac Add test2038.sh to clean 2024-01-24 12:19:38 -06:00
Mike Black W9MDB 1b5fbc1d8b Add 2038 test during build -- make check will fail is there is a 2038 problem
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-24 10:45:32 -06:00
Mike Black W9MDB a4ff5a3e60 Update simftdx101.c 2024-01-23 15:52:59 -06:00
Mike Black W9MDB 83fa835864 Update simft991.c 2024-01-23 15:52:32 -06:00
Michael Black ceebaeae35
Merge pull request #1486 from GeoBaltz/oops3
FIx more paste errors.
2024-01-23 15:46:05 -06:00
George Baltz N3GB 0145588fd9 Drat. Fix more copy/paste SNAFUs 2024-01-23 12:40:49 -05:00
Michael Black 17b9321310
Merge pull request #1485 from GeoBaltz/ctcss
CTCSS/TONE functions for TS-890S
2024-01-23 10:36:01 -06:00
George Baltz N3GB 75079d40a8 Add remaining rigs, matching old behavior.
Fix copy/paste foulup.
2024-01-23 09:55:35 -05:00
George Baltz N3GB 5ad803d90c Add funcs to set/clear TONE/CTCSS modes for TS-890S 2024-01-23 09:55:35 -05:00
George Baltz N3GB e42bb719b9 Fix off by one error in tones for TS-590/890/990
Fix some rigs I found docs for - more needed
2024-01-23 09:55:35 -05:00
George Baltz N3GB a703c77c2d Implement ctcss tone for TS-890S. 2024-01-23 09:55:35 -05:00
Mike Black W9MDB 74b0752898 Add Guohe Q900
https://github.com/Hamlib/Hamlib/issues/1483
2024-01-22 16:34:18 -06:00
Mike Black W9MDB a52d0c5931 map token_t to hamlib_token_t for API backwards compatility
https://github.com/Hamlib/Hamlib/issues/1469
2024-01-22 11:48:06 -06:00
Mike Black W9MDB efeba2dfe0 Fix some more hamlib_token_t
https://github.com/Hamlib/Hamlib/issues/1469
2024-01-22 10:50:30 -06:00
Mike Black W9MDB 75cf467c1d Change to hamlib_token_t in swg files
05033171c3 (commitcomment-137562136)
2024-01-22 09:31:50 -06:00
Mike Black W9MDB 1bb469f90f More token_t changes
https://github.com/Hamlib/Hamlib/issues/1469
2024-01-21 23:33:19 -06:00
Mike Black W9MDB 354606f46d Comment out __TIMESIZE check as mingw64 thinks it is not 64 bits -- so we may not need this
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-21 23:31:11 -06:00
Mike Black W9MDB 046f3b849c Fix mingw build
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-21 23:28:41 -06:00
Mike Black W9MDB 05033171c3 Change token_t to hamlib_token_t to avoid collsions with libbsm and others
https://github.com/Hamlib/Hamlib/issues/1469
2024-01-21 23:11:55 -06:00
Mike Black W9MDB 67aee82133 Add compile-time warning if __TIMESIZE != 64
https://github.com/Hamlib/Hamlib/issues/1478
2024-01-21 22:39:57 -06:00
Mike Black W9MDB e62dcd0b4a Merge branch 'master' of https://github.com/Hamlib/Hamlib 2024-01-21 16:40:54 -06:00
Mike Black W9MDB 2cc68f4773 Fix compilation for mingw DLL 2024-01-21 16:38:19 -06:00
Michael Black c4733d9dc3
Merge pull request #1482 from mikaelnousiainen/update-news-for-vfo-and-split-changes
Update NEWS for split/VFO handling changes
2024-01-21 16:13:04 -06:00
Mikael Nousiainen 66218e57f7 Update NEWS for split/VFO handling changes 2024-01-22 00:10:42 +02:00
Mike Black W9MDB e4e12f3ce7 Fix testcache.c for new behavior 2024-01-21 14:41:25 -06:00
Michael Black 1dfd17cc18
Merge pull request #1481 from mikaelnousiainen/streamline-vfo-targeting-and-split-functionality
Streamline VFO targeting and split functionality
2024-01-21 14:24:48 -06:00
Mikael Nousiainen 8bb5bcefb9 Merge upstream and fix conflicts 2024-01-21 20:59:54 +02:00
Mike Black W9MDB 7d0c737e96 Fix Icom startup with poweron
https://github.com/Hamlib/Hamlib/issues/1480
2024-01-21 11:39:07 -06:00
Mike Black W9MDB 77aa5ddb55 Revert FT991 change 2024-01-20 22:29:41 -06:00
Mike Black W9MDB eff0c7b636 Add SY command validation
remove FT991 from vfo adjustment
2024-01-20 10:15:18 -06:00
Mikael Nousiainen 4b3a7514ca Merge upstream and fix conflicts 2024-01-20 13:08:29 +02:00
Mike Black W9MDB d391773622 Ensure transmit vfo is used for rig split 2024-01-19 16:44:04 -06:00
Mike Black W9MDB 761f1d3b00 Add rest of RIG_FUNC_SYNC changes 2024-01-18 09:18:49 -06:00
Mike Black W9MDB 48d3f3f750 Add RIG_FUNC_SYNC -- only for FTDX101D/MP right now. 2024-01-18 07:56:30 -06:00
Mike Black W9MDB aec9348138 Add rig_band_changes to HAMLIB API 2024-01-18 07:39:56 -06:00
Mike Black W9MDB df64af4583 Suppress no get_vfo message for Icom rigs.
No hope of getting Icom to ever provide this ability
2024-01-15 11:18:46 -06:00
Mike Black W9MDB 0e5d2cfc48 Fix tx_vfo default in rig.c 2024-01-15 07:33:21 -06:00
Mike Black W9MDB 4d568c782e Speed up rig_band_changed actions for FT991 and perhaps others
Putting the AC001; command immediately after FA freq change make the band change end state occur immediately
2024-01-15 07:28:22 -06:00
Mikael Nousiainen eb7634abfb Merge upstream changes and fix conflicts 2024-01-15 09:24:17 +02:00
Mike Black W9MDB d6689145a0 Make rig_band_changed HAMLIB_API 2024-01-14 23:06:41 -06:00
Michael Black 34ccdcc5a5
Merge pull request #1476 from GeoBaltz/rp2
Phase 2 of moving port structures
2024-01-14 22:24:48 -06:00
George Baltz N3GB f15679f575 Update example.c
Avoid using raw rigport, in two different ways.
Fix variable name.
2024-01-14 18:13:05 -05:00
George Baltz N3GB 7f67363687 Need more parens to work in expressions.
Clean up sticky note items.
2024-01-14 18:13:05 -05:00
George Baltz N3GB 64f69421de Pointerize all the ports in src/rig.c 2024-01-14 18:13:05 -05:00
George Baltz N3GB aa9c3b39ba Convert more files in src/
Leaves only src/rig.c
2024-01-14 18:13:05 -05:00
George Baltz N3GB fddddf1f6f Port conf.c to use access macros
This will need to copy to all deprecated port structures, when the time comes.
2024-01-14 18:13:05 -05:00
George Baltz N3GB 2c85a96309 Add function to get rotator port address(es)
Add ROTPORT2 definitions.
Convert src/rotator.c to use new access.
2024-01-14 18:13:05 -05:00
George Baltz N3GB b0d1eb297f Function to get amplifier port address
Convert src/amplifier.c to new MACROs/access method.
2024-01-14 18:13:05 -05:00
George Baltz N3GB cd1f4d3929 Implement function to get structure address
Add AMPPORT and ROTPORT macros
2024-01-14 18:13:05 -05:00
George Baltz N3GB e178a984ca Add cache to the MACRO/porting list
Update comments
And port my favorite PoC target, rigs/kenwood/kenwood.c
2024-01-14 18:13:05 -05:00
Mike Black W9MDB 0b67958751 Add x25cmdfails and x26cmdfails to ic7700.c 2024-01-14 14:35:55 -06:00
Mike Black W9MDB 4b03abbdac Remove static from band_changed.c 2024-01-14 08:47:10 -06:00
Mike Black W9MDB 11b5da8782 Fix RIG_MODEL in tmd710.c 2024-01-13 17:38:23 -06:00
Mike Black W9MDB 190747430f Add 4100.c 2024-01-13 11:49:57 -06:00
Mike Black W9MDB f8fd79442d Add Barrett 4100 2024-01-13 11:47:13 -06:00
Mike Black W9MDB 34f953ba0b Change debug statements to use spaces() function 2024-01-13 08:27:37 -06:00
Mike Black W9MDB 9b817f325d Add --skipinit to rigctl.c -- can speed up single command-line invocations by quite a bit 2024-01-13 08:26:44 -06:00
Mike Black W9MDB dc0fd2955d Add simtmc710 to Makefile.am 2024-01-13 08:25:57 -06:00
Mike Black W9MDB 89876895de Remove Error message from simxiegug90.c 2024-01-13 08:25:24 -06:00
Mike Black W9MDB 79c496800e Add simtmd710 2024-01-13 08:24:39 -06:00
Mike Black W9MDB a6951c8e14 Change debug indentation to use "*" to make more visible 2024-01-13 08:23:01 -06:00
Michael Black 2646f0fd3a
Merge pull request #1455 from GeoBaltz/rp
Basic definitions and first steps for making port tables addressed by pointers
2024-01-13 08:09:34 -06:00
Mike Black W9MDB 8280748ace Fix KY message length
Add "AC" recognition with "AC;" validation
2024-01-13 06:36:59 -06:00
Mike Black W9MDB 32ed2c4d91 Add debug for stopbits in serial_setup 2024-01-11 08:12:07 -06:00
Mike Black W9MDB ac054e9f75 Fix error check in rig_bandselect 2024-01-11 07:15:19 -06:00
Mike Black W9MDB 05fb4389f7 Fix segfault in rig_bandselect 2024-01-11 07:03:16 -06:00
Mike Black W9MDB e25fab7d2f Add band_changed to rig.c 2024-01-10 11:25:44 -06:00
Mike Black W9MDB ddb0a64272 Reduce debug level for band changing 2024-01-10 09:48:01 -06:00
Mike Black W9MDB 47062cf812 Fix mingw compile warning on ts590.c 2024-01-10 09:45:40 -06:00
Mike Black W9MDB 7002ca9f09 Add band_change.c to Makefile.am 2024-01-10 08:32:35 -06:00
Mike Black W9MDB a7d2a5e32b Seperate rig_band_changed into it's own file included from rig.c 2024-01-10 08:21:18 -06:00
Mike Black W9MDB 2709fb8ab9 Add rig_band_changed function for customization of rig actions on each band
This takes user action to customize during build right now.
2024-01-10 07:28:17 -06:00
Mike Black W9MDB e610d3b691 astyle rig.c 2024-01-10 06:38:37 -06:00
Mike Black W9MDB cb74453f06 Fix Doppler detection false alarm for WSJT-X's 55 Hz test 2024-01-10 06:37:46 -06:00
Mike Black W9MDB 5e59a555d8 Fix TS590 get/set_mode for bandwiths for all and FM mode which doesn't map well for this
https://github.com/Hamlib/Hamlib/issues/1472
2024-01-09 12:49:44 -06:00
Mike Black W9MDB df78960ff1 Revert "Change FTDX10 handshake to None instead of Hardware"
This reverts commit aeb2692b42.

Testing another DX10 shows hardware handshake is needed.
Perhaps when using only a 3-wire serial port it still works with no handshake
2024-01-08 12:06:20 -06:00
Mike Black W9MDB 21c14da270 Add DL2MAN (tr)uSDX rig
Copy of TS480 for starters and needs refinement
2024-01-07 22:38:52 -06:00
Mike Black W9MDB e9e43e23da Remove readonly references to caps structure since it is R/W now 2024-01-07 11:55:20 -06:00
Mike Black W9MDB eab660500e Suppress UDP packet error when errno==0
https://github.com/Hamlib/Hamlib/issues/1461
2024-01-06 16:12:48 -06:00
Mike Black W9MDB 2eefb14137 Fix LVL granulatiry in ts590.c again 2024-01-05 16:34:03 -06:00
Mike Black W9MDB 890d1a69aa Fix granularity in ts590.c 2024-01-05 16:26:45 -06:00
Mike Black W9MDB 47f92eb5f7 Improved Kenwood USB_AF and USB_AF_INPUT level to make it more symmetrical
Values can now be enter in signal digits .1 .2 .3 .4 .5 .6 .7 .8, .9 and higher is max value
2024-01-04 12:25:38 -06:00
Mikael Nousiainen 051e671bfa Merge upstream changes and fix conflicts. Use snprintf() in most sprintflst.c functions to avoid buffer overflows. 2024-01-04 10:43:15 +02:00
Mikael Nousiainen 2358cba6a4 Fix issues with Dummy rig VFOs. Fix Yaesu ST split command. 2024-01-04 10:13:43 +02:00
Michael Black 5980eb3cc7
Merge pull request #1470 from GeoBaltz/fix7
Fix copy/paste errors in rigs/icom/
2024-01-03 22:10:06 -06:00
George Baltz N3GB bb1590ed9c More typos/copy/paste errors in rigs/icom 2024-01-03 21:13:42 -05:00
George Baltz N3GB 64d606c1c4 Fix copy/paste errors in xiegu.c 2024-01-03 21:00:36 -05:00
Mike Black W9MDB 921def7c5f Show Xeigu Radio ID during g90_open
https://github.com/Hamlib/Hamlib/issues/909
2024-01-03 16:56:10 -06:00
Mike Black W9MDB 9877387c55 Force split off for Yaesu rigs with 60m_exception since split cannot operate in memory mode 2023-12-30 08:18:44 -06:00
Mike Black W9MDB bd746387f9 Fix set_ant and get_ant for rigctl -m 2 dump_caps
https://github.com/Hamlib/Hamlib/issues/1466
2023-12-29 15:59:34 -06:00
Mike Black W9MDB 65bd022a2c Fix BAND_SELECT segfault on dumpcaps
https://github.com/Hamlib/Hamlib/issues/1467
2023-12-29 15:41:05 -06:00
Mike Black W9MDB c019467987 Ignore set_split for Yaesu 60M exception rigs
Cannot do split in memory modey
2023-12-28 12:11:31 -06:00
Mike Black W9MDB 19c4b01e5a Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-12-28 11:52:24 -06:00
Mike Black W9MDB 5492572176 Add FTDX10 to 860M exception 2023-12-28 11:51:56 -06:00
Michael Black 0c1f66710a
Merge pull request #1464 from zcsahok/minor_man_fix
Minor man page fix
2023-12-28 06:37:23 -06:00
zcsahok 5d0cbba91e Minor man page fix 2023-12-28 12:18:02 +00:00
Mike Black W9MDB a4fa021848 Update kenwood.c for THETIS 2023-12-27 11:58:40 -06:00
Mike Black W9MDB bc2f2ce5c7 Enable set_ptt for IC703 2023-12-27 10:25:48 -06:00
Mike Black W9MDB da478d6e74 Add THETIS to flex.c 2023-12-26 22:46:38 -06:00
Mike Black W9MDB 02a6c80800 Fix RIG_IS_THETIS in kenwood.c to match RIG_IS_POWERSDR 2023-12-26 22:36:55 -06:00
Mike Black W9MDB 08ba518b71 Change network.s to allow MacOS compilation for is_networked
https://github.com/Hamlib/Hamlib/issues/1463
2023-12-26 06:40:11 -06:00
Mike Black W9MDB 32f37d390f Allow mulitcast receiver to continue after error==0
https://github.com/Hamlib/Hamlib/issues/1418
2023-12-25 16:13:43 -06:00
Mike Black W9MDB 3ba1bc2c19 Get the right variable name for checking the 169.x.x.x address
https://github.com/Hamlib/Hamlib/issues/1461
2023-12-24 22:26:04 -06:00
Mike Black W9MDB b2850ff7a8 Fix warning message on duplicate IP addresses to only when trying to use
https://github.com/Hamlib/Hamlib/issues/1461
2023-12-24 16:25:43 -06:00
Mike Black W9MDB 675ed1c85a Fix 169.x.x.x network detection
https://github.com/Hamlib/Hamlib/issues/1461
2023-12-24 16:18:48 -06:00
Mike Black W9MDB a1b56bc315 Prevent multicast from trying to use 169.x.x.x network
https://github.com/Hamlib/Hamlib/issues/1461
2023-12-24 14:52:37 -06:00
Mike Black W9MDB 8c8c20c256 Make multicast bind the IPV4 address if available
https://github.com/Hamlib/Hamlib/issues/1461
2023-12-24 11:39:30 -06:00
Mike Black W9MDB 37c0f07ecb Add some debug for https://github.com/Hamlib/Hamlib/issues/1461 2023-12-23 00:01:56 -06:00
Mike Black W9MDB bca0a6ee47 Make FLRig name simpler for rig list 2023-12-22 16:00:40 -06:00
Mike Black W9MDB c3d489cca3 Update Thetis entry for correct display in WSJT-X 2023-12-22 09:15:22 -06:00
Mike Black W9MDB 70c35791ce Add rig entry for Thetis 2023-12-22 07:51:48 -06:00
Michael Black cc81d7ecca
Merge pull request #1458 from DJ3CE/power_ic705905
Patch power reading of IC-705/-905
2023-12-21 08:39:12 -06:00
Mike Black W9MDB 7542f4cc71 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-12-21 08:17:19 -06:00
Mike Black W9MDB 633da3d7c6 Update NEWS 2023-12-21 08:17:08 -06:00
Michael Black 25596f4c79
Merge pull request #1459 from dgbalharrie/master
Add number of CW and Voice memories to supporting Icom, Yaesu, Kenwoo…
2023-12-21 08:14:44 -06:00
Mike Black W9MDB 9ac55a9baa Add notes on voice memory for rigs 2023-12-21 08:13:41 -06:00
Michael Black 74062c6aba
Merge branch 'master' into master 2023-12-21 07:53:27 -06:00
DJ3CE a5c273efe9 Patch power reading of IC-705/-905 2023-12-21 01:18:18 +01:00
davidg 3061d5e208 Add number of CW and Voice memories to supporting Icom, Yaesu, Kenwood and Elecraft Radios. Added added .chanlist to TS890S 2023-12-20 21:26:57 +00:00
George Baltz N3GB 8dff750285 Define different (disambiguated) names for external use. 2023-12-20 14:49:35 -05:00
Mike Black W9MDB ea7ce78c65 Balance RETURNFUNC in id5100.c 2023-12-19 22:42:08 -06:00
George Baltz N3GB 9af715d244 Convert the remaining files in rigs/kenwood/ 2023-12-19 18:58:37 -05:00
George Baltz N3GB b38014832f More Kenwood rigs ported to new access macros. 2023-12-19 18:58:37 -05:00
George Baltz N3GB 9c7a21282c Add basic support for transparent access to port structures.
Define macros for internal access to port data.
Port rigs/kenwood/kenwood.c to use new access as PoC

Part 1 of issue #1445
2023-12-19 18:58:37 -05:00
Mike Black W9MDB 576ed8266a Ignore scanfc Invalid argument for rotctld
https://github.com/Hamlib/Hamlib/issues/1391
2023-12-19 16:23:03 -06:00
Mikael Nousiainen 1cc08d2f00 Merge upstream and fix conflicts 2023-12-19 18:03:12 +02:00
Mike Black W9MDB 7334da6d89 Split AZ/EL request into two transactions for easycomm.c 2023-12-19 09:29:31 -06:00
Mikael Nousiainen 3a414c3221 Allow split passband width changes without changing the mode 2023-12-19 10:16:27 +02:00
Mike Black W9MDB 935cebed6e Remove some debug and fix debug indendation 2023-12-18 16:44:57 -06:00
Mikael Nousiainen 93b61d2c5e Fix dummy rig bugs. Improve FTDX101/FTDX10 ST split command logic. 2023-12-19 00:08:35 +02:00
Mike Black W9MDB af5ea58350 Add -# --skip_init option to rigctl 2023-12-18 15:26:46 -06:00
Mike Black W9MDB 48b6b4910c Allow compilation for systems without pthreads
https://github.com/Hamlib/Hamlib/issues/1373
2023-12-18 11:56:41 -06:00
Mike Black W9MDB 21cbd77047 Add retries in easycomm.c 2023-12-18 09:11:19 -06:00
Mike Black W9MDB a3676e0e3b Improve error output in easycom.c to show message 2023-12-18 09:05:15 -06:00
Mike Black W9MDB 3a6073d401 astyle files 2023-12-18 08:25:15 -06:00
Mike Black W9MDB 98edf92240 Update rig.h documentation a bit 2023-12-18 07:53:55 -06:00
Mike Black W9MDB 19bf90bbb4 Minor update to rigctl.1 rigctld.1 2023-12-18 07:13:23 -06:00
Mike Black W9MDB bc6f874675 Fix wireless detection 2023-12-17 23:13:32 -06:00
Mike Black W9MDB dbb8f4d5a7 Remove some debug statements 2023-12-17 22:29:21 -06:00
Mike Black W9MDB 1f38d59153 Fix Windows rigctl shutdown
https://github.com/Hamlib/Hamlib/issues/1448
2023-12-17 17:38:28 -06:00
Mike Black W9MDB 248d5e44a9 Fix cppcheck warning in newcat.c 2023-12-17 12:52:34 -06:00
Mike Black W9MDB 027b780189 Fix FT857 set_vfo cppcheck warning as get_vfo is always RIG_OK 2023-12-17 06:19:08 -06:00
Mike Black W9MDB ac7c908036 Add DSTAR to flrig.c -- thanks to Philip Rose GM3ZZA 2023-12-16 17:09:11 -06:00
Mike Black W9MDB 50711dcfb8 Remove dead code in flex6xxx.c 2023-12-16 15:03:21 -06:00
Mike Black W9MDB 11876d7cc4 Fix ptt shadow in flex6xxx.c 2023-12-16 15:02:01 -06:00
Mike Black W9MDB e267c62764 astyle files 2023-12-16 11:37:58 -06:00
Mike Black W9MDB e1b3ac2a95 Fix DLL build for rigfreqwalk 2023-12-15 08:40:08 -06:00
Mike Black W9MDB 67e57f6e4d Fix compilation for LLVM-MINGW 2023-12-15 08:05:20 -06:00
Mike Black W9MDB f81d49cdab Fix satellite mode for IC-9700
https://github.com/Hamlib/Hamlib/issues/1451
2023-12-13 17:28:31 -06:00
Mike Black W9MDB 5dac79340f Remove x25_always from IC9700
https://github.com/Hamlib/Hamlib/issues/1451
2023-12-13 16:36:58 -06:00
Mike Black W9MDB 10accf17b8 Remove all bw functions if failing 2023-12-13 16:31:12 -06:00
Mike Black W9MDB 18c88c9f38 Fix clang warnings
https://github.com/Hamlib/Hamlib/issues/1450
2023-12-12 22:49:25 -06:00
Mike Black W9MDB 5dc55ff9e1 Fix some double entries 2023-12-12 12:11:31 -06:00
Mike Black W9MDB 81db043fbd Fix targetable vfo in xiegu.c 2023-12-12 12:06:38 -06:00
Mike Black W9MDB 27d7e8bd2d Revert "Speed up shutdown of multicast thread"
This broke Windows rigctl quit
This reverts commit b25b496051.
2023-12-09 15:57:47 -06:00
Mike Black W9MDB 5f0c8691d7 Add ICPW2 to IC7610 2023-12-09 15:08:08 -06:00
Mike Black W9MDB e9f9286f21 Remove hamlibgui -- going another route 2023-12-09 10:03:35 -06:00
Mike Black W9MDB b25b496051 Speed up shutdown of multicast thread 2023-12-09 09:45:21 -06:00
Mike Black W9MDB 72fba4eb5b Update simic7610 2023-12-09 09:43:20 -06:00
Mike Black W9MDB 63c615a452 Add IPP, DPP, and TX_INHIBIT for IC7610 2023-12-09 09:23:50 -06:00
Mike Black W9MDB ea823e911c Add RIG_LEVEL_RFPOWER_METER_WATTS to TS590 2023-12-08 23:35:58 -06:00
Mike Black W9MDB ae69772d2a Update NEWS 2023-12-08 11:42:44 -06:00
Mike Black W9MDB f6eed23494 Ignore RIG_VFO_NONE in cache.c 2023-12-08 08:24:29 -06:00
Mike Black W9MDB cf973c9b0a Ignorie RIG_VFO_OTHER cache request 2023-12-08 07:53:21 -06:00
Mike Black W9MDB 3729f658ec Add 60M channel 3 for 5357MhZ for FT8 on channelized 60M rigs 2023-12-04 22:18:14 -06:00
Mike Black W9MDB 768ca6105d Update comment in icom.c 2023-12-04 16:35:23 -06:00
Mike Black W9MDB f0e97a9e0e Allow freq=0 for PowerSDR and perhaps others 2023-12-04 16:13:52 -06:00
Michael Black 4e1aa90499
Merge pull request #1444 from GeoBaltz/fix6
Restore shared library ABI compatibility with previous hamlibs
2023-12-04 14:42:48 -06:00
George Baltz N3GB f4d40e0d79 Restore shared library ABI compatibility with previous hamlibs
No need for post_ptt_delay to be in hamlib_port - move it to misc
  rig_state data.
Update references to post_ptt_delay
Fix a couple of typos
Add code to actually set post_ptt_delay

Fixes issue #1412
2023-12-04 10:47:52 -05:00
Michael Black e3f1816e8a
Merge pull request #1441 from GeoBaltz/fix5
Fix FTDX101MP RFPOWER the right way
2023-12-01 10:41:37 -06:00
George Baltz N3GB 37fb4eafdd Fix FTDX101MP RFPOWER the right way. 2023-12-01 11:22:46 -05:00
George Baltz N3GB ed630b28d1 Revert "Fix FTDX101MP RFPOWER to allow 200W"
Unnecessary code, breaks other levels.

This reverts commit f255f6f8d8.
2023-12-01 11:11:21 -05:00
Mike Black W9MDB f255f6f8d8 Fix FTDX101MP RFPOWER to allow 200W
https://github.com/Hamlib/Hamlib/issues/1396
2023-11-30 22:32:42 -06:00
Mike Black W9MDB 88c3d9427b Fix simftdx101 2023-11-30 22:15:44 -06:00
Mike Black W9MDB cc49669b49 Change Icom 0x26 behavior to leave filter# alone
Rigs should remember filter based on last filter used for the mode
2023-11-30 10:31:56 -06:00
Mike Black W9MDB 8940d91522 Fix CPU usage in simulators when client quits 2023-11-29 17:04:56 -06:00
Mike Black W9MDB e40981e198 Add simtrusdx.c 2023-11-29 16:02:19 -06:00
Mike Black W9MDB a5ad218bba Add simft1000 to Makefile.am 2023-11-29 15:58:15 -06:00
Mike Black W9MDB 7973db52de Remove debug from network.c 2023-11-29 14:53:39 -06:00
Mike Black W9MDB 001dd01a10 Fix more compile errors for mingw 2023-11-29 12:53:16 -06:00
Mike Black W9MDB 756fad1c72 Fix compile error on mingw with network.c 2023-11-29 12:47:38 -06:00
Mike Black W9MDB 07f57cfc18 Fix error on ctrl-c of rigctld 2023-11-29 12:45:11 -06:00
Mike Black W9MDB ed94193935 Add #define RIGCAPS_NOT_CONST
Allows clients to test for which declarations to use
https://github.com/Hamlib/Hamlib/issues/1436
2023-11-29 11:10:43 -06:00
Mike Black W9MDB a910b16e8f Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-11-28 07:06:47 -06:00
Michael Black 4f019e622e
Merge pull request #1434 from pdaderko/master
Fix for iOptron rotator (tested with AZ Mount Pro), added improvements
2023-11-28 07:06:33 -06:00
pdaderko c0457a0d7b
Fixed functionality (AZ Mount Pro), added improvements
Updated code to work with current AZ Mount Pro firmware.
Current firmware uses serial at 115200.
Original code looked for # delimiter on responses, but not all responses end in #.  This caused the software to timeout, which caused slow response time, and in some cases returned a failure (including :MountInfo# used at open).  All responses have fixed length replies, so code updated to look at fixed length data rather than delimiter.
Added workarounds for a couple firmware bugs.
Minor cleanup.
2023-11-28 05:07:00 -05:00
Mike Black W9MDB 09ab2819b3 Add better error info to serial error 2023-11-27 11:39:09 -06:00
Mike Black W9MDB 46c16b22a0 Fix compile warning 2023-11-26 12:41:26 -06:00
Mike Black W9MDB 698cb10ff3 Re-enable extra get_freq so see if it fixes timeout problem on IC-7100 2023-11-25 22:33:07 -06:00
Mike Black W9MDB 9c01045356 Fix HOMEPATH for Windows hamlib_settings file 2023-11-25 15:05:42 -06:00
Mike Black W9MDB 30f47cdeba Update Icom simulators for better behavior at rigctl shutdown 2023-11-25 09:29:01 -06:00
Mike Black W9MDB 50563e2fce Add simft1000.c 2023-11-24 22:08:56 -06:00
Mike Black W9MDB 6712f32fe3 Add VFOB mode to FT1000 2023-11-24 17:20:01 -06:00
Mike Black W9MDB 8c49a977fa Change FT1000 to ALPHA 2023-11-24 17:18:06 -06:00
Mike Black W9MDB 5bb669edbd Add FT-1000 in write-only mode
freq,mode,ptt,vfo functions implemented
2023-11-24 17:06:35 -06:00
Mikael Nousiainen 0dea8ed8bb Print integer level range 2023-11-24 00:17:48 +02:00
Mike Black W9MDB 9841e500b9 Fix ptt_share segmentation fault
https://github.com/Hamlib/Hamlib/issues/1433
Fix ID5100 0x25 and simplex VFO actions
https://github.com/Hamlib/Hamlib/issues/1429
2023-11-23 15:00:05 -06:00
Mike Black W9MDB f28d674211 Remove unnecessary rig_get_freq 2023-11-22 23:44:15 -06:00
Michael Black 50c4646c1d
Merge pull request #1432 from dgbalharrie/master
added RIG_MTYPE_VOICE and RIG_MTYPE_MORSE to chan_type_t and IC 7300,…
2023-11-22 17:10:35 -06:00
davidg f88399ed3a fix the missing comma in chan_list for IC7300, IC9700, IC705 2023-11-22 18:14:33 +00:00
davidg d0fd27afd6 added RIG_MTYPE_VOICE and RIG_MTYPE_MORSE to chan_type_t and IC 7300, 9700 and 703 radios. 2023-11-22 17:46:21 +00:00
Mikael Nousiainen 8185a3562b Merge branch 'master' into streamline-vfo-targeting-and-split-functionality 2023-11-22 18:52:37 +02:00
Mikael Nousiainen 00cb0eccdc Fix multicast publisher write commands to use a mutex lock to prevent corruption in (spectrum) data written with multiple write() calls. Remove unnecessary hl_usleep() calls in Icom backend, as the frame parser will correctly detect transceive messages. 2023-11-22 18:41:55 +02:00
Mike Black W9MDB 5d51e29d44 Fix conf.c to detect const structure 2023-11-22 07:28:05 -06:00
Mike Black W9MDB 15729dfafd Fix segfault in conf.c on TOK_PTT_TYPE 2023-11-22 07:18:55 -06:00
Mikael Nousiainen 7b341a2ad6 Merge branch 'master' into streamline-vfo-targeting-and-split-functionality 2023-11-20 10:16:15 +02:00
Mikael Nousiainen 7d5f540b9c Fix bugs in dummy rig. Report errors (incl. timeouts) from icom_get_powerstat(), because the timeout reason is often something else than rig being powered off. Check for power status changes in rigctld/rigctl command loops. 2023-11-20 10:15:45 +02:00
Mike Black W9MDB bb87d92f43 Update simts950 and simts990 2023-11-18 10:39:58 -06:00
Mike Black W9MDB eff7d97c64 Update rigctl.1 2023-11-17 00:07:04 -06:00
Mike Black W9MDB 58fdb4423f Add callback.c test 2023-11-16 16:37:03 -06:00
Mike Black W9MDB 85f828b19f Add sim.h 2023-11-16 16:33:32 -06:00
Mike Black W9MDB 41a1da795c Fix build for Apple
https://github.com/Hamlib/Hamlib/issues/1430
2023-11-16 15:42:52 -06:00
Mike Black W9MDB deebca4eaf Remove voice functions from IC275 -- rig does not have them 2023-11-16 15:12:01 -06:00
Mike Black W9MDB 7d9ef323d7 Add some needed enums 2023-11-16 14:40:54 -06:00
Mike Black W9MDB 43545e171a Fix debug statement for mingw 2023-11-16 14:40:25 -06:00
Mike Black W9MDB 16488d3267 Add -liphlpapi to configure.ac for mingw build
https://github.com/Hamlib/Hamlib/issues/1409
2023-11-16 09:16:26 -06:00
Mike Black W9MDB c1780b19f4 Add wireless detection for multicast address -- possible fix for UDP error messages by using 127.0.0.1 instead of IN_ADDR_ANY
https://github.com/Hamlib/Hamlib/issues/1409
2023-11-16 09:05:29 -06:00
Mike Black W9MDB cb34dc3b20 Add stop_voice_mem to some icom rigs
Also add  send_voice_mem to IC275
2023-11-16 09:02:32 -06:00
Mike Black W9MDB 4f0393d6ad Add simic275.c 2023-11-15 07:38:13 -06:00
Mike Black W9MDB e8d387d51c Update actions in c-cpp.yml 2023-11-14 23:54:56 -06:00
Mike Black W9MDB 1fce7ced5b Really fix modeMapGetHamblib in Flrig to find mode in multiple mode list
https://github.com/Hamlib/Hamlib/issues/1428
2023-11-14 23:44:47 -06:00
Mike Black W9MDB 512c82649e Fix modeMapGetHamblib in Flrig to find mode in multiple mode list
https://github.com/Hamlib/Hamlib/issues/1428
2023-11-14 22:55:25 -06:00
Mike Black W9MDB c348632b26 Add ptt_type to rig->caps when set so it can be queried correctly 2023-11-14 17:03:40 -06:00
Mikael Nousiainen b78fa43b56 Fix issues in VFO targeting. Allow IC-9700 to target Sub receiver (requires VFO swapping). 2023-11-14 23:00:37 +02:00
Mike Black W9MDB 8478367223 Improve rigctld printout when TCP session is aborted 2023-11-14 10:23:14 -06:00
Mike Black W9MDB f57b7cba71 Revert commit 1c379e793a
Removing LF from here caused "l ?" to not have CR where "L ?" does.
I don't see the problem with a CR to end the printout.
Not sure why this was removed before...bad documentation on my part.
2023-11-14 07:42:38 -06:00
Mike Black W9MDB 723b835fdd Remove bogus set_level in ts590.c for ALC,SWR,COMP 2023-11-14 06:48:41 -06:00
Mikael Nousiainen dd974a2536 Merge branch 'master' into streamline-vfo-targeting-and-split-functionality 2023-11-14 10:05:52 +02:00
Mikael Nousiainen e2e723ec60 Simplify/streamline split VFO handling, especially in the Icom backend. Detect reverse split automatically at startup for Icom rigs. 2023-11-14 10:05:17 +02:00
Mike Black W9MDB d868f1a545 Fix FLRig get_bwA/B for rigs that do not have it
https://github.com/Hamlib/Hamlib/issues/1427
2023-11-13 23:07:57 -06:00
Michael Black 394cb4cbcf
Merge pull request #1426 from GeoBaltz/990_meter
990 meter
2023-11-13 17:48:52 -06:00
Mike Black W9MDB b1b567d64a Fix FLRig get_bwA/B for rigs that do not have get_bwA/b
https://github.com/Hamlib/Hamlib/issues/1427
2023-11-13 13:58:06 -06:00
George Baltz N3GB 176c49240d Use general meter reader to get SWR value for TS-990. 2023-11-13 13:24:52 -05:00
George Baltz N3GB e05b79acd3 Move meter reader to kenwood.c, so it can be used by ts990.c 2023-11-13 12:47:18 -05:00
Mike Black W9MDB e19bdc3d56 Update vfo_fixup for ID5100 dual watch mode
https://github.com/Hamlib/Hamlib/issues/1425
2023-11-13 10:26:00 -06:00
Mike Black W9MDB e7786cee4c Fix TS990S SWR read -- strange behavior of RM command reading first RM turned on for read
New SWR table too for TS990S
https://github.com/Hamlib/Hamlib/issues/1423
2023-11-12 13:22:02 -06:00
Mike Black W9MDB 43159e55a1 Default configure builds shared libraries
Adding --enable-static now turnes off shared as it never build both at the same time
2023-11-12 08:47:28 -06:00
Mike Black W9MDB 9832fba797 Add null check in rig_get_function_ptr 2023-11-11 22:21:38 -06:00
Mike Black W9MDB 6351d5deac Get scaling correct (i.e.none) for FLRig get_SWR
https://github.com/Hamlib/Hamlib/issues/1423
2023-11-10 17:38:57 -06:00
Mike Black W9MDB 1374ee554c Add new get_SWR function for FLRig
https://github.com/Hamlib/Hamlib/issues/1423
2023-11-10 15:43:20 -06:00
Mikael Nousiainen 4a926ec503 Fix issues found during testing 2023-11-10 20:32:59 +02:00
Mike Black W9MDB 774e60895c Use new FLRig get_SWR method if available -- otherwise use old method 2023-11-10 11:55:30 -06:00
Mike Black W9MDB 5059ec8cd6 Add SWR for TS990
https://github.com/Hamlib/Hamlib/issues/1423
2023-11-10 10:55:31 -06:00
Mike Black W9MDB 1f9d3a63d4 Fix PTT status for multicast 2023-11-09 11:26:56 -06:00
Michael Black 7cb10edf20
Merge pull request #1421 from mikaelnousiainen/hamlib-multicast-4
Improve rig poll routine (multicast)
2023-11-09 09:33:13 -06:00
Mikael Nousiainen 82f2b10275 Merge branch 'hamlib-multicast-4' into streamline-vfo-targeting-and-split-functionality 2023-11-09 09:59:48 +02:00
Mikael Nousiainen 59285750ef Fix conflict 2023-11-09 09:59:35 +02:00
Mikael Nousiainen c90c675add Unify and streamline Icom backend logic for freq/mode and split commands. Allow use of targeted freq/mode whenever possible. Move certain Icom-specific caps to the icom_priv_caps struct to remove rig-specific conditions in generic backend code. 2023-11-09 09:57:23 +02:00
Mikael Nousiainen 0ece468b49 Merge branch 'hamlib-multicast-4' into streamline-vfo-targeting-and-split-functionality 2023-11-09 09:54:16 +02:00
Mikael Nousiainen 3a08bbe3d8 Detect also VFO changes in poll routine and allow detection of multiple changes at once. Remove old unused code. 2023-11-09 09:53:48 +02:00
Mike Black W9MDB 5d7db6b516 Fix FLRig SWR value
Change float level print to %g format for better appearance
https://github.com/Hamlib/Hamlib/issues/1417
2023-11-08 17:14:10 -06:00
Mike Black W9MDB f1a9823bdd Move swr from rig_cache to priv value until we get rig_cache fixed to be expandable
https://github.com/Hamlib/Hamlib/issues/1419
2023-11-08 08:05:56 -06:00
Mike Black W9MDB 62341a657e Only allow SWR read when ptt is on for PowerSDR
https://github.com/Hamlib/Hamlib/issues/1417
2023-11-07 16:05:27 -06:00
Mike Black W9MDB 02b4da83c3 Fix PowerSDR swr reading -- then we can fix FLRig's read too
https://github.com/Hamlib/Hamlib/issues/1417
2023-11-07 16:00:31 -06:00
Mike Black W9MDB a5bac08190 Add SWR to flrig 2023-11-07 12:32:47 -06:00
Mikael Nousiainen 4fa61a9a32 Merge branch 'master' into streamline-vfo-targeting-and-split-functionality 2023-11-07 15:59:49 +02:00
Mike Black W9MDB 7c3e71a487 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-11-07 07:55:10 -06:00
Michael Black 162a685887
Merge pull request #1416 from mikaelnousiainen/hamlib-multicast-3
List all available VFOs in multicast state snapshot packets
2023-11-07 07:54:55 -06:00
Mikael Nousiainen afdb26093e List all available VFOs in multicast state snapshot packets 2023-11-07 09:55:30 +02:00
Mikael Nousiainen 89abbfeb3a Merge master and fix conflicts 2023-11-07 09:41:29 +02:00
Mike Black W9MDB 4aa8e010a1 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-11-05 22:38:55 -06:00
Mike Black W9MDB 45dca3be59 Add dumpcap include files to test/Makefile.am 2023-11-05 17:34:49 -06:00
Mike Black W9MDB 49e93f3090 Comment out lines on compile warning 2023-11-05 17:16:09 -06:00
Mike Black W9MDB 02ffc6d6dc More set_conf/get_conf work
https://github.com/Hamlib/Hamlib/issues/971
2023-11-05 17:03:21 -06:00
Michael Black 2d2d5009e0
Merge pull request #1415 from mikaelnousiainen/hamlib-multicast-2
Add rig communication status to rig_state and multicast packets
2023-11-05 16:55:13 -06:00
Mike Black W9MDB 1e3e1a9499 Only do swr and power for PowerSDR then ptt is active 2023-11-05 16:53:53 -06:00
Mike Black W9MDB 337fb0f3e5 Add SWR reading for PowerSDR/Thetis 2023-11-05 16:45:15 -06:00
Mikael Nousiainen 43d1fbb323 Add more detailed rig communication status to rig_state and multicast state data packets. Handle SIGINT and SIGTERM in a consistent way in both rigctl and rigctld. 2023-11-06 00:42:02 +02:00
Mike Black W9MDB 31298bb917 Reduce debug in icom.c 2023-11-05 16:39:49 -06:00
Michael Black 3107a060f0
Merge pull request #1413 from mikaelnousiainen/hamlib-multicast-1
Refactor multicast publisher/server code
2023-11-05 15:26:55 -06:00
Mikael Nousiainen f8814732a2 Merge master and fix conflicts 2023-11-05 13:23:35 +02:00
Mikael Nousiainen 41c891251f Fix multicast receiver shutdown by using non-blocking sockets and select(). Use the same port number 4532 for both state snapshots and commands -- it is enough to have different multicast groups for them. Publish multicast state snapshots more often (change detection interval now set to 50ms), but at least at interval defined by poll_interval. 2023-11-03 17:18:49 +02:00
Mike Black W9MDB 40a8cedc9d get_conf/set_conf now shows parameters for rigctl and rotctl. Using it with rigctld and rotctld sends output to console instead of remote client
https://github.com/Hamlib/Hamlib/issues/971
2023-11-02 17:06:39 -05:00
Mikael Nousiainen 5b86d4efff Bind multicast receiver to INADDR_ANY on Windows, because binding to multicast group IPs doesn't seem to work. Use a different port number for (4351) multicast receiver commands to avoid multicast publisher packets ending up in the receiver (loopback issue). 2023-11-02 18:00:16 +02:00
Mikael Nousiainen 88e86fb62a Comment out SO_REUSEADDR for now 2023-11-02 00:35:47 +02:00
Mikael Nousiainen 53ff60d981 Fix socket option again 2023-11-02 00:32:05 +02:00
Mikael Nousiainen 5fb2e68e07 Fix warning 2023-11-02 00:20:15 +02:00
Mikael Nousiainen f36822ac20 Fix socket option 2023-11-02 00:18:27 +02:00
Mikael Nousiainen f618540f22 Join multicast group to enable UDP packet reception 2023-11-02 00:11:57 +02:00
Mike Black W9MDB 0dbe24ff42 Restore vfo offset lines accidentally removed in rig.c 2023-11-01 16:25:09 -05:00
Mike Black W9MDB f4f4d122a8 Improve post_ptt_delay behavior
https://github.com/Hamlib/Hamlib/issues/1412
2023-11-01 15:54:36 -05:00
Mike Black W9MDB 8484b132f2 Add FTDX5000 to 60M exception handling 2023-11-01 10:14:18 -05:00
Mike Black W9MDB 7f8f470ef7 Hopefully fix compile warning in newcat.c 2023-11-01 09:17:53 -05:00
Mike Black W9MDB 701bc36559 Update simts450.c 2023-10-31 23:03:17 -05:00
Mike Black W9MDB fccc540353 Add 60M exception for FT897/D
https://github.com/Hamlib/Hamlib/issues/1414
2023-10-31 22:40:30 -05:00
Mike Black W9MDB 6cb17e49dc Add post_ptt_delay for situations where more time is needed for external relay operations
Detect Doppler frequency changes for Kenwood rigs and avoid querying frequency...just set it...to provide stable timing
https://github.com/Hamlib/Hamlib/issues/1412
2023-10-31 17:34:31 -05:00
Mikael Nousiainen c8c8869a3c Refactor multicast publisher and rig poll routine. Create skeleton for multicast command server. 2023-11-01 00:26:37 +02:00
Mikael Nousiainen f89e0f0388 Cleaning up and unifying the Icom backend 2023-10-31 22:38:43 +02:00
Mike Black W9MDB fb03d095df Add recvfrom for client to send commands to multicast server
https://github.com/Hamlib/Hamlib/issues/695
2023-10-30 22:53:13 -05:00
Mike Black W9MDB 012534a628 Add nonblock mode to multicast for recv_from use
https://github.com/Hamlib/Hamlib/issues/695
2023-10-30 10:23:13 -05:00
Mike Black W9MDB 6b558c5d2a Revert "Add nonblocking mode to multicast for recv_from use"
This reverts commit f9bd07bbf5.
2023-10-30 10:21:58 -05:00
Mike Black W9MDB f9bd07bbf5 Add nonblocking mode to multicast for recv_from use
https://github.com/Hamlib/Hamlib/issues/695
2023-10-30 10:20:52 -05:00
Mikael Nousiainen 8ab8aafe48 Streamline VFO targeting and split functionality. Rewrite Icom backend routines to always avoid VFO swapping is the rig supports the 'targetable' commands 0x25 and 0x26. Work in progress. 2023-10-29 10:28:36 +02:00
Mike Black W9MDB 7c5d4db2fe Fix ptt status for multicast object to show ptt correct VFO 2023-10-27 15:11:19 -05:00
Michael Black 06c20da738
Merge pull request #1411 from GeoBaltz/oops1
f conversion already rounds, so no external rounding needed.
2023-10-25 15:23:46 -05:00
Mike Black W9MDB 1d57136d69 Fix TS590 USB_AF and USB_AF_INPUT maximum level
https://github.com/Hamlib/Hamlib/issues/1402
2023-10-25 15:18:33 -05:00
George Baltz N3GB 66e8548d60 f conversion already rounds, so no external rounding needed. 2023-10-25 16:12:11 -04:00
Michael Black 6d0035180c
Merge pull request #1410 from GeoBaltz/yaesu_level4
Yaesu level4
2023-10-25 14:48:30 -05:00
George Baltz N3GB 228aac34ca Replace hard coded constants with table values
Make sure table values exist.
2023-10-25 14:08:07 -04:00
George Baltz N3GB b5653852b3 Enable set_level checking for all Yaesu/newcat rigs. 2023-10-25 13:49:32 -04:00
Mike Black W9MDB d396623486 Fix compile warning with kenwood.c 2023-10-25 11:15:49 -05:00
Mike Black W9MDB 325277f269 Add USB_AF and USB_AF_INPUT for FTDX101D/MP 2023-10-24 23:07:33 -05:00
Mike Black W9MDB 32728ba95f Update FTDX101D antenna comment 2023-10-24 15:45:46 -05:00
Mike Black W9MDB 599554ee16 Add note for the future ANT possibilities for the FTDX101D 2023-10-24 15:44:28 -05:00
Mike Black W9MDB 192822417b Fix segfault for Kenwood L MICGAIN
Fix potential segfault in iofunc.c when stopset is null
2023-10-23 09:33:32 -05:00
Mike Black W9MDB e0fa354d3a Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-10-22 22:48:59 -05:00
Mike Black W9MDB a8f224e660 Reduce debug for multicast
https://github.com/Hamlib/Hamlib/issues/695
2023-10-22 22:48:36 -05:00
Michael Black 7e0d60535a
Merge pull request #1407 from dforsi/fix/twiddle
Fix warning message for twiddle_rit
2023-10-22 17:23:55 -05:00
Mike Black W9MDB 0613c5844b Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-10-22 16:59:23 -05:00
Mike Black W9MDB 541c1e1de2 Send out immediate multicast packet on freq,mode,split,ptt,width changes
https://github.com/Hamlib/Hamlib/issues/695
2023-10-22 16:58:44 -05:00
Daniele Forsi IU5HKX b17d2b869c Fix warning message for twiddle_rit
It was referencing a different option.
2023-10-22 23:43:37 +02:00
Michael Black ce6dd8d2c7
Merge pull request #1406 from dforsi/fix/manpage
Fix man page of rigctld
2023-10-22 16:26:12 -05:00
Daniele Forsi IU5HKX 5a7eec1af7 Fix man page of rigctld
The options rigctld-idle and bind-all where written with an underscore.
2023-10-22 23:21:02 +02:00
Mike Black W9MDB 84875071a9 Change modelist to modes array
Change id: to 3-elements
1 packet per second right now -- but will soon send out a packet upon any change of data
https://github.com/Hamlib/Hamlib/issues/695
2023-10-22 13:18:51 -05:00
Mike Black W9MDB 9b6d1565f1 More disabling of spectrum until it works well on Windows too
Maybe can enable for Linux only.
https://github.com/Hamlib/Hamlib/issues/695
2023-10-22 08:34:13 -05:00
Mike Black W9MDB fb49c0cf70 Remove bad RIG_LEVEL_USB* items 2023-10-21 16:05:16 -05:00
Mike Black W9MDB 46bfe24a62 Disable SPECTRUM from multicast until we get it working well with CAT control
https://github.com/Hamlib/Hamlib/issues/695
2023-10-21 15:57:30 -05:00
Mike Black W9MDB 00d69f63ef stop multicast during rig_close
https://github.com/Hamlib/Hamlib/issues/1405
2023-10-21 15:55:59 -05:00
Mike Black W9MDB bdeb433d04 Fix level print in kenwood.c for portability 2023-10-21 12:44:16 -05:00
Mike Black W9MDB 464fa3f478 Revert "Promote token_t to unsigned long long"
This broke several things -- have to do this inside kenwood.c instead
This reverts commit 01292b261f.
2023-10-21 12:39:47 -05:00
Mike Black W9MDB 344f06382c Fix sprintflst mode to skip empty modes 2023-10-21 12:10:16 -05:00
Mike Black W9MDB aa429806aa Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-10-21 11:47:31 -05:00
Mike Black W9MDB 65caf427f0 Fix sprintflst mode extra space 2023-10-21 11:46:31 -05:00
Michael Black e1ca06655d
Merge pull request #1404 from GeoBaltz/usb_stuff
Implement RIG_LEVEL_USB_* on Kenwood TS-890S
2023-10-21 10:20:54 -05:00
George Baltz N3GB a1baf7307d Implement RIG_LEVEL_USB_AF[_INPUT] for TS-890S
+ some cleanup.
2023-10-21 10:44:16 -04:00
George Baltz N3GB 9a22b39fcd Add RIG_LEVEL_USB_AF_INPUT to RIG_LEVEL_FLOAT_LIST 2023-10-21 10:24:42 -04:00
George Baltz N3GB 05823482a0 Fix duplicate level definition 2023-10-20 18:23:29 -04:00
Mike Black W9MDB c74fc74e9e Fix TS590 get level USB_AF and USB_AF_INPUT 2023-10-20 17:02:08 -05:00
Mike Black W9MDB b6ffeeda99 Fix stupid mistake on ts590.c 2023-10-20 16:39:30 -05:00
Mike Black W9MDB f697f71205 Fix USB_AF USB_AF_INPUT for TS590SG 2023-10-20 16:33:45 -05:00
Mike Black W9MDB b609eb0085 Make multicast a little quieter so one can run rigctl -vvvvv
https://github.com/Hamlib/Hamlib/issues/695
2023-10-20 16:25:21 -05:00
Mike Black W9MDB df413d0dc4 Enable multicast by default on 224.0.0.1 port 4532
Does not allow for rig control yet -- just rig info
https://github.com/Hamlib/Hamlib/issues/695
2023-10-20 15:18:23 -05:00
Mike Black W9MDB d87671b54b Add a TRACE function to network.c 2023-10-20 11:52:59 -05:00
Mike Black W9MDB 289585388b Allow network_init to succeed when already initialized
https://github.com/Hamlib/Hamlib/issues/695
2023-10-20 11:25:20 -05:00
Mike Black W9MDB ff2c0e6b03 Fix USB_AF and USB_AF_INPUT for TS590
https://github.com/Hamlib/Hamlib/issues/1402
2023-10-20 09:35:03 -05:00
Mike Black W9MDB 01292b261f Promote token_t to unsigned long long
https://github.com/Hamlib/Hamlib/issues/1402
2023-10-19 23:35:20 -05:00
Mike Black W9MDB ec6c19854e Fix AG response for simts590.c 2023-10-18 17:14:37 -05:00
Mike Black W9MDB f5f8694a70 Add RIG_LEVEL_USB_AF_INPUT
Add RIG_LEVEL_USB_AF and RIG_LEVEL_USB_AF_INPUT to ts590.c
More rigs to be updated for this
2023-10-18 16:47:29 -05:00
Mike Black W9MDB 914c4f4d2a Add clearerr in rotctl_parse.c 2023-10-18 16:45:42 -05:00
Mike Black W9MDB 60356f5774 Fix some simulators to use new WRITE function
Update simts590.c
2023-10-18 15:37:28 -05:00
Mike Black W9MDB cb5e9ec853 Remove debug from configure.ac
https://github.com/Hamlib/Hamlib/issues/1403
2023-10-18 10:15:11 -05:00
Mike Black W9MDB aac762712a Fix static build with indi
Now builds both dynamic and static
https://github.com/Hamlib/Hamlib/issues/1403
2023-10-18 10:10:46 -05:00
Mike Black W9MDB 680ce55ba2 Revert "Fix get_vfo_info VFO argument"
This reverts commit 1bf2111c7a.
2023-10-15 22:53:27 -05:00
Mike Black W9MDB 1bf2111c7a Fix get_vfo_info VFO argument 2023-10-15 22:47:23 -05:00
Mike Black W9MDB 8a006db51d Hopefully fix network.c build warning 2023-10-15 08:09:19 -05:00
Mike Black W9MDB 9f053799e9 Fix indi build
d72127f29a (commitcomment-130010062)
2023-10-15 07:44:50 -05:00
Mike Black W9MDB cdc9bc45f2 Add -b/bind_all option to rigctld
By default rigctld will not try all interfaces
Windows was not recognizing duplicate rigctld instances and failing with Log4OM
https://github.com/Hamlib/Hamlib/issues/1400
2023-10-14 16:55:43 -05:00
Mike Black W9MDB b72dd095f7 Fix cppcheck warning 2023-10-14 12:45:37 -05:00
Mike Black W9MDB 8d15c04727 Fix more cppcheck items 2023-10-14 12:01:41 -05:00
Mike Black W9MDB e2354333f3 Return early in icom/frame.c on BUSERROR 2023-10-14 12:01:15 -05:00
Mike Black W9MDB 534fe449a2 Fix more cppcheck items 2023-10-13 17:36:29 -05:00
Mike Black W9MDB d72127f29a Fix cppcheck warnings 2023-10-11 23:22:42 -05:00
Mike Black W9MDB 501c4b62c9 cppcheck fixes 2023-10-11 09:01:15 -05:00
Mike Black W9MDB 9c6e564006 Fix flrig to work for now -- speed up will come later
https://github.com/Hamlib/Hamlib/issues/1398
2023-10-10 17:56:53 -05:00
Mike Black W9MDB 744eb5fc5d Revert to VFO argument for set_ant and get_ant
https://github.com/Hamlib/Hamlib/issues/1399
2023-10-10 10:44:39 -05:00
Mike Black W9MDB e68b6f98b5 Add RIG_CONF_INT
Fix AGC_LAST value thanks to cppcheck
2023-10-08 17:18:16 -05:00
Mike Black W9MDB 67fdf34f22 Update simftdx101.c 2023-10-08 17:16:46 -05:00
Mike Black W9MDB d3edab3759 Fix cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-08 17:16:10 -05:00
Mike Black W9MDB dfc04d49c4 Fix cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-08 17:14:55 -05:00
Mike Black W9MDB fd1c48bfab Fix printout of ext_level 2023-10-08 16:51:39 -05:00
Mike Black W9MDB 64d6cd4af2 Update some rigctl commands that do not need the VFO argument 2023-10-07 14:10:50 -05:00
Mike Black W9MDB d7b65ec5a5 In newcat.c add PC cmd to no validation 2023-10-07 09:54:38 -05:00
Mike Black W9MDB f7f57ecc68 Fix ID5100 to not use 0x25 cmd when in dual watch - otherwise use x25 in normal mode 2023-10-07 08:29:10 -05:00
Mike Black W9MDB 8a9776664e Fix ID5100 to use Main=Tx, Sub=Rx when split is requested
https://github.com/Hamlib/Hamlib/issues/1218
2023-10-07 08:20:41 -05:00
Mike Black W9MDB 4175929a48 More changes from cppcheck 2023-10-06 22:59:55 -05:00
Mike Black W9MDB 8dea15d4db Fix cppcheck.sh some more 2023-10-06 17:50:33 -05:00
Mike Black W9MDB 3217a007e4 Fix cppcheck.sh 2023-10-06 17:48:59 -05:00
Mike Black W9MDB d5f7660781 Fix some more cppcheck items
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-06 15:14:10 -05:00
Mike Black W9MDB e2d03ea581 Fix Icom error
https://github.com/Hamlib/Hamlib/issues/1395
2023-10-05 17:22:19 -05:00
Mike Black W9MDB 6957c15ec3 Remove the last 2 bytes of an FLRig packet 2023-10-05 16:32:23 -05:00
Mike Black W9MDB d48c847cf5 Revert "Add CR/LF to the flrig improvement"
This reverts commit 4fd9edbc97.
2023-10-05 09:41:58 -05:00
Mike Black W9MDB 4fd9edbc97 Add CR/LF to the flrig improvement 2023-10-05 08:54:43 -05:00
Mike Black W9MDB adc339039d Fix compile warning in testmW2power.c 2023-10-05 08:46:14 -05:00
Mike Black W9MDB 98ab55b805 Remove sleep from flrig.c
https://github.com/Hamlib/Hamlib/issues/1394
2023-10-04 17:41:32 -05:00
Mike Black W9MDB 89db4ae757 Fix flrig.c 2023-10-04 17:33:11 -05:00
Mike Black W9MDB d4cf8a04d7 Change iofunc.c to read FLRig more efficiently
https://github.com/Hamlib/Hamlib/issues/1394
2023-10-04 17:30:02 -05:00
Mike Black W9MDB e0c4988e6a Fix some more cppcheck items
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-04 15:50:24 -05:00
Mike Black W9MDB da5de3cb6e Fix wrong delete in xiegu.c
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-03 22:06:05 -05:00
Mike Black W9MDB 3b5f7a6dcf Add and fix some cppcheck suppress items
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-03 17:11:09 -05:00
Mike Black W9MDB c93440706f Fix rigctlsync.c compilation 2023-10-02 23:27:57 -05:00
Mike Black W9MDB 5ac1e50b80 Fix always true conditions found by cppcheck
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-02 23:10:58 -05:00
Mike Black W9MDB 631a2a3aa1 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-10-02 12:33:03 -05:00
Mike Black W9MDB 717a451d9c Fix possible null pointer warning from cppcheck
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-02 12:32:20 -05:00
Michael Black 1a8ae4b434
Merge pull request #1392 from GeoBaltz/yaesu_level3
Yaesu level3
2023-10-02 12:31:49 -05:00
George Baltz N3GB 84ca35f19e Fix inverted VHF/UHF BANDSELECT labels 2023-10-02 12:55:01 -04:00
George Baltz N3GB 6877d03579 Convert NR to use level_gran
Also gets rid of now unused newcat_scale_float() - all its former callers
  round to nearest.

Note: the quirk handling was mostly left intact - should be checked out
  with the individual rigs.
2023-10-02 12:55:01 -04:00
Mike Black W9MDB 1a4a189dbc Try to make rigctl(d)/rotctl(d) a little more robust in case of bad data
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-02 10:48:26 -05:00
Mike Black W9MDB 0484dc08c8 Fix prints/scanf argument mismatches idenfitied by cppcheck
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 18:01:27 -05:00
Mike Black W9MDB 18d016a2a2 Fix th.c logic error discovered by cppcheck
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 17:42:45 -05:00
Mike Black W9MDB 18e122196f Fix shadow variable warnings from cppcheck
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 17:38:13 -05:00
Mike Black W9MDB 71f8b3b8c9 Fix always false cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 17:26:51 -05:00
Mike Black W9MDB 93af897753 FIx always true cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 16:51:07 -05:00
Mike Black W9MDB a469823028 Fix cppcheck unused warning 2023-10-01 13:28:29 -05:00
Mike Black W9MDB f00661a8ae Fix unused cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 12:01:38 -05:00
Mike Black W9MDB e1e7112cb5 Fix redundant cppcheck warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 11:54:44 -05:00
Mike Black W9MDB 53855c868d Fix remaining cppcheck redundant warnings
https://github.com/Hamlib/Hamlib/issues/1351
2023-10-01 08:24:06 -05:00
Mike Black W9MDB 027c59d6e9 Hopefully fix newcat.c compile error on older compiler 2023-10-01 07:38:59 -05:00
Mike Black W9MDB 6e8d328fb1 Fix most of the redundant warning from cppcheck 2023-09-30 23:42:22 -05:00
Mike Black W9MDB 4d540b1459 Fix scope reductions from cppcheck 2023-09-30 22:50:16 -05:00
Mike Black W9MDB f9e9657ad1 Fix cppcheck warning 2023-09-30 22:36:09 -05:00
Mike Black W9MDB d49543f00c Fix cppcheck warning in gemini.c
https://github.com/Hamlib/Hamlib/issues/604
2023-09-30 16:28:05 -05:00
Mike Black W9MDB f55d0fc872 Minor update to note in newcat.c 2023-09-30 16:11:55 -05:00
Mike Black W9MDB 2423fb237c Improve Yaesu send_morse
Can now send message 1-5 or up to 50 char msg
e.g. rigctl -m 1035 -r /dev/ttyUSB0 b 1
or
rigctl -m 1035 -r /dev/ttyUSB0 b "CQ CQ DE W9MDB"
2023-09-30 16:07:07 -05:00
Mike Black W9MDB aeb03fda62 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-09-30 15:44:04 -05:00
Mike Black W9MDB 8bb6a57548 Reduce debug in fifo.c 2023-09-30 15:43:52 -05:00
Michael Black a82d67234b
Merge pull request #1390 from dg1sbg/master
Major code cleanup. Replace dyn. memory by static memory usage.
2023-09-28 14:58:33 -05:00
Frank Goenninger f9a9de37cf FIXED: Incorrect usage of snprintf() argument for buffer length. 2023-09-28 19:30:11 +02:00
Frank Goenninger 76a836af5b FIXED: Source code inconsistency after major code change. 2023-09-28 18:36:30 +02:00
Frank Goenninger cd9077fbc2 Major code cleanup. Replace dyn. memory by static memory usage. 2023-09-28 18:18:57 +02:00
Mike Black W9MDB 6b6289313c Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-09-28 08:05:07 -05:00
Mike Black W9MDB 85787c8e89 Fix ST command for older FTDX101D/MP firmware -- needed to turn on split light
Apparenlty split was still working but light was not coming on.
https://github.com/Hamlib/Hamlib/issues/1388
2023-09-28 08:04:01 -05:00
Michael Black db6ffaf7da
Merge pull request #1389 from dg1sbg/master
RIG ADAT: Adaptation to firmware 1.40fb and transverter board.
2023-09-27 14:00:24 -05:00
Frank Goenninger 3e0420f138 .gitignore: Ignore some macOS housekeeping files. 2023-09-27 20:27:58 +02:00
Mike Black W9MDB 85226e5bc4 Add two more allowances for FT-991 firmware bug where IF command returns 41 bytes instead of 28 2023-09-27 20:27:58 +02:00
Mike Black W9MDB be8372c72f FT-991A V2-01 firmware randomly adds 13 bytes to IF command so allow for it 2023-09-27 20:27:58 +02:00
Frank Goenninger f797178e96 RIG ADAT: Adaption to firmware 1.40fb and transverter board. 2023-09-27 20:11:24 +02:00
Mike Black W9MDB b731e77841 Add two more allowances for FT-991 firmware bug where IF command returns 41 bytes instead of 28 2023-09-27 10:23:07 -05:00
Mike Black W9MDB 44a6274bbe FT-991A V2-01 firmware randomly adds 13 bytes to IF command so allow for it 2023-09-27 09:54:50 -05:00
Mike Black W9MDB 6b4cc5b36b Fix stop_voice_mem for some kenwood rigs 2023-09-26 08:14:50 -05:00
Mike Black W9MDB 6f3a9831c3 Add voice to TS480 2023-09-25 16:44:52 -05:00
Mike Black W9MDB 5e4cb6f1c1 Add voice_mem functions for TS590S/SG and TS-2000
Increase max baud for TS-2000 to 115200
Change TS-2000 to hardware handshake default
2023-09-25 15:15:45 -05:00
Mike Black W9MDB 6644afbf8d Fix segfault with rigctld/rigctl -m 2 -u
https://github.com/Hamlib/Hamlib/issues/1386
2023-09-20 17:35:29 -05:00
Mike Black W9MDB 1fbb03fa92 Remove multicast.c from build
https://github.com/Hamlib/Hamlib/issues/695
2023-09-20 12:17:10 -05:00
Mike Black W9MDB 5f825aa0d4 Add modelist to multicast
Add time to multicast
Fix id to show rig+path
Remove sleep to speed up multicast packets to once per seconds
https://github.com/Hamlib/Hamlib/issues/695
2023-09-18 12:48:39 -05:00
Mike Black W9MDB da9199577e Add voice_mem commands for TS990S 2023-09-17 16:26:50 -05:00
Mike Black W9MDB 86df4001a1 Remove one more section from multicast to avoid compile warning fornow.
https://github.com/Hamlib/Hamlib/issues/695
2023-09-16 11:25:22 -05:00
Mike Black W9MDB 57c8819ce0 Remove multicast rx until we get it working
https://github.com/Hamlib/Hamlib/issues/695
2023-09-16 10:00:07 -05:00
Mike Black W9MDB e9ef4c1a81 Add ModeList to multicast packet
https://github.com/Hamlib/Hamlib/issues/695
2023-09-16 09:47:30 -05:00
Mike Black W9MDB 5115fa8959 Fix Kenwood PB command to stop last requested voice channel started
https://github.com/Hamlib/Hamlib/issues/1385
2023-09-16 09:36:00 -05:00
Mike Black W9MDB 0bee582095 Remove some more debug from multicast.c to get git build working again 2023-09-15 23:50:50 -05:00
Mike Black W9MDB e972262e80 Remove some debug from multicast as github build was perhaps failing on it 2023-09-15 23:43:09 -05:00
Mike Black W9MDB 3e91601a0f Fix JSON for multicast 2023-09-15 23:22:10 -05:00
Mike Black W9MDB d50ff331ee Add AGC level get/set to Barrett 4050
https://github.com/Hamlib/Hamlib/issues/1384
2023-09-15 11:43:48 -05:00
Mike Black W9MDB 9415fc3446 Expand Barret channels to include non-ham bands 2023-09-15 10:49:55 -05:00
Mike Black W9MDB f05b6604a2 Add github reference to README.developer 2023-09-14 22:11:21 -05:00
Mike Black W9MDB 8a4767db17 Add kenwood_stop_voice and fix TS890S send_voice 2023-09-14 17:29:20 -05:00
Mike Black W9MDB 4df8260cc1 Stop validating TX1; on FT-950 -- seems it didn't like TX; after TX1;
https://github.com/Hamlib/Hamlib/issues/1382
2023-09-14 10:11:27 -05:00
Mike Black W9MDB 4f65288c32 Fix multicast_stop DLL export
https://github.com/Hamlib/Hamlib/issues/1090
2023-09-14 10:01:06 -05:00
Mike Black W9MDB 3cf5fab21d Slow down multicast broadcast when no change has occurred
https://github.com/Hamlib/Hamlib/issues/1090
2023-09-14 09:44:50 -05:00
Mike Black W9MDB ee807a7541 Prevent multicast from doing rig queries at all for now -- threading contention needs to be addressed
https://github.com/Hamlib/Hamlib/issues/695
2023-09-14 08:55:21 -05:00
Mike Black W9MDB a00326161c Phase I of rig multicast
https://github.com/Hamlib/Hamlib/issues/1090
2023-09-13 17:25:26 -05:00
Mike Black W9MDB 5b4654024a Fix MD cmd for Win4Yaesu by not validating it. Was not responding fast enough and timing out during validation efforts
https://github.com/Hamlib/Hamlib/issues/1381
2023-09-12 16:04:14 -05:00
Mike Black W9MDB 81e14ae4f1 Remove ST command from newcat.c for FTDX101D/MP set_tx_vfo
Seems to fail on latest firmware for FTDX101MP
https://github.com/Hamlib/Hamlib/issues/1379
2023-09-11 22:09:11 -05:00
Mike Black W9MDB 6f229d1c1a Fix FTDX101D/MP to not validate ST command
https://github.com/Hamlib/Hamlib/issues/1379
2023-09-11 16:17:54 -05:00
Mike Black W9MDB c07e40e18b Fix memory channgle in FTDX101 and FTDX101MP
Add tag  data to memsave.c
Fix  RVF error for Elecraft K3
2023-09-08 17:05:34 -05:00
Mike Black W9MDB 256766c5b6 Fix Elecraft K3 RVF fail to just warn and not quit 2023-09-08 16:54:15 -05:00
Mike Black W9MDB 8ebadb3b7d Get more firmware info for Elecraft K3 2023-09-07 12:01:18 -05:00
Mike Black W9MDB 1e93364f7d Update simic7851 2023-09-07 11:57:03 -05:00
Mike Black W9MDB 3c48de2159 Update FT991 channel list to include PMS and 5MHz channels 2023-09-07 11:27:43 -05:00
Mike Black W9MDB 2e3e0df4d6 Remove debug from serial.c 2023-08-29 07:45:42 -05:00
Mike Black W9MDB 5963e149a9 Fix IC-590 filter byte
https://github.com/Hamlib/Hamlib/issues/1375
2023-08-28 23:34:28 -05:00
Mike Black W9MDB 5d12e5f8bd Fix IC-905 10Ghz+ set/get freq and lower frequencies too
https://github.com/Hamlib/Hamlib/issues/1375
2023-08-27 15:43:28 -05:00
Mike Black W9MDB 6e7aec3077 Fix IC905 test for 5.8GHz (not MHz)
vi simic905.c
2023-08-27 12:33:11 -05:00
Mike Black W9MDB 875214eb54 Fix IC-905 set_freq -- get_freq should be working
https://github.com/Hamlib/Hamlib/issues/1375
2023-08-27 12:08:00 -05:00
Mike Black W9MDB 8ede3518f1 Remove VFO_OP_XCHG from IC-905 as it's not working in firmware V1.11 anymore
https://github.com/Hamlib/Hamlib/issues/1374
2023-08-26 16:06:20 -05:00
Mike Black W9MDB 42b6fb13f9 Remove hamlib/config.h from nobase_include_HEADERS
https://github.com/Hamlib/Hamlib/issues/1373
2023-08-26 10:13:54 -05:00
Mike Black W9MDB c1f24b2f7a Fix TS2000 SA command 2023-08-25 15:36:12 -05:00
Michael Black 897faf00c0
Merge pull request #1349 from torque/spid-logfix
spid: handle a control stream containing log packets
2023-08-22 22:25:48 -05:00
torque d049b90aa9
spid: flush serial input buffer before command send
This seems to take care of the log data pretty much entirely and is
possibly a much simpler alternative solution to the previous two
commits. However, for full robustness, I think it makes sense to keep
all three of these changes together. Also, it's entirely possible that
this approach introduces a performance regression: I haven't
particularly looked at how the buffer flushing is implemented, but if
it ends up doing looped reads with a timeout, this could slow down
command processing for the SPID object significantly. Since I've only
tested this through the command line interface, I have not taken a
close look at performance.
2023-08-22 17:25:53 -07:00
torque ccab50a7df
spid: account for another type of debug message
When the settings are saved via the front panel on the MD-01, the
following debug messages are printed on COM 0:

    thread_motionController: settings changed!\r\n
    thread_protocols: settings changed!\r\n

Notably, because these aren't timestamped the way the other debug
messages are, they were missing the our debug message sieve and causing
protocol errors. Address this by treating anything that doesn't start
with the ROT2PROG start byte ('W') as a log frame.
2023-08-22 17:25:53 -07:00
torque 470c71dd93
spid: handle a control stream containing log packets
I have an MD-01 controller running firmware 2.0.237 that is connected
to the computer via the COM0 DB9 port. When it receives a control
command to move the rotator, it prints debug logs to the serial output
that look like this:

  input:
    W3600\x0A4500\x0A\x2F\x20

  output:
    W\x03\x06\x00\x00\x0A\x04\x05\x01\x00\x0A\x20
    287925671: in motion\r\n
    287925673: Change motion state M0 to mcsStart\r\n
    287925678: GO  A 0.000000 0.000000 t ---\r\n
    287925680: in motion\r\n
    287925683: Change motion state M1 to mcsStart\r\n
    287925686: GO  E 90.000000 91.000000 t ---\r\n
    287925690: distance to go M0 too small. End.\r\n
    287925694: Change motion state M0 to mcsStopped\r\n
    287925698: Stop on motor 0 on angle 0.000000\r\n
    287925703: Change motion state M1 to mcsRunning\r\n
    287926610: distance to go M1 too small. End.\r\n
    287926613: Change motion state M1 to mcsStopped\r\n
    287926617: Stop on motor 1 on angle 90.000000\r\n

Note that the response frame is not necessarily present in an specific
order relative to the log messages: I have seen it come after the logs
as well. Because the current implementation just slurps up response
bytes without checking the framing or anything, as soon as any of this
log data enters the command stream, all subsequent commands will read
completely bogus responses.

Regardless of whether it's due to a misconfiguration, a weird artifact
of the firmware, or something more sinister, the MD-01 is awkwardly
interspersing its normal fixed-size-frame response with these
line-based log messages. As shown above, the log messages appear to be
consistently of the format <timestamp>: <message>\r\n, where
<timestamp> is some kind of integer timestamp (possibly relative to
unit boot) and <message> is an ASCII string.

Due to poor(?) design decisions by the protocol designers, the frame
start and end bytes are both printable ASCII characters ('W' and ' '
respectively) and the MD-01 response frame contains no other
validation information (such as a CRC), which means that a valid log
line could fairly easily contain a character sequence that is
indistinguishable from a valid response frame, without actually being
a valid response frame.

However, since the log messages appear to be reasonably strictly
structured, we can make a small number of assumptions that will allow
us to reliably separate response frames from log lines without having
to fall back on a heuristic-based parsing strategy. These assumptions
are as follows:

1. A log line will always begin with an ASCII character in the range
   [0-9], none of which are the frame start byte.
2. A log line will never contain \r\n in the middle of the line (i.e.
   multi-line log messages do not exist). This means a log "frame" will
   always be of the form [0-9]<anything>\r\n.
3. The controller will not emit a response frame in the middle of a log
   line.
4. The operating system's serial port read buffer is large enough that
   we won't lose data while accumulating log messages between commands.

Provided the above assumptions are true, a simple state machine can be
used to parse the response by treating the log lines as a different
type of frame. This could be made much more robust by applying
additional heuristics for specific packets (e.g. get_position has some
reasonably strict numerical bounds that could be used to sanity check
the contents of the reply frame).
2023-08-22 17:25:53 -07:00
Mike Black W9MDB 46c0649b23 Fix spacing in k3/k4_stop_morse
https://github.com/Hamlib/Hamlib/issues/1366
2023-08-21 16:33:53 -05:00
Mike Black W9MDB 404ceb8c4b Change send_morse, stop_morse, send_voice_mem, and stop_voicemem to not require a VFO argument
https://github.com/Hamlib/Hamlib/issues/1365
2023-08-21 15:16:32 -05:00
Mike Black W9MDB 453a8cc94f Fix K3/K4 stop_morse
https://github.com/Hamlib/Hamlib/issues/1366
2023-08-21 15:10:41 -05:00
Mike Black W9MDB 5113c6a895 Add simqrplabs.c 2023-08-21 10:31:55 -05:00
Mike Black W9MDB 194906b290 For QRPLabs ignore the IF return length as the differenet models can't agree on the length.
QMX adds an extra space on the end with firmware 1_00_09
https://github.com/Hamlib/Hamlib/issues/1372
2023-08-21 10:13:26 -05:00
Mike Black W9MDB 24e407c82c Fix github build 2023-08-20 16:34:35 -05:00
Mike Black W9MDB 7011b48554 Add rigfreqwalk 2023-08-20 16:16:08 -05:00
Mike Black W9MDB cca3891362 Change L METER to allow meter names in addition to numeric
Change l METER to return meter number=name instead of just number
Hopefully doesn't mess up anybody using this function via rigctl/rigctld uf they parsing the number correctly.
It's easier for users with to use/see text names for both set/get
https://github.com/Hamlib/Hamlib/issues/1369
2023-08-20 16:03:25 -05:00
Mike Black W9MDB 1b0f0ec422 Fix K3 stop_morse RPRT return
https://github.com/Hamlib/Hamlib/issues/1365
2023-08-19 15:35:54 -05:00
Mike Black W9MDB b40da0f6b0 Increase send_morse size to use maximum for rigs or 20 chars (if morse_qsize unknown)
This will still allow for up to 1023 characater to queue up.
No guarantees on which rigs allow for this queuing though.
Kenwood rigs can at least find the buffer status to wait for room but not all rigs do.
https://github.com/Hamlib/Hamlib/issues/1368
2023-08-19 12:36:07 -05:00
Mike Black W9MDB 424e8cc04a Reduce KY wait time in kenwood.s to 50ms instead of 500ms
https://github.com/Hamlib/Hamlib/issues/1366
2023-08-19 11:22:31 -05:00
Mike Black W9MDB 1ad43a44ba Fix KEYERTYPE
https://github.com/Hamlib/Hamlib/issues/1363
2023-08-19 08:43:06 -05:00
Mike Black W9MDB 3492be2562 Fix compile warning in flex6xxx.c 2023-08-19 08:29:05 -05:00
Mike Black W9MDB af86f44eac Fix CW morse infinite loop when error occurs RIG_EINVAL 2023-08-18 22:35:21 -05:00
Mike Black W9MDB d57e4ae185 Improve Kenwood send_morse speed 2023-08-18 17:36:19 -05:00
Mike Black W9MDB 3318766a7c Add stop_morse to elecraft rigs
https://github.com/Hamlib/Hamlib/issues/1366
2023-08-18 16:54:19 -05:00
Mike Black W9MDB 3814f2dadf Add set_voice_mem and stop_voice_mem for K3/K3S/K4
https://github.com/Hamlib/Hamlib/issues/1367
2023-08-18 16:49:35 -05:00
Mike Black W9MDB 36dade6e6c Strip CR/LF from 'b' command input
https://github.com/Hamlib/Hamlib/issues/1365
2023-08-18 12:20:41 -05:00
Mike Black W9MDB 57ebd647eb Add split capability to Xiegu G90
https://github.com/Hamlib/Hamlib/issues/1364
2023-08-18 10:56:58 -05:00
Mike Black W9MDB 7bd9cbef83 Fix simxiegug90.c
https://github.com/Hamlib/Hamlib/issues/1364
2023-08-18 09:29:53 -05:00
Mike Black W9MDB 7eefc77f5d Revert "Fix G90 by changing set/get_mode_with_data to set/get_mode and suppress icom_get_dsp_flt"
G90 Firmware 1.80 fixes the x1a x03 command along with x25/x26
This reverts commit 01730082fb.
2023-08-18 09:27:05 -05:00
Mike Black W9MDB 4faef9e031 Add simxiegug90.c 2023-08-18 08:17:39 -05:00
Mike Black W9MDB 01730082fb Fix G90 by changing set/get_mode_with_data to set/get_mode and suppress icom_get_dsp_flt
https://github.com/Hamlib/Hamlib/issues/1364
2023-08-18 08:06:14 -05:00
Mike Black W9MDB 0edd1df223 Add more KEYERTYPE implementaions to Icom rigs 2023-08-18 00:04:59 -05:00
Mike Black W9MDB 147dea7651 Remove get_dsp_flt for G90 as it does not have that command 2023-08-17 22:57:11 -05:00
Mike Black W9MDB ccd6472f03 Fix KEYERTYPE in ic7300.c and add parsing of STRAIGHT, BUG, PADDLE for rigctl(d)
https://xiegu.eu/downloads/
2023-08-17 22:49:20 -05:00
Mike Black W9MDB 8c63fdeafc Add KEYERTYPE for IC-7300, IC-705, IC-9700
https://github.com/Hamlib/Hamlib/issues/1363
2023-08-17 17:52:03 -05:00
Mike Black W9MDB aa338afa1a Fix parm_gran for Kenwood
https://github.com/Hamlib/Hamlib/issues/1357
2023-08-17 17:12:33 -05:00
Mike Black W9MDB 63bb03cb07 Fix Yaesu gran_parm
https://github.com/Hamlib/Hamlib/issues/1357
2023-08-17 16:57:05 -05:00
Mike Black W9MDB e887152407 Fix parm_gran
https://github.com/Hamlib/Hamlib/issues/1357
2023-08-17 16:04:45 -05:00
Mike Black W9MDB beb69f752a Add BACKLIGHT to IC7300
Add get_powerstat to  IC9700 which speeds up start when auto_power_on is detected
2023-08-14 22:22:55 -05:00
Mike Black W9MDB 5062d565a9 Add the ability to parse '1' in parse_vfo for gpredict 'S 1 1' and 'S 0 1' command
https://github.com/Hamlib/Hamlib/issues/1362
2023-08-14 16:15:03 -05:00
Mike Black W9MDB 2bc28f2dea Fix duplicate printout in get_parm
https://github.com/Hamlib/Hamlib/issues/1361
2023-08-14 12:35:28 -05:00
Mike Black W9MDB 003b50bc57 Standardize extended response in rigctld for level, func, and parm
,l VFOA AGC
get_level: VFOA,AGC,0,RPRT 0

,u VFOA RIT
get_func: VFOA,RIT,0,RPRT 0

,p ANN
get_parm: currVFO,ANN,0,RPRT 0

Error example
,p NB
get_parm: currVFO,NB,RPRT -1

https://github.com/Hamlib/Hamlib/issues/1361
2023-08-13 23:23:23 -05:00
Mike Black W9MDB f0765e6c3a Remove more noisy debug from frame.c 2023-08-12 11:32:27 -05:00
Mike Black W9MDB 7392d206a8 Remove noisy debug from frame.c 2023-08-12 11:06:42 -05:00
Mike Black W9MDB fb3d83a19a Add BANDSELECT to PowerSDR
https://github.com/Hamlib/Hamlib/issues/1353
2023-08-11 17:50:42 -05:00
Mike Black W9MDB ac5018a9a3 Update 60M band for BANDSELECT 2023-08-11 13:31:23 -05:00
Mike Black W9MDB 1f50b88320 Fill out BANDSELECT frequency table
https://github.com/Hamlib/Hamlib/issues/1353
2023-08-11 12:12:17 -05:00
Mike Black W9MDB 6014e3142d Another attempt to fix codeql deprecation warning 2023-08-11 11:35:29 -05:00
Mike Black W9MDB f5e30815b7 Fix codeql 2023-08-11 11:32:53 -05:00
Mike Black W9MDB ef3b90a1be Update codeql 2023-08-11 11:31:57 -05:00
Mike Black W9MDB 72870ec26a Update codeql 2023-08-11 11:11:57 -05:00
Mike Black W9MDB afa51b9863 Add simftdx101 2023-08-11 10:53:00 -05:00
Mike Black W9MDB d7d450df49 Add parm BANDSELECT for Yaesu rigs
'p BANDSELECT' returns current band of VFOA
'P BANDSELECT BAND160M' example selects the 160M band
'P BANDSELECT ?' shows  bands available for the rig
Kenwood rigs will be next
Icom rigs TBD when Icom explains the return from 0x1a 0x01 -- no bandselect possible so manual setting of rig values
https://github.com/Hamlib/Hamlib/issues/1353
2023-08-11 10:40:42 -05:00
Mike Black W9MDB 11d2f34ec8 Fix rigctlsync.1 man page 2023-08-08 15:42:40 -05:00
Mike Black W9MDB 22aee2ff31 Update simulators 2023-08-07 23:30:29 -05:00
Mike Black W9MDB 55370c1e64 Fix non-targetable VFO Icom rigs (e.g. IC7100) error during open routine by call get_freq first to establish echo on or off
https://github.com/Hamlib/Hamlib/issues/1358
2023-08-07 17:21:39 -05:00
Mike Black W9MDB dfb923e001 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-08-05 12:15:50 -05:00
Mike Black W9MDB 23ae64eead Add is_ft710 for SH command in newcat.c 2023-08-05 12:15:28 -05:00
Mike Black W9MDB 457b09d50f Fix FTDX101D/MP to allow new 3200/3500/4000Hz bandwidths
https://github.com/Hamlib/Hamlib/issues/1355
2023-08-05 09:45:24 -05:00
Mike Black W9MDB 93a1d90889 Fix FTDX101D/MP to allow new 3200/3500/4000Hz bandwidths
https://github.com/Hamlib/Hamlib/issues/1356
2023-08-05 09:41:55 -05:00
Mike Black W9MDB 11f8a33e76 Add simic7851 2023-08-05 07:48:21 -05:00
Michael Black 6c3e5a6b7f
Merge pull request #1354 from GeoBaltz/yaesu_level2
Yaesu level2
2023-08-04 08:58:27 -05:00
George Baltz N3GB b1bef6101b Convert RFPOWER to level_gran usage
Two rigs (FTDX3000dm & FT450D) handled slightly abnormally - both should
function as before.

Remove 2 now unused variables to avoid compiler warnings.
2023-08-03 10:01:30 -04:00
George Baltz N3GB 915ee383fb Convert MONITOR_GAIN 2023-08-03 10:01:30 -04:00
George Baltz N3GB cbec337cd3 Convert SQL to use level_gran data. 2023-08-03 10:01:30 -04:00
Mike Black W9MDB 90f0ffcdc9 Add simts950 simts990 2023-08-03 08:14:15 -05:00
Mike Black W9MDB 2194d0dac9 Fix cppcheck notes 2023-08-02 23:40:01 -05:00
Mike Black W9MDB 12f855dbac Fix cppcheck note 2023-08-02 23:38:06 -05:00
Mike Black W9MDB 18390bdbf8 Fix cppcheck note 2023-08-02 23:36:45 -05:00
Mike Black W9MDB aa3cf89886 Fix cppcheck style 2023-08-02 23:33:05 -05:00
Mike Black W9MDB 17c5a8aed9 Fix cppcheck shadow variable 2023-08-02 23:32:02 -05:00
Mike Black W9MDB 364a136000 Fix cppcheck style 2023-08-02 23:28:52 -05:00
Mike Black W9MDB 7c57a22ac8 Fix cppcheck style 2023-08-02 23:16:53 -05:00
Mike Black W9MDB 145c9e0c80 Fix cppcheck style 2023-08-02 23:13:36 -05:00
Mike Black W9MDB bf9835791b Fix cppcheck style 2023-08-02 23:13:01 -05:00
Mike Black W9MDB 10f88807e6 Fix cppcheck sylte 2023-08-02 23:09:37 -05:00
Mike Black W9MDB 82c169527d Fix cppcheck style 2023-08-02 23:08:07 -05:00
Mike Black W9MDB 4f14e14993 Fix cppcheck style 2023-08-02 23:07:22 -05:00
Mike Black W9MDB 652e12a446 Fix cppcheck style 2023-08-02 23:06:21 -05:00
Mike Black W9MDB a29eb33e6e Fix cppcheck error discovery 2023-08-02 23:03:30 -05:00
Mike Black W9MDB 321f3f8ab4 Fix cppcheck error discovery 2023-08-02 23:00:23 -05:00
Mike Black W9MDB a9b3d62f41 Fix cppcheck warning 2023-08-02 22:58:22 -05:00
Mike Black W9MDB 8cf3d5c02c Fix cppcheck style 2023-08-02 22:55:45 -05:00
Mike Black W9MDB 2c81d04ec0 Fix cppcheck warning 2023-08-02 22:55:13 -05:00
Mike Black W9MDB 2f818472ab Fix cppcheck style 2023-08-02 22:52:06 -05:00
Mike Black W9MDB 89214bf132 Fix cppcheck style 2023-08-02 22:51:25 -05:00
Mike Black W9MDB 3eafbcad11 Fix cppcheck styles 2023-08-02 22:47:36 -05:00
Mike Black W9MDB d03affebea Fix cppcheck warnings 2023-08-02 22:33:02 -05:00
Mike Black W9MDB deaf44c8c6 Remove deprecated code 2023-08-02 22:26:34 -05:00
Mike Black W9MDB 6c89f0045f Fix cppcheck warning 2023-08-02 22:24:05 -05:00
Mike Black W9MDB d5828f65ff Fix cppcheck style 2023-08-02 22:22:13 -05:00
Mike Black W9MDB 97b341eb3f Fix precise_time.c 2023-08-02 22:19:20 -05:00
Mike Black W9MDB 494252fe1c Fix cppcheck style error 2023-08-02 22:18:32 -05:00
Mike Black W9MDB d76e28d772 Fix cppcheck warnings 2023-08-02 17:32:51 -05:00
Mike Black W9MDB 5ddfefb91d Fix cppcheck warnings 2023-08-02 17:32:40 -05:00
Mike Black W9MDB bbff9fae9f Fix cppcheck warnings 2023-08-02 17:29:36 -05:00
Mike Black W9MDB 8a49278682 Fix cppcheck warnings 2023-08-02 17:26:29 -05:00
Mike Black W9MDB a4b88ee84a Fix cppcheck warnings 2023-08-02 17:25:12 -05:00
Mike Black W9MDB d48d12c972 Fix cppcheck warnings 2023-08-02 17:24:11 -05:00
Mike Black W9MDB 6a4e31f890 Fix cppcheck warnings 2023-08-02 17:19:51 -05:00
Mike Black W9MDB 2e34bb5991 Fix cppcheck warnings 2023-08-02 17:16:12 -05:00
Mike Black W9MDB 503f27e20c Fix cppcheck warnings 2023-08-02 17:04:07 -05:00
Mike Black W9MDB f0821041a2 Fix cppcheck warnings 2023-08-02 17:03:22 -05:00
Mike Black W9MDB 0228614a17 Fix cppcheck warnings 2023-08-02 16:58:58 -05:00
Mike Black W9MDB 17382c03c6 Fix cppcheck warnings 2023-08-02 16:54:02 -05:00
Mike Black W9MDB 6aa13e45c7 Fix cppcheck warnings 2023-08-02 16:49:06 -05:00
Mike Black W9MDB 56de3bb25d Fix FTDX10 SM command 2023-08-02 16:13:55 -05:00
Mike Black W9MDB 942e4cd950 Fix get_level AF for FTDX10 2023-08-02 16:09:32 -05:00
Mike Black W9MDB 232d7626cc Yaesu rigs (at least some of them cannot use MG command when in RTTY or CW mode
So we return RIG_OK for set which just ignores it and level=0 in this case
2023-08-02 16:01:10 -05:00
Mike Black W9MDB 2709be053c Fix new.cat EX030109 command 2023-08-02 15:25:44 -05:00
Mike Black W9MDB e155dfbf5e Fix cppcheck errors
https://github.com/Hamlib/Hamlib/issues/1350
2023-08-02 12:50:03 -05:00
Mike Black W9MDB 6c794a17bd Fix cppcheck errors
https://github.com/Hamlib/Hamlib/issues/1350
2023-08-02 12:41:25 -05:00
Mike Black W9MDB 428500bb1c Fix cppcheck error
https://github.com/Hamlib/Hamlib/issues/1350
2023-08-02 12:37:36 -05:00
Mike Black W9MDB 6ef0f32d56 Add KS to simftdx1200.v 2023-08-01 17:05:59 -05:00
Mike Black W9MDB 89797e5a54 Fix rig_set_freq to only set vfo at end when needed
https://github.com/Hamlib/Hamlib/issues/1126
2023-07-31 22:40:42 -05:00
Mike Black W9MDB c452cd31d9 Add simic705 simulator 2023-07-31 17:10:17 -05:00
Mike Black W9MDB 801d34e3fb Fix reverse split for Yaeus VFO_SUB rigs
https://github.com/Hamlib/Hamlib/issues/1103
2023-07-31 15:31:06 -05:00
Mike Black W9MDB d9b1cfb404 Fix fifo.c mutex handling 2023-07-31 09:08:34 -05:00
Mike Black W9MDB 5446b2c99d Fix dependency for ignore.swg 2023-07-30 16:01:35 -05:00
Mike Black W9MDB 71629cf2f3 Hopefully fix Mac perl binding build 2023-07-30 11:24:16 -05:00
Mike Black W9MDB c251a075ab Fix MAC build 2023-07-30 09:49:10 -05:00
Mike Black W9MDB ddb128bbf7 Make fifo.c thread safe 2023-07-30 07:55:28 -05:00
Mike Black W9MDB 006f724dae Make fifo.c thread safe 2023-07-30 07:53:17 -05:00
Mike Black W9MDB b4ddf64b31 Assume rig is powered on if get_powerstat is not implemented 2023-07-30 07:25:57 -05:00
Mike Black W9MDB 21c5c3f419 Update comments in rig.c 2023-07-30 07:17:44 -05:00
Mike Black W9MDB 2852fba73f Increase sleep during power on for Icom to wait for serial port to wake up 2023-07-29 15:10:36 -05:00
Mike Black W9MDB b24cad1278 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-07-28 17:32:56 -05:00
Mike Black W9MDB bd1fcbe025 Adjust icom power up to use the mininum number of 0xfe's needed for the baud rate 2023-07-28 17:32:23 -05:00
Mike Black W9MDB ebb6efba8d Add simic7200.c fully compatible with FLRig
Add simic7000.c
Improve simpowersdr.c
2023-07-28 17:02:00 -05:00
Michael Black 1260921daf
Merge pull request #1347 from GeoBaltz/fix3
Fix segfault on rigctl exit
2023-07-28 07:25:21 -05:00
George Baltz N3GB 192b5fe7a5 Fix segfault on rigctl exit
If rigctl does a recovery close/open cycle, a freed buffer gets reused.
This can cause segfault or worse.
2023-07-28 08:13:03 -04:00
Michael Black 342e082fbb
Merge pull request #1346 from GeoBaltz/yaesu_level
Yaesu level
2023-07-27 16:14:58 -05:00
George Baltz N3GB 2ccac887d2 New for old - update level_gran for ft9000Old 2023-07-27 16:29:33 -04:00
George Baltz N3GB 2f3c632ff6 Convert ANTIVOX & VOXGAIN 2023-07-27 15:01:55 -04:00
George Baltz N3GB bb260d2640 Convert COMP 2023-07-26 16:58:26 -04:00
George Baltz N3GB d1106cae8b Convert MICGAIN to level_gran
Update rig info
Round to nearest integer
2023-07-26 16:58:26 -04:00
George Baltz N3GB a975a6e8a6 Convert set/get AF, RF to use level_gran info. 2023-07-26 16:58:26 -04:00
George Baltz N3GB ee5b96443f Add basis for level_gran use in newcat.c
Do the easy one - CWPITCH
2023-07-26 16:58:26 -04:00
Mike Black W9MDB 13a8c0fb1d Add get_gpio to man pages
https://github.com/Hamlib/Hamlib/issues/1121
2023-07-26 08:15:57 -05:00
Mike Black W9MDB bf3ac3bbec Fix bogus warning in ic7300.c 2023-07-25 22:05:17 -05:00
Mike Black W9MDB 00d94d410f Make windows termios.c a touch faster
Improve debug in termios.c
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-25 10:33:49 -05:00
Mike Black W9MDB 802892887a Remove get_vfo from FT9000Old 2023-07-25 06:35:59 -05:00
Mike Black W9MDB bbdd1dc312 Add new rig FT9000Old version that does not have VS command 2023-07-24 22:41:00 -05:00
Mike Black W9MDB fcba1cab20 Make icom echo check skip the 1st two bytes of the frame
Saw an instance where the 1st 0xfe was corrupted so this allows for that
2023-07-24 17:35:14 -05:00
Mike Black W9MDB da96315dc5 Fix serial.c
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-24 12:19:14 -05:00
Mike Black W9MDB 2c40ebcbc1 Fix termios.c
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-24 12:17:56 -05:00
Mike Black W9MDB 09143fcff9 Make find_port win32_serial_find_port so it can used elsewhere
Use WIN32 PurgeComm instead of polling chars
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-24 12:15:37 -05:00
Mike Black W9MDB f5b4cd6047 Move structure from termios.c to win32_termios.h
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-24 12:08:18 -05:00
Mike Black W9MDB 557e9a71e5 Change fifo push to eliminate chars > x80
sending 0xff through rigctld was pushing -1 and causing peek to lock up
2023-07-24 09:44:40 -05:00
Mike Black W9MDB 75569ab3f2 Update simic7610 2023-07-24 08:58:49 -05:00
Mike Black W9MDB 23639557a0 Revert "Remove rig_flush from icom/frame.c"
This reverts commit ca3f19fbd6.
Evidence showing this is needed when sequencing is lost
Instead we need to improved Windows serial_flush
2023-07-24 08:30:14 -05:00
Mike Black W9MDB c288dacb54 Add simic7610 2023-07-24 08:30:04 -05:00
Mike Black W9MDB d02b9f02b1 Force flush of rig when first opened
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-23 16:04:31 -05:00
Mike Black W9MDB ca3f19fbd6 Remove rig_flush from icom/frame.c
Speeds up Windows serial i/o by about 6ms per call for Icom rigs
https://github.com/Hamlib/Hamlib/issues/1123
2023-07-23 14:55:27 -05:00
Mike Black W9MDB 9c246ed3fb Disable use_cached_freq/mode for Icom rigs -- we can't tell which VFO we're on
https://github.com/Hamlib/Hamlib/issues/1221
2023-07-23 09:19:25 -05:00
Mike Black W9MDB 448c41978f Add some capability to simelecraft.c 2023-07-23 08:42:06 -05:00
Mike Black W9MDB 9ad070c33f Add gpio command to rigctl(d) usable with pttport setting CM108
e.g. to set gpio2 on use 'gpio GPIO2 1" and off "gpio GPIO2 0"
Should work with GPIO1-4
New API funcions rig_cm108_get_bit rig_cm108_set_bit
https://github.com/Hamlib/Hamlib/issues/1121
2023-07-22 10:32:25 -05:00
Mike Black W9MDB d28ce6b798 Bump up some 1024 buffers to 2048 to avoid overflow error 2023-07-21 11:46:58 -05:00
Mike Black W9MDB c9fc80fea1 Clean up warning in simic7300.c 2023-07-21 11:35:34 -05:00
Mike Black W9MDB d8d716f0f2 Fix h command for newer Yaesu rigs -- now reads channel correctly.
https://github.com/Hamlib/Hamlib/issues/1342
2023-07-21 10:16:25 -05:00
Mike Black W9MDB f48f6152ff Disallow CR/LF in fifo push 2023-07-21 09:50:42 -05:00
Mike Black W9MDB c5cc47dcd1 Make fifo routines print hex when needed 2023-07-21 09:44:24 -05:00
Mike Black W9MDB ef4489172a Update man pages for send_morse info 2023-07-21 09:31:57 -05:00
Mike Black W9MDB 9b89e3fe23 Fix dtr/rts serial port set for amp and rot 2023-07-20 17:46:39 -05:00
Mike Black W9MDB 8fe3080139 Reduce debug level misc.c 2023-07-20 17:38:05 -05:00
Mike Black W9MDB aacf060e11 Remove set_vfo B in ft100 set_ptt as WJST-X was getting confused about being in reverse split 2023-07-20 16:59:57 -05:00
Mike Black W9MDB 7adc91d0ea Prevent segfault in fifo peek 2023-07-20 15:29:47 -05:00
Mike Black W9MDB f33fa95d8d Update rigctl/d man pages 2023-07-20 15:22:11 -05:00
Mike Black W9MDB 2da6c400f7 Add RTS/DTR capability to rotctl and ampctl 2023-07-20 11:58:26 -05:00
Mike Black W9MDB 2f838f2264 Fix make dist error 2023-07-20 11:23:06 -05:00
Mike Black W9MDB c17b5da379 Move serial_cfg_params to common inlude fill as it is applicate to all serial devices 2023-07-20 11:12:24 -05:00
Mike Black W9MDB 1688f25ed5 Add hamlib_version2 do dump_caps and dump_state 2023-07-20 10:17:55 -05:00
Mike Black W9MDB 4c8994d905 Add hamlib_version to dump_state 2023-07-20 10:01:30 -05:00
Mike Black W9MDB d0eed2b412 Fix windows build dependency on version_dll.rc to hamlibdatetime.h 2023-07-20 09:06:21 -05:00
Mike Black W9MDB 17c7c4d68f Update man pages some more 2023-07-20 07:52:43 -05:00
Mike Black W9MDB 8161cda2fc Update man pages 2023-07-20 07:49:56 -05:00
Mike Black W9MDB df9d9dfbd1 Change testrig.c back to original port 2023-07-19 22:11:26 -05:00
Mike Black W9MDB 64cb40f066 Fix segfault with testrig and fifo bad values 2023-07-19 12:30:21 -05:00
Mike Black W9MDB 2c83486775 Minor changes to icom.c 2023-07-19 12:07:16 -05:00
Mike Black W9MDB 3a3c51bcf6 Slow down morse_data_handler_stop a bit for RigPi
Make FIFO volatile
Disable keyspd change -- just doesn't work on most rigs
2023-07-19 11:05:17 -05:00
Mike Black W9MDB 1fdc3f3eaf Disable wait_morse in send_morse loop -- was causing inter-char delays 2023-07-19 09:37:12 -05:00
Mike Black W9MDB 2395d37afd Reduce debug in iofunc.c 2023-07-19 08:24:56 -05:00
Mike Black W9MDB 79737df92a Change testcpp.cc back to dummy rig for make test 2023-07-18 22:39:55 -05:00
Mike Black W9MDB d6b8575eb3 Fix simic7300 to work with testcpp.cc 2023-07-18 22:33:14 -05:00
Mike Black W9MDB 0540fa4f12 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-07-18 22:17:09 -05:00
Mike Black W9MDB c1212b5bf3 Allow morse send to continue until fifo is flushed 2023-07-18 22:16:40 -05:00
Mike Black W9MDB 0a9796f2e7 Disallow send_morse when not in CW/CWR mode 2023-07-18 17:50:29 -05:00
Michael Black daa86f5b7a
Merge pull request #1339 from mikaelnousiainen/ft710-fixes
Improve Yaesu FT-710 backend
2023-07-18 15:45:37 -05:00
Mikael Nousiainen d0fba93c65 Bump version for FT-710 2023-07-18 23:32:36 +03:00
Mikael Nousiainen ebc10b84f4 Fix more FT-710 issues and implement the new CF clarifier command 2023-07-18 23:31:15 +03:00
Mike Black W9MDB f7bed3320e Fix set_split_mode for Icom rigs
Add some more send_morse fixes - still can't do speed change yet
2023-07-18 12:37:54 -05:00
Mike Black W9MDB b58c0a0fa4 IC-9700 VFO selection now works for VFOA, VFOB, MainA, MainB, SubA, and SubB
WSJT-X does not set VFOB mode when VFOA mode is already selected...must change VFOA mode and back again to set VFOB
2023-07-18 10:20:53 -05:00
Mike Black W9MDB 56ad3ac1ef Update SLICE information in rig.h 2023-07-17 17:42:34 -05:00
Mike Black W9MDB 983a9fae0b Update rigctl.1 'U' items to current set and add more information 2023-07-17 17:40:58 -05:00
Mike Black W9MDB 330322e745 Add WPM notes to send_morse 2023-07-17 17:25:47 -05:00
Mike Black W9MDB 876e79c34d Add DUAL_WATCH for IC756 2023-07-17 17:22:54 -05:00
Mike Black W9MDB 015de3b5a4 Add fifo peek 2023-07-17 10:26:47 -05:00
Mike Black W9MDB 5df0ae02f1 Allow W command to use any hex terminator 2023-07-17 09:33:18 -05:00
Mike Black W9MDB 52df1e4f0a Allow fd terminator for W command. Any fd value, e.g. fd, 0xfd, \0xfd will work 2023-07-17 09:28:37 -05:00
Mike Black W9MDB 3814224c89 Moving CW speed change to morse thread 2023-07-17 07:36:03 -05:00
Mike Black W9MDB 9b04338080 Give a warning for the IC-9700 if trying to select VFOB while in satmode 2023-07-16 16:54:59 -05:00
Mike Black W9MDB e167d0f1a0 Fix FT-991 poweron routine 2023-07-16 15:08:33 -05:00
Mike Black W9MDB 7962a51f05 Update simic7300.c 2023-07-16 12:16:11 -05:00
Mike Black W9MDB 902cfd708f Improve Icom set_powerstat=1
Original 2023-07-16T09:28:43.323319-0600:    4:rig_set_powerstat: elapsed=10236ms
IC-7300  2023-07-16T09:46:48.814844-0600:    4:rig_set_powerstat: elapsed=4020ms
IC-9700  2023-07-16T10:36:27.239828-0600:    4:rig_set_powerstat: elapsed=5717ms
The goal is to tweak each rig for fastest result but need more testers for that
Slowest right now is IC-9700 which is the default value
Total timeout will be just over 10.5 seconds to allow rig to power on
https://github.com/Hamlib/Hamlib/issues/1325
2023-07-16 10:38:59 -05:00
Mike Black W9MDB 932cca4c84 Revert "IC-705 cannot do get_powerstat"
This is handled in icom.c generic routine
This reverts commit a2c7227676.
2023-07-15 22:55:07 -05:00
Mike Black W9MDB d834a5a50d Revert "IC-7610 cannot do get_powerstat"
This is handled in icom.c generic routine
This reverts commit 685f8c3862.
2023-07-15 22:54:04 -05:00
Mike Black W9MDB 8cd135e2ce Move morse handler after rig_open 2023-07-15 22:24:17 -05:00
Mike Black W9MDB 685f8c3862 IC-7610 cannot do get_powerstat 2023-07-15 16:12:38 -05:00
Mike Black W9MDB a2c7227676 IC-705 cannot do get_powerstat 2023-07-15 15:52:25 -05:00
Mike Black W9MDB a360d2aaec Return when +/- is send in send_morse 2023-07-15 08:42:13 -05:00
Mike Black W9MDB f3941cdf62 send_morse should now accept + and - to increase/decrease KEYSPD by 5WPM 2023-07-15 07:55:27 -05:00
Mike Black W9MDB 2204ebef56 Add simic7100.c back 2023-07-15 07:46:01 -05:00
Mike Black W9MDB ecf914fca9 Clean up simulators/Makefile.am 2023-07-15 07:24:27 -05:00
Mike Black W9MDB 71f4e47006 Fix simicgeneric.c Makefile.am 2023-07-15 07:20:54 -05:00
Mike Black W9MDB 820549faf6 Rename simicom routines to shorter version 2023-07-15 07:14:31 -05:00
Mike Black W9MDB 8a99adc5eb Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-07-13 12:09:40 -05:00
Mike Black W9MDB c4aa3c51f9 async_data_enabled = 0
Until we get Windows serial I/O fixed
2023-07-13 12:09:11 -05:00
Michael Black 3821ef92fa
Merge pull request #1336 from mikaelnousiainen/fix-morse-handler-1
Fix FIFO pop() sign issue and clean up morse data handler code
2023-07-12 06:30:38 -05:00
Mikael Nousiainen c7e73ddf8f Fix FIFO pop() sign issue and clean up morse data handler code 2023-07-12 10:52:42 +03:00
Mikael Nousiainen c1829e3de0 Add ft710.h 2023-07-12 00:36:49 +03:00
Mikael Nousiainen d54912e375 FT-710 fixes, part 1 2023-07-12 00:29:32 +03:00
Mike Black W9MDB 5a8bd96427 Fix CPU usage problem in new morse data handler
https://github.com/Hamlib/Hamlib/issues/1334
2023-07-11 11:41:54 -05:00
Mike Black W9MDB 778889e06a Fix rigctlcom.c and rigctlsync. version 2023-07-11 11:19:07 -05:00
Mike Black W9MDB 0225d51a60 Update simulators 2023-07-11 11:16:51 -05:00
Mike Black W9MDB 556e1dd198 Add simicom7600 2023-07-11 11:16:23 -05:00
Mike Black W9MDB 94cce72428 Add hamlib_version command to rigctl/rigctld and format version date as ISO8601 2023-07-11 11:13:04 -05:00
Mike Black W9MDB 79657a4b4d Ensure bytes_read is updated when errors occur during Windows serial i/o 2023-07-11 11:02:03 -05:00
Mike Black W9MDB 84048e3e94 Fix newcat.c TX validation 2023-07-11 10:11:13 -05:00
Mike Black W9MDB a5034b88ab Shutdown threads before the rig is closed 2023-07-11 08:36:09 -05:00
Mike Black W9MDB b37e9877bd Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-07-10 17:27:09 -05:00
Mike Black W9MDB 2ff99809f1 Remove validation from BD/BU commands in newcat.c
https://github.com/Hamlib/Hamlib/issues/1331
2023-07-10 17:26:45 -05:00
Michael Black bb9a93cc35
Merge pull request #1332 from GeoBaltz/levels_4
Levels 4
2023-07-10 14:59:27 -05:00
George Baltz N3GB b2ea9da61c Enable level_gran[] checking for all calls to kenwood_set_level.
Part of issue #1144
2023-07-10 15:39:41 -04:00
George Baltz N3GB 649f09449a Yet more missing level defs. 2023-07-10 15:39:41 -04:00
George Baltz N3GB 34fd238291 Still more level_gran data. 2023-07-10 15:39:41 -04:00
George Baltz N3GB 14cb2304b0 Use level_gran[] values in kenwood_get_level. 2023-07-10 15:39:41 -04:00
Mike Black W9MDB fdc074e1b8 Rename FIFO to FIFO_RIG to avoid collision with freedv FIFO 2023-07-10 06:57:11 -05:00
Mike Black W9MDB 04c65d9d7e Add Quisk as a rig 2023-07-09 23:06:05 -05:00
Mike Black W9MDB d22653a69d Fix stop_morse to work with new send_morse 2023-07-09 17:04:39 -05:00
Mike Black W9MDB e9fd0fba40 send_morse now uses a fifo queue and can send up to 1024 chars in one message
it relies on the rig backend returning an error when the rig's CW queue is full
2023-07-09 16:51:33 -05:00
Mike Black W9MDB 97c9cb1961 Add status for rigctl dumpcaps 2023-07-09 12:28:13 -05:00
Mike Black W9MDB 1ddaf63856 Fix model_name, mfg_name, version, and copyright for rigctld dumpcaps 2023-07-09 12:24:26 -05:00
Michael Black ebf054f4cc
Merge pull request #1330 from mikaelnousiainen/fix-power-status-and-serial-port-issues
Fix power status and serial port issues
2023-07-08 11:51:31 -05:00
Mikael Nousiainen c6d0365c3b Merge master and fix conflicts 2023-07-08 19:40:10 +03:00
Mike Black W9MDB 9218d208ef Re-enable async 2023-07-08 09:46:54 -05:00
Mike Black W9MDB 0e25df0b4e Remove timeout test code from iofunc.c
https://github.com/Hamlib/Hamlib/issues/1329
2023-07-08 08:01:05 -05:00
Mike Black W9MDB ba9a1006e8 Fix rig.c 2023-07-07 22:39:05 -05:00
Mike Black W9MDB bcad19d563 Add morse_data items 2023-07-07 22:34:45 -05:00
Mike Black W9MDB af506f8e15 Implement next phase of threaded rig_send_morse 2023-07-07 22:23:28 -05:00
Mike Black W9MDB fda5b984e7 Add current_vfo to cache debug statement 2023-07-07 22:22:57 -05:00
Mike Black W9MDB 8ebe230029 Comment out unused var 2023-07-07 22:12:55 -05:00
Mike Black W9MDB 4b43c755a6 Add fifo.h to Makefile.am 2023-07-07 15:37:06 -05:00
Mike Black W9MDB 4f3bdbdffe Add fifo routine to be used for CW queueing 2023-07-07 15:26:36 -05:00
Mike Black W9MDB ce052db3a2 Remove get_vfo from ic9700 ic7610 and ic785x 2023-07-07 12:06:38 -05:00
Mike Black W9MDB 3cc6b7614c Fix IC7610 caps structure for new firmware test 2023-07-07 11:47:59 -05:00
Mike Black W9MDB 3bda269494 Add elapsd to rig_test_cw 2023-07-04 22:20:34 -05:00
Mike Black W9MDB 90585cbb6e Add testmW2power.c 2023-07-04 17:36:42 -05:00
Mike Black W9MDB 24f17730f4 Add \test command to rigctl -- first test routine is "cw"
https://github.com/Hamlib/Hamlib/issues/1281
2023-07-04 17:31:07 -05:00
Mike Black W9MDB 52cba4630b Change FLRig PKT modes to PKTUSB/LSB instead of RTTY
https://github.com/Hamlib/Hamlib/issues/1327
2023-07-03 07:56:04 -05:00
Mike Black W9MDB ad1e63efa1 Fix FT-991 Fake It failing to retrun to receive frequency
Yaesu rigs will no return from set_ptt until TX0 is achieved
Restrict 300ms wait just to FTDX3000 due to antenna switching
This speeds up set_ptt off for other Yaeus rigs
https://github.com/Hamlib/Hamlib/issues/1326
2023-07-02 17:50:38 -05:00
Michael Black 58e5e260a5
Merge pull request #1324 from koarlchen/rigctld-get-powerstat-separator-character
Fix 'get_powerstat' command provided by rigctld regarding extended response protocol
2023-07-02 17:28:52 -05:00
Michael Black 858f2b66c3
Merge pull request #1315 from j-gallardo/j-gallardo-patch-1
Update password.c
2023-07-02 17:28:18 -05:00
max 44fa32c8cd Fix 'get_powerstat' command provided by rigctld by taking care of the given separator according to the extended response protocol 2023-06-29 16:20:00 +02:00
Mike Black W9MDB 7a713634e3 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-06-29 09:19:00 -05:00
Mike Black W9MDB 4c02a70ea3 Fix IC-76XX rig_mW2power -- fixed any such rig
https://github.com/Hamlib/Hamlib/issues/1323
2023-06-29 09:17:46 -05:00
Michael Black 0f706dfaae
Merge pull request #1322 from koarlchen/man-rigctld-typo-section-command
Fix minor typo in man page for rigctld
2023-06-29 07:35:13 -05:00
max 16b83b76b3 Fix minor typo (missing u character) 2023-06-29 13:34:14 +02:00
Mike Black W9MDB 25ad13cea9 Add BG2FX FC4/C/CR/L 2023-06-28 12:48:30 -05:00
Mike Black W9MDB 4171598eaf Initialize rig->state.targetable_vfo 2023-06-27 22:58:56 -05:00
Mike Black W9MDB f3cab55c4f Change set_mode_x26 to do correct VFO for 7600/7610
https://github.com/Hamlib/Hamlib/issues/1319
2023-06-27 14:28:37 -05:00
Mike Black W9MDB a3ac6e0be3 Change to using RIG_IS macros
Fix segfault on non 76XX rigs
https://github.com/Hamlib/Hamlib/issues/1319
2023-06-27 11:24:27 -05:00
Mike Black W9MDB c0c70b0146 Fix IC-7600 set/get freq to use new 0x25/x26 capability if available
https://github.com/Hamlib/Hamlib/issues/1319
2023-06-27 08:54:43 -05:00
Mike Black W9MDB 2728d47a60 For TS-2000 turn off VOX before TX 2023-06-27 06:55:16 -05:00
Mike Black W9MDB 4bd904502b Fix TS2000 RIG_VFO_C errors 2023-06-26 23:16:48 -05:00
Mike Black W9MDB b158b224ab Fix TS-2000 set_ptt
https://github.com/Hamlib/Hamlib/issues/1321
2023-06-26 23:07:40 -05:00
Mike Black W9MDB fcef98e60d Improve Malachine band change time a bit 2023-06-23 23:38:44 -05:00
Mike Black W9MDB 5c3f26cc56 Cover more cases for detecting rig power 2023-06-20 17:32:16 -05:00
Mike Black W9MDB e9d0320111 Update simts590.c 2023-06-20 17:31:09 -05:00
Mike Black W9MDB 28396bad7a Updates to anytone -- more development needed 2023-06-20 17:29:58 -05:00
Mike Black W9MDB 5a26bde236 Add simts450.c 2023-06-20 17:13:54 -05:00
Mike Black W9MDB 105cc6e3c6 Reduce unknown vfo in cache.c to WARNING 2023-06-20 10:05:47 -05:00
Mike Black W9MDB 3283c3b22f Reduce no get_vfo message to WARNING 2023-06-20 10:03:35 -05:00
Mike Black W9MDB 701aaab1c6 Ensure usb echo off is determined first thing for Icom rigs
https://github.com/Hamlib/Hamlib/issues/1318
2023-06-20 09:32:10 -05:00
Mike Black W9MDB c5937b23e5 Initialize rig->state_depth and remove one debug statement 2023-06-20 08:07:32 -05:00
Mike Black W9MDB 1c2033c17f Add comment to rig.h about not modifying callbacks structure 2023-06-18 07:45:45 -05:00
Mike Black W9MDB 751935d838 Fix without-cxx-binding build
https://github.com/Hamlib/Hamlib/issues/1317
2023-06-17 23:00:55 -05:00
Mike Black W9MDB 5281361e07 Update rig->caps in netrigctl.c for level_gran and parm_gran
https://github.com/Hamlib/Hamlib/issues/1305
2023-06-17 15:43:16 -05:00
Mike Black W9MDB efb567f667 Make sure to unexport the GPIO port during close
https://github.com/Hamlib/Hamlib/issues/1316
2023-06-17 11:57:07 -05:00
Mike Black W9MDB 97811d2aa7 Remove whitespace after backslash in lib/Makefile.am 2023-06-17 08:29:15 -05:00
j-gallardo 4dfe98b0fe
Update password.c
I had problems compiling with declaration inside 'for' loops.
2023-06-17 08:51:53 +02:00
Mike Black W9MDB b3a61cf00e astyle icom.c 2023-06-16 23:24:25 -05:00
Mike Black W9MDB f14c241f43 Fix IC-905 frequency -- needed to be 10Hz units 2023-06-16 22:32:13 -05:00
Mike Black W9MDB fa31975650 Allow RIG_PTT_NONE to run through the backend for PTT
This allows dummy rig to be used in WSJT-X with Tune and such
https://github.com/Hamlib/Hamlib/issues/1313
2023-06-16 09:50:40 -05:00
Mike Black W9MDB d9b936618c Remove VFO_TX from dummy 2023-06-11 23:34:15 -05:00
Mike Black W9MDB f9d27d0e35 Add get_vfo_list to help in rigctl 2023-06-11 14:15:32 -05:00
Mike Black W9MDB 8e94bc63d0 Fix millisecond abbreviations and capitalization errors 2023-06-11 08:49:57 -05:00
Mike Black W9MDB 33d13f7849 Remove HAMLIB_TRACE from iofunc.c 2023-06-10 00:01:24 -05:00
Mike Black W9MDB 07dde9ae0f Remove Makefile.Windows
3b7760e4d2 (commitcomment-116188707)
2023-06-09 23:27:38 -05:00
Mike Black W9MDB ebedbbbfb5 Clean up debug a bit 2023-06-09 22:51:54 -05:00
Mike Black W9MDB dc1fa7f450 Remove ENTERFUNC from frame.c to balance 2023-06-09 22:39:24 -05:00
Mike Black W9MDB 2e610be031 Balance RETURNFUNC in ic7300.c 2023-06-09 22:33:36 -05:00
Mike Black W9MDB c640f66326 Balance RETURNFUNS2 in rig.c 2023-06-09 22:17:51 -05:00
Mike Black W9MDB 88a1d88e0f Fix icom.c set_mode_with_data to skip mode if same and skip bandwidth if same or nochange
https://github.com/Hamlib/Hamlib/issues/1312
2023-06-09 17:06:46 -05:00
Mike Black W9MDB 03e72c3a99 Add set_cache to rig_set_split_freq_mode 2023-06-09 14:48:34 -05:00
Mike Black W9MDB 788db91e2f Change Malachite post_write_delay to 250ms based on user testing on Linux & Windows 2023-06-09 12:38:45 -05:00
Mike Black W9MDB 163d10651b Add stop_morse and wait_morse to PowerSDR 2023-06-09 09:07:36 -05:00
Mike Black W9MDB c4f635ab5d Add send_morse to PowerSDR 2023-06-08 23:42:21 -05:00
Mike Black W9MDB 224d68d1ac Speed up Malachite normal operations with 125ms post write requirement instead of 400ms
400ms needs for band changes on Malachite
Fix BUILTINFUNC calls to compile correctly -- this is for debugging only
2023-06-08 17:34:39 -05:00
Mikael Nousiainen 4aec461337 Improve Icom power status handling. Add auto power on/off to netrigctl. 2023-06-08 18:56:29 +03:00
Mike Black W9MDB 6100bfdc11 Fix silly error in sleep.c 2023-06-08 09:03:04 -05:00
Mike Black W9MDB 8d8f224aff Reduce debug in sleep.c -- seems stable now 2023-06-08 09:01:28 -05:00
Mike Black W9MDB 32569d4020 Do not allow cache hit for 55Hz and 56Hz values used by WSJT-X 2023-06-07 17:46:10 -05:00
Mike Black W9MDB 9bec3fad4f Hopefully speed up Malachite on get commands by temporarily changin post_write_delay to 400ms 2023-06-07 17:36:19 -05:00
Mike Black W9MDB 05cf554671 This seems to fix the DLL backwards compatiblity now -- more testing needed
Revert "Remove timeout_retry as it broke DLL compatibility"

This reverts commit 1c08cd7a64.
2023-06-07 07:26:39 -05:00
Mike Black W9MDB 203920e293 FIx FT817 set/get_mode -- thanks to Mooner Salem K6AQ
https://github.com/drowe67/freedv-gui/issues/409
2023-06-07 07:05:05 -05:00
Mike Black W9MDB 835b66e7df Give the FT-920 some time during PTT OFF to allow it to occur
Fake-It was not working probably due to this as can't set freq while PTT
2023-06-06 23:34:15 -05:00
Mike Black W9MDB 92363f6b0c Re-add field to rig_state for DLL alignment
https://github.com/Hamlib/Hamlib/issues/1299
2023-06-06 15:12:52 -05:00
Mike Black W9MDB 72071a313e Fix FT817 get_mode
https://github.com/Hamlib/Hamlib/issues/1308
2023-06-06 14:22:28 -05:00
Mike Black W9MDB 138060d4d9 Fix flex6xxx ZZAR command 2023-06-06 14:17:48 -05:00
Mike Black W9MDB 527dbaad34 Add LOCK in send_morse 2023-06-06 12:40:51 -05:00
Mike Black W9MDB b25db51a51 Allow icom_send_morse to repeat a single char transmit when receiving a NAK 2023-06-06 10:42:30 -05:00
Mike Black W9MDB bc50d9c273 +04d actaully kicks out 3-digits and not 4 -- the + is included in the width value
Revert "Fix PowerSDR ZZAR command format -- may need another fix for SmartSDR format to be different"

This reverts commit 1e5563909d.
2023-06-06 10:16:21 -05:00
Mike Black W9MDB 1e5563909d Fix PowerSDR ZZAR command format -- may need another fix for SmartSDR format to be different 2023-06-06 10:09:32 -05:00
Mike Black W9MDB 21f0e560f7 For Icom rigs when PASSBAND_NOCHANGE is requested do not change the filter setting
https://github.com/Hamlib/Hamlib/issues/1309
2023-06-06 09:44:25 -05:00
Mike Black W9MDB e8af3447aa Fix ft817.c build for MacOS and Pi
https://github.com/Hamlib/Hamlib/issues/1308
2023-06-06 08:36:50 -05:00
Mike Black W9MDB 5276e25a92 FIx from Brian G8SEZ for FT817 get_mode
And another fix for returning the correct mode hopefully for DIG modes
https://github.com/Hamlib/Hamlib/issues/1308
2023-06-06 08:14:37 -05:00
Mike Black W9MDB acc42665ef Allow FT817 to write to EEPROM for set_mode
Should not cause too much wear on the EEPROM
https://github.com/Hamlib/Hamlib/issues/1308
2023-06-05 08:34:59 -05:00
Mike Black W9MDB 55cbf80719 Fix compile warning in rig.c 2023-06-04 17:44:31 -05:00
Mike Black W9MDB 4e4d8e39d8 Fix sleep.c function 2023-06-04 17:43:33 -05:00
Mike Black W9MDB eb97c7c107 Change anytone.c to use bluetooth protocol
Update some things to keep debug quiet during thread operations in anytone.c
2023-06-04 15:56:01 -05:00
Mike Black W9MDB e1e570d19a Add documentaion for FT-817 2023-06-04 07:56:10 -05:00
Mike Black W9MDB 48b01aa3ff Add RIG_MODE_PKTLSB to FT817 even though it must be switched using Menu 26
Add a warning message to notify the user
https://github.com/Hamlib/Hamlib/issues/1308
2023-06-04 07:18:00 -05:00
Mike Black W9MDB a6de41e206 rigctld can now see RIG_LEVEL values correctly
https://github.com/Hamlib/Hamlib/issues/1305
2023-06-03 16:50:30 -05:00
Mike Black W9MDB 412221d346 Update anytone.c a bit 2023-06-03 16:48:20 -05:00
Mike Black W9MDB 2491d208d9 Fix FT450 and FT991 RIG_LEVEL_NR values
https://github.com/Hamlib/Hamlib/issues/1305
2023-06-02 15:16:38 -05:00
Mike Black W9MDB cd0b685ed2 Change FT450 and FT991 RIG_LEVEL_NR back
https://github.com/Hamlib/Hamlib/issues/1305
2023-06-02 10:25:05 -05:00
Mike Black W9MDB 729554ea80 Update NEWS 2023-06-02 10:24:46 -05:00
Mike Black W9MDB b34f18af40 Promote IC905 to stable since it seems to work OK 2023-05-31 14:22:37 -05:00
Mike Black W9MDB 1fb69e18fd Update 2023-05-31 11:40:09 -05:00
Mike Black W9MDB 82954c0549 Change Yaeus sleep afer PTT off to 300ms instead of 100ms
DX3000 was failing frequency change in Fake It mode probably due to antenna switching times
This was a separate rx/tx antennas
2023-05-31 08:36:55 -05:00
Mike Black W9MDB fe209d7cce Fix Yaeus LVL_NR to default 1-15 range and set FT450 to 1-11 ranges
https://github.com/Hamlib/Hamlib/issues/1305
2023-05-31 07:55:50 -05:00
Mike Black W9MDB fd86001ead Revert "Remove multicast from rig_state structure as it breaks backwards compability on DLL with WSJT-X"
This didn't fix the DLL compatibility problem
This reverts commit 77d9d11f92.
2023-05-31 07:27:34 -05:00
Mike Black W9MDB c3cf7a9874 Change IC-905 to ALPHA status 2023-05-31 07:18:59 -05:00
Mike Black W9MDB 2c8f8a9c29 Added rig_set_debug_filename due to Python not being able to pass a FILE*
https://github.com/Hamlib/Hamlib/issues/1307
2023-05-31 07:04:20 -05:00
Mike Black W9MDB 5745457d7f Fix anytone thread deletion 2023-05-30 22:10:19 -05:00
Mike Black W9MDB c85cf58235 astyle rigctl_parse.c 2023-05-30 16:10:52 -05:00
Mike Black W9MDB bdd16c8f20 Fix W command for rigctld
https://github.com/Hamlib/Hamlib/issues/1306
2023-05-30 15:57:33 -05:00
Mike Black W9MDB 5541deb812 Fix get_ptt command for anytone 2023-05-29 22:27:31 -05:00
Mike Black W9MDB 8fcd8242af Change anytone set_ptt to use new PTT On hold command 2023-05-29 22:16:23 -05:00
Mike Black W9MDB 1ea7e23235 Reduce get_vfo anytone command to 1 instead of 2 sequences with new command found 2023-05-29 22:11:14 -05:00
Mike Black W9MDB 16137cd72a Change mutex locking locations in anytone.c 2023-05-29 15:58:14 -05:00
Mike Black W9MDB 75699adbbb Add TARGETABLE_MODE for IC7700 since VFOB can have independent mode
https://github.com/Hamlib/Hamlib/issues/1304
2023-05-29 15:23:24 -05:00
Mike Black W9MDB dcd8ac58cf Update comment in anytone.c 2023-05-29 10:09:46 -05:00
Mike Black W9MDB 84643407ff Reduce debug in anytone.c thread unless CACHE debug level is requested 2023-05-29 09:56:29 -05:00
Mike Black W9MDB 07a9f321b4 Fix anytone set/get VFO
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-28 16:38:27 -05:00
Mike Black W9MDB f37c24d052 Anytone process 0xaa 0x53 message 2023-05-27 16:30:04 -05:00
Mike Black W9MDB e5bb7355b8 More anytone fixes
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 16:21:14 -05:00
Mike Black W9MDB 4ae3519c4e Revert "Allow generic_read_string to terminate on expected_len"
This reverts commit 00b6e0ecd7.
2023-05-27 15:13:22 -05:00
Mike Black W9MDB 08abfbe19a Revert "Fix read_string_generic to only use expected_len when expected_len == 0"
This reverts commit 9b748bdb2e.
2023-05-27 15:11:40 -05:00
Mike Black W9MDB 1f95e06cc1 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-05-27 14:59:22 -05:00
Mike Black W9MDB 9b748bdb2e Fix read_string_generic to only use expected_len when expected_len == 0
00b6e0ecd7 (commitcomment-115297173)
2023-05-27 14:58:07 -05:00
Mike Black W9MDB 4e8acc728c Fix anytone/Makefile.am to include anytone.h
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 12:58:18 -05:00
Mike Black W9MDB 34f20cc970 Add thread to anytone.c to do the keep alive it needs
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 12:51:24 -05:00
Mike Black W9MDB c4a56a4cf0 Fix simatd578 one more time
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 12:00:44 -05:00
Mike Black W9MDB 33a1b2dfb0 Fix simatdt578 entry 2023-05-27 11:12:27 -05:00
Mike Black W9MDB 3b45dfa4b8 Add AnyTone D578UVIII
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 11:04:56 -05:00
Mike Black W9MDB ab6058da03 Add simatd578.c 2023-05-27 10:45:45 -05:00
Mike Black W9MDB 00b6e0ecd7 Allow generic_read_string to terminate on expected_len
https://github.com/Hamlib/Hamlib/issues/1303
2023-05-27 10:07:32 -05:00
Mike Black W9MDB 77d9d11f92 Remove multicast from rig_state structure as it breaks backwards compability on DLL with WSJT-X
This is due to the callbacks structure being realigned as the state structure expanded
https://github.com/Hamlib/Hamlib/issues/1299
2023-05-26 17:11:43 -05:00
Mike Black W9MDB 81dd39319b Clean up startup messages in newcat.c when power is off 2023-05-26 12:19:50 -05:00
Mike Black W9MDB ccd832d4cb Improve power on message in rig.c 2023-05-26 11:04:42 -05:00
Mike Black W9MDB 8d465a257e Fix a couple more debug statements 2023-05-26 10:53:32 -05:00
Mike Black W9MDB 06f5d8376f Fix debug message eol 2023-05-26 10:52:04 -05:00
Michael Black f01a165ec7
Merge pull request #1302 from mikaelnousiainen/power-status-bug-fixes
Power status bug fixes
2023-05-26 10:47:35 -05:00
Mikael Nousiainen fd68723da1 Fix issues with power status handling in rigctl+rigctld and the Yaesu backend 2023-05-26 18:03:20 +03:00
Mikael Nousiainen 8730e6a0b1 IC-746 and IC-756ProII+III support AGC_TIME 2023-05-23 23:25:27 +03:00
Michael Black 610bf2d903
Merge pull request #1301 from GeoBaltz/man1
Man1
2023-05-23 15:05:54 -05:00
George Baltz N3GB b6fe91504f Avoid NULL dereference in debug statement. 2023-05-23 13:14:28 -04:00
Mike Black W9MDB 79492d4284 Put enter/leave CAT in FT767GX.c again and reduce write_delay to zero.
Hopefully speeds things up and still works but may need to tweak write_delay
https://github.com/Hamlib/Hamlib/issues/1300
2023-05-23 10:11:51 -05:00
George Baltz N3GB ae14af4bc1 Add missing commands to man pages 2023-05-23 10:59:29 -04:00
George Baltz N3GB a7d24a99db Fix typos (missing '('s ) in man pages. 2023-05-23 10:59:28 -04:00
Mike Black W9MDB 083669dbc8 Hopefully speed up FT767GX considerably
https://github.com/Hamlib/Hamlib/issues/1300
2023-05-22 11:25:57 -05:00
Mike Black W9MDB 657e41fd09 Add rig_date_strget to DLL for WSJTX use 2023-05-22 09:32:04 -05:00
Mike Black W9MDB 7309b24411 Add simicom7100 2023-05-22 09:31:51 -05:00
Mike Black W9MDB dbf1cacac6 Special version of misc.c for debugging 2023-05-22 09:10:42 -05:00
Mike Black W9MDB 15a01889cd Prevent segfault in rig_get_caps_int/cptr calls 2023-05-22 08:47:01 -05:00
Mikael Nousiainen 9e1adcfdb8 Merge master and fix conflicts 2023-05-21 23:11:26 +03:00
Mikael Nousiainen cce66d3257 Fix power on/off bugs: rig_open() should succeed even if rig is powered off, auto power-on should not be automatically enabled (prevents turning rig off), fix Kenwood and Yaesu power on/off sequences for all rigs 2023-05-21 23:01:03 +03:00
Mike Black W9MDB 52358d7922 Add some more debug to rig_get_caps_int
https://github.com/Hamlib/Hamlib/issues/1299
2023-05-21 10:15:22 -05:00
Mike Black W9MDB 082bf83daa Add some debug to misc.c to figure out why WSJT-X is seeing ptt_type==0 2023-05-21 09:45:57 -05:00
Mike Black W9MDB 4832cc1bb2 Improve kenwood.c debug a little bit to reduce confusion
https://github.com/Hamlib/Hamlib/issues/1298
2023-05-21 08:15:47 -05:00
Mike Black W9MDB ece6a7ae1a Add a slight delay after opening the rig port to allow serial port settling 2023-05-20 23:41:18 -05:00
Mike Black W9MDB 6eb0735c75 Update Icom rigs that cannot query power status 2023-05-20 22:22:02 -05:00
Mike Black W9MDB 8b9a8d6649 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-05-20 22:11:37 -05:00
Mike Black W9MDB 125273f7a2 Change IC7610 so use 0x03 for get_powerstat 2023-05-20 22:10:38 -05:00
Michael Black c5f0e1e577
Merge pull request #1297 from GeoBaltz/levels_3
Levels 3
2023-05-20 12:53:23 -05:00
George Baltz N3GB 14dbe41e76 Add Elecraft defaults to makefile. 2023-05-20 13:30:40 -04:00
George Baltz N3GB e5f6b4e9d2 Fix the comment about float levels.
And now that the comment parses, fix the check to respect it.

I seriously doubt anyone will ever use this, but you never know.
2023-05-20 11:13:16 -04:00
George Baltz N3GB d3c2ebcc1f Round 4 of level_gran updates.
Fill in more holes.  This should cover the Kenwood and Elecraft rigs,
with most of the callers of kenwood_set_level vetted.  Also fills in
some other data in rig->caps.

Still looking for a way to (programatically) verify that AGC data is
checked and processed correctly.
2023-05-20 11:13:16 -04:00
George Baltz N3GB d27283ceb7 Update RIG_LEVEL_READONLY_LIST.
Drop duplicate RFPOWER_METER, add TEMP_METER.
2023-05-20 11:13:16 -04:00
George Baltz N3GB 3029260582 Add default level values for Elecraft rigs.
Add limits for 0.0-1.0 float values.
2023-05-20 11:13:16 -04:00
George Baltz N3GB 7a69042876 Enable full level checking for TS-890S.
Turn on checking against level_gran on the TS-890S,
so I can eat my own dog food.
2023-05-20 11:13:16 -04:00
George Baltz N3GB ea37ad1b21 Remove hard-coded constants.
Use more data already in rig->caps instead of hard coding values.
2023-05-20 11:13:16 -04:00
George Baltz N3GB 05f04730d7 Round 3 of level_gran updates. 2023-05-20 11:13:16 -04:00
Mike Black W9MDB 1c08cd7a64 Remove timeout_retry as it broke DLL compatibility 2023-05-19 23:50:57 -05:00
Mike Black W9MDB ca62509013 Fix simftdx3000.c 2023-05-19 23:46:14 -05:00
Mike Black W9MDB e2a1a00f3a Add some more LOCKs and astyle rig.c 2023-05-19 23:45:36 -05:00
Mike Black W9MDB 9528132f81 In icom.c show poweron with OK retval 2023-05-19 23:44:51 -05:00
Mike Black W9MDB 67344a66a7 Fix TS590 SH/SL command expected length 2023-05-19 16:32:26 -05:00
Mike Black W9MDB 04ee4ec580 Fix IC7800 to use get_freq instead of 0x18 command since it cannot read power status 2023-05-18 11:40:43 -05:00
Mike Black W9MDB 673ef04b0f Add x25_always to ic7610.c ic785x.c 2023-05-17 23:56:33 -05:00
Mike Black W9MDB a9d098bab3 Add send_voice_mem to kenwood.c and TS890 2023-05-17 22:41:29 -05:00
Mike Black W9MDB 44c9f83ae0 Improve power on sequencing for Yaesu rigs
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-17 17:26:53 -05:00
Mike Black W9MDB df53b9a928 Add simicom7300 2023-05-17 16:18:25 -05:00
Mike Black W9MDB 0f5982272a Add icom_get_vfo for IC7610 and IC785X 2023-05-17 14:10:32 -05:00
Mike Black W9MDB 474428082d Add rig_get_vfo for IC9700 -- seems we can use x07 0Xd2 to determine main/sub vfo now 2023-05-17 14:03:08 -05:00
Mike Black W9MDB 14c535a01b Add RIG_VFO_CURR check to suppress bogus warning 2023-05-17 12:22:12 -05:00
Mike Black W9MDB b607482651 Fix stupid error in rig_debug 2023-05-17 12:05:58 -05:00
Mike Black W9MDB 3c93d83848 Reduce debug in rig.c to CACHE for the lock function 2023-05-17 12:04:19 -05:00
Mike Black W9MDB efc90d30de Remove another temporary debug from iofunc.c 2023-05-17 11:45:50 -05:00
Mike Black W9MDB 84187e976d Remove temporary DEBUG from iofunc.c 2023-05-17 11:36:09 -05:00
Mike Black W9MDB 445e5070c1 Fix 30-second timeout on Windows for the async thread to stop
https://github.com/Hamlib/Hamlib/issues/1295
2023-05-17 10:25:33 -05:00
Mike Black W9MDB 630f5866a7 Completely remove single ; valcmd in newcat.c 2023-05-16 17:16:28 -05:00
Mike Black W9MDB bba58dff7b Revert newcat.c valcmd to ID; as single ; was causing timeouts on FT-991 and possibly others
Using ; required a 100ms sleep after receiving the ?; response and that sleep can be removed when using ID;
22ms time vs 135ms time to set freq on FT-991 now
2023-05-16 17:04:09 -05:00
Mike Black W9MDB e02c42f629 Reduce hl_usleep debug to DEBUG_CACHE 2023-05-16 17:03:47 -05:00
Mike Black W9MDB f43aa43671 Fix newcat.c VFOB validation 2023-05-16 15:57:22 -05:00
Mike Black W9MDB f691be94d9 Fix sleep.c conversion from usec to sec 2023-05-16 15:56:50 -05:00
Mike Black W9MDB c14d6f0fa2 Add timeout value to debug in iofunc.c
https://github.com/Hamlib/Hamlib/issues/695
2023-05-16 07:54:17 -05:00
Mike Black W9MDB 1ad664be4c Add line# to a couple of debug statements in iofunc.c to distinguish them
https://github.com/Hamlib/Hamlib/issues/695
2023-05-16 07:52:00 -05:00
Mike Black W9MDB 01a7eee18d Reduced loop time in termios.c to 1ms vice 10ms
https://github.com/Hamlib/Hamlib/issues/695
2023-05-16 07:38:21 -05:00
Mike Black W9MDB f4a08e10bf Add winmm.lib to Win32 build
https://github.com/Hamlib/Hamlib/issues/1290
2023-05-15 14:24:16 -05:00
Mike Black W9MDB 6142e98c23 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-05-15 11:53:42 -05:00
Mike Black W9MDB 73465d16c4 Remove cJSON.c from cppcheck as it segfaults on it right now 2023-05-15 11:48:59 -05:00
Mike Black W9MDB 58655be355 Replace hl_usleep with monotonic sleep shamelessly stolen from FLRig
https://github.com/Hamlib/Hamlib/issues/1290
2023-05-15 11:45:54 -05:00
Mike Black W9MDB d3b912aadb Add precise_time.c to misc to help speed up Windows
https://github.com/Hamlib/Hamlib/issues/1290
2023-05-15 11:45:40 -05:00
Mike Black W9MDB 1265ede384 Add precise_time.c to misc to help speed up Windows 2023-05-15 11:44:17 -05:00
Mike Black W9MDB 31733cea22 Reduce lock debug to VERBOSE
https://github.com/Hamlib/Hamlib/issues/695
2023-05-15 07:49:02 -05:00
Mike Black W9MDB eff6f2d554 Fix TS590 vfo test to ensure correct A/B when CURR/TX/RX is used
https://github.com/Hamlib/Hamlib/issues/1293
2023-05-15 07:45:38 -05:00
Mike Black W9MDB 647c5b37ef Fix hl_usleep again to undo prior fix
Fix hl_usleep to not sleep if 1ms or less is called for -- speeds things up on Windows dramatically
2023-05-14 15:42:00 -05:00
Mike Black W9MDB 29d3833228 Fix nanosleep timing 2023-05-14 14:11:13 -05:00
Mike Black W9MDB 5e8de57f54 Allow using nanosleep in hl_usleep 2023-05-14 13:52:05 -05:00
Michael Black fa9948b17d
Merge pull request #1294 from mikaelnousiainen/improve-read-timeout-retry-logic
Improve read timeout retry logic
2023-05-14 13:19:34 -05:00
Mikael Nousiainen a43cd80799 Set default timeout_retry value to 1 and allow per-rig override of the setting. Disable timeout_retry during serial flush to avoid slowing down flushes. 2023-05-14 21:13:39 +03:00
Mike Black W9MDB 176a63c726 Add simft847.c 2023-05-14 13:12:45 -05:00
Mike Black W9MDB 0ad834f59e Add simft847 to Makefile.am 2023-05-14 13:11:58 -05:00
Mike Black W9MDB 05ab130f91 Add width/shift debug to ts590.c
https://github.com/Hamlib/Hamlib/issues/1293
2023-05-14 12:50:49 -05:00
Mike Black W9MDB 6651345065 Add SF command for TS-590S/SG
Still need to add bandwidth get/set
https://github.com/Hamlib/Hamlib/issues/1293
2023-05-14 11:06:22 -05:00
Michael Black 10f1f3a7cd
Merge pull request #1289 from mikaelnousiainen/bug-fixes-1
Fix a number of issues in the current Hamlib code
2023-05-14 07:26:34 -05:00
Mikael Nousiainen eea12aff0a Merge master 2023-05-14 12:08:15 +03:00
Mikael Nousiainen 93e8a2879d Fix read timeout retry logic 2023-05-14 11:57:09 +03:00
Mikael Nousiainen c75fdeb3e4 Make retries in case of read timeout optional and configurable via set-conf option. When not absolutely necessary, they will significantly slow down flushing and normal serial communications with a rig 2023-05-14 11:52:48 +03:00
Mike Black W9MDB 7c5a636a64 Add FTDX10 to CAT TOT 100ms rigs 2023-05-13 22:27:23 -05:00
Mike Black W9MDB 09c57dd961 Check multicast for null
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 16:26:46 -05:00
Mike Black W9MDB c3cfb760bb Align lock with depth check
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 16:24:52 -05:00
Mike Black W9MDB 7f4665723a Add lock function affected rig_get_freq and rig_set_freq
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 16:20:55 -05:00
Mike Black W9MDB 12384c7796 Change rigctl_parse to use ENTERFUNC2 instead of ENTERFUNC
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 16:11:46 -05:00
Mike Black W9MDB 300c0c415a Fix some state.depth values 2023-05-13 16:02:41 -05:00
Mike Black W9MDB 006ca07b3c Fix multicast.h
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 15:44:08 -05:00
Mike Black W9MDB 75b1b20fa2 Remove dead code from multicast.h
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 15:41:38 -05:00
Mike Black W9MDB c4d0df1f86 Balance RETURNFUNC2 in cache.c 2023-05-13 15:22:31 -05:00
Mike Black W9MDB 14cdbcba31 Balance RETURNFUNC in cache.c 2023-05-13 15:11:11 -05:00
Mike Black W9MDB c2d1f04507 Add comments about multicast mutex
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 14:54:43 -05:00
Mike Black W9MDB 8ad62b1af8 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-05-13 10:49:26 -05:00
Mike Black W9MDB 99baa872bf Move sleep for serial before the flush 2023-05-13 10:49:08 -05:00
Mike Black W9MDB 28e2d8f45c Move sleep for serial before the flush 2023-05-13 10:48:39 -05:00
Mike Black W9MDB 43b24caa01 Fix rigctld timeout on open
https://github.com/Hamlib/Hamlib/issues/1288
2023-05-13 10:41:41 -05:00
Mike Black W9MDB 26aa57aded Add rig_lock and pthread mutex for multicast
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 08:11:50 -05:00
Mike Black W9MDB fc96ec0874 Add new rig_lock function for eventual use in threading with new multicast
https://github.com/Hamlib/Hamlib/issues/695
2023-05-13 08:00:06 -05:00
Mikael Nousiainen e89687668d Add flushing of rig port, including async data pipes, after \send_raw and \send_cmd to drain any extra rig responses 2023-05-13 00:04:37 +03:00
Mike Black W9MDB c7cfc78303 Add IC7700 to rigs that don't have 0x25 2023-05-12 14:36:40 -05:00
Mike Black W9MDB 1f98f0d347 Try again to fix ft847 vfo reading
https://github.com/Hamlib/Hamlib/issues/1286#issuecomment-1545971701
2023-05-12 11:19:02 -05:00
Mikael Nousiainen 92215dfd2a Fix bugs in \send_raw command and add possibility to specify any command terminator character. Add \stop_morse to Dummy rig. 2023-05-12 10:01:32 +03:00
Mike Black W9MDB dfc5e72d02 Have FT847 default to sat_mode when Sub VFO is requested
Don't see any way to query satellite mode
https://github.com/Hamlib/Hamlib/issues/1286#issuecomment-1544662994
2023-05-11 16:36:12 -05:00
Mike Black W9MDB bdecc7f73e Only do close functions when comm_state is true
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-10 23:27:40 -05:00
Mike Black W9MDB 5f55b0ea48 Since we do two timeouts now for serial we can cut serial timeouts in half
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-10 23:23:33 -05:00
Mike Black W9MDB f03b03878e Speed up timeout during rig_open by not doing any retries
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-10 23:00:12 -05:00
Mike Black W9MDB 6285c4a6b8 Remove unused variable in newcat.c
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-10 17:28:49 -05:00
Mike Black W9MDB 131f8443a3 Improve Yaesu poweron detection speed in default condition of already powered on
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-10 17:24:41 -05:00
Mike Black W9MDB e9cc1881dc Fix x25cmdfails detection in icom.c
https://github.com/Hamlib/Hamlib/issues/1277#issuecomment-1542655090
2023-05-10 14:42:22 -05:00
Mikael Nousiainen c80d45378a More fixes to command 0x25 logic 2023-05-10 22:39:45 +03:00
Mikael Nousiainen 716637c4ab Fix x25cmdfails logic to allow failure detection only once. Subsequent failures after an initial successful use of command 0x25 will not prevent use of the command. 2023-05-10 22:35:44 +03:00
Mikael Nousiainen 1596e125b6 Fix use of uninitialized variable 2023-05-10 20:57:33 +03:00
Mikael Nousiainen 4b8de5f96d Change float level granularity formatting to use %f to avoid E notation. Fix AGC_TIME level range for Icom rigs. Fix listing of AGC levels in \dump_caps. Add \stop_morse and \wait_morse in \dump_caps. Add simulation of responses in \send_cmd_rx and \send_raw for dummy rig (and if rig port type is NONE). Fix other minor issues. 2023-05-10 20:53:18 +03:00
Mike Black W9MDB 42d6cce77b Add multicast tests to .gitignore 2023-05-10 11:21:30 -05:00
Mike Black W9MDB d2924c7ae7 Add a flush in newcat.c get_powerstat 2023-05-09 14:13:17 -05:00
Mike Black W9MDB 58e6ee3553 I think we can work without config.h being included in rig.h
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 12:00:53 -05:00
Mike Black W9MDB 322ba6901c Remove multicast.h from src/Makefile.am 2023-05-09 11:57:11 -05:00
Mike Black W9MDB 04e10da6e3 Move multicast.h to include/hamlib and fix some other things
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 11:46:54 -05:00
Mike Black W9MDB b67803358c Update multicast.c JSON
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 09:23:46 -05:00
Mike Black W9MDB 7985286208 Add PTT to multicast packet
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 09:15:41 -05:00
Mike Black W9MDB f97736649f Remove #pragma from rigtestmcastrx.c
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 08:24:41 -05:00
Mike Black W9MDB 7835329e32 Fix mingw build for multicast.c
https://github.com/Hamlib/Hamlib/issues/695
2023-05-09 07:00:03 -05:00
Mike Black W9MDB 1d96a84b44 Fix dangling pointer in aor.c 2023-05-08 23:58:52 -05:00
Mike Black W9MDB 4f0d78f1d9 Fix cppcheck warnings 2023-05-08 23:56:28 -05:00
Mike Black W9MDB 7101c699c8 Fix cppcheck warnings 2023-05-08 17:35:44 -05:00
Mike Black W9MDB 46d31277c1 Fix responsebuf in kpa.c 2023-05-08 17:31:11 -05:00
Mike Black W9MDB ca763d4ff1 Clean up JSON
https://github.com/Hamlib/Hamlib/issues/695
2023-05-08 17:15:26 -05:00
Mike Black W9MDB a4c10c3206 Fix cppcheck warnings 2023-05-08 12:16:51 -05:00
Mike Black W9MDB f45aea8859 Add simicom9100.c and fix compilation of all others due to POSIX requirements 2023-05-08 12:04:08 -05:00
Mike Black W9MDB 247f0f72cf Excludes IC9100 from updating x25cmdfails from satmode
The IC9100 never supports 0x25
https://github.com/Hamlib/Hamlib/issues/1284
2023-05-08 10:30:24 -05:00
Mike Black W9MDB dad55ef148 astyle files getting ready for WSJT-x-2.7.0rc1 2023-05-08 07:37:13 -05:00
Mike Black W9MDB f55e7b8348 Rename multicast test routines and clean up things a bit
Now works on mingw32 and Linux
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 23:23:01 -05:00
Mike Black W9MDB 6fa16ea77f Fix mingw compile warning
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 17:38:45 -05:00
Mike Black W9MDB 023a6bd3fb Add EXPORT to multicast.h
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 17:32:36 -05:00
Mike Black W9MDB 9fd6af9699 Fix mingw compile warning 2023-05-07 17:28:08 -05:00
Mike Black W9MDB b55a46a0f6 Fix mingw compile warnings 2023-05-07 17:27:31 -05:00
Mike Black W9MDB e505ed37db Fix compile warning on mingw 2023-05-07 17:26:31 -05:00
Mike Black W9MDB 62b9a12e89 Add multicastserver test
Fix compile warnings on mingw
2023-05-07 17:17:50 -05:00
Mike Black W9MDB 2a758b96ab Fix compile warning in tci1x.c 2023-05-07 17:17:01 -05:00
Mike Black W9MDB 6e6d192c91 Fix mingw compile warning 2023-05-07 17:13:21 -05:00
Mike Black W9MDB 5d130be05c Fix another mingw compile warning on rotorez.c 2023-05-07 16:44:43 -05:00
Mike Black W9MDB 5648e587a8 Fix mingw compile warning on rotorez.c 2023-05-07 16:42:44 -05:00
Mike Black W9MDB a8d9d90025 Fix multicast.c build on mingw
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 15:34:31 -05:00
Mike Black W9MDB b0357025e6 Add multicast.c to hamlib build
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 15:32:43 -05:00
Mike Black W9MDB 65a3305fa8 Add multicastclient to tests/Makefile.am
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 13:22:38 -05:00
Mike Black W9MDB b6f1cc4bc8 Attempt to get multicastclient working on mingw
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 10:59:43 -05:00
Mike Black W9MDB 7ab97b5e7a Remove ARPA_INET warning
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 09:47:10 -05:00
Mike Black W9MDB 95375a5587 Fix multicast test compile
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 09:45:27 -05:00
Mike Black W9MDB 6c6b1799f9 Fix make distcheck
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 07:42:13 -05:00
Mike Black W9MDB 58b01989b8 Fix mingw build some more
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 07:34:21 -05:00
Mike Black W9MDB 1022596f76 Fix mingw build again
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 07:29:59 -05:00
Mike Black W9MDB 60782af15a Fix github build
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 07:27:44 -05:00
Mike Black W9MDB 1b3cee99fb Fix multicast compile on mingw
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 07:21:15 -05:00
Mike Black W9MDB e3c2a8d6ca Add first implementation of multicast functions and multicastclient.c test program.
Next step will be to implement this when rig is opened.
This will turn Hamlib into a polling system in addition to polling -- caching will handle repeated requests
This should mean basic functions of freq, mode, split, ptt (and others when implemented) will have almost
immediate responses as only the cached values should be used.
https://github.com/Hamlib/Hamlib/issues/695
2023-05-07 06:50:35 -05:00
Mike Black W9MDB f94ca77399 Fix NAK in simicom9700.c 2023-05-07 06:50:05 -05:00
Mike Black W9MDB 4a8a82ffc4 Fix icom.c 0x25 detection and add IC9100 to known rigs that doesn't have 0x25
https://github.com/Hamlib/Hamlib/issues/1284
2023-05-05 09:38:07 -05:00
Mike Black W9MDB 41113de9a2 Reduce debug level in iofunc.c 2023-05-05 09:10:43 -05:00
Mike Black W9MDB fd4b3eb103 Reduce read_string_generic timeout debug to TRACE level 2023-05-05 08:11:51 -05:00
Mike Black W9MDB 1ab828f8ef Reduce icom.c 0x25 warning to trace level -- the error is expected when rig does not support 0x25 2023-05-04 07:20:16 -05:00
Mike Black W9MDB d044ad998c Add retry to icom_get_ptt
https://github.com/Hamlib/Hamlib/issues/1283
2023-05-03 16:18:02 -05:00
Mike Black W9MDB ec64850901 Change netrigctl.c to return POWER_OFF when timeout occurs as opposed to invalid command
https://github.com/Hamlib/Hamlib/issues/1282
2023-05-03 15:40:00 -05:00
Mike Black W9MDB 5134fc5fda Progress on Expert amplifier 2023-04-30 17:12:57 -05:00
Mike Black W9MDB 1e9ecb079a Fix RT21 2nd device for elevation
https://github.com/Hamlib/Hamlib/issues/1257
https://github.com/Hamlib/Hamlib/issues/1258
2023-04-30 17:04:34 -05:00
Mike Black W9MDB 4ada211713 Do 1 retry when timing out in read_string_generic 2023-04-30 17:02:09 -05:00
Mike Black W9MDB 6e1b58b980 Update test.json 2023-04-30 11:46:34 -05:00
Mike Black W9MDB 40a1e7a2c4 Update multicast plan 2023-04-30 11:46:12 -05:00
Mike Black W9MDB 5a079e03a4 Restore elecraft extended K2 cmd set to startup value 2023-04-30 09:52:24 -05:00
Mike Black W9MDB 34566d433b Add simft817.c 2023-04-30 08:50:12 -05:00
Mike Black W9MDB 2b37e8b79b Fix debug statement in rig.c 2023-04-29 17:10:25 -05:00
Mike Black W9MDB e4acbac647 Try to reopen rig on hard error
https://github.com/Hamlib/Hamlib/issues/1282
2023-04-29 16:58:18 -05:00
Mike Black W9MDB fdf1c3cdab Fix auto_power_on with netrigctl when powered off but still responding to PS; command
https://github.com/Hamlib/Hamlib/issues/1282
2023-04-29 16:13:48 -05:00
Mike Black W9MDB 3f7cf2d0b3 Improve power on message 2023-04-29 16:07:05 -05:00
Mike Black W9MDB 9318df8e75 Update NEWS 2023-04-29 12:56:00 -05:00
Mike Black W9MDB a349c3e07b Change ft817 startup timeout to 1500ms to avoid a timeout
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-29 07:57:07 -05:00
Mike Black W9MDB e5a6055d57 Another attempt to fix ft817_get_vfo
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-28 22:30:07 -05:00
Mike Black W9MDB 215aa6b92c Try to fix ft817 get_vfo to return the valid status bye
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-28 08:20:57 -05:00
Mike Black W9MDB e82f127965 Allow icom read_frame to return when bus collision occurs
https://github.com/Hamlib/Hamlib/issues/1280
2023-04-26 15:38:08 -05:00
Mike Black W9MDB addee81f43 Fix rigctld sending an extra space in front of send_morse string
Single space still works
https://github.com/Hamlib/Hamlib/issues/1281
2023-04-25 22:27:38 -05:00
Mike Black W9MDB 07ba41d551 Add a retry in icom frame.c in case of collision
https://github.com/Hamlib/Hamlib/issues/1280
2023-04-25 11:07:25 -05:00
Mike Black W9MDB da94c8b770 Change ft817.c to not mask the low bit on eepromp reads -- hopefully this doesn't break everything
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-25 08:52:42 -05:00
Mike Black W9MDB 1db6487b8d Add simspid.c 2023-04-25 08:26:12 -05:00
Mike Black W9MDB 1c1b9e7511 Enable async_io for IC-746 and IC-746PRO
https://github.com/Hamlib/Hamlib/issues/1280
2023-04-25 08:13:03 -05:00
Mike Black W9MDB 6fadbfb112 Change Icom 0x25 logic to only allow one detection
https://github.com/Hamlib/Hamlib/issues/1277
2023-04-25 08:00:43 -05:00
Mike Black W9MDB 44807be556 Add simrotorez 2023-04-25 07:58:55 -05:00
Mike Black W9MDB f153398480 Update NEWS 2023-04-22 12:09:33 -05:00
Mike Black W9MDB 6422bc51d5 Add version to rig_init debug info 2023-04-22 11:39:03 -05:00
Mike Black W9MDB 4ba3a02512 FT-817 add 100ms delay during ft817_open to avoid initial cmd error during startup
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-22 11:22:16 -05:00
Mike Black W9MDB 2af9f2c5b3 For FT-817 add sleep after set_vfo to allow vfo swap to occur
https://github.com/Hamlib/Hamlib/issues/1278
2023-04-21 22:05:42 -05:00
Mike Black W9MDB 6c410f164e This did not solve the problem with Win4Yaesu
Revert "https://github.com/Hamlib/Hamlib/issues/1275"

This reverts commit c02ded5b49.
2023-04-21 16:04:04 -05:00
Michael Black 72266a677d
Merge pull request #1276 from dforsi/fix/typos
Fix name of command in --version and usage outputs
2023-04-20 17:19:14 -05:00
Mike Black W9MDB c02ded5b49 https://github.com/Hamlib/Hamlib/issues/1275 2023-04-19 15:15:56 -05:00
Daniele Forsi IU5HKX 6eee376cbf Fix name of command in the version text 2023-04-19 21:49:30 +02:00
Daniele Forsi IU5HKX f390aa499d Fix name of command in the usage and version texts 2023-04-19 21:41:07 +02:00
Michael Black 3b66959f4e
Merge pull request #1274 from mikaelnousiainen/ts590sg-fixes
Fix and extend TS-590(S/SG) backend
2023-04-17 07:21:10 -05:00
Mikael Nousiainen 1a59ce2ae2 Fix and extend TS-590(S/SG) backend 2023-04-15 00:25:29 +03:00
Michael Black 4551199de1
Merge pull request #1273 from dforsi/fix/cppcheck
Fix check for RIG_BUSBUSY
2023-04-11 16:40:18 -05:00
Daniele Forsi IU5HKX 6f0efd59e6 Fix check for RIG_BUSBUSY
Fixes a cppcheck warning:
rigs/icom/frame.c:510:19: style: Redundant condition: The condition 'i != 14' is redundant since 'i < 0' is sufficient. [redundantCondition]
        if (i < 0 && i != RIG_BUSBUSY) /* die on errors */
2023-04-11 23:28:46 +02:00
Michael Black 6c197dbc1c
Merge pull request #1270 from dforsi/fix/segfault
Fix segfaults with malformed input and wrong command line arguments
2023-04-11 15:46:56 -05:00
Daniele Forsi IU5HKX 1c72440c51 Fix segfaults with malformed input and wrong command line arguments
Fixes:
NULL dereference.

Steps to reproduce:
echo L x | tests/ampctl
echo L x | tests/rigctl
echo L x | tests/rotctl
2023-04-10 19:44:49 +02:00
Daniele Forsi IU5HKX e11b4bd01c Fix segfaults with malformed input and wrong command line arguments
Fixes:
NULL dereference.

Steps to reproduce:
echo L | tests/ampctl
echo L | tests/rigctl
echo L | tests/rotctl
2023-04-10 19:44:40 +02:00
Mike Black W9MDB 905c9fff95 Fix SDR++ giving wrong answer for get_powerstat
https://github.com/Hamlib/Hamlib/issues/1266
2023-04-10 09:37:01 -05:00
Michael Black 6c1d83ed86
Merge pull request #1269 from ncw/fix-qcx-cw-sending
Fix QRP Labs QCX Morse Sending
2023-04-09 22:14:00 -05:00
Michael Black cf77666cc1
Merge pull request #1268 from dforsi/fix/doxygen
Add/fix Doxygen comments
2023-04-09 22:13:42 -05:00
Daniele Forsi IU5HKX c3d06fd043 Add/fix Doxygen comments 2023-04-09 23:06:36 +02:00
Daniele Forsi IU5HKX 96bb604b12 Fix typos 2023-04-09 23:06:32 +02:00
Mike Black W9MDB dd874dbf7f Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-04-09 08:30:44 -05:00
Mike Black W9MDB e5a00cddb9 Fix case where netrigctl gets a 0 answer to chk_vfo
https://github.com/Hamlib/Hamlib/issues/1266
2023-04-09 08:29:48 -05:00
Nick Craig-Wood 2c283ab47a Fix QRP Labs QCX Morse Sending
Before this fix, hamlib used the TS480 protocol for sending morse
which adds a lot of spaces on the end.

The QCX actually uses the Elecraft morse sending protocol so switch it
over to using that.

Tested with QCX Mini firmware v1.09a
2023-04-09 14:00:25 +01:00
Nate Bargmann 748b45b91f
Update recent dates in NEWS 2023-04-05 16:52:56 -05:00
Mike Black W9MDB 22970f16de Fix Serial speed information in dumpcaps 2023-04-05 10:30:20 -05:00
Mike Black W9MDB 99170c1025 Add error message when rig is not turned on that mentions auto_power_on 2023-03-30 22:28:09 -05:00
Mike Black W9MDB 3053263c52 Update NEWS 2023-03-29 08:46:05 -05:00
Mike Black W9MDB 38d6858698 Progress on Expert ampctl 2023-03-28 17:23:54 -05:00
Mike Black W9MDB 1ec7dc07ec Fix expert_amp_caps 2023-03-28 17:14:59 -05:00
Mike Black W9MDB 7236942d89 Adding Expert Linear amplifier 2023-03-28 17:08:40 -05:00
Mike Black W9MDB c331899d94 Fix expert in rotators/Android.mk 2023-03-28 15:58:08 -05:00
Michael Black 9d7ac000e5
Merge pull request #1265 from dforsi/fix/duplicated-initializers
Fix initializer-overrides warnings by clang
2023-03-28 14:25:11 -05:00
Daniele Forsi IU5HKX 8d40732064 Fix initializer-overrides warnings by clang
Fixes:
dx77.c:225:5: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
    {
    ^
dx77.c:217:23: note: previous initialization is here
    .tx_range_list2 = {RIG_FRNG_END,},
                      ^~~~~~~~~~~~~~~

ft991.c:356:27: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
    .scan =               newcat_scan,
                          ^~~~~~~~~~~
ft991.c:352:27: note: previous initialization is here
    .scan =               newcat_scan,
                          ^~~~~~~~~~~
2023-03-28 19:53:29 +02:00
Mike Black W9MDB f11db5c949 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-03-28 11:53:30 -05:00
Mike Black W9MDB bbda209fc0 Add park to rotorez
https://github.com/Hamlib/Hamlib/issues/1257
2023-03-28 11:53:00 -05:00
Mike Black W9MDB 7395ef0e3f Add park to rotorez 2023-03-28 11:52:26 -05:00
Mike Black W9MDB 403ec07b6b Fix auto_power_on from rigctl invocation with --set-conf=auto_power_on=1
https://github.com/Hamlib/Hamlib/issues/1220
2023-03-28 10:43:07 -05:00
Mike Black W9MDB 79db09c201 Fix PS0; command in newcat.c
https://github.com/Hamlib/Hamlib/issues/1220
2023-03-28 10:24:31 -05:00
Mike Black W9MDB 224820fb44 Fix rigctld get_powerstat
https://github.com/Hamlib/Hamlib/issues/1220
2023-03-28 09:43:26 -05:00
Mike Black W9MDB 5aab96beff Enable async by default -- this prevents WSJT-X from crashing when transceive mode is on for the IC9700
https://github.com/Hamlib/Hamlib/issues/1264
2023-03-27 10:04:59 -05:00
Mike Black W9MDB d34983f495 Fix strcmp duplicates iun ftdx simulators 2023-03-26 17:03:27 -05:00
Michael Black d522967b32
Merge pull request #1262 from dforsi/fix/cppcheck
Remove duplicated conditions
2023-03-26 16:16:30 -05:00
Daniele Forsi IU5HKX 692deca638 Remove duplicated conditions
Fixes:
rigs/yaesu/newcat.c:10537:9: style: Same expression 'strcmp(priv->cmd_str,"IS1;")==0' found multiple times in chain of '||' operators. [duplicateExpression]
        || strcmp(priv->cmd_str, "IS1;") == 0
        ^
rigs/yaesu/newcat.c:10548:9: style: Same expression 'strcmp(priv->cmd_str,"NR0;")==0' found multiple times in chain of '||' operators. [duplicateExpression]
        || strcmp(priv->cmd_str, "NR0;") == 0
        ^
rigs/yaesu/newcat.c:10549:9: style: Same expression 'strcmp(priv->cmd_str,"NR1;")==0' found multiple times in chain of '||' operators. [duplicateExpression]
        || strcmp(priv->cmd_str, "NR1;") == 0
        ^
rigs/yaesu/newcat.c:10552:9: style: Same expression on both sides of '||'. [duplicateExpression]
        || strcmp(priv->cmd_str, "OS0;") == 0
        ^
2023-03-26 23:00:38 +02:00
Michael Black 30b2087f5d
Merge pull request #1261 from dforsi/fix/typos
Fix typos
2023-03-26 08:05:32 -05:00
Daniele Forsi IU5HKX 2db37fe7db Fix typos 2023-03-26 11:01:51 +02:00
Mike Black W9MDB dd75f55b1f Update NEWS 2023-03-25 12:38:24 -05:00
Mike Black W9MDB ac197389a2 Fix IC-7160 get_powerstat to disable it...cannot read power status from 7610 2023-03-25 11:20:52 -05:00
Mike Black W9MDB 8cce59b048 Improve simelecraft.c to work with FLRig 2023-03-22 22:45:56 -05:00
Mike Black W9MDB 8cdb21b6f3 Add ST command detection to set_cmd_validate in newcat.c 2023-03-22 15:09:48 -05:00
Mike Black W9MDB 7914842c2d Another attempt to make Mac compiler happy
https://github.com/Hamlib/Hamlib/issues/1256
2023-03-21 12:03:10 -05:00
Mike Black W9MDB 9f960fa531 Try another fix for MacOS compile
https://github.com/Hamlib/Hamlib/issues/1256
2023-03-21 10:05:26 -05:00
Mike Black W9MDB 2712c57058 Try another fix for MacOS compile
https://github.com/Hamlib/Hamlib/issues/1256
2023-03-21 10:04:41 -05:00
Mike Black W9MDB d893de407e Fix Mac compile error in newcat.c
https://github.com/Hamlib/Hamlib/issues/1256
2023-03-21 08:44:29 -05:00
Mike Black W9MDB 56907442ab Fix kpa.h 2023-03-20 23:33:16 -05:00
Mike Black W9MDB cf956daf17 Clean up id5100.c 2023-03-20 23:20:40 -05:00
Mike Black W9MDB 3254ac70a1 Change FT991, FTDX101MP, FTDX3000 to use ; for command validation
https://github.com/Hamlib/Hamlib/issues/1252
2023-03-20 23:10:35 -05:00
Mike Black W9MDB 0f0bbeb612 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-03-20 23:08:38 -05:00
Mike Black W9MDB 558747fab3 Update simft991.c 2023-03-20 23:06:50 -05:00
Michael Black 4004046d49
Merge pull request #1255 from dforsi/fix/doxygen
Fix Doxygen documentation
2023-03-19 22:18:07 -05:00
Daniele Forsi IU5HKX 26d3e79cf5 Fix Doxygen comments 2023-03-19 23:15:49 +01:00
Daniele Forsi IU5HKX 8e24746a3e Fix typos 2023-03-19 22:20:28 +01:00
Daniele Forsi IU5HKX 3c94527fb6 Fix Doxygen documentation for the GRBLTRK rotators
Fixes:
.../include/hamlib/rotlist.h:642: warning: documentation for unknown define ROT_MODEL_GRBLTRK found.
.../include/hamlib/rotlist.h:651: warning: Member ROT_MODEL_GRBLTRK_SER (macro definition) of group rotator is not documented.
.../include/hamlib/rotlist.h:652: warning: Member ROT_MODEL_GRBLTRK_NET (macro definition) of group rotator is not documented.
.../include/hamlib/rotlist.h:651: warning: Member ROT_MODEL_GRBLTRK_SER (macro definition) of group rotator is not documented.
.../include/hamlib/rotlist.h:652: warning: Member ROT_MODEL_GRBLTRK_NET (macro definition) of group rotator is not documented.
2023-03-19 19:08:05 +01:00
Daniele Forsi IU5HKX 38cc75c568 Fix Doxygen documentation for the Apex rotator
Fixes:
.../include/hamlib/rotlist.h:672: warning: documentation for unknown define ROT_MODEL_APEX found.
.../include/hamlib/rotlist.h:680: warning: Member ROT_MODEL_APEX_SHARED_LOOP (macro definition) of group rotator is not documented.
2023-03-19 19:07:51 +01:00
Daniele Forsi IU5HKX 6de5aa7838 Fix Doxygen unmatched directives \cond and \endcond 2023-03-19 18:42:24 +01:00
Mike Black W9MDB 389ee47f76 Update NEWS 2023-03-18 23:43:36 -05:00
Mike Black W9MDB 113cad3ee1 For K3 prevent ID; command from K22; command
Remote ops was having a problem with K22;
https://github.com/Hamlib/Hamlib/issues/1254
2023-03-18 23:40:45 -05:00
Mike Black W9MDB 2adf049084 Update NEWS 2023-03-18 22:21:07 -05:00
Mike Black W9MDB 0f7908be22 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-03-18 22:20:12 -05:00
Mike Black W9MDB 5e00bed9cb Fix Gemini DX1200 gemini_set_level function 2023-03-18 22:18:50 -05:00
Mike Black W9MDB fd473062d1 astyle kenwood.c 2023-03-18 15:21:30 -05:00
Michael Black 18c4eb4631
Merge pull request #1251 from dforsi/fix/cppcheck
Fix/cppcheck
2023-03-18 08:41:35 -05:00
Michael Black e022ff2314
Merge pull request #1250 from dforsi/fix/ampctl-show-conf
Enable --show-conf for ampctl and ampctld
2023-03-18 08:41:06 -05:00
Daniele Forsi IU5HKX 01a2dd23ed Fix cppcheck "missingInclude" informational message
Fixes:
tests/rigtestlibusb.c:30:0: information: Include file: "libusb.h" not found. [missingInclude]
2023-03-18 11:17:18 +01:00
Daniele Forsi IU5HKX 51c88e0a6d Add to .gitignore some files created during "make check" 2023-03-18 11:02:13 +01:00
Daniele Forsi IU5HKX c3e7021c61 Fix cppcheck "unmatchedSuppression" informational messages
Fixes:
tests/ampctl.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
tests/ampctl_parse.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
tests/rigctl.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
tests/rigctl_parse.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
tests/rotctl.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
tests/rotctl_parse.c👎0: information: Unmatched suppression: knownConditionTrueFalse [unmatchedSuppression]
2023-03-18 10:46:04 +01:00
Daniele Forsi IU5HKX e997984662 Fix several cppcheck "missingInclude" informational messages
The following STILL reamin:
scripts/MSVC/2022/x64/hamlibTest/hamlibTest.h:3:0: information: Include file: "resource.h" not found. [missingInclude]
scripts/MSVC/2022/x86/hamlibTest/hamlibTest.h:3:0: information: Include file: "resource.h" not found. [missingInclude]
src/network.c:83:0: information: Include file: "io.h" not found. [missingInclude]
tests/rigtestlibusb.c:30:0: information: Include file: "libusb.h" not found. [missingInclude]
2023-03-18 10:46:04 +01:00
Daniele Forsi IU5HKX b02ff9daa1 Fix passing one or more paths to ./cppcheck.sh
The --check-config arguments can be passed explicitly if desired.
2023-03-18 10:46:04 +01:00
Daniele Forsi IU5HKX c9e2c5f697 Fix include not found by cppcheck.sh also in the other branch of the "if"
Fixes:
nofile:0:0: error: Can not open include file 'include/config.h' that is explicitly included. [preprocessorErrorDirective]
2023-03-18 10:46:04 +01:00
Daniele Forsi IU5HKX c3265dc905 Fix typos
Fixes:
rigctld.c:1233:5: warning: implicit declaration of function ‘mutext_rigctld’; did you mean ‘mutex_rigctld’? [-Wimplicit-function-declaration]
rigctltcp.c:1217:5: warning: implicit declaration of function ‘mutext_rigctld’; did you mean ‘mutex_rigctld’? [-Wimplicit-function-declaration]
2023-03-18 10:46:04 +01:00
Daniele Forsi IU5HKX 52d41236a7 Enable --show-conf for ampctl and ampctld 2023-03-18 10:25:36 +01:00
Mike Black W9MDB 57b7cd1860 Fix spelling error in rotctl.c help and add offset settings to rotctl.1 2023-03-16 16:41:35 -05:00
Mike Black W9MDB 24a4a09484 Update NEWS 2023-03-14 17:35:33 -05:00
Michael Black e05eb7743b
Merge pull request #1248 from matthew-wolf-n4mtt/n4mtt-saebrtrack
N4MTT saebrtrack
2023-03-14 17:31:22 -05:00
Matthew J Wolf dff890a143
Merge branch 'Hamlib:master' into n4mtt-saebrtrack 2023-03-14 18:15:06 -04:00
Michael Black 9823a41f48
Merge pull request #1247 from dforsi/master
Fix include not found by cppcheck.sh
2023-03-12 12:44:29 -05:00
Daniele Forsi IU5HKX 8e08385d2d Fix include not found by cppcheck.sh
Fixes:
nofile:0:0: error: Can not open include file 'include/config.h' that is explicitly included. [preprocessorErrorDirective]
2023-03-12 18:39:08 +01:00
Matthew J. Wolf a64bb4fc7d Duplicated other changes made to easycom 2023-03-10 14:28:43 -05:00
Matthew J. Wolf 631a7a5faa change from commit cdb3a60 to master 2023-03-10 13:48:29 -05:00
Matthew J. Wolf 16f03dcdfb Type casting from easycom 2023-03-10 13:40:37 -05:00
Matthew J. Wolf f5c26bf235 Inital add of rotator saebrtrack 2023-03-10 13:03:14 -05:00
Michael Black 19b2c33e62
Merge pull request #1246 from akhepcat/master
Support 5ghz/60M memory channels
2023-03-09 22:22:04 -06:00
Leif Sawyer 09a6bbf7c7 Support 5ghz/60M memory channels 2023-03-09 13:56:09 -09:00
Mike Black W9MDB 77dd85289c Update NEWS 2023-03-08 15:54:05 -06:00
Michael Black 94b8e53be9
Merge pull request #1245 from mikaelnousiainen/icom-async-fixes
Fix issues with async I/O
2023-03-08 15:50:23 -06:00
Mikael Nousiainen f17f6f0f42 Disable rig port flushing when async I/O is enabled. Improve validation of Icom frames. 2023-03-08 23:35:08 +02:00
Michael Black 0e6fd996bc
Merge pull request #1244 from mikaelnousiainen/ts2000-fixes
Improve Kenwood TS-2000 backend
2023-03-08 15:31:58 -06:00
Mike Black W9MDB 6cf65cc099 Update NEWS 2023-03-07 15:40:19 -06:00
Mike Black W9MDB 2f68033840 Fix set_vfo in jst145.c 2023-03-07 15:38:28 -06:00
Mike Black W9MDB 95196ca96c Fix set_freq in jst145.c 2023-03-07 15:00:00 -06:00
Mikael Nousiainen ec0645780c Fix Kenwood TS-2000 bugs and implement essential commands for remote control 2023-03-07 10:38:20 +02:00
Mike Black W9MDB 0591aee8e6 Remove dead code 2023-03-06 11:32:58 -06:00
Mike Black W9MDB edc18103f0 Move semicolon removal after complete string is read.
xg3 was expecting single ; response and old way was causing timeouts
2023-03-06 11:27:41 -06:00
Mike Black W9MDB a8aba7c13b Add tcflush back into flush routine
https://github.com/Hamlib/Hamlib/issues/1241
2023-03-06 11:26:35 -06:00
Michael Black 2622113d2f
Merge pull request #1243 from kholia/simulator-fixes
Minor fixes for FT-747GX simulator
2023-03-06 09:48:00 -06:00
Dhiru Kholia 3d4fe8fead Minor fixes for FT-747GX simulator 2023-03-06 21:00:35 +05:30
Mike Black W9MDB d06244c47f Re-enable set/get mem for xg3 2023-03-05 17:03:29 -06:00
Mike Black W9MDB eb5767c0ca Align xg3 with kenwood_priv and remove set/get mem for xg3 for now 2023-03-05 13:19:43 -06:00
Mike Black W9MDB e428d824cd Fix xg3 set_freq 2023-03-05 13:12:33 -06:00
Michael Black 126e7dfefd
Merge pull request #1242 from dforsi/master
Fix unterminated comment
2023-03-04 16:29:23 -06:00
Daniele Forsi IU5HKX 9ad9f23fe1 Fix unterminated comment
Fixes a cppcheck error:
rigs/mds/serialnum.c:106:1: error: Unmatched '}'. Configuration: ''. [syntaxError]
2023-03-04 23:13:11 +01:00
Mike Black W9MDB decc056662 Remove caps->get_ptt from DTR/RTS get_ptt -- seems we should not need query via CAT when using DTR/RTS
https://github.com/Hamlib/Hamlib/issues/1241
2023-03-04 11:17:14 -06:00
Mike Black W9MDB fe1eabf531 Win4Yaesu is not recognizing EX commands so we ignore errors on the EX command for some Yaeus rigs 2023-02-28 16:57:47 -06:00
Michael Black ee7ecc71a1
Merge pull request #1240 from GeoBaltz/kenwood_levels
Kenwood levels
2023-02-26 23:40:50 -06:00
George Baltz N3GB 07fc69f3e8 Enable first user of check_level_param
Use check_level_param for all RIG_LEVEL_CWPITCH sets for Kenwood rigs.
Note that the placement of the call is temporary; eventually it should
be moved outside the main switch statement, and invoked for all set_levels.
2023-02-26 13:12:52 -05:00
George Baltz N3GB a9b9154a2d Round 2. 2023-02-26 13:12:52 -05:00
George Baltz N3GB 14aa095362 Do the check for min=max=0 the right way.
Avoids possible compiler/arch/endian weirdness.
2023-02-26 13:12:52 -05:00
George Baltz N3GB 00e2797c6f First round of level_gran additions.
Issue: #1144
2023-02-26 13:12:52 -05:00
George Baltz N3GB bc476a1c94 ATTenuator level 0 should always be allowed - to turn it off. 2023-02-26 13:12:52 -05:00
George Baltz N3GB f161ae7b35 Add routine to check input to <brand>_set_level
See https://github.com/Hamlib/Hamlib/issues/1144
2023-02-26 13:12:52 -05:00
George Baltz N3GB f5a1dabd06 Add missing level definitions for TS-590SG 2023-02-26 13:12:52 -05:00
Mike Black W9MDB a9cb121584 Add stop_morse for some Kenwood rigs 2023-02-25 22:11:11 -06:00
Mike Black W9MDB 717dae5027 Fix potential segfault in cmdstr check in kenwood.c 2023-02-21 11:44:12 -06:00
Mike Black W9MDB fb12668f06 Allow single semicolon characaters to be skipped 2023-02-20 22:49:27 -06:00
Mike Black W9MDB 514d87dcc9 astyle kenwood.c 2023-02-19 17:01:42 -06:00
Mike Black W9MDB c0030fa01d Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-02-19 16:57:10 -06:00
Mike Black W9MDB 10ac497c0b Improve response of ;;;;PS1; command 2023-02-19 16:56:51 -06:00
Michael Black fef9737a47
Merge pull request #1238 from dforsi/update-gitignore
Update .gitignore
2023-02-19 08:23:46 -06:00
Daniele Forsi IU5HKX dbd9ff45fa Update .gitignore
Add more generated files.
2023-02-19 08:42:15 +01:00
Mike Black W9MDB 3d38f8b214 Add offset_vfoa and offset_vfob configuraiton parameters for adding freq offsets to VFOA/Main and VFOB/Sub 2023-02-17 12:33:14 -06:00
Michael Black 1edb21a38d
Merge pull request #1237 from dforsi/fix/unused-includes
Remove unused includes and add useful includes
2023-02-16 12:20:44 -06:00
Mike Black W9MDB 51712b9a66 Update NEWS 2023-02-16 12:18:52 -06:00
Daniele Forsi IU5HKX 51d95bb8f7 [amplifiers] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 3f90086991 [tests] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX cdb3a60f02 [rotators] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 52be0797d8 [rigs/*] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 7673abc59b [yaesu] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 420125b8bc [kenwood] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 7211730866 [icom] Fix includes 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 72e94b6069 Add include/hamlib directory to all makefiles 2023-02-16 19:08:24 +01:00
Daniele Forsi IU5HKX 561f65a56d [extra] Remove unused include of config.h 2023-02-14 19:59:04 +01:00
Daniele Forsi IU5HKX 1213d87448 [amplifiers] Remove unused include of config.h 2023-02-14 19:58:38 +01:00
Daniele Forsi IU5HKX d09c048161 [rigs/*] Remove unused include of config.h 2023-02-14 19:57:48 +01:00
Daniele Forsi IU5HKX b6fe95ae80 [tests] Remove unused include of config.h 2023-02-14 19:57:27 +01:00
Daniele Forsi IU5HKX b6ec70fcb2 [rotators] Remove unused include of config.h 2023-02-14 19:57:06 +01:00
Daniele Forsi IU5HKX a04abe6e04 [yaesu] Remove unused include of config.h 2023-02-14 19:30:51 +01:00
Daniele Forsi IU5HKX 5c17054295 [kenwood] Remove unused include of config.h 2023-02-14 19:29:22 +01:00
Daniele Forsi IU5HKX 2e894dd9cc [icom] Remove unused include of config.h
Found wih "Include What You Use".
2023-02-14 19:21:18 +01:00
Mike Black W9MDB 9dbe4ef79a Separate the validation cmd in newcat.c to allow rig post_write_delay to be in effect
https://github.com/Hamlib/Hamlib/issues/1219
2023-02-14 09:22:50 -06:00
Mike Black W9MDB 58700c6e9f Increase post_write to 20ms for FT710
https://github.com/Hamlib/Hamlib/issues/1235
2023-02-12 07:26:28 -06:00
Mike Black W9MDB 4078fa9248 Fix ID5100 S Main 1 Sub
https://github.com/Hamlib/Hamlib.git
2023-02-10 16:49:37 -06:00
Mike Black W9MDB 111627533f Changes to support ID-5100 in gpredict.
Can now set set freq/mode on VFOA/B or Main/Sub correctly automatically switching dual watch mode as needed
2023-02-10 08:02:48 -06:00
Mike Black W9MDB f9adf5de0a Add attenuator level control for TS890
Update SMeter/SWR tables for TS890
Thanks to N3GB George Baltz
2023-02-08 12:02:19 -06:00
Mike Black W9MDB cbd5f9ad3e Future-proof 32/64/128-bit detection 2023-02-07 10:47:38 -06:00
Mike Black W9MDB 1e1abaccbc Add 64/32-bit information to version 2023-02-07 10:43:22 -06:00
Mike Black W9MDB 907a178aa6 Some fixes for th.c operation
https://github.com/Hamlib/Hamlib/issues/1230
2023-02-06 16:01:08 -06:00
Mike Black W9MDB 73fc563ceb Add fix for TMD700
https://github.com/Hamlib/Hamlib/issues/1230
2023-02-06 15:58:18 -06:00
Mike Black W9MDB e9724a9058 Add simtmd700 2023-02-06 15:57:20 -06:00
Mike Black W9MDB 321c366045 Add simtmd700 2023-02-06 15:56:36 -06:00
Mike Black W9MDB cc7c335dc5 Improve FT-857 get_vfo response when error occurs
This could be FT-857 EEPROM burnout
https://github.com/Hamlib/Hamlib/issues/1232
2023-02-06 15:14:34 -06:00
Mike Black W9MDB c903c09cd1 Allo FT-857 to return cached vfo when set_vfo is called and EEPROM read error occurs
https://github.com/Hamlib/Hamlib/issues/1232
2023-02-06 11:11:17 -06:00
Mike Black W9MDB b037c72c50 Fix AF level control for FTDX10 and FT710
https://github.com/Hamlib/Hamlib/issues/1231
2023-02-05 17:28:23 -06:00
Mike Black W9MDB 44e8389e00 Fix suppression of setting frequency on nontargetable rigs when in split mode
That is, do not set TX VFO when receiving and do not set RX VFO when transmitting
Should allow gpredict to work much better
2023-02-04 23:54:40 -06:00
Mike Black W9MDB 0e9bdc5d04 Fix spelling error in kenwood.c 2023-02-04 17:08:31 -06:00
Mike Black W9MDB 1efff461e3 Have icom rigs show debug when civ addr has been changed and timeout occurs
https://github.com/Hamlib/Hamlib/issues/1229
2023-02-04 14:22:57 -06:00
Mike Black W9MDB c055817c27 Fix FT-450D detection 2023-02-04 06:35:40 -06:00
Mike Black W9MDB 8c0bb2034d Fix VFO A/B swapping for gpredict -- hopefully better behavior for VFO swapping rigs
Should avoid setting RX freq while TX and avoid TX freq while RX
https://github.com/Hamlib/Hamlib/issues/1230
2023-02-02 23:15:26 -06:00
Mike Black W9MDB fa503c5b3b Change TM-D700 and TM-D710 to hardware flow control
https://github.com/Hamlib/Hamlib/issues/1228
2023-02-01 22:19:02 -06:00
Mike Black W9MDB 61e4e8d676 Update NEWS 2023-02-01 16:50:53 -06:00
Mike Black W9MDB d645bae207 Ensure K4 is in K40 mode when requesting ID 2023-02-01 16:50:10 -06:00
Mike Black W9MDB fa4a96e6a6 Add rigctlsync to doc/Makefile.am 2023-01-30 07:54:43 -06:00
Mike Black W9MDB 6fbb098612 Fix segfault using python Hamlib.rig_parse_mode(None)
Argument really needed to be 'None' but now prints out better error message
https://github.com/Hamlib/Hamlib/issues/1227
2023-01-29 15:50:27 -06:00
Mike Black W9MDB 29ad027b63 Update simicom9700.c 2023-01-29 12:46:48 -06:00
Mike Black W9MDB 33b8c1c88d Update NEWS 2023-01-28 12:48:04 -06:00
Mike Black W9MDB 14016be817 Some updates to fix rc2800 operations
be72027f9a
2023-01-28 12:42:14 -06:00
Mike Black W9MDB 2cec9e6d57 Update rigctlsync 2023-01-27 23:49:47 -06:00
Mike Black W9MDB 9bc5c4a883 Add rigctlsync utility to allow synchornizing a rig to SDR# 2023-01-27 23:35:31 -06:00
Mike Black W9MDB 8a25a3be90 Fix sdrsharp model name to show gpredict 2023-01-27 17:46:46 -06:00
Mike Black W9MDB ff64d86fd9 Fix sdrsharp manufacturer name 2023-01-27 17:44:08 -06:00
Mike Black W9MDB 5c36bef6c2 Fix compile warning in sdrsharp.c 2023-01-27 17:39:14 -06:00
Mike Black W9MDB 41a8a50e65 Add SDR# rig for use with SDR#'s gpredict pluigin -- can only get/set freq 2023-01-27 17:31:24 -06:00
Mike Black W9MDB 0177d85a5d Forgot to also checking rig.c to allow get_powerstat failing to just keep going
https://github.com/Hamlib/Hamlib/issues/1226
2023-01-26 09:32:19 -06:00
Mike Black W9MDB 1e353191bc Make Kenwood rigs wake up serial port on PS command
Failing get_powerstat will now return RIG_OK
https://github.com/Hamlib/Hamlib/issues/1226
2023-01-26 08:35:45 -06:00
Mike Black W9MDB eb049ab92d Add dummy bytes to kenwood PS; command
https://github.com/Hamlib/Hamlib/issues/1226
2023-01-25 22:18:45 -06:00
Mike Black W9MDB 8d1eacc9cb Update NEWS 2023-01-24 11:28:33 -06:00
Mike Black W9MDB 267184ad44 Change QRP QDX PTT command to TQ instead of TX -- more incompability with TS-480 commands 2023-01-24 11:26:22 -06:00
Mike Black W9MDB a47eba7ce4 Revert "Update NEWS"
This reverts commit 76a3ab19eb.
2023-01-24 11:25:49 -06:00
Mike Black W9MDB 76a3ab19eb Update NEWS 2023-01-24 11:23:47 -06:00
Mike Black W9MDB 3fd698d063 Change QRP QRDX PTT to use TQ instead TX...more incompability with TS-480 standard 2023-01-24 11:22:19 -06:00
Mike Black W9MDB b977858da9 Update NEWS 2023-01-23 14:50:59 -06:00
Mike Black W9MDB d68c218a3d ERemove EX103 get/set for FTDX5000 2023-01-23 14:49:06 -06:00
Mike Black W9MDB 79129087e0 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-01-23 09:12:48 -06:00
Mike Black W9MDB af94130749 Update NEWS 2023-01-23 09:10:58 -06:00
Michael Black 907560270e
Update test.json
Add WidthUpper/Lower to json draft
2023-01-23 08:34:58 -06:00
Mike Black W9MDB 52bed765ef Clean up rig power on/off sequencing for Kenwood/Elecraft rigs
Note that the K3/K3S cannot power on via CAT control
https://github.com/Hamlib/Hamlib/issues/1225
2023-01-22 23:41:21 -06:00
Mike Black W9MDB 9626894029 Fix K3/K3S VFOB mode/bandwidth setting
https://github.com/Hamlib/Hamlib/issues/1224
2023-01-22 16:45:22 -06:00
Mike Black W9MDB 9b89a99f99 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2023-01-22 10:49:45 -06:00
Mike Black W9MDB d16b52e414 Fix IC7300 5 second sleep during poweron
Reverse ID-5100 logic for dual watch mode
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-22 10:49:15 -06:00
Mike Black W9MDB 407b0fcc54 Fix IC7300 5 second sleep during poweron
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-22 10:43:58 -06:00
Mike Black W9MDB 344779eaf1 Add draft HamlibGUI controller using dotnet and GTK.
Should compile on Windows, Linux, and MacOS with appropriate dotnet package installed
See README.TXT in directory
https://github.com/Hamlib/Hamlib/issues/1223
2023-01-22 10:02:46 -06:00
Mike Black W9MDB 18a2d91f59 Add HAMLIB_VERSION_MAJOR, HAMLIB_VERSION_MINOR, and HAMLIB_VERSION_PATCH #defines
https://github.com/Hamlib/Hamlib/issues/1209
2023-01-21 22:49:51 -06:00
Mike Black W9MDB 0c2426c800 Add 5 second sleep during power on for IC7300
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-21 17:21:04 -06:00
Mike Black W9MDB cdbd517228 Remove double execution of get_powerstat -- was causing rigctld to give an error
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-21 12:55:44 -06:00
Mike Black W9MDB cfde2c8a92 Add ability for set_vfo_opt 0/1 so rigctl can control VFO option 2023-01-20 16:53:42 -06:00
Mike Black W9MDB eb1d467236 Fix segfault in aclog.c 2023-01-20 15:39:23 -06:00
Mike Black W9MDB 50a14bb08f Add ACLog rig -- should work with WSJT_X and Fake It mode -- mode setting is a bit odd though might need None for mode in WSJT-X and manually set rig 2023-01-20 12:47:52 -06:00
Mike Black W9MDB 13d27a3567 Add GPS data, rig time, and GPS time for future JSON broadcast data 2023-01-19 22:58:12 -06:00
Mike Black W9MDB c78371353c Allow get_powerstat when rig is powered off
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-19 17:15:59 -06:00
Mike Black W9MDB 268f44eb7d Remove one sleep from set_powerstat loop
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-18 23:32:18 -06:00
Mike Black W9MDB 3daed948a8 Make auto_power_on a bit more robust for RigPI which seems slow to get going
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-18 23:27:27 -06:00
Mike Black W9MDB 9d096c4ac9 Improve powerstat on/off behavior for Icom rigs
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-18 15:00:18 -06:00
Mike Black W9MDB ac220815c4 Fix rig_close entry in id5100.c 2023-01-18 12:37:15 -06:00
Mike Black W9MDB 57b063a44c Balance ENTER/RETURN in rig.c 2023-01-18 12:25:05 -06:00
Mike Black W9MDB 9861d1f87b Add dual watch capability for ID-5100
https://github.com/Hamlib/Hamlib/issues/1218
2023-01-18 08:49:11 -06:00
Mike Black W9MDB 6f6379e547 Add hamlibmodels to Makefile.am 2023-01-18 08:38:43 -06:00
Mike Black W9MDB b38739bcab Show AGC Level None when there are no AGC settings for rig
https://github.com/Hamlib/Hamlib/issues/1155
2023-01-18 07:09:28 -06:00
Mike Black W9MDB f392cc4c18 Fix AGC level display in rigctld
https://github.com/Hamlib/Hamlib/issues/1155
2023-01-17 23:54:05 -06:00
Mike Black W9MDB 16af6ae3aa Update NEWS 2023-01-17 22:31:17 -06:00
Mike Black W9MDB aeb2692b42 Change FTDX10 handshake to None instead of Hardware 2023-01-17 22:30:02 -06:00
Mike Black W9MDB c0866e0bad Add hamlibmodels.c example 2023-01-17 16:23:45 -06:00
Mike Black W9MDB 739fe24e62 Add new simulator to Makefile.am 2023-01-17 15:45:29 -06:00
Mike Black W9MDB d180883f3e Allow rigctl/rigctld to continue when a bad set_conf is called -- just shows a warning now 2023-01-17 09:22:55 -06:00
Mike Black W9MDB c02370d279 Allow rigctld to continue when an invalid set_conf parameter is used 2023-01-17 09:19:39 -06:00
Mike Black W9MDB 3f8da23bb6 Improved set_conf error when serial_handshake is invalid 2023-01-17 08:50:47 -06:00
Mike Black W9MDB cb1c98fa85 Fix xdgpath in settings.c 2023-01-16 09:24:00 -06:00
Mike Black W9MDB 0ad5a4b742 Attempt to allow PS; query for Yaeus rigs when powered off
https://github.com/Hamlib/Hamlib/issues/1220
2023-01-15 22:22:14 -06:00
Mike Black W9MDB c3ff7e134f Add TS-2000 to has_ps exceptions
https://github.com/Hamlib/Hamlib/issues/1213
2023-01-15 12:41:01 -06:00
Mike Black W9MDB e681185b61 Update NEWS 2023-01-15 10:18:44 -06:00
Mike Black W9MDB 77ce6b6dc3 Add FT991 to 60M exception 2023-01-15 10:17:54 -06:00
Mike Black W9MDB 29a80fb496 Fix get_powerstat call when get_powerstat is not defined
https://github.com/Hamlib/Hamlib/issues/1217
2023-01-13 17:30:55 -06:00
Mike Black W9MDB 9c48ec785c Improve serial port timeout when permission proble or does not exist
https://github.com/Hamlib/Hamlib/issues/1216
2023-01-12 11:23:11 -06:00
Mike Black W9MDB e4471b9ece Fix BSD build include path order
https://github.com/Hamlib/Hamlib/issues/1208
2023-01-10 23:07:53 -06:00
Michael Black 37b2901293
Merge pull request #1215 from fillods/F8CFE/celestron_status
Update status of celestron to Stable
2023-01-10 15:21:03 -06:00
Stephane Fillod 51f9cbe457 Update status of celestron to Stable
Tested-by: Eric K0JEG
Tested-by: Daniel DL7NDR <040+73@mailbox.org>
Tested-by: Андрей Родионов <dernasherbrezon@gmail.com>
2023-01-10 20:41:07 +01:00
Mike Black W9MDB dc131cba7f Fix set_powerstat on/off/on for Icom rigs using rigctld power_on=0
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-10 08:46:10 -06:00
Mike Black W9MDB 00dce998ae Fix Elecraft power2mW precision/accuracy
Should fix any others too
https://github.com/Hamlib/Hamlib/issues/1205
2023-01-09 23:26:15 -06:00
Mike Black W9MDB 5ebde1ca34 Really fix CM108 ptt_bitnum usage
https://github.com/Hamlib/Hamlib/issues/1203
2023-01-09 22:53:01 -06:00
Mike Black W9MDB aa1cf567f6 Fix Icom poweron behavior
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-09 12:34:22 -06:00
Mike Black W9MDB 7cc477869f Revert "Close rig on set_powerstat 0 -- Linux was unable to reconnect to IC-7300"
This reverts commit 93e3aec588.
2023-01-09 12:21:33 -06:00
Mike Black W9MDB 3eedc5a5af Update NEWS
https://github.com/Hamlib/Hamlib/issues/1203
2023-01-09 11:24:34 -06:00
Mike Black W9MDB 56c87cfa9a Fix CM108 ptt setting
https://github.com/Hamlib/Hamlib/issues/1203
2023-01-09 11:03:50 -06:00
Mike Black W9MDB 7c5b095ff3 Update NEWS 2023-01-09 10:44:27 -06:00
Mike Black W9MDB 58621995f3 Fix FT-710, FTDX10, FTDX101D/MP 60M operations
https://github.com/Hamlib/Hamlib/issues/1211
2023-01-09 10:42:57 -06:00
Mike Black W9MDB d2ef9d5eda Fix get_powerstat status return to always show POWER_ON for kenwood non-PS rigs
https://github.com/Hamlib/Hamlib/issues/1213
2023-01-09 10:28:43 -06:00
Mike Black W9MDB 89fadca3bd For Icom rigs close and reopen rig after set_powerstat=1 -- Linux resets the usb device
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-09 09:50:25 -06:00
Mike Black W9MDB 93e3aec588 Close rig on set_powerstat 0 -- Linux was unable to reconnect to IC-7300
https://github.com/Hamlib/Hamlib/issues/1212
2023-01-08 16:48:35 -06:00
Mike Black W9MDB 57522f0b93 Ensure 60M exception for FT710 is only for US language setting
https://github.com/Hamlib/Hamlib/issues/1211
2023-01-08 10:28:34 -06:00
Mike Black W9MDB 8be3fcbef5 Add FT-710 to 60M exception in newcat.c to allow some ability to work with WSJT-X
https://github.com/Hamlib/Hamlib/issues/1211
2023-01-08 07:58:57 -06:00
Mike Black W9MDB 0a2dddfce0 Update NEWS 2023-01-07 22:20:06 -06:00
Mike Black W9MDB e3ac42a6b6 Update timing in nrd535.c based on testing thanks to markjfine 2023-01-07 22:17:24 -06:00
Mike Black W9MDB 02312ef322 Update NEWS 2023-01-07 17:30:09 -06:00
Mike Black W9MDB 6cb7a8c560 Fix FTDX3000 EX039 error
https://github.com/Hamlib/Hamlib/issues/1206
2023-01-07 16:03:34 -06:00
Mike Black W9MDB 7978d74750 Force K22 mode on Elecraft rigs to get PC power level in .1W intervals for low power operations
https://github.com/Hamlib/Hamlib/issues/1205
2023-01-07 11:46:56 -06:00
Mike Black W9MDB eb904148b5 Fix elecraft power2mW by scaling power to either 15W or 100W based on KPA availability
We are ignoring the tx_range values for the Kn series
https://github.com/Hamlib/Hamlib/issues/1205
2023-01-06 23:31:18 -06:00
Mike Black W9MDB 22df154486 Remove EX039 check from FTDX3000/3000DM
https://github.com/Hamlib/Hamlib/issues/1206
2023-01-06 22:22:25 -06:00
Mike Black W9MDB 79255fa27c Remove unnecessary check from netrigctl.c
https://github.com/Hamlib/Hamlib/issues/1155
2023-01-06 16:41:45 -06:00
Mike Black W9MDB 4a487ffdcc Fix rigctld agc level readings -- allow for rig backedn to specify "RIG_AGC_NONE" now for clarity if desired
https://github.com/Hamlib/Hamlib/issues/1155
2023-01-06 16:21:58 -06:00
Mike Black W9MDB db218e9e73 Update man pages to clarify upper/lower case for set/get commands 2023-01-06 10:30:32 -06:00
Mike Black W9MDB 86771a9557 Update simelecraft.c 2023-01-06 07:56:11 -06:00
Mike Black W9MDB e6c5c15452 Update NEWS 2023-01-05 23:32:41 -06:00
Mike Black W9MDB bbd0f856ca Fix rig_getpower2mW so it checks all range lists
https://github.com/Hamlib/Hamlib/issues/1205
2023-01-05 23:31:15 -06:00
Mike Black W9MDB 31d2939acc Fix auto_power_on check in rigctld.c 2023-01-05 10:02:46 -06:00
Mike Black W9MDB 589736e8f7 Add simid5100.c 2023-01-04 17:33:55 -06:00
Mike Black W9MDB 6dbd2cff5e Update NEWS 2023-01-04 17:23:49 -06:00
Mike Black W9MDB 902be172c1 Allow rigctld to start with autopower_on=0 and avoid timeouts at startup 2023-01-04 17:22:56 -06:00
Mike Black W9MDB f1b6d322ba Update NEWS 2023-01-04 15:46:17 -06:00
Mike Black W9MDB 87cc9a8c3d Update ID5100 and ID4100
Promote ID5100 to stable
https://github.com/Hamlib/Hamlib/issues/1204
https://github.com/Hamlib/Hamlib/issues/1202
https://github.com/Hamlib/Hamlib/issues/1202
2023-01-04 15:40:36 -06:00
Mike Black W9MDB 383c95b9c4 Get dummy rig to work with grig by disallowing empty "u" calls 2023-01-04 15:39:23 -06:00
Mike Black W9MDB af9a7a6938 Make 3-byte Icom ID rigs show error message 2023-01-04 10:48:30 -06:00
Mike Black W9MDB cceffce4a5 Remove XONXOFF flow control from ID5100 and ID4100 -- Firmware E8 is not working correclty that flow control
https://github.com/Hamlib/Hamlib/issues/1202
2023-01-04 10:45:06 -06:00
Mike Black W9MDB 0404b43bd8 Add PKTUSB to ft1000mp rigs 2023-01-04 07:24:05 -06:00
Mike Black W9MDB 138795668f Fix ID5100 get/set_mode
Remove ID rigs freq_len check as civ_731 setting should cover it
https://github.com/Hamlib/Hamlib/issues/1204
2023-01-04 06:57:12 -06:00
Mike Black W9MDB 9c5809ffba Fix units for get freq for ID5100 ID4100 ID31 ID51
https://github.com/Hamlib/Hamlib/issues/1200
2023-01-03 17:54:04 -06:00
Mike Black W9MDB 1b6b78f54a Another attempt to fix get/set freq for ID5100 ID4100 ID31 ID51
https://github.com/Hamlib/Hamlib/issues/1202
https://github.com/Hamlib/Hamlib/issues/1200
2023-01-03 12:17:16 -06:00
Mike Black W9MDB 4c09344f32 Convert Icom 3-byte frequency to Hz from KHz
https://github.com/Hamlib/Hamlib/issues/1200
2023-01-02 23:04:54 -06:00
Mike Black W9MDB 9f0bd7b310 Add rigctltcp.c -- not working yet 2023-01-02 11:38:27 -06:00
Mike Black W9MDB 0b2f0873b0 Update NEWS 2023-01-02 11:32:18 -06:00
Mike Black W9MDB c7b33ef0b3 Fix ID5100 ID4100 ID31 ID51 get/set freq
Remove get_powerstat from ID4100 ID31 ID51 as it they are not capable
Add new rig_is_model function to help with Icom rig identification checks
https://github.com/Hamlib/Hamlib/issues/1202
https://github.com/Hamlib/Hamlib/issues/1200
2023-01-02 11:30:52 -06:00
Mike Black W9MDB f68d45d99b Update NEWS 2023-01-02 08:58:21 -06:00
Mike Black W9MDB fa7289995c Remove get_powerstat from Icom ID-5100 -- does not have the ability to get power status
https://github.com/Hamlib/Hamlib/issues/1201
2023-01-02 08:48:59 -06:00
Mike Black W9MDB 582686505c TS-890S query rig to find out which meter type the operator has selected
Thanks to N3GB George Baltz
2023-01-01 16:40:19 -06:00
Mike Black W9MDB 712564a2ae Revert "TS-890S query rig to find out which meter type the operator has selected"
Committed a bit too much
This reverts commit 2fc1d157ba.
2023-01-01 16:39:25 -06:00
Mike Black W9MDB 2fc1d157ba TS-890S query rig to find out which meter type the operator has selected
Thanks to N3GB George Baltz
2023-01-01 16:33:46 -06:00
Mike Black W9MDB b1fcdea72d Update NEWS 2022-12-31 14:45:46 -06:00
Mike Black W9MDB 1ee37d0a56 Update NEWS 2022-12-31 09:34:29 -06:00
Mike Black W9MDB c1662ce886 Remove set_rts and set_dtr low from serial.c
This was causing hardward flow control to fail on Linux and MacOS
https://github.com/Hamlib/Hamlib/issues/1198
https://github.com/Hamlib/Hamlib/issues/1199
2022-12-31 09:30:25 -06:00
Mike Black W9MDB 1bb1f545eb Update NEWS 2022-12-31 08:10:06 -06:00
Mike Black W9MDB 64c566cd14 Add QRPLabs QCX/QDX for better behavior/capability from ts480 entry 2022-12-30 16:04:39 -06:00
Mike Black W9MDB b6654c78cb Update NEWS 2022-12-30 09:37:50 -06:00
Mike Black W9MDB f67a53c41c Allow for 36 and 37 byte IF lengths for ic10.c
This should fix QRP QRDX buggy IF message -- hopefully the fix theirs to send 33 bytes.
https://github.com/Hamlib/Hamlib/issues/1196#issuecomment-1367473810
2022-12-29 11:36:50 -06:00
Mike Black W9MDB 04ccccb02d astyle newcat.c 2022-12-28 16:36:59 -06:00
Mike Black W9MDB 7e81e8552a FTDX5000 will now remember startup front/rear setting and restore it
Will also allow front/rear selection in WSJT-X/JTDX
https://github.com/Hamlib/Hamlib/issues/1195
2022-12-28 16:34:32 -06:00
Mike Black W9MDB 1fd44dcef2 Make FT5000 EX1031;TX1; command two commands
https://github.com/Hamlib/Hamlib/issues/1193
2022-12-28 14:27:05 -06:00
Mike Black W9MDB 2306ee4f1d Make sure FT5000 is in data mode for PTT request -- returns to MIC mode on shutdown
https://github.com/Hamlib/Hamlib/issues/1193
2022-12-28 14:11:25 -06:00
Mike Black W9MDB 606aea1552 FT5000 cannot use RIG_PTT_ON_DATA/MIC menu 103 control and is now set for rear automatically too
https://github.com/Hamlib/Hamlib/issues/1193
2022-12-28 12:41:39 -06:00
Mike Black W9MDB cfc2e28c19 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2022-12-26 10:22:16 -06:00
Mike Black W9MDB a75b274f6f Change FTDX5000 write_delay to zero -- was causing microham to return ?; to every command
https://github.com/Hamlib/Hamlib/issues/1080
2022-12-26 10:21:35 -06:00
Mike Black W9MDB ab511cbea6 https://github.com/Hamlib/Hamlib/issues/1080 2022-12-26 09:44:53 -06:00
Mike Black W9MDB 0450b36c67 Fix apex build and warning message
https://github.com/Hamlib/Hamlib/issues/1159
2022-12-25 22:26:52 -06:00
Mike Black W9MDB bc6c14e430 Add Apex Shared Loop rotator
https://github.com/Hamlib/Hamlib/issues/1159
2022-12-25 17:07:26 -06:00
Mike Black W9MDB c59b5383e9 Remove echo from Makefile.am 2022-12-24 22:20:28 -06:00
Mike Black W9MDB 97ef9e5bea Add RIG_LEVEL_AGC_TIME to more Icom rigs
https://github.com/Hamlib/Hamlib/issues/1136
2022-12-24 14:37:32 -06:00
Mike Black W9MDB 5db44be3ba Update NEWS 2022-12-24 14:03:18 -06:00
Mike Black W9MDB e70465a9c0 Fix grep error on mingw build 2022-12-24 11:31:12 -06:00
Mike Black W9MDB b61550bf6b Merge branch 'master' of https://github.com/Hamlib/Hamlib 2022-12-23 23:40:11 -06:00
Mike Black W9MDB 4689a2ff11 Add client_version for rigctld clients to report their version to rigctld
This should allow for rigctld to report deprecation, compatibility, or alternatives
https://github.com/Hamlib/Hamlib/issues/1153
2022-12-23 23:39:20 -06:00
Mike Black W9MDB bfa4bbd50d Full version info now available for Windows File/Properties/Details
Will show git version until released
https://github.com/Hamlib/Hamlib/issues/1168
2022-12-23 17:44:44 -06:00
Mike Black W9MDB 70f38022b6 Update NEWS 2022-12-23 16:53:18 -06:00
Mike Black W9MDB 33b2456129 Make FTDX5000 return to MIC input on closing
https://github.com/Hamlib/Hamlib/issues/1193
2022-12-23 16:49:45 -06:00
Mike Black W9MDB 17f88dccbf Fix version_dll.c
https://github.com/Hamlib/Hamlib/issues/1168
2022-12-22 12:14:29 -06:00
Mike Black W9MDB 267d07f708 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2022-12-22 11:58:13 -06:00
Mike Black W9MDB f31e1b7ad9 File/Properties/Details on hamlib-X.dll now shows information except for File version (still to be fixed)
https://github.com/Hamlib/Hamlib/issues/1168
2022-12-22 11:50:50 -06:00
Mike Black W9MDB cafc094788 Add version information for Windows file/Properties/Details
https://github.com/Hamlib/Hamlib/issues/1168
2022-12-21 15:44:36 -06:00
Mike Black W9MDB b153bcd1e5 Change TX-500 to only have 9600 baud available
https://github.com/Hamlib/Hamlib/issues/1188
2022-12-20 08:29:12 -06:00
Mike Black W9MDB f468fa3c1d Allow POWERSDR to do commands when powered off 2022-12-19 16:58:44 -06:00
Mike Black W9MDB 31e911edb8 Remove powerstat from TX-500 -- was always responding PS0;
https://github.com/Hamlib/Hamlib/issues/1188
2022-12-19 14:55:14 -06:00
Mike Black W9MDB 287fb9091b Update info in hamlib_tuner_control
https://github.com/Hamlib/Hamlib/issues/1192
2022-12-19 14:38:58 -06:00
Mike Black W9MDB 04b18c9d5b Add --set-conf=tuner_control_pathname=hamlib_tuner_control
Program will be passed 0 or 1 (Off or On)
Example script in tests/hamlib_tuner_control
https://github.com/Hamlib/Hamlib/issues/1192
2022-12-19 12:55:18 -06:00
Mike Black W9MDB ea29263f35 Fix unidirectional rig cached frequency (e.g. FT736R)
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-18 09:01:27 -06:00
Mike Black W9MDB b1828d951a Ensure get_powerstat return RIG_OK when rig does not have get_powerstat
https://github.com/Hamlib/Hamlib/issues/1189
2022-12-17 17:23:52 -06:00
Mike Black W9MDB 9970a2767d Reset rig->state.cache.split so it can be set again when rigctld reopens the rig
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-17 10:35:56 -06:00
Mike Black W9MDB 04f5195cfd Do not reset cache for unidirectional rigs
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-17 10:28:31 -06:00
Mike Black W9MDB 9508c45f00 Update NEWS 2022-12-17 10:00:07 -06:00
Mike Black W9MDB 120c580de0 FT-736 did not have get_mode so only call get_mode when available
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-17 09:59:04 -06:00
Mike Black W9MDB 250a5b0211 Update NEWS 2022-12-15 17:14:00 -06:00
Mike Black W9MDB f554c3a7ff Fix kenwood_ts890_get_level -- thanks to N3GB George Baltz 2022-12-15 17:11:08 -06:00
Mike Black W9MDB 32b1ce161e Update NEWS 2022-12-15 12:04:14 -06:00
Michael Black 830bf5a941
Merge pull request #1191 from PianetaRadio/master
Rotator Prosistel elevation with azimuth logic
2022-12-15 11:42:53 -06:00
PianetaRadio 9eecfc3b2d
Update rotlist.h
Add Elevation rotator with Control box responding to azimuth logic
2022-12-15 18:24:55 +01:00
PianetaRadio 40066a6cfa
Update prosistel.c
Add Elevation rotator with Control box responding to azimuth logic
2022-12-15 18:21:23 +01:00
PianetaRadio b1ac588667
Update prosistel.h
Add Elevation rotator with Control box responding to azimuth logic
2022-12-15 18:12:32 +01:00
PianetaRadio 7fc23e59a3
Update prosistel.c
Add Elevation rotator with Control box responding to azimuth logic
2022-12-15 18:09:51 +01:00
Mike Black W9MDB 2a84386ae8 Add simft736.c and update others 2022-12-14 22:59:46 -06:00
Mike Black W9MDB 57f2646daa Update NEWS 2022-12-14 11:17:17 -06:00
Mike Black W9MDB e9192f5a8b Add get_freq cached for FT736R to allow working with gpredict
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-14 11:14:54 -06:00
Mike Black W9MDB a9497b2958 Update NEWS 2022-12-14 11:04:30 -06:00
Mike Black W9MDB eb03592d00 If get_powerstat fails in any way then always return RIG_POWER_ON
https://github.com/Hamlib/Hamlib/issues/1189
2022-12-14 09:05:27 -06:00
Mike Black W9MDB d1fffb7c84 Update NEWS 2022-12-13 08:02:24 -06:00
Mike Black W9MDB 368a07ad78 Update NEWS 2022-12-12 23:53:41 -06:00
Mike Black W9MDB f224e71a58 -R option will keep rig open as long as 1 or more clients are connected
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-12 23:46:53 -06:00
Mike Black W9MDB 5b704d24fb Allow rigctld to close the rig with the -R option when client disconnects.
This makes it close when any one client disconnects.
Should only close when no clients are connected -- that will be the next patch
This is for the FT736R and gpredict
https://github.com/Hamlib/Hamlib/issues/1187
2022-12-12 23:28:22 -06:00
Mike Black W9MDB 5c4c2f7748 If get_powerstat fails assume rig is powered on -- should fix sdr++ problem
https://github.com/Hamlib/Hamlib/issues/1186
2022-12-12 17:38:52 -06:00
Mike Black W9MDB df8b88072a Add all the baud rates to serial.c -- virtual serial ports can handle 4,000,000 baud 2022-12-11 23:18:38 -06:00
Mike Black W9MDB 3a91446287 Update simftdx1200.c 2022-12-11 14:50:13 -06:00
Mike Black W9MDB d977f3fbdb astyle newcat.c 2022-12-11 13:56:29 -06:00
Mike Black W9MDB 294bdc7d2a Add FTDX1200 to rigs that need to ensure PTT is off before changing frequency
https://github.com/Hamlib/Hamlib/issues/1185
2022-12-11 11:53:22 -06:00
Mike Black W9MDB d1dccffd6b Add serialnum parser for MDS rig 2022-12-10 11:58:20 -06:00
Mike Black W9MDB fd24547386 Add new simulators 2022-12-10 11:57:31 -06:00
Mike Black W9MDB 5339b431e4 Fix rigctld segfault when using -P RTS
https://github.com/Hamlib/Hamlib/issues/1182
2022-12-10 11:49:45 -06:00
Mike Black W9MDB 17ad0fcb90 Merge branch 'master' of https://github.com/Hamlib/Hamlib 2022-12-09 23:35:20 -06:00
Mike Black W9MDB 6331709fd6 Add --disable-parallel configure option
https://github.com/Hamlib/Hamlib/issues/1181
2022-12-09 23:35:03 -06:00
Mike Black W9MDB ebdad6d736 Add --disable-parallel configure option 2022-12-09 23:32:51 -06:00
Mike Black W9MDB 6ef7009f6c Merge branch 'master' of https://github.com/Hamlib/Hamlib 2022-12-09 12:19:19 -06:00
Michael Black 2f7e5ab733
Merge pull request #1180 from dforsi/fix/unused-includes
Remove unused includes
2022-12-09 12:19:06 -06:00
Daniele Forsi IU5HKX f359f32bc4 Remove unused include of stdlib.h 2022-12-09 18:10:24 +01:00
Daniele Forsi IU5HKX 34ef939350 Remove unused include of stdarg.h 2022-12-09 18:05:18 +01:00
Daniele Forsi IU5HKX f17a08fe85 Remove unused include of stdbool.h 2022-12-09 18:03:41 +01:00
Daniele Forsi IU5HKX f4923723fb Remove unused includes of ctype.h 2022-12-09 17:43:48 +01:00
Daniele Forsi IU5HKX 05a8aaebe3 Remove unused include of usb_port.h 2022-12-09 17:39:43 +01:00
Daniele Forsi IU5HKX a5773f6f4e Remove unused includes of cal.h 2022-12-09 17:39:43 +01:00
Daniele Forsi IU5HKX 3f077a5cf5 Remove unused includes of gpio.h 2022-12-09 17:31:23 +01:00
Daniele Forsi IU5HKX 6008979708 Remove unused include of getopt.h 2022-12-09 17:31:20 +01:00
Mike Black W9MDB 93c4c28d06 Update NEWS 2022-12-09 09:55:49 -06:00
Nate Bargmann 477c94c8fb
Quell groff warning of "font p not found".
Font names need to be upper case in nroff.
2022-12-09 08:24:36 -06:00
Daniele Forsi IU5HKX 84fc3169df Remove unused includes of frame.h 2022-12-09 14:51:22 +01:00
Daniele Forsi IU5HKX b93551712f Remove unused includes of fcntl.h 2022-12-09 14:06:59 +01:00
Daniele Forsi IU5HKX 2f6b80d98d Remove unused include of cm108.h 2022-12-09 12:41:24 +01:00
Daniele Forsi IU5HKX 6de45dd331 Remove unused include of amp_dummy.h 2022-12-09 12:37:34 +01:00
Daniele Forsi IU5HKX f7fe2912ec Remove unused includes of errno.h 2022-12-09 12:32:54 +01:00
Mike Black W9MDB aa50482c83 astyle flir.c 2022-12-08 22:37:22 -06:00
Mike Black W9MDB 9eddf62687 Update simftdx3000.c 2022-12-08 22:37:10 -06:00
Mike Black W9MDB 0489df5bf1 Update NEWS 2022-12-08 22:36:35 -06:00
Michael Black d369b60f6d
Merge pull request #1164 from andz82/master
Added FLIR/DirectedPerception PTU rotor backend
2022-12-08 22:30:24 -06:00
Mike Black W9MDB dd029a3082 Fix FTDX3000 split problem with sticking on Sub VFO
https://github.com/Hamlib/Hamlib/issues/1177
2022-12-08 22:26:09 -06:00
Mike Black W9MDB 180e49754f Update NEWS 2022-12-08 22:25:18 -06:00
Michael Black 458bb2d9e4
Merge pull request #1179 from PianetaRadio/patch-1
Update NEWS
2022-12-08 16:43:15 -06:00
PianetaRadio 8a057d8bf4
Update NEWS
FT-2000 NB2
2022-12-08 21:03:22 +01:00
Mike Black W9MDB 7b7a0460ed Bump .Net verison to 7.0 for multicast testing 2022-12-08 11:39:22 -06:00
Michael Black 299f1de2f9
Merge pull request #1178 from Hamlib/dependabot/nuget/bindings/csharp/multicast/Newtonsoft.Json-13.0.2
Bump Newtonsoft.Json from 13.0.1 to 13.0.2 in /bindings/csharp/multicast
2022-12-08 10:10:26 -06:00
dependabot[bot] c103d55eff
Bump Newtonsoft.Json from 13.0.1 to 13.0.2 in /bindings/csharp/multicast
Bumps [Newtonsoft.Json](https://github.com/JamesNK/Newtonsoft.Json) from 13.0.1 to 13.0.2.
- [Release notes](https://github.com/JamesNK/Newtonsoft.Json/releases)
- [Commits](https://github.com/JamesNK/Newtonsoft.Json/compare/13.0.1...13.0.2)

---
updated-dependencies:
- dependency-name: Newtonsoft.Json
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-12-08 15:26:53 +00:00
andz 07cc887432 Added Android.mk 2022-11-30 16:06:27 +01:00
andz 0860bda832 Changed header description 2022-11-30 15:56:08 +01:00
andz 0cc4ca778d
Merge branch 'Hamlib:master' into master 2022-11-30 15:50:38 +01:00
andz a522e6f6e7 Added README.md 2022-11-30 15:41:41 +01:00
andz c7d0004b36 Fixed Info command 2022-11-30 15:33:55 +01:00
andz b2d6a856a4 Fixed segfault when read_string failed 2022-11-30 15:00:29 +01:00
andz db690f37ff Cleaned up
* removed all warnings
* retrun -RIG_ENIMPL for all not yet implemented functions
2022-11-30 13:55:00 +01:00
andz 0bdb6827da Implemented FLIR basic funktions:
* flir_init
* flir_cleanup
* flir_open
* flir_close
* flir_set_position
* flir_get_position
* flir_park
* flir_stop
* flir_reset
* flir_move
2022-11-30 12:20:25 +01:00
andz 82ef0a39bf Initial adding FLIR PTU rotator 2022-11-26 01:04:36 +01:00
687 zmienionych plików z 59817 dodań i 15555 usunięć

Wyświetl plik

@ -16,7 +16,7 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
@ -29,7 +29,7 @@ jobs:
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v4
# Override language selection by uncommenting this and choosing your languages
# with:
# languages: go, javascript, csharp, python, cpp, java
@ -37,7 +37,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
#- name: Autobuild
# uses: github/codeql-action/autobuild@v2
# uses: github/codeql-action/autobuild@v4
# Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
@ -52,4 +52,4 @@ jobs:
make
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v4

Wyświetl plik

@ -12,10 +12,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: bootstrap
run: |
sudo apt install libusb-1.0-0-dev
sudo apt install libgpiod-dev
sudo apt install grep
./bootstrap
- name: README Debug

Wyświetl plik

@ -12,10 +12,11 @@ jobs:
runs-on: fedora:32
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: bootstrap
run: |
sudo apt install libusb-1.0-0-dev
sudo apt install libgpiod-dev
./bootstrap
- name: configure
run: ./configure --without-cxx-binding

Wyświetl plik

@ -39,11 +39,11 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v2
uses: actions/checkout@v4
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
@ -54,7 +54,7 @@ jobs:
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
#- name: Autobuild
# uses: github/codeql-action/autobuild@v2
# uses: github/codeql-action/autobuild@v3
# Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl
@ -65,9 +65,10 @@ jobs:
- run: |
sudo apt install libusb-1.0-0-dev
sudo apt install libgpiod-dev
./bootstrap
./configure
make
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v3

8
.gitignore vendored
Wyświetl plik

@ -8,6 +8,8 @@
*.lo
*.la
*.orig
*.sh.log
*.sh.trs
*.swp
$depbase.Tpo
Makefile
@ -53,6 +55,8 @@ tests/ampctld
tests/rigctl
tests/rigctlcom
tests/rigctld
tests/rigctlsync
tests/rigctltcp
tests/rigmem
tests/rigsmtr
tests/rigswr
@ -60,6 +64,8 @@ tests/rotctl
tests/rotctld
tests/testlibusb
tests/rigtestlibusb
tests/rigtestmcast
tests/rigtestmcastrx
src/hamlibdatetime.h
.gdbinit
build/
@ -67,3 +73,5 @@ libs/
obj/
.project
.cproject
.DS_Store
._.DS_Store

128
CODE_OF_CONDUCT.md 100644
Wyświetl plik

@ -0,0 +1,128 @@
# Contributor Covenant Code of Conduct
## Our Pledge
We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, religion, or sexual identity
and orientation.
We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.
## Our Standards
Examples of behavior that contributes to a positive environment for our
community include:
* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the
overall community
Examples of unacceptable behavior include:
* The use of sexualized language or imagery, and sexual attention or
advances of any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email
address, without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting
## Enforcement Responsibilities
Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive,
or harmful.
Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons for moderation
decisions when appropriate.
## Scope
This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.
Examples of representing our community include using an official e-mail address,
posting via an official social media account, or acting as an appointed
representative at an online or offline event.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at
.
All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the
reporter of any incident.
## Enforcement Guidelines
Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:
### 1. Correction
**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community.
**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.
### 2. Warning
**Community Impact**: A violation through a single incident or series
of actions.
**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or
permanent ban.
### 3. Temporary Ban
**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.
**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.
### 4. Permanent Ban
**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.
**Consequence**: A permanent ban from any sort of public interaction within
the community.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.0, available at
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
Community Impact Guidelines were inspired by [Mozilla's code of conduct
enforcement ladder](https://github.com/mozilla/diversity).
[homepage]: https://www.contributor-covenant.org
For answers to common questions about this code of conduct, see the FAQ at
https://www.contributor-covenant.org/faq. Translations are available at
https://www.contributor-covenant.org/translations.

93
CONTRIBUTING.md 100644
Wyświetl plik

@ -0,0 +1,93 @@
# Welcome to Hamlib docs contributing guide <!-- omit in toc -->
Thank you for investing your time in contributing to our project! Any contribution you make will be reflected on [docs.github.com](https://docs.github.com/en) :sparkles:.
Read our [Code of Conduct](./CODE_OF_CONDUCT.md) to keep our community approachable and respectable.
In this guide you will get an overview of the contribution workflow from opening an issue, creating a PR, reviewing, and merging the PR.
Use the table of contents icon <img src="/contributing/images/table-of-contents.png" width="25" height="25" /> on the top left corner of this document to get to a specific section of this guide quickly.
## New contributor guide
To get an overview of the project, read the [README](../README.md) file. Here are some resources to help you get started with open source contributions:
- [Finding ways to contribute to open source on GitHub](https://docs.github.com/en/get-started/exploring-projects-on-github/finding-ways-to-contribute-to-open-source-on-github)
- [Set up Git](https://docs.github.com/en/get-started/getting-started-with-git/set-up-git)
- [GitHub flow](https://docs.github.com/en/get-started/using-github/github-flow)
- [Collaborating with pull requests](https://docs.github.com/en/github/collaborating-with-pull-requests)
## Getting started
To navigate our codebase with confidence, see [the introduction to working in the docs repository](/contributing/README.md) :confetti_ball:. For more information on how we write our markdown files, see "[Using Markdown and Liquid in GitHub Docs](https://docs.github.com/en/contributing/writing-for-github-docs/using-markdown-and-liquid-in-github-docs)."
Check to see what [types of contributions](/contributing/types-of-contributions.md) we accept before making changes. Some of them don't even require writing a single line of code :sparkles:.
### Issues
#### Create a new issue
If you spot a problem with the docs, [search if an issue already exists](https://docs.github.com/en/github/searching-for-information-on-github/searching-on-github/searching-issues-and-pull-requests#search-by-the-title-body-or-comments). If a related issue doesn't exist, you can open a new issue using a relevant [issue form](https://github.com/github/docs/issues/new/choose).
#### Solve an issue
Scan through our [existing issues](https://github.com/github/docs/issues) to find one that interests you. You can narrow down the search using `labels` as filters. See "[Label reference](https://docs.github.com/en/contributing/collaborating-on-github-docs/label-reference)" for more information. As a general rule, we dont assign issues to anyone. If you find an issue to work on, you are welcome to open a PR with a fix.
### Make Changes
#### Make changes in the UI
Click **Make a contribution** at the bottom of any docs page to make small changes such as a typo, sentence fix, or a broken link. This takes you to the `.md` file where you can make your changes and [create a pull request](#pull-request) for a review.
<img src="/contributing/images/contribution_cta.png" />
#### Make changes in a codespace
For more information about using a codespace for working on GitHub documentation, see "[Working in a codespace](https://github.com/github/docs/blob/main/contributing/codespace.md)."
#### Make changes locally
1. Fork the repository.
- Using GitHub Desktop:
- [Getting started with GitHub Desktop](https://docs.github.com/en/desktop/installing-and-configuring-github-desktop/getting-started-with-github-desktop) will guide you through setting up Desktop.
- Once Desktop is set up, you can use it to [fork the repo](https://docs.github.com/en/desktop/contributing-and-collaborating-using-github-desktop/cloning-and-forking-repositories-from-github-desktop)!
- Using the command line:
- [Fork the repo](https://docs.github.com/en/github/getting-started-with-github/fork-a-repo#fork-an-example-repository) so that you can make your changes without affecting the original project until you're ready to merge them.
2. Install or update to **Node.js**, at the version specified in `.node-version`. For more information, see [the development guide](../contributing/development.md).
3. Create a working branch and start with your changes!
### Commit your update
Commit the changes once you are happy with them. Don't forget to use the "[Self review checklist](https://docs.github.com/en/contributing/collaborating-on-github-docs/self-review-checklist)" to speed up the review process :zap:.
### Pull Request
When you're finished with the changes, create a pull request, also known as a PR.
- Fill the "Ready for review" template so that we can review your PR. This template helps reviewers understand your changes as well as the purpose of your pull request.
- Don't forget to [link PR to issue](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue) if you are solving one.
- Enable the checkbox to [allow maintainer edits](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/allowing-changes-to-a-pull-request-branch-created-from-a-fork) so the branch can be updated for a merge.
Once you submit your PR, a Docs team member will review your proposal. We may ask questions or request additional information.
- We may ask for changes to be made before a PR can be merged, either using [suggested changes](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/incorporating-feedback-in-your-pull-request) or pull request comments. You can apply suggested changes directly through the UI. You can make any other changes in your fork, then commit them to your branch.
- As you update your PR and apply changes, mark each conversation as [resolved](https://docs.github.com/en/github/collaborating-with-issues-and-pull-requests/commenting-on-a-pull-request#resolving-conversations).
- If you run into any merge issues, checkout this [git tutorial](https://github.com/skills/resolve-merge-conflicts) to help you resolve merge conflicts and other issues.
### Your PR is merged!
Congratulations :tada::tada: The Hamlib team thanks you :sparkles:.
Once your PR is merged, your contributions will be publicly visible on [Hamlib](https://github.com/Hamlib/Hamlib).
## Windows
This site can be developed on Windows, however a few potential gotchas need to be kept in mind:
1. Regular Expressions: Windows uses `\r\n` for line endings, while Unix-based systems use `\n`. Therefore, when working on Regular Expressions, use `\r?\n` instead of `\n` in order to support both environments. The Node.js [`os.EOL`](https://nodejs.org/api/os.html#os_os_eol) property can be used to get an OS-specific end-of-line marker.
2. Paths: Windows systems use `\` for the path separator, which would be returned by `path.join` and others. You could use `path.posix`, `path.posix.join` etc and the [slash](https://ghub.io/slash) module, if you need forward slashes - like for constructing URLs - or ensure your code works with either.
3. Bash: Not every Windows developer has a terminal that fully supports Bash, so it's generally preferred to write [scripts](/script) in JavaScript instead of Bash.
4. Filename too long error: There is a 260 character limit for a filename when Git is compiled with `msys`. While the suggestions below are not guaranteed to work and could cause other issues, a few workarounds include:
- Update Git configuration: `git config --system core.longpaths true`
- Consider using a different Git client on Windows

Wyświetl plik

@ -362,7 +362,7 @@ the command line of the application's 'configure' script:
These can be set on the Hamlib 'configure' script's command line to see the
effect on the Hamlib utilities when they are built as statically linked
applicatins (--disable-shared option passed to 'configure'). With these
applications (--disable-shared option passed to 'configure'). With these
environment variables it can be seen that 'rigctl' contains no rotor symbols
nor does 'rotctl' contain any rig symbols.

Plik diff jest za duży Load Diff

Wyświetl plik

@ -6,12 +6,12 @@ aclocal_DATA = hamlib.m4
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = hamlib.pc
EXTRA_DIST = PLAN LICENSE hamlib.m4 hamlib.pc.in README.developer \
EXTRA_DIST = PLAN LICENSE hamlib.m4 hamlib.pc.in README.md README.developer \
README.betatester README.freqranges README.multicast README.osx \
Android.mk
doc_DATA = ChangeLog COPYING COPYING.LIB LICENSE \
README README.betatester README.developer
README.md README.betatester README.developer
SUBDIRS = macros include lib security \
$(BACKEND_LIST) \
@ -28,4 +28,6 @@ DIST_SUBDIRS = macros include lib src c++ bindings tests doc android scripts rot
security $(BACKEND_LIST) $(RIG_BACKEND_LIST) $(ROT_BACKEND_LIST) $(AMP_BACKEND_LIST)
# Install any third party macros into our tree for distribution
ACLOCAL_AMFLAGS = -I macros --install
ACLOCAL_AMFLAGS = -I macros --install
AM_CFLAGS=-D_TIME_BITS=64

151
NEWS
Wyświetl plik

@ -1,8 +1,8 @@
Hamlib -- History of visible changes.
Copyright (C) 2000-2003 Frank Singleton
Copyright (C) 2000-2021 Stephane Fillod, and others
Copyright (C) 2000-2021 Michael Black W9MDB, and others
Copyright (C) 2000-2023 Stephane Fillod, and others
Copyright (C) 2000-2023 Michael Black W9MDB, and others
Please send Hamlib bug reports to hamlib-developer@lists.sourceforge.net
@ -13,13 +13,152 @@ Version 5.x -- future
* Change FT1000MP Mark V model names to align with FT1000MP
Version 4.6
* 2023-11-XX -- Planned for Nov 2023
* Added SDR Radio SDRConsole -- TS-2000 is now hardware flow control so need separate entry
* Added --set-conf=filter_usb, filter_usbd, and filter_cw to allow Icom rigs set mode to set filter number too
* Added macros for applications to obtain pointers to Hamlib structures(issues #1445, #1420, #487).
Internal conversion is still a WIP, but use of these macros will make the final cutover transparent to applications.
* Added Guohe Q900 entry
* Unify behavior of all rigctl split commands
* Make the set_split_* commands modify the state of the specified split VFO -- the current or targeted VFO do not have any effect
* Make the set_split_* commands enable split automatically if not enabled
* Make the get_split_* commands return frequency of 0 Hz, mode NONE and filter of 0 Hz if split is not enabled
* Allow all split commands to avoid VFO swapping if supported by the rig model
* Improve Icom backend to set/get frequency, mode and filter without VFO swapping if supported by the rig model
* Improve Yaesu newcat backend split handling
* Expose "Targetable features" (RIG_TARGETABLE_*) in dump_caps output to allow clients to determine which commands can be executed without VFO swapping
* Added RIG_FUNC_SYNC for FTDX101D/MP
* Added Barrett 4100
* Added DL2MAN (tr)uSDX -- needs refinement
* Added Thetis entry -- derived from FlexRadio/Apache PowerSDR
* Added VOICE/CW memory capability to many rigs -- thanks to David Balharrie M0DGB/G8FKH
* Add -# --skip_init option to rigctl to skip rig initialization -- useful for executing commands quickly
* rig_caps is no longer constant -- this may break some 3rd party relying on the "const" declaration. Here's an example of how to handle compatiblity.
#ifdef RIGCAPS_NOT_CONST
static int add_to_list(struct rig_caps* rc, void*)
#else
static int add_to_list(const struct rig_caps* rc, void*)
#endif
* IC7610 now has IPP, DPP, and TX_INHIBIT functions set/get
* Hamlib now starts a multicast server that sends out rig information. Does not receive commands yet.
See README.multicast
* rigctld has new -b/bind-all option to try all interfaces -- restores original behavior. This was done to fix duplicate rigctld instances on Windows
* Yaesu rigs can now use send_morse to send keyer message 1-5 or a CW message up to 50 chars (which will use memory 1)
* rig set level METER can now take SWR,COMP,ALC,IC/ID,DB,PO,VDD,TEMP arguments to set which meter to display
* reg get level displays meter number=name now
* Added parm BANDSELECT for Yaesu rigs
'p BANDSELECT' returns current band of VFOA
'P BANDSELECT BAND160M' example selects the 160M band
'P BANDSELECT ?' shows bands available for the rig
* Added rig_cm108_get/set_bit to API and get/set_gpio to rigctl(d) for GPIO1,2,3,4 access on CM108
* Added BG2FX FX4/C/CR/L
* Fixed IC7610 to use new 0x25 0x26 command added in latest firmware
* Fix W command in rigctld to work propery -- can take terminating char or # of bytes to expect
* Add rig_set_debug_filename so Python can redirect debug stream
* Fix Yaesu LBL_NR to use proper values
* Add IC-905
* Add Anytone D578UVIII -- should work on any D558 model and perhaps others too
* Add saebrtrack rotor https://sites.google.com/site/marklhammond/saebrtrack
* Add offset_vfoa and offset_vfob applying to rig_set_freq
* Fix K4 to put it in K40 mode when requesting ID
* Fixes for M2 Rotors
* Add rigctlsync utility to synchronize frequency from a rig to SDR# (or others)
* Add SDR# rig for use with SDR#'s gpredict plugin -- can only get/set freq
* Add Apex Shared Loop rotator -- unidirectional only so far
* Add client_version to rigctld so client can report it's version for future use/compatibility/alternatives
* Add --set-conf=tuner_control_pathname=hamlib_tuner_control (default)
If file exists then it will be called with 0/1 (Off/On) argument
with 'U TUNER 0' or 'U TUNER 1"
Default path is for current directory
* Add MDS 4710/9710 rigs
* Add FLIR PTU-D48, E46, D100, D300 rotors
* Fix FTDX3000 rig split
Version 4.5.6
* Fix rigctld/rigctltcp information
* Fix FT817 get/set_vfo
Version 4.5.5
* 2023-04-05
* Add park to rotorez.c
* Fix rig power on/off from rigctl cmd line and rigctld
* Enable async mode by default to prevent WSJT-X crash on IC9700 with transceive on
* Fix IC7610 get_powerstat to disable it -- cannot read power status
* Fix K3 K22 command error for remote operations
* Fix Gemini DX1200 gemini_set_level
* Fix async I/O to not call flush
* Change EX startup commands for Yaesu rigs to allow errors...Win4Yaesu not recognizing EX commands
* Fix jst145 set_freq and get_freq
* Restore tcflush as some odd behavior was seen that tclush fixes
* Fix XG3 operations
* Separate the validation cmd in newcat.c to allow rig post_write_delay to be in effect
* Increase post_write to 20ms for FT710
* Add attenuator level control for TS890
* Update SMeter/SWR tables for TS890
* Add fix for TMD700
* Improve FT-857 get_vfo response when error occurs
* Allow FT-857 to use cached vfo on get_vfo when error occurs reading EEPROM
* Fix FTDX10 FT710 set_level AF
* Fix FT-450D detection
* Fix VFO A/B swapping for gpredict -- hopefully better behavior for VFO swapping rigs
Should avoid setting RX freq while TX and avoid TX freq while RX
* Fix QRP QDX PTT to new TQ command due to firmware changes
* Remove EX103 check for FTDX5000
* Fix K3/K3S VFOB setting of mode/width
* Fix AGC level display in rigctld
* Change FTDX10 to no serial handshake
* Add TS2000 to has_ps exception
* Add FT991 to 60M exception
* Fix get_powerstat bad call in rigctl_parse.c
* Really fix CM108 ptt_bitnum usage
* Fix Elecraft power2mW precision/accuracy
* Fix power on/off/on for Icom rigs with rigctld power_on=0
Version 4.5.4
* 2023-01-10
* Fix CM108 ptt setting for non-default usage
* Fix power on/off for Icom rigs with rigctld power_on=0
* Fix get_powerstat status return for non-PS kenwood rigs
* Fix FT-710, FTDX10, FTDX101D/MP usage on 60M
* Fix timing on NRD-535D
* Fix AGC levels with rigctld
* Fix FTDX3000 EX039 error
* Fix Elecraft power2mW operation
* Fix rig_power2mW so it checks all ranges
* Allow rigctld to start with autopower_on=0 to avoid startup timeouts when rig is powered off
* Fix dummy device to work with grig by disallowing empty "u" call
* Fix ID5100 and promote to stable and hopefully ID4100 too
* Remove get_powerstat from Icom ID-5100,ID-4100,ID-31,ID-51 and fix get/set freq in all
Version 4.5.3
* 2022-12-31
* Fix serial.c for hardware flow control on Linux and MacOSy
* Add QRPLabs QCX/QDX rig -- not quite a TS480
* Fix QRP QRDX firmware bugs in IF message so PTT works now
* FTDX5000 will now remember startup front/read settings and restore it
* Fix FTDX5000 write_delay with microham
* Fix grep error on MingW build
Version 4.5.2
* 2022-12-23
* Fix PowerSDR ability to do commands while powered off
* Fix TX-500 operations
* Fix FTDX5000 to return to MIC input on closing
* Fix rig.c calling rig_get_mode when backend does not have get_mode
* Fix kenwood_ts890_get_level
* Add Prosistel D elevation CBOX az to fix problem with azimuth control
* Fix FT736R gpredict usage by adding cached get_freq
* Fix get_powerstat problem with Log4OM/Flex and others
* Fix -R option to not need argument
* Fix -R option to close rig on last rigctld client disconnect
* Add FTDX1200 to rigs that need to ensure PTT is off before changing frequency
* Add --disable-parallel configure option for mingw builds on Linux
Version 4.5.1
* 2022-XX-XX
* 2022-12-08
* FT2000, FTDX3000/D, FT891, FT991, FT950, FTDX5000 now set CAT TOT to 100ms
* Add missing NB2 setting to FT-950, FTDX-1200, FTDX-3000, FTDX-5000, FTDX-9000
* Add missing NB2 setting to FT-950, FTDX-1200, FT-2000, FTDX-3000, FTDX-5000, FTDX-9000
* Add missing meter reading to TS-890S -- thanks to Geore Baltz N3GB
* Fix FT736 VFOB freq and mode set
* Added send_raw to rigctl -- see rigctl man page
@ -118,7 +257,7 @@ Version 4.3.1
- scripts: Update example in readme, since 4.0 817 is 1020
- Make testlibusb.c compatible with libusb < 1.0.23
Note: On systems with libusb < 1.0.23 a warning will be emitted
but compliation should proceed without error.
but compilation should proceed without error.
- Update testlibusb.c warning to "may be" instead of "will be"
- Change kenwood to only set VFOA default on 1st rig_open call

Wyświetl plik

@ -2,7 +2,8 @@ Hamlib - (C) Frank Singleton 2000 (vk3fcs@ix.netcom.com)
(C) Stephane Fillod 2000-2011
(C) The Hamlib Group 2000-2013
Take a look at http://sourceforge.net/projects/hamlib/
Primary site for the latest development version of Hamlib is https://github.com/Hamlib/Hamlib
Also take a look at http://sourceforge.net/projects/hamlib/
Here you will find a mail list, and the latest releases.
See README.md for frontend/backend outline.

Wyświetl plik

@ -1,13 +1,69 @@
Planned for version 5.0 -- comments/suggestions about this are more than welcome
Planned for version 4.6 -- comments/suggestions about this are more than welcome
Example of multicast packet as of 2023-10-20
===================================================================
{
"app": "Hamlib",
"version": "4.6~git 2023-10-20T16:52:59Z SHA=d87671",
"seq": 183,
"time": "2023-10-20T20:13:53.139869-0000",
"crc": 0,
"rig": {
"id": "FLRig:127.0.0.1:12345:30508",
"status": "OK",
"errorMsg": "",
"name": "FLRig",
"split": false,
"splitVfo": "VFOA",
"satMode": false,
"modelist": "AM CW USB LSB FM CWR PKTLSB PKTUSB "
},
"vfos": [
{
"name": "VFOA",
"freq": 14074270,
"mode": "PKTUSB",
"width": 3,
"ptt": false,
"rx": true,
"tx": true
},
{
"name": "VFOB",
"freq": 14074500,
"mode": "",
"width": 0,
"ptt": false,
"rx": false,
"tx": false
}
],
"spectra": [
{
"id": 0,
"name": "?",
"type": "FIXED",
"minLevel": 0,
"maxLevel": 0,
"minStrength": 0,
"maxStrength": 0,
"centerFreq": 0,
"span": 0,
"lowFreq": 0,
"highFreq": 0,
"length": 0,
"data": ""
}
]
}
===========================================================
Multicast UDP broadcast containing rig snapshot data
Bidirectional rig control and status
Choice of token pairs or JSON
All packets will be tagged with ID=[unique name] -- so multiple rigs can broadcast/rx on the same port
Will be able to set freq, mode, width, ptt, satmode, and split to start since those are common to many apps.
Will eventually be able to set freq, mode, width, ptt, satmode, and split to start since those are common to many apps.
More functions will be added as time goes on.
Broadcast packet contents to be based on get_rig_info output
This will be the text format of name=value pairs
Can be multiple VFO lines
Parsers should allow for unknown tags that may be added in the future
@ -34,14 +90,23 @@ JSON data snapshot format for UDP packets:
"crc": 0,
"rig": {
"__comment1__": "customizable rig identification -- will allow multiple rigs to be on the multicast",
"id": "Rig#1",
"name": "Dummy",
"id": {
"model":"IC-7300",
"endpoint":"com1",
"process":"53535",
}
"name": "IC-7300",
"ptt" : false,
"split": true,
"splitVfo": "VFOB",
"satMode": false,
"status": "OK";
"errorMsg": "OK",
"modes":[
"AM",
"CW",
"USB"
]
},
"vfos": [
{

Wyświetl plik

@ -7,6 +7,10 @@ A developer cannot apply for HSHR for segfaults on his/her own code.
Here is the list of the brave fellows:
* Christoph Berg DF7CB python with Hamlib.rig_parse(None)
* Saku Nyland OH1KH v4.5.1, 10/2022, rigctld.c using ptt_type=RTS
* David Kjellquist WB5NHL, v1.1.3, 09/2002, kenwood/ts570.c
caught on TS570D backend startup.

Wyświetl plik

@ -21,7 +21,6 @@
#include <stdlib.h>
#include <string.h>
#include "misc.h"
#include "kpa.h"
struct fault_list
@ -75,7 +74,7 @@ int kpa_init(AMP *amp)
return -RIG_ENOMEM;
}
amp->state.ampport.type.rig = RIG_PORT_SERIAL;
AMPPORT(amp)->type.rig = RIG_PORT_SERIAL;
return RIG_OK;
}
@ -93,18 +92,14 @@ int kpa_close(AMP *amp)
int kpa_flushbuffer(AMP *amp)
{
struct amp_state *rs;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
rs = &amp->state;
return rig_flush(&rs->ampport);
return rig_flush(AMPPORT(amp));
}
int kpa_transaction(AMP *amp, const char *cmd, char *response, int response_len)
{
struct amp_state *rs;
hamlib_port_t *ampp = AMPPORT(amp);
int err;
int len = 0;
int loop;
@ -115,19 +110,17 @@ int kpa_transaction(AMP *amp, const char *cmd, char *response, int response_len)
kpa_flushbuffer(amp);
rs = &amp->state;
loop = 3;
do // wake up the amp by sending ; until we receive ;
{
char c = ';';
rig_debug(RIG_DEBUG_VERBOSE, "%s waiting for ;\n", __func__);
err = write_block(&rs->ampport, (unsigned char *) &c, 1);
err = write_block(ampp, (unsigned char *) &c, 1);
if (err != RIG_OK) { return err; }
len = read_string(&rs->ampport, (unsigned char *) response, response_len, ";",
len = read_string(ampp, (unsigned char *) response, response_len, ";",
1, 0, 1);
if (len < 0) { return len; }
@ -135,14 +128,14 @@ int kpa_transaction(AMP *amp, const char *cmd, char *response, int response_len)
while (--loop > 0 && (len != 1 || response[0] != ';'));
// Now send our command
err = write_block(&rs->ampport, (unsigned char *) cmd, strlen(cmd));
err = write_block(ampp, (unsigned char *) cmd, strlen(cmd));
if (err != RIG_OK) { return err; }
if (response) // if response expected get it
{
response[0] = 0;
len = read_string(&rs->ampport, (unsigned char *) response, response_len, ";",
len = read_string(ampp, (unsigned char *) response, response_len, ";",
1, 0, 1);
if (len < 0)
@ -165,11 +158,11 @@ int kpa_transaction(AMP *amp, const char *cmd, char *response, int response_len)
{
char c = ';';
rig_debug(RIG_DEBUG_VERBOSE, "%s waiting for ;\n", __func__);
err = write_block(&rs->ampport, (unsigned char *) &c, 1);
err = write_block(ampp, (unsigned char *) &c, 1);
if (err != RIG_OK) { return err; }
len = read_string(&rs->ampport, (unsigned char *) responsebuf, KPABUFSZ, ";", 1,
len = read_string(ampp, (unsigned char *) responsebuf, KPABUFSZ, ";", 1,
0, 1);
if (len < 0) { return len; }
@ -184,6 +177,7 @@ int kpa_transaction(AMP *amp, const char *cmd, char *response, int response_len)
* Get Info
* returns the model name string
*/
// cppcheck-suppress *
const char *kpa_get_info(AMP *amp)
{
const struct amp_caps *rc;
@ -227,7 +221,7 @@ int kpa_get_freq(AMP *amp, freq_t *freq)
int kpa_set_freq(AMP *amp, freq_t freq)
{
char responsebuf[KPABUFSZ];
char responsebuf[KPABUFSZ] = "\0";
int retval;
unsigned long tfreq;
int nargs;
@ -277,7 +271,6 @@ int kpa_get_level(AMP *amp, setting_t level, value_t *val)
int pwrinput;
float float_value = 0;
int int_value = 0, int_value2 = 0;
struct amp_state *rs = &amp->state;
struct kpa_priv_data *priv = amp->state.priv;
@ -373,7 +366,7 @@ int kpa_get_level(AMP *amp, setting_t level, value_t *val)
//
do
{
retval = read_string(&rs->ampport, (unsigned char *) responsebuf,
retval = read_string(AMPPORT(amp), (unsigned char *) responsebuf,
sizeof(responsebuf), ";", 1, 0,
1);

Wyświetl plik

@ -33,7 +33,7 @@
// Is this big enough?
#define KPABUFSZ 100
extern const struct amp_caps kpa1500_rot_caps;
extern const struct amp_caps kpa1500_amp_caps;
/*
* Private data structure

Wyświetl plik

@ -22,7 +22,6 @@
*
*/
#include <hamlib/config.h>
#include <stdio.h>
@ -63,7 +62,7 @@ const struct amp_caps kpa1500_amp_caps =
.mfg_name = "Elecraft",
.version = "20220710.0",
.copyright = "LGPL",
.status = RIG_STATUS_ALPHA,
.status = RIG_STATUS_BETA,
.amp_type = AMP_TYPE_OTHER,
.port_type = RIG_PORT_SERIAL,
.serial_rate_min = 4800,
@ -110,7 +109,6 @@ const struct amp_caps kpa1500_amp_caps =
static int kpa1500_send_priv_cmd(AMP *amp, const char *cmdstr)
{
struct amp_state *rs;
int err;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
@ -120,8 +118,7 @@ static int kpa1500_send_priv_cmd(AMP *amp, const char *cmdstr)
return -RIG_EINVAL;
}
rs = &amp->state;
err = write_block(&rs->ampport, cmdstr, strlen(cmdstr));
err = write_block(AMPPORT(amp), cmdstr, strlen(cmdstr));
if (err != RIG_OK)
{

Wyświetl plik

@ -0,0 +1,12 @@
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
LOCAL_SRC_FILES := expert.c
LOCAL_MODULE := expert
LOCAL_CFLAGS :=
LOCAL_C_INCLUDES := android include src
LOCAL_LDLIBS := -lhamlib
include $(BUILD_STATIC_LIBRARY)

Wyświetl plik

@ -0,0 +1,8 @@
SRC = expert.c
EXPERTSRC = expert.h
noinst_LTLIBRARIES = libhamlib-expert.la
libhamlib_expert_la_SOURCES = $(SRC) $(EXPERTSRC)
EXTRA_DIST = README.expert Android.mk

Wyświetl plik

@ -0,0 +1,7 @@
hamlib - Copyright (C) 2023 The Hamlib Group
File: README.expert
Notes on Expert backends
2023-03-20 Initial prototype for Expert amplifiers

Wyświetl plik

@ -0,0 +1,750 @@
/*
* Hamlib Expert amplifier backend - low level communication routines
* Copyright (c) 2023 by Michael Black W9MDB
*
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#include <stdlib.h>
#include <string.h>
#include "expert.h"
#include "register.h"
#include "misc.h"
struct fault_list
{
int code;
char *errmsg;
};
const struct fault_list expert_fault_list [] =
{
{0, "No fault condition"},
{0x10, "Watchdog Timer was reset"},
{0x20, "PA Current is too high"},
{0x40, "Temperature is too high"},
{0x60, "Input power is too high"},
{0x61, "Gain is too low"},
{0x70, "Invalid frequency"},
{0x80, "50V supply voltage too low or too high"},
{0x81, "5V supply voltage too low or too high"},
{0x82, "10V supply voltage too low or too high"},
{0x83, "12V supply voltage too low or too high"},
{0x84, "-12V supply voltage too low or too high"},
{0x85, "5V or 400V LPF board supply voltages not detected"},
{0x90, "Reflected power is too high"},
{0x91, "SWR very high"},
{0x92, "ATU no match"},
{0xB0, "Dissipated power too high"},
{0xC0, "Forward power too high"},
{0xE0, "Forward power too high for current setting"},
{0xF0, "Gain is too high"},
{0, NULL}
};
/*
* Initialize data structures
*/
int expert_init(AMP *amp)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp)
{
return -RIG_EINVAL;
}
amp->state.priv = (struct expert_priv_data *)
calloc(1, sizeof(struct expert_priv_data));
if (!amp->state.priv)
{
return -RIG_ENOMEM;
}
AMPPORT(amp)->type.rig = RIG_PORT_SERIAL;
return RIG_OK;
}
int expert_open(AMP *amp)
{
unsigned char cmd = 0x80;
unsigned char response[256];
rig_debug(RIG_DEBUG_TRACE, "%s: entered\n", __func__);
expert_transaction(amp, &cmd, 1, response, 256);
return RIG_OK;
}
int expert_close(AMP *amp)
{
unsigned char cmd = 0x81;
unsigned char response[256];
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
expert_transaction(amp, &cmd, 1, response, 4);
if (amp->state.priv) { free(amp->state.priv); }
amp->state.priv = NULL;
return RIG_OK;
}
int expert_flushbuffer(AMP *amp)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
return rig_flush(AMPPORT(amp));
}
int expert_transaction(AMP *amp, const unsigned char *cmd, int cmd_len,
unsigned char *response, int response_len)
{
hamlib_port_t *ampp = AMPPORT(amp);
int err;
int len = 0;
char cmdbuf[64];
int checksum = 0;
if (cmd) { rig_debug(RIG_DEBUG_VERBOSE, "%s called, cmd=%80s\n", __func__, cmd); }
else
{
rig_debug(RIG_DEBUG_ERR, "%s: cmd empty\n", __func__);
return -RIG_EINVAL;
}
if (!amp) { return -RIG_EINVAL; }
expert_flushbuffer(amp);
cmdbuf[0] = cmdbuf[1] = cmdbuf[2] = 0x55;
for (int i = 0; i < cmd_len; ++i) { checksum += cmd[i]; }
checksum = checksum % 256;
cmdbuf[3] = cmd_len;
memcpy(&cmdbuf[4], cmd, cmd_len);
cmdbuf[3 + cmd_len + 1] = checksum;
// Now send our command
err = write_block(ampp, (unsigned char *) cmdbuf, 3 + cmd_len + 2);
if (err != RIG_OK) { return err; }
if (response) // if response expected get it
{
int bytes = 0;
response[0] = 0;
// read the 4-byte header x55x55x55xXX where XX is the hex # of bytes
len = read_block_direct(ampp, (unsigned char *) response, 4);
rig_debug(RIG_DEBUG_ERR, "%s: len=%d, bytes=%02x\n", __func__, len,
response[3]);
if (len < 0)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s: error=%s\n", __func__,
rigerror(len));
return len;
}
if (len == 4) { bytes = response[3]; }
rig_debug(RIG_DEBUG_ERR, "%s: bytes=%d\n", __func__, bytes);
len = read_block_direct(ampp, (unsigned char *) response, bytes - 3);
dump_hex(response, len);
}
else // if no response expected try to get one
{
char responsebuf[KPABUFSZ];
responsebuf[0] = 0;
int loop = 3;
do
{
char c = ';';
rig_debug(RIG_DEBUG_VERBOSE, "%s waiting for ;\n", __func__);
err = write_block(ampp, (unsigned char *) &c, 1);
if (err != RIG_OK) { return err; }
len = read_string(ampp, (unsigned char *) responsebuf, KPABUFSZ, ";", 1,
0, 1);
if (len < 0) { return len; }
}
while (--loop > 0 && (len != 1 || responsebuf[0] != ';'));
}
return RIG_OK;
}
/*
* Get Info
* returns the model name string
*/
// cppcheck-suppress constParameterCallback
const char *expert_get_info(AMP *amp)
{
const struct amp_caps *rc;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp) { return (const char *) - RIG_EINVAL; }
rc = amp->caps;
return rc->model_name;
}
int expert_get_freq(AMP *amp, freq_t *freq)
{
char responsebuf[KPABUFSZ] = "\0";
int retval;
unsigned long tfreq;
int nargs;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp) { return -RIG_EINVAL; }
retval = expert_transaction(amp, NULL, 0, NULL, sizeof(responsebuf));
if (retval != RIG_OK) { return retval; }
nargs = sscanf(responsebuf, "^FR%lu", &tfreq);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s Error: ^FR response='%s'\n", __func__,
responsebuf);
return -RIG_EPROTO;
}
*freq = tfreq * 1000;
return RIG_OK;
}
int expert_set_freq(AMP *amp, freq_t freq)
{
char responsebuf[KPABUFSZ] = "\0";
int retval;
unsigned long tfreq;
int nargs;
unsigned char cmd[KPABUFSZ];
rig_debug(RIG_DEBUG_VERBOSE, "%s called, freq=%"PRIfreq"\n", __func__, freq);
if (!amp) { return -RIG_EINVAL; }
// SNPRINTF(cmd, sizeof(cmd), "^FR%05ld;", (long)freq / 1000);
cmd[0] = 0x00;
retval = expert_transaction(amp, cmd, 0, NULL, 0);
if (retval != RIG_OK) { return retval; }
nargs = sscanf(responsebuf, "^FR%lu", &tfreq);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s Error: ^FR response='%s'\n", __func__,
responsebuf);
return -RIG_EPROTO;
}
if (tfreq * 1000 != freq)
{
rig_debug(RIG_DEBUG_ERR,
"%s Error setting freq: ^FR freq!=freq2, %f=%lu '%s'\n", __func__,
freq, tfreq * 1000, responsebuf);
return -RIG_EPROTO;
}
return RIG_OK;
}
int expert_get_level(AMP *amp, setting_t level, value_t *val)
{
char responsebuf[KPABUFSZ] = "\0";
unsigned char cmd[8];
int retval;
int fault;
int i;
int nargs;
int antenna;
int pwrpeak;
int pwrref;
int pwrfwd;
int pwrinput;
float float_value = 0;
int int_value = 0, int_value2 = 0;
struct expert_priv_data *priv = amp->state.priv;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
// get the current antenna selected
cmd[0] = 0x00;
retval = expert_transaction(amp, cmd, 0, NULL, sizeof(responsebuf));
if (retval != RIG_OK) { return retval; }
antenna = 0;
nargs = sscanf(responsebuf, "^AE%d", &antenna);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s: invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
rig_debug(RIG_DEBUG_VERBOSE, "%s: cmd=%s, antenna=%d\n", __func__, cmd,
antenna);
switch (level)
{
case AMP_LEVEL_SWR:
cmd[0] = 0x00;
break;
case AMP_LEVEL_NH:
cmd[0] = 0x00;
break;
case AMP_LEVEL_PF:
cmd[0] = 0x00;
break;
case AMP_LEVEL_PWR_INPUT:
cmd[0] = 0x00;
break;
case AMP_LEVEL_PWR_FWD:
cmd[0] = 0x00;
break;
case AMP_LEVEL_PWR_REFLECTED:
cmd[0] = 0x00;
break;
case AMP_LEVEL_PWR_PEAK:
cmd[0] = 0x00;
break;
case AMP_LEVEL_FAULT:
cmd[0] = 0x00;
break;
}
retval = expert_transaction(amp, cmd, 0, NULL, sizeof(responsebuf));
if (retval != RIG_OK) { return retval; }
switch (level)
{
case AMP_LEVEL_SWR:
//nargs = sscanf(responsebuf, "^SW%f", &float_value);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
val->f = float_value / 10.0f;
return RIG_OK;
case AMP_LEVEL_NH:
case AMP_LEVEL_PF:
//nargs = sscanf(responsebuf, "^DF%d,%d", &int_value, &int_value2);
if (nargs != 2)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
rig_debug(RIG_DEBUG_VERBOSE, "%s freq range=%dKHz,%dKHz\n", __func__,
int_value, int_value2);
//
do
{
retval = read_string(AMPPORT(amp), (unsigned char *) responsebuf,
sizeof(responsebuf), ";", 1, 0,
1);
if (retval != RIG_OK) { return retval; }
if (strstr(responsebuf, "BYPASS") != 0)
{
int antenna2 = 0;
nargs = sscanf(responsebuf, "AN%d Side TX %d %*s %*s %d", &antenna2, &int_value,
&int_value2);
rig_debug(RIG_DEBUG_VERBOSE, "%s response='%s'\n", __func__, responsebuf);
if (nargs != 3)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
rig_debug(RIG_DEBUG_VERBOSE, "%s antenna=%d,nH=%d\n", __func__, antenna2,
int_value);
val->i = level == AMP_LEVEL_NH ? int_value : int_value2;
return RIG_OK;
}
}
while (strstr(responsebuf, "BYPASS"));
break;
case AMP_LEVEL_PWR_INPUT:
cmd[0] = 0x00;
nargs = sscanf(responsebuf, "^SW%d", &pwrinput);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
val->i = pwrinput;
return RIG_OK;
break;
case AMP_LEVEL_PWR_FWD:
cmd[0] = 0x00;
nargs = sscanf(responsebuf, "^SW%d", &pwrfwd);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
val->i = pwrfwd;
return RIG_OK;
break;
case AMP_LEVEL_PWR_REFLECTED:
cmd[0] = 0x00;
nargs = sscanf(responsebuf, "^SW%d", &pwrref);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
val->i = pwrref;
return RIG_OK;
break;
case AMP_LEVEL_PWR_PEAK:
cmd[0] = 0x00;
nargs = sscanf(responsebuf, "^SW%d", &pwrpeak);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
val->i = pwrpeak;
return RIG_OK;
break;
case AMP_LEVEL_FAULT:
cmd[0] = 0x00;
nargs = sscanf(responsebuf, "^SW%d", &fault);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_ERR, "%s invalid value %s='%s'\n", __func__, cmd,
responsebuf);
return -RIG_EPROTO;
}
for (i = 0; expert_fault_list[i].errmsg != NULL; ++i)
{
if (expert_fault_list[i].code == fault)
{
val->s = expert_fault_list[i].errmsg;
return RIG_OK;
}
}
rig_debug(RIG_DEBUG_ERR, "%s unknown fault from %s\n", __func__, responsebuf);
SNPRINTF(priv->tmpbuf, sizeof(priv->tmpbuf), "Unknown fault code=0x%02x",
fault);
val->s = priv->tmpbuf;
return RIG_OK;
break;
default:
rig_debug(RIG_DEBUG_ERR, "%s unknown level=%s\n", __func__,
rig_strlevel(level));
}
return -RIG_EINVAL;
}
int expert_get_powerstat(AMP *amp, powerstat_t *status)
{
unsigned char responsebuf[KPABUFSZ] = "\0";
int retval;
int operate = 0;
int ampon = 0;
int nargs = 0;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
*status = RIG_POWER_UNKNOWN;
if (!amp) { return -RIG_EINVAL; }
retval = expert_transaction(amp, NULL, 0, responsebuf, sizeof(responsebuf));
if (retval != RIG_OK) { return retval; }
//nargs = sscanf(responsebuf, "^ON%d", &ampon);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s Error: ^ON response='%s'\n", __func__,
responsebuf);
return -RIG_EPROTO;
}
switch (ampon)
{
case 0: *status = RIG_POWER_OFF; return RIG_OK;
case 1: *status = RIG_POWER_ON; break;
default:
rig_debug(RIG_DEBUG_VERBOSE, "%s Error: ^ON unknown response='%s'\n", __func__,
responsebuf);
return -RIG_EPROTO;
}
retval = expert_transaction(amp, NULL, 0, responsebuf, sizeof(responsebuf));
if (retval != RIG_OK) { return retval; }
//nargs = sscanf(responsebuf, "^ON%d", &operate);
if (nargs != 1)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s Error: ^ON response='%s'\n", __func__,
responsebuf);
return -RIG_EPROTO;
}
*status = operate == 1 ? RIG_POWER_OPERATE : RIG_POWER_STANDBY;
return RIG_OK;
}
int expert_set_powerstat(AMP *amp, powerstat_t status)
{
int retval;
unsigned char cmd[8];
int cmd_len = 1;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp) { return -RIG_EINVAL; }
switch (status)
{
case RIG_POWER_UNKNOWN: break;
case RIG_POWER_OFF: cmd[0] = 0x0a; break;
case RIG_POWER_ON: cmd[0] = 0x0b; break;
case RIG_POWER_OPERATE: cmd[0] = 0x0d; break;
case RIG_POWER_STANDBY: cmd[0] = 0x0a; break;
default:
rig_debug(RIG_DEBUG_ERR, "%s invalid status=%d\n", __func__, status);
cmd[0] = 0x00;
}
retval = expert_transaction(amp, cmd, cmd_len, NULL, 0);
if (retval != RIG_OK) { return retval; }
return RIG_OK;
}
int expert_reset(AMP *amp, amp_reset_t reset)
{
int retval;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
// toggling from standby to operate supposed to reset
retval = expert_set_powerstat(amp, RIG_POWER_STANDBY);
if (retval != RIG_OK)
{
rig_debug(RIG_DEBUG_ERR, "%s: error setting RIG_POWER_STANDBY '%s'\n", __func__,
strerror(retval));
}
return expert_set_powerstat(amp, RIG_POWER_OPERATE);
}
struct expert_priv_data *expert_priv;
/*
* API local implementation
*
*/
/*
* Private helper function prototypes
*/
/* *************************************
*
* Separate model capabilities
*
* *************************************
*/
/*
* Expert 1.3K-FA, 1.5K-FA, and 2K-FA
*/
const struct amp_caps expert_amp_caps =
{
AMP_MODEL(AMP_MODEL_EXPERT_FA),
.model_name = "1.3K-FA/1.5K-FA/2K-FA",
.mfg_name = "Expert",
.version = "20230328.0",
.copyright = "LGPL",
.status = RIG_STATUS_BETA,
.amp_type = AMP_TYPE_OTHER,
.port_type = RIG_PORT_SERIAL,
.serial_rate_min = 9600,
.serial_rate_max = 115200,
.serial_data_bits = 8,
.serial_stop_bits = 1,
.serial_parity = RIG_PARITY_NONE,
.serial_handshake = RIG_HANDSHAKE_NONE,
.write_delay = 0,
.post_write_delay = 0,
.timeout = 2000,
.retry = 2,
.has_get_level = AMP_LEVEL_SWR | AMP_LEVEL_NH | AMP_LEVEL_PF | AMP_LEVEL_PWR_INPUT | AMP_LEVEL_PWR_FWD | AMP_LEVEL_PWR_REFLECTED | AMP_LEVEL_FAULT,
.has_set_level = 0,
.amp_open = expert_open,
.amp_init = expert_init,
.amp_close = expert_close,
.reset = expert_reset,
.get_info = expert_get_info,
.get_powerstat = expert_get_powerstat,
.set_powerstat = expert_set_powerstat,
.set_freq = expert_set_freq,
.get_freq = expert_get_freq,
.get_level = expert_get_level,
};
/* ************************************
*
* API functions
*
* ************************************
*/
/*
*
*/
#if 0 // not implemented yet
/*
* Send command string to amplifier
*/
static int expert_send_priv_cmd(AMP *amp, const char *cmdstr)
{
int err;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp)
{
return -RIG_EINVAL;
}
err = write_block(AMPPORT(amp), cmdstr, strlen(cmdstr));
if (err != RIG_OK)
{
return err;
}
return RIG_OK;
}
#endif
/*
* Initialize backend
*/
DECLARE_INITAMP_BACKEND(expert)
{
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
amp_register(&expert_amp_caps);
return RIG_OK;
}

Wyświetl plik

@ -0,0 +1,62 @@
/*
* Hamlib backend library for the Expert amplifier set.
*
* expert.h - (C) Michael Black W9MDB 2023
*
* This shared library provides an API for communicating
* via serial interface to Expert amplifiers.
*
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#ifndef _AMP_EXPERT_H
#define _AMP_EXPERT_H 1
#include <hamlib/amplifier.h>
#include <iofunc.h>
#include <serial.h>
// Is this big enough?
#define KPABUFSZ 100
extern const struct amp_caps expert_amp_caps;
/*
* Private data structure
*/
struct expert_priv_data
{
char tmpbuf[256]; // for unknown error msg
};
int expert_init(AMP *amp);
int expert_close(AMP *amp);
int expert_reset(AMP *amp, amp_reset_t reset);
int expert_flush_buffer(AMP *amp);
int expert_transaction(AMP *amp, const unsigned char *cmd, int cmd_len, unsigned char *response,
int response_len);
const char *expert_get_info(AMP *amp);
int expert_get_freq(AMP *amp, freq_t *freq);
int expert_set_freq(AMP *amp, freq_t freq);
int expert_get_level(AMP *amp, setting_t level, value_t *val);
int expert_get_powerstat(AMP *amp, powerstat_t *status);
int expert_set_powerstat(AMP *amp, powerstat_t status);
#endif /* _AMP_EXPERT_H */

Wyświetl plik

@ -22,7 +22,6 @@
*
*/
#include <hamlib/config.h>
#include <stdio.h>
@ -61,9 +60,9 @@ const struct amp_caps gemini_amp_caps =
AMP_MODEL(AMP_MODEL_GEMINI_DX1200),
.model_name = "DX1200/HF-1K",
.mfg_name = "Gemini",
.version = "20220710.0",
.version = "20230318.0",
.copyright = "LGPL",
.status = RIG_STATUS_ALPHA,
.status = RIG_STATUS_STABLE,
.amp_type = AMP_TYPE_OTHER,
.port_type = RIG_PORT_NETWORK,
.write_delay = 0,
@ -105,7 +104,6 @@ const struct amp_caps gemini_amp_caps =
static int gemini_send_priv_cmd(AMP *amp, const char *cmdstr)
{
struct amp_state *rs;
int err;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
@ -115,8 +113,7 @@ static int gemini_send_priv_cmd(AMP *amp, const char *cmdstr)
return -RIG_EINVAL;
}
rs = &amp->state;
err = write_block(&rs->ampport, cmdstr, strlen(cmdstr));
err = write_block(AMPPORT(amp), cmdstr, strlen(cmdstr));
if (err != RIG_OK)
{

Wyświetl plik

@ -24,11 +24,13 @@
#include "misc.h"
#include "gemini.h"
#if 0
struct fault_list
{
int code;
char *errmsg;
};
#endif
/*
* Initialize data structures
@ -51,7 +53,7 @@ int gemini_init(AMP *amp)
return -RIG_ENOMEM;
}
amp->state.ampport.type.rig = RIG_PORT_NETWORK;
AMPPORT(amp)->type.rig = RIG_PORT_NETWORK;
return RIG_OK;
}
@ -69,22 +71,17 @@ int gemini_close(AMP *amp)
int gemini_flushbuffer(AMP *amp)
{
struct amp_state *rs;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
rs = &amp->state;
return rig_flush(&rs->ampport);
return rig_flush(AMPPORT(amp));
}
int gemini_transaction(AMP *amp, const char *cmd, char *response,
int response_len)
{
struct amp_state *rs;
hamlib_port_t *ampp = AMPPORT(amp);
int err;
int len = 0;
rig_debug(RIG_DEBUG_VERBOSE, "%s called, cmd=%s\n", __func__, cmd);
@ -92,18 +89,16 @@ int gemini_transaction(AMP *amp, const char *cmd, char *response,
gemini_flushbuffer(amp);
rs = &amp->state;
// Now send our command
err = write_block(&rs->ampport, (unsigned char *) cmd, strlen(cmd));
err = write_block(ampp, (unsigned char *) cmd, strlen(cmd));
if (err != RIG_OK) { return err; }
if (response) // if response expected get it
{
response[0] = 0;
len = read_string(&rs->ampport, (unsigned char *) response, response_len, "\n",
1, 0, 1);
int len = read_string(ampp, (unsigned char *) response, response_len,
"\n", 1, 0, 1);
if (len < 0)
{
@ -123,6 +118,7 @@ int gemini_transaction(AMP *amp, const char *cmd, char *response,
* Get Info
* returns the model name string
*/
// cppcheck-suppress constParameterPointer
const char *gemini_get_info(AMP *amp)
{
const struct amp_caps *rc;
@ -157,7 +153,7 @@ int gemini_status_parse(AMP *amp)
{
char tmp[8];
double freq;
n += sscanf(p, "BAND=%lf%s", &freq, tmp);
n += sscanf(p, "BAND=%lf%7s", &freq, tmp);
if (tmp[0] == 'K') { priv->band = freq * 1000; }
@ -168,10 +164,10 @@ int gemini_status_parse(AMP *amp)
n += sscanf(p, "VSWR=%lf", &priv->vswr);
n += sscanf(p, "CURRENT=%d", &priv->current);
n += sscanf(p, "TEMPERATURE=%d", &priv->temperature);
n += sscanf(p, "STATE=%s", priv->state);
n += sscanf(p, "PTT=%s", tmp);
n += sscanf(p, "STATE=%7s", priv->state);
n += sscanf(p, "PTT=%7s", tmp);
priv->ptt = tmp[0] == 'T';
n += sscanf(p, "TRIP=%s", priv->trip);
n += sscanf(p, "TRIP=%7s", priv->trip);
if (n == 0)
{
@ -187,12 +183,14 @@ int gemini_status_parse(AMP *amp)
int gemini_get_freq(AMP *amp, freq_t *freq)
{
int retval;
struct gemini_priv_data *priv = amp->state.priv;
struct gemini_priv_data *priv;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (!amp) { return -RIG_EINVAL; }
priv = amp->state.priv;
retval = gemini_status_parse(amp);
if (retval != RIG_OK) { return retval; }
@ -282,13 +280,12 @@ int gemini_set_level(AMP *amp, setting_t level, value_t val)
if (val.f < .67) { cmd = "PM\n"; }
return RIG_OK;
break;
}
retval = gemini_transaction(amp, cmd, NULL, 0);
if (retval != RIG_OK) { return retval; }
if (retval == RIG_OK) { return retval; }
rig_debug(RIG_DEBUG_ERR, "%s: Unknown level=%s\n", __func__,
rig_strlevel(level));

Wyświetl plik

@ -39,7 +39,7 @@ BUILT_SOURCES += hamlibperl_wrap.c
MOSTLYCLEANFILES += hamlibperl_wrap.c Hamlib.pm Hamlib.bs Hamlib-pl.mk.old
example_DATA += perltest.pl
hamlibperl_wrap.c: hamlib.swg $(SWIGDEP)
hamlibperl_wrap.c: hamlib.swg $(SWIGDEP) ignore.swg rig.swg
$(AM_V_GEN)$(SWIG) -perl5 -shadow $(AM_CPPFLAGS) -I$(top_srcdir)/bindings \
-o $@ $$(test -f hamlib.swg || echo '$(srcdir)/')hamlib.swg

Wyświetl plik

@ -92,14 +92,14 @@ typedef struct Amp {
AMPMETHOD1(set_powerstat, powerstat_t)
void set_conf(const char *name, const char *val) {
token_t tok = amp_token_lookup(self->amp, name);
hamlib_token_t tok = amp_token_lookup(self->amp, name);
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;
else
self->error_status = amp_set_conf(self->amp, tok, val);
}
AMPMETHOD2(set_conf, token_t, const_char_string)
AMPMETHOD2(set_conf, hamlib_token_t, const_char_string)
/*
* declare wrapper method with one output argument besides AMP*
@ -110,14 +110,14 @@ typedef struct Amp {
/* get functions */
const char *get_conf(token_t tok) {
const char *get_conf(hamlib_token_t tok) {
static char s[128] = "";
self->error_status = amp_get_conf(self->amp, tok, s);
return s;
}
const char *get_conf(const char *name) {
token_t tok = amp_token_lookup(self->amp, name);
hamlib_token_t tok = amp_token_lookup(self->amp, name);
static char s[128] = "";
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;

Wyświetl plik

@ -0,0 +1,8 @@
Phase I
Broadcast primary rig info plus full packet with dummy values
Phase II
Receive basic rig commands
Phase III
Extend broadcast info
Phase IV
Extend rig commands

Wyświetl plik

@ -2,15 +2,15 @@ Works on Windows and Linux
Requires you get dotnet installed of course
For Wiundows install Visual Studio or such to get dotnet
For Windows install Visual Studio or such to get dotnet
On Ubuntu 20.04 it was this
On Ubuntu 21.04 it was this
apt install snap
apt install mono-complete
snap install dotnet-sdk --classic --channel=5.0
snap install dotnet-sdk --classic --channel=6.0
snap alias dotnet-sdk.dotnet dotnet
snap install dotnet-runtime-50 --classic
snap alias dotnet-runtime-50.dotnet dotnet
snap install dotnet-runtime-60 --classic
snap alias dotnet-runtime-60.dotnet dotnet
export DOTNET_ROOT=/snap/dotnet-sdk/current
Once dotnet is OK
@ -19,4 +19,20 @@ dotnet build
You should then be able to run
./bin/Debug/net5.0/multicast
./bin/Debug/net6.0/multicast
======================================================
Waiting for Net 7.0/8.0 to be in Ubunut main packages
Following did not work
sudo apt remove 'dotnet*' 'aspnet*' 'netstandard*'
touch /etc/apt/preferences
// add to preferences
Package: dotnet* aspnet* netstandard*
Pin: origin "archive.ubuntu.com"
Pin-Priority: -10
// end preferences
snap remove dotnet-sdk
snap install dotnet-sdk --classic --channel=7.0
snap alias dotnet-runtime-70.dotnet dotnet

Wyświetl plik

@ -9,6 +9,7 @@ namespace HamlibMultiCast
{
public class HamlibMulticastClient
{
public string __comment1__;
public class VFO
{
public string Name;
@ -17,19 +18,25 @@ namespace HamlibMultiCast
public int Width;
public bool RX;
public bool TX;
public int WidthLower;
public int WidthUpper;
}
public string __comment_spectrum__;
public class SpectrumClass
{
public string Name;
public int Length;
public string __comment_spectrum_data__;
public string Data;
public string Type;
public int MinLevel;
public int MaxLevel;
public int MinStrength;
public int MaxStrength;
public string __comment_spectrum_center__;
public double CenterFreq;
public int Span;
public string __comment_spectrum_fixed__;
public double LowFreq;
public double HighFreq;
}
@ -38,14 +45,26 @@ namespace HamlibMultiCast
public string Command;
public string Status;
}
public string __comment_gps__;
public class GPS {
public double Latitude;
public double Longitude;
public double Altitude;
}
public string ID;
public string VFOCurr;
public List<VFO> VFOs { get; set; }
public bool Split;
public string __comment_time__;
public string Time;
public bool SatMode;
public string Rig;
public string App;
public string __comment_version__;
public string Version;
public string __comment_seq__;
public UInt32 Seq;
public string __comment_crc__;
public string CRC;
public List<SpectrumClass> Spectra { get; set; }
}

Wyświetl plik

@ -2,11 +2,11 @@
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<TargetFramework>net7.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.2" />
</ItemGroup>
</Project>

Wyświetl plik

@ -1,78 +1,16 @@
"ID": "FT-991:/dev/ttyUSB0",
"Time": 2023-05-05T04:32:47.834952-0000,
"Sequence": 892,
"VFOCurr": "VFOA",
"VFOs": [
{
"__comment1__": "customizable rig identification -- will allow multiple rigs to be on the multicast",
"ID": "Rig#1",
"VFOs": [
{
"Name": "VFOA",
"Freq": 14074000,
"Mode": "USB",
"Width": 5000,
"RX": true,
"TX": false
},
{
"Name": "VFOB",
"Freq": 14076000,
"Mode": "USB",
"Width": 5000,
"RX": false,
"TX": false
}],
"__comment_spectrum__": "Rigs that have spectrum output may include this data",
"Spectra": [
{
"Name": "Main",
"Length": 475,
"__comment_spectrum_data__": "2-char hex bytes so data len=2*Length",
"Data": "00AAFF75BD2AAA...",
"Type": "FIXED|CENTER",
"MinLevel": 0,
"MaxLevel": 140,
"MinStrength": -100,
"MaxStrength": 0,
"__comment_spectrum_center__": "If Type=CENTER, the following fields will be present:",
"CenterFreq": 14267000,
"Span": 25000,
"__comment_spectrum_fixed__": "If SpectrumType=FIXED, the following fields will be present:",
"LowFreq": 14000000,
"HighFreq": 14250000
},
{
"Name": "Sub",
"Length": 475,
"__comment_spectrum_data__": "2-char hex bytes so data len=2*Length",
"Data": "00AAFF75BD2AAA...",
"Type": "FIXED|CENTER",
"MinLevel": 0,
"MaxLevel": 140,
"MinStrength": -100,
"MaxStrength": 0,
"__comment_spectrum_center__": "If Type=CENTER, the following fields will be present:",
"CenterFreq": 14267000,
"Span": 25000,
"__comment_spectrum_fixed__": "If SpectrumType=FIXED, the following fields will be present:",
"LowFreq": 14000000,
"HighFreq": 14250000
}],
"LastCommand": {
"ID": "MyApp 123",
"Command": "set_freq VFOA 14074000",
"Status": "OK"
},
"Split": true,
"SatMode": false,
"Rig": "Dummy",
"App": "Hamlib",
"__comment_version__": "protocol version date YYYYMMDD",
"Version": "20210520",
"__comment_seq__": "Seq is 1-up sequence number 32-bit -- wraps around to 1 from 2^32-1",
"Seq": 1,
"__comment_crc__": "32-bit CRC of entire JSON record replacing the CRC value with 0x00000000",
"CRC": "0x00000000"
{
,
"Name": "VFOA",
"Freq": 14086800,
"Mode": "AM",
"Width": 9000,
"RX": True,
"TX": False
}

Wyświetl plik

@ -213,6 +213,8 @@
%ignore hamlib_version2;
%ignore macro_name;
%ignore FIFO_RIG;
#ifdef SWIGLUA
%ignore Rig::set_level(setting_t,int,vfo_t);
%ignore Rig::set_ext_level(setting_t,value_t,vfo_t);

Wyświetl plik

@ -359,7 +359,7 @@ typedef channel_t * const_channel_t_p;
METHOD3(set_ts, shortfreq_t)
METHOD2(set_ant, ant_t, value_t)
METHOD2(set_func, setting_t, int)
METHOD2(set_ext_func, token_t, int)
METHOD2(set_ext_func, hamlib_token_t, int)
METHOD3(set_bank, int)
METHOD3(set_mem, int)
METHOD3(send_dtmf, const_char_string)
@ -371,7 +371,7 @@ typedef channel_t * const_channel_t_p;
METHODSUPERSET(level, int, i, RIG_LEVEL_IS_FLOAT(stg))
METHODSUPERSET(level, float, f, !RIG_LEVEL_IS_FLOAT(stg))
METHODSTRSET(level)
METHOD2(set_ext_level, token_t, value_t)
METHOD2(set_ext_level, hamlib_token_t, value_t)
METHODSIMPLEGET(level, int, i, RIG_LEVEL_IS_FLOAT(stg))
METHODSIMPLEGET(level, float, f, !RIG_LEVEL_IS_FLOAT(stg))
@ -403,8 +403,8 @@ typedef channel_t * const_channel_t_p;
METHOD1(ext_token_lookup, const_char_string) /* level & parm */
METHOD1(token_lookup, const_char_string) /* conf */
METHOD2(set_conf, token_t, const_char_string)
METHOD2(set_ext_parm, token_t, value_t)
METHOD2(set_conf, hamlib_token_t, const_char_string)
METHOD2(set_ext_parm, hamlib_token_t, value_t)
METHODSIMPLESET(parm, int, i, RIG_PARM_IS_FLOAT(stg))
METHODSIMPLESET(parm, float, f, !RIG_PARM_IS_FLOAT(stg))
@ -420,7 +420,7 @@ typedef channel_t * const_channel_t_p;
void set_conf(const char *name, const char *val) {
token_t tok = rig_token_lookup(self->rig, name);
hamlib_token_t tok = rig_token_lookup(self->rig, name);
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;
else
@ -508,14 +508,14 @@ typedef channel_t * const_channel_t_p;
return chan;
}
void get_conf(token_t tok, char *returnstr) {
void get_conf(hamlib_token_t tok, char *returnstr) {
returnstr[0] = '\0';
self->error_status = rig_get_conf(self->rig, tok, returnstr);
}
void get_conf(const char *name, char *returnstr) {
returnstr[0] = '\0';
token_t tok = rig_token_lookup(self->rig, name);
hamlib_token_t tok = rig_token_lookup(self->rig, name);
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;
else
@ -540,7 +540,7 @@ typedef channel_t * const_channel_t_p;
return status;
}
int get_ext_func(token_t func, vfo_t vfo = RIG_VFO_CURR) {
int get_ext_func(hamlib_token_t func, vfo_t vfo = RIG_VFO_CURR) {
int status;
self->error_status = rig_get_ext_func(self->rig, vfo, func, &status);
return status;
@ -554,7 +554,7 @@ typedef channel_t * const_channel_t_p;
/* TODO: dynamic casting */
}
void get_ext_level(token_t token, vfo_t vfo = RIG_VFO_CURR)
void get_ext_level(hamlib_token_t token, vfo_t vfo = RIG_VFO_CURR)
{ value_t val = {0}; self->error_status = rig_get_level(self->rig, vfo, token, &val);
//if (RIG_LEVEL_IS_FLOAT(level))
/* TODO: dynamic casting */
@ -566,7 +566,7 @@ typedef channel_t * const_channel_t_p;
/* TODO: dynamic casting */
}
void get_ext_parm(token_t parm)
void get_ext_parm(hamlib_token_t parm)
{ value_t val = {0}; self->error_status = rig_get_parm(self->rig, parm, &val);
//if (RIG_LEVEL_IS_FLOAT(parm))
/* TODO: dynamic casting */

Wyświetl plik

@ -88,23 +88,23 @@ typedef struct Rot {
ROTMETHOD1(token_lookup, const_char_string) /* conf */
void set_conf(const char *name, const char *val) {
token_t tok = rot_token_lookup(self->rot, name);
hamlib_token_t tok = rot_token_lookup(self->rot, name);
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;
else
self->error_status = rot_set_conf(self->rot, tok, val);
}
ROTMETHOD2(set_conf, token_t, const_char_string)
ROTMETHOD2(set_conf, hamlib_token_t, const_char_string)
const char *get_conf(token_t tok) {
const char *get_conf(hamlib_token_t tok) {
static char s[128] = "";
self->error_status = rot_get_conf(self->rot, tok, s);
return s;
}
const char *get_conf(const char *name) {
token_t tok = rot_token_lookup(self->rot, name);
hamlib_token_t tok = rot_token_lookup(self->rot, name);
static char s[128] = "";
if (tok == RIG_CONF_END)
self->error_status = -RIG_EINVAL;

Wyświetl plik

@ -65,7 +65,7 @@ void Amplifier::close(void) {
CHECK_AMP( amp_close(theAmp) );
}
void Amplifier::setConf(token_t token, const char *val)
void Amplifier::setConf(hamlib_token_t token, const char *val)
{
CHECK_AMP( amp_set_conf(theAmp, token, val) );
}
@ -74,7 +74,7 @@ void Amplifier::setConf(const char *name, const char *val)
CHECK_AMP( amp_set_conf(theAmp, tokenLookup(name), val) );
}
void Amplifier::getConf(token_t token, char *val)
void Amplifier::getConf(hamlib_token_t token, char *val)
{
CHECK_AMP( amp_get_conf(theAmp, token, val) );
}
@ -83,7 +83,7 @@ void Amplifier::getConf(const char *name, char *val)
CHECK_AMP( amp_get_conf(theAmp, tokenLookup(name), val) );
}
token_t Amplifier::tokenLookup(const char *name)
hamlib_token_t Amplifier::tokenLookup(const char *name)
{
return amp_token_lookup(theAmp, name);
}

Wyświetl plik

@ -76,7 +76,7 @@ void Rig::close(void) {
CHECK_RIG( rig_close(theRig) );
}
void Rig::setConf(token_t token, const char *val)
void Rig::setConf(hamlib_token_t token, const char *val)
{
CHECK_RIG( rig_set_conf(theRig, token, val) );
}
@ -85,7 +85,7 @@ void Rig::setConf(const char *name, const char *val)
CHECK_RIG( rig_set_conf(theRig, tokenLookup(name), val) );
}
void Rig::getConf(token_t token, char *val)
void Rig::getConf(hamlib_token_t token, char *val)
{
CHECK_RIG( rig_get_conf(theRig, token, val) );
}
@ -94,7 +94,7 @@ void Rig::getConf(const char *name, char *val)
CHECK_RIG( rig_get_conf(theRig, tokenLookup(name), val) );
}
token_t Rig::tokenLookup(const char *name)
hamlib_token_t Rig::tokenLookup(const char *name)
{
return rig_token_lookup(theRig, name);
}

Wyświetl plik

@ -64,7 +64,7 @@ void Rotator::close(void) {
CHECK_ROT( rot_close(theRot) );
}
void Rotator::setConf(token_t token, const char *val)
void Rotator::setConf(hamlib_token_t token, const char *val)
{
CHECK_ROT( rot_set_conf(theRot, token, val) );
}
@ -73,7 +73,7 @@ void Rotator::setConf(const char *name, const char *val)
CHECK_ROT( rot_set_conf(theRot, tokenLookup(name), val) );
}
void Rotator::getConf(token_t token, char *val)
void Rotator::getConf(hamlib_token_t token, char *val)
{
CHECK_ROT( rot_get_conf(theRot, token, val) );
}
@ -82,7 +82,7 @@ void Rotator::getConf(const char *name, char *val)
CHECK_ROT( rot_get_conf(theRot, tokenLookup(name), val) );
}
token_t Rotator::tokenLookup(const char *name)
hamlib_token_t Rotator::tokenLookup(const char *name)
{
return rot_token_lookup(theRot, name);
}

Wyświetl plik

@ -11,7 +11,7 @@ int main(int argc, char* argv[])
Rig myRig {RIG_MODEL_DUMMY};
try {
myRig.setConf("rig_pathname", "/dev/ttyS1");
myRig.setConf("rig_pathname", "/dev/pts/4");
myRig.open();
myRig.setFreq(MHz(144));
std::cout << myRig.getLevelI(RIG_LEVEL_STRENGTH) << "dB" << std::endl;

Wyświetl plik

@ -15,6 +15,8 @@ dnl however, the use of '~' should be fine as apt (others?) will treat
dnl it as an earlier version than the actual release. TNX KA6MAL
dnl PACKAGE_NAME + " " + PACKAGE_VERSION must not exceed 20 chars!
AC_INIT([Hamlib],[4.6~git],[hamlib-developer@lists.sourceforge.net],[hamlib],[http://www.hamlib.org])
#AC_INIT([PRODUCT_NAME], [Hamlib])
#AC_DEFINE([Hamlib], [PRODUCT_VERSION_RESOURCE])
AC_CONFIG_SRCDIR([include/hamlib/rig.h])
AC_CONFIG_MACRO_DIR([macros])
@ -41,27 +43,48 @@ m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
## ------------------------------ ##
## Hamlib specific configuration. ##
## ------------------------------ ##
AC_ARG_ENABLE([shared],
[AS_HELP_STRING([--enable-shared],
[Enable shared libraries @<:@default=yes@:>@])],
[enable_shared=$enableval],
[enable_shared=yes])
AC_ARG_ENABLE([static],
[AS_HELP_STRING([--enable-static],
[Enable static libraries @<:@default=check@:>@])],
[enable_static=$enableval],
[enable_static=check])
AS_IF([test "x$enable_static" = "xyes"], [
enable_shared=no
])
AS_IF([test "x$enable_static" = "xyes" && test "x$enable_shared" = "xyes"], [
AC_MSG_ERROR([Both --enable-static and --enable-shared cannot be enabled at the same time.])
])
dnl New backends must be listed here! Also the new Makefile path must be
dnl added to AC_CONFIG_FILES near the end of this file. See README.developer
dnl Beware of duplication should a backend directory include both rig and
dnl rotor definitions, e.g. "dummy". Optional backends will not be listed
dnl here but will be added later, e.g. "winradio".
RIG_BACKEND_LIST="rigs/adat rigs/alinco rigs/aor rigs/barrett rigs/codan rigs/dorji rigs/drake rigs/dummy rigs/elad rigs/flexradio rigs/icom rigs/icmarine rigs/jrc rigs/kachina rigs/kenwood rigs/kit rigs/lowe rigs/pcr rigs/prm80 rigs/racal rigs/rft rigs/rs rigs/skanti rigs/tapr rigs/tentec rigs/tuner rigs/uniden rigs/winradio rigs/wj rigs/yaesu rigs/gomspace rigs/mds"
ROT_BACKEND_LIST="rotators/amsat rotators/ars rotators/celestron rotators/cnctrk rotators/grbltrk rotators/easycomm rotators/ether6 rotators/fodtrack rotators/gs232a rotators/heathkit rotators/m2 rotators/meade rotators/rotorez rotators/sartek rotators/spid rotators/ts7400 rotators/prosistel rotators/ioptron rotators/satel rotators/radant"
RIG_BACKEND_LIST="rigs/adat rigs/alinco rigs/aor rigs/barrett rigs/codan rigs/dorji rigs/drake rigs/dummy rigs/elad rigs/flexradio rigs/icom rigs/icmarine rigs/jrc rigs/kachina rigs/kenwood rigs/kit rigs/lowe rigs/pcr rigs/prm80 rigs/racal rigs/rft rigs/rs rigs/skanti rigs/tapr rigs/tentec rigs/tuner rigs/uniden rigs/winradio rigs/wj rigs/yaesu rigs/gomspace rigs/mds rigs/anytone rigs/motorola"
ROT_BACKEND_LIST="rotators/amsat rotators/apex rotators/ars rotators/celestron rotators/cnctrk rotators/grbltrk rotators/easycomm rotators/ether6 rotators/flir rotators/fodtrack rotators/gs232a rotators/heathkit rotators/m2 rotators/meade rotators/rotorez rotators/sartek rotators/saebrtrack rotators/spid rotators/ts7400 rotators/prosistel rotators/ioptron rotators/satel rotators/radant"
# Amplifiers are all in the amplifiers directory
AMP_BACKEND_LIST="amplifiers/elecraft amplifiers/gemini"
AMP_BACKEND_LIST="amplifiers/elecraft amplifiers/gemini amplifiers/expert"
dnl See README.release on setting these values
# Values given to -version-info when linking. See libtool documentation.
# Set them here to keep c++/Makefile and src/Makefile in sync.
ABI_VERSION=4
ABI_REVISION=6
ABI_PATCH=0
ABI_AGE=0
AC_DEFINE_UNQUOTED([ABI_VERSION], [$ABI_VERSION], [Frontend ABI version])
AC_DEFINE_UNQUOTED([ABI_REVISION], [$ABI_REVISION], [Frontend ABI revision])
AC_DEFINE_UNQUOTED([ABI_AGE], [$ABI_AGE], [Frontend ABI age])
AC_DEFINE_UNQUOTED([ABI_VERSION_MAJOR], [$ABI_VERSION], [Frontend Major version])
AC_DEFINE_UNQUOTED([ABI_VERSION_MINOR], [$ABI_REVISION], [Frontend Minor version])
AC_DEFINE_UNQUOTED([ABI_VERSION_PATCH], [$ABI_PATCH], [Frontend Patch version])
AC_SUBST([ABI_VERSION])
AC_SUBST([ABI_REVISION])
@ -71,7 +94,7 @@ AC_SUBST([ABI_AGE])
AM_CPPFLAGS="${AM_CPPFLAGS} -DIN_HAMLIB"
# Add Hamlib header include paths
AM_CPPFLAGS="${AM_CPPFLAGS} -I\$(top_srcdir)/include -I\$(top_srcdir)/src -I\$(top_srcdir)/lib -I\$(top_builddir)/include"
AM_CPPFLAGS="${AM_CPPFLAGS} -I\$(top_srcdir)/include -I\$(top_srcdir)/src -I\$(top_srcdir)/lib -I\$(top_builddir)/include -I\$(top_srcdir)/include/hamlib -D_TIME_BITS=64 -D_FILE_OFFSET_BITS=64"
## --------------- ##
@ -218,7 +241,17 @@ AC_CHECK_FUNC([gethostbyname],
[],
[AC_CHECK_LIB([ws2_32],
[main],
[NET_LIBS="$NET_LIBS -lws2_32"],
[NET_LIBS="$NET_LIBS -lws2_32 -liphlpapi"],
[],
[])
])
# Winsock2 32 bit
AC_CHECK_FUNC([timeBeginPeriod],
[],
[AC_CHECK_LIB([winmm],
[main],
[NET_LIBS="$NET_LIBS -lwinmm"],
[],
[])
])
@ -260,6 +293,7 @@ LT_PREREQ([2.2.6b])
dnl N.B. LT_INIT([win32-dll]) does not work for older libtool
dnl so require new enough version above.
LT_INIT([win32-dll])
LT_LANG([Windows Resource])
## -------------------------- ##
@ -267,9 +301,10 @@ LT_INIT([win32-dll])
## -------------------------- ##
dnl The host_os variable is set by the AC_CANONICAL_HOST macro above.
AM_CONDITIONAL([VERSIONDLL], false)
AS_CASE(["$host_os"],
[freebsd*], [
AM_CPPFLAGS="-I/usr/local/include ${AM_CPPFLAGS}"
AM_CPPFLAGS="${AM_CPPFLAGS} -I/usr/local/include"
AM_LDFLAGS="${AM_LDFLAGS} -L/usr/local/lib"
AC_SUBST([AM_LDFLAGS])],
@ -281,7 +316,9 @@ AS_CASE(["$host_os"],
AC_SUBST([OSXLDFLAGS])],
[mingw* | pw32* | cygwin*], [
AM_CONDITIONAL([VERSIONDLL], true)
WINLDFLAGS="-Wl,--output-def,libhamlib.def -Wl,--add-stdcall-alias"
VERSIONDLL="version_dll.rc"
AC_SUBST([WINLDFLAGS])
# Enable ld's "auto import" for executables
@ -362,12 +399,14 @@ AS_IF([test x"$ax_cv_lib_readline" = "xno"], [
dnl Check if INDI support in rigctl/rotctl is wanted
AC_MSG_CHECKING([whether to use INDI in rigctl/rotctl])
AC_ARG_WITH([indi],
[AS_HELP_STRING([--without-indi],
[disable INDI in rigctl/rotctl @<:@default=yes@:>@])],
[cf_with_indi_support=no],
[cf_with_indi_support=yes]
#AS_IF([test x"${cf_with_cxx_binding}" = "xyes"], [
AC_ARG_WITH([indi],
[AS_HELP_STRING([--without-indi],
[disable INDI in rigctl/rotctl @<:@default=yes@:>@])],
[cf_with_indi_support=yes],
[cf_with_indi_support=no]
)
#])
AS_IF([test x"$cf_with_indi_support" != "xno"], [
# INDI support needs a C++ compiler, tested for presence above.
@ -694,6 +733,15 @@ AC_ARG_ENABLE([winradio],
[cf_with_winradio="yes" AC_DEFINE([HAVE_WINRADIO],[1],[Define if winradio backend is built])])
AC_MSG_RESULT([$cf_with_winradio])
dnl Parallel port device disable
AC_MSG_CHECKING([whether to build parallel port devices])
AC_ARG_ENABLE([parallel],
[AS_HELP_STRING([--disable-parallel],
[do not build parallel devices @<:@default=yes@:>@])],
[cf_with_parallel="no"],
[cf_with_parallel="yes" AC_DEFINE([HAVE_PARALLEL],[1],[Define if parallel devices are to be built])])
AC_MSG_RESULT([$cf_with_parallel])
DL_LIBS=""
AS_IF([test x"${cf_with_winradio}" = "xyes"],
@ -828,12 +876,14 @@ bindings/Makefile
doc/Makefile
doc/hamlib.cfg
rotators/amsat/Makefile
rotators/apex/Makefile
rotators/ars/Makefile
rotators/celestron/Makefile
rotators/cnctrk/Makefile
rotators/grbltrk/Makefile
rotators/easycomm/Makefile
rotators/ether6/Makefile
rotators/flir/Makefile
rotators/fodtrack/Makefile
rotators/gs232a/Makefile
rotators/heathkit/Makefile
@ -843,6 +893,7 @@ rotators/meade/Makefile
rotators/prosistel/Makefile
rotators/rotorez/Makefile
rotators/sartek/Makefile
rotators/saebrtrack/Makefile
rotators/spid/Makefile
rotators/ts7400/Makefile
rotators/indi/Makefile
@ -880,11 +931,14 @@ rigs/wj/Makefile
rigs/yaesu/Makefile
rigs/gomspace/Makefile
rigs/mds/Makefile
rigs/anytone/Makefile
rigs/motorola/Makefile
tests/Makefile
scripts/Makefile
android/Makefile
amplifiers/elecraft/Makefile
amplifiers/gemini/Makefile
amplifiers/expert/Makefile
simulators/Makefile
hamlib.pc
])
@ -913,6 +967,7 @@ echo \
Enable HTML rig feature matrix ${cf_enable_html_matrix}
Enable WinRadio ${cf_with_winradio}
Enable Parallel ${cf_with_parallel}
Enable USRP ${cf_with_usrp}
Enable USB backends ${cf_with_libusb}
Enable shared libs ${enable_shared}

Wyświetl plik

@ -1,5 +1,5 @@
#!/bin/sh
set -x
# Author Michael Black W9MDB
# This SUPPRESS setting results in no warnings as of 2020-01-14
# There are things that could still be done...especially in the C++ area
@ -14,6 +14,7 @@ SUPPRESS="\
-i bindings \
-i lib/getopt.c \
-i lib/getopt_long.c \
-i lib/cJSON.c \
--suppress=*:extra/gnuradio/demod.h \
--suppress=*:extra/gnuradio/HrAGC.h \
--suppress=*:extra/gnuradio/nfm.h \
@ -22,12 +23,9 @@ SUPPRESS="\
--suppress=*:extra/gnuradio/wfm.h \
--suppress=*:extra/gnuradio/wfm.h \
--suppress=*:extra/gnuradio/HrAGC.h \
--suppress=knownConditionTrueFalse:tests/rotctl.c \
--suppress=knownConditionTrueFalse:tests/rigctl.c \
--suppress=knownConditionTrueFalse:tests/ampctl.c \
--suppress=knownConditionTrueFalse:tests/rotctl_parse.c \
--suppress=knownConditionTrueFalse:tests/rigctl_parse.c \
--suppress=knownConditionTrueFalse:tests/ampctl_parse.c"
--suppress=*:extra/gnuradio/gnuradio.cc \
--suppress=missingIncludeSystem \
--suppress=*:style/rigs/adat/adat.c
#CHECK="\
#-D RIG_LEVEL_LINEOUT=1 \
@ -73,6 +71,7 @@ CHECK="\
-D SIGINT \
-D WIN32 \
-D CLOCK_REALTIME \
-D HAVE_PTHREAD \
-D HAVE_SIGNAL"
# If no directory or file name provided, scan the entire project.
@ -80,30 +79,35 @@ if test $# -eq 0 ; then
echo "See cppcheck.log when done"
echo "This takes a while to run"
cppcheck --inline-suppr \
--check-level=exhaustive \
-I src \
-I include \
--include=include/config.h \
--include=include/hamlib/rig.h \
-I include/hamlib/ \
-I lib \
-I security \
-q \
--force \
--enable=all \
--std=c99 \
$SUPPRESS \
$CHECK \
--template='{file}:{line},{severity},{id},{message}' \
. \
>cppcheck.log 2>&1
else
cppcheck --check-config \
--inline-suppr \
cppcheck --inline-suppr \
--check-level=exhaustive \
-I src \
-I include \
--include=include/config.h \
--include=include/hamlib/rig.h \
-I include/hamlib/ \
-I lib \
-I security \
-q \
--force \
--enable=all \
--std=c99 \
$SUPPRESS \
$CHECK \
$1
--template='{file}:{line},{severity},{id},{message}'\
"$@"
fi

Wyświetl plik

@ -2,7 +2,7 @@ EXTRA_DIST = hamlib.cfg index.doxygen hamlib.css footer.html hamlib.png
dist_man_MANS = man1/ampctl.1 man1/ampctld.1 \
man1/rigctl.1 man1/rigctld.1 man1/rigmem.1 man1/rigsmtr.1 \
man1/rigswr.1 man1/rotctl.1 man1/rotctld.1 man1/rigctlcom.1 \
man1/rigswr.1 man1/rotctl.1 man1/rotctld.1 man1/rigctlcom.1 man1/rigctlsync.1 \
man7/hamlib.7 man7/hamlib-primer.7 man7/hamlib-utilities.7
SRCDOCLST = \

Wyświetl plik

@ -159,7 +159,7 @@ PDF as blocks of constant width text and should be verbatim input or output
in the shell, programs, or blocks of source code.
Text intended to be typed at a shell or program prompt should be in bold and
program orshell output in normal weight. In some cases it will be necessary
program or shell output in normal weight. In some cases it will be necessary
to use the "\fB...\fP" font formatting calls especially where backslash
escapes ("\\") are required.

Wyświetl plik

@ -17,7 +17,7 @@ MAN_EXTENSION = .3
# Set GENERATE_LATEX to YES to generate the needed files for the PDF manual
# and run 'make doc'. Then 'cd latex ; make' to generate the PDF manual.
#
# See section 1.3.1.2 in @top_srcdir@/README.developer for the needed LaTEX
# See section 1.3.1.2 in @top_srcdir@/README.developer for the needed LaTeX
# packages.
USE_PDFLATEX = YES
PDF_HYPERLINKS = YES

Wyświetl plik

@ -81,8 +81,7 @@ Use
.I device
as the file name of the port connected to the radio.
.IP
Often a serial port, but could be a USB to serial adapter. Typically
.IR /dev/ttyS0 ", " /dev/ttyS1 ", " /dev/ttyUSB0 ,
Typically /dev/ttyS0 ", " /dev/ttyS1 ", " /dev/ttyUSB0 ,
etc. on Linux,
.IR COM1 ", " COM2 ,
etc. on MS Windows. The BSD flavors and Mac OS/X have their own designations.
@ -187,8 +186,32 @@ above. Note the dummy device has no serial parameters.
.
.TP
.BR \-C ", " \-\-set\-conf = \fIparm=val\fP [ \fI,parm=val\fP ]
Set radio configuration parameter(s), e.g.
.IR stop_bits=2 .
Set configuration parameter(s). Some common ones are:
.in +4n
.EX
.RB async: "True enables asynchronous data transfer for backends that support it. This allows use of transceive and spectrum data."
.RB auto_power_on: "True enables compatible rigs to be powered up on open"
.RB auto_power_off: "True enables compatible rigs to be powered down on close"
.RB auto_disable_screensaver: "True enables compatible rigs to have their screen saver disabled on open"
.RB dcd_type: "Data Carrier Detect (or squelch) interface type override"
.RB dcd_pathname: "Path name to the device file of the Data Carrier Detect (or squelch)"
.RB disable_yaesu_bandselect: "True disables the automatic band select on band change for Yaesu rigs"
.RB dtr_state: "ON turns on DTR, OFF turns it off, Unset disables it"
.RB lo_freq: "Frequency to add to the VFO frequency for use with a transverter"
.RB post_write_delay: "Delay in ms between each command sent out"
.RB ptt_share: "True enables ptt port to be shared with other apps"
.RB ptt_type: "Push-To-Talk interface type override"
.RB ptt_pathname: "Path name to the device file of the Push-To-Talk"
.RB ptt_bitnum: "Push-To-Talk GPIO bit number"
.RB retry: "Max number of retry"
.RB rts_state: "ON turns on DTR, OFF turns it off, Unset disables it"
.RB twiddle_timeout: "For satellite ops when VFOB is twiddled will pause VFOB commands until timeout"
.RB twiddle_rit: "Suppress get_freq on VFOB for RIT tuning satellites"
.RB timeout: "Timeout in ms"
.RB write_delay: "Delay in ms between each byte sent out"
.RB tuner_control_pathname: "Path name to a script/program to control a tuner with 1 argument of 0/1 for Tuner Off/On"
.EE
.in
.IP
Use the
.B -L
@ -351,12 +374,12 @@ Since most of the
.B Hamlib
operations have a
.BR set " and a " get
method, an upper case letter will often be used for a
method, a single upper case letter will often be used for a
.B set
method whereas the corresponding lower case letter refers to the
method whereas the corresponding single lower case letter refers to the
.B get
method. Each operation also has a long name; in interactive mode, prepend a
backslash, \(oq\\\(cq, to enter a long command name.
backslash, \(oq\\\(cq, to enter a long command name all lower case.
.
.PP
Example: Use \(lq\\dump_caps\(rq to see what capabilities this radio and
@ -701,7 +724,10 @@ Option returned depends on rig..for Icom is likely the RX only flag.
.BR b ", " send_morse " \(aq" \fIMorse\fP \(aq
Send
.RI \(aq Morse \(aq
symbols. For Yaesu rigs use memory#.
symbols. For Yaesu rigs use memory#1-5 or up to 50 char msg
.EX
Example from command line: rigctl -m 3073 -r /dev/ttyUSB0 b "CQ CQ DE ME"
Yaesu example to send message#1: rigctl -m 1035 -r /dev/ttyUSB0 b 1
.
.TP
.BR 0xbb ", " stop_morse "
@ -712,6 +738,11 @@ Stop sending the current morse code.
Wait for morse to finish -- only works on full break-in
.
.TP
.BR 0x94 ", " send_voice_mem " \(aq" \fIMsgnum\fP \(aq
Have rig transmit internal message
.RI \(aq Msgnum \(aq
.
.TP
.BR 0x8b ", " get_dcd
Get
.RI \(aq DCD \(aq
@ -815,7 +846,60 @@ Func is a token: \(oqFAGC\(cq, \(oqNB\(cq, \(oqCOMP\(cq, \(oqVOX\(cq,
\(oqARO\(cq, \(oqLOCK\(cq, \(oqMUTE\(cq, \(oqVSC\(cq, \(oqREV\(cq,
\(oqSQL\(cq, \(oqABM\(cq, \(oqBC\(cq, \(oqMBC\(cq, \(oqRIT\(cq, \(oqAFC\(cq,
\(oqSATMODE\(cq, \(oqSCOPE\(cq, \(oqRESUME\(cq, \(oqTBURST\(cq, \(oqTUNER\(cq,
\(oqXIT\(cq.
\(oqXIT\(cq, \(oqNB2\(cq, \(oqDSQL\(cq, \(oqAFLT\(cq, \(oqANL\(cq, \(oqBC2\(cq,
\(oqDUAL_WATCH\(cq, \(oqDIVERSITY\(cq, \(oqCSQL\(cq, \(oqSCEN\(cq,
\(oqTRANSCEIVE\(cq, \(oqSPECTRUM\(cq, \(oqSPECTRUM_HOLD\(cq, \(oqSEND_MORSE\(cq,
\(oqSEND_VOICE_MEM\(cq, \(oqOVF_STATUS\(cq.
FAGC -- Fast AGC
NB -- Noise Blanker
COMP -- Speech Compression
VOX -- Voice Operated Relay
TONE -- CTCSS Tone TX
TSQL -- CTCSS Activate/De-activate RX
SBKIN -- Semi Break-in (CW mode)
FBKIN -- Full Break-in (CW mode)
ANF -- Automatic Notch Filter (DSP)
NR -- Noise Reduction (DSP)
AIP -- RF pre-amp (AIP on Kenwood, IPO on Yaesu, etc.)
APF -- Audio Peak Filter
MON -- Monitor transmitted signal
MN -- Manual Notch
RF -- RTTY Filter
ARO -- Auto Repeater Offset
LOCK -- Lock
MUTE -- Mute
VSC -- Voice Scan Control
REV -- Reverse transmit and receive frequencies
SQL -- Turn Squelch Monitor on/off
ABM -- Auto Band Mode
BC -- Beat Canceller
MBC -- Manual Beat Canceller
RIT -- Receiver Incremental Tuning
AFC -- Auto Frequency Control ON/OFF
SATMODE -- Satellite mode ON/OFF
SCOPE -- Simple bandscope ON/OFF
RESUME -- Scan auto-resume
TBURST -- 1750 Hz tone burst
TUNER -- Enable automatic tuner
XIT -- Transmitter Incremental Tuning
NB2 -- 2nd Noise Blanker
CSQL -- DCS Squelch setting
AFLT -- AF Filter setting
ANL -- Noise limiter setting
BC2 -- 2nd Beat Cancel
DUAL_WATCH -- Dual Watch / Sub Receiver
DIVERSITY -- Diversity receive
DSQL -- Digital modes squelch
SCEN -- scrambler/encryption
SLICE -- Rig slice selection -- Flex
TRANSCEIVE -- Send radio state changes automatically ON/OFF
SPECTRUM -- Spectrum scope data output ON/OFF
SPECTRUM_HOLD -- Pause spectrum scope updates ON/OFF
SEND_MORSE -- Send specified characters using CW
SEND_VOICE_MEM -- Transmit in SSB message stored in memory
OVF -- Read overflow status 0=Off, 1=On
.IP
Func Status is a non null value for \(lqactivate\(rq or \(lqde-activate\(rq
otherwise, much as TRUE/FALSE definitions in the C language (true is non-zero
@ -854,9 +938,9 @@ Level is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOXDELAY\(cq, \(oqAF\(cq,
\(oqBAL\(cq, \(oqMETER\(cq, \(oqVOXGAIN\(cq, \(oqANTIVOX\(cq,
\(oqSLOPE_LOW\(cq, \(oqSLOPE_HIGH\(cq, \(oqBKIN_DLYMS\(cq, \(oqRAWSTR\(cq, \(oqSWR\(cq,
\(oqALC\(cq, \(oqSTRENGTH\(cq, \(oqRFPOWER_METER\(cq, \(oqCOMPMETER\(cq, \(oqVD_METER\(cq, \(oqID_METER\(cq,
\(oqNOTCHF_RAW\(cq, \(oqMONITOR_GAIN\(cq, \(oqNQ\(cq, \(oqRFPOWER_METER_WATTS\cq, \(oqSPECTRUM_MODE\(cq,
\(oqSPECTRUM_SPAN\(cq, \(oqSPECTRUM_EDGE_LOW\(cq, \(oqSPECTRUM_EDGE_HIGH\(cq, \(oqSPECTRUM_SPEED\cq,
\(oqSPECTRUM_REF\(cq, (oqSPECTRUM_AVG\(cq, \(oqSPECTRUM_ATT\cq, \(oqTEMP_METER\cq, \(oqBAND_SELECT\(cq,
\(oqNOTCHF_RAW\(cq, \(oqMONITOR_GAIN\(cq, \(oqNQ\(cq, \(oqRFPOWER_METER_WATTS\(cq, \(oqSPECTRUM_MODE\(cq,
\(oqSPECTRUM_SPAN\(cq, \(oqSPECTRUM_EDGE_LOW\(cq, \(oqSPECTRUM_EDGE_HIGH\(cq, \(oqSPECTRUM_SPEED\(cq,
\(oqSPECTRUM_REF\(cq, \(oqSPECTRUM_AVG\(cq, \(oqSPECTRUM_ATT\(cq, \(oqTEMP_METER\(cq, \(oqBANDSELECT\(cq,
\(oqUSB_AF\(cq.
.IP
The Level Value can be a float or an integer value. For the AGC token the
@ -886,7 +970,7 @@ Seconds
VOXDELAY(ds), BKINDL(ms), BKIN_DLYMS(ms)
Raw info from rig
RAWSTR, BAND_SELECT (subject to change -- index right now but may convert to band name)
RAWSTR, BANDSELECT (subject to change -- index right now but may convert to band name)
SWR
SWR
@ -901,6 +985,8 @@ Lookup - if level shows 0/0/0 then it's probably a lookup value
SPECTRUM_MODE 0=None, 1=Center, 2=Fixed, 3=Center Scroll, 4=Fixed Scroll
SPECTRUM_AVG rig specific
METER -- SWR,COMP,ALC,IC/ID,DB,PO,VDD,TEMP or can use the numbers above in Lookup l METER returns the meter number=name
Watts
RFPOWER_METER_WATTS
@ -938,12 +1024,25 @@ and
.RI \(aq "Parm Value" \(aq.
.IP
Parm is a token: \(oqANN\(cq, \(oqAPO\(cq, \(oqBACKLIGHT\(cq, \(oqBEEP\(cq,
\(oqTIME\(cq, \(oqBAT\(cq, \(oqKEYLIGHT\(cq.
\(oqTIME\(cq, \(oqBAT\(cq, \(oqKEYLIGHT\(cq, \(oqSCREENSAVER\(cq, \(oqAFIF\(cq, \(oqBANDSELECT\(cq, \(oqKEYERTYPE\(cq.
.IP
.BR Note :
Passing a \(oq?\(cq (query) as the first argument instead of a Parm token will
return a space separated list of radio backend supported set parameter tokens.
Use this to determine the supported parameters of a given radio backend.
.IP
ANN -- "Announce" level, see ann_t
APO -- Auto power off, int in minute
BACKLIGHT -- LCD light, float [0.0 ... 1.0]
BEEP -- Beep on keypressed, int (0,1)
TIME -- hh:mm:ss, int in seconds from 00:00:00
BAT -- battery level, float [0.0 ... 1.0]
KEYLIGHT -- Button backlight, on/off
SCREENSAVER -- rig specific timeouts
AFIF -- 0=AF audio, 1=IF audio -- see IC-7300/9700/705
BANDSELECT -- band name, e.g. BAND160M, BAND80M.... a ? instead of band will show band possibilities
KEYERTYPE -- Icom keyer type 0,1,2 or STRAIGHT,BUG,PADDLE
.
.TP
.BR p ", " get_parm " \(aq" \fIParm\fP \(aq
@ -1069,7 +1168,7 @@ VFO reset, \(oq4\(cq = Memory Clear reset, \(oq8\(cq = Master reset.
.IP
Since these values are defined as a bitmask in
.IR include/hamlib/rig.h ,
it should be possible to AND these values together to do multiple resets at
it should be possible to OR these values together to do multiple resets at
once, if the backend supports it or supports a reset action via rig control at
all.
.
@ -1182,11 +1281,11 @@ option above, will terminate each command string sent to the radio. This
character should not be a part of the input string.
.
.TP
.BR W ", " send_cmd_rx " \(aq" \fICmd\fP\(aq " " \fI[nbytes or terminator char\FP
.BR W ", " send_cmd_rx " \(aq" \fICmd\fP\(aq " " \fInbytes_or_terminator_char\fP
Send a raw command string to the radio and expect nbytes returned or the terminator char (e.g. ;).
.IP
This is useful for testing and troubleshooting radio commands and responses when
developing a backend. If the # of bytes requested is <= the number actually returned no timeout will occur.
developing a backend. If the # of bytes requested is <= the number actually returned no timeout will occur. If a char is provided it will be used to terminate reading the string so ';' is popular for Kenwood/Yaesu commands for example.
.IP
The command argument can have no spaces in it.
For binary protocols enter values as \\0xAA\\0xBB. Expect a
@ -1289,7 +1388,7 @@ CW Skimmer is started and "set_lock_mode 0" when CW Skimmer is stopped.
Returns current lock mode status 1=On, 2=Off (only useful when using rigctld)
.
.TP
.BR send_raw " \(aq" \fITerminator\fP "\(aq \(aq" \fIString\fp \(aq
.BR send_raw " \(aq" \fITerminator\fP "\(aq \(aq" \fIString\fP \(aq
.EX
Can send ASCII string or 0xnn values -- there can be no spaces in the command string.
Possible terminator values are CR, LF, ;, ICOM, 0-100 (bytes to read), or -1 meaning unknown (will timeout on read)
@ -1299,6 +1398,44 @@ Examples:
send_raw -1 0xFE;0xFE;0x94;0x03;0xFD
send_raw 14 0xFE;0xFE;0x94;0x03;0xFD
.
.TP
.BR client_version " \(aq" \fIString\fP "\(aq
.EX
Client can send its version to rigctld and get feedback on compatibility, deprecation, and alternatives
.TP
.BR hamlib_version
.EX
Returns hamlib version with ISO8601 date/time
.
.TP
.BR test
.EX
Performs test routines. Under development.
.
.TP
.BR set_gpio " \(aq" \fIGPIO#\fP "\(aq
.EX
Sets GPIO1, GPIO2, GPIO3, GPIO4 on the GPIO ptt port
Can also use 1,2,3,4
.
.TP
.BR get_gpio " \(aq" \fIGPIO#\fP "\(aq
.EX
Reads GPIO1, GPIO2, GPIO3, GPIO4 on the GPIO ptt port
Can also use 1,2,3,4
.
.TP
.BR skip_init
.EX
Skips rig initialization -- useful when executing commands with rigctl to speed up things
.
.TP
.BR freq_skip " " 'skip'
.EX
When skip!=0 skips setting freq on TX_VFO when in RX and on RX_VFO when in TX -- for use with gpredict and rigs that do not have TARGETABLE_VFO
.
.SH READLINE
.
.SH READLINE
.
If

Wyświetl plik

@ -127,8 +127,7 @@ Use
.I device
as the file name of the port connected to the radio.
.IP
Often a serial port, but could be a USB to serial adapter. Typically
.IR /dev/ttyS0 ", " /dev/ttyS1 ", " /dev/ttyUSB0 ,
Typically /dev/ttyS0 ", " /dev/ttyS1 ", " /dev/ttyUSB0 ,
etc. on Linux,
.IR COM1 ", " COM2 ,
etc. on MS Windows. The BSD flavors and Mac OS/X have their own designations.
@ -293,8 +292,32 @@ above.
.
.TP
.BR \-C ", " \-\-set\-conf = \fIparm=val\fP [ \fI,parm=val\fP ]
Set radio configuration parameter(s), e.g.
.IR stop_bits=2 .
Set configuration parameter(s). Some common ones are:
.in +4
.EX
.RB async: "True enables asynchronous data transfer for backends that support it. This allows use of transceive and spectrum data."
.RB auto_power_on: "True enables compatible rigs to be powered up on open"
.RB auto_power_off: "True enables compatible rigs to be powered down on close"
.RB auto_disable_screensaver: "True enables compatible rigs to have their screen saver disabled on open"
.RB dcd_type: "Data Carrier Detect (or squelch) interface type override"
.RB dcd_pathname: "Path name to the device file of the Data Carrier Detect (or squelch)"
.RB disable_yaesu_bandselect: "True disables the automatic band select on band change for Yaesu rigs"
.RB dtr_state: "ON turns on DTR, OFF turns it off, Unset disables it"
.RB lo_freq: "Frequency to add to the VFO frequency for use with a transverter"
.RB post_write_delay: "Delay in ms between each command sent out"
.RB ptt_share: "True enables ptt port to be shared with other apps"
.RB ptt_type: "Push-To-Talk interface type override"
.RB ptt_pathname: "Path name to the device file of the Push-To-Talk"
.RB ptt_bitnum: "Push-To-Talk GPIO bit number"
.RB retry: "Max number of retry"
.RB rts_state: "ON turns on DTR, OFF turns it off, Unset disables it"
.RB twiddle_timeout: "For satellite ops when VFOB is twiddled will pause VFOB commands until timeout"
.RB twiddle_rit: "Suppress get_freq on VFOB for RIT tuning satellites"
.RB timeout: "Timeout in ms"
.RB write_delay: "Delay in ms between each byte sent out"
.RB tuner_control_pathname: "Path name to a script/program to control a tuner with 1 argument of 0/1 for Tuner Off/On"
.EE
.in
.IP
Use the
.B -L
@ -372,10 +395,14 @@ option as it generates no output on its own.
Sets password on rigctld which requires hamlib to use rig_set_password and rigctl to use \\password to access rigctld. A 32-char shared secret will be displayed to be used on the client side.
.
.TP
.BR \-R ", " \-\-rigctld_idle
.BR \-R ", " \-\-rigctld\-idle
Will make rigctld close the rig when no clients are connected. Normally remains connected to speed up connects.
.
.TP
.BR \-b ", " \-\-bind\-all
Will make rigctld try to bind to first network device available.
.
.TP
.BR \-h ", " \-\-help
Show a summary of these options and exit.
.
@ -414,12 +441,12 @@ Since most of the
.B Hamlib
operations have a
.BR set " and a " get
method, an upper case letter will be used for
method, a single upper case letter will be used for
.B set
methods whereas the corresponding lower case letter refers to the
methods whereas the corresponding single lower case letter refers to the
.B get
method. Each operation also has a long name; prepend a backslash, \(oq\\\(cq,
to send a long command name.
to send a long command name all in lower case.
.
.PP
Example (Perl): \(lqprint $socket "\\\\dump_caps\\n";\(rq to see what the
@ -701,7 +728,23 @@ number (\(oq0\(cq, \(oq1\(cq, \(oq2\(cq, ...).
.BR b ", " send_morse " \(aq" \fIMorse\fP \(aq
Send
.RI \(aq Morse \(aq
symbols.
symbols. For Yaesu rigs use memory# (1-5 for most rigs) or up to 50 char message (which will use memory#1)
.EX
Example from rigctld socket: b CQ CQ DE ME
Yaesu example to send message#1 frm rigctld socket: b 1
.
.TP
.BR 0xbb ", " stop_morse "
Stop sending the current morse code.
.
.TP
.BR 0xbc ", " wait_morse "
Wait for morse to finish -- only works on full break-in
.
.TP
.BR 0x94 ", " send_voice_mem " \(aq" \fIMsgnum\fP \(aq
Have rig transmit internal message
.RI \(aq Msgnum \(aq
.
.TP
.BR 0x8b ", " get_dcd
@ -846,9 +889,9 @@ evel is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOXDELAY\(cq, \(oqAF\(cq,
\(oqBAL\(cq, \(oqMETER\(cq, \(oqVOXGAIN\(cq, \(oqANTIVOX\(cq,
\(oqSLOPE_LOW\(cq, \(oqSLOPE_HIGH\(cq, \(oqBKIN_DLYMS\(cq, \(oqRAWSTR\(cq, \(oqSWR\(cq,
\(oqALC\(cq, \(oqSTRENGTH\(cq, \(oqRFPOWER_METER\(cq, \(oqCOMPMETER\(cq, \(oqVD_METER\(cq, \(oqID_METER\(cq,
\(oqNOTCHF_RAW\(cq, \(oqMONITOR_GAIN\(cq, \(oqNQ\(cq, \(oqRFPOWER_METER_WATTS\cq, \(oqSPECTRUM_MODE\(cq,
\(oqSPECTRUM_SPAN\(cq, \(oqSPECTRUM_EDGE_LOW\(cq, \(oqSPECTRUM_EDGE_HIGH\(cq, \(oqSPECTRUM_SPEED\cq,
\(oqSPECTRUM_REF\(cq, (oqSPECTRUM_AVG\(cq, \(oqSPECTRUM_ATT\cq, \(oqTEMP_METER\cq, \(oqBAND_SELECT\(cq,
\(oqNOTCHF_RAW\(cq, \(oqMONITOR_GAIN\(cq, \(oqNQ\(cq, \(oqRFPOWER_METER_WATTS\(cq, \(oqSPECTRUM_MODE\(cq,
\(oqSPECTRUM_SPAN\(cq, \(oqSPECTRUM_EDGE_LOW\(cq, \(oqSPECTRUM_EDGE_HIGH\(cq, \(oqSPECTRUM_SPEED\(cq,
\(oqSPECTRUM_REF\(cq, \(oqSPECTRUM_AVG\(cq, \(oqSPECTRUM_ATT\(cq, \(oqTEMP_METER\(cq, \(oqBAND_SELECT\(cq,
\(oqUSB_AF\(cq.
.IP
The Level Value can be a float or an integer value. For the AGC token the
@ -883,7 +926,7 @@ and
.RI \(aq "Parm Value" \(aq.
.IP
Parm is a token: \(oqANN\(cq, \(oqAPO\(cq, \(oqBACKLIGHT\(cq, \(oqBEEP\(cq,
\(oqTIME\(cq, \(oqBAT\(cq, \(oqKEYLIGHT\(cq.
\(oqTIME\(cq, \(oqBAT\(cq, \(oqKEYLIGHT\(cq, \(oqBANDSELECT\(cq, \(oqKEYERTYPE\(cq.
.IP
.BR Note :
Passing a \(oq?\(cq (query) as the first argument instead of a Parm token will
@ -1009,7 +1052,7 @@ VFO reset, \(oq4\(cq = Memory Clear reset, \(oq8\(cq = Master reset.
.IP
Since these values are defined as a bitmask in
.IR include/hamlib/rig.h ,
it should be possible to AND these values together to do multiple resets at
it should be possible to OR these values together to do multiple resets at
once, if the backend supports it or supports a reset action via rig control at
all.
.
@ -1163,6 +1206,47 @@ CW Skimmer is started and "set_lock_mode 0" when CW Skimmer is stopped.
.BR get_lock_mode
Returns current lock mode status 1=On, 2=Off (only useful with rigctld)
.
.TP
.BR send_raw " \(aq" \fITerminator\fP "\(aq \(aq" \fIString\fP \(aq
.EX
Can send ASCII string or 0xnn values -- there can be no spaces in the command string.
Possible terminator values are CR, LF, ;, ICOM, 0-100 (bytes to read), or -1 meaning unknown (will timeout on read)
Examples:
send_raw ; FA;MD;
send_raw icom 0xFE;0xFE;0x94;0x03;0xFD
send_raw -1 0xFE;0xFE;0x94;0x03;0xFD
send_raw 14 0xFE;0xFE;0x94;0x03;0xFD
.
.TP
.BR client_version " \(aq" \fIString\fP "\(aq
.EX
Client can send its version to rigctld and get feedback on compatibility, deprecation, and alternatives
.TP
.BR hamlib_version
.EX
Returns hamlib version with ISO8601 date/time
.
.TP
.BR hamlib_version
.EX
Returns hamlib version with ISO8601 date/time
.
.TP
.BR test
.EX
Performs test routines. Under development.
.
.TP
.BR set_gpio " \(aq" \fIGPIO#\fP "\(aq
.EX
Sets GPIO1, GPIO2, GPIO3, GPIO4 on the GPIO ptt port
Can also use 1,2,3,4
.
.TP
.BR get_gpio " \(aq" \fIGPIO#\fP "\(aq
.EX
Reads GPIO1, GPIO2, GPIO3, GPIO4 on the GPIO ptt port
Can also use 1,2,3,4
.
.SH PROTOCOL
.

Wyświetl plik

@ -0,0 +1,329 @@
.\" Hey, EMACS: -*- nroff -*-
.\"
.\" For layout and available macros, see man(7), man-pages(7), groff_man(7)
.\" Please adjust the date whenever revising the manpage.
.\"
.\" Note: Please keep this page in sync with the source, rigctlsync.c
.\"
.TH RIGCTLSYNC "1" "2023-01-27" "Hamlib" "Hamlib Utilities"
.
.
.SH NAME
.
rigctlsync \- synchronize a rig to SDR# (or other rig)
.
.SH SYNOPSIS
.
.
.SY rigctlsync
.OP \-hlLuV
.OP \-m id
.OP \-r device
.OP \-R device
.OP \-s baud
.OP \-S baud
.OP \-c id
.OP \-C parm=val
.OP \-B
.RB [ \-v [ \-Z ]]
.YS
.
.SH DESCRIPTION
Allows you to synchornize frequence from a rig to SDR#.
Best when used with rigctld, FlRig, or a multiport radio.
.
.PP
Please report bugs and provide feedback at the e-mail address given in the
.B BUGS
section below. Patches and code enhancements sent to the same address are
welcome.
.
.
.SH OPTIONS
.
This program follows the usual GNU command line syntax. Short options that
take an argument may have the value follow immediately or be separated by a
space. Long options starting with two dashes (\(oq\-\(cq) require an
\(oq=\(cq between the option and any argument.
.
.PP
Here is a summary of the supported options:
.
.TP
.BR \-m ", " \-\-model = \fIid\fP
Select radio model number.
.IP
See model list (use \(lqrigctlsync -l\(rq).
.IP
.BR Note :
.B rigctlsync
(or third party software using the C API) will use radio model 2 for
.B NET rigctl
(communicating with
.BR rigctld ).
.
.TP
.BR \-r ", " \-\-rig\-file = \fIdevice\fP
Use
.I device
as the file name of the port connected to the radio.
.IP
Often a serial port, but could be a USB to serial adapter. Typically
.IR /dev/ttyS0 ", " /dev/ttyS1 ", " /dev/ttyUSB0 ,
etc. on Linux,
.IR COM1 ", " COM2 ,
etc. on MS Windows. The BSD flavors and Mac OS/X have their own designations.
See your system's documentation.
.IP
The special string \(lquh\-rig\(rq may be given to enable micro-ham device
support.
.
.TP
.BR \-R ", " \-\-rig\-file2 = \fIdevice\fP
Use
.I device
as the file name of one of the virtual com ports -- your program will connect
to the other com port of the virtual pair.
.
.TP
.BR \-s ", " \-\-serial\-speed = \fIbaud\fP
Set serial speed to
.I baud
rate.
.IP
Uses maximum serial speed from radio backend capabilities (set by
.B -m
above) as the default.
.
.TP
.BR \-S ", " \-\-serial\-speed2 = \fIbaud\fP
Set serial speed to
.I baud
rate for virtual com port (see
.BR -R ).
.
.IP
Uses maximum serial speed from radio backend capabilities (set by
.B -m
above) as the default.
.
.TP
.BR \-c ", " \-\-civaddr = \fIid\fP
Use
.I id
as the CI-V address to communicate with the rig.
.IP
Only useful for Icom and some Ten-Tec rigs.
.IP
.BR Note :
The
.I id
is in decimal notation, unless prefixed by
.IR 0x ,
in which case it is hexadecimal.
.
.TP
.BR \-L ", " \-\-show\-conf
List all config parameters for the radio defined with
.B \-m
above.
.
.TP
.BR \-C ", " \-\-set\-conf = \fIparm=val\fP [ \fI,parm=val\fP ]
Set radio configuration parameter(s), e.g.
.IR stop_bits=2 .
.IP
Use the
.B -L
option above for a list of configuration parameters for a given model number.
.
.TP
.BR \-u ", " \-\-dump\-caps
Dump capabilities for the radio defined with
.B -m
above and exit.
.
.TP
.BR \-l ", " \-\-list
List all model numbers defined in
.B Hamlib
and exit.
.IP
The list is sorted by model number.
.IP
.BR Note :
In Linux the list can be scrolled back using
.BR Shift-PageUp / Shift-PageDown ,
or using the scrollbars of a virtual terminal in X or the cmd window in
Windows. The output can be piped to
.BR more (1)
or
.BR less (1),
e.g. \(lqrigctl -l | more\(rq.
.
.TP
.BR \-n ", " \-\-no\-restore\-ai
.B rigctl
restores the state of auto information (AI) on the controlled rig.
.IP
If this is not desired, for example if you are using
.B rigctl
to turn AI mode on or off, pass this option.
.
.TP
.BR \-B ", " \-\-mapa2b
Maps set_freq on VFOA to VFOB instead.
This allows using CW skimmer with the rig in split mode and clicking on a frequency in CW skimmer
will set VFOB to the transmit frequency.
.
.TP
.BR \-v ", " \-\-verbose
Set verbose mode, cumulative (see
.B DIAGNOSTICS
below).
.
.TP
.BR \-Z ", " \-\-debug\-time\-stamps
Enable time stamps for the debug messages.
.IP
Use only in combination with the
.B -v
option as it generates no output on its own.
.
.TP
.BR \-h ", " \-\-help
Show a summary of these options and exit.
.
.TP
.BR \-V ", " \-\-version
Show version of
.B rigctl
and exit.
.
.PP
.BR Note :
Some options may not be implemented by a given backend and will return an
error. This is most likely to occur with the
.B \-\-set\-conf
and
.B \-\-show\-conf
options.
.
.
.SH DIAGNOSTICS
.
The
.BR \-v ,
.B \-\-verbose
option allows different levels of diagnostics
to be output to
.B stderr
and correspond to \-v for
.BR BUG ,
\-vv for
.BR ERR ,
\-vvv for
.BR WARN ,
\-vvvv for
.BR VERBOSE ,
or \-vvvvv for
.BR TRACE .
.
.PP
A given verbose level is useful for providing needed debugging information to
the email address below. For example, TRACE output shows all of the values
sent to and received from the radio which is very useful for radio backend
library development and may be requested by the developers.
.
.
.SH EXIT STATUS
.B rigctlsync
exits with:
.
.TP
.B 0
if all operations completed normally;
.
.TP
.B 1
if there was an invalid command line option or argument;
.
.TP
.B 2
if an error was returned by
.BR Hamlib .
.
.
.SH EXAMPLE
.
Start
.B rigctlsync
with FLRig as the Hamlib model
.UE .
.
.PP
.in +4n
.EX
.RB $ " rigctlsync -m 4 -M 9 -R 192.168.1.1:4532"
.EE
.in
.
.PP
The following diagram shows the communications flow that allows N1MM Logger+
to communicate with a radio connected to Flrig:
.
.PP
.in +4n
.EE
.in
.
.
.SH BUGS
.
.PP
Report bugs to:
.IP
.nf
.MT hamlib\-developer@lists.sourceforge.net
Hamlib Developer mailing list
.ME
.fi
.
.
.SH COPYING
.
This file is part of Hamlib, a project to develop a library that simplifies
radio, rotator, and amplifier control functions for developers of software
primarily of interest to radio amateurs and those interested in radio
communications.
.
.PP
Copyright \(co 2000-2011 Stephane Fillod
.br
Copyright \(co 2000-2018 the Hamlib Group (various contributors)
.br
Copyright \(co 2010-2020 Nate Bargmann
.br
Copyright \(co 2019 Michael Black W9MDB
.
.PP
This is free software; see the file COPYING for copying conditions. There is
NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
.
.
.SH SEE ALSO
.
.BR rigctld (1),
.BR rigctl (1),
.BR socat (1),
.BR hamlib (7)
.
.
.SH COLOPHON
.
Links to the Hamlib Wiki, Git repository, release archives, and daily snapshot
archives are available via
.
.UR http://www.hamlib.org
hamlib.org
.UE .

Wyświetl plik

@ -23,6 +23,8 @@ rotctl \- control antenna rotators
.OP \-s baud
.OP \-t char
.OP \-C parm=val
.OP \-o azoffset
.OP \-O eloffset
.RB [ \-v [ \-Z ]]
.RB [ command | \- ]
.YS
@ -131,6 +133,15 @@ The semicolon (\(oq;\(cq) is a common terminator for rotators that accept
ASCII character strings.
.
.TP
.BR \-o ", " \-\-set\-azoffset
Azimuth correction floating point -- during set value is added, during get value is subtracted.
.
.TP
.BR \-O ", " \-\-set\-eloffset
Elevation correction floating point -- during set value is added, during get value is subtracted.
.
.
.TP
.BR \-L ", " \-\-show\-conf
List all configuration parameters for the rotator defined with
.B \-m

Wyświetl plik

@ -132,7 +132,7 @@ int gr_init(RIG *rig)
rig->state.priv = (void*)priv;
rig_debug(RIG_DEBUG_VERBOSE,"%s called\n", __FUNCTION__ );
rig->state.rigport.type.rig = RIG_PORT_NONE;
RIGORT(rig)->type.rig = RIG_PORT_NONE;
memset(priv->parms, 0, RIG_SETTING_MAX*sizeof(value_t));
@ -160,7 +160,7 @@ int gr_init(RIG *rig)
/*
* Assumes rig!=NULL, rig->state.priv!=NULL
*/
int gnuradio_set_conf(RIG *rig, token_t token, const char *val)
int gnuradio_set_conf(RIG *rig, hamlib_token_t token, const char *val)
{
struct gnuradio_priv_data *priv;
struct rig_state *rs;
@ -184,7 +184,7 @@ int gnuradio_set_conf(RIG *rig, token_t token, const char *val)
* Assumes rig!=NULL, rig->state.priv!=NULL
* and val points to a buffer big enough to hold the conf value.
*/
int gnuradio_get_conf(RIG *rig, token_t token, char *val)
int gnuradio_get_conf(RIG *rig, hamlib_token_t token, char *val)
{
struct gnuradio_priv_data *priv;
struct rig_state *rs;
@ -870,7 +870,6 @@ int gnuradio_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op)
return ret;
}
// cppcheck-suppress *
DECLARE_INITRIG_BACKEND(gnuradio)
{
rig_debug(RIG_DEBUG_VERBOSE, "gnuradio: _init called\n");

Wyświetl plik

@ -44,8 +44,8 @@ int gr_get_vfo(RIG *rig, vfo_t *vfo);
int gr_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width);
int gr_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width);
int gnuradio_set_conf(RIG *rig, token_t token, const char *val);
int gnuradio_get_conf(RIG *rig, token_t token, char *val);
int gnuradio_set_conf(RIG *rig, hamlib_token_t token, const char *val);
int gnuradio_get_conf(RIG *rig, hamlib_token_t token, char *val);
int gnuradio_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val);
int gnuradio_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val);
@ -61,10 +61,10 @@ int graudioiq_open(RIG *rig);
extern const struct confparams gnuradio_cfg_params[];
extern const struct rig_caps gr_caps;
extern const struct rig_caps mc4020_caps;
extern const struct rig_caps graudio_caps;
extern const struct rig_caps graudioiq_caps;
extern struct rig_caps gr_caps;
extern struct rig_caps mc4020_caps;
extern struct rig_caps graudio_caps;
extern struct rig_caps graudioiq_caps;
__END_DECLS

Wyświetl plik

@ -19,7 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
@ -50,7 +49,7 @@ static const struct gnuradio_priv_caps gr_priv_caps =
.IF_center_freq = MHz(5.75),
};
const struct rig_caps gr_caps =
struct rig_caps gr_caps =
{
.rig_model = RIG_MODEL_GNURADIO,
.model_name = "GNU Radio dev",

Wyświetl plik

@ -19,7 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
@ -53,7 +52,7 @@ static const struct gnuradio_priv_caps graudio_priv_caps =
};
const struct rig_caps graudio_caps =
struct rig_caps graudio_caps =
{
.rig_model = RIG_MODEL_GRAUDIO,
.model_name = "GNU Radio GrAudio",
@ -127,7 +126,7 @@ const struct rig_caps graudio_caps =
.vfo_op = gnuradio_vfo_op,
};
const struct rig_caps graudioiq_caps =
struct rig_caps graudioiq_caps =
{
.rig_model = RIG_MODEL_GRAUDIOIQ,
.model_name = "GNU Radio GrAudio I&Q",

Wyświetl plik

@ -19,7 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
@ -50,7 +49,7 @@ static const struct gnuradio_priv_caps mc4020_priv_caps =
};
const struct rig_caps mc4020_caps =
struct rig_caps mc4020_caps =
{
.rig_model = RIG_MODEL_MC4020,
.model_name = "GNU Radio MC4020",

Wyświetl plik

@ -52,6 +52,7 @@ int main(int argc, char *argv[])
}
// turn this into a macro
// cppcheck-suppress cstyleCast
priv = (struct gnuradio_priv_data*)my_rig->state.priv;
if (priv == NULL) {
printf("Internal error, can't retrieve priv data!\n");

Wyświetl plik

@ -16,13 +16,13 @@ hamlib_rotapi.pas
HamlibComponents.pas
This file contain two components that encapsulate the rig and rotator
frontends. It is very simular to the C++ class.
frontends. It is very similar to the C++ class.
A simple test program is included in the tests/ directory. It implements
a selection dialog and a very simple Radio Control dialog.
This binding was develop with Borland Kylix Open Edition Ver 2.0. Open Edition
This binding was developed with Borland Kylix Open Edition Ver 2.0. Open Edition
is freely downloadable from Borland's website for use with GPL projects.
http://www.borland.com/kylix/

Wyświetl plik

@ -327,7 +327,7 @@ const
//#define RIG_IS_TOKEN_FRONTEND(t) ((t)&(1<<30))
{*
* strongly inspired from soundmedem. Thanks Thomas!
* strongly inspired from soundmodem. Thanks Thomas!
*}
RIG_CONF_STRING = 0;
RIG_CONF_COMBO = 1;
@ -472,7 +472,7 @@ type
const
{*
* tranceive mode, ie. the rig notify the host of any event,
* transceive mode, ie. the rig notify the host of any event,
* like freq changed, mode changed, etc.
*}
RIG_TRN_OFF = 0;

Wyświetl plik

@ -3,4 +3,4 @@ noinst_HEADERS = bandplan.h num_stdio.h
nobase_include_HEADERS = hamlib/rig.h hamlib/riglist.h hamlib/rig_dll.h \
hamlib/rotator.h hamlib/rotlist.h hamlib/rigclass.h \
hamlib/rotclass.h hamlib/amplifier.h hamlib/amplist.h \
hamlib/ampclass.h hamlib/config.h
hamlib/ampclass.h hamlib/multicast.h

Wyświetl plik

@ -53,11 +53,11 @@ public:
// This method closes the communication port to the amp
void close(void);
void setConf(token_t token, const char *val);
void setConf(hamlib_token_t token, const char *val);
void setConf(const char *name, const char *val);
void getConf(token_t token, char *val);
void getConf(hamlib_token_t token, char *val);
void getConf(const char *name, char *val);
token_t tokenLookup(const char *name);
hamlib_token_t tokenLookup(const char *name);
void setFreq(freq_t freq);
freq_t getFreq();

Wyświetl plik

@ -18,6 +18,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
/* SPDX-License-Identifier: LGPL-2.1-or-later */
#ifndef _AMPLIFIER_H
#define _AMPLIFIER_H 1
@ -232,9 +233,9 @@ struct amp_caps
int (*set_freq)(AMP *amp, freq_t val); /*!< Pointer to backend implementation of ::amp_set_freq(). */
int (*get_freq)(AMP *amp, freq_t *val); /*!< Pointer to backend implementation of ::amp_get_freq(). */
int (*set_conf)(AMP *amp, token_t token, const char *val); /*!< Pointer to backend implementation of ::amp_set_conf(). */
int (*get_conf2)(AMP *amp, token_t token, char *val, int val_len); /*!< Pointer to backend implementation of ::amp_get_conf(). */
int (*get_conf)(AMP *amp, token_t token, char *val); /*!< Pointer to backend implementation of ::amp_get_conf(). */
int (*set_conf)(AMP *amp, hamlib_token_t token, const char *val); /*!< Pointer to backend implementation of ::amp_set_conf(). */
int (*get_conf2)(AMP *amp, hamlib_token_t token, char *val, int val_len); /*!< Pointer to backend implementation of ::amp_get_conf(). */
int (*get_conf)(AMP *amp, hamlib_token_t token, char *val); /*!< Pointer to backend implementation of ::amp_get_conf(). */
/*
* General API commands, from most primitive to least.. :()
@ -244,8 +245,8 @@ struct amp_caps
int (*reset)(AMP *amp, amp_reset_t reset); /*!< Pointer to backend implementation of ::amp_reset(). */
int (*get_level)(AMP *amp, setting_t level, value_t *val); /*!< Pointer to backend implementation of ::amp_get_level(). */
int (*set_level)(AMP *amp, setting_t level, value_t val); /*!< Pointer to backend implementation of ::amp_get_level(). */
int (*get_ext_level)(AMP *amp, token_t level, value_t *val); /*!< Pointer to backend implementation of ::amp_get_ext_level(). */
int (*set_ext_level)(AMP *amp, token_t level, value_t val); /*!< Pointer to backend implementation of ::amp_set_ext_level(). */
int (*get_ext_level)(AMP *amp, hamlib_token_t level, value_t *val); /*!< Pointer to backend implementation of ::amp_get_ext_level(). */
int (*set_ext_level)(AMP *amp, hamlib_token_t level, value_t val); /*!< Pointer to backend implementation of ::amp_set_ext_level(). */
int (*set_powerstat)(AMP *amp, powerstat_t status); /*!< Pointer to backend implementation of ::amp_set_powerstat(). */
int (*get_powerstat)(AMP *amp, powerstat_t *status); /*!< Pointer to backend implementation of ::amp_get_powerstat(). */
@ -335,11 +336,11 @@ amp_cleanup HAMLIB_PARAMS((AMP *amp));
extern HAMLIB_EXPORT(int)
amp_set_conf HAMLIB_PARAMS((AMP *amp,
token_t token,
hamlib_token_t token,
const char *val));
extern HAMLIB_EXPORT(int)
amp_get_conf HAMLIB_PARAMS((AMP *amp,
token_t token,
hamlib_token_t token,
char *val));
extern HAMLIB_EXPORT(int)
amp_set_powerstat HAMLIB_PARAMS((AMP *amp,
@ -407,7 +408,7 @@ extern HAMLIB_EXPORT(const struct confparams *)
amp_confparam_lookup HAMLIB_PARAMS((AMP *amp,
const char *name));
extern HAMLIB_EXPORT(token_t)
extern HAMLIB_EXPORT(hamlib_token_t)
amp_token_lookup HAMLIB_PARAMS((AMP *amp,
const char *name));
@ -428,12 +429,12 @@ amp_ext_lookup HAMLIB_PARAMS((AMP *amp,
extern HAMLIB_EXPORT(int)
amp_get_ext_level HAMLIB_PARAMS((AMP *amp,
token_t token,
hamlib_token_t token,
value_t *val));
extern HAMLIB_EXPORT(int)
amp_set_ext_level HAMLIB_PARAMS((AMP *amp,
token_t token,
hamlib_token_t token,
value_t val));
extern HAMLIB_EXPORT(const char *) amp_strlevel(setting_t);
@ -445,6 +446,8 @@ rig_ext_lookup HAMLIB_PARAMS((RIG *rig,
extern HAMLIB_EXPORT(setting_t) amp_parse_level(const char *s);
extern HAMLIB_EXPORT(const char *) amp_strlevel(setting_t);
extern HAMLIB_EXPORT(void *) amp_data_pointer(AMP *amp, rig_ptrx_t idx);
//! @endcond

Wyświetl plik

@ -106,10 +106,15 @@
//! @endcond
#define AMP_MODEL_ELECRAFT_KPA1500 AMP_MAKE_MODEL(AMP_ELECRAFT, 1)
//#define AMP_MODEL_ELECRAFT_KPA500 AMP_MAKE_MODEL(AMP_ELECRAFT, 2)
#define AMP_GEMINI 3
#define AMP_BACKEND_GEMINI "gemini"
#define AMP_MODEL_GEMINI_DX1200 AMP_MAKE_MODEL(AMP_GEMINI, 1)
#define AMP_EXPERT 4
#define AMP_BACKEND_EXPERT "expert"
#define AMP_MODEL_EXPERT_FA AMP_MAKE_MODEL(AMP_EXPERT, 1)
/**
* \brief Convenience type definition for an amplifier model.

Wyświetl plik

@ -0,0 +1,45 @@
//include <stdio.h>
//#include <stdlib.h>
//#include <string.h>
//#include <errno.h>
//#include <unistd.h>
#include <hamlib/rig.h>
//#include <sys/socket.h>
#ifdef HAVE_NETINET_IN_H
#include <netinet/in.h>
#endif
#ifdef _WIN32
#include <winsock2.h>
#include <ws2tcpip.h>
#endif
#ifdef HAVE_ARPA_INET_H
#include <arpa/inet.h>
#endif
#ifndef MULTICAST_H
#define MULTICAST_H
struct multicast_vfo
{
char *name;
double freq;
char *mode;
int width;
int widthLower;
int widthUpper;
unsigned char rx; // true if in rx mode
unsigned char tx; // true in in tx mode
};
struct multicast_broadcast
{
char *ID;
struct multicast_vfo **vfo;
};
// returns # of bytes sent
extern HAMLIB_EXPORT (int) multicast_init(RIG *rig, char *addr, int port);
extern HAMLIB_EXPORT (int) multicast_send(RIG *rig, const char *msg, int msglen);
extern HAMLIB_EXPORT (int) multicast_stop(RIG *rig);
#endif //MULTICAST_H

Plik diff jest za duży Load Diff

Wyświetl plik

@ -46,7 +46,7 @@ public:
#endif
const struct rig_caps *caps;
struct rig_caps *caps;
// This method opens the communication port to the rig
void open(void);
@ -54,11 +54,11 @@ public:
// This method closes the communication port to the rig
void close(void);
void setConf(token_t token, const char *val);
void setConf(hamlib_token_t token, const char *val);
void setConf(const char *name, const char *val);
void getConf(token_t token, char *val);
void getConf(hamlib_token_t token, char *val);
void getConf(const char *name, char *val);
token_t tokenLookup(const char *name);
hamlib_token_t tokenLookup(const char *name);
void setFreq(freq_t freq, vfo_t vfo = RIG_VFO_CURR);
freq_t getFreq(vfo_t vfo = RIG_VFO_CURR);
@ -177,22 +177,27 @@ public:
void reset(reset_t reset);
// callbacks available in your derived object
// cppcheck-suppress unusedFunction
virtual int FreqEvent(vfo_t, freq_t, rig_ptr_t) const
{
return RIG_OK;
}
// cppcheck-suppress unusedFunction
virtual int ModeEvent(vfo_t, rmode_t, pbwidth_t, rig_ptr_t) const
{
return RIG_OK;
}
// cppcheck-suppress unusedFunction
virtual int VFOEvent(vfo_t, rig_ptr_t) const
{
return RIG_OK;
}
// cppcheck-suppress unusedFunction
virtual int PTTEvent(vfo_t, ptt_t, rig_ptr_t) const
{
return RIG_OK;
}
// cppcheck-suppress unusedFunction
virtual int DCDEvent(vfo_t, dcd_t, rig_ptr_t) const
{
return RIG_OK;
@ -287,6 +292,7 @@ public:
//! @endcond
// cppcheck-suppress unusedFunction
inline void THROW(const RigException *e)
{
#if defined(__GNUG__)
@ -298,6 +304,7 @@ inline void THROW(const RigException *e)
#elif defined(_MSC_VER)
throw* e;
#elif defined(__SUNPRO_CC)
// cppcheck-suppress cstyleCast
genericerror(1, ((e != 0) ? (char *)(e->message) : ""));
#else

Wyświetl plik

@ -33,6 +33,8 @@
#define RIG_MAKE_MODEL(a,b) ((a)*MAX_MODELS_PER_BACKEND+(b))
#define RIG_BACKEND_NUM(a) ((a)/MAX_MODELS_PER_BACKEND)
//! @endcond
/*! \file riglist.h
* \brief Hamlib rig(radio) model definitions.
*
@ -49,6 +51,13 @@
* whishes to use. It is done with the rig_init() API call.
*/
/**
* \def RIG_MODEL_NONE
* \brief A macro that returns the model number for an unknown model.
*
* The none backend, as the name suggests, does nothing. It is mainly for
* internal use.
*/
#define RIG_MODEL_NONE 0
/*! \def RIG_MODEL_DUMMY
@ -62,16 +71,21 @@
* It has also been expanded to provide support to "virtual" type of rigs
* such as the network rig control backend and W1HKJ's Flrig application.
*/
//! @cond Doxygen_Suppress
#define RIG_DUMMY 0
#define RIG_BACKEND_DUMMY "dummy"
//! @endcond
#define RIG_MODEL_DUMMY RIG_MAKE_MODEL(RIG_DUMMY, 1)
//! @cond Doxygen_Suppress
#define RIG_MODEL_NETRIGCTL RIG_MAKE_MODEL(RIG_DUMMY, 2)
#define RIG_MODEL_ARMSTRONG RIG_MAKE_MODEL(RIG_DUMMY, 3)
#define RIG_MODEL_FLRIG RIG_MAKE_MODEL(RIG_DUMMY, 4)
#define RIG_MODEL_TRXMANAGER_RIG RIG_MAKE_MODEL(RIG_DUMMY, 5)
#define RIG_MODEL_DUMMY_NOVFO RIG_MAKE_MODEL(RIG_DUMMY, 6)
#define RIG_MODEL_TCI1X RIG_MAKE_MODEL(RIG_DUMMY, 7)
#define RIG_MODEL_ACLOG RIG_MAKE_MODEL(RIG_DUMMY, 8)
#define RIG_MODEL_SDRSHARP RIG_MAKE_MODEL(RIG_DUMMY, 9)
#define RIG_MODEL_QUISK RIG_MAKE_MODEL(RIG_DUMMY, 10)
/*
* Yaesu
@ -127,7 +141,8 @@
#define RIG_MODEL_FT650 RIG_MAKE_MODEL(RIG_YAESU, 47)
#define RIG_MODEL_FT990UNI RIG_MAKE_MODEL(RIG_YAESU, 48)
#define RIG_MODEL_FT710 RIG_MAKE_MODEL(RIG_YAESU, 49)
#define RIG_MODEL_FT9000OLD RIG_MAKE_MODEL(RIG_YAESU, 50)
#define RIG_MODEL_Q900 RIG_MAKE_MODEL(RIG_YAESU, 51)
/*
* Kenwood
@ -185,6 +200,11 @@
#define RIG_MODEL_MALACHITE RIG_MAKE_MODEL(RIG_KENWOOD, 49)
#define RIG_MODEL_LAB599_TX500 RIG_MAKE_MODEL(RIG_KENWOOD,50)
#define RIG_MODEL_SDRUNO RIG_MAKE_MODEL(RIG_KENWOOD,51)
#define RIG_MODEL_QRPLABS RIG_MAKE_MODEL(RIG_KENWOOD,52)
#define RIG_MODEL_FX4 RIG_MAKE_MODEL(RIG_KENWOOD,53)
#define RIG_MODEL_THETIS RIG_MAKE_MODEL(RIG_KENWOOD, 54)
#define RIG_MODEL_TRUSDX RIG_MAKE_MODEL(RIG_KENWOOD, 55)
#define RIG_MODEL_SDRCONSOLE RIG_MAKE_MODEL(RIG_KENWOOD, 56)
/*
* Icom
@ -272,7 +292,7 @@
#define RIG_MODEL_X6100 RIG_MAKE_MODEL(RIG_ICOM, 87) /* Xiegu X6100 */
#define RIG_MODEL_G90 RIG_MAKE_MODEL(RIG_ICOM, 88) /* Xiegu G90 */
#define RIG_MODEL_X5105 RIG_MAKE_MODEL(RIG_ICOM, 89) /* Xiegu X5105 -- G90 compatible */
#define RIG_MODEL_IC905 RIG_MAKE_MODEL(RIG_ICOM, 90)
/*
* Optoelectronics (CI-V)
@ -282,7 +302,6 @@
#define RIG_MODEL_OS535 RIG_MAKE_MODEL(RIG_ICOM, 52)
#define RIG_MODEL_OS456 RIG_MAKE_MODEL(RIG_ICOM, 53)
/*
* TenTec (CI-V)
*/
@ -291,7 +310,6 @@
#define RIG_MODEL_PARAGON2 RIG_MAKE_MODEL(RIG_ICOM, 59)
#define RIG_MODEL_DELTAII RIG_MAKE_MODEL(RIG_ICOM, 64)
/*
* Icom PCR
*/
@ -302,7 +320,6 @@
#define RIG_MODEL_PCR1500 RIG_MAKE_MODEL(RIG_PCR, 3)
#define RIG_MODEL_PCR2500 RIG_MAKE_MODEL(RIG_PCR, 4)
/*
* AOR
*/
@ -325,7 +342,6 @@
#define RIG_MODEL_AR7030P RIG_MAKE_MODEL(RIG_AOR, 15)
#define RIG_MODEL_SR2200 RIG_MAKE_MODEL(RIG_AOR, 16)
/*
* JRC
*/
@ -339,7 +355,6 @@
#define RIG_MODEL_NRD535 RIG_MAKE_MODEL(RIG_JRC, 6)
#define RIG_MODEL_NRD545 RIG_MAKE_MODEL(RIG_JRC, 7)
/*
* Radio Shack
* Actually, they might be either Icom or Uniden. TBC --SF
@ -353,7 +368,6 @@
#define RIG_MODEL_RS2042 RIG_MAKE_MODEL(RIG_RADIOSHACK, 5) /* w/ OptoElectronics OS435 Board */
#define RIG_MODEL_RS2041 RIG_MAKE_MODEL(RIG_RADIOSHACK, 6) /* PRO-2041 */
/*
* Uniden
*/
@ -372,7 +386,6 @@
#define RIG_MODEL_BCD996T RIG_MAKE_MODEL(RIG_UNIDEN, 11)
#define RIG_MODEL_BC898 RIG_MAKE_MODEL(RIG_UNIDEN, 12)
/*
* Drake
*/
@ -382,7 +395,6 @@
#define RIG_MODEL_DKR8A RIG_MAKE_MODEL(RIG_DRAKE, 2)
#define RIG_MODEL_DKR8B RIG_MAKE_MODEL(RIG_DRAKE, 3)
/*
* Lowe
*/
@ -393,7 +405,6 @@
#define RIG_MODEL_HF250 RIG_MAKE_MODEL(RIG_LOWE, 3)
#define RIG_MODEL_HF235 RIG_MAKE_MODEL(RIG_LOWE, 4)
/*
* Racal
*/
@ -405,7 +416,6 @@
#define RIG_MODEL_RA3710 RIG_MAKE_MODEL(RIG_RACAL, 4)
#define RIG_MODEL_RA3702 RIG_MAKE_MODEL(RIG_RACAL, 5)
/*
* Watkins-Johnson
*/
@ -416,7 +426,6 @@
#define RIG_MODEL_WJ8711 RIG_MAKE_MODEL(RIG_WJ, 3)
#define RIG_MODEL_WJ8888 RIG_MAKE_MODEL(RIG_WJ, 4)
/*
* Rohde & Schwarz--ek
*/
@ -428,7 +437,6 @@
#define RIG_MODEL_EK895 RIG_MAKE_MODEL(RIG_EK, 4)
#define RIG_MODEL_EK070 RIG_MAKE_MODEL(RIG_EK, 5)
/*
* Skanti
*/
@ -439,7 +447,6 @@
#define RIG_MODEL_TRP9000 RIG_MAKE_MODEL(RIG_SKANTI, 3)
#define RIG_MODEL_TRP8255 RIG_MAKE_MODEL(RIG_SKANTI, 4)
/*
* WiNRADiO/LinRADiO
*/
@ -457,7 +464,6 @@
#define RIG_MODEL_G305 RIG_MAKE_MODEL(RIG_WINRADIO, 10)
#define RIG_MODEL_G315 RIG_MAKE_MODEL(RIG_WINRADIO, 11)
/*
* Ten Tec
*/
@ -476,7 +482,6 @@
#define RIG_MODEL_RX331 RIG_MAKE_MODEL(RIG_TENTEC, 12)
#define RIG_MODEL_TT599 RIG_MAKE_MODEL(RIG_TENTEC, 13) /* Eagle */
/*
* Alinco
*/
@ -485,7 +490,6 @@
#define RIG_MODEL_DX77 RIG_MAKE_MODEL(RIG_ALINCO, 1)
#define RIG_MODEL_DXSR8 RIG_MAKE_MODEL(RIG_ALINCO, 2)
/*
* Kachina
*/
@ -493,7 +497,6 @@
#define RIG_BACKEND_KACHINA "kachina"
#define RIG_MODEL_505DSP RIG_MAKE_MODEL(RIG_KACHINA, 1)
/*
* Gnuradio backend
*/
@ -505,7 +508,6 @@
#define RIG_MODEL_GRAUDIOIQ RIG_MAKE_MODEL(RIG_GNURADIO, 4) /* I&Q stereo sound card source */
#define RIG_MODEL_USRP_G RIG_MAKE_MODEL(RIG_GNURADIO, 5) /* Universal Software Radio Peripheral */
/*
* Microtune tuners
*/
@ -515,7 +517,6 @@
#define RIG_MODEL_MICROTUNE_4702 RIG_MAKE_MODEL(RIG_MICROTUNE, 2) /* Alan's */
#define RIG_MODEL_MICROTUNE_4707 RIG_MAKE_MODEL(RIG_MICROTUNE, 3)
/*
* TAPR
*/
@ -523,7 +524,6 @@
#define RIG_BACKEND_TAPR "tapr"
#define RIG_MODEL_DSP10 RIG_MAKE_MODEL(RIG_TAPR, 1)
/*
* Flex-radio
*/
@ -534,7 +534,6 @@
#define RIG_MODEL_DTTSP RIG_MAKE_MODEL(RIG_FLEXRADIO, 3)
#define RIG_MODEL_DTTSP_UDP RIG_MAKE_MODEL(RIG_FLEXRADIO, 4)
/*
* VEB Funkwerk Köpenick RFT
*/
@ -542,7 +541,6 @@
#define RIG_BACKEND_RFT "rft"
#define RIG_MODEL_EKD500 RIG_MAKE_MODEL(RIG_RFT, 1)
/*
* Various kits
*/
@ -568,7 +566,6 @@
#define RIG_MODEL_FUNCUBEDONGLEPLUS RIG_MAKE_MODEL(RIG_KIT, 18) /* FunCUBE Dongle Pro+ */
#define RIG_MODEL_RSHFIQ RIG_MAKE_MODEL(RIG_KIT, 19) /* RS-HFIQ */
/*
* SW/FM/TV tuner cards supported by Video4Linux,*BSD, ..
*/
@ -577,7 +574,6 @@
#define RIG_MODEL_V4L RIG_MAKE_MODEL(RIG_TUNER, 1)
#define RIG_MODEL_V4L2 RIG_MAKE_MODEL(RIG_TUNER, 2)
/*
* Rohde & Schwarz--rs
*/
@ -588,7 +584,6 @@
#define RIG_MODEL_XK2100 RIG_MAKE_MODEL(RIG_RS, 3)
#define RIG_MODEL_EK89X RIG_MAKE_MODEL(RIG_RS, 4)
/*
* Phillips/Simoco PRM80
*/
@ -597,7 +592,6 @@
#define RIG_MODEL_PRM8060 RIG_MAKE_MODEL(RIG_PRM80, 1)
#define RIG_MODEL_PRM8070 RIG_MAKE_MODEL(RIG_PRM80, 2)
/*
* ADAT by HB9CBU
*
@ -607,7 +601,6 @@
#define RIG_BACKEND_ADAT "adat"
#define RIG_MODEL_ADT_200A RIG_MAKE_MODEL(RIG_ADAT, 1)
/*
* ICOM Marine
*/
@ -618,7 +611,6 @@
#define RIG_MODEL_IC_M710 RIG_MAKE_MODEL(RIG_ICMARINE, 3)
#define RIG_MODEL_IC_M803 RIG_MAKE_MODEL(RIG_ICMARINE, 4)
/*
* Dorji transceiver modules
*/
@ -635,6 +627,7 @@
#define RIG_MODEL_BARRETT_2050 RIG_MAKE_MODEL(RIG_BARRETT, 1)
#define RIG_MODEL_BARRETT_950 RIG_MAKE_MODEL(RIG_BARRETT, 2)
#define RIG_MODEL_BARRETT_4050 RIG_MAKE_MODEL(RIG_BARRETT, 3)
#define RIG_MODEL_BARRETT_4100 RIG_MAKE_MODEL(RIG_BARRETT, 4)
/*
* Elad
@ -657,7 +650,6 @@
#define RIG_GOMSPACE 35
#define RIG_BACKEND_GOMSPACE "gomspace"
#define RIG_MODEL_GS100 RIG_MAKE_MODEL(RIG_GOMSPACE, 1)
//! @endcond
/*
* MDS Microwave Data Systems https://en.wikipedia.org/wiki/Microwave_Data_Systems
@ -673,6 +665,22 @@
etc.
*/
/*
* AnyTone rigs
*/
#define RIG_ANYTONE 37
#define RIG_BACKEND_ANYTONE "AnyTone"
#define RIG_MODEL_ATD578UVIII RIG_MAKE_MODEL(RIG_ANYTONE, 1)
/*
* Motorola rigs
*/
#define RIG_MOTOROLA 38
#define RIG_BACKEND_MOTOROLA "Motorola"
#define RIG_MODEL_MICOM2 RIG_MAKE_MODEL(RIG_MOTOROLA, 1)
//! @endcond
/*! \typedef typedef int rig_model_t
\brief Convenience type definition for rig model.

Wyświetl plik

@ -18,6 +18,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
/* SPDX-License-Identifier: LGPL-2.1-or-later */
#ifndef _ROTATOR_H
#define _ROTATOR_H 1
@ -413,8 +414,8 @@ struct rot_caps {
int (*rot_open)(ROT *rot); /*!< Pointer to backend implementation of ::rot_open(). */
int (*rot_close)(ROT *rot); /*!< Pointer to backend implementation of ::rot_close(). */
int (*set_conf)(ROT *rot, token_t token, const char *val); /*!< Pointer to backend implementation of ::rot_set_conf(). */
int (*get_conf)(ROT *rot, token_t token, char *val); /*!< Pointer to backend implementation of ::rot_get_conf(). */
int (*set_conf)(ROT *rot, hamlib_token_t token, const char *val); /*!< Pointer to backend implementation of ::rot_set_conf(). */
int (*get_conf)(ROT *rot, hamlib_token_t token, char *val); /*!< Pointer to backend implementation of ::rot_get_conf(). */
/*
* General API commands, from most primitive to least.. :()
@ -441,19 +442,19 @@ struct rot_caps {
int (*set_parm)(ROT *rot, setting_t parm, value_t val); /*!< Pointer to backend implementation of ::rot_set_parm(). */
int (*get_parm)(ROT *rot, setting_t parm, value_t *val); /*!< Pointer to backend implementation of ::rot_get_parm(). */
int (*set_ext_level)(ROT *rot, token_t token, value_t val); /*!< Pointer to backend implementation of ::rot_set_ext_level(). */
int (*get_ext_level)(ROT *rot, token_t token, value_t *val); /*!< Pointer to backend implementation of ::rot_get_ext_level(). */
int (*set_ext_level)(ROT *rot, hamlib_token_t token, value_t val); /*!< Pointer to backend implementation of ::rot_set_ext_level(). */
int (*get_ext_level)(ROT *rot, hamlib_token_t token, value_t *val); /*!< Pointer to backend implementation of ::rot_get_ext_level(). */
int (*set_ext_func)(ROT *rot, token_t token, int status); /*!< Pointer to backend implementation of ::rot_set_ext_func(). */
int (*get_ext_func)(ROT *rot, token_t token, int *status); /*!< Pointer to backend implementation of ::rot_get_ext_func(). */
int (*set_ext_func)(ROT *rot, hamlib_token_t token, int status); /*!< Pointer to backend implementation of ::rot_set_ext_func(). */
int (*get_ext_func)(ROT *rot, hamlib_token_t token, int *status); /*!< Pointer to backend implementation of ::rot_get_ext_func(). */
int (*set_ext_parm)(ROT *rot, token_t token, value_t val); /*!< Pointer to backend implementation of ::rot_set_ext_parm(). */
int (*get_ext_parm)(ROT *rot, token_t token, value_t *val); /*!< Pointer to backend implementation of ::rot_get_ext_parm(). */
int (*set_ext_parm)(ROT *rot, hamlib_token_t token, value_t val); /*!< Pointer to backend implementation of ::rot_set_ext_parm(). */
int (*get_ext_parm)(ROT *rot, hamlib_token_t token, value_t *val); /*!< Pointer to backend implementation of ::rot_get_ext_parm(). */
int (*get_status)(ROT *rot, rot_status_t *status); /*!< Pointer to backend implementation of ::rot_get_status(). */
const char *macro_name; /*!< Rotator model macro name. */
int (*get_conf2)(ROT *rot, token_t token, char *val, int val_len); /*!< Pointer to backend implementation of ::rot_get_conf2(). */
int (*get_conf2)(ROT *rot, hamlib_token_t token, char *val, int val_len); /*!< Pointer to backend implementation of ::rot_get_conf2(). */
};
//! @cond Doxygen_Suppress
#define ROT_MODEL(arg) .rot_model=arg,.macro_name=#arg
@ -544,16 +545,16 @@ rot_cleanup HAMLIB_PARAMS((ROT *rot));
extern HAMLIB_EXPORT(int)
rot_set_conf HAMLIB_PARAMS((ROT *rot,
token_t token,
hamlib_token_t token,
const char *val));
extern HAMLIB_EXPORT(int)
rot_get_conf HAMLIB_PARAMS((ROT *rot,
token_t token,
hamlib_token_t token,
char *val));
extern HAMLIB_EXPORT(int)
rot_get_conf2 HAMLIB_PARAMS((ROT *rot,
token_t token,
hamlib_token_t token,
char *val,
int val_len));
@ -635,29 +636,29 @@ rot_get_parm HAMLIB_PARAMS((ROT *rig,
extern HAMLIB_EXPORT(int)
rot_set_ext_level HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
value_t val));
extern HAMLIB_EXPORT(int)
rot_get_ext_level HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
value_t *val));
extern HAMLIB_EXPORT(int)
rot_set_ext_func HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
int status));
extern HAMLIB_EXPORT(int)
rot_get_ext_func HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
int *status));
extern HAMLIB_EXPORT(int)
rot_set_ext_parm HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
value_t val));
extern HAMLIB_EXPORT(int)
rot_get_ext_parm HAMLIB_PARAMS((ROT *rig,
token_t token,
hamlib_token_t token,
value_t *val));
extern HAMLIB_EXPORT(const char *)
@ -700,7 +701,7 @@ extern HAMLIB_EXPORT(const struct confparams *)
rot_confparam_lookup HAMLIB_PARAMS((ROT *rot,
const char *name));
extern HAMLIB_EXPORT(token_t)
extern HAMLIB_EXPORT(hamlib_token_t)
rot_token_lookup HAMLIB_PARAMS((ROT *rot,
const char *name));
@ -729,8 +730,8 @@ rot_ext_lookup HAMLIB_PARAMS((ROT *rot,
extern HAMLIB_EXPORT(const struct confparams *)
rot_ext_lookup_tok HAMLIB_PARAMS((ROT *rot,
token_t token));
extern HAMLIB_EXPORT(token_t)
hamlib_token_t token));
extern HAMLIB_EXPORT(hamlib_token_t)
rot_ext_token_lookup HAMLIB_PARAMS((ROT *rot,
const char *name));
@ -797,6 +798,8 @@ extern HAMLIB_EXPORT(const char *) rot_strlevel(setting_t);
extern HAMLIB_EXPORT(const char *) rot_strparm(setting_t);
extern HAMLIB_EXPORT(const char *) rot_strstatus(rot_status_t);
extern HAMLIB_EXPORT(void *) rot_data_pointer(ROT *rot, rig_ptrx_t idx);
//! @endcond
/**

Wyświetl plik

@ -51,11 +51,11 @@ public:
// This method closes the communication port to the rot
void close(void);
void setConf(token_t token, const char *val);
void setConf(hamlib_token_t token, const char *val);
void setConf(const char *name, const char *val);
void getConf(token_t token, char *val);
void getConf(hamlib_token_t token, char *val);
void getConf(const char *name, char *val);
token_t tokenLookup(const char *name);
hamlib_token_t tokenLookup(const char *name);
void setPosition(azimuth_t az, elevation_t el);
void getPosition(azimuth_t& az, elevation_t& el);

Wyświetl plik

@ -557,6 +557,7 @@
#define ROT_MODEL_PROSISTEL_D_AZ ROT_MAKE_MODEL(ROT_PROSISTEL, 1)
#define ROT_MODEL_PROSISTEL_D_EL ROT_MAKE_MODEL(ROT_PROSISTEL, 2)
#define ROT_MODEL_PROSISTEL_COMBI_TRACK_AZEL ROT_MAKE_MODEL(ROT_PROSISTEL, 3)
#define ROT_MODEL_PROSISTEL_D_EL_CBOXAZ ROT_MAKE_MODEL(ROT_PROSISTEL, 4)
/**
@ -636,9 +637,17 @@
#define ROT_MODEL_ANDROIDSENSOR ROT_MAKE_MODEL(ROT_ANDROIDSENSOR, 1)
/**
* \brief A macro that returns the model number of the GRBLTRK backend.
* \brief A macro that returns the model number of the ROT_MODEL_GRBLTRK_SER backend.
*
* \def ROT_MODEL_GRBLTRK
* \def ROT_MODEL_GRBLTRK_SER
*
* The GRBLTRK backend can be used with rotators that support the GRBL
* protocol.
*/
/**
* \brief A macro that returns the model number of the ROT_MODEL_GRBLTRK_NET backend.
*
* \def ROT_MODEL_GRBLTRK_NET
*
* The GRBLTRK backend can be used with rotators that support the GRBL
* protocol.
@ -650,6 +659,48 @@
#define ROT_MODEL_GRBLTRK_SER ROT_MAKE_MODEL(ROT_GRBLTRK, 1)
#define ROT_MODEL_GRBLTRK_NET ROT_MAKE_MODEL(ROT_GRBLTRK, 2)
/**
* \brief A macro that returns the model number of the FLIR backend.
*
* \def ROT_MODEL_FLIR
*
* The FLIR backend can be used with FLIR and DirectedPercepition
* rotators using the PTU protocol (e.g. PTU-D48). Currently only
* the serial interface is supported and no ethernet.
*/
//! @cond Doxygen_Suppress
#define ROT_FLIR 25
#define ROT_BACKEND_FLIR "flir"
//! @endcond
#define ROT_MODEL_FLIR ROT_MAKE_MODEL(ROT_FLIR, 1)
/**
* \brief A macro that returns the model number of the APEX backend.
*
* \def ROT_MODEL_APEX_SHARED_LOOP
*
* The APEX backend can be used with APEX * rotators.
*/
//! @cond Doxygen_Suppress
#define ROT_APEX 26
#define ROT_BACKEND_APEX "apex"
//! @endcond
#define ROT_MODEL_APEX_SHARED_LOOP ROT_MAKE_MODEL(ROT_APEX, 1)
/**
* \brief A macro that returns the model number of the SAEBRTRACK backend.
*
* \def ROT_MODEL_SAEBRTRACK
*
* The SAEBRTRACK backend can be used with SAEBRTRACK * rotators.
*/
//! @cond Doxygen_Suppress
#define ROT_SAEBRTRACK 27
#define ROT_BACKEND_SAEBRTRACK "SAEBRTrack"
//! @endcond
#define ROT_MODEL_SAEBRTRACK ROT_MAKE_MODEL(ROT_SAEBRTRACK, 1)
/**
* \brief Convenience type definition for a rotator model.
*

Wyświetl plik

@ -3,5 +3,5 @@ EXTRA_DIST = getopt.c getopt.h getopt_long.c usleep.c \
noinst_LTLIBRARIES = libmisc.la
libmisc_la_SOURCES = cJSON.c cJSON.h asyncpipe.c asyncpipe.h
libmisc_la_SOURCES = cJSON.c cJSON.h asyncpipe.c asyncpipe.h precise_time.c
libmisc_la_LIBADD = $(LTLIBOBJS) $(NET_LIBS)

Wyświetl plik

@ -43,6 +43,7 @@ int async_pipe_create(hamlib_async_pipe_t **pipe_out,
if (!pipe->read)
{
free(pipe);
return -RIG_EINTERNAL;
}
@ -143,7 +144,7 @@ ssize_t async_pipe_read(hamlib_async_pipe_t *pipe, void *buf, size_t count,
LPOVERLAPPED overlapped = &pipe->read_overlapped;
DWORD wait_result;
int result;
ssize_t bytes_read;
ssize_t bytes_read = 0;
result = ReadFile(read_handle, buf, count, NULL, overlapped);
@ -248,7 +249,7 @@ ssize_t async_pipe_write(hamlib_async_pipe_t *pipe, const unsigned char *buf,
LPOVERLAPPED overlapped = &pipe->write_overlapped;
DWORD wait_result;
int result;
ssize_t bytes_written;
ssize_t bytes_written = 0;
result = WriteFile(write_handle, buf, count, NULL, overlapped);

Wyświetl plik

@ -57,7 +57,6 @@
#endif
#include "cJSON.h"
#include <hamlib/rig.h>
/* define our own boolean type */
#ifdef true
@ -126,8 +125,8 @@ CJSON_PUBLIC(double) cJSON_GetNumberValue(const cJSON *const item)
CJSON_PUBLIC(const char *) cJSON_Version(void)
{
static char version[15];
SNPRINTF(version, sizeof(version), "%i.%i.%i", CJSON_VERSION_MAJOR,
CJSON_VERSION_MINOR, CJSON_VERSION_PATCH);
sprintf(version, "%i.%i.%i", CJSON_VERSION_MAJOR, CJSON_VERSION_MINOR,
CJSON_VERSION_PATCH);
return version;
}
@ -168,7 +167,7 @@ typedef struct internal_hooks
/* work around MSVC error C2322: '...' address of dllimport '...' is not static */
static void *CJSON_CDECL internal_malloc(size_t size)
{
return calloc(1, size);
return malloc(size);
}
static void CJSON_CDECL internal_free(void *pointer)
{
@ -319,7 +318,7 @@ typedef struct
/* Parse the input text to generate a number, and populate the result into item. */
static cJSON_bool parse_number(cJSON *const item,
parse_buffer *const input_buffer, int input_buffer_len)
parse_buffer *const input_buffer)
{
double number = 0;
unsigned char *after_end = NULL;
@ -595,22 +594,23 @@ static cJSON_bool print_number(const cJSON *const item,
/* This checks for NaN and Infinity */
if (isnan(d) || isinf(d))
{
SNPRINTF((char *)number_buffer, sizeof(number_buffer), "null");
length = strlen((char *)number_buffer);
length = sprintf((char *)number_buffer, "null");
}
else if (d == (double)item->valueint)
{
length = sprintf((char *)number_buffer, "%d", item->valueint);
}
else
{
/* Try 15 decimal places of precision to avoid nonsignificant nonzero digits */
SNPRINTF((char *)number_buffer, sizeof(number_buffer), "%1.15g", d);
length = strlen((char *)number_buffer);
length = sprintf((char *)number_buffer, "%1.15g", d);
/* Check whether the original double can be recovered */
if ((sscanf((char *)number_buffer, "%lg", &test) != 1)
|| !compare_double((double)test, d))
{
/* If not, print with 17 decimal places of precision */
SNPRINTF((char *)number_buffer, sizeof(number_buffer), "%1.17g", d);
length = strlen((char *)number_buffer);
length = sprintf((char *)number_buffer, "%1.17g", d);
}
}
@ -813,7 +813,7 @@ fail:
/* Parse the input text into an unescaped cinput, and populate item. */
static cJSON_bool parse_string(cJSON *const item,
parse_buffer *const input_buffer, int input_buffer_len)
parse_buffer *const input_buffer)
{
const unsigned char *input_pointer = buffer_at_offset(input_buffer) + 1;
const unsigned char *input_end = buffer_at_offset(input_buffer) + 1;
@ -964,7 +964,7 @@ fail:
/* Render the cstring provided to an escaped version that can be printed. */
static cJSON_bool print_string_ptr(const unsigned char *const input,
printbuffer *const output_buffer, int output_buffer_len)
printbuffer *const output_buffer)
{
const unsigned char *input_pointer = NULL;
unsigned char *output = NULL;
@ -1104,25 +1104,24 @@ static cJSON_bool print_string_ptr(const unsigned char *const input,
}
/* Invoke print_string_ptr (which is useful) on an item. */
static cJSON_bool print_string(const cJSON *const item, printbuffer *const p,
int p_len)
static cJSON_bool print_string(const cJSON *const item, printbuffer *const p)
{
return print_string_ptr((unsigned char *)item->valuestring, p, p_len);
return print_string_ptr((unsigned char *)item->valuestring, p);
}
/* Predeclare these prototypes. */
static cJSON_bool parse_value(cJSON *const item,
parse_buffer *const input_buffer, int output_buffer_len);
parse_buffer *const input_buffer);
static cJSON_bool print_value(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len);
printbuffer *const output_buffer);
static cJSON_bool parse_array(cJSON *const item,
parse_buffer *const input_buffer, int output_buffer_len);
parse_buffer *const input_buffer);
static cJSON_bool print_array(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len);
printbuffer *const output_buffer);
static cJSON_bool parse_object(cJSON *const item,
parse_buffer *const input_buffer, int output_buffer_len);
parse_buffer *const input_buffer);
static cJSON_bool print_object(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len);
printbuffer *const output_buffer);
/* Utility to jump whitespace and cr/lf */
static parse_buffer *buffer_skip_whitespace(parse_buffer *const buffer)
@ -1213,8 +1212,7 @@ CJSON_PUBLIC(cJSON *) cJSON_ParseWithLengthOpts(const char *value,
goto fail;
}
if (!parse_value(item, buffer_skip_whitespace(skip_utf8_bom(&buffer)),
sizeof(buffer)))
if (!parse_value(item, buffer_skip_whitespace(skip_utf8_bom(&buffer))))
{
/* parse failure. ep is set. */
goto fail;
@ -1289,7 +1287,7 @@ static unsigned char *print(const cJSON *const item, cJSON_bool format,
const internal_hooks *const hooks)
{
static const size_t default_buffer_size = 256;
printbuffer buffer[16];
printbuffer buffer[1];
unsigned char *printed = NULL;
memset(buffer, 0, sizeof(buffer));
@ -1306,7 +1304,7 @@ static unsigned char *print(const cJSON *const item, cJSON_bool format,
}
/* print the value */
if (!print_value(item, buffer, sizeof(buffer)))
if (!print_value(item, buffer))
{
goto fail;
}
@ -1393,7 +1391,7 @@ CJSON_PUBLIC(char *) cJSON_PrintBuffered(const cJSON *item, int prebuffer,
p.format = fmt;
p.hooks = global_hooks;
if (!print_value(item, &p, sizeof(p)))
if (!print_value(item, &p))
{
global_hooks.deallocate(p.buffer);
return NULL;
@ -1419,12 +1417,12 @@ CJSON_PUBLIC(cJSON_bool) cJSON_PrintPreallocated(cJSON *item, char *buffer,
p.format = format;
p.hooks = global_hooks;
return print_value(item, &p, sizeof(p));
return print_value(item, &p);
}
/* Parser core - when encountering text, process appropriately. */
static cJSON_bool parse_value(cJSON *const item,
parse_buffer *const input_buffer, int input_buffer_len)
parse_buffer *const input_buffer)
{
if ((input_buffer == NULL) || (input_buffer->content == NULL))
{
@ -1464,7 +1462,7 @@ static cJSON_bool parse_value(cJSON *const item,
if (can_access_at_index(input_buffer, 0)
&& (buffer_at_offset(input_buffer)[0] == '\"'))
{
return parse_string(item, input_buffer, input_buffer_len);
return parse_string(item, input_buffer);
}
/* number */
@ -1473,21 +1471,21 @@ static cJSON_bool parse_value(cJSON *const item,
|| ((buffer_at_offset(input_buffer)[0] >= '0')
&& (buffer_at_offset(input_buffer)[0] <= '9'))))
{
return parse_number(item, input_buffer, input_buffer_len);
return parse_number(item, input_buffer);
}
/* array */
if (can_access_at_index(input_buffer, 0)
&& (buffer_at_offset(input_buffer)[0] == '['))
{
return parse_array(item, input_buffer, input_buffer_len);
return parse_array(item, input_buffer);
}
/* object */
if (can_access_at_index(input_buffer, 0)
&& (buffer_at_offset(input_buffer)[0] == '{'))
{
return parse_object(item, input_buffer, input_buffer_len);
return parse_object(item, input_buffer);
}
return false;
@ -1495,7 +1493,7 @@ static cJSON_bool parse_value(cJSON *const item,
/* Render a value to text. */
static cJSON_bool print_value(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len)
printbuffer *const output_buffer)
{
unsigned char *output = NULL;
@ -1564,13 +1562,13 @@ static cJSON_bool print_value(const cJSON *const item,
}
case cJSON_String:
return print_string(item, output_buffer, output_buffer_len);
return print_string(item, output_buffer);
case cJSON_Array:
return print_array(item, output_buffer, output_buffer_len);
return print_array(item, output_buffer);
case cJSON_Object:
return print_object(item, output_buffer, output_buffer_len);
return print_object(item, output_buffer);
default:
return false;
@ -1579,7 +1577,7 @@ static cJSON_bool print_value(const cJSON *const item,
/* Build an array from input text. */
static cJSON_bool parse_array(cJSON *const item,
parse_buffer *const input_buffer, int input_buffer_len)
parse_buffer *const input_buffer)
{
cJSON *head = NULL; /* head of the linked list */
cJSON *current_item = NULL;
@ -1646,7 +1644,7 @@ static cJSON_bool parse_array(cJSON *const item,
input_buffer->offset++;
buffer_skip_whitespace(input_buffer);
if (!parse_value(current_item, input_buffer, input_buffer_len))
if (!parse_value(current_item, input_buffer))
{
goto fail; /* failed to parse value */
}
@ -1689,7 +1687,7 @@ fail:
/* Render an array to text */
static cJSON_bool print_array(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len)
printbuffer *const output_buffer)
{
unsigned char *output_pointer = NULL;
size_t length = 0;
@ -1715,7 +1713,7 @@ static cJSON_bool print_array(const cJSON *const item,
while (current_element != NULL)
{
if (!print_value(current_element, output_buffer, output_buffer_len))
if (!print_value(current_element, output_buffer))
{
return false;
}
@ -1762,7 +1760,7 @@ static cJSON_bool print_array(const cJSON *const item,
/* Build an object from the text. */
static cJSON_bool parse_object(cJSON *const item,
parse_buffer *const input_buffer, int input_buffer_len)
parse_buffer *const input_buffer)
{
cJSON *head = NULL; /* linked list head */
cJSON *current_item = NULL;
@ -1828,7 +1826,7 @@ static cJSON_bool parse_object(cJSON *const item,
input_buffer->offset++;
buffer_skip_whitespace(input_buffer);
if (!parse_string(current_item, input_buffer, input_buffer_len))
if (!parse_string(current_item, input_buffer))
{
goto fail; /* failed to parse name */
}
@ -1849,7 +1847,7 @@ static cJSON_bool parse_object(cJSON *const item,
input_buffer->offset++;
buffer_skip_whitespace(input_buffer);
if (!parse_value(current_item, input_buffer, input_buffer_len))
if (!parse_value(current_item, input_buffer))
{
goto fail; /* failed to parse value */
}
@ -1891,7 +1889,7 @@ fail:
/* Render an object to text. */
static cJSON_bool print_object(const cJSON *const item,
printbuffer *const output_buffer, int output_buffer_len)
printbuffer *const output_buffer)
{
unsigned char *output_pointer = NULL;
size_t length = 0;
@ -1942,8 +1940,7 @@ static cJSON_bool print_object(const cJSON *const item,
}
/* print key */
if (!print_string_ptr((unsigned char *)current_item->string, output_buffer,
output_buffer_len))
if (!print_string_ptr((unsigned char *)current_item->string, output_buffer))
{
return false;
}
@ -1968,7 +1965,7 @@ static cJSON_bool print_object(const cJSON *const item,
output_buffer->offset += length;
/* print value */
if (!print_value(current_item, output_buffer, output_buffer_len))
if (!print_value(current_item, output_buffer))
{
return false;
}
@ -2573,9 +2570,9 @@ CJSON_PUBLIC(cJSON_bool) cJSON_ReplaceItemViaPointer(cJSON *const parent,
else
{
/*
* To find the last item in array quickly, we use prev in array.
* We can't modify the last item's next pointer where this item was the parent's child
*/
* To find the last item in array quickly, we use prev in array.
* We can't modify the last item's next pointer where this item was the parent's child
*/
if (replacement->prev != NULL)
{
replacement->prev->next = replacement;
@ -2622,6 +2619,12 @@ static cJSON_bool replace_item_in_object(cJSON *object, const char *string,
replacement->string = (char *)cJSON_strdup((const unsigned char *)string,
&global_hooks);
if (replacement->string == NULL)
{
return false;
}
replacement->type &= ~cJSON_StringIsConst;
return cJSON_ReplaceItemViaPointer(object, get_object_item(object, string,

Wyświetl plik

@ -124,9 +124,9 @@ typedef struct cJSON
typedef struct cJSON_Hooks
{
/* malloc/free are CDECL on Windows regardless of the default calling convention of the compiler, so ensure the hooks allow passing those functions directly. */
void *(CJSON_CDECL *malloc_fn)(size_t sz);
void (CJSON_CDECL *free_fn)(void *ptr);
/* malloc/free are CDECL on Windows regardless of the default calling convention of the compiler, so ensure the hooks allow passing those functions directly. */
void *(CJSON_CDECL *malloc_fn)(size_t sz);
void (CJSON_CDECL *free_fn)(void *ptr);
} cJSON_Hooks;
typedef int cJSON_bool;
@ -255,7 +255,7 @@ CJSON_PUBLIC(cJSON *) cJSON_Duplicate(const cJSON *item, cJSON_bool recurse);
CJSON_PUBLIC(cJSON_bool) cJSON_Compare(const cJSON * const a, const cJSON * const b, const cJSON_bool case_sensitive);
/* Minify a strings, remove blank characters(such as ' ', '\t', '\r', '\n') from strings.
* The input pointer json cannot point to a read-only address area, such as a string constant,
* The input pointer json cannot point to a read-only address area, such as a string constant,
* but should point to a readable and writable address area. */
CJSON_PUBLIC(void) cJSON_Minify(char *json);
@ -279,6 +279,13 @@ CJSON_PUBLIC(double) cJSON_SetNumberHelper(cJSON *object, double number);
/* Change the valuestring of a cJSON_String object, only takes effect when type of object is cJSON_String */
CJSON_PUBLIC(char*) cJSON_SetValuestring(cJSON *object, const char *valuestring);
/* If the object is not a boolean type this does nothing and returns cJSON_Invalid else it returns the new type*/
#define cJSON_SetBoolValue(object, boolValue) ( \
(object != NULL && ((object)->type & (cJSON_False|cJSON_True))) ? \
(object)->type=((object)->type &(~(cJSON_False|cJSON_True)))|((boolValue)?cJSON_True:cJSON_False) : \
cJSON_Invalid\
)
/* Macro for iterating over an array or object */
#define cJSON_ArrayForEach(element, array) for(element = (array != NULL) ? (array)->child : NULL; element != NULL; element = element->next)

Wyświetl plik

@ -1,7 +1,7 @@
/* Dummy function to make sure libmisc never become an empty library.
* Solaris linker does not like such libs.
*/
// cppcheck-suppress unusedFunction
void dummy(void)
{

181
lib/precise_time.c 100644
Wyświetl plik

@ -0,0 +1,181 @@
// ---------------------------------------------------------------------
// precise_time.cxx
//
// Copyright (C) 2023
// Dave Freese, W1HKJ
//
// This file is part of flrig
//
// flrig is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// flrig is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with fldigi. If not, see <http://www.gnu.org/licenses/>.
// ---------------------------------------------------------------------
#include <errno.h>
#include <time.h>
#include <sys/time.h>
#if 0
// return current tick time in seconds
double monotonic_seconds()
{
static struct timeval t1;
gettimeofday(&t1, NULL);
return t1.tv_sec + t1.tv_usec / 1e6;
}
#else
//======================================================================
//
// A cross platform monotonic timer.
// Copyright 2013 Alex Reece.
//
#include <unistd.h>
#define NANOS_PER_SECF 1000000000.0
#define USECS_PER_SEC 1000000
static int showme = 0;
#if _POSIX_TIMERS > 0 && defined(_POSIX_MONOTONIC_CLOCK)
// If we have it, use clock_gettime and CLOCK_MONOTONIC.
#include <time.h>
double monotonic_seconds()
{
if (showme)
{
showme = 0;
}
struct timespec time;
// Note: Make sure to link with -lrt to define clock_gettime.
clock_gettime(CLOCK_MONOTONIC, &time);
return ((double) time.tv_sec) + ((double) time.tv_nsec / (NANOS_PER_SECF));
}
#elif defined(__APPLE__)
// If we don't have CLOCK_MONOTONIC, we might be on a Mac. There we instead
// use mach_absolute_time().
#include <mach/mach_time.h>
static mach_timebase_info_data_t info;
static void __attribute__((constructor)) init_info()
{
mach_timebase_info(&info);
}
double monotonic_seconds()
{
uint64_t time = mach_absolute_time();
double dtime = (double) time;
dtime *= (double) info.numer;
dtime /= (double) info.denom;
return dtime / NANOS_PER_SECF;
}
#elif defined(__WIN32__)
// On Windows, use QueryPerformanceCounter and QueryPerformanceFrequency.
#include <windows.h>
static double PCFreq = 0.0;
// According to http://stackoverflow.com/q/1113409/447288, this will
// make this function a constructor.
// TODO(awreece) Actually attempt to compile on windows.
// w1hkj - builds OK on mingw32
static void __cdecl init_pcfreq();
__declspec(allocate(".CRT$XCU")) void (__cdecl *init_pcfreq_)() = init_pcfreq;
static void __cdecl init_pcfreq()
{
// Accoring to http://stackoverflow.com/a/1739265/447288, this will
// properly initialize the QueryPerformanceCounter.
LARGE_INTEGER li;
int has_qpc = QueryPerformanceFrequency(&li);
assert(has_qpc);
PCFreq = ((double) li.QuadPart) / 1000.0;
}
double monotonic_seconds()
{
LARGE_INTEGER li;
QueryPerformanceCounter(&li);
return ((double) li.QuadPart) / PCFreq;
}
#else
// Fall back to rdtsc. The reason we don't use clock() is this scary message
// from the man page:
// "On several other implementations, the value returned by clock() also
// includes the times of any children whose status has been collected via
// wait(2) (or another wait-type call)."
//
// Also, clock() only has microsecond accuracy.
//
// This whitepaper offered excellent advice on how to use rdtscp for
// profiling: http://download.intel.com/embedded/software/IA/324264.pdf
//
// Unfortunately, we can't follow its advice exactly with our semantics,
// so we're just going to use rdtscp with cpuid.
//
// Note that rdtscp will only be available on new processors.
#include <stdint.h>
static inline uint64_t rdtsc()
{
uint32_t hi, lo;
uint64_t hi64, lo64;
asm volatile("rdtscp\n"
"movl %%edx, %0\n"
"movl %%eax, %1\n"
"cpuid"
: "=r"(hi), "=r"(lo) : : "%rax", "%rbx", "%rcx", "%rdx");
hi64 = hi;
lo64 = lo;
return (hi64 << 32) | lo64;
}
static uint64_t rdtsc_per_sec = 0;
static void __attribute__((constructor)) init_rdtsc_per_sec()
{
uint64_t before, after;
before = rdtsc();
usleep(USECS_PER_SEC);
after = rdtsc();
rdtsc_per_sec = after - before;
}
double monotonic_seconds()
{
if (showme)
{
showme = false;
}
return (double) rdtsc() / (double) rdtsc_per_sec;
}
#endif
#endif

Wyświetl plik

@ -1,5 +1,6 @@
#include <hamlib/rig.h>
#include <hamlib/config.h>
#include "misc.h"
#if defined(WIN32) && !defined(HAVE_TERMIOS_H)
@ -9,9 +10,11 @@
#ifdef DEBUG
#define DEBUG_VERBOSE
#define DEBUG_ERRORS
#define report(a) fprintf(stderr,a)
#define report_warning(a) fprintf(stderr,a)
#define report_error(a) fprintf(stderr,a)
static char message[256];
static char datestr[64];
#define report(a) fprintf(stderr, "%s: %s", date_strget(datestr, sizeof(datestr), 0), a)
#define report_warning(a) fprintf(stderr, "%s: %s", date_strget(datestr, sizeof(datestr), 0), a)
#define report_error(a) fprintf(stderr, "%s: %s", date_strget(datestr, sizeof(datestr), 0), a)
#else
#define report(a) do {} while (0)
#define report_warning(a) do {} while (0)
@ -65,31 +68,8 @@ int my_errno;
#if 0
extern int errno;
#endif
struct termios_list
{
char filename[512];
int my_errno;
int interrupt;
int event_flag;
int tx_happened;
unsigned long *hComm;
struct termios *ttyset;
struct serial_struct *sstruct;
/* for DTR DSR */
unsigned char MSR;
struct async_struct *astruct;
struct serial_icounter_struct *sis;
int open_flags;
OVERLAPPED rol;
OVERLAPPED wol;
OVERLAPPED sol;
int fd;
struct termios_list *next;
struct termios_list *prev;
};
struct termios_list *first_tl = NULL;
static struct termios_list *find_port(int);
struct termios_list *first_tl = NULL;
/*----------------------------------------------------------
serial_test
@ -130,7 +110,7 @@ int win32_serial_test(char *filename)
static void termios_setflags(int fd, int termios_flags[])
{
struct termios_list *index = find_port(fd);
struct termios_list *index = win32_serial_find_port(fd);
int i, result;
int windows_flags[11] = { 0, EV_RXCHAR, EV_TXEMPTY, EV_CTS, EV_DSR,
EV_RING | 0x2000, EV_RLSD, EV_ERR,
@ -761,7 +741,7 @@ int win32_serial_close(int fd)
return (0);
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -1101,7 +1081,7 @@ termios_list()
comments:
----------------------------------------------------------*/
static struct termios_list *find_port(int fd)
struct termios_list *win32_serial_find_port(int fd)
{
char message[80];
@ -1489,7 +1469,7 @@ int win32_serial_write(int fd, const char *Str, int length)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -1588,7 +1568,7 @@ int win32_serial_read(int fd, void *vb, int size)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -1650,7 +1630,7 @@ int win32_serial_read(int fd, void *vb, int size)
do
{
ClearErrors(index, &stat);
hl_usleep(1000);
hl_usleep(100);
}
while (stat.cbInQue < index->ttyset->c_cc[VMIN] && c > clock());
@ -1787,7 +1767,7 @@ int win32_serial_read(int fd, void *vb, int size)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -2409,7 +2389,7 @@ int tcgetattr(int fd, struct termios *s_termios)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -2652,7 +2632,7 @@ int tcsetattr(int fd, int when, struct termios *s_termios)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -2863,7 +2843,7 @@ int tcsendbreak(int fd, int duration)
ENTER("tcsendbreak");
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -2908,7 +2888,7 @@ int tcdrain(int fd)
int old_flag;
ENTER("tcdrain");
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -2985,7 +2965,7 @@ int tcflush(int fd, int queue_selector)
ENTER("tcflush");
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -3166,7 +3146,7 @@ int win32_serial_ioctl(int fd, int request, ...)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -3635,7 +3615,7 @@ int win32_serial_fcntl(int fd, int command, ...)
return 0;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -3688,7 +3668,7 @@ termios_interrupt_event_loop()
----------------------------------------------------------*/
static void termios_interrupt_event_loop(int fd, int flag)
{
struct termios_list *index = find_port(fd);
struct termios_list *index = win32_serial_find_port(fd);
if (!index)
{
@ -3738,7 +3718,7 @@ int win32_serial_select(int n, fd_set *readfds, fd_set *writefds,
goto fail;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -3798,9 +3778,9 @@ int win32_serial_select(int n, fd_set *readfds, fd_set *writefds,
goto end;
}
hl_usleep(10000);
hl_usleep(1000);
/* FIXME: not very accurate wrt process time */
timeout_usec -= 10000;
timeout_usec -= 1000;
report("sleep...\n");
@ -3895,7 +3875,7 @@ int win32_serial_select(int n, fd_set *readfds, fd_set *writefds,
return 1;
}
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -4028,7 +4008,7 @@ static int termiosGetParityErrorChar(int fd)
DCB dcb;
ENTER("termiosGetParityErrorChar");
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{
@ -4058,7 +4038,7 @@ static void termiosSetParityError(int fd, char value)
struct termios_list *index;
ENTER("termiosSetParityErrorChar");
index = find_port(fd);
index = win32_serial_find_port(fd);
if (!index)
{

Wyświetl plik

@ -119,6 +119,29 @@ struct serial_icounter_struct {
int reserved[9]; /* unused */
};
struct termios_list
{
char filename[512];
int my_errno;
int interrupt;
int event_flag;
int tx_happened;
unsigned long *hComm;
struct termios *ttyset;
struct serial_struct *sstruct;
/* for DTR DSR */
unsigned char MSR;
struct async_struct *astruct;
struct serial_icounter_struct *sis;
int open_flags;
OVERLAPPED rol;
OVERLAPPED wol;
OVERLAPPED sol;
int fd;
struct termios_list *next;
struct termios_list *prev;
};
int win32_serial_test( char * );
int win32_serial_open(const char *File, int flags, ... );
int win32_serial_close(int fd);
@ -126,6 +149,7 @@ int win32_serial_read(int fd, void *b, int size);
int win32_serial_write(int fd, const char *Str, int length);
int win32_serial_ioctl(int fd, int request, ... );
int win32_serial_fcntl(int fd, int command, ...);
struct termios_list *win32_serial_find_port(int);
/*
* lcc winsock.h conflicts
*/

Plik diff jest za duży Load Diff

Wyświetl plik

@ -5,7 +5,7 @@
// adat.h
//
// Created by Frank Goenninger DG1SBG.
// Copyright © 2011, 2012 Frank Goenninger.
// Copyright © 2011, 2012, 2023 Frank Goenninger.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
@ -29,21 +29,23 @@
// SYSTEM INCLUDES
// ---------------------------------------------------------------------------
#include <stddef.h>
// ---------------------------------------------------------------------------
// HAMLIB INCLUDES
// ---------------------------------------------------------------------------
#include <hamlib/rig.h>
#include "token.h"
// ---------------------------------------------------------------------------
// GLOBAL DEFINITIONS
// ---------------------------------------------------------------------------
#define BACKEND_VER "20191206"
#define BACKEND_VER "20230927"
#define ADAT_BUFSZ 256
#define ADAT_RESPSZ 256
#define ADAT_BUFSZ 255
#define ADAT_RESPSZ 255
#define ADAT_CR "\x0d"
#define ADAT_EOL "\x0a"
@ -98,7 +100,7 @@
// ADAT MODE DEFINITIONS
#define ADAT_MODE_LENGTH 5
#define ADAT_MODE_LENGTH 15
#define ADAT_NR_MODES 8
// Each mode is defined by three values:
@ -322,31 +324,45 @@
// -- GET POWER STATUS --
// -- GET INFO --
// Nothing to define here
// -- OPEN ADAT --
// Nothing to define here
// -- ADAT SPECIAL: RECOVER FROM ERROR --
// Nothing to define here
// ---------------------------------------------------------------------------
// ADAT PRIVATE DATA
// ---------------------------------------------------------------------------
#define ADAT_PRIV_DATA_PRODUCTNAME_LENGTH 255
#define ADAT_PRIV_DATA_SERIALNR_LENGTH 255
#define ADAT_PRIV_DATA_IDCODE_LENGTH 255
#define ADAT_PRIV_DATA_OPTIONS_LENGTH 255
#define ADAT_PRIV_DATA_FWVERSION_LENGTH 255
#define ADAT_PRIV_DATA_HWVERSION_LENGTH 255
#define ADAT_PRIV_DATA_GUIFWVERSION_LENGTH 255
#define ADAT_PRIV_DATA_CALLSIGN_LENGTH 255
#define ADAT_PRIV_DATA_CMD_LENGTH 255
#define ADAT_PRIV_DATA_RESULT_LENGTH 255
typedef struct _adat_priv_data
{
int nOpCode;
char *pcProductName; // Future use (USB direct I/O)
char acProductName[ ADAT_PRIV_DATA_PRODUCTNAME_LENGTH + 1]; // Future use (USB direct I/O)
// ADAT device info
char *pcSerialNr;
char *pcIDCode;
char *pcOptions;
char *pcFWVersion;
char *pcHWVersion;
char *pcGUIFWVersion;
char acSerialNr[ ADAT_PRIV_DATA_SERIALNR_LENGTH + 1 ];
char acIDCode[ ADAT_PRIV_DATA_IDCODE_LENGTH + 1 ];
char acOptions[ ADAT_PRIV_DATA_OPTIONS_LENGTH + 1 ];
char acFWVersion[ ADAT_PRIV_DATA_FWVERSION_LENGTH + 1 ];
char acHWVersion[ ADAT_PRIV_DATA_HWVERSION_LENGTH + 1 ];
char acGUIFWVersion[ ADAT_PRIV_DATA_GUIFWVERSION_LENGTH + 1 ];
char *pcCallsign;
char acCallsign[ ADAT_PRIV_DATA_CALLSIGN_LENGTH + 1 ];
// ADAT Operational Settings: will change during TRX use
@ -377,10 +393,10 @@ typedef struct _adat_priv_data
// ADAT Command-related Values
char *pcCmd;
char acCmd[ ADAT_PRIV_DATA_CMD_LENGTH + 1 ];
int nCmdKind;
char *pcResult;
char acResult[ ADAT_PRIV_DATA_RESULT_LENGTH + 1 ];
int nRC;
} adat_priv_data_t,
@ -531,9 +547,6 @@ int adat_cmd_recover_from_error(RIG *, int);
int adat_transaction(RIG *, adat_cmd_list_ptr);
adat_priv_data_ptr adat_new_priv_data(RIG *);
void adat_del_priv_data(adat_priv_data_t **);
// Command implementation
int adat_cmd_fn_get_serial_nr(RIG *);
@ -543,7 +556,6 @@ int adat_cmd_fn_get_gui_fw_version(RIG *);
int adat_cmd_fn_get_id_code(RIG *);
int adat_cmd_fn_get_options(RIG *);
int adat_cmd_fn_set_callsign(RIG *);
int adat_cmd_fn_get_callsign(RIG *);
int adat_cmd_fn_set_freq(RIG *);
@ -568,8 +580,8 @@ int adat_reset(RIG *, reset_t);
int adat_open(RIG *);
int adat_close(RIG *);
int adat_set_conf(RIG *, token_t, const char *val);
int adat_get_conf(RIG *, token_t, char *val);
int adat_set_conf(RIG *, hamlib_token_t, const char *val);
int adat_get_conf(RIG *, hamlib_token_t, char *val);
int adat_set_freq(RIG *, vfo_t, freq_t);
int adat_get_freq(RIG *, vfo_t, freq_t *);
@ -598,7 +610,7 @@ int adat_power2mW(RIG *, unsigned int *, float, freq_t, rmode_t);
int adat_get_powerstat(RIG *, powerstat_t *);
extern const struct rig_caps adt_200a_caps;
extern struct rig_caps adt_200a_caps;
// ---------------------------------------------------------------------------
// END OF FILE

Wyświetl plik

@ -5,7 +5,7 @@
// adt_200a.c
//
// Created by Frank Goenninger DG1SBG.
// Copyright © 2011, 2012 Frank Goenninger.
// Copyright © 2011, 2012, 2023 Frank Goenninger.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
@ -21,9 +21,6 @@
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#include <hamlib/config.h>
// ---------------------------------------------------------------------------
// ADT-200A INCLUDES
// ---------------------------------------------------------------------------
@ -51,7 +48,7 @@
// ADT-200A HAMLIB CAPS / DESCRIPTION
// ---------------------------------------------------------------------------
const struct rig_caps adt_200a_caps =
struct rig_caps adt_200a_caps =
{
RIG_MODEL(RIG_MODEL_ADT_200A),
.model_name = "ADT-200A",
@ -103,12 +100,18 @@ const struct rig_caps adt_200a_caps =
.rx_range_list1 =
{
{ kHz(10), MHz(30), ADT_200A_MODES, -1, -1, ADT_200A_VFO },
{ MHz(50), MHz(50.5), ADT_200A_MODES, -1, -1, ADT_200A_VFO },
{ MHz(70), MHz(70.7), ADT_200A_MODES, -1, -1, ADT_200A_VFO },
{ MHz(146), MHz(148), ADT_200A_MODES, -1, -1, ADT_200A_VFO },
RIG_FRNG_END,
},
.tx_range_list1 =
{
{ kHz(10), MHz(30), ADT_200A_MODES, mW(100), W(50), ADT_200A_VFO },
{ MHz(50), MHz(50.5), ADT_200A_MODES, mW(10), W(1), ADT_200A_FRA },
{ MHz(70), MHz(70.7), ADT_200A_MODES, mW(10), W(1), ADT_200A_FRA },
{ MHz(146), MHz(148), ADT_200A_MODES, mW(10), mW(100), ADT_200A_FRA },
RIG_FRNG_END,
},
@ -166,8 +169,10 @@ const struct rig_caps adt_200a_caps =
{ RIG_MODE_FM, Hz(8000) },
{ RIG_MODE_FM, Hz(9000) },
{ RIG_MODE_FM, Hz(10000) },
{ RIG_MODE_FM, Hz(11000) },
{ RIG_MODE_FM, Hz(12000) },
{ RIG_MODE_FM, Hz(15000) },
{ RIG_MODE_FM, Hz(20000) },
{ RIG_MODE_FM, Hz(25000) },
RIG_FLT_END,
},
.str_cal = ADT_200A_STR_CAL,

Wyświetl plik

@ -25,6 +25,12 @@
#if !defined( __ADT_200A_INCLUDED__ )
#define __ADT_200A_INCLUDED__
// ---------------------------------------------------------------------------
// HAMLIB INCLUDES
// ---------------------------------------------------------------------------
#include "rig.h"
// ---------------------------------------------------------------------------
// ADAT INCLUDES
// ---------------------------------------------------------------------------

Wyświetl plik

@ -19,7 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <hamlib/rig.h>
#include <register.h>

Wyświetl plik

@ -23,12 +23,11 @@
#define _ALINCO_H 1
#include <hamlib/rig.h>
#include <tones.h>
#define BACKEND_VER "20200323"
extern const struct rig_caps dx77_caps;
extern const struct rig_caps dxsr8_caps;
extern struct rig_caps dx77_caps;
extern struct rig_caps dxsr8_caps;
#define BUFSZ 32

Wyświetl plik

@ -19,8 +19,7 @@
*
*/
#include <hamlib/config.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h> /* String function definitions */
@ -29,8 +28,8 @@
#include "idx_builtin.h"
#include "alinco.h"
#include <serial.h>
#include "tones.h"
#include <misc.h>
#include <cal.h>
/*
* modes in use by the "2G" command
@ -151,7 +150,7 @@ int dx77_get_mem(RIG *rig, vfo_t vfo, int *ch);
* - up/down
* - scan
*/
const struct rig_caps dx77_caps =
struct rig_caps dx77_caps =
{
RIG_MODEL(RIG_MODEL_DX77),
.model_name = "DX-77",
@ -215,7 +214,6 @@ const struct rig_caps dx77_caps =
RIG_FRNG_END,
},
.tx_range_list1 = {RIG_FRNG_END,},
.tx_range_list2 = {RIG_FRNG_END,},
.rx_range_list2 =
{
@ -303,7 +301,7 @@ int dx77_transaction(RIG *rig,
{
int retval;
struct rig_state *rs;
hamlib_port_t *rp = RIGPORT(rig);
char echobuf[BUFSZ + 1];
if (cmd == NULL)
@ -313,11 +311,9 @@ int dx77_transaction(RIG *rig,
return -RIG_EINTERNAL;
}
rs = &rig->state;
rig_flush(rp);
rig_flush(&rs->rigport);
retval = write_block(&rs->rigport, (unsigned char *) cmd, cmd_len);
retval = write_block(rp, (unsigned char *) cmd, cmd_len);
if (retval != RIG_OK)
{
@ -328,7 +324,7 @@ int dx77_transaction(RIG *rig,
* Transceiver sends an echo of cmd followed by a CR/LF
* TODO: check whether cmd and echobuf match (optional)
*/
retval = read_string(&rs->rigport, (unsigned char *) echobuf, BUFSZ,
retval = read_string(rp, (unsigned char *) echobuf, BUFSZ,
LF, strlen(LF), 0, 1);
if (retval < 0)
@ -336,7 +332,7 @@ int dx77_transaction(RIG *rig,
return retval;
}
if (!(data && data_len))
if (((data == NULL) && (data_len > 0)) || ((data != NULL) && (data_len == 0)))
{
rig_debug(RIG_DEBUG_ERR, "%s: data and datalen not both NULL??\n", __func__);
return -RIG_EINTERNAL;
@ -345,7 +341,7 @@ int dx77_transaction(RIG *rig,
/* no data expected, check for OK returned */
if (data == NULL)
{
retval = read_string(&rs->rigport, (unsigned char *) echobuf, BUFSZ,
retval = read_string(rp, (unsigned char *) echobuf, BUFSZ,
LF, strlen(LF), 0, 1);
if (retval < 0)
@ -367,7 +363,7 @@ int dx77_transaction(RIG *rig,
}
}
retval = read_string(&rs->rigport, (unsigned char *) data, BUFSZ,
retval = read_string(rp, (unsigned char *) data, BUFSZ,
LF, strlen(LF), 0, 1);
if (retval < 0)
@ -499,7 +495,6 @@ int dx77_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
}
/* at least 6 digits */
// cppcheck-suppress *
SNPRINTF(freqbuf, sizeof(freqbuf), AL CMD_RXFREQ "%06"PRIll EOM, (int64_t)freq);
return dx77_transaction(rig, freqbuf, strlen(freqbuf), NULL, NULL);
@ -1015,11 +1010,11 @@ int dx77_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val)
{
lvl = 31;
}
else if (val.i >= 6 && val.i < 20)
else if (val.i < 20)
{
lvl = val.i + 25;
}
else if (val.i >= 20 && val.i <= 50)
else if (val.i <= 50)
{
lvl = val.i - 20;
}
@ -1263,7 +1258,7 @@ int dx77_set_parm(RIG *rig, setting_t parm, value_t val)
*/
int dx77_set_ctcss_tone(RIG *rig, vfo_t vfo, tone_t tone)
{
const struct rig_caps *caps;
struct rig_caps *caps;
unsigned char tonebuf[BUFSZ];
int i;

Wyświetl plik

@ -19,13 +19,13 @@
*
*/
#include <hamlib/config.h>
#include <stdint.h>
#include <stdlib.h>
#include <string.h> /* String function definitions */
#include <hamlib/rig.h>
#include <serial.h>
#include "tones.h"
#include <misc.h>
#include <iofunc.h>
#include <num_stdio.h>
@ -75,7 +75,7 @@ int dxsr8_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt);
* https://yo5ptd.wordpress.com/2017/02/12/alinco-dx-sr8/
* for a partially documented protocol
*/
const struct rig_caps dxsr8_caps =
struct rig_caps dxsr8_caps =
{
RIG_MODEL(RIG_MODEL_DXSR8),
.model_name = "DX-SR8",
@ -235,7 +235,7 @@ int dxsr8_transaction(RIG *rig,
{
int retval;
struct rig_state *rs;
hamlib_port_t *rp = RIGPORT(rig);
char replybuf[BUFSZ + 1];
int reply_len;
@ -246,11 +246,9 @@ int dxsr8_transaction(RIG *rig,
return -RIG_EINTERNAL;
}
rs = &rig->state;
rig_flush(rp);
rig_flush(&rs->rigport);
retval = write_block(&rs->rigport, (unsigned char *) cmd, cmd_len);
retval = write_block(rp, (unsigned char *) cmd, cmd_len);
if (retval != RIG_OK)
{
@ -261,7 +259,7 @@ int dxsr8_transaction(RIG *rig,
* Transceiver sends an echo of cmd followed by a CR/LF
* TODO: check whether cmd and echobuf match (optional)
*/
retval = read_string(&rs->rigport, (unsigned char *) replybuf, BUFSZ,
retval = read_string(rp, (unsigned char *) replybuf, BUFSZ,
LF, strlen(LF), 0, 1);
if (retval < 0)
@ -270,7 +268,7 @@ int dxsr8_transaction(RIG *rig,
}
retval = read_string(&rs->rigport, (unsigned char *) replybuf, BUFSZ,
retval = read_string(rp, (unsigned char *) replybuf, BUFSZ,
LF, strlen(LF), 0, 1);
if (retval < 0)
@ -344,7 +342,6 @@ int dxsr8_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
return -RIG_EINVAL;
}
// cppcheck-suppress *
SNPRINTF(cmd, sizeof(cmd), AL "~RW_RXF%08"PRIll EOM, (int64_t)freq);
return dxsr8_transaction(rig, cmd, strlen(cmd), NULL, NULL);
}
@ -357,7 +354,7 @@ int dxsr8_get_freq(RIG *rig, vfo_t vfo, freq_t *freq)
{
int retval, data_len;
char cmd[] = AL "~RR_RXF" EOM;
const char cmd[] = AL "~RR_RXF" EOM;
char freqbuf[BUFSZ];
retval = dxsr8_transaction(rig, cmd, strlen(cmd), freqbuf, &data_len);
@ -368,7 +365,7 @@ int dxsr8_get_freq(RIG *rig, vfo_t vfo, freq_t *freq)
}
/* extract RX freq */
retval = num_sscanf(freqbuf, "%"SCNfreq, freq);
num_sscanf(freqbuf, "%"SCNfreq, freq);
return RIG_OK;
}
@ -469,9 +466,15 @@ int dxsr8_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
return -RIG_EINVAL;
}
filter = 0; // avoid compiler warings of being possibly uninitialized
filter = 0; // avoid compiler warnings of being possibly uninitialized
retval = dxsr8_read_num(rig, AL "~RR_NAR" EOM, &filter);
if (retval != RIG_OK)
{
rig_debug(RIG_DEBUG_ERR, "%s: dxsr8_read_num:%s\n", __func__, rigerror(retval));
return retval;
}
if (filter == 0)
{
*width = rig_passband_wide(rig, *mode);

Wyświetl plik

@ -0,0 +1,12 @@
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
LOCAL_SRC_FILES := anytone.c d578.c
LOCAL_MODULE := anytone
LOCAL_CFLAGS :=
LOCAL_C_INCLUDES := android include src
LOCAL_LDLIBS := $(LOCAL_SHARED_LIBRARIES) -Lobj/local/$(TARGET_ARCH_ABI)
include $(BUILD_STATIC_LIBRARY)

Wyświetl plik

@ -0,0 +1,6 @@
ANYTONESRC = anytone.c d578.c anytone.h
noinst_LTLIBRARIES = libhamlib-anytone.la
libhamlib_anytone_la_SOURCES = $(ANYTONESRC)
EXTRA_DIST = Android.mk

Wyświetl plik

@ -0,0 +1,456 @@
// ---------------------------------------------------------------------------
// AnyTone D578 Hamlib Backend
// ---------------------------------------------------------------------------
//
// d578.c
//
// Created by Michael Black W9MDB
// Copyright © 2023 Michael Black W9MDB.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
// ---------------------------------------------------------------------------
// SYSTEM INCLUDES
// ---------------------------------------------------------------------------
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <ctype.h>
#include <errno.h>
// ---------------------------------------------------------------------------
// HAMLIB INCLUDES
// ---------------------------------------------------------------------------
#include <hamlib/rig.h>
#include "serial.h"
#include "misc.h"
#include "register.h"
#include "riglist.h"
// ---------------------------------------------------------------------------
// ANYTONE INCLUDES
// ---------------------------------------------------------------------------
#include "anytone.h"
int anytone_transaction(RIG *rig, unsigned char *cmd, int cmd_len,
unsigned char *reply, int reply_len, int expected_len);
DECLARE_INITRIG_BACKEND(anytone)
{
int retval = RIG_OK;
rig_register(&anytone_d578_caps);
return retval;
}
// ---------------------------------------------------------------------------
// proberig_anytone
// ---------------------------------------------------------------------------
DECLARE_PROBERIG_BACKEND(anytone)
{
int retval = RIG_OK;
if (!port)
{
return RIG_MODEL_NONE;
}
if (port->type.rig != RIG_PORT_SERIAL)
{
return RIG_MODEL_NONE;
}
port->write_delay = port->post_write_delay = 0;
port->parm.serial.stop_bits = 1;
port->retry = 1;
retval = serial_open(port);
if (retval != RIG_OK)
{
retval = -RIG_EIO;
}
return retval;
}
// AnyTone needs a keep-alive to emulate the MIC
// Apparently to keep the rig from getting stuck in PTT if mic disconnects
void *anytone_thread(void *vrig)
{
RIG *rig = (RIG *)vrig;
hamlib_port_t *rp = RIGPORT(rig);
anytone_priv_data_t *p = STATE(rig)->priv;
rig_debug(RIG_DEBUG_TRACE, "%s: anytone_thread started\n", __func__);
p->runflag = 1;
while (p->runflag)
{
char c[64];
SNPRINTF(c, sizeof(c), "+ADATA:00,001\r\na\r\n");
MUTEX_LOCK(p->priv.mutex);
// if we don't have CACHE debug enabled then we only show WARN and higher for this rig
enum rig_debug_level_e debug_level_save;
rig_get_debug(&debug_level_save);
if (rig_need_debug(RIG_DEBUG_CACHE) == 0)
{
rig_set_debug(RIG_DEBUG_WARN); // only show WARN debug otherwise too verbose
}
write_block(rp, (unsigned char *)c, strlen(c));
char buf[32];
read_block(rp, (unsigned char *)buf, 22);
if (rig_need_debug(RIG_DEBUG_CACHE) == 0)
{
rig_set_debug(debug_level_save);
}
MUTEX_UNLOCK(p->priv.mutex);
hl_usleep(1000 * 1000); // 1-second loop
}
return NULL;
}
// ---------------------------------------------------------------------------
// anytone_send
// ---------------------------------------------------------------------------
int anytone_send(RIG *rig,
unsigned char *cmd, int cmd_len)
{
int retval = RIG_OK;
hamlib_port_t *rp = RIGPORT(rig);
ENTERFUNC;
rig_flush(rp);
retval = write_block(rp, (unsigned char *) cmd,
cmd_len);
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// anytone_receive
// ---------------------------------------------------------------------------
int anytone_receive(RIG *rig, unsigned char *buf, int buf_len, int expected)
{
int retval = RIG_OK;
hamlib_port_t *rp = RIGPORT(rig);
ENTERFUNC;
// retval = read_string(rp, (unsigned char *) buf, buf_len,
// NULL, 0, 0, expected);
retval = read_block(rp, buf, expected);
if (retval > 0)
{
retval = RIG_OK;
rig_debug(RIG_DEBUG_VERBOSE, "%s: read %d byte=0x%02x\n", __func__, retval,
buf[0]);
}
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// anytone_transaction
// ---------------------------------------------------------------------------
int anytone_transaction(RIG *rig, unsigned char *cmd, int cmd_len,
unsigned char *reply, int reply_len, int expected_len)
{
int retval = RIG_OK;
//anytone_priv_data_t *p = STATE(rig)->priv;
ENTERFUNC;
retval = anytone_send(rig, cmd, cmd_len);
if (retval == RIG_OK && expected_len != 0)
{
int len = anytone_receive(rig, reply, reply_len, expected_len);
rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): rx len=%d\n", __func__, __LINE__, len);
}
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_init
// ---------------------------------------------------------------------------
int anytone_init(RIG *rig)
{
int retval = RIG_OK;
ENTERFUNC;
if (rig != NULL)
{
anytone_priv_data_ptr p = NULL;
// Get new Priv Data
p = calloc(1, sizeof(anytone_priv_data_t));
if (p == NULL)
{
retval = -RIG_ENOMEM;
RETURNFUNC(retval);
}
else
{
STATE(rig)->priv = p;
p->vfo_curr = RIG_VFO_NONE;
#ifdef HAVE_PTHREAD
pthread_mutex_init(&p->mutex, NULL);
#endif
}
}
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_cleanup
// ---------------------------------------------------------------------------
int anytone_cleanup(RIG *rig)
{
int retval = RIG_OK;
if (rig == NULL)
{
return -RIG_EARG;
}
ENTERFUNC;
free(STATE(rig)->priv);
STATE(rig)->priv = NULL;
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_open
// ---------------------------------------------------------------------------
int anytone_open(RIG *rig)
{
int retval = RIG_OK;
hamlib_port_t *rp = RIGPORT(rig);
ENTERFUNC;
unsigned char cmd[] = { 0x2B, 0x41, 0x44, 0x41, 0x54, 0x41, 0x3A, 0x30, 0x30, 0x2C, 0x30, 0x30, 0x31, 0x0d, 0x0a, 'a', 0x0d, 0x0a };
write_block(rp, cmd, sizeof(cmd));
hl_usleep(500 * 1000);
char cmd2[64];
SNPRINTF(cmd2, sizeof(cmd2), "+ADATA:00,016\r\n%cD578UV COM MODE\r\n", 0x01);
write_block(rp, (unsigned char *)cmd2, strlen(cmd2));
SNPRINTF(cmd2, sizeof(cmd2), "+ADATA:00,000\r\n");
unsigned char reply[512];
anytone_transaction(rig, (unsigned char *)cmd2, strlen(cmd2), reply,
sizeof(reply), strlen(cmd2));
pthread_t id;
// will start the keep alive
int err = pthread_create(&id, NULL, anytone_thread, (void *)rig);
if (err)
{
rig_debug(RIG_DEBUG_ERR, "%s: pthread_create error: %s\n", __func__,
strerror(errno));
RETURNFUNC(-RIG_EINTERNAL);
}
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_close
// ---------------------------------------------------------------------------
int anytone_close(RIG *rig)
{
int retval = RIG_OK;
ENTERFUNC;
char *cmd = "+ADATA:00,000\r\n";
anytone_transaction(rig, (unsigned char *)cmd, strlen(cmd), NULL, 0, 0);
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_get_vfo
// ---------------------------------------------------------------------------
int anytone_get_vfo(RIG *rig, vfo_t *vfo)
{
int retval = RIG_OK;
//char cmd[] = { 0x41, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x06 };
//char cmd[] = { "+ADATA06:00,001",0x41, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x06 };
ENTERFUNC;
const anytone_priv_data_ptr p = (anytone_priv_data_ptr) STATE(rig)->priv;
unsigned char reply[512];
unsigned char cmd[] = { 0x2b, 0x41, 0x44, 0x41, 0x54, 0x41, 0x3a, 0x30, 0x30, 0x2c, 0x30, 0x30, 0x36, 0x0d, 0x0a, 0x04, 0x05, 0x00, 0x00, 0x00, 0x00, 0x0d, 0x0a };
anytone_transaction(rig, cmd, sizeof(cmd), reply, sizeof(reply), 114);
if (reply[113] == 0x9b) { *vfo = RIG_VFO_A; }
else if (reply[113] == 0x9c) { *vfo = RIG_VFO_B; }
else
{
*vfo = RIG_VFO_A; // default to VFOA
rig_debug(RIG_DEBUG_ERR, "%s: unknown vfo=0x%02x\n", __func__, reply[113]);
}
p->vfo_curr = *vfo;
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// Function anytone_set_vfo
// ---------------------------------------------------------------------------
int anytone_set_vfo(RIG *rig, vfo_t vfo)
{
ENTERFUNC;
RETURNFUNC(RIG_OK);
}
// ---------------------------------------------------------------------------
// Function anytone_get_ptt
// ---------------------------------------------------------------------------
int anytone_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt)
{
int retval = RIG_OK;
ENTERFUNC;
anytone_priv_data_t *p = STATE(rig)->priv;
*ptt = p->ptt;
RETURNFUNC(retval);
}
// ---------------------------------------------------------------------------
// anytone_set_ptt
// ---------------------------------------------------------------------------
int anytone_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt)
{
int retval = RIG_OK;
ENTERFUNC;
//char buf[8] = { 0x41, 0x00, 0x00, 0x00, 0x27, 0x00, 0x00, 0x06 };
unsigned char ptton[] = { 0x2B, 0x41, 0x44, 0x41, 0x54, 0x41, 0x3A, 0x30, 0x30, 0x2C, 0x30, 0x30, 0x31, 0x0d, 0x0a, 0x61, 0x0d, 0x0a };
unsigned char pttoff[] = { 0x2B, 0x41, 0x44, 0x41, 0x54, 0x41, 0x3A, 0x30, 0x30, 0x2C, 0x30, 0x32, 0x33, 0x0d, 0x0a, 0x56, 0x0d, 0x0a };
void *pttcmd = ptton;
if (!ptt) { pttcmd = pttoff; }
//if (!ptt) { cmd = " (unsigned char*)+ADATA:00,023\r\nV\r\n"; }
MUTEX_LOCK(p->mutex);
anytone_transaction(rig, pttcmd, sizeof(ptton), NULL, 0, 0);
anytone_priv_data_t *p = STATE(rig)->priv;
p->ptt = ptt;
MUTEX_UNLOCK(p->mutex);
RETURNFUNC(retval);
}
int anytone_get_freq(RIG *rig, vfo_t vfo, freq_t *freq)
{
char cmd[32];
int retval;
hamlib_port_t *rp = RIGPORT(rig);
SNPRINTF(cmd, sizeof(cmd), "+ADATA:00,006\r\n");
cmd[15] = 0x04;
cmd[16] = 0x2c;
cmd[17] = 0x07;
cmd[18] = 0x00;
cmd[19] = 0x00;
cmd[21] = 0x00;
cmd[22] = 0x00;
cmd[23] = 0x0d;
cmd[24] = 0x0a;
if (vfo == RIG_VFO_B) { cmd[16] = 0x2d; }
int retry = 2;
MUTEX_LOCK(p->priv.mutex);
rig_flush(rp);
do
{
write_block(rp, (unsigned char *)cmd, 25);
unsigned char buf[512];
retval = read_block(rp, buf, 138);
if (retval == 138)
{
*freq = from_bcd_be(&buf[17], 8) * 10;
rig_debug(RIG_DEBUG_VERBOSE, "%s: VFOA freq=%g\n", __func__, *freq);
retval = RIG_OK;
}
}
while (retval != 138 && --retry > 0);
MUTEX_UNLOCK(p->priv.mutex);
return RIG_OK;
}
int anytone_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
{
char cmd[64];
hamlib_port_t *rp = RIGPORT(rig);
if (vfo == RIG_VFO_A)
{
snprintf(cmd, sizeof(cmd), "ADATA:00,005\r\n%c%c%c%c\r\n", 2, 0, 0, 0);
}
else
{
snprintf(cmd, sizeof(cmd), "ADATA:00,005\r\n%c%c%c%c\r\n", 1, 0, 0, 0);
}
MUTEX_LOCK(p->priv.mutex);
rig_flush(rp);
write_block(rp, (unsigned char *) cmd, 20);
unsigned char backend[] = { 0x2f, 0x03, 0x00, 0xff, 0xff, 0xff, 0xff, 0x15, 0x50, 0x00, 0x00, 0x0d, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xcf, 0x09, 0x00, 0x00, 0x0d, 0x0a};
snprintf(cmd, sizeof(cmd), "ADATA:00,023\r\n");
int bytes = strlen(cmd) + sizeof(backend);
memcpy(&cmd[15], backend, sizeof(backend));
hl_usleep(10 * 1000);
write_block(rp, (unsigned char *)cmd, bytes);
MUTEX_UNLOCK(p->priv.mutex);
return -RIG_ENIMPL;
}
// ---------------------------------------------------------------------------
// END OF FILE
// ---------------------------------------------------------------------------

Wyświetl plik

@ -0,0 +1,48 @@
#ifndef _ANYTONE_H
#define _ANYTONE_H 1
#include "hamlib/rig.h"
#define BACKEND_VER "20231001"
#define ANYTONE_RESPSZ 64
extern struct rig_caps anytone_d578_caps;
#ifdef PTHREAD
#include <pthread.h>
#define MUTEX(var) static pthread_mutex_t var = PTHREAD_MUTEX_INITIALIZER
#define MUTEX_LOCK(var) pthread_mutex_lock(var)
#define MUTEX_UNLOCK(var) pthread_mutex_unlock(var)
#else
#define MUTEX(var)
#define MUTEX_LOCK(var)
#define MUTEX_UNLOCK(var)
#endif
typedef struct _anytone_priv_data
{
ptt_t ptt;
vfo_t vfo_curr;
int runflag; // thread control
char buf[64];
pthread_mutex_t mutex;
} anytone_priv_data_t,
* anytone_priv_data_ptr;
extern int anytone_init(RIG *rig);
extern int anytone_cleanup(RIG *rig);
extern int anytone_open(RIG *rig);
extern int anytone_close(RIG *rig);
extern int anytone_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt);
extern int anytone_get_ptt(RIG *rig, vfo_t vfo,ptt_t *ptt);
extern int anytone_set_vfo(RIG *rig, vfo_t vfo);
extern int anytone_get_vfo(RIG *rig, vfo_t *vfo);
extern int anytone_set_freq(RIG *rig, vfo_t vfo, freq_t freq);
extern int anytone_get_freq(RIG *rig, vfo_t vfo, freq_t *freq);
#endif /* _ANYTONE_H */

Wyświetl plik

@ -0,0 +1,95 @@
// ---------------------------------------------------------------------------
// Anytone D578UVIII
// ---------------------------------------------------------------------------
//
// d578.c
//
// Created by Michael Black W9MDB
// Copyright © 2023, Michael Black W9MDB.
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
#include "anytone.h"
#define D578_VFO (RIG_VFO_A|RIG_VFO_B)
#define D578_MODES (RIG_MODE_USB|RIG_MODE_AM)
struct rig_caps anytone_d578_caps =
{
RIG_MODEL(RIG_MODEL_ATD578UVIII),
.model_name = "D578A",
.mfg_name = "AnyTone",
.version = BACKEND_VER ".0",
.copyright = "Michael Black W9MDB: GNU LGPL",
.status = RIG_STATUS_BETA,
.rig_type = RIG_TYPE_TRANSCEIVER,
.ptt_type = RIG_PTT_RIG,
.dcd_type = RIG_DCD_NONE,
.port_type = RIG_PORT_SERIAL,
.serial_rate_min = 115200,
.serial_rate_max = 115200,
.serial_data_bits = 8,
.serial_stop_bits = 1,
.serial_parity = RIG_PARITY_NONE,
.serial_handshake = RIG_HANDSHAKE_NONE,
.write_delay = 0,
.post_write_delay = 0,
.timeout = 1000,
.retry = 3,
.level_gran = {},
.parm_gran = {},
.ctcss_list = NULL,
.dcs_list = NULL,
.targetable_vfo = RIG_TARGETABLE_NONE,
.transceive = 0,
.rx_range_list1 =
{
{ MHz(108), MHz(174), D578_MODES, -1, -1, D578_VFO },
{ MHz(144), MHz(148), D578_MODES, -1, -1, D578_VFO },
{ MHz(222), MHz(225), D578_MODES, -1, -1, D578_VFO },
{ MHz(420), MHz(450), D578_MODES, -1, -1, D578_VFO },
RIG_FRNG_END,
},
.tx_range_list1 =
{
{ MHz(144), MHz(148), D578_MODES, W(1), W(55), D578_VFO },
{ MHz(222), MHz(225), D578_MODES, W(1), W(40), D578_VFO },
{ MHz(420), MHz(450), D578_MODES, W(1), W(25), D578_VFO },
RIG_FRNG_END,
},
.rig_init = anytone_init,
.rig_cleanup = anytone_cleanup,
.rig_open = anytone_open,
.rig_close = anytone_close,
.get_vfo = anytone_get_vfo,
.set_vfo = anytone_set_vfo,
.get_ptt = anytone_get_ptt,
.set_ptt = anytone_set_ptt,
.set_freq = anytone_set_freq,
.get_freq = anytone_get_freq,
.hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS
};
// ---------------------------------------------------------------------------
// END OF FILE
// ---------------------------------------------------------------------------

Wyświetl plik

@ -16,7 +16,7 @@ The previous AR5000 could:
Now, it:
- can get and set frequency.
- can read and set (all) modes.
- still does not support VFO D & E. I probably have not understood how VFO_N(3) and VFO_N(4) are ment to be used :-(
- still does not support VFO D & E. I probably have not understood how VFO_N(3) and VFO_N(4) are meant to be used :-(
- can read AGC-level.

Wyświetl plik

@ -19,10 +19,9 @@
*
*/
#include <hamlib/config.h>
#include <stdint.h>
#include <stdio.h>
#include <ctype.h>
#include <string.h>
#include "hamlib/rig.h"
#include "serial.h"
@ -59,7 +58,7 @@
/*
* aor_transaction
* We assume that rig!=NULL, rig->state!= NULL, data!=NULL, data_len!=NULL
* We assume that rig!=NULL, STATE(rig)!= NULL, data!=NULL, data_len!=NULL
* Otherwise, you'll get a nice seg fault. You've been warned!
* return value: RIG_OK if everything's fine, negative value otherwise
* TODO: error case handling
@ -68,15 +67,13 @@ static int aor_transaction(RIG *rig, const char *cmd, int cmd_len, char *data,
int *data_len)
{
int retval;
struct rig_state *rs;
hamlib_port_t *rp = RIGPORT(rig);
char ackbuf[BUFSZ];
int ack_len;
rs = &rig->state;
rig_flush(rp);
rig_flush(&rs->rigport);
retval = write_block(&rs->rigport, (unsigned char *) cmd, cmd_len);
retval = write_block(rp, (unsigned char *) cmd, cmd_len);
if (retval != RIG_OK)
{
@ -96,7 +93,7 @@ static int aor_transaction(RIG *rig, const char *cmd, int cmd_len, char *data,
/*
* Do wait for a reply
*/
retval = read_string(&rs->rigport, (unsigned char *) data, BUFSZ, EOM,
retval = read_string(rp, (unsigned char *) data, BUFSZ, EOM,
strlen(EOM), 0, 1);
if (retval < 0)
@ -125,7 +122,7 @@ static int aor_transaction(RIG *rig, const char *cmd, int cmd_len, char *data,
if (retval >= 1 && data[0] == '?')
{
/* command failed? resync with radio */
write_block(&rs->rigport, (unsigned char *) EOM, 1);
write_block(rp, (unsigned char *) EOM, 1);
return -RIG_EPROTO;
}
@ -145,7 +142,7 @@ int aor_close(RIG *rig)
* since no reply is to be expected.
*/
return write_block(&rig->state.rigport, (unsigned char *) "EX" EOM, 3);
return write_block(RIGPORT(rig), (unsigned char *) "EX" EOM, 3);
}
static int format_freq(char *buf, int buf_len, freq_t freq)
@ -175,7 +172,6 @@ static int format_freq(char *buf, int buf_len, freq_t freq)
f = f * 100 + lowhz;
// cppcheck-suppress *
SNPRINTF(buf, buf_len, "RF%010"PRIll, f);
return strlen(buf);
}
@ -272,8 +268,8 @@ int aor_set_vfo(RIG *rig, vfo_t vfo)
case RIG_VFO_MEM: vfocmd = "MR" EOM; break;
default:
rig_debug(RIG_DEBUG_ERR, "aor_set_vfo: unsupported vfo %d\n",
vfo);
rig_debug(RIG_DEBUG_ERR, "aor_set_vfo: unsupported vfo %s\n",
rig_strvfo(vfo));
return -RIG_EINVAL;
}
@ -541,7 +537,8 @@ int parse8k_aor_mode(RIG *rig, char aormode, char aorwidth, rmode_t *mode,
int aor_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
{
struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
char ackbuf[BUFSZ], ackbuf2[BUFSZ];
char ackbuf[BUFSZ];
char ackbuf2[BUFSZ];
char *mdp, *mdp2;
int ack_len, ack2_len, retval;
@ -608,7 +605,7 @@ int aor_set_ts(RIG *rig, vfo_t vfo, shortfreq_t ts)
/*
* aor_set_level
* Assumes rig!=NULL, rig->state.priv!=NULL
* Assumes rig!=NULL, STATE(rig)->priv!=NULL
*/
int aor_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val)
{
@ -616,7 +613,7 @@ int aor_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val)
char lvlbuf[BUFSZ];
int agc;
rs = &rig->state;
rs = STATE(rig);
switch (level)
@ -673,16 +670,14 @@ int aor_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val)
/*
* aor_get_level
* Assumes rig!=NULL, rig->state.priv!=NULL, val!=NULL
* Assumes rig!=NULL, STATE(rig)->priv!=NULL, val!=NULL
*/
int aor_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
{
struct rig_state *rs;
struct rig_state *rs = STATE(rig);
char lvlbuf[BUFSZ], ackbuf[BUFSZ];
int ack_len, retval;
rs = &rig->state;
switch (level)
{
case RIG_LEVEL_RAWSTR:
@ -719,7 +714,7 @@ int aor_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
if (rig->caps->rig_model == RIG_MODEL_AR8000)
{
sscanf(ackbuf + 2, "%x", &val->i);
sscanf(ackbuf + 2, "%x", &val->u);
val->i &= ~0x80; /* mask squelch status */
}
else if (rig->caps->rig_model == RIG_MODEL_AR8200 ||
@ -729,7 +724,7 @@ int aor_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
}
else
{
sscanf(ackbuf + 3, "%x", &val->i);
sscanf(ackbuf + 3, "%x", &val->u);
}
break;
@ -760,7 +755,7 @@ int aor_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
if (att > HAMLIB_MAXDBLSTSIZ || rs->attenuator[att - 1] == 0)
{
rig_debug(RIG_DEBUG_ERR, "Unsupported att %s %d\n",
rig_debug(RIG_DEBUG_ERR, "Unsupported att %s %u\n",
__func__, att);
return -RIG_EPROTO;
}
@ -823,7 +818,7 @@ int aor_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
/*
* aor_get_dcd
* Assumes rig!=NULL, rig->state.priv!=NULL, val!=NULL
* Assumes rig!=NULL, STATE(rig)->priv!=NULL, val!=NULL
*/
int aor_get_dcd(RIG *rig, vfo_t vfo, dcd_t *dcd)
{
@ -850,7 +845,7 @@ int aor_get_dcd(RIG *rig, vfo_t vfo, dcd_t *dcd)
/*
* aor_set_powerstat
* Assumes rig!=NULL, rig->state.priv!=NULL
* Assumes rig!=NULL, STATE(rig)->priv!=NULL
*/
int aor_set_powerstat(RIG *rig, powerstat_t status)
{
@ -894,7 +889,7 @@ int aor_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op)
/*
* aor_scan, scan operation
* Assumes rig!=NULL, rig->state.priv!=NULL
* Assumes rig!=NULL, STATE(rig)->priv!=NULL
*/
int aor_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch)
{
@ -938,7 +933,7 @@ int aor_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch)
*/
int aor_set_mem(RIG *rig, vfo_t vfo, int ch)
{
struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
const struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
char membuf[BUFSZ];
int mem_num;
char bank_base;
@ -972,7 +967,7 @@ int aor_set_mem(RIG *rig, vfo_t vfo, int ch)
*/
int aor_get_mem(RIG *rig, vfo_t vfo, int *ch)
{
struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
const struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
int mem_len, retval;
char membuf[BUFSZ];
@ -1151,7 +1146,7 @@ static int parse_chan_line(RIG *rig, channel_t *chan, char *basep,
char *tag2p;
tagp = strstr(basep, "MD");
if (!tagp && mem_caps->mode && mem_caps->width)
if (!tagp)
{
rig_debug(RIG_DEBUG_WARN, "%s: no MD in returned string: '%s'\n",
__func__, basep);
@ -1239,7 +1234,7 @@ static int parse_chan_line(RIG *rig, channel_t *chan, char *basep,
int aor_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only)
{
struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
const struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
char aorcmd[BUFSZ];
int chan_len;
char chanbuf[BUFSZ];
@ -1345,9 +1340,9 @@ int aor_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only)
int aor_get_chan_all_cb(RIG *rig, vfo_t vfo, chan_cb_t chan_cb, rig_ptr_t arg)
{
struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
const struct aor_priv_caps *priv = (struct aor_priv_caps *)rig->caps->priv;
int i, j, retval;
chan_t *chan_list = rig->state.chan_list;
chan_t *chan_list = STATE(rig)->chan_list;
channel_t *chan;
int chan_count;
char aorcmd[BUFSZ];
@ -1424,7 +1419,7 @@ int aor_get_chan_all_cb(RIG *rig, vfo_t vfo, chan_cb_t chan_cb, rig_ptr_t arg)
/*
* get next line
*/
retval = read_string(&rig->state.rigport, (unsigned char *) chanbuf, BUFSZ,
retval = read_string(RIGPORT(rig), (unsigned char *) chanbuf, BUFSZ,
EOM, strlen(EOM), 0, 1);
if (retval < 0)
@ -1457,7 +1452,7 @@ const char *aor_get_info(RIG *rig)
return NULL;
}
if (retval > 2) { idbuf[2] = '\0'; }
// never executed -- if (retval > 2) { idbuf[2] = '\0'; }
retval = aor_transaction(rig, "VR" EOM, 3, frmbuf, &frm_len);

Wyświetl plik

@ -64,16 +64,16 @@ int aor_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only);
int aor_set_channel(RIG *rig, vfo_t vfo, const channel_t *chan);
int aor_get_chan_all_cb (RIG * rig, vfo_t vfo, chan_cb_t chan_cb, rig_ptr_t);
extern const struct rig_caps ar2700_caps;
extern const struct rig_caps ar8200_caps;
extern const struct rig_caps ar8000_caps;
extern const struct rig_caps ar8600_caps;
extern const struct rig_caps ar5000_caps;
extern const struct rig_caps ar3000a_caps;
extern const struct rig_caps ar7030_caps;
extern const struct rig_caps ar3030_caps;
extern const struct rig_caps ar5000a_caps;
extern const struct rig_caps ar7030p_caps;
extern const struct rig_caps sr2200_caps;
extern struct rig_caps ar2700_caps;
extern struct rig_caps ar8200_caps;
extern struct rig_caps ar8000_caps;
extern struct rig_caps ar8600_caps;
extern struct rig_caps ar5000_caps;
extern struct rig_caps ar3000a_caps;
extern struct rig_caps ar7030_caps;
extern struct rig_caps ar3030_caps;
extern struct rig_caps ar5000a_caps;
extern struct rig_caps ar7030p_caps;
extern struct rig_caps sr2200_caps;
#endif /* _AOR_H */

Wyświetl plik

@ -19,9 +19,8 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
#include <string.h>
#include <hamlib/rig.h>
#include "aor.h"
@ -81,14 +80,14 @@ static const struct aor_priv_caps ar2700_priv_caps =
* part of info from http://www.aoruk.com/2700.htm
* Interface unit: CU-8232 (or equivalent)
*/
const struct rig_caps ar2700_caps =
struct rig_caps ar2700_caps =
{
RIG_MODEL(RIG_MODEL_AR2700),
.model_name = "AR2700",
.mfg_name = "AOR",
.version = BACKEND_VER ".0",
.copyright = "LGPL",
.status = RIG_STATUS_ALPHA,
.status = RIG_STATUS_BETA,
.rig_type = RIG_TYPE_SCANNER,
.ptt_type = RIG_PTT_NONE,
.dcd_type = RIG_DCD_RIG,

Wyświetl plik

@ -19,16 +19,11 @@
*
*/
#include <hamlib/config.h>
#include <stdio.h>
#include <string.h>
#include <hamlib/rig.h>
#include <serial.h>
#include <misc.h>
#include "aor.h"
static int ar3k_set_freq(RIG *rig, vfo_t vfo, freq_t freq);
static int ar3k_get_freq(RIG *rig, vfo_t vfo, freq_t *freq);
@ -67,7 +62,7 @@ static int ar3k_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val);
* TODO:
* set_channel, get_channel, set_func MUTE,SQL, get_dcd, ...
*/
const struct rig_caps ar3000a_caps =
struct rig_caps ar3000a_caps =
{
RIG_MODEL(RIG_MODEL_AR3000A),
.model_name = "AR3000A",
@ -190,13 +185,11 @@ static int ar3k_transaction(RIG *rig, const char *cmd, int cmd_len, char *data,
int *data_len)
{
int retval;
struct rig_state *rs;
hamlib_port_t *rp = RIGPORT(rig);
rs = &rig->state;
rig_flush(rp);
rig_flush(&rs->rigport);
retval = write_block(&rs->rigport, (unsigned char *) cmd, cmd_len);
retval = write_block(rp, (unsigned char *) cmd, cmd_len);
if (retval != RIG_OK)
{
@ -209,7 +202,7 @@ static int ar3k_transaction(RIG *rig, const char *cmd, int cmd_len, char *data,
return RIG_OK;
}
retval = read_string(&rs->rigport, (unsigned char *) data, BUFSZ,
retval = read_string(rp, (unsigned char *) data, BUFSZ,
EOM, strlen(EOM), 0, 1);
if (retval == -RIG_ETIMEOUT)

Wyświetl plik

@ -18,7 +18,6 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
*/
#include <hamlib/config.h>
#include <stdio.h>
#include <stdlib.h>
@ -28,7 +27,6 @@
#include "serial.h"
#include "idx_builtin.h"
#include "misc.h"
#include "aor.h"
static int ar3030_set_vfo(RIG *rig, vfo_t vfo);
@ -95,7 +93,7 @@ struct ar3030_priv_data
*
* ar3030 rig capabilities.
*/
const struct rig_caps ar3030_caps =
struct rig_caps ar3030_caps =
{
RIG_MODEL(RIG_MODEL_AR3030),
.model_name = "AR3030",
@ -218,22 +216,20 @@ static int ar3030_transaction(RIG *rig, const char *cmd, int cmd_len,
char *data, int *data_len)
{
int retval;
struct rig_state *rs;
hamlib_port_t *rp = RIGPORT(rig);
int retry = 3;
char tmpdata[BUFSZ];
rs = &rig->state;
if (data == NULL)
{
data = tmpdata;
}
rig_flush(&rs->rigport);
rig_flush(rp);
do
{
retval = write_block(&rs->rigport, (unsigned char *) cmd, cmd_len);
retval = write_block(rp, (unsigned char *) cmd, cmd_len);
if (retval != RIG_OK)
{
@ -244,7 +240,7 @@ static int ar3030_transaction(RIG *rig, const char *cmd, int cmd_len,
if (data)
{
/* expecting 0x0d0x0a on all commands so wait for the 0x0a */
retval = read_string(&rs->rigport, (unsigned char *) data, BUFSZ,
retval = read_string(rp, (unsigned char *) data, BUFSZ,
"\x0a", 1, 0, 1);
if (retval == -RIG_ETIMEOUT)
@ -281,15 +277,16 @@ static int ar3030_transaction(RIG *rig, const char *cmd, int cmd_len,
int ar3030_init(RIG *rig)
{
struct ar3030_priv_data *priv;
struct rig_state *rs = STATE(rig);
rig->state.priv = calloc(1, sizeof(struct ar3030_priv_data));
rs->priv = calloc(1, sizeof(struct ar3030_priv_data));
if (!rig->state.priv)
if (!rs->priv)
{
return -RIG_ENOMEM;
}
priv = rig->state.priv;
priv = rs->priv;
priv->curr_ch = 99; /* huh! FIXME: get_mem in open() ? */
priv->curr_vfo = RIG_VFO_A;
@ -299,7 +296,7 @@ int ar3030_init(RIG *rig)
int ar3030_cleanup(RIG *rig)
{
struct ar3030_priv_data *priv = rig->state.priv;
struct ar3030_priv_data *priv = STATE(rig)->priv;
free(priv);
@ -309,12 +306,10 @@ int ar3030_cleanup(RIG *rig)
int ar3030_close(RIG *rig)
{
int retval;
struct rig_state *rs;
rig_debug(RIG_DEBUG_TRACE, "%s:\n", __func__);
rs = &rig->state;
rig_flush(&rs->rigport);
rig_flush(RIGPORT(rig));
retval = ar3030_transaction(rig, "Q" CR, strlen("Q" CR), NULL, NULL);
rig_debug(RIG_DEBUG_TRACE, "%s: retval=%d\n", __func__, retval);
@ -324,7 +319,7 @@ int ar3030_close(RIG *rig)
int ar3030_set_vfo(RIG *rig, vfo_t vfo)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char *cmd = "";
int retval;
@ -358,7 +353,8 @@ int ar3030_set_vfo(RIG *rig, vfo_t vfo)
int ar3030_get_vfo(RIG *rig, vfo_t *vfo)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
const struct ar3030_priv_data *priv = (struct ar3030_priv_data *)
STATE(rig)->priv;
*vfo = priv->curr_vfo;
@ -372,7 +368,7 @@ int ar3030_get_vfo(RIG *rig, vfo_t *vfo)
*/
int ar3030_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char freqbuf[BUFSZ];
int retval;
@ -396,7 +392,7 @@ int ar3030_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
*/
int ar3030_get_freq(RIG *rig, vfo_t vfo, freq_t *freq)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char *rfp;
int freq_len, retval;
char freqbuf[BUFSZ];
@ -496,7 +492,7 @@ int ar3030_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width)
*/
int ar3030_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
int buf_len, retval;
char buf[BUFSZ];
@ -558,7 +554,7 @@ int ar3030_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
int ar3030_set_mem(RIG *rig, vfo_t vfo, int ch)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
int retval = RIG_OK;
if (priv->curr_vfo == RIG_VFO_MEM)
@ -578,7 +574,7 @@ int ar3030_set_mem(RIG *rig, vfo_t vfo, int ch)
int ar3030_get_mem(RIG *rig, vfo_t vfo, int *ch)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char infobuf[BUFSZ];
int info_len, retval;
@ -651,7 +647,7 @@ int ar3030_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val)
int ar3030_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
int info_len, retval;
char infobuf[BUFSZ], *p;
@ -722,7 +718,7 @@ int ar3030_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val)
int ar3030_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char cmdbuf[BUFSZ], infobuf[BUFSZ];
int info_len, retval;
@ -798,7 +794,6 @@ int ar3030_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only)
rig_passband_normal(rig, chan->mode);
// cppcheck-suppress *
chan->levels[LVL_ATT].i = infobuf[6] == '0' ? 0 :
rig->caps->attenuator[infobuf[4] - '1'];
@ -820,7 +815,7 @@ int ar3030_get_channel(RIG *rig, vfo_t vfo, channel_t *chan, int read_only)
int ar3030_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op)
{
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)rig->state.priv;
struct ar3030_priv_data *priv = (struct ar3030_priv_data *)STATE(rig)->priv;
char buf[16];
int retval;

Wyświetl plik

@ -20,8 +20,6 @@
*
*/
#include <hamlib/config.h>
#include <stdio.h>
#include <string.h>
#include <hamlib/rig.h>
@ -101,7 +99,7 @@ static const struct aor_priv_caps ar5k_priv_caps =
*
* TODO: retrieve BW info, and rest of commands
*/
const struct rig_caps ar5000_caps =
struct rig_caps ar5000_caps =
{
RIG_MODEL(RIG_MODEL_AR5000),
.model_name = "AR5000",
@ -247,14 +245,14 @@ const struct rig_caps ar5000_caps =
*
* TODO: retrieve BW info, and rest of commands
*/
const struct rig_caps ar5000a_caps =
struct rig_caps ar5000a_caps =
{
RIG_MODEL(RIG_MODEL_AR5000A),
.model_name = "AR5000A",
.mfg_name = "AOR",
.version = BACKEND_VER ".0",
.copyright = "LGPL",
.status = RIG_STATUS_BETA,
.status = RIG_STATUS_STABLE,
.rig_type = RIG_TYPE_SCANNER,
.ptt_type = RIG_PTT_NONE,
.dcd_type = RIG_DCD_RIG,

Wyświetl plik

@ -24,12 +24,9 @@
// Version 2004.11.29 F.Melchert (DC9RP)
//
#include <hamlib/config.h>
#include <stdio.h>
#include <hamlib/rig.h>
#include "aor.h"
#include "serial.h"
#include "idx_builtin.h"
@ -69,23 +66,23 @@
static int rxr_writeByte(RIG *rig, unsigned char c)
{
return write_block(&rig->state.rigport, &c, 1);
return write_block(RIGPORT(rig), &c, 1);
}
static int rxr_readByte(RIG *rig)
{
unsigned char response[1];
unsigned char buf[] = {0x71}; // Read command
const unsigned char buf[] = {0x71}; // Read command
int retval;
retval = write_block(&rig->state.rigport, buf, 1);
retval = write_block(RIGPORT(rig), buf, 1);
if (retval != RIG_OK)
{
return retval;
}
retval = read_block(&rig->state.rigport, response, 1);
retval = read_block(RIGPORT(rig), response, 1);
if (retval != RIG_OK)
{
@ -193,7 +190,8 @@ static void Execute_Routine_2_1(RIG *rig, char mp, char ad, int numSteps)
}
#endif
// Routine 3 Set passband Setup all IF parameters from filter, pbsval and bfoval bytes.
static void Execute_Routine_3_1(RIG *rig, char mp, char ad, int numSteps)
static void Execute_Routine_3_1(RIG *rig, char mp, char ad,
unsigned int numSteps)
{
setLock(rig, 1); //Set Lock Level
setMemPtr(rig, mp, ad); //page, address
@ -272,16 +270,17 @@ static void Execute_Routine_6_1(RIG *rig, char mp, char ad, int numSteps)
static int Execute_Routine_14(RIG *rig)
{
unsigned char response[1];
unsigned char buf[] = {0x2e}; // Read command
hamlib_port_t *rp = RIGPORT(rig);
const unsigned char buf[] = {0x2e}; // Read command
int retval;
retval = write_block(&rig->state.rigport, buf, 1);
retval = write_block(rp, buf, 1);
if (retval != RIG_OK)
{
return retval;
}
retval = read_block(&rig->state.rigport, response, 1);
retval = read_block(rp, response, 1);
if (retval != RIG_OK)
{
@ -491,7 +490,7 @@ static int ar7030_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
setMemPtr(rig, 0, 0x38);
if ((*width = BCD_To_int(rig, rxr_readByte(rig)) * 100) < 0)
if ((*width = (pbwidth_t)BCD_To_int(rig, rxr_readByte(rig)) * 100) < 0)
{
return -RIG_EINVAL;
}
@ -775,7 +774,7 @@ static int ar7030_reset(RIG *rig, reset_t reset)
const struct rig_caps ar7030_caps =
struct rig_caps ar7030_caps =
{
RIG_MODEL(RIG_MODEL_AR7030),
.model_name = "AR7030",
@ -805,7 +804,6 @@ const struct rig_caps ar7030_caps =
.has_get_parm = AR7030_PARM,
.has_set_parm = RIG_PARM_NONE,
.level_gran = {
// cppcheck-suppress *
[LVL_RAWSTR] = { .min = { .i = 0 }, .max = { .i = 255 } },
},
.parm_gran = {},

Wyświetl plik

@ -24,8 +24,6 @@
* Version 2009.11.21 Larry Gadallah (VE6VQ)
*/
#include <hamlib/config.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
@ -33,7 +31,6 @@
#include "hamlib/rig.h"
#include "ar7030p.h"
#include "serial.h"
#include "idx_builtin.h"
#define AR7030P_MODES ( RIG_MODE_AM | \
@ -231,7 +228,7 @@ static struct ext_list *alloc_init_ext(const struct confparams *cfp)
}
#if 0 /* unused; re-enabled as needed. */
static struct ext_list *find_ext(struct ext_list *elp, token_t token)
static struct ext_list *find_ext(struct ext_list *elp, hamlib_token_t token)
{
int i;
@ -267,9 +264,9 @@ static int ar7030p_init(RIG *rig)
{
int i;
rig->state.priv = (void *) priv;
STATE(rig)->priv = (void *) priv;
rig->state.rigport.type.rig = RIG_PORT_SERIAL;
RIGPORT(rig)->type.rig = RIG_PORT_SERIAL;
priv->powerstat = RIG_POWER_ON;
priv->bank = 0;
@ -330,12 +327,14 @@ static int ar7030p_init(RIG *rig)
static int ar7030p_cleanup(RIG *rig)
{
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) rig->state.priv;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) STATE(rig)->priv;
int rc = RIG_OK;
int i;
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
if (priv == NULL) { return RIG_OK; }
for (i = 0; i < NB_CHAN; i++)
{
free(priv->mem[ i ].ext_levels);
@ -346,12 +345,9 @@ static int ar7030p_cleanup(RIG *rig)
free(priv->ext_parms);
if (NULL != rig->state.priv)
{
free(rig->state.priv);
}
free(STATE(rig)->priv);
rig->state.priv = NULL;
STATE(rig)->priv = NULL;
return (rc);
}
@ -367,8 +363,10 @@ static int ar7030p_open(RIG *rig)
{
int rc = RIG_OK;
unsigned char v;
struct rig_state *rs;
assert(NULL != rig);
rs = STATE(rig);
rc = lockRx(rig, LOCK_1);
@ -377,9 +375,9 @@ static int ar7030p_open(RIG *rig)
int i;
/* Load calibration table */
rig->state.str_cal.size = rig->caps->str_cal.size;
rs->str_cal.size = rig->caps->str_cal.size;
for (i = 0; i < rig->state.str_cal.size; i++)
for (i = 0; i < rs->str_cal.size; i++)
{
rc = readByte(rig, EEPROM1, SM_CAL + i, &v);
@ -388,12 +386,12 @@ static int ar7030p_open(RIG *rig)
break;
}
rig->state.str_cal.table[ i ].val = rig->caps->str_cal.table[ i ].val;
rig->state.str_cal.table[ i ].raw = (int) v;
rs->str_cal.table[ i ].val = rig->caps->str_cal.table[ i ].val;
rs->str_cal.table[ i ].raw = (int) v;
rig_debug(RIG_DEBUG_VERBOSE, "%s: index %d, val %d, raw %d\n",
__func__, i, rig->state.str_cal.table[ i ].val,
rig->state.str_cal.table[ i ].raw);
__func__, i, rs->str_cal.table[ i ].val,
rs->str_cal.table[ i ].raw);
}
if (RIG_OK == rc)
@ -431,6 +429,7 @@ static int ar7030p_open(RIG *rig)
*
* /return 0 on success, < 0 on failure
*/
// cppcheck-suppress *
static int ar7030p_close(RIG *rig)
{
assert(NULL != rig);
@ -486,7 +485,7 @@ static int ar7030p_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
if (RIG_OK == rc)
{
const struct rig_caps *caps = rig->caps;
struct rig_caps *caps = rig->caps;
if ((caps->rx_range_list1[ 0 ].endf > freq) &&
(caps->rx_range_list1[ 0 ].startf < freq))
@ -1223,7 +1222,7 @@ static int ar7030p_get_level(RIG *rig, vfo_t vfo, setting_t level,
static int ar7030p_set_vfo(RIG *rig, vfo_t vfo)
{
int rc = RIG_OK;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) rig->state.priv;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) STATE(rig)->priv;
switch (vfo)
{
@ -1267,7 +1266,8 @@ static int ar7030p_set_vfo(RIG *rig, vfo_t vfo)
static int ar7030p_get_vfo(RIG *rig, vfo_t *vfo)
{
int rc = RIG_OK;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) rig->state.priv;
struct ar7030p_priv_data const *priv = (struct ar7030p_priv_data *)
STATE(rig)->priv;
assert(NULL != vfo);
@ -1276,6 +1276,7 @@ static int ar7030p_get_vfo(RIG *rig, vfo_t *vfo)
return (rc);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_set_parm(RIG *rig, setting_t parm, value_t val)
{
int rc = -RIG_ENIMPL;
@ -1300,6 +1301,7 @@ static int ar7030p_set_parm(RIG *rig, setting_t parm, value_t val)
return (rc);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_get_parm(RIG *rig, setting_t parm, value_t *val)
{
int rc = -RIG_ENIMPL;
@ -1329,7 +1331,7 @@ static int ar7030p_set_mem(RIG *rig, vfo_t vfo, int ch)
{
int rc = RIG_OK;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) rig->state.priv;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) STATE(rig)->priv;
if (RIG_VFO_MEM == priv->curr_vfo)
{
@ -1349,8 +1351,9 @@ static int ar7030p_get_mem(RIG *rig, vfo_t vfo, int *ch)
{
int rc = RIG_OK;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *) rig->state.priv;
channel_t *curr = priv->curr;
struct ar7030p_priv_data const *priv = (struct ar7030p_priv_data *)
STATE(rig)->priv;
const channel_t *curr = priv->curr;
assert(NULL != ch);
@ -1388,6 +1391,7 @@ static int ar7030p_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op)
return (rc);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch)
{
int rc = -RIG_ENIMPL;
@ -1603,6 +1607,7 @@ static int ar7030p_reset(RIG *rig, reset_t reset)
return (rc);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_set_func(RIG *rig, vfo_t vfo, setting_t func,
int status)
{
@ -1611,15 +1616,18 @@ static int ar7030p_set_func(RIG *rig, vfo_t vfo, setting_t func,
return (-RIG_ENIMPL);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_get_func(RIG *rig, vfo_t vfo, setting_t func,
int *status)
{
assert(NULL != rig);
assert(NULL != status);
*status = 0;
return (-RIG_ENIMPL);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_decode_event(RIG *rig)
{
assert(NULL != rig);
@ -1627,6 +1635,7 @@ static int ar7030p_decode_event(RIG *rig)
return (-RIG_ENIMPL);
}
// cppcheck-suppress constParameterCallback
static int ar7030p_set_channel(RIG *rig, vfo_t vfo, const channel_t *chan)
{
assert(NULL != rig);
@ -1643,8 +1652,9 @@ static int ar7030p_get_channel(RIG *rig, vfo_t vfo, channel_t *chan,
unsigned int f;
unsigned char *p = NULL;
int ch;
struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *)rig->state.priv;
channel_t *curr = priv->curr;
const struct ar7030p_priv_data *priv = (struct ar7030p_priv_data *)
STATE(rig)->priv;
const channel_t *curr = priv->curr;
assert(NULL != chan);
@ -1673,7 +1683,6 @@ static int ar7030p_get_channel(RIG *rig, vfo_t vfo, channel_t *chan,
if (RIG_OK == rc)
{
// cppcheck-suppress *
chan->levels[ LVL_SQL ].f = (float) v / 255.0;
}
@ -1766,7 +1775,7 @@ static int ar7030p_get_channel(RIG *rig, vfo_t vfo, channel_t *chan,
return (rc);
}
const struct rig_caps ar7030p_caps =
struct rig_caps ar7030p_caps =
{
RIG_MODEL(RIG_MODEL_AR7030P),
.model_name = "AR7030 Plus",

Wyświetl plik

@ -31,7 +31,6 @@
#include <hamlib/rig.h>
#include "ar7030p.h"
#include "serial.h"
#include "idx_builtin.h"
static enum PAGE_e curPage = NONE; /* Current memory page */
static unsigned int curAddr = 65535; /* Current page address */
@ -57,7 +56,7 @@ int NOP(RIG *rig, unsigned char x)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -79,7 +78,7 @@ int SRH(RIG *rig, unsigned char x)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -109,7 +108,7 @@ int PGE(RIG *rig, enum PAGE_e page)
case EEPROM2:
case EEPROM3:
case ROM:
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -142,7 +141,7 @@ int ADR(RIG *rig, unsigned char x)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -164,7 +163,7 @@ int ADH(RIG *rig, unsigned char x)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -188,7 +187,7 @@ int WRD(RIG *rig, unsigned char out)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -211,7 +210,7 @@ int MSK(RIG *rig, unsigned char mask)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -249,7 +248,7 @@ int EXE(RIG *rig, enum ROUTINE_e routine)
case DISP_BUFF:
case READ_SIGNAL:
case READ_BTNS:
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -281,7 +280,7 @@ int RDD(RIG *rig, unsigned char len)
assert(NULL != rig);
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -289,7 +288,7 @@ int RDD(RIG *rig, unsigned char len)
}
else
{
rc = read_block(&rig->state.rigport, (char *) &inChr, len);
rc = read_block(RIGPORT(rig), (char *) &inChr, len);
if (1 != rc)
{
@ -322,7 +321,7 @@ int LOC(RIG *rig, enum LOCK_LVL_e level)
case LOCK_1:
case LOCK_2:
case LOCK_3:
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -367,7 +366,7 @@ int BUT(RIG *rig, enum BUTTON_e button)
case BTN_STAR:
case BTN_MENU:
case BTN_POWER:
rc = write_block(&rig->state.rigport, (char *) &op, 1);
rc = write_block(RIGPORT(rig), (char *) &op, 1);
if (0 != rc)
{
@ -404,7 +403,7 @@ int execRoutine(RIG *rig, enum ROUTINE_e rtn)
assert(NULL != rig);
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(RIGPORT(rig), &v, 1))
{
rc = RIG_OK;
@ -429,6 +428,7 @@ int execRoutine(RIG *rig, enum ROUTINE_e rtn)
static int setAddr(RIG *rig, enum PAGE_e page, unsigned int addr)
{
int rc = RIG_OK;
hamlib_port_t *rp = RIGPORT(rig);
unsigned char v;
assert(NULL != rig);
@ -441,7 +441,7 @@ static int setAddr(RIG *rig, enum PAGE_e page, unsigned int addr)
{
v = PGE(page);
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(rp, &v, 1))
{
curPage = page;
rc = RIG_OK;
@ -458,7 +458,7 @@ static int setAddr(RIG *rig, enum PAGE_e page, unsigned int addr)
{
v = SRH((0x0f0 & addr) >> 4);
rc = write_block(&rig->state.rigport, &v, 1);
rc = write_block(rp, &v, 1);
if (rc != RIG_OK)
{
@ -467,13 +467,13 @@ static int setAddr(RIG *rig, enum PAGE_e page, unsigned int addr)
v = ADR((0x00f & addr));
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(rp, &v, 1))
{
if (0xff < addr)
{
v = ADH((0xf00 & addr) >> 8);
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(rp, &v, 1))
{
curAddr = addr;
rc = RIG_OK;
@ -526,6 +526,7 @@ static int setAddr(RIG *rig, enum PAGE_e page, unsigned int addr)
int writeByte(RIG *rig, enum PAGE_e page, unsigned int addr, unsigned char x)
{
int rc;
hamlib_port_t *rp = RIGPORT(rig);
unsigned char hi = SRH((x & 0xf0) >> 4);
unsigned char lo = WRD(x & 0x0f);
@ -537,9 +538,9 @@ int writeByte(RIG *rig, enum PAGE_e page, unsigned int addr, unsigned char x)
{
rc = -RIG_EIO;
if (0 == write_block(&rig->state.rigport, &hi, 1))
if (0 == write_block(rp, &hi, 1))
{
if (0 == write_block(&rig->state.rigport, &lo, 1))
if (0 == write_block(rp, &lo, 1))
{
rc = RIG_OK;
curAddr++;
@ -668,6 +669,7 @@ int writeInt(RIG *rig, enum PAGE_e page, unsigned int addr, unsigned int x)
int readByte(RIG *rig, enum PAGE_e page, unsigned int addr, unsigned char *x)
{
int rc = RIG_OK;
hamlib_port_t *rp = RIGPORT(rig);
unsigned char v = RDD(1); // Read command
assert(NULL != rig);
@ -679,9 +681,9 @@ int readByte(RIG *rig, enum PAGE_e page, unsigned int addr, unsigned char *x)
{
rc = -RIG_EIO;
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(rp, &v, 1))
{
if (1 == read_block(&rig->state.rigport, x, 1))
if (1 == read_block(rp, x, 1))
{
curAddr++;
rc = RIG_OK;
@ -842,7 +844,7 @@ int readSignal(RIG *rig, unsigned char *x)
if (RIG_OK == rc)
{
if (1 == read_block(&rig->state.rigport, x, 1))
if (1 == read_block(RIGPORT(rig), x, 1))
{
rc = RIG_OK;
@ -868,7 +870,7 @@ int flushBuffer(RIG *rig)
assert(NULL != rig);
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(RIGPORT(rig), &v, 1))
{
rc = RIG_OK;
}
@ -897,7 +899,7 @@ int lockRx(RIG *rig, enum LOCK_LVL_e level)
{
v = LOC(level);
if (0 == write_block(&rig->state.rigport, &v, 1))
if (0 == write_block(RIGPORT(rig), &v, 1))
{
rc = RIG_OK;
@ -985,27 +987,29 @@ int getCalLevel(RIG *rig, unsigned char rawAgc, int *dbm)
int raw = (int) rawAgc;
int step;
unsigned char v;
struct rig_state *rs;
assert(NULL != rig);
assert(NULL != dbm);
rs = STATE(rig);
rig_debug(RIG_DEBUG_VERBOSE, "%s: raw AGC %03d\n", __func__, rawAgc);
for (i = 0; i < rig->state.str_cal.size; i++)
for (i = 0; i < rs->str_cal.size; i++)
{
*dbm = rig->state.str_cal.table[ i ].val;
*dbm = rs->str_cal.table[ i ].val;
rig_debug(RIG_DEBUG_VERBOSE, "%s: got cal table[ %d ] dBm value %d\n", __func__,
i, *dbm);
/* if the remaining difference in the raw value is negative */
if (0 > (raw - rig->state.str_cal.table[ i ].raw))
if (0 > (raw - rs->str_cal.table[ i ].raw))
{
/* calculate step size */
if (0 < i)
{
step = rig->state.str_cal.table[ i ].val -
rig->state.str_cal.table[ i - 1 ].val;
step = rs->str_cal.table[ i ].val -
rs->str_cal.table[ i - 1 ].val;
}
else
{
@ -1016,7 +1020,7 @@ int getCalLevel(RIG *rig, unsigned char rawAgc, int *dbm)
/* interpolate the final value */
*dbm -= step; /* HACK - table seems to be off by one index */
*dbm += (int)(((double) raw / (double) rig->state.str_cal.table[ i ].raw) *
*dbm += (int)(((double) raw / (double) rs->str_cal.table[ i ].raw) *
(double) step);
rig_debug(RIG_DEBUG_VERBOSE, "%s: interpolated dBm value %d\n", __func__, *dbm);
@ -1027,7 +1031,7 @@ int getCalLevel(RIG *rig, unsigned char rawAgc, int *dbm)
else
{
/* calculate the remaining raw value */
raw = raw - rig->state.str_cal.table[ i ].raw;
raw = raw - rs->str_cal.table[ i ].raw;
rig_debug(RIG_DEBUG_VERBOSE, "%s: residual raw value %d\n", __func__, raw);
}

Wyświetl plik

@ -19,8 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
#include <hamlib/rig.h>
@ -62,7 +60,7 @@ static const struct aor_priv_caps ar8000_priv_caps =
*
* part of info from http://www.aoruk.com/8000.htm
*/
const struct rig_caps ar8000_caps =
struct rig_caps ar8000_caps =
{
RIG_MODEL(RIG_MODEL_AR8000),
.model_name = "AR8000",

Wyświetl plik

@ -19,8 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
#include <hamlib/rig.h>
@ -86,14 +84,14 @@ static const struct aor_priv_caps ar8k_priv_caps =
*
* part of info from http://www.aoruk.com/8200.htm
*/
const struct rig_caps ar8200_caps =
struct rig_caps ar8200_caps =
{
RIG_MODEL(RIG_MODEL_AR8200),
.model_name = "AR8200",
.mfg_name = "AOR",
.version = BACKEND_VER ".0",
.copyright = "LGPL",
.status = RIG_STATUS_BETA,
.status = RIG_STATUS_STABLE,
.rig_type = RIG_TYPE_SCANNER,
.ptt_type = RIG_PTT_NONE,
.dcd_type = RIG_DCD_RIG,

Wyświetl plik

@ -19,8 +19,6 @@
*
*/
#include <hamlib/config.h>
#include <stdlib.h>
#include <hamlib/rig.h>
@ -88,7 +86,7 @@ static const struct aor_priv_caps ar8600_priv_caps =
*
* part of info from http://www.aoruk.com/8600.htm
*/
const struct rig_caps ar8600_caps =
struct rig_caps ar8600_caps =
{
RIG_MODEL(RIG_MODEL_AR8600),
.model_name = "AR8600",

Some files were not shown because too many files have changed in this diff Show More