hamlib-cvs-digest Mailing List for Ham Radio Control Libraries (Page 9)
Library to control radio transceivers and receivers
Brought to you by:
n0nb
You can subscribe to this list here.
2000 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(57) |
Nov
(27) |
Dec
(25) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2001 |
Jan
(41) |
Feb
(101) |
Mar
(60) |
Apr
(32) |
May
(32) |
Jun
(198) |
Jul
(95) |
Aug
(60) |
Sep
(48) |
Oct
(96) |
Nov
(27) |
Dec
(222) |
2002 |
Jan
(180) |
Feb
(46) |
Mar
(68) |
Apr
(11) |
May
(36) |
Jun
(34) |
Jul
(113) |
Aug
(42) |
Sep
(71) |
Oct
(65) |
Nov
(116) |
Dec
(40) |
2003 |
Jan
(32) |
Feb
(92) |
Mar
(29) |
Apr
(102) |
May
(21) |
Jun
(34) |
Jul
(3) |
Aug
(60) |
Sep
(30) |
Oct
(62) |
Nov
(57) |
Dec
(33) |
2004 |
Jan
(28) |
Feb
(46) |
Mar
(16) |
Apr
(14) |
May
(31) |
Jun
(21) |
Jul
(10) |
Aug
(80) |
Sep
(42) |
Oct
(11) |
Nov
(28) |
Dec
(13) |
2005 |
Jan
(35) |
Feb
(26) |
Mar
(20) |
Apr
(118) |
May
(2) |
Jun
(5) |
Jul
|
Aug
|
Sep
(5) |
Oct
(1) |
Nov
(13) |
Dec
(1) |
2006 |
Jan
(9) |
Feb
(25) |
Mar
(22) |
Apr
(6) |
May
|
Jun
|
Jul
(2) |
Aug
(1) |
Sep
(3) |
Oct
(46) |
Nov
(13) |
Dec
(7) |
2007 |
Jan
(9) |
Feb
(14) |
Mar
(3) |
Apr
|
May
(6) |
Jun
(1) |
Jul
|
Aug
(11) |
Sep
(7) |
Oct
(8) |
Nov
(41) |
Dec
(3) |
2008 |
Jan
(27) |
Feb
(16) |
Mar
(13) |
Apr
(23) |
May
(39) |
Jun
(4) |
Jul
(7) |
Aug
(1) |
Sep
(13) |
Oct
(52) |
Nov
(44) |
Dec
(55) |
2009 |
Jan
(72) |
Feb
(69) |
Mar
|
Apr
|
May
|
Jun
(13) |
Jul
(1) |
Aug
(6) |
Sep
(15) |
Oct
(11) |
Nov
(31) |
Dec
(20) |
2010 |
Jan
(24) |
Feb
(21) |
Mar
(22) |
Apr
(40) |
May
(38) |
Jun
(4) |
Jul
(2) |
Aug
(22) |
Sep
(19) |
Oct
(14) |
Nov
(5) |
Dec
(8) |
2011 |
Jan
(14) |
Feb
(36) |
Mar
(6) |
Apr
|
May
|
Jun
(23) |
Jul
(13) |
Aug
(8) |
Sep
(7) |
Oct
|
Nov
(3) |
Dec
(9) |
2012 |
Jan
(17) |
Feb
(13) |
Mar
(10) |
Apr
|
May
(1) |
Jun
(14) |
Jul
(4) |
Aug
(12) |
Sep
(2) |
Oct
(24) |
Nov
(14) |
Dec
(2) |
2013 |
Jan
(4) |
Feb
(3) |
Mar
(3) |
Apr
(3) |
May
(10) |
Jun
(4) |
Jul
(7) |
Aug
|
Sep
(15) |
Oct
(5) |
Nov
(1) |
Dec
(2) |
2014 |
Jan
|
Feb
(8) |
Mar
(1) |
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
(1) |
Sep
(3) |
Oct
(7) |
Nov
(6) |
Dec
(3) |
2015 |
Jan
(4) |
Feb
(5) |
Mar
(8) |
Apr
(8) |
May
(2) |
Jun
|
Jul
(4) |
Aug
(7) |
Sep
(8) |
Oct
|
Nov
(6) |
Dec
(4) |
2016 |
Jan
(6) |
Feb
(26) |
Mar
(3) |
Apr
(10) |
May
(6) |
Jun
(5) |
Jul
(1) |
Aug
(4) |
Sep
(3) |
Oct
(4) |
Nov
(3) |
Dec
(10) |
2017 |
Jan
(11) |
Feb
(11) |
Mar
(2) |
Apr
(1) |
May
(7) |
Jun
(2) |
Jul
(11) |
Aug
(9) |
Sep
(5) |
Oct
(5) |
Nov
(1) |
Dec
(2) |
2018 |
Jan
(5) |
Feb
(2) |
Mar
(19) |
Apr
(7) |
May
(11) |
Jun
(3) |
Jul
(4) |
Aug
(10) |
Sep
(2) |
Oct
(8) |
Nov
(6) |
Dec
(9) |
2019 |
Jan
(9) |
Feb
(6) |
Mar
(2) |
Apr
(4) |
May
(6) |
Jun
(9) |
Jul
(6) |
Aug
(3) |
Sep
(5) |
Oct
(2) |
Nov
(8) |
Dec
(9) |
2020 |
Jan
(15) |
Feb
(1) |
Mar
(18) |
Apr
(33) |
May
(43) |
Jun
(87) |
Jul
(45) |
Aug
(8) |
Sep
(43) |
Oct
(3) |
Nov
(5) |
Dec
(42) |
2021 |
Jan
(116) |
Feb
(40) |
Mar
(58) |
Apr
(48) |
May
(29) |
Jun
(2) |
Jul
|
Aug
(22) |
Sep
(18) |
Oct
(1) |
Nov
|
Dec
(3) |
2022 |
Jan
(1) |
Feb
(1) |
Mar
|
Apr
(1) |
May
(2) |
Jun
(1) |
Jul
|
Aug
(1) |
Sep
|
Oct
(6) |
Nov
(2) |
Dec
(9) |
2023 |
Jan
(10) |
Feb
|
Mar
|
Apr
(10) |
May
(3) |
Jun
(1) |
Jul
(2) |
Aug
(4) |
Sep
(1) |
Oct
|
Nov
(2) |
Dec
(3) |
2024 |
Jan
(4) |
Feb
(1) |
Mar
(2) |
Apr
(2) |
May
(5) |
Jun
(3) |
Jul
(1) |
Aug
(2) |
Sep
|
Oct
(2) |
Nov
(3) |
Dec
(9) |
2025 |
Jan
(5) |
Feb
(5) |
Mar
|
Apr
(10) |
May
(20) |
Jun
(43) |
Jul
(24) |
Aug
(17) |
Sep
|
Oct
|
Nov
|
Dec
|
From: n0nb <n0...@us...> - 2022-12-08 20:43:01
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 7b7a0460edfcef8afe1ef7f5b5b0f3e109751926 (commit) via 299f1de2f93d8ca778c104221de7e9cfd6b7ee1f (commit) via c103d55effdf77b52ef0527e6aea3fdf7adca82b (commit) via b5e258228e3559ff615768c1d148676279144512 (commit) via 2fc6344d546d456f4d4749ebe18159a3baf17e93 (commit) via 22af811d5ff3fe7260d54044ce748a1963547499 (commit) via 6a80385f8bc2658b1f29aa5cb32d3ea1b60c82a3 (commit) via 5f634df53843d1e5235b067c0470993952e99cac (commit) via dae50c7a953fb6b1ba5a0a091eb508b28c9a2aa6 (commit) via 40d1bad1e144feacdbe229af8afd9e36173b25de (commit) via e3487cb5c6330243cf8cf7f0081e5b4b74c1becc (commit) via e603da4cb6cbc2d540bb29591c5a141b9a226ef2 (commit) via ea1a718bb52339a8f5f9c582d083bc9ac5448063 (commit) via 156b810319cfeaefdbbf0f4e78090be7bc0d4a61 (commit) via a2b3e1348c374c6e2ef555636704471eb4d813e3 (commit) via 825fc07d0007b6b5661c255a08d76badd3765513 (commit) via fdd88c317e56131099a5de73b72727868c3bde3e (commit) via 1e1ed4c9e61f08e4022e2b3ce1a2e196c6958ba3 (commit) via d3d1fd7c40b916e912469a5d51afc3a3f04b9ad8 (commit) via 20caf608acd01f0162032240bfed3412163f83e5 (commit) via 827ae18f2e3cce61a95974394eee7428dd465ecb (commit) via 4fe9f5918d9b41fffcaabb1d78abea273b8dce4e (commit) via 560afb9de2841cc8d76e608437af2b6cd3aaf000 (commit) via a9de174335f86ab3db9bd2199b44ee871f522baa (commit) via aaab26686a2b44d4a273c8d2239f3ced0867ce6b (commit) via 57f6c863c6b3b2062a23ffbd1c120fb3ce448d3e (commit) via 545811a9786ba5b9ae1b3d7fb8b7051cd9e98b9a (commit) via 2b145fe71770c079ee6b7bae047d5ff51d9321ca (commit) via 3e01e7e9a7b7c013403ea2c6ddb3186950f07ebf (commit) via 13538c38e0db9d7046ee07ed98b790237c0901ec (commit) via cb72a054eaafaf6a4e7309078790cb4be713dc52 (commit) via 01706287ff1fc6481ae3eda65faba57d091dc691 (commit) via 1102dede64ac324af7e98f0895612773e3608d89 (commit) via be499866b9b97b24416366eb609eedc041ebb8b4 (commit) via 887aeae114739af812e1e12b24f771ea31b0e6e3 (commit) via ed3d7ed32382cbfb41a1f293d9283cdea7e239ca (commit) via c9ec1adc9f972c85056bf7c6e51f839f0d473082 (commit) via e46da0c86ed6350f52ea5b8b16f6e0c1bc9138b1 (commit) via b504d251070b3356f93583197ebb58b85e29c4e9 (commit) via 84b4620a94a4ff6e37619bf52f12c4145fa625d9 (commit) via 3112c2f9e05dc57f606f96c4593944c2edae1ae7 (commit) via 54bfba3c14e74d8e9eaf5426a1094d7d853bdb84 (commit) via 033cc8a192646e753f4e8a9516f5bf0601a82787 (commit) via 72701a9032e024a506e4e54f8860ecdabe112681 (commit) via 479d7a080aa56c381049921b9c58c0c387bd84c2 (commit) via bb7d3cbad40f7ab55dc88d59ac9b9632d379837e (commit) via 20233b92c0f03e819298145e2b063f2336bc8f93 (commit) via b90afcb438245c7351851f091518fd6d6eb52896 (commit) via 9c3405465cbe4a98454bac7dab622e90199ee7c7 (commit) via dc7e9bd7e9f2174f9ee245672000c97a84077fbe (commit) via a116cbe5025e8cc0f499c8616f5e47e1c729905c (commit) via a400539d09df8fa4bf20051469b93f29d3f18198 (commit) via c6b11728c9b4424109bd66aecdd91531bdfe6914 (commit) via ea11358379abae2a524950d29480fd8b3658daa4 (commit) via 526b1853b6a6c7fa32bee11e5fc502dc609d75b2 (commit) via e2570d9d49b5f07da22d2877fc4a10b68c4dd25e (commit) via 09fb0818475bbc72a609ddf4316c125a689822a1 (commit) via c5a83b1652d00cee5cdfdf472a87ba440b7009da (commit) via b4a6f985247a2289dee8554d27f89132feeb1781 (commit) via 3e6ca76c31a9a4f2e9e76d16899bd8090c9f2555 (commit) via 39a78a4af7b8eed216a97ed3a9aa4a1920f30d04 (commit) via 4d7db63b975ae5a3e3f0f216659f52395c2fce56 (commit) via 72e86bf18bf0d22da1c01e1c64043c4cf11cf8fd (commit) via f81c20eb378c14ab405389d13e48530aebbdce43 (commit) via ce1932fb9ac26dcc289adcece33756e547142f23 (commit) via 66d0dc9a5de100875d269c6c397bb4ae66c3f1c9 (commit) via 8b75fc8ea6231ba95c469e681412296d25d0f101 (commit) via 16826c5a88c371870332997fe4f5101b8871aa79 (commit) via 5957b8697d7e56a34f806435c9bb50c082c352e9 (commit) via 9824ff6bf0ccf153c7f48a4f4e670c224e0b25fe (commit) via d8fcb16a589959a52aa6b3e39dee2b4c30aca632 (commit) via 7368609a76728af32f7686fb472289d4fe4ce1f7 (commit) via c932468a11091d5a532fa1c0b24af64cd4c7ae6c (commit) via 340045384d9141f6ce428cfc31246540e722df67 (commit) via 427ca8d90f8252998f59e42e41ba1ec0ef7387ca (commit) via 3ce5718a655b2cc3c7c21d6ae4524afe0a95d7fb (commit) via 09e73b2ec9b2b624e33cdd19a25072616fa69e0f (commit) via 6995986880f9a1f3b788ec4c147ebca6f06173c5 (commit) via 58f2549a994062c5e3b3f68e93f349ef8e6cdfd8 (commit) via a0711bfa715faf6985a232c2caee423d94f7e1d7 (commit) via af6d4d03e365ace65bb544c614d988740a26de63 (commit) via 5d7f69572717b89d62cc2844ba20cc419eb7203f (commit) via f8a5b92bc7d84bca1319c78c21a7048a9ad2f395 (commit) via ca4814c4722b361e329a5e3ad59cc7b29fab8c2f (commit) via 1ef3549e9405b782caa8c32f9f13488035f60f0c (commit) via 93d3a9e213c56a41b67232c6ca2ec3e39a9e6a8c (commit) via 6679eaf8bff191b2d8826359498b5efc5039b347 (commit) via edcbd17612813103f931a882e3c767156448addf (commit) via 508eef31f913cfd6530c85ac9a8566a0d941bd24 (commit) via e3a1d8c96c80eeae321edb3c9cf60e75fb4acccf (commit) via 7068378a915662904a1c6a4aa0f81e7107af181e (commit) via 09f83cbfb7b2be5909dfa329e0c7d20ad253a694 (commit) via 2c384ece6b3f6b474ffe2154b2d30ad97f426049 (commit) via 0bacb35f06b5d8a0677491879e8f6d5fb8769fa1 (commit) via b133b90419e0a161b933829b45aaec59281fb7fa (commit) via 3c273c001af1357afe6c23b64b29f80e23fde823 (commit) via 37a40eabf2b8b61070dd16453eddcf8829f40e6a (commit) via 8193d9cedaa0bb771a0acf5f24dc9bdbbdb79a19 (commit) via 8cffaf387530950794d367519933aa34d4215dd5 (commit) via e55f43a0273f679cbf0ea5c63adf66c01ff4f4b9 (commit) via 1a4745a7c21b5e55653540e8a003f2ad0cee6d9f (commit) via 25ac6d77d663861aa3c293c155267ad629de1e3b (commit) via 6c5e0e69748e0261b0b064870c41e1f54a99855c (commit) via 2b487fe718ace903697a85718e4ffc3995d25df8 (commit) via 31e40d2751f519a7e77d570b3aeebfa069186db9 (commit) via a20c21aab023e23396f0f2ac380207aa7c9d0dbe (commit) via 6b41f0738fe627e86c1b758f3c65005a59a42efb (commit) via 99627855a20a1c61781f5c3cc148efa8c0b5f1c4 (commit) via a29e89cf939cbdd3de33d90ac7b8df83bc788373 (commit) via 1e68b06b53829221567792276f7de335991331f5 (commit) via d7edd89a12be134a904d0a3d5fc3e4f68f111c16 (commit) via 1aebee2da9d29ff1d1a16e19f23bbff4e0f319a8 (commit) via 5fa3d59810f7310e5e0d0e3447c4be083d39496d (commit) via 4f5bf9aaddb3ef4b0a92daafee63641c67e293ef (commit) via 1ea7241bbf297736cf465da1d3c25051a28e93c0 (commit) via a563c749f4a582ca43624e8d1d4113a2314057c6 (commit) via 20ce6004485ae1d8910ff032cd9d826f8933a795 (commit) via ae0f7f423776a644befae3bac8c854905bb64292 (commit) via d8caad3d1b609aef97a4c2bb821f3ff77999d3ba (commit) via 7bcf599afc47c791da994042ad785dbee08026d7 (commit) via 4bede074fc0e1b5ca0fb22c1e8f348e6e4118580 (commit) via 8533002f8e5e6943afe810ebd6aed818470c37ae (commit) via 2aaa05b96735b5db65a1ed9a1c6a16b5b4657398 (commit) via ba065466230196cfebd5081956a492b74b17e7f5 (commit) via 5a5fc68922a56ce9f6c8b2138f06acd55e19dc67 (commit) via 5164c1c366714ed46659718b4890372b4e334f20 (commit) via 8616be635ee36b01774a2235009b5f8a6eb90cdc (commit) via cc3d912a76cd80bebcbf3509d885754d10e7ec38 (commit) via c168a99c832d53227233915e041e615ef5375c03 (commit) via 60a6170545d5f63a754df4435ab65c5094fbbec2 (commit) via c844b02ed11e38b8b423352fd99ab0ece2c3f8cd (commit) via d7ab03957329b991a4f248dcac437ecf8d804ae6 (commit) via 42f65cc5fb8a486f001027c452c29645ed4cd1cc (commit) via 782e54e4f2aa92418f4eca42a242c41e90f3d934 (commit) from 9a6d4d761249c553ef71093754213ca72e94eeb9 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 7b7a0460edfcef8afe1ef7f5b5b0f3e109751926 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 11:39:22 2022 -0600 Bump .Net verison to 7.0 for multicast testing diff --git a/bindings/csharp/multicast/multicast.csproj b/bindings/csharp/multicast/multicast.csproj index f3006615..d08b4c72 100644 --- a/bindings/csharp/multicast/multicast.csproj +++ b/bindings/csharp/multicast/multicast.csproj @@ -2,7 +2,7 @@ <PropertyGroup> <OutputType>Exe</OutputType> - <TargetFramework>net5.0</TargetFramework> + <TargetFramework>net7.0</TargetFramework> </PropertyGroup> <ItemGroup> commit 299f1de2f93d8ca778c104221de7e9cfd6b7ee1f Merge: b5e25822 c103d55e Author: Michael Black <mdb...@ya...> Date: Thu Dec 8 10:10:26 2022 -0600 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 commit c103d55effdf77b52ef0527e6aea3fdf7adca82b Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu Dec 8 15:26:53 2022 +0000 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] <su...@gi...> diff --git a/bindings/csharp/multicast/multicast.csproj b/bindings/csharp/multicast/multicast.csproj index e7a76d33..f3006615 100644 --- a/bindings/csharp/multicast/multicast.csproj +++ b/bindings/csharp/multicast/multicast.csproj @@ -6,7 +6,7 @@ </PropertyGroup> <ItemGroup> - <PackageReference Include="Newtonsoft.Json" Version="13.0.1" /> + <PackageReference Include="Newtonsoft.Json" Version="13.0.2" /> </ItemGroup> </Project> ----------------------------------------------------------------------- Summary of changes: .github/codeql-analysis.yml | 6 +- .github/workflows/codeql-analysis.yml | 6 +- NEWS | 15 +- astyle.sh | 1 + bindings/csharp/multicast/multicast.csproj | 4 +- configure.ac | 3 +- doc/man1/rigctl.1 | 11 + include/hamlib/rig.h | 37 +- include/hamlib/riglist.h | 7 + include/hamlib/rotlist.h | 4 +- rigs/adat/adt_200a.c | 1 + rigs/adat/adt_200a.h | 14 + rigs/alinco/dx77.c | 18 +- rigs/alinco/dxsr8.c | 2 +- rigs/aor/aor.c | 4 +- rigs/dummy/dummy.c | 7 +- rigs/dummy/flrig.c | 22 +- rigs/dummy/netrigctl.c | 39 +- rigs/dummy/netrotctl.c | 105 +++--- rigs/dummy/tci1x.c | 1 + rigs/dummy/trxmanager.c | 1 + rigs/flexradio/sdr1k.c | 6 +- rigs/gomspace/gs100.c | 8 +- rigs/icom/Makefile.am | 2 +- rigs/icom/ic7000.c | 4 +- rigs/icom/ic703.c | 4 +- rigs/icom/ic706.c | 16 +- rigs/icom/ic7100.c | 4 +- rigs/icom/ic718.c | 4 +- rigs/icom/ic7200.c | 4 +- rigs/icom/ic7410.c | 4 +- rigs/icom/ic746.c | 8 +- rigs/icom/ic751.c | 4 +- rigs/icom/ic756.c | 16 +- rigs/icom/ic7600.c | 4 +- rigs/icom/ic7610.c | 2 +- rigs/icom/ic765.c | 11 +- rigs/icom/ic7700.c | 4 +- rigs/icom/ic78.c | 4 +- rigs/icom/ic7800.c | 4 +- rigs/icom/ic781.c | 9 +- rigs/icom/ic785x.c | 2 +- rigs/icom/ic910.c | 20 +- rigs/icom/ic9100.c | 7 +- rigs/icom/ic92d.c | 4 +- rigs/icom/icom.c | 9 +- rigs/icom/icom.h | 5 +- rigs/icom/icr10.c | 4 +- rigs/icom/icr20.c | 4 +- rigs/icom/icr6.c | 6 +- rigs/icom/icr75.c | 4 +- rigs/icom/icr8500.c | 4 +- rigs/icom/icr8600.c | 2 +- rigs/icom/icr9000.c | 4 +- rigs/icom/icr9500.c | 4 +- rigs/icom/icrx7.c | 4 +- rigs/icom/id1.c | 8 +- rigs/icom/id31.c | 2 + rigs/icom/id4100.c | 2 + rigs/icom/id51.c | 2 + rigs/icom/id5100.c | 5 +- rigs/icom/level_gran_icom.h | 57 +++ rigs/icom/xiegu.c | 32 +- rigs/kenwood/Makefile.am | 2 +- rigs/kenwood/flex6xxx.c | 9 +- rigs/kenwood/k3.c | 5 +- rigs/kenwood/kenwood.c | 62 +++- rigs/kenwood/kenwood.h | 3 +- rigs/kenwood/level_gran_kenwood.h | 43 +++ rigs/kenwood/r5000.c | 4 +- rigs/kenwood/thd7.c | 12 +- rigs/kenwood/thd72.c | 11 +- rigs/kenwood/thd74.c | 7 +- rigs/kenwood/thf6a.c | 7 +- rigs/kenwood/thf7.c | 7 +- rigs/kenwood/thg71.c | 8 +- rigs/kenwood/tmd700.c | 9 +- rigs/kenwood/tmd710.c | 10 +- rigs/kenwood/tmv7.c | 11 +- rigs/kenwood/trc80.c | 5 +- rigs/kenwood/ts140.c | 4 +- rigs/kenwood/ts2000.c | 7 +- rigs/kenwood/ts440.c | 4 +- rigs/kenwood/ts450s.c | 5 +- rigs/kenwood/ts480.c | 42 ++- rigs/kenwood/ts50s.c | 9 +- rigs/kenwood/ts570.c | 20 +- rigs/kenwood/ts590.c | 6 + rigs/kenwood/ts680.c | 4 +- rigs/kenwood/ts690.c | 9 +- rigs/kenwood/ts711.c | 5 +- rigs/kenwood/ts790.c | 6 +- rigs/kenwood/ts811.c | 5 +- rigs/kenwood/ts850.c | 6 +- rigs/kenwood/ts870s.c | 11 +- rigs/kenwood/ts890s.c | 214 ++++++++++- rigs/kenwood/ts930.c | 10 +- rigs/kenwood/ts940.c | 1 + rigs/kenwood/ts950.c | 23 +- rigs/kenwood/ts990s.c | 11 +- rigs/kenwood/tx500.c | 4 +- rigs/kenwood/xg3.c | 9 + rigs/kit/fifisdr.c | 2 +- rigs/kit/miniVNA.c | 15 +- rigs/kit/rs_hfiq.c | 22 +- rigs/mds/4710.c | 93 +++++ rigs/mds/9710.c | 94 +++++ {rotators/ars => rigs/mds}/Android.mk | 4 +- rigs/mds/Makefile.am | 6 + rigs/mds/mds.c | 565 +++++++++++++++++++++++++++++ rigs/mds/mds.h | 28 ++ rigs/rs/ek89x.c | 6 + rigs/rs/xk2100.c | 6 + rigs/skanti/trp8000.c | 2 +- rigs/tapr/dsp10.c | 4 +- rigs/tentec/argonaut.c | 27 +- rigs/tentec/jupiter.c | 25 +- rigs/tentec/rx350.c | 27 +- rigs/tentec/tentec2.h | 1 + rigs/winradio/g313-posix.c | 2 +- rigs/winradio/g313-win.c | 4 +- rigs/winradio/winradio.c | 2 + rigs/yaesu/Makefile.am | 2 +- rigs/yaesu/YaesuTargetableVFO.ods | Bin 3800 -> 20521 bytes rigs/yaesu/frg100.c | 12 +- rigs/yaesu/frg8800.c | 4 + rigs/yaesu/frg9600.c | 4 + rigs/yaesu/ft100.c | 7 +- rigs/yaesu/ft1000d.c | 6 +- rigs/yaesu/ft1000mp.c | 12 + rigs/yaesu/ft1200.c | 8 +- rigs/yaesu/ft1200.h | 2 +- rigs/yaesu/ft2000.c | 6 +- rigs/yaesu/ft2000.h | 2 +- rigs/yaesu/ft3000.c | 5 +- rigs/yaesu/ft450.c | 6 +- rigs/yaesu/ft5000.c | 8 +- rigs/yaesu/ft5000.h | 2 +- rigs/yaesu/ft600.c | 11 +- rigs/yaesu/ft710.c | 10 +- rigs/yaesu/ft736.c | 13 +- rigs/yaesu/ft747.c | 4 + rigs/yaesu/ft757gx.c | 14 +- rigs/yaesu/ft767gx.c | 8 +- rigs/yaesu/ft817.c | 10 +- rigs/yaesu/ft840.c | 4 + rigs/yaesu/ft847.c | 25 +- rigs/yaesu/ft857.c | 6 +- rigs/yaesu/ft890.c | 4 + rigs/yaesu/ft891.c | 6 +- rigs/yaesu/ft897.c | 12 +- rigs/yaesu/ft900.c | 4 + rigs/yaesu/ft9000.c | 9 +- rigs/yaesu/ft9000.h | 2 +- rigs/yaesu/ft920.c | 4 + rigs/yaesu/ft950.c | 7 +- rigs/yaesu/ft950.h | 2 +- rigs/yaesu/ft980.h | 4 + rigs/yaesu/ft990.c | 4 + rigs/yaesu/ft991.c | 44 +-- rigs/yaesu/ft991.h | 2 +- rigs/yaesu/ftdx10.c | 10 +- rigs/yaesu/ftdx101.c | 10 +- rigs/yaesu/ftdx101mp.c | 6 +- rigs/yaesu/level_gran_yaesu.h | 42 +++ rigs/yaesu/newcat.c | 219 +++++++---- rigs/yaesu/newcat.h | 2 +- rigs/yaesu/vr5000.c | 4 + rigs/yaesu/vx1700.c | 1 - rigs/yaesu/yaesu.h | 1 + simulators/simft818.c | 2 + simulators/simftdx3000.c | 15 +- simulators/simicom.c | 1 + simulators/simicom9700.c | 27 +- simulators/simkenwood.c | 2 +- simulators/simpowersdr.c | 15 +- simulators/simyaesu.c | 3 +- src/iofunc.c | 13 +- src/mem.c | 15 +- src/misc.c | 2 + src/register.c | 4 +- src/rig.c | 263 +++++++++++++- src/serial.c | 4 + src/sprintflst.c | 60 +++ src/sprintflst.h | 1 + tests/ampctl_parse.c | 1 + tests/dumpcaps.c | 125 ++++--- tests/memcsv.c | 2 + tests/rigctl.c | 3 +- tests/rigctl_parse.c | 136 ++++++- tests/rigctlcom.c | 97 ++++- tests/rigctld.c | 4 +- tests/rotctl_parse.c | 33 +- tests/sendraw.c | 38 ++ tests/testcaps.sh | 12 + tests/testrig.c | 10 +- 196 files changed, 2998 insertions(+), 666 deletions(-) create mode 100755 astyle.sh create mode 100644 rigs/icom/level_gran_icom.h create mode 100644 rigs/kenwood/level_gran_kenwood.h create mode 100644 rigs/mds/4710.c create mode 100644 rigs/mds/9710.c copy {rotators/ars => rigs/mds}/Android.mk (81%) create mode 100644 rigs/mds/Makefile.am create mode 100644 rigs/mds/mds.c create mode 100644 rigs/mds/mds.h create mode 100644 rigs/yaesu/level_gran_yaesu.h create mode 100644 tests/sendraw.c create mode 100755 tests/testcaps.sh hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-12-08 16:47:30
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The annotated tag, 4.5.1 has been created at 4504d86bec77ec0cbaa3aabf0e093cb6597a2ad9 (tag) tagging 75fbd097b1508e0a29b80206e193fd45a9a332cf (commit) replaces 4.5 tagged by Nate Bargmann on Thu Dec 8 10:44:04 2022 -0600 - Log ----------------------------------------------------------------- Hamlib 4.5.1 release -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQSC1k9rDmfNQfaJu6b7LFEw1VqIGQUCY5IUdQAKCRD7LFEw1VqI GTxGAKCid+a39lgEr/GG0umzfv7cnXtrwQCePkAKJ0b9C3aXXGvmHzgsS3aYa/A= =Qay3 -----END PGP SIGNATURE----- Michael Black (7): Merge pull request #1137 from PianetaRadio/master Merge pull request #1148 from PianetaRadio/master Merge pull request #1161 from mdblack98/master Merge pull request #1166 from PianetaRadio/master Merge pull request #1167 from PianetaRadio/master Merge pull request #1169 from PianetaRadio/master Merge pull request #1175 from PianetaRadio/master Mike Black W9MDB (136): Add ability to enter terminator char for W send_cmd_rx so one can do 'W FA; ;' without a timeout needed Merge branch 'master' of https://github.com/Hamlib/Hamlib Update NEWS Fix space in string compare in flrig.c https://github.com/Hamlib/Hamlib/issues/1134 Small update to newcat.c notes Add RIG_LEVEL_USB_AF for IC-705, IC-7300, IC-9700, IC-785x, and IC-R8600 In combination with RIG_LEVEL_RF we should be able to create an AGC control for WSJTX and JTDX for example to keep audio levels within a good A/D range automagically https://github.com/Hamlib/Hamlib/issues/1135 Update simicom9700.c Fix LEVEL_USB_AF https://github.com/Hamlib/Hamlib/issues/1135 Remove debug from misc.c IC7300 cannot get powerstat so use get_freq instead. There are likely more Icom rigs like this Add AGC_OFF to IC7300 agc levels Add simft747gx.c Add AGC_TIME to IC-7300, IC-9700, and IC-705 https://github.com/Hamlib/Hamlib/issues/1136 Update NEWS Fix flrig get_ptt https://github.com/Hamlib/Hamlib/issues/1138 Add ID 800 for FT710 Add RIG_FUNC_OVF_STATUS for IC-7300, IC-9700, IC-705, IC-R8600 Add RIG_LEVEL_KEYSPD to ts890s.c https://github.com/Hamlib/Hamlib/issues/1139 Fix dummy_set_split_freq Fix if_len in flex6xxx.c https://github.com/Hamlib/Hamlib/issues/1141 Update NEWS Fix IC-7300 rig power on hopefully https://github.com/Hamlib/Hamlib/issues/1142 Fix NEWS Fix segfault in icom_get_powerstat Update simicom9700.c Fix 5W level of ftdx10.c based on user testing Improve README.md by adding github and sourceforge info Add RIG_FUNC_TUNER to flrig.c Update ftdx10.h power levels Fix FT-991 level_gran https://github.com/Hamlib/Hamlib/issues/1144 Fix rotctld dumpcaps to expose client rot_type instead of Other Fix rotctld dumpcaps to expose client rot_type instead of Other https://github.com/Hamlib/Hamlib/issues/1035 Merge branch 'master' of https://github.com/Hamlib/Hamlib Fix new protocol in rotctl functions to duplicate logic in rigctl new protocol https://github.com/Hamlib/Hamlib/issues/1035 Move rotctl south_zero to new dump protocol section for backwards compatibility https://github.com/Hamlib/Hamlib/issues/1035 Fix backwards compatibility of rotctl with rotctld https://github.com/Hamlib/Hamlib/issues/1035 Fix dumpcap level_gran for Yaesu rigs Update Makefile.am for Yaesu to include level_gran_yaesu.h Fix all Icom level_gran values Fix readonly set_level in flex6xxx.c Fix level_gran on kenwood rigs https://github.com/Hamlib/Hamlib/issues/1035 Fix dummy ptt_type when ptt_type is specified on command line for rigctl and rigctld https://github.com/Hamlib/Hamlib/issues/888 Add missing level_gran_kenwood.h https://github.com/Hamlib/Hamlib/issues/1035 Fix segfault with ptt_type --- seems to be constant on LHS so can't set it Update simicom9700.c Update level_gran_yaesu.h Fix some dumpcaps warnings in many rigs Merge branch 'master' of https://github.com/Hamlib/Hamlib Fix clang warning on callback functions https://github.com/Hamlib/Hamlib/issues/1149 Fix memcsv.c https://github.com/Hamlib/Hamlib/issues/1149 Add MDS 4710 rig Update NEWS Add mds.h to mds/Makefile.am Clean up rest of dumpcap backend warnings Fix duplicate MODES in g313-win.c ser_open now sets rts and dtr low on startup https://github.com/Hamlib/Hamlib/issues/1131 Move ser_set_rts/dtr to beggining of serial_setup https://github.com/Hamlib/Hamlib/issues/1131 Update astyle formatting Fix dumpcaps filter printout to only show valid filters https://github.com/Hamlib/Hamlib/issues/1151 Split MDS 4710/9710 Add astyle.sh to format all .c files Change minimum timeout on all Kenwood rigs to 500ms -- legacy timeouts were a touch too short for all situations Update NEWS Correct NEWS Fix Xiegu X6100 rig split https://github.com/Hamlib/Hamlib/issues/1152 Update NEWS Make kenwood a bit more robust to discern between no reply and corrupted/unexpected reply This logic should be usable to use AI mode eventually or share serial splitter line Improve debug a bit in rig.c so show model and remove unnecessary debug Change MDS 4710/9710 to Alpha status -- no testing has been done yet Add data mode and targetable freq/mode to Xiegu X6100 https://github.com/Hamlib/Hamlib/issues/1154 Update icom.h data https://github.com/Hamlib/Hamlib/issues/1154 Add set_mode_with_data and get_mode_with_data to Xiegu G90 Fix rig_send_raw to return bytes read, fill buffer, and also work with fixed length response/null terminator https://github.com/Hamlib/Hamlib/issues/1157 Update NEWS Add sendraw.c to test directory https://github.com/Hamlib/Hamlib/issues/1157 Fix rigctld showing the real rig agc_levels instead of all levels Fix display of RIG_AGC_OFF Add RIG_AGC_LONG Fix PowerSDR AGC values https://github.com/Hamlib/Hamlib/issues/1155 astyle files Add AGC levels to ts2000.c and fix AGC Level printout to show index number instead of enumeration number. Add RIG_AGC_LONG and RIG_AGC_ON levels to match rig's capabilities better Still need to allow setting AGC level using mnemonics instead of level value to make it more usable Add AGC levels to Kenwood rigs that we can verify have them https://github.com/Hamlib/Hamlib/milestone/16 Add send_raw to rigctl Fix send_raw and add some debug to it https://github.com/Hamlib/Hamlib/issues/1157 Change rigctl send_raw to also require terminator https://github.com/Hamlib/Hamlib/issues/1157 Change rigctl_powerstat message to only show when powerstat shows off and promote to error Remove misc.h dependency from testrig.h For FT736 fix set_vfo to also work for VFOB and set split when VFOB is requested https://github.com/Hamlib/Hamlib/issues/1160 For FT736 add TARGETABLE_MODE and fix set_mode to work with VFOB https://github.com/Hamlib/Hamlib/issues/1160 Update codeql due to deprecation Merge branch 'master' of https://github.com/Hamlib/Hamlib Update NEWS Update github actions for deprecation Remove accidental commit Fix compilation warning on fifisdr.c Fix 32-bit compile warning in sprintflst.c Fix mingw64 warnings Fix send_raw for Windows https://github.com/Hamlib/Hamlib/issues/1157 Astyle files Fix logic in dummy.c Fix rx_range_list2 problem in dx77.x Fix duplicate targetable_vfo in xiegu.c Fix frequency check in k3.c Fix range list in mds.c Fix compiler warnings Fix k3.c math.h Fix misc TS890S items -- thanks to George Baltz N3GB Update NEWS Astyle newcat.c Re-enable O_NDELAY -- slowed things down by about 2X https://github.com/Hamlib/Hamlib/issues/1163 Update NEWS Fix newcat check for passband nochange https://github.com/Hamlib/Hamlib/issues/1163 Balance the ELAPSED functions Add netrigctl_send_raw to allow send_raw to work with rigctld https://github.com/Hamlib/Hamlib/issues/1157 astyle newcat.c Change FT991 write_delay to 5ms -- was seeing many serial errors with 0ms https://github.com/Hamlib/Hamlib/issues/1163 Add SM and KS commands to rigctlcom to work better with DXCommander https://github.com/Hamlib/Hamlib/issues/1170 If mode for VFOB is requested but rig does not have TARGETABLE_MODE then just return VFOA mode https://github.com/Hamlib/Hamlib/issues/1172 Reduce FT991 write_delay to 2ms and post_write_delay to 0ms This works with CAT TOT = 10ms at 38,400 baud https://github.com/Hamlib/Hamlib/issues/1163 For the FT991 change write_delay=0 and post_write_delay=2 https://github.com/Hamlib/Hamlib/issues/1163 Force the FT-991 to 100ms along with FT-DX2000, Ft-891, FT950, FTDX3000/D 10ms was seeing timeouts on some rigs using rigctl https://github.com/Hamlib/Hamlib/issues/1163 Update NEWS Fix ID for FT991 and FT991 in newcat.c so CAT TOT settings work https://github.com/Hamlib/Hamlib/issues/1163 Add secondary check for rig_model in newcat.c for CAT TOT in case ID command fails https://github.com/Hamlib/Hamlib/issues/1163 Change CAT TOT command in newcat.c to expect a response https://github.com/Hamlib/Hamlib/issues/1163 If rig does not have TARGETABLE_MODE then we return the cached values from VFOA https://github.com/Hamlib/Hamlib/issues/1172 Add RIG_TARGETABLE_MODE to ts890.c https://github.com/Hamlib/Hamlib/issues/1172 Fix Jupiter set_freq problem -- was messing up strlen due to binary format https://github.com/Hamlib/Hamlib/issues/1174 Merge branch 'master' of https://github.com/Hamlib/Hamlib Fix spelling error in rig.c Update simftdx3000.c Add missing calibration tables for TS890S Merge remote-tracking branch 'origin/master' into Hamlib-4.5.1 Revert "Fix range list in mds.c" Revert "Change MDS 4710/9710 to Alpha status -- no testing has been done yet" Revert "Split MDS 4710/9710" Revert "Add mds.h to mds/Makefile.am" Revert "Add MDS 4710 rig" Remove 9710.c Nate Bargmann (1): Advance configure.ac to 4.6~git PianetaRadio (30): Update netrotctl.c Update ft991.c Update newcat.c Update ft991.c Merge branch 'Hamlib:master' into master Update ft991.c Update newcat.c Added RIG_FUNC_NB2 get/send func Added RIG_FUNC_NB2 Update newcat version NB2 NB2 NB2 NB2 NB2 NB2 NB2 NB2 Update targetable_vfo NB2 Update targetable_vfo Update targetable_vfo Update targetable_vfo Update targetable_vfo Update targetable_vfo Update newcat.c Update newcat.c Update Merge branch 'Hamlib:master' into master Merge branch 'Hamlib:master' into master ----------------------------------------------------------------------- hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: n0nb <n0...@us...> - 2022-12-08 16:46:57
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, Hamlib-4.5.1 has been created at 75fbd097b1508e0a29b80206e193fd45a9a332cf (commit) - Log ----------------------------------------------------------------- commit 75fbd097b1508e0a29b80206e193fd45a9a332cf Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:11:46 2022 -0600 Remove 9710.c diff --git a/rigs/mds/9710.c b/rigs/mds/9710.c deleted file mode 100644 index 0f6bd72f..00000000 --- a/rigs/mds/9710.c +++ /dev/null @@ -1,91 +0,0 @@ -#include "mds.h" - -const struct rig_caps mds_9710_caps = -{ - RIG_MODEL(RIG_MODEL_MDS9710), - .model_name = "9710", - .mfg_name = "MDS", - .version = "20221116.0", - .copyright = "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 = 110, - .serial_rate_max = 38400, - .serial_data_bits = 8, - .serial_stop_bits = 1, - .serial_parity = RIG_PARITY_NONE, - .serial_handshake = RIG_HANDSHAKE_HARDWARE, - .write_delay = 0, - .post_write_delay = 0, - .timeout = 1000, - .retry = 3, - - .has_get_func = RIG_FUNC_NONE, - .has_set_func = RIG_FUNC_NONE, - .has_get_level = MDS_LEVELS, - .has_set_level = RIG_LEVEL_NONE, - .has_get_parm = RIG_PARM_NONE, - .has_set_parm = RIG_PARM_NONE, -// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, -// .ctcss_list = common_ctcss_list, -// .dcs_list = full_dcs_list, -// 2050 does have channels...not implemented yet as no need yet -// .chan_list = { -// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, -// { 19, 19, RIG_MTYPE_CALL }, -// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, -// RIG_CHAN_END, -// }, -// .scan_ops = DUMMY_SCAN, -// .vfo_ops = DUMMY_VFO_OP, - .transceive = RIG_TRN_RIG, - .rx_range_list1 = { - { - .startf = MHz(800), .endf = MHz(880), .modes = MDS_ALL_MODES, - .startf = MHz(880), .endf = MHz(960), .modes = MDS_ALL_MODES, - .low_power = 0, .high_power = 0, MDS_ALL_MODES, RIG_ANT_1, - }, - RIG_FRNG_END, - }, - .rx_range_list2 = {RIG_FRNG_END,}, - .tx_range_list1 = { - {MHz(380), MHz(530), MDS_ALL_MODES, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE}, - RIG_FRNG_END, - }, -// .tx_range_list2 = {RIG_FRNG_END,} - .tuning_steps = { - // Rem: no support for changing tuning step - {MDS_ALL_MODES, 6250}, - RIG_TS_END, - }, - - .filters = { - {MDS_ALL_MODES, RIG_FLT_ANY}, - RIG_FLT_END - }, - .priv = NULL, - - .rig_init = mds_init, - .rig_open = mds_open, - .rig_cleanup = mds_cleanup, - -// .set_conf = dummy_set_conf, -// .get_conf = dummy_get_conf, - - .set_freq = mds_set_freq, - .get_freq = mds_get_freq, -// .set_mode = mds_set_mode, -// .get_mode = mds_get_mode, - -// .set_level = dummy_set_level, -// .get_level = mds_get_level, - - .get_info = mds_get_info, - .set_ptt = mds_set_ptt, - .get_ptt = mds_get_ptt, -// .get_dcd = dummy_get_dcd, - .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS -}; commit 9a1ea33d0e254bf89100dc47cc74bc8ab9698ed4 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:08:50 2022 -0600 Revert "Add MDS 4710 rig" This reverts commit 1e68b06b53829221567792276f7de335991331f5. diff --git a/configure.ac b/configure.ac index d6c9f11b..c92e77cc 100644 --- a/configure.ac +++ b/configure.ac @@ -47,7 +47,7 @@ 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" +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" 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" # Amplifiers are all in the amplifiers directory AMP_BACKEND_LIST="amplifiers/elecraft amplifiers/gemini" @@ -879,7 +879,6 @@ rigs/winradio/Makefile rigs/wj/Makefile rigs/yaesu/Makefile rigs/gomspace/Makefile -rigs/mds/Makefile tests/Makefile scripts/Makefile android/Makefile diff --git a/include/hamlib/riglist.h b/include/hamlib/riglist.h index fd7a1d93..a6843224 100644 --- a/include/hamlib/riglist.h +++ b/include/hamlib/riglist.h @@ -659,12 +659,6 @@ #define RIG_MODEL_GS100 RIG_MAKE_MODEL(RIG_GOMSPACE, 1) //! @endcond -/* - * MDS Microwave Data Systems https://en.wikipedia.org/wiki/Microwave_Data_Systems - */ -#define RIG_MDS 36 -#define RIG_BACKEND_MDS "MDS" -#define RIG_MODEL_MDS4710 RIG_MAKE_MODEL(RIG_MDS, 1) /* * TODO: RIG_MODEL_KWZ30, KNEISNER +DOERING diff --git a/rigs/mds/Android.mk b/rigs/mds/Android.mk deleted file mode 100644 index 1de62734..00000000 --- a/rigs/mds/Android.mk +++ /dev/null @@ -1,12 +0,0 @@ -LOCAL_PATH:= $(call my-dir) - -include $(CLEAR_VARS) - -LOCAL_SRC_FILES := mds.c -LOCAL_MODULE := mds - -LOCAL_CFLAGS := -LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) - -include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/mds/Makefile.am b/rigs/mds/Makefile.am deleted file mode 100644 index ca478dde..00000000 --- a/rigs/mds/Makefile.am +++ /dev/null @@ -1,6 +0,0 @@ -MDSSRC = mds.c - -noinst_LTLIBRARIES = libhamlib-mds.la -libhamlib_mds_la_SOURCES = $(MDSSRC) - -EXTRA_DIST = Android.mk diff --git a/rigs/mds/mds.c b/rigs/mds/mds.c deleted file mode 100644 index e2a9e1ef..00000000 --- a/rigs/mds/mds.c +++ /dev/null @@ -1,660 +0,0 @@ -/* - * Hamlib MDS 4710/9710 backend - main file - * Copyright (c) 2022 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 <hamlib/config.h> - -#include <stdio.h> -#include <stdlib.h> -#include <string.h> - -#include <hamlib/rig.h> -#include "serial.h" -#include "misc.h" -#include "cal.h" -#include "token.h" -#include "register.h" - -#include "mds.h" - -#define MAXCMDLEN 32 - -#define MDS_VFOS (RIG_VFO_A) - -#define MDS_MODES (RIG_MODE_NONE) - -#define MDS_LEVELS (RIG_LEVEL_NONE) - - -const struct rig_caps mds_caps; - -DECLARE_INITRIG_BACKEND(mds) -{ - rig_debug(RIG_DEBUG_VERBOSE, "%s: _init called\n", __func__); - - rig_register(&mds_caps); - rig_debug(RIG_DEBUG_VERBOSE, "%s: _init back from rig_register\n", __func__); - - return RIG_OK; -} - -int mds_transaction(RIG *rig, char *cmd, int expected, char **result) -{ - char cmd_buf[MAXCMDLEN]; - int retval; - struct rig_state *rs = &rig->state; - struct mds_priv_data *priv = rig->state.priv; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: cmd=%s\n", __func__, cmd); - - SNPRINTF(cmd_buf, sizeof(cmd_buf), "%s\n", cmd); - - rig_flush(&rs->rigport); - retval = write_block(&rs->rigport, (unsigned char *) cmd_buf, strlen(cmd_buf)); - - if (retval < 0) - { - return retval; - } - - if (expected == 0) - { - return RIG_OK; - } - else - { - char cmdtrm_str[2]; /* Default Command/Reply termination char */ - cmdtrm_str[0] = 0x0d; - cmdtrm_str[1] = 0x00; - retval = read_string(&rs->rigport, (unsigned char *) priv->ret_data, - sizeof(priv->ret_data), cmdtrm_str, strlen(cmdtrm_str), 0, expected); - - if (retval < 0) - { - rig_debug(RIG_DEBUG_ERR, "%s(%d): error in read_block\n", __func__, __LINE__); - return retval; - } - } - - if (result != NULL) - { - rig_debug(RIG_DEBUG_VERBOSE, "%s: setting result\n", __func__); - *result = &(priv->ret_data[0]); - } - else - { - rig_debug(RIG_DEBUG_VERBOSE, "%s: no result requested\n", __func__); - } - - return RIG_OK; -} - -int mds_init(RIG *rig) -{ - rig_debug(RIG_DEBUG_VERBOSE, "%s version %s\n", __func__, rig->caps->version); - // cppcheck claims leak here but it's freed in cleanup - rig->state.priv = (struct mds_priv_data *)calloc(1, - sizeof(struct mds_priv_data)); - - if (!rig->state.priv) - { - return -RIG_ENOMEM; - } - - return RIG_OK; -} - -/* - * mds_cleanup - * - */ - -int mds_cleanup(RIG *rig) -{ - - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); - - if (!rig) - { - return -RIG_EINVAL; - } - - if (rig->state.priv) - { - free(rig->state.priv); - } - - rig->state.priv = NULL; - - return RIG_OK; -} - -/* - * mds_get_freq - * Assumes rig!=NULL, rig->state.priv!=NULL, freq!=NULL - */ -int mds_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) -{ - int retval; - char *response = NULL; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s\n", __func__, rig_strvfo(vfo)); - *freq = 0; - - retval = mds_transaction(rig, "TX", 16, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_ERR, "%s: invalid response=%s\n", __func__, response); - return retval; - } - - retval = sscanf(response, "%lg", freq); - - if (retval != 1) - { - rig_debug(RIG_DEBUG_ERR, "%s: Unable to parse response\n", __func__); - return -RIG_EPROTO; - } - - return RIG_OK; -} - -// TC command does not work on 4050 -- not implemented as of 2022-01-12 -/* - * mds_set_freq - * assumes rig!=NULL, rig->state.priv!=NULL - */ -int mds_set_freq(RIG *rig, vfo_t vfo, freq_t freq) -{ - char cmd_buf[MAXCMDLEN]; - int retval; - freq_t tfreq; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s freq=%.0f\n", __func__, - rig_strvfo(vfo), freq); - - retval = rig_get_freq(rig, vfo, &tfreq); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_VERBOSE, "%s: get_freq failed: %s\n", __func__, - strerror(retval)); - return retval; - } - - if (tfreq == freq) - { - rig_debug(RIG_DEBUG_VERBOSE, "%s: freq not changing\n", __func__); - return RIG_OK; - } - - // If we are not explicitly asking for VFO_B then we'll set the receive side also - if (vfo != RIG_VFO_B) - { - char *response = NULL; - SNPRINTF((char *) cmd_buf, sizeof(cmd_buf), "TX%.4f", freq / 1e6); - retval = mds_transaction(rig, cmd_buf, 0, &response); - - if (retval < 0) - { - rig_debug(RIG_DEBUG_ERR, "%s: TX failed\n", __func__); - return retval; - } - - SNPRINTF((char *) cmd_buf, sizeof(cmd_buf), "RX%.4f", freq / 1e6); - retval = mds_transaction(rig, cmd_buf, 0, &response); - - if (retval < 0) - { - rig_debug(RIG_DEBUG_ERR, "%s: RX failed\n", __func__); - return retval; - } - } - - return RIG_OK; -} - -/* - * mds_set_ptt - * Assumes rig!=NULL - */ -int mds_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) -{ - int retval; - char cmd_buf[MAXCMDLEN]; - char *response = NULL; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: ptt=%d\n", __func__, ptt); - - SNPRINTF(cmd_buf, sizeof(cmd_buf), "%s", ptt ? "KEY" : "DKEY"); - retval = mds_transaction(rig, cmd_buf, 0, &response); - - if (retval < 0) - { - rig_debug(RIG_DEBUG_ERR, "%s: invalid response=%s\n", __func__, response); - return retval; - } - - if (strncmp(response, "OK", 2) != 0) - { - rig_debug(RIG_DEBUG_ERR, "%s: Expected OK, got '%s'\n", __func__, response); - return -RIG_EINVAL; - } - - rig_debug(RIG_DEBUG_VERBOSE, "%s: cmd:IP result=%s\n", __func__, response); - - return RIG_OK; -} - -/* - * mds_get_ptt - * Assumes rig!=NULL - */ -int mds_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt) -{ - int retval; - char *response = NULL; - char c; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s\n", __func__, rig_strvfo(vfo)); - - retval = mds_transaction(rig, "IP", 0, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_ERR, "%s: error response?='%s'\n", __func__, response); - return retval; - } - - c = response[0]; - - if (c == '1' || c == '0') - { - *ptt = c - '0'; - } - else - { - rig_debug(RIG_DEBUG_ERR, "%s: error response='%s'\n", __func__, response); - return -RIG_EPROTO; - } - - return RIG_OK; -} - -/* - * mds_set_mode - * Assumes rig!=NULL - * Note that 2050 does not have set or get width - */ -int mds_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) -{ - char cmd_buf[32], ttmode; - int retval; - rmode_t tmode; - pbwidth_t twidth; - - //struct tt588_priv_data *priv = (struct tt588_priv_data *) rig->state.priv; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s mode=%s width=%d\n", __func__, - rig_strvfo(vfo), rig_strrmode(mode), (int)width); - - retval = rig_get_mode(rig, vfo, &tmode, &twidth); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_ERR, "%s: get_mode failed %s\n", __func__, - strerror(retval)); - } - - if (tmode == mode) - { - rig_debug(RIG_DEBUG_VERBOSE, "%s: already mode %s so not changing\n", __func__, - rig_strrmode(mode)); - return RIG_OK; - } - - switch (mode) - { - case RIG_MODE_USB: - ttmode = 'U'; - break; - - case RIG_MODE_LSB: - ttmode = 'L'; - break; - - case RIG_MODE_CW: - ttmode = 'C'; - break; - - case RIG_MODE_AM: - ttmode = 'A'; - break; - - case RIG_MODE_RTTY: - ttmode = 'F'; - break; - - default: - rig_debug(RIG_DEBUG_ERR, "%s: unsupported mode %s\n", __func__, - rig_strrmode(mode)); - return -RIG_EINVAL; - } - - SNPRINTF((char *) cmd_buf, sizeof(cmd_buf), "TB%c\n", ttmode); - - retval = mds_transaction(rig, cmd_buf, 0, NULL); - - if (retval < 0) - { - return retval; - } - - return RIG_OK; -} - -/* - * mds_get_mode - * Assumes rig!=NULL - * Note that 2050 does not have set or get width - */ -int mds_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) -{ - char *result = NULL; - int retval; - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s\n", __func__, rig_strvfo(vfo)); - - retval = mds_transaction(rig, "IB", 0, &result); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_ERR, "%s: bad response=%s\n", __func__, result); - return retval; - } - - //dump_hex((unsigned char *)result,strlen(result)); - switch (result[1]) - { - case 'L': - *mode = RIG_MODE_LSB; - break; - - case 'U': - *mode = RIG_MODE_USB; - break; - - case 'A': - *mode = RIG_MODE_AM; - break; - - case 'F': - *mode = RIG_MODE_RTTY; - break; - - case 'C': - *mode = RIG_MODE_CW; - break; - - default: - rig_debug(RIG_DEBUG_ERR, "%s: Unknown mode='%c%c'\n", __func__, result[0], - result[1]); - return -RIG_EPROTO; - } - - *width = 3000; // we'll default this to 3000 for now - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s mode=%s width=%d\n", __func__, - rig_strvfo(vfo), rig_strrmode(*mode), (int)*width); - - return RIG_OK; -} - -#if 0 -int mds_get_vfo(RIG *rig, vfo_t *vfo) -{ - *vfo = RIG_VFO_A; - - if (check_vfo(*vfo) == FALSE) - { - rig_debug(RIG_DEBUG_ERR, "%s: unsupported VFO %s\n", __func__, - rig_strvfo(*vfo)); - return -RIG_EINVAL; - } - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s\n", __func__, rig_strvfo(*vfo)); - - return RIG_OK; -} -#endif - -/* - * mds_get_level - */ -int mds_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) -{ - int retval = 0; - char *response = NULL; - - switch (level) - { - int strength; - int n; - - case RIG_LEVEL_STRENGTH: - retval = mds_transaction(rig, "IAL", 0, &response); - - if (retval < 0) - { - rig_debug(RIG_DEBUG_ERR, "%s: invalid response=%s\n", __func__, - response); - return retval; - } - - n = sscanf(response, "%2d", &strength); - - if (n == 1) - { - val->i = strength; - } - else - { - rig_debug(RIG_DEBUG_ERR, "%s: unable to parse STRENGTH from %s\n", - __func__, response); - return -RIG_EPROTO; - } - - break; - - default: - rig_debug(RIG_DEBUG_ERR, "%s: unsupported level %s\n", __func__, - rig_strlevel(level)); - return -RIG_EINVAL; - } - - rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s level=%s val=%s\n", __func__, - rig_strvfo(vfo), rig_strlevel(level), response); - - return RIG_OK; -} - -/* - * mds_get_info - */ -const char *mds_get_info(RIG *rig) -{ - char *response = NULL; - int retval; - - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); - - retval = mds_transaction(rig, "MODEL", 16, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_WARN, "%s: MODEL command failed: %s\n", __func__, - strerror(retval)); - } - else - { - rig_debug(RIG_DEBUG_VERBOSE, "Model: %s\n", response); - } - - response = NULL; - retval = mds_transaction(rig, "SER", 16, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_WARN, "%s: SER command failed: %s\n", __func__, - strerror(retval)); - } - else - { - rig_debug(RIG_DEBUG_VERBOSE, "Serial# %s\n", response); - } - - response = NULL; - retval = mds_transaction(rig, "SREV", 16, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_WARN, "%s: SREV command failed: %s\n", __func__, - strerror(retval)); - } - else - { - rig_debug(RIG_DEBUG_VERBOSE, "Firmware %s\n", response); - } - - response = NULL; - retval = mds_transaction(rig, "SHOW DC", 16, &response); - - if (retval != RIG_OK) - { - rig_debug(RIG_DEBUG_ERR, "%s: SHOW DC failed result=%s\n", __func__, response); - } - else - { - rig_debug(RIG_DEBUG_VERBOSE, "DC %s\n", response); - } - - return response; -} - -int mds_open(RIG *rig) -{ - char *response = NULL; - int retval; - - ENTERFUNC; - mds_get_info(rig); - retval = mds_transaction(rig, "MODEM NONE", 0, &response); - retval = mds_transaction(rig, "PTT 0", 0, &response); - RETURNFUNC(retval); -} - -const struct rig_caps mds_caps = -{ - RIG_MODEL(RIG_MODEL_MDS4710), - .model_name = "4710", - .mfg_name = "MDS", - .version = "20221114.0", - .copyright = "LGPL", - .status = RIG_STATUS_BETA, - .rig_type = RIG_TYPE_TRANSCEIVER, -// .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, - .ptt_type = RIG_PTT_RIG, - .dcd_type = RIG_DCD_NONE, - .port_type = RIG_PORT_SERIAL, - .serial_rate_min = 110, - .serial_rate_max = 38400, - .serial_data_bits = 8, - .serial_stop_bits = 1, - .serial_parity = RIG_PARITY_NONE, - .serial_handshake = RIG_HANDSHAKE_HARDWARE, - .write_delay = 0, - .post_write_delay = 0, - .timeout = 1000, - .retry = 3, - - .has_get_func = RIG_FUNC_NONE, - .has_set_func = RIG_FUNC_NONE, - .has_get_level = MDS_LEVELS, - .has_set_level = RIG_LEVEL_NONE, - .has_get_parm = RIG_PARM_NONE, - .has_set_parm = RIG_PARM_NONE, -// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, -// .ctcss_list = common_ctcss_list, -// .dcs_list = full_dcs_list, -// 2050 does have channels...not implemented yet as no need yet -// .chan_list = { -// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, -// { 19, 19, RIG_MTYPE_CALL }, -// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, -// RIG_CHAN_END, -// }, -// .scan_ops = DUMMY_SCAN, -// .vfo_ops = DUMMY_VFO_OP, - .transceive = RIG_TRN_RIG, - .rx_range_list1 = { - { - .startf = MHz(380), .endf = MHz(530), .modes = RIG_MODE_ALL, - .low_power = 0, .high_power = 0, MDS_VFOS, RIG_ANT_1 - }, - RIG_FRNG_END, - }, - .rx_range_list2 = {RIG_FRNG_END,}, - .tx_range_list1 = { - {MHz(380), MHz(530), RIG_MODE_ALL, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE}, - RIG_FRNG_END, - }, -// .tx_range_list2 = {RIG_FRNG_END,} - .tuning_steps = { - // Rem: no support for changing tuning step - {RIG_MODE_ALL, 6250}, - RIG_TS_END, - }, - - .filters = { - {RIG_MODE_ALL, RIG_FLT_ANY}, - RIG_FLT_END - }, - .priv = NULL, - - .rig_init = mds_init, - .rig_open = mds_open, - .rig_cleanup = mds_cleanup, - -// .set_conf = dummy_set_conf, -// .get_conf = dummy_get_conf, - - .set_freq = mds_set_freq, - .get_freq = mds_get_freq, -// .set_mode = mds_set_mode, -// .get_mode = mds_get_mode, - -// .set_level = dummy_set_level, -// .get_level = mds_get_level, - - .get_info = mds_get_info, - .set_ptt = mds_set_ptt, - .get_ptt = mds_get_ptt, -// .get_dcd = dummy_get_dcd, - .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS -}; diff --git a/rigs/mds/mds.h b/rigs/mds/mds.h deleted file mode 100644 index b9d0cfce..00000000 --- a/rigs/mds/mds.h +++ /dev/null @@ -1,9 +0,0 @@ -#define MDS_DATA_LEN 256 -#define MDS_RET_LEN 256 -struct mds_priv_data { - char cmd_str[MDS_DATA_LEN]; /* command string buffer */ - char ret_data[MDS_RET_LEN]; /* returned data--max value, most are less */ -}; - -extern const struct rig_caps barrett_caps; - diff --git a/src/register.c b/src/register.c index d49f2b9f..c9aa4841 100644 --- a/src/register.c +++ b/src/register.c @@ -44,7 +44,7 @@ # define PATH_MAX 1024 #endif -#define RIG_BACKEND_MAX 50 +#define RIG_BACKEND_MAX 32 #define DEFINE_INITRIG_BACKEND(backend) \ int MAKE_VERSIONED_FN(PREFIX_INITRIG, ABI_VERSION, backend(void *be_handle)); \ @@ -89,7 +89,6 @@ DEFINE_INITRIG_BACKEND(barrett); DEFINE_INITRIG_BACKEND(elad); DEFINE_INITRIG_BACKEND(codan); DEFINE_INITRIG_BACKEND(gomspace); -DEFINE_INITRIG_BACKEND(mds); //! @endcond #ifdef HAVE_WINRADIO @@ -148,7 +147,6 @@ static struct { RIG_ELAD, RIG_BACKEND_ELAD, RIG_FUNCNAMA(elad) }, { RIG_CODAN, RIG_BACKEND_CODAN, RIG_FUNCNAMA(codan) }, { RIG_GOMSPACE, RIG_BACKEND_GOMSPACE, RIG_FUNCNAM(gomspace) }, - { RIG_MDS, RIG_BACKEND_MDS, RIG_FUNCNAMA(mds) }, { 0, NULL }, /* end */ }; commit bffec5b5284dc2e6e9a8097b842d8b587b8fd87f Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:08:05 2022 -0600 Revert "Add mds.h to mds/Makefile.am" This reverts commit 99627855a20a1c61781f5c3cc148efa8c0b5f1c4. diff --git a/rigs/mds/Makefile.am b/rigs/mds/Makefile.am index 12bfe7ee..ca478dde 100644 --- a/rigs/mds/Makefile.am +++ b/rigs/mds/Makefile.am @@ -1,4 +1,4 @@ -MDSSRC = mds.c mds.h +MDSSRC = mds.c noinst_LTLIBRARIES = libhamlib-mds.la libhamlib_mds_la_SOURCES = $(MDSSRC) commit 4b794bf08f0d6444efaa6e46968ef6939ab4aa9d Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:07:29 2022 -0600 Revert "Split MDS 4710/9710" This reverts commit 1a4745a7c21b5e55653540e8a003f2ad0cee6d9f. diff --git a/include/hamlib/riglist.h b/include/hamlib/riglist.h index 0850f5ed..fd7a1d93 100644 --- a/include/hamlib/riglist.h +++ b/include/hamlib/riglist.h @@ -665,7 +665,6 @@ #define RIG_MDS 36 #define RIG_BACKEND_MDS "MDS" #define RIG_MODEL_MDS4710 RIG_MAKE_MODEL(RIG_MDS, 1) -#define RIG_MODEL_MDS9710 RIG_MAKE_MODEL(RIG_MDS, 2) /* * TODO: RIG_MODEL_KWZ30, KNEISNER +DOERING diff --git a/rigs/mds/4710.c b/rigs/mds/4710.c deleted file mode 100644 index 8d3725e5..00000000 --- a/rigs/mds/4710.c +++ /dev/null @@ -1,93 +0,0 @@ -#include "mds.h" - -const struct rig_caps mds_4710_caps = -{ - RIG_MODEL(RIG_MODEL_MDS4710), - .model_name = "4710", - .mfg_name = "MDS", - .version = "20221114.0", - .copyright = "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 = 110, - .serial_rate_max = 38400, - .serial_data_bits = 8, - .serial_stop_bits = 1, - .serial_parity = RIG_PARITY_NONE, - .serial_handshake = RIG_HANDSHAKE_HARDWARE, - .write_delay = 0, - .post_write_delay = 0, - .timeout = 1000, - .retry = 3, - - .has_get_func = RIG_FUNC_NONE, - .has_set_func = RIG_FUNC_NONE, - .has_get_level = MDS_LEVELS, - .has_set_level = RIG_LEVEL_NONE, - .has_get_parm = RIG_PARM_NONE, - .has_set_parm = RIG_PARM_NONE, -// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, -// .ctcss_list = common_ctcss_list, -// .dcs_list = full_dcs_list, -// 2050 does have channels...not implemented yet as no need yet -// .chan_list = { -// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, -// { 19, 19, RIG_MTYPE_CALL }, -// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, -// RIG_CHAN_END, -// }, -// .scan_ops = DUMMY_SCAN, -// .vfo_ops = DUMMY_VFO_OP, - .transceive = RIG_TRN_RIG, - .rx_range_list1 = { - { - .startf = MHz(380), .endf = MHz(530), .modes = MDS_ALL_MODES, - .low_power = 0, .high_power = 0, MDS_VFOS, RIG_ANT_1, "USA" - }, - RIG_FRNG_END, - }, - .rx_range_list2 = {RIG_FRNG_END,}, - .tx_range_list1 = { - {MHz(380), MHz(400), MDS_ALL_MODES, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE, "USA"}, - {MHz(400), MHz(450), MDS_ALL_MODES, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE, "USA"}, - {MHz(450), MHz(512), MDS_ALL_MODES, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE, "USA"}, - {MHz(406), MHz(530), MDS_ALL_MODES, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE, "USA"}, - RIG_FRNG_END, - }, -// .tx_range_list2 = {RIG_FRNG_END,} - .tuning_steps = { - // Rem: no support for changing tuning step - {MDS_ALL_MODES, 6250}, - RIG_TS_END, - }, - - .filters = { - {MDS_ALL_MODES, RIG_FLT_ANY}, - RIG_FLT_END - }, - .priv = NULL, - - .rig_init = mds_init, - .rig_open = mds_open, - .rig_cleanup = mds_cleanup, - -// .set_conf = dummy_set_conf, -// .get_conf = dummy_get_conf, - - .set_freq = mds_set_freq, - .get_freq = mds_get_freq, -// .set_mode = mds_set_mode, -// .get_mode = mds_get_mode, - -// .set_level = dummy_set_level, -// .get_level = mds_get_level, - - .get_info = mds_get_info, - .set_ptt = mds_set_ptt, - .get_ptt = mds_get_ptt, -// .get_dcd = dummy_get_dcd, - .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS -}; diff --git a/rigs/mds/Makefile.am b/rigs/mds/Makefile.am index 20144ede..12bfe7ee 100644 --- a/rigs/mds/Makefile.am +++ b/rigs/mds/Makefile.am @@ -1,4 +1,4 @@ -MDSSRC = mds.c mds.h 4710.c 9710.c +MDSSRC = mds.c mds.h noinst_LTLIBRARIES = libhamlib-mds.la libhamlib_mds_la_SOURCES = $(MDSSRC) diff --git a/rigs/mds/mds.c b/rigs/mds/mds.c index 37f73c25..e2a9e1ef 100644 --- a/rigs/mds/mds.c +++ b/rigs/mds/mds.c @@ -35,15 +35,20 @@ #define MAXCMDLEN 32 -extern const struct rig_caps mds_4710_caps; -extern const struct rig_caps mds_9710_caps; +#define MDS_VFOS (RIG_VFO_A) + +#define MDS_MODES (RIG_MODE_NONE) + +#define MDS_LEVELS (RIG_LEVEL_NONE) + + +const struct rig_caps mds_caps; DECLARE_INITRIG_BACKEND(mds) { rig_debug(RIG_DEBUG_VERBOSE, "%s: _init called\n", __func__); - rig_register(&mds_4710_caps); - rig_register(&mds_9710_caps); + rig_register(&mds_caps); rig_debug(RIG_DEBUG_VERBOSE, "%s: _init back from rig_register\n", __func__); return RIG_OK; @@ -563,3 +568,93 @@ int mds_open(RIG *rig) retval = mds_transaction(rig, "PTT 0", 0, &response); RETURNFUNC(retval); } + +const struct rig_caps mds_caps = +{ + RIG_MODEL(RIG_MODEL_MDS4710), + .model_name = "4710", + .mfg_name = "MDS", + .version = "20221114.0", + .copyright = "LGPL", + .status = RIG_STATUS_BETA, + .rig_type = RIG_TYPE_TRANSCEIVER, +// .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, + .ptt_type = RIG_PTT_RIG, + .dcd_type = RIG_DCD_NONE, + .port_type = RIG_PORT_SERIAL, + .serial_rate_min = 110, + .serial_rate_max = 38400, + .serial_data_bits = 8, + .serial_stop_bits = 1, + .serial_parity = RIG_PARITY_NONE, + .serial_handshake = RIG_HANDSHAKE_HARDWARE, + .write_delay = 0, + .post_write_delay = 0, + .timeout = 1000, + .retry = 3, + + .has_get_func = RIG_FUNC_NONE, + .has_set_func = RIG_FUNC_NONE, + .has_get_level = MDS_LEVELS, + .has_set_level = RIG_LEVEL_NONE, + .has_get_parm = RIG_PARM_NONE, + .has_set_parm = RIG_PARM_NONE, +// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, +// .ctcss_list = common_ctcss_list, +// .dcs_list = full_dcs_list, +// 2050 does have channels...not implemented yet as no need yet +// .chan_list = { +// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, +// { 19, 19, RIG_MTYPE_CALL }, +// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, +// RIG_CHAN_END, +// }, +// .scan_ops = DUMMY_SCAN, +// .vfo_ops = DUMMY_VFO_OP, + .transceive = RIG_TRN_RIG, + .rx_range_list1 = { + { + .startf = MHz(380), .endf = MHz(530), .modes = RIG_MODE_ALL, + .low_power = 0, .high_power = 0, MDS_VFOS, RIG_ANT_1 + }, + RIG_FRNG_END, + }, + .rx_range_list2 = {RIG_FRNG_END,}, + .tx_range_list1 = { + {MHz(380), MHz(530), RIG_MODE_ALL, W(.1), W(5), RIG_VFO_A, RIG_ANT_NONE}, + RIG_FRNG_END, + }, +// .tx_range_list2 = {RIG_FRNG_END,} + .tuning_steps = { + // Rem: no support for changing tuning step + {RIG_MODE_ALL, 6250}, + RIG_TS_END, + }, + + .filters = { + {RIG_MODE_ALL, RIG_FLT_ANY}, + RIG_FLT_END + }, + .priv = NULL, + + .rig_init = mds_init, + .rig_open = mds_open, + .rig_cleanup = mds_cleanup, + +// .set_conf = dummy_set_conf, +// .get_conf = dummy_get_conf, + + .set_freq = mds_set_freq, + .get_freq = mds_get_freq, +// .set_mode = mds_set_mode, +// .get_mode = mds_get_mode, + +// .set_level = dummy_set_level, +// .get_level = mds_get_level, + + .get_info = mds_get_info, + .set_ptt = mds_set_ptt, + .get_ptt = mds_get_ptt, +// .get_dcd = dummy_get_dcd, + .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS +}; diff --git a/rigs/mds/mds.h b/rigs/mds/mds.h index 2b985eb8..b9d0cfce 100644 --- a/rigs/mds/mds.h +++ b/rigs/mds/mds.h @@ -1,28 +1,9 @@ -#include <hamlib/rig.h> - #define MDS_DATA_LEN 256 #define MDS_RET_LEN 256 - -#define MDS_VFOS (RIG_VFO_A) - -#define MDS_ALL_MODES (RIG_MODE_USB) - -#define MDS_LEVELS (RIG_LEVEL_NONE) - - struct mds_priv_data { char cmd_str[MDS_DATA_LEN]; /* command string buffer */ char ret_data[MDS_RET_LEN]; /* returned data--max value, most are less */ }; -extern const struct rig_caps mds_4710_caps; -extern const struct rig_caps mds_9710_caps; +extern const struct rig_caps barrett_caps; -int mds_init(RIG *rig); -int mds_open(RIG *rig); -int mds_cleanup(RIG *rig); -int mds_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt); -int mds_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt); -int mds_get_freq(RIG *rig, vfo_t vfo, freq_t *freq); -int mds_set_freq(RIG *rig, vfo_t vfo, freq_t freq); -const char *mds_get_info(RIG *rig); commit 6ad428e09180d5d6a79f39ad6e6ce0c649415e5b Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:01:55 2022 -0600 Revert "Change MDS 4710/9710 to Alpha status -- no testing has been done yet" This reverts commit 09f83cbfb7b2be5909dfa329e0c7d20ad253a694. diff --git a/rigs/mds/4710.c b/rigs/mds/4710.c index 879bf38a..8d3725e5 100644 --- a/rigs/mds/4710.c +++ b/rigs/mds/4710.c @@ -7,7 +7,7 @@ const struct rig_caps mds_4710_caps = .mfg_name = "MDS", .version = "20221114.0", .copyright = "LGPL", - .status = RIG_STATUS_ALPHA, + .status = RIG_STATUS_BETA, .rig_type = RIG_TYPE_TRANSCEIVER, .ptt_type = RIG_PTT_RIG, .dcd_type = RIG_DCD_NONE, diff --git a/rigs/mds/9710.c b/rigs/mds/9710.c index 5bd40740..0f6bd72f 100644 --- a/rigs/mds/9710.c +++ b/rigs/mds/9710.c @@ -7,7 +7,7 @@ const struct rig_caps mds_9710_caps = .mfg_name = "MDS", .version = "20221116.0", .copyright = "LGPL", - .status = RIG_STATUS_ALPHA, + .status = RIG_STATUS_BETA, .rig_type = RIG_TYPE_TRANSCEIVER, .ptt_type = RIG_PTT_RIG, .dcd_type = RIG_DCD_NONE, commit f1464f5a1ce9b1de39f6100690b4bb46daa226f9 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:01:44 2022 -0600 Revert "Fix range list in mds.c" This reverts commit b4a6f985247a2289dee8554d27f89132feeb1781. diff --git a/rigs/mds/9710.c b/rigs/mds/9710.c index f380dbc7..5bd40740 100644 --- a/rigs/mds/9710.c +++ b/rigs/mds/9710.c @@ -45,9 +45,6 @@ const struct rig_caps mds_9710_caps = .rx_range_list1 = { { .startf = MHz(800), .endf = MHz(880), .modes = MDS_ALL_MODES, - .low_power = 0, .high_power = 0, MDS_ALL_MODES, RIG_ANT_1, - }, - { .startf = MHz(880), .endf = MHz(960), .modes = MDS_ALL_MODES, .low_power = 0, .high_power = 0, MDS_ALL_MODES, RIG_ANT_1, }, commit 96134330391def67cac21be64a74e7e29efc708e Merge: 58f9fd41 b5e25822 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 8 09:00:38 2022 -0600 Merge remote-tracking branch 'origin/master' into Hamlib-4.5.1 diff --cc NEWS index 35dfca97,7fc4511d..70890f3c --- a/NEWS +++ b/NEWS @@@ -13,7 -13,33 +13,33 @@@ Version 5.x -- futur * Change FT1000MP Mark V model names to align with FT1000MP Version 4.6 - * 2023-XX-XX + * 2023-11-XX -- Planned for Nov 2023 + * Add MDS 4710/9710 rigs + + 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 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 + * Fix AGC Level dumpcaps on most rigs + * Fix rig_send_raw to return bytes read, fill buffer, and also work with fixed length response/null terminator + * Change all Kenwood rigs to 500ms serial timeout + * Fix dumpcaps filter printout to only show declared filters + * Fix triggering PTT on XGComms device on Linux + * Fix level_gran in all rigs + * Add RIG_FUNC_TUNER to flrig.c + * Fix FT-991 level_gran (needs to be done for lots of rigs) + * Fix man page rigctl to show units for LEVEL items + * Fix Flex6xxx if_len + * Fix FLRig set_ptt + * Fix missing KEYSPD to TS890 + * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; + * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF + * Add RIG_LEVEL_AGC_TIME to allow AGC/OFF to be set for IC-7300, IC-9700, IC-705 + * Add RIG_FUNC_OVF_STATUS to get overflow status for IC-7300, IC-9700, IC-705, and IC-R8600 + Version 4.5 * 2022-10-30 diff --cc configure.ac index 28908b58,866ebff4..d6c9f11b --- a/configure.ac +++ b/configure.ac @@@ -14,7 -14,7 +14,7 @@@ dnl Please do not use '-' in the versio 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.5],[ham...@li...],[hamlib],[http://www.hamlib.org]) -AC_INIT([Hamlib],[4.6~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) ++AC_INIT([Hamlib],[4.5.1],[ham...@li...],[hamlib],[http://www.hamlib.org]) AC_CONFIG_SRCDIR([include/hamlib/rig.h]) AC_CONFIG_MACRO_DIR([macros]) commit b5e258228e3559ff615768c1d148676279144512 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 7 15:30:38 2022 -0600 Add missing calibration tables for TS890S diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index d30217bd..9c23b131 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -24,6 +24,7 @@ #include <hamlib/rig.h> #include "kenwood.h" +#include "cal.h" // TODO: Copied from TS-480, to be verified #define TS890_VFO (RIG_VFO_A|RIG_VFO_B) @@ -37,7 +38,7 @@ // TODO: Copied from TS-480, to be verified #define TS890_LEVEL_SET (RIG_LEVEL_RFPOWER|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_AGC|RIG_LEVEL_KEYSPD|RIG_LEVEL_CWPITCH) -#define TS890_LEVEL_GET (RIG_LEVEL_RFPOWER|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_AGC|RIG_LEVEL_KEYSPD|RIG_LEVEL_ALC|RIG_LEVEL_SWR|RIG_LEVEL_COMP_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_TEMP_METER|RIG_LEVEL_CWPITCH) +#define TS890_LEVEL_GET (RIG_LEVEL_RFPOWER|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_AGC|RIG_LEVEL_KEYSPD|RIG_LEVEL_ALC|RIG_LEVEL_SWR|RIG_LEVEL_COMP_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_TEMP_METER|RIG_LEVEL_CWPITCH|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH) #define TS890_FUNC_ALL (RIG_FUNC_NB|RIG_FUNC_NB2|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_NR|RIG_FUNC_BC|RIG_FUNC_BC2|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_TUNER|RIG_FUNC_SEND_MORSE) #define TS890_VFO_OPS (RIG_OP_UP|RIG_OP_DOWN|RIG_OP_BAND_UP|RIG_OP_BAND_DOWN|RIG_OP_CPY|RIG_OP_TUNE) @@ -302,23 +303,17 @@ int kenwood_ts890_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) return retval; } - if (levelint < 0 || levelint >= 70) + if (rig->caps->swr_cal.size) { - val->f = 99.0; /* 99 == infinty */ + val->f = rig_raw2val_float(val->i, &rig->caps->swr_cal); } else { -#if 0 - val->f = 70.0 / (70 - levelint); -#else - /* Linear approximations of a very non-linear function */ if (levelint < 12) { val->f = 1.0 + (float)levelint / 22.0; } else if (levelint < 24) { val->f = 1.5 + (float)(levelint - 11) / 24.0; } else if (levelint < 36) { val->f = 2.0 + (float)(levelint - 23) / 12.0; } else { val->f = 3.0 + (float)(levelint - 35) / 6.0; } - -#endif } return RIG_OK; @@ -383,6 +378,50 @@ static struct kenwood_priv_caps ts890s_priv_caps = .cmdtrm = EOM_KEN, }; +/* S-meter calibration table + * The TS-890S has two distinct S-meter curves, selectable + * by menu option. Define both, but since Hamlib has only + * one slot, use the the IARU one. + * Values taken from TS-890S In-Depth Manual, p. 8 + */ +/* Meter Type 1 - Kenwood specific (default) */ +#define TS890_SM_CAL2 { 9, \ + { \ + { 0, -28 }, \ + { 3, -26 }, \ + { 11, -20 }, \ + { 19, -13 }, \ + { 27, -7 }, \ + { 35, 0 }, \ + { 48, 20 }, \ + { 59, 40 }, \ + { 70, 60 }, \ + } } +/* Meter Type 2 - IARU Standard */ +#define TS890_SM_CAL1 { 9, \ + { \ + { 0, -54 }, \ + { 3, -48 }, \ + { 11, -36 }, \ + { 19, -24 }, \ + { 27, -12 }, \ + { 35, 0 }, \ + { 48, 20 }, \ + { 59, 40 }, \ + { 70, 60 }, \ + } } + +/* SWR meter calibration table */ +/* The full scale value reads infinity, so arbitrary */ +#define TS890_SWR_CAL { 5, \ + { \ + { 0, 1.0 }, \ + { 11, 1.5 }, \ + { 23, 2.0 }, \ + { 35, 3.0 }, \ + { 70, 15.0 } \ + } } + /* * TS-890S rig capabilities * Copied from ts480_caps, many of the values have not been verified. @@ -393,7 +432,7 @@ const struct rig_caps ts890s_caps = RIG_MODEL(RIG_MODEL_TS890S), .model_name = "TS-890S", .mfg_name = "Kenwood", - .version = BACKEND_VER ".8", + .version = BACKEND_VER ".9", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -415,7 +454,7 @@ const struct rig_caps ts890s_caps = .max_rit = kHz(9.99), .max_xit = kHz(9.99), .max_ifshift = Hz(0), - .targetable_vfo = RIG_TARGETABLE_FREQ|RIG_TARGETABLE_MODE, + .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, .transceive = RIG_TRN_RIG, .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_SLOW, RIG_AGC_MEDIUM, RIG_AGC_FAST, RIG_AGC_ON }, @@ -504,6 +543,9 @@ const struct rig_caps ts890s_caps = }, .vfo_ops = TS890_VFO_OPS, + .str_cal = TS890_SM_CAL1, + .swr_cal = TS890_SWR_CAL, + .priv = (void *)& ts890s_priv_caps, .rig_init = kenwood_init, .rig_open = kenwood_open, commit 2fc6344d546d456f4d4749ebe18159a3baf17e93 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Dec 6 23:27:28 2022 -0600 Update simftdx3000.c diff --git a/simulators/simftdx3000.c b/simulators/simftdx3000.c index 6438f634..e8c4a31f 100644 --- a/simulators/simftdx3000.c +++ b/simulators/simftdx3000.c @@ -231,14 +231,27 @@ int main(int argc, char *argv[]) } else if (strcmp(buf, "FT;") == 0) { - SNPRINTF(buf, sizeof(buf), "FT%d;", ft); + int val = ft; + + if (ft == 2) { val == 0; } + else if (ft == 3) { val == 1; } + + SNPRINTF(buf, sizeof(buf), "FT%d;", val); n = write(fd, buf, strlen(buf)); } + else if (strncmp(buf, "FT", 2) == 0) + { + sscanf(buf, "FT%d", &ft); + } else if (strcmp(buf, "MD0;") == 0) { SNPRINTF(buf, sizeof(buf), "MD0%d;", md); n = write(fd, buf, strlen(buf)); } + else if (strncmp(buf, "MD0", 3) == 0) + { + sscanf(buf, "MD0%d", &md); + } else if (strcmp(buf, "VS;") == 0) { SNPRINTF(buf, sizeof(buf), "VS%d;", vs); commit 22af811d5ff3fe7260d54044ce748a1963547499 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Dec 6 12:56:13 2022 -0600 Fix spelling error in rig.c diff --git a/src/rig.c b/src/rig.c index c0d7f269..7c8b326f 100644 --- a/src/rig.c +++ b/src/rig.c @@ -7403,7 +7403,7 @@ static int async_data_handler_start(RIG *rig) if (!rs->async_data_enabled) { rig_debug(RIG_DEBUG_TRACE, - "%s: async data support disabled since asynd_data_enabled=%d\n", __func__, + "%s: async data support disabled since async_data_enabled=%d\n", __func__, rs->async_data_enabled); RETURNFUNC(RIG_OK); } commit 6a80385f8bc2658b1f29aa5cb32d3ea1b60c82a3 Merge: 40d1bad1 5f634df5 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Dec 5 13:59:55 2022 -0600 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit 5f634df53843d1e5235b067c0470993952e99cac Merge: e3487cb5 dae50c7a Author: Michael Black <mdb...@ya...> Date: Mon Dec 5 13:51:53 2022 -0600 Merge pull request #1175 from PianetaRadio/master Updated YaesuTargetableVFO.ods commit dae50c7a953fb6b1ba5a0a091eb508b28c9a2aa6 Merge: 825fc07d e3487cb5 Author: PianetaRadio <789...@us...> Date: Mon Dec 5 20:40:50 2022 +0100 Merge branch 'Hamlib:master' into master commit 40d1bad1e144feacdbe229af8afd9e36173b25de Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Dec 5 12:49:03 2022 -0600 Fix Jupiter set_freq problem -- was messing up strlen due to binary format https://github.com/Hamlib/Hamlib/issues/1174 diff --git a/rigs/tentec/jupiter.c b/rigs/tentec/jupiter.c index bb54dec5..5009991a 100644 --- a/rigs/tentec/jupiter.c +++ b/rigs/tentec/jupiter.c @@ -130,7 +130,7 @@ const struct rig_caps tt538_caps = RIG_MODEL(RIG_MODEL_TT538), .model_name = "TT-538 Jupiter", .mfg_name = "Ten-Tec", - .version = "20191209.0", + .version = "20221205.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -444,20 +444,20 @@ int tt538_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) int tt538_set_freq(RIG *rig, vfo_t vfo, freq_t freq) { - char bytes[4]; + unsigned char bytes[4]; unsigned char cmdbuf[16]; /* Freq is 4 bytes long, MSB sent first. */ - bytes[3] = ((int) freq >> 24) & 0xff; - bytes[2] = ((int) freq >> 16) & 0xff; - bytes[1] = ((int) freq >> 8) & 0xff; - bytes[0] = (int) freq & 0xff; + bytes[3] = ((unsigned int) freq >> 24) & 0xff; + bytes[2] = ((unsigned int) freq >> 16) & 0xff; + bytes[1] = ((unsigned int) freq >> 8) & 0xff; + bytes[0] = ((unsigned int) freq ) & 0xff; SNPRINTF((char *) cmdbuf, sizeof(cmdbuf), "*%c%c%c%c%c" EOM, which_vfo(rig, vfo), bytes[3], bytes[2], bytes[1], bytes[0]); - return tt538_transaction(rig, (char *) cmdbuf, strlen((char *)cmdbuf), NULL, + return tt538_transaction(rig, (char *) cmdbuf, 6, NULL, NULL); } @@ -716,7 +716,7 @@ int tt538_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) width = tt538_filter_number((int) width); SNPRINTF((char *) cmdbuf, sizeof(cmdbuf), "*W%c" EOM, (unsigned char) width); - return tt538_transaction(rig, (char *) cmdbuf, strlen((char *)cmdbuf), NULL, + return tt538_transaction(rig, (char *) cmdbuf, 4, NULL, NULL); return RIG_OK; @@ -1006,6 +1006,7 @@ int tt538_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) { char cc, cmdbuf[32], c1, c2; int retval; + int len; switch (level) { @@ -1023,20 +1024,24 @@ int tt538_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) } SNPRINTF(cmdbuf, sizeof(cmdbuf), "*G%c" EOM, cc); + len = 4; break; case RIG_LEVEL_AF: SNPRINTF(cmdbuf, sizeof(cmdbuf), "*U%c" EOM, (int)(127 * val.f)); + len = 4; break; case RIG_LEVEL_RF: SNPRINTF(cmdbuf, sizeof(cmdbuf), "*I%c" EOM, (int)(127 * val.f)); + len = 4; break; case RIG_LEVEL_IF: c1 = val.i >> 8; c2 = val.i & 0xff; SNPRINTF(cmdbuf, sizeof(cmdbuf), "*P%c%c" EOM, c1, c2); + len = 5; break; case RIG_LEVEL_ATT: @@ -1050,10 +1055,12 @@ int tt538_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) } SNPRINTF(cmdbuf, sizeof(cmdbuf), "*J%c" EOM, cc); + len = 4; break; case RIG_LEVEL_SQL: SNPRINTF(cmdbuf, sizeof(cmdbuf), "*H%c" EOM, (int)(127 * val.f)); + len = 4; break; default: @@ -1062,7 +1069,7 @@ int tt538_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) return -RIG_EINVAL; } - retval = tt538_transaction(rig, cmdbuf, strlen((char *)cmdbuf), NULL, NULL); + retval = tt538_transaction(rig, cmdbuf, len, NULL, NULL); if (retval != RIG_OK) { commit e3487cb5c6330243cf8cf7f0081e5b4b74c1becc Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Dec 5 09:13:13 2022 -0600 Add RIG_TARGETABLE_MODE to ts890.c https://github.com/Hamlib/Hamlib/issues/1172 diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index bfcd067f..d30217bd 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -393,7 +393,7 @@ const struct rig_caps ts890s_caps = RIG_MODEL(RIG_MODEL_TS890S), .model_name = "TS-890S", .mfg_name = "Kenwood", - .version = BACKEND_VER ".7", + .version = BACKEND_VER ".8", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -415,7 +415,7 @@ const struct rig_caps ts890s_caps = .max_rit = kHz(9.99), .max_xit = kHz(9.99), .max_ifshift = Hz(0), - .targetable_vfo = RIG_TARGETABLE_FREQ, + .targetable_vfo = RIG_TARGETABLE_FREQ|RIG_TARGETABLE_MODE, .transceive = RIG_TRN_RIG, .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_SLOW, RIG_AGC_MEDIUM, RIG_AGC_FAST, RIG_AGC_ON }, commit e603da4cb6cbc2d540bb29591c5a141b9a226ef2 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Dec 4 11:59:28 2022 -0600 If rig does not have TARGETABLE_MODE then we return the cached values from VFOA https://github.com/Hamlib/Hamlib/issues/1172 diff --git a/src/rig.c b/src/rig.c index 6efc6540..c0d7f269 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2433,7 +2433,9 @@ int HAMLIB_API rig_get_mode(RIG *rig, if (vfo == RIG_VFO_B && !(caps->targetable_vfo & RIG_TARGETABLE_MODE)) { - vfo = RIG_VFO_A; // we'll just return VFO_A mode which is probably cached + *mode = rig->state.cache.modeMainA; + *width = rig->state.cache.widthMainA; + return RIG_OK; } if ((*mode != RIG_MODE_NONE && cache_ms_mode < rig->state.cache.timeout_ms) commit ea1a718bb52339a8f5f9c582d083bc9ac5448063 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Dec 4 11:18:33 2022 -0600 Change CAT TOT command in newcat.c to expect a response https://github.com/Hamlib/Hamlib/issues/1163 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index dda61be6..5bdae1f4 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -613,7 +613,7 @@ int newcat_open(RIG *rig) SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "%s", cmd); - if (RIG_OK != (err = newcat_set_cmd(rig))) + if (RIG_OK != (err = newcat_get_cmd(rig))) { RETURNFUNC(err); } diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index b5f302fc..3f35b553 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20221203" +#define NEWCAT_VER "20221204" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit 156b810319cfeaefdbbf0f4e78090be7bc0d4a61 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Dec 3 22:39:38 2022 -0600 Add secondary check for rig_model in newcat.c for CAT TOT in case ID command fails https://github.com/Hamlib/Hamlib/issues/1163 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 5515ae66..dda61be6 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -603,13 +603,13 @@ int newcat_open(RIG *rig) int err; char *cmd = "EX0291;EX029;"; // FT2000/D - if (priv->rig_id == NC_RIGID_FT950) { cmd = "EX0271;EX027;"; } - else if (priv->rig_id == NC_RIGID_FT891) { cmd = "EX05071;EX0507;"; } - else if (priv->rig_id == NC_RIGID_FT991) { cmd = "EX0321;EX032;"; } - else if (priv->rig_id == NC_RIGID_FT991A) { cmd = "EX0321;EX032;"; } - else if (priv->rig_id == NC_RIGID_FTDX3000) { cmd = "EX0391;EX039;"; } - else if (priv->rig_id == NC_RIGID_FTDX3000DM) { cmd = "EX0391;EX039;"; } - else if (priv->rig_id == NC_RIGID_FTDX5000) { cmd = "EX0331;EX033"; } + if (priv->rig_id == NC_RIGID_FT950 || rig->caps->rig_model == RIG_MODEL_FT950) { cmd = "EX0271;EX027;"; } + else if (priv->rig_id == NC_RIGID_FT891 || rig->caps->rig_model == RIG_MODEL_FT891) { cmd = "EX05071;EX0507;"; } + else if (priv->rig_id == NC_RIGID_FT991 || rig->caps->rig_model == RIG_MODEL_FT991) { cmd = "EX0321;EX032;"; } + else if (priv->rig_id == NC_RIGID_FT991A || rig->caps->rig_model == RIG_MODEL_FT991) { cmd = "EX0321;EX032;"; } + else if (priv->rig_id == NC_RIGID_FTDX3000 || rig->caps->rig_model == RIG_MODEL_FTDX3000) { cmd = "EX0391;EX039;"; } + else if (priv->rig_id == NC_RIGID_FTDX3000DM || rig->caps->rig_model == RIG_MODEL_FTDX3000) { cmd = "EX0391;EX039;"; } + else if (priv->rig_id == NC_RIGID_FTDX5000 || rig->caps->rig_model == RIG_MODEL_FTDX5000) { cmd = "EX0331;EX033"; } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "%s", cmd); commit a2b3e1348c374c6e2ef555636704471eb4d813e3 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Dec 3 22:24:05 2022 -0600 Fix ID for FT991 and FT991 in newcat.c so CAT TOT settings work https://github.com/Hamlib/Hamlib/issues/1163 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index db01775d..5515ae66 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -57,7 +57,8 @@ typedef enum nc_rigid_e NC_RIGID_FT450D = 244, NC_RIGID_FT950 = 310, NC_RIGID_FT891 = 135, - NC_RIGID_FT991 = 135, + NC_RIGID_FT991 = 570, + NC_RIGID_FT991A = 670, NC_RIGID_FT2000 = 251, NC_RIGID_FT2000D = 252, NC_RIGID_FTDX1200 = 583, @@ -594,6 +595,7 @@ int newcat_open(RIG *rig) || priv->rig_id == NC_RIGID_FT2000D || priv->rig_id == NC_RIGID_FT891 || priv->rig_id == NC_RIGID_FT991 + || priv->rig_id == NC_RIGID_FT991A || priv->rig_id == NC_RIGID_FT950 || priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) @@ -604,6 +606,7 @@ int newcat_open(RIG *rig) if (priv->rig_id == NC_RIGID_FT950) { cmd = "EX0271;EX027;"; } else if (priv->rig_id == NC_RIGID_FT891) { cmd = "EX05071;EX0507;"; } else if (priv->rig_id == NC_RIGID_FT991) { cmd = "EX0321;EX032;"; } + else if (priv->rig_id == NC_RIGID_FT991A) { cmd = "EX0321;EX032;"; } else if (priv->rig_id == NC_RIGID_FTDX3000) { cmd = "EX0391;EX039;"; } else if (priv->rig_id == NC_RIGID_FTDX3000DM) { cmd = "EX0391;EX039;"; } else if (priv->rig_id == NC_RIGID_FTDX5000) { cmd = "EX0331;EX033"; } commit 825fc07d0007b6b5661c255a08d76badd3765513 Merge: d3d1fd7c fdd88c31 Author: PianetaRadio <789...@us...> Date: Sun Dec 4 00:44:32 2022 +0100 Merge branch 'Hamlib:master' into master commit fdd88c317e56131099a5de73b72727868c3bde3e Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Dec 3 15:44:19 2022 -0600 Update NEWS diff --git a/NEWS b/NEWS index 5a09d4f7..7fc4511d 100644 --- a/NEWS +++ b/NEWS @@ -18,6 +18,7 @@ Version 4.6 Version 4.5.1 * 2022-XX-XX + * 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 meter reading to TS-890S -- thanks to Geore Baltz N3GB * Fix FT736 VFOB freq and mode set commit 1e1ed4c9e61f08e4022e2b3ce1a2e196c6958ba3 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Dec 3 15:18:02 2022 -0600 Force the FT-991 to 100ms along with FT-DX2000, Ft-891, FT950, FTDX3000/D 10ms was seeing timeouts on some rigs using rigctl https://github.com/Hamlib/Hamlib/issues/1163 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 6eddf0c2..db01775d 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -587,24 +587,28 @@ int newcat_open(RIG *rig) rig_debug(RIG_DEBUG_VERBOSE, "%s: rig_id=%d\n", __func__, priv->rig_id); rig->state.rigport.timeout = timeout; -#if 0 // possible future enhancement? - // some rigs have a CAT TOT timeout that defaults to 10ms // so we'll increase CAT timeout to 100ms + // 10ms seemed problematic on some rigs/computers if (priv->rig_id == NC_RIGID_FT2000 || priv->rig_id == NC_RIGID_FT2000D || priv->rig_id == NC_RIGID_FT891 || priv->rig_id == NC_RIGID_FT991 - || priv->rig_id == NC_RIGID_FT950) + || priv->rig_id == NC_RIGID_FT950 + || priv->rig_id == NC_RIGID_FTDX3000 + || priv->rig_id == NC_RIGID_FTDX3000DM) { int err; - char *cmd = "EX0291%c"; + char *cmd = "EX0291;EX029;"; // FT2000/D - if (priv->rig_id == NC_RIGID_FT950) { cmd = "EX0271%c"; } - else if (priv->rig_id == NC_RIGID_FT891) { cmd = "EX05071c"; } - else if (priv->rig_id == NC_RIGID_FT991) { cmd = "EX0321c"; } + if (priv->rig_id == NC_RIGID_FT950) { cmd = "EX0271;EX027;"; } + else if (priv->rig_id == NC_RIGID_FT891) { cmd = "EX05071;EX0507;"; } + else if (priv->rig_id == NC_RIGID_FT991) { cmd = "EX0321;EX032;"; } + else if (priv->rig_id == NC_RIGID_FTDX3000) { cmd = "EX0391;EX039;"; } + else if (priv->rig_id == NC_RIGID_FTDX3000DM) { cmd = "EX0391;EX039;"; } + else if (priv->rig_id == NC_RIGID_FTDX5000) { cmd = "EX0331;EX033"; } - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), cmd, cat_term); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "%s", cmd); if (RIG_OK != (err = newcat_set_cmd(rig))) { @@ -612,40 +616,12 @@ int newcat_open(RIG *rig) } } -#endif - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) { rig->state.disable_yaesu_bandselect = 1; rig_debug(RIG_DEBUG_VERBOSE, "%s: disabling FTDX3000 band select\n", __func__); } - if (priv->rig_id == NC_RIGID_FTDX5000) - { - int err; - // set the CAT TIME OUT TIMER to 100ms - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0331;"); - - if (RIG_OK != (err = newcat_set_cmd(rig))) - { - rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, - rigerror(err)); - } - } - - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) - { - ... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-11-11 03:17:53
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 9a6d4d761249c553ef71093754213ca72e94eeb9 (commit) via 853806b9785975309c407c1e7d7f2158b50a95b3 (commit) via fc0fc1c67a5332a8ad2b55caddf288f2797a4b4e (commit) via eeac97c72594b364fc65d760d4ca9d332796d380 (commit) via 539457f6ce4c178b2141821b89521dfd69ba1875 (commit) via 27f424dfe2d9922c81c2d371dcee56074715c619 (commit) via 09d7ed2f196707e68cd24fffad03bebb525184f7 (commit) via 36717917ce9347f21708ad391befede96f486d51 (commit) via 77ae5ef5c99401d242832fa91f61d1a8483bb1e5 (commit) via 2993ca9e62d5eaf2e82ae8f60b85198aa7e1cd3c (commit) via 1ef362a954647b9ec92da0808963b1de0b0fa7b1 (commit) via fde9ad706c5aa3b95cb4a2e3fbcc7201f331cc78 (commit) via 24eb991f559398ebb6c66e9bbc716f872c6a2b3e (commit) via 0963d8c5bfd8ff7aa8176de35d18f9030e3c1acd (commit) via 454f640237c29a680f36b1b8d7358f542e53443f (commit) from 1074410bd527271f2f1f13b930911dd38a59e179 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 9a6d4d761249c553ef71093754213ca72e94eeb9 Merge: 853806b9 fc0fc1c6 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 17:53:50 2022 -0600 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit 853806b9785975309c407c1e7d7f2158b50a95b3 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 17:51:44 2022 -0600 Fix rotctld dumpcaps to expose client rot_type instead of Other https://github.com/Hamlib/Hamlib/issues/1035 diff --git a/rigs/dummy/netrotctl.c b/rigs/dummy/netrotctl.c index 16b6c22e..aaf657ef 100644 --- a/rigs/dummy/netrotctl.c +++ b/rigs/dummy/netrotctl.c @@ -144,7 +144,7 @@ static int netrotctl_open(ROT *rot) } rs->max_el = rot->caps->max_el = atof(buf); - + ret = read_string(&rot->state.rotport, (unsigned char *) buf, BUF_MAX, "\n", sizeof("\n"), 0, 1); @@ -155,6 +155,23 @@ static int netrotctl_open(ROT *rot) rs->south_zero = atoi(buf); + // Prot 1 is tag=value format + if (prot_ver >= 1) + { + ret = read_string(&rot->state.rotport, (unsigned char *) buf, BUF_MAX, "\n", + sizeof("\n"), 0, 1); + + if (ret <= 0) + { + return (ret < 0) ? ret : -RIG_EPROTO; + } + + if (strstr(buf, "AzEl")) { rot->caps->rot_type = ROT_TYPE_AZEL; } + else if (strstr(buf, "Az")) { rot->caps->rot_type = ROT_TYPE_AZIMUTH; } + else if (strstr(buf, "El")) { rot->caps->rot_type = ROT_TYPE_ELEVATION; } + } + + return RIG_OK; } diff --git a/tests/rotctl.c b/tests/rotctl.c index f7c74c45..f8dd99aa 100644 --- a/tests/rotctl.c +++ b/tests/rotctl.c @@ -369,6 +369,14 @@ int main(int argc, char *argv[]) rot_token_foreach(my_rot, print_conf_list, (rig_ptr_t)my_rot); } + retcode = rot_open(my_rot); + + if (retcode != RIG_OK) + { + fprintf(stderr, "rot_open: error = %s \n", rigerror(retcode)); + exit(2); + } + /* * Print out capabilities, and exits immediately as we may be interested * only in caps, and rig_open may fail. @@ -380,14 +388,6 @@ int main(int argc, char *argv[]) exit(0); } - retcode = rot_open(my_rot); - - if (retcode != RIG_OK) - { - fprintf(stderr, "rot_open: error = %s \n", rigerror(retcode)); - exit(2); - } - my_rot->state.az_offset = az_offset; my_rot->state.el_offset = el_offset; diff --git a/tests/rotctl_parse.c b/tests/rotctl_parse.c index 1a7c03d6..daeff767 100644 --- a/tests/rotctl_parse.c +++ b/tests/rotctl_parse.c @@ -2363,7 +2363,7 @@ declare_proto_rot(dump_state) /* * - Protocol version */ -#define ROTCTLD_PROT_VER 0 +#define ROTCTLD_PROT_VER 1 if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { @@ -2414,6 +2414,21 @@ declare_proto_rot(dump_state) fprintf(fout, "%d%c", rs->south_zero, resp_sep); + char *rtype = "Unknown"; + + switch (rot->caps->rot_type) + { + case ROT_TYPE_OTHER: rtype = "Other"; break; + + case ROT_TYPE_AZIMUTH : rtype = "Az"; break; + + case ROT_TYPE_ELEVATION : rtype = "El"; break; + + case ROT_TYPE_AZEL : rtype = "AzEl"; break; + } + + fprintf(fout, "rot_type=%s%c", rtype, resp_sep); + return RIG_OK; } commit fc0fc1c67a5332a8ad2b55caddf288f2797a4b4e Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 17:51:44 2022 -0600 Fix rotctld dumpcaps to expose client rot_type instead of Other diff --git a/rigs/dummy/netrotctl.c b/rigs/dummy/netrotctl.c index 16b6c22e..aaf657ef 100644 --- a/rigs/dummy/netrotctl.c +++ b/rigs/dummy/netrotctl.c @@ -144,7 +144,7 @@ static int netrotctl_open(ROT *rot) } rs->max_el = rot->caps->max_el = atof(buf); - + ret = read_string(&rot->state.rotport, (unsigned char *) buf, BUF_MAX, "\n", sizeof("\n"), 0, 1); @@ -155,6 +155,23 @@ static int netrotctl_open(ROT *rot) rs->south_zero = atoi(buf); + // Prot 1 is tag=value format + if (prot_ver >= 1) + { + ret = read_string(&rot->state.rotport, (unsigned char *) buf, BUF_MAX, "\n", + sizeof("\n"), 0, 1); + + if (ret <= 0) + { + return (ret < 0) ? ret : -RIG_EPROTO; + } + + if (strstr(buf, "AzEl")) { rot->caps->rot_type = ROT_TYPE_AZEL; } + else if (strstr(buf, "Az")) { rot->caps->rot_type = ROT_TYPE_AZIMUTH; } + else if (strstr(buf, "El")) { rot->caps->rot_type = ROT_TYPE_ELEVATION; } + } + + return RIG_OK; } diff --git a/tests/rotctl.c b/tests/rotctl.c index f7c74c45..f8dd99aa 100644 --- a/tests/rotctl.c +++ b/tests/rotctl.c @@ -369,6 +369,14 @@ int main(int argc, char *argv[]) rot_token_foreach(my_rot, print_conf_list, (rig_ptr_t)my_rot); } + retcode = rot_open(my_rot); + + if (retcode != RIG_OK) + { + fprintf(stderr, "rot_open: error = %s \n", rigerror(retcode)); + exit(2); + } + /* * Print out capabilities, and exits immediately as we may be interested * only in caps, and rig_open may fail. @@ -380,14 +388,6 @@ int main(int argc, char *argv[]) exit(0); } - retcode = rot_open(my_rot); - - if (retcode != RIG_OK) - { - fprintf(stderr, "rot_open: error = %s \n", rigerror(retcode)); - exit(2); - } - my_rot->state.az_offset = az_offset; my_rot->state.el_offset = el_offset; diff --git a/tests/rotctl_parse.c b/tests/rotctl_parse.c index 1a7c03d6..daeff767 100644 --- a/tests/rotctl_parse.c +++ b/tests/rotctl_parse.c @@ -2363,7 +2363,7 @@ declare_proto_rot(dump_state) /* * - Protocol version */ -#define ROTCTLD_PROT_VER 0 +#define ROTCTLD_PROT_VER 1 if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { @@ -2414,6 +2414,21 @@ declare_proto_rot(dump_state) fprintf(fout, "%d%c", rs->south_zero, resp_sep); + char *rtype = "Unknown"; + + switch (rot->caps->rot_type) + { + case ROT_TYPE_OTHER: rtype = "Other"; break; + + case ROT_TYPE_AZIMUTH : rtype = "Az"; break; + + case ROT_TYPE_ELEVATION : rtype = "El"; break; + + case ROT_TYPE_AZEL : rtype = "AzEl"; break; + } + + fprintf(fout, "rot_type=%s%c", rtype, resp_sep); + return RIG_OK; } commit eeac97c72594b364fc65d760d4ca9d332796d380 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 16:00:00 2022 -0600 Fix FT-991 level_gran https://github.com/Hamlib/Hamlib/issues/1144 diff --git a/NEWS b/NEWS index 251f49cf..64e100de 100644 --- a/NEWS +++ b/NEWS @@ -17,6 +17,9 @@ Version 4.6 Version 4.5.1 * 2022-XX-XX + * Add RIG_FUNC_TUNER to flrig.c + * Fix FT-991 level_gran (needs to be done for lots of rigs) + * Fix man page rigctl to show units for LEVEL items * Fix Flex6xxx if_len * Fix FLRig set_ptt * Add KEYSPD to TS890 diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index b29f030a..438de67d 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -863,6 +863,53 @@ The Level Value can be a float or an integer value. For the AGC token the value is one of \(oq0\(cq = OFF, \(oq1\(cq = SUPERFAST, \(oq2\(cq = FAST, \(oq3\(cq = SLOW, \(oq4\(cq = USER, \(oq5\(cq = MEDIUM, \(oq6\(cq = AUTO. Note that not all values work on all rigs. To list usable values do "rigctl -m [modelnum] -u | grep AGC levels" or for Windows "rigctl -m [modelnum] -u | find "AGC levels"". +.IP +Level units +.in +4n +.EX +0.0-1.0 where 0=0% and 1.0=100% (except for BAL where 50% is center) + AF, ALC, ANTIVOX, BAL, COMP, MICGAIN, MONITOR_GAIN, NOTCHF_RAW, NR, RF, RFPOWER, RFPOWER_METER, USB_AF, VOXGAIN + +Amps + ID_METER(A) + +dB + NL, COMP_METER, PREAMP, ATT, SLOPE_LOW, SLOPE_HIGH, SPECTRUM_REF, SPECTRUM_ATT, STRENGTH + +Degrees(temperature) + TEMP_METER(C) + +Hz + CWPITCH, IF, NOTCHF, PBT_IN, PBT_OUT, SPECTRUM_EDGE_LOW, SPECTRUM_EDGE_HIGH, SPECTRUM_SPAN + +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) + +SWR + SWR + +Volts + VD_METER + +Lookup - if level shows 0/0/0 then it's probably a lookup value + METER RIG_METER_XXXX 1=SWR, 2=COMP, 4=ALC, 8=IC, 16=DB, 32=PO, 64=VDD, 128=Temp + AGC 0=None, 1=SuperFast, 2=Fast, 3=Slow, 4=User, 5=Medium, 6=Auto + Note: Not all AGC values may be available -- see AGC Level in dumpcaps (e.g. rigctl -m 1035 -u | grep AGC) + SPECTRUM_MODE 0=None, 1=Center, 2=Fixed, 3=Center Scroll, 4=Fixed Scroll + SPECTRUM_AVG rig specific + +Watts + RFPOWER_METER_WATTS + +WPM + KEYSPD +.in +.EE +.IP + .IP .BR Note : Passing a \(oq?\(cq (query) as the first argument instead of a Level token diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index d2af1e20..4b4fc427 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -141,7 +141,7 @@ const struct rig_caps ft991_caps = RIG_MODEL(RIG_MODEL_FT991), .model_name = "FT-991", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".13", + .version = NEWCAT_VER ".14", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -166,10 +166,43 @@ const struct rig_caps ft991_caps = .has_set_parm = RIG_PARM_NONE, .level_gran = { // cppcheck-suppress * - [LVL_RAWSTR] = { .min = { .i = 0 }, .max = { .i = 255 } }, - [LVL_CWPITCH] = { .min = { .i = 300 }, .max = { .i = 1050 }, .step = { .i = 50 } }, - [LVL_KEYSPD] = { .min = { .i = 4 }, .max = { .i = 60 }, .step = { .i = 1 } }, - [LVL_NOTCHF] = { .min = { .i = 1 }, .max = { .i = 3200 }, .step = { .i = 10 } }, + /* raw data */ + [LVL_RAWSTR] = { .min = { .i = 0 }, .max = { .i = 255 } }, + /* levels with dB units */ + [LVL_PREAMP] = { .min = { .i = 10 }, .max = { .i = 20 }, .step = { .i = 10 } }, + [LVL_ATT] = { .min = { .i = 12 }, .max = { .i = 12 }, .step = { .i = 0 } }, + [LVL_STRENGTH] = { .min = { .i = 0 }, .max = { .i = 60 }, .step = { .i = 0 } }, + [LVL_NB] = { .min = { .f = 0 }, .max = { .f = 10 }, .step = { .f = 1 } }, + /* levels with WPM units */ + [LVL_KEYSPD] = { .min = { .i = 4 }, .max = { .i = 60 }, .step = { .i = 1 } }, + /* levels with Hz units */ + [LVL_CWPITCH] = { .min = { .i = 300 }, .max = { .i = 1050 }, .step = { .i = 50 } }, + [LVL_IF] = { .min = { .i = -1200 }, .max = { .i = 1200 }, .step = { .i = 20 } }, + [LVL_NOTCHF] = { .min = { .i = 1 }, .max = { .i = 3200 }, .step = { .i = 10 } }, + /* levels with time units */ + [LVL_VOXDELAY] = { .min = { .i = 3 }, .max = { .i = 300 }, .step = { .i = 1 } }, + [LVL_BKINDL] = { .min = { .i = 30 }, .max = { .i = 3000 }, .step = { .i = 1 } }, + [LVL_BKIN_DLYMS] = { .min = { .i = 30 }, .max = { .i = 3000 }, .step = { .i = 1 } }, + /* level with misc units */ + [LVL_SWR] = { .min = { .f = 0 }, .max = { .f = 5.0 }, .step = { .f = 1.0f/255.0f } }, + [LVL_BAND_SELECT] = { .min = { .i = 0 }, .max = { .i = 16 }, .step = { .i = 1 } }, + /* levels with 0-1 values -- increment based on rig's range */ + [LVL_NR] = { .min = { .f = 0 }, .max = { .f = 1 }, .step = { .f = 1.0f/10.0f } }, + [LVL_AF] = { .min = { .f = 0 }, .max = { .f = 1.0 }, .step = { .f = 1.0f/255.0f } }, + [LVL_RF] = { .min = { .f = 0 }, .max = { .f = 1.0 }, .step = { .f = 1.0f/255.0f } }, + [LVL_RFPOWER] = { .min = { .f = .05 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_RFPOWER_METER] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/255.0f } }, + [LVL_RFPOWER_METER_WATTS] = { .min = { .f = .0 }, .max = { .f = 100 }, .step = { .f = 1.0f/255.0f } }, + [LVL_COMP_METER] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/255.0f } }, + [LVL_ID_METER] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/255.0f } }, + [LVL_VD_METER] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/255.0f } }, + [LVL_SQL] = { .min = { .f = 0 }, .max = { .f = 1.0 }, .step = { .f = 1.0f/100.0f } }, + [LVL_MICGAIN] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_MONITOR_GAIN] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_COMP] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_VOXGAIN] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_ANTIVOX] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, + [LVL_ALC] = { .min = { .f = .0 }, .max = { .f = 1 }, .step = { .f = 1.0f/100.0f } }, }, .ctcss_list = common_ctcss_list, .dcs_list = common_dcs_list, diff --git a/rigs/yaesu/ft991.h b/rigs/yaesu/ft991.h index 92e5c988..7371bd59 100644 --- a/rigs/yaesu/ft991.h +++ b/rigs/yaesu/ft991.h @@ -54,7 +54,7 @@ RIG_LEVEL_RFPOWER|RIG_LEVEL_RF|RIG_LEVEL_SQL|\ RIG_LEVEL_MICGAIN|RIG_LEVEL_IF|RIG_LEVEL_CWPITCH|\ RIG_LEVEL_KEYSPD|RIG_LEVEL_AF|RIG_LEVEL_AGC|\ - RIG_LEVEL_METER|RIG_LEVEL_BKINDL|RIG_LEVEL_SQL|\ + RIG_LEVEL_METER|RIG_LEVEL_BKINDL|RIG_LEVEL_BKIN_DLYMS|RIG_LEVEL_SQL|\ RIG_LEVEL_VOXGAIN|RIG_LEVEL_VOXDELAY|RIG_LEVEL_COMP|\ RIG_LEVEL_ANTIVOX|RIG_LEVEL_NR|RIG_LEVEL_NB|RIG_LEVEL_NOTCHF|\ RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|\ diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 560cb290..c2ed5915 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -4187,16 +4187,20 @@ int newcat_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) } else { - fpf = newcat_scale_float(15, val.f); - - if (fpf < 1) + if (is_ft991) { - fpf = 1; + fpf = newcat_scale_float(10, val.f); + if (fpf > 10) fpf=10; + } + else + { + fpf = newcat_scale_float(15, val.f); + if (fpf > 15) fpf=10; } - if (fpf > 15) + if (fpf < 0) { - fpf = 15; + fpf = 0; } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "RL0%02d%c", fpf, cat_term); @@ -4443,7 +4447,7 @@ int newcat_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) else if (is_ft991) { fpf = newcat_scale_float(100, val.f); - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX147%03d%c", fpf, cat_term); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX145%03d%c", fpf, cat_term); } else if (is_ft891) { diff --git a/src/idx_builtin.h b/src/idx_builtin.h index 004bdbbf..4c468034 100644 --- a/src/idx_builtin.h +++ b/src/idx_builtin.h @@ -165,7 +165,7 @@ #define LVL_USB_AF setting2idx_builtin(RIG_LEVEL_USB_AF) #define LVL_AGC_TIME setting2idx_builtin(RIG_LEVEL_AGC_TIME) -#define LVL_50 setting2idx_builtin(RIG_LEVEL_50) +#define LVL_BAND_SELECT setting2idx_builtin(RIG_LEVEL_BAND_SELECT) #define LVL_51 setting2idx_builtin(RIG_LEVEL_51) #define LVL_52 setting2idx_builtin(RIG_LEVEL_52) #define LVL_53 setting2idx_builtin(RIG_LEVEL_53) commit 539457f6ce4c178b2141821b89521dfd69ba1875 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 12:18:18 2022 -0600 Update ftdx10.h power levels diff --git a/rigs/yaesu/ftdx10.h b/rigs/yaesu/ftdx10.h index 3b59e5c1..67b690dc 100644 --- a/rigs/yaesu/ftdx10.h +++ b/rigs/yaesu/ftdx10.h @@ -78,7 +78,7 @@ { \ 5, \ { \ - {35, 5.0f}, \ + {27, 5.0f}, \ {94, 25.0f}, \ {147, 50.0f}, \ {176, 75.0f}, \ commit 27f424dfe2d9922c81c2d371dcee56074715c619 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 12:17:17 2022 -0600 Add RIG_FUNC_TUNER to flrig.c diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index 507d6cc0..1e0b997a 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -76,6 +76,7 @@ static int flrig_get_vfo(RIG *rig, vfo_t *vfo); static int flrig_set_vfo(RIG *rig, vfo_t vfo); static int flrig_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt); static int flrig_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt); +static int flrig_set_func(RIG *rig, vfo_t vfo, setting_t setting, int status); static int flrig_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); static int flrig_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq); static int flrig_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, @@ -141,7 +142,7 @@ const struct rig_caps flrig_caps = RIG_MODEL(RIG_MODEL_FLRIG), .model_name = "FLRig", .mfg_name = "FLRig", - .version = "20221104.0", + .version = "20221109.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -154,7 +155,8 @@ const struct rig_caps flrig_caps = .retry = 2, .has_get_func = RIG_FUNC_NONE, - .has_set_func = RIG_FUNC_NONE, + .has_set_func = RIG_FUNC_TUNER, + .set_func = flrig_set_func, .has_get_level = FLRIG_LEVELS, .has_set_level = RIG_LEVEL_SET(FLRIG_LEVELS), .has_get_parm = FLRIG_PARM, @@ -2359,6 +2361,23 @@ HAMLIB_EXPORT(int) flrig_cat_string(RIG *rig, const char *arg) return retval; } +HAMLIB_EXPORT(int) flrig_set_func(RIG *rig, vfo_t vfo, setting_t func, int status) +{ + int retval; + char cmd_arg[MAXARGLEN]; + rig_debug(RIG_DEBUG_VERBOSE, "%s called: level=%s, status=%d\n", __func__, rig_strfunc(func), status); + switch(func) + { + case RIG_FUNC_TUNER: + SNPRINTF(cmd_arg, sizeof(cmd_arg), + "<params><param><value>%d</value></param></params>", status); + retval = flrig_transaction(rig, "rig.tune", cmd_arg, NULL, 0); + default: + retval = -RIG_ENIMPL; + } + return retval; +} + #if 0 static int flrig_set_ext_parm(RIG *rig, setting_t parm, value_t val) { commit 09d7ed2f196707e68cd24fffad03bebb525184f7 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Nov 10 08:03:43 2022 -0600 Improve README.md by adding github and sourceforge info diff --git a/README.md b/README.md index 754d423f..3b109369 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,15 @@ Hamlib - (C) Frank Singleton 2000 (vk...@ix...) (C) Stephane Fillod 2000-2011 - (C) The Hamlib Group 2000-2012 + (C) The Hamlib Group 2000-2022 + The purpose of this project is to provide stable, flexible, shared libraries that enable quicker development of Amateur Radio Equipment Control Applications. +The master repository is https://github.com/Hamlib/Hamlib +Daily snapshots are available at https://n0nb.users.sourceforge.net/ +Development happens on the github master (often by +merging feature branches) and each release has a release branch. Many Amateur Radio Transceivers come with serial interfaces that allows software to control the radio. This project will endeavour to provide shared commit 36717917ce9347f21708ad391befede96f486d51 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Nov 9 15:27:20 2022 -0600 Fix 5W level of ftdx10.c based on user testing diff --git a/rigs/yaesu/ftdx10.c b/rigs/yaesu/ftdx10.c index 58d1be65..3e1cf8e0 100644 --- a/rigs/yaesu/ftdx10.c +++ b/rigs/yaesu/ftdx10.c @@ -137,7 +137,7 @@ const struct rig_caps ftdx10_caps = RIG_MODEL(RIG_MODEL_FTDX10), .model_name = "FTDX-10", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".3", + .version = NEWCAT_VER ".4", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, commit 77ae5ef5c99401d242832fa91f61d1a8483bb1e5 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 8 15:33:13 2022 -0600 Update simicom9700.c diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index 6eaf47ae..f61959a2 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -39,7 +39,7 @@ int ptt = 0; int satmode = 0; int agc_time = 1; int ovf_status = 0; -int powerstat = 1; +int powerstat = 0; void dumphex(unsigned char *buf, int n) { @@ -55,6 +55,7 @@ frameGet(int fd, unsigned char *buf) memset(buf, 0, BUFSIZE); unsigned char c; +again: while (read(fd, &c, 1) > 0) { buf[i++] = c; @@ -65,6 +66,19 @@ frameGet(int fd, unsigned char *buf) dumphex(buf, i); return i; } + + if (i > 2 && c==0xfe) + { + printf("Turning power on due to 0xfe string\n"); + powerstat = 1; + int j; + for(j=i;j<175;++j) + { + if (read(fd, &c, 1) < 0) break; + } + i=0; + goto again; + } } printf("Error???\n"); @@ -88,12 +102,6 @@ void frameParse(int fd, unsigned char *frame, int len) switch (frame[4]) { - case 0xfe: - usleep(500 * 1000); - tcflush(fd, TCIFLUSH); - powerstat = 1; - break; - case 0x03: //from_bcd(frameackbuf[2], (civ_731_mode ? 4 : 5) * 2); commit 2993ca9e62d5eaf2e82ae8f60b85198aa7e1cd3c Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 8 15:09:09 2022 -0600 Fix segfault in icom_get_powerstat diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 82a785f5..3bb8bf44 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -8073,9 +8073,9 @@ int icom_get_powerstat(RIG *rig, powerstat_t *status) { freq_t freq; int retrysave = rig->caps->retry; - rig->caps->retry = 0; + rig->state.rigport.retry = 0; int retval = rig_get_freq(rig, RIG_VFO_A, &freq); - rig->caps->retry = retrysave; + rig->state.rigport.retry = retrysave; *status = retval==RIG_OK ? RIG_POWER_ON : RIG_POWER_OFF; return retval; } diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index 8a080eb0..6eaf47ae 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -13,6 +13,9 @@ #include <sys/time.h> #include <hamlib/rig.h> #include "../src/misc.h" +#include <termios.h> +#include <unistd.h> + #define BUFSIZE 256 #define X25 @@ -36,7 +39,7 @@ int ptt = 0; int satmode = 0; int agc_time = 1; int ovf_status = 0; -int powerstat = 0; +int powerstat = 1; void dumphex(unsigned char *buf, int n) { @@ -85,6 +88,12 @@ void frameParse(int fd, unsigned char *frame, int len) switch (frame[4]) { + case 0xfe: + usleep(500 * 1000); + tcflush(fd, TCIFLUSH); + powerstat = 1; + break; + case 0x03: //from_bcd(frameackbuf[2], (civ_731_mode ? 4 : 5) * 2); @@ -100,8 +109,12 @@ void frameParse(int fd, unsigned char *frame, int len) } frame[10] = 0xfd; + if (powerstat) + { n = write(fd, frame, 11); + } + break; case 0x04: @@ -233,7 +246,7 @@ void frameParse(int fd, unsigned char *frame, int len) frame[6] = ovf_status; frame[7] = 0xfd; n = write(fd, frame, 8); - ovf_status = ovf_status==0?1:0; + ovf_status = ovf_status == 0 ? 1 : 0; break; case 0x11: @@ -527,11 +540,14 @@ int main(int argc, char **argv) } if (powerstat) - frameParse(fd, buf, len); + { + frameParse(fd, buf, len); + } else { - usleep(1000*1000); + usleep(1000 * 1000); } + rigStatus(); } commit 1ef362a954647b9ec92da0808963b1de0b0fa7b1 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 8 14:59:14 2022 -0600 Fix NEWS diff --git a/NEWS b/NEWS index f510f08e..251f49cf 100644 --- a/NEWS +++ b/NEWS @@ -19,7 +19,7 @@ Version 4.5.1 * 2022-XX-XX * Fix Flex6xxx if_len * Fix FLRig set_ptt - * Add KEYSPD to TS870 + * Add KEYSPD to TS890 * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF * Add RIG_LEVEL_AGC_TIME to allow AGC/OFF to be set for IC-7300, IC-9700, IC-705 commit fde9ad706c5aa3b95cb4a2e3fbcc7201f331cc78 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 8 10:47:57 2022 -0600 Fix IC-7300 rig power on hopefully https://github.com/Hamlib/Hamlib/issues/1142 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 2dd50a07..82a785f5 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -8047,6 +8047,8 @@ int icom_get_powerstat(RIG *rig, powerstat_t *status) ENTERFUNC; + *status = RIG_POWER_OFF; // default return until proven otherwise + /* r75 has no way to get power status, so fake it */ if (rig->caps->rig_model == RIG_MODEL_ICR75) { @@ -8070,7 +8072,11 @@ int icom_get_powerstat(RIG *rig, powerstat_t *status) if (rig->caps->rig_model == RIG_MODEL_IC7300) { freq_t freq; + int retrysave = rig->caps->retry; + rig->caps->retry = 0; int retval = rig_get_freq(rig, RIG_VFO_A, &freq); + rig->caps->retry = retrysave; + *status = retval==RIG_OK ? RIG_POWER_ON : RIG_POWER_OFF; return retval; } else diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index f19be87c..8a080eb0 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -36,6 +36,7 @@ int ptt = 0; int satmode = 0; int agc_time = 1; int ovf_status = 0; +int powerstat = 0; void dumphex(unsigned char *buf, int n) { @@ -99,7 +100,8 @@ void frameParse(int fd, unsigned char *frame, int len) } frame[10] = 0xfd; - n = write(fd, frame, 11); + if (powerstat) + n = write(fd, frame, 11); break; case 0x04: @@ -524,7 +526,12 @@ int main(int argc, char **argv) fd = openPort(argv[1]); } + if (powerstat) frameParse(fd, buf, len); + else + { + usleep(1000*1000); + } rigStatus(); } diff --git a/src/rig.c b/src/rig.c index 7e07af18..ee997c1f 100644 --- a/src/rig.c +++ b/src/rig.c @@ -5860,9 +5860,11 @@ int HAMLIB_API rig_get_powerstat(RIG *rig, powerstat_t *status) if (rig->caps->get_powerstat == NULL) { + *status = RIG_POWER_ON; // default to power if not available RETURNFUNC(-RIG_ENAVAIL); } + *status = RIG_POWER_OFF; // default now to power off until proven otherwise in get_powerstat HAMLIB_TRACE; retcode = rig->caps->get_powerstat(rig, status); RETURNFUNC(retcode); commit 24eb991f559398ebb6c66e9bbc716f872c6a2b3e Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 8 10:16:19 2022 -0600 Update NEWS diff --git a/NEWS b/NEWS index 36abaaee..f510f08e 100644 --- a/NEWS +++ b/NEWS @@ -13,7 +13,13 @@ Version 5.x -- future * Change FT1000MP Mark V model names to align with FT1000MP Version 4.6 - * 2023-XX-XX + * 2023-11-XX -- Planned for Nov 2023 + +Version 4.5.1 + * 2022-XX-XX + * Fix Flex6xxx if_len + * Fix FLRig set_ptt + * Add KEYSPD to TS870 * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF * Add RIG_LEVEL_AGC_TIME to allow AGC/OFF to be set for IC-7300, IC-9700, IC-705 commit 0963d8c5bfd8ff7aa8176de35d18f9030e3c1acd Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Nov 7 12:24:55 2022 -0600 Fix if_len in flex6xxx.c https://github.com/Hamlib/Hamlib/issues/1141 diff --git a/rigs/kenwood/flex6xxx.c b/rigs/kenwood/flex6xxx.c index f07afe43..8d72a12e 100644 --- a/rigs/kenwood/flex6xxx.c +++ b/rigs/kenwood/flex6xxx.c @@ -88,14 +88,14 @@ static struct kenwood_priv_caps f6k_priv_caps = { .cmdtrm = EOM_KEN, .mode_table = flex_mode_table, - .if_len = 38 + .if_len = 37 }; static struct kenwood_priv_caps powersdr_priv_caps = { .cmdtrm = EOM_KEN, .mode_table = powersdr_mode_table, - .if_len = 38 + .if_len = 37 }; #define DSP_BW_NUM 8 commit 454f640237c29a680f36b1b8d7358f542e53443f Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Nov 6 15:58:30 2022 -0600 Fix dummy_set_split_freq diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index 1f6fca1b..b1eb070b 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -424,6 +424,7 @@ static int dummy_set_freq(RIG *rig, vfo_t vfo, freq_t freq) } if (vfo == RIG_VFO_CURR) { vfo = priv->curr_vfo; } + if (vfo == RIG_VFO_CURR || RIG_VFO_TX) { vfo = vfo_fixup(rig,vfo,rig->state.cache.split); } // if needed for testing enable this to emulate a rig with 100hz resolution #if 0 @@ -930,13 +931,16 @@ static int dummy_get_dcs_sql(RIG *rig, vfo_t vfo, unsigned int *code) static int dummy_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq) { struct dummy_priv_data *priv = (struct dummy_priv_data *)rig->state.priv; + int retval; ENTERFUNC; + + retval = dummy_set_freq(rig, vfo, tx_freq); priv->curr->tx_freq = tx_freq; rig_debug(RIG_DEBUG_VERBOSE, "%s: priv->curr->tx_freq = %.0f\n", __func__, priv->curr->tx_freq); - RETURNFUNC(RIG_OK); + RETURNFUNC(retval); } @@ -2266,7 +2270,7 @@ struct rig_caps dummy_caps = RIG_MODEL(RIG_MODEL_DUMMY), .model_name = "Dummy", .mfg_name = "Hamlib", - .version = "20220727.0", + .version = "20221106.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_OTHER, ----------------------------------------------------------------------- Summary of changes: NEWS | 11 ++++++++++- README.md | 7 ++++++- doc/man1/rigctl.1 | 47 +++++++++++++++++++++++++++++++++++++++++++++++ rigs/dummy/dummy.c | 8 ++++++-- rigs/dummy/flrig.c | 23 +++++++++++++++++++++-- rigs/dummy/netrotctl.c | 19 ++++++++++++++++++- rigs/icom/icom.c | 6 ++++++ rigs/kenwood/flex6xxx.c | 4 ++-- rigs/yaesu/ft991.c | 43 ++++++++++++++++++++++++++++++++++++++----- rigs/yaesu/ft991.h | 2 +- rigs/yaesu/ftdx10.c | 2 +- rigs/yaesu/ftdx10.h | 2 +- rigs/yaesu/newcat.c | 18 +++++++++++------- simulators/simicom9700.c | 37 ++++++++++++++++++++++++++++++++++--- src/idx_builtin.h | 2 +- src/rig.c | 2 ++ tests/rotctl.c | 16 ++++++++-------- tests/rotctl_parse.c | 17 ++++++++++++++++- 18 files changed, 229 insertions(+), 37 deletions(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-11-06 19:49:12
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 1074410bd527271f2f1f13b930911dd38a59e179 (commit) via c218996e2fc1fb2626956f1fbed63c2114ac1161 (commit) via 8789321465b0a6b9128ad09f86032668e134ee34 (commit) via bf22bc4b02d6a89ac21536e09a61d51a4ca540d0 (commit) via 3c3112ddc601a411137c358e36ded3358efe2236 (commit) via d311153f6386a77508943368e536193c50e4ffb8 (commit) via dac5175cad340df649fb9a674257259b5d4aa773 (commit) via a397b39ca3f3143abda61346f8b253032b4eb3da (commit) via aedf39adc2c30a95a944e130b5d7398a77aab7d4 (commit) via eff048d729dd56f86aead6c4c670bc8435a1a22e (commit) via b2cf596b5494d6201f8d506a881bb8aaf3df7970 (commit) via 790bf7704c8a175aabfe8cd54ec267c0d5b7fbd3 (commit) via 0d73bb22a080ea04b489f723cdbac6ee4c5744a2 (commit) via eb667185ef587323809a298e171d2e538e2005cd (commit) via 2a30396d70dda90ae8e2218bf761b0ffc7ee5e8d (commit) via b2bd93a7be8fb48189337e2dc0961a58d9d82651 (commit) via 1cb999af01c1a2e4298d66b94485730c706adf16 (commit) via 6b1555365ab5dbe4fc82037d0737d72d01cdaf29 (commit) via 4ce202a5798daba37a63abd3ab0357644b617f5a (commit) via cd1dc4c05df3ed96a0c1384b45f589e86bb0aa17 (commit) from 56b2814e75ca6b3ce622f90f6160ce8088bc5987 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 1074410bd527271f2f1f13b930911dd38a59e179 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Nov 5 12:58:40 2022 -0500 Add RIG_LEVEL_KEYSPD to ts890s.c https://github.com/Hamlib/Hamlib/issues/1139 diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index 69dde65b..6a40b43a 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -36,7 +36,7 @@ #define TS890_AM_TX_MODES RIG_MODE_AM // TODO: Copied from TS-480, to be verified -#define TS890_LEVEL_ALL (RIG_LEVEL_RFPOWER|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_AGC) +#define TS890_LEVEL_ALL (RIG_LEVEL_RFPOWER|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_AGC|RIG_LEVEL_KEYSPD) #define TS890_FUNC_ALL (RIG_FUNC_NB|RIG_FUNC_NB2|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_NR|RIG_FUNC_NR|RIG_FUNC_BC|RIG_FUNC_BC2|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_TUNER|RIG_FUNC_SEND_MORSE) #define TS890_VFO_OPS (RIG_OP_UP|RIG_OP_DOWN|RIG_OP_BAND_UP|RIG_OP_BAND_DOWN|RIG_OP_CPY|RIG_OP_TUNE) @@ -241,7 +241,7 @@ const struct rig_caps ts890s_caps = RIG_MODEL(RIG_MODEL_TS890S), .model_name = "TS-890S", .mfg_name = "Kenwood", - .version = BACKEND_VER ".3", + .version = BACKEND_VER ".4", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, commit c218996e2fc1fb2626956f1fbed63c2114ac1161 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 23:31:51 2022 -0500 Add RIG_FUNC_OVF_STATUS for IC-7300, IC-9700, IC-705, IC-R8600 diff --git a/NEWS b/NEWS index 07908008..36abaaee 100644 --- a/NEWS +++ b/NEWS @@ -17,6 +17,7 @@ Version 4.6 * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF * Add RIG_LEVEL_AGC_TIME to allow AGC/OFF to be set for IC-7300, IC-9700, IC-705 + * Add RIG_FUNC_OVF_STATUS to get overflow status for IC-7300, IC-9700, IC-705, and IC-R8600 Version 4.5 diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 6f1474ab..705f9dd0 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -1180,9 +1180,9 @@ typedef uint64_t setting_t; #define RIG_FUNC_TRANSCEIVE CONSTANT_64BIT_FLAG (42) /*!< \c TRANSCEIVE -- Send radio state changes automatically ON/OFF */ #define RIG_FUNC_SPECTRUM CONSTANT_64BIT_FLAG (43) /*!< \c SPECTRUM -- Spectrum scope data output ON/OFF */ #define RIG_FUNC_SPECTRUM_HOLD CONSTANT_64BIT_FLAG (44) /*!< \c SPECTRUM_HOLD -- Pause spectrum scope updates ON/OFF */ -#define RIG_FUNC_SEND_MORSE CONSTANT_64BIT_FLAG (45) /*!< \c SEND_MORSE -- Send specified characters using CW */ -#define RIG_FUNC_SEND_VOICE_MEM CONSTANT_64BIT_FLAG (46) /*!< \c SEND_VOICE_MEM -- Transmit in SSB message stored in memory */ -#define RIG_FUNC_BIT47 CONSTANT_64BIT_FLAG (47) /*!< \c available for future RIG_FUNC items */ +#define RIG_FUNC_SEND_MORSE CONSTANT_64BIT_FLAG (45) /*!< \c SEND_MORSE -- Send specified characters using CW */ +#define RIG_FUNC_SEND_VOICE_MEM CONSTANT_64BIT_FLAG (46) /*!< \c SEND_VOICE_MEM -- Transmit in SSB message stored in memory */ +#define RIG_FUNC_OVF_STATUS CONSTANT_64BIT_FLAG (47) /*!< \c OVF -- Read overflow status 0=Off, 1=On */ #define RIG_FUNC_BIT48 CONSTANT_64BIT_FLAG (48) /*!< \c available for future RIG_FUNC items */ #define RIG_FUNC_BIT49 CONSTANT_64BIT_FLAG (49) /*!< \c available for future RIG_FUNC items */ #define RIG_FUNC_BIT50 CONSTANT_64BIT_FLAG (50) /*!< \c available for future RIG_FUNC items */ diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 143aeab1..2fcb1c55 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -52,7 +52,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, #define IC7300_OTHER_TX_MODES (RIG_MODE_FM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR) #define IC7300_AM_TX_MODES (RIG_MODE_AM|RIG_MODE_PKTAM) -#define IC7300_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_SCOPE|RIG_FUNC_TUNER|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM) +#define IC7300_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_SCOPE|RIG_FUNC_TUNER|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM|RIG_FUNC_OVF_STATUS) #define IC7300_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF|RIG_LEVEL_AGC_TIME) @@ -146,7 +146,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, */ #define IC9700_VFOS (RIG_VFO_A|RIG_VFO_B|RIG_VFO_MAIN|RIG_VFO_SUB|RIG_VFO_MEM|RIG_VFO_MAIN_A|RIG_VFO_MAIN_B|RIG_VFO_SUB_A|RIG_VFO_SUB_B) #define IC9700_PARMS (RIG_PARM_ANN|RIG_PARM_BACKLIGHT|RIG_PARM_TIME|RIG_PARM_BEEP|RIG_PARM_SCREENSAVER) -#define IC9700_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_SCOPE|RIG_FUNC_SATMODE|RIG_FUNC_DUAL_WATCH|RIG_FUNC_AFC|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM) +#define IC9700_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_SCOPE|RIG_FUNC_SATMODE|RIG_FUNC_DUAL_WATCH|RIG_FUNC_AFC|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM|RIG_FUNC_OVF_STATUS) #define IC9700_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF) #define IC9700_VFO_OPS (RIG_OP_CPY|RIG_OP_XCHG|RIG_OP_FROM_VFO|RIG_OP_TO_VFO|RIG_OP_MCL) #define IC9700_SCAN_OPS (RIG_SCAN_STOP|RIG_SCAN_MEM|RIG_SCAN_PROG|RIG_SCAN_SLCT) @@ -549,7 +549,7 @@ const struct rig_caps ic7300_caps = RIG_MODEL(RIG_MODEL_IC7300), .model_name = "IC-7300", .mfg_name = "Icom", - .version = BACKEND_VER ".9", + .version = BACKEND_VER ".10", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -786,7 +786,7 @@ struct rig_caps ic9700_caps = RIG_MODEL(RIG_MODEL_IC9700), .model_name = "IC-9700", .mfg_name = "Icom", - .version = BACKEND_VER ".10", + .version = BACKEND_VER ".11", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1099,7 +1099,7 @@ const struct rig_caps ic705_caps = RIG_MODEL(RIG_MODEL_IC705), .model_name = "IC-705", .mfg_name = "Icom", - .version = BACKEND_VER ".7", + .version = BACKEND_VER ".8", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, diff --git a/rigs/icom/ic7610.c b/rigs/icom/ic7610.c index b273bf33..2079f60d 100644 --- a/rigs/icom/ic7610.c +++ b/rigs/icom/ic7610.c @@ -39,7 +39,7 @@ #define IC7610_OTHER_TX_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_FM|RIG_MODE_PSK|RIG_MODE_PSKR|RIG_MODE_PKTLSB|RIG_MODE_PKTUSB|RIG_MODE_PKTFM) #define IC7610_AM_TX_MODES (RIG_MODE_AM|RIG_MODE_PKTAM) -#define IC7610_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_TUNER|RIG_FUNC_APF|RIG_FUNC_DUAL_WATCH|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD) +#define IC7610_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_TUNER|RIG_FUNC_APF|RIG_FUNC_DUAL_WATCH|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_OVF_STATUS) #define IC7610_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_BALANCE|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH) @@ -350,7 +350,7 @@ const struct rig_caps ic7610_caps = RIG_MODEL(RIG_MODEL_IC7610), .model_name = "IC-7610", .mfg_name = "Icom", - .version = BACKEND_VER ".8", + .version = BACKEND_VER ".9", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index ad142127..2dd50a07 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -7338,6 +7338,13 @@ int icom_get_func(RIG *rig, vfo_t vfo, setting_t func, int *status) break; + case RIG_FUNC_OVF_STATUS: + { + fct_cn = C_RD_SQSM; + fct_sc = S_OVF; + break; + } + default: rig_debug(RIG_DEBUG_ERR, "%s: unsupported get_func %s\n", __func__, rig_strfunc(func)); diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 8e232e8f..4373583f 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20220909" +#define BACKEND_VER "20221104" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) diff --git a/rigs/icom/icr8600.c b/rigs/icom/icr8600.c index 90c360c8..aaa60787 100644 --- a/rigs/icom/icr8600.c +++ b/rigs/icom/icr8600.c @@ -37,7 +37,7 @@ #define ICR8600_FUNC_ALL (RIG_FUNC_NB|RIG_FUNC_ANF|RIG_FUNC_MN|RIG_FUNC_AFC|\ RIG_FUNC_NR|RIG_FUNC_AIP|RIG_FUNC_LOCK|RIG_FUNC_VSC|RIG_FUNC_RESUME|RIG_FUNC_TSQL|\ - RIG_FUNC_CSQL|RIG_FUNC_DSQL|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD) + RIG_FUNC_CSQL|RIG_FUNC_DSQL|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_OVF_STATUS) #define ICR8600_LEVEL_ALL (RIG_LEVEL_ATT|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|\ RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_PREAMP|\ @@ -132,7 +132,7 @@ const struct rig_caps icr8600_caps = RIG_MODEL(RIG_MODEL_ICR8600), .model_name = "IC-R8600", .mfg_name = "Icom", - .version = BACKEND_VER ".2", + .version = BACKEND_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_BETA, .rig_type = RIG_TYPE_RECEIVER, diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index 0b19acf6..f19be87c 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -35,6 +35,7 @@ int ant_option = 0; int ptt = 0; int satmode = 0; int agc_time = 1; +int ovf_status = 0; void dumphex(unsigned char *buf, int n) { @@ -226,6 +227,13 @@ void frameParse(int fd, unsigned char *frame, int len) { static int meter_level = 0; + case 0x07: + frame[6] = ovf_status; + frame[7] = 0xfd; + n = write(fd, frame, 8); + ovf_status = ovf_status==0?1:0; + break; + case 0x11: printf("Using meter level %d\n", meter_level); meter_level += 10; diff --git a/src/misc.c b/src/misc.c index 2946ec69..c0ab5071 100644 --- a/src/misc.c +++ b/src/misc.c @@ -736,6 +736,7 @@ static const struct { RIG_FUNC_SPECTRUM_HOLD, "SPECTRUM_HOLD" }, { RIG_FUNC_SEND_MORSE, "SEND_MORSE" }, { RIG_FUNC_SEND_VOICE_MEM, "SEND_VOICE_MEM" }, + { RIG_FUNC_OVF_STATUS, "OVF_STATUS" }, { RIG_FUNC_NONE, "" }, }; commit 8789321465b0a6b9128ad09f86032668e134ee34 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 22:41:02 2022 -0500 Add ID 800 for FT710 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index dd67ff66..560cb290 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -68,7 +68,8 @@ typedef enum nc_rigid_e NC_RIGID_FTDX3000 = 460, NC_RIGID_FTDX3000DM = 462, // an undocumented FT-DX3000DM 50W rig NC_RIGID_FTDX101D = 681, - NC_RIGID_FTDX101MP = 682 + NC_RIGID_FTDX101MP = 682, + NC_RIGID_FT710 = 800, } nc_rigid_t; @@ -10484,7 +10485,7 @@ int newcat_set_cmd_validate(RIG *rig) // For FA and FB rig.c now tries to verify the set_freq actually works // For example the FT-2000 can't do a FA set followed by an immediate read // We were using "ID" to verify the command but rig.c now does - // a verifcation of frequency and retries if it doesn't match + // a verification of frequency and retries if it doesn't match if ((strncmp(priv->cmd_str, "FA", 2) == 0) && (strlen(priv->cmd_str) > 3)) { strcpy(valcmd, "FA;"); diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 76547210..68b64270 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20221025" +#define NEWCAT_VER "20221104" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit bf22bc4b02d6a89ac21536e09a61d51a4ca540d0 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 13:26:52 2022 -0500 Fix flrig get_ptt https://github.com/Hamlib/Hamlib/issues/1138 diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index f3fa1286..507d6cc0 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -141,7 +141,7 @@ const struct rig_caps flrig_caps = RIG_MODEL(RIG_MODEL_FLRIG), .model_name = "FLRig", .mfg_name = "FLRig", - .version = "20221030.0", + .version = "20221104.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1308,7 +1308,7 @@ static int flrig_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt) RETURNFUNC(retval); } - if (strlen(xml) > 0) + if (strlen(value) > 0) { xml_parse(xml, value, sizeof(value)); *ptt = atoi(value); commit 3c3112ddc601a411137c358e36ded3358efe2236 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 10:52:16 2022 -0500 Update NEWS diff --git a/NEWS b/NEWS index 73490b44..07908008 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,7 @@ Version 4.6 * 2023-XX-XX * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF + * Add RIG_LEVEL_AGC_TIME to allow AGC/OFF to be set for IC-7300, IC-9700, IC-705 Version 4.5 commit d311153f6386a77508943368e536193c50e4ffb8 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 10:49:14 2022 -0500 Add AGC_TIME to IC-7300, IC-9700, and IC-705 https://github.com/Hamlib/Hamlib/issues/1136 diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index e1678106..6f1474ab 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -598,10 +598,8 @@ typedef unsigned int vfo_t; */ typedef shortfreq_t pbwidth_t; +typedef float agc_time_t; -/** - * \brief DCD status - */ typedef enum dcd_e { RIG_DCD_OFF = 0, /*!< Squelch closed */ RIG_DCD_ON /*!< Squelch open */ @@ -1005,7 +1003,7 @@ typedef uint64_t rig_level_e; #define RIG_LEVEL_TEMP_METER CONSTANT_64BIT_FLAG(48) /*!< \c TEMP_METER -- arg float (C, centigrade) */ #define RIG_LEVEL_BAND_SELECT CONSTANT_64BIT_FLAG(49) /*!< \c BAND_SELECT -- arg enum BAND_ENUM */ #define RIG_LEVEL_USB_AF CONSTANT_64BIT_FLAG(50) /*!< \c ACC/USB AF output level */ -#define RIG_LEVEL_51 CONSTANT_64BIT_FLAG(51) /*!< \c Future use */ +#define RIG_LEVEL_AGC_TIME CONSTANT_64BIT_FLAG(51) /*!< \c AGC_TIME -- in seconds, rig dependent */ #define RIG_LEVEL_52 CONSTANT_64BIT_FLAG(52) /*!< \c Future use */ #define RIG_LEVEL_53 CONSTANT_64BIT_FLAG(53) /*!< \c Future use */ #define RIG_LEVEL_54 CONSTANT_64BIT_FLAG(54) /*!< \c Future use */ @@ -1020,7 +1018,7 @@ typedef uint64_t rig_level_e; #define RIG_LEVEL_63 CONSTANT_64BIT_FLAG(63) /*!< \c Future use */ //! @cond Doxygen_Suppress -#define RIG_LEVEL_FLOAT_LIST (RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_APF|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_COMP|RIG_LEVEL_BALANCE|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_TEMP_METER|RIG_LEVEL_USB_AF) +#define RIG_LEVEL_FLOAT_LIST (RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_APF|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_COMP|RIG_LEVEL_BALANCE|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_TEMP_METER|RIG_LEVEL_USB_AF|RIG_LEVEL_AGC_TIME) #define RIG_LEVEL_READONLY_LIST (RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_STRENGTH|RIG_LEVEL_RAWSTR|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER) diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index b3f6a8c5..143aeab1 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -54,7 +54,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, #define IC7300_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_SCOPE|RIG_FUNC_TUNER|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM) -#define IC7300_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF) +#define IC7300_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF|RIG_LEVEL_AGC_TIME) #define IC7300_VFOS (RIG_VFO_A|RIG_VFO_B|RIG_VFO_MEM) #define IC7300_PARMS (RIG_PARM_ANN|RIG_PARM_BACKLIGHT|RIG_PARM_TIME|RIG_PARM_BEEP) @@ -255,7 +255,7 @@ struct cmdparams ic705_extcmds[] = { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x31}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x78}, CMD_DAT_INT, 1 }, { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x13}, CMD_DAT_LVL, 2 }, - { {0} } + { {.s = RIG_PARM_NONE} } }; int ic7300_ext_tokens[] = @@ -284,7 +284,7 @@ static const struct icom_priv_caps IC7300_priv_caps = ic7300_ts_sc_list, .agc_levels_present = 1, .agc_levels = { - { .level = RIG_AGC_OFF, .icom_level = 0 }, + { .level = RIG_AGC_OFF, .icom_level = 0 }, // note this is handled by AGC time constant instead { .level = RIG_AGC_FAST, .icom_level = 1 }, { .level = RIG_AGC_MEDIUM, .icom_level = 2 }, { .level = RIG_AGC_SLOW, .icom_level = 3 }, @@ -382,6 +382,7 @@ static const struct icom_priv_caps IC9700_priv_caps = .serial_USB_echo_check = 1, /* USB CI-V may not echo */ .agc_levels_present = 1, .agc_levels = { + { .level = RIG_AGC_OFF, .icom_level = 0 }, // note this is handled by AGC time constant instead { .level = RIG_AGC_FAST, .icom_level = 1 }, { .level = RIG_AGC_MEDIUM, .icom_level = 2 }, { .level = RIG_AGC_SLOW, .icom_level = 3 }, @@ -429,6 +430,7 @@ static const struct icom_priv_caps IC705_priv_caps = .serial_USB_echo_check = 1, /* USB CI-V may not echo */ .agc_levels_present = 1, .agc_levels = { + { .level = RIG_AGC_OFF, .icom_level = 0 }, { .level = RIG_AGC_FAST, .icom_level = 1 }, { .level = RIG_AGC_MEDIUM, .icom_level = 2 }, { .level = RIG_AGC_SLOW, .icom_level = 3 }, @@ -579,7 +581,8 @@ const struct rig_caps ic7300_caps = [LVL_SPECTRUM_SPEED] = {.min = {.i = 0}, .max = {.i = 2}, .step = {.i = 1}}, [LVL_SPECTRUM_REF] = {.min = {.f = -20.0f}, .max = {.f = 20.0f}, .step = {.f = 0.5f}}, [LVL_SPECTRUM_AVG] = {.min = {.i = 0}, .max = {.i = 3}, .step = {.i = 1}}, - [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f/255.0f }}, + [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f / 255.0f }}, + [LVL_AGC_TIME] = {.min = {.f = 0.0f}, .max = {.f = 8.0f}, .step = {.f = 0.1f }}, }, .parm_gran = {}, .ext_tokens = ic7300_ext_tokens, @@ -592,7 +595,7 @@ const struct rig_caps ic7300_caps = .max_xit = Hz(9999), .max_ifshift = Hz(0), .agc_level_count = 3, - .agc_levels = { RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, + .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, .vfo_ops = IC7300_VFO_OPS, .scan_ops = IC7300_SCAN_OPS, @@ -814,7 +817,8 @@ struct rig_caps ic9700_caps = [LVL_SPECTRUM_SPEED] = {.min = {.i = 0}, .max = {.i = 2}, .step = {.i = 1}}, [LVL_SPECTRUM_REF] = {.min = {.f = -20.0f}, .max = {.f = 20.0f}, .step = {.f = 0.5f}}, [LVL_SPECTRUM_AVG] = {.min = {.i = 0}, .max = {.i = 3}, .step = {.i = 1}}, - [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f/255.0f }}, + [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f / 255.0f }}, + [LVL_AGC_TIME] = {.min = {.f = 0.0f}, .max = {.f = 8.0f}, .step = {.f = 0.1f }}, }, .parm_gran = {}, .ext_tokens = ic9700_ext_tokens, @@ -827,7 +831,7 @@ struct rig_caps ic9700_caps = .max_xit = Hz(9999), .max_ifshift = Hz(0), .agc_level_count = 3, - .agc_levels = { RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, + .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_SPECTRUM, .vfo_ops = IC9700_VFO_OPS, .scan_ops = IC9700_SCAN_OPS, @@ -1126,7 +1130,8 @@ const struct rig_caps ic705_caps = [LVL_SPECTRUM_SPEED] = {.min = {.i = 0}, .max = {.i = 2}, .step = {.i = 1}}, [LVL_SPECTRUM_REF] = {.min = {.f = -20.0f}, .max = {.f = 20.0f}, .step = {.f = 0.5f}}, [LVL_SPECTRUM_AVG] = {.min = {.i = 0}, .max = {.i = 3}, .step = {.i = 1}}, - [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f/255.0f }}, + [LVL_USB_AF] = {.min = {.f = 0.0f}, .max = {.f = 1.0f}, .step = {.f = 1.0f / 255.0f }}, + [LVL_AGC_TIME] = {.min = {.f = 0.0f}, .max = {.f = 8.0f}, .step = {.f = 0.1f }}, }, .parm_gran = {}, .ext_tokens = ic705_ext_tokens, @@ -1139,7 +1144,7 @@ const struct rig_caps ic705_caps = .max_xit = Hz(9999), .max_ifshift = Hz(0), .agc_level_count = 3, - .agc_levels = { RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, + .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW }, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, .vfo_ops = IC7300_VFO_OPS, .scan_ops = IC7300_SCAN_OPS, diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index f9ff2b77..ad142127 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -418,6 +418,16 @@ const pbwidth_t rtty_fil[] = 0, }; +/* AGC Time value lookups */ +const agc_time_t agc_level[] = // default +{ + 0, 0.1, 0.2, 0.3, 0.5, 0.8, 1.2, 1.6, 2.0, 2.5, 3.0, 4.0, 5.0, 6.0 +}; +const agc_time_t agc_level2[] = // AM Mode for 7300/9700/705 +{ + 0, 0.3, 0.5, 0.8, 1.2, 1.6, 2.0, 2.5, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 +}; + struct icom_addr { rig_model_t model; @@ -3450,6 +3460,33 @@ int icom_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) lvl_sc = S_LVL_COMP; break; + case RIG_LEVEL_AGC_TIME: + lvl_cn = C_CTL_MEM; + lvl_sc = 0x04; + cmd_len = 1; + { + int i; + icom_val = 0; + const float *agcp = agc_level; + + if (rig->state.current_mode == RIG_MODE_AM) { agcp = agc_level2; } + + rig_debug(RIG_DEBUG_ERR, "%s: val.f=%g\n", __func__, val.f); + + for (i = 0; i <= 13; ++i) + { + if (agcp[i] <= val.f) + { + rig_debug(RIG_DEBUG_ERR, "%s: agcp=%g <= val.f=%g at %d\n", __func__, agcp[i], + val.f, i); + icom_val = i; + } + } + + cmdbuf[0] = icom_val; + } + break; + case RIG_LEVEL_AGC: lvl_cn = C_CTL_FUNC; lvl_sc = S_FUNC_AGC; @@ -4058,6 +4095,13 @@ int icom_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) break; + case RIG_LEVEL_AGC_TIME: + lvl_cn = C_CTL_MEM; + lvl_sc = 0x04; // IC-9700, 7300, 705 so far + cmd_len = 0; + + break; + default: rig_debug(RIG_DEBUG_ERR, "%s: unsupported get_level %s\n", __func__, rig_strlevel(level)); @@ -4358,6 +4402,20 @@ int icom_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) val->i = (int) from_bcd(respbuf + cmdhead + 5, 5 * 2); break; + case RIG_LEVEL_AGC_TIME: + + // some rigs have different level interpretaions for different modes + if (rig->state.current_mode == RIG_MODE_AM) + { + val->f = agc_level2[icom_val]; + } + else + { + val->f = agc_level[icom_val]; + } + + break; + /* RIG_LEVEL_ATT/RIG_LEVEL_SPECTRUM_ATT: returned value is already an integer in dB (coded in BCD) */ default: if (RIG_LEVEL_IS_FLOAT(level)) @@ -8001,6 +8059,7 @@ int icom_get_powerstat(RIG *rig, powerstat_t *status) *status = ((ack_len == 6) && (ackbuf[0] == C_CTL_MEM)) ? RIG_POWER_ON : RIG_POWER_OFF; } + if (rig->caps->rig_model == RIG_MODEL_IC7300) { freq_t freq; diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index 963f2113..0b19acf6 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -24,8 +24,8 @@ int split = 0; // we make B different from A to ensure we see a difference at startup float freqA = 14074000; float freqB = 14074500; -mode_t modeA = RIG_MODE_CW; -mode_t modeB = RIG_MODE_USB; +mode_t modeA = RIG_MODE_PKTUSB; +mode_t modeB = RIG_MODE_PKTUSB; int datamodeA = 0; int datamodeB = 0; pbwidth_t widthA = 0; @@ -34,6 +34,7 @@ ant_t ant_curr = 0; int ant_option = 0; int ptt = 0; int satmode = 0; +int agc_time = 1; void dumphex(unsigned char *buf, int n) { @@ -274,15 +275,28 @@ void frameParse(int fd, unsigned char *frame, int len) n = write(fd, frame, 8); break; - case 0x04: // IC7200 data mode - frame[6] = 0; - frame[7] = 0; - frame[8] = 0xfd; - n = write(fd, frame, 9); + case 0x04: // AGC TIME + printf("frame[6]==x%02x, frame[7]=0%02x\n", frame[6], frame[7]); + + if (frame[6] == 0xfd) // the we are reading + { + frame[6] = agc_time; + frame[7] = 0xfd; + n = write(fd, frame, 8); + } + else + { + printf("AGC_TIME RESPONSE******************************"); + agc_time = frame[6]; + frame[4] = 0xfb; + frame[5] = 0xfd; + n = write(fd, frame, 6); + } + break; case 0x07: // satmode - frame[6] = 0; + frame[4] = 0; frame[7] = 0xfd; n = write(fd, frame, 8); break; @@ -412,6 +426,8 @@ void frameParse(int fd, unsigned char *frame, int len) default: printf("cmd 0x%02x unknown\n", frame[4]); } + if (n == 0) { printf("Write failed?\n"); } + // don't care about the rig type yet } diff --git a/src/idx_builtin.h b/src/idx_builtin.h index 0585c916..004bdbbf 100644 --- a/src/idx_builtin.h +++ b/src/idx_builtin.h @@ -164,7 +164,7 @@ #define LVL_SPECTRUM_ATT setting2idx_builtin(RIG_LEVEL_SPECTRUM_ATT) #define LVL_USB_AF setting2idx_builtin(RIG_LEVEL_USB_AF) -#define LVL_49 setting2idx_builtin(RIG_LEVEL_49) +#define LVL_AGC_TIME setting2idx_builtin(RIG_LEVEL_AGC_TIME) #define LVL_50 setting2idx_builtin(RIG_LEVEL_50) #define LVL_51 setting2idx_builtin(RIG_LEVEL_51) #define LVL_52 setting2idx_builtin(RIG_LEVEL_52) diff --git a/src/misc.c b/src/misc.c index 91cc8d04..2946ec69 100644 --- a/src/misc.c +++ b/src/misc.c @@ -926,6 +926,7 @@ static const struct { RIG_LEVEL_TEMP_METER, "TEMP_METER" }, { RIG_LEVEL_BAND_SELECT, "BAND_SELECT" }, { RIG_LEVEL_USB_AF, "USB_AF" }, + { RIG_LEVEL_AGC_TIME, "AGC_TIME" }, { RIG_LEVEL_NONE, "" }, }; commit dac5175cad340df649fb9a674257259b5d4aa773 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Nov 4 10:12:09 2022 -0500 Add simft747gx.c diff --git a/simulators/simft747gx.c b/simulators/simft747gx.c new file mode 100644 index 00000000..a0ce5cb8 --- /dev/null +++ b/simulators/simft747gx.c @@ -0,0 +1,180 @@ +// can run this using rigctl/rigctld and socat pty devices +// gcc -o simft897 simft897.c +#define _XOPEN_SOURCE 600 +#include <stdio.h> +#include <stdlib.h> +#include <fcntl.h> +#include <string.h> +#include <unistd.h> +#include "../include/hamlib/rig.h" + +#define BUFSIZE 256 + +float freqA = 14074000; +float freqB = 14074500; +char tx_vfo = '0'; +char rx_vfo = '0'; +char modeA = '1'; +char modeB = '1'; +int width_main = 500; +int width_sub = 700; + + +int +getmyline(int fd, unsigned char *buf) +{ + unsigned char c; + int i = 0; + int n = 0; + memset(buf, 0, BUFSIZE); + + while (read(fd, &c, 1) > 0 && i < 5) + { + buf[i++] = c; + n++; + } + + printf("n=%d %02x %02x %02x %02x %02x\n", n, buf[0], buf[1], buf[2], buf[3], + buf[4]); + return n; +} + +#if defined(WIN32) || defined(_WIN32) +int openPort(char *comport) // doesn't matter for using pts devices +{ + int fd; + fd = open(comport, O_RDWR); + + if (fd < 0) + { + perror(comport); + } + + return fd; +} + +#else +int openPort(char *comport) // doesn't matter for using pts devices +{ + int fd = posix_openpt(O_RDWR); + char *name = ptsname(fd); + + if (name == NULL) + { + perror("pstname"); + return -1; + } + + printf("name=%s\n", name); + + if (fd == -1 || grantpt(fd) == -1 || unlockpt(fd) == -1) + { + perror("posix_openpt"); + return -1; + } + + return fd; +} +#endif + + + +int main(int argc, char *argv[]) +{ + unsigned char buf[256]; + unsigned char *pbuf; + int n; + + +again: + int fd = openPort(argv[1]); + + while (1) + { + int bytes = getmyline(fd, buf); + + if (bytes == 0) + { + close(fd); + goto again; + } + + if (bytes != 5) + { + printf("Not 5 bytes? bytes=%d\n", bytes); + } + + switch (buf[4]) + { + case 0x01: + printf("SPLIT\n"); + break; + + case 0x02: + printf("MEMORY\n"); + break; + + case 0x03: + printf("VFO_TO_M\n"); + break; + + case 0x04: + printf("DLOCK\n"); + break; + + case 0x05: + printf("A_BVFO\n"); + break; + + case 0x06: + printf("M_TO_VFO\n"); + break; + + case 0x07: + printf("UP500K\n"); + break; + + case 0x08: + printf("DN500K\n"); + break; + + case 0x09: + printf("CLAR\n"); + break; + + case 0x0a: + printf("FREQ_SET\n"); + break; + + case 0x0c: + printf("MODE_SET\n"); + break; + + case 0x0e: + printf("PACING\n"); // no reply + break; + + case 0x0f: + printf("PTT\n"); + break; + + case 0x10: + printf("UPDATE\n"); + buf[0] = 0x01; // status byte -- split on + buf[1] = 0x14; + buf[2] = 0x07; + buf[3] = 0x41; + buf[4] = 0x02; + write(fd, buf, 5); + buf[0] = 0; + + for (int i = 5; i < 340; ++i) { write(fd, buf, 1); } + + break; + + default: printf("Unknown cmd=%02x\n", buf[4]); + } + } + + return 0; +} commit a397b39ca3f3143abda61346f8b253032b4eb3da Merge: eff048d7 aedf39ad Author: Michael Black <mdb...@ya...> Date: Fri Nov 4 08:47:45 2022 -0500 Merge pull request #1137 from PianetaRadio/master Update netrotctl.c commit aedf39adc2c30a95a944e130b5d7398a77aab7d4 Author: PianetaRadio <789...@us...> Date: Fri Nov 4 11:32:39 2022 +0100 Update netrotctl.c Add south_zero from dump_state in open function diff --git a/rigs/dummy/netrotctl.c b/rigs/dummy/netrotctl.c index 38b64554..16b6c22e 100644 --- a/rigs/dummy/netrotctl.c +++ b/rigs/dummy/netrotctl.c @@ -144,6 +144,16 @@ static int netrotctl_open(ROT *rot) } rs->max_el = rot->caps->max_el = atof(buf); + + ret = read_string(&rot->state.rotport, (unsigned char *) buf, BUF_MAX, "\n", + sizeof("\n"), 0, 1); + + if (ret <= 0) + { + return (ret < 0) ? ret : -RIG_EPROTO; + } + + rs->south_zero = atoi(buf); return RIG_OK; } commit eff048d729dd56f86aead6c4c670bc8435a1a22e Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 14:57:37 2022 -0500 Add AGC_OFF to IC7300 agc levels diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 7f954412..b3f6a8c5 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -284,6 +284,7 @@ static const struct icom_priv_caps IC7300_priv_caps = ic7300_ts_sc_list, .agc_levels_present = 1, .agc_levels = { + { .level = RIG_AGC_OFF, .icom_level = 0 }, { .level = RIG_AGC_FAST, .icom_level = 1 }, { .level = RIG_AGC_MEDIUM, .icom_level = 2 }, { .level = RIG_AGC_SLOW, .icom_level = 3 }, commit b2cf596b5494d6201f8d506a881bb8aaf3df7970 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 14:51:47 2022 -0500 IC7300 cannot get powerstat so use get_freq instead. There are likely more Icom rigs like this diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 987008aa..f9ff2b77 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -8001,6 +8001,12 @@ int icom_get_powerstat(RIG *rig, powerstat_t *status) *status = ((ack_len == 6) && (ackbuf[0] == C_CTL_MEM)) ? RIG_POWER_ON : RIG_POWER_OFF; } + if (rig->caps->rig_model == RIG_MODEL_IC7300) + { + freq_t freq; + int retval = rig_get_freq(rig, RIG_VFO_A, &freq); + return retval; + } else { retval = icom_transaction(rig, C_SET_PWR, -1, NULL, 0, commit 790bf7704c8a175aabfe8cd54ec267c0d5b7fbd3 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 12:27:33 2022 -0500 Remove debug from misc.c diff --git a/src/misc.c b/src/misc.c index 1ec46810..91cc8d04 100644 --- a/src/misc.c +++ b/src/misc.c @@ -1051,7 +1051,7 @@ const char *HAMLIB_API rig_strlevel(setting_t level) { int i; - rig_debug(RIG_DEBUG_VERBOSE, "%s called level=%lx\n", __func__, level); + rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); if (level == RIG_LEVEL_NONE) { commit 0d73bb22a080ea04b489f723cdbac6ee4c5744a2 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 12:25:42 2022 -0500 Fix LEVEL_USB_AF https://github.com/Hamlib/Hamlib/issues/1135 diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 187e5d2a..7f954412 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -226,7 +226,7 @@ struct cmdparams ic7300_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x59}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x71}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x02}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x60}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x60}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_NONE} } }; @@ -240,7 +240,7 @@ struct cmdparams ic9700_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x03, 0x30}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x27}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x92}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x06}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x06}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_NONE} } }; @@ -254,7 +254,7 @@ struct cmdparams ic705_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x03, 0x59}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x31}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x78}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x13}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x13}, CMD_DAT_LVL, 2 }, { {0} } }; diff --git a/rigs/icom/ic7610.c b/rigs/icom/ic7610.c index e84a6714..b273bf33 100644 --- a/rigs/icom/ic7610.c +++ b/rigs/icom/ic7610.c @@ -137,7 +137,7 @@ struct cmdparams ic7610_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x02, 0x92}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x12}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x70}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x82}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x82}, CMD_DAT_LVL, 2 }, { { 0 } } }; diff --git a/rigs/icom/ic785x.c b/rigs/icom/ic785x.c index c5acc0ca..7b9b4b61 100644 --- a/rigs/icom/ic785x.c +++ b/rigs/icom/ic785x.c @@ -128,7 +128,7 @@ struct cmdparams ic785x_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x03, 0x09}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x55}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x87}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x52}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x52}, CMD_DAT_LVL, 2 }, { { 0 } } }; diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 4b04e5cb..987008aa 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -4051,6 +4051,13 @@ int icom_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) cmdbuf[0] = icom_get_spectrum_vfo(rig, vfo); break; + case RIG_LEVEL_USB_AF: + lvl_cn = C_CTL_SCP; + lvl_sc = S_SCP_ATT; + cmd_len = 1; + + break; + default: rig_debug(RIG_DEBUG_ERR, "%s: unsupported get_level %s\n", __func__, rig_strlevel(level)); diff --git a/rigs/icom/icr8600.c b/rigs/icom/icr8600.c index 39f2bf78..90c360c8 100644 --- a/rigs/icom/icr8600.c +++ b/rigs/icom/icr8600.c @@ -70,7 +70,7 @@ struct cmdparams icr8600_extcmds[] = { {.s = RIG_PARM_TIME}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x32}, CMD_DAT_TIM, 2 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x92}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x40}, CMD_DAT_INT, 1 }, - { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x81}, CMD_DAT_LVL, 2 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x81}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_NONE} } }; diff --git a/src/misc.c b/src/misc.c index 91cc8d04..1ec46810 100644 --- a/src/misc.c +++ b/src/misc.c @@ -1051,7 +1051,7 @@ const char *HAMLIB_API rig_strlevel(setting_t level) { int i; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + rig_debug(RIG_DEBUG_VERBOSE, "%s called level=%lx\n", __func__, level); if (level == RIG_LEVEL_NONE) { diff --git a/src/sprintflst.h b/src/sprintflst.h index 940a378f..919ee896 100644 --- a/src/sprintflst.h +++ b/src/sprintflst.h @@ -25,7 +25,7 @@ #include <hamlib/rig.h> #include <hamlib/rotator.h> -#define SPRINTF_MAX_SIZE 512 +#define SPRINTF_MAX_SIZE 1024 __BEGIN_DECLS commit eb667185ef587323809a298e171d2e538e2005cd Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 10:34:45 2022 -0500 Update simicom9700.c diff --git a/simulators/simicom9700.c b/simulators/simicom9700.c index 35502894..963f2113 100644 --- a/simulators/simicom9700.c +++ b/simulators/simicom9700.c @@ -257,6 +257,11 @@ void frameParse(int fd, unsigned char *frame, int len) break; + case 0x18: // miscellaneous things + frame[5] = 1; + frame[6] = 0xfd; + n = write(fd, frame, 7); + break; case 0x1a: // miscellaneous things switch (frame[5]) commit 2a30396d70dda90ae8e2218bf761b0ffc7ee5e8d Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Nov 1 09:14:19 2022 -0500 Add RIG_LEVEL_USB_AF for IC-705, IC-7300, IC-9700, IC-785x, and IC-R8600 In combination with RIG_LEVEL_RF we should be able to create an AGC control for WSJTX and JTDX for example to keep audio levels within a good A/D range automagically https://github.com/Hamlib/Hamlib/issues/1135 diff --git a/NEWS b/NEWS index ccad1326..73490b44 100644 --- a/NEWS +++ b/NEWS @@ -15,6 +15,7 @@ Version 5.x -- future Version 4.6 * 2023-XX-XX * rigctl 'W' command can now use a singled char terminator like ; that allows for variable length responses with no timeout -- e.g. W FA; ; + * New RIG_LEVEL_USB_AF to control audio gain from rig to computer -- to allow AGC function in software using RF and USB_AF Version 4.5 diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index 29ad2090..b29f030a 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -847,13 +847,17 @@ Set and .RI \(aq "Level Value" \(aq. .IP -Level is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOX\(cq, \(oqAF\(cq, +Level is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOXDELAY\(cq, \(oqAF\(cq, \(oqRF\(cq, \(oqSQL\(cq, \(oqIF\(cq, \(oqAPF\(cq, \(oqNR\(cq, \(oqPBT_IN\(cq, -\(oqPBT_OUT\(cq, \(oqCWPITCH\(cq, \(oqRFPOWER\(cq, \(oqRFPOWER_METER\(cq, \(oqRFPOWER_METER_WATTS\(cq, \(oqMICGAIN\(cq, +\(oqPBT_OUT\(cq, \(oqCWPITCH\(cq, \(oqRFPOWER\(cq, \(oqMICGAIN\(cq, \(oqKEYSPD\(cq, \(oqNOTCHF\(cq, \(oqCOMP\(cq, \(oqAGC\(cq, \(oqBKINDL\(cq, \(oqBAL\(cq, \(oqMETER\(cq, \(oqVOXGAIN\(cq, \(oqANTIVOX\(cq, -\(oqSLOPE_LOW\(cq, \(oqSLOPE_HIGH\(cq, \(oqRAWSTR\(cq, \(oqSWR\(cq, -\(oqALC\(cq, \(oqSTRENGTH\(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, +\(oqUSB_AF\(cq. .IP The Level Value can be a float or an integer value. For the AGC token the value is one of \(oq0\(cq = OFF, \(oq1\(cq = SUPERFAST, \(oq2\(cq = FAST, diff --git a/doc/man1/rigctld.1 b/doc/man1/rigctld.1 index 876518ef..391920a7 100644 --- a/doc/man1/rigctld.1 +++ b/doc/man1/rigctld.1 @@ -839,13 +839,17 @@ Set and .RI \(aq "Level Value" \(aq. .IP -Level is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOX\(cq, \(oqAF\(cq, +evel is a token: \(oqPREAMP\(cq, \(oqATT\(cq, \(oqVOXDELAY\(cq, \(oqAF\(cq, \(oqRF\(cq, \(oqSQL\(cq, \(oqIF\(cq, \(oqAPF\(cq, \(oqNR\(cq, \(oqPBT_IN\(cq, -\(oqPBT_OUT\(cq, \(oqCWPITCH\(cq, \(oqRFPOWER\(cq, \(oqRFPOWER_METER\(cq, \(oqRFPOWER_METER_WATTS\(cq, \(oqMICGAIN\(cq, +\(oqPBT_OUT\(cq, \(oqCWPITCH\(cq, \(oqRFPOWER\(cq, \(oqMICGAIN\(cq, \(oqKEYSPD\(cq, \(oqNOTCHF\(cq, \(oqCOMP\(cq, \(oqAGC\(cq, \(oqBKINDL\(cq, \(oqBAL\(cq, \(oqMETER\(cq, \(oqVOXGAIN\(cq, \(oqANTIVOX\(cq, -\(oqSLOPE_LOW\(cq, \(oqSLOPE_HIGH\(cq, \(oqRAWSTR\(cq, \(oqSWR\(cq, -\(oqALC\(cq, \(oqSTRENGTH\(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, +\(oqUSB_AF\(cq. .IP The Level Value can be a float or an integer value. For the AGC token the value is one of \(oq0\(cq = OFF, \(oq1\(cq = SUPERFAST, \(oq2\(cq = FAST, diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 8b7f72b4..e1678106 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -978,7 +978,7 @@ typedef uint64_t rig_level_e; #define RIG_LEVEL_SLOPE_HIGH CONSTANT_64BIT_FLAG(24) /*!< \c SLOPE_HIGH -- Slope tune, high frequency cut, arg int (Hz) */ #define RIG_LEVEL_BKIN_DLYMS CONSTANT_64BIT_FLAG(25) /*!< \c BKIN_DLYMS -- BKin Delay, arg int Milliseconds */ - /*!< These are not settable */ + /*!< Some of these are not settable after this point */ #define RIG_LEVEL_RAWSTR CONSTANT_64BIT_FLAG(26) /*!< \c RAWSTR -- Raw (A/D) value for signal strength, specific to each rig, arg int */ //#define RIG_LEVEL_SQLSTAT CONSTANT_64BIT_FLAG(27) /*!< \c SQLSTAT -- SQL status, arg int (open=1/closed=0). Deprecated, use get_dcd instead */ #define RIG_LEVEL_SWR CONSTANT_64BIT_FLAG(28) /*!< \c SWR -- SWR, arg float [0.0 ... infinite] */ @@ -1004,7 +1004,7 @@ typedef uint64_t rig_level_e; #define RIG_LEVEL_SPECTRUM_ATT CONSTANT_64BIT_FLAG(47) /*!< \c SPECTRUM_ATT -- Spectrum scope attenuator, arg int (dB). Supported attenuator values defined in rig caps. */ #define RIG_LEVEL_TEMP_METER CONSTANT_64BIT_FLAG(48) /*!< \c TEMP_METER -- arg float (C, centigrade) */ #define RIG_LEVEL_BAND_SELECT CONSTANT_64BIT_FLAG(49) /*!< \c BAND_SELECT -- arg enum BAND_ENUM */ -#define RIG_LEVEL_50 CONSTANT_64BIT_FLAG(50) /*!< \c Future use */ +#define RIG_LEVEL_USB_AF CONSTANT_64BIT_FLAG(50) /*!< \c ACC/USB AF output level */ #define RIG_LEVEL_51 CONSTANT_64BIT_FLAG(51) /*!< \c Future use */ #define RIG_LEVEL_52 CONSTANT_64BIT_FLAG(52) /*!< \c Future use */ #define RIG_LEVEL_53 CONSTANT_64BIT_FLAG(53) /*!< \c Future use */ @@ -1020,7 +1020,7 @@ typedef uint64_t rig_level_e; #define RIG_LEVEL_63 CONSTANT_64BIT_FLAG(63) /*!< \c Future use */ //! @cond Doxygen_Suppress -#define RIG_LEVEL_FLOAT_LIST (RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_APF|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_COMP|RIG_LEVEL_BALANCE|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_TEMP_METER) +#define RIG_LEVEL_FLOAT_LIST (RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_SQL|RIG_LEVEL_APF|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_COMP|RIG_LEVEL_BALANCE|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_TEMP_METER|RIG_LEVEL_USB_AF) #define RIG_LEVEL_READONLY_LIST (RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_STRENGTH|RIG_LEVEL_RAWSTR|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER) diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 19b276d0..187e5d2a 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -54,7 +54,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, #define IC7300_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_SCOPE|RIG_FUNC_TUNER|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM) -#define IC7300_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH) +#define IC7300_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF) #define IC7300_VFOS (RIG_VFO_A|RIG_VFO_B|RIG_VFO_MEM) #define IC7300_PARMS (RIG_PARM_ANN|RIG_PARM_BACKLIGHT|RIG_PARM_TIME|RIG_PARM_BEEP) @@ -147,7 +147,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, #define IC9700_VFOS (RIG_VFO_A|RIG_VFO_B|RIG_VFO_MAIN|RIG_VFO_SUB|RIG_VFO_MEM|RIG_VFO_MAIN_A|RIG_VFO_MAIN_B|RIG_VFO_SUB_A|RIG_VFO_SUB_B) #define IC9700_PARMS (RIG_PARM_ANN|RIG_PARM_BACKLIGHT|RIG_PARM_TIME|RIG_PARM_BEEP|RIG_PARM_SCREENSAVER) #define IC9700_FUNCS (RIG_FUNC_NB|RIG_FUNC_COMP|RIG_FUNC_VOX|RIG_FUNC_TONE|RIG_FUNC_TSQL|RIG_FUNC_SBKIN|RIG_FUNC_FBKIN|RIG_FUNC_NR|RIG_FUNC_MON|RIG_FUNC_MN|RIG_FUNC_ANF|RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_SCOPE|RIG_FUNC_SATMODE|RIG_FUNC_DUAL_WATCH|RIG_FUNC_AFC|RIG_FUNC_TRANSCEIVE|RIG_FUNC_SPECTRUM|RIG_FUNC_SPECTRUM_HOLD|RIG_FUNC_SEND_MORSE|RIG_FUNC_SEND_VOICE_MEM) -#define IC9700_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH) +#define IC9700_LEVELS (RIG_LEVEL_PREAMP|RIG_LEVEL_ATT|RIG_LEVEL_AGC|RIG_LEVEL_COMP|RIG_LEVEL_BKINDL|RIG_LEVEL_NR|RIG_LEVEL_PBT_IN|RIG_LEVEL_PBT_OUT|RIG_LEVEL_CWPITCH|RIG_LEVEL_RFPOWER|RIG_LEVEL_MICGAIN|RIG_LEVEL_KEYSPD|RIG_LEVEL_NOTCHF_RAW|RIG_LEVEL_SQL|RIG_LEVEL_RAWSTR|RIG_LEVEL_STRENGTH|RIG_LEVEL_AF|RIG_LEVEL_RF|RIG_LEVEL_VOXGAIN|RIG_LEVEL_ANTIVOX|RIG_LEVEL_VOXDELAY|RIG_LEVEL_SWR|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER_METER|RIG_LEVEL_RFPOWER_METER_WATTS|RIG_LEVEL_COMP_METER|RIG_LEVEL_VD_METER|RIG_LEVEL_ID_METER|RIG_LEVEL_MONITOR_GAIN|RIG_LEVEL_NB|RIG_LEVEL_SPECTRUM_MODE|RIG_LEVEL_SPECTRUM_SPAN|RIG_LEVEL_SPECTRUM_SPEED|RIG_LEVEL_SPECTRUM_REF|RIG_LEVEL_SPECTRUM_AVG|RIG_LEVEL_SPECTRUM_EDGE_LOW|RIG_LEVEL_SPECTRUM_EDGE_HIGH|RIG_LEVEL_USB_AF) #define IC9700_VFO_OPS (RIG_OP_CPY|RIG_OP_XCHG|RIG_OP_FROM_VFO|RIG_OP_TO_VFO|RIG_OP_MCL) #define IC9700_SCAN_OPS (RIG_SCAN_STOP|RIG_SCAN_MEM|RIG_SCAN_PROG|RIG_SCAN_SLCT) #define IC9700_ALL_TX_MODES (RIG_MODE_FM|RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_DSTAR|RIG_MODE_DD) @@ -226,6 +226,7 @@ struct cmdparams ic7300_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x59}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x71}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x02}, CMD_DAT_INT, 1 }, + { {.s = RIG_LEVEL_USB_AF}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x60}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_NONE} } }; @@ -239,7 +240,8 @@ struct cmdparams ic9700_extcmds[] = { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-10-30 01:06:14
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The annotated tag, 4.5 has been created at 61a02c500ce9c7b40003ccb9ff2fbf11d08dbff3 (tag) tagging 58f9fd41be46671d2254fa897200f9672c59f94e (commit) tagged by Nate Bargmann on Sat Oct 29 20:02:37 2022 -0500 - Log ----------------------------------------------------------------- Hamlib 4.5 release -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQSC1k9rDmfNQfaJu6b7LFEw1VqIGQUCY13NUAAKCRD7LFEw1VqI GdiZAJ9nXWKNFQq8UOmdvsoJuUnS4OlkkQCeMQ4BtiBvSi0Xqij1SV2USvvib1Q= =VmhK -----END PGP SIGNATURE----- (no author) (1): New repository initialized by cvs2svn. Adrian Chadd (1): Upgrade TS-711 and TS-811 to work. Agis Zisimatos (1): easycomm: Return the correct value of pointer val Alessandro Zummo, IZ1PRB (36): Remove const from priv_caps to allow kenwood_init to initialize default values if they're missing Call kenwood_init in each and every driver Use an appropriate debug level Support get/set_powerstat on pcr100 Add kenwood_simple_cmd Make set_ptt behave as before, fix set_ant for ts570.c ts450: remove RIG_FUNC_TONE from has_xx_func if tone unit is not detected ts450,ts690,ts850: use FL command to get/set filters in get/set_mode. (code from ts850.c) ts450: indentation fixes remove fixed command terminator (;) from generic code ts140,ts2000,ts480,ts570,ts680,ts850,ts870s: remove usage of fixed ; and EOM fix tabs thg71,tmv7,ts450s,ts690: verify rig id at rig_open ts450: implement set_channel remove unused parameter from get_kenwood_func ts570,ts850,ts870s,ts140,ts480,ts680: use kenwood_simple_cmd where possible Replace __FUNCTION__, which is gcc specific and was deprecated a long time ago, with __func__, which is at least defined in C99. generic, ts850: implemented CTCSS TN command (reported not working for ts850, should now be fixed) Add description for the kenwood mode n. 8 implemented set/get_ext_param (voice, fine, xit, rit). enabled on ts450 and ts850 Added my call sign removed comment about switch optimizatons. the compiler will generate the assembly code in a different order which is usually based on the case value. other compiler optimizations might also affect it, so it's useless to optimize the order. check ptt status before set_ptt. enabled on ts850. style fixes band up/down was inverted Try to compensate for leftover characters Try to cope withe the PCR100 and PCR1000 at the same time Bumped out to beta, solved a few bugs. Tested with PCR100/1000/1500. kenwood: send the whole buffer at once, added kenwood_cmd - removed EOM, it's handled by kenwood_transaction - fixed tabs and spaces - added generic routine for vfo errors - set_mem: do not switch vfo if already in mem mode - simplified invocation of some commands - buffer optimizations - added PARM_BEEP and PARM_APO - fixed getting of LEVEL_RFPOWER - fixed get_ant tmv7: removed EOM thg71: removed EOM thf7: - wrong rfpower level granularity - added .reset - call kenwood_open - use generic th_set_vfo th: fixed formatting issue th: fixed stack corruption th: fixed a missing newline Alex V Flinsch, KC2IVL (8): Initial changes for ft100 Initial release initial release fixed various command options new file, list of tones/codes and sequence used by various yaesu rigs added get frequency to ft100 code added getinfo func hdr *** empty log message *** Alexander Sack (1): Get firmware revision level from K3/KX3. Alexander Schultze (3): easycomm: include a new EasyComm3 to support move speed and infostring update EasyComm3 to include setting and getting of config and status easycomm: implement get/set config, easycom include status and error bytes, fix get_info Alexandru Csete OZ9AEC (34): Added new stylesheet to make API docs look better. Modified to use new stylesheet. Added doxygen comments. Added rotator.h and rotlist.h to the input list. Applied Tommi's improvements from the FT-857 backend with the following changes and additions: Full RF power scale corresponds to 10 bars, not 15. Added RIT, XIT and IF shift ranges to dummy backend. Cast constant caps to variable caps in order to avoid compiler warnings. Cast from const to variable in order to avoid compiler warnings. - Cast unsigned char to char in order to avoid compiler warnings. - Ensure that all variables have a value before they are used (ft920). - Disable unused functions and variables (frg100). - Incremented backend version numbers. Use tone_t for pcr1_ctcss_list. Changed arg 4 of pcr_transaction to unsigned. Cast the other mismatches to (char *). Cast unsigned char to char in order to avoid compiler warnings. Incremented backend version number. - Cast unsigned char to char in order to avoid compiler warnings. - Ensure that all variables have a value before they are used (tentec.c). - Cast unsigned char to char in order to avoid compiler warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast unsigned char to char in order to avoid compiler warnings. - Handle all enum values in switch statements. Fixed type mismatches that caused compile warnings. Fixed type mismatches that caused compile warnings. Initialise icom_val to avoid compiler warning. Fixed type mismatches between signed and unsigned char. There are a few very suspicious 'if' statements in icom.c and frame.c - Fixed type mismatches and unhandled switch cases. - Incremented backend version numbers. Cast constant caps to variable caps in order to avoid compiler warnings. Updated. Added infor about w (send_cmd). Max serial rate is 9600. Changed backend status to stable. Escape the backslash character. The 765 can do RIG_SCAN_PROG and RIG_SCAN_MEM. Fixed S-meter reading to use calibration table since frontend always uses RAWSTR. Fixed RF power reading and added power2mw and mw2power. Fixed RIG_LEVEL_STRENGTH reading. Andrew Errington (1): Initial support for CM108 GPIO contorl of PTT Andrew Rodland (3): Fix spurious writes when no RT-21 second port Enable "stop" command for RT-21 rotator. Update RT-21 version AuroraRAS (5): Prepare .gitignore file for NDK build Append the missing information to build hamlib v4.3 for Android NDK make the Android.mk files adapt to multi arch add androidsensor rotator AndroidSensor codes improvement Ben Coleman, NJ8J (6): Fixed bug in rpcrig_set_parm (using RIG_LEVEL_IS_FLOAT instead of RIG_PARM_FLOAT) Fixed same bug in rigctl_get_parm. Added checking of return string from rig on set (non-retrieval) commands. Added code for COMP function. Added alinco_set_parm & tweaked dx77 capabilities. Handle setting Keyer speed and CW Pitch Added NJ8J's email address. Change email address for NJ8J Berndt Josef Wulf, VK5ABN (11): Implemented rig_set_channel() Implemented set_parm() for BACKLIGHT operation Commented out RIG_MODE_PKTFM overlooked at the submission of previous code Implemented RIG_MODE_PKTFM and RIG_MODE_PKTLSB modes Changed debug message format for freq_t from long long to double ft990_get_ptt() now uses the FT990_SF_XMIT instead of FT990_SF_PTT. FT990_SF_PTT only returns status of PTT activated by CAT commands, whereas FT990_SF_XMIT reports the actual status of the ptt line. ft990_get_mem(): Fixed bug that prevented the reporting of current channel number when vfo != RIG_VFO_MEM Fixed erroneous return value Fixed mispelled name for VK5ABN Added missing modes to RX/TX caps Fixed bug in ft990_set_mode that caused RTTY interchanged modes USB/LSB Fixed bugs in ft990_get_channel Bill Barker (1): Add test for Flex 6300 ID Bill Somerville (212): Patch submission for IC-756 Patch to allow same serial port for PTT and CAT. Patch to fix broken Yaesu backend with FT-2000(D) Fix rig_open not failing when PTT/DCD port is unavailable. Fix Icom IC-756 filter handling. Fix Yaesu newcat backend set_tx_vfo issue. Add support for Data Modes on Icom "Pro" models. Fix Icom IC-726 mode handling. Fix Kenwood TS-2000 split operation. Fix Kenwood Split Operation for TS50 & TS480. Fix Kenwood TS-870s split and bandwidth set/get. Correct receive buffer length for IS; comamnd. Fix Kenwood CAT transaction busy retry mechanism. Fix Kenwood get split VFO function. Add data sub-mode support for TS590s. Correct order of MD and DA commands for TS590s. Get firmware revision for TS590s in rig_open. Fix TS590s firmware defect. Fix Kenwood get_vfo function returning wrong VFO in split TX. Make Kenwood TS590s firmware defect fixup revision specific. Extend TS590s firmware defect fixup to both VFOs. Fix Icom IC-756 Pro III get data mode. Add spilt mode get and set for Elecraft K3. Fix data sub-modes on Elecraft K3. Fix Elecraft Data Mode Translation. Fix Elecraft K3 Data Sub-Mode Setting. Fix Yaesu FT1000MP and FT1000MP Mk V modes. Fix configure.ac Fix a warning message. Added option to not use VFO XCHG command when setting split parameters. Fix a buffer overflow in the Windows termios emulation. Fix pkg-config generation. Fix Icom IC-756Pro mode get/set. Facility for rigctl to read commands from standard input. Add a pause command to the rigctl command set. Prefix action function names so as not to clash with system names. Prefix action function names so as not to clash with system names. Corrected typos in rigctl.1 manpage. Add read commands from stdin and pause command features to rotctl. Merge branch 'rigctl-stdin' of ssh://git.code.sf.net/u/bsomervi/hamlib into rigctl-stdin Fix manpage errors. Remove redundant RIG_PTT_SERIAL_CAT enum from ptt_t Only check for serial control line conflicts if PTT shares CAT port Fix Ten-Tec Orion get/set split functions Icom IC-7410 has VFO A/B not MAIN/SUB Added IC-7410 data modes Add retry mechanism for Yaesu "newcat" backend Implement retries for Yaesu "newcat" rigs Disable auto information mode on open Add retry mechanism for Yaesu "newcat" backend Implement retries for Yaesu "newcat" rigs Disable auto information mode on open Merge branch 'yaesu-retries' of ssh://git.code.sf.net/u/bsomervi/hamlib into yaesu-retries RIG_OK is zero and need not be negated and this will not change Fix response length expected error in K3 back end Data mode support for the Icom IC-7700 Data mode support for the Icom IC-9100 Data mode support for the Icom IC-7200 Add support for the Kenwood TS-590SG Kenwood TS-590SG Always clear serial control lines when used for PTT Disable AI mode on open for Kenwood/Elecraft rigs Add more diagnostics and error checks to serial line control Move serial line control error checks to lower level routines Merge branch 'master' into kenwood-ai-off-at-start Merge branch 'master' into ptt-control-on-cat-port Fix serial i/o on Windows. Yaesu newcat style command response reading improvements Increase communications timeout for Icom rigs Kenwood AIn; command has no reply Revert read_string() to partial results are a success status Remove gratuitous sleeps before function exits Error checks on simulated direct VFO addressing Elecraft K2 RTTY modes are not FSK Kenwood and Elecraft rigs sometimes ignore commands Removed kenwood_cmd function and replaced uses of it Allow for failed test command on the K2 Elecraft K3 has 1 stop bit Kenwood TS-570 series IF returns current frequency Switch to "ID;" command for verification as no "AI;" on TS-840s Increase Elecraft K2 comms timeout and retries Switch Kenwood TS940 to generic kenwood CAT functions Improve command verification for Kenwood & Elecraft Use local buffer in kenwood transaction funciton Clarify the handling of Kenwood CAT message terminators Further clarification in the implementation of kenwood_transaction() Removed redundant precondition test Remove kenwood_simple_cmd as kenwood_transaction has that functionality Call kenwood_open() for TS-2000 to ensure AI mode is disabled Allow for bad ID from DDUtil in TS-2000 mode Allow one extra byte in read_string() length to accomodate terminator Enable data modes for the Icom IC-7100 Allow for PowerSDR ID in Kenwood TS2000 emulation mode Fix TenTec Argonaut message lengths and timeout Fix TenTec set split command Implement get PTT status for the TenTec Argonaut Fix error with width in set mode for the TT argonaut Yaesu FT540 can only change the frequency of the current VFO Fix defect in Kenwood TS-940 IF command response parsing Fix response lengths for the TT Jupiter 538 Do not attempt CAT PTT commands on the Icom IC-706mkIIG Use correct argument type for serial control line functions Initial back end implementation for the Kenwood TS-990s Mode set is not VFO targetable on the Kenwood TS990s The Kenwood TS990s only does split Tx on SUB VFO The doesn't appear to be a way of getting PTT/SEND on the TS990s Lower both RTS and DTR on alternate PTT serial port Honour any error status from serial port calls Dummy get_ptt function needs to read RTS/DTR/PARALLEL Make autogen.sh agnostic to whitespace in paths Increase the number or retries for most Kenwood rigs Command validation for Yaesu set commands Remove unecessary delays from TS-940S backend Proper IPv6 and dual stack networking Fix compiler warnings Proper IPv6 and dual stack networking for rotator net daemon Attempt to restore AI status on exit Allow for poor emulations of Kenwood rigs that have no ID command Use correct function to execute set type commands with no response Add a new command line option '--no-restore-ai' ('-n') to rigctl Fix FT-817/857/897 issues and add some missing functionality Fix missing PKTUSB mode setting code for FT-817 & FT-897 Fix a logic error in band detection during IC-910 set frequency Add missing configuration getters Detect C-IV NAK returns as rejected commands Elecraft rigs do not switch VFO in IF command responses during split Tx. Redundant split mode directives on Elecraft rigs cause Tx failures Only use IPv6 features on Windows versions that support it (>=XP) Improve IPv6 portability and consistency Add 23cms to IC-910(H) backend Implement combined split VFO frequency and mode setting. Initial implementation of rig_{set,get}_split_freq_mode() for FT-857. Implement rig_{set,get}_split_freq_mode() for IC-756 series. Add {get,set}_splitfrequency_mode for the IC-910(H) Elide unnecessary CAT commands when setting split frequency and mode Do not swap VFO unnecessarily Better set frequency semantics for the IC-910(h) VFO targetable get frequency operation for the Icom IC-910(h) Make sure right band is used when setting frequency on IC-910(H) Use rig state rig port retry option rather than from capabilities Use a sensible port timeout value for the Kenwood TS-850 Further attempts to simplify and improve Icom CAT for split operating Add RIG_PASSBAND_NOCHANGE as possible set_{split_,split_freq_,}mode argument Switch to POSIXLY_CORRECT mode for getopt_long() Fix a regression introduced in 222ad74 Do not crash if expected CTCSS tones not sepcified Do not attempt to query AI state on the TS-450s as it is not supported Some more Kenwood rigs with no AI query Adjust rig_list_foreach to allow use for unregistering Fix an issue presenting on the Yaesu FT-450(D) Release the serial port used for PTT when possible Change the IC7600 & IC7800 set/get mode to versions that support DATA modes Add rig_{open,close} functions to TS-790 backend Revised kenwood rig busy response handling Add get and set split functions for the TS450S Simplify and fix defects in the FT991 back end Fix some endian issues in the si570/AVR SDR back ends Fix a state machine defect with repeated PTT reset calls Do not pass --no-cpp_precomp to compilers on Mac OS X Allow RIG_LEVEL_STRENGTH queries over the network link Stop rigctld and rotctld crashing when service threads cannot write to clients Use snprintf throughout kenwood/kenwood.c for buffer safety Fix off-by-one issue in reading memory mode from IF command response Fix some issues with commands not supported by TS-2000 CAT emulations Add best guess transmit status to rig state structure Take out unecessary delays in K(X)3(S) back end. FT-817 status queries honour retries and timeout Make rig_open() call in rigctld lazy and add graceful termination Simplify SWIG interface definition and hide 64-bit values from Lua binding Remove unnecessary delays from TS-990 and TS-2000 back ends Change frequency setting for the FT-747GX to something more basic Fix an incorrect error return value from win32_serial_select() Fix timeout issues with the Ten-Tec Orion/Eagle Ensure compilation works with a pre C11 compiler Make code C90 compliant again Move unnecessary global and file static variables to the stack Simplify unnecessary persistence of extended response state Fix misunderstanding of netrigctl_transaction() return value Made PTT and DCD options consistent between rigctl and rigctld Report unrecognised PTT and DCD types in rigctl and rigctld Update i/o functions to support GPIO(N) port closure Fixed erroneous messages in rig_close with GPIO(N) PTT or DCD types Remove duplication across GPIO and GPION handling of PTT and DCD Improved get PTT state handling in dummy backend Simplify closing of device files Repair a regression with the dummy get PTT functionality Revert "Add debug to serial.c" Repair a regression with the dummy get PTT functionality Revert "Add debug to serial.c" Fix regression with slow responses from SmartSDR causing errors Deal with remote PTT type at the client end Avoid 'echo -n' as macOS sh doesn't support it Fixing an operator precedence defect Updates to the TH-D7A/E back end Less ambiguous variable name and repair merge issue in prior commit Add missing config parameters for rig power on/off and screen-saver New power on option rather than power on/off Make version recording safe for parallel builds without breaking make dist Make version recording safe for parallel builds Ensure old hamlibdatetime.h headers in the source dir are ignored Merge branch 'safe-scs-versioning' of ssh://git.code.sf.net/u/bsomervi/hamlib into safe-scs-versioning Fix make dist versioning Use BUILT_SOURCES make mechanism as intended Fix rebuild dependency Build hamlibdatetime.h every time Force copy over existing Minimize rebuilding Correct use of sh if Another attempt at a reliable SCS version header generation Remove temporary file Add missing shared library API exports Add missing export definition Blaine Kubesh (8): added Icom803 to icmarine added Icom803 to icmarine added Icom803 to icmarine Update ic-m803 remote-id to 20 Update icm803.c Update AUTHORS undo author changes Update icm803.c Bob Freeman (1): New CNCTRK rotor backend Brian G. Lucas (10): Pretty much a complete re-write of thd72.c, since the old one didn't work at all. Many commands have been tested with real hardware. But more work remains to be done. WIP: thd72 driver. More level, func, and parm stuff works. WIP: thd72 driver. Try to simplify the menu based interface. WIP: thd72 driver. First cut at get_channel(). Other cleanup. WIP: thd72 driver. More interfaces implemented. Other cleanup. Implement some more interfaces. Comment out get_chan_all_cb because the block read routine doesn't work. Fix a format so that it works with Windows. Can't test it because I have no Windows machines. Fix RFPOWER level for FT-450D. It uses 5-100, rather than 0-255 that the FT-450 does. In newcat_open(), initialize rig_id in case any subsequent commands need it. Some calls to thd72_get_menu_item where passing wrong values for range check. C-Elegans (1): Add ability to have rigctld display transverter frequency CJ (1): fix windows makefile Charles Suprin (7): Add file for TM-D710 support. Merge branch 'master' of ssh://hamlib.git.sourceforge.net/gitroot/hamlib/hamlib Add D710 to riglist. Add D710 code to kenwood library. Register D710 interface. Initial D710 Implementation. Register D710 interface. Charles Suprin, AA1VS (3): extend th_get_vfo_char to support D700 Changed th_set_freq to round and select step size to use. Allows 6.25kHz and 5kHz channelization. Use new th_set_freq for TM-D700 Chris Karpinsky, AA1VL (7): add serial_flush() method to clean rx buffer initial stab at this for the Yaesu FT-817 add ft817.* add ft817 bump the backend status to ALPHA Initial entry of cgirig giving ability to use hamlib from a web browser. increased post write delay to 300 Chris Ruvolo (4): TS-690: deal with optional tone board using TS-450 logic TS-690 does not implement the PC command to get/set output power level TS-690 does not implement the GT command to get/set AGC rate TS-690: bump version Christoph Berg (2): ic7610: Re-add send_morse Implement netrigctl_stop_morse Chuck Hemker, N2POR (1): Use RIG_TARGETABLE_MODE in rig_set_mode and rig_get_mode Chuck Ritola (8): Use loop to ensure RS-HFIQ hears first command. Closes #730 Add ability to read TX drive level Implement board temperature reading for TEMP_METER Parse and store RS-HFIQ firmware version. Firmware version check before power meter query. Merge branch 'master' into rshfiq-aug2021 Map FCDPP LNA and Mixer Gain as PREAMP values. Closes #766 Map FCDPP LNA and Mixer Gain as PREAMP values. Closes #766 DL1YCF (6): Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Dale E. Edmons, KD7ENI (19): Added comments to commandline in rigctl (second time) --Dale Started TS-2000 update/overhaul --Dale Copied too much stuff, backed out what I broke. Bring ts2k.c more in line with current CVS. Changed ts2000.c to ts2000.h. Start of rig menuing functions. New file. Renamed ts2000.c.new ts2000.h Bring code more in line with CVS code. Changes often, so added status. Will delete when things stabilize. Corrected status to CVS branch. Renamed new ts2000.c to ts2000.h Wouldn't compile. Removed ts2k.c. Haven't got all new rig.h stuff removed. Temp kludge to make ts2k.c compile (keeps Hamlib from compiling!). Updated status. Added working TS-2000 files. There are some changes left out but this is the minimum I could commit and have a functional rig. The cost is that I've broken kylix and others that duplicate rig.h. I'm in the process of repairing the damage. Please be patient. I hope a day or so, but am asking for up to a week. E-mail me about *anything* you find broken. Kylix (and similar) is (are) known to not work. Changed name back to original. Had to re-run automake kenwood/Makefile. 1) Updated branch_ts2k with respect to HEAD. 2) Working ts2k_menu. (only in RIG_MODEL_TS2K) 3) Split TS-2000 into experimental and standard versions: RIG_MODEL_TS2000 = standard, RIG_MODEL_TS2K = experimental. 4) Basic command parser in tests/rc. Will open/close rig or copy a freq from one rig/vfo to another rig/vfo. Very cool. Very basic. Very experimental. 5) Added test programs. a) testcmd - calls parser (no command prompt yet!) b) testts2k - replacement for testrig (with trivial modification) c) testptt - testts2k/testrig should not transmit. TX stuff in testptt. 6) Used crowbar to merge HEAD into branch_ts2k. Working on clean-up. 7) I'm sure I've forgotten or neglected to mention some other stuff. Daniel Estévez (2): Fix DIG MODE for FT817-ND Fix DIG MODE for FT817-ND Daniele Forsi (5): Set the executable bits on py3test.py Fix spelling errors Fix more spelling errors Fix more spelling errors Fix typos Daniele Forsi IU5HKX (9): Fix a [missingInclude] "information" when running cppcheck --check-config The -M option needs an argument like its long version "multicast-addr" Fix lintian warning: macro 'RG' not defined Fix lintian warning: macro 'IN' not defined Fix spelling errors Remove unused includes related to times and dates Remove unused includes of math.h Remove unused includes Revert unwanted changes Dario Ventura (3): New Prosistel rotor backend from IZ7CRX Add elevation code to Prosistel backend TS2000 Satellite mode and Gpredict Dariusz Bismor, SQ9KEJ (1): rigmem: implement CSV file loading David Brewerton M0EZP (1): FT990UNI patch contribution from M0EZP David Fannin (1): Submission for new backend model (134) for Yaesu FT-DX1200 Davide Gerhard (3): tests/{memcsv.c,memsave.c}: partially revert commit 4072f9f4 ic746.c: correct chanbuf length, fix channel structure and support split ic746.c: add ic746pro_set_channel() to load memory from csv Dawid SQ6EMM (3): Add method to build inside docker Let SEND_MORSE and SEND_VOICE_MEM be announced as capabilities. Allow \send_voice_mem to be used over network and tested in dummy rig Dawid Szymanski (2): ICOM Voice Keyer implemented. typo fix Diane Bruce, VA3DB (5): - first cut at fixing configure to recognise --without-tcl-binding and --without-python-binding options - gt_HEADER_INTTYPES_H is definitely bogus here, leftover from what? - document debian/FreeBSD needs for AUTOMAKE etc. - add in libtoolize which should be there - These should have been commented out. - Extra comma on RIG_STATUS_BUGGY can cause a compiler error. Dieter Röver (1): Fix bug in vfo_comp calculation in Hamlib Ekki Plicht (DF4OR) (2): New model Icom IC-R8600 Patch for Icom DCS code handling Elliott Liggett (1): Added functionality for the IC-7300 auto antenna tuner Eriks Dobelis (2): ft817: adding delay before next retry after returning from tx to rx ft817: Moving delay value into #define section of the header Ervin Hegedus (9): RIG_PASSBAND_NORMAL wasn't handled correctly when rig_set_mode() was called - fixed Fixed SWIG `Setting a const char * variable may leak memory' error Fixed Kenwood filter cmd when passband is set to 500Hz Merged from upstream Merge branch 'master' of http://git.code.sf.net/p/hamlib/code Added Lua binding and demo script Added new example to Python demo script (set/get float type level) Change variable length argument handling in affected functions Fix two typos Ervin Hegedüs (1): rig.swg: New properly formatted macro Evgeniy Titorenko (1): Add Radant AZV-1 Rotator controller protocol. Francois Retief (21): Added read_serial function to read strings from a port. Corrected some comments Added code to hexdump to right align ASCII dump column added private caps for rig termination character add private caps and more commands. Changed to a new transaction function and adde quite a few commands. add private caps to store the termination character of Kenwood rigs commands. added a kenwood_init and _cleanup routine for priv caps & priv data. Added a new function: LCD Lamp ON/OFF (for Kenwood TH-7DA) check trn state of rig in rig_open. Initial commit of Kylix binding New backend for rotators New RPC backend for rotators Added rot_move function Fix macro name Added rot_move function Added easycomm and rpcrot backends Fixed circular dependency for rpc.rigd and rpc.rotd regenerated Added IC-910 rig. Added constants for the IC-910 rig. Frank Goenninger (3): Add ADAT ADT-200A backend adat updates from Frank, DG1SBG ADAT fixes on Windows Frank Singleton, VK3FCS (165): Initial revision Initial revision *** empty log message *** *** empty log message *** *** empty log message *** Initial revision Initial revision *** empty log message *** *** empty log message *** added build_all ,cleanall and verify targets *** empty log message *** initial top level makefile add some things initial import initial import initial import fixed some typos use rig_open and rig_close added rig_open and rig_close fixed cmd_sat_on / off added sat-on and sat_off to test changed cmd_get_rx_status, must do tx also updated test() all reads use while (1) and break added ../common as object path added rig_open and rig_close using rig_open and rig_close and serial.h use common dir for serial stuff use ft747 on serial port /dev/ttyS0 read uses while(1) and break use while(1) and break added read_sleep use read_sleep now from serial.h using read_sleep from serial.h had rx and tx status swapped (document error?) removed cmd_get_update using CVS instead of RCS directories use MODE_xx defines cannot use const int in case statements ?? so use #define instead use #defines for MODE_XXX used in case statements working out freq conversion, unfinished playing with test routines long int cmd_get_freq_mode_status_main_vfo(int fd, unsigned char *mode); long int cmd_get_freq_mode_status_main_vfo(int fd, unsigned char *mode) frq = cmd_get_freq_mode_status_main_vfo(fd, &mode); starting with the cmd_set commands now starting on cmd_set commands now starting on cmd_set_freq commands now add scanning todo now set sat rx and tx freq and mode also fix typo dump raw hex data when writing and reading trying some cms_set_freq_xxx commands added routines for dec <-> packed decimal conversion minor added generic hex dump routine, static void dump_hex(unsigned char *ptr, int size, int width); removed unwanted debug printf's removed dump_hex from here.. calc_freq_from_packed4 is about to be replaced calc_packed_from_char and calc_char_from_packed now here cleanup cleanup void dump_hex(unsigned char *ptr, int size, int width); adding dcs tables and repeater offset in Hz describe faulty yaesu documentation added README.license for GPL added GPL license info included full GPL license Updated docs to point to http://sourceforge.net/projects/hamlib/ and added a C code snippet on how to use the API. added -I$(COMMON_DIR) to find rig.h added -I$(COMMON_DIR) to find rig.h adding capabilities initial capabilities stuff starting to add rig_caps stuff starting to add rig_caps stuff starting to add rig_caps stuff. added GPL stuff and comments adding rig_caps stuff adding rig_cap stuff adding rig_caps stuff add capabilities and preferences adding rig_caps functionality adding rig_caps stuff frontend reduction on backend function namespace - phew !! frontend API clarification removed old open_port2() using old rig_caps fixed some typos, added 3 more candidates for API missing ; in some enums converting to frontend/backend structure compiles ok removed open_port() and write_block() removed open_port() and write_block() fixed typos, added &ft747_caps in rig_caps changing to frontend/backend style converting to frontend/backend style added 3 more cmd_* for API examples Example of setting rig Main VFO to 439.700 Mhz FM cleanup comments added extern const struct rig_caps ft747_caps; still thinking about set/get strategy minor updates added extra rig caps added some set/get examples with return code checking added testrig to Makefile, no linking yet added usleep to read_sleep() updated rig_caps structure *** empty log message *** test making a shared lib (at last) for the frontend - more todo test making a shared lib for the frontend - make hamlib describe frontend/backend structure updated code snippet example started ft747_set_ptt and ft747_set_vfo starting to implement set/get pairs added typedef enum ptt_type_e ptt_type_t; added VFO types to enum starting on libhamlib Makefile, added ./lib and ./include under common make, make install, and make clean work ok, using ./lib and ./include directories also. make, make install, and make clean work ok, using ./lib and ./include directories also. removed "make verify". Added reference to common/Makefile added printf("testrig:main() has been called \n"); for testing linking makefile for testing testrig linking alternative rig_base declaration removes references to rig_caps at compile time. should populate it another way -- FS added printf's to confirm rig.c (hamlib) is being called ok better libhamlib.so version :-) added ft847_open and ft847_close to enable CAT ON/OFF added ft747_open and ft747_close updated lib names for backend to libhamlib-xxxxx.so API updates - added set/get_mode merge with TRN stuff and add some set/get_mode and vfo stuff added post_write_delay cvs mails to hamlib-cvs-digest cvs mail update works ok :-) minor fixes updated ptt/mode/vfo added set/get freq to use generic bcd etc more set_freq() examples 1. Added VFO as target for some set/get cmds. 2. ./testrig still runs ok using RIG_VFO_CURR. minor update to active VFO handling in _set_vfo some new defines for FT747_VFO_A/B minor updates to active vfo handling added ptt handling example, stand back ! trying different approach to storing cmd sequence. _set_ptt is being converted. Needs tidying up though. Some sequences are complete, and can be read from static data. Incomplete sequences will eventually be copied form static declaration, and completed in priv data. Removed static stuff from functions. Also, begin to implement table driven command translation from API to rig native. priv now contains a cmd table that is used for backend commands towards rig. Added some new freq/mode combinations. converting ft847 to table driven, similar to ft747. more table driven stuff for ft847. cat/ptt/freq being converted. Added ft847_send_priv_cmd(), converted some part of API to use this. Added _set_mode to work now. TODO: put _send_priv_cmd into yaesu.[ch] so ft747 can use also. Turned on PTT also (stand back).. rig_cleanup and rig_close not calling backend removed unused calc_ functions. removed old API functions, general cleanup tested rig_close and rig_cleanup Initial release, common yaesu declareations etc. add version tag nseq uses YAESU_CMD_LENGTH Initial yaesu Makefile Moved from ft747 and ft847 dirs common yaesu handling common yaesu dir Begin to use common yaesu code general cleanup, added _send_priv_cmd added targetable_vfo value to caps minor cleanup ChangeLog history started Initial import for ChangeLog handling starting to convert rig struct to readable form more of convert rig struct to readable form Changelog update for HAMLIB-1.1.1 Georges Auberger (1): Add product id for CM119B chip. Used in KURI adapter designed by W7NX. Gerardo Richarte (1): gs232b.c: Improve get_position string parsing Gisle Vanem (1): Enable verbose mode in bindings/pytest.py Greg Troxel (1): Warning about dodgy code in drake.c HB9EIK (4): Initial release ELAD FDM DUO Update ELAD files Update build system for ELAD backend Update copyright for fdm_duo.c Hans Van Ingelgom (1): Added Peaberry V1 and V2 models Hegedüs Ervin (4): Merge branch 'master' of http://git.code.sf.net/p/hamlib/code Check SWIG string functions for some languages Leave off multiply 'typedef const char * const_char_string' definition (in rig.swg and rotator.swg) Fixed int[10] type variable error in bindings Jae Stutzman (5): Added HPSDR backend Clears potential garbage data in read buffer prior to command being sent Updated PiHPSDR backend defaults Use Windows ioctlsocket to avoid buffer overrun Added new AGC control for PiHPSDR James Watson, HZ1JW (2): Added ic7200 to icom Corrected modes in ic7200.c Jaroslav Skarvada (2): Fix hardcoded pcconfig libdir Fix serial_port DCD squelch Jeroen Vreeken (9): Add support for GPIO PTT. Add missing breaks and improve error messages Add Dorji DRA818 modules (VHF and UHF variants) Also works with NiceRF SA818 modules Merge branch 'master' of git://git.code.sf.net/p/hamlib/code Small fixes to DRA818 volume handling Add GPIO and GPION options for DCD. Also bump abi version since the config params struct needed resizing. Merge branch 'master' of github.com:Hamlib/Hamlib GPIO working after debugging Merge branch 'master' of github.com:Hamlib/Hamlib Johan Ström (1): Backup serial options on open, restore on close John Paul Adrian Glaubitz (1): dummy/dummy.c: Fix unaligned access in dummy_get_level() Jonathan Bastien-Filiatrault (3): Correct FT; command that does not exist on the FT-891. Allow setting split mode without smashing the VFOB frequency. Scale power values correctly for Yaesu FT-891. Jonny public (1): ether6: New rotor backend from Jonny, DG9OAA Joop Stakenborg, PG4I (116): update (kenwood is not a WIP anymore) first implementation of kenwood_get_ptt enable get_ptt for this rig add get_ptt for this rig additional protocol checks and cleanups fix signal strength add RIG_LEVEL_RFPOWER fix_compilation add rit capabilities bring comands in sync with other kenwood rigs add rit capabilities send_morse added explain set_rit fix get_ctcss_tone by using IF command typo add xit capabilities add set_level and get_level bring rig in sync with other kenwood rigs bump version numbers nothing returned by the rig for these commands fix get_level_agc fix set_level_agc getting in sync with the debian 1.1.2 package remove template files initial checkin make this NMU for now correct the path for copying files in the apropriate package do not install the old changelog versioning not used move .la, .a, .so files to the correct package include rpc.rigd and rpc.rotd include pkgconfig support don't create shlibs file for drake, jrc and easycomm libraries move hamlib1 to the top so the documentations gets installed correctly make building easier, call autogen.sh INSTALL file not used build the documentation package we don't have to call configure twice cleanup remove some build dependencies and don't call autogen.sh ts450s uses IF command for get_vfo, get_freq and get_mode minor bugfix, bump to beta add CWR and RTTYR this rig does not have a command for reading IF bandwidth retrieve passband with FW command passband should be calculated after mode is set use rig_passband_normal here various lintian fixes one last lintian fix use FW command to set bandpass cw filters for normal, narrow and wide more filters get_mode and set_mode for this rig filters some comments correct rit add get_level cleanups more modes set_level for this rig should use kenwood_get_freq minor bug add rpm support need hamlib.spec for 'make rpm' make rpm will fail with a '-' in the version number a working spec file update debian build for rotorez and fodtrack, minor fixes unofficial fix the debian build script, new maintainer update the debian build tree to the latest correct baudrate for the ts-950, use the information field IF for get_vfo by default (supported by most kenwood rigs), ts870s will use the much shorter FR command for get_vfo correct baudrate for some rigs and add ts-950 to the id_list ts-850 returns ID 009 according to martin, OK1RR fix 'make rpm' build for hamlib-1.1.5 not needed sync with latest debian package and add tcl, c++, python and perl bindings correct spelling s-meter calibration by Matt Dawson basic functionality by Matt Dawson, tested with grig and xlog lifetime e-mail address :-) sync with latest debian release more functionality, mode and frequency get by Matt Dawson only switch tx vfo is split is on set attenuator level export convenience function get_kenwood_level, so they can be use by other backends add RIG_LEVEL_SWR, copied from ts850 add RIG_LEVEL_COMP, RIG_LEVEL_AGC, copied from ts850 bump version, no preamp really add ALC read this time, only change meter if needed, cleanups split has_get_level and has_set_level fix coding, python2.4 compatibility fix compilation warnings more compilation warnings nuked, use tone_t for ctcss_list use size_t fix more compilation warnings, int->size_t, unsigned char->char more unsigned char->char and int->size_t transitions set functions should have ack_len zero, also need to check other rigs make sure we use ack_len=0 for functions that return nothing (set functions) more unsigned char->char and int->size_t transitions extend rig capabilities, patch by Tom, DL1JBE add RIG_LEVEL_STRENGTH to caps, set post write delay to 0 and do some cleanups re-establish post-write delay remove rpath backdoor long long really needed here? updates by matt, GW0VNR long long really needed here? - patch by diane Bruce distribute footer.html correct set/get power try better s-meter readings packages renamed obsolete sync with latest debian release no need to link to python sync with latest, python changes another debian update: use 'make distclean' in the rules file Joshua Lynch (4): initial SatEL rotator support factored io functions out. improve reliability...i hope. fixed state bug. reconnecting would disable motion every other connect. merged upstream/master into master Juergen Rinas, DC3BW (4): added antenna switching... added a few get_level/set_level get_function/set_functions. * fixed set_func (concerns most kenwood rigs) * added 115200 to the list of baudrates in probeallrigs_kenwood() * fixed ptt * expanded frequency range (available after firmware update) according to http://www.kenwood.com/i/products/info/amateur/ts_480/firmware/pop_ts480_e.htm * added tuning steps * added filter list * increased version info Julian Cable (3): WinRadio G313: Updates from Julian Campbell wrg313api.c: Fix Win32 (MinGW) build issue Use Automake conditionals for G313 build Juuso Lehtinen (4): Add get & set RIG_LEVEL_NB for Yaesu rigs. Fix set level METER for Yaesu rigs Add ID, VD & Comp meter cals for FT991 Add better defaults for newcat meter cals Kamal Mostafa (3): Fix mingw32 cross-compilation procedure and config Do not let macros/ac_python_devel.m4 trash CPPFLAGS and LIBS Fix spelling errors Kamal Mostafa, KA6MAL (19): Hard-code length of hamlib_version and hamlib_copyright strings to stay compliant with hamlib 1.2 ABI and avoid spurious "consider relinking" warnings from dynamic loader. Removed stale debian/ dir from the hamlib source (it is maintained in the Debian diff and isn't useful in this tree). Update bundled libltdl (libtool) to version 2.2.6b to address CVE-2009-3736. - autogen.sh: never downgrade our bundled libltdl/ (only run libtoolize if system version is newer than our bundled version). - autofixer.sh: script removed as libtool 1.x is no longer allowed. - configure.ac: (not enabled) optional setting to deprecate embedded libltdl/. Added Kamal Mostafa and Jaime Robles as maintainers for Debian packaging. Fix build --with-python-binding breakage introduced by Python 2.6: Do not reference LOCALMODLIBS, else it will add libraries to our link line (e.g -lssl) which are not necessarily installed. Elektor 507 frequency selection resolution improvements, contributed by John Nogatch AC6SL. Move backend libraries into /usr/lib/hamlib directory. Force automake to invoke the C (not C++) linker in kit/ when no C++ is in use. python: fix --with-python-binding configure macro fix configure.ac paths for FreeBSD Remove bundled libltdl (libtool) README.developer: restore libtool prerequisite text Fix segfault on improper -C syntax configure: add check and advice for missing ltdl.h configure: refine advice for missing ltdl.h source warnings cleanup: rpcgen-generated code source warnings cleanup: #if-0 out a few unused routines source warnings cleanup: #ifdef out unused FT-840 routines source warnings cleanup: rotorez_rot_reset wrapper for stop Kayne (1): Updated k3_set_modes to work on KX3 Kosta Arvanitis (1): Allow IC-7410 to send cw messages Kārlis Millers (1): Merge pull request #1 from Hamlib/master Ladislav Vaiz (3): Add Android build support Android build updates for monolithic build Initial support for FUNcube Dongle Pro Lance Conry (1): From a pull request but modified to fit current codebase and clean up warnings https://github.com/Hamlib/Hamlib/pull/1071 Larry Gadallah (1): AR7030+: Error reading signal strength for low signal levels. Larry Gadallah, VE6VQ (20): Added Larry Gadallah as maintainer of AOR AR7030+ Added AOR AR7030 Plus Added caps for AR7030+ Added caps for AR7030+ Added AR7030+ Alpha version of AR7030+ backend Alpha version of AR7030+ backend Rationalized naming convention, ran everything through lint. Rationalized naming convention, ran everything through lint. Fixed SVN tags Fixed SVN tags Added AR7030P utilities in ar7030p_utils.c Initial version of utility functions for AR7030 Plus receiver Removed utility/helper functions, added/updated Rig API functions Added new I/O helper functions, IR code definitions Added private data to support channel information Added init/cleanup functions, started implementation of mem/channel access functions Added prototypes for pbsToHz() and hzToPBS() helper functions. Added comments to denote mey_sq, mey_pb, and mey_id labels Added implementation for pbsToHz() and hzToPBS() helper functions. Added various memory/VFO functions. Lorenzo Santina (2): Fixed rigctl ignore error command line Fixed c++ exception for visual studio compiler Magne Mæhre (1): Enable set_powerstat (turning radio on/off) for IC-7100. Malcolm Herring (62): init branch init branch New model: Icom IC-R6 Icom IC-R10 & 20 testing complete. Move to Beta ignore build Complete R6 commands Add IC-R30 daily fix tones Merge remote-tracking branch 'Hamlib/master' update Merge branch 'master' into icr6 ICR6 new functions merge update Merge remote-tracking branch 'Hamlib/master' commands 00-15 Merge branch 'master' into icr30 icr30 updates Automatically detect CI-V echo state Icom R8600 to Alpha Update contributors Merge branch 'master' into origin/master Fix Icom DCS SQL funnctions Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' Prepare for D-STAR implementation Merge remote-tracking branch 'Hamlib/master' Initial implementation of icom extended operations more extended operations Merge remote-tracking branch 'Hamlib/master' more ext functions fix merge conflicts more ext_cmd updates ic7100 ext functions Merge remote-tracking branch 'mdblack/master' Merge branch 'master' of https://github.com/malcolmh/Hamlib add token list for ext operations Merge remote-tracking branch 'mdblack/master' more ext operations Merge remote-tracking branch 'mdblack/master' custom ops using ext ops scheme custom level ops Merge remote-tracking branch 'mdblack/master' Merge remote-tracking branch 'Hamlib/master' add scope functions update IC7100 update rigs for new functions Merge remote-tracking branch 'Hamlib/master' new directory structure Merge remote-tracking branch 'Hamlib/master' correct powerstat caps Merge remote-tracking branch 'Hamlib/master' New custom parm implementations restore get_powerstat correct rig_close cap Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' add g/set_ext_func to API additional error checking for extended operations Add Macports to README.osx Mark J. Fine (25): Fixed post-write-delay timing Added support for ECSS/FAX and meter strength Added support for meter strength Added ECSS support to R8B and reconfigured default filter modes Reconfigured default filter modes Updated to reflect recent changes within v1.2.2cvs-2 Fixed CWPITCH function on IC-R75 to use 'set mode data' command. Added level granularity steps included other rig_ prefixes fixed get_powerstat to read correctly when memory channel is blank Added memory switching function in set_vfo Added set memory channel# in radio in set_mem Added set_vfo command for vfo/mem switching Corrected handling of "vacant" memory channels Correctly detect if in memory mode in get_vfo() Reduced large decision trees with bitwise math Added set/get channel functions Updated set/get channel functions Made get_channel aware of untunable blank memory channel accounted for dual preamp (10 & 20db) Fixed passband width return for IC-756PROII Added FM narrow to passband spec Added a provisional define for a variable bandwidth control Added a provisional variable bandwidth control to the RIG_LEVEL enumeration Added provisions for a variable bandwidth control Added provisions for a tone control Corrected problems with Squelch (SQL) and Notch (NOTCHF) controls Added provisions for a variable bandwidth control (BWC) Fixed low-end of freq range from 100kHz to 10kHz. Fixed several differences in 535/545 commands Added missing manual notch switch for the NRD-545 Martin Cooper (2): Don't expect a response when none is required. Don't send EasyComm I commands to EasyComm II rotators. Martin Ewing (7): Add test for valid set frequency, esp. for VFOA (ham band only) Expand valid range_lists for full hardware ranges Fix tt565_transaction to allow Morse commands. Orion.c: remove spurious debug statement. implement level settting and misc fixes remove debug stmt Increment Jupiter version Trim TS950 commands that are not provided by CAT jupiter.c: Updates from Martin, AA6E Martin Ewing, AA6E (69): specified buffer lengths, added default vfo A setting Fix SWR & S-meter, set ATT, set AGC, add rough STR_CAL func. Fix timeout, add retry, better S-mtr scale various bug fixes Added RIG_LEVEL_CWPITCH, RIG_LEVEL_KEYSPD, send_morse() Added RIG_FUNC_TUNER, RIG_FUNC_LOCK and RIG_FUNC_VOX, fixed MEM_CAP. Added VFO_OPS, promote to Beta Support LEVEL_VOX, VOXGAIN, ANTIVOX Support LEVEL_NR as Orion NB setting (firmware bug), FUNC_NB -> NB=0,4 Add get_, set_ant (ignores rx only ant) Added Orion, Orion 2 info Squashed warnings about signedness Orion S-meter cal minor - add doxygen info for enums minor - doxygen parameters doxygen formatting add comments info on generating docs doc improvements add comment documentation documentation allow atten = 0 dB patch from SM6PPS fix enum documentation documentation page documentation documentation split orion.c and add doc info documentation SM6PPS mods for AOR 5000a further rx-320 mods by Ken Prox use binary mode VFO requests correct CHANNEL_CAPS sytax Dead simple sample Hamlib program Correct float vs int interpolation options Add autodetect version 1 or 2 firmware (using rig_get_info). Correct V1 calibration. Make V2 calibration the default. Signal RIG_LEVEL_STRENGTH supported. Moved firmware detection to new tt565_open routine, where it is done every time the rig is opened. Add more functions to example program. Ensure printable get_info string Fix bug that seg faulted when get_info returned null. (No reward points!) Add S meter operations to sample program. Adjust retry & timeout values to help in case of no response from rig, i.e., if rig power happens to be off. Prettify some code indents. Better error handling, reliability for serial I/O. Misc prettification. TT Omni VI / Plus improvements Fix typo Fix Omni VI PTT function Update Icom info Declutter Omni VI memories, rit/xit Fix serial I/O error checking Add author. (credits info added to web page, also) Switch back to ASCII freq. setting because of hardware(?) bug. Add AF, RF gain and squelch level capability. Add thanks to W1RFI & ARRL minor changes RIG_STATUS_ALPHA reflecting initial tests. fix missing comma use rawstrength.i which matters in PPC compile fix string handling in LEVEL_RAWSTR Orion - implement RIG_LEVEL_STRENGTH Example updates Orion: Allow frontend to handle RIG_LEVEL_STRENGTH Minor comment re rit/xit Downgrade ERR to WARN (i/o retry) Init revision - tnx Stephane Autofixer sets up for libtool v1 or v2 autofixer.sh supportin libtool v1 and v2 minor update repair echo cmd Max Lock (1): Addition of support for CM108B PTT Michael Black (1393): TenTec Omni VII update from W9MDB New XG3 backend Fixes to termios.c on W32 targets xg3 patch Check TS-590S for EU or US firmware New backend for FT-991 Flush the debug stream Omni VII to set VFO_CURR correctly Omni VII patch for WSJT-X FT-991 patch Small FT-991 patch for WSJT support Omni VII patch FT-857 and FT-991 patches Fix possible frequency overflow on Kenwood and Yaesu Add get_freq to FRG-100 Clean up clang warnings on adat.c Clear up a clang compiler warning in kenwood/elecraft.h Clean up clang warnings in tentec Fix port->pathname checks Quell clang warnings in tests directory Various Yaesu updates Simply define TRUE to 1 in omnivii.c Allow the ft757gx to work with WSJT-X. Remove input redirects in autogen.sh Initial support for the IC-7300 Add send_morse to icom rigs tmd710 patch Icom frame patch Exposed constants via function calls Remove define Merge branch 'master' of https://github.com/N0NB/hamlib Changed some modules to LGPL in lieu of GPL Fixed buffer overflow in rigctl_parse and rotctl_parse Merge branch 'master' of https://github.com/N0NB/hamlib Move K3 DT0 before mode switch, add version info to electraft rig open, WSJT-X VOX rig split now works Merge branch 'master' of https://github.com/N0NB/hamlib Added IC-7850/51 -- works with WSJT-X Merge branch 'master' of https://github.com/N0NB/hamlib Add ic7850 ic7851 -- works with wsjtx Add ic7850 ic7851 -- works with wsjtx Merger 7850/51 into 785x Fix ft991_get_mode Added ft891 backend Fix ic785x default addr to 0x8e Fix FT-891 recognition IC-M710 now working with WSJST-X Add icm710.h to icmarine Makefile.am Merge pull request #1 from Hamlib/master Fix FT857 to return the SMeter-based value Reduce debug info in flrig.c Change RIG_MODE and RIG_FUNC to 64-bit values Merge hamlib head Add PRXll macro for 64-bit use Fixup for 64-bit in memcsv.c 64 bit mods to netrigctl.c testrig.c Add TS-890S as derivative of TS-480 plus new modes Add XHCG to ic706.c Change rmode_t to uint64_t and remove unneeded casts Fix RIG_MODE structure in src/msic.c Fix some 64bit items and add RIG_FUNC_NB2 for TS-890S Suppress GCC unused-return warning Fix rig_idx2settings for 64-bit sprintf_list functions Fix flrig when WSJT-X startup causes rig mode change Increase flrig timeout value Add USB mode to flrig Fix flrig memory leak Fix bug where constant value was being trashed Add PKT modes to ts590.c Add BC2 and NB2 functions for newer kenwoods Change RIG_SETTING_MAX for 64-bit compatibility All kenwoods to have 3-char commands for functions and return whatever value the rig returns instead of 0/1 Changes to add more ts890 capabilities, e.g. NB2, BC2 Fix kenwoood BC BC2 returns Fix kenwood BC BC2 return merge master ... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-10-29 23:58:54
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 56b2814e75ca6b3ce622f90f6160ce8088bc5987 (commit) from fc9755e9162cb72b7fbe50518dc4bb874ca7f9f2 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 56b2814e75ca6b3ce622f90f6160ce8088bc5987 Author: Nate Bargmann <n0...@n0...> Date: Sat Oct 29 18:56:22 2022 -0500 Advance configure.ac to 4.6~git Also advance ABI_REVISION=6. diff --git a/configure.ac b/configure.ac index 92564506..0abd26f4 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,7 @@ dnl Please do not use '-' in the version number, as package managers will fail, 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.5~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) +AC_INIT([Hamlib],[4.6~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) AC_CONFIG_SRCDIR([include/hamlib/rig.h]) AC_CONFIG_MACRO_DIR([macros]) @@ -56,7 +56,7 @@ 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=5 +ABI_REVISION=6 ABI_AGE=0 AC_DEFINE_UNQUOTED([ABI_VERSION], [$ABI_VERSION], [Frontend ABI version]) ----------------------------------------------------------------------- Summary of changes: configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-10-29 23:42:51
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, Hamlib-4.5 has been created at 58f9fd41be46671d2254fa897200f9672c59f94e (commit) - Log ----------------------------------------------------------------- commit 58f9fd41be46671d2254fa897200f9672c59f94e Author: Nate Bargmann <n0...@n0...> Date: Sat Oct 29 18:39:41 2022 -0500 Advance configure.ac to 4.5 diff --git a/configure.ac b/configure.ac index 92564506..28908b58 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,7 @@ dnl Please do not use '-' in the version number, as package managers will fail, 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.5~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) +AC_INIT([Hamlib],[4.5],[ham...@li...],[hamlib],[http://www.hamlib.org]) AC_CONFIG_SRCDIR([include/hamlib/rig.h]) AC_CONFIG_MACRO_DIR([macros]) ----------------------------------------------------------------------- hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-10-29 23:36:59
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via fc9755e9162cb72b7fbe50518dc4bb874ca7f9f2 (commit) from 5a6b0b471967f53b7f591bc3bdca127555768dbc (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit fc9755e9162cb72b7fbe50518dc4bb874ca7f9f2 Author: Nate Bargmann <n0...@n0...> Date: Sat Oct 29 18:35:21 2022 -0500 Change 4.5 release date in NEWS diff --git a/NEWS b/NEWS index 312543fe..35dfca97 100644 --- a/NEWS +++ b/NEWS @@ -16,7 +16,7 @@ Version 4.6 * 2023-XX-XX Version 4.5 - * 2022-10-12 + * 2022-10-30 * New rotator utility https://www.pianetaradio.it/blog/catrotator/ * Add FT-710 * Add Rohde&Schwartz EK89X receiver ----------------------------------------------------------------------- Summary of changes: NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-10-29 22:57:13
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 5a6b0b471967f53b7f591bc3bdca127555768dbc (commit) from 9c02b2ebc2df7a2ac55806e721ec1a95025f75b5 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 5a6b0b471967f53b7f591bc3bdca127555768dbc Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 28 16:30:39 2022 -0500 Reduce debug verbosity diff --git a/src/iofunc.c b/src/iofunc.c index dc0c1937..0b8e6ae9 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -1349,7 +1349,7 @@ static int read_string_generic(hamlib_port_t *p, #endif rd_count = port_read_generic(p, &rxbuffer[total_count], expected_len == 1 ? 1 : minlen, direct); - rig_debug(RIG_DEBUG_VERBOSE, "%s: read %d bytes\n", __func__, (int)rd_count); +// rig_debug(RIG_DEBUG_VERBOSE, "%s: read %d bytes\n", __func__, (int)rd_count); minlen -= rd_count; if (errno == EAGAIN) ----------------------------------------------------------------------- Summary of changes: src/iofunc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2022-10-27 11:38:46
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 9c02b2ebc2df7a2ac55806e721ec1a95025f75b5 (commit) via b63460f05f74972c68a806a0f16e4979efcd0a0d (commit) via 8c274456d43e34b1981ee01e2335e4dde8836793 (commit) via e3ce4a35a4168a0352ba2b31f72610e806bc2165 (commit) via d3d21983f05f8c22f071f5ae0fe7613059e4ecb4 (commit) via bbeb87eb0572067c2a9bf14848070d82a60fc4a0 (commit) via b6743177910773c3790c0183f3ab307179094093 (commit) via 04a1a8def170ede47bcdaed759904f684beca45f (commit) via 399153df9bba1e6770bdc56d1f0eb41adc49c205 (commit) via 0b49f569ba0379710dbed571642d084a2aabcb0b (commit) via e9325c9c7b1453f7c60796459440e74b768dae70 (commit) via e616f282818a11fd07b9d8d89b45491c0067ede8 (commit) via 411925a372aadd073792986de85d53b2d338cb9e (commit) via b46b930770ad4b8e3be0e019f0c6d0892eef4905 (commit) via e6cd452c9d3804486b8e757512a05132a52cbfe7 (commit) via 04bc5cc0895484cef60496d2b6f4096b1ab6dcb6 (commit) via 791a5e3f5748f9eba33260354ca2a67279caca7d (commit) via 436365f6a496db6e0b04e1de997637fc54c55682 (commit) via ec4aea81b2b25555e7c76be28e7f781fceeab59f (commit) via e6d0403cd2d81cf03643776c47cebd8dc84810dc (commit) via dde5d752fce4521d6daabe6253caf702bf9fff86 (commit) via b3d0a5a350bef1dbdb9908bc5558efc2bc64cc45 (commit) via eb9efa720052360eb8868dd25cf26966ff977169 (commit) via 032d37626e961a67f70baf697ddf5ff22059c9b2 (commit) via 8adfd5e351e88f217cccbd93a45b50226b5cf4d0 (commit) via 4dbce1a0aa57e1712d6e0166b428ecdd59b44f3c (commit) via 63805eb427890535da97447544bc7c2b56ecc433 (commit) via 745554683433b40a43e27e08bd171c5254fb9c2c (commit) via 48241f52d0411ea2d5128ebcb65dcc23b98f9fe2 (commit) via e7647de001ed7f53d8d00e7379a76d3ca024219f (commit) via 0b68de7b6569110ebf85dbd0b9fe7dea4547f904 (commit) via 467964aba0106ef3e43e3b436373db8c1f32b2ea (commit) via 6bd5ab89b66d9687bcf37297aee064e3c84bcd9f (commit) via c169ec59dd70322c8e0347fbf205462b2416f493 (commit) via a033b66f9c5e164ee7d7c77809e631fee71408c8 (commit) via 66351df5549266e3d2756632a096ef65a1ae52c2 (commit) via e28e019179530538efee2274a31b4f70546f812d (commit) via 67b933ddb5dacc4804b32a100d110c9710a6b69f (commit) via 9ffd0a4ba5e557db170b2aa61c754f185ec72a3e (commit) via 7c2bdbb64fc2aba9c8cc9ef514db3210b04a7da1 (commit) via 9b98ea11eb11460dcbd5befeaaa3f9e821e68826 (commit) via 57a7e656c29e34a261ed2234bbdb5a6e3c563451 (commit) via b1d132dd276c5b492239f9459cdae37161bcd7db (commit) via 4985d9ab26fae3a492428ea1349847a397a33a17 (commit) via 7db23d549f16212df0c8a3f0e01eeb693ad83335 (commit) via 8c4c906efe99597c8dc281f2e434d3b6291bd6f2 (commit) via e7262e23c8250b8606b0da6dfd1cb48df6dfe996 (commit) via f58ca95c9c265fe4785066d0143cf0bfb3f0df31 (commit) via 098d1d8dbb2f9f3042380bfee117fb5e357e1e8c (commit) via 224ccc7839c0f2ce4535b38ce0f81cf7a3f67b5c (commit) via 66a823bb6b9b6c27bc61924cbd285d937640a977 (commit) via 7da1a1f6a1ebc2c44b9a9834b0a8d6b45643f8de (commit) via 9cb511af00f00e2ab42d0a8c731492f615a207c7 (commit) via f5f97b35db7ec607bc6205599c0ad9524119e561 (commit) via 400758136357cbfeeb33f665d0b0f6f6c14ce7e2 (commit) via 6c746c310bc85b3629220a6182aeb756b52b4405 (commit) via 86245cffa6bc831df2a5555a6c1240db5764e4ee (commit) via 0cd6f1f7610d353d4fdb2e8e0ac02e39364059f2 (commit) via 81f489b969d39d5460efe36b16fe3290e56d6186 (commit) via 1d0d73340547f7c0f49a5dda34fc7443ac7c647c (commit) via 571f59e696f474ee3cffe35a8a3a74e20d68e055 (commit) via d3824aa7abcfa1856097bc31777198d3e50241e7 (commit) via 927b2d858ab2710301c26c04a40316c6bc4a6e8d (commit) via 9410e7f66f2a6b789dc5fa0dc2534837688477c4 (commit) via e2616b991a6cc6fa22c6f0e77fd437aa5aa17bfd (commit) via e630fc818005f551e4fccf522a0fd71d73b42d54 (commit) via 5701e73e1e38f3c8818b26044f7734f109d164dc (commit) via 69a39dfa2e335d1208a4cf692690e61f9dd33ba9 (commit) via 5e9b853d0791cae2d9bbb9e364052134866de843 (commit) via 7e51932a9ec55d75f74768c27fb40e9819170066 (commit) via aa0937e6c150c3cea599b462732c66a9234ddcb5 (commit) via 884190886c4c2763aeeb23b2b5481ef0ff389efd (commit) via 1aed27c71a11bbd7f2c89b88bdcf2b1219383646 (commit) via b3d69d221e35e860503ff7dc83658a6aa1a9b1a7 (commit) via 4c2a68c94bc4451293ea05ce3f071845b202c783 (commit) via 825e3eefa814fea6d597d3eb8547c40f2a5542ce (commit) via f0fdf97a9b8d1c2a87720bf9930c48f43d623a5e (commit) via 7c071b84b69f1fb0436af458db9359b9e42a696a (commit) from 6f967a68d5a6c0fda3e0d4092dde54eb6ffd4c32 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 9c02b2ebc2df7a2ac55806e721ec1a95025f75b5 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Oct 25 23:26:16 2022 -0500 Fix Yaesu DT command and add 2 or 4 digit timezone option https://github.com/Hamlib/Hamlib/issues/1132 diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index d04b1f46..b80a640c 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -1158,13 +1158,16 @@ Sets rig clock -- note that some rigs do not handle seconds or milliseconds. If you try to set sec/msec and rig does not support it you will get a debug warning message. Format is ISO8601, .EX -Formats accepted -YYYY-MM-DDTHH:MM:SS.SSS+ZZ (where +ZZ is either -/+ UTC offset) +Formats accepted allow for 2-digit or 4-digit time zone +YYYY-MM-DDTHH:MM:SS.SSS+ZZ (where +ZZ is either -/+ UTC offset HH) +YYYY-MM-DDTHH:MM:SS.SSS+ZZZZ (where +ZZZZ is either -/+ UTC offset HHMM) YYYY-MM-DDTHH:MM:SS+ZZ +YYYY-MM-DDTHH:MM:SS+ZZZZ YYYY-MM-DDTHH:MM+ZZ +YYYY-MM-DDTHH:MM+ZZZZ YYYY-MM-DD (sets date only) Note: Icom rigs expect you to set local time and the hours off to UTC. -So...4PM EST example would be 2021-12-01T16:00:00+05 +So...4PM EST example would be 2021-12-01T16:00:00+0500 But...if you want to display GMT you must set the clock for GMT with zero UTC offset. Hopefully Icom will allow displaying either clock in the future diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 1aee1fdc..d10f7605 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -263,9 +263,9 @@ static const yaesu_newcat_commands_t valid_commands[] = {"CT", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, {"DA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, {"DN", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"DT", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE }, {"DP", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, {"DS", TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, + {"DT", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE }, {"ED", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, {"EK", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE }, {"EM", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE }, @@ -11557,6 +11557,8 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, RETURNFUNC2(err); } + if (hour < 0) RETURNFUNC2(RIG_OK); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT1%02d%02d%02d%c", hour, min, sec, cat_term); diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 8b52fa79..76547210 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20221021" +#define NEWCAT_VER "20221025" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 diff --git a/simulators/simyaesu.c b/simulators/simyaesu.c index f332f459..c5a31363 100644 --- a/simulators/simyaesu.c +++ b/simulators/simyaesu.c @@ -23,6 +23,8 @@ int roofing_filter_main = 1; int roofing_filter_sub = 6; int width_main = 0; int width_sub = 0; +int ex039 = 0; +int lk = 0; // ID 0310 == 310, Must drop leading zero typedef enum nc_rigid_e @@ -401,6 +403,40 @@ int main(int argc, char *argv[]) SNPRINTF(buf, sizeof(buf), "SH%c%02d;", buf[2], buf[2] == 0 ? width_main : width_sub); } + else if (strcmp(buf, "EX039;") == 0) + { + SNPRINTF(buf, sizeof(buf), "EX039%d;", ex039); + n = write(fd, buf, strlen(buf)); + } + else if (strncmp(buf, "EX039", 3) == 0) + { + sscanf(buf, "EX039%d", &ex039); + } + else if (strcmp(buf, "LK;") == 0) + { + SNPRINTF(buf, sizeof(buf), "LK%d;", lk); + n = write(fd, buf, strlen(buf)); + } + else if (strncmp(buf, "LK", 3) == 0) + { + sscanf(buf, "LK%d", &lk); + } + else if (strncmp(buf, "DT0;", 4) == 0) + { + SNPRINTF(buf, sizeof(buf), "DT020221022;"); + n = write(fd, buf, strlen(buf)); + } + else if (strncmp(buf, "DT1;", 4) == 0) + { + SNPRINTF(buf, sizeof(buf), "DT1222100;"); + n = write(fd, buf, strlen(buf)); + } + else if (strncmp(buf, "DT2;", 4) == 0) + { + SNPRINTF(buf, sizeof(buf), "DT2+0500;"); + n = write(fd, buf, strlen(buf)); + } + else if (strlen(buf) > 0) { diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index c52c5be6..99fb0702 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -5172,9 +5172,9 @@ declare_proto_rig(get_cache) /* '0xf8' */ declare_proto_rig(set_clock) { - int year, mon, day, hour = -1, min = -1, sec = -1; - double msec; - int utc_offset = 0; + int year, mon, day, hour = -1, min = -1, sec = 0; + double msec=-1; + int utc_offset = 0; int n; char timebuf[64]; @@ -5196,22 +5196,35 @@ declare_proto_rig(set_clock) &hour, &min, &sec, &msec, &utc_offset); } - else - { + else if (arg1[16] == '+' || arg1[16] == '-') + { // YYYY-MM-DDTHH:MM+ZZ + n = sscanf(arg1, "%04d-%02d-%02dT%02d:%02d%d", &year, &mon, &day, &hour, + &min, &utc_offset); + } + else if (arg1[19] == '+' || arg1[19] == '-') + { // YYYY-MM-DDTHH:MM:SS+ZZ + n = sscanf(arg1, "%04d-%02d-%02dT%02d:%02d:%02d%d", &year, &mon, &day, &hour, + &min, &sec, &utc_offset); + } + else if (arg1[23] == '+' || arg1[23] == '-') + { // YYYY-MM-DDTHH:MM:SS.SSS+ZZ n = sscanf(arg1, "%04d-%02d-%02dT%02d:%02d:%02d%lf%d", &year, &mon, &day, &hour, &min, &sec, &msec, &utc_offset); } + else + { + rig_debug(RIG_DEBUG_ERR, "%s: '%s' not valid time format\n", __func__, arg1); + RETURNFUNC2(-RIG_EINVAL); + } rig_debug(RIG_DEBUG_VERBOSE, "%s: n=%d, %04d-%02d-%02dT%02d:%02d:%02d.%0.3f%s%02d\n", __func__, n, year, mon, day, hour, min, sec, msec, utc_offset >= 0 ? "+" : "-", (unsigned)abs(utc_offset)); - rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); - if (utc_offset < 24) { utc_offset *= 100; } // allow for minutes offset too - rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + rig_debug(RIG_DEBUG_VERBOSE, "%s: utc_offset=%d\n", __func__, utc_offset); RETURNFUNC(rig_set_clock(rig, year, mon, day, hour, min, sec, msec, utc_offset)); commit b63460f05f74972c68a806a0f16e4979efcd0a0d Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Oct 25 23:23:13 2022 -0500 Future code information in iofunc.c diff --git a/src/iofunc.c b/src/iofunc.c index cdaa662f..dc0c1937 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -1339,10 +1339,14 @@ static int read_string_generic(hamlib_port_t *p, */ do { - // The ioctl works on Linux but not mingw -- enable in 4.6 for non-mingw builds and see if it breaks anything - //int avail=0; - //ioctl(p->fd, FIONREAD, &avail); +#if 0 +#ifndef __MINGW32__ + // The ioctl works on Linux but not mingw + int avail=0; + ioctl(p->fd, FIONREAD, &avail); //rig_debug(RIG_DEBUG_ERR, "xs: avail=%d expected_len=%d, minlen=%d, direct=%d\n", __func__, avail, expected_len, minlen, direct); +#endif +#endif rd_count = port_read_generic(p, &rxbuffer[total_count], expected_len == 1 ? 1 : minlen, direct); rig_debug(RIG_DEBUG_VERBOSE, "%s: read %d bytes\n", __func__, (int)rd_count); commit 8c274456d43e34b1981ee01e2335e4dde8836793 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 22:59:49 2022 -0500 Update rigctl.1 Update simft897.c diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index 0487f4a7..d04b1f46 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -947,13 +947,18 @@ radio backend. Perform a .RI \(aq "Scan Fct" \(aq on a -.RI \(aq "Scan Channel" \(aq. +.RI \(aq "Scan Option" \(aq. .IP Scan Function is a token: \(oqSTOP\(cq, \(oqMEM\(cq, \(oqSLCT\(cq, \(oqPRIO\(cq, \(oqPROG\(cq, \(oqDELTA\(cq, \(oqVFO\(cq, \(oqPLT\(cq. .IP -.\" FIXME: What is a scan channel value? -Scan Channel is an integer (maybe?). +Scan Option is an integer. +.IP +Scan Option for Yaesu rigs 0=STOP, 1=UP, 2=DOWN. +.IP +Scan Option for Icom rigs is a channel number to program with G otherwise not used. +.IP +Scan Option for Kenwood rigs is not used. .IP .BR Note : Passing a \(oq?\(cq (query) as the first argument instead of a Scan Fct token diff --git a/simulators/simft897.c b/simulators/simft897.c index 6367847c..f86fe184 100644 --- a/simulators/simft897.c +++ b/simulators/simft897.c @@ -144,7 +144,10 @@ again: case 0x03: printf("READ RX STATUS\n"); - buf[0] = buf[1] = buf[2] = buf[3] = 0; + buf[0] = 0x01; + buf[1] = 0x40; + buf[2] = 0x74; + buf[3] = 0x00; buf[4] = 0x03; n = write(fd, buf, 5); break; commit e3ce4a35a4168a0352ba2b31f72610e806bc2165 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 22:54:20 2022 -0500 Add RIG_SCAN_STOP to newcat_scan diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 2bf46758..1aee1fdc 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -6895,8 +6895,11 @@ int newcat_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch) int retval; ENTERFUNC; - if (scan != RIG_SCAN_VFO) RETURNFUNC2(-RIG_EINVAL); - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SC%d%c", ch, cat_term); + + if (scan != RIG_SCAN_VFO) { RETURNFUNC2(-RIG_EINVAL); } + + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SC%d%c", + scan == RIG_SCAN_STOP ? 0 : ch, cat_term); if (RIG_OK != (retval = newcat_set_cmd(rig))) { commit d3d21983f05f8c22f071f5ae0fe7613059e4ecb4 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 22:41:29 2022 -0500 Fix newcat_scan diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index f7652eb9..2bf46758 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -6895,7 +6895,8 @@ int newcat_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch) int retval; ENTERFUNC; - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SC%d%c", scan, cat_term); + if (scan != RIG_SCAN_VFO) RETURNFUNC2(-RIG_EINVAL); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SC%d%c", ch, cat_term); if (RIG_OK != (retval = newcat_set_cmd(rig))) { commit bbeb87eb0572067c2a9bf14848070d82a60fc4a0 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 22:27:58 2022 -0500 Add newcat_scan for Yaesu rigs diff --git a/rigs/yaesu/ft1200.c b/rigs/yaesu/ft1200.c index 9ba50b22..88882397 100644 --- a/rigs/yaesu/ft1200.c +++ b/rigs/yaesu/ft1200.c @@ -190,6 +190,7 @@ const struct rig_caps ftdx1200_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX1200_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, /* May enable later as the 1200 has an Auto Info command */ .bank_qty = 0, @@ -323,5 +324,6 @@ const struct rig_caps ftdx1200_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft2000.c b/rigs/yaesu/ft2000.c index 268586b5..c73a254e 100644 --- a/rigs/yaesu/ft2000.c +++ b/rigs/yaesu/ft2000.c @@ -172,6 +172,7 @@ const struct rig_caps ft2000_caps = .max_xit = Hz(9999), .max_ifshift = Hz(1000), .vfo_ops = FT2000_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, .transceive = RIG_TRN_OFF, /* May enable later as the 2000 has an Auto Info command */ .bank_qty = 0, @@ -308,5 +309,6 @@ const struct rig_caps ft2000_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft3000.c b/rigs/yaesu/ft3000.c index 88700167..34ce1256 100644 --- a/rigs/yaesu/ft3000.c +++ b/rigs/yaesu/ft3000.c @@ -285,6 +285,7 @@ const struct rig_caps ftdx3000_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX5000_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, /* one of the few diffs from the 5000 */ .transceive = RIG_TRN_OFF, /* May enable later as the 5000 has an Auto Info command */ .bank_qty = 0, @@ -414,6 +415,7 @@ const struct rig_caps ftdx3000_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft450.c b/rigs/yaesu/ft450.c index f157b24f..021d123d 100644 --- a/rigs/yaesu/ft450.c +++ b/rigs/yaesu/ft450.c @@ -82,6 +82,7 @@ const struct rig_caps ft450_caps = .agc_level_count = 4, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FT450_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, /* May enable later as the 450 has an Auto Info command */ .bank_qty = 0, @@ -203,6 +204,7 @@ const struct rig_caps ft450_caps = .get_channel = newcat_get_channel, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft5000.c b/rigs/yaesu/ft5000.c index aaa42e35..150f32ad 100644 --- a/rigs/yaesu/ft5000.c +++ b/rigs/yaesu/ft5000.c @@ -180,6 +180,7 @@ const struct rig_caps ftdx5000_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX5000_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_ANT | RIG_TARGETABLE_ROOFING, .transceive = RIG_TRN_OFF, /* May enable later as the 5000 has an Auto Info command */ .bank_qty = 0, @@ -310,5 +311,6 @@ const struct rig_caps ftdx5000_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft710.c b/rigs/yaesu/ft710.c index 54ddfb1e..a643cccd 100644 --- a/rigs/yaesu/ft710.c +++ b/rigs/yaesu/ft710.c @@ -176,6 +176,7 @@ const struct rig_caps ft710_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX10_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON, .transceive = RIG_TRN_OFF, /* May enable later as the FTDX10 has an Auto Info command */ .bank_qty = 0, @@ -311,5 +312,6 @@ const struct rig_caps ft710_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft891.c b/rigs/yaesu/ft891.c index b8247080..2c244c65 100644 --- a/rigs/yaesu/ft891.c +++ b/rigs/yaesu/ft891.c @@ -173,6 +173,7 @@ const struct rig_caps ft891_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FT891_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, /* May enable later as the 950 has an Auto Info command */ .bank_qty = 0, @@ -323,6 +324,7 @@ const struct rig_caps ft891_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft9000.c b/rigs/yaesu/ft9000.c index 43fe7f4d..39305e22 100644 --- a/rigs/yaesu/ft9000.c +++ b/rigs/yaesu/ft9000.c @@ -89,6 +89,7 @@ const struct rig_caps ft9000_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FT9000_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_ANT, .transceive = RIG_TRN_OFF, /* May enable later as the 9000 has an Auto Info command */ .bank_qty = 0, @@ -213,5 +214,6 @@ const struct rig_caps ft9000_caps = .get_channel = newcat_get_channel, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft950.c b/rigs/yaesu/ft950.c index b9b46ea0..c3e682a9 100644 --- a/rigs/yaesu/ft950.c +++ b/rigs/yaesu/ft950.c @@ -127,6 +127,7 @@ const struct rig_caps ft950_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FT950_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, /* May enable later as the 950 has an Auto Info command */ .bank_qty = 0, @@ -285,5 +286,6 @@ const struct rig_caps ft950_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index 52765118..d2af1e20 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -141,7 +141,7 @@ const struct rig_caps ft991_caps = RIG_MODEL(RIG_MODEL_FT991), .model_name = "FT-991", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".12", + .version = NEWCAT_VER ".13", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -181,6 +181,7 @@ const struct rig_caps ft991_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FT991_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, /* May enable later as the 950 has an Auto Info command */ .bank_qty = 0, @@ -354,9 +355,11 @@ const struct rig_caps ft991_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .wait_morse = rig_wait_morse, + .scan = newcat_scan, .send_voice_mem = newcat_send_voice_mem, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ftdx10.c b/rigs/yaesu/ftdx10.c index 3ef3876d..58d1be65 100644 --- a/rigs/yaesu/ftdx10.c +++ b/rigs/yaesu/ftdx10.c @@ -176,6 +176,7 @@ const struct rig_caps ftdx10_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX10_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON, .transceive = RIG_TRN_OFF, /* May enable later as the FTDX10 has an Auto Info command */ .bank_qty = 0, @@ -311,5 +312,6 @@ const struct rig_caps ftdx10_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ftdx101.c b/rigs/yaesu/ftdx101.c index 76b97e7c..d7aeec2f 100644 --- a/rigs/yaesu/ftdx101.c +++ b/rigs/yaesu/ftdx101.c @@ -176,6 +176,7 @@ const struct rig_caps ftdx101d_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX101_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON | RIG_TARGETABLE_ANT | RIG_TARGETABLE_ROOFING, .transceive = RIG_TRN_OFF, /* May enable later as the FTDX101 has an Auto Info command */ .bank_qty = 0, @@ -312,6 +313,7 @@ const struct rig_caps ftdx101d_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ftdx101mp.c b/rigs/yaesu/ftdx101mp.c index 349bda87..1f635181 100644 --- a/rigs/yaesu/ftdx101mp.c +++ b/rigs/yaesu/ftdx101mp.c @@ -112,6 +112,7 @@ const struct rig_caps ftdx101mp_caps = .max_xit = Hz(9999), .max_ifshift = Hz(1200), .vfo_ops = FTDX101_VFO_OPS, + .scan_ops = RIG_SCAN_VFO, .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON | RIG_TARGETABLE_ANT, .transceive = RIG_TRN_OFF, /* May enable later as the FTDX101 has an Auto Info command */ .bank_qty = 0, @@ -249,5 +250,6 @@ const struct rig_caps ftdx101mp_caps = .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, + .scan = newcat_scan, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 627c2a0c..f7652eb9 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -6891,9 +6891,20 @@ int newcat_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op) int newcat_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch) { + struct newcat_priv_data *priv = (struct newcat_priv_data *)rig->state.priv; + int retval; + ENTERFUNC; + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SC%d%c", scan, cat_term); - RETURNFUNC(-RIG_ENAVAIL); + if (RIG_OK != (retval = newcat_set_cmd(rig))) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, + retval); + RETURNFUNC2(retval); + } + + RETURNFUNC2(retval); } @@ -11629,4 +11640,3 @@ int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, RETURNFUNC2(retval); } - diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 87b3878b..8b52fa79 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20221013" +#define NEWCAT_VER "20221021" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 @@ -236,7 +236,7 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, int sec, double msec, int utc_offset); int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, int *min, int *sec, double *msec, int *utc_offset); - +int newcat_scan(RIG *rig, vfo_t vfo, scan_t scan, int ch); #define TOKEN_BACKEND(t) (t) commit b6743177910773c3790c0183f3ab307179094093 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 13:26:13 2022 -0500 Fix kenwood PS command length diff --git a/rigs/kenwood/kenwood.c b/rigs/kenwood/kenwood.c index 7612ace6..b6964f5c 100644 --- a/rigs/kenwood/kenwood.c +++ b/rigs/kenwood/kenwood.c @@ -4862,7 +4862,7 @@ int kenwood_get_powerstat(RIG *rig, powerstat_t *status) RETURNFUNC(-RIG_EINVAL); } - retval = kenwood_safe_transaction(rig, "PS", pwrbuf, 6, 4); + retval = kenwood_safe_transaction(rig, "PS", pwrbuf, 6, 3); if (retval != RIG_OK) { diff --git a/rigs/kenwood/kenwood.h b/rigs/kenwood/kenwood.h index d7b70a34..194a7068 100644 --- a/rigs/kenwood/kenwood.h +++ b/rigs/kenwood/kenwood.h @@ -28,7 +28,7 @@ #include "token.h" #include "misc.h" -#define BACKEND_VER "20221012" +#define BACKEND_VER "20221021" #define EOM_KEN ';' #define EOM_TH '\r' commit 04a1a8def170ede47bcdaed759904f684beca45f Merge: 399153df 0b49f569 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 11:22:45 2022 -0500 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit 399153df9bba1e6770bdc56d1f0eb41adc49c205 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 21 08:19:46 2022 -0500 Add bootstrap info to README.md diff --git a/README.md b/README.md index 09e5372e..754d423f 100644 --- a/README.md +++ b/README.md @@ -78,6 +78,8 @@ Recompiling Hamlib is entirely developed using GNU tools, under various Linux systems. The library may be recompiled by the familiar "three step": +Note: if ./configure does not exist run ./bootstrap first + ./configure make sudo make install commit 0b49f569ba0379710dbed571642d084a2aabcb0b Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Oct 20 22:35:02 2022 -0500 Update INSTALL to include directions for git clone https://github.com/Hamlib/Hamlib/issues/1128 diff --git a/INSTALL b/INSTALL index 3fabd7a3..d55fed81 100644 --- a/INSTALL +++ b/INSTALL @@ -10,11 +10,16 @@ on. These are generic instructions for people who are not familiar with installing autoconfiguring software (along with some Hamlib-specific information). + The simplest way to compile this package is to enter the source code main directory and do the following: 1. Configure the source code by typing: + If you check out the source code from github you need this step first + $ ./bootstrap + + With the tar file or after the step above from a git clone $ ./configure If configure does not exist you can create it with ./bootstrap commit e9325c9c7b1453f7c60796459440e74b768dae70 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 16 08:15:33 2022 -0500 Fix case on TS-990S diff --git a/rigs/kenwood/ts990s.c b/rigs/kenwood/ts990s.c index eb2c01e5..1bcd9ddd 100644 --- a/rigs/kenwood/ts990s.c +++ b/rigs/kenwood/ts990s.c @@ -120,7 +120,7 @@ static struct kenwood_priv_caps ts990s_priv_caps = const struct rig_caps ts990s_caps = { RIG_MODEL(RIG_MODEL_TS990S), - .model_name = "TS-990s", + .model_name = "TS-990S", .mfg_name = "Kenwood", .version = BACKEND_VER ".1", .copyright = "LGPL", commit e616f282818a11fd07b9d8d89b45491c0067ede8 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Oct 15 17:06:53 2022 -0500 set_mode will no longer set mode unless necessary this will preven display flashing on some rigs now that WSJTX sets VFOB mode diff --git a/src/rig.c b/src/rig.c index 722914fa..7e07af18 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2246,6 +2246,21 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) vfo = vfo_fixup(rig, vfo, rig->state.cache.split); + // if we're not asking for bandwidth and the mode is already set we don't need to do it + // this will prevent flashing on some rigs like the TS-870 + if (caps->get_mode && width == RIG_PASSBAND_NOCHANGE) + { + rmode_t mode_curr; + pbwidth_t width_curr; + retcode = caps->get_mode(rig, vfo, &mode_curr, &width_curr); + if (retcode == RIG_OK && mode==mode_curr) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s: mode already %s and bw change not requested\n", __func__, rig_strrmode(mode)); + ELAPSED2; + RETURNFUNC2(RIG_OK); + } + } + if ((caps->targetable_vfo & RIG_TARGETABLE_MODE) || vfo == rig->state.current_vfo) { commit 411925a372aadd073792986de85d53b2d338cb9e Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 14 15:44:24 2022 -0500 FT710 does have targetable mode diff --git a/rigs/yaesu/ft710.c b/rigs/yaesu/ft710.c index d9a8da36..54ddfb1e 100644 --- a/rigs/yaesu/ft710.c +++ b/rigs/yaesu/ft710.c @@ -176,7 +176,7 @@ const struct rig_caps ft710_caps = .agc_level_count = 5, .agc_levels = { RIG_AGC_OFF, RIG_AGC_FAST, RIG_AGC_MEDIUM, RIG_AGC_SLOW, RIG_AGC_AUTO }, .vfo_ops = FTDX10_VFO_OPS, - .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON, + .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_FUNC | RIG_TARGETABLE_LEVEL | RIG_TARGETABLE_COMMON, .transceive = RIG_TRN_OFF, /* May enable later as the FTDX10 has an Auto Info command */ .bank_qty = 0, .chan_desc_sz = 0, commit b46b930770ad4b8e3be0e019f0c6d0892eef4905 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 14 15:33:26 2022 -0500 Update FT710 parameters based on testing FT8 mode defaults to 1 stop bit and no hardware flow control diff --git a/rigs/yaesu/ft710.c b/rigs/yaesu/ft710.c index 786a3e23..d9a8da36 100644 --- a/rigs/yaesu/ft710.c +++ b/rigs/yaesu/ft710.c @@ -137,7 +137,7 @@ const struct rig_caps ft710_caps = RIG_MODEL(RIG_MODEL_FT710), .model_name = "FT-710", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".0", + .version = NEWCAT_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -147,12 +147,12 @@ const struct rig_caps ft710_caps = .serial_rate_min = 4800, .serial_rate_max = 115200, .serial_data_bits = 8, - .serial_stop_bits = 2, + .serial_stop_bits = 1, .serial_parity = RIG_PARITY_NONE, - .serial_handshake = RIG_HANDSHAKE_HARDWARE, - .write_delay = FTDX10_WRITE_DELAY, - .post_write_delay = FTDX10_POST_WRITE_DELAY, - .timeout = 2000, + .serial_handshake = RIG_HANDSHAKE_NONE, + .write_delay = 0, + .post_write_delay = 0, + .timeout = 1000, .retry = 3, .has_get_func = FTDX10_FUNCS, .has_set_func = FTDX10_FUNCS, commit e6cd452c9d3804486b8e757512a05132a52cbfe7 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 14 09:02:40 2022 -0500 Fix detection if FT-710 Update simyaesu.c diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 5ec9091f..627c2a0c 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -7351,7 +7351,7 @@ ncboolean newcat_valid_command(RIG *rig, char const *const command) if (!is_ft450 && !is_ft950 && !is_ft891 && !is_ft991 && !is_ft2000 && !is_ftdx5000 && !is_ftdx9000 && !is_ftdx1200 && !is_ftdx3000 && !is_ftdx101d - && !is_ftdx101mp && !is_ftdx10) + && !is_ftdx101mp && !is_ftdx10 && !is_ft710) { rig_debug(RIG_DEBUG_ERR, "%s: '%s' is unknown\n", __func__, caps->model_name); RETURNFUNC2(FALSE); diff --git a/simulators/simyaesu.c b/simulators/simyaesu.c index 9d63509b..f332f459 100644 --- a/simulators/simyaesu.c +++ b/simulators/simyaesu.c @@ -117,7 +117,7 @@ int main(int argc, char *argv[]) { printf("Cmd:%s\n", buf); } - else { return 0; } + //else { return 0; } if (buf[0] == 0x0a) { commit 04bc5cc0895484cef60496d2b6f4096b1ab6dcb6 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Oct 13 17:41:27 2022 -0500 Add FT710 to newcat.c checks diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 6c13a165..5ec9091f 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -90,8 +90,9 @@ typedef struct _yaesu_newcat_commands ncboolean ft1200; ncboolean ft3000; ncboolean ft101d; - ncboolean ft10; + ncboolean ftdx10; ncboolean ft101mp; + ncboolean ft710; } yaesu_newcat_commands_t; /** @@ -206,6 +207,7 @@ const cal_table_float_t yaesu_default_id_meter_cal = // Easy reference to rig model -- it is set in newcat_valid_command static ncboolean is_ft450; +static ncboolean is_ft710; static ncboolean is_ft891; static ncboolean is_ft950; static ncboolean is_ft991; @@ -237,125 +239,125 @@ static ncboolean is_ftdx10; */ static const yaesu_newcat_commands_t valid_commands[] = { - /* Command FT-450 FT-950 FT-891 FT-991 FT-2000 FT-9000 FT-5000 FT-1200 FT-3000 FTDX101D FTDX10 FTDX101MP */ - {"AB", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"AC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"AG", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"AI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"AM", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"AN", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE }, - {"AO", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, - {"BA", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BC", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BM", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, - {"BP", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BU", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"BY", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"CH", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"CN", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"CO", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"CS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"CT", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"DA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"DN", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"DT", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE }, - {"DP", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE }, - {"DS", TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE }, - {"ED", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"EK", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, TRUE }, - {"EM", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE }, - {"EN", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"EU", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"EX", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"FA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"FB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"FK", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, - {"FN", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, - {"FR", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"FS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"FT", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"GT", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"ID", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"IF", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"IS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"KM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"KP", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"KR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"KS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"KY", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"LK", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"LM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MA", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MB", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, - {"MC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MG", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MK", TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE }, - {"ML", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MT", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, - {"MW", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"MX", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"NA", TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"NB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"NL", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"NR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"OI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"OS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PL", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PR", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"PS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"QI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"QR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"QS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RF", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RG", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RL", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RO", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE }, - {"RP", TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, - {"RS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RT", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"RU", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SF", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SH", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SQ", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, - {"SS", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE }, + /* Command FT-450 FT-950 FT-891 FT-991 FT-2000 FT-9000 FT-5000 FT-1200 FT-3000 FTDX101D FTDX10 FTDX101MP FT710 */ + {"AB", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"AC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"AG", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"AI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"AM", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"AN", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, FALSE }, + {"AO", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"BA", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BC", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BM", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"BP", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BU", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"BY", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"CH", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"CN", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"CO", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"CS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"CT", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"DA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"DN", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"DT", FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"DP", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, + {"DS", TRUE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, + {"ED", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"EK", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, FALSE, FALSE, TRUE, FALSE }, + {"EM", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, FALSE, TRUE }, + {"EN", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"EU", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"EX", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"FA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"FB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"FK", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, + {"FN", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"FR", FALSE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"FS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"FT", TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"GT", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"ID", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"IF", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"IS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"KM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"KP", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"KR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"KS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"KY", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"LK", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"LM", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MA", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MB", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"MC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MD", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MG", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MK", TRUE, TRUE, FALSE, FALSE, TRUE, TRUE, TRUE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE }, + {"ML", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MT", FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, TRUE, TRUE, TRUE, TRUE }, + {"MW", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"MX", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"NA", TRUE, TRUE, TRUE, TRUE, TRUE, FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"NB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"NL", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"NR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"OI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"OS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PA", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PB", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PC", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PL", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PR", FALSE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"PS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"QI", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"QR", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"QS", TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE, TRUE }, + {"RA", TRUE, TRUE, TRUE, TRUE, ... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-08-25 18:40:10
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 6f967a68d5a6c0fda3e0d4092dde54eb6ffd4c32 (commit) via efd166fb50f0bea3887c4d40b3ed951312fb113c (commit) via 2c5013662dfe3158b2c3806e59be2c62fb277915 (commit) via dc02c566f5f5c9f257de99d1724d786ee8b47bc0 (commit) via ef06b358d7f1fc477608f3dc2cd167f45592a71d (commit) via 2275bf51f85fba88d405e4e206cbc941692106f4 (commit) via 95126fd350169c778c7f53b1233a78835874aec4 (commit) via f8f0678988c36abf2e042f97fc4166d6c91cb59b (commit) via 4664620b92b0f5167db1043fa98f727b396bcb04 (commit) via 3f99ec47db8a0aefdf50410dfcdcc62a942e9f21 (commit) via e86e05bce33df755f5a650fde3c5bbf79433d79e (commit) via e8fa723bc88d8ba4934895afa85196a217c8b749 (commit) via 2fdf608793074ce36d5e9ed7f86ef52ca6ab974b (commit) via c34f71933780245fb48a9d448b43c07fcc9b3226 (commit) via 2f08201f1295626fded6c01710fbccdce7d01e88 (commit) via ce5c90a6c72229e0f9fc1e1e48987c81c53d6c9e (commit) via b4150fce198daa77687cc868128be3e8b4b02e50 (commit) via d0dcfbff84597d4814e73256804d1fe6cf4d589f (commit) via abc2d5a84613691bbe7b2e6e5332797865295f9c (commit) via b97b8b0fe7c0b76f3e4715416c1da39d800c5e5e (commit) via 28b1a9bb9525be07f7d80212e17b4d744a0dc9f5 (commit) via 179ee66f0d788b95d3d26363391b6e64b4cb8ab6 (commit) via 6965927fb4b610e36edcc43dff8769f2a9a01b15 (commit) via ed5a26ac4e8670424ab7c686f5db88e362fa0595 (commit) via deb5ea6d6fa0adf09eb0ec07697d80b3739191d6 (commit) via 4442f67e7adc40ab3a705834d602f4b0f2d6da2c (commit) via 88f5022079a7d5dcad2047f5d43dffee2f130de7 (commit) via 23fcad6d866911c346028b750beebef5fd1799c9 (commit) via 34e651cf62ecc32649a29d1a68a07d47ff6dc686 (commit) via 2b4411c9c3a26f81d4428a97b1d2399ed1e4b6f7 (commit) via fb62a2f8814145e469d8762c713c089843f7e1e7 (commit) via 36e88e705b2a4260c84cac52b2c0b049ca5b2be5 (commit) via c4a2f647882be5596809b06379b69b146b353c5b (commit) via fa162231e7672575ed9889641f9f1414d538a1a2 (commit) via 7b8aa15b9c1112b9ed790ad481a0eaf5644c4d83 (commit) via 824a6d11fc37fb2877ab5bbe487d911c7ae56b45 (commit) via 810da5f54c7533289c2d4c86d20fedf3f57cbf0a (commit) via eea51fe7c7ce25643699bd7c9b73153ece3cac0f (commit) via 3c4a9f162714e9ad8686692df3ec15c34dfa2602 (commit) via 32f9353c03b5426304c1828fb9b0b62fe6079afa (commit) via 1830d768d69e7058ede6189b385ad5222a4d889e (commit) via f32af7496d07c74a5157c195c623f834c5ed07f4 (commit) via a81c295b3c20a333f5a058507437bbeb10b637e9 (commit) via 8c172af2249401eae0076a3dda178b18d8a73e29 (commit) via e8c36b2b4bca47b8209d1ba90369364fb6847aa9 (commit) via 0e85260d0fdf30cdb554a932cc35163a374fca99 (commit) via 5ee3c15c3b4f25215493c63e0a7748e27db83105 (commit) via 3762823255486f9ac0277f8369e50535838e5aa5 (commit) via 65a2101aff39e9db2891be233f37e5f05a795f7c (commit) via 998715f3f49f8274ae385fb102238e104246177a (commit) via 0b059cdb93b02b3dc069f2b13df4687a92e906f0 (commit) via e76bbf0e51145a734314371314687c9f50e09042 (commit) via 6bd647f4ed327d7b71deb401e216c76d5a74e1bb (commit) via 51650e94254fd737b3b83d920445753ab2665339 (commit) via 57f486bcc2341eb7ff7688cff0b373c1bac4ea39 (commit) via 0ff94e1a7ee3f1f42660db030f77bb4e1c43f438 (commit) via 81f8b03630eb8f0fb913a063160265930c486258 (commit) via 57dcd19bb3f1ac13731279752f29c60761a35c29 (commit) via 8e31b1363b0bc58af9ac938d2a5dcedba8aa1acf (commit) via 37830f7442b0525cdc4d0a3b6deebdc9b5a2802e (commit) via 1191ddc602079ed0bf41f0d885f42de0b1de5f22 (commit) via 36838e2f730a52fa428c82fbe41591bf409b6a40 (commit) via 2b7c2ab5ce16275eece683729bbaceb3aad703f5 (commit) via 2703aa7dab2d179676443985df14541c64c0ccdf (commit) via 69c85a13c096137b0da4110a80a48e46a230cba2 (commit) via 362dfe2612ce89fbb4d5932083ffb9a9374b9160 (commit) via 38801283703ee35722b632e88b32f90107c76295 (commit) via 64e226045a01d52a9ff6601be8161b0f3224a6d7 (commit) via 36c777e8bbd61600b89253656d1c6263206310cd (commit) via 2da9e4903a38080c26db350697eec53504a5f5c6 (commit) via be3865693ae87baee1c95e3622466d2c64eb402f (commit) via 15f54ccab5c235c917b64422e186df1d3fdad0f7 (commit) via 4385b50b1f4ce29475c08999aae45bc961307118 (commit) via 64c8327190a05efa3659dcd0b352ecaeda31df26 (commit) via 1f05801d0f1f828b7a98cad6bf587d5758b5456c (commit) via 57aa5e839952122cfe725d8747d8b5fc7ba9a950 (commit) via a83eb3bf42bcbfacb7f23f1ef551af5fcdc3e387 (commit) via 44ad5c63637aa7402695ef994ec9f380f1d00aa1 (commit) via 627ec8365222b2f8e59ffba2b907bb3b74d4bfea (commit) via dd3208ad348a676fb00461f2747d2f81d142346b (commit) via 027b3ee0a56b2325e0c72c94143a498dc9680f2d (commit) via 0c89bcd89fc0aaf5440d7bface9418b32eb114e6 (commit) via 9715babfafd75aea210fce438751aae376959f5e (commit) via f8039c9d91f42916c02b4124c5d961a82698aa5d (commit) via 21e6e9bf2a2d216961e7515121bf02f965a41d32 (commit) via d8b33f3b0e7d516f2d1482edb747266b768ea7b6 (commit) via aa130e547453669e93071d3ab07170ead84de9bd (commit) via 8af92926bb3daed970ed5738db67dd805015e005 (commit) via 74b4d7beb6deb708eb745e3c61e512e8b72eb5f2 (commit) via 7a132e2703b347ba9c3384c2103f5fcfa1452151 (commit) via 34018600ee840ea3ccaefe8f649f20cbcd4fe41b (commit) via 5f7b56801bb35bdeeefa14b1041071648cb18088 (commit) via 4dfe46edbb67caff669b554665ba2b1aeb12a937 (commit) via b7cbd39d1d9250efe6ccaf4c2ce89ead2e7a6531 (commit) via 8e9dea8ca989d6cadb26f4ad8e37bdf8978e77f3 (commit) via ff15e141ef92fd1255d8508c81604a49582eb16e (commit) via 05941406daeef734e6c6adf321a9904c1a8d5b6d (commit) via 02b2dad5b08ffe9b326444869a6fc3edce0b24e0 (commit) via 1c0655a9f5b67da1cbb5785ac3f03017ceff72a4 (commit) via 72c6bbf2c313e2fc94e7fc970294ac15d494d9ea (commit) via 4677fb16d471043cc500c4e7737722387320a3c9 (commit) via 4627e7c4fb07267dd15413ce5935505380b11cf1 (commit) via f4f7bc90814c14747aba264863ccc953413f4481 (commit) via 67248edfb819aa971d515e7cf9093cbcba7e704b (commit) via bceac4b40146b0087e8d518d181b4ce541f4f87e (commit) via 6d329131afb4fa1db43094f670dddbc2d4203da4 (commit) via 946408e0de1db9436ff46ccd9f985be28d3964c2 (commit) via cbef79b87356a7833ff340cd878355a76a5e7ccf (commit) via cc7c5961a0ce6d8cc2a449c009a715546639ad1a (commit) via d9c7fda5c9bd2505974bda8c79310d658f167ee2 (commit) via ea9257db45231d8fef6a64b7e7086f63b996af2a (commit) via 4d41dd140fdf890f0ef851066a4afb54018c32c7 (commit) via 8be68aacff211604f373930b1ef97d28e15370e3 (commit) via ccea73e631d8a7cac0280f9ccecc8c12cf77858f (commit) via 93ca57a555c9cf31475e0ba0834265e055c2d59d (commit) via 74aba61978699a5cd4f5bd92859e86c16d4b5d39 (commit) via 0e2ec276466621d761574b9e21750f52eb0ba317 (commit) via d0c615ae437a75f4f80925ccc67cfa3665d4ddf1 (commit) via 668db3a0e280cbe17a560462b4affd4bd1aa5aca (commit) via 30884ae47e244ec4fb8866cce86561b247ec78dc (commit) via 71f5766d5777fec453a3555a96f5a2df668854bd (commit) via 1566ceae3545775c8ed5641953fb2c098054228b (commit) via d0a09d49cc0527e8496c2d37952c4aa0f4921122 (commit) via 94338d46dd30f47880f8d66f85986a2e4431cbca (commit) via 2835c431dfe485a4341b84d62317ab2951df1743 (commit) via 363219e60a1db57d06ece703299c449bed37a6ec (commit) via 7b49921468d4c953b2eb2acbf777216fbd6e9c68 (commit) via a331b59f5f8b64c9b99f7551cbdbaecfcf24ad41 (commit) via e5ba9c401af5a7d0ae33e58a7f803dd2da3f117d (commit) via 0ec962243383d5d4f5bc7832d25432fd4abf51bf (commit) via 9f3314085aefb9c3ba71a01c316e0dc6b5412808 (commit) via b1369f9458b8dc023ef084f6d9dc5da37a3fdbd1 (commit) via 8acbef68aeb18ef2c29270198cb54131ecff3349 (commit) via 08c06aea147efe28d56baaf308b03d8463c9600e (commit) via 0e79b256555a01dd7c536e2211dfd98c91e0a2fd (commit) via 28e3ed2c37f5c2cd70b80e784bc44e4802ddff02 (commit) via 994d7a2ca6fdbb139d63411bbf22c6ac0a6e3cb7 (commit) via 6019873b666c6f99c943aa889866b91479d90122 (commit) via fc6e4321433cb5c532b522d7360b2e1ea30e4e69 (commit) via 5e6c1eaef868c61991a4c21628d77654482a1d04 (commit) via 4bdbb9954c18d46385bba5c63cafb9d5da293b22 (commit) via 5097d024ebed8448c1fbe06be6192a0215f23417 (commit) via e34c70cfb247fa4d9f9ace51bf2b7089d87d23f0 (commit) via 7708e979d989bb8d727884f54558d98c1c03744e (commit) via fc0e80a0d1dd2c44702b6c9f4049954a80267ab9 (commit) via 7dee3aaf5d6ddcb870701995c48f9ae3d4f72fe3 (commit) via 944a52e6643e9d5f74ad9ab9bf7a6634cb4ed987 (commit) via 04b9353d88904bdca59942c1a98437a8b6606170 (commit) via a8326ba4b5382334a9b2b060b75cacc33a89c0a1 (commit) via aa616b3707f88b39eb6717436e7a2fdcae3e769f (commit) via 3b7635ba7a876da30d8f633d1a585fb094e4d001 (commit) via cd2b73415076488f47821b705ff6e4cfc16eb3be (commit) via f4d0e3e4025048dcd1871708226b825927d47e01 (commit) via 64183e7d34b4256a43e5409de2c4870d632a195a (commit) via 0bcf9a8f9867fb607bec384c4fc1f6c7c8363bfe (commit) via 57112572799dabb1130bae719c11ef1c20b969a3 (commit) via 2f4bca95f75f1a2ba10f9ce0a2f3cda4bbe580a4 (commit) via b5f9f06cb0a86568b4da49e6f41d1e3bb7b4337a (commit) via 7a7342320008d77fe25a101c1dde73bee1f7b891 (commit) via 6955a0ed4f62f23d7c2f9c927c7daacd8ddcc420 (commit) via 04250b32032bca77a2c49ad5f10ab21a8460cef7 (commit) via d1640bd896e150f5898a4039255a407f6f3cc066 (commit) via 05c5724bcf9df2421e382d7c890475150a5957b7 (commit) via eccdfa564fb26fea6ad51d08e529db3796d91d54 (commit) via 0b6161c8e44f5c31680b41fb87e34eeb81ad039d (commit) via d3659ef996d1ddcd6fe24ba278fa7687ab890ac4 (commit) via 021dbcd26e681e9768045e892fe7fb14fa56427f (commit) via 7944ea511d7218e3d72d57a97bb01d778ab002bb (commit) via e716a010e8eb62b8430b28b661f958ad935e25ca (commit) via e7f51edfcb904a27ae107e31fb7690f31bc4962c (commit) via 214835339c7b7485c25d84d85ded10a5d8f68c28 (commit) via be58dae67492743164a098b01e835fa4cd4b5695 (commit) via 6513b485c93d052003b69911805261a2be92e818 (commit) via 28d304e8fe55eb400142ae35ee96bde88212f89f (commit) via 844141dbd88e05d1d0f7b980eca66be63299db27 (commit) via 5c9df8e27d75b262b21071a554f44488eae540af (commit) via 5e9bfed4cef2179da644822e26728d1faaf744fc (commit) via fdbdb388e20443a52686f745687bff701fa1cf6b (commit) via 521d3f6ac3b25799d80658e7dbd0bb7930b4180a (commit) from afabcfffa5ccb480e7d785c5f7e270c9779b8949 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 6f967a68d5a6c0fda3e0d4092dde54eb6ffd4c32 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Aug 23 17:20:03 2022 -0500 Make pthread.h a default include and remove config.h from being included in rig.h https://github.com/Hamlib/Hamlib/milestone/14 diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 2717adcb..a491ebfb 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -37,10 +37,7 @@ #include <string.h> #include <inttypes.h> #include <time.h> -#include <hamlib/config.h> -#ifdef HAVE_PTHREAD #include <pthread.h> -#endif /* Rig list is in a separate file so as not to mess up w/ this one */ #include <hamlib/riglist.h> @@ -2571,9 +2568,7 @@ struct rig_state { void *async_data_handler_priv_data; volatile int poll_routine_thread_run; void *poll_routine_priv_data; -#ifdef HAVE_PTHREAD pthread_mutex_t mutex_set_transaction; -#endif hamlib_port_t rigport; /*!< Rig port (internal use). */ hamlib_port_t pttport; /*!< PTT port (internal use). */ hamlib_port_t dcdport; /*!< DCD port (internal use). */ diff --git a/security/security.c b/security/security.c index cc661eee..bc45f322 100644 --- a/security/security.c +++ b/security/security.c @@ -27,6 +27,7 @@ #include "AESStringCrypt.h" #include "password.h" #include "../src/misc.h" +#include "hamlib/config.h" #if defined(_WIN32) // gmtime_r can be defined by mingw diff --git a/src/misc.h b/src/misc.h index 063385e8..b85f969b 100644 --- a/src/misc.h +++ b/src/misc.h @@ -23,6 +23,7 @@ #define _MISC_H 1 #include <hamlib/rig.h> +#include <hamlib/config.h> /* commit efd166fb50f0bea3887c4d40b3ed951312fb113c Merge: ef06b358 2c501366 Author: Michael Black <mdb...@ya...> Date: Tue Aug 23 12:11:51 2022 -0500 Merge pull request #1106 from mikaelnousiainen/fix-yaesu-power-off-handling Fix handling of EPOWER error code and reduce unnecessary commands in Yaesu newcat backend commit 2c5013662dfe3158b2c3806e59be2c62fb277915 Author: Mikael Nousiainen <mik...@ik...> Date: Tue Aug 23 00:14:12 2022 +0300 Fix warning message for allowed commands when rig is powered off diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index caeb5956..d6ee9489 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -1745,9 +1745,8 @@ readline_repeat: && cmd_entry->cmd != 0xf0 // chk_vfo && cmd_entry->cmd != 0x87) // set_powerstat { - //rig_debug(RIG_DEBUG_WARN, "%s: %s - only \\set_powerstat can be run \n", __func__, rigerror(-RIG_EPOWER)); rig_debug(RIG_DEBUG_WARN, - "%s: only \\set_powerstat can be run when rig powered off\n", __func__); + "%s: command %s not allowed when rig is powered off\n", __func__, cmd_entry->name); retcode = -RIG_EPOWER; } else commit dc02c566f5f5c9f257de99d1724d786ee8b47bc0 Author: Mikael Nousiainen <mik...@ik...> Date: Tue Aug 23 00:10:25 2022 +0300 Fix handling of the new EPOWER error code: do not re-open rig and fix/extend allowed commands when rig is powered off. Fix Yaesu newcat backend to not try to call rig ID command during command validation. diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 505bc94f..2717adcb 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -176,7 +176,8 @@ enum rig_errcode_e { */ #define RIG_IS_SOFT_ERRCODE(errcode) (errcode == RIG_EINVAL || errcode == RIG_ENIMPL || errcode == RIG_ERJCTED \ || errcode == RIG_ETRUNC || errcode == RIG_ENAVAIL || errcode == RIG_ENTARGET \ - || errcode == RIG_EVFO || errcode == RIG_EDOM || errcode == RIG_ESECURITY) + || errcode == RIG_EVFO || errcode == RIG_EDOM || errcode == RIG_EDEPRECATED \ + || errcode == RIG_ESECURITY || errcode == RIG_EPOWER) /** * \brief Token in the netrigctl protocol for returning error code diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 23e246e1..f9265f0b 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -481,6 +481,26 @@ int newcat_init(RIG *rig) priv->current_mem = NC_MEM_CHANNEL_NONE; priv->fast_set_commands = FALSE; + /* + * Determine the type of rig from the model number. Note it is + * possible for several model variants to exist; i.e., all the + * FT-9000 variants. + */ + + is_ft450 = newcat_is_rig(rig, RIG_MODEL_FT450); + is_ft891 = newcat_is_rig(rig, RIG_MODEL_FT891); + is_ft950 = newcat_is_rig(rig, RIG_MODEL_FT950); + is_ft991 = newcat_is_rig(rig, RIG_MODEL_FT991); + is_ft2000 = newcat_is_rig(rig, RIG_MODEL_FT2000); + is_ftdx9000 = newcat_is_rig(rig, RIG_MODEL_FT9000); + is_ftdx5000 = newcat_is_rig(rig, RIG_MODEL_FTDX5000); + is_ftdx1200 = newcat_is_rig(rig, RIG_MODEL_FTDX1200); + is_ftdx3000 = newcat_is_rig(rig, RIG_MODEL_FTDX3000); + is_ftdx3000dm = FALSE; // Detected dynamically + is_ftdx101d = newcat_is_rig(rig, RIG_MODEL_FTDX101D); + is_ftdx101mp = newcat_is_rig(rig, RIG_MODEL_FTDX101MP); + is_ftdx10 = newcat_is_rig(rig, RIG_MODEL_FTDX10); + RETURNFUNC(RIG_OK); } @@ -7327,26 +7347,6 @@ ncboolean newcat_valid_command(RIG *rig, char const *const command) RETURNFUNC2(FALSE); } - /* - * Determine the type of rig from the model number. Note it is - * possible for several model variants to exist; i.e., all the - * FT-9000 variants. - */ - - is_ft450 = newcat_is_rig(rig, RIG_MODEL_FT450); - is_ft891 = newcat_is_rig(rig, RIG_MODEL_FT891); - is_ft950 = newcat_is_rig(rig, RIG_MODEL_FT950); - is_ft991 = newcat_is_rig(rig, RIG_MODEL_FT991); - is_ft2000 = newcat_is_rig(rig, RIG_MODEL_FT2000); - is_ftdx9000 = newcat_is_rig(rig, RIG_MODEL_FT9000); - is_ftdx5000 = newcat_is_rig(rig, RIG_MODEL_FTDX5000); - is_ftdx1200 = newcat_is_rig(rig, RIG_MODEL_FTDX1200); - is_ftdx3000 = newcat_is_rig(rig, RIG_MODEL_FTDX3000); - is_ftdx3000dm = newcat_get_rigid(rig) == 462; - is_ftdx101d = newcat_is_rig(rig, RIG_MODEL_FTDX101D); - is_ftdx101mp = newcat_is_rig(rig, RIG_MODEL_FTDX101MP); - is_ftdx10 = newcat_is_rig(rig, RIG_MODEL_FTDX10); - if (!is_ft450 && !is_ft950 && !is_ft891 && !is_ft991 && !is_ft2000 && !is_ftdx5000 && !is_ftdx9000 && !is_ftdx1200 && !is_ftdx3000 && !is_ftdx101d && !is_ftdx101mp && !is_ftdx10) @@ -10082,6 +10082,8 @@ int newcat_get_rigid(RIG *rig) { s += 2; /* ID0310, jump past ID */ priv->rig_id = atoi(s); + + is_ftdx3000dm = priv->rig_id == NC_RIGID_FTDX3000DM; } rig_debug(RIG_DEBUG_TRACE, "rig_id = %d, idstr = %s\n", priv->rig_id, diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 57cce91b..caeb5956 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -1737,10 +1737,11 @@ readline_repeat: if (retcode == RIG_OK) { rig_powerstat = stat; } } - // only command allows when powered off is 0x87=set_powerstat - if (retcode == RIG_OK && (rig_powerstat == RIG_POWER_OFF - || rig_powerstat == RIG_POWER_STANDBY) - && cmd_entry->cmd != 0x01 // dump_caps + // Allow only certain commands when the rig is powered off + if (retcode == RIG_OK && (rig_powerstat == RIG_POWER_OFF || rig_powerstat == RIG_POWER_STANDBY) + && cmd_entry->cmd != '1' // dump_caps + && cmd_entry->cmd != '3' // dump_conf + && cmd_entry->cmd != 0x8f // dump_state && cmd_entry->cmd != 0xf0 // chk_vfo && cmd_entry->cmd != 0x87) // set_powerstat { commit ef06b358d7f1fc477608f3dc2cd167f45592a71d Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Aug 22 15:55:35 2022 -0500 Add verification of EX commands in newcat.c diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 23e246e1..7335794c 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -607,9 +607,8 @@ int newcat_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, rigerror(err)); } - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX033;"); - newcat_get_cmd(rig); } + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) { int err; @@ -621,8 +620,6 @@ int newcat_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, rigerror(err)); } - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX039;"); - newcat_get_cmd(rig); } RETURNFUNC(RIG_OK); @@ -2578,7 +2575,9 @@ int newcat_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) // we assume split is always on VFO_B //if (*tx_vfo == RIG_VFO_B || *tx_vfo == RIG_VFO_SUB) - rig_debug(RIG_DEBUG_TRACE, "%s: tx_vfo=%s, curr_vfo=%s\n", __func__, rig_strvfo(*tx_vfo), rig_strvfo(rig->state.current_vfo)); + rig_debug(RIG_DEBUG_TRACE, "%s: tx_vfo=%s, curr_vfo=%s\n", __func__, + rig_strvfo(*tx_vfo), rig_strvfo(rig->state.current_vfo)); + if (*tx_vfo != rig->state.current_vfo) { *split = RIG_SPLIT_ON; @@ -7531,8 +7530,9 @@ int newcat_set_tx_vfo(RIG *rig, vfo_t tx_vfo) { HAMLIB_TRACE; p1 = p1 + 2; /* use non-Toggle commands */ + // If VFOB is active then we change VFOB with FT3 instead of VFOA - if (rig->state.current_vfo == RIG_VFO_B) p1++; + if (rig->state.current_vfo == RIG_VFO_B) { p1++; } } if (is_ftdx101d || is_ftdx101mp) @@ -10465,7 +10465,8 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, "FA;"); - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 || priv->rig_id == NC_RIGID_FTDX3000DM) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 + || priv->rig_id == NC_RIGID_FTDX3000DM) { strcpy(valcmd, ""); } @@ -10474,7 +10475,8 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, "FB;"); - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 || priv->rig_id == NC_RIGID_FTDX3000DM) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 + || priv->rig_id == NC_RIGID_FTDX3000DM) { strcpy(valcmd, ""); } @@ -10545,6 +10547,17 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, "FA;"); // nothing to validate } + else if (strncmp(priv->cmd_str, "EX", 2) == 0) + { + char *p = strchr(priv->cmd_str, ';'); + + if (p) + { + strcpy(valcmd, priv->cmd_str); // we query the same number + *p = '\0'; + *(p - 1) = ';'; + } + } else { rig_debug(RIG_DEBUG_TRACE, "%s: %s not implemented\n", __func__, priv->cmd_str); diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 08dd7573..f9dda6c4 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220821" +#define NEWCAT_VER "20220822" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit 2275bf51f85fba88d405e4e206cbc941692106f4 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 12:20:01 2022 -0500 When Yaeus rigs are split and tx is on VFOA then turning split off will remain on VFOB tx/rx https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index bcdc4b72..23e246e1 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -7531,6 +7531,8 @@ int newcat_set_tx_vfo(RIG *rig, vfo_t tx_vfo) { HAMLIB_TRACE; p1 = p1 + 2; /* use non-Toggle commands */ + // If VFOB is active then we change VFOB with FT3 instead of VFOA + if (rig->state.current_vfo == RIG_VFO_B) p1++; } if (is_ftdx101d || is_ftdx101mp) commit 95126fd350169c778c7f53b1233a78835874aec4 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 12:00:38 2022 -0500 Add EX echo as separte get_cmd call for CAT TOT TIMEOUT Could do this for other EX commands too https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index fc5f76f9..bcdc4b72 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -607,6 +607,8 @@ int newcat_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, rigerror(err)); } + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX033;"); + newcat_get_cmd(rig); } if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) { @@ -619,6 +621,8 @@ int newcat_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, rigerror(err)); } + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX039;"); + newcat_get_cmd(rig); } RETURNFUNC(RIG_OK); commit f8f0678988c36abf2e042f97fc4166d6c91cb59b Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 11:57:53 2022 -0500 Take out EX echo request -- can't do that as EX command does not expect response https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index c8d0aaf5..fc5f76f9 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -600,7 +600,7 @@ int newcat_open(RIG *rig) { int err; // set the CAT TIME OUT TIMER to 100ms - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0331;EX033;"); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0331;"); if (RIG_OK != (err = newcat_set_cmd(rig))) { @@ -612,7 +612,7 @@ int newcat_open(RIG *rig) { int err; // set the CAT TIME OUT TIMER to 100ms - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0391;EX039;"); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0391;"); if (RIG_OK != (err = newcat_set_cmd(rig))) { commit 4664620b92b0f5167db1043fa98f727b396bcb04 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 11:51:34 2022 -0500 Add FTDX300DM to same exceptions as FTDX3000 https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 497b2667..c8d0aaf5 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -590,7 +590,7 @@ int newcat_open(RIG *rig) #endif - if (priv->rig_id == NC_RIGID_FTDX3000) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) { rig->state.disable_yaesu_bandselect = 1; rig_debug(RIG_DEBUG_VERBOSE, "%s: disabling FTDX3000 band select\n", __func__); @@ -608,7 +608,7 @@ int newcat_open(RIG *rig) rigerror(err)); } } - if (priv->rig_id == NC_RIGID_FTDX3000) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX3000DM) { int err; // set the CAT TIME OUT TIMER to 100ms @@ -10459,7 +10459,7 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, "FA;"); - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 || priv->rig_id == NC_RIGID_FTDX3000DM) { strcpy(valcmd, ""); } @@ -10468,7 +10468,7 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, "FB;"); - if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000) + if (priv->rig_id == NC_RIGID_FTDX3000 || priv->rig_id == NC_RIGID_FTDX5000 || priv->rig_id == NC_RIGID_FTDX3000DM) { strcpy(valcmd, ""); } commit 3f99ec47db8a0aefdf50410dfcdcc62a942e9f21 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 11:47:13 2022 -0500 Have FTDX5000 and DX3000 echo CAT TOT TIMEOUT when set https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index c794d01c..497b2667 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -600,7 +600,7 @@ int newcat_open(RIG *rig) { int err; // set the CAT TIME OUT TIMER to 100ms - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0331;"); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0331;EX033;"); if (RIG_OK != (err = newcat_set_cmd(rig))) { @@ -612,7 +612,7 @@ int newcat_open(RIG *rig) { int err; // set the CAT TIME OUT TIMER to 100ms - SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0391;"); + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0391;EX039;"); if (RIG_OK != (err = newcat_set_cmd(rig))) { commit e86e05bce33df755f5a650fde3c5bbf79433d79e Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 11:40:52 2022 -0500 Change FTDX3000 CAT TOT TIMEOUT to 100ms Change Yaesu split detection to detect reverse split https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 80c8163f..c794d01c 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -608,6 +608,18 @@ int newcat_open(RIG *rig) rigerror(err)); } } + if (priv->rig_id == NC_RIGID_FTDX3000) + { + int err; + // set the CAT TIME OUT TIMER to 100ms + SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "EX0391;"); + + if (RIG_OK != (err = newcat_set_cmd(rig))) + { + rig_debug(RIG_DEBUG_ERR, "%s: FTDX5000 CAT RATE error: %s\n", __func__, + rigerror(err)); + } + } RETURNFUNC(RIG_OK); } @@ -2561,7 +2573,9 @@ int newcat_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) } // we assume split is always on VFO_B - if (*tx_vfo == RIG_VFO_B || *tx_vfo == RIG_VFO_SUB) + //if (*tx_vfo == RIG_VFO_B || *tx_vfo == RIG_VFO_SUB) + rig_debug(RIG_DEBUG_TRACE, "%s: tx_vfo=%s, curr_vfo=%s\n", __func__, rig_strvfo(*tx_vfo), rig_strvfo(rig->state.current_vfo)); + if (*tx_vfo != rig->state.current_vfo) { *split = RIG_SPLIT_ON; } diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 393b9f78..08dd7573 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220819" +#define NEWCAT_VER "20220821" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit e8fa723bc88d8ba4934895afa85196a217c8b749 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Aug 21 10:29:22 2022 -0500 Change FTDX3000 write_delay back to zero -- at value of 1 rigctl was showing all ? responses from rig at 38400 baud https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/ft3000.c b/rigs/yaesu/ft3000.c index 7aebdd7d..88700167 100644 --- a/rigs/yaesu/ft3000.c +++ b/rigs/yaesu/ft3000.c @@ -244,7 +244,7 @@ const struct rig_caps ftdx3000_caps = RIG_MODEL(RIG_MODEL_FTDX3000), .model_name = "FTDX-3000", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".7", + .version = NEWCAT_VER ".8", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -259,7 +259,7 @@ const struct rig_caps ftdx3000_caps = .serial_handshake = RIG_HANDSHAKE_HARDWARE, // write_delay 5ms or less was causing VS1;VS; to answer with VS0 instead of VS1 even though change did occur // see https://github.com/Hamlib/Hamlib/issues/906 - .write_delay = 1, + .write_delay = 0, // delay of 1 broke rigctl -- all ? responses .post_write_delay = FTDX5000_POST_WRITE_DELAY, .timeout = 2000, .retry = 3, commit 2fdf608793074ce36d5e9ed7f86ef52ca6ab974b Merge: c34f7193 2f08201f Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Aug 20 22:56:16 2022 -0500 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit c34f71933780245fb48a9d448b43c07fcc9b3226 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Aug 20 22:56:04 2022 -0500 Astyle files diff --git a/rigs/dummy/netrigctl.c b/rigs/dummy/netrigctl.c index 5b32afdb..5cb0c3ad 100644 --- a/rigs/dummy/netrigctl.c +++ b/rigs/dummy/netrigctl.c @@ -1071,9 +1071,11 @@ static int netrigctl_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) char buf[BUF_MAX]; char vfostr[16] = ""; - rig_debug(RIG_DEBUG_VERBOSE, "%s called vfo=%s, ptt=%d, ptt_type=%d\n", __func__, + rig_debug(RIG_DEBUG_VERBOSE, "%s called vfo=%s, ptt=%d, ptt_type=%d\n", + __func__, rig_strvfo(vfo), ptt, rig->state.pttport.type.ptt); - if(rig->state.pttport.type.ptt == RIG_PTT_NONE) return RIG_OK; + + if (rig->state.pttport.type.ptt == RIG_PTT_NONE) { return RIG_OK; } ret = netrigctl_vfostr(rig, vfostr, sizeof(vfostr), RIG_VFO_A); diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 6dbc0cf9..11ba6d25 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -682,28 +682,28 @@ int icom_init(RIG *rig) // we can add rigs here that will never use the 0x25 cmd // some like the 751 don't even reject the command and have to time out if ( - rig->caps->rig_model == RIG_MODEL_IC275 - || rig->caps->rig_model == RIG_MODEL_IC375 - || rig->caps->rig_model == RIG_MODEL_IC706 - || rig->caps->rig_model == RIG_MODEL_IC706MKII - || rig->caps->rig_model == RIG_MODEL_IC706MKIIG - || rig->caps->rig_model == RIG_MODEL_IC751 - || rig->caps->rig_model == RIG_MODEL_X5105 - || rig->caps->rig_model == RIG_MODEL_IC1275 - || rig->caps->rig_model == RIG_MODEL_IC746 - || rig->caps->rig_model == RIG_MODEL_IC756 - || rig->caps->rig_model == RIG_MODEL_IC756PRO - || rig->caps->rig_model == RIG_MODEL_IC756PROII - || rig->caps->rig_model == RIG_MODEL_IC756PROIII - || rig->caps->rig_model == RIG_MODEL_IC746PRO - || rig->caps->rig_model == RIG_MODEL_IC756 - || rig->caps->rig_model == RIG_MODEL_IC7000 - || rig->caps->rig_model == RIG_MODEL_IC7100 - || rig->caps->rig_model == RIG_MODEL_IC7200 - || rig->caps->rig_model == RIG_MODEL_IC821H - || rig->caps->rig_model == RIG_MODEL_IC910 - || rig->caps->rig_model == RIG_MODEL_IC2730 - ) + rig->caps->rig_model == RIG_MODEL_IC275 + || rig->caps->rig_model == RIG_MODEL_IC375 + || rig->caps->rig_model == RIG_MODEL_IC706 + || rig->caps->rig_model == RIG_MODEL_IC706MKII + || rig->caps->rig_model == RIG_MODEL_IC706MKIIG + || rig->caps->rig_model == RIG_MODEL_IC751 + || rig->caps->rig_model == RIG_MODEL_X5105 + || rig->caps->rig_model == RIG_MODEL_IC1275 + || rig->caps->rig_model == RIG_MODEL_IC746 + || rig->caps->rig_model == RIG_MODEL_IC756 + || rig->caps->rig_model == RIG_MODEL_IC756PRO + || rig->caps->rig_model == RIG_MODEL_IC756PROII + || rig->caps->rig_model == RIG_MODEL_IC756PROIII + || rig->caps->rig_model == RIG_MODEL_IC746PRO + || rig->caps->rig_model == RIG_MODEL_IC756 + || rig->caps->rig_model == RIG_MODEL_IC7000 + || rig->caps->rig_model == RIG_MODEL_IC7100 + || rig->caps->rig_model == RIG_MODEL_IC7200 + || rig->caps->rig_model == RIG_MODEL_IC821H + || rig->caps->rig_model == RIG_MODEL_IC910 + || rig->caps->rig_model == RIG_MODEL_IC2730 + ) { priv->x25cmdfails = 1; } @@ -814,7 +814,8 @@ static vfo_t icom_current_vfo_x25(RIG *rig) { // we can't change freqs unless rig is idle and we don't know that // so we only check vfo once when freqs are equal - rig_debug(RIG_DEBUG_TRACE, "%s: vfo already determined...returning current_vfo\n", + rig_debug(RIG_DEBUG_TRACE, + "%s: vfo already determined...returning current_vfo\n", __func__); return rig->state.current_vfo; } @@ -1882,7 +1883,8 @@ pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) } } - if (RIG_MODEL_X108G == rig->caps->rig_model || RIG_MODEL_X5105 == rig->caps->rig_model) + if (RIG_MODEL_X108G == rig->caps->rig_model + || RIG_MODEL_X5105 == rig->caps->rig_model) { priv->no_1a_03_cmd = ENUM_1A_03_NO; } @@ -3455,7 +3457,8 @@ int icom_set_level(RIG *rig, vfo_t vfo, setting_t level, value_t val) int found = 0; for (i = 0; - i <= RIG_AGC_LAST && priv_caps->agc_levels[i].level != RIG_AGC_LAST && priv_caps->agc_levels[i].icom_level >= 0; i++) + i <= RIG_AGC_LAST && priv_caps->agc_levels[i].level != RIG_AGC_LAST + && priv_caps->agc_levels[i].icom_level >= 0; i++) { if (priv_caps->agc_levels[i].level == val.i) { diff --git a/rigs/kenwood/kenwood.c b/rigs/kenwood/kenwood.c index c773a799..75306e82 100644 --- a/rigs/kenwood/kenwood.c +++ b/rigs/kenwood/kenwood.c @@ -4941,6 +4941,7 @@ int kenwood_send_morse(RIG *rig, vfo_t vfo, const char *msg) * If answer is something else, return with error to prevent infinite loops */ if (!strncmp(m2, "KY0", 3)) { break; } + if (!strncmp(m2, "KY2", 3)) { break; } if (!strncmp(m2, "KY1", 3)) { hl_usleep(500000); } diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index dbf27165..1679b035 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -547,7 +547,8 @@ int ft747_set_freq(RIG *rig, vfo_t vfo, freq_t freq) p = (struct ft747_priv_data *)rig->state.priv; - rig_debug(RIG_DEBUG_VERBOSE, "ft747: requested freq = %"PRIfreq" Hz vfo = %s \n", freq, rig_strvfo(vfo)); + rig_debug(RIG_DEBUG_VERBOSE, + "ft747: requested freq = %"PRIfreq" Hz vfo = %s \n", freq, rig_strvfo(vfo)); /* * Copy native cmd freq_set to private cmd storage area @@ -579,12 +580,15 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) freq_t f; int ret; - rig_debug(RIG_DEBUG_VERBOSE, "%s: called vfo=%s, freqMainA=%.0f, freqMainB=%.0f\n", __func__, rig_strvfo(vfo), rig->state.cache.freqMainA, rig->state.cache.freqMainB); + rig_debug(RIG_DEBUG_VERBOSE, + "%s: called vfo=%s, freqMainA=%.0f, freqMainB=%.0f\n", __func__, + rig_strvfo(vfo), rig->state.cache.freqMainA, rig->state.cache.freqMainB); - if (vfo == RIG_VFO_CURR) vfo = rig->state.cache.vfo; - if (rig->state.cache.ptt == RIG_PTT_ON) + if (vfo == RIG_VFO_CURR) { vfo = rig->state.cache.vfo; } + + if (rig->state.cache.ptt == RIG_PTT_ON) { - *freq = RIG_VFO_B? rig->state.cache.freqMainB : rig->state.cache.freqMainA; + *freq = RIG_VFO_B ? rig->state.cache.freqMainB : rig->state.cache.freqMainA; return RIG_OK; } @@ -999,7 +1003,8 @@ static int ft747_get_update_data(RIG *rig) p = (struct ft747_priv_data *)rig->state.priv; rigport = &rig->state.rigport; - if (rig->state.cache.ptt == RIG_PTT_ON || !rig_check_cache_timeout(&p->status_tv, FT747_CACHE_TIMEOUT)) + if (rig->state.cache.ptt == RIG_PTT_ON + || !rig_check_cache_timeout(&p->status_tv, FT747_CACHE_TIMEOUT)) { return RIG_OK; } diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index b4e161c7..80c8163f 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -771,14 +771,15 @@ int newcat_set_freq(RIG *rig, vfo_t vfo, freq_t freq) ENTERFUNC; - if (newcat_60m_exception(rig, freq)) - { + if (newcat_60m_exception(rig, freq)) + { // we don't try to set freq on 60m for some rigs since we must be in memory mode // and we can't run split mode on 60M memory mode either if (rig->state.cache.split == RIG_SPLIT_ON) { rig_set_split_vfo(rig, RIG_VFO_A, RIG_VFO_A, RIG_SPLIT_OFF); } + RETURNFUNC(RIG_OK); } // we don't set freq in this case @@ -10382,7 +10383,7 @@ int newcat_get_cmd(RIG *rig) rig_debug(RIG_DEBUG_WARN, "%s: Rig busy - retrying %d of %d: '%s'\n", __func__, retry_count, state->rigport.retry, priv->cmd_str); // DX3000 was taking 1.6 seconds in certain command sequences - hl_usleep(600*1000); // 600ms wait should cover most cases hopefully + hl_usleep(600 * 1000); // 600ms wait should cover most cases hopefully rc = -RIG_ERJCTED; /* retry */ break; diff --git a/rotators/rotorez/rotorez.c b/rotators/rotorez/rotorez.c index 6d8c1b75..0ce9c068 100644 --- a/rotators/rotorez/rotorez.c +++ b/rotators/rotorez/rotorez.c @@ -312,7 +312,7 @@ const struct rot_caps yrc1_rot_caps = ROT_MODEL(ROT_MODEL_YRC1), .model_name = "DCU2/DCU3/YRC-1", .mfg_name = "Hy-Gain", - .version = "20100823.2", + .version = "20100823.2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rot_type = ROT_TYPE_OTHER, diff --git a/simulators/simft897.c b/simulators/simft897.c index f889bc68..6367847c 100644 --- a/simulators/simft897.c +++ b/simulators/simft897.c @@ -142,13 +142,14 @@ again: case 0xF7: printf("READ TX STATUS\n"); break; - case 0x03: - printf("READ RX STATUS\n"); + case 0x03: + printf("READ RX STATUS\n"); buf[0] = buf[1] = buf[2] = buf[3] = 0; - buf[4] = 0x03; n = write(fd, buf, 5); + buf[4] = 0x03; n = write(fd, buf, 5); break; - case 0xbb: buf[0] = buf[1] = 0;printf("READ EPROM\n"); n = write(fd, buf, 2);break; + case 0xbb: buf[0] = buf[1] = 0; printf("READ EPROM\n"); n = write(fd, buf, 2); + break; default: printf("Unknown cmd=%02x\n", buf[4]); } diff --git a/simulators/simkenwood.c b/simulators/simkenwood.c index bf70b8b1..e49bcf2e 100644 --- a/simulators/simkenwood.c +++ b/simulators/simkenwood.c @@ -296,13 +296,13 @@ int main(int argc, char *argv[]) { SNPRINTF(buf, sizeof(buf), "DA%d;", datamode); n = write(fd, buf, strlen(buf)); - printf("%s\n",buf); + printf("%s\n", buf); continue; } else if (strncmp(buf, "DA", 2) == 0) { sscanf(buf, "DA%d", &datamode); - printf("%s\n",buf); + printf("%s\n", buf); continue; } else if (strncmp(buf, "BD;", 3) == 0) diff --git a/tests/dumpcaps.c b/tests/dumpcaps.c index 7258ffaf..fb666d3b 100644 --- a/tests/dumpcaps.c +++ b/tests/dumpcaps.c @@ -296,7 +296,8 @@ int dumpcaps(RIG *rig, FILE *fout) const struct icom_priv_caps *priv_caps = (const struct icom_priv_caps *) rig->caps->priv; - if (priv_caps && RIG_BACKEND_NUM(rig->caps->rig_model) == RIG_ICOM && priv_caps->agc_levels_present) + if (priv_caps && RIG_BACKEND_NUM(rig->caps->rig_model) == RIG_ICOM + && priv_caps->agc_levels_present) { for (i = 0; i <= RIG_AGC_LAST && priv_caps->agc_levels[i].level != RIG_AGC_LAST && priv_caps->agc_levels[i].icom_level >= 0; i++) diff --git a/tests/rigctl.c b/tests/rigctl.c index 2b18f0ca..c9006468 100644 --- a/tests/rigctl.c +++ b/tests/rigctl.c @@ -736,7 +736,8 @@ void usage(void) usage_rig(stdout); printf("\nError codes and messages\n"); - for(enum rig_errcode_e e = 0; e<RIG_EEND; ++e) + + for (enum rig_errcode_e e = 0; e < RIG_EEND; ++e) { printf("-%d - %s", e, rigerror2(e)); } commit 2f08201f1295626fded6c01710fbccdce7d01e88 Merge: b4150fce ce5c90a6 Author: Michael Black <mdb...@ya...> Date: Sat Aug 20 22:35:27 2022 -0500 Merge pull request #1102 from georges/cm119b-support Add product id for CM119B chip. Used in KURI adapter designed by W7NX. commit ce5c90a6c72229e0f9fc1e1e48987c81c53d6c9e Author: Georges Auberger <381...@us...> Date: Sat Aug 20 15:26:17 2022 -1000 Add product id for CM119B chip. Used in KURI adapter designed by W7NX. diff --git a/src/cm108.c b/src/cm108.c index 71a61c68..086d3805 100644 --- a/src/cm108.c +++ b/src/cm108.c @@ -114,12 +114,13 @@ int cm108_open(hamlib_port_t *port) if (!ioctl(fd, HIDIOCGRAWINFO, &hiddevinfo) && ((hiddevinfo.vendor == 0x0d8c - // CM108/108B/109/119/119A + // CM108/108B/109/119/119A/119B && ((hiddevinfo.product >= 0x0008 && hiddevinfo.product <= 0x000f) || hiddevinfo.product == 0x0012 || hiddevinfo.product == 0x013a - || hiddevinfo.product == 0x013c)) + || hiddevinfo.product == 0x013c + || hiddevinfo.product == 0x0013)) // SSS1621/23 || (hiddevinfo.vendor == 0x0c76 && (hiddevinfo.product == 0x1605 commit b4150fce198daa77687cc868128be3e8b4b02e50 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 15:39:21 2022 -0500 FT747GX add TARGETABLE_FREQ and update rx_range_list and tx_range_list for new range_list implmentation https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 155fdf01..dbf27165 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -333,7 +333,7 @@ const struct rig_caps ft747_caps = .max_rit = Hz(0), /* 9999 */ .max_xit = Hz(0), .max_ifshift = Hz(0), - .targetable_vfo = 0, + .targetable_vfo = RIG_TARGETABLE_FREQ, .transceive = RIG_TRN_OFF, .bank_qty = 0, .chan_desc_sz = 0, @@ -343,18 +343,14 @@ const struct rig_caps ft747_caps = RIG_CHAN_END, }, - .rx_range_list1 = { RIG_FRNG_END, }, /* FIXME: enter region 1 setting */ - - .tx_range_list1 = { RIG_FRNG_END, }, - - .rx_range_list2 = { { + .rx_range_list1 = { { .startf = kHz(100), .endf = 29999900, .modes = FT747_ALL_RX_MODES, .low_power = -1, .high_power = -1, .vfo = FT747_VFOS }, RIG_FRNG_END, }, /* rx range */ - .tx_range_list2 = { {kHz(1500), 1999900, FT747_OTHER_TX_MODES, .low_power = 5000, .high_power = 100000, .vfo = FT747_VFOS}, /* 100W class */ + .tx_range_list1 = { {kHz(1500), 1999900, FT747_OTHER_TX_MODES, .low_power = 5000, .high_power = 100000, .vfo = FT747_VFOS}, /* 100W class */ {.startf = kHz(1500), .endf = 1999900, FT747_AM_TX_MODES, .low_power = 2000, .high_power = 25000, .vfo = FT747_VFOS}, /* 25W class */ commit d0dcfbff84597d4814e73256804d1fe6cf4d589f Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 11:57:08 2022 -0500 FT747GX remove debug code -- duh... diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index bbd73ed1..155fdf01 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -569,11 +569,6 @@ int ft747_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_force_cache_timeout(&p->status_tv); cmd = p->p_cmd; /* get native sequence */ - cmd[0] = 0x01; - cmd[1] = 0x02; - cmd[2] = 0x03; - cmd[3] = 0x04; - cmd[4] = 0x05; return write_block(&rig->state.rigport, cmd, YAESU_CMD_LENGTH); } commit abc2d5a84613691bbe7b2e6e5332797865295f9c Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 09:33:10 2022 -0500 FT747GX show cached freqs when get_freq is called https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 0e10b3f4..bbd73ed1 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -588,7 +588,7 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) freq_t f; int ret; - rig_debug(RIG_DEBUG_VERBOSE, "%s: called vfo=%s\n", __func__, rig_strvfo(vfo)); + rig_debug(RIG_DEBUG_VERBOSE, "%s: called vfo=%s, freqMainA=%.0f, freqMainB=%.0f\n", __func__, rig_strvfo(vfo), rig->state.cache.freqMainA, rig->state.cache.freqMainB); if (vfo == RIG_VFO_CURR) vfo = rig->state.cache.vfo; if (rig->state.cache.ptt == RIG_PTT_ON) commit b97b8b0fe7c0b76f3e4715416c1da39d800c5e5e Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 09:30:59 2022 -0500 For FT747GX do not get info when PTT is on -- use cached info diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index f77a8fd8..0e10b3f4 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -1008,7 +1008,7 @@ static int ft747_get_update_data(RIG *rig) p = (struct ft747_priv_data *)rig->state.priv; rigport = &rig->state.rigport; - if (!rig_check_cache_timeout(&p->status_tv, FT747_CACHE_TIMEOUT)) + if (rig->state.cache.ptt == RIG_PTT_ON || !rig_check_cache_timeout(&p->status_tv, FT747_CACHE_TIMEOUT)) { return RIG_OK; } commit 28b1a9bb9525be07f7d80212e17b4d744a0dc9f5 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 08:33:31 2022 -0500 Increase FT747GX cache timeout to 1500ms as get_freq is taking over 1000ms diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 081a795c..f77a8fd8 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -303,7 +303,7 @@ const struct rig_caps ft747_caps = RIG_MODEL(RIG_MODEL_FT747), .model_name = "FT-747GX", .mfg_name = "Yaesu", - .version = "20220819.0", + .version = "20220819.1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, diff --git a/rigs/yaesu/ft747.h b/rigs/yaesu/ft747.h index 10463c53..2df6513a 100644 --- a/rigs/yaesu/ft747.h +++ b/rigs/yaesu/ft747.h @@ -67,10 +67,9 @@ * rig_get_mode() in a row. * * The timeout is set to at least the time to transfer the block (790ms) - * plus post write delay, plus some margin, but less than 1 second, - * which may be typical polling period. + * plus post write delay, plus some margin as get_freq was taking > 1000ms */ -#define FT747_CACHE_TIMEOUT 900 +#define FT747_CACHE_TIMEOUT 1500 #endif /* _FT747_H */ commit 179ee66f0d788b95d3d26363391b6e64b4cb8ab6 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 08:21:29 2022 -0500 Add 600ms wait when newcat.c see rig busy https://github.com/Hamlib/Hamlib/issues/1100 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 54b6e98c..b4e161c7 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -10381,6 +10381,8 @@ int newcat_get_cmd(RIG *rig) rig_debug(RIG_DEBUG_WARN, "%s: Rig busy - retrying %d of %d: '%s'\n", __func__, retry_count, state->rigport.retry, priv->cmd_str); + // DX3000 was taking 1.6 seconds in certain command sequences + hl_usleep(600*1000); // 600ms wait should cover most cases hopefully rc = -RIG_ERJCTED; /* retry */ break; diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 61c5cfd0..393b9f78 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220816" +#define NEWCAT_VER "20220819" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit 6965927fb4b610e36edcc43dff8769f2a9a01b15 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 07:55:20 2022 -0500 Add IC275 to icom rigs that can't do 0x25 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 7ec57b4f..6dbc0cf9 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -682,7 +682,8 @@ int icom_init(RIG *rig) // we can add rigs here that will never use the 0x25 cmd // some like the 751 don't even reject the command and have to time out if ( - rig->caps->rig_model == RIG_MODEL_IC375 + rig->caps->rig_model == RIG_MODEL_IC275 + || rig->caps->rig_model == RIG_MODEL_IC375 || rig->caps->rig_model == RIG_MODEL_IC706 || rig->caps->rig_model == RIG_MODEL_IC706MKII || rig->caps->rig_model == RIG_MODEL_IC706MKIIG diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 8238f927..c363f3b8 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20220801" +#define BACKEND_VER "20220819" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit ed5a26ac4e8670424ab7c686f5db88e362fa0595 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Aug 19 06:58:03 2022 -0500 Try to get FT747GX to return freq while transmitting https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 8a87998d..081a795c 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -303,7 +303,7 @@ const struct rig_caps ft747_caps = RIG_MODEL(RIG_MODEL_FT747), .model_name = "FT-747GX", .mfg_name = "Yaesu", - .version = "20220818.0", + .version = "20220819.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -591,7 +591,11 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) rig_debug(RIG_DEBUG_VERBOSE, "%s: called vfo=%s\n", __func__, rig_strvfo(vfo)); if (vfo == RIG_VFO_CURR) vfo = rig->state.cache.vfo; - if (rig->state.cache.ptt == RIG_PTT_ON) return vfo == RIG_VFO_B? rig->state.cache.freqMainB : rig->state.cache.freqMainA; + if (rig->state.cache.ptt == RIG_PTT_ON) + { + *freq = RIG_VFO_B? rig->state.cache.freqMainB : rig->state.cache.freqMainA; + return RIG_OK; + } p = (struct ft747_priv_data *)rig->state.priv; ret = ft747_get_update_data(rig); /* get whole shebang from rig */ commit deb5ea6d6fa0adf09eb0ec07697d80b3739191d6 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Aug 18 17:33:41 2022 -0500 For FT747GX return cached freq when in TX diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 108da31c..8a87998d 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -590,8 +590,10 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) rig_debug(RIG_DEBUG_VERBOSE, "%s: called vfo=%s\n", __func__, rig_strvfo(vfo)); - p = (struct ft747_priv_data *)rig->state.priv; + if (vfo == RIG_VFO_CURR) vfo = rig->state.cache.vfo; + if (rig->state.cache.ptt == RIG_PTT_ON) return vfo == RIG_VFO_B? rig->state.cache.freqMainB : rig->state.cache.freqMainA; + p = (struct ft747_priv_data *)rig->state.priv; ret = ft747_get_update_data(rig); /* get whole shebang from rig */ if (ret < 0) commit 4442f67e7adc40ab3a705834d602f4b0f2d6da2c Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Aug 18 17:03:17 2022 -0500 Finally got the FT747GX set_freq working correctly https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 2f626a58..108da31c 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -150,8 +150,8 @@ typedef enum ft747_native_cmd_e ft747_native_cmd_t; #define FT747_SUMO_DISPLAYED_MODE 0x18 #define FT747_SUMO_DISPLAYED_STATUS 0x00 #define FT747_SUMO_DISPLAYED_FREQ 0x01 -#define FT747_SUMO_VFO_A_FREQ 0x08 -#define FT747_SUMO_VFO_B_FREQ 0x10 +#define FT747_SUMO_VFO_A_FREQ 0x09 +#define FT747_SUMO_VFO_B_FREQ 0x11 @@ -622,7 +622,7 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) rig_debug(RIG_DEBUG_VERBOSE, "ft747: freq = %"PRIfreq" Hz for VFO = %s\n", f, rig_strvfo(vfo)); - (*freq) = f * 10; /* return displayed frequency */ + (*freq) = f; /* return displayed frequency */ return RIG_OK; } commit 88f5022079a7d5dcad2047f5d43dffee2f130de7 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Aug 18 15:59:56 2022 -0500 Still trying to fix FT747GX set_freq https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 9d896d5c..2f626a58 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -150,8 +150,8 @@ typedef enum ft747_native_cmd_e ft747_native_cmd_t; #define FT747_SUMO_DISPLAYED_MODE 0x18 #define FT747_SUMO_DISPLAYED_STATUS 0x00 #define FT747_SUMO_DISPLAYED_FREQ 0x01 -#define FT747_SUMO_VFO_A_FREQ 0x09 -#define FT747_SUMO_VFO_B_FREQ 0x11 +#define FT747_SUMO_VFO_A_FREQ 0x08 +#define FT747_SUMO_VFO_B_FREQ 0x10 @@ -604,15 +604,15 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) { case RIG_VFO_CURR: /* grab freq and convert */ - f = from_bcd_be(&(p->update_data[FT747_SUMO_DISPLAYED_FREQ]), 9); + f = from_bcd_be(&(p->update_data[FT747_SUMO_DISPLAYED_FREQ]), 8); break; case RIG_VFO_A: - f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_A_FREQ]), 9); + f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_A_FREQ]), 8); break; case RIG_VFO_B: - f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_B_FREQ]), 9); + f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_B_FREQ]), 8); break; default: commit 23fcad6d866911c346028b750beebef5fd1799c9 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Aug 18 09:21:17 2022 -0500 Hopefully fix FT747GX get_freq https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 4be2de01..9d896d5c 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -303,7 +303,7 @@ const struct rig_caps ft747_caps = RIG_MODEL(RIG_MODEL_FT747), .model_name = "FT-747GX", .mfg_name = "Yaesu", - .version = "20220817.0", + .version = "20220818.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -604,15 +604,15 @@ int ft747_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) { case RIG_VFO_CURR: /* grab freq and convert */ - f = from_bcd_be(&(p->update_data[FT747_SUMO_DISPLAYED_FREQ]), 7); + f = from_bcd_be(&(p->update_data[FT747_SUMO_DISPLAYED_FREQ]), 9); break; case RIG_VFO_A: - f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_A_FREQ]), 7); + f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_A_FREQ]), 9); break; case RIG_VFO_B: - f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_B_FREQ]), 7); + f = from_bcd_be(&(p->update_data[FT747_SUMO_VFO_B_FREQ]), 9); break; default: commit 34e651cf62ecc32649a29d1a68a07d47ff6dc686 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Aug 17 17:40:09 2022 -0500 Attempt to fix ft747gx set_freq https://github.com/Hamlib/Hamlib/issues/1101 diff --git a/rigs/yaesu/ft747.c b/rigs/yaesu/ft747.c index 8bbdd1c0..4be2de01 100644 --- a/rigs/yaesu/ft747.c +++ b/rigs/yaesu/ft747.c @@ -303,7 +303,7 @@ const struct rig_caps ft747_caps = RIG_MODEL(RIG_MODEL_FT747), .model_name = "FT-747GX", .mfg_name = "Yaesu", - .version = "20220327.0", + .version = "20220817.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -551,7 +551,7 @@ int ft747_set_freq(RIG *rig, vfo_t vfo, freq_t freq) p = (struct ft747_priv_data *)rig->state.priv; - rig_debug(RIG_DEBUG_VERBOSE, "ft747: requested freq = %"PRIfreq" Hz \n", freq); + rig_debug(RIG_DEBUG_VERBOSE, "ft747: requested freq = %"PRIfreq" Hz vfo = %s \n", freq, rig_strvfo(vfo)); /* * Copy native cmd freq_set to private cmd storage area @@ -569,6 +569,11 @@ int ft747_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_force_cache_timeout(&p->status_tv); cmd = p->p_cmd; /* get native sequence */ + cmd[0] = 0x01; + cmd[1] = 0x02;... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-06-18 12:09:34
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via afabcfffa5ccb480e7d785c5f7e270c9779b8949 (commit) via 60635c15e774c727ae7eda585d697a4623088bcc (commit) via fb875be8e0c88da80df2605df030934fcb8a6ced (commit) via 9256be1939bdd82aa9b055ae515000f89f0b4441 (commit) via c8a844daf08640040297fcc1e66b85ca67402134 (commit) via e905b905891f16b24a3002b17f85e1c02ce63874 (commit) via eee02c86f861facaa20398c9983766a30c7e8c5b (commit) via 6f35b9740385c1a048545fcb5b4ece0ad4a87572 (commit) via 1beacd56bdaa3a41212c1225a8fc48113158a43b (commit) via 4d3e8ac240ae4109cc05dbf05c1e7591634e6370 (commit) via b443a6ac3fa56c95b7935c0505c97de63c391a33 (commit) via 87be0742bf300f8853aba9f0c41c25c47340ceea (commit) via 71edbcb5cc80f96312f6742274c38a127fe55234 (commit) via 2a2a529e05e9e3f8b4ef90436838e26890b7f805 (commit) via 593a31c19582e104c6d2a1a233c77d809c7a4963 (commit) via 9ce445d4ab0526df026787b3e11b71f1e94ec54d (commit) via a89dc73376b5b614a077aa698ecbd0d7fd8e3455 (commit) via 8c1bb1d4394ba5ace1c0950c9b21d00819b5d7c0 (commit) via f3b95e744af74c8c8a09148bc55abf533f6037a6 (commit) via 459e4ce7356b154d9c44a10cd6bfa6dc0c188967 (commit) via 17aa82dc12913c7c31b8b4927de8d391aa31345f (commit) via e66cf67a969757a017002d0029b04c93df52818e (commit) via e859d6a2c9c87cc29200c7bc30646ac8892b5e72 (commit) via a9e7bd443322bb4eb6be497557b5677fcecbea45 (commit) via c964ec6bfb965f9c0dfedcc419fe30aee2fb22d3 (commit) via 82fac3e0a695fc620e8a122ebe1487cd94e4c642 (commit) via 5b5b83b3f3b2f41e09fb67937d0f9273dfc6b4b8 (commit) via 5f26083face67ef02fd4bee99742bc64827ad81c (commit) via 534299d9fbdf644d571cfe03896f30982d5a5b69 (commit) via bba6a0b88b3feb37f72c09ff71986395a5700461 (commit) via 92ba0b92ace07c48195aaf82fcefee165e77cf0a (commit) via eb453db0568ec6e780a845717121dabcc7ebed8c (commit) via 25a2a00c126066df35b08448bb9575420df94906 (commit) via f7fe9dc2390423325a9a8bbf1c76c89bd09c92fa (commit) via 2a3fb3bb081b5920d8e6dd025b1c7c3c0e4ebb22 (commit) via dc89d085d001e10117cbeddf9e6f61226466623b (commit) via 24c18938c284300ff4cab7a1b516058dffa4de36 (commit) via e0d39b3dcb96e19020d51cfa94fcb803b7d88352 (commit) via cca8d2b4eddee24a8b1ae75ef82eb173575ee9b4 (commit) via 479c43afa1f307245af451a2f85836ef1107c099 (commit) via ce99f4c75de83b0a6cac834ada2b28bd2cbc62f7 (commit) via 3b8f52d03d3320d52b10187bca9b6209ed799ade (commit) via ad2f5047e0fdfdf41c547721d5d16a318e5bbea1 (commit) via c17bcaa3439f1727796a82901c0b1ea28db39d1a (commit) via 0373846f8b2c8832863849bf4641a94a60cdad18 (commit) via fda25c3bc32d9b7491a3f0bb280dad85dec6a007 (commit) via 5d8f2e80f3ef41e50488eea6ae1fd6c227455ba1 (commit) via 43765cd1111ca3620fe0ec7c0599b059f6cbf593 (commit) via e84502b443222722b11354369d86d0c52843b0d5 (commit) via fb86c8cf558f569dc69adca9271e99d8bea6f8d8 (commit) via 0f25083d576015d587d0d51ede838f66e6523027 (commit) via 6f5040904eaf14ab328bdca4b888c91af86a8e0b (commit) via 4360188643fe2168367ebad536a81016cea126de (commit) via d12ca2291659064a06ea3522e16b18c61094fc41 (commit) via b99e8988e09baabf82cbedd3a178d2b9ecbe6b34 (commit) via 447fa2cb5c9c49740ee978819f3d3a93dc337616 (commit) via 8652741301c736c4d8d984d45656da9b83cea31f (commit) via a468f0dee8199bfaf202f8c024762ae602a04bd4 (commit) via f555eceff9dd05c5f035f6701f3526d013cb84e9 (commit) via 739f6990679c62b1a74fd7ed52455b40ed8ffd61 (commit) via ce1d863a699debc45cd14227fed839f70d0ac74c (commit) via 860e280f85d1d7d92a4e11c1c19316f138964bfb (commit) via 763836881f1a523f44d8f3706a6da9489a3a8349 (commit) via 0acb549153509c930ff76c844e4adb16411ef249 (commit) via d40d55f50c944fcd958cf60f0dd6fda081637252 (commit) via 66b69f60a9ca2181e849df6a026b85afaed8bdd0 (commit) via 1c1d3394eb5cdf0fb1b1b0df5be99874be9e5ed0 (commit) via 644a72a40d8d29bf5c4d00a60a255ef01fe9a912 (commit) via 19c0193859cfe9f5ac27941ee26d859536a1b2b9 (commit) from 76405a1a9ae41c33db847bdf270876cad8680843 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit afabcfffa5ccb480e7d785c5f7e270c9779b8949 Merge: fb875be8 60635c15 Author: Michael Black <mdb...@ya...> Date: Fri Jun 17 17:32:40 2022 -0500 Merge pull request #1069 from cjtheham/master Fix windows makefile commit 60635c15e774c727ae7eda585d697a4623088bcc Author: CJ <cjt...@pr...> Date: Fri Jun 17 17:26:45 2022 -0500 fix windows makefile diff --git a/Makefile.Windows b/Makefile.Windows index 613e7c09..ce756f84 100755 --- a/Makefile.Windows +++ b/Makefile.Windows @@ -1,9710 +1,1993 @@ +# +# GNU Makefile for Hamlib (MSVC / clang-cl / MinGW). +# +# G. Vanem <gv...@ya...> 2019 - 2021. +# +THIS_FILE = Makefile.Windows +DATE = $(shell date +%d-%B-%Y) +ABI_VER = 4 + +# +# From 'configure.ac': +# +MAJOR_VER = 4 +MINOR_VER = 2 +VERSION = $(MAJOR_VER).$(MINOR_VER) + +# +# Choose your weapons. Do a 'make vclean' after changing any of these. +# +USE_LIBGD ?= 1 +USE_LIBINDI ?= 0 +USE_LIBREADLINE ?= 0 +USE_LIBUSB ?= 1 +USE_LIBUSRP ?= 1 +USE_LIBXML2 ?= 1 +USE_LUAJIT ?= 0 +USE_MP_COMPILE ?= 1 + +# +# Add support for a 'GnuRadio' device. +# Impossible as it is not up-to-date with current GnuRadio 3.9 API. +# +USE_GNURADIO ?= 0 + +# +# Use the Winsock tracing library (works badly for MinGW): +# https://github.com/gvanem/wsock-trace +# +USE_WSOCK_TRACE ?= 1 + +# +# Use only static external libraries to create '$(Hamlib_DLL)'. +# But '_Hamlib.pyd' and 'HamlibLua.dll' always uses '$(Hamlib_DLL)'. +# +USE_STATIC ?= 1 + +# +# Use '$(Hamlib_DLL)' for all C programs. +# And '$(Hamlib++_DLL)' for all C++ programs. +# +USE_DLLs_FOR_PROGRAMS ?= 1 + +# +# Set to 0 for no Python module. +# Set to 2 to create a Python 2.x module. +# Set to 3 to create a Python 3.x module. +# +USE_PY_BINDING ?= 3 + +# +# Use 'astyle' or 'clang-format' in the "%.i: %.c" preprocess rules below. +# +USE_ASTYLE ?= 0 +USE_CLANG_FORMAT ?= 0 + +# +# Change these as needed: +# (or create env-vars like 'LIBXML2_ROOT=c:/whatever/xml2'). +# +LIBXML2_ROOT ?= f:/MinGW32/src/Parsers/libxml2 +LIBICONV_ROOT ?= f:/MinGW32/src/libiconv-1.15 +LIBGD_ROOT ?= f:/MinGW32/src/Graphics/libgd-2.1.0 +LIBREADLINE_ROOT ?= f:/MinGW32/src/misc/libreadline +LUAJIT_ROOT ?= f:/MinGW32/src/LUA/LuaJIT +LUA5_ROOT ?= f:/MinGW32/src/LUA/Lua-5.4 +LIBUSB_ROOT ?= f:/MinGW32/src/USB/libusb +LIBUSRP_ROOT ?= f:/gv/dx-radio/Bor-IP/src/libusrp/usrp/host +GNURADIO_ROOT ?= f:/gv/dx-radio/GnuRadio/gv-build +LIBINDI_ROOT ?= f:/ProgramFiler/Stellarium/src/src/external/libindi + +PYTHON ?= py -3 + +ifeq ($(USE_LUAJIT),1) + LUA_ROOT = $(realpath $(LUAJIT_ROOT)) + LUA_LIB = $(call select, $(LUA_ROOT)/src/libluajit.a, $(LUA_ROOT)/src/luajit.lib) +else + LUA_ROOT = $(realpath $(LUA5_ROOT)) + LUA_LIB = $(call select, $(LUA_ROOT)/src/liblua.a, $(LUA_ROOT)/src/lua.lib) +endif + +MKDIR = mkdir +RMDIR = rmdir --parents +MOVE = mv --force +COPY = cp --preserve=timestamps --update + +# +# 'clang-cl' may not like stuff in '%CL'. +# Just remove it. +# +export CL= + +define Usage + + Usage: "$(MAKE) -f $(THIS_FILE) CC=[cl | clang-cl | gcc] [CPU=x86 | x64] [all | clean | vclean | realclean | depend | doxy_docs | py_module | lua_module]" + Specify CC=cl - use MSVC + Specify CC=clang-cl - use clang-cl + Specify CC=gcc - use MinGW +endef + +# +# Check the casing of '$CPU'. GNU-make is case-sensitive. +# +ifeq ($(CPU),) + CPU = x86 +endif + +ifeq ($(CPU),X86) + CPU = x86 +else ifeq ($(CPU),X64) + CPU = x64 +endif + +# +# If '$(CPU)=x64', build 64-bit version. Assuming your MinGW +# is dual-target capable and supports the '-mxx' option. +# Otherwise 32-bit programs. +# +ifeq ($(CPU),x64) + BITS = 64 + RCFLAGS = --target=pe-x86-64 + X_SUFFIX = _x64 +else + BITS = 32 + RCFLAGS = --target=pe-i386 + X_SUFFIX = +endif + +ifeq ($(CC),gcc) + OBJ_DIR = MinGW_obj + USE_MP_COMPILE := 0 + +else ifeq ($(CC),clang-cl) + OBJ_DIR = clang_obj + USE_MP_COMPILE := 0 + +else ifeq ($(CC),cl) + OBJ_DIR = MSVC_obj + +else + $(error $(Usage)) +endif + +ifeq ($(CC),gcc) + select = $(1) + CFLAGS = -m$(BITS) -O2 -g --include config.h + LDFLAGS = -m$(BITS) -Wl,--print-map,--sort-common + O = o + A = a + + # + # We want true Winsock2. Not some POSIX emulation that messes up things big-time. + # + CFLAGS += -D__USE_W32_SOCKETS + + WS2_32_LIB = -lws2_32 + +else + select = $(2) + CFLAGS = -nologo -MD -W3 -Zi -O2 -EHsc -DWIN32 -FI./config.h + LDFLAGS = -nologo -debug -incremental:no -verbose -machine:$(CPU) -nodefaultlib:uuid.lib + O = obj + A = lib + + ifeq ($(CC),clang-cl) + CFLAGS += -fms-compatibility -ferror-limit=5 + endif + + ifeq ($(USE_WSOCK_TRACE),1) + WS2_32_LIB = wsock_trace.lib + else + WS2_32_LIB = ws2_32.lib + endif +endif + +# +# Warning control: +# +ifeq ($(CC),gcc) + CFLAGS += -Wall \ + -Wno-format \ + -Wno-array-bounds \ + -Wno-missing-braces \ + -Wno-unused-function \ + -Wno-unused-variable \ + -Wno-shift-count-overflow + +else ifeq ($(CC),clang-cl) + CFLAGS += -Wall \ + -Wno-undef \ + -Wno-unused-function \ + -Wno-unused-macros \ + -Wno-unused-parameter \ + -Wno-unused-variable \ + -Wno-visibility \ + -Wno-unknown-pragmas \ + -Wno-ignored-attributes \ + -Wno-strict-prototypes \ + -Wno-reserved-id-macro \ + -Wno-shadow \ + -Wno-cast-align \ + -Wno-cast-qual \ + -Wno-shorten-64-to-32 \ + -Wno-pedantic \ + -Wno-format-pedantic \ + -Wno-format-nonliteral \ + -Wno-switch-enum \ + -Wno-covered-switch-default \ + -Wno-sign-conversion \ + -Wno-sign-compare \ + -Wno-double-promotion \ + -Wno-assign-enum \ + -Wno-unreachable-code \ + -Wno-unreachable-code-return \ + -Wno-unreachable-code-break \ + -Wno-c++98-compat-pedantic \ + -Wno-old-style-cast \ + -Wno-extra-semi-stmt \ + -Wno-missing-field-initializers \ + -Wno-missing-noreturn \ + -Wno-missing-prototypes \ + -Wno-missing-variable-declarations \ + -Wno-bad-function-cast \ + -Wno-redundant-parens \ + -Wno-tautological-unsigned-zero-compare \ + -Wno-nonportable-system-include-path \ + -Wno-implicit-int-conversion \ + -Wno-float-conversion \ + -Wno-float-equal \ + -Wno-implicit-float-conversion \ + -Wno-implicit-fallthrough \ + -Wno-shift-count-overflow \ + -Wno-documentation \ + -Wno-documentation-unknown-command \ + -Wno-gnu-zero-variadic-macro-arguments \ + -Wno-zero-as-null-pointer-constant + + ifeq ($(USE_LIBUSRP),1) + CFLAGS += -Wno-suggest-override \ + -Wno-suggest-destructor-override + endif + + # + # When on AppVeyor, do not suppress these warnings since they have an old 'clang-cl'. + # + ifeq ($(APPVEYOR_PROJECT_NAME)x,x) + CFLAGS += -Wno-implicit-int-float-conversion \ + -Wno-deprecated-copy-dtor + endif + + # + # This warning is kinda important: + # + # rigs/dummy/dummy.h(46,5): warning: 'netrigctl_get_vfo_mode' redeclared without 'dllimport' attribute: previous + # 'dllimport' ignored [-Winconsistent-dllimport] + # int netrigctl_get_vfo_mode(RIG *); + # ^ + # So do not add a '-Wno-inconsistent-dllimport'. + # + # And so is this '-Wconditional-uninitialized'. + # +else + CFLAGS += -wd4018 -wd4101 -wd4142 -wd4146 -wd4244 -wd4251 -wd4305 -wd4700 -wd4800 + + ifeq ($(BITS),64) + CFLAGS += -wd4267 + endif +endif + +# CFLAGS += -DHASH_BLOOM + +# +# External libraries for '$(Hamlib_DLL)': +# +EX_LIBS = $(WS2_32_LIB) + +# +# The DLL and library names: +# +Hamlib_DLL = Hamlib-$(ABI_VER).dll +Hamlib_IMP_LIB = $(call select, libHamlib-$(ABI_VER).dll.a, Hamlib-$(ABI_VER)_imp.lib) +Hamlib_STAT_LIB = $(call select, libHamlib-$(ABI_VER).a, Hamlib-$(ABI_VER).lib) + +# +# The C++ library +# +Hamlib++_DLL = Hamlib-$(ABI_VER)++.dll +Hamlib++_IMP_LIB = $(call select, libHamlib-$(ABI_VER)++.dll.a, Hamlib-$(ABI_VER)++_imp.lib) + +# +# The internal utility library; '$(hamlib_misc_SRC)'. +# +misc_LIB = $(call select, libmisc.a, misc.lib) + +# +# What to build: +# +TARGETS = $(Hamlib_STAT_LIB) $(Hamlib_DLL) \ + $(Hamlib_IMP_LIB) $(misc_LIB) + +# +# The C++ interface is dynamic only. +# +TARGETS += $(Hamlib++_DLL) $(Hamlib++_IMP_LIB) + +# +# For 'test/*.c' only. They all use '$(Hamlib_DLL)'. +# +PROG_LIBS = $(WS2_32_LIB) $(call select, -lwinpthread) + +ifeq ($(USE_DLLs_FOR_PROGRAMS),1) + # + # A strangely named macro ('-DUSE_Hamlib_DLL' would be better), but + # this will let all .c and .cc programs to use 'Hamlib-$(ABI_VER).dll' + # + PROG_CFLAGS = -DDLL_EXPORT + + # + # Use 'Hamlib-$(ABI_VER).dll' for C programs. + # + C_PROG_LIBS = $(misc_LIB) $(Hamlib_IMP_LIB) + + # + # Use 'Hamlib-$(ABI_VER)++.dll and 'Hamlib-$(ABI_VER).dll' for C++ programs. + # The library order matter for MinGW only. + # + CPP_PROG_LIBS = $(Hamlib_IMP_LIB) $(Hamlib++_IMP_LIB) +else + PROG_CFLAGS = + PROG_LIBS = $(EX_LIBS) + C_PROG_LIBS = $(Hamlib_STAT_LIB) $(misc_LIB) + CPP_PROG_LIBS = $(Hamlib_STAT_LIB) $(misc_LIB) $(Hamlib++_IMP_LIB) +endif + +# +# For 'rigs/kit/usrp.c' and 'rigs/kit/usrp_impl.cc'. +# This needs Boost too. Untested by me. +# +ifeq ($(USE_LIBUSRP),1) + CFLAGS += -DHAVE_USRP \ + -I$(LIBUSRP_ROOT)/include \ + -I$(LIBUSRP_ROOT)/include/usrp + + EX_LIBS += $(call select, $(LIBUSRP_ROOT)/libUSRP.a, \ + $(LIBUSRP_ROOT)/libUSRP_imp.lib) + + hamlib_CC_SRC = kit/usrp_impl.cc +endif + +ifeq ($(USE_LIBUSB),1) + CFLAGS += -DHAVE_LIBUSB \ + -DHAVE_LIBUSB_H \ + -I$(LIBUSB_ROOT)/libusb + + ifeq ($(USE_STATIC),1) + EX_LIBS += $(call select, $(LIBUSB_ROOT)/libusb-1.0.a -ladvapi32, \ + $(LIBUSB_ROOT)/libusb-1.0.lib advapi32.lib) + else + EX_LIBS += $(call select, $(LIBUSB_ROOT)/libusb-1.0.dll.a, \ + $(LIBUSB_ROOT)/libusb-1.0_imp.lib) + endif +endif + +# +# Untested; does it exist except for MinGW? +# +ifeq ($(USE_LIBREADLINE),1) + CFLAGS += -DHAVE_LIBREADLINE \ + -I$(LIBREADLINE_ROOT)/include + + EX_LIBS += $(call select, $(LIBREADLINE_ROOT)/libreadline.a, \ + $(LIBREADLINE_ROOT)/libreadline.lib) +endif + +CFLAGS += -I. \ + -I./include \ + -I./include/hamlib \ + -I./lib \ + -I./src \ + -I./tests + +ifneq ($(CC),gcc) + CFLAGS += -I$(OBJ_DIR) + EX_LIBS += user32.lib kernel32.lib +endif + +c_to_obj = $(addprefix $(OBJ_DIR)/, \ + $(notdir $(1:.c=.$(O)))) + +cc_to_obj = $(addprefix $(OBJ_DIR)/, \ + $(notdir $(1:.cc=.$(O)))) + +cpp_to_obj = $(addprefix $(OBJ_DIR)/, \ + $(notdir $(1:.cpp=.$(O)))) + +c_to_i = $(notdir $(1:.c=.i)) +cc_to_i = $(notdir $(1:.cc=.i)) + +VPATH = rigs/dummy src tests c++ amplifiers/elecraft + +VPATH += $(addprefix rigs/, \ + adat \ + alinco \ + aor \ + barrett \ + dorji \ + drake \ + elad \ + flexradio \ + icmarine \ + icom \ + jrc \ + kachina \ + kenwood \ + kit \ + lowe \ + pcr \ + prm80 \ + racal \ + rft \ + rs \ + skanti \ + tapr \ + tentec \ + tuner \ + uniden \ + winradio \ + wj \ + yaesu) + +VPATH += $(addprefix rotators/, \ + amsat \ + ars \ + celestron \ + cnctrk \ + easycomm \ + ether6 \ + fodtrack \ + gs232a \ + heathkit \ + indi \ + ioptron \ + m2 \ + meade \ + prosistel \ + rotorez \ + sartek \ + satel \ + spid \ + ts7400) + +# +# For compiling 'HamlibPy2_wrap.c,' 'HamlibPy3_wrap.c' and 'HamlibLua_wrap.c'. +# +VPATH += $(OBJ_DIR) + +# +# All of these use '$(Hamlib_DLL)': +# +TESTS_PROGS = ampctl.exe \ + ampctld.exe \ + dumpmem.exe \ + example.exe \ + listrigs.exe \ + rigctl.exe \ + rigctld.exe \ + rigctlcom.exe \ + rigsmtr.exe \ + rigswr.exe \ + rig_bench.exe \ + rotctl.exe \ + rotctld.exe \ + simyaesu.exe \ + testbcd.exe \ + testfreq.exe \ + testloc.exe \ + testrig.exe \ + testrigcaps.exe \ + testrigopen.exe \ + testtrn.exe + +ifneq ($(APPVEYOR_PROJECT_NAME),) + # + # TODO: build with 'LIBUSB_ROOT = ./CI/libusb', 'LIBXML2_ROOT = ./CI/libxml2' etc. + # when running via 'appveyor.yml' + # +endif + +ifeq ($(USE_LIBXML2),1) + TESTS_PROGS += rigmem.exe + PROG_CFLAGS += -I$(LIBXML2_ROOT)/include \ + -I$(LIBICONV_ROOT)/include \ + -DHAVE_XML2 + + # + # Use the dynamic version of 'libxml2'. + # I.e. do not set 'PROG_CFLAGS += -DLIBXML_STATIC'. + # Otherwise we could need to link to a static 'Iconv', 'Zlib' and + # a 'liblzma' too (depending on how 'libxml2' was built). + # + XML2_LIB = $(call select, $(LIBXML2_ROOT)/libxml2.dll.a, \ + $(LIBXML2_ROOT)/xml2_imp.lib) +endif + +ifeq ($(USE_LIBGD),1) + TESTS_PROGS += rigmatrix.exe + PROG_CFLAGS += -I$(LIBGD_ROOT)/src +endif + +# +# This always uses '$(Hamlib++_DLL)'. +# +TESTS_PROGS += testcpp.exe + +# +# All .c-files for '$(Hamlib_DLL)'. +# Except for those in '$(hamlib_misc_SRC)' which do not need to be exported. +# +hamlib_C_SRC = $(addprefix src/, \ + amp_conf.c \ + amp_reg.c \ + amp_settings.c \ + amplifier.c \ + cal.c \ + cm108.c \ + conf.c \ + debug.c \ + event.c \ + ext.c \ + extamp.c \ + gpio.c \ + locator.c \ + iofunc.c \ + mem.c \ + misc.c \ + microham.c \ + network.c \ + parallel.c \ + register.c \ + rig.c \ + rot_conf.c \ + rot_ext.c \ + rot_reg.c \ + rot_settings.c \ + rotator.c \ + serial.c \ + settings.c \ + sleep.c \ + tones.c \ + usb_port.c) + +hamlib_C_SRC += $(addprefix rigs/dummy/, \ + amp_dummy.c \ + dummy.c \ + dummy_common.c \ + flrig.c \ + netampctl.c \ + netrigctl.c \ + netrotctl.c \ + rot_dummy.c \ + trxmanager.c) + +hamlib_C_SRC += $(addprefix rigs/adat/, \ + adat.c \ + adt_200a.c) + +hamlib_C_SRC += $(addprefix rigs/alinco/, \ + alinco.c \ + dx77.c \ + dxsr8.c) + +hamlib_C_SRC += $(addprefix rigs/aor/, \ + aor.c \ + ar2700.c \ + ar3000.c \ + ar3030.c \ + ar5000.c \ + ar7030.c \ + ar7030p.c \ + ar7030p_utils.c \ + ar8000.c \ + ar8200.c \ + ar8600.c \ + sr2200.c) + +hamlib_C_SRC += $(addprefix rigs/barrett/, \ + 950.c \ + barrett.c) + +hamlib_C_SRC += $(addprefix rigs/dorji/, \ + dorji.c \ + dra818.c) + +hamlib_C_SRC += $(addprefix rigs/drake/, \ + drake.c \ + r8a.c \ + r8b.c) + +hamlib_C_SRC += $(addprefix rigs/elad/, \ + elad.c \ + fdm_duo.c) + +hamlib_C_SRC += $(addprefix rigs/flexradio/, \ + dttsp.c \ + flexradio.c \ + sdr1k.c) + +hamlib_C_SRC += $(addprefix rigs/icmarine/, \ + icm700pro.c \ + icm710.c \ + icm802.c \ + icm803.c \ + icmarine.c) + +hamlib_C_SRC += $(addprefix rigs/icom/, \ + delta2.c \ + frame.c \ + ic78.c \ + ic92d.c \ + ic271.c \ + ic275.c \ + ic471.c \ + ic475.c \ + ic703.c \ + ic706.c \ + ic707.c \ + ic718.c \ + ic725.c \ + ic726.c \ + ic728.c \ + ic735.c \ + ic736.c \ + ic737.c \ + ic738.c \ + ic746.c \ + ic751.c \ + ic756.c \ + ic761.c \ + ic765.c \ + ic775.c \ + ic781.c \ + ic785x.c \ + ic820h.c \ + ic821h.c \ + ic910.c \ + ic970.c \ + ic1275.c \ + ic2730.c \ + ic7000.c \ + ic7100.c \ + ic7200.c \ + ic7300.c \ + ic7410.c \ + ic7600.c \ + ic7610.c \ + ic7700.c \ + ic7800.c \ + ic9100.c \ + icom.c \ + icr6.c \ + icr10.c \ + icr20.c \ + icr30.c \ + icr71.c \ + icr72.c \ + icr75.c \ + icr7000.c \ + icr8500.c \ + icr8600.c \ + icr9000.c \ + icr9500.c \ + icrx7.c \ + id1.c \ + id31.c \ + id4100.c \ + id51.c \ + id5100.c \ + omni.c \ + optoscan.c \ + os456.c \ + os535.c \ + perseus.c \ + x108g.c) + +hamlib_C_SRC += $(addprefix rigs/jrc/, \ + jrc.c \ + nrd525.c \ + nrd535.c \ + nrd545.c) + +hamlib_C_SRC += $(addprefix rigs/kachina/, \ + 505dsp.c \ + kachina.c) + +hamlib_C_SRC += $(addprefix rigs/kenwood/, \ + elecraft.c \ + flex.c \ + flex6xxx.c \ + ic10.c \ + k2.c \ + k3.c \ + kenwood.c \ + pihpsdr.c \ + r5000.c \ + th.c \ + thd7.c \ + thd72.c \ + thd74.c \ + thf6a.c \ + thf7.c \ + thg71.c \ + tmd700.c \ + tmd710.c \ + tmv7.c \ + transfox.c \ + trc80.c \ + ts50s.c \ + ts140.c \ + ts440.c \ + ts450s.c \ + ts480.c \ + ts570.c \ + ts590.c \ + ts680.c \ + ts690.c \ + ts711.c \ + ts790.c \ + ts811.c \ + ts850.c \ + ts870s.c \ + ts930.c \ + ts940.c \ + ts950.c \ + ts990s.c \ + ts2000.c \ + xg3.c) + +hamlib_C_SRC += $(addprefix rigs/kit/, \ + dds60.c \ + drt1.c \ + dwt.c \ + elektor304.c \ + elektor507.c \ + fifisdr.c \ + funcube.c \ + hiqsdr.c \ + kit.c \ + miniVNA.c \ + pcrotor.c \ + rs_hfiq.c \ + si570avrusb.c \ + usrp.c) + +hamlib_C_SRC += $(addprefix rigs/lowe/, \ + hf235.c \ + lowe.c) + +hamlib_C_SRC += $(addprefix rigs/pcr/, \ + pcr.c \ + pcr100.c \ + pcr1000.c \ + pcr1500.c \ + pcr2500.c) + +hamlib_C_SRC += $(addprefix rigs/prm80/, \ + prm80.c \ + prm8060.c) + +hamlib_C_SRC += $(addprefix rigs/racal/, \ + ra37xx.c \ + ra3702.c \ + ra6790.c \ + racal.c) + +hamlib_C_SRC += $(addprefix rigs/rft/, \ + ekd500.c \ + rft.c) + +hamlib_C_SRC += $(addprefix rigs/rs/, \ + eb200.c \ + esmc.c \ + gp2000.c \ + rs.c \ + xk2100.c) + +hamlib_C_SRC += $(addprefix rigs/skanti/, \ + skanti.c \ + trp8000.c \ + trp8255.c) + +hamlib_C_SRC += $(addprefix rigs/tapr/, \ + dsp10.c \ + tapr.c) + +hamlib_C_SRC += $(addprefix rigs/tentec/, \ + argonaut.c \ + jupiter.c \ + omnivii.c \ + orion.c \ + paragon.c \ + pegasus.c \ + rx320.c \ + rx331.c \ + rx340.c \ + rx350.c \ + tentec.c \ + tentec2.c \ + tt550.c) + +hamlib_C_SRC += $(addprefix rigs/tuner/, \ + tuner.c \ + v4l.c \ + v4l2.c) + +hamlib_C_SRC += $(addprefix rigs/uniden/, \ + bc245.c \ + bc250.c \ + bc780.c \ + bc895.c \ + bc898.c \ + bcd396t.c \ + bcd996t.c \ + pro2052.c \ + uniden.c \ + uniden_digital.c) + +hamlib_C_SRC += $(addprefix rigs/winradio/, \ + g303.c \ + g305.c \ + g313-win.c \ + winradio.c \ + wr1000.c \ + wr1500.c \ + wr1550.c \ + wr3100.c \ + wr3150.c \ + wr3500.c \ + wr3700.c) + +hamlib_C_SRC += $(addprefix rigs/wj/, \ + wj.c \ + wj8888.c) + +hamlib_C_SRC += $(addprefix rigs/yaesu/, \ + frg100.c \ + frg8800.c \ + frg9600.c \ + ft100.c \ + ft450.c \ + ft600.c \ + ft736.c \ + ft747.c \ + ft757gx.c \ + ft767gx.c \ + ft817.c \ + ft840.c \ + ft847.c \ + ft857.c \ + ft890.c \ + ft891.c \ + ft897.c \ + ft900.c \ + ft920.c \ + ft950.c \ + ft980.c \ + ft990.c \ + ft991.c \ + ft1000d.c \ + ft1000mp.c \ + ft1200.c \ + ft2000.c \ + ft3000.c \ + ft5000.c \ + ft9000.c \ + ftdx10.c \ + ftdx101.c \ + ftdx101mp.c \ + newcat.c \ + vr5000.c \ + vx1700.c \ + yaesu.c) + +# +# Code for Antenna Rotators: +# +hamlib_C_SRC += $(addprefix rotators/, \ + amsat/if100.c \ + ars/ars.c \ + celestron/celestron.c \ + cnctrk/cnctrk.c \ + easycomm/easycomm.c \ + ether6/ether6.c \ + fodtrack/fodtrack.c \ + heathkit/hd1780.c \ + ioptron/rot_ioptron.c \ + m2/rc2800.c \ + meade/meade.c \ + prosistel/prosistel.c \ + rotorez/rotorez.c \ + sartek/sartek.c \ + satel/satel.c \ + spid/spid.c \ + ts7400/ts7400.c) + +hamlib_C_SRC += $(addprefix rotators/gs232a/, \ + gs232.c \ + gs232a.c \ + gs232b.c) + +hamlib_C_SRC += $(addprefix amplifiers/elecraft/, \ + kpa.c \ + kpa1500.c) + +# +# Untested. +# +ifeq ($(USE_LIBINDI),1) + VPATH += $(LIBINDI_ROOT)/libs/indibase + + CFLAGS += -DHAVE_LIBINDI=1 \ + -DHAVE_INDIBASE_LAYOUT=1 \ + -I$(LIBINDI_ROOT) \ + -I$(LIBINDI_ROOT)/libs \ + -I$(LIBINDI_ROOT)/../zlib + + hamlib_C_SRC += rotators/indi/indi.c + hamlib_CPP_SRC = rotators/indi/indi_wrapper.cpp \ + $(addprefix $(LIBINDI_ROOT)/libs/indibase/, \ + basedevice.cpp \ + indiproperty.cpp) +endif + +ifeq ($(USE_GNURADIO),1) + VPATH += extra/gnuradio + CFLAGS += -I./extra/gnuradio -I$(GNURADIO_ROOT)/include + + hamlib_C_SRC += $(addprefix extra/gnuradio/, \ + gr.c \ + graudio.c \ + mc4020.c) + + hamlib_CC_SRC += gnuradio/gnuradio.cc +endif + +# +# Various support code for Hamlib's internal use: +# +hamlib_misc_SRC = lib/termios.c \ + lib/win-misc.c \ + tests/sprintflst.c + +ifneq ($(CC),gcc) + hamlib_misc_SRC += $(addprefix lib/, \ + getopt_long.c \ + gettimeofday.c \ + usleep.c) +endif + +# +# .cc sources for $(Hamlib++_DLL)': +# +hamlib++_SRC = $(addprefix c++/, \ + ampclass.cc \ + rigclass.cc \ + rotclass.cc) + +# +# .c sources for various programs: +# +ampctl_SRC = $(addprefix tests/, \ + ampctl.c \ + ampctl_parse.c \ + dumpcaps_amp.c) + +ampctld_SRC = $(addprefix tests/, \ + ampctld.c \ + ampctl_parse.c \ + dumpcaps_amp.c) + +rigctlcom_SRC = $(addprefix tests/, \ + dumpcaps.c \ + rigctlcom.c \ + rigctl_parse.c) + +rigctl_SRC = $(addprefix tests/, \ + dumpcaps.c \ + dumpcaps_rot.c \ + rigctl.c \ + rigctl_parse.c) + +rigctld_SRC = $(addprefix tests/, \ + dumpcaps.c \ + dumpcaps_rot.c \ + rigctld.c \ + rigctl_parse.c) + +rigmem_SRC = $(addprefix tests/, \ + rigmem.c \ + memcsv.c \ + memload.c \ + memsave.c) + +rotctl_SRC = $(addprefix tests/, \ + rotctl.c \ + rotctl_parse.c \ + dumpcaps.c \ + dumpcaps_rot.c) + +rotctld_SRC = $(addprefix tests/, \ + rotctld.c \ + rotctl_parse.c \ + dumpcaps.c \ + dumpcaps_rot.c) + +hamlib_C_OBJ = $(call c_to_obj, $(hamlib_C_SRC)) +hamlib_CC_OBJ = $(call cc_to_obj, $(hamlib_CC_SRC)) +hamlib_CPP_OBJ = $(call cpp_to_obj,$(hamlib_CPP_SRC)) +hamlib++_OBJ = $(call cc_to_obj, $(hamlib++_SRC)) + +hamlib_misc_OBJ = $(call c_to_obj, $(hamlib_misc_SRC)) +ampctl_OBJ = $(call c_to_obj, $(ampctl_SRC)) +ampctld_OBJ = $(call c_to_obj, $(ampctld_SRC)) +rigctlcom_OBJ = $(call c_to_obj, $(rigctlcom_SRC)) +rigctl_OBJ = $(call c_to_obj, $(rigctl_SRC)) +rigctld_OBJ = $(call c_to_obj, $(rigctld_SRC)) +rigmatrix_OBJ = $(call c_to_obj, tests/rigmatrix.c) +rigmem_OBJ = $(call c_to_obj, $(rigmem_SRC)) +rotctl_OBJ = $(call c_to_obj, $(rotctl_SRC)) +rotctld_OBJ = $(call c_to_obj, $(rotctld_SRC)) + +hamlib_i = $(call c_to_i, $(hamlib_C_SRC)) +hamlib++_i = $(call cc_to_i, $(hamlib++_SRC)) + +$(hamlib_C_OBJ) \ +$(hamlib++_OBJ) \ +$(hamlib_i) \ +$(hamlib++_i): EXTRA_CFLAGS = -DIN_HAMLIB + +$(hamlib++_OBJ) \ +$(hamlib++_i): EXTRA_CFLAGS += -DDLL_EXPORT + +all_test_OBJ = $(addprefix $(OBJ_DIR)/, \ + dumpmem.$(O) \ + example.$(O) \ + listrigs.$(O) \ + rig_bench.$(O) \ + rigsmtr.$(O) \ + rigswr.$(O) \ + simyaesu.$(O) \ + testcpp.$(O) \ + testfreq.$(O) \ + testbcd.$(O) \ + testfreq.$(O) \ + testloc.$(O) \ + testrig.$(O) \ + testrigcaps.$(O) \ + testrigopen.$(O) \ + testtrn.$(O)) + +all_test_OBJ += $(ampctl_OBJ) \ + $(ampctld_OBJ) \ + $(rigctlcom_OBJ) \ + $(rigctl_OBJ) \ + $(rigctld_OBJ) \ + $(rigmatrix_OBJ) \ + $(rigmem_OBJ) \ + $(rotctl_OBJ) \ + $(rotctld_OBJ) \ + +all_test_I = $(notdir $(all_test_OBJ:.$(O)=.i)) + +$(all_test_OBJ) $(all_test_I): EXTRA_CFLAGS = $(PROG_CFLAGS) + +.SECONDARY: $(all_test_OBJ) + +GENERATED = config.h \ + tests/hamlibdatetime.h + +ifneq ($(CC),gcc) + GENERATED += $(addprefix $(OBJ_DIR)/, \ + unistd.h \ + termios.h \ + strings.h \ + sys/time.h \ + sys/ioctl.h) +endif + +all: $(OBJ_DIR) $(OBJ_DIR)/sys $(GENERATED) rm_elecraft $(TARGETS) programs epilogue + +$(OBJ_DIR) $(OBJ_DIR)/sys: + - $(MKDIR) $@ + +# +# This is a 0-byte file that messes with 'rigs/kenwood/elecraft.c' +# +rm_elecraft: + rm -f amplifiers/elecraft/elecraft.c + +epilogue: + $(call white_message, Welcome to $(Hamlib_DLL) and $(Hamlib++_DLL) (CPU=$(CPU)).) + $(call green_message, You could also do a 'make -f $(THIS_FILE) [doxy_docs | py_module | lua_module]'.\n) + +programs: $(GENERATED) $(TESTS_PROGS) + +$(hamlib_misc_OBJ): EXTRA_CFLAGS += -DIN_HAMLIB_MISC_LIB + +$(misc_LIB): $(hamlib_misc_OBJ) + $(call create_lib, $@, $^) + +$(Hamlib_STAT_LIB): $(hamlib_C_OBJ) $(hamlib_CC_OBJ) $(hamlib_CPP_OBJ) + $(call create_lib, $@, $^) + +$(Hamlib_IMP_LIB): $(Hamlib_DLL) +$(Hamlib++_IMP_LIB): $(Hamlib++_DLL) + +$(Hamlib_DLL): $(OBJ_DIR)/Hamlib.def $(Hamlib_STAT_LIB) $(misc_LIB) $(OBJ_DIR)/Hamlib.res + $(call link_DLL, $@, $(Hamlib_IMP_LIB), $(call select,,-def:)$^ $(EX_LIBS)) + +$(Hamlib++_DLL): $(hamlib++_OBJ) $(Hamlib_IMP_LIB) $(OBJ_DIR)/Hamlib++.res + $(call link_DLL, $@, $(Hamlib++_IMP_LIB), $^ $(call select, -lstdc++,) $(EX_LIBS)) + +# +# For MSVC only. +# +ifeq ($(USE_MP_COMPILE),1) + $(hamlib_C_OBJ): $(hamlib_C_SRC) | $(CC).args + $(CC) -MP @$(CC).args -DIN_HAMLIB -Fo./$(OBJ_DIR)\\ $(hamlib_C_SRC) + @echo +endif + +$(CC).args: $(THIS_FILE) + $(call green_message, Creating $@) + $(call create_resp_file, $@, $(CFLAGS) -c) + +# +# For 'testcpp.exe': +# +testcpp.exe: $(OBJ_DIR)/testcpp.$(O) $(CPP_PROG_LIBS) + $(call link_EXE, $@, $^ $(call select, -lstdc++,) $(EX_LIBS)) + +# +# For '$(TESTS_PROGS)': +# +$(OBJ_DIR)/%.$(O): tests/%.c | $(CC).args + $(call Compile, $<, $@) + +ampctl.exe: $(ampctl_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) + +ampctld.exe: $(ampctld_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +rigctlcom.exe: $(rigctlcom_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +rigctl.exe: $(rigctl_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +rigctld.exe: $(rigctld_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +rigmem.exe: $(rigmem_OBJ) $(C_PROG_LIBS) $(XML2_LIB) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +rotctl.exe: $(rotctl_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) -<!DOCTYPE html> -<html lang="en" - data-color-mode="light" - data-light-theme="light" - data-dark-theme="dark"> - <head> - <meta charset="utf-8"> - <link rel="dns-prefetch" href="https://github.githubassets.com"> - <link rel="dns-prefetch" href="https://avatars.githubusercontent.com"> - <link rel="dns-prefetch" href="https://github-cloud.s3.amazonaws.com"> - <link rel="dns-prefetch" href="https://user-images.githubusercontent.com/"> +rotctld.exe: $(rotctld_OBJ) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) +# +# I do not have a GD.lib for MSVC/clang. Use the dynamic MinGW version instead. +# Copy it's .DLL here to avoid another DLL-hell. +# +rigmatrix.exe: $(rigmatrix_OBJ) $(C_PROG_LIBS) $(LIBGD_ROOT)/src/libgd.dll.a + $(call link_EXE, $@, $^ $(PROG_LIBS)) + $(COPY) $(LIBGD_ROOT)/src/bgd.dll . +# +# For all other simple test-programs: +# +%.exe: $(OBJ_DIR)/%.$(O) $(C_PROG_LIBS) + $(call link_EXE, $@, $^ $(PROG_LIBS)) - <link crossorigin="anonymous" media="all" integrity="sha512-UdasBeAS0uriwyLr54gKKE8RYxeMfD/ikM+zOIKI7MZjGXwQfM1zha4aFvIxspXkCm2EAxWQC1QNWyu07ku5Ig==" rel="stylesheet" href="https://github.githubassets.com/assets/frameworks-51d6ac05e012d2eae2c322ebe7880a28.css" /> - - <link crossorigin="anonymous" media="all" integrity="sha512-o4J+tBmn3RlwVnhfBv2BySdk2NdgQAoLnJ9/EKw7Uoua6x2ERCXWLLBdx8O6SeZ1kaQtDPjg+ZxMkfFKpQYipQ==" rel="stylesheet" href="https://github.githubassets.com/assets/behaviors-a3827eb419a7dd197056785f06fd81c9.css" /> - - - - <link crossorigin="anonymous" media="all" integrity="sha512-Z/uTO5JrxIlQATq+PIRNjt2OYLkjbq8VtkRTRNrX+b8rd3EIkPIZOA0mD/xYFZ6YVPr3JPL2xg6JXkltIWf08g==" rel="stylesheet" href="https://github.githubassets.com/assets/github-67fb933b926bc48950013abe3c844d8e.css" /> +# +# For '$(hamlib_C_SRC)' and '$(hamlib_CC_SRC)': +# +$(OBJ_DIR)/%.$(O): %.c | $(CC).args + $(call Compile, $<, $@) + +$(OBJ_DIR)/%.$(O): %.cc | $(CC).args + $(call Compile, $<, $@) + +$(OBJ_DIR)/%.$(O): %.cpp | $(CC).args + $(call Compile, $<, $@) + +# +# For '$(hamlib_misc_SRC)' since 'lib' is not in 'VPATH' due to 'lib/dummy.c'. +# +$(OBJ_DIR)/%.$(O): lib/%.c | $(CC).args + $(call Compile, $<, $@) - <script crossorigin="anonymous" defer="defer" integrity="sha512-8K2vvwbW+6H27Nad5ydg8PA2/aMD/LKq+EiK9s0U0hhVZxCI2tWBsYk9beAtisRw2j+Or5k2/F+6dk02nmj/PA==" type="application/javascript" src="https://github.githubassets.com/assets/environment-f0adafbf.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-3yixvhtA5nOJY+pDcqvBKztKjFwZqklw1mnoaHUlxzLSqT8hc8aJ8KPa+OjVGlOvZAp2prs7kh6cAJFDQBQ1JQ==" type="application/javascript" src="https://github.githubassets.com/assets/chunk-frameworks-df28b1be.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-Bpsh6jNrHD75e3XfQQ+wdo+ky+Ig480DD8OVdZnHZglPO+r5sXnoSvs4In/HaKtH2Di2MVNL7NJFib5zmKrayQ==" type="application/javascript" src="https://github.githubassets.com/assets/chunk-vendor-069b21ea.js"></script> - - <script crossorigin="anonymous" defer="defer" integrity="sha512-TOWq4GrLDl5mgWizcNAEVEOywj4s3Lr0QgDdFUXLept1zNuX1ja/vDsDaU8smKjzepcaDpC+sOiyrx/RL6D04w==" type="application/javascript" src="https://github.githubassets.com/assets/behaviors-4ce5aae0.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-AwxJjNYHMbBW1RDMWqHLbm5ef0HpZqNZm4BU62VDY1R3ClrM8cwzqMGk0YJDgSjC0X3HMnQLUYS8sIcRPYZ3aQ==" type="application/javascript" src="https://github.githubassets.com/assets/primer-030c498c.js"></script> - - <script crossorigin="anonymous" defer="defer" integrity="sha512-MiuFoXnjDmRNVM/xNR9yfPr8Qi8Q6+TKWIrkXp+1QJv9MW8lpBfOy0u7AuVuXQVYKIhsr5DCuCxIs1STWpujLg==" type="application/javascript" data-module-id="./chunk-color-modes.js" data-src="https://github.githubassets.com/assets/chunk-color-modes-322b85a1.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-evfy6RyDyXvLuaEEFaUaIlw9dSRgvKkF3rMeUELkvXq7sGEK/43vTg+3EE6E8nOsjpuPyYQjgS8bxzqkTjlZag==" type="application/javascript" data-module-id="./chunk-contributions-spider-graph.js" data-src="https://github.githubassets.com/assets/chunk-contributions-spider-graph-7af7f2e9.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-obMR8mPKx8OvqRe34LgnUcxeJ1qujiA4ND3H6UX13ExMlA/WfHLjEzXRmgGRcRvN/8J1nzc+Z+jgz/PLTFy6zg==" type="application/javascript" data-module-id="./chunk-drag-drop.js" data-src="https://github.githubassets.com/assets/chunk-drag-drop-a1b311f2.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-cVnIoXzYnuz2SYwsbnuCpTFzvO17cPoQV2mK82+em//c8i7V2L0VEeInplXGgfbx4d8bQGQuPPx0P0BCRfJ37g==" type="application/javascript" data-module-id="./chunk-edit.js" data-src="https://github.githubassets.com/assets/chunk-edit-7159c8a1.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-TGnbT/6B5dxVwEk7iOlwSY9mfqhfq8m05ec+KjdlfEwoieq73iBeyidClQUSmFa2snukwzF9peY8c7FJf9FARA==" type="application/javascript" data-module-id="./chunk-emoji-picker-element.js" data-src="https://github.githubassets.com/assets/chunk-emoji-picker-element-4c69db4f.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-NwYkwzxETzKUYRXumHDsBIuggkh86KmJ1WrwWZW5wTvVPf047+wOmOHI5b4D65bfdtd3WbXJ7k+3ZWoxpIaqcA==" type="application/javascript" data-module-id="./chunk-insights-graph.js" data-src="https://github.githubassets.com/assets/chunk-insights-graph-370624c3.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-ZhHO4yoDkpCF2sJkzsW3BP1RNu9ji9N6KwuBWy03eGOwkHKwBbs5gKizpeyjslAXlWOV4f9HRVN981Du0AfcvQ==" type="application/javascript" data-module-id="./chunk-jump-to.js" data-src="https://github.githubassets.com/assets/chunk-jump-to-6611cee3.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-S8aUo+fRvLif3bA63pJ03RyoYVNFJ7Q+aOmtVVHabaVFMwV1zMdE4HTEewMkbU0ZK2Ik5Q3Ob9/JE+zrNC5qaw==" type="application/javascript" data-module-id="./chunk-profile-pins-element.js" data-src="https://github.githubassets.com/assets/chunk-profile-pins-element-4bc694a3.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-E+H+wAtjiqutBvn2cnXzDIvmasIhYiS7i7JzOfFUwo+Ej8zT54OrJtP//RhwixnypgOpCF4JvqzYy6zOtORDmg==" type="application/javascript" data-module-id="./chunk-runner-groups.js" data-src="https://github.githubassets.com/assets/chunk-runner-groups-13e1fec0.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-U+Pp1bYuA3fRqhike5Go//O/vsExaZLz00lrIby+rZ88yf03nQHz3wLZR9paWkakpD7TH5nS6AUpabCc7OFWpg==" type="application/javascript" data-module-id="./chunk-sortable-behavior.js" data-src="https://github.githubassets.com/assets/chunk-sortable-behavior-53e3e9d5.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-cAsQOq53AtF8bCPWtKuMXOB2Jjt2089fKQQXtk1bNk2ZSBjx2yQOdGZWsXDfWG5H8FmjJzZsepBmOhy+wO7uAQ==" type="application/javascript" data-module-id="./chunk-toast.js" data-src="https://github.githubassets.com/assets/chunk-toast-700b103a.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-QBwrFY4kzAVN0nZmTYJLeEhi5bQ+42rE8h1g384XeZb7n62BykcUICACtaDQ473aIrRf38RSR7WDfNEIVuSlTA==" type="application/javascript" data-module-id="./chunk-tweetsodium.js" data-src="https://github.githubassets.com/assets/chunk-tweetsodium-401c2b15.js"></script> - <script crossorigin="anonymous" defer="defer" integrity="sha512-RfbLfWsDwvP53bQvgbFm/0j3n5N7IuPQ9yyQ1ah3azz9E2KVeo5ujcUGh++d+t49H0EUTKfeAZ+g9PgCVCjErw==" type="application/javascript" data-module-id="./chunk-user-status-submit.js" data-src="https://github.githubassets.com/assets/chunk-user-status-submit-45f6cb7d.js"></script> - - <script crossorigin="anonymous" defer="defer" integrity="sha512-bVgr2gL7DaSaCp/Aev1O/9V1boyT/1FCjRIYcSMOG4AqUvP9e7h3hMvR9LtX0sHt/uTv7Sp1YtF1KMDQm9E6Nw==" type="application/javascript" src="https://github.githubassets.com/assets/repositories-6d582bda.js"></script> -<script crossorigin="anonymous" defer="defer" integrity="sha512-ng+rLwG9JuJBuJQWCGyT4r3VjNUz1FNWKpqbE2zWpJJZHkkwqkYWwJxo5k+PZCuWqUWZxofbuEtLrQnnjIyTqQ==" type="application/javascript" src="https://github.githubassets.com/assets/diffs-9e0fab2f.js"></script> - - <meta name="viewport" content="width=device-width"> - - <title>Hamlib/Makefile.Windows at master · gvanem/Hamlib</title> - <meta name="description" content="Ham radio control library. Now supporting MSVC + clang-cl too. - gvanem/Hamlib"> - <link rel="search" type="application/opensearchdescription+xml" href="/opensearch.xml" title="GitHub"> - <link rel="fluid-icon" href="https://github.com/fluidicon.png" title="GitHub"> - <meta property="fb:app_id" content="1401488693436528"> - <meta name="apple-itunes-app" content="app-id=1477376905" /> - <meta name="twitter:image:src" content="https://avatars.githubusercontent.com/u/945271?s=400&v=4" /><meta name="twitter:site" content="@github" /><meta name="twitter:card" content="summary" /><meta name="twitter:title" content="gvanem/Hamlib" /><meta name="twitter:description" content="Ham radio control library. Now supporting MSVC + clang-cl too. - gvanem/Hamlib" /> - <meta property="og:image" content="https://avatars.githubusercontent.com/u/945271?s=400&v=4" /><meta property="og:site_name" content="GitHub" /><meta property="og:type" content="object" /><meta property="og:title" content="gvanem/Hamlib" /><meta property="og:url" content="https://github.com/gvanem/Hamlib" /><meta property="og:description" content="Ham radio control library. Now supporting MSVC + clang-cl too. - gvanem/Hamlib" /> - - - - - - <link rel="assets" href="https://github.githubassets.com/"> - <link rel="shared-web-socket" href="wss://alive.github.com/_sockets/u/8899915/ws?session=eyJ2IjoiVjMiLCJ1Ijo4ODk5OTE1LCJzIjo2NTkyOTY0MDMsImMiOjY1NzMwNzA3LCJ0IjoxNjE1MjY4ODExfQ==--2dbf41cfcdcb25546b2110fed5c954965bc58f74c20e0ffc7562ed5293c0d594" data-refresh-url="/_alive"> - <link rel="shared-web-socket-src" href="/socket-worker-5029ae85.js"> - <link rel="sudo-modal" href="/sessions/sudo_modal"> - - <meta name="request-id" content="C514:1DF1:1229255:1FF6538:60470BC3" data-pjax-transient="true" /><meta name="html-safe-nonce" content="a16fbfa9c0f8d7b2045600b8396573a9da1db93ed11f3e8527b3c39012f91b55" data-pjax-transient="true" /><meta name="visitor-payload" content="eyJyZWZlcnJlciI6Imh0dHBzOi8vZ2l0aHViLmNvbS9ndmFuZW0vSGFtbGliL2ZpbmQvbWFzdGVyIiwicmVxdWVzdF9pZCI6IkM1MTQ6MURGMToxMjI5MjU1OjFGRjY1Mzg6NjA0NzBCQzMiLCJ2aXNpdG9yX2lkIjoiMzY4NzI5MTA4Mzc3NzU5MjY2MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9" data-pjax-transient="true" /><meta name="visitor-hmac" content="1df62dc27d9095fb012f67844c4106d13cb7354dbe9005128d63378abfac0d56" data-pjax-transient="true" /> - - <meta name="hovercard-subject-tag" content="repository:214546134" data-pjax-transient> - - - <meta name="github-keyboard-shortcuts" content="repository,source-code" data-pjax-transient="true" /> - - - - <meta name="selected-link" value="repo_source" data-pjax-transient> - - <meta name="google-site-verification" content="c1kuD-K2HIVF635lypcsWPoD4kilo5-jA_wBFyT4uMY"> - <meta name="google-site-verification" content="KT5gs8h0wvaagLKAVWq8bbeNwnZZK1r1XQysX3xurLU"> - <meta name="google-site-verification" content="ZzhVyEFwb7w3e0-uOTltm8Jsck2F5StVihD0exw2fsA"> - <meta name="google-site-verification" content="GXs5KoUUkNCoaAZn7wPN-t01Pywp9M3sEjnt_3_ZWPc"> - - <meta name="octolytics-host" content="collector.githubapp.com" /><meta name="octolytics-app-id" content="github" /><meta name="octolytics-event-url" content="https://collector.githubapp.com/github-external/browser_event" /><meta name="octolytics-actor-id" content="8899915" /><meta name="octolytics-actor-login" content="mdblack98" /><meta name="octolytics-actor-hash" content="2eef6ecf973baf7c17cbfff04cda596b4d8d96fb9f2fbaf6d5c1152a38ce2ad3" /> - - <meta name="analytics-location" content="/<user-name>/<repo-name>/blob/show" data-pjax-transient="true" /> - - - - - - <meta name="optimizely-datafile" content="{"version": "4", "rollouts": [], "typedAudiences": [], "anonymizeIP": true, "projectId": "16737760170", "variables": [], "featureFlags": [], "experiments": [{"status": "Running", "audienceIds": [], "variations": [{"variables": [], "id": "19739506060", "key": "en"}, {"variables": [], "id": "19720506378", "key": "pt"}], "id": "19741925936", "key": "homepage_translation", "layerId": "19739776731", "trafficAllocation": [{"entityId": "19720506378", "endOfRange": 5000}, {"entityId": "19739506060", "endOfRange": 10000}], "forcedVariations": {}}], "audiences": [{"conditions": "[\"or\", {\"match\": \"exact\", \"name\": \"$opt_dummy_attribute\", \"type\": \"custom_attribute\", \"value\": \"$opt_dummy_value\"}]", "id": "$opt_dummy_audience", "name": "Optimizely-Generated Audience for Backwards Compatibility"}], "groups": [{"policy": "random", "trafficAllocation": [{"entityId": "20065350824", "endOfRange": 10000}], "experiments": [{"status": "Running", "audienceIds": [], "variations": [{"variables": [], "id": "20061181493", "key": "control"}, {"variables": [], "id": "20046091568", "key": "most_popular"}], "id": "20065350824", "key": "pricing_page", "layerId": "20047761391", "trafficAllocation": [{"entityId": "20061181493", "endOfRange": 5000}, {"entityId": "20046091568", "endOfRange": 10000}], "forcedVariations": {"1693726779.1607624005": "most_popular", "b3d9f4f9910bc46c43a8d65ab83d8570": "most_popular"}}], "id": "19972601768"}], "attributes": [{"id": "16822470375", "key": "user_id"}, {"id": "17143601254", "key": "spammy"}, {"id": "18175660309", "key": "organization_plan"}, {"id": "18813001570", "key": "is_logged_in"}, {"id": "19073851829", "key": "geo"}], "botFiltering": false, "accountId": "16737760170", "events": [{"experimentIds": [], "id": "17911811441", "key": "hydro_click.dashboard.teacher_toolbox_cta"}, {"experimentIds": [], "id": "18124116703", "key": "submit.organizations.complete_sign_up"}, {"experimentIds": [], "id": "18145892387", "key": "no_metric.tracked_outside_of_optimizely"}, {"experimentIds": [], "id": "18178755568", "key": "click.org_onboarding_checklist.add_repo"}, {"experimentIds": [], "id": "18180553241", "key": "submit.repository_imports.create"}, {"experimentIds": [], "id": "18186103728", "key": "click.help.learn_more_about_repository_creation"}, {"experimentIds": [], "id": "18188530140", "key": "test_event.do_not_use_in_production"}, {"experimentIds": [], "id": "18191963644", "key": "click.empty_org_repo_cta.transfer_repository"}, {"experimentIds": [], "id": "18195612788", "key": "click.empty_org_repo_cta.import_repository"}, {"experimentIds": [], "id": "18210945499", "key": "click.org_onboarding_checklist.invite_members"}, {"experimentIds": [], "id": "18211063248", "key": "click.empty_org_repo_cta.create_repository"}, {"experimentIds": [], "id": "18215721889", "key": "click.org_onboarding_checklist.update_profile"}, {"experimentIds": [], "id": "18224360785", "key": "click.org_onboarding_checklist.dismiss"}, {"experimentIds": [], "id": "18234832286", "key": "submit.organization_activation.complete"}, {"experimentIds": [], "id": "18252392383", "key": "submit.org_repository.create"}, {"experimentIds": [], "id": "18257551537", "key": "submit.org_member_invitation.create"}, {"experimentIds": [],... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-05-31 12:49:44
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 76405a1a9ae41c33db847bdf270876cad8680843 (commit) via a9eeb70f218c1a3eb2a2ada449da4d16383c2047 (commit) via ab0e3f3d2b2c924408bf55695c8fb40ccf683691 (commit) via 2cfc02a10cc5a845d9c1e6f1d5eb2b6ddd94bb04 (commit) via 01ddc8860882536fdeca2a9ac29ced0a43a3191d (commit) via 901cea8944f86c65cf5319555747f6d14192ffd6 (commit) via f19d354ede1de0d2f3a910854aba9174a7e55125 (commit) via fc26aa545fa41261b8a5d6c0209a24dae6576a88 (commit) via ae67384dafe21bc2bc2fc0f65635ed9f10970732 (commit) via 3eab223a472f38bfc1cd8e816bf94a4d622bd628 (commit) via 83508b5e38d56596797beea5a5204ad6738c310a (commit) via 5400b6d1ee779f3127a78f25d97302b6f42b2711 (commit) via b50fe3b7b2007b64767b6d3a57be777845b6a45a (commit) via 56260bb416536ef5ea5a6d5265310b2338bde444 (commit) via 3f5bf2bb2389df7c03f6ec5dba6713b988b6f829 (commit) via 4544214c3a831258ada5d3e4f87408d7fcc2dadb (commit) via d529881cdb2cb24cb0d9883b967524f45dc189f4 (commit) via d42e75bac65898900cb59b2d8e5671a212eb52b6 (commit) via 0d46e5b92ec03c3ffcd7fcb04e01b4115d353120 (commit) via 8cc4d59cbb06871838c0c41e2491de9f85449a82 (commit) via 0b73daa4d80ea6ec03b0c5483512899604d9623f (commit) via 7ce07c09ad7151fc925ed2a18141ffbe7947b304 (commit) via 76103ec19956554973c1759657046ae5c9ef75d0 (commit) via fe7c465624b7dc1e3c47c0892cf97562000d7469 (commit) via 6b76701efca61afbaebabed100ceda2b4c333dc1 (commit) via 52736df8b8820929d39e4397db979e48493388bc (commit) via c8b2322018d0d5d6e69164ec613b5de3f26e73b1 (commit) via 19f00558e4886c2ee6b05db05a3cce8ba4e29805 (commit) via 1c379e793a066c30d35fed99e5fb1a77f7a882f8 (commit) via febeb40722764f342ebdfb05e72829f1ac32a808 (commit) via 21276336787410d972d4c58bdc13d1f23fec829b (commit) via f44fe0ed31c56ecf89c81b1d94c3c4863888e0c6 (commit) via fa9adb0c85160b92935dd7c0238af00b7fb89211 (commit) via b1a4bb06ce11674ca7abf81b35e76790f31c430f (commit) via f09a62b7f4b45a9dbe0b03f24121607606baa912 (commit) via 7e451446a7d07c4210af9590d439122d1b18e6ad (commit) via 11bcf032290a876afd33ebb892821684f7669639 (commit) via a823e5d3431c349bdd3e79e9a78da9e13866dec1 (commit) via c9d31337b97787db9d5477cb7de542a6cd21477f (commit) via f6d5b7e3c6b3d8cf7f41924136319515c35f47f5 (commit) via 921d4d43ef14caada6e48151250b1353fb9dea61 (commit) via 85dfb1bed8c6296b29c62ff23c10ddc795db1a8f (commit) from 468dd151102ef94d71c071b1acf736b65cc727ff (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 76405a1a9ae41c33db847bdf270876cad8680843 Merge: ab0e3f3d a9eeb70f Author: Michael Black <mdb...@ya...> Date: Tue May 31 06:56:28 2022 -0500 Merge pull request #1045 from PianetaRadio/master Dummy rotator max_az = 450 commit a9eeb70f218c1a3eb2a2ada449da4d16383c2047 Author: PianetaRadio <789...@us...> Date: Tue May 31 12:38:30 2022 +0200 Dummy rotator max_az = 450 diff --git a/rigs/dummy/rot_dummy.c b/rigs/dummy/rot_dummy.c index 5b60f056..f2e3cf75 100644 --- a/rigs/dummy/rot_dummy.c +++ b/rigs/dummy/rot_dummy.c @@ -929,14 +929,14 @@ struct rot_caps dummy_rot_caps = ROT_MODEL(ROT_MODEL_DUMMY), .model_name = "Dummy", .mfg_name = "Hamlib", - .version = "20220519.0", + .version = "20220531.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rot_type = ROT_TYPE_AZEL, .port_type = RIG_PORT_NONE, .min_az = -180., - .max_az = 180., + .max_az = 450., .min_el = 0., .max_el = 90., commit ab0e3f3d2b2c924408bf55695c8fb40ccf683691 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 30 22:26:38 2022 -0500 Update rigctl and rigctld man pages to add set_lock_mode and get_lock_mode diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index a3c581d0..3747b1cb 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -1217,6 +1217,16 @@ before sending the next command to the radio. .BR password " \(aq" \fIPassword\fP \(aq Sends password to rigctld when rigctld has been secured with -A. Must use the 32-char shared secret from rigctld. . +.TP +.BR set_lock_mode " \(aq" \fILocked\fP \(aq +Turns mode lock on(1) or off(0). Turning on will prevent all clients from changing the rig mode. +For example this is useful when running CW Skimmer in FM mode on an IC-7300. Clicking spots +in a spotting program will not change the VFOA mode when lock is on. So "set_lock_mode 1" when +CW Skimmer is started and "set_lock_mode 0" when CW Skimmer is stopped. +. +.TP +.BR get_lock_mode +Returns current lock mode status 1=On, 2=Off . .SH READLINE . diff --git a/doc/man1/rigctld.1 b/doc/man1/rigctld.1 index 0f2eec3e..a01ea92e 100644 --- a/doc/man1/rigctld.1 +++ b/doc/man1/rigctld.1 @@ -1140,6 +1140,17 @@ Set vfo option Status 1=on or 0=off This is the same as using the -o switch for rigctl and ritctld. This can be dyamically changed while running. . +.TP +.BR set_lock_mode " \(aq" \fILocked\fP \(aq +Turns mode lock on(1) or off(0). Turning on will prevent all clients from changing the rig mode. +For example this is useful when running CW Skimmer in FM mode on an IC-7300. Clicking spots +in a spotting program will not change the VFOA mode when lock is on. So "set_lock_mode 1" when +CW Skimmer is started and "set_lock_mode 0" when CW Skimmer is stopped. +. +.TP +.BR get_lock_mode +Returns current lock mode status 1=On, 2=Off +. . .SH PROTOCOL . commit 2cfc02a10cc5a845d9c1e6f1d5eb2b6ddd94bb04 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 30 07:45:47 2022 -0500 Update rigctl.1 man page to add stop_morse and wait_morse diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index 5211174c..a3c581d0 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -704,6 +704,14 @@ Send symbols. For Yaesu rigs use memory#. . .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 0x8b ", " get_dcd Get .RI \(aq DCD \(aq commit 01ddc8860882536fdeca2a9ac29ced0a43a3191d Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 29 23:04:50 2022 -0500 Update rigctld.1 man page diff --git a/doc/man1/rigctld.1 b/doc/man1/rigctld.1 index b8b18b35..0f2eec3e 100644 --- a/doc/man1/rigctld.1 +++ b/doc/man1/rigctld.1 @@ -205,7 +205,7 @@ in which case it is hexadecimal. .BR \-S ", " \-\-separator = \fIchar\fP Use char as separator instead of line feed .IP -The default is \n +The default is \n. Recommend using $ or @ as they work on both Unix and Windows .IP . .TP commit 901cea8944f86c65cf5319555747f6d14192ffd6 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 29 22:53:30 2022 -0500 Add wait_morse to rigs that had send_morse but missing wait_morse wait_morse only works on full break-in https://github.com/Hamlib/Hamlib/issues/1043 diff --git a/rigs/icom/ic7600.c b/rigs/icom/ic7600.c index cd461c0b..3dbc2488 100644 --- a/rigs/icom/ic7600.c +++ b/rigs/icom/ic7600.c @@ -270,7 +270,7 @@ const struct rig_caps ic7600_caps = RIG_MODEL(RIG_MODEL_IC7600), .model_name = "IC-7600", .mfg_name = "Icom", - .version = BACKEND_VER ".2", + .version = BACKEND_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -446,6 +446,7 @@ const struct rig_caps ic7600_caps = .set_powerstat = icom_set_powerstat, .get_powerstat = icom_get_powerstat, .send_morse = icom_send_morse, + .wait_morse = rig_wait_morse, .set_clock = ic7600_set_clock, .get_clock = ic7600_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS diff --git a/rigs/kenwood/ts480.c b/rigs/kenwood/ts480.c index edbaa553..cfa38fae 100644 --- a/rigs/kenwood/ts480.c +++ b/rigs/kenwood/ts480.c @@ -1256,7 +1256,7 @@ const struct rig_caps ts480_caps = RIG_MODEL(RIG_MODEL_TS480), .model_name = "TS-480", .mfg_name = "Kenwood", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1435,6 +1435,7 @@ const struct rig_caps ts480_caps = .set_ext_func = ts480_set_ext_func, .get_ext_func = ts480_get_ext_func, .send_morse = kenwood_send_morse, + .wait_morse = rig_wait_morse, .vfo_op = kenwood_vfo_op, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; @@ -1608,7 +1609,7 @@ const struct rig_caps sdruno_caps = RIG_MODEL(RIG_MODEL_SDRUNO), .model_name = "SDRUno", .mfg_name = "SDRPlay", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1788,6 +1789,7 @@ const struct rig_caps sdruno_caps = .set_ext_func = ts480_set_ext_func, .get_ext_func = ts480_get_ext_func, .send_morse = kenwood_send_morse, + .wait_morse = rig_wait_morse, .vfo_op = kenwood_vfo_op, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index c73066ff..c41217d8 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -376,6 +376,7 @@ const struct rig_caps ts890s_caps = .set_ant = kenwood_set_ant, .get_ant = kenwood_get_ant, .send_morse = kenwood_send_morse, + .wait_morse = rig_wait_morse, .scan = kenwood_scan, /* not working, invalid arguments using rigctl; kenwood_scan does only support on/off and not tone and CTCSS scan */ .has_set_level = TS890_LEVEL_ALL, .has_get_level = TS890_LEVEL_ALL, diff --git a/rigs/tentec/orion.h b/rigs/tentec/orion.h index baa7dc5e..cbe242e8 100644 --- a/rigs/tentec/orion.h +++ b/rigs/tentec/orion.h @@ -196,7 +196,7 @@ const struct rig_caps tt565_caps = { RIG_MODEL(RIG_MODEL_TT565), .model_name = "TT-565 Orion", .mfg_name = "Ten-Tec", -.version = BACKEND_VER ".0", +.version = BACKEND_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -358,6 +358,7 @@ RIG_MODEL(RIG_MODEL_TT565), .reset = tt565_reset, .get_info = tt565_get_info, .send_morse = tt565_send_morse, +.wait_morse = rig_wait_morse, .get_func = tt565_get_func, .set_func = tt565_set_func, .get_ant = tt565_get_ant, diff --git a/rigs/yaesu/ft1200.c b/rigs/yaesu/ft1200.c index 36505854..9ba50b22 100644 --- a/rigs/yaesu/ft1200.c +++ b/rigs/yaesu/ft1200.c @@ -320,6 +320,7 @@ const struct rig_caps ftdx1200_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS diff --git a/rigs/yaesu/ft2000.c b/rigs/yaesu/ft2000.c index afc02286..268586b5 100644 --- a/rigs/yaesu/ft2000.c +++ b/rigs/yaesu/ft2000.c @@ -307,5 +307,6 @@ const struct rig_caps ft2000_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft3000.c b/rigs/yaesu/ft3000.c index a338605f..dd359b68 100644 --- a/rigs/yaesu/ft3000.c +++ b/rigs/yaesu/ft3000.c @@ -413,6 +413,7 @@ const struct rig_caps ftdx3000_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft450.c b/rigs/yaesu/ft450.c index dc6932c8..f157b24f 100644 --- a/rigs/yaesu/ft450.c +++ b/rigs/yaesu/ft450.c @@ -42,7 +42,7 @@ const struct rig_caps ft450_caps = RIG_MODEL(RIG_MODEL_FT450), .model_name = "FT-450", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".1", + .version = NEWCAT_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -202,6 +202,7 @@ const struct rig_caps ft450_caps = .set_channel = newcat_set_channel, .get_channel = newcat_get_channel, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft5000.c b/rigs/yaesu/ft5000.c index 22dc60d6..6e51b73c 100644 --- a/rigs/yaesu/ft5000.c +++ b/rigs/yaesu/ft5000.c @@ -140,7 +140,7 @@ const struct rig_caps ftdx5000_caps = RIG_MODEL(RIG_MODEL_FTDX5000), .model_name = "FTDX-5000", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".2", + .version = NEWCAT_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -309,5 +309,6 @@ const struct rig_caps ftdx5000_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft891.c b/rigs/yaesu/ft891.c index 8124d6c2..b8247080 100644 --- a/rigs/yaesu/ft891.c +++ b/rigs/yaesu/ft891.c @@ -133,7 +133,7 @@ const struct rig_caps ft891_caps = RIG_MODEL(RIG_MODEL_FT891), .model_name = "FT-891", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".6", + .version = NEWCAT_VER ".7", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -320,6 +320,7 @@ const struct rig_caps ft891_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS diff --git a/rigs/yaesu/ft9000.c b/rigs/yaesu/ft9000.c index 78ca77ec..43fe7f4d 100644 --- a/rigs/yaesu/ft9000.c +++ b/rigs/yaesu/ft9000.c @@ -49,7 +49,7 @@ const struct rig_caps ft9000_caps = RIG_MODEL(RIG_MODEL_FT9000), .model_name = "FTDX-9000", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".1", + .version = NEWCAT_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -212,5 +212,6 @@ const struct rig_caps ft9000_caps = .set_channel = newcat_set_channel, .get_channel = newcat_get_channel, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft920.c b/rigs/yaesu/ft920.c index a4327c85..e0ca52e2 100644 --- a/rigs/yaesu/ft920.c +++ b/rigs/yaesu/ft920.c @@ -410,7 +410,7 @@ const struct rig_caps ft920_caps = RIG_MODEL(RIG_MODEL_FT920), .model_name = "FT-920", .mfg_name = "Yaesu", - .version = "20210221.0", /* YYYYMMDD */ + .version = "20220529.0", /* YYYYMMDD */ .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, diff --git a/rigs/yaesu/ft950.c b/rigs/yaesu/ft950.c index b06a0b32..b9b46ea0 100644 --- a/rigs/yaesu/ft950.c +++ b/rigs/yaesu/ft950.c @@ -87,7 +87,7 @@ const struct rig_caps ft950_caps = RIG_MODEL(RIG_MODEL_FT950), .model_name = "FT-950", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".2", + .version = NEWCAT_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -284,5 +284,6 @@ const struct rig_caps ft950_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index 8ab22880..433569f9 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -141,7 +141,7 @@ const struct rig_caps ft991_caps = RIG_MODEL(RIG_MODEL_FT991), .model_name = "FT-991", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".10", + .version = NEWCAT_VER ".11", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -353,6 +353,7 @@ const struct rig_caps ft991_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .send_voice_mem = newcat_send_voice_mem, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, diff --git a/rigs/yaesu/ftdx10.c b/rigs/yaesu/ftdx10.c index 83bd296e..3ef3876d 100644 --- a/rigs/yaesu/ftdx10.c +++ b/rigs/yaesu/ftdx10.c @@ -137,7 +137,7 @@ const struct rig_caps ftdx10_caps = RIG_MODEL(RIG_MODEL_FTDX10), .model_name = "FTDX-10", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".2", + .version = NEWCAT_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -308,6 +308,7 @@ const struct rig_caps ftdx10_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS diff --git a/rigs/yaesu/ftdx101.c b/rigs/yaesu/ftdx101.c index 3d8d049f..76b97e7c 100644 --- a/rigs/yaesu/ftdx101.c +++ b/rigs/yaesu/ftdx101.c @@ -137,7 +137,7 @@ const struct rig_caps ftdx101d_caps = RIG_MODEL(RIG_MODEL_FTDX101D), .model_name = "FTDX-101D", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".15", + .version = NEWCAT_VER ".16", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -309,6 +309,7 @@ const struct rig_caps ftdx101d_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS diff --git a/rigs/yaesu/ftdx101mp.c b/rigs/yaesu/ftdx101mp.c index cf8ea3f7..349bda87 100644 --- a/rigs/yaesu/ftdx101mp.c +++ b/rigs/yaesu/ftdx101mp.c @@ -75,7 +75,7 @@ const struct rig_caps ftdx101mp_caps = RIG_MODEL(RIG_MODEL_FTDX101MP), .model_name = "FTDX-101MP", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".6", + .version = NEWCAT_VER ".7", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -246,6 +246,7 @@ const struct rig_caps ftdx101mp_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .wait_morse = rig_wait_morse, .set_clock = newcat_set_clock, .get_clock = newcat_get_clock, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS commit f19d354ede1de0d2f3a910854aba9174a7e55125 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 29 12:06:44 2022 -0500 Astyle files diff --git a/rigs/yaesu/ft847.c b/rigs/yaesu/ft847.c index b21d147c..3c7ef3e1 100644 --- a/rigs/yaesu/ft847.c +++ b/rigs/yaesu/ft847.c @@ -612,12 +612,12 @@ const struct rig_caps ft650_caps = }, /* rx range end */ .tx_range_list2 = { - {kHz(24500),kHz(25000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, - {kHz(24500),kHz(25000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, - {kHz(28000),kHz(29700), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, - {kHz(28000),kHz(29700), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, - {kHz(50000),kHz(54000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, - {kHz(50000),kHz(54000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(24500), kHz(25000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(24500), kHz(25000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(28000), kHz(29700), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(28000), kHz(29700), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(50000), kHz(54000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(50000), kHz(54000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, RIG_FRNG_END, }, /* tx range end */ diff --git a/simulators/simicom.c b/simulators/simicom.c index 6b6a9a4f..5536be42 100644 --- a/simulators/simicom.c +++ b/simulators/simicom.c @@ -253,9 +253,10 @@ void frameParse(int fd, unsigned char *frame, int len) } break; + case 0x1c: - switch(frame[5]) - { + switch (frame[5]) + { case 0: if (frame[6] == 0xfd) { @@ -263,16 +264,19 @@ void frameParse(int fd, unsigned char *frame, int len) frame[7] = 0xfd; write(fd, frame, 8); } - else { + else + { ptt = frame[6]; frame[7] = 0xfb; frame[8] = 0xfd; write(fd, frame, 9); } + break; - } - break; + } + + break; #ifdef X25 diff --git a/src/rig.c b/src/rig.c index ed3aacaa..482ab0c0 100644 --- a/src/rig.c +++ b/src/rig.c @@ -328,7 +328,7 @@ void add2debugmsgsave(const char *s) char *p; char stmp[DEBUGMSGSAVE_SIZE]; int i, nlines; - int maxmsg = DEBUGMSGSAVE_SIZE/2; + int maxmsg = DEBUGMSGSAVE_SIZE / 2; MUTEX_LOCK(debugmsgsave); memset(stmp, 0, sizeof(stmp)); p = debugmsgsave; @@ -361,7 +361,8 @@ void add2debugmsgsave(const char *s) } --nlines; - if (nlines == 0 && strlen(debugmsgsave) > maxmsg) strcpy(debugmsgsave,"!!!!debugmsgsave too long\n"); + + if (nlines == 0 && strlen(debugmsgsave) > maxmsg) { strcpy(debugmsgsave, "!!!!debugmsgsave too long\n"); } } if (strlen(stmp) + strlen(s) + 1 < DEBUGMSGSAVE_SIZE) @@ -374,6 +375,7 @@ void add2debugmsgsave(const char *s) "%s: debugmsgsave overflow!! len of debugmsgsave=%d, len of add=%d\n", __func__, (int)strlen(debugmsgsave), (int)strlen(s)); } + MUTEX_UNLOCK(debugmsgsave); } diff --git a/src/sprintflst.c b/src/sprintflst.c index 549af7ad..e591d558 100644 --- a/src/sprintflst.c +++ b/src/sprintflst.c @@ -41,7 +41,8 @@ int check_buffer_overflow(char *str, int len, int nlen) { if (len + 32 >= nlen) // make sure at least 32 bytes are available { - rig_debug(RIG_DEBUG_ERR, "%s: buffer overflow, len=%u, nlen=%d, str='%s', len+32 must be >= nlen\n", + rig_debug(RIG_DEBUG_ERR, + "%s: buffer overflow, len=%u, nlen=%d, str='%s', len+32 must be >= nlen\n", __func__, len, nlen, str); } diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 272cfb80..97d5f5c6 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -364,8 +364,8 @@ static struct test_table test_list[] = { 0xf7, "get_mode_bandwidths", ACTION(get_mode_bandwidths), ARG_IN | ARG_NOVFO, "Mode" }, { 0xa0, "set_separator", ACTION(set_separator), ARG_IN | ARG_NOVFO, "Separator" }, { 0xa1, "get_separator", ACTION(get_separator), ARG_NOVFO, "Separator" }, - { 0xa2, "set_lock_mode", ACTION(set_lock_mode), ARG_IN | ARG_NOVFO, "Locked" }, - { 0xa3, "get_lock_mode", ACTION(get_lock_mode), ARG_NOVFO, "Locked" }, + { 0xa2, "set_lock_mode", ACTION(set_lock_mode), ARG_IN | ARG_NOVFO, "Locked" }, + { 0xa3, "get_lock_mode", ACTION(get_lock_mode), ARG_NOVFO, "Locked" }, { 0x00, "", NULL }, }; @@ -2176,7 +2176,9 @@ declare_proto_rig(set_mode) mode = rig_parse_mode(arg1); CHKSCN1ARG(sscanf(arg2, "%ld", &width)); - if (rig->state.lock_mode) RETURNFUNC(RIG_OK); + + if (rig->state.lock_mode) { RETURNFUNC(RIG_OK); } + RETURNFUNC(rig_set_mode(rig, vfo, mode, width)); } @@ -2337,7 +2339,8 @@ declare_proto_rig(get_vfo_info) } else { - fprintf(fout, "%.0f%c%s%c%d%c%d%c%d\n", freq, resp_sep, modestr, resp_sep, (int)width, resp_sep, (int)split, resp_sep, + fprintf(fout, "%.0f%c%s%c%d%c%d%c%d\n", freq, resp_sep, modestr, resp_sep, + (int)width, resp_sep, (int)split, resp_sep, (int)satmode); } @@ -5206,8 +5209,9 @@ declare_proto_rig(get_separator) if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { - fprintf(fout, "%s: ", cmd->arg1); + fprintf(fout, "%s: ", cmd->arg1); } + sprintf(buf, "0x%x", rig_resp_sep); fprintf(fout, "%s\n", buf); @@ -5227,7 +5231,7 @@ declare_proto_rig(get_lock_mode) { if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { - fprintf(fout, "%s: ", cmd->arg1); + fprintf(fout, "%s: ", cmd->arg1); } fprintf(fout, "%d\n", rig->state.lock_mode); commit fc26aa545fa41261b8a5d6c0209a24dae6576a88 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 29 12:06:03 2022 -0500 Fix get_separator rigctl output diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 6a551de6..272cfb80 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -5204,11 +5204,11 @@ declare_proto_rig(get_separator) { char buf[32]; - if (isprint(rig_resp_sep)) + if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { - sprintf(buf, "%c", rig_resp_sep); + fprintf(fout, "%s: ", cmd->arg1); } - else { sprintf(buf, "0x%x %p", rig_resp_sep, &rig_resp_sep); } + sprintf(buf, "0x%x", rig_resp_sep); fprintf(fout, "%s\n", buf); return RIG_OK; commit ae67384dafe21bc2bc2fc0f65635ed9f10970732 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 29 12:00:03 2022 -0500 https://github.com/Hamlib/Hamlib/issues/1044 diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 8354ec80..d4e39ed1 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -2572,6 +2572,7 @@ struct rig_state { int use_cached_mode; /*<! flag instructing rig_get_mode to use cached values when asyncio is in use */ int use_cached_ptt; /*<! flag instructing rig_get_ptt to use cached values when asyncio is in use */ int depth; /*<! a depth counter to use for debug indentation and such */ + int lock_mode; /*<! flag that prevents mode changes if ~= 0 -- see set/get_lock_mode */ }; //! @cond Doxygen_Suppress diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index f79e58b5..6a551de6 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -252,6 +252,8 @@ declare_proto_rig(set_clock); declare_proto_rig(get_clock); declare_proto_rig(set_separator); declare_proto_rig(get_separator); +declare_proto_rig(set_lock_mode); +declare_proto_rig(get_lock_mode); /* @@ -361,7 +363,9 @@ static struct test_table test_list[] = // { 0x99, "set_password", ACTION(set_password), ARG_IN | ARG_NOVFO, "Password" }, { 0xf7, "get_mode_bandwidths", ACTION(get_mode_bandwidths), ARG_IN | ARG_NOVFO, "Mode" }, { 0xa0, "set_separator", ACTION(set_separator), ARG_IN | ARG_NOVFO, "Separator" }, - { 0xa1, "get_separator", ACTION(get_separator), ARG_OUT | ARG_NOVFO, "Separator" }, + { 0xa1, "get_separator", ACTION(get_separator), ARG_NOVFO, "Separator" }, + { 0xa2, "set_lock_mode", ACTION(set_lock_mode), ARG_IN | ARG_NOVFO, "Locked" }, + { 0xa3, "get_lock_mode", ACTION(get_lock_mode), ARG_NOVFO, "Locked" }, { 0x00, "", NULL }, }; @@ -2172,6 +2176,7 @@ declare_proto_rig(set_mode) mode = rig_parse_mode(arg1); CHKSCN1ARG(sscanf(arg2, "%ld", &width)); + if (rig->state.lock_mode) RETURNFUNC(RIG_OK); RETURNFUNC(rig_set_mode(rig, vfo, mode, width)); } @@ -5208,3 +5213,23 @@ declare_proto_rig(get_separator) fprintf(fout, "%s\n", buf); return RIG_OK; } + +/* '0xa2' */ +declare_proto_rig(set_lock_mode) +{ + int lock; + CHKSCN1ARG(sscanf(arg1, "%d", &lock)); + rig->state.lock_mode = lock != 0; + return RIG_OK; +} +/* '0xa3' */ +declare_proto_rig(get_lock_mode) +{ + if ((interactive && prompt) || (interactive && !prompt && ext_resp)) + { + fprintf(fout, "%s: ", cmd->arg1); + } + + fprintf(fout, "%d\n", rig->state.lock_mode); + return RIG_OK; +} commit 3eab223a472f38bfc1cd8e816bf94a4d622bd628 Merge: 83508b5e 5400b6d1 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 28 15:22:02 2022 -0500 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit 83508b5e38d56596797beea5a5204ad6738c310a Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 28 15:21:22 2022 -0500 Add send_morse to TS-890S https://github.com/Hamlib/Hamlib/issues/1043 diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index f92fa4aa..c73066ff 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -241,7 +241,7 @@ const struct rig_caps ts890s_caps = RIG_MODEL(RIG_MODEL_TS890S), .model_name = "TS-890S", .mfg_name = "Kenwood", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -375,6 +375,7 @@ const struct rig_caps ts890s_caps = .reset = kenwood_reset, .set_ant = kenwood_set_ant, .get_ant = kenwood_get_ant, + .send_morse = kenwood_send_morse, .scan = kenwood_scan, /* not working, invalid arguments using rigctl; kenwood_scan does only support on/off and not tone and CTCSS scan */ .has_set_level = TS890_LEVEL_ALL, .has_get_level = TS890_LEVEL_ALL, commit 5400b6d1ee779f3127a78f25d97302b6f42b2711 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 28 15:21:22 2022 -0500 Add send_morse to TS-890S diff --git a/rigs/kenwood/ts890s.c b/rigs/kenwood/ts890s.c index f92fa4aa..c73066ff 100644 --- a/rigs/kenwood/ts890s.c +++ b/rigs/kenwood/ts890s.c @@ -241,7 +241,7 @@ const struct rig_caps ts890s_caps = RIG_MODEL(RIG_MODEL_TS890S), .model_name = "TS-890S", .mfg_name = "Kenwood", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -375,6 +375,7 @@ const struct rig_caps ts890s_caps = .reset = kenwood_reset, .set_ant = kenwood_set_ant, .get_ant = kenwood_get_ant, + .send_morse = kenwood_send_morse, .scan = kenwood_scan, /* not working, invalid arguments using rigctl; kenwood_scan does only support on/off and not tone and CTCSS scan */ .has_set_level = TS890_LEVEL_ALL, .has_get_level = TS890_LEVEL_ALL, commit b50fe3b7b2007b64767b6d3a57be777845b6a45a Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 28 15:21:10 2022 -0500 Improved debug msg in sprintflst.c diff --git a/src/sprintflst.c b/src/sprintflst.c index bac0831e..549af7ad 100644 --- a/src/sprintflst.c +++ b/src/sprintflst.c @@ -41,7 +41,7 @@ int check_buffer_overflow(char *str, int len, int nlen) { if (len + 32 >= nlen) // make sure at least 32 bytes are available { - rig_debug(RIG_DEBUG_ERR, "%s: buffer overflow, len=%u, nlen=%d, str='%s'\n", + rig_debug(RIG_DEBUG_ERR, "%s: buffer overflow, len=%u, nlen=%d, str='%s', len+32 must be >= nlen\n", __func__, len, nlen, str); } commit 56260bb416536ef5ea5a6d5265310b2338bde444 Merge: d42e75ba 3f5bf2bb Author: Michael Black <mdb...@ya...> Date: Fri May 27 09:51:17 2022 -0500 Merge pull request #1042 from PianetaRadio/master Rotator GS23 Azimuth commit 3f5bf2bb2389df7c03f6ec5dba6713b988b6f829 Author: PianetaRadio <789...@us...> Date: Fri May 27 09:18:13 2022 +0200 GS23 Azimuth diff --git a/include/hamlib/rotlist.h b/include/hamlib/rotlist.h index 2bca4607..f3f3ce92 100644 --- a/include/hamlib/rotlist.h +++ b/include/hamlib/rotlist.h @@ -314,6 +314,7 @@ #define ROT_MODEL_GS232A_EL ROT_MAKE_MODEL(ROT_GS232A, 10) #define ROT_MODEL_GS232B_AZ ROT_MAKE_MODEL(ROT_GS232A, 11) #define ROT_MODEL_GS232B_EL ROT_MAKE_MODEL(ROT_GS232A, 12) +#define ROT_MODEL_GS23_AZ ROT_MAKE_MODEL(ROT_GS232A, 13) /** commit 4544214c3a831258ada5d3e4f87408d7fcc2dadb Author: PianetaRadio <789...@us...> Date: Fri May 27 09:13:18 2022 +0200 GS23 Azimuth diff --git a/rotators/gs232a/gs232a.c b/rotators/gs232a/gs232a.c index 4aa2c7fd..6bdaf008 100644 --- a/rotators/gs232a/gs232a.c +++ b/rotators/gs232a/gs232a.c @@ -422,6 +422,51 @@ const struct rot_caps gs23_rot_caps = .set_level = gs232a_rot_set_level, }; + +/* ************************************************************************* */ +/* + * Generic GS23 azimuth rotator capabilities. + */ + +const struct rot_caps gs23_az_rot_caps = +{ + ROT_MODEL(ROT_MODEL_GS23_AZ), + .model_name = "GS-23 azimuth", + .mfg_name = "Yaesu/Kenpro", + .version = "20220527.0", + .copyright = "LGPL", + .status = RIG_STATUS_STABLE, + .rot_type = ROT_TYPE_AZIMUTH, + .port_type = RIG_PORT_SERIAL, + .serial_rate_min = 150, + .serial_rate_max = 9600, + .serial_data_bits = 8, + .serial_stop_bits = 1, + .serial_parity = RIG_PARITY_NONE, + .serial_handshake = RIG_HANDSHAKE_NONE, + .write_delay = 0, + .post_write_delay = 50, + .timeout = 400, + .retry = 3, + + .min_az = -180.0, + .max_az = 450.0, /* vary according to rotator type */ + .min_el = 0.0, + .max_el = 0.0, + + .has_get_level = GS232A_LEVELS, + .has_set_level = ROT_LEVEL_SET(GS232A_LEVELS), + + .level_gran = { [ROT_LVL_SPEED] = { .min = { .i = 1 }, .max = { .i = 4 }, .step = { .i = 1 } } }, + + .rot_init = gs232a_rot_init, + .get_position = gs232a_rot_get_position, + .set_position = gs232a_rot_set_position, + .stop = gs232a_rot_stop, + .get_level = gs232a_rot_get_level, + .set_level = gs232a_rot_set_level, +}; + /* ************************************************************************* */ /* * Generic GS232 rotator capabilities. commit d529881cdb2cb24cb0d9883b967524f45dc189f4 Author: PianetaRadio <789...@us...> Date: Fri May 27 09:08:28 2022 +0200 GS23 Azimuth only diff --git a/rotators/gs232a/gs232a.h b/rotators/gs232a/gs232a.h index 681fbc85..47f1d2d9 100644 --- a/rotators/gs232a/gs232a.h +++ b/rotators/gs232a/gs232a.h @@ -31,6 +31,7 @@ extern const struct rot_caps gs232b_az_rot_caps; extern const struct rot_caps gs232b_el_rot_caps; extern const struct rot_caps f1tetracker_rot_caps; extern const struct rot_caps gs23_rot_caps; +extern const struct rot_caps gs23_az_rot_caps; extern const struct rot_caps gs232_rot_caps; extern const struct rot_caps amsat_lvb_rot_caps; extern const struct rot_caps st2_rot_caps; commit d42e75bac65898900cb59b2d8e5671a212eb52b6 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu May 26 08:25:39 2022 -0500 Avoid deadlock in add2debugmsgsave diff --git a/src/rig.c b/src/rig.c index 43e218da..ed3aacaa 100644 --- a/src/rig.c +++ b/src/rig.c @@ -328,6 +328,7 @@ void add2debugmsgsave(const char *s) char *p; char stmp[DEBUGMSGSAVE_SIZE]; int i, nlines; + int maxmsg = DEBUGMSGSAVE_SIZE/2; MUTEX_LOCK(debugmsgsave); memset(stmp, 0, sizeof(stmp)); p = debugmsgsave; @@ -342,7 +343,7 @@ void add2debugmsgsave(const char *s) // strip the last 19 lines p = debugmsgsave; - while ((nlines > 19 || strlen(debugmsgsave) > 2048) && p != NULL) + while ((nlines > 19 || strlen(debugmsgsave) > maxmsg) && p != NULL) { p = strchr(debugmsgsave, '\n'); @@ -360,6 +361,7 @@ void add2debugmsgsave(const char *s) } --nlines; + if (nlines == 0 && strlen(debugmsgsave) > maxmsg) strcpy(debugmsgsave,"!!!!debugmsgsave too long\n"); } if (strlen(stmp) + strlen(s) + 1 < DEBUGMSGSAVE_SIZE) commit 0d46e5b92ec03c3ffcd7fcb04e01b4115d353120 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed May 25 11:55:14 2022 -0500 Fix check_buffer_overlow for rig_set_ant diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 7e75fbaa..f79e58b5 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -4487,7 +4487,7 @@ declare_proto_rig(get_ant) int status; ant_t ant, ant_curr, ant_tx, ant_rx; value_t option; - char antbuf[32]; + char antbuf[64]; ENTERFUNC; commit 8cc4d59cbb06871838c0c41e2491de9f85449a82 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed May 25 10:48:16 2022 -0500 Change rig->caps-retry to rig->state.rigport.retry https://github.com/Hamlib/Hamlib/issues/1037 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 01451981..b87f5d98 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -5387,11 +5387,11 @@ int icom_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq) subcmd = 0x00; } - retry_save = rig->caps->retry; - rig->caps->retry = 1; + retry_save = rig->state.rigport.retry; + rig->state.rigport.retry = 1; retval = icom_transaction(rig, cmd, subcmd, freqbuf, freq_len, ackbuf, &ack_len); - rig->caps->retry = retry_save; + rig->state.rigport.retry = retry_save; if (retval == RIG_OK) // then we're done!! { diff --git a/rigs/kenwood/ic10.c b/rigs/kenwood/ic10.c index 0fd0f6ef..9285f793 100644 --- a/rigs/kenwood/ic10.c +++ b/rigs/kenwood/ic10.c @@ -155,7 +155,7 @@ static int get_ic10_if(RIG *rig, char *data) rig_debug(RIG_DEBUG_TRACE, "%s: called\n", __func__); - for (i = 0; retval != RIG_OK && i < rig->caps->retry; i++) + for (i = 0; retval != RIG_OK && i < rig->state.rigport.retry; i++) { data_len = 37; retval = ic10_transaction(rig, "IF;", 3, data, &data_len); commit 0b73daa4d80ea6ec03b0c5483512899604d9623f Author: Mike Black W9MDB <mdb...@ya...> Date: Wed May 25 07:59:43 2022 -0500 Fix FT650 detection in ft847.c diff --git a/rigs/yaesu/ft847.c b/rigs/yaesu/ft847.c index 8786efb7..b21d147c 100644 --- a/rigs/yaesu/ft847.c +++ b/rigs/yaesu/ft847.c @@ -324,7 +324,7 @@ static const yaesu_cmd_set_t ncmd[] = * Receiver caps */ - +#define UNIDIRECTIONAL (rig->caps->rig_model == RIG_MODEL_FT847UNI || rig->caps->rig_model == RIG_MODEL_FT650) #define FT847_ALL_RX_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_FM) #define FT847_SSB_CW_RX_MODES (RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB) #define FT847_AM_FM_RX_MODES (RIG_MODE_AM|RIG_MODE_FM) @@ -365,6 +365,16 @@ static tone_t ft847_ctcss_list[] = 1862, 1928, 2035, 2107, 2181, 2257, 2336, 2418, 2503, 0 }; +#if 0 +static tone_t ft650_ctcss_list[] = +{ + 670, 719, 744, 770, 797, 825, 854, 885, 915, + 948, 974, 1000, 1035, 1072, 1109, 1148, 1188, 1230, 1273, + 1318, 1365, 1413, 1462, 1514, 1567, 1622, 1679, 1738, 1799, + 1862, 1928, 2035, 2107, 2181, 2257, 2336, 2418, 2503, + 0 +}; +#endif /* @@ -377,7 +387,7 @@ const struct rig_caps ft847_caps = RIG_MODEL(RIG_MODEL_FT847), .model_name = "FT-847", .mfg_name = "Yaesu", - .version = "20210221.0", + .version = "20220525.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -532,7 +542,7 @@ const struct rig_caps ft650_caps = RIG_MODEL(RIG_MODEL_FT650), .model_name = "FT-650", .mfg_name = "Yaesu", - .version = "20220524.0", + .version = "20220525.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -558,7 +568,7 @@ const struct rig_caps ft650_caps = .has_set_parm = RIG_PARM_NONE, .level_gran = {}, /* granularity */ .parm_gran = {}, - .ctcss_list = ft847_ctcss_list, + //.ctcss_list = ft847_ctcss_list, .preamp = { RIG_DBLST_END, }, /* no preamp/att in CAT */ .attenuator = { RIG_DBLST_END, }, .max_rit = Hz(0), @@ -662,7 +672,7 @@ const struct rig_caps mchfqrp_caps = RIG_MODEL(RIG_MODEL_MCHFQRP), .model_name = "mcHF QRP", .mfg_name = "M0NKA", - .version = "20211103.0", + .version = "20220525.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1173,7 +1183,7 @@ static int ft847_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_debug(RIG_DEBUG_VERBOSE, fmt, __func__, (int64_t)from_bcd_be(p_cmd, 8) * 10); - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { struct ft847_priv_data *priv = (struct ft847_priv_data *)rig->state.priv; @@ -1216,7 +1226,7 @@ static int get_freq_and_mode(RIG *rig, vfo_t vfo, freq_t *freq, rmode_t *mode, rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo =%s \n", __func__, rig_strvfo(vfo)); - if (rig->caps->rig_model == RIG_MODEL_FT847UNI || rig->caps->rig_model == RIG_MODEL_FT650) + if (UNIDIRECTIONAL) { if (vfo == RIG_VFO_MAIN) { @@ -1345,7 +1355,7 @@ static int ft847_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) rig_debug(RIG_DEBUG_VERBOSE, "%s: generic mode = %s\n", __func__, rig_strrmode(mode)); - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { struct ft847_priv_data *priv = (struct ft847_priv_data *)rig->state.priv; priv->mode = mode; @@ -1540,7 +1550,7 @@ static int ft847_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) rig_debug(RIG_DEBUG_VERBOSE, "%s: called \n", __func__); - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { struct ft847_priv_data *priv = (struct ft847_priv_data *)rig->state.priv; priv->ptt = ptt; @@ -1575,7 +1585,7 @@ static int ft847_get_status(RIG *rig, int status_ci) int len; int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1628,7 +1638,7 @@ static int ft847_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt) struct ft847_priv_data *p = (struct ft847_priv_data *) rig->state.priv; int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { struct ft847_priv_data *priv = (struct ft847_priv_data *)rig->state.priv; *ptt = priv->ptt; @@ -1662,7 +1672,7 @@ static int ft847_get_dcd(RIG *rig, vfo_t vfo, dcd_t *dcd) struct ft847_priv_data *p = (struct ft847_priv_data *) rig->state.priv; int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1691,7 +1701,7 @@ static int ft847_get_rawstr_level(RIG *rig, value_t *val) struct ft847_priv_data *p = (struct ft847_priv_data *) rig->state.priv; int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1718,7 +1728,7 @@ static int ft847_get_smeter_level(RIG *rig, value_t *val) { int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1763,7 +1773,7 @@ static int ft847_get_alc_level(RIG *rig, value_t *val) struct ft847_priv_data *p = (struct ft847_priv_data *) rig->state.priv; int n; - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1791,7 +1801,7 @@ static int ft847_get_alc_level(RIG *rig, value_t *val) */ static int ft847_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) { - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } @@ -1953,7 +1963,7 @@ static int ft847_set_rptr_offs(RIG *rig, vfo_t vfo, shortfreq_t rptr_offs) { unsigned char p_cmd[YAESU_CMD_LENGTH]; /* sequence to send */ - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (UNIDIRECTIONAL) { return -RIG_ENIMPL; } commit 7ce07c09ad7151fc925ed2a18141ffbe7947b304 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 24 08:17:55 2022 -0500 Update NEWS diff --git a/NEWS b/NEWS index 9369dadf..4ff04807 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,7 @@ Version 4.6 Version 4.5 * 2022-05-XX + * Add FT-650 * Add get_separator and set_separator and -S option for rigctld -- node-red applicability * Add GRBLTRK rotor project -- two axis rotor * enum meter_level_e is deprecated and will be removed in 4.6 commit 76103ec19956554973c1759657046ae5c9ef75d0 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 24 07:59:35 2022 -0500 Update some FT-650 capabilities diff --git a/rigs/yaesu/ft847.c b/rigs/yaesu/ft847.c index f9383e0b..8786efb7 100644 --- a/rigs/yaesu/ft847.c +++ b/rigs/yaesu/ft847.c @@ -552,8 +552,8 @@ const struct rig_caps ft650_caps = .has_get_func = RIG_FUNC_NONE, .has_set_func = FT847_FUNC_ALL, - .has_get_level = FT847_LEVEL_ALL, - .has_set_level = RIG_LEVEL_BAND_SELECT, + //.has_get_level = FT847_LEVEL_ALL, + //.has_set_level = RIG_LEVEL_BAND_SELECT, .has_get_parm = RIG_PARM_NONE, .has_set_parm = RIG_PARM_NONE, .level_gran = {}, /* granularity */ @@ -564,7 +564,7 @@ const struct rig_caps ft650_caps = .max_rit = Hz(0), .max_xit = Hz(0), .max_ifshift = Hz(0), - .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_TONE | RIG_TARGETABLE_FUNC, + //.targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_TONE | RIG_TARGETABLE_FUNC, .transceive = RIG_TRN_OFF, .bank_qty = 0, .chan_desc_sz = 0, @@ -613,8 +613,13 @@ const struct rig_caps ft650_caps = /* mode/filter list, .remember = order matters! */ .filters = { - {RIG_MODE_SSB | RIG_MODE_CW | RIG_MODE_CWR, kHz(2.2)}, - {RIG_MODE_CW | RIG_MODE_CWR, Hz(500)}, + {RIG_MODE_SSB | RIG_MODE_CW, kHz(2.4)}, + {RIG_MODE_SSB, kHz(2.2)}, + {RIG_MODE_SSB, kHz(2.0)}, + {RIG_MODE_SSB, kHz(1.8)}, + {RIG_MODE_CW, Hz(1200)}, + {RIG_MODE_CW, Hz(600)}, + {RIG_MODE_CW, Hz(300)}, {RIG_MODE_AM, kHz(9)}, {RIG_MODE_AM, kHz(2.2)}, {RIG_MODE_FM, kHz(15)}, @@ -632,23 +637,23 @@ const struct rig_caps ft650_caps = .get_freq = ft847_get_freq, /* get freq */ .set_mode = ft847_set_mode, /* set mode */ .get_mode = ft847_get_mode, /* get mode */ - .set_split_vfo = ft847_set_split_vfo, - .get_split_vfo = ft847_get_split_vfo, - .set_split_freq = ft847_set_split_freq, - .get_split_freq = ft847_get_split_freq, - .set_split_mode = ft847_set_split_mode, - .get_split_mode = ft847_get_split_mode, +// .set_split_vfo = ft847_set_split_vfo, +// .get_split_vfo = ft847_get_split_vfo, +// .set_split_freq = ft847_set_split_freq, +// .get_split_freq = ft847_get_split_freq, +// .set_split_mode = ft847_set_split_mode, +// .get_split_mode = ft847_get_split_mode, .set_ptt = ft847_set_ptt, /* set ptt */ .get_ptt = ft847_get_ptt, /* get ptt */ - .get_dcd = ft847_get_dcd, /* get dcd */ - .get_level = ft847_get_level, /* get level */ +// .get_dcd = ft847_get_dcd, /* get dcd */ +// .get_level = ft847_get_level, /* get level */ .set_func = ft847_set_func, .set_ctcss_tone = ft847_set_ctcss_tone, - .set_ctcss_sql = ft847_set_ctcss_sql, - .set_dcs_sql = ft847_set_dcs_sql, - .set_rptr_shift = ft847_set_rptr_shift, - .set_rptr_offs = ft847_set_rptr_offs, +// .set_ctcss_sql = ft847_set_ctcss_sql, +// .set_dcs_sql = ft847_set_dcs_sql, +// .set_rptr_shift = ft847_set_rptr_shift, +// .set_rptr_offs = ft847_set_rptr_offs, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; commit fe7c465624b7dc1e3c47c0892cf97562000d7469 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 24 07:43:50 2022 -0500 Add FT-650 rig -- same as FT847UNI diff --git a/include/hamlib/riglist.h b/include/hamlib/riglist.h index a1df7a82..771182a8 100644 --- a/include/hamlib/riglist.h +++ b/include/hamlib/riglist.h @@ -124,6 +124,7 @@ #define RIG_MODEL_FTDX101MP RIG_MAKE_MODEL(RIG_YAESU, 44) #define RIG_MODEL_MCHFQRP RIG_MAKE_MODEL(RIG_YAESU, 45) #define RIG_MODEL_FT450D RIG_MAKE_MODEL(RIG_YAESU, 46) +#define RIG_MODEL_FT650 RIG_MAKE_MODEL(RIG_YAESU, 47) /* diff --git a/rigs/yaesu/ft847.c b/rigs/yaesu/ft847.c index 9e2262a4..f9383e0b 100644 --- a/rigs/yaesu/ft847.c +++ b/rigs/yaesu/ft847.c @@ -368,9 +368,8 @@ static tone_t ft847_ctcss_list[] = /* - * ft847 rigs capabilities. + * ft847 rig capabilities. * Notice that some rigs share the same functions. - * Also this struct is READONLY! */ const struct rig_caps ft847_caps = @@ -523,6 +522,136 @@ const struct rig_caps ft847_caps = .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; +/* + * ft600 rigs capabilities. + * Notice that some rigs share the same functions. + */ + +const struct rig_caps ft650_caps = +{ + RIG_MODEL(RIG_MODEL_FT650), + .model_name = "FT-650", + .mfg_name = "Yaesu", + .version = "20220524.0", + .copyright = "LGPL", + .status = RIG_STATUS_STABLE, + .rig_type = RIG_TYPE_TRANSCEIVER, + .ptt_type = RIG_PTT_RIG, + .dcd_type = RIG_DCD_RIG, + .port_type = RIG_PORT_SERIAL, + .serial_rate_min = 4800, + .serial_rate_max = 4800, + .serial_data_bits = 8, + .serial_stop_bits = 2, + .serial_parity = RIG_PARITY_NONE, + .serial_handshake = RIG_HANDSHAKE_NONE, + .write_delay = FT847_WRITE_DELAY, + .post_write_delay = FT847_POST_WRITE_DELAY, + .timeout = 1000, + .retry = 0, + + .has_get_func = RIG_FUNC_NONE, + .has_set_func = FT847_FUNC_ALL, + .has_get_level = FT847_LEVEL_ALL, + .has_set_level = RIG_LEVEL_BAND_SELECT, + .has_get_parm = RIG_PARM_NONE, + .has_set_parm = RIG_PARM_NONE, + .level_gran = {}, /* granularity */ + .parm_gran = {}, + .ctcss_list = ft847_ctcss_list, + .preamp = { RIG_DBLST_END, }, /* no preamp/att in CAT */ + .attenuator = { RIG_DBLST_END, }, + .max_rit = Hz(0), + .max_xit = Hz(0), + .max_ifshift = Hz(0), + .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE | RIG_TARGETABLE_TONE | RIG_TARGETABLE_FUNC, + .transceive = RIG_TRN_OFF, + .bank_qty = 0, + .chan_desc_sz = 0, + + .chan_list = { RIG_CHAN_END, }, /* FIXME: memory chan list: 78, but only in clonable mode? */ + + .rx_range_list1 = { + {MHz(24.5), MHz(56), FT847_ALL_RX_MODES, -1, -1, FT847_VFOS, FT847_ANTS, "EUR"}, + RIG_FRNG_END, + }, /* rx range end */ + + .tx_range_list1 = { + FRQ_RNG_HF(1, FT847_OTHER_TX_MODES, W(5), W(100), FT847_VFOS, FT847_ANTS), + FRQ_RNG_HF(1, FT847_AM_TX_MODES, W(1), W(25), FT847_VFOS, FT847_ANTS), + + FRQ_RNG_6m(1, FT847_OTHER_TX_MODES, W(5), W(100), FT847_VFOS, FT847_ANTS), + FRQ_RNG_6m(1, FT847_AM_TX_MODES, W(1), W(25), FT847_VFOS, FT847_ANTS), + + FRQ_RNG_4m(1, FT847_OTHER_TX_MODES, W(1), W(50), FT847_VFOS, FT847_ANTS), + FRQ_RNG_4m(1, FT847_AM_TX_MODES, W(1), W(12.5), FT847_VFOS, FT847_ANTS), + + FRQ_RNG_2m(1, FT847_OTHER_TX_MODES, W(1), W(50), FT847_VFOS, FT847_ANTS), + FRQ_RNG_2m(1, FT847_AM_TX_MODES, W(1), W(12.5), FT847_VFOS, FT847_ANTS), + + FRQ_RNG_70cm(1, FT847_OTHER_TX_MODES, W(1), W(50), FT847_VFOS, FT847_ANTS), + FRQ_RNG_70cm(1, FT847_AM_TX_MODES, W(1), W(12.5), FT847_VFOS, FT847_ANTS), + + RIG_FRNG_END, + }, /* tx range end */ + + .rx_range_list2 = { + {MHz(24.5), MHz(56), FT847_ALL_RX_MODES, -1, -1, FT847_VFOS, FT847_ANTS, "USA"}, + + RIG_FRNG_END, + }, /* rx range end */ + + .tx_range_list2 = { + {kHz(24500),kHz(25000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(24500),kHz(25000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(28000),kHz(29700), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(28000),kHz(29700), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(50000),kHz(54000), FT847_OTHER_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + {kHz(50000),kHz(54000), FT847_AM_TX_MODES, W(10), W(100), FT847_VFOS, FT847_ANTS}, + RIG_FRNG_END, + }, /* tx range end */ + + /* mode/filter list, .remember = order matters! */ + .filters = { + {RIG_MODE_SSB | RIG_MODE_CW | RIG_MODE_CWR, kHz(2.2)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(500)}, + {RIG_MODE_AM, kHz(9)}, + {RIG_MODE_AM, kHz(2.2)}, + {RIG_MODE_FM, kHz(15)}, + {RIG_MODE_FM, kHz(9)}, + RIG_FLT_END, + }, + + .priv = NULL, + .rig_init = ft847_init, + .rig_cleanup = ft847_cleanup, + .rig_open = ft847_open, + .rig_close = ft847_close, + + .set_freq = ft847_set_freq, /* set freq */ + .get_freq = ft847_get_freq, /* get freq */ + .set_mode = ft847_set_mode, /* set mode */ + .get_mode = ft847_get_mode, /* get mode */ + .set_split_vfo = ft847_set_split_vfo, + .get_split_vfo = ft847_get_split_vfo, + .set_split_freq = ft847_set_split_freq, + .get_split_freq = ft847_get_split_freq, + .set_split_mode = ft847_set_split_mode, + .get_split_mode = ft847_get_split_mode, + .set_ptt = ft847_set_ptt, /* set ptt */ + .get_ptt = ft847_get_ptt, /* get ptt */ + .get_dcd = ft847_get_dcd, /* get dcd */ + .get_level = ft847_get_level, /* get level */ + + .set_func = ft847_set_func, + .set_ctcss_tone = ft847_set_ctcss_tone, + .set_ctcss_sql = ft847_set_ctcss_sql, + .set_dcs_sql = ft847_set_dcs_sql, + .set_rptr_shift = ft847_set_rptr_shift, + .set_rptr_offs = ft847_set_rptr_offs, + .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS +}; + const struct rig_caps mchfqrp_caps = { RIG_MODEL(RIG_MODEL_MCHFQRP), @@ -1082,7 +1211,7 @@ static int get_freq_and_mode(RIG *rig, vfo_t vfo, freq_t *freq, rmode_t *mode, rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo =%s \n", __func__, rig_strvfo(vfo)); - if (rig->caps->rig_model == RIG_MODEL_FT847UNI) + if (rig->caps->rig_model == RIG_MODEL_FT847UNI || rig->caps->rig_model == RIG_MODEL_FT650) { if (vfo == RIG_VFO_MAIN) { diff --git a/rigs/yaesu/yaesu.c b/rigs/yaesu/yaesu.c index 1ff2c91f..ffe3061a 100644 --- a/rigs/yaesu/yaesu.c +++ b/rigs/yaesu/yaesu.c @@ -119,6 +119,7 @@ DECLARE_INITRIG_BACKEND(yaesu) rig_register(&ft897d_caps); rig_register(&ftdx101mp_caps); rig_register(&mchfqrp_caps); + rig_register(&ft650_caps); return RIG_OK; } diff --git a/rigs/yaesu/yaesu.h b/rigs/yaesu/yaesu.h index 66e96aba..2674fa88 100644 --- a/rigs/yaesu/yaesu.h +++ b/rigs/yaesu/yaesu.h @@ -87,5 +87,6 @@ extern const struct rig_caps ft818_caps; extern const struct rig_caps ftdx10_caps; extern const struct rig_caps ftdx101mp_caps; extern const struct rig_caps mchfqrp_caps; +extern const struct rig_caps ft650_caps; #endif /* _YAESU_H */ commit 6b76701efca61afbaebabed100ceda2b4c333dc1 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 23 11:44:19 2022 -0500 Put mutex in add2debugmsgsave diff --git a/src/rig.c b/src/rig.c index ca6c35c2..43e218da 100644 --- a/src/rig.c +++ b/src/rig.c @@ -160,6 +160,16 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */ #define LOCK \ +#ifdef PTHREAD +#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 + /* * Data structure to track the opened rig (by rig_open) */ @@ -311,11 +321,14 @@ char debugmsgsave[DEBUGMSGSAVE_SIZE] = ""; char debugmsgsave2[DEBUGMSGSAVE_SIZE] = ""; char debugmsgsave3[DEBUGMSGSAVE_SIZE] = ""; +MUTEX(debugmsgsave); + void add2debugmsgsave(const char *s) { char *p; char stmp[DEBUGMSGSAVE_SIZE]; int i, nlines; + MUTEX_LOCK(debugmsgsave); memset(stmp, 0, sizeof(stmp)); p = debugmsgsave; @@ -359,6 +372,7 @@ void add2debugmsgsave(const char *s) "%s: debugmsgsave overflow!! len of debugmsgsave=%d, len of add=%d\n", __func__, (int)strlen(debugmsgsave), (int)strlen(s)); } + MUTEX_UNLOCK(debugmsgsave); } /** @@ -6885,16 +6899,6 @@ const char *HAMLIB_API rig_copyright() return hamlib_copyright2; } -#ifdef PTHREAD -#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 - /** * \brief get a cookie to grab rig control * \param rig Not used commit 52736df8b8820929d39e4397db979e48493388bc Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 23 11:40:05 2022 -0500 Fix spelling error diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 1c66d018..8354ec80 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -1401,6 +1401,7 @@ struct filter_list { #define RIG_FLT_ANY 0 #define RIG_FLT_END {RIG_MODE_NONE, 0} #define RIG_IS_FLT_END(f) ((f).modes == RIG_MODE_NONE) +#define DEBUGMSGSAVE_SIZE 24000 //! @endcond @@ -3272,8 +3273,7 @@ rig_need_debug HAMLIB_PARAMS((enum rig_debug_level_e debug_level)); extern HAMLIB_EXPORT(void)add2debugmsgsave(const char *s); -// this need to be fairly big to avoid compiler warnings -#define DEBUGMSGSAVE_SIZE 24000 +// this needs to be fairly big to avoid compiler warnings extern HAMLIB_EXPORT_VAR(char) debugmsgsave[DEBUGMSGSAVE_SIZE]; // last debug msg extern HAMLIB_EXPORT_VAR(char) debugmsgsave2[DEBUGMSGSAVE_SIZE]; // last-1 debug msg // debugmsgsave3 is deprecated commit c8b2322018d0d5d6e69164ec613b5de3f26e73b1 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 23 10:41:16 2022 -0500 Try to fix random seg fault in add2debugmsgsave diff --git a/src/rig... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-05-18 08:46:43
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 468dd151102ef94d71c071b1acf736b65cc727ff (commit) via a0cb833548de747eafc7d22c3cf3258645277eaf (commit) via 21a2190e7f7a1294324ec5c4a649051ba4f9c325 (commit) via da28af73e64e2a2b219babddb13b9f02efb028fe (commit) via d89bc3df4ffb51c41e1033d7c54da9f188fec568 (commit) via 59211b6a5881285a0dc2070f25ddb1cfbbe520a8 (commit) via bdd7ffdda19064bbe3467a91f9ecdf407034452d (commit) via a0321ba25f1b7073736cbb631427b53f70b32df6 (commit) via 72f38f02d1010c570a2b1bf3791f535e8abdbc8a (commit) via e9fb733dae0e7acb2897850787ebbdcf2520e37c (commit) via 17539bb68adabb1f8e08247a87f6c2042345699b (commit) via 0849172dc55f2768ee17bad8d8708fcaf65189d3 (commit) via 4d8e64acfe6996071feaf2d166ec0c8611278320 (commit) via ecd78e73542b283f9f691d5da0bafd9920941883 (commit) via 4c2ab11c561ef3e9d745a883081f6aac3077a659 (commit) via 82a915563b0f9ba3f2c22caa63bee84b9c6d27c9 (commit) via d54f5a1c34fc7a5714f86d5a785fe7851caea820 (commit) via a518bdcaf1043cfe8c47c39ff38c31cab4de5227 (commit) via 3892bc41dc87dc8ff3a55097e1354f1edb4e9709 (commit) via f16988d3638ddc9487171dcf2bc3f88fd489d888 (commit) via 51cbf4af7ab7b73e7efe5213024c35865934cc91 (commit) via 67a7a613a0f42c97d48230528d4f0227bdbfe2d0 (commit) via cb8b7c185c80d1fcf4687df3689f25ab7df6879d (commit) via 6f9d057162a448a891016fc86606ecdfc33fc50b (commit) via 2f638a10bf77e4d3c4c28ecfd168cdbf18535d30 (commit) via 81d0c3c768b23b2c3e73e5df5165ce3a4f833dde (commit) via 3096ad8b6801063d095a9136e858aa1c0f0cd8a1 (commit) via d0fa5d7776e8451f144652f92d848ea0858d279e (commit) via 80043d437c8a05958452fdd3f82a4d15c08ad6c9 (commit) via c63a71601a314925e79550abf72cc4c7e993004f (commit) via 49cbc18e198132ba72e647058778d49a15c3173d (commit) via 066978ed15d27c995f23946f4c2adf4a5889cddd (commit) via ed1f0a22dcd131df70dda2954fec829e5f53e661 (commit) via cc73447d7c5961e4932dd274da623123adeff531 (commit) via 4bf2a8a2b84a0737131766ac0adea164710a17fb (commit) via 10635407654c4c0db493d25ec9d5985912e4cc70 (commit) via 3a569fcde1f0fe1fdaf7f0e80f561313f8307c5d (commit) via 2aa8d4b675531c46d7fdcd424f396a9a908410c8 (commit) via 11ffd603abd7f1acf3239090d2597c8a77ccf11c (commit) via 45208df8c61795c02b0ce802f2304c2fafff4746 (commit) via 1f5f80805793a917a84422528625b3e75c62bc06 (commit) via 6ad3ace7263ba98b5c8320ac518d9c718fce0bef (commit) via 71407bbf1da8b2a4bde40b45a8bb5a3ac20953ef (commit) via 019faf3b6a63d6f044d2761dc5239ff5703afad4 (commit) via a22787393f98fda919b7a43140b8d5f0084a87ce (commit) via e76cd714549bf46a04fc7dc28e1c81f3187cda9d (commit) via af8b0d57e91bf8cdbc938330b702970bf6e5e04f (commit) via c107fd4af31981da573ecb586b702cd006e9a5fd (commit) via 8865bf6c66e795e2fa290e8b0329c6d4e10ad0d4 (commit) via 434d28cd9a87c6dcf89b59f5c5e5434d87101ca7 (commit) via 22d40093275c254cb5fe122786475dd1e26822c8 (commit) via e4d7dbf24cbeeb1eddfef9ee77797c880c29c13c (commit) via e9d9cb9eabdd4b3af4a125c282230a260cb17bb1 (commit) via ab499d31eb357cebb988232d346d847d6e2f47a6 (commit) via 1dd915a7066b16607f6407b08f206aa7505ed867 (commit) via e661642a7d5f094813d10e211079ec3d6fbedd98 (commit) via f0f96dd5ce54734e52d5d033fb103874ccc5f8ed (commit) via f0c84aa33887146f980bef423898eaa436b091ae (commit) via 80fb97b433a6bcd13591866b3aed640e2be88a0a (commit) via ddf0be7b72a7e797c5cde12fec7d6a7883a5254d (commit) via ca53b02dcdeca0f8c174d292ac89675e7c138c10 (commit) via 4fa9a211adbcb1ae9329db41c27854af70f39d64 (commit) via c774a05be43622c21b28e19a7432e58737678dab (commit) via 4d919ec4546f2eb2ee15f04ce93b789824d20c4a (commit) via 9dfbd235af43e3cce4dc26ed75545493f1473ee4 (commit) via 279bc84dfee648e8e3e248e211007400b82cfe44 (commit) via 6cc4aefdb0f8823f4965d6bf600865d75caf88cc (commit) via c0d298f0eb9087ea72c4d271bef4f0247fb4ed4f (commit) via 5259102cf1b58a57ecc9e67c5b96855f35cdb28c (commit) via 24c7a0042a992c5bc6f3ec65581c9acb7abf1367 (commit) via a0796552901a984a0e1f79afb67cddd0a63a572c (commit) via 8bf1e7c649ac10f7672e0b99d854bde772458b83 (commit) via cc7d9cd78da4982a0d913fc0cf5d00793d4e0976 (commit) via d60391fcb08f9969c9956a95b74da00818a662e0 (commit) via b30db5bc594c5ec5af6df6d19d1e211c169c4882 (commit) via 8cfa1f2f7d14b665ce6b5c6a248840259b69f0e8 (commit) via e3bf699732327d8d640ce7ae5920af19058d5e7b (commit) via 704a6aac4b703f7b3802d640cd24f5386bac050a (commit) via e4bd3c8edecb104495af8d8fc3b62f33b51186fa (commit) via f0469e48a77491171f53d8091ed99a80e3bc4ef0 (commit) via 3a4d99dd7730a9057440a44df2350ecd24498d05 (commit) via 9d73fa737d0fff47e6af7ba9454527d5f0241621 (commit) via 4ecf274353d9e05ffb2e31a3a6ba320d01c5c7ab (commit) via 9d952e6d09989d3594c3d0378b3a144dc6221b57 (commit) via 428ca4a196d6b50032495e120671ed92d4b1fce4 (commit) via 1b64214032e441c1302fd1ec55ea892fce83bbca (commit) via 19c17eb5ba52e729eec15f8d0556eefd251a9565 (commit) via 79180089a64f7cf3acc62bc532052fb0a5444267 (commit) via f35e2d8c34d3ea7ac4fb4572916efb0ed642ce6b (commit) via 157eead0213c5aaac20c51308cb418061862cd32 (commit) via 5cce47e23322aac3f5dd198cda6611d85f29fc29 (commit) via f9c0758e1425272ff078414e61c22d298d0b319a (commit) via 829b632984f7e67cc8e4420951687c4424758281 (commit) via 56efa155dc0bfdcfa042690ac5780d9c5777f67b (commit) via 0b62193d92e1969af809e4a1127d1b2f118e0d5a (commit) via 5c0e98fe5693a28854f5a9968afe67609586ce58 (commit) via d7da44a3b5e1d7f2330f5be45047ed05af744d9a (commit) via 4b64d5f7c37882c6bddcaad82be8c7b3dd0aace4 (commit) via e1c2a08789f9f18ffd0b930f52bb62a33db5c31a (commit) via 5c1ed109a962dd1f1abec81651adeb6f809aca33 (commit) via 533ad321d4f457770fda1f7110be63368788e7d4 (commit) via 15795d8366356ffbe8cc39af054399cdcf096b5a (commit) via 244738fcc93dc812b347339bacbb2c73072199c4 (commit) via a975d734ba44e152c6ef95c75da418593e5cfa8e (commit) via e05d04046065999a30c58c1786a92a5ad59dd0f3 (commit) via 3529c789a8d06afac3325608885d7aeb9d01f11b (commit) via c8faa7a9150825b18f24dcffe86e926a2f649b3b (commit) via 6ad344034107374485ee043e9695b5d304e045f3 (commit) from c76dc1453d963334968ab9879caceb180021f12b (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 468dd151102ef94d71c071b1acf736b65cc727ff Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 17:03:48 2022 -0500 Update simkenwood.c diff --git a/simulators/simkenwood.c b/simulators/simkenwood.c index ec1e9dc3..89c9e107 100644 --- a/simulators/simkenwood.c +++ b/simulators/simkenwood.c @@ -14,6 +14,7 @@ float freqA = 14074000; float freqB = 14074500; int filternum = 7; int datamode = 0; +int ptt, ptt_data, ptt_mic, ptt_tune; // ID 0310 == 310, Must drop leading zero typedef enum nc_rigid_e @@ -260,6 +261,18 @@ int main(int argc, char *argv[]) { continue; } + else if (strncmp(buf, "TX", 2) == 0) + { + ptt = ptt_mic = ptt_data = ptt_tune = 0; + switch(buf[2]) + { + case ';': ptt = 1; + case '0': ptt_mic = 1; + case '1': ptt_data = 1; + case '2': ptt_tune = 1; + } + continue; + } else if (strlen(buf) > 0) { fprintf(stderr, "Unknown command: %s\n", buf); commit a0cb833548de747eafc7d22c3cf3258645277eaf Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 17:03:22 2022 -0500 Update simicom.c diff --git a/simulators/simicom.c b/simulators/simicom.c index d99d65b8..93e96346 100644 --- a/simulators/simicom.c +++ b/simulators/simicom.c @@ -15,6 +15,7 @@ #include "../src/misc.h" #define BUFSIZE 256 +#define X25 int civ_731_mode = 0; vfo_t current_vfo = RIG_VFO_A; @@ -25,6 +26,7 @@ float freqA = 14074000; float freqB = 14074500; mode_t modeA = RIG_MODE_CW; mode_t modeB = RIG_MODE_USB; +int datamode = 0; pbwidth_t widthA = 0; pbwidth_t widthB = 1; ant_t ant_curr = 0; @@ -250,7 +252,7 @@ void frameParse(int fd, unsigned char *frame, int len) break; -#if 1 +#ifdef X25 case 0x25: if (frame[6] == 0xfd) @@ -281,6 +283,18 @@ void frameParse(int fd, unsigned char *frame, int len) frame[5] = 0xfd; } + break; + case 0x26: + for(int i=0;i<6;++i) printf("%02x:",frame[i]); + if (frame[6] == 0xfd) // then a query + { + frame[6] = frame[5] == 0? modeA : modeB; + frame[7] = datamode; + frame[8] = 0xfb; + frame[9] = 0xfd; + write(fd, frame, 10); + } + printf("\n"); break; #else @@ -288,6 +302,10 @@ void frameParse(int fd, unsigned char *frame, int len) frame[4] = 0xfa; frame[5] = 0xfd; break; + case 0x26: + frame[4] = 0xfa; + frame[5] = 0xfd; + break; #endif default: printf("cmd 0x%02x unknown\n", frame[4]); @@ -353,6 +371,11 @@ int main(int argc, char **argv) int fd = openPort(argv[1]); printf("%s: %s\n", argv[0], rig_version()); +#ifdef X25 + printf("x25/x26 command recognized\n"); +#else + printf("x25/x26 command rejected\n"); +#endif #if defined(WIN32) || defined(_WIN32) if (argc != 2) commit 21a2190e7f7a1294324ec5c4a649051ba4f9c325 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 16:19:36 2022 -0500 Update simyaesu.c diff --git a/simulators/simyaesu.c b/simulators/simyaesu.c index 612f4fd9..8e5c2e73 100644 --- a/simulators/simyaesu.c +++ b/simulators/simyaesu.c @@ -17,9 +17,12 @@ char rx_vfo = '0'; vfo_t curr_vfo = RIG_VFO_A; char modeA = '1'; char modeB = '1'; -int width = 0; int ptt; int power = 1; +int roofing_filter_main = 1; +int roofing_filter_sub = 6; +int width_main = 0; +int width_sub = 0; // ID 0310 == 310, Must drop leading zero typedef enum nc_rigid_e @@ -354,19 +357,54 @@ int main(int argc, char *argv[]) if (n < 0) { perror("EX032"); } } + else if (strcmp(buf, "NA0;") == 0) + { + SNPRINTF(buf, sizeof(buf), "NA00;"); + usleep(50 * 1000); + n = write(fd, buf, strlen(buf)); + //printf("%s n=%d\n", buf, n); + } + else if (strcmp(buf, "RF0;") == 0) + { + SNPRINTF(buf, sizeof(buf), "RF0%d;", roofing_filter_main); + usleep(50 * 1000); + n = write(fd, buf, strlen(buf)); + } + else if (strcmp(buf, "RF1;") == 0) + { + SNPRINTF(buf, sizeof(buf), "RF1%d;", roofing_filter_sub); + usleep(50 * 1000); + n = write(fd, buf, strlen(buf)); + } + else if (strncmp(buf, "RF", 2) == 0) + { + SNPRINTF(buf, sizeof(buf), "RF%c%d;", buf[2], buf[2]==0?roofing_filter_main:roofing_filter_sub); + usleep(50 * 1000); + n = write(fd, buf, strlen(buf)); + } else if (strcmp(buf, "SH0;") == 0) { - SNPRINTF(buf, sizeof(buf), "SH0%02d;", width); + SNPRINTF(buf, sizeof(buf), "SH%c%02d;", buf[2], width_main); usleep(50 * 1000); n = write(fd, buf, strlen(buf)); - printf("%s n=%d\n", buf, n); } - else if (strcmp(buf, "NA0;") == 0) + else if (strcmp(buf, "SH1;") == 0) { - SNPRINTF(buf, sizeof(buf), "NA00;"); + SNPRINTF(buf, sizeof(buf), "SH%c%02d;", buf[2], width_sub); usleep(50 * 1000); n = write(fd, buf, strlen(buf)); - //printf("%s n=%d\n", buf, n); + } + else if (strncmp(buf, "SH",2) == 0 && strlen(buf) > 4) + { + int vfo, twidth; + sscanf(buf,"SH%1d%d", &vfo, &twidth); + if (vfo == 0) width_main = twidth; + else width_sub = twidth; + printf("width_main=%d, width_sub=%d\n", width_main, width_sub); + } + else if (strncmp(buf, "SH",2) == 0) + { + SNPRINTF(buf, sizeof(buf), "SH%c%02d;", buf[2], buf[2]==0?width_main:width_sub); } else if (strlen(buf) > 0) commit da28af73e64e2a2b219babddb13b9f02efb028fe Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 09:10:40 2022 -0500 Update informatino for GRBLTRK rotor diff --git a/NEWS b/NEWS index 7871bc04..3526578d 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,7 @@ Version 4.6 Version 4.5 * 2022-05-XX + * Add GRBLTRK rotor project -- two axis rotor * enum meter_level_e is deprecated and will be removed in 4.6 * Add SDRPlay SDRUno rig -- can now use Data/Pkt in WSJTX * Add ability to use cat_string to FLRig via the "w" and "W" commands diff --git a/rotators/grbltrk/README.txt b/rotators/grbltrk/README.txt new file mode 100644 index 00000000..873e6d6c --- /dev/null +++ b/rotators/grbltrk/README.txt @@ -0,0 +1,2 @@ +More information at +https://github.com/wuxx/AntRunner commit d89bc3df4ffb51c41e1033d7c54da9f188fec568 Merge: 59211b6a e9fb733d Author: Michael Black <mdb...@ya...> Date: Tue May 17 08:14:48 2022 -0500 Merge pull request #1032 from wuxx/master add new rotator grbltrk commit 59211b6a5881285a0dc2070f25ddb1cfbbe520a8 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 07:49:44 2022 -0500 Fix mode=NONE in rig_set_mode diff --git a/src/rig.c b/src/rig.c index 1d78b95e..d0af7a0e 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2105,8 +2105,11 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) RETURNFUNC2(-RIG_ENAVAIL); } - if (vfo == RIG_VFO_CURR) { vfo = rig->state.current_vfo; } - else if (mode == RIG_MODE_NONE) // the we just use the current mode to set width + if (vfo == RIG_VFO_CURR) + { + vfo = rig->state.current_vfo; + } + if (mode == RIG_MODE_NONE) // the we just use the current mode to set width { pbwidth_t twidth; rig_get_mode(rig, vfo, &mode, &twidth); commit bdd7ffdda19064bbe3467a91f9ecdf407034452d Merge: a0321ba2 72f38f02 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 07:42:23 2022 -0500 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit a0321ba25f1b7073736cbb631427b53f70b32df6 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 06:39:10 2022 -0500 Add ability to set mode only with rig_set_mode by using Mode=NONE diff --git a/src/rig.c b/src/rig.c index 99a269c1..1d78b95e 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2106,6 +2106,11 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) } if (vfo == RIG_VFO_CURR) { vfo = rig->state.current_vfo; } + else if (mode == RIG_MODE_NONE) // the we just use the current mode to set width + { + pbwidth_t twidth; + rig_get_mode(rig, vfo, &mode, &twidth); + } vfo = vfo_fixup(rig, vfo, rig->state.cache.split); commit 72f38f02d1010c570a2b1bf3791f535e8abdbc8a Author: Mike Black W9MDB <mdb...@ya...> Date: Tue May 17 06:39:10 2022 -0500 Add ability to set mode only with rig_set_mode by using VFO=NONE diff --git a/src/rig.c b/src/rig.c index 99a269c1..1d78b95e 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2106,6 +2106,11 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) } if (vfo == RIG_VFO_CURR) { vfo = rig->state.current_vfo; } + else if (mode == RIG_MODE_NONE) // the we just use the current mode to set width + { + pbwidth_t twidth; + rig_get_mode(rig, vfo, &mode, &twidth); + } vfo = vfo_fixup(rig, vfo, rig->state.cache.split); commit e9fb733dae0e7acb2897850787ebbdcf2520e37c Author: wuxx <wuj...@gm...> Date: Tue May 17 13:23:44 2022 +0800 add new rotator grbltrk Changes to be committed: modified: Android.mk modified: configure.ac modified: include/hamlib/rotlist.h new file: rotators/grbltrk/Android.mk new file: rotators/grbltrk/Makefile.am new file: rotators/grbltrk/grbltrk.c modified: src/rot_reg.c diff --git a/Android.mk b/Android.mk index fd6cb4dc..1abfacca 100644 --- a/Android.mk +++ b/Android.mk @@ -34,6 +34,7 @@ include $(TOP_PATH)/rotators/amsat/Android.mk include $(TOP_PATH)/rotators/ars/Android.mk include $(TOP_PATH)/rotators/celestron/Android.mk include $(TOP_PATH)/rotators/cnctrk/Android.mk +include $(TOP_PATH)/rotators/grbltrk/Android.mk include $(TOP_PATH)/rotators/easycomm/Android.mk include $(TOP_PATH)/rotators/ether6/Android.mk include $(TOP_PATH)/rotators/fodtrack/Android.mk diff --git a/configure.ac b/configure.ac index ab6e120f..5a6250ff 100644 --- a/configure.ac +++ b/configure.ac @@ -48,7 +48,7 @@ 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" -ROT_BACKEND_LIST="rotators/amsat rotators/ars rotators/celestron rotators/cnctrk 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" +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" # Amplifiers are all in the amplifiers directory AMP_BACKEND_LIST="amplifiers/elecraft" @@ -831,6 +831,7 @@ rotators/amsat/Makefile rotators/ars/Makefile rotators/celestron/Makefile rotators/cnctrk/Makefile +rotators/grbltrk/Makefile rotators/easycomm/Makefile rotators/ether6/Makefile rotators/fodtrack/Makefile diff --git a/include/hamlib/rotlist.h b/include/hamlib/rotlist.h index 522d4acb..2bca4607 100644 --- a/include/hamlib/rotlist.h +++ b/include/hamlib/rotlist.h @@ -623,6 +623,20 @@ #define ROT_BACKEND_ANDROIDSENSOR "androidsensor" #define ROT_MODEL_ANDROIDSENSOR ROT_MAKE_MODEL(ROT_ANDROIDSENSOR, 1) +/** + * \brief A macro that returns the model number of the GRBLTRK backend. + * + * \def ROT_MODEL_GRBLTRK + * + * The GRBLTRK backend can be used with rotators that support the GRBL + * protocol. + */ +//! @cond Doxygen_Suppress +#define ROT_GRBLTRK 24 +#define ROT_BACKEND_GRBLTRK "grbltrk" +//! @endcond +#define ROT_MODEL_GRBLTRK_SER ROT_MAKE_MODEL(ROT_GRBLTRK, 1) +#define ROT_MODEL_GRBLTRK_NET ROT_MAKE_MODEL(ROT_GRBLTRK, 2) /** * \brief Convenience type definition for a rotator model. diff --git a/rotators/grbltrk/Android.mk b/rotators/grbltrk/Android.mk new file mode 100755 index 00000000..89978259 --- /dev/null +++ b/rotators/grbltrk/Android.mk @@ -0,0 +1,12 @@ +LOCAL_PATH:= $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := grbltrk.c +LOCAL_MODULE := grbltrk + +LOCAL_CFLAGS := -DHAVE_CONFIG_H +LOCAL_C_INCLUDES := android include src +LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi + +include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/grbltrk/Makefile.am b/rotators/grbltrk/Makefile.am new file mode 100755 index 00000000..fbd33aa5 --- /dev/null +++ b/rotators/grbltrk/Makefile.am @@ -0,0 +1,5 @@ + +noinst_LTLIBRARIES = libhamlib-grbltrk.la +libhamlib_grbltrk_la_SOURCES = grbltrk.c + +EXTRA_DIST = Android.mk diff --git a/rotators/grbltrk/grbltrk.c b/rotators/grbltrk/grbltrk.c new file mode 100755 index 00000000..00142361 --- /dev/null +++ b/rotators/grbltrk/grbltrk.c @@ -0,0 +1,564 @@ +/* + * Hamlib Rotator backend - LinuxCNC no hardware port + * Copyright (c) 2015 by Robert Freeman + * Adapted from AMSAT code by Stephane Fillod + * + * 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 + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include <math.h> +#include <stdlib.h> +#include <string.h> /* String function definitions */ +#include <unistd.h> /* UNIX standard function definitions */ + +#ifdef HAVE_SYS_IOCTL_H +#include <sys/ioctl.h> +#endif + +#include "hamlib/rotator.h" +#include "hamlib/rig.h" + +#include "misc.h" +#include "serial.h" +#include "token.h" +#include "network.h" + +#include "register.h" + +#define RSIZE (1024) + +#define XDEGREE2MM(d) ((d)/9.0) + +// 42-gear-22 +#define YDEGREE2MM(d) ((d)/9.0) + +//#define YDEGREE2MM(d) ((d) * ((1710) / (77*9))) +//#define YDEGREE2MM(d) ((d) * ((190) / (77))) + +/* + +$0=10 (step pulse, usec) +$1=25 (step idle delay, msec) +$2=0 (step port invert mask:00000000) +$3=0 (dir port invert mask:00000000) +$4=0 (step enable invert, bool) +$5=0 (limit pins invert, bool) +$6=0 (probe pin invert, bool) +$10=3 (status report mask:00000011) +$11=0.010 (junction deviation, mm) +$12=0.002 (arc tolerance, mm) +$13=0 (report inches, bool) +$20=0 (soft limits, bool) +$21=0 (hard limits, bool) +$22=0 (homing cycle, bool) +$23=0 (homing dir invert mask:00000000) +$24=25.000 (homing feed, mm/min) +$25=500.000 (homing seek, mm/min) +$26=250 (homing debounce, msec) +$27=1.000 (homing pull-off, mm) +$30=1000. (rpm max) +$31=0. (rpm min) +$32=0 (motor lock bool) +$33=7 (motor mode mask:00000111) +$100=80.000 (x, step/mm) +$101=80.000 (y, step/mm) +$102=80.000 (z, step/mm) +$110=10000.000 (x max rate, mm/min) +$111=10000.000 (y max rate, mm/min) +$112=10000.000 (z max rate, mm/min) +$120=250.000 (x accel, mm/sec^2) +$121=250.000 (y accel, mm/sec^2) +$122=250.000 (z accel, mm/sec^2) +$130=500.000 (x max travel, mm) +$131=500.000 (y max travel, mm) +$132=500.000 (z max travel, mm) + +*/ + +char *grbl_get_config = "$$\r\n"; +char *grbl_get_pos = "?\r\n"; + +char *grbl_init_list[] = +{ + "$1=255\r\n", /* lock motors */ + "$3=3\r\n", /* invert X and Y direction */ + //"$100=80\r\n", /* axis-x a4988 16 microstep */ + "$100=1776\r\n", /* axis-x a4988 16 microstep 42-gear-motor-22-(1710/77) (80*1710)/77 */ + //"$101=160\n", /* axis-y drv8825 32 microstep */ + //"$101=80\n", /* axis-y a4988 16 microstep */ + "$101=1776\r\n", /* axis-y a4988 16 microstep 42-gear-motor-22-(1710/77) (80*1710)/77 */ + "$110=50\r\n", + "$111=50\r\n", + "$120=25\r\n", + "$121=25\r\n", + "G90\r\n", + "G0 X0 Y0\r\n", +}; + +static int +grbl_request(ROT *rot, char *request, uint32_t req_size, char *response, uint32_t *resp_size) +{ + int retval; + static int fail_count = 0; + + rot_debug(RIG_DEBUG_ERR, "req: [%s][%d]\n", request, fail_count); + + if (rot->caps->rot_model == ROT_MODEL_GRBLTRK_SER + || rot->caps->rot_model == ROT_MODEL_GRBLTRK_NET) { + //fprintf(stderr, "ctrl by serial/network\n"); + + if ((retval = write_block(&rot->state.rotport, (unsigned char *)request, req_size)) != RIG_OK) { + rot_debug(RIG_DEBUG_ERR, "%s write_block fail!\n", __func__); + //exit(-1); + fail_count++; + //return RIG_EIO; + } else { + fail_count = 0; + } + + rig_flush(&rot->state.rotport); + + usleep(300000); + if ((retval = read_string(&rot->state.rotport, (unsigned char *)response, 1024, "\n", 1, 0, 1)) < 0) { + rot_debug(RIG_DEBUG_ERR, "%s read_string fail! (%d) \n", __func__, retval); + //exit(-1); + fail_count++; + //return RIG_EIO; + } else { + fail_count = 0; + } + + if (fail_count >= 10) { + rot_debug(RIG_DEBUG_ERR, "%s too much xfer fail! exit\n", __func__); + exit(-1); + } + + rig_flush(&rot->state.rotport); + + rot_debug(RIG_DEBUG_ERR, "rsp: [%s]\n", response); + //fprintf(stderr, "rsp: [%s]\n", response); + + *resp_size = retval; + + } + + return RIG_OK; +} + +static int +grbl_init(ROT *rot) +{ + int i, retval; + uint32_t init_count; + char rsp[RSIZE]; + uint32_t resp_size; + + /* get total config */ + grbl_request(rot, grbl_get_config, strlen(grbl_get_config), rsp, &resp_size); + if (strstr(rsp, grbl_init_list[0]) != NULL) { + rot_debug(RIG_DEBUG_ERR, "%s: grbl already configured\n", __func__); + return RIG_OK; + } + + init_count = sizeof(grbl_init_list) / sizeof(grbl_init_list[0]); + + for(i = 0; i < init_count; i++) { + rot_debug(RIG_DEBUG_ERR, "grbl_request [%s] ", grbl_init_list[i]); + retval = grbl_request(rot, grbl_init_list[i], strlen(grbl_init_list[i]), rsp, &resp_size); + //fprintf(stderr, "done\n"); + if (retval != RIG_OK) { + rot_debug(RIG_DEBUG_ERR, "grbl_request [%s] fail\n", grbl_init_list[i]); + return RIG_EIO; + } + } + + return RIG_OK; +} + +static int +grbltrk_rot_set_position(ROT *rot, azimuth_t curr_az, elevation_t curr_el) +{ + int i; + int retval; + static float prev_az, prev_el; + + static float prev_x, curr_x; + float x[3], delta[3]; + + float y; + + char req[RSIZE] = {0}; + char rsp[RSIZE] = {0}; + uint32_t rsp_size; + + float min_value; + int min_index; + + /* az:x: 0 - 360 */ + /* el:y: 0 - 90 */ + rot_debug(RIG_DEBUG_ERR, + "%s: (prev_x) = (%.3f); (prev_az) = (%.3f); (prev_el) = (%.3f); (curr_az, curr_el) = (%.3f, %.3f)\n", __func__, + prev_x, prev_az, prev_el, curr_az, curr_el); + + /* convert degree to mm, 360 degree = 40mm, 1 degree = 0.111mm */ + //x = az * 0.111; + //y = el * 0.111; + + /* 360 -> 0 */ + if ((prev_az > 270 && prev_az < 360) && + (curr_az > 0 && curr_az < 90 )) { + + rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + if (prev_x >= XDEGREE2MM(270)) { + curr_x = XDEGREE2MM(curr_az) + XDEGREE2MM(360); + } else { + curr_x = XDEGREE2MM(curr_az); + } + /* 0 -> 360 */ + } else if ((prev_az > 0 && prev_az < 90 ) && + (curr_az > 270 && curr_az < 360)) { + rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + + if (prev_x >= XDEGREE2MM(360)) { + curr_x = XDEGREE2MM(curr_az); + } else { + curr_x = XDEGREE2MM(curr_az) - XDEGREE2MM(360); + } + + /* reset */ + } else if (curr_az == 0 && curr_el == 0) { + rot_debug(RIG_DEBUG_ERR, "%s: reset\n", __func__); + curr_x = 0; + } else { + rot_debug(RIG_DEBUG_ERR, "%s:%d prev_x: %.3f\n", __func__, __LINE__, prev_x); + + x[0] = XDEGREE2MM(curr_az) - XDEGREE2MM(360); + x[1] = XDEGREE2MM(curr_az); + x[2] = XDEGREE2MM(curr_az) + XDEGREE2MM(360); + + delta[0] = prev_x - x[0]; + delta[1] = prev_x - x[1]; + delta[2] = prev_x - x[2]; + + if (delta[0] < 0) { delta[0] = -1 * delta[0]; } + if (delta[1] < 0) { delta[1] = -1 * delta[1]; } + if (delta[2] < 0) { delta[2] = -1 * delta[2]; } + + min_value = delta[0]; + min_index = 0; + + for(i = 0; i < 3; i++) { + if (delta[i] <= min_value) { + min_value = delta[i]; + min_index = i; + } + } + + curr_x = x[min_index]; + rot_debug(RIG_DEBUG_ERR, "min_index: %d; curr_x: %.3f\n", min_index, curr_x); + } + + y = YDEGREE2MM(curr_el); + + /**/ + + snprintf(req, sizeof(req), "G0 X%.3f Y%.3f\n", curr_x, y); + + retval = grbl_request(rot, req, strlen(req), rsp, &rsp_size); + + if (retval != RIG_OK) + { + return retval; + } + + prev_az = curr_az; + prev_el = curr_el; + + prev_x = curr_x; + return RIG_OK; + +} + +static int +grbltrk_rot_get_position(ROT *rot, azimuth_t *az, elevation_t *el) +{ + + //static char req[RSIZE]; + static char rsp[RSIZE]; + uint32_t rsp_size; + + float mpos[3]; + char dummy0[256]; + char dummy1[256]; + + int retval; + int i; + + rot_debug(RIG_DEBUG_ERR, "%s called\n", __func__); + + //snprintf(req, sizeof(req), "?\r\n"); + + for(i = 0; i < 5; i++) { + retval = grbl_request(rot, grbl_get_pos, strlen(grbl_get_pos), rsp, &rsp_size); + + /*FIXME: X Y safe check */ + + if (retval != RIG_OK) + { + return retval; + } + + if (strstr(rsp, "MPos") == NULL) { + rot_debug(RIG_DEBUG_ERR, "%s no MPos found, continue\n", __func__); + continue; + } + + /* grbl 0.9 mega328p */ + /* <Idle,MPos:0.000,0.000,0.000,WPos:0.000,0.000,0.000,SC:0> */ + //sscanf(rsp, "%[^','],MPos:%f,%f,%f,WPos:%f,%f,%f,%s", &dummy[0], &mpos[0], &mpos[1], &mpos[2], &wpos[0], &wpos[1], &wpos[2], &dummy[1]); + + /* grbl 1.3a esp32 */ + //<Idle|MPos:0.000,0.000,0.000|FS:0,0|Pn:P|WCO:5.000,0.000,0.000> + sscanf(rsp, "%[^'|']|MPos:%f,%f,%s", dummy0, &mpos[0], &mpos[1], dummy1); + + //rot_debug(RIG_DEBUG_ERR, "%s: (%.3f, %.3f) (%.3f, %.3f)\n", __func__, mpos[0], mpos[1], wpos[0], wpos[1]); + + //*az = (azimuth_t) mpos[0] / 0.111; + //*el = (elevation_t) mpos[1] / 0.111; + *az = (azimuth_t) mpos[0] * 9; + *el = (elevation_t) mpos[1] * 9; + + if ((*az) < 0) { + (*az) = (*az) + 360; + } + + //rot_debug(RIG_DEBUG_ERR, "%s: (az, el) = (%.3f, %.3f)\n", __func__, *az, *el); + + rot_debug(RIG_DEBUG_ERR, "%s: (az, el) = (%.3f, %.3f)\n", __func__, *az, *el); + + return RIG_OK; + + } + + *az = (azimuth_t) 0; + *el = (elevation_t) 0; + return RIG_OK; +} + +static int +grbltrk_rot_set_conf(ROT *rot, token_t token, const char *val) +{ + int i, retval; + char req[RSIZE] = {0}; + char rsp[RSIZE]; + uint32_t resp_size, len; + + rot_debug(RIG_DEBUG_ERR, "token: %ld; value: [%s]\n", token, val); + + len = strlen(val); + + if ((len != 0) && (val[0] == 'G')) { + + for(i = 0; i < len; i++) { + + if (val[i] == '@') { + req[i] = ' '; + } else { + req[i] = val[i]; + } + } + + req[i] = '\n'; + len = strlen(req); + + rot_debug(RIG_DEBUG_ERR, "send gcode [%s]\n", req); + retval = grbl_request(rot, req, len, rsp, &resp_size); + if (retval < 0) { + rot_debug(RIG_DEBUG_ERR, "grbl_request [%s] fail\n", val); + return RIG_EIO; + } + } + + return RIG_OK; +} + +static int +grbltrk_rot_init(ROT *rot) +{ + int r = RIG_OK; + + rot_debug(RIG_DEBUG_ERR, "%s:%d rot->caps->rot_model: %d\n", __func__, __LINE__, rot->caps->rot_model); + + return r; +} + +static int +grbl_net_open(ROT *rot, int port) +{ + //network_open(&rot->state.rotport, port); + + //rot_debug(RIG_DEBUG_ERR, "%s:%d network_fd: %d\n", __func__, __LINE__, (&rot->state.rotport)->fd); + rot_debug(RIG_DEBUG_ERR, "%s:%d \n", __func__, __LINE__); + + return 0; +} + +static int +grbltrk_rot_open(ROT *rot) +{ + int r = RIG_OK; + char host[128] = {0}; + //char ip[32]; + //int port; + + //rot_debug(RIG_DEBUG_ERR, "%s:%d rot->caps->rot_model: %d\n", __func__, __LINE__, rot->caps->rot_model); + if (rot->caps->rot_model == ROT_MODEL_GRBLTRK_SER) { + rot_debug(RIG_DEBUG_ERR, "%s:%d ctrl via serial\n", __func__, __LINE__); + } else if (rot->caps->rot_model == ROT_MODEL_GRBLTRK_NET) { + rot_get_conf(rot, TOK_PATHNAME, host); + rot_debug(RIG_DEBUG_ERR, "%s:%d ctrl via net, host [%s]\n", __func__, __LINE__, host); + grbl_net_open(rot, 23); + +#if 0 + if (sscanf(host, "%[^:]:%d", ip, &port) == 2) { + grbl_net_open(rot, ip, port); + } else { + grbl_net_open(rot, NULL, 0); /* use default ip & port */ + } +#endif + + } + + grbl_init(rot); + + //rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + + return r; +} + +static void +grbl_net_close(ROT *rot) +{ + port_close(&rot->state.rotport, RIG_PORT_NETWORK); +} + +static int +grbltrk_rot_close(ROT *rot) +{ + int r = RIG_OK; + + if (rot->caps->rot_model == ROT_MODEL_GRBLTRK_SER) { + rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + } else if (rot->caps->rot_model == ROT_MODEL_GRBLTRK_NET) { + rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + grbl_net_close(rot); + } + + rot_debug(RIG_DEBUG_ERR, "%s:%d\n", __func__, __LINE__); + + return r; +} + + +/** CNCTRK implements essentially only the set position function. + it assumes there is a LinuxCNC running with the Axis GUI */ +const struct rot_caps grbltrk_serial_rot_caps = +{ + ROT_MODEL(ROT_MODEL_GRBLTRK_SER), + .model_name = "GRBLTRK via Serial", + .mfg_name = "BG5DIW", + .version = "20220515.0", + .copyright = "LGPL", + .status = RIG_STATUS_BETA, + .rot_type = ROT_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 = 400, + .retry = 0, + + + .min_az = 0, + .max_az = 360, + .min_el = 0, + .max_el = 90, + + .rot_init = grbltrk_rot_init, + .rot_open = grbltrk_rot_open, + + .set_position = grbltrk_rot_set_position, + .get_position = grbltrk_rot_get_position, + .set_conf = grbltrk_rot_set_conf, +}; + +const struct rot_caps grbltrk_net_rot_caps = +{ + ROT_MODEL(ROT_MODEL_GRBLTRK_NET), + .model_name = "GRBLTRK via Net", + .mfg_name = "BG5DIW", + .version = "20220515.0", + .copyright = "LGPL", + .status = RIG_STATUS_BETA, + .rot_type = ROT_TYPE_OTHER, + .port_type = RIG_PORT_NETWORK, /* RIG_PORT_NONE */ + //.port_type = RIG_PORT_NONE, /* RIG_PORT_NONE */ + + .write_delay = 0, + .post_write_delay = 0, + .timeout = 300, + .retry = 0, + //.retry = 3, + + + .min_az = 0, + .max_az = 360, + .min_el = 0, + .max_el = 90, + + .rot_init = grbltrk_rot_init, + .rot_open = grbltrk_rot_open, + .rot_close = grbltrk_rot_close, + + .set_position = grbltrk_rot_set_position, + .get_position = grbltrk_rot_get_position, + .set_conf = grbltrk_rot_set_conf, +}; + + +/* ************************************************************************* */ + +DECLARE_INITROT_BACKEND(grbltrk) +{ + rig_debug(RIG_DEBUG_VERBOSE, "%s: _init called\n", __func__); + + //rot_debug(RIG_DEBUG_ERR, "%s: _init called\n", __func__); + + rot_register(&grbltrk_serial_rot_caps); + + rot_register(&grbltrk_net_rot_caps); + + return RIG_OK; +} diff --git a/src/rot_reg.c b/src/rot_reg.c index 1300b36b..aeebf322 100644 --- a/src/rot_reg.c +++ b/src/rot_reg.c @@ -90,6 +90,7 @@ DEFINE_INITROT_BACKEND(indi); #if defined(ANDROID) || defined(__ANDROID__) DEFINE_INITROT_BACKEND(androidsensor); #endif +DEFINE_INITROT_BACKEND(grbltrk); //! @endcond /** @@ -137,6 +138,7 @@ static struct #if defined(ANDROID) || defined(__ANDROID__) { ROT_ANDROIDSENSOR, ROT_BACKEND_ANDROIDSENSOR, ROT_FUNCNAMA(androidsensor) }, #endif + { ROT_GRBLTRK, ROT_BACKEND_GRBLTRK, ROT_FUNCNAMA(grbltrk) }, { 0, NULL }, /* end */ }; commit 17539bb68adabb1f8e08247a87f6c2042345699b Author: Mike Black W9MDB <mdb...@ya...> Date: Mon May 16 22:56:16 2022 -0500 Add VFO UP DOWN to PowerSDR diff --git a/rigs/kenwood/flex6xxx.c b/rigs/kenwood/flex6xxx.c index 01762e15..339ac430 100644 --- a/rigs/kenwood/flex6xxx.c +++ b/rigs/kenwood/flex6xxx.c @@ -42,7 +42,7 @@ #define F6K_LEVEL_ALL (RIG_LEVEL_SLOPE_HIGH|RIG_LEVEL_SLOPE_LOW|RIG_LEVEL_KEYSPD) #define F6K_VFO (RIG_VFO_A|RIG_VFO_B) -#define POWERSDR_VFO_OP (RIG_OP_BAND_UP|RIG_OP_BAND_DOWN) +#define POWERSDR_VFO_OP (RIG_OP_BAND_UP|RIG_OP_BAND_DOWN|RIG_OP_UP|RIG_OP_DOWN) #define F6K_ANTS (RIG_ANT_1|RIG_ANT_2|RIG_ANT_3) @@ -1231,7 +1231,7 @@ const struct rig_caps powersdr_caps = RIG_MODEL(RIG_MODEL_POWERSDR), .model_name = "PowerSDR/Thetis", .mfg_name = "FlexRadio/ANAN", - .version = "20220512.0", + .version = "20220516.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, commit 0849172dc55f2768ee17bad8d8708fcaf65189d3 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 22:29:43 2022 -0500 Add elapsed time to rig_vfo_op diff --git a/src/rig.c b/src/rig.c index 2ca3123c..99a269c1 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2756,6 +2756,7 @@ int HAMLIB_API rig_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) { ptt = RIG_PTT_ON; } + #endif /* fall through */ @@ -5842,6 +5843,7 @@ int HAMLIB_API rig_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op) vfo_t curr_vfo; ENTERFUNC; + ELAPSED1; if (CHECK_RIG_ARG(rig)) { @@ -5861,12 +5863,14 @@ int HAMLIB_API rig_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op) || vfo == rig->state.current_vfo) { retcode = caps->vfo_op(rig, vfo, op); + ELAPSED2; RETURNFUNC(retcode); } if (!caps->set_vfo) { rig_debug(RIG_DEBUG_WARN, "%s: no set_vfo\n", __func__); + ELAPSED2; RETURNFUNC(-RIG_ENAVAIL); } @@ -5890,6 +5894,7 @@ int HAMLIB_API rig_vfo_op(RIG *rig, vfo_t vfo, vfo_op_t op) retcode = rc2; } + ELAPSED2; RETURNFUNC(retcode); } commit 4d8e64acfe6996071feaf2d166ec0c8611278320 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 11:53:38 2022 -0500 Stop mapping MICDATA ptt to PTT -- there should be no reason to do this and it was interfering with rigctld and MICDATA rigs TS480/590/890/990 https://github.com/Hamlib/Hamlib/issues/998 diff --git a/src/rig.c b/src/rig.c index 5369d55b..2ca3123c 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2751,10 +2751,12 @@ int HAMLIB_API rig_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) switch (rig->state.pttport.type.ptt) { case RIG_PTT_RIG: +#if 0 // https://github.com/Hamlib/Hamlib/issues/998 -- this is interfering with rigctld and MICDATA rigs if (ptt == RIG_PTT_ON_MIC || ptt == RIG_PTT_ON_DATA) { ptt = RIG_PTT_ON; } +#endif /* fall through */ case RIG_PTT_RIG_MICDATA: diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 5740763f..de1aeb65 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -2448,6 +2448,7 @@ declare_proto_rig(set_ptt) CHKSCN1ARG(sscanf(arg1, "%d", &scr)); ptt = scr; + rig_debug(RIG_DEBUG_VERBOSE, "%s: set_ptt ptt=%d\n", __func__, ptt); /* * We allow RIG_PTT_ON_MIC and RIG_PTT_ON_DATA arriving from netrigctl. @@ -2462,11 +2463,16 @@ declare_proto_rig(set_ptt) case RIG_PTT_ON_MIC: case RIG_PTT_ON_DATA: + // No longer map this -- is confusing rigctld and MICDATA rigs + // https://github.com/Hamlib/Hamlib/issues/998 +#if 0 // map to a legal value - if (rig->state.pttport.type.ptt != RIG_PTT_RIG_MICDATA) + if (rig->caps->ptt_type != RIG_PTT_RIG_MICDATA) { + rig_debug(RIG_DEBUG_ERR, "%s: pttport.type.ptt=%d\n", __func__, rig->state.pttport.type.ptt); ptt = RIG_PTT_ON; } +#endif break; @@ -2482,6 +2488,7 @@ declare_proto_rig(set_ptt) RETURNFUNC(-RIG_EINVAL); } + rig_debug(RIG_DEBUG_ERR, "%s: ptt=%d\n", __func__, ptt); RETURNFUNC(rig_set_ptt(rig, vfo, ptt)); } commit ecd78e73542b283f9f691d5da0bafd9920941883 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 11:26:29 2022 -0500 Clean up simkenwood warnings diff --git a/simulators/simkenwood.c b/simulators/simkenwood.c index d31369ad..ec1e9dc3 100644 --- a/simulators/simkenwood.c +++ b/simulators/simkenwood.c @@ -199,12 +199,12 @@ int main(int argc, char *argv[]) else if (strcmp(buf, "FA;") == 0) { SNPRINTF(buf, sizeof(buf), "FA%011d;", freqa); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strcmp(buf, "FB;") == 0) { SNPRINTF(buf, sizeof(buf), "FA%011d;", freqa); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "FA", 2) == 0) { @@ -217,18 +217,18 @@ int main(int argc, char *argv[]) else if (strncmp(buf, "AI;", 3) == 0) { SNPRINTF(buf, sizeof(buf), "AI0;"); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "SA;", 3) == 0) { SNPRINTF(buf, sizeof(buf), "SA0;"); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "MD;", 3) == 0) { SNPRINTF(buf, sizeof(buf), "MD%d;", modeA); // not worried about modeB yet for simulator - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "MD", 2) == 0) { @@ -237,7 +237,7 @@ int main(int argc, char *argv[]) else if (strncmp(buf, "FL;", 3) == 0) { SNPRINTF(buf, sizeof(buf), "FL%03d;", filternum); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "FL", 2) == 0) { @@ -246,7 +246,7 @@ int main(int argc, char *argv[]) else if (strncmp(buf, "DA;", 3) == 0) { SNPRINTF(buf, sizeof(buf), "DA%d;", datamode); - write(fd, buf, strlen(buf)); + n = write(fd, buf, strlen(buf)); } else if (strncmp(buf, "DA", 2) == 0) { commit 4c2ab11c561ef3e9d745a883081f6aac3077a659 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 10:03:40 2022 -0500 Move longlat2locator and locator2longlat to rig.h from rotator.h These are more generic now than just for rotator use diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index d2ceb0fb..b6582aef 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -3391,14 +3391,14 @@ extern HAMLIB_EXPORT(int) rig_password(RIG *rig, const char *key1); extern HAMLIB_EXPORT(void) rig_password_generate_secret(char *pass, char result[HAMLIB_SECRET_LENGTH + 1]); -//extern HAMLIB_EXPORT(int) -int longlat2locator HAMLIB_PARAMS((double longitude, +extern HAMLIB_EXPORT(int) +longlat2locator HAMLIB_PARAMS((double longitude, double latitude, char *locator_res, int pair_count)); -//extern HAMLIB_EXPORT(int) -int locator2longlat HAMLIB_PARAMS((double *longitude, +extern HAMLIB_EXPORT(int) +locator2longlat HAMLIB_PARAMS((double *longitude, double *latitude, const char *locator)); diff --git a/include/hamlib/rotator.h b/include/hamlib/rotator.h index 626d63b2..7eb04012 100644 --- a/include/hamlib/rotator.h +++ b/include/hamlib/rotator.h @@ -751,6 +751,7 @@ distance_long_path HAMLIB_PARAMS((double distance)); extern HAMLIB_EXPORT(double) azimuth_long_path HAMLIB_PARAMS((double azimuth)); +#if 0 extern HAMLIB_EXPORT(int) longlat2locator HAMLIB_PARAMS((double longitude, double latitude, @@ -761,6 +762,7 @@ extern HAMLIB_EXPORT(int) locator2longlat HAMLIB_PARAMS((double *longitude, double *latitude, const char *locator)); +#endif extern HAMLIB_EXPORT(double) dms2dec HAMLIB_PARAMS((int degrees, commit 82a915563b0f9ba3f2c22caa63bee84b9c6d27c9 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 09:31:09 2022 -0500 Remove debug from barrett.c to prevent compilation warning diff --git a/rigs/barrett/barrett.c b/rigs/barrett/barrett.c index db9beec1..3e212358 100644 --- a/rigs/barrett/barrett.c +++ b/rigs/barrett/barrett.c @@ -163,8 +163,8 @@ int barrett_transaction(RIG *rig, char *cmd, int expected, char **result) strtok_r(*result, "\r", &dummy); } - rig_debug(RIG_DEBUG_VERBOSE, "%s: returning result=%s\n", __func__, - *result); + //rig_debug(RIG_DEBUG_VERBOSE, "%s: returning result=%s\n", __func__, + // *result); } else { commit d54f5a1c34fc7a5714f86d5a785fe7851caea820 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 09:17:51 2022 -0500 Speed up yaesu compilation a bit when using -j switch in make by moving yaesu.c up the list diff --git a/rigs/yaesu/Makefile.am b/rigs/yaesu/Makefile.am index ad71aec0..da537a66 100644 --- a/rigs/yaesu/Makefile.am +++ b/rigs/yaesu/Makefile.am @@ -14,6 +14,6 @@ NEWCATSRC = newcat.c newcat.h ft450.c ft450.h ft950.c ft950.h ft991.c ft991.h \ ft891.c ft891.h ftdx101.c ftdx101.h ftdx101mp.c ft3000.c ftdx10.c noinst_LTLIBRARIES = libhamlib-yaesu.la -libhamlib_yaesu_la_SOURCES = $(YAESUSRC) $(NEWCATSRC) yaesu.c yaesu.h +libhamlib_yaesu_la_SOURCES = yaesu.c yaesu.h $(YAESUSRC) $(NEWCATSRC) EXTRA_DIST = README.ft890 README.ft920 Android.mk commit a518bdcaf1043cfe8c47c39ff38c31cab4de5227 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun May 15 09:15:27 2022 -0500 Speed up icom compilation a bit when using -j switch in make by moving icom.c up the list diff --git a/rigs/icom/Makefile.am b/rigs/icom/Makefile.am index fc928be3..fbad2ffc 100644 --- a/rigs/icom/Makefile.am +++ b/rigs/icom/Makefile.am @@ -1,4 +1,4 @@ -ICOMSRC = ic706.c icr8500.c ic735.c ic775.c ic756.c \ +ICOMSRC = icom.c icom.h icom_defs.h frame.c frame.h ic706.c icr8500.c ic735.c ic775.c ic756.c \ ic275.c ic475.c ic1275.c ic820h.c ic821h.c \ icr7000.c ic910.c ic9100.c ic970.c ic725.c ic737.c ic718.c \ os535.c os456.c omni.c delta2.c ic92d.c \ @@ -9,7 +9,7 @@ ICOMSRC = ic706.c icr8500.c ic735.c ic775.c ic756.c \ ic707.c ic728.c ic751.c ic761.c \ ic78.c ic7800.c ic785x.c \ ic7000.c ic7100.c ic7200.c ic7300.c ic7600.c ic7610.c ic7700.c icf8101.c \ - icom.c icom.h icom_defs.h frame.c frame.h ic7300.h optoscan.c optoscan.h xiegu.c + ic7300.h optoscan.c optoscan.h xiegu.c noinst_LTLIBRARIES = libhamlib-icom.la libhamlib_icom_la_SOURCES = $(ICOMSRC) commit 3892bc41dc87dc8ff3a55097e1354f1edb4e9709 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 14 22:13:17 2022 -0500 Remove form feed form rigctl_parse. Did not do what we need for node-red diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 80d35390..5740763f 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -1782,7 +1782,6 @@ readline_repeat: } } } - fprintf(fout, "\f"); // add a form feed for node-red tcp request to use as end-char fflush(fout); commit f16988d3638ddc9487171dcf2bc3f88fd489d888 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat May 14 17:36:28 2022 -0500 Fix get_vfo_info prompt diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 7605cb08..80d35390 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -88,11 +88,12 @@ extern int read_history(); #define ARG_OUT3 0x20 #define ARG_IN4 0x40 #define ARG_OUT4 0x80 +#define ARG_OUT5 0x100 #define ARG_IN_LINE 0x4000 #define ARG_NOVFO 0x8000 #define ARG_IN (ARG_IN1|ARG_IN2|ARG_IN3|ARG_IN4) -#define ARG_OUT (ARG_OUT1|ARG_OUT2|ARG_OUT3|ARG_OUT4) +#define ARG_OUT (ARG_OUT1|ARG_OUT2|ARG_OUT3|ARG_OUT4|ARG_OUT5) static int chk_vfo_executed; char rigctld_password[64]; @@ -140,6 +141,7 @@ struct test_table const char *arg3; const char *arg4; const char *arg5; + const char *arg6; }; @@ -344,7 +346,7 @@ static struct test_table test_list[] = { 0x8f, "dump_state", ACTION(dump_state), ARG_OUT | ARG_NOVFO }, { 0xf0, "chk_vfo", ACTION(chk_vfo), ARG_NOVFO, "ChkVFO" }, /* rigctld only--check for VFO mode */ { 0xf2, "set_vfo_opt", ACTION(set_vfo_opt), ARG_NOVFO | ARG_IN, "Status" }, /* turn vfo option on/off */ - { 0xf3, "get_vfo_info", ACTION(get_vfo_info), ARG_NOVFO | ARG_IN1 | ARG_OUT4, "Freq", "Mode", "Width", "Split", "SatMode" }, /* get several vfo parameters at once */ + { 0xf3, "get_vfo_info", ACTION(get_vfo_info), ARG_IN1 | ARG_OUT5, "VFO", "Freq", "Mode", "Width", "Split", "SatMode" }, /* get several vfo parameters at once */ { 0xf5, "get_rig_info", ACTION(get_rig_info), ARG_NOVFO | ARG_OUT, "RigInfo" }, /* get several vfo parameters at once */ { 0xf4, "get_vfo_list", ACTION(get_vfo_list), ARG_OUT | ARG_NOVFO, "VFOs" }, { 0xf6, "get_modes", ACTION(get_modes), ARG_OUT | ARG_NOVFO, "Modes" }, @@ -1780,6 +1782,7 @@ readline_repeat: } } } + fprintf(fout, "\f"); // add a form feed for node-red tcp request to use as end-char fflush(fout); @@ -2316,11 +2319,11 @@ declare_proto_rig(get_vfo_info) if ((interactive && prompt) || (interactive && !prompt && ext_resp)) { - fprintf(fout, "%s: %.0f\n", cmd->arg1, freq); - fprintf(fout, "%s: %s\n", cmd->arg2, modestr); - fprintf(fout, "%s: %d\n", cmd->arg3, (int)width); - fprintf(fout, "%s: %d\n", cmd->arg4, (int)split); - fprintf(fout, "%s: %d\n", cmd->arg5, (int)satmode); + fprintf(fout, "%s: %.0f\n", cmd->arg2, freq); + fprintf(fout, "%s: %s\n", cmd->arg3, modestr); + fprintf(fout, "%s: %d\n", cmd->arg4, (int)width); + fprintf(fout, "%s: %d\n", cmd->arg5, (int)split); + fprintf(fout, "%s: %d\n", cmd->arg6, (int)satmode); } else { commit 51cbf4af7ab7b73e7efe5213024c35865934cc91 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri May 13 22:29:13 2022 -0500 For the FT-991 do not call get_narrow when mode is C4FM, PKTFM, or PKTFMN diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 9269c5b1..3d975a8d 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -9156,10 +9156,12 @@ int newcat_get_rx_bandwidth(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t *width) } /* end if is_ft891 */ else if (is_ft991) { - if ((narrow = get_narrow(rig, vfo)) < 0) + // some modes are fixed and can't be queried with "NA0" + if (mode != RIG_MODE_C4FM && mode != RIG_MODE_PKTFM && mode != RIG_MODE_PKTFMN && (narrow = get_narrow(rig, vfo)) < 0) { RETURNFUNC(-RIG_EPROTO); } + narrow = 0; switch (mode) { commit 67a7a613a0f42c97d48230528d4f0227bdbfe2d0 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri May 13 17:07:59 2022 -0500 Update NEWS with an async example diff --git a/NEWS b/NEWS index 964a2342..7871bc04 100644 --- a/NEWS +++ b/NEWS @@ -15,7 +15,7 @@ Version 5.x -- future Version 4.6 Version 4.5 - * 2022-04-XX + * 2022-05-XX * enum meter_level_e is deprecated and will be removed in 4.6 * Add SDRPlay SDRUno rig -- can now use Data/Pkt in WSJTX * Add ability to use cat_string to FLRig via the "w" and "W" commands @@ -29,6 +29,10 @@ Version 4.5 rigctld -A will produce a consistent shared key for any specific password that can used in \password and rig_set_password TBD The shared key can also be placed in .hamlib_settings * Asynchronous rig data output handling to support transceive and spectrum data. Mikael, OH3BHX + Example for the IC-7300 to multicast on port 20001 and provide async rig information + rigctld --port=20001 --model=3073 --serial-speed=115200 --rig-file=/dev/serial/... --set-conf=rts_state=OFF --set-conf=dtr_state=OFF --multicast-addr=224.0.0.1 --multicast-port=20001 --set-conf=async=1 + +Also, spectrum data output needs to be enabled with: \set_func SPECTRUM 1 * See new set_conf option async for some Icom rigs * Multicast UDP packet output for asynchronous data. Mikael, OH3BHX * Rig state poll routine to serve commonly used data like frequency and mode from cache. Mikael, OH3BHX commit cb8b7c185c80d1fcf4687df3689f25ab7df6879d Author: Mike Black W9MDB <mdb...@ya...> Date: Fri May 13 16:53:22 2022 -0500 Correct compile warning in settings.c https://github.com/Hamlib/Hamlib/issues/985 diff --git a/src/settings.c b/src/settings.c index abe36289..40add6a7 100644 --- a/src/settings.c +++ b/src/settings.c @@ -1113,8 +1113,9 @@ HAMLIB_EXPORT(int) rig_settings_load_all(char *settings_file) if (strcmp(s, "sharedkey") == 0) { - //sharedkey = strdup(v); - //rig_debug(RIG_DEBUG_TRACE, "%s: settings_file=%s, shared_key=%s\n", __func__, settings_file, sharedkey); + char *sharedkey = strdup(v); + rig_debug(RIG_DEBUG_TRACE, "%s: settings_file=%s, shared_key=%s\n", __func__, settings_file, sharedkey); + free(sharedkey); } } commit 6f9d057162a448a891016fc86606ecdfc33fc50b Author: Mike Black W9MDB <mdb...@ya...> Date: Fri May 13 16:50:13 2022 -0500 astyle files getting ready for release diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index d7961feb..0db6be3b 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -519,16 +519,17 @@ static int dummy_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) vfo = vfo_fixup(rig, vfo, rig->state.cache.split); - if (width == RIG_PASSBAND_NOCHANGE) { - switch(vfo) + if (width == RIG_PASSBAND_NOCHANGE) + { + switch (vfo) { case RIG_VFO_MAIN: - case RIG_VFO_A: width = priv->vfo_a.width;break; + case RIG_VFO_A: width = priv->vfo_a.width; break; case RIG_VFO_SUB: - case RIG_VFO_B: width = priv->vfo_b.width;break; + case RIG_VFO_B: width = priv->vfo_b.width; break; - case RIG_VFO_C: width = priv->vfo_c.width;break; + case RIG_VFO_C: width = priv->vfo_c.width; break; } } diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index a818d705..7e0904c5 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -806,12 +806,14 @@ static int flrig_open(RIG *rig) int v1 = 0, v2 = 0, v3 = 0, v4 = 0; sscanf(value, "%d.%d.%d.%d", &v1, &v2, &v3, &v4); char version[32]; - sprintf(version,"%03d%03d%03d%03d",v1,v2,v3,v4); + sprintf(version, "%03d%03d%03d%03d", v1, v2, v3, v4); int iversion = 0; - sscanf(version,"%d", &iversion); - rig_debug(RIG_DEBUG_VERBOSE, "%s: version='%s'=%d\n", __func__, version, iversion); + sscanf(version, "%d", &iversion); + rig_debug(RIG_DEBUG_VERBOSE, "%s: version='%s'=%d\n", __func__, version, + iversion); priv->has_verify_cmds = 0; + if (iversion >= 1003054000) // 1.3.54 or greater { priv->has_verify_cmds = 1; @@ -869,10 +871,12 @@ static int flrig_open(RIG *rig) /* see if get_bwA is available */ retval = flrig_transaction(rig, "rig.get_bwA", NULL, value, sizeof(value)); + if (retval == RIG_ENAVAIL) // must not have it { priv->has_get_bwA = 0; - rig_debug(RIG_DEBUG_VERBOSE, "%s: get_bwA is not available=%s\n", __func__, value); + rig_debug(RIG_DEBUG_VERBOSE, "%s: get_bwA is not available=%s\n", __func__, + value); } else { @@ -882,10 +886,12 @@ static int flrig_open(RIG *rig) /* see if set_bwA is available */ retval = flrig_transaction(rig, "rig.set_bwA", NULL, value, sizeof(value)); + if (retval == RIG_ENAVAIL) // must not have it { priv->has_set_bwA = 0; - rig_debug(RIG_DEBUG_VERBOSE, "%s: set_bwA is not available=%s\n", __func__, value); + rig_debug(RIG_DEBUG_VERBOSE, "%s: set_bwA is not available=%s\n", __func__, + value); } else { @@ -1520,9 +1526,13 @@ static int flrig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) width); if (vfo == RIG_VFO_A) - retval = flrig_transaction(rig, "rig.set_bwA", cmd_arg, NULL, 0); + { + retval = flrig_transaction(rig, "rig.set_bwA", cmd_arg, NULL, 0); + } else - retval = flrig_transaction(rig, "rig.set_bwB", cmd_arg, NULL, 0); + { + retval = flrig_transaction(rig, "rig.set_bwB", cmd_arg, NULL, 0); + } if (retval < 0) { @@ -2335,7 +2345,7 @@ static int flrig_get_ext_parm(RIG *rig, token_t token, value_t *val) RETURNFUNC(RIG_OK); } -HAMLIB_EXPORT(int) flrig_cat_string (RIG *rig, const char *arg) +HAMLIB_EXPORT(int) flrig_cat_string(RIG *rig, const char *arg) { int retval; char cmd_arg[MAXARGLEN]; diff --git a/rigs/dummy/netrigctl.c b/rigs/dummy/netrigctl.c index d8c55122..0c527435 100644 --- a/rigs/dummy/netrigctl.c +++ b/rigs/dummy/netrigctl.c @@ -2640,7 +2640,9 @@ int netrigctl_password(RIG *rig, const char *key1) rig_debug(RIG_DEBUG_VERBOSE, "%s: key1=%s\n", __func__, key1); SNPRINTF(cmdbuf, sizeof(cmdbuf), "\\password %s\n", key1); retval = netrigctl_transaction(rig, cmdbuf, strlen(cmdbuf), buf); - if (retval != RIG_OK) retval = -RIG_EPROTO; + + if (retval != RIG_OK) { retval = -RIG_EPROTO; } + RETURNFUNC(retval); } diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index d1acd783..01451981 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -678,12 +678,13 @@ int icom_init(RIG *rig) priv->filter = RIG_PASSBAND_NOCHANGE; priv->x25cmdfails = 0; priv->x1cx03cmdfails = 0; + // we can add rigs here that will never use the 0x25 cmd // some like the 751 don't even reject the command and have to time out if (rig->caps->rig_model == RIG_MODEL_IC706 - || rig->caps->rig_model == RIG_MODEL_IC706MKII - || rig->caps->rig_model == RIG_MODEL_IC706MKIIG - || rig->caps->rig_model == RIG_MODEL_IC751 + || rig->caps->rig_model == RIG_MODEL_IC706MKII + || rig->caps->rig_model == RIG_MODEL_IC706MKIIG + || rig->caps->rig_model == RIG_MODEL_IC751 ) { priv->x25cmdfails = 1; @@ -5366,8 +5367,8 @@ int icom_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq) // we can add rigs we kn... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-04-27 15:46:05
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via c76dc1453d963334968ab9879caceb180021f12b (commit) via def3e6fea5deacf23ea2fc7fb95e4fae3ffab5cd (commit) via a006636ee3a6c9e7d5ba5125b7e2aae2f0fcf23c (commit) via 5400d8ed01f417174f2fa3228aa7e71748bc9e6e (commit) via 7cc2550ee369b1537bd25dae18a52324dbecd96e (commit) via fbd78931925f5788985871330fb30e332297c817 (commit) via 5c61f559472f7f0048ae764e469280a21f0296e2 (commit) via 382282ba204fcf1f23274254a7c5aeae8ee64d60 (commit) via b55668e2faf750a73c082ab8b619f37a67ddb028 (commit) via 6bd9cdfda090d496c1486a706f6d6ddf7a43fa1e (commit) via d412914f96526c6420d28af8f9f9725b30ae2e14 (commit) via 6497048f288092a86edb7b9cbcd25aea9cf5fec4 (commit) via 07d2602950509c01016d0709d9534af0b3235dc3 (commit) via 871dcbe8a3497f91b8db92531a274fb196b36e29 (commit) via 3dd9277e7902f8647b6ae6798d01a8b939403d6b (commit) via 2f29f326ab00492e79dd42631ee3d94aca881565 (commit) via 0405498b0725c54652fcd485ecaba95d0fd89d92 (commit) via 4ac7d024e8add9cdcb4d73cf569eea95f3307799 (commit) via 5427b4cf863e0dc6f59727e0a9a3e480ab9b4055 (commit) via ff5682ea7e88c098d7b9b2e2d3930afe46cc796a (commit) via 6b0dbab42f9fcdaa31f2d34b899672c50a6a04d8 (commit) via 0473702cb652cb40ead34a762b2c8bbf8ece7794 (commit) via 4e21730cd0d284b126d1f328d43d62554fab7e3f (commit) via 9ee49933d72c0142ab9173d781ee9f6e369a3ad4 (commit) via 86b737b95a3dea9a9bb526834ebba409d4d590b2 (commit) via 9df30be05fb6d39e9ab3768edd9a924e24690d5c (commit) via f5ee5c86fd685d4eee5325db33214b25afca4718 (commit) via e409efbaefb3724fbb3653adb75d48552ab26ef7 (commit) via 863f50f2fbbba7ceb645a3b3dcc042903bd60eb2 (commit) via 4055810dc8eb2853b9524e604880ae202c227444 (commit) via d54b541c0d0e6e9cba3103c7caab13f5507a7c21 (commit) via eb6ce19600d7af5c483e234da5272416b9981650 (commit) via 3e7dcc85ab32258e3385cc88a8a718ccb79f4253 (commit) via 5ab39f30220b7c1e211f658d54a818145a4e62cf (commit) via 5c6e92a089d8925731812639efe3b09a534b38d3 (commit) via b085b353e5f3ef6aa4909718e03e2a2f2e029eac (commit) via ad2e3bb0ee81bfd2babfafa667ad2a84b1de90b6 (commit) via cd5f69fb96425f5f28268fff28ef5147555aee20 (commit) via bf9125d3db5fa1498a98aa0391e66f9802d8280a (commit) via b1381087891b41f73372312983f1e50f804a6087 (commit) via d38a0a8f5fce11a02abd73b8dd7f150cbd956687 (commit) via af7def205c6a9d0b82ae10a59eaa422ec78dfde6 (commit) via b485b2f5931d2518e6135f4664bacb1e833d7696 (commit) via c68233e9d500bed908a3b1dd03641ca9c338045c (commit) via 8f1178c552f8305ea5801ccac9a163900213dd62 (commit) via 770aa4e98aa2930e1a309416f0bdc3d037e6e0f7 (commit) via 3ac385ed05ae80ec5e7660042448617eb3888901 (commit) via 6846d164bf44858af481154605abffcc32ac58d9 (commit) via 1bdb6ce2bffa7696ebad6b3918fb09509eb99409 (commit) via 135e8765656b0c3db654b3bae3961e9f3ea90b2c (commit) via d04981ac397ccd73cfc3bdf67beaf37331560d35 (commit) via 98c225a416a9d6d6823d8c6d3e3c4e41e8cc35b8 (commit) via 4468b153e2383ce7d27f5d8b74c31774db93ad20 (commit) via d9c49971173ace233d2d9c7c8172942777cd2ef1 (commit) via b98f8bef2569ace5efad1b38e5029f537d91ad55 (commit) via 1710058bfa6acabd72c50e6fd5c9c5a70f76922e (commit) via 14dc9acccf57871141aaacbec605a76a8d5ae0ca (commit) via 08456af0f856dd9aa0ceecbe708a84bd0ef2efef (commit) via ada37e07a95d0f3eeeeb31a206e29a08d7cbb590 (commit) via 412121655d314b6d807e395229e8ef2471966325 (commit) via 20e2abf7bc62ce4c6ba9f32cbb01a570e25cf863 (commit) via 4a618321251196bd5a41022a2afe766d225c2258 (commit) via 769a3a559b5d40b22e6727d09c8beca968a98404 (commit) via 467d0fd716fb517f7961d016a5d4c9977a477743 (commit) via 5d88b6579c04eeff146f2240d1fc3f1a2e266ff4 (commit) via 5bc1e89cb13205c28f80afa24c6d1929eb1cfac1 (commit) via bf92f890b1e7bb4e81ea5798d1113ee892d79d3e (commit) via ea64b69a9e262f54f7c793682e9f3289d60dffc9 (commit) via d2dfa10d8936d74e152bc46637f7d21e94f421f2 (commit) via 7671229529a559b454e82eab093e322e3510db54 (commit) via bd1ffcfb5427b7c08309a75aba9954f01f49f23f (commit) via a5fb30d5b613d53fae549930992bd83db04dc876 (commit) via acf80cea37f5d0c2b122834e0bc3b8f594092ec4 (commit) via e44ed57b1e1c930fea26760ff545d5678f437cfc (commit) via 25809ca90359114ed606633cc2236c99ee2824bb (commit) via 7aa0ba961fe8ad8be73acb70f990f7eba7a2ab27 (commit) via 590ddd7b82930afb20bfe0d9292c6744e5413fa8 (commit) via 3f6edf3808ff411577e0364b32dca5ea6afe335c (commit) via 02f10b34f6d3f057035177fb71c6ceb06555bcb3 (commit) via 645ae51a5d5b17eebfb89a8fede720e07aadcfd9 (commit) via fceac511eadbde504d0e7f24d3b1d262c2bcf09c (commit) via a57d1a4880e018a48ae918b1fabffad31fa1402a (commit) via 3aa8f31dcdd4aaea00f038bf929971c0c2baed55 (commit) via 56fc193323958f925d95e8dd9ec469200c80c8bc (commit) via a830e1b6e1fd252a2c43f350b02138366dbced2c (commit) via 5588b2465c5c846de8556bf55bc4f53f0d5b7c77 (commit) via d6cfef69638164131c0ad890d3ce11502199d6fd (commit) via b40ec940e84b153e96b8330e63f103d4c9e8ed4f (commit) via 3686a308d862626ceac6eea40a6896e988641a34 (commit) via afc2776599300649588fdc088a87c8d1caa82fd6 (commit) via ded8e671c8460691a6c844a3caca1623cba3c204 (commit) via 27ec5f4c482c4decf69a79d4198ddefb29ec9a92 (commit) via f16194ca4cd7547cca8dfe9996713d924f97ef3a (commit) via c0b5d7982a409b0e9797ad90e86c264710f2bb4a (commit) via fb2997ff2c7f85253ea3299632ce9e0497ef08cd (commit) via 4e9962e90b97d67525616be182dcf837fcab011d (commit) via 3bb045cecc7c18058f8fadeeac4e9cf9abb365ca (commit) via bdd36892e0cdc6411a6881f467fe98a5b605cfff (commit) via 5fb3405d1f90f2094d39d06a7d6d51e158b6d990 (commit) via a038a70b6ac1bd4d32563a448439b56ab967a397 (commit) via 8c514476e40079e36f3f65c892d6863ec727e0f0 (commit) via 5ac1ba6452c55aa283e033d51c0ee1c953b52bdb (commit) via 43ee66473d28f328110db397e3e5ba465deeb2aa (commit) via 36c6ce49f93749b766784a6f7b3b10831ca633f9 (commit) via 3659ede4036cb51bcf53f4697d77ce940641925a (commit) via fce87b1b1060c109ae2fbcc827120d1bf52cb6a9 (commit) via 575d6dd1af6cef7104f0447576569d04901cd659 (commit) via 2f8d6e0f19c8f6470f3a4d82477a1d82fbb667c1 (commit) via 14b6941a01e86a53f4cdce81dd6e82a9aa651d17 (commit) via 528da5dc9ab4d0d2459256add58f4e2e0683f175 (commit) via 1ef86d8e93f096a4506bed450b203df935a85190 (commit) via 56866fecd54ac9568427bc873541d997a31f860d (commit) via c66f54c208104d9a5821f90d79ce6ba13087d1a2 (commit) via c31e57fee7b19effc26df6251a9f9f45dfd3d8ae (commit) via 21680572ab01f0084d42beea124446ff5a326318 (commit) via 1993073559504993a7cf2aec360bc54723967c6e (commit) via 78a5522447d322da02ee733bb6b48c816f23cac2 (commit) via 0f84d70cacb13e2d560c4836e07acaf62e79a86a (commit) via e5031ef72c7dcc67d3c458228118942897fe129c (commit) via a012e8e25d33b3b05b1cb1ed3edf2c5900474e91 (commit) via 7aa29b9f51536e5246d0780e153a16d9c2e1450b (commit) via 827bc131938aba0b9f3496e95bb3ae35df9704e3 (commit) via fdec51eee02378f4b7420315bdf714ddf73bed0d (commit) via 5d9f6ed6e9c272876e68bfca42a67f57bc4a4731 (commit) via a93e7d1e0b2bb846934298fdda831ac134c76410 (commit) via 4ad2f355b193c238753c999ba58b2ac01b23e09f (commit) via 223d2b7c119580f7f61160b7458aa2d9fae1fa12 (commit) via 8fbda12ce2f435c4f1930d1fe642a10b9e12a3bb (commit) via 1d005351b77274e7ee9a1593b62f23a224e423bf (commit) via 20019efe6d7ff1e484763528f95ccbd1fad792c5 (commit) via 2943b84548523f8fedb9b929371bb0d9446f6129 (commit) via f0b624cd55970817adfabde2d67d6e7a4fd36bf6 (commit) via 6709a189fa135de40c02572780e67daccdfc5200 (commit) via 606609f62eaf8aa354616e7a46712c03cdf37f09 (commit) via 0333cdfca5aa9f3b867c4a4c03e220ecd143b1b0 (commit) via 499198bf5070a5ca4477e424dada99768a48d596 (commit) via c5a5276b15c251151c67e17c50b2fb712ec3809d (commit) via b3d93cc2314734f6bb9d1db7ed963f16a5a2a1a7 (commit) via 9e2ac436313a79cb83f22eeda64b0dda036f588e (commit) via f51e778b1b8357abc0bde03ea052642241742c3f (commit) via be8547f5d64ff4389f9d420859c4df8796e5166e (commit) via 80630326a0c686e708720e9532f737099c98f4e2 (commit) via b0aa034accbc557eac1817c50d5e0b2b76dee978 (commit) via 9f0cee832454714e4ebef0143e069e9ed09aacc5 (commit) via b3ff4b0167489233a53dc570dc807639fb5814ed (commit) via f4cf9091543b03dfad5093725218f5757574ffd7 (commit) via 1444448aebeadbb705d1b40ab3220f95020a432c (commit) via 27000c27fb65ae4d3a19e26896c281f2c554d852 (commit) via 2c43ee5f0c9f0efe6eb1534d8fca4fce5c0fb3a7 (commit) via 23280e812cd5fe3aed49d00fe26cf33136fb9433 (commit) via c519dbd78afde2ce92e99defa7203b2d9fbdf80b (commit) via 7be2aac2c1438fa2848d191e0b21dda9e74b12bb (commit) via b7503986eaf7786c43d875b9c17653b7b85e77e4 (commit) via 9ba2b4502c687e68f23eab958b341ec16b316a82 (commit) via fb16f2263157bc3a4e6d60181f9dfee7d6064e68 (commit) via 9ae519fc410b8488c8445ab730babc086de08aec (commit) via d10912ee640f023e92ec79212c326b0b46385fd1 (commit) via ede76968782bf514ae872b70b924e4360776888e (commit) via 83e5b14cf644c282580cb448891d4ad622eb0fb8 (commit) from d04f4b6b3b53e7b630ebecfd46fa6a7fc257e90e (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit c76dc1453d963334968ab9879caceb180021f12b Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Apr 27 10:14:27 2022 -0500 Forgot to commit kenwood.h diff --git a/rigs/kenwood/kenwood.h b/rigs/kenwood/kenwood.h index 8d2dac5e..ede66b43 100644 --- a/rigs/kenwood/kenwood.h +++ b/rigs/kenwood/kenwood.h @@ -28,7 +28,7 @@ #include "token.h" #include "misc.h" -#define BACKEND_VER "20220312" +#define BACKEND_VER "20220427" #define EOM_KEN ';' #define EOM_TH '\r' @@ -64,6 +64,8 @@ extern struct confparams kenwood_cfg_params[]; #define MD_AM '5' #define MD_FSK '6' #define MD_CWR '7' +// MD_DIG used by SDRPlay +#define MD_DIG '8' #define MD_FSKR '9' /* S-meter calibration tables */ @@ -306,6 +308,7 @@ extern const struct rig_caps ts890s_caps; extern const struct rig_caps pt8000a_caps; extern const struct rig_caps malachite_caps; extern const struct rig_caps tx500_caps; +extern const struct rig_caps sdruno_caps; /* use when not interested in the answer, but want to check its len */ static int inline kenwood_simple_transaction(RIG *rig, const char *cmd, commit def3e6fea5deacf23ea2fc7fb95e4fae3ffab5cd Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Apr 27 10:11:41 2022 -0500 Add SDRUNO rig since it uses MD8 for DIG mode -- so PKTUSB will now be recognized for it diff --git a/include/hamlib/riglist.h b/include/hamlib/riglist.h index 6f165e3f..a1df7a82 100644 --- a/include/hamlib/riglist.h +++ b/include/hamlib/riglist.h @@ -181,6 +181,7 @@ #define RIG_MODEL_POWERSDR RIG_MAKE_MODEL(RIG_KENWOOD, 48) #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) /* * Icom diff --git a/rigs/kenwood/kenwood.c b/rigs/kenwood/kenwood.c index 4ccfcda7..fdf8aff4 100644 --- a/rigs/kenwood/kenwood.c +++ b/rigs/kenwood/kenwood.c @@ -114,6 +114,7 @@ static const struct kenwood_id_string kenwood_id_string_list[] = { RIG_MODEL_TS2000, "019" }, { RIG_MODEL_TS480, "020" }, { RIG_MODEL_PT8000A, "020" }, // TS480 ID but behaves differently + { RIG_MODEL_SDRUNO, "020" }, // TS480 ID but behaves differently { RIG_MODEL_TS590S, "021" }, { RIG_MODEL_TS990S, "022" }, { RIG_MODEL_TS590SG, "023" }, @@ -143,7 +144,7 @@ rmode_t kenwood_mode_table[KENWOOD_MODE_TABLE_MAX] = [5] = RIG_MODE_AM, [6] = RIG_MODE_RTTY, // FSK Mode [7] = RIG_MODE_CWR, - [8] = RIG_MODE_NONE, /* TUNE mode */ + [8] = RIG_MODE_NONE, /* TUNE mode or PKTUSB for SDRUNO */ [9] = RIG_MODE_RTTYR, // FSKR Mode [10] = RIG_MODE_PSK, [11] = RIG_MODE_PSKR, @@ -750,6 +751,12 @@ int kenwood_init(RIG *rig) rig_debug(RIG_DEBUG_TRACE, "%s: if_len = %d\n", __func__, caps->if_len); + // SDRUno uses mode 8 for DIG + if (rig->caps->rig_model == RIG_MODEL_SDRUNO) + { + kenwood_mode_table[8] = RIG_MODE_PKTUSB; + } + RETURNFUNC2(RIG_OK); } @@ -5670,6 +5677,7 @@ DECLARE_INITRIG_BACKEND(kenwood) rig_register(&pt8000a_caps); rig_register(&malachite_caps); rig_register(&tx500_caps); + rig_register(&sdruno_caps); return (RIG_OK); } diff --git a/rigs/kenwood/ts480.c b/rigs/kenwood/ts480.c index 8f277479..edbaa553 100644 --- a/rigs/kenwood/ts480.c +++ b/rigs/kenwood/ts480.c @@ -34,6 +34,7 @@ #include "kenwood.h" #define TS480_ALL_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_FM|RIG_MODE_RTTY|RIG_MODE_RTTYR) +#define SDRUNO_ALL_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_FM|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_PKTUSB) #define PS8000A_ALL_MODES (RIG_MODE_AM|RIG_MODE_AMS|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_FM|RIG_MODE_RTTY|RIG_MODE_RTTYR) #define TS480_OTHER_TX_MODES (RIG_MODE_CW|RIG_MODE_SSB|RIG_MODE_FM|RIG_MODE_RTTY) @@ -1598,6 +1599,199 @@ const struct rig_caps pt8000a_caps = .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; +/* + * SDRPlay SDRUno rig capabilities + * Notice that some rigs share the same functions. + */ +const struct rig_caps sdruno_caps = +{ + RIG_MODEL(RIG_MODEL_SDRUNO), + .model_name = "SDRUno", + .mfg_name = "SDRPlay", + .version = BACKEND_VER ".1", + .copyright = "LGPL", + .status = RIG_STATUS_STABLE, + .rig_type = RIG_TYPE_TRANSCEIVER, + .ptt_type = RIG_PTT_RIG_MICDATA, + .dcd_type = RIG_DCD_RIG, + .port_type = RIG_PORT_SERIAL, + .serial_rate_min = 4800, + .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 = 200, + .retry = 3, + .preamp = {12, RIG_DBLST_END,}, + .attenuator = {12, RIG_DBLST_END,}, + .max_rit = kHz(9.99), + .max_xit = kHz(9.99), + .max_ifshift = Hz(0), + .targetable_vfo = RIG_TARGETABLE_FREQ, + .transceive = RIG_TRN_RIG, + + .rx_range_list1 = { + {kHz(100), Hz(59999999), SDRUNO_ALL_MODES, -1, -1, TS480_VFO}, + RIG_FRNG_END, + }, /*!< Receive frequency range list for ITU region 1 */ + .tx_range_list1 = { + {kHz(1810), kHz(1850), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, /* 100W class */ + {kHz(1810), kHz(1850), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, /* 25W class */ + {kHz(3500), kHz(3800), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(3500), kHz(3800), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(7), kHz(7200), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(7), kHz(7200), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(10100), kHz(10150), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(10100), kHz(10150), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(14), kHz(14350), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(14), kHz(14350), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(18068), kHz(18168), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(18068), kHz(18168), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(21), kHz(21450), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(21), kHz(21450), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(24890), kHz(24990), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(24890), kHz(24990), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(28), kHz(29700), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(28), kHz(29700), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(50), kHz(52000), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(50), kHz(52000), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + RIG_FRNG_END, + }, /*!< Transmit frequency range list for ITU region 1 */ + .rx_range_list2 = { + {kHz(100), Hz(59999999), TS480_ALL_MODES, -1, -1, TS480_VFO}, + RIG_FRNG_END, + }, /*!< Receive frequency range list for ITU region 2 */ + .tx_range_list2 = { + {kHz(1800), MHz(2) - 1, TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, /* 100W class */ + {kHz(1800), MHz(2) - 1, TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, /* 25W class */ + {kHz(3500), MHz(4) - 1, TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(3500), MHz(4) - 1, TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(5250), kHz(5450), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(5250), kHz(5450), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(7), kHz(7300), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(7), kHz(7300), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(10100), kHz(10150), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(10100), kHz(10150), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(14), kHz(14350), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(14), kHz(14350), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(18068), kHz(18168), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(18068), kHz(18168), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(21), kHz(21450), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(21), kHz(21450), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {kHz(24890), kHz(24990), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {kHz(24890), kHz(24990), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(28), kHz(29700), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(28), kHz(29700), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + {MHz(50), kHz(52000), TS480_OTHER_TX_MODES, 5000, 100000, TS480_VFO}, + {MHz(50), kHz(52000), TS480_AM_TX_MODES, 5000, 25000, TS480_VFO}, + RIG_FRNG_END, + }, /*!< Transmit frequency range list for ITU region 2 */ + .tuning_steps = { + {TS480_ALL_MODES, kHz(1)}, + {TS480_ALL_MODES, Hz(2500)}, + {TS480_ALL_MODES, kHz(5)}, + {TS480_ALL_MODES, Hz(6250)}, + {TS480_ALL_MODES, kHz(10)}, + {TS480_ALL_MODES, Hz(12500)}, + {TS480_ALL_MODES, kHz(15)}, + {TS480_ALL_MODES, kHz(20)}, + {TS480_ALL_MODES, kHz(25)}, + {TS480_ALL_MODES, kHz(30)}, + {TS480_ALL_MODES, kHz(100)}, + {TS480_ALL_MODES, kHz(500)}, + {TS480_ALL_MODES, MHz(1)}, + {TS480_ALL_MODES, 0}, /* any tuning step */ + RIG_TS_END, + }, + /* mode/filter list, remember: order matters! */ + .filters = { + {RIG_MODE_SSB, kHz(2.4)}, + {RIG_MODE_SSB, Hz(270)}, + {RIG_MODE_SSB, Hz(500)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(200)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(50)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(1000)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(80)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(100)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(150)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(300)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(400)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(500)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(600)}, + {RIG_MODE_CW | RIG_MODE_CWR, Hz(2000)}, + {RIG_MODE_RTTY | RIG_MODE_RTTYR, Hz(500)}, + {RIG_MODE_RTTY | RIG_MODE_RTTYR, Hz(250)}, + {RIG_MODE_RTTY | RIG_MODE_RTTYR, Hz(1000)}, + {RIG_MODE_RTTY | RIG_MODE_RTTYR, Hz(1500)}, + {RIG_MODE_AM, kHz(6)}, + {RIG_MODE_AM, kHz(2.4)}, + {RIG_MODE_FM, kHz(12)}, + {RIG_MODE_PKTUSB, kHz(4)}, + RIG_FLT_END, + }, + .vfo_ops = TS480_VFO_OPS, + .level_gran = { + [LVL_RAWSTR] = { .min = { .i = 0 }, .max = { .i = 255 } }, + [LVL_VOXDELAY] = { .min = { .i = 0 }, .max = { .i = 30 }, .step = { .i = 1 } }, + [LVL_KEYSPD] = {.min = {.i = 10}, .max = {.i = 60}, .step = {.i = 1}}, + [LVL_CWPITCH] = {.min = {.i = 400}, .max = {.i = 1000}, .step = {.i = 50}}, + [LVL_BKIN_DLYMS] = {.min = {.i = 0}, .max = {.i = 1000}, .step = {.i = 50}}, + [LVL_SLOPE_LOW] = {.min = {.i = 0}, .max = {.i = 2400}, .step = {.i = 10}}, + [LVL_SLOPE_HIGH] = {.min = {.i = 0}, .max = {.i = 5000}, .step = {.i = 10}}, + }, + .str_cal = TS480_STR_CAL, + .swr_cal = TS480_SWR_CAL, + + .ext_tokens = ts480_ext_tokens, + .extfuncs = ts480_ext_funcs, + .extlevels = ts480_ext_levels, + + .priv = (void *)& ts480_priv_caps, + .rig_init = ts480_init, + .rig_open = kenwood_open, + .rig_cleanup = kenwood_cleanup, + .set_freq = kenwood_set_freq, + .get_freq = kenwood_get_freq, + .set_rit = ts480_set_rit, + .get_rit = ts480_get_rit, + .set_xit = ts480_set_rit, + .get_xit = ts480_get_rit, + .set_mode = kenwood_set_mode, + .get_mode = kenwood_get_mode, + .set_vfo = kenwood_set_vfo, + .get_vfo = kenwood_get_vfo_if, + .set_split_vfo = kenwood_set_split_vfo, + .get_split_vfo = kenwood_get_split_vfo_if, + .get_ptt = kenwood_get_ptt, + .set_ptt = kenwood_set_ptt, + .get_dcd = kenwood_get_dcd, + .set_powerstat = kenwood_set_powerstat, + .get_powerstat = kenwood_get_powerstat, + .get_info = kenwood_ts480_get_info, + .reset = kenwood_reset, + .set_ant = kenwood_set_ant, + .get_ant = kenwood_get_ant, + .scan = kenwood_scan, /* not working, invalid arguments using rigctl; kenwood_scan does only support on/off and not tone and CTCSS scan */ + .has_set_level = TS480_LEVEL_ALL, + .has_get_level = TS480_LEVEL_ALL, + .set_level = kenwood_ts480_set_level, + .get_level = kenwood_ts480_get_level, + .set_ext_level = ts480_set_ext_level, + .get_ext_level = ts480_get_ext_level, + .has_get_func = TS480_FUNC_ALL, + .has_set_func = TS480_FUNC_ALL, + .set_func = ts480_set_func, + .get_func = ts480_get_func, + .set_ext_func = ts480_set_ext_func, + .get_ext_func = ts480_get_ext_func, + .send_morse = kenwood_send_morse, + .vfo_op = kenwood_vfo_op, + .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS +}; + const struct confparams malachite_cfg_parms[] = { { commit a006636ee3a6c9e7d5ba5125b7e2aae2f0fcf23c Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 15:27:13 2022 -0500 Fix flrig_cat_string diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index a7f70fff..99780411 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -2322,8 +2322,11 @@ static int flrig_get_ext_parm(RIG *rig, token_t token, value_t *val) HAMLIB_EXPORT(int) flrig_cat_string (RIG *rig, const char *arg) { int retval; + char cmd_arg[MAXARGLEN]; rig_debug(RIG_DEBUG_VERBOSE, "%s called: %s\n", __func__, arg); - retval = flrig_transaction(rig, "rig.cat_string", (char*)arg, NULL, 0); + SNPRINTF(cmd_arg, sizeof(cmd_arg), + "<params><param><value>%s</value></param></params>", arg); + retval = flrig_transaction(rig, "rig.cat_string", cmd_arg, NULL, 0); return retval; } commit 5400d8ed01f417174f2fa3228aa7e71748bc9e6e Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 12:54:06 2022 -0500 Fix send_command to detect FLRig correctly diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index 95048b54..ba8261e6 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -4688,7 +4688,7 @@ declare_proto_rig(send_cmd) rig_debug(RIG_DEBUG_TRACE, "%s: backend_num=%d\n", __func__, backend_num); - if (backend_num == RIG_MODEL_FLRIG) + if (rig->caps->rig_model == RIG_MODEL_FLRIG) { // call flrig raw send function cat_string or cat_priority_string flrig_cat_string(rig, arg1); commit 7cc2550ee369b1537bd25dae18a52324dbecd96e Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 12:47:27 2022 -0500 Export flrig_cat_string for DLL diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index dbc363c9..a7f70fff 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -2319,7 +2319,7 @@ static int flrig_get_ext_parm(RIG *rig, token_t token, value_t *val) RETURNFUNC(RIG_OK); } -int flrig_cat_string (RIG *rig, const char *arg) +HAMLIB_EXPORT(int) flrig_cat_string (RIG *rig, const char *arg) { int retval; rig_debug(RIG_DEBUG_VERBOSE, "%s called: %s\n", __func__, arg); commit fbd78931925f5788985871330fb30e332297c817 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 12:42:27 2022 -0500 Add cat_string to the raw send command in rigctl for FLRig diff --git a/rigs/dummy/flrig.c b/rigs/dummy/flrig.c index b2fac1ed..dbc363c9 100644 --- a/rigs/dummy/flrig.c +++ b/rigs/dummy/flrig.c @@ -142,7 +142,7 @@ const struct rig_caps flrig_caps = RIG_MODEL(RIG_MODEL_FLRIG), .model_name = "FLRig", .mfg_name = "FLRig", - .version = "20220205.0", + .version = "20220425.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -2319,6 +2319,13 @@ static int flrig_get_ext_parm(RIG *rig, token_t token, value_t *val) RETURNFUNC(RIG_OK); } +int flrig_cat_string (RIG *rig, const char *arg) +{ + int retval; + rig_debug(RIG_DEBUG_VERBOSE, "%s called: %s\n", __func__, arg); + retval = flrig_transaction(rig, "rig.cat_string", (char*)arg, NULL, 0); + return retval; +} #if 0 static int flrig_set_ext_parm(RIG *rig, setting_t parm, value_t val) diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index f0d64b14..95048b54 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -4665,6 +4665,8 @@ static int hasbinary(char *s, int len) * * 'w' and 'W' */ +extern int flrig_cat_string(RIG *rig, const char *arg); + declare_proto_rig(send_cmd) { int retval; @@ -4686,6 +4688,12 @@ declare_proto_rig(send_cmd) rig_debug(RIG_DEBUG_TRACE, "%s: backend_num=%d\n", __func__, backend_num); + if (backend_num == RIG_MODEL_FLRIG) + { + // call flrig raw send function cat_string or cat_priority_string + flrig_cat_string(rig, arg1); + } + // need to move the eom_buf to rig-specifc backends // we'll let KENWOOD backends use the ; char in the rigctl commands if (backend_num == RIG_KENWOOD || backend_num == RIG_YAESU) commit 5c61f559472f7f0048ae764e469280a21f0296e2 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 10:15:54 2022 -0500 Add RIG_PARM_AFIF to allow rigs like IC-7300/9700/705 to select the AF/IF audio output diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 5b402064..1a46eee3 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -1032,7 +1032,8 @@ enum rig_parm_e { RIG_PARM_TIME = (1 << 5), /*!< \c TIME -- hh:mm:ss, int in seconds from 00:00:00 */ RIG_PARM_BAT = (1 << 6), /*!< \c BAT -- battery level, float [0.0 ... 1.0] */ RIG_PARM_KEYLIGHT = (1 << 7), /*!< \c KEYLIGHT -- Button backlight, on/off */ - RIG_PARM_SCREENSAVER = (1 << 8) /*!< \c SCREENSAVER -- rig specific timeouts */ + RIG_PARM_SCREENSAVER = (1 << 8), /*!< \c SCREENSAVER -- rig specific timeouts */ + RIG_PARM_AFIF = (1 << 9) /*!< \c AFIF -- 0=AF audio, 1=IF audio -- see IC-7300/9700/705 */ }; /** diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 80ba2749..0413fee0 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -223,6 +223,7 @@ struct cmdparams ic7300_extcmds[] = { {.s = RIG_PARM_BEEP}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x23}, CMD_DAT_BOL, 1 }, { {.s = RIG_PARM_BACKLIGHT}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x81}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_TIME}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x95}, CMD_DAT_TIM, 2 }, + { {.s = RIG_PARM_AFIF}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x59}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x59}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x00, 0x71}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x02}, CMD_DAT_INT, 1 }, @@ -235,6 +236,7 @@ struct cmdparams ic9700_extcmds[] = { {.s = RIG_PARM_BACKLIGHT}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x52}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_SCREENSAVER}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x67}, CMD_DAT_INT, 1 }, { {.s = RIG_PARM_TIME}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x80}, CMD_DAT_TIM, 2 }, + { {.s = RIG_PARM_AFIF}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x00}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x03, 0x30}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x27}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x92}, CMD_DAT_INT, 1 }, @@ -247,6 +249,7 @@ struct cmdparams ic705_extcmds[] = { {.s = RIG_PARM_BACKLIGHT}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x36}, CMD_DAT_LVL, 2 }, { {.s = RIG_PARM_SCREENSAVER}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x38}, CMD_DAT_INT, 1 }, { {.s = RIG_PARM_TIME}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x66}, CMD_DAT_TIM, 2 }, + { {.s = RIG_PARM_AFIF}, CMD_PARAM_TYPE_PARM, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x09}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_VOXDELAY}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x03, 0x59}, CMD_DAT_INT, 1 }, { {.s = RIG_FUNC_TRANSCEIVE}, CMD_PARAM_TYPE_FUNC, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x31}, CMD_DAT_BOL, 1 }, { {.s = RIG_LEVEL_SPECTRUM_AVG}, CMD_PARAM_TYPE_LEVEL, C_CTL_MEM, S_MEM_PARM, SC_MOD_RW, 2, {0x01, 0x78}, CMD_DAT_INT, 1 }, @@ -541,7 +544,7 @@ const struct rig_caps ic7300_caps = RIG_MODEL(RIG_MODEL_IC7300), .model_name = "IC-7300", .mfg_name = "Icom", - .version = BACKEND_VER ".6", + .version = BACKEND_VER ".7", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -776,7 +779,7 @@ const struct rig_caps ic9700_caps = RIG_MODEL(RIG_MODEL_IC9700), .model_name = "IC-9700", .mfg_name = "Icom", - .version = BACKEND_VER ".6", + .version = BACKEND_VER ".7", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1087,7 +1090,7 @@ const struct rig_caps ic705_caps = RIG_MODEL(RIG_MODEL_IC705), .model_name = "IC-705", .mfg_name = "Icom", - .version = BACKEND_VER ".4", + .version = BACKEND_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, commit 382282ba204fcf1f23274254a7c5aeae8ee64d60 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 08:18:06 2022 -0500 Fix rigctl option -B diff --git a/tests/rigctlcom.c b/tests/rigctlcom.c index 50655cde..d5c89281 100644 --- a/tests/rigctlcom.c +++ b/tests/rigctlcom.c @@ -254,7 +254,7 @@ int main(int argc, char *argv[]) version(); exit(0); - case 'A': + case 'B': mapa2b = 1; break; commit b55668e2faf750a73c082ab8b619f37a67ddb028 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Apr 25 08:09:51 2022 -0500 Update usage and no arg for -B option diff --git a/tests/rigctlcom.c b/tests/rigctlcom.c index ce0cdb38..50655cde 100644 --- a/tests/rigctlcom.c +++ b/tests/rigctlcom.c @@ -93,7 +93,7 @@ #define SHORT_OPTIONS "B:m:r:R:p:d:P:D:s:S:c:C:lLuvhVZ" static struct option long_options[] = { - {"mapa2b", 1, 0, 'B'}, + {"mapa2b", 0, 0, 'B'}, {"model", 1, 0, 'm'}, {"rig-file", 1, 0, 'r'}, {"rig-file2", 1, 0, 'R'}, @@ -1658,6 +1658,7 @@ void usage() " -S, --serial-speed2=BAUD set serial speed of the virtual com port [default=115200]\n" " -c, --civaddr=ID set CI-V address, decimal (for Icom rigs only)\n" " -C, --set-conf=PARM=VAL set config parameters\n" + " -B, --mapa2b maps set_freq on VFOA to VFOB -- useful for CW Skimmer\n" " -L, --show-conf list all config parameters\n" " -l, --list list all model numbers and exit\n" " -u, --dump-caps dump capabilities and exit\n" commit 6bd9cdfda090d496c1486a706f6d6ddf7a43fa1e Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Apr 24 14:46:30 2022 -0500 Update rigctlcom.1 man page to add new -B --mapa2b option diff --git a/doc/man1/rigctlcom.1 b/doc/man1/rigctlcom.1 index 7d63037d..3e5d3992 100644 --- a/doc/man1/rigctlcom.1 +++ b/doc/man1/rigctlcom.1 @@ -28,6 +28,7 @@ rigctlcom \- COM port passthru as TS-2000 emulator to your rig .OP \-S baud .OP \-c id .OP \-C parm=val +.OP \-B .RB [ \-v [ \-Z ]] .YS . @@ -244,7 +245,6 @@ e.g. \(lqrigctl -l | more\(rq. . .TP .BR \-n ", " \-\-no\-restore\-ai -On exit .B rigctl restores the state of auto information (AI) on the controlled rig. .IP @@ -253,6 +253,12 @@ If this is not desired, for example if you are using 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 commit d412914f96526c6420d28af8f9f9725b30ae2e14 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Apr 24 14:22:43 2022 -0500 Update NEWS diff --git a/NEWS b/NEWS index 59a13680..78a0aa01 100644 --- a/NEWS +++ b/NEWS @@ -10,9 +10,16 @@ Please send Hamlib bug reports to ham...@li... Version 5.x -- future * rig_get_conf deprecated and replaced by rig_get_conf2 * rot_get_conf deprecated and replaced by rot_get_conf2 + * Change FT1000MP Mark V model names to align with FT1000MP Version 4.5 * 2022-04-XX + * Add -B/--mapa2b to rigctlcom + Allows rigctlcom to map set_freq on VFOA to VFOB instead + This will allow CW Skimmer to work with some rigs (e.g. IC7300) using FM + mode on VFOA and CW mode on VFOB and split mode transmit on VFOB. + Clicking on CW Skimmer will change VFOB instead of VFOA to allow working + dxpeditions where the fox is staying on frequency * Add password capability to rigctld via -A switch. rigctld -A will produce a consistent shared key for any specific password that can used in \password and rig_set_password TBD The shared key can also be placed in .hamlib_settings commit 6497048f288092a86edb7b9cbcd25aea9cf5fec4 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Apr 24 14:19:20 2022 -0500 Allow rigctlcom to map set_freq on VFOA to VFOB instead This will allow CW Skimmer to work with some rigs (e.g. IC7300) using FM mode on VFOA and CW mode on VFOB and split mode transmit on VFOB. Clicking on CW Skimmer will change VFOB instead of VFOA to allow working dxpeditions where the fox is staying on frequency diff --git a/tests/rigctlcom.c b/tests/rigctlcom.c index 0c3f38ce..ce0cdb38 100644 --- a/tests/rigctlcom.c +++ b/tests/rigctlcom.c @@ -90,9 +90,10 @@ * NB: do NOT use -W since it's reserved by POSIX. * TODO: add an option to read from a file */ -#define SHORT_OPTIONS "m:r:R:p:d:P:D:s:S:c:C:lLuvhVZ" +#define SHORT_OPTIONS "B:m:r:R:p:d:P:D:s:S:c:C:lLuvhVZ" static struct option long_options[] = { + {"mapa2b", 1, 0, 'B'}, {"model", 1, 0, 'm'}, {"rig-file", 1, 0, 'r'}, {"rig-file2", 1, 0, 'R'}, @@ -120,6 +121,11 @@ static int handle_ts2000(void *arg); static RIG *my_rig; /* handle to rig */ static hamlib_port_t my_com; /* handle to virtual COM port */ static int verbose; +/* CW Skimmer can only set VFOA */ +/* IC7300 for example can run VFOA on FM and VFOB on CW */ +/* So -A/--mapa2b changes set_freq on VFOA to VFOB */ +/* This allows working CW Skimmer in split mode and transmit on VFOB */ +static int mapa2b; /* maps set_freq on VFOA to VFOB instead */ #ifdef HAVE_SIG_ATOMIC_T static sig_atomic_t volatile ctrl_c; @@ -219,7 +225,7 @@ int main(int argc, char *argv[]) char conf_parms[MAXCONFLEN] = ""; int status; - printf("rigctlcom Version 1.2\n"); + printf("rigctlcom Version 1.3\n"); while (1) { @@ -248,6 +254,10 @@ int main(int argc, char *argv[]) version(); exit(0); + case 'A': + mapa2b = 1; + break; + case 'm': if (!optarg) { @@ -1512,9 +1522,11 @@ static int handle_ts2000(void *arg) else if (strncmp(arg, "FA0", 3) == 0) { freq_t freq; + vfo_t vfo = RIG_VFO_A; + if (mapa2b) vfo = RIG_VFO_B; sscanf((char *)arg + 2, "%"SCNfreq, &freq); - return rig_set_freq(my_rig, vfo_fixup(my_rig, RIG_VFO_A, + return rig_set_freq(my_rig, vfo_fixup(my_rig, vfo, my_rig->state.cache.split), freq); } else if (strncmp(arg, "FB0", 3) == 0) commit 07d2602950509c01016d0709d9534af0b3235dc3 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Apr 22 16:39:42 2022 -0500 Update documentation in ft1000mp.c https://github.com/Hamlib/Hamlib/issues/1014 diff --git a/rigs/yaesu/ft1000mp.c b/rigs/yaesu/ft1000mp.c index 4f432993..df0cecd4 100644 --- a/rigs/yaesu/ft1000mp.c +++ b/rigs/yaesu/ft1000mp.c @@ -54,50 +54,50 @@ enum ft1000mp_native_cmd_e { FT1000MP_NATIVE_SPLIT_OFF = 0, - FT1000MP_NATIVE_SPLIT_ON, - FT1000MP_NATIVE_RECALL_MEM, - FT1000MP_NATIVE_VFO_TO_MEM, - FT1000MP_NATIVE_VFO_A, - FT1000MP_NATIVE_VFO_B, - FT1000MP_NATIVE_M_TO_VFO, - FT1000MP_NATIVE_RIT_ON, - FT1000MP_NATIVE_RIT_OFF, - FT1000MP_NATIVE_XIT_ON, - FT1000MP_NATIVE_XIT_OFF, - FT1000MP_NATIVE_RXIT_SET, - FT1000MP_NATIVE_FREQA_SET, - FT1000MP_NATIVE_FREQB_SET, - FT1000MP_NATIVE_MODE_SET_LSB, - FT1000MP_NATIVE_MODE_SET_USB, - FT1000MP_NATIVE_MODE_SET_CW, - FT1000MP_NATIVE_MODE_SET_CWR, - FT1000MP_NATIVE_MODE_SET_AM, - FT1000MP_NATIVE_MODE_SET_AMS, - FT1000MP_NATIVE_MODE_SET_FM, - FT1000MP_NATIVE_MODE_SET_FMW, - FT1000MP_NATIVE_MODE_SET_RTTY_LSB, - FT1000MP_NATIVE_MODE_SET_RTTY_USB, - FT1000MP_NATIVE_MODE_SET_DATA_LSB, - FT1000MP_NATIVE_MODE_SET_DATA_FM, - FT1000MP_NATIVE_MODE_SET_LSB_B, - FT1000MP_NATIVE_MODE_SET_USB_B, - FT1000MP_NATIVE_MODE_SET_CW_B, - FT1000MP_NATIVE_MODE_SET_CWR_B, - FT1000MP_NATIVE_MODE_SET_AM_B, - FT1000MP_NATIVE_MODE_SET_AMS_B, - FT1000MP_NATIVE_MODE_SET_FM_B, - FT1000MP_NATIVE_MODE_SET_FMW_B, - FT1000MP_NATIVE_MODE_SET_RTTY_LSB_B, - FT1000MP_NATIVE_MODE_SET_RTTY_USB_B, - FT1000MP_NATIVE_MODE_SET_DATA_LSB_B, - FT1000MP_NATIVE_MODE_SET_DATA_FM_B, - FT1000MP_NATIVE_PACING, - FT1000MP_NATIVE_PTT_OFF, - FT1000MP_NATIVE_PTT_ON, - FT1000MP_NATIVE_VFO_UPDATE, - FT1000MP_NATIVE_CURR_VFO_UPDATE, - FT1000MP_NATIVE_UPDATE, - FT1000MP_NATIVE_AB, + FT1000MP_NATIVE_SPLIT_ON, // 1 + FT1000MP_NATIVE_RECALL_MEM, // 2 + FT1000MP_NATIVE_VFO_TO_MEM, // 3 + FT1000MP_NATIVE_VFO_A, // 4 + FT1000MP_NATIVE_VFO_B, // 5 + FT1000MP_NATIVE_M_TO_VFO, // 6 + FT1000MP_NATIVE_RIT_ON, // 7 + FT1000MP_NATIVE_RIT_OFF, // 8 + FT1000MP_NATIVE_XIT_ON, // 9 + FT1000MP_NATIVE_XIT_OFF, // 10 + FT1000MP_NATIVE_RXIT_SET, // 11 + FT1000MP_NATIVE_FREQA_SET, // 12 + FT1000MP_NATIVE_FREQB_SET, // 13 + FT1000MP_NATIVE_MODE_SET_LSB, // 14 + FT1000MP_NATIVE_MODE_SET_USB, // 15 + FT1000MP_NATIVE_MODE_SET_CW, // 16 + FT1000MP_NATIVE_MODE_SET_CWR, // 17 + FT1000MP_NATIVE_MODE_SET_AM, // 18 + FT1000MP_NATIVE_MODE_SET_AMS, // 19 + FT1000MP_NATIVE_MODE_SET_FM, // 20 + FT1000MP_NATIVE_MODE_SET_FMW, // 21 + FT1000MP_NATIVE_MODE_SET_RTTY_LSB, // 22 + FT1000MP_NATIVE_MODE_SET_RTTY_USB, // 23 + FT1000MP_NATIVE_MODE_SET_DATA_LSB, // 24 + FT1000MP_NATIVE_MODE_SET_DATA_FM, // 25 + FT1000MP_NATIVE_MODE_SET_LSB_B, // 26 + FT1000MP_NATIVE_MODE_SET_USB_B, // 27 + FT1000MP_NATIVE_MODE_SET_CW_B, // 28 + FT1000MP_NATIVE_MODE_SET_CWR_B, // 29 + FT1000MP_NATIVE_MODE_SET_AM_B, // 30 + FT1000MP_NATIVE_MODE_SET_AMS_B, // 31 + FT1000MP_NATIVE_MODE_SET_FM_B, // 32 + FT1000MP_NATIVE_MODE_SET_FMW_B, // 33 + FT1000MP_NATIVE_MODE_SET_RTTY_LSB_B, // 34 + FT1000MP_NATIVE_MODE_SET_RTTY_USB_B, // 35 + FT1000MP_NATIVE_MODE_SET_DATA_LSB_B, // 36 + FT1000MP_NATIVE_MODE_SET_DATA_FM_B, // 37 + FT1000MP_NATIVE_PACING, // 38 + FT1000MP_NATIVE_PTT_OFF, // 39 + FT1000MP_NATIVE_PTT_ON, // 40 + FT1000MP_NATIVE_VFO_UPDATE, // 41 + FT1000MP_NATIVE_CURR_VFO_UPDATE, // 42 + FT1000MP_NATIVE_UPDATE, // 43 + FT1000MP_NATIVE_AB, // 44 FT1000MP_NATIVE_SIZE /* end marker, value indicates number of */ /* native cmd entries */ @@ -166,62 +166,62 @@ static int ft1000mp_send_priv_cmd(RIG *rig, unsigned char ci); static const yaesu_cmd_set_t ncmd[] = { - { 1, { 0x00, 0x00, 0x00, 0x00, 0x01 } }, /* split = off */ - { 1, { 0x00, 0x00, 0x00, 0x01, 0x01 } }, /* split = on */ - { 0, { 0x00, 0x00, 0x00, 0x00, 0x02 } }, /* recall memory */ - { 0, { 0x00, 0x00, 0x00, 0x00, 0x03 } }, /* memory operations */ - { 1, { 0x00, 0x00, 0x00, 0x00, 0x05 } }, /* select vfo A */ - { 1, { 0x00, 0x00, 0x00, 0x01, 0x05 } }, /* select vfo B */ - { 0, { 0x00, 0x00, 0x00, 0x00, 0x06 } }, /* copy memory data to vfo A */ - { 1, { 0x00, 0x00, 0x00, 0x01, 0x09 } }, /* RX clarifier on */ - { 1, { 0x00, 0x00, 0x00, 0x00, 0x09 } }, /* RX clarifier off */ - { 1, { 0x00, 0x00, 0x00, 0x81, 0x09 } }, /* TX clarifier on */ - { 1, { 0x00, 0x00, 0x00, 0x80, 0x09 } }, /* TX clarifier off */ - { 0, { 0x00, 0x00, 0x00, 0xFF, 0x09 } }, /* set clarifier offset */ - - { 0, { 0x00, 0x00, 0x00, 0x00, 0x0a } }, /* set VFOA freq */ - { 0, { 0x00, 0x00, 0x00, 0x00, 0x8a } }, /* set VFOB freq */ - - { 1, { 0x00, 0x00, 0x00, 0x00, 0x0c } }, /* vfo A mode set LSB */ - { 1, { 0x00, 0x00, 0x00, 0x01, 0x0c } }, /* vfo A mode set USB */ - { 1, { 0x00, 0x00, 0x00, 0x02, 0x0c } }, /* vfo A mode set CW-USB */ - { 1, { 0x00, 0x00, 0x00, 0x03, 0x0c } }, /* vfo A mode set CW-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x04, 0x0c } }, /* vfo A mode set AM */ - { 1, { 0x00, 0x00, 0x00, 0x05, 0x0c } }, /* vfo A mode set AM sync */ - { 1, { 0x00, 0x00, 0x00, 0x06, 0x0c } }, /* vfo A mode set FM */ - { 1, { 0x00, 0x00, 0x00, 0x07, 0x0c } }, /* vfo A mode set FMW? */ - { 1, { 0x00, 0x00, 0x00, 0x08, 0x0c } }, /* vfo A mode set RTTY-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x09, 0x0c } }, /* vfo A mode set RTTY-USB */ - { 1, { 0x00, 0x00, 0x00, 0x0a, 0x0c } }, /* vfo A mode set DATA-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x0b, 0x0c } }, /* vfo A mode set DATA-FM */ - - { 1, { 0x00, 0x00, 0x00, 0x80, 0x0c } }, /* vfo B mode set LSB */ - { 1, { 0x00, 0x00, 0x00, 0x81, 0x0c } }, /* vfo B mode set USB */ - { 1, { 0x00, 0x00, 0x00, 0x82, 0x0c } }, /* vfo B mode set CW-USB */ - { 1, { 0x00, 0x00, 0x00, 0x83, 0x0c } }, /* vfo B mode set CW-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x84, 0x0c } }, /* vfo B mode set AM */ - { 1, { 0x00, 0x00, 0x00, 0x85, 0x0c } }, /* vfo B mode set AM */ - { 1, { 0x00, 0x00, 0x00, 0x86, 0x0c } }, /* vfo B mode set FM */ - { 1, { 0x00, 0x00, 0x00, 0x87, 0x0c } }, /* vfo B mode set FMN */ - { 1, { 0x00, 0x00, 0x00, 0x88, 0x0c } }, /* vfo B mode set DATA-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x89, 0x0c } }, /* vfo B mode set DATA-LSB */ - { 1, { 0x00, 0x00, 0x00, 0x8a, 0x0c } }, /* vfo B mode set DATA-USB */ - { 1, { 0x00, 0x00, 0x00, 0x8b, 0x0c } }, /* vfo B mode set DATA-FM */ - - { 0, { 0x00, 0x00, 0x00, 0x00, 0x0e } }, /* update interval/pacing */ - { 1, { 0x00, 0x00, 0x00, 0x00, 0x0F } }, /* PTT OFF */ - { 1, { 0x00, 0x00, 0x00, 0x01, 0x0F } }, /* PTT ON */ - { 1, { 0x00, 0x00, 0x00, 0x03, 0x10 } }, /* status update VFO A & B update */ - { 1, { 0x00, 0x00, 0x00, 0x02, 0x10 } }, /* status update operating data */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0x01 } }, /* 0 split = off */ + { 1, { 0x00, 0x00, 0x00, 0x01, 0x01 } }, /* 1 split = on */ + { 0, { 0x00, 0x00, 0x00, 0x00, 0x02 } }, /* 2 recall memory */ + { 0, { 0x00, 0x00, 0x00, 0x00, 0x03 } }, /* 3 memory operations */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0x05 } }, /* 4 select vfo A */ + { 1, { 0x00, 0x00, 0x00, 0x01, 0x05 } }, /* 5 select vfo B */ + { 0, { 0x00, 0x00, 0x00, 0x00, 0x06 } }, /* 6 copy memory data to vfo A */ + { 1, { 0x00, 0x00, 0x00, 0x01, 0x09 } }, /* 7 RX clarifier on */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0x09 } }, /* 8 RX clarifier off */ + { 1, { 0x00, 0x00, 0x00, 0x81, 0x09 } }, /* 9 TX clarifier on */ + { 1, { 0x00, 0x00, 0x00, 0x80, 0x09 } }, /* 10 TX clarifier off */ + { 0, { 0x00, 0x00, 0x00, 0xFF, 0x09 } }, /* 11 set clarifier offset */ + + { 0, { 0x00, 0x00, 0x00, 0x00, 0x0a } }, /* 12 set VFOA freq */ + { 0, { 0x00, 0x00, 0x00, 0x00, 0x8a } }, /* 13 set VFOB freq */ + + { 1, { 0x00, 0x00, 0x00, 0x00, 0x0c } }, /* 14 vfo A mode set LSB */ + { 1, { 0x00, 0x00, 0x00, 0x01, 0x0c } }, /* 15 vfo A mode set USB */ + { 1, { 0x00, 0x00, 0x00, 0x02, 0x0c } }, /* 16 vfo A mode set CW-USB */ + { 1, { 0x00, 0x00, 0x00, 0x03, 0x0c } }, /* 17 vfo A mode set CW-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x04, 0x0c } }, /* 18 vfo A mode set AM */ + { 1, { 0x00, 0x00, 0x00, 0x05, 0x0c } }, /* 19 vfo A mode set AM sync */ + { 1, { 0x00, 0x00, 0x00, 0x06, 0x0c } }, /* 20 vfo A mode set FM */ + { 1, { 0x00, 0x00, 0x00, 0x07, 0x0c } }, /* 21 vfo A mode set FMW? */ + { 1, { 0x00, 0x00, 0x00, 0x08, 0x0c } }, /* 22 vfo A mode set RTTY-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x09, 0x0c } }, /* 23 vfo A mode set RTTY-USB */ + { 1, { 0x00, 0x00, 0x00, 0x0a, 0x0c } }, /* 24 vfo A mode set DATA-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x0b, 0x0c } }, /* 25 vfo A mode set DATA-FM */ + + { 1, { 0x00, 0x00, 0x00, 0x80, 0x0c } }, /* 26 vfo B mode set LSB */ + { 1, { 0x00, 0x00, 0x00, 0x81, 0x0c } }, /* 27 vfo B mode set USB */ + { 1, { 0x00, 0x00, 0x00, 0x82, 0x0c } }, /* 28 vfo B mode set CW-USB */ + { 1, { 0x00, 0x00, 0x00, 0x83, 0x0c } }, /* 29 vfo B mode set CW-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x84, 0x0c } }, /* 30 vfo B mode set AM */ + { 1, { 0x00, 0x00, 0x00, 0x85, 0x0c } }, /* 31 vfo B mode set AM */ + { 1, { 0x00, 0x00, 0x00, 0x86, 0x0c } }, /* 32 vfo B mode set FM */ + { 1, { 0x00, 0x00, 0x00, 0x87, 0x0c } }, /* 33 vfo B mode set FMN */ + { 1, { 0x00, 0x00, 0x00, 0x88, 0x0c } }, /* 34 vfo B mode set DATA-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x89, 0x0c } }, /* 35 vfo B mode set DATA-LSB */ + { 1, { 0x00, 0x00, 0x00, 0x8a, 0x0c } }, /* 36 vfo B mode set DATA-USB */ + { 1, { 0x00, 0x00, 0x00, 0x8b, 0x0c } }, /* 37 vfo B mode set DATA-FM */ + + { 0, { 0x00, 0x00, 0x00, 0x00, 0x0e } }, /* 38 update interval/pacing */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0x0F } }, /* 39 PTT OFF */ + { 1, { 0x00, 0x00, 0x00, 0x01, 0x0F } }, /* 40 PTT ON */ + { 1, { 0x00, 0x00, 0x00, 0x03, 0x10 } }, /* 41 status update VFO A & B update */ + { 1, { 0x00, 0x00, 0x00, 0x02, 0x10 } }, /* 42 status update operating data */ // We only ask for the 1st 3 status bytes // The MARK-V was not recognizing the 6-byte request // This should be all we need as we're only getting the VFO - { 1, { 0x00, 0x00, 0x00, 0x00, 0xFA } }, /* Read status flags */ - /* { 0, { 0x00, 0x00, 0x00, 0x00, 0x70 } }, */ /* keyer commands */ - /* { 1, { 0x00, 0x00, 0x00, 0x00, 0x81 } }, */ /* tuner off */ - /* { 1, { 0x00, 0x00, 0x00, 0x01, 0x81 } }, */ /* tuner on */ - /* { 1, { 0x00, 0x00, 0x00, 0x00, 0x82 } }, */ /* tuner start*/ - { 1, { 0x00, 0x00, 0x00, 0x00, 0x85 } }, /* A>B */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0xFA } }, /* 43 Read status flags */ + { 1, { 0x00, 0x00, 0x00, 0x00, 0x85 } }, /* 44 A>B */ + /* { 0, { 0x00, 0x00, 0x00, 0x00, 0x70 } }, */ /* 45 keyer commands */ + /* { 1, { 0x00, 0x00, 0x00, 0x00, 0x81 } }, */ /* 46 tuner off */ + /* { 1, { 0x00, 0x00, 0x00, 0x01, 0x81 } }, */ /* 47 tuner on */ + /* { 1, { 0x00, 0x00, 0x00, 0x00, 0x82 } }, */ /* 48 tuner start*/ }; commit 871dcbe8a3497f91b8db92531a274fb196b36e29 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Apr 21 17:08:06 2022 -0500 Add split functions to FT1000MP models ft1000mp_set_split_mode ft1000mp_get_split_mode ft100mp_get_split_freq_mode https://github.com/Hamlib/Hamlib/issues/1014 diff --git a/rigs/yaesu/ft1000mp.c b/rigs/yaesu/ft1000mp.c index 03f5b1f1..4f432993 100644 --- a/rigs/yaesu/ft1000mp.c +++ b/rigs/yaesu/ft1000mp.c @@ -115,8 +115,12 @@ static int ft1000mp_open(RIG *rig); static int ft1000mp_set_freq(RIG *rig, vfo_t vfo, freq_t freq); static int ft1000mp_get_freq(RIG *rig, vfo_t vfo, freq_t *freq); static int ft1000mp_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); +static int ft1000mp_set_split_mode(RIG *rig, vfo_t vfo, rmode_t tx_mode, pbwidth_t tx_width); +static int ft1000mp_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_width); static int ft1000mp_set_split_freq_mode(RIG *rig, vfo_t vfo, freq_t freq, rmode_t mode, pbwidth_t width); +static int ft1000mp_get_split_freq_mode(RIG *rig, vfo_t vfo, freq_t *freq, + rmode_t *mode, pbwidth_t *width); static int ft1000mp_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq); static int ft1000mp_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); @@ -312,7 +316,7 @@ const struct rig_caps ft1000mp_caps = RIG_MODEL(RIG_MODEL_FT1000MP), .model_name = "FT-1000MP", .mfg_name = "Yaesu", - .version = "20211113.0", + .version = "20220421.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -424,7 +428,10 @@ const struct rig_caps ft1000mp_caps = .set_split_freq = ft1000mp_set_split_freq, .get_split_freq = ft1000mp_get_split_freq, + .set_split_mode = ft1000mp_set_split_mode, + .get_split_mode = ft1000mp_get_split_mode, .set_split_freq_mode = ft1000mp_set_split_freq_mode, + .get_split_freq_mode = ft1000mp_get_split_freq_mode, .set_split_vfo = ft1000mp_set_split_vfo, .get_split_vfo = ft1000mp_get_split_vfo, @@ -448,7 +455,7 @@ const struct rig_caps ft1000mpmkv_caps = RIG_MODEL(RIG_MODEL_FT1000MPMKV), .model_name = "MARK-V FT-1000MP", .mfg_name = "Yaesu", - .version = "20211014.0", + .version = "20220421.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -560,7 +567,10 @@ const struct rig_caps ft1000mpmkv_caps = .set_split_freq = ft1000mp_set_split_freq, .get_split_freq = ft1000mp_get_split_freq, + .set_split_mode = ft1000mp_set_split_mode, + .get_split_mode = ft1000mp_get_split_mode, .set_split_freq_mode = ft1000mp_set_split_freq_mode, + .get_split_freq_mode = ft1000mp_get_split_freq_mode, .set_split_vfo = ft1000mp_set_split_vfo, .get_split_vfo = ft1000mp_get_split_vfo, @@ -584,7 +594,7 @@ const struct rig_caps ft1000mpmkvfld_caps = RIG_MODEL(RIG_MODEL_FT1000MPMKVFLD), .model_name = "MARK-V Field FT-1000MP", .mfg_name = "Yaesu", - .version = "20211014.0", + .version = "20220421.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -696,7 +706,10 @@ const struct rig_caps ft1000mpmkvfld_caps = .set_split_freq = ft1000mp_set_split_freq, .get_split_freq = ft1000mp_get_split_freq, + .set_split_mode = ft1000mp_set_split_mode, + .get_split_mode = ft1000mp_get_split_mode, .set_split_freq_mode = ft1000mp_set_split_freq_mode, + .get_split_freq_mode = ft1000mp_get_split_freq_mode, .set_split_vfo = ft1000mp_set_split_vfo, .get_split_vfo = ft1000mp_get_split_vfo, @@ -1781,11 +1794,56 @@ static int ft1000mp_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq) RETURNFUNC(ft1000mp_set_freq(rig, RIG_VFO_B, tx_freq)); } +static int ft1000mp_set_split_mode(RIG *rig, vfo_t vfo, rmode_t tx_mode, pbwidth_t tx_width) +{ + int retval; + retval = rig_set_mode(rig, RIG_VFO_B, tx_mode, tx_width); + RETURNFUNC(retval); +} + +static int ft1000mp_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_width) +{ + int retval; + retval = rig_get_mode(rig, RIG_VFO_B, tx_mode, tx_width); + RETURNFUNC(retval); +} + static int ft1000mp_set_split_freq_mode(RIG *rig, vfo_t vfo, freq_t freq, rmode_t mode, pbwidth_t width) { - // don't believe mode on VFOB can be different than mode on VFOA - return ft1000mp_set_split_freq(rig, vfo, freq); + int retval; + retval = rig_set_mode(rig, RIG_VFO_B, mode, width); + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s: rig_set_mode failed: %s\n", __func__, rigerror(retval)); + RETURNFUNC(retval); + } + retval = ft1000mp_set_split_freq(rig, vfo, freq); + if (retval == RIG_OK) + { + rig->state.cache.freqMainB = freq; + rig->state.cache.modeMainB = mode; + } + RETURNFUNC(retval); +} + +static int ft1000mp_get_split_freq_mode(RIG *rig, vfo_t vfo, freq_t *freq, + rmode_t *mode, pbwidth_t *width) +{ + int retval; + retval = rig_get_mode(rig, RIG_VFO_B, mode, width); + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s: rig_set_mode failed: %s\n", __func__, rigerror(retval)); + RETURNFUNC(retval); + } + retval = ft1000mp_get_split_freq(rig, vfo, freq); + if (retval == RIG_OK) + { + rig->state.cache.freqMainB = *freq; + rig->state.cache.modeMainB = *mode; + } + RETURNFUNC(retval); } static int ft1000mp_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq) commit 3dd9277e7902f8647b6ae6798d01a8b939403d6b Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Apr 19 23:08:46 2022 -0500 Reduce debug in misc.c diff --git a/src/misc.c b/src/misc.c index d8d99768..b8d94def 100644 --- a/src/misc.c +++ b/src/misc.c @@ -2451,7 +2451,7 @@ long long HAMLIB_API rig_get_caps_int(rig_model_t rig_model, enum rig_caps_int_e rig_caps) { const struct rig_caps *caps = rig_get_caps(rig_model); - rig_debug(RIG_DEBUG_TRACE, "%s: getting rig_caps=%u\n", __func__, rig_caps); + //rig_debug(RIG_DEBUG_TRACE, "%s: getting rig_caps=%u\n", __func__, rig_caps); switch (rig_caps) { commit 2f29f326ab00492e79dd42631ee3d94aca881565 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Apr 19 23:06:03 2022 -0500 Ensure cache is update for split https://github.com/Hamlib/Hamlib/issues/1012 diff --git a/src/rig.c b/src/rig.c index c556c26d..a8a908a7 100644 --- a/src/rig.c +++ b/src/rig.c @@ -4524,6 +4524,8 @@ int HAMLIB_API rig_set_split_vfo(RIG *rig, case RIG_VFO_B: rx_vfo = split == 1 ? RIG_VFO_A : RIG_VFO_B; break; } + rig->state.cache.split = split; + rig->state.cache.split_vfo = tx_vfo; rx_vfo = vfo_fixup(rig, rx_vfo, split); tx_vfo = vfo_fixup(rig, tx_vfo, split); rig->state.rx_vfo = rx_vfo; commit 0405498b0725c54652fcd485ecaba95d0fd89d92 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Apr 19 18:10:41 2022 -0500 Fix FT-817/818 set_split to set split cache https://github.com/Hamlib/Hamlib/issues/1012 diff --git a/rigs/yaesu/ft817.c b/rigs/yaesu/ft817.c index 4bd37ce3..8ef7b811 100644 --- a/rigs/yaesu/ft817.c +++ b/rigs/yaesu/ft817.c @@ -1890,6 +1890,8 @@ static int ft817_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) return n; } + rig->state.cache.split = split; + return RIG_OK; } commit 4ac7d024e8add9cdcb4d73cf569eea95f3307799 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Apr 19 17:42:29 2022 -0500 Make FT-817/FT-818 return cached VFOB freq when split and transmitting https://github.com/Hamlib/Hamlib/issues/1012 diff --git a/rigs/yaesu/ft817.c b/rigs/yaesu/ft817.c index e190d5a7..4bd37ce3 100644 --- a/rigs/yaesu/ft817.c +++ b/rigs/yaesu/ft817.c @@ -295,7 +295,7 @@ const struct rig_caps ft817_caps = RIG_MODEL(RIG_MODEL_FT817), .model_name = "FT-817", .mfg_name = "Yaesu", - .version = "20220407.0", + .version = "20220419.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -442,7 +442,7 @@ const struct rig_caps ft818_caps = RIG_MODEL(RIG_MODEL_FT818), .model_name = "FT-818", .mfg_name = "Yaesu", - .version = "20200710.0", + .version = "20220419.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -821,7 +821,14 @@ static int ft817_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) int retries = rig->state.rigport.retry + 1; // +1 because, because 2 steps are needed even in best scenario - rig_debug(RIG_DEBUG_VERBOSE, "%s: called\n", __func__); + rig_debug(RIG_DEBUG_VERBOSE, "%s: called, vfo=%s, ptt=%d, split=%d\n", __func__, rig_strvfo(vfo), rig->state.cache.ptt, rig->state.cache.split); + + // we can't query VFOB while in transmit and split mode + if (rig->state.cache.ptt && vfo==RIG_VFO_B && rig->state.cache.split) + { + *freq = rig->state.cache.freqMainB; + return RIG_OK; + } while ((f1 == 0 || f1 != f2) && retries-- > 0) { commit 5427b4cf863e0dc6f59727e0a9a3e480ab9b4055 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Apr 16 22:47:51 2022 -0500 Promote U... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-02-22 19:24:15
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via d04f4b6b3b53e7b630ebecfd46fa6a7fc257e90e (commit) via 1874f3a92a458db793bf309a5c1439ae33dd00e6 (commit) via a41df584876f5150705377d1524a0b5dbfefce28 (commit) via 0cb65577490c188b681c83e8c1bcf4e25957cfe9 (commit) via 9e762a3b10d9dfe1137633072880045cbf7b90b9 (commit) via 18dd9aa169151b2c71943cd7eb7c6396ca7944b0 (commit) via 2d51b635c23e286949d9891fb86edcf0cb967a1d (commit) via 51247efbdddab713b971c3dfef026e913adb1e78 (commit) via d6f05e1974226b505e16f2f2314fa7a71b7779e3 (commit) via 92161c989a5b2f95ec80cc12d87e0b04166a9d1c (commit) via 7cc2ca30b04c287df00ee34c243fe81b7427ff73 (commit) via 05fa5b8f60454fb84e02d99c736ad44f2c224b81 (commit) via 09ea2693c2c1a84543a55f34dae84fec14818a2a (commit) via 7cf8ea393adc59cf088fb135ece0ab403b219530 (commit) via 8073f745e0ca392855d49f460652a1aeca5e243d (commit) via 3752b7ef9f7158fb626306a2098427cff5b51a2f (commit) via 453e831d6380675a559b67dcd267fa9e2c0168b7 (commit) via 523a22359a9e4e1096e12bf86e8cd66b2de6c7a9 (commit) via dabf1f2c61289028e11913f4cfe767b0f3761f46 (commit) via 8b40735752f89a5381623311363e162fabb64440 (commit) via f0a9832669329dbbed5b51158e539fa2881494b9 (commit) via 4d6633e46f8ac182d528217714c5e3622a9c3983 (commit) via 3c9b1203bb2c0e68c8376d468dc04eb39c728ad0 (commit) via 15ab655ecc05ea18cea044c96cd63e98877ffbe9 (commit) via c0630312a3856534c6eaf9a12dc7336abaa35239 (commit) via 779c2d344e3153f774de2f8b48157e8d81b11663 (commit) via 44c4e45eece49382f53301378f4bced125b37832 (commit) via 4b60373d66f11d47b5125592074fc0374dd39103 (commit) via 799b588a7c6c325f55a3f20a064edba9aa04e3e4 (commit) via 91652dbaee4cb52c2436cdbe856962c99ae32297 (commit) via faa5f5d19a241dedbb9fa3fb71b748e420abd654 (commit) via d86e2b980a8d416323e7b1f47ebf60f1a746fabe (commit) via 2c12e5d09f7a8a02d7fec9ca2afc0709aa03da98 (commit) via 2a852aee1b8d8c0bd7972065717c6b642b2318d9 (commit) via 86af300d4e1d08e0b4cf38b9ee376a26e1c50954 (commit) via 98887b32dafe9e55f6e8dc6a003b71a4b5c0fc8a (commit) via 7a5bcf0f4afdf46b69054046b3a853bdc723dd79 (commit) via eac7d76a07a0875a26f59f0907794eb21f65ddab (commit) via d44ca477ae3ee5e19d60b2be913d13370ea5ee2b (commit) via 64a841d24951b0d0227d37d4c10a4f1bfde129a1 (commit) via 76805ae60c9dc3168d1d8a7aaac99cdda6e289f5 (commit) via a770d5c0b37b44b62d954de90685afbcbf3a187e (commit) via e70db413a029a5e9fffa6149b14ef0f851c0c2d8 (commit) via 65cc7a76a347db86adc2d63bee7c08d0bdf262a7 (commit) via ea7eff2f3be73d25bce138a1c64d73b5e41f5a06 (commit) via c8d5f8ca07e7195e40fdc9ab4167201b5fb44c0d (commit) via a360bd0a070f5a451239b39d6e621643df0cf219 (commit) via b1acff58778371584d5892b0d3a607882ef49623 (commit) via 9a3fbc09db644c2d1ac6854011b968a64686a97b (commit) via 498e09e22c16c9644afce6d8dfe45f309c5620f0 (commit) via 9a0ca5bf835de8c9edec769135b79dc837f72b2c (commit) via 656ba431c377eaa24d6a20e10754b1144529b1b5 (commit) via 5e6a99b48fba8225671c35a07f1251631b4ffab1 (commit) via 56dc4471d95f461b413b05fb2d5b9f2283e39227 (commit) via fe9760a6250fed7edadfc29a79e099e235a84364 (commit) via e645f3412035b32dd3b8dff3a955a3ff0d9cb7ac (commit) via fa167379e503c9ea50259d57591255e3d1b3fcbd (commit) via 24660644e90d91fa5ef49f96fa317691267ced96 (commit) via d813cae42611046a0df45c8d4bb207b1f59a8491 (commit) via 205b7c27b6e866bf2fe8663d6a3dbcfed8ef9459 (commit) via d209438549048b303e058dc29b31ec1728d61fd6 (commit) via ac3f71bf237300d26cea17171502d27596c77aad (commit) via 44f06a95eb855c02f20d701c21497661f307c862 (commit) via 9a15ed057e025d012c89e44453616b9890db5b61 (commit) via b38c4cdb23b42437c1ac8f64ac2a29e7b6f8b601 (commit) via 299bcdc6b9b84aea03627b7158318425f4549d18 (commit) via 1b2e3154b77ee66b0bdefe3ee055eeadccd33543 (commit) via a8426d14886c5a2893f40d9b05411d51c495ec33 (commit) via e4939b79d15a2ea55bd841791c8d5b85b0582e93 (commit) via 79ef9b7c200936ba0cb5c69d9dd3fcf7522f9c5e (commit) via e166cfa7ea13425af7b8a0a639deaada8e77e06e (commit) via 6202b41c87c0f9627f7b490ead225fe88fb57975 (commit) via 191aabc087373cbde51be654f16691f93b804cc9 (commit) via a9916a8506b5da3f52e2c36f59328e1c324c0fd0 (commit) via 81202d34777972570f02c0508f527b2738967808 (commit) via 982f88035c639fddec5244f80758ed1a9b5c9f2b (commit) via 74b3d13d6a3e624e77d74680a8d3813a811e76e0 (commit) via 144debb46a7bd2b85e799251b79ca8f11f862d56 (commit) via 09e5d4089ce36db4526866a017add862a6cdb29a (commit) via 9e8c68ccdff1dffde37a6eb4332b6bbf248a2507 (commit) via 6bfa103b32e527a770bbee6764eb35d08e092d5b (commit) via 96f9e6aceaae6d8dd2dc00a7caff454553677ec8 (commit) via abca36a6f8948ae163f789953cdc7140dc950777 (commit) via 5c1b328b2256288c71d6f59c7590c5b9bdb647af (commit) via 2f38a32b0ab6ff0610ce4f296ec748f4cbbfa231 (commit) via 43f8a1d68026e68b1e2a4408f8c2c46e31f50c17 (commit) via f2a41a6452ad7f27edc76df4adc45865791d7bbb (commit) via a0fc3eaffa0434a4d7d9ada236d94a08e578d72c (commit) via 599761f196844c5d51bb2874a9a2c9a1155c1639 (commit) via 524dd1f8c206a0642dc03b0a8969a3007470ca4e (commit) via 7876f17551f7e2638654995d2e5f1d6a903f390b (commit) via 7c2d9ec0f05eb0e9e8f4696c6665dae3d648ac85 (commit) via 0b7210b01c44c0e8d3ecc847d3f1f27304b32dea (commit) via 0ec19b6354285c8e4aeeeeb32f2e0703d1603537 (commit) via 7e1e90352edf1f325af7027edd2e3962f5680d5e (commit) via 3df4571ec40e6c598aafa903d9e72df7ecc7bc71 (commit) via 6934536e097ade7ae2e60d3335b71f04a39e1bce (commit) via 92eb1bc4bc65cb629fa64a5c8ffeb38ad94a3c88 (commit) via f7ab6199387075094c3d27f55f6ffedd16232c96 (commit) via 7f406427cab5d9066eddf4e6668054c1a6d88a04 (commit) via 2061ab92a8b69e8473938a57396d574752d8e0c3 (commit) via 2989782286a166e803e4a3d44c3e416dc6f1cd1d (commit) via 776c68e3b1e8b121e1d8818522c4e382d157dae2 (commit) via 6f486e69d6d94c360a35f80feaf07f1ba489e905 (commit) via 5976e6a65f331625d5f53c0c237ff74dbc8d63be (commit) via 278693ea367820ca6e6f6e77b08988641314f07f (commit) via ceb3dd161f4284d46ec733a794f24427ed53f223 (commit) via a5bd84547a97de9dba13a84ba55e190ab7e53b09 (commit) via 8c34ce1a2daa7f0f4a26d2aa4d464cd7c5565909 (commit) via 30aff6102ea2e825b6e4cbd0595ee7dc6876ee8c (commit) via db1de6bfd2555420d6c63bb2ed55cf362976e3ba (commit) via adeb2980a5c8563977d51e55b10daf940aab32a1 (commit) via 69b1f272d7c03f8107bd54e2be8fc07590649301 (commit) via 61656760ef0930be9def534b0d53462839b03e35 (commit) via 9c60d1b9a0c3d3d9684ddfc13725b08910bcda68 (commit) via 92bd1d4e8315a5ce8916085a7c7d3af7a1e8379b (commit) via c1ed899c192ffdbf1d76b0e9c4892e6a4057c5cb (commit) via 1c5826d533fd2f5d34c75798e95d40f759d18a09 (commit) via 27f3cafc6e28157f0fa5da51762a65f8c0494e30 (commit) via 9ae7f7535db68e4b811b313efbd6fa541611b4cf (commit) via 68e121d82c8000d60075c51a9e1f115772ad0620 (commit) via d6d446944bb45b213ce227aa33aded4b1b214635 (commit) via 3a77601ca5da42ccdbd7203c6bd4394df62c1826 (commit) via b9d3de3cbf92503ff1f7b1db3c9936adca53b1e1 (commit) via 836fae0ba030bcc13f8ecd39c8b18de1e5afaa5c (commit) via 81d61c09cc0dfdad1addd2808cf42ba6b21a33cf (commit) via 1d9c067dd2422463789a450706960ecd608d5dd2 (commit) via 0062a09307c827678bdf65af80204ee4e01359b6 (commit) via 9aade8de3f525ee2ea7199e624ff7e57e3e02508 (commit) via 1bc9c0da7904f538d0b5369ceeecb0a56ffc4a66 (commit) via bbd20c45ddc97828282ea92425c1e7f7a6932023 (commit) via 5a1e73396cb81b77fbe76c897a4f809c822595c4 (commit) via 9852288992d6d8f5fe37eea4d903528955f70b4d (commit) via 3498fb1cf60d91e7d44020f49818b4d95dd56baf (commit) via a20a91e38124907d96429ac03297c5e20c7da547 (commit) via c4e01ddadbaebf429c41583a1b868ccff55e731b (commit) via 3b1b643df3f33237a50c24b70d3c864fc79c64d5 (commit) via 9ede1174a348ca51d1db8ce4a3a92b5959842c21 (commit) via 324e663d81b5d8bd2da8515691491bd63b0f92a5 (commit) via 950ed91e559778a2f92c6420a716a823d0c00929 (commit) via d5cd99b7f5ee25f6a6885532d7a5390f584fdd79 (commit) via 8efe1b4e3026dbf01e32c6101255d778c7689199 (commit) via 2b580d1c017ecf07b5bce4ad2dab6db527a3f127 (commit) via 4c6f9bf9f20d3131d986628cbbfb8a3ec077d6a7 (commit) via 4ae7d6d1587d73a7de74b61a1b75140bc0d47ca6 (commit) via da1400cd0d32de88163caa96c93348dfaaafa4ad (commit) via 9dd5f70b019221b4e43547b207c0fa9bbca98f29 (commit) via 41eedc94797366d90fff6f841d3c225ef2473ab0 (commit) via 011f9789e22b28cf31da3485364ccdd5474340ea (commit) via 51be4b4dc914932a6f7b23fe36e76a7ce6e3bbfb (commit) via f6941437ba4eb22080db02674f7591e3d7ad9fd4 (commit) via 668147885f93d79ca9f401dc2264e586d24e64b5 (commit) via 64af7ca65a9109fa77b2305bc9ea9c764c290f77 (commit) via 236caa0d726becfbd2ac8263b27a653d7890c9f9 (commit) via 931037450e4ea41b8ed93586903243a5a3f80eb2 (commit) via cd7af2934d66932e1bfc4dd6c7243c5142a5e1a9 (commit) via f08c7d7e36aba15495c4e745e6aceac8a7d7c2d0 (commit) via 4ef62a84369b4b1dd685e011aac3450214ae4313 (commit) via 615f102cccf2d29d4ff1cbf3335bf1b1001bf6de (commit) via 024e7b75551673df939fb1d70a8cdb174b702c3a (commit) via a33f1b7920ab5b9633c55255d8f4194862c8481e (commit) via 456ab24f58978bdb7ffd82a6d140e2b970a00b28 (commit) via 918ca72202fe8cc8614b569e0712f6b351d4d070 (commit) via 9102358fee90096e168c6277c61edb24c263c6c4 (commit) via 46cd85fb60b71f6176e9809a16d0896726919dcc (commit) via 2e218c56b62ed186552476ad1767391315a56f54 (commit) via 6e6d22ae36243efd7f0d6c418b11b16c0e5db329 (commit) via 171f58124392f320e4bf23be762e33cb4b1a4cb0 (commit) via 7b4b7ee630a2f60f5c0ca67069501775dda6ba28 (commit) via 9820d0314bdc26bc3c056b4eea10024130277197 (commit) via 63b31eac4e92bb345357d6434280adc693cef720 (commit) via 3c60636b80c2d2ad9d3ecd377a39ce7e288718d5 (commit) via f90c6a95ce410bc5e48864756a3e44cff89d0682 (commit) via 0588d3be3a22807e7e319315157df6f5cb8afb24 (commit) via b8802f3fee7a3878c07b32c3fbc7b6c0741f2741 (commit) via 991e31482087de0d09a4a48874c74d6f3e681d5c (commit) via 8e18fd624d208ecd9f1f4eeec5ae9f23638f60ca (commit) via 4e0ddf10d280094499cfe532908cf6a3ee42c725 (commit) via afd595d2da13d45c92547315172346c3edfc681a (commit) via dc34cae503c71e961d0ca547dbe7dfebfa243f76 (commit) via 86c62d5dbbdf279c1bb96ec83587a90a53603fc2 (commit) via 78b9ad122ea41b37d3aaadfc1e370ad1274b130d (commit) via fab7f4d54c2a50a6dad820b02638aa575a3db2fe (commit) via f7ab1e62ccf96278c5e18d9f9e2ef6f38c77d690 (commit) via b5bcae4af35c2f06a292383dfbc4c2f3db6c246c (commit) via f696123a3bac480c2c6582728d224f8604166f55 (commit) via 2028d4d1fa6c57e4634284fcef16957a3294b695 (commit) via b9d6ba4585e7a0f0819e342e629ad30335e7d3af (commit) via 469ab0f5a84da4ae13e8483eeea9384f3b6647a3 (commit) via 6c344493ae9e6e2b3bd438efcb9198a1402a8e60 (commit) via 81bb70bb84368f22d4080604999e88b03cf2107a (commit) via 401e718d607de87ceb4ce90de60c80bc13ae4971 (commit) via 551594f48df569000f8675e8783618eb50dd8f3d (commit) via 39e93ef3daf44c3e1931075b3a3c8f756701d992 (commit) via 9646895258ddfc4ffbb8c602d14f38c361d11e4c (commit) via d6d345d918a055d03ed965fafef05f2dc05bad01 (commit) via 9407ef38600326d7c106093597359e77beff8622 (commit) via f3a38b73fccbc30ce9973bffcc3a270a01462ef0 (commit) via a277d7ab9b84911a817b6e98b32a2e937a7f87d5 (commit) via cb36210ddbae37ef8a096a0df2035036e81dd841 (commit) via 27adcc2e75bdae30f184104160008764360b00d3 (commit) via aab335b09babbb976a42f816797e75239174721f (commit) via d4bb78d751322c2dad6220ee663f3d1a738f4fb8 (commit) via fe0894770021f083929e110c906cbcb173cdfff4 (commit) via 67e28c4faf691ec33a214717d91a9fa80084b8a4 (commit) via a22b21f3d7fa9fc94e11587f1cd1b5e7f11169d4 (commit) via 6d7d2804de299da7ec40e2b280125d91e021673d (commit) via 9e86e622385032bc51000e614d7b03d15a51e34d (commit) via 8dc8b99393ceba0635e5a0948e59e79ad85650c6 (commit) via 1c309b523eef315499a6d784c549003a845cd355 (commit) via 77e946c118182cc74fcc8775c9fed45c393d9225 (commit) via 4dfaa0383861ffca8425e179995302d6b63c1a24 (commit) via a2d5893437ea45558ee88d800f17d508604f7019 (commit) via 91102743d0852e24f8278e913c25868f352ca67e (commit) via c27ef08d5af5ae690d579e04ca8a153d119ee000 (commit) via 987af84908a3a6349b298f42e0de6b3244b7345b (commit) via 51da62f3fbc49386ed1a8363960afd8672d47b21 (commit) via 26e56921194fc22cdd5610a9988a81eb15fb4613 (commit) via f04aa34876694d77a8ae61e0a1b4a3f6601838d8 (commit) via 1beebfc835f16ce29499a66111753f992d11cff1 (commit) via 388738b78b8e1a76c1170ab19d3409a759fd1634 (commit) via 3bf3ed8aa6558941aa2d5ed508a230ded77f13a5 (commit) via 664604f7b6b7d73c0f78f6678bcbd582650e69b1 (commit) via 976cd61d2e9dddc3a038ef7abf599a29a9a3436b (commit) via 38d7697d0377ed7b48fb63286d24966b14f28465 (commit) via fba46c785013e93a3fcef11be18e296de7abc71e (commit) via bff29003eae33045920389f9d0be666b5d11c9f3 (commit) via 6f0d8bdccee0b3306a006c06e7a0173f8dd17d62 (commit) via 506fcd18819020c4210694294b999e7a4253c413 (commit) via 1f428c8d958313a08a79474d705f9c3d83cb8904 (commit) via be992b8a36a999726306f0214d847bbadd6587ea (commit) via 03aa7b1d835342ef9ef5e03c730d5c5819f96bc2 (commit) via 1eb474f2e60094e342a780f85cd9f9f018868bb3 (commit) via 8585a04284b40d843eeb7ece48bd6d8a897d9a73 (commit) via b650277642ccdb92bd6a668845639b65eec2806b (commit) via 610568784724af78372406675b77663735b5b4c3 (commit) via dc1a9dd2cd07855c71f17164cf77d0ba3e745613 (commit) via 1561bc96008536899a1ed566edf2fb386e5834c8 (commit) via 965d2dc52be31cbc21483a366f7286123c74d2f9 (commit) via 970d253866b42abafab99e0af99c2b3b1cd04d2c (commit) via ed4a667f77e9a3be32badbfad31d981d93b34b28 (commit) via 308a221c786b5e7e47b24e4fabea7ecfb2508a5d (commit) via 4d8e2c1f94b743872a4b2be49fd3103af363ee5f (commit) via 9ed935e10b8331b857d107f2e8e56ccbaf666344 (commit) via b6c5ecd58449693b661814bcdafaaf058cc7897f (commit) via 2d85464688f5be5f74b87b6dcfa077c69a6cc38b (commit) via 09c9b0155265d795a81e28f04f10420feebfd724 (commit) via 191ac98634581bdbed6c87bca6291473bc9cf336 (commit) via c45c088f494ce4b62c1bb1ac3a7882ee01d4f416 (commit) via f90af0d054bc185fef7cbcad08d9ca4ce523da22 (commit) via 265ac886466fab208ff4a4d45f81f5191079e4c2 (commit) via c3643451732afcfffeb4366e5ed40dddf06f2630 (commit) via 52ca1f5dfa890dca037f56b2d666e2c284195397 (commit) via 58d650a872b7d76e10d1c81f96aee1f234d9963b (commit) via 00f25c1e149ea637e8423f6f76bd2134527c5e37 (commit) via 98259ffa6dbfd49c42ccbf1c61e98645adb8b573 (commit) via b3e2110f8deb253a2fecac0f5091080a7f53e8e3 (commit) via 9aaed9e3138c9bfe55921a6b1f6bf6b07aef9a5d (commit) via a5a5cc90d8e30e241a2f9262db13cb74560a1d11 (commit) via 53c8abd307ad05e63efb1da6c330cbd68807e1eb (commit) via 92542cb02864f380c70475776370a5e0476bf0f6 (commit) via d86fafb598d2eef3f645381482c0af9759b64427 (commit) via 2f2cf4a68d16af05a9d53eb71f05a63c836e1711 (commit) via 5ca6650ddeea7f0211e8a061ed35ac588928c2b7 (commit) via 28174de21a4cc44bf54ce326f6252a33b7ecc65e (commit) via f0e57afd6306b12ede06806daf92812223682153 (commit) via 09c1d74a822fd53ec587ee7258e4c3c814f94274 (commit) via f48654e1998caf14b02351efa7df7928bda879d5 (commit) via 7ecd467126897b5fb126aed5ef89864b34ce5567 (commit) via 82dd8da9cd47dd71b874051580216859b8419fc3 (commit) via e2bb11aa4c5eb8187e3222f9c50a925561423cdd (commit) via f801244fb6d799e8bc8fcfb2a4134803aa5a0e9a (commit) via 0e5962a8166aadf6a08bd3f1d554164e3a6c6544 (commit) via aa3daf4eda7ae9894ff7b61096a87b0a560521a3 (commit) via 29ff10f455ee5b95120e315f7ed156ffa745ad5e (commit) via 165b5b29218f3143a6d64e959fff3c50fd0ef2e1 (commit) via 9e3afe2729ba63aaf754181d6ffb55df2365ec40 (commit) via 53424a3c56724263f4f2d26148e54b765016d1bf (commit) via e69ad3786d3cd515bf850ee5f1aa45f5e59d17ca (commit) via ea6f0bdff6e8f3020c4bd19539e9302e905fd1ed (commit) via fa67809b3248ae8578450e9a4a80ae3b52c0d514 (commit) via f213b2ce7a00614024dc7062819bba86ed539e73 (commit) via 5b9feffa7852b94a816d5f552bb78da967cd7dbc (commit) via d01e939559daa474794b74aa411b482db5914524 (commit) via fe167c7ff48c795901501f7365fdf328fb0143c7 (commit) via b2edec79bf59bbc9a4b5c927a524b65d1210a294 (commit) via 2de74e5c54ac36a45ae9dc87a5ff3bfc94f584ea (commit) via 91772295d761ff2c0c77296f1cb25794ab54fbb9 (commit) via 198d4c6db304066e0b1e76f5828adaa6cba6b72c (commit) via 30a06c4fc674d47986f731ce60855fee2f399ae8 (commit) via 194eb752685a68afb1f376ee6aa43db4a21f4c59 (commit) via b577f3bd51a9f35405b9d18ddc7ad72c98f9cd6a (commit) via 893d37d25fdca762700c513f73afc7ac9b8e9d03 (commit) via 2422de0951df312ea29a604803772e01d0635a8e (commit) via 3f3b74e408d237f00d5362a04c7d8bce8d6afd3b (commit) via dcc176a2635f24a6f936fb90f255768fb39ee264 (commit) via 014daefb5f7da136d73f9bd930ec9ecc4cbcdf4d (commit) via 3385a5f37bd0c217b07a0f5d4576cc1438aff069 (commit) via 18f7036fb09948ac99d3485f5afa833fd36357ec (commit) via 9538357ef4cdd417b464965625b1607884000640 (commit) via 906ac22ae4cddea3b400f44b988381d5a270c0a9 (commit) via ac3b85481847bac9241dd78fb0b1ab9d1336cc3d (commit) via 4c4b8debfcb4d1ee26114849fd7aca42f3df5817 (commit) via ae2c5b13e3024e2ebe75e1b6b94282b6c40fe69d (commit) via 01c164b2b5473e68238a97310d3d1130a66e99f1 (commit) via aac189ed1f81c383a81a9f2664eb0ea8af144f10 (commit) via 72cda702c932582aa4092f1632d4aeb7fed695ff (commit) via 36f516f840e23ac64d03b14b633fd23e362e3089 (commit) via 6a516b4a34b25a83e7d5d4df1856fa82c266e9a2 (commit) via 939b3e38851abf1028a0b7c3a666947b7e0eadb9 (commit) via a291def17fe147522f8e1e33e71b789925b76237 (commit) via a7f6d693ac64e5d63d5554251466414f5d22b7ac (commit) via 4793e9206bdafd3c59fd0411aad1ab737650305d (commit) via be16de711ce38ede5f003095fd08659be585de29 (commit) via d217bcac629afd00d9e79ace3d049db4f558da49 (commit) via 64847e5c302a2195bd42967def6e5ab2f24343be (commit) via 9c099165d5860e936a9fd11474b4d919ad648156 (commit) via 3f001cc9f62f9ae61bc38d42c07e6d9a651794cd (commit) via aaac79c55e5750708c6d9451c9602ac0f94c1168 (commit) via 66194804f9163812e3616edf1ddabd0a78e88e9b (commit) via abb3405caee36040c814aec1ca7112a27b3e00f4 (commit) via 789858c1db3f4357b955c9a2cf0b320b15667ce9 (commit) via b2254a56676b7a297508db02cf08c99184f35cd7 (commit) via acf682c4986a881286871b1ea06de4a01569c426 (commit) via 37ae6d1ca3c88206fe1bdde03109dd62b2851fb6 (commit) via f335a36d69f54235561e0f00c2208844f3ea1b90 (commit) via ab8a74a48d0540884242ab634c3e872e7ba37927 (commit) via 69bae15cf269d8edce38dc6438b3578ade096588 (commit) via d049c89e5eada0872762c528947a24ee96a78513 (commit) via 8c3a5e8d3c96bbe7e4966285711f2bf50aecfc74 (commit) via b53bc014e3ecb83639637f7c13910985e7b4b580 (commit) via 71ddc2e60d9a6f835f5ad68080153d43ee8daef9 (commit) via c503ba6806bb1bd295671285228932beed41b6a7 (commit) via f463eef2cfbaf3527e5859147c9dbd572ec6d470 (commit) via 20882cb18f547f2eac9e4c735524e165f8b1f09c (commit) via 8829a8011d3c90de9d11ba45682cabb9c8cc7474 (commit) via 3232117ebff9a119b87c6f5c3c1386fc958c53e4 (commit) via c2cb94e4122f9668318ab47eaa2f7ab888f4ee2f (commit) via 416144b62bfb19d0ddcf10980b4b255ca577e829 (commit) via 57617cda73dfbbd8ce817423d2c89cee2bd7a091 (commit) via d6e33fd562dcc285dd1dc6e3250acc5fd6db201e (commit) via 8372bba7f44050020fe7296adfcb3c43046c3442 (commit) via 9e140519db6a76487a7413e6e30a19b0545d0a87 (commit) via ea76b9e4955ae7e61969c6dd193e4f154dd39016 (commit) via 18f69356c9c30327db2d9fa97f302083c336c863 (commit) via b0ae08f7b7ed43f3df33354131b9defc3237d5b8 (commit) via dfc3725de3af80bd7d6d26e5d1e0aa4e0ab179c9 (commit) via 265be9f3132d9c6dfda6353ef281d550e49978ce (commit) via ac59a643c7971a6e951807018a23eb8db01bafbb (commit) via 4fd1acedfc50d973d0e43a1d40e90ac9c847d799 (commit) via 58b9e16099c2b0d82af4f7e6e052bf5c3f774777 (commit) via 21ac4aaf05f7de7fbcad0fbe1ca31fc5e6cb2971 (commit) via fd935597a9cddd7e58a6ddd9fcb526116ab5ba86 (commit) via b84086d7f657b12ba5c4a881c42a1a6fc4d4a17f (commit) via c88e32e0d60760e194130eb6616761e0a0b22a1d (commit) via 18ca415b4186f9fb05b16b81eb99954a36316b9b (commit) via fdae4f6aa5b7ba0bd7f5e7e526f19755ec45ad87 (commit) via 926eba4d1c85347acd0111fb3ff30fd5bd857701 (commit) via dff4f4f12411c78cca718e7342a2fbf66a2e1a71 (commit) via 00bdc638292c7532715dedad34a9ff90ab0ed23b (commit) via bf4afbcaa1d5baba010fb66e0ead8113c4160e9b (commit) via 4adcda259a6be21fd8f65545b2b0ec59f10a5c7e (commit) via 390d05ec69feb089f4d25dd98167749ce25ca273 (commit) via c280bd244088988bcb62e782751e9338a6638a6b (commit) via d84ac6ab5dcbe47cedae4647f919bc4da8a9dffa (commit) via 83562939fb14773773c09583af3f1ff3fa655261 (commit) via 9daf7394b134026ca07cb791e0c67aa4e47b324b (commit) via c3db2b07aeb58e85bcec1178818ae8c1b06a0219 (commit) via 3bf26fa65d07a99d945de1a0862e0b0d9c14a8fd (commit) via 05f4f00cbdb9682db570f387a1ccb48c80759862 (commit) via 405040b3755a9934b7125be9a9bbadc41c83f1ef (commit) via 20dd20032d472ebf51e30bf4ea5325bb2ff142bd (commit) via 7764b59f36bed972a76d82132b06a3bfe3a7debe (commit) via 814ac551e8968fc950e597f5ee210faee46fb946 (commit) via 660483325005a0ac59f79f171b0329672bfbee9d (commit) via bd8ced530ec50039739f416114c0bb8c48cf8949 (commit) via 0600adb077b18c700e63c04d454b25295f65751f (commit) via 086c3f7f1d909a57db3d7ab6d07464669ed35b66 (commit) via 13e50f1a03bf4422633922672ef633a57e1d3bb3 (commit) via bf8bce2d5a2cddb716f1755853b4dadb138955c7 (commit) via 3548ab8d811034199dddb4926a96bfd7be80baa4 (commit) via ed1210e97449ad80ee08aba5e0ea5cd712d2a494 (commit) via d96d616ce5533817ac0383865895143e31b5070b (commit) via b358437ceacdf8615ec9477a2d2c0d34c084bcb6 (commit) via e63fbf0812ebefaa537b3513fc5ae0d2ba8b0e89 (commit) via 7774cabfa6a8c3adfb15fa1916260f399ddd5029 (commit) via 579831926fd31c63e662ad41ec2bb21148460ee0 (commit) via 7bcc35ebc46f174ca7081e405926dbdf53257976 (commit) via 1cb47f6af4260f2ea0545fbe459742ca647f7a74 (commit) via 46055ac14ac524e49cb558871ceadc025c65be03 (commit) via 4cb1a35a914e906eff655cab8c32c4c17002cf04 (commit) via 088b7183056e5d16b195e16e3d46c00ee3d73579 (commit) via 3022ba279acde0e006ffca6885a8ca4a79a1de71 (commit) via 1d19a0ffbc219d1419610929867029254e7206b1 (commit) from 9731b5fda2124f9f570290b57aa8a7fbd3f7753f (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit d04f4b6b3b53e7b630ebecfd46fa6a7fc257e90e Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Feb 21 08:26:49 2022 -0600 Add validation handling for SH and RF in newcat.c Fix FTDX10 SH command formatting https://github.com/Hamlib/Hamlib/issues/973 diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 2ed7364e..8c01e2e5 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -8515,7 +8515,7 @@ int newcat_set_rx_bandwidth(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SH%c%d%02d;", main_sub_vfo, on, w); } - else if (is_ft2000 || is_ftdx10 || is_ftdx3000) + else if (is_ft2000 || is_ftdx3000) { SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "SH0%02d;", w); } @@ -10350,6 +10350,16 @@ int newcat_set_cmd_validate(RIG *rig) { strcpy(valcmd, ""); // nothing to validate } + else if (strncmp(priv->cmd_str, "SH", 2) == 0) + { + // could validate with SH but different formats need to be handled + strcpy(valcmd, ""); // nothing to validate + } + else if (strncmp(priv->cmd_str, "RF", 2) == 0) + { + // could validate with RF but different formats need to be handled + strcpy(valcmd, ""); // nothing to validate + } else { rig_debug(RIG_DEBUG_TRACE, "%s: %s not implemented\n", __func__, priv->cmd_str); diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 809a933a..beec2756 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220220" +#define NEWCAT_VER "20220221" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit 1874f3a92a458db793bf309a5c1439ae33dd00e6 Merge: 0cb65577 a41df584 Author: Michael Black <mdb...@ya...> Date: Sun Feb 20 22:10:12 2022 -0600 Merge pull request #972 from challinan/master Add support for K3 Morse send via KY(W) command commit a41df584876f5150705377d1524a0b5dbfefce28 Author: challinan <cha...@gm...> Date: Sun Feb 20 22:19:26 2022 -0500 Add support for K3 Morse send via KY(W) command diff --git a/rigs/kenwood/k3.c b/rigs/kenwood/k3.c index 10095839..b243c822 100644 --- a/rigs/kenwood/k3.c +++ b/rigs/kenwood/k3.c @@ -41,7 +41,7 @@ #define K3_FUNC_ALL (RIG_FUNC_NB|RIG_FUNC_VOX|RIG_FUNC_APF|\ RIG_FUNC_DUAL_WATCH|RIG_FUNC_DIVERSITY|\ - RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT) + RIG_FUNC_LOCK|RIG_FUNC_RIT|RIG_FUNC_XIT|RIG_FUNC_SEND_MORSE) #define K3_LEVEL_ALL (RIG_LEVEL_ATT|RIG_LEVEL_PREAMP|RIG_LEVEL_AGC|RIG_LEVEL_SQL|\ RIG_LEVEL_STRENGTH|RIG_LEVEL_ALC|RIG_LEVEL_RFPOWER|RIG_LEVEL_KEYSPD|\ @@ -2365,6 +2365,11 @@ int k3_set_func(RIG *rig, vfo_t vfo, setting_t func, int status) SNPRINTF(buf, sizeof(buf), "DV%c", (status == 0) ? '0' : '1'); break; + case RIG_FUNC_SEND_MORSE: + // Transmit a CW character - K3 does not return any response + snprintf(buf, sizeof(buf), "KYW%c", status); + break; + default: return kenwood_set_func(rig, vfo, func, status); } diff --git a/rigs/kenwood/kenwood.c b/rigs/kenwood/kenwood.c index bf26747a..04d86e85 100644 --- a/rigs/kenwood/kenwood.c +++ b/rigs/kenwood/kenwood.c @@ -337,6 +337,7 @@ transaction_write: int skip = strncmp(cmdstr, "RX", 2) == 0; skip |= strncmp(cmdstr, "RU", 2) == 0; skip |= strncmp(cmdstr, "RD", 2) == 0; + skip |= strncmp(cmdstr, "KYW", 3) == 0; if (skip) { commit 0cb65577490c188b681c83e8c1bcf4e25957cfe9 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Feb 20 10:31:25 2022 -0600 Update version in newcat.h diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index fa3d8715..809a933a 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220213" +#define NEWCAT_VER "20220220" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 commit 9e762a3b10d9dfe1137633072880045cbf7b90b9 Merge: 51247efb 18dd9aa1 Author: Michael Black <mdb...@ya...> Date: Sun Feb 20 09:09:59 2022 -0600 Merge pull request #970 from jleh/ft991-meter-cal Yaesu meter calibrations commit 18dd9aa169151b2c71943cd7eb7c6396ca7944b0 Author: Juuso Lehtinen <ju...@ka...> Date: Sun Feb 20 01:13:14 2022 +0200 Add better defaults for newcat meter cals diff --git a/rigs/yaesu/ft991.h b/rigs/yaesu/ft991.h index 54919939..78b3c14a 100644 --- a/rigs/yaesu/ft991.h +++ b/rigs/yaesu/ft991.h @@ -121,10 +121,10 @@ } \ } -#define FT991_VD_CAL { 3, \ +/* TBC */ +#define FT991_VD_CAL { 2, \ { \ { 0, 0.0f }, \ - { 189, 13.6f }, \ { 192, 13.8f }, \ } \ } diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 57297d2d..7b158886 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -150,21 +150,26 @@ const cal_table_float_t yaesu_default_swr_cal = // TODO: Provide sane defaults const cal_table_float_t yaesu_default_alc_cal = { - 3, + 2, { {0, 0.0f}, - {128, 1.0f}, - {255, 2.0f}, + {64, 1.0f} } }; -// TODO: Provide sane defaults const cal_table_float_t yaesu_default_comp_meter_cal = { - 2, + 9, { - {0, 0.0f}, - {255, 100.0f}, + { 0, 0.0f }, + { 40, 2.5f }, + { 60, 5.0f }, + { 85, 7.5f }, + { 135, 10.0f }, + { 150, 12.5f }, + { 175, 15.0f }, + { 195, 17.5f }, + { 220, 20.0f } } }; @@ -179,23 +184,21 @@ const cal_table_float_t yaesu_default_rfpower_meter_cal = } }; -// TODO: Provide sane defaults const cal_table_float_t yaesu_default_vd_meter_cal = { 2, { {0, 0.0f}, - {255, 1.0f}, + {190, 13.8f}, } }; -// TODO: Provide sane defaults const cal_table_float_t yaesu_default_id_meter_cal = { 2, { {0, 0.0f}, - {255, 1.0f}, + {100, 10.0f}, } }; @@ -5103,11 +5106,11 @@ int newcat_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) if (rig->caps->comp_meter_cal.size == 0) { - val->f = rig_raw2val_float(atoi(retlvl), &yaesu_default_comp_meter_cal) / 100; + val->f = rig_raw2val_float(atoi(retlvl), &yaesu_default_comp_meter_cal); } else { - val->f = rig_raw2val_float(atoi(retlvl), &rig->caps->comp_meter_cal) / 100; + val->f = rig_raw2val_float(atoi(retlvl), &rig->caps->comp_meter_cal); } break; commit 2d51b635c23e286949d9891fb86edcf0cb967a1d Author: Juuso Lehtinen <juu...@oh...> Date: Thu Feb 17 18:07:43 2022 +0200 Add ID, VD & Comp meter cals for FT991 Power level should return 0 when power is 0 diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index a9c0503e..aab8a408 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -185,6 +185,9 @@ const struct rig_caps ft991_caps = .chan_desc_sz = 0, .rfpower_meter_cal = FT991_RFPOWER_METER_CAL, .str_cal = FT991_STR_CAL, + .id_meter_cal = FT991_ID_CAL, + .vd_meter_cal = FT991_VD_CAL, + .comp_meter_cal = FT991_COMP_CAL, .chan_list = { { 1, 99, RIG_MTYPE_MEM, NEWCAT_MEM_CAP }, { 100, 117, RIG_MTYPE_EDGE, NEWCAT_MEM_CAP }, /* two by two */ diff --git a/rigs/yaesu/ft991.h b/rigs/yaesu/ft991.h index 302300c1..54919939 100644 --- a/rigs/yaesu/ft991.h +++ b/rigs/yaesu/ft991.h @@ -75,8 +75,9 @@ // Borrowed from FLRig -- Thanks to Dave W1HKJ #define FT991_RFPOWER_METER_CAL \ { \ - 6, \ + 7, \ { \ + {0, 0.0f}, \ {10, 0.8f}, \ {50, 8.0f}, \ {100, 26.0f}, \ @@ -108,6 +109,40 @@ } } +#define FT991_ID_CAL { 7, \ + { \ + { 0, 0.0f }, \ + { 53, 5.0f }, \ + { 65, 6.0f }, \ + { 78, 7.0f }, \ + { 86, 8.0f }, \ + { 98, 9.0f }, \ + { 107, 10.0f } \ + } \ +} + +#define FT991_VD_CAL { 3, \ + { \ + { 0, 0.0f }, \ + { 189, 13.6f }, \ + { 192, 13.8f }, \ + } \ +} + +#define FT991_COMP_CAL { 9, \ + { \ + { 0, 0.0f }, \ + { 40, 2.5f }, \ + { 60, 5.0f }, \ + { 85, 7.5f }, \ + { 135, 10.0f }, \ + { 150, 12.5f }, \ + { 175, 15.0f }, \ + { 195, 17.5f }, \ + { 220, 20.0f } \ + } \ +} + /* * Other features (used by rig_caps) * commit 51247efbdddab713b971c3dfef026e913adb1e78 Merge: 92161c98 d6f05e19 Author: Michael Black <mdb...@ya...> Date: Sat Feb 19 22:18:01 2022 -0600 Merge pull request #969 from challinan/master Correct compiler warning - s.b. bitwise or commit d6f05e1974226b505e16f2f2314fa7a71b7779e3 Author: challinan <cha...@gm...> Date: Sat Feb 19 21:39:17 2022 -0500 Correct compiler warning - s.b. bitwise or diff --git a/src/rig.c b/src/rig.c index 0463cb7b..20745be5 100644 --- a/src/rig.c +++ b/src/rig.c @@ -4053,7 +4053,7 @@ int HAMLIB_API rig_set_split_mode(RIG *rig, RETURNFUNC(RIG_OK); } - if (tx_vfo & (RIG_VFO_CURR || RIG_VFO_TX)) + if (tx_vfo & (RIG_VFO_CURR | RIG_VFO_TX)) { rig_debug(RIG_DEBUG_WARN, "%s(%d): Unhandled TXVFO=%s, tx_mode=%s\n", __func__, __LINE__, rig_strvfo(tx_vfo), rig_strrmode(tx_mode)); commit 92161c989a5b2f95ec80cc12d87e0b04166a9d1c Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:50:35 2022 -0600 Balance RETURNFUNC diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 5498cefa..29b904e9 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2229,7 +2229,7 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode, icom_set_dsp_flt(rig, mode, width); - RETURNFUNC2(retval); + RETURNFUNC(retval); } /* commit 7cc2ca30b04c287df00ee34c243fe81b7427ff73 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:47:58 2022 -0600 Balance RETURNFUNC diff --git a/rigs/dummy/tci1x.c b/rigs/dummy/tci1x.c index 1bd882fa..6b32a348 100644 --- a/rigs/dummy/tci1x.c +++ b/rigs/dummy/tci1x.c @@ -599,7 +599,6 @@ static int tci1x_open(RIG *rig) char *pr; //struct tci1x_priv_data *priv = (struct tci1x_priv_data *) rig->state.priv; - ENTERFUNC; rig_debug(RIG_DEBUG_VERBOSE, "%s: version %s\n", __func__, rig->caps->version); char *websocket = "GET / HTTP/1.1\r\nHost: localhost:50001\r\nUpgrade: websocket\r\nConnection: Upgrade\r\nSec-WebSocket-Key: TnwnvtFT6akIBYQC7nh3vA==\r\nSec-WebSocket-Version: 13\r\n\r\n"; @@ -621,7 +620,6 @@ static int tci1x_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: DEVICE failed: %s\n", __func__, rigerror(retval)); // we fall through and assume old version - //RETURNFUNC(retval); } sscanf(&value[2], "device:%s", value); @@ -635,8 +633,6 @@ static int tci1x_open(RIG *rig) { rig_debug(RIG_DEBUG_ERR, "%s: RECEIVE_ONLY failed: %s\n", __func__, rigerror(retval)); - // we fall through and assume old version - //RETURNFUNC(retval); } sscanf(&value[2], "receive_only:%s", value); @@ -660,20 +656,19 @@ static int tci1x_open(RIG *rig) if (retval != RIG_OK) { rig_debug(RIG_DEBUG_ERR, "%s: tci1x_get_freq not working!!\n", __func__); - //RETURNFUNC(RIG_EPROTO); } rig->state.current_vfo = RIG_VFO_A; rig_debug(RIG_DEBUG_TRACE, "%s: currvfo=%s value=%s\n", __func__, rig_strvfo(rig->state.current_vfo), value); //tci1x_get_split_vfo(rig, vfo, &priv->split, &vfo_tx); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); /* find out available widths and modes */ retval = tci1x_transaction(rig, "modulations_list;", NULL, value, sizeof(value)); - if (retval != RIG_OK) { RETURNFUNC(retval); } + if (retval != RIG_OK) { RETURNFUNC2(retval); } sscanf(&value[2], "modulations_list:%s", arg); rig_debug(RIG_DEBUG_VERBOSE, "%s: modes=%s\n", __func__, arg); @@ -801,7 +796,7 @@ static int tci1x_open(RIG *rig) rig_debug(RIG_DEBUG_VERBOSE, "%s: hamlib modes=%s\n", __func__, value); - RETURNFUNC(retval); + RETURNFUNC2(retval); } /* @@ -823,7 +818,7 @@ static int tci1x_cleanup(RIG *rig) { struct tci1x_priv_data *priv; - rig_debug(RIG_DEBUG_TRACE, "%s\n", __func__); + ENTERFUNC; if (!rig) { @@ -919,7 +914,7 @@ static int tci1x_set_freq(RIG *rig, vfo_t vfo, freq_t freq) char *cmd; struct tci1x_priv_data *priv = (struct tci1x_priv_data *) rig->state.priv; - rig_debug(RIG_DEBUG_TRACE, "%s\n", __func__); + ENTERFUNC; rig_debug(RIG_DEBUG_TRACE, "%s: vfo=%s freq=%.0f\n", __func__, rig_strvfo(vfo), freq); commit 05fa5b8f60454fb84e02d99c736ad44f2c224b81 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:42:43 2022 -0600 Balance RETURNFUNC diff --git a/rigs/kenwood/ts480.c b/rigs/kenwood/ts480.c index 02c6f5f0..8f277479 100644 --- a/rigs/kenwood/ts480.c +++ b/rigs/kenwood/ts480.c @@ -258,7 +258,7 @@ static int ts480_get_func(RIG *rig, vfo_t vfo, setting_t func, int *status) char buf[20]; int retval; - rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); + ENTERFUNC; switch (func) { @@ -427,7 +427,7 @@ static int ts480_read_meters(RIG *rig, int *swr, int *comp, int *alc) char ackbuf[32]; int expected_len = 24; - rig_debug(RIG_DEBUG_TRACE, "%s: called\n", __func__); + ENTERFUNC; retval = write_block(&rs->rigport, (unsigned char *) cmd, strlen(cmd)); @@ -484,7 +484,7 @@ kenwood_ts480_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) int levelint; int retval; - rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); + ENTERFUNC; switch (level) { @@ -785,7 +785,7 @@ static int ts480_set_rit(RIG *rig, vfo_t vfo, shortfreq_t rit) int rit_enabled; int xit_enabled; - rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); + ENTERFUNC; if (rit < -9999 || rit > 9999) { @@ -855,7 +855,7 @@ static int ts480_get_rit(RIG *rig, vfo_t vfo, shortfreq_t *rit) char buf[7]; struct kenwood_priv_data *priv = rig->state.priv; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + ENTERFUNC; if (!rit) { @@ -882,7 +882,7 @@ static int ts480_set_ext_func(RIG *rig, vfo_t vfo, token_t token, int status) char cmdbuf[20]; int retval; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + ENTERFUNC; switch (token) { @@ -935,7 +935,7 @@ static int ts480_get_ext_func(RIG *rig, vfo_t vfo, token_t token, int *status) char ackbuf[20]; int retval; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + ENTERFUNC; switch (token) { @@ -980,7 +980,7 @@ static int ts480_set_ext_level(RIG *rig, vfo_t vfo, token_t token, value_t val) int retval; char cmdbuf[20]; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + ENTERFUNC; switch (token) { @@ -1071,7 +1071,7 @@ static int ts480_get_ext_level(RIG *rig, vfo_t vfo, token_t token, value_t *val) int retval; int value; - rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + ENTERFUNC; switch (token) { @@ -1228,7 +1228,7 @@ int ts480_init(RIG *rig) struct kenwood_priv_data *priv; int retval; - rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); + ENTERFUNC; retval = kenwood_init(rig); @@ -1638,7 +1638,7 @@ int malachite_set_freq(RIG *rig, vfo_t vfo, freq_t freq) retval = kenwood_set_freq(rig, vfo, freq); - RETURNFUNC(retval); + RETURNFUNC2(retval); } /* commit 09ea2693c2c1a84543a55f34dae84fec14818a2a Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:39:50 2022 -0600 Balance RETURNFUNC diff --git a/rigs/yaesu/ft1000mp.c b/rigs/yaesu/ft1000mp.c index 66a4fbc7..03f5b1f1 100644 --- a/rigs/yaesu/ft1000mp.c +++ b/rigs/yaesu/ft1000mp.c @@ -951,7 +951,7 @@ static int ft1000mp_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) { unsigned char cmd_index = 0; /* index of sequence to send */ - rig_debug(RIG_DEBUG_VERBOSE, "%s: called\n", __func__); + ENTERFUNC; /* frontend sets VFO for us */ diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 413d6578..6032e11a 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -10728,7 +10728,7 @@ static int newcat_set_apf_frequency(RIG *rig, vfo_t vfo, int freq) if (!newcat_valid_command(rig, "CO")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } // Range seems to be -250..250 Hz in 10 Hz steps @@ -10749,10 +10749,10 @@ static int newcat_set_apf_frequency(RIG *rig, vfo_t vfo, int freq) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_apf_frequency(RIG *rig, vfo_t vfo, int *freq) @@ -10804,7 +10804,7 @@ static int newcat_get_apf_frequency(RIG *rig, vfo_t vfo, int *freq) // Range seems to be -250..250 Hz in 10 Hz steps *freq = raw_value * 10 - 250; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int newcat_set_apf_width(RIG *rig, vfo_t vfo, int choice) @@ -10813,7 +10813,7 @@ static int newcat_set_apf_width(RIG *rig, vfo_t vfo, int choice) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -10839,10 +10839,10 @@ static int newcat_set_apf_width(RIG *rig, vfo_t vfo, int choice) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_apf_width(RIG *rig, vfo_t vfo, int *choice) @@ -10854,7 +10854,7 @@ static int newcat_get_apf_width(RIG *rig, vfo_t vfo, int *choice) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -10879,12 +10879,12 @@ static int newcat_get_apf_width(RIG *rig, vfo_t vfo, int *choice) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } ret_data_len = strlen(priv->ret_data); @@ -10897,7 +10897,7 @@ static int newcat_get_apf_width(RIG *rig, vfo_t vfo, int *choice) *choice = atoi(ret_data); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int newcat_set_contour(RIG *rig, vfo_t vfo, int status) @@ -10907,7 +10907,7 @@ static int newcat_set_contour(RIG *rig, vfo_t vfo, int status) if (!newcat_valid_command(rig, "CO")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp) @@ -10932,10 +10932,10 @@ static int newcat_set_contour(RIG *rig, vfo_t vfo, int status) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_contour(RIG *rig, vfo_t vfo, int *status) @@ -10949,7 +10949,7 @@ static int newcat_get_contour(RIG *rig, vfo_t vfo, int *status) if (!newcat_valid_command(rig, "CO")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp) @@ -10972,12 +10972,12 @@ static int newcat_get_contour(RIG *rig, vfo_t vfo, int *status) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } ret_data_len = strlen(priv->ret_data); @@ -10992,7 +10992,7 @@ static int newcat_get_contour(RIG *rig, vfo_t vfo, int *status) *status = (ret_data[last_char_index] == '1') ? 1 : 0; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int newcat_set_contour_frequency(RIG *rig, vfo_t vfo, int freq) @@ -11002,7 +11002,7 @@ static int newcat_set_contour_frequency(RIG *rig, vfo_t vfo, int freq) if (!newcat_valid_command(rig, "CO")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp) @@ -11030,10 +11030,10 @@ static int newcat_set_contour_frequency(RIG *rig, vfo_t vfo, int freq) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_contour_frequency(RIG *rig, vfo_t vfo, int *freq) @@ -11046,7 +11046,7 @@ static int newcat_get_contour_frequency(RIG *rig, vfo_t vfo, int *freq) if (!newcat_valid_command(rig, "CO")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp) @@ -11069,12 +11069,12 @@ static int newcat_get_contour_frequency(RIG *rig, vfo_t vfo, int *freq) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } ret_data_len = strlen(priv->ret_data); @@ -11097,10 +11097,10 @@ static int newcat_get_contour_frequency(RIG *rig, vfo_t vfo, int *freq) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int newcat_set_contour_level(RIG *rig, vfo_t vfo, int level) @@ -11109,7 +11109,7 @@ static int newcat_set_contour_level(RIG *rig, vfo_t vfo, int level) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -11136,10 +11136,10 @@ static int newcat_set_contour_level(RIG *rig, vfo_t vfo, int level) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_contour_level(RIG *rig, vfo_t vfo, int *level) @@ -11151,7 +11151,7 @@ static int newcat_get_contour_level(RIG *rig, vfo_t vfo, int *level) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -11176,12 +11176,12 @@ static int newcat_get_contour_level(RIG *rig, vfo_t vfo, int *level) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } ret_data_len = strlen(priv->ret_data); @@ -11194,7 +11194,7 @@ static int newcat_get_contour_level(RIG *rig, vfo_t vfo, int *level) *level = atoi(ret_data); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int newcat_set_contour_width(RIG *rig, vfo_t vfo, int width) @@ -11203,7 +11203,7 @@ static int newcat_set_contour_width(RIG *rig, vfo_t vfo, int width) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -11229,10 +11229,10 @@ static int newcat_set_contour_width(RIG *rig, vfo_t vfo, int width) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_get_contour_width(RIG *rig, vfo_t vfo, int *width) @@ -11244,7 +11244,7 @@ static int newcat_get_contour_width(RIG *rig, vfo_t vfo, int *width) if (!newcat_valid_command(rig, "EX")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } if (is_ftdx101d || is_ftdx101mp || is_ftdx10) @@ -11269,12 +11269,12 @@ static int newcat_get_contour_width(RIG *rig, vfo_t vfo, int *width) } else { - RETURNFUNC(-RIG_ENIMPL); + RETURNFUNC2(-RIG_ENIMPL); } if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } ret_data_len = strlen(priv->ret_data); @@ -11287,7 +11287,7 @@ static int newcat_get_contour_width(RIG *rig, vfo_t vfo, int *width) *width = atoi(ret_data); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, @@ -11299,7 +11299,7 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, if (!newcat_valid_command(rig, "DT")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT0%04d%02d%02d%c", year, month, @@ -11309,7 +11309,7 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, { rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, err); - RETURNFUNC(err); + RETURNFUNC2(err); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT1%02d%02d%02d%c", hour, min, @@ -11319,7 +11319,7 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, { rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, err); - RETURNFUNC(err); + RETURNFUNC2(err); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT2%c%04d%c", @@ -11329,10 +11329,10 @@ int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, { rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, err); - RETURNFUNC(err); + RETURNFUNC2(err); } - RETURNFUNC(retval); + RETURNFUNC2(retval); } int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, @@ -11345,14 +11345,14 @@ int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, if (!newcat_valid_command(rig, "DT")) { - RETURNFUNC(-RIG_ENAVAIL); + RETURNFUNC2(-RIG_ENAVAIL); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT0%c", cat_term); if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } n = sscanf(priv->ret_data, "DT0%04d%02d%02d", year, month, day); @@ -11361,14 +11361,14 @@ int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, { rig_debug(RIG_DEBUG_ERR, "%s: DT0 unable to parse '%s'\n", __func__, priv->ret_data); - RETURNFUNC(-RIG_EPROTO); + RETURNFUNC2(-RIG_EPROTO); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT1%c", cat_term); if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } n = sscanf(priv->ret_data, "DT1%02d%02d%02d", hour, min, sec); @@ -11377,14 +11377,14 @@ int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, { rig_debug(RIG_DEBUG_ERR, "%s: DT1 unable to parse '%s'\n", __func__, priv->ret_data); - RETURNFUNC(-RIG_EPROTO); + RETURNFUNC2(-RIG_EPROTO); } SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "DT2%c", cat_term); if ((err = newcat_get_cmd(rig)) != RIG_OK) { - RETURNFUNC(err); + RETURNFUNC2(err); } // we keep utc_offset in HHMM format rather than converting @@ -11394,9 +11394,9 @@ int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, { rig_debug(RIG_DEBUG_ERR, "%s: DT2 unable to parse '%s'\n", __func__, priv->ret_data); - RETURNFUNC(-RIG_EPROTO); + RETURNFUNC2(-RIG_EPROTO); } - RETURNFUNC(retval); + RETURNFUNC2(retval); } commit 7cf8ea393adc59cf088fb135ece0ab403b219530 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:35:48 2022 -0600 Balance RETURNFUNC diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index 33c42df8..8b21860d 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -2056,7 +2056,7 @@ static int dummy_set_trn(RIG *rig, int trn) priv->trn = trn; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } @@ -2066,7 +2066,7 @@ static int dummy_get_trn(RIG *rig, int *trn) *trn = priv->trn; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static const char *dummy_get_info(RIG *rig) commit 8073f745e0ca392855d49f460652a1aeca5e243d Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:34:20 2022 -0600 Balance RETURNFUNC diff --git a/rigs/codan/codan.c b/rigs/codan/codan.c index 2fe038da..d7eab3f1 100644 --- a/rigs/codan/codan.c +++ b/rigs/codan/codan.c @@ -169,14 +169,14 @@ int codan_open(RIG *rig) codan_transaction(rig, "login", 1, &results); codan_set_freq(rig, RIG_VFO_A, 14074000.0); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } int codan_close(RIG *rig) { char *results = NULL; codan_transaction(rig, "logout admin\rfreq", 1, &results); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } int codan_cleanup(RIG *rig) commit 3752b7ef9f7158fb626306a2098427cff5b51a2f Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:33:54 2022 -0600 Balance RETURNFUNC diff --git a/rigs/kenwood/ts480.c b/rigs/kenwood/ts480.c index b3d01d6b..02c6f5f0 100644 --- a/rigs/kenwood/ts480.c +++ b/rigs/kenwood/ts480.c @@ -223,12 +223,12 @@ static int ts480_get_ex_menu(RIG *rig, int number, int value_len, int *value) if (retval != RIG_OK) { - RETURNFUNC(retval); + RETURNFUNC2(retval); } sscanf(ackbuf + 9, "%d", value); - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int ts480_set_func(RIG *rig, vfo_t vfo, setting_t func, int status) commit 453e831d6380675a559b67dcd267fa9e2c0168b7 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:33:16 2022 -0600 Balance RETURNFUNC diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 222883de..5498cefa 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2099,13 +2099,13 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode, { rig_debug(RIG_DEBUG_ERR, "%s: get_mode failed: %s\n", __func__, rigerror(retval)); - RETURNFUNC2(retval); + RETURNFUNC(retval); } if (tmode == mode && ((width == RIG_PASSBAND_NOCHANGE) || (width == twidth))) { rig_debug(RIG_DEBUG_TRACE, "%s: mode/width not changing\n", __func__); - RETURNFUNC2(RIG_OK); + RETURNFUNC(RIG_OK); } // looks like we need to change it commit 523a22359a9e4e1096e12bf86e8cd66b2de6c7a9 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:32:09 2022 -0600 Balance RETURNFUNC diff --git a/rigs/yaesu/ft1000mp.c b/rigs/yaesu/ft1000mp.c index 884c8989..66a4fbc7 100644 --- a/rigs/yaesu/ft1000mp.c +++ b/rigs/yaesu/ft1000mp.c @@ -901,7 +901,7 @@ static int ft1000mp_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) freq_t f; int retval; - rig_debug(RIG_DEBUG_VERBOSE, "%s: called\n", __func__); + ENTERFUNC; if (vfo == RIG_VFO_CURR) { diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index a9c0503e..31220727 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -1105,11 +1105,11 @@ static int ft991_get_dcs_sql(RIG *rig, vfo_t vfo, tone_t *code) static int ft991_set_vfo(RIG *rig, vfo_t vfo) { rig->state.current_vfo = vfo; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } static int ft991_get_vfo(RIG *rig, vfo_t *vfo) { *vfo = rig->state.current_vfo; - RETURNFUNC(RIG_OK); + RETURNFUNC2(RIG_OK); } diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 57297d2d..413d6578 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -10718,7 +10718,7 @@ int newcat_send_voice_mem(RIG *rig, vfo_t vfo, int ch) // we don't do any channel checking -- varies by rig -- could do it but not critical SNPRINTF(priv->cmd_str, sizeof(priv->cmd_str), "PB%s%d%c", p1, ch, cat_term); - RETURNFUNC(newcat_set_cmd(rig)); + RETURNFUNC2(newcat_set_cmd(rig)); } static int newcat_set_apf_frequency(RIG *rig, vfo_t vfo, int freq) commit dabf1f2c61289028e11913f4cfe767b0f3761f46 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:29:59 2022 -0600 Revert "Balance RETURNFUNC" This reverts commit 8b40735752f89a5381623311363e162fabb64440. diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index 01419fb6..33c42df8 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -2056,7 +2056,7 @@ static int dummy_set_trn(RIG *rig, int trn) priv->trn = trn; - RETURNFUNC2(RIG_OK); + RETURNFUNC(RIG_OK); } diff --git a/rigs/dummy/netrigctl.c b/rigs/dummy/netrigctl.c index 2e47112b..983ba117 100644 --- a/rigs/dummy/netrigctl.c +++ b/rigs/dummy/netrigctl.c @@ -2630,31 +2630,6 @@ static int netrigctl_power2mW(RIG *rig, unsigned int *mwpower, float power, RETURNFUNC(RIG_OK); } -/* key1 is the 1st key generated when -A/--password is requested in rigctld - * key2 is generated by the client using key1 - * key2 is decodes using key1 and should match key1 by key1's length - * random data can be appended to key2 to make it variable on each call -*/ -static int netrigctl_password(RIG *rig, unsigned char *key1, unsigned char *key2) -{ - char cmdbuf[64]; - char buf[BUF_MAX]; - int ret; - - SNPRINTF(cmdbuf, sizeof(cmdbuf), "\\password %s\n", key2); - - ret = netrigctl_transaction(rig, cmdbuf, strlen(cmdbuf), buf); - - if (ret <= 0) - { - return -RIG_EINVAL; - } - - ENTERFUNC; - - RETURNFUNC(RIG_OK); -} - /* @@ -2666,7 +2641,7 @@ struct rig_caps netrigctl_caps = RIG_MODEL(RIG_MODEL_NETRIGCTL), .model_name = "NET rigctl", .mfg_name = "Hamlib", - .version = "20220218.0", + .version = "20211123.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_OTHER, @@ -2771,7 +2746,6 @@ struct rig_caps netrigctl_caps = //.get_trn = netrigctl_get_trn, .power2mW = netrigctl_power2mW, .mW2power = netrigctl_mW2power, - .password = netrigctl_password, .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; commit 8b40735752f89a5381623311363e162fabb64440 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Feb 19 16:29:31 2022 -0600 Balance RETURNFUNC diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index 33c42df8..01419fb6 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -2056,7 +2056,7 @@ static int dummy_set_trn(RIG *rig, int trn) priv->trn = trn; - RETURNFUNC(RIG_OK); ... [truncated message content] |
From: Nate B. <n0...@us...> - 2022-01-07 13:48:15
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 9731b5fda2124f9f570290b57aa8a7fbd3f7753f (commit) via 0f26a981c11383160c5dd7804b8a744a8b7ad523 (commit) via 4dd97ef79c1b54915334040074fd8ebde4e4c141 (commit) via a6e25219ca15aa97abb651cb437490ea9f7081f7 (commit) via f3e0178f6bde567affd295af1be3f025ea90077b (commit) via 1cc0b2fb594709c069aa830b28bf1e12de0cd36d (commit) via e486f10c52fbfa5b89ebfdb0c96d0a866831657e (commit) via 573544120520039b52df8ffd4ccd1843b2cfae3b (commit) via 2f0b12fbb3952e5adac14fbac5328b823f343f51 (commit) via 0b6d4236338b5476830a31119940e307953d1a30 (commit) via 3f431314d83631ef951647d0ad8a42cee9cb5617 (commit) via bf013a9bb3ddd36f6d0e87cba9b1e225a4f5e54a (commit) via 2857a54ea6b34b1b7cfe407b20505f9a78a04f0f (commit) via f634cd3050d61288c48d40ed0b00a71e0214617f (commit) via f5a83df14c24cd5bc7409f839ee60c73b879110f (commit) via 4eb0719f1dfb0e4704ffd9b98892a12937990fd0 (commit) via 5a5902c7edbebe80b7ed4fdeca2dbf753a4660c1 (commit) via 5b942259ac52373ba3b2e25ff7fd6f96659a922b (commit) via 8ee038346446f33624fe4cfd5f23833392d77263 (commit) via a00d78c860ce33efdc897ab2e2d77da8fdf51cf6 (commit) via 60c1be9d0d7dd7e7bda95084b17c0a281ce3531f (commit) via 66819cd13340341d219700102dcfa563895582e5 (commit) via fb048939185ff529bdcacccdb4e80bf7fb504064 (commit) via a38447ece64d45d4b13b6b207111b7c16c276af1 (commit) via be53d99d9fee367a9e138a986be2d8331f3ee0cd (commit) via 18548ef29833de460c598c2ed92995ce46f62e70 (commit) via 01b7f81119a7bca2d128e75a53215e06ecf47438 (commit) via 3fd5198a57884d121f3651c83bec12902d445476 (commit) via 0080044fb1a9d3c78f43bafe737a326945578b60 (commit) via 954d70c143a9a0293371d8def3a7300ce3ca68c4 (commit) via 8a7806997535cf3ec513de02890ae316f8cf9cf6 (commit) via 80188965a16959a954581108f9d53b4cbd719d70 (commit) via a1ea9bf0e3e40133bec1f7b15f620d26d7329543 (commit) via 7c7d04dc84dddf415a5662db47cb0a13ac99b8a0 (commit) via a54b74f3c5fe6ac79fe3bba36faa236081ef33f0 (commit) via e6be62c4af1f5b33ef03941188998a39dec9309c (commit) via 8bf26f1fa0f16cf86b45059723d96b77c6e064ff (commit) via 76b3ec72fd6cb903075255878c31f2e9f38acfe5 (commit) via f547ef0f138f6455c40a6036f8edca77d9502361 (commit) via e9038f7c4194fefb4cd33d29db055b72ec6eda37 (commit) via 05bed8f52e076a08eb4a94ec7b5bcba0c597214a (commit) via 99f964ed7260175626133fc28e0d7ad988ec41cf (commit) via e223cf8ac9f9bc8ab49a99c4d0f25167a26d7cec (commit) via 320eb0975d01d9da97189db749625813ab9a8511 (commit) via 739e0633f7ad904fc83914bbdf3ec64b817b4f48 (commit) via 32a990346689c5e7eaf3a58cf27803f41ec49f99 (commit) via 502409aa174844939f008cc51779696b6829f32c (commit) via cab6ae80b5f141e68c1f899f4327fd7de8e4da44 (commit) via c8cf296711e193e53e51c9874f5681685518a50e (commit) via 882471bf19c8b8fa2c15bd1b316476a707d28540 (commit) via 664ca3871513bacc454c1e3f7b0808ea0094d7b1 (commit) via 6d16f2415755e69a96cc0040852e7ed893b53ec6 (commit) via f5b229f9dc4b4364d2f40e0b0b415e92c9a371ce (commit) via 36859c33dc8668a553fb4ae53103a8cd16749fe5 (commit) via a77f18b79a4c1479e0174c335d5ed9cc93bad5dd (commit) via 86a6ffb19e3aae8a1364dab9bd696d93ed4755de (commit) via 1c0ecc7ec63405e65fbb4386c85381823333f12d (commit) via b0b660ede9e3f839249104170e249d8ac3813902 (commit) via 045ab048f1d7ac4d4fa450c21b4651abcd40ea77 (commit) via af3027bbd1dc173c4ef6f85d33feef637a608528 (commit) via d2d622a3e814d4aaaaa55de09eed1146491e1564 (commit) via 43889b1af9553071f6837478e14603a813a9e1da (commit) via 7ce460f7d6721d6c5fdeb2dafd055fc4bf137572 (commit) via fc002ad1877db2d9729b94f84d35121d938fd759 (commit) via 1518b8033c9b1d201badc045cdd4b19a7b0d4bb2 (commit) via d4d4547321b4ced028a06c3cf342c6009250db86 (commit) via 451aa7be0c51b1417ef5d14e9ce5d7aa762d8c4e (commit) via 16406bba09a120baadb48be6045625ef6b2ee75e (commit) via 0ccf0b480c8b24d84f087d86401a27b93be0e719 (commit) via 70beeb69e1f1eb0bacdc50ea4e70c43fbd9d835a (commit) via 2f15661067ae132887f159f9849050c61bb2d9a4 (commit) via 09746800222bf1943f311832a264e90b77a8c6cf (commit) via 1048cbb56859909103f94b7813e65a83274bcee8 (commit) via 2fe9117639b81b2e5bfec12b0a3ecb994df01d49 (commit) via 65cfbb97609adc6bfc28f812cad635cae02ccdce (commit) via 3a79e125c468d9aa1aacf789f6edf22cee8a7452 (commit) via 3da4a9ea740a3b639d04aa8ed04d5f54090f2e3a (commit) via 1601375f7a7e2176dd9e5593fcfbaf5d50af1bde (commit) via 665e0de4881466e1ef89f2ce1c0add95d92f1bf1 (commit) via 196be77da4ef202cc79640c4be64f9538fed1290 (commit) via 016bcfcf394c0b7562b90ef1f29bee7d8f49b753 (commit) via a9fd2020f6a453815ee85dc9aeb175751be2af29 (commit) via ef77f1c71f58834cc497610431c93b1038b0126e (commit) via 90400c0d9f3f3fff0c745e8e6bf9d9ccad9f3b77 (commit) via 72dac9a573f37334caa6c01c846d934810a055a0 (commit) via 5a188089330c0bba04ce78ed0a0ca1763b4de0db (commit) via 499ffcc1f849d10ec3c6119c7817c0d4161a2c47 (commit) via d510893f7e68940e16fb044482512d1f42495526 (commit) via 52e856dbbe22e784e35c55d5ada5d37b6c714008 (commit) via 55b8f03c740ef35b1da0becb93f99d45cf2a759b (commit) via 8c5816c53c508fd9e6dd3ef1aebeb23f83203cc5 (commit) via e602e7da54b30875dfb92f8e1ffb195a23a04900 (commit) via cee10db2cd81b6afcb35ff395216c3a02f209e42 (commit) via 296b3b6e034fde28324aa4201f3320c96351c323 (commit) via b62d1da67194c39a95808a574ddadbc9564904fa (commit) via 2c7394f638a3a74b1e23fc21b290a9c04c8ae966 (commit) via dfa6b730d93b06f259256d856c4fde2641faeced (commit) via f12b4187e402f7bf07573982ad61cac80874aacb (commit) via 367023db31dfcf25ba15208c10e27b1b348575ba (commit) via 783ae504a75211afc6864ccab2eb00e96eba4500 (commit) via 4f4b14f771d6501f7010bc66e1b45ece5e5b1d97 (commit) via ece4d8484ff3916d340076242aa356bcb63bb40a (commit) via baea7e8c9a30ddf051cd04deec1b715856e4ed83 (commit) via 2cd18ffa3cecbecc4b5ff408275831b8e31ee909 (commit) via 99b98934300e83a66ca9f8f14f8df58b958828e6 (commit) via a7693b00f4c8ff1630ef8f5fbcb8509afc18a53f (commit) via 0d8e1355bd0db769d2c0d7a1512cd9293dba31db (commit) via 0fe723d6facffc2a688a5f0fe92659fa947734b2 (commit) via 908f33b8efefad1b3009968f023e00d0b3b59c13 (commit) via b78ec43e2e8c391f0eca5761f7d059c013b23173 (commit) via cd9a24b72e3a21eaa37cb6563d3a3b1c7b014bc6 (commit) via c764336e730135324f9a5df5d4ee0df3b9ccb6ff (commit) via c901126bf61888967e65a093abfd31c57fba65cf (commit) via 39d9577c1c1de02a23cac044ef5a5aa9f0192893 (commit) via dc0c5ddcf6625e79389bf093523bcf73608568fa (commit) via 4d33abeaae869925eb6aab165aaa05283354207c (commit) via 3cf36a7877be815ddd77b64f2ae52ef599ba0b58 (commit) via c6c18c0903850fb962dad9041d48647989a6c067 (commit) via 1a88ae350b5fa259ea5c2a997354f9bc5e9298c0 (commit) via db38378412543307df572ee4469e9b49af9e2098 (commit) via 2f95f7a8f4028153e42b602980efe9321bd96886 (commit) via 7ea9eb3f13f0358285e4900522870de6edaa6be4 (commit) via 16cf1990155faaf547b2bb6a8349d0349557f965 (commit) via dda13b91c66fc4118f2e7db9c068338ad61f9e34 (commit) via e9b732d6fde5e7affe388129d13f54068775b6da (commit) via 41eb23bb26a27f8af8badadba45c8edbbcb6a0c8 (commit) via 6aa7f9e9bc169eb71b428d59262da999caa78a65 (commit) via 09aae91d37ef9f7f06b284f79cba8ef308a6c2c9 (commit) via 4c0af35163504501514fe598e57e7bf2705a2e4e (commit) via 465d14ff3039539c95220ff3e68f6dd51408a51a (commit) via baa70cdca11d9f2a61985b240558cb8890b1a844 (commit) via 32ce1bae50706daf6d8e3bba5d135f69fa23ff70 (commit) via e257116689fbee21a54d12215bf562b0591942f1 (commit) via 1d067d6a4302be573b89d304e4da90784c632a84 (commit) via 56c95b152953acc868f9d16c04e8926b4c770fda (commit) via add666f8919b0584d68a7fd3e603b9c0193f73ca (commit) via 5e15159c79c056d235f69a1c092fdae6029bd081 (commit) via 4fa2d684778052087c655f5eae98a3ddcfb55bae (commit) via 26bfaa37ead9ab31ea8a5f0a6e375271c4e2c18c (commit) via b90c745239ff303adf3a0a121bec78ac51d6229b (commit) via 550e5daa3bbac1d89edcb25f43dfd704d6c58760 (commit) via 759918aac6263798b2df4137f9a3f12a1bc71da9 (commit) via c67f21bf963c626d9ab31e3aaac159371b70a51e (commit) via cb80f2b18da3938e2d438dcf392f08136cde4ce6 (commit) via 67e18b865e8a1376c55bcfff62deeb1e883408c1 (commit) via 674a9868d907e1cf2ffbf02e4432e6be6caa09db (commit) via b11f2e4bbfe4a97a485b965ef43c27caf3cec5d7 (commit) via 4d1e7e63f10438a5231961947d144fffacbf846f (commit) via 07cac7be764c676f79618dc9074b0c5a32157bf3 (commit) via 16976641e781c06a1d0dbe421f3e43a1a02b5b8a (commit) via 1b6a1b85a8efdcfc354df2c2b276c7c0a24721f4 (commit) via c6fbc8e682c9da469d808e66d4a24e14a8c64b5d (commit) via 29541d98069b89117ceaf242ca7fde7f79560b9f (commit) via c20f397c24f5737a97f031ae22845a76348dc9b6 (commit) via d857f181635059fd6c227f758cffd0707f26ffe5 (commit) via 39cec4aa27e6b3211034298df51ab852af862765 (commit) via 1f538ad7ece1533f596da38fd03a3367319d2050 (commit) from 223488699853a2555c45a2a08d835ba4d8eeff73 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 9731b5fda2124f9f570290b57aa8a7fbd3f7753f Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Jan 7 07:23:37 2022 -0600 Remove README.Barrett from Makefile.am diff --git a/rigs/barrett/Makefile.am b/rigs/barrett/Makefile.am index ebab766b..5df26260 100644 --- a/rigs/barrett/Makefile.am +++ b/rigs/barrett/Makefile.am @@ -3,4 +3,4 @@ BARRETTSRC = barrett.c barrett.h 950.c 4050.c noinst_LTLIBRARIES = libhamlib-barrett.la libhamlib_barrett_la_SOURCES = $(BARRETTSRC) -EXTRA_DIST = README.barrett Android.mk +EXTRA_DIST = Android.mk commit 0f26a981c11383160c5dd7804b8a744a8b7ad523 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Jan 7 07:17:57 2022 -0600 Add 4050.c diff --git a/rigs/barrett/4050.c b/rigs/barrett/4050.c new file mode 100644 index 00000000..e752fe58 --- /dev/null +++ b/rigs/barrett/4050.c @@ -0,0 +1,266 @@ +/* + * Hamlib Barrett 4050 backend - main file + * Copyright (c) 2017-2022 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 + * + */ +#ifdef HAVE_CONFIG_H +# include "config.h" +#endif + +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include <unistd.h> +#include <math.h> + +#include <hamlib/rig.h> +#include "serial.h" +#include "misc.h" +#include "cal.h" +#include "token.h" +#include "register.h" + +#include "barrett.h" + +#define MAXCMDLEN 32 + +#define BARRETT4050_VFOS (RIG_VFO_A|RIG_VFO_MEM) + +#define BARRETT4050_MODES (RIG_MODE_AM | RIG_MODE_CW | RIG_MODE_RTTY | RIG_MODE_SSB) + +#define BARRETT4050_LEVELS (RIG_LEVEL_NONE) + +#define BARRETT4050_FUNCTIONS (RIG_FUNC_TUNER) + + +static int barrett4050_set_freq(RIG *rig, vfo_t vfo, freq_t freq); + +static int barrett4050_get_level(RIG *rig, vfo_t vfo, setting_t level, + value_t *val); + +static const char *barrett4050_get_info(RIG *rig); + +// 10 band channel from 441 to 450 +#define CHANNEL_BASE 441 + +struct chan_map_s +{ + float lo, hi; + int chan_offset; +}; + +// Our 10 bands +static struct chan_map_s chan_map[] = +{ + { 1.8, 2.0, 0}, + { 3.5, 4.0, 1}, + { 5.3, 5.4, 2}, + { 7.0, 7.3, 3}, + { 10.1, 10.15, 4}, + { 14.0, 14.35, 5}, + { 18.068, 18.168, 6}, + { 21.0, 21.45, 7}, + { 24.89, 24.99, 8}, + { 28.0, 29.7, 9} +}; + +const struct rig_caps barrett4050_caps = +{ + RIG_MODEL(RIG_MODEL_BARRETT_4050), + .model_name = "4050", + .mfg_name = "Barrett", + .version = BACKEND_VER ".0", + .copyright = "LGPL", + .status = RIG_STATUS_ALPHA, + .rig_type = RIG_TYPE_TRANSCEIVER, + .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, + .ptt_type = RIG_PTT_RIG, + .dcd_type = RIG_DCD_NONE, + .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_XONXOFF, + .write_delay = 0, + .post_write_delay = 0, + .timeout = 1000, + .retry = 3, + + .has_get_func = BARRETT4050_FUNCTIONS, + .has_set_func = BARRETT4050_FUNCTIONS, + .has_get_level = BARRETT4050_LEVELS, + .has_set_level = RIG_LEVEL_NONE, + .has_get_parm = RIG_PARM_NONE, + .has_set_parm = RIG_PARM_NONE, + .transceive = RIG_TRN_RIG, + .rx_range_list1 = {{ + .startf = kHz(1600), .endf = MHz(30), .modes = BARRETT4050_MODES, + .low_power = -1, .high_power = -1, BARRETT4050_VFOS, RIG_ANT_1 + }, + RIG_FRNG_END, + }, + .rx_range_list2 = {RIG_FRNG_END,}, + .tx_range_list1 = {RIG_FRNG_END,}, + .tx_range_list2 = {RIG_FRNG_END,}, + .tuning_steps = { {BARRETT4050_MODES, 1}, {BARRETT4050_MODES, RIG_TS_ANY}, RIG_TS_END, }, + .filters = { + {RIG_MODE_SSB | RIG_MODE_CW | RIG_MODE_RTTY, kHz(2.4)}, + {RIG_MODE_CW, Hz(500)}, + {RIG_MODE_AM, kHz(8)}, + {RIG_MODE_AM, kHz(2.4)}, + RIG_FLT_END, + }, + .priv = NULL, + + .rig_init = barrett_init, + .rig_cleanup = barrett_cleanup, + + .set_freq = barrett4050_set_freq, + .get_freq = barrett_get_freq, + .set_mode = barrett_set_mode, + .get_mode = barrett_get_mode, + + .get_level = barrett4050_get_level, + + .get_info = barrett4050_get_info, + .set_ptt = barrett_set_ptt, + .get_ptt = NULL, + .set_split_freq = barrett_set_split_freq, + .set_split_vfo = barrett_set_split_vfo, + .get_split_vfo = barrett_get_split_vfo, +}; + +/* + * barrett4050_set_freq + * assumes rig!=NULL, rig->state.priv!=NULL + */ +int barrett4050_set_freq(RIG *rig, vfo_t vfo, freq_t freq) +{ + char cmd_buf[MAXCMDLEN]; + int retval; + int i; + int chan = -1; + freq_t freq_rx, freq_tx; + freq_t freq_MHz; + char *response = NULL; + //struct barrett_priv_data *priv = rig->state.priv; + + rig_debug(RIG_DEBUG_VERBOSE, "%s: vfo=%s freq=%.0f\n", __func__, + rig_strvfo(vfo), freq); + + // 950 can only set freq via memory channel + // So we make a 10-channel memory from 441-450 by band + // And we don't care about VFO -- we set TX=RX to avoid doing split freq changes + // Trying to minimize writes to EEPROM + + // What band is being requested? + freq_MHz = freq / 1e6; + + for (i = 0; i < 10; ++i) + { + if (freq_MHz >= chan_map[i].lo && freq_MHz <= chan_map[i].hi) + { + chan = CHANNEL_BASE + chan_map[i].chan_offset; + } + } + + rig_debug(RIG_DEBUG_VERBOSE, "%s: using chan %d for freq %.0f \n", __func__, + chan, freq); + + // Set the channel + sprintf((char *) cmd_buf, "XC%04d", chan); + retval = barrett_transaction(rig, cmd_buf, 0, &response); + + if (retval < 0) + { + return retval; + } + + // Read the current channel for the requested freq to see if it needs changing + sprintf((char *) cmd_buf, "IDC%04d", chan); + retval = barrett_transaction(rig, cmd_buf, 0, &response); + + if (retval < 0) + { + return retval; + } + + if (sscanf(response, "%4d%8lf%8lf", &chan, &freq_rx, &freq_tx) != 2) + { + rig_debug(RIG_DEBUG_ERR, "%s: unable to parse chan/freq from %s\n", __func__, + response); + return -RIG_EPROTO; + } + + rig_debug(RIG_DEBUG_VERBOSE, "%s: got chan %d, freq_rx=%.0f, freq_tx=%.0f", + __func__, chan, + freq_rx, freq_tx); + + if (freq_rx == freq && freq_tx == freq) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s: no freq change needed\n", __func__); + return RIG_OK; + } + + // New freq so let's update the channel + // We do not support split mode -- too many writes to EEPROM to support it + sprintf((char *) cmd_buf, "PC%04dR%08.0lfT%08.0lf", chan, freq, freq); + retval = barrett_transaction(rig, cmd_buf, 0, &response); + + if (retval != RIG_OK || strncmp(response, "OK", 2) != 0) + { + rig_debug(RIG_DEBUG_ERR, "%s: Expected OK, got '%s'\n", __func__, response); + return -RIG_EPROTO; + } + + return RIG_OK; +} + +/* + * barrett4050_get_level + */ +int barrett4050_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) +{ + return -RIG_ENIMPL; +} + +/* + * barrett4050_get_info + */ +const char *barrett4050_get_info(RIG *rig) +{ + char *response = NULL; + int retval; + + rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + + retval = barrett_transaction(rig, "IV", 0, &response); + + if (retval == RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s: result=%s\n", __func__, response); + } + else + { + rig_debug(RIG_DEBUG_VERBOSE, "Software Version %s\n", response); + } + + return response; +} commit 4dd97ef79c1b54915334040074fd8ebde4e4c141 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Jan 7 07:12:17 2022 -0600 Change Barret set_mode to use temporary commmand instead of channel write diff --git a/NEWS b/NEWS index 0608718d..073de2cd 100644 --- a/NEWS +++ b/NEWS @@ -14,6 +14,7 @@ Version 5.x Version 4.5 * 202?-??-?? + * Added Barrett 4050 * Added TM-V71(A) * Added IC-F8101 * Added JRC JST-145 and JST-245 diff --git a/rigs/barrett/barrett.c b/rigs/barrett/barrett.c index 94b11f8c..37226d25 100644 --- a/rigs/barrett/barrett.c +++ b/rigs/barrett/barrett.c @@ -435,7 +435,7 @@ int barrett_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) return -RIG_EINVAL; } - sprintf((char *) cmd_buf, "XB%c" EOM, ttmode); + sprintf((char *) cmd_buf, "TB%c" EOM, ttmode); retval = barrett_transaction(rig, cmd_buf, 0, NULL); commit a6e25219ca15aa97abb651cb437490ea9f7081f7 Merge: f3e0178f 1cc0b2fb Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Jan 7 06:55:30 2022 -0600 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit f3e0178f6bde567affd295af1be3f025ea90077b Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Jan 7 06:55:13 2022 -0600 Add Barrett 4050 diff --git a/include/hamlib/riglist.h b/include/hamlib/riglist.h index b1542278..301e5324 100644 --- a/include/hamlib/riglist.h +++ b/include/hamlib/riglist.h @@ -627,6 +627,7 @@ #define RIG_BACKEND_BARRETT "barrett" #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) /* * Elad diff --git a/rigs/barrett/950.c b/rigs/barrett/950.c index 942613be..79531e06 100644 --- a/rigs/barrett/950.c +++ b/rigs/barrett/950.c @@ -63,7 +63,7 @@ struct chan_map_s }; // Our 10 bands -struct chan_map_s chan_map[] = +static struct chan_map_s chan_map[] = { { 1.8, 2.0, 0}, { 3.5, 4.0, 1}, diff --git a/rigs/barrett/Makefile.am b/rigs/barrett/Makefile.am index 71953213..ebab766b 100644 --- a/rigs/barrett/Makefile.am +++ b/rigs/barrett/Makefile.am @@ -1,4 +1,4 @@ -BARRETTSRC = barrett.c barrett.h 950.c +BARRETTSRC = barrett.c barrett.h 950.c 4050.c noinst_LTLIBRARIES = libhamlib-barrett.la libhamlib_barrett_la_SOURCES = $(BARRETTSRC) diff --git a/rigs/barrett/README.barrett b/rigs/barrett/README.barrett deleted file mode 100644 index b6c6aed7..00000000 --- a/rigs/barrett/README.barrett +++ /dev/null @@ -1,3 +0,0 @@ -Initial version done for Barrett 250 -May need to break out to separate rigs -Mike Black W9MDB diff --git a/rigs/barrett/barrett.c b/rigs/barrett/barrett.c index 237c8e92..94b11f8c 100644 --- a/rigs/barrett/barrett.c +++ b/rigs/barrett/barrett.c @@ -46,165 +46,6 @@ #define BARRETT_LEVELS (RIG_LEVEL_STRENGTH) -int barrett_init(RIG *rig); -int barrett_cleanup(RIG *rig); -static int barrett_set_freq(RIG *rig, vfo_t vfo, freq_t freq); -int barrett_get_freq(RIG *rig, vfo_t vfo, freq_t *freq); -int barrett_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt); -static int barrett_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt); -int barrett_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width); -int barrett_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, - pbwidth_t *width); - -int barrett_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); -int barrett_set_split_vfo(RIG *rig, vfo_t rxvfo, split_t split, - vfo_t txvfo); - -int barrett_get_split_vfo(RIG *rig, vfo_t rxvfo, split_t *split, - vfo_t *txvfo); - -static int barrett_get_level(RIG *rig, vfo_t vfo, setting_t level, - value_t *val); - -static const char *barrett_get_info(RIG *rig); - - -const struct rig_caps barrett_caps = -{ - RIG_MODEL(RIG_MODEL_BARRETT_2050), - .model_name = "2050", - .mfg_name = "Barrett", - .version = BACKEND_VER ".0", - .copyright = "LGPL", - .status = RIG_STATUS_STABLE, - .rig_type = RIG_TYPE_TRANSCEIVER, - .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, - .ptt_type = RIG_PTT_RIG, - .dcd_type = RIG_DCD_NONE, - .port_type = RIG_PORT_SERIAL, - .serial_rate_min = 9600, - .serial_rate_max = 9600, - .serial_data_bits = 8, - .serial_stop_bits = 1, - .serial_parity = RIG_PARITY_NONE, - .serial_handshake = RIG_HANDSHAKE_XONXOFF, - .write_delay = 0, - .post_write_delay = 50, - .timeout = 1000, - .retry = 3, - - .has_get_func = RIG_FUNC_NONE, - .has_set_func = RIG_FUNC_NONE, - .has_get_level = BARRETT_LEVELS, - .has_set_level = RIG_LEVEL_NONE, - .has_get_parm = RIG_PARM_NONE, - .has_set_parm = RIG_PARM_NONE, -// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, -// .ctcss_list = common_ctcss_list, -// .dcs_list = full_dcs_list, -// 2050 does have channels...not implemented yet as no need yet -// .chan_list = { -// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, -// { 19, 19, RIG_MTYPE_CALL }, -// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, -// RIG_CHAN_END, -// }, -// .scan_ops = DUMMY_SCAN, -// .vfo_ops = DUMMY_VFO_OP, - .transceive = RIG_TRN_RIG, - .rx_range_list1 = {{ - .startf = kHz(1600), .endf = MHz(30), .modes = BARRETT_MODES, - .low_power = -1, .high_power = -1, BARRETT_VFOS, RIG_ANT_1 - }, - RIG_FRNG_END, - }, - .rx_range_list2 = {RIG_FRNG_END,}, - .tx_range_list1 = {RIG_FRNG_END,}, - .tx_range_list2 = {RIG_FRNG_END,}, - .tuning_steps = { {BARRETT_MODES, 1}, {BARRETT_MODES, RIG_TS_ANY}, RIG_TS_END, }, - .filters = { - {RIG_MODE_SSB | RIG_MODE_CW | RIG_MODE_RTTY, kHz(2.4)}, - {RIG_MODE_CW, Hz(500)}, - {RIG_MODE_AM, kHz(8)}, - {RIG_MODE_AM, kHz(2.4)}, - RIG_FLT_END, - }, - .priv = NULL, - -// .extlevels = dummy_ext_levels, -// .extparms = dummy_ext_parms, -// .cfgparams = dummy_cfg_params, - - .rig_init = barrett_init, - .rig_cleanup = barrett_cleanup, - -// .set_conf = dummy_set_conf, -// .get_conf = dummy_get_conf, - - .set_freq = barrett_set_freq, - .get_freq = barrett_get_freq, - .set_mode = barrett_set_mode, - .get_mode = barrett_get_mode, - -// .set_powerstat = dummy_set_powerstat, -// .get_powerstat = dummy_get_powerstat, -// .set_level = dummy_set_level, - .get_level = barrett_get_level, -// .set_func = dummy_set_func, -// .get_func = dummy_get_func, -// .set_parm = dummy_set_parm, -// .get_parm = dummy_get_parm, -// .set_ext_level = dummy_set_ext_level, -// .get_ext_level = dummy_get_ext_level, -// .set_ext_parm = dummy_set_ext_parm, -// .get_ext_parm = dummy_get_ext_parm, - - .get_info = barrett_get_info, - .set_ptt = barrett_set_ptt, - .get_ptt = barrett_get_ptt, -// .get_dcd = dummy_get_dcd, -// .set_rptr_shift = dummy_set_rptr_shift, -// .get_rptr_shift = dummy_get_rptr_shift, -// .set_rptr_offs = dummy_set_rptr_offs, -// .get_rptr_offs = dummy_get_rptr_offs, -// .set_ctcss_tone = dummy_set_ctcss_tone, -// .get_ctcss_tone = dummy_get_ctcss_tone, -// .set_dcs_code = dummy_set_dcs_code, -// .get_dcs_code = dummy_get_dcs_code, -// .set_ctcss_sql = dummy_set_ctcss_sql, -// .get_ctcss_sql = dummy_get_ctcss_sql, -// .set_dcs_sql = dummy_set_dcs_sql, -// .get_dcs_sql = dummy_get_dcs_sql, - .set_split_freq = barrett_set_split_freq, -// .get_split_freq = dummy_get_split_freq, -// .set_split_mode = dummy_set_split_mode, -// .get_split_mode = dummy_get_split_mode, - .set_split_vfo = barrett_set_split_vfo, - .get_split_vfo = barrett_get_split_vfo, -// .set_rit = dummy_set_rit, -// .get_rit = dummy_get_rit, -// .set_xit = dummy_set_xit, -// .get_xit = dummy_get_xit, -// .set_ts = dummy_set_ts, -// .get_ts = dummy_get_ts, -// .set_ant = dummy_set_ant, -// .get_ant = dummy_get_ant, -// .set_bank = dummy_set_bank, -// .set_mem = dummy_set_mem, -// .get_mem = dummy_get_mem, -// .vfo_op = dummy_vfo_op, -// .scan = dummy_scan, -// .send_dtmf = dummy_send_dtmf, -// .recv_dtmf = dummy_recv_dtmf, -// .send_morse = dummy_send_morse, -// .set_channel = dummy_set_channel, -// .get_channel = dummy_get_channel, -// .set_trn = dummy_set_trn, -// .get_trn = dummy_get_trn, -// .power2mW = dummy_power2mW, -// .mW2power = dummy_mW2power, -}; - DECLARE_INITRIG_BACKEND(barrett) { @@ -212,6 +53,7 @@ DECLARE_INITRIG_BACKEND(barrett) rig_register(&barrett_caps); rig_register(&barrett950_caps); + rig_register(&barrett4050_caps); rig_debug(RIG_DEBUG_VERBOSE, "%s: _init back from rig_register\n", __func__); return RIG_OK; @@ -243,7 +85,8 @@ int barrett_transaction(RIG *rig, char *cmd, int expected, char **result) if (expected == 0) { // response format is 0x11,data...,0x0d,0x0a,0x13 - retval = read_string(&rs->rigport, (unsigned char *) priv->ret_data, sizeof(priv->ret_data), + retval = read_string(&rs->rigport, (unsigned char *) priv->ret_data, + sizeof(priv->ret_data), "\x11", 1, 0, 1); rig_debug(RIG_DEBUG_VERBOSE, "%s: resultlen=%d\n", __func__, (int)strlen(priv->ret_data)); @@ -792,10 +635,38 @@ int barrett_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) const char *barrett_get_info(RIG *rig) { char *response = NULL; + char *series; int retval; rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + retval = barrett_transaction(rig, "IDR", 0, &response); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_WARN, "%s: IDR command failed: %s\n", __func__, + strerror(retval)); + } + else + { + series = "unknown"; + } + + series = strdup(response); + retval = barrett_transaction(rig, "IDS", 0, &response); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_WARN, "%s: IDS command failed: %s\n", __func__, + strerror(retval)); + } + else + { + response = "unknown"; + } + + rig_debug(RIG_DEBUG_VERBOSE, "%s: Barrett series %s, serial# %s\n", __func__, + series, response); retval = barrett_transaction(rig, "IVF", 0, &response); if (retval == RIG_OK) @@ -809,3 +680,148 @@ const char *barrett_get_info(RIG *rig) return response; } + +int barrett_open(RIG *rig) +{ + ENTERFUNC; + barrett_get_info(rig); + RETURNFUNC(RIG_OK); +} + + +const struct rig_caps barrett_caps = +{ + RIG_MODEL(RIG_MODEL_BARRETT_2050), + .model_name = "2050", + .mfg_name = "Barrett", + .version = BACKEND_VER ".0", + .copyright = "LGPL", + .status = RIG_STATUS_STABLE, + .rig_type = RIG_TYPE_TRANSCEIVER, + .targetable_vfo = RIG_TARGETABLE_FREQ | RIG_TARGETABLE_MODE, + .ptt_type = RIG_PTT_RIG, + .dcd_type = RIG_DCD_NONE, + .port_type = RIG_PORT_SERIAL, + .serial_rate_min = 9600, + .serial_rate_max = 9600, + .serial_data_bits = 8, + .serial_stop_bits = 1, + .serial_parity = RIG_PARITY_NONE, + .serial_handshake = RIG_HANDSHAKE_XONXOFF, + .write_delay = 0, + .post_write_delay = 50, + .timeout = 1000, + .retry = 3, + + .has_get_func = RIG_FUNC_NONE, + .has_set_func = RIG_FUNC_NONE, + .has_get_level = BARRETT_LEVELS, + .has_set_level = RIG_LEVEL_NONE, + .has_get_parm = RIG_PARM_NONE, + .has_set_parm = RIG_PARM_NONE, +// .level_gran = { [LVL_CWPITCH] = { .step = { .i = 10 } } }, +// .ctcss_list = common_ctcss_list, +// .dcs_list = full_dcs_list, +// 2050 does have channels...not implemented yet as no need yet +// .chan_list = { +// { 0, 18, RIG_MTYPE_MEM, DUMMY_MEM_CAP }, +// { 19, 19, RIG_MTYPE_CALL }, +// { 20, NB_CHAN-1, RIG_MTYPE_EDGE }, +// RIG_CHAN_END, +// }, +// .scan_ops = DUMMY_SCAN, +// .vfo_ops = DUMMY_VFO_OP, + .transceive = RIG_TRN_RIG, + .rx_range_list1 = {{ + .startf = kHz(1600), .endf = MHz(30), .modes = BARRETT_MODES, + .low_power = -1, .high_power = -1, BARRETT_VFOS, RIG_ANT_1 + }, + RIG_FRNG_END, + }, + .rx_range_list2 = {RIG_FRNG_END,}, + .tx_range_list1 = {RIG_FRNG_END,}, + .tx_range_list2 = {RIG_FRNG_END,}, + .tuning_steps = { {BARRETT_MODES, 1}, {BARRETT_MODES, RIG_TS_ANY}, RIG_TS_END, }, + .filters = { + {RIG_MODE_SSB | RIG_MODE_CW | RIG_MODE_RTTY, kHz(2.4)}, + {RIG_MODE_CW, Hz(500)}, + {RIG_MODE_AM, kHz(8)}, + {RIG_MODE_AM, kHz(2.4)}, + RIG_FLT_END, + }, + .priv = NULL, + +// .extlevels = dummy_ext_levels, +// .extparms = dummy_ext_parms, +// .cfgparams = dummy_cfg_params, + + .rig_init = barrett_init, + .rig_open = barrett_open, + .rig_cleanup = barrett_cleanup, + +// .set_conf = dummy_set_conf, +// .get_conf = dummy_get_conf, + + .set_freq = barrett_set_freq, + .get_freq = barrett_get_freq, + .set_mode = barrett_set_mode, + .get_mode = barrett_get_mode, + +// .set_powerstat = dummy_set_powerstat, +// .get_powerstat = dummy_get_powerstat, +// .set_level = dummy_set_level, + .get_level = barrett_get_level, +// .set_func = dummy_set_func, +// .get_func = dummy_get_func, +// .set_parm = dummy_set_parm, +// .get_parm = dummy_get_parm, +// .set_ext_level = dummy_set_ext_level, +// .get_ext_level = dummy_get_ext_level, +// .set_ext_parm = dummy_set_ext_parm, +// .get_ext_parm = dummy_get_ext_parm, + + .get_info = barrett_get_info, + .set_ptt = barrett_set_ptt, + .get_ptt = barrett_get_ptt, +// .get_dcd = dummy_get_dcd, +// .set_rptr_shift = dummy_set_rptr_shift, +// .get_rptr_shift = dummy_get_rptr_shift, +// .set_rptr_offs = dummy_set_rptr_offs, +// .get_rptr_offs = dummy_get_rptr_offs, +// .set_ctcss_tone = dummy_set_ctcss_tone, +// .get_ctcss_tone = dummy_get_ctcss_tone, +// .set_dcs_code = dummy_set_dcs_code, +// .get_dcs_code = dummy_get_dcs_code, +// .set_ctcss_sql = dummy_set_ctcss_sql, +// .get_ctcss_sql = dummy_get_ctcss_sql, +// .set_dcs_sql = dummy_set_dcs_sql, +// .get_dcs_sql = dummy_get_dcs_sql, + .set_split_freq = barrett_set_split_freq, +// .get_split_freq = dummy_get_split_freq, +// .set_split_mode = dummy_set_split_mode, +// .get_split_mode = dummy_get_split_mode, + .set_split_vfo = barrett_set_split_vfo, + .get_split_vfo = barrett_get_split_vfo, +// .set_rit = dummy_set_rit, +// .get_rit = dummy_get_rit, +// .set_xit = dummy_set_xit, +// .get_xit = dummy_get_xit, +// .set_ts = dummy_set_ts, +// .get_ts = dummy_get_ts, +// .set_ant = dummy_set_ant, +// .get_ant = dummy_get_ant, +// .set_bank = dummy_set_bank, +// .set_mem = dummy_set_mem, +// .get_mem = dummy_get_mem, +// .vfo_op = dummy_vfo_op, +// .scan = dummy_scan, +// .send_dtmf = dummy_send_dtmf, +// .recv_dtmf = dummy_recv_dtmf, +// .send_morse = dummy_send_morse, +// .set_channel = dummy_set_channel, +// .get_channel = dummy_get_channel, +// .set_trn = dummy_set_trn, +// .get_trn = dummy_get_trn, +// .power2mW = dummy_power2mW, +// .mW2power = dummy_mW2power, +}; diff --git a/rigs/barrett/barrett.h b/rigs/barrett/barrett.h index 9395d72b..3513d414 100644 --- a/rigs/barrett/barrett.h +++ b/rigs/barrett/barrett.h @@ -28,7 +28,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20181111" +#define BACKEND_VER "20220107" #define EOM "\x0d" #define TRUE 1 @@ -40,6 +40,7 @@ extern const struct rig_caps barrett_caps; extern const struct rig_caps barrett950_caps; +extern const struct rig_caps barrett4050_caps; struct barrett_priv_data { char cmd_str[BARRETT_DATA_LEN]; /* command string buffer */ commit 1cc0b2fb594709c069aa830b28bf1e12de0cd36d Merge: 57354412 e486f10c Author: Michael Black <mdb...@ya...> Date: Thu Jan 6 10:05:52 2022 -0600 Merge pull request #922 from mikaelnousiainen/fix-typo-1 Fix typo in conf parameters documentation commit e486f10c52fbfa5b89ebfdb0c96d0a866831657e Author: Mikael Nousiainen <mik...@ik...> Date: Thu Jan 6 10:38:39 2022 +0200 Fix typo in conf parameters documentation diff --git a/src/conf.c b/src/conf.c index 40bebeae..b6225476 100644 --- a/src/conf.c +++ b/src/conf.c @@ -170,7 +170,7 @@ static const struct confparams frontend_cfg_params[] = }, { TOK_ASYNC, "async", "Asynchronous data transfer support", - "True enables asynchronous data transfer for backends that support it. This enabled handling of transceive and spectrum data, for example.", + "True enables asynchronous data transfer for backends that support it. This allows use of transceive and spectrum data.", "0", RIG_CONF_CHECKBUTTON, { } }, commit 573544120520039b52df8ffd4ccd1843b2cfae3b Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Jan 5 22:58:30 2022 -0600 Fix set_mode_with_data for IC-7200 https://github.com/Hamlib/Hamlib/issues/921 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index d117e57d..f0758922 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2510,6 +2510,8 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) } else { + priv_data->filter = 0; + if (mode_len == 2) priv_data->filter = modebuf[2]; rig_debug(RIG_DEBUG_TRACE, "%s: modebuf[0]=0x%02x, modebuf[1]=0x%02x, mode_len=%d\n", __func__, modebuf[0], modebuf[1], mode_len); diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 412144b6..f98ad274 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20211222" +#define BACKEND_VER "20220105" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit 2f0b12fbb3952e5adac14fbac5328b823f343f51 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Jan 5 13:13:12 2022 -0600 Fix WIN32 build diff --git a/src/iofunc.c b/src/iofunc.c index 99f9b0b3..76171213 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -433,6 +433,7 @@ int HAMLIB_API port_close(hamlib_port_t *p, rig_port_t port_type) extern int is_uh_radio_fd(int fd); +#ifdef ASYNC_BUG static int port_read_sync_data_error_code(hamlib_port_t *p) { ssize_t total_bytes_read = 0; @@ -573,6 +574,7 @@ static ssize_t port_read_sync_data_pipe(hamlib_port_t *p, void *buf, size_t coun { return port_read_sync_data(p, buf, count); } +#endif /* On MinGW32/MSVC/.. the appropriate accessor must be used * depending on the port type, sigh. commit 0b6d4236338b5476830a31119940e307953d1a30 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Jan 5 13:11:34 2022 -0600 Revert "Fix win32 build" This reverts commit 3f431314d83631ef951647d0ad8a42cee9cb5617. diff --git a/rigs/icom/ic706.c b/rigs/icom/ic706.c index f953530b..67db3529 100644 --- a/rigs/icom/ic706.c +++ b/rigs/icom/ic706.c @@ -615,11 +615,7 @@ const struct rig_caps ic706mkiig_caps = .get_split_mode = icom_get_split_mode, .set_split_vfo = icom_set_split_vfo, .get_split_vfo = icom_mem_get_split_vfo, - .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS, - .async_data_supported = 1, - .read_frame_direct = icom_read_frame_direct, - .is_async_frame = icom_is_async_frame, - .process_async_frame = icom_process_async_frame, + .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS }; diff --git a/rigs/yaesu/ft3000.c b/rigs/yaesu/ft3000.c index 8a7b15fc..d2e590e3 100644 --- a/rigs/yaesu/ft3000.c +++ b/rigs/yaesu/ft3000.c @@ -234,18 +234,6 @@ int ft3000_get_ant(RIG *rig, vfo_t vfo, ant_t dummy, value_t *option, RETURNFUNC(RIG_OK); } -static int dx3000_set_vfo(RIG *rig, vfo_t vfo) -{ - rig->state.current_vfo = vfo; - RETURNFUNC(RIG_OK); -} - -static int dx3000_get_vfo(RIG *rig, vfo_t *vfo) -{ - *vfo = rig->state.current_vfo; - RETURNFUNC(RIG_OK); -} - /* * FTDX 3000 rig capabilities @@ -258,7 +246,7 @@ const struct rig_caps ftdx3000_caps = RIG_MODEL(RIG_MODEL_FTDX3000), .model_name = "FTDX-3000", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".5a", + .version = NEWCAT_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -273,8 +261,8 @@ const struct rig_caps ftdx3000_caps = .serial_handshake = RIG_HANDSHAKE_HARDWARE, // write_delay 5ms or less was causing VS1;VS; to answer with VS0 instead of VS1 even though change did occur // see https://github.com/Hamlib/Hamlib/issues/906 - .write_delay = 0, - .post_write_delay = 25, // same as FT-991 + .write_delay = 10, + .post_write_delay = FTDX5000_POST_WRITE_DELAY, .timeout = 2000, .retry = 3, .has_get_func = FTDX5000_FUNCS, @@ -297,7 +285,7 @@ const struct rig_caps ftdx3000_caps = .max_xit = Hz(9999), .max_ifshift = Hz(1000), .vfo_ops = FTDX5000_VFO_OPS, - .targetable_vfo = RIG_TARGETABLE_FREQ|RIG_TARGETABLE_MODE, /* one of the few diffs from the 5000 */ + .targetable_vfo = RIG_TARGETABLE_FREQ, /* one of the few diffs from the 5000 */ .transceive = RIG_TRN_OFF, /* May enable later as the 5000 has an Auto Info command */ .bank_qty = 0, .chan_desc_sz = 0, @@ -384,8 +372,8 @@ const struct rig_caps ftdx3000_caps = .get_freq = newcat_get_freq, .set_mode = newcat_set_mode, .get_mode = newcat_get_mode, - .set_vfo = dx3000_set_vfo, - .get_vfo = dx3000_get_vfo, + .set_vfo = newcat_set_vfo, + .get_vfo = newcat_get_vfo, .set_ptt = newcat_set_ptt, .get_ptt = newcat_get_ptt, .set_split_vfo = newcat_set_split_vfo, diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index b09e0fcb..dc0039a8 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -10099,7 +10099,7 @@ int newcat_set_cmd_validate(RIG *rig) } else if ((strncmp(priv->cmd_str, "VS", 2) == 0) && (strlen(priv->cmd_str) > 3)) { - strcpy(valcmd, "ID;"); + strcpy(valcmd, "VS;"); } else if (strncmp(priv->cmd_str, "SV", 2) == 0) { diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index cc59fcd3..9fe9023e 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20220103" +#define NEWCAT_VER "20211227" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 diff --git a/src/iofunc.c b/src/iofunc.c index 76171213..99f9b0b3 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -433,7 +433,6 @@ int HAMLIB_API port_close(hamlib_port_t *p, rig_port_t port_type) extern int is_uh_radio_fd(int fd); -#ifdef ASYNC_BUG static int port_read_sync_data_error_code(hamlib_port_t *p) { ssize_t total_bytes_read = 0; @@ -574,7 +573,6 @@ static ssize_t port_read_sync_data_pipe(hamlib_port_t *p, void *buf, size_t coun { return port_read_sync_data(p, buf, count); } -#endif /* On MinGW32/MSVC/.. the appropriate accessor must be used * depending on the port type, sigh. commit 3f431314d83631ef951647d0ad8a42cee9cb5617 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Jan 5 13:08:38 2022 -0600 Fix win32 build diff --git a/rigs/icom/ic706.c b/rigs/icom/ic706.c index 67db3529..f953530b 100644 --- a/rigs/icom/ic706.c +++ b/rigs/icom/ic706.c @@ -615,7 +615,11 @@ const struct rig_caps ic706mkiig_caps = .get_split_mode = icom_get_split_mode, .set_split_vfo = icom_set_split_vfo, .get_split_vfo = icom_mem_get_split_vfo, - .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS + .hamlib_check_rig_caps = HAMLIB_CHECK_RIG_CAPS, + .async_data_supported = 1, + .read_frame_direct = icom_read_frame_direct, + .is_async_frame = icom_is_async_frame, + .process_async_frame = icom_process_async_frame, }; diff --git a/rigs/yaesu/ft3000.c b/rigs/yaesu/ft3000.c index d2e590e3..8a7b15fc 100644 --- a/rigs/yaesu/ft3000.c +++ b/rigs/yaesu/ft3000.c @@ -234,6 +234,18 @@ int ft3000_get_ant(RIG *rig, vfo_t vfo, ant_t dummy, value_t *option, RETURNFUNC(RIG_OK); } +static int dx3000_set_vfo(RIG *rig, vfo_t vfo) +{ + rig->state.current_vfo = vfo; + RETURNFUNC(RIG_OK); +} + +static int dx3000_get_vfo(RIG *rig, vfo_t *vfo) +{ + *vfo = rig->state.current_vfo; + RETURNFUNC(RIG_OK); +} + /* * FTDX 3000 rig capabilities @@ -246,7 +258,7 @@ const struct rig_caps ftdx3000_caps = RIG_MODEL(RIG_MODEL_FTDX3000), .model_name = "FTDX-3000", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".5", + .version = NEWCAT_VER ".5a", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -261,8 +273,8 @@ const struct rig_caps ftdx3000_caps = .serial_handshake = RIG_HANDSHAKE_HARDWARE, // write_delay 5ms or less was causing VS1;VS; to answer with VS0 instead of VS1 even though change did occur // see https://github.com/Hamlib/Hamlib/issues/906 - .write_delay = 10, - .post_write_delay = FTDX5000_POST_WRITE_DELAY, + .write_delay = 0, + .post_write_delay = 25, // same as FT-991 .timeout = 2000, .retry = 3, .has_get_func = FTDX5000_FUNCS, @@ -285,7 +297,7 @@ const struct rig_caps ftdx3000_caps = .max_xit = Hz(9999), .max_ifshift = Hz(1000), .vfo_ops = FTDX5000_VFO_OPS, - .targetable_vfo = RIG_TARGETABLE_FREQ, /* one of the few diffs from the 5000 */ + .targetable_vfo = RIG_TARGETABLE_FREQ|RIG_TARGETABLE_MODE, /* one of the few diffs from the 5000 */ .transceive = RIG_TRN_OFF, /* May enable later as the 5000 has an Auto Info command */ .bank_qty = 0, .chan_desc_sz = 0, @@ -372,8 +384,8 @@ const struct rig_caps ftdx3000_caps = .get_freq = newcat_get_freq, .set_mode = newcat_set_mode, .get_mode = newcat_get_mode, - .set_vfo = newcat_set_vfo, - .get_vfo = newcat_get_vfo, + .set_vfo = dx3000_set_vfo, + .get_vfo = dx3000_get_vfo, .set_ptt = newcat_set_ptt, .get_ptt = newcat_get_ptt, .set_split_vfo = newcat_set_split_vfo, diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index dc0039a8..b09e0fcb 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -10099,7 +10099,7 @@ int newcat_set_cmd_validate(RIG *rig) } else if ((strncmp(priv->cmd_str, "VS", 2) == 0) && (strlen(priv->cmd_str) > 3)) { - strcpy(valcmd, "VS;"); + strcpy(valcmd, "ID;"); } else if (strncmp(priv->cmd_str, "SV", 2) == 0) { diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 9fe9023e..cc59fcd3 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20211227" +#define NEWCAT_VER "20220103" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 diff --git a/src/iofunc.c b/src/iofunc.c index 99f9b0b3..76171213 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -433,6 +433,7 @@ int HAMLIB_API port_close(hamlib_port_t *p, rig_port_t port_type) extern int is_uh_radio_fd(int fd); +#ifdef ASYNC_BUG static int port_read_sync_data_error_code(hamlib_port_t *p) { ssize_t total_bytes_read = 0; @@ -573,6 +574,7 @@ static ssize_t port_read_sync_data_pipe(hamlib_port_t *p, void *buf, size_t coun { return port_read_sync_data(p, buf, count); } +#endif /* On MinGW32/MSVC/.. the appropriate accessor must be used * depending on the port type, sigh. commit bf013a9bb3ddd36f6d0e87cba9b1e225a4f5e54a Merge: f634cd30 2857a54e Author: Michael Black <mdb...@ya...> Date: Wed Jan 5 11:52:26 2022 -0600 Merge pull request #918 from mikaelnousiainen/async-io-on-windows Implement async I/O on Windows commit 2857a54ea6b34b1b7cfe407b20505f9a78a04f0f Author: Mikael Nousiainen <mik...@ik...> Date: Wed Jan 5 19:12:43 2022 +0200 Allow enabling of async data mode via conf option. Ignore multicast data publishing if the publisher routine is not enabled. diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 00f6fe5d..ce9dfe38 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -2218,6 +2218,7 @@ typedef struct hamlib_port { int client_port; /*!< client socket port for tcp connection */ RIG *rig; /*!< our parent RIG device */ +#ifdef ASYNC_BUG int async; /*!< enable asynchronous data handling if true */ #if defined(_WIN32) hamlib_async_pipe_t *sync_data_pipe; /*!< pipe data structure for synchronous data */ @@ -2228,6 +2229,7 @@ typedef struct hamlib_port { int fd_sync_error_write; /*!< file descriptor for writing synchronous data error codes */ int fd_sync_error_read; /*!< file descriptor for reading synchronous data error codes */ #endif +#endif } hamlib_port_t; //! @endcond @@ -2239,7 +2241,7 @@ typedef hamlib_port_t port_t; #define HAMLIB_ELAPSED_SET 1 #define HAMLIB_ELAPSED_INVALIDATE 2 -#define HAMLIB_CACHE_ALWAYS -1 /*< value to set cache timeout to always use cache */ +#define HAMLIB_CACHE_ALWAYS (-1) /*< value to set cache timeout to always use cache */ typedef enum { HAMLIB_CACHE_ALL, // to set all cache timeouts at once @@ -2399,7 +2401,7 @@ struct rig_state { rig_ptr_t priv; /*!< Pointer to private rig state data. */ rig_ptr_t obj; /*!< Internal use by hamlib++ for event handling. */ - int async_data; /*!< Whether async data mode is on */ + int async_data_enabled; /*!< Whether async data mode is enabled */ int poll_interval; /*!< Rig state polling period in milliseconds */ freq_t current_freq; /*!< Frequency currently set */ rmode_t current_mode; /*!< Mode currently set */ diff --git a/src/conf.c b/src/conf.c index 9347f737..40bebeae 100644 --- a/src/conf.c +++ b/src/conf.c @@ -168,6 +168,11 @@ static const struct confparams frontend_cfg_params[] = "Suppress get_freq on VFOB for RIT tuning satellites", "Unset", RIG_CONF_COMBO, { .c = {{ "Unset", "ON", "OFF", NULL }} } }, + { + TOK_ASYNC, "async", "Asynchronous data transfer support", + "True enables asynchronous data transfer for backends that support it. This enabled handling of transceive and spectrum data, for example.", + "0", RIG_CONF_CHECKBUTTON, { } + }, { RIG_CONF_END, NULL, } }; @@ -666,6 +671,15 @@ static int frontend_set_conf(RIG *rig, token_t token, const char *val) rs->twiddle_rit = val_i ? 1 : 0; break; + case TOK_ASYNC: + if (1 != sscanf(val, "%d", &val_i)) + { + return -RIG_EINVAL; //value format error + } + + rs->async_data_enabled = val_i ? 1 : 0; + break; + default: return -RIG_EINVAL; } @@ -1010,6 +1024,9 @@ static int frontend_get_conf(RIG *rig, token_t token, char *val) sprintf(val, "%d", rs->twiddle_rit); break; + case TOK_ASYNC: + sprintf(val, "%d", rs->async_data_enabled); + break; default: return -RIG_EINVAL; diff --git a/src/network.c b/src/network.c index a08d20ef..eb3175d9 100644 --- a/src/network.c +++ b/src/network.c @@ -692,21 +692,37 @@ static int multicast_publisher_write_packet_header(RIG *rig, multicast_publisher int network_publish_rig_poll_data(RIG *rig) { + struct rig_state *rs = &rig->state; multicast_publisher_data_packet packet = { .type = MULTICAST_PUBLISHER_DATA_PACKET_TYPE_POLL, .padding = 0, .data_length = 0, }; + + if (rs->multicast_publisher_priv_data == NULL) + { + // Silently ignore call if multicast publisher is not enabled + return RIG_OK; + } + return multicast_publisher_write_packet_header(rig, &packet); } int network_publish_rig_transceive_data(RIG *rig) { + struct rig_state *rs = &rig->state; multicast_publisher_data_packet packet = { .type = MULTICAST_PUBLISHER_DATA_PACKET_TYPE_TRANSCEIVE, .padding = 0, .data_length = 0, }; + + if (rs->multicast_publisher_priv_data == NULL) + { + // Silently ignore call if multicast publisher is not enabled + return RIG_OK; + } + return multicast_publisher_write_packet_header(rig, &packet); } @@ -724,8 +740,8 @@ int network_publish_rig_spectrum_data(RIG *rig, struct rig_spectrum_line *line) if (rs->multicast_publisher_priv_data == NULL) { - // Silently ignore if multicast publisher is not enabled - RETURNFUNC(RIG_OK); + // Silently ignore call if multicast publisher is not enabled + return RIG_OK; } result = multicast_publisher_write_packet_header(rig, &packet); diff --git a/src/rig.c b/src/rig.c index 868bd07c..d4780b55 100644 --- a/src/rig.c +++ b/src/rig.c @@ -452,18 +452,15 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model) */ rs = &rig->state; + rs->async_data_enabled = 0; rs->rigport.fd = -1; rs->pttport.fd = -1; rs->comm_state = 0; rig_debug(RIG_DEBUG_VERBOSE, "%s: rs->comm_state==0?=%d\n", __func__, rs->comm_state); rs->rigport.type.rig = caps->port_type; /* default from caps */ -#ifdef ASYNC_BUG -#ifdef HAVE_PTHREAD - rs->rigport.async = caps->async_data_supported; -#else +#if defined(ASYNC_BUG) && defined(HAVE_PTHREAD) rs->rigport.async = 0; -#endif #endif switch (caps->port_type) @@ -513,11 +510,6 @@ RIG *HAMLIB_API rig_init(rig_model_t rig_model) rs->vfo_comp = 0.0; /* override it with preferences */ rs->current_vfo = RIG_VFO_CURR; /* we don't know yet! */ rs->tx_vfo = RIG_VFO_CURR; /* we don't know yet! */ -#ifdef HAVE_PTHREAD - rs->async_data = caps->async_data_supported; -#else - rs->async_data = 0; -#endif rs->poll_interval = 0; // disable polling by default rs->lo_freq = 0; rs->cache.timeout_ms = 500; // 500ms cache timeout by default @@ -723,6 +715,12 @@ int HAMLIB_API rig_open(RIG *rig) rs = &rig->state; rs->rigport.rig = rig; +#if defined(ASYNC_BUG) && defined(HAVE_PTHREAD) + // Enable async data only if it's enabled through conf settings *and* supported by the backend + rs->async_data_enabled = rs->async_data_enabled && caps->async_data_supported; + rs->rigport.async = rs->async_data_enabled; +#endif + if (strlen(rs->rigport.pathname) > 0) { char hoststr[256], portstr[6]; @@ -6880,39 +6878,39 @@ HAMLIB_EXPORT(void) sync_callback(int lock) #ifdef ASYNC_BUG static int async_data_handler_start(RIG *rig) { - const struct rig_caps *caps = rig->caps; struct rig_state *rs = &rig->state; async_data_handler_priv_data *async_data_handler_priv; ENTERFUNC; + if (!rs->async_data_enabled) + { + rig_debug(RIG_DEBUG_TRACE, "%s: async data support disabled\n", __func__); + RETURNFUNC(RIG_OK); + } + #ifdef ASYNC_BUG #ifdef HAVE_PTHREAD - if (caps->async_data_supported) - { - rs->async_data_handler_thread_run = 1; - rs->async_data_handler_priv_data = calloc(1, - sizeof(async_data_handler_priv_data)); + rs->async_data_handler_thread_run = 1; + rs->async_data_handler_priv_data = calloc(1, + sizeof(async_data_handler_priv_data)); - if (rs->async_data_handler_priv_data == NULL) - { - RETURNFUNC(-RIG_ENOMEM); - } + if (rs->async_data_handler_priv_data == NULL) + { + RETURNFUNC(-RIG_ENOMEM); + } - async_data_handler_priv = (async_data_handler_priv_data *) - rs->async_data_handler_priv_data; - async_data_handler_priv->args.rig = rig; - int err = pthread_create(&async_data_handler_priv->thread_id, NULL, - async_data_handler, &async_data_handler_priv->args); + async_data_handler_priv = (async_data_handler_priv_data *) + rs->async_data_handler_priv_data; + async_data_handler_priv->args.rig = rig; + int err = pthread_create(&async_data_handler_priv->thread_id, NULL, + async_data_handler, &async_data_handler_priv->args); - if (err) - { - rig_debug(RIG_DEBUG_ERR, "%s(%d) pthread_create error: %s\n", __FILE__, - __LINE__, - strerror(errno)); - RETURNFUNC(-RIG_EINTERNAL); - } + if (err) + { + rig_debug(RIG_DEBUG_ERR, "%s: pthread_create error: %s\n", __func__, strerror(errno)); + RETURNFUNC(-RIG_EINTERNAL); } #endif @@ -6943,8 +6941,7 @@ static int async_data_handler_stop(RIG *rig) if (err) { - rig_debug(RIG_DEBUG_ERR, "%s(%d): pthread_join error: %s\n", __FILE__, __LINE__, - strerror(errno)); + rig_debug(RIG_DEBUG_ERR, "%s: pthread_join error: %s\n", __func__, strerror(errno)); // just ignore the error } @@ -6973,9 +6970,7 @@ void *async_data_handler(void *arg) int result; #endif - rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): Starting async data handler thread\n", - __FILE__, - __LINE__); + rig_debug(RIG_DEBUG_VERBOSE, "%s: Starting async data handler thread\n", __func__); // TODO: check how to enable "transceive" on recent Kenwood/Yaesu rigs // TODO: add initial support for async in Kenwood kenwood_transaction (+one) functions -> add transaction_active flag usage @@ -7045,9 +7040,7 @@ void *async_data_handler(void *arg) #endif - rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): Stopping async data handler thread\n", - __FILE__, - __LINE__); + rig_debug(RIG_DEBUG_VERBOSE, "%s: Stopping async data handler thread\n", __func__); return NULL; } diff --git a/src/token.h b/src/token.h index b73174a6..46b80f19 100644 --- a/src/token.h +++ b/src/token.h @@ -91,6 +91,9 @@ #define TOK_PTT_SHARE TOKEN_FRONTEND(35) /** \brief PTT share with other applications */ #define TOK_FLUSHX TOKEN_FRONTEND(36) +/** \brief Asynchronous data transfer support */ +#define TOK_ASYNC TOKEN_FRONTEND(37) + /* * rig specific tokens */ commit f634cd3050d61288c48d40ed0b00a71e0214617f Merge: 4eb0719f f5a83df1 Author: Michael Black <mdb...@ya...> Date: Tue Jan 4 16:54:35 2022 -0600 Merge pull request #913 from arodland/rt21-stop Enable "stop" command for RT-21 rotator. commit f5a83df14c24cd5bc7409f839ee60c73b879110f Author: Andrew Rodland <an...@cl...> Date: Tue Jan 4 17:47:48 2022 -0500 Update RT-21 version diff --git a/rotators/rotorez/rotorez.c b/rotators/rotorez/rotorez.c index 044ab6a5..af36466f 100644 --- a/rotators/rotorez/rotorez.c +++ b/rotators/rotorez/rotorez.c @@ -310,7 +310,7 @@ const struct rot_caps rt21_rot_caps = ROT_MODEL(ROT_MODEL_RT21), .model_name = "RT-21", .mfg_name = "Green Heron", - .version = "20210801.0", + .version = "20220104.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rot_type = ROT_TYPE_OTHER, commit 4eb0719f1dfb0e4704ffd9b98892a12937990fd0 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Jan 4 07:11:44 2022 -0600 Fix IC-7610 send_voice_mem looping https://github.com/Hamlib/Hamlib/issues/917 diff --git a/rigs/icom/ic7610.c b/rigs/icom/ic7610.c index 7ad2100c..45d7ae09 100644 --- a/rigs/icom/ic7610.c +++ b/rigs/icom/ic7610.c @@ -352,7 +352,7 @@ const struct rig_caps ic7610_caps = RIG_MODEL(RIG_MODEL_IC7610), .model_name = "IC-7610", .mfg_name = "Icom", - .version = BACKEND_VER ".5", + .version = BACKEND_VER ".6", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -582,7 +582,7 @@ const struct rig_caps ic7610_caps = .send_morse = icom_send_morse, .stop_morse = icom_stop_morse, .wait_morse = rig_wait_morse, - .send_voice_mem = rig_send_voice_mem, + .send_voice_mem = icom_send_voice_mem, .set... [truncated message content] |
From: Nate B. <n0...@us...> - 2021-12-02 23:59:45
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 223488699853a2555c45a2a08d835ba4d8eeff73 (commit) via 712a5f3f046f66b2f2cc4a15b12275efe5a3b27a (commit) via 1a22f5caf73973208c4c2c3ac6686ed47b17660e (commit) via a1da584bc13b9b4481e4bde21eed0e708dd2d10e (commit) via b5a4e99a3e9a39c073c5567ce22d80831216b31e (commit) via cab48cecfae7a21377379fedb12bc76aed0ebfb8 (commit) via 9ed36ffe548f0a5e14329851980b59f46aa47fe6 (commit) via d38a248fdaa6c65320e736b3bd255dda73b1246b (commit) via 41990372da5c697f8b0fe6a4799866aafdd1b490 (commit) via 8e28c68d3e892c94e35ecb19b41fd6be466487f8 (commit) via 23d291de3ce0adaecf19432013a286313fbe1e04 (commit) via 26d1b57d8f5a37322f0609a610022ae2ecab8423 (commit) via a1c8493c62d309488e2f41f50850372bc41e6052 (commit) via a36b74deca550d7dce67d8bc4fdf5b06561fcaac (commit) via e16035ef8e92831ce718d32895342bae6ddb71aa (commit) via fc7beda918dd7ce490db0600533712c8c8f79422 (commit) via 48b53ffaac85645ed523c5578a88e2749c18ae1c (commit) via 3affc1066ca5034a04f76b31e8796892332b1e35 (commit) via 618cf901450351d76b471a32fa45a15ef99072e4 (commit) via eaa6d1bc28711a2cf5c57b9d042956a447cd3c72 (commit) via 1fe7a9a78097296bc21bace93db3d2c7db572bb1 (commit) via 361dc2c2e2888d431752673b44dc7e833efcff5c (commit) via 63a51c36a1728a3f91715cda4d78f6c3c4bbf911 (commit) via 7349a0de736166fd07073921800870c3ddd176a7 (commit) via 8a443a8667bae46c46141024a4b9bd7d9c5beba6 (commit) via 5cf68f3647d13efbc9865bfcdfbb91c5e3e8af17 (commit) via d22e7d2f7722d634dae82b0e80302bc58dd1dcf2 (commit) via 643e18dc289e30f3b586b3581d473f370cdbbec6 (commit) via 7c1e14d79dd37f20caa0c6bbded68a7c77b0341f (commit) via 921bd9812fd518c299b2c9e2bce09669b4dc010d (commit) via 71662c79f87a9c9a143eab1cbb056912e5fbae88 (commit) via ada6543b09872e9095170d2c38bd4751d2439a5a (commit) via 02bd4f6e9ec99e253ee88b82a252431d13bd54a3 (commit) via d1a7964ac4ab270dd07b0e672c18f03bb58542dc (commit) via d820ee9dbfbd12bc030e6576cc8eea6655cbffbb (commit) via e58db5cd52535143ddbe8132d9bfc8268ab75558 (commit) via 8928672e2cf89eb796f65b2dfd3d3a12f5272811 (commit) via d94c8c92256f2da22375c593c269f489913d5c2f (commit) via 70a7db3318b84374ee2e8bac042a90a6f4124883 (commit) via ccac553f1b43f1062c1ee7120de29f17a0b3e116 (commit) via e283e2b03948757b205f017ec5b733d705b75ec0 (commit) via 238e17b736256a0d49da23b5a20fd14dd190023f (commit) via 3fb9f50003d61b1cd45a127bf8beed5e9676627b (commit) via cf527c8d24a86e9965ab826cb78de4fdf6180801 (commit) via ba407cfcdf6740a90ace04016f4a1de0a1e2c3dd (commit) via 6f308b94078a69477540dbe3fb83a58868c2d068 (commit) via 42284ef70b7a56d05a4759677ccf5b0b5d19e10f (commit) via 9b5e283e95684d8145267d3cbf42a0c631324b26 (commit) via f71712b23b6daeaea97c0e1995c7fee4d1084410 (commit) via 12f7bb4d8f81da856e298e9e534d149b8b4e72a5 (commit) via 4b3bbabc5da31df483ff1c70f1102ef5435e57bf (commit) via 050826bb4486ce15b822a13a802732fb83029671 (commit) via 383d97dee0685b167373a6e0eea81af0d40142b7 (commit) via f3dc90f8f5547731f9babb50635c3a12f8037cb1 (commit) via c229c2f52df383216e307bc0d76e8b81b0e431c1 (commit) via 8c3e8fed284d404e59ed710f0fd2b4f336f85191 (commit) via 489ecf6aed5a66804a00a57d04c95ffbd4ccf947 (commit) via d9d247cad3a66bba55a3eed737edcd72c075b6a0 (commit) via 3de368f6a2c5ffe72dd60c3f7e95b3569c8df36b (commit) via 3502852d428141b8075f479dcab59883978bd13d (commit) via f044c2bfdd904cd744f73c224fd044029ccdd5e8 (commit) via 450273164481829c391f40fcb95a11b71d3d0f40 (commit) via fdd0749c09909f41c59535725fc81239d0246926 (commit) via a67f885c853c9824cd021123c70375fca4911d30 (commit) via 470d3b7c4fc22fbb7b8883c5065d9b927f48b3fe (commit) via 4e717d2386201845da77e2ffff4fa0ef182ac1f7 (commit) via dbb9f90abf7ccae3c9b5c603a1180524a26f4047 (commit) via d6110a8b8bb8f62c745556a2784a57334d80f467 (commit) via 8b5685425ae052295803405e13ad987665fdb2f5 (commit) via 0032f567e1b14d870c622f20f5db07ac5cac96d6 (commit) via 4c530dc578f35c9236b36d2daef03bf0a7cc4e18 (commit) via 782e39eb33931b0a78a1a43e7d5353d1a3c7df1b (commit) via 7dceda7d2cca71851d591e055b472eedea10dc6a (commit) via 65cc461918d237a1eb0c5227f904d2ba31ff7c9c (commit) via ff89d6441ee0769c9e6b3936c562db59f49dcd36 (commit) via f2ae765c37bc787469e14fe372a5116e0ef67b0d (commit) via e64a128f3a8eb6d47188a4552d620843c2ea66aa (commit) via 61141126c1a22451ae9761a1b7a9a5635b932765 (commit) via 68edfe3357f4bb0e96b304f297ec03203b3a8882 (commit) via 9eccaec6afb29a795d640dee97400e8ee0756d4b (commit) via 5102d3e7210065cb69480c9213308cf9415f709b (commit) via 353bee3a5fa6ebede652eeab683042eb87fa1e85 (commit) via 6ba1bc0811ab1d9ee5fc7992bde0bfca30f56302 (commit) via eed96376758252e73f77b60c0f8fec991a785882 (commit) via aa86f25321b10a3d677efdea89fe172cfbccadc9 (commit) via 40546d9e5a8292301acff93de4476c75ec70fd09 (commit) via d6541eba0a09543f79bfc1fcaf31d09458994a01 (commit) via a3e888dc3fa29de956cbbe735a0c2dc39f458a45 (commit) via d1f9ca1b68d7859eac00051fabb33e6b7835f23e (commit) via b17d681fc28f48e6bda9103f78552c348c87ab56 (commit) via 5eb169edc17a9a107c781dc0395a3accae98ed03 (commit) via 3b927a81eb5c7a425102fc8305a42d2834361fe2 (commit) via 41ebbb02b5abf49fc3601790f1886cebc5aa1a1c (commit) via 50bbf7b36b7fd95a19c487fd6762c43d19c7d146 (commit) via 663b149a487a3b211cd0ad7cee7f5bb400ec9a70 (commit) via a9c2792c23beca4316dc30a6d08d3fb72f650343 (commit) via 023a1b8d5cf656e1a65b9f01835e2819a062af5f (commit) via 6ca98441967d2ab2b1b42627bb1cc90be4160736 (commit) via ac4c59232ddce1302729e9111914c7ab340830ff (commit) via c5828909504726283c22418a562fc3480818f3e4 (commit) via ffe3c9d0127075237fd50dcec3f6bc029036021b (commit) via 65b3cb9da3ed8d317183a0338fba989f9b73684c (commit) via 9554e4937da904935bb2a1759b0bd05848245d3d (commit) via 00657fba429798e28db181a37d04a294bdf2f155 (commit) via e7530643a032ad7c92065cfab473859d84463731 (commit) via 057788b300535cb6fac6890da453548e37199c8d (commit) via 544fcf719440e641285f30ada4c268f33dd36f60 (commit) via c1c549cbf34076e310de9f1e0a0ec3056bd07ea0 (commit) via 44abad93748afbb8a8636cc2ca3fdc47625c2a89 (commit) via b4f42286501b94948f6c99da15309e149c83c23a (commit) via 233036f874411492384c5209ef4202d617dae2e3 (commit) via a271948b3df6151834c0ef46635df747296a42ff (commit) via c1c1f1f05375e9385688748a3f5da7034805bf07 (commit) via 30ef04b1a49c075dafae2b3be54c9a02e8625a2c (commit) via 9842cdb1f398e45294b82b00356152f4b1228d2a (commit) via de1b0f5126893eb9a92fd5bee248739fe0f3a6e9 (commit) via 8fe190d6226e442840e67cfdaa6d6c6696527591 (commit) via 57bb2b15d637ddd1954e8273dfeb682b3382248d (commit) via c6ae89cf6f99ba76732fe241763a9639e8a5fe84 (commit) via 603223d49318e383cf05891dcf70cf1ff0ab5ee9 (commit) via 52e0840f1d5bebf1454e71f819986396ecd54a10 (commit) via 746ba96eb1efc0d0419c8a0c34f2f97699c20e2e (commit) via dc585776fce20fd1d2a183ea5af9a15270e86749 (commit) via 84fb123202f1582a96f5250d8654182501bb6556 (commit) via 44871f7e9b04fee6e7e5a346a3563822fd60c4e4 (commit) via 1ed398466d7f5dcb05b4ca695b5bb867b6d95ae3 (commit) via f071adac8fea680ce233bb51e9d78c1b1699c0c9 (commit) via b2646f54a45fb3d45151c4e9f5248321ec65e9e5 (commit) via bf2867021e9b50ea42413824c9a5f8e98acb4318 (commit) via 4a18fa22821d6a6370919cd3d72bd8190220b7c5 (commit) via d28f4409683b3dcc34a0ff618714e20f3b43078a (commit) via 4ad28fd5aba217fa606d0645e536db98b925e816 (commit) via b9c86da0fb044430ba6f8833b132259d955f66f1 (commit) via 0309a34d02d1f32c6f723136335b479b213811e8 (commit) via 8cba9d7ee939b47dffbf057284d70aefafd65b41 (commit) via 9d2aaa00c0f9dfabfdced47112a81b041b005763 (commit) via 6f82645ee80dda1ca83d406d8693f218eafcbb58 (commit) via db9cd44bcf2d1b88c23ebc4016e7847d625448a3 (commit) via ab0d25ce3b9a8ffc7a7c37cf31cb51b462be952a (commit) via 022d4e4f67d2cdfd9d0ff6be0d68b7f382399c87 (commit) via 1dc9f56e13e445941ebe52ba236c9b02154002fd (commit) via eb8c8d8e5f06250879eef18fa24f4b99a54bdb27 (commit) via 5f9153cd0a0422fbefda2de5886d4d2a6f1fe519 (commit) via ff1d2bab83184fa785be2d757699c2334264b4d9 (commit) via a755d82ffdd2e2f1e5ffa7f2b63ca694b1bf8de6 (commit) via 58635746494d098e9eec168756944331d1f1592b (commit) via 47ca65cc6790066581f6aa1d6387a0aaeba97d2e (commit) via d18c3a81119419e793b3d415fa78ef1ba6a20053 (commit) via 739d808d6af2447b993cd4793a4b1fde04d3da90 (commit) via 0e3393a1e024ec8140b963f3c272b8d05286203b (commit) via 468c5d2c03859d9a682022aab147858b1bf09e34 (commit) via f5abd7a176f21ea9c74cc444b351510acfc90f8b (commit) via a7a97776bb7466a1e6fa32e75ea24ce2713d0099 (commit) via 6bfa5705fdb6bef9bebc1fe2638f392cd7bff159 (commit) via 7e9a8f14ccfafd5244ca8b4568688b0c4f724671 (commit) via 636acf2155e70ed633fea8cfcbd0456c13aa5125 (commit) via 5cdbdd04c643ac513b4cffd50c82be54be714e89 (commit) via 6f018701a092607ed09173af6824e578cef5a649 (commit) via c3d1e1559a6e0fc01a45a2d43c9d490a06bac49a (commit) via 1ca3d34010fec4e692d216f5aff9ba04a0f40217 (commit) via 014219c4ade4bdd9e8f009474e9fa70f67711eb7 (commit) via 28cdd671613a82af287d946597af9d9903f805f7 (commit) via c9d7a924c79e9b84b126f5cbc9e85c05bc9b8c46 (commit) via efe54c80c567076597fbf0e3b7ebe03df433a0f8 (commit) via a312efb96b85043096e47262463af18933878d4e (commit) via f77dc0992424ff2e9524d26149c4865c10700e69 (commit) via 3ae48c507d1f54666e42ca157cfc4a30896bef51 (commit) via 9186702776bb047d76e1a32acc93874a3919e18b (commit) via 6553373ad162ab8665b087fdd254a85cb4d1141a (commit) via c83949ae6db075bf922399f1272364dc180d8d1a (commit) via 5e90774728676bb421b619700ae68f668687303b (commit) via 6b6156c416a1e02ce9713d354aba5f41763d50cd (commit) via a15726e6522133fb42fda2fdfdb665d14581ef4e (commit) via 5c29e099a9dc4156587bdbb2c1b941fe5a5f4882 (commit) via 10c3ab09ac57f08f8162471c6057c4145fd70aa4 (commit) via 024f7f061c717845fca305f91cb4f7d132ed9864 (commit) via 0cd7e5cc166c4086193ad00201446f28afae85b1 (commit) via c0aeb14a2a7748c081c384e855fc81ef77705bab (commit) via dc09191f0795408d98f09c6f8e84ba23b0e7cb44 (commit) via 736072bbaf2fb9be9b6cfa20d418664a73a5a105 (commit) via e3731400c37135b37a9ccbc1d637c36deb848dfd (commit) via 44cce057f27b2345a6f02b3214d108f73c63bd99 (commit) via 84df12919f8036ed5f95c0bd980c9528da32f1d4 (commit) via 899cd71b1da674c1f30dfe4eb459198e9bf74aaf (commit) via 49f3452bf224064b742235342842acdf138b981b (commit) via 569f21c7feff16a0da29ed726549a0ad3eb06b92 (commit) via 80f7378bf5e62dfbe43d8bef5c02c9e8358e4327 (commit) via 3dde8030a08739e1c5e4f02435cb30432a60526b (commit) via 1ade49f3d5c40ffc06aca254c1499247cce58731 (commit) via 1b10d113f28c4a8250a7f2b62b76aedb0d731bfb (commit) via 25e5f593006c1fb94adf330e4dff4d7cb4a53557 (commit) via 015d79cc806032a05c97ae2bcee342fda3c7814e (commit) via 6c43e5c6ac4fa96b62b049fe257974e8a6c2ed1d (commit) via 7f1faf24c0fbfa2af6ce576d3eb29c756edcedde (commit) via a8a317f6abe22f83d7bf2e9ffd3879d6af55f14b (commit) via dc70e2a41f3b36940f4b445512db615355b66e99 (commit) via 4462fe423effe8257e5374f3989d7b17a9ac674a (commit) via 83b7243946c86343ab4c2ebefa3ae04c23f9b118 (commit) via 50512b4bf9a60c769ef3a95e6f6c8bc275010448 (commit) via 891ca6ed75345079dc5d6e4c98865f867400ea10 (commit) via 8a983cae80c1ef5d387d7626bff1dba30233a8e7 (commit) via 4c634f8c0411231a107e36e0e4c45ee47aa76ee6 (commit) via da34930ab95c9eff5b4fa1ce2a2931f1ef245947 (commit) via ac43daa998651d71538194693e482080ba7a58f7 (commit) via 4c1cbf0aa9fb96df1aae919f1e20e0aecefacfa3 (commit) via 16a879bc7275469694ff6a90de5d638f511f9407 (commit) via 6a4bebcb964ce01b120fe025ae2ae4dcfd3dfa92 (commit) via c7acbc19de87d75094ff10d6b8a156a90df12e4a (commit) via 8263ac2ce8fd16bbe16f7390a71dcdf8b94ae23d (commit) via dfab74d74daf7ff601ad88d66b1096c4b3cbd1c3 (commit) via 5f5aabe176ea90f56191b3d8d104976ecc4794b2 (commit) via c6249ed0f75c24a3122bf56d88b9036cc5e578de (commit) from d5a1b125cd8dd441adf974e7bc9685d9f7495cf1 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 223488699853a2555c45a2a08d835ba4d8eeff73 Author: Nate Bargmann <n0...@n0...> Date: Thu Dec 2 17:56:17 2021 -0600 Advance to 4.5~git diff --git a/NEWS b/NEWS index 8c34da14..262862a1 100644 --- a/NEWS +++ b/NEWS @@ -6,6 +6,9 @@ Copyright (C) 2000-2021 Michael Black W9MDB, and others Please send Hamlib bug reports to ham...@li... +Version 4.5 + * 202?-??-?? + Version 4.4 * 2021-12-02 * Icom rigs now default filter 2 when setting PKTUSB but user can override diff --git a/configure.ac b/configure.ac index 540c0baf..0f04b931 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,7 @@ dnl Please do not use '-' in the version number, as package managers will fail, 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.4~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) +AC_INIT([Hamlib],[4.5~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) AC_CONFIG_SRCDIR([include/hamlib/rig.h]) AC_CONFIG_MACRO_DIR([macros]) @@ -56,7 +56,7 @@ 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=4 +ABI_REVISION=5 ABI_AGE=0 AC_DEFINE_UNQUOTED([ABI_VERSION], [$ABI_VERSION], [Frontend ABI version]) ----------------------------------------------------------------------- Summary of changes: NEWS | 10 +- Segfault-award | 4 + amplifiers/elecraft/kpa.c | 9 +- configure.ac | 4 +- cppcheck.sh | 2 +- doc/Makefile.am | 2 +- doc/man1/rigctl.1 | 35 +- doc/man1/rigctld.1 | 29 +- extra/kylix/hamlib_rigapi.pas | 2 +- include/hamlib/rig.h | 28 +- include/hamlib/riglist.h | 2 + lib/termios.c | 13 +- rigs/adat/adat.c | 4 +- rigs/alinco/dx77.c | 6 +- rigs/alinco/dxsr8.c | 4 +- rigs/aor/aor.c | 5 +- rigs/aor/ar3000.c | 2 +- rigs/aor/ar3030.c | 2 +- rigs/aor/sr2200.c | 2 +- rigs/barrett/barrett.c | 2 +- rigs/dorji/dra818.c | 5 +- rigs/drake/drake.c | 4 +- rigs/dummy/Makefile.am | 2 +- rigs/dummy/dummy.c | 56 +- rigs/dummy/dummy.h | 1 + rigs/dummy/flrig.c | 34 +- rigs/dummy/netampctl.c | 6 +- rigs/dummy/netrigctl.c | 105 +++- rigs/dummy/netrotctl.c | 14 +- rigs/dummy/rot_dummy.c | 9 +- rigs/dummy/{flrig.c => tci1x.c} | 969 +++++++++++------------------- rigs/dummy/trxmanager.c | 2 +- rigs/elad/elad.c | 6 +- rigs/icmarine/icmarine.c | 2 +- rigs/icom/Makefile.am | 2 +- rigs/icom/frame.c | 5 +- rigs/icom/ic7100.c | 105 +++- rigs/icom/ic7300.c | 218 ++++++- rigs/icom/ic7300.h | 8 + rigs/icom/ic7600.c | 112 +++- rigs/icom/ic7610.c | 114 +++- rigs/icom/ic7700.c | 109 +++- rigs/icom/ic7800.c | 108 +++- rigs/icom/ic785x.c | 9 +- rigs/icom/icom.c | 188 ++++-- rigs/icom/icom.h | 2 +- rigs/icom/optoscan.c | 6 +- rigs/jrc/jrc.c | 4 +- rigs/kachina/kachina.c | 6 +- rigs/kenwood/elecraft.c | 65 +- rigs/kenwood/elecraft.h | 2 + rigs/kenwood/flex6xxx.c | 1 + rigs/kenwood/ic10.c | 4 +- rigs/kenwood/k3.c | 179 ++++-- rigs/kenwood/kenwood.c | 380 +++++++++--- rigs/kenwood/kenwood.h | 6 +- rigs/kenwood/ts480.c | 2 +- rigs/kenwood/ts890s.c | 1 + rigs/kenwood/xg3.c | 8 +- rigs/kit/funcube.c | 30 +- rigs/kit/rs_hfiq.c | 39 +- rigs/lowe/lowe.c | 4 +- rigs/prm80/prm80.c | 14 +- rigs/racal/ra37xx.c | 2 +- rigs/racal/racal.c | 2 +- rigs/rft/rft.c | 2 +- rigs/rs/gp2000.c | 2 +- rigs/rs/rs.c | 2 +- rigs/skanti/skanti.c | 4 +- rigs/tentec/omnivii.c | 5 +- rigs/tentec/orion.c | 4 +- rigs/tentec/rx331.c | 3 +- rigs/tentec/rx340.c | 2 +- rigs/tentec/tentec.c | 2 +- rigs/tentec/tt550.c | 5 +- rigs/uniden/uniden.c | 4 +- rigs/uniden/uniden_digital.c | 2 +- rigs/yaesu/FT8X7eeprom.odt | Bin 0 -> 15533 bytes rigs/yaesu/frg100.c | 3 +- rigs/yaesu/ft100.c | 169 +++--- rigs/yaesu/ft1000d.c | 196 +++--- rigs/yaesu/ft1000mp.c | 56 +- rigs/yaesu/ft1200.c | 71 ++- rigs/yaesu/ft2000.c | 51 +- rigs/yaesu/ft2000.h | 2 +- rigs/yaesu/ft3000.c | 69 ++- rigs/yaesu/ft450.c | 4 +- rigs/yaesu/ft5000.c | 60 +- rigs/yaesu/ft5000.h | 2 +- rigs/yaesu/ft600.c | 116 ++-- rigs/yaesu/ft747.c | 68 ++- rigs/yaesu/ft757gx.c | 6 +- rigs/yaesu/ft817.c | 185 +++--- rigs/yaesu/ft840.c | 51 +- rigs/yaesu/ft847.c | 377 ++++++++---- rigs/yaesu/ft857.c | 97 +-- rigs/yaesu/ft890.c | 57 +- rigs/yaesu/ft891.c | 103 +++- rigs/yaesu/ft891.h | 2 +- rigs/yaesu/ft897.c | 85 +-- rigs/yaesu/ft900.c | 57 +- rigs/yaesu/ft9000.c | 6 +- rigs/yaesu/ft920.c | 17 +- rigs/yaesu/ft950.c | 4 +- rigs/yaesu/ft990.c | 122 ++-- rigs/yaesu/ft991.c | 107 +++- rigs/yaesu/ft991.h | 2 +- rigs/yaesu/ftdx10.c | 70 ++- rigs/yaesu/ftdx10.h | 2 +- rigs/yaesu/ftdx101.c | 70 ++- rigs/yaesu/ftdx101.h | 2 +- rigs/yaesu/ftdx101mp.c | 5 +- rigs/yaesu/newcat.c | 1054 ++++++++++++++++++++++++++++++++- rigs/yaesu/newcat.h | 17 +- rigs/yaesu/vx1700.c | 148 ++--- rigs/yaesu/yaesu.c | 1 + rigs/yaesu/yaesu.h | 1 + rotators/celestron/celestron.c | 2 +- rotators/easycomm/easycomm.c | 2 +- rotators/ether6/ether6.c | 2 +- rotators/gs232a/gs232.c | 2 +- rotators/gs232a/gs232a.c | 2 +- rotators/gs232a/gs232b.c | 2 +- rotators/ioptron/rot_ioptron.c | 2 +- rotators/m2/rc2800.c | 4 +- rotators/meade/meade.c | 2 +- rotators/prosistel/prosistel.c | 2 +- rotators/radant/radant.c | 2 +- rotators/rotorez/rotorez.c | 2 +- rotators/satel/satel.c | 16 +- rotators/spid/spid.c | 12 +- simulators/{simyaesu.c => simft991.c} | 10 + simulators/simicom.c | 15 +- simulators/simkenwood.c | 28 +- simulators/simyaesu.c | 50 ++ src/iofunc.c | 50 +- src/iofunc.h | 4 +- src/mem.c | 2 + src/misc.c | 67 ++- src/misc.h | 2 + src/network.c | 20 +- src/rig.c | 361 +++++++++-- src/serial.c | 47 +- tests/ampctl_parse.c | 2 +- tests/ampctld.c | 4 +- tests/dumpcaps.c | 1 + tests/rig_bench.c | 9 +- tests/rigctl_parse.c | 95 ++- tests/rigctlcom.c | 4 +- tests/rigctld.c | 4 +- tests/rotctl_parse.c | 2 +- tests/rotctld.c | 4 +- tests/testcookie.c | 9 +- 153 files changed, 5574 insertions(+), 1939 deletions(-) copy rigs/dummy/{flrig.c => tci1x.c} (65%) create mode 100644 rigs/icom/ic7300.h create mode 100755 rigs/yaesu/FT8X7eeprom.odt copy simulators/{simyaesu.c => simft991.c} (93%) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Nate B. <n0...@us...> - 2021-12-02 23:52:16
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The annotated tag, 4.4 has been created at a28f8f85214540379909a7a7580b277665d83b2e (tag) tagging 5f8c4cd5c2c0830c8e363762c4255c6e3e4d3e3f (commit) tagged by Nate Bargmann on Thu Dec 2 17:49:56 2021 -0600 - Log ----------------------------------------------------------------- 4.4 Hamlib 4.4 release -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQSC1k9rDmfNQfaJu6b7LFEw1VqIGQUCYalb/QAKCRD7LFEw1VqI GczuAJ0TFvu0mvd+I16txXKh1nocFttejQCdG5BjIfRwLV6P85CUrBtjDsqHrZY= =dT12 -----END PGP SIGNATURE----- (no author) (1): New repository initialized by cvs2svn. Adrian Chadd (1): Upgrade TS-711 and TS-811 to work. Agis Zisimatos (1): easycomm: Return the correct value of pointer val Alessandro Zummo, IZ1PRB (36): Remove const from priv_caps to allow kenwood_init to initialize default values if they're missing Call kenwood_init in each and every driver Use an appropriate debug level Support get/set_powerstat on pcr100 Add kenwood_simple_cmd Make set_ptt behave as before, fix set_ant for ts570.c ts450: remove RIG_FUNC_TONE from has_xx_func if tone unit is not detected ts450,ts690,ts850: use FL command to get/set filters in get/set_mode. (code from ts850.c) ts450: indentation fixes remove fixed command terminator (;) from generic code ts140,ts2000,ts480,ts570,ts680,ts850,ts870s: remove usage of fixed ; and EOM fix tabs thg71,tmv7,ts450s,ts690: verify rig id at rig_open ts450: implement set_channel remove unused parameter from get_kenwood_func ts570,ts850,ts870s,ts140,ts480,ts680: use kenwood_simple_cmd where possible Replace __FUNCTION__, which is gcc specific and was deprecated a long time ago, with __func__, which is at least defined in C99. generic, ts850: implemented CTCSS TN command (reported not working for ts850, should now be fixed) Add description for the kenwood mode n. 8 implemented set/get_ext_param (voice, fine, xit, rit). enabled on ts450 and ts850 Added my call sign removed comment about switch optimizatons. the compiler will generate the assembly code in a different order which is usually based on the case value. other compiler optimizations might also affect it, so it's useless to optimize the order. check ptt status before set_ptt. enabled on ts850. style fixes band up/down was inverted Try to compensate for leftover characters Try to cope withe the PCR100 and PCR1000 at the same time Bumped out to beta, solved a few bugs. Tested with PCR100/1000/1500. kenwood: send the whole buffer at once, added kenwood_cmd - removed EOM, it's handled by kenwood_transaction - fixed tabs and spaces - added generic routine for vfo errors - set_mem: do not switch vfo if already in mem mode - simplified invocation of some commands - buffer optimizations - added PARM_BEEP and PARM_APO - fixed getting of LEVEL_RFPOWER - fixed get_ant tmv7: removed EOM thg71: removed EOM thf7: - wrong rfpower level granularity - added .reset - call kenwood_open - use generic th_set_vfo th: fixed formatting issue th: fixed stack corruption th: fixed a missing newline Alex V Flinsch, KC2IVL (8): Initial changes for ft100 Initial release initial release fixed various command options new file, list of tones/codes and sequence used by various yaesu rigs added get frequency to ft100 code added getinfo func hdr *** empty log message *** Alexander Sack (1): Get firmware revision level from K3/KX3. Alexander Schultze (3): easycomm: include a new EasyComm3 to support move speed and infostring update EasyComm3 to include setting and getting of config and status easycomm: implement get/set config, easycom include status and error bytes, fix get_info Alexandru Csete OZ9AEC (34): Added new stylesheet to make API docs look better. Modified to use new stylesheet. Added doxygen comments. Added rotator.h and rotlist.h to the input list. Applied Tommi's improvements from the FT-857 backend with the following changes and additions: Full RF power scale corresponds to 10 bars, not 15. Added RIT, XIT and IF shift ranges to dummy backend. Cast constant caps to variable caps in order to avoid compiler warnings. Cast from const to variable in order to avoid compiler warnings. - Cast unsigned char to char in order to avoid compiler warnings. - Ensure that all variables have a value before they are used (ft920). - Disable unused functions and variables (frg100). - Incremented backend version numbers. Use tone_t for pcr1_ctcss_list. Changed arg 4 of pcr_transaction to unsigned. Cast the other mismatches to (char *). Cast unsigned char to char in order to avoid compiler warnings. Incremented backend version number. - Cast unsigned char to char in order to avoid compiler warnings. - Ensure that all variables have a value before they are used (tentec.c). - Cast unsigned char to char in order to avoid compiler warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version number. - Cast/change unsigned char to char in order to fix compile warnings. - Incremented backend version numbers. - Cast unsigned char to char in order to avoid compiler warnings. - Handle all enum values in switch statements. Fixed type mismatches that caused compile warnings. Fixed type mismatches that caused compile warnings. Initialise icom_val to avoid compiler warning. Fixed type mismatches between signed and unsigned char. There are a few very suspicious 'if' statements in icom.c and frame.c - Fixed type mismatches and unhandled switch cases. - Incremented backend version numbers. Cast constant caps to variable caps in order to avoid compiler warnings. Updated. Added infor about w (send_cmd). Max serial rate is 9600. Changed backend status to stable. Escape the backslash character. The 765 can do RIG_SCAN_PROG and RIG_SCAN_MEM. Fixed S-meter reading to use calibration table since frontend always uses RAWSTR. Fixed RF power reading and added power2mw and mw2power. Fixed RIG_LEVEL_STRENGTH reading. Andrew Errington (1): Initial support for CM108 GPIO contorl of PTT AuroraRAS (5): Prepare .gitignore file for NDK build Append the missing information to build hamlib v4.3 for Android NDK make the Android.mk files adapt to multi arch add androidsensor rotator AndroidSensor codes improvement Ben Coleman, NJ8J (6): Fixed bug in rpcrig_set_parm (using RIG_LEVEL_IS_FLOAT instead of RIG_PARM_FLOAT) Fixed same bug in rigctl_get_parm. Added checking of return string from rig on set (non-retrieval) commands. Added code for COMP function. Added alinco_set_parm & tweaked dx77 capabilities. Handle setting Keyer speed and CW Pitch Added NJ8J's email address. Change email address for NJ8J Berndt Josef Wulf, VK5ABN (11): Implemented rig_set_channel() Implemented set_parm() for BACKLIGHT operation Commented out RIG_MODE_PKTFM overlooked at the submission of previous code Implemented RIG_MODE_PKTFM and RIG_MODE_PKTLSB modes Changed debug message format for freq_t from long long to double ft990_get_ptt() now uses the FT990_SF_XMIT instead of FT990_SF_PTT. FT990_SF_PTT only returns status of PTT activated by CAT commands, whereas FT990_SF_XMIT reports the actual status of the ptt line. ft990_get_mem(): Fixed bug that prevented the reporting of current channel number when vfo != RIG_VFO_MEM Fixed erroneous return value Fixed mispelled name for VK5ABN Added missing modes to RX/TX caps Fixed bug in ft990_set_mode that caused RTTY interchanged modes USB/LSB Fixed bugs in ft990_get_channel Bill Barker (1): Add test for Flex 6300 ID Bill Somerville (212): Patch submission for IC-756 Patch to allow same serial port for PTT and CAT. Patch to fix broken Yaesu backend with FT-2000(D) Fix rig_open not failing when PTT/DCD port is unavailable. Fix Icom IC-756 filter handling. Fix Yaesu newcat backend set_tx_vfo issue. Add support for Data Modes on Icom "Pro" models. Fix Icom IC-726 mode handling. Fix Kenwood TS-2000 split operation. Fix Kenwood Split Operation for TS50 & TS480. Fix Kenwood TS-870s split and bandwidth set/get. Correct receive buffer length for IS; comamnd. Fix Kenwood CAT transaction busy retry mechanism. Fix Kenwood get split VFO function. Add data sub-mode support for TS590s. Correct order of MD and DA commands for TS590s. Get firmware revision for TS590s in rig_open. Fix TS590s firmware defect. Fix Kenwood get_vfo function returning wrong VFO in split TX. Make Kenwood TS590s firmware defect fixup revision specific. Extend TS590s firmware defect fixup to both VFOs. Fix Icom IC-756 Pro III get data mode. Add spilt mode get and set for Elecraft K3. Fix data sub-modes on Elecraft K3. Fix Elecraft Data Mode Translation. Fix Elecraft K3 Data Sub-Mode Setting. Fix Yaesu FT1000MP and FT1000MP Mk V modes. Fix configure.ac Fix a warning message. Added option to not use VFO XCHG command when setting split parameters. Fix a buffer overflow in the Windows termios emulation. Fix pkg-config generation. Fix Icom IC-756Pro mode get/set. Facility for rigctl to read commands from standard input. Add a pause command to the rigctl command set. Prefix action function names so as not to clash with system names. Prefix action function names so as not to clash with system names. Corrected typos in rigctl.1 manpage. Add read commands from stdin and pause command features to rotctl. Merge branch 'rigctl-stdin' of ssh://git.code.sf.net/u/bsomervi/hamlib into rigctl-stdin Fix manpage errors. Remove redundant RIG_PTT_SERIAL_CAT enum from ptt_t Only check for serial control line conflicts if PTT shares CAT port Fix Ten-Tec Orion get/set split functions Icom IC-7410 has VFO A/B not MAIN/SUB Added IC-7410 data modes Add retry mechanism for Yaesu "newcat" backend Implement retries for Yaesu "newcat" rigs Disable auto information mode on open Add retry mechanism for Yaesu "newcat" backend Implement retries for Yaesu "newcat" rigs Disable auto information mode on open Merge branch 'yaesu-retries' of ssh://git.code.sf.net/u/bsomervi/hamlib into yaesu-retries RIG_OK is zero and need not be negated and this will not change Fix response length expected error in K3 back end Data mode support for the Icom IC-7700 Data mode support for the Icom IC-9100 Data mode support for the Icom IC-7200 Add support for the Kenwood TS-590SG Kenwood TS-590SG Always clear serial control lines when used for PTT Disable AI mode on open for Kenwood/Elecraft rigs Add more diagnostics and error checks to serial line control Move serial line control error checks to lower level routines Merge branch 'master' into kenwood-ai-off-at-start Merge branch 'master' into ptt-control-on-cat-port Fix serial i/o on Windows. Yaesu newcat style command response reading improvements Increase communications timeout for Icom rigs Kenwood AIn; command has no reply Revert read_string() to partial results are a success status Remove gratuitous sleeps before function exits Error checks on simulated direct VFO addressing Elecraft K2 RTTY modes are not FSK Kenwood and Elecraft rigs sometimes ignore commands Removed kenwood_cmd function and replaced uses of it Allow for failed test command on the K2 Elecraft K3 has 1 stop bit Kenwood TS-570 series IF returns current frequency Switch to "ID;" command for verification as no "AI;" on TS-840s Increase Elecraft K2 comms timeout and retries Switch Kenwood TS940 to generic kenwood CAT functions Improve command verification for Kenwood & Elecraft Use local buffer in kenwood transaction funciton Clarify the handling of Kenwood CAT message terminators Further clarification in the implementation of kenwood_transaction() Removed redundant precondition test Remove kenwood_simple_cmd as kenwood_transaction has that functionality Call kenwood_open() for TS-2000 to ensure AI mode is disabled Allow for bad ID from DDUtil in TS-2000 mode Allow one extra byte in read_string() length to accomodate terminator Enable data modes for the Icom IC-7100 Allow for PowerSDR ID in Kenwood TS2000 emulation mode Fix TenTec Argonaut message lengths and timeout Fix TenTec set split command Implement get PTT status for the TenTec Argonaut Fix error with width in set mode for the TT argonaut Yaesu FT540 can only change the frequency of the current VFO Fix defect in Kenwood TS-940 IF command response parsing Fix response lengths for the TT Jupiter 538 Do not attempt CAT PTT commands on the Icom IC-706mkIIG Use correct argument type for serial control line functions Initial back end implementation for the Kenwood TS-990s Mode set is not VFO targetable on the Kenwood TS990s The Kenwood TS990s only does split Tx on SUB VFO The doesn't appear to be a way of getting PTT/SEND on the TS990s Lower both RTS and DTR on alternate PTT serial port Honour any error status from serial port calls Dummy get_ptt function needs to read RTS/DTR/PARALLEL Make autogen.sh agnostic to whitespace in paths Increase the number or retries for most Kenwood rigs Command validation for Yaesu set commands Remove unecessary delays from TS-940S backend Proper IPv6 and dual stack networking Fix compiler warnings Proper IPv6 and dual stack networking for rotator net daemon Attempt to restore AI status on exit Allow for poor emulations of Kenwood rigs that have no ID command Use correct function to execute set type commands with no response Add a new command line option '--no-restore-ai' ('-n') to rigctl Fix FT-817/857/897 issues and add some missing functionality Fix missing PKTUSB mode setting code for FT-817 & FT-897 Fix a logic error in band detection during IC-910 set frequency Add missing configuration getters Detect C-IV NAK returns as rejected commands Elecraft rigs do not switch VFO in IF command responses during split Tx. Redundant split mode directives on Elecraft rigs cause Tx failures Only use IPv6 features on Windows versions that support it (>=XP) Improve IPv6 portability and consistency Add 23cms to IC-910(H) backend Implement combined split VFO frequency and mode setting. Initial implementation of rig_{set,get}_split_freq_mode() for FT-857. Implement rig_{set,get}_split_freq_mode() for IC-756 series. Add {get,set}_splitfrequency_mode for the IC-910(H) Elide unnecessary CAT commands when setting split frequency and mode Do not swap VFO unnecessarily Better set frequency semantics for the IC-910(h) VFO targetable get frequency operation for the Icom IC-910(h) Make sure right band is used when setting frequency on IC-910(H) Use rig state rig port retry option rather than from capabilities Use a sensible port timeout value for the Kenwood TS-850 Further attempts to simplify and improve Icom CAT for split operating Add RIG_PASSBAND_NOCHANGE as possible set_{split_,split_freq_,}mode argument Switch to POSIXLY_CORRECT mode for getopt_long() Fix a regression introduced in 222ad74 Do not crash if expected CTCSS tones not sepcified Do not attempt to query AI state on the TS-450s as it is not supported Some more Kenwood rigs with no AI query Adjust rig_list_foreach to allow use for unregistering Fix an issue presenting on the Yaesu FT-450(D) Release the serial port used for PTT when possible Change the IC7600 & IC7800 set/get mode to versions that support DATA modes Add rig_{open,close} functions to TS-790 backend Revised kenwood rig busy response handling Add get and set split functions for the TS450S Simplify and fix defects in the FT991 back end Fix some endian issues in the si570/AVR SDR back ends Fix a state machine defect with repeated PTT reset calls Do not pass --no-cpp_precomp to compilers on Mac OS X Allow RIG_LEVEL_STRENGTH queries over the network link Stop rigctld and rotctld crashing when service threads cannot write to clients Use snprintf throughout kenwood/kenwood.c for buffer safety Fix off-by-one issue in reading memory mode from IF command response Fix some issues with commands not supported by TS-2000 CAT emulations Add best guess transmit status to rig state structure Take out unecessary delays in K(X)3(S) back end. FT-817 status queries honour retries and timeout Make rig_open() call in rigctld lazy and add graceful termination Simplify SWIG interface definition and hide 64-bit values from Lua binding Remove unnecessary delays from TS-990 and TS-2000 back ends Change frequency setting for the FT-747GX to something more basic Fix an incorrect error return value from win32_serial_select() Fix timeout issues with the Ten-Tec Orion/Eagle Ensure compilation works with a pre C11 compiler Make code C90 compliant again Move unnecessary global and file static variables to the stack Simplify unnecessary persistence of extended response state Fix misunderstanding of netrigctl_transaction() return value Made PTT and DCD options consistent between rigctl and rigctld Report unrecognised PTT and DCD types in rigctl and rigctld Update i/o functions to support GPIO(N) port closure Fixed erroneous messages in rig_close with GPIO(N) PTT or DCD types Remove duplication across GPIO and GPION handling of PTT and DCD Improved get PTT state handling in dummy backend Simplify closing of device files Repair a regression with the dummy get PTT functionality Revert "Add debug to serial.c" Repair a regression with the dummy get PTT functionality Revert "Add debug to serial.c" Fix regression with slow responses from SmartSDR causing errors Deal with remote PTT type at the client end Avoid 'echo -n' as macOS sh doesn't support it Fixing an operator precedence defect Updates to the TH-D7A/E back end Less ambiguous variable name and repair merge issue in prior commit Add missing config parameters for rig power on/off and screen-saver New power on option rather than power on/off Make version recording safe for parallel builds without breaking make dist Make version recording safe for parallel builds Ensure old hamlibdatetime.h headers in the source dir are ignored Merge branch 'safe-scs-versioning' of ssh://git.code.sf.net/u/bsomervi/hamlib into safe-scs-versioning Fix make dist versioning Use BUILT_SOURCES make mechanism as intended Fix rebuild dependency Build hamlibdatetime.h every time Force copy over existing Minimize rebuilding Correct use of sh if Another attempt at a reliable SCS version header generation Remove temporary file Add missing shared library API exports Add missing export definition Blaine Kubesh (8): added Icom803 to icmarine added Icom803 to icmarine added Icom803 to icmarine Update ic-m803 remote-id to 20 Update icm803.c Update AUTHORS undo author changes Update icm803.c Bob Freeman (1): New CNCTRK rotor backend Brian G. Lucas (10): Pretty much a complete re-write of thd72.c, since the old one didn't work at all. Many commands have been tested with real hardware. But more work remains to be done. WIP: thd72 driver. More level, func, and parm stuff works. WIP: thd72 driver. Try to simplify the menu based interface. WIP: thd72 driver. First cut at get_channel(). Other cleanup. WIP: thd72 driver. More interfaces implemented. Other cleanup. Implement some more interfaces. Comment out get_chan_all_cb because the block read routine doesn't work. Fix a format so that it works with Windows. Can't test it because I have no Windows machines. Fix RFPOWER level for FT-450D. It uses 5-100, rather than 0-255 that the FT-450 does. In newcat_open(), initialize rig_id in case any subsequent commands need it. Some calls to thd72_get_menu_item where passing wrong values for range check. C-Elegans (1): Add ability to have rigctld display transverter frequency Charles Suprin (7): Add file for TM-D710 support. Merge branch 'master' of ssh://hamlib.git.sourceforge.net/gitroot/hamlib/hamlib Add D710 to riglist. Add D710 code to kenwood library. Register D710 interface. Initial D710 Implementation. Register D710 interface. Charles Suprin, AA1VS (3): extend th_get_vfo_char to support D700 Changed th_set_freq to round and select step size to use. Allows 6.25kHz and 5kHz channelization. Use new th_set_freq for TM-D700 Chris Karpinsky, AA1VL (7): add serial_flush() method to clean rx buffer initial stab at this for the Yaesu FT-817 add ft817.* add ft817 bump the backend status to ALPHA Initial entry of cgirig giving ability to use hamlib from a web browser. increased post write delay to 300 Chris Ruvolo (4): TS-690: deal with optional tone board using TS-450 logic TS-690 does not implement the PC command to get/set output power level TS-690 does not implement the GT command to get/set AGC rate TS-690: bump version Christoph Berg (2): ic7610: Re-add send_morse Implement netrigctl_stop_morse Chuck Hemker, N2POR (1): Use RIG_TARGETABLE_MODE in rig_set_mode and rig_get_mode Chuck Ritola (8): Use loop to ensure RS-HFIQ hears first command. Closes #730 Add ability to read TX drive level Implement board temperature reading for TEMP_METER Parse and store RS-HFIQ firmware version. Firmware version check before power meter query. Merge branch 'master' into rshfiq-aug2021 Map FCDPP LNA and Mixer Gain as PREAMP values. Closes #766 Map FCDPP LNA and Mixer Gain as PREAMP values. Closes #766 DL1YCF (6): Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Merge branch 'master' of https://github.com/Hamlib/Hamlib Dale E. Edmons, KD7ENI (19): Added comments to commandline in rigctl (second time) --Dale Started TS-2000 update/overhaul --Dale Copied too much stuff, backed out what I broke. Bring ts2k.c more in line with current CVS. Changed ts2000.c to ts2000.h. Start of rig menuing functions. New file. Renamed ts2000.c.new ts2000.h Bring code more in line with CVS code. Changes often, so added status. Will delete when things stabilize. Corrected status to CVS branch. Renamed new ts2000.c to ts2000.h Wouldn't compile. Removed ts2k.c. Haven't got all new rig.h stuff removed. Temp kludge to make ts2k.c compile (keeps Hamlib from compiling!). Updated status. Added working TS-2000 files. There are some changes left out but this is the minimum I could commit and have a functional rig. The cost is that I've broken kylix and others that duplicate rig.h. I'm in the process of repairing the damage. Please be patient. I hope a day or so, but am asking for up to a week. E-mail me about *anything* you find broken. Kylix (and similar) is (are) known to not work. Changed name back to original. Had to re-run automake kenwood/Makefile. 1) Updated branch_ts2k with respect to HEAD. 2) Working ts2k_menu. (only in RIG_MODEL_TS2K) 3) Split TS-2000 into experimental and standard versions: RIG_MODEL_TS2000 = standard, RIG_MODEL_TS2K = experimental. 4) Basic command parser in tests/rc. Will open/close rig or copy a freq from one rig/vfo to another rig/vfo. Very cool. Very basic. Very experimental. 5) Added test programs. a) testcmd - calls parser (no command prompt yet!) b) testts2k - replacement for testrig (with trivial modification) c) testptt - testts2k/testrig should not transmit. TX stuff in testptt. 6) Used crowbar to merge HEAD into branch_ts2k. Working on clean-up. 7) I'm sure I've forgotten or neglected to mention some other stuff. Daniel Estévez (2): Fix DIG MODE for FT817-ND Fix DIG MODE for FT817-ND Daniele Forsi (5): Set the executable bits on py3test.py Fix spelling errors Fix more spelling errors Fix more spelling errors Fix typos Daniele Forsi IU5HKX (1): Fix a [missingInclude] "information" when running cppcheck --check-config Dario Ventura (3): New Prosistel rotor backend from IZ7CRX Add elevation code to Prosistel backend TS2000 Satellite mode and Gpredict Dariusz Bismor, SQ9KEJ (1): rigmem: implement CSV file loading David Fannin (1): Submission for new backend model (134) for Yaesu FT-DX1200 Davide Gerhard (3): tests/{memcsv.c,memsave.c}: partially revert commit 4072f9f4 ic746.c: correct chanbuf length, fix channel structure and support split ic746.c: add ic746pro_set_channel() to load memory from csv Dawid SQ6EMM (1): Add method to build inside docker Dawid Szymanski (2): ICOM Voice Keyer implemented. typo fix Diane Bruce, VA3DB (5): - first cut at fixing configure to recognise --without-tcl-binding and --without-python-binding options - gt_HEADER_INTTYPES_H is definitely bogus here, leftover from what? - document debian/FreeBSD needs for AUTOMAKE etc. - add in libtoolize which should be there - These should have been commented out. - Extra comma on RIG_STATUS_BUGGY can cause a compiler error. Dieter Röver (1): Fix bug in vfo_comp calculation in Hamlib Ekki Plicht (DF4OR) (2): New model Icom IC-R8600 Patch for Icom DCS code handling Elliott Liggett (1): Added functionality for the IC-7300 auto antenna tuner Eriks Dobelis (2): ft817: adding delay before next retry after returning from tx to rx ft817: Moving delay value into #define section of the header Ervin Hegedus (9): RIG_PASSBAND_NORMAL wasn't handled correctly when rig_set_mode() was called - fixed Fixed SWIG `Setting a const char * variable may leak memory' error Fixed Kenwood filter cmd when passband is set to 500Hz Merged from upstream Merge branch 'master' of http://git.code.sf.net/p/hamlib/code Added Lua binding and demo script Added new example to Python demo script (set/get float type level) Change variable length argument handling in affected functions Fix two typos Ervin Hegedüs (1): rig.swg: New properly formatted macro Evgeniy Titorenko (1): Add Radant AZV-1 Rotator controller protocol. Francois Retief (21): Added read_serial function to read strings from a port. Corrected some comments Added code to hexdump to right align ASCII dump column added private caps for rig termination character add private caps and more commands. Changed to a new transaction function and adde quite a few commands. add private caps to store the termination character of Kenwood rigs commands. added a kenwood_init and _cleanup routine for priv caps & priv data. Added a new function: LCD Lamp ON/OFF (for Kenwood TH-7DA) check trn state of rig in rig_open. Initial commit of Kylix binding New backend for rotators New RPC backend for rotators Added rot_move function Fix macro name Added rot_move function Added easycomm and rpcrot backends Fixed circular dependency for rpc.rigd and rpc.rotd regenerated Added IC-910 rig. Added constants for the IC-910 rig. Frank Goenninger (3): Add ADAT ADT-200A backend adat updates from Frank, DG1SBG ADAT fixes on Windows Frank Singleton, VK3FCS (165): Initial revision Initial revision *** empty log message *** *** empty log message *** *** empty log message *** Initial revision Initial revision *** empty log message *** *** empty log message *** added build_all ,cleanall and verify targets *** empty log message *** initial top level makefile add some things initial import initial import initial import fixed some typos use rig_open and rig_close added rig_open and rig_close fixed cmd_sat_on / off added sat-on and sat_off to test changed cmd_get_rx_status, must do tx also updated test() all reads use while (1) and break added ../common as object path added rig_open and rig_close using rig_open and rig_close and serial.h use common dir for serial stuff use ft747 on serial port /dev/ttyS0 read uses while(1) and break use while(1) and break added read_sleep use read_sleep now from serial.h using read_sleep from serial.h had rx and tx status swapped (document error?) removed cmd_get_update using CVS instead of RCS directories use MODE_xx defines cannot use const int in case statements ?? so use #define instead use #defines for MODE_XXX used in case statements working out freq conversion, unfinished playing with test routines long int cmd_get_freq_mode_status_main_vfo(int fd, unsigned char *mode); long int cmd_get_freq_mode_status_main_vfo(int fd, unsigned char *mode) frq = cmd_get_freq_mode_status_main_vfo(fd, &mode); starting with the cmd_set commands now starting on cmd_set commands now starting on cmd_set_freq commands now add scanning todo now set sat rx and tx freq and mode also fix typo dump raw hex data when writing and reading trying some cms_set_freq_xxx commands added routines for dec <-> packed decimal conversion minor added generic hex dump routine, static void dump_hex(unsigned char *ptr, int size, int width); removed unwanted debug printf's removed dump_hex from here.. calc_freq_from_packed4 is about to be replaced calc_packed_from_char and calc_char_from_packed now here cleanup cleanup void dump_hex(unsigned char *ptr, int size, int width); adding dcs tables and repeater offset in Hz describe faulty yaesu documentation added README.license for GPL added GPL license info included full GPL license Updated docs to point to http://sourceforge.net/projects/hamlib/ and added a C code snippet on how to use the API. added -I$(COMMON_DIR) to find rig.h added -I$(COMMON_DIR) to find rig.h adding capabilities initial capabilities stuff starting to add rig_caps stuff starting to add rig_caps stuff starting to add rig_caps stuff. added GPL stuff and comments adding rig_caps stuff adding rig_cap stuff adding rig_caps stuff add capabilities and preferences adding rig_caps functionality adding rig_caps stuff frontend reduction on backend function namespace - phew !! frontend API clarification removed old open_port2() using old rig_caps fixed some typos, added 3 more candidates for API missing ; in some enums converting to frontend/backend structure compiles ok removed open_port() and write_block() removed open_port() and write_block() fixed typos, added &ft747_caps in rig_caps changing to frontend/backend style converting to frontend/backend style added 3 more cmd_* for API examples Example of setting rig Main VFO to 439.700 Mhz FM cleanup comments added extern const struct rig_caps ft747_caps; still thinking about set/get strategy minor updates added extra rig caps added some set/get examples with return code checking added testrig to Makefile, no linking yet added usleep to read_sleep() updated rig_caps structure *** empty log message *** test making a shared lib (at last) for the frontend - more todo test making a shared lib for the frontend - make hamlib describe frontend/backend structure updated code snippet example started ft747_set_ptt and ft747_set_vfo starting to implement set/get pairs added typedef enum ptt_type_e ptt_type_t; added VFO types to enum starting on libhamlib Makefile, added ./lib and ./include under common make, make install, and make clean work ok, using ./lib and ./include directories also. make, make install, and make clean work ok, using ./lib and ./include directories also. removed "make verify". Added reference to common/Makefile added printf("testrig:main() has been called \n"); for testing linking makefile for testing testrig linking alternative rig_base declaration removes references to rig_caps at compile time. should populate it another way -- FS added printf's to confirm rig.c (hamlib) is being called ok better libhamlib.so version :-) added ft847_open and ft847_close to enable CAT ON/OFF added ft747_open and ft747_close updated lib names for backend to libhamlib-xxxxx.so API updates - added set/get_mode merge with TRN stuff and add some set/get_mode and vfo stuff added post_write_delay cvs mails to hamlib-cvs-digest cvs mail update works ok :-) minor fixes updated ptt/mode/vfo added set/get freq to use generic bcd etc more set_freq() examples 1. Added VFO as target for some set/get cmds. 2. ./testrig still runs ok using RIG_VFO_CURR. minor update to active VFO handling in _set_vfo some new defines for FT747_VFO_A/B minor updates to active vfo handling added ptt handling example, stand back ! trying different approach to storing cmd sequence. _set_ptt is being converted. Needs tidying up though. Some sequences are complete, and can be read from static data. Incomplete sequences will eventually be copied form static declaration, and completed in priv data. Removed static stuff from functions. Also, begin to implement table driven command translation from API to rig native. priv now contains a cmd table that is used for backend commands towards rig. Added some new freq/mode combinations. converting ft847 to table driven, similar to ft747. more table driven stuff for ft847. cat/ptt/freq being converted. Added ft847_send_priv_cmd(), converted some part of API to use this. Added _set_mode to work now. TODO: put _send_priv_cmd into yaesu.[ch] so ft747 can use also. Turned on PTT also (stand back).. rig_cleanup and rig_close not calling backend removed unused calc_ functions. removed old API functions, general cleanup tested rig_close and rig_cleanup Initial release, common yaesu declareations etc. add version tag nseq uses YAESU_CMD_LENGTH Initial yaesu Makefile Moved from ft747 and ft847 dirs common yaesu handling common yaesu dir Begin to use common yaesu code general cleanup, added _send_priv_cmd added targetable_vfo value to caps minor cleanup ChangeLog history started Initial import for ChangeLog handling starting to convert rig struct to readable form more of convert rig struct to readable form Changelog update for HAMLIB-1.1.1 Gerardo Richarte (1): gs232b.c: Improve get_position string parsing Gisle Vanem (1): Enable verbose mode in bindings/pytest.py Greg Troxel (1): Warning about dodgy code in drake.c HB9EIK (4): Initial release ELAD FDM DUO Update ELAD files Update build system for ELAD backend Update copyright for fdm_duo.c Hans Van Ingelgom (1): Added Peaberry V1 and V2 models Hegedüs Ervin (4): Merge branch 'master' of http://git.code.sf.net/p/hamlib/code Check SWIG string functions for some languages Leave off multiply 'typedef const char * const_char_string' definition (in rig.swg and rotator.swg) Fixed int[10] type variable error in bindings Jae Stutzman (5): Added HPSDR backend Clears potential garbage data in read buffer prior to command being sent Updated PiHPSDR backend defaults Use Windows ioctlsocket to avoid buffer overrun Added new AGC control for PiHPSDR James Watson, HZ1JW (2): Added ic7200 to icom Corrected modes in ic7200.c Jaroslav Skarvada (2): Fix hardcoded pcconfig libdir Fix serial_port DCD squelch Jeroen Vreeken (9): Add support for GPIO PTT. Add missing breaks and improve error messages Add Dorji DRA818 modules (VHF and UHF variants) Also works with NiceRF SA818 modules Merge branch 'master' of git://git.code.sf.net/p/hamlib/code Small fixes to DRA818 volume handling Add GPIO and GPION options for DCD. Also bump abi version since the config params struct needed resizing. Merge branch 'master' of github.com:Hamlib/Hamlib GPIO working after debugging Merge branch 'master' of github.com:Hamlib/Hamlib Johan Ström (1): Backup serial options on open, restore on close John Paul Adrian Glaubitz (1): dummy/dummy.c: Fix unaligned access in dummy_get_level() Jonathan Bastien-Filiatrault (3): Correct FT; command that does not exist on the FT-891. Allow setting split mode without smashing the VFOB frequency. Scale power values correctly for Yaesu FT-891. Jonny public (1): ether6: New rotor backend from Jonny, DG9OAA Joop Stakenborg, PG4I (116): update (kenwood is not a WIP anymore) first implementation of kenwood_get_ptt enable get_ptt for this rig add get_ptt for this rig additional protocol checks and cleanups fix signal strength add RIG_LEVEL_RFPOWER fix_compilation add rit capabilities bring comands in sync with other kenwood rigs add rit capabilities send_morse added explain set_rit fix get_ctcss_tone by using IF command typo add xit capabilities add set_level and get_level bring rig in sync with other kenwood rigs bump version numbers nothing returned by the rig for these commands fix get_level_agc fix set_level_agc getting in sync with the debian 1.1.2 package remove template files initial checkin make this NMU for now correct the path for copying files in the apropriate package do not install the old changelog versioning not used move .la, .a, .so files to the correct package include rpc.rigd and rpc.rotd include pkgconfig support don't create shlibs file for drake, jrc and easycomm libraries move hamlib1 to the top so the documentations gets installed correctly make building easier, call autogen.sh INSTALL file not used build the documentation package we don't have to call configure twice cleanup remove some build dependencies and don't call autogen.sh ts450s uses IF command for get_vfo, get_freq and get_mode minor bugfix, bump to beta add CWR and RTTYR this rig does not have a command for reading IF bandwidth retrieve passband with FW command passband should be calculated after mode is set use rig_passband_normal here various lintian fixes one last lintian fix use FW command to set bandpass cw filters for normal, narrow and wide more filters get_mode and set_mode for this rig filters some comments correct rit add get_level cleanups more modes set_level for this rig should use kenwood_get_freq minor bug add rpm support need hamlib.spec for 'make rpm' make rpm will fail with a '-' in the version number a working spec file update debian build for rotorez and fodtrack, minor fixes unofficial fix the debian build script, new maintainer update the debian build tree to the latest correct baudrate for the ts-950, use the information field IF for get_vfo by default (supported by most kenwood rigs), ts870s will use the much shorter FR command for get_vfo correct baudrate for some rigs and add ts-950 to the id_list ts-850 returns ID 009 according to martin, OK1RR fix 'make rpm' build for hamlib-1.1.5 not needed sync with latest debian package and add tcl, c++, python and perl bindings correct spelling s-meter calibration by Matt Dawson basic functionality by Matt Dawson, tested with grig and xlog lifetime e-mail address :-) sync with latest debian release more functionality, mode and frequency get by Matt Dawson only switch tx vfo is split is on set attenuator level export convenience function get_kenwood_level, so they can be use by other backends add RIG_LEVEL_SWR, copied from ts850 add RIG_LEVEL_COMP, RIG_LEVEL_AGC, copied from ts850 bump version, no preamp really add ALC read this time, only change meter if needed, cleanups split has_get_level and has_set_level fix coding, python2.4 compatibility fix compilation warnings more compilation warnings nuked, use tone_t for ctcss_list use size_t fix more compilation warnings, int->size_t, unsigned char->char more unsigned char->char and int->size_t transitions set functions should have ack_len zero, also need to check other rigs make sure we use ack_len=0 for functions that return nothing (set functions) more unsigned char->char and int->size_t transitions extend rig capabilities, patch by Tom, DL1JBE add RIG_LEVEL_STRENGTH to caps, set post write delay to 0 and do some cleanups re-establish post-write delay remove rpath backdoor long long really needed here? updates by matt, GW0VNR long long really needed here? - patch by diane Bruce distribute footer.html correct set/get power try better s-meter readings packages renamed obsolete sync with latest debian release no need to link to python sync with latest, python changes another debian update: use 'make distclean' in the rules file Joshua Lynch (4): initial SatEL rotator support factored io functions out. improve reliability...i hope. fixed state bug. reconnecting would disable motion every other connect. merged upstream/master into master Juergen Rinas, DC3BW (4): added antenna switching... added a few get_level/set_level get_function/set_functions. * fixed set_func (concerns most kenwood rigs) * added 115200 to the list of baudrates in probeallrigs_kenwood() * fixed ptt * expanded frequency range (available after firmware update) according to http://www.kenwood.com/i/products/info/amateur/ts_480/firmware/pop_ts480_e.htm * added tuning steps * added filter list * increased version info Julian Cable (3): WinRadio G313: Updates from Julian Campbell wrg313api.c: Fix Win32 (MinGW) build issue Use Automake conditionals for G313 build Kamal Mostafa (3): Fix mingw32 cross-compilation procedure and config Do not let macros/ac_python_devel.m4 trash CPPFLAGS and LIBS Fix spelling errors Kamal Mostafa, KA6MAL (19): Hard-code length of hamlib_version and hamlib_copyright strings to stay compliant with hamlib 1.2 ABI and avoid spurious "consider relinking" warnings from dynamic loader. Removed stale debian/ dir from the hamlib source (it is maintained in the Debian diff and isn't useful in this tree). Update bundled libltdl (libtool) to version 2.2.6b to address CVE-2009-3736. - autogen.sh: never downgrade our bundled libltdl/ (only run libtoolize if system version is newer than our bundled version). - autofixer.sh: script removed as libtool 1.x is no longer allowed. - configure.ac: (not enabled) optional setting to deprecate embedded libltdl/. Added Kamal Mostafa and Jaime Robles as maintainers for Debian packaging. Fix build --with-python-binding breakage introduced by Python 2.6: Do not reference LOCALMODLIBS, else it will add libraries to our link line (e.g -lssl) which are not necessarily installed. Elektor 507 frequency selection resolution improvements, contributed by John Nogatch AC6SL. Move backend libraries into /usr/lib/hamlib directory. Force automake to invoke the C (not C++) linker in kit/ when no C++ is in use. python: fix --with-python-binding configure macro fix configure.ac paths for FreeBSD Remove bundled libltdl (libtool) README.developer: restore libtool prerequisite text Fix segfault on improper -C syntax configure: add check and advice for missing ltdl.h configure: refine advice for missing ltdl.h source warnings cleanup: rpcgen-generated code source warnings cleanup: #if-0 out a few unused routines source warnings cleanup: #ifdef out unused FT-840 routines source warnings cleanup: rotorez_rot_reset wrapper for stop Kayne (1): Updated k3_set_modes to work on KX3 Kosta Arvanitis (1): Allow IC-7410 to send cw messages Kārlis Millers (1): Merge pull request #1 from Hamlib/master Ladislav Vaiz (3): Add Android build support Android build updates for monolithic build Initial support for FUNcube Dongle Pro Larry Gadallah (1): AR7030+: Error reading signal strength for low signal levels. Larry Gadallah, VE6VQ (20): Added Larry Gadallah as maintainer of AOR AR7030+ Added AOR AR7030 Plus Added caps for AR7030+ Added caps for AR7030+ Added AR7030+ Alpha version of AR7030+ backend Alpha version of AR7030+ backend Rationalized naming convention, ran everything through lint. Rationalized naming convention, ran everything through lint. Fixed SVN tags Fixed SVN tags Added AR7030P utilities in ar7030p_utils.c Initial version of utility functions for AR7030 Plus receiver Removed utility/helper functions, added/updated Rig API functions Added new I/O helper functions, IR code definitions Added private data to support channel information Added init/cleanup functions, started implementation of mem/channel access functions Added prototypes for pbsToHz() and hzToPBS() helper functions. Added comments to denote mey_sq, mey_pb, and mey_id labels Added implementation for pbsToHz() and hzToPBS() helper functions. Added various memory/VFO functions. Lorenzo Santina (2): Fixed rigctl ignore error command line Fixed c++ exception for visual studio compiler Magne Mæhre (1): Enable set_powerstat (turning radio on/off) for IC-7100. Malcolm Herring (62): init branch init branch New model: Icom IC-R6 Icom IC-R10 & 20 testing complete. Move to Beta ignore build Complete R6 commands Add IC-R30 daily fix tones Merge remote-tracking branch 'Hamlib/master' update Merge branch 'master' into icr6 ICR6 new functions merge update Merge remote-tracking branch 'Hamlib/master' commands 00-15 Merge branch 'master' into icr30 icr30 updates Automatically detect CI-V echo state Icom R8600 to Alpha Update contributors Merge branch 'master' into origin/master Fix Icom DCS SQL funnctions Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' Prepare for D-STAR implementation Merge remote-tracking branch 'Hamlib/master' Initial implementation of icom extended operations more extended operations Merge remote-tracking branch 'Hamlib/master' more ext functions fix merge conflicts more ext_cmd updates ic7100 ext functions Merge remote-tracking branch 'mdblack/master' Merge branch 'master' of https://github.com/malcolmh/Hamlib add token list for ext operations Merge remote-tracking branch 'mdblack/master' more ext operations Merge remote-tracking branch 'mdblack/master' custom ops using ext ops scheme custom level ops Merge remote-tracking branch 'mdblack/master' Merge remote-tracking branch 'Hamlib/master' add scope functions update IC7100 update rigs for new functions Merge remote-tracking branch 'Hamlib/master' new directory structure Merge remote-tracking branch 'Hamlib/master' correct powerstat caps Merge remote-tracking branch 'Hamlib/master' New custom parm implementations restore get_powerstat correct rig_close cap Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' Merge remote-tracking branch 'Hamlib/master' add g/set_ext_func to API additional error checking for extended operations Add Macports to README.osx Mark J. Fine (25): Fixed post-write-delay timing Added support for ECSS/FAX and meter strength Added support for meter strength Added ECSS support to R8B and reconfigured default filter modes Reconfigured default filter modes Updated to reflect recent changes within v1.2.2cvs-2 Fixed CWPITCH function on IC-R75 to use 'set mode data' command. Added level granularity steps included other rig_ prefixes fixed get_powerstat to read correctly when memory channel is blank Added memory switching function in set_vfo Added set memory channel# in radio in set_mem Added set_vfo command for vfo/mem switching Corrected handling of "vacant" memory channels Correctly detect if in memory mode in get_vfo() Reduced large decision trees with bitwise math Added set/get channel functions Updated set/get channel functions Made get_channel aware of untunable blank memory channel accounted for dual preamp (10 & 20db) Fixed passband width return for IC-756PROII Added FM narrow to passband spec Added a provisional define for a variable bandwidth control Added a provisional variable bandwidth control to the RIG_LEVEL enumeration Added provisions for a variable bandwidth control Added provisions for a tone control Corrected problems with Squelch (SQL) and Notch (NOTCHF) controls Added provisions for a variable bandwidth control (BWC) Fixed low-end of freq range from 100kHz to 10kHz. Fixed several differences in 535/545 commands Added missing manual notch switch for the NRD-545 Martin Cooper (2): Don't expect a response when none is required. Don't send EasyComm I commands to EasyComm II rotators. Martin Ewing (7): Add test for valid set frequency, esp. for VFOA (ham band only) Expand valid range_lists for full hardware ranges Fix tt565_transaction to allow Morse commands. Orion.c: remove spurious debug statement. implement level settting and misc fixes remove debug stmt Increment Jupiter version Trim TS950 commands that are not provided by CAT jupiter.c: Updates from Martin, AA6E Martin Ewing, AA6E (69): specified buffer lengths, added default vfo A setting Fix SWR & S-meter, set ATT, set AGC, add rough STR_CAL func. Fix timeout, add retry, better S-mtr scale various bug fixes Added RIG_LEVEL_CWPITCH, RIG_LEVEL_KEYSPD, send_morse() Added RIG_FUNC_TUNER, RIG_FUNC_LOCK and RIG_FUNC_VOX, fixed MEM_CAP. Added VFO_OPS, promote to Beta Support LEVEL_VOX, VOXGAIN, ANTIVOX Support LEVEL_NR as Orion NB setting (firmware bug), FUNC_NB -> NB=0,4 Add get_, set_ant (ignores rx only ant) Added Orion, Orion 2 info Squashed warnings about signedness Orion S-meter cal minor - add doxygen info for enums minor - doxygen parameters doxygen formatting add comments info on generating docs doc improvements add comment documentation documentation allow atten = 0 dB patch from SM6PPS fix enum documentation documentation page documentation documentation split orion.c and add doc info documentation SM6PPS mods for AOR 5000a further rx-320 mods by Ken Prox use binary mode VFO requests correct CHANNEL_CAPS sytax Dead simple sample Hamlib program Correct float vs int interpolation options Add autodetect version 1 or 2 firmware (using rig_get_info). Correct V1 calibration. Make V2 calibration the default. Signal RIG_LEVEL_STRENGTH supported. Moved firmware detection to new tt565_open routine, where it is done every time the rig is opened. Add more functions to example program. Ensure printable get_info string Fix bug that seg faulted when get_info returned null. (No reward points!) Add S meter operations to sample program. Adjust retry & timeout values to help in case of no response from rig, i.e., if rig power happens to be off. Prettify some code indents. Better error handling, reliability for serial I/O. Misc prettification. TT Omni VI / Plus improvements Fix typo Fix Omni VI PTT function Update Icom info Declutter Omni VI memories, rit/xit Fix serial I/O error checking Add author. (credits info added to web page, also) Switch back to ASCII freq. setting because of hardware(?) bug. Add AF, RF gain and squelch level capability. Add thanks to W1RFI & ARRL minor changes RIG_STATUS_ALPHA reflecting initial tests. fix missing comma use rawstrength.i which matters in PPC compile fix string handling in LEVEL_RAWSTR Orion - implement RIG_LEVEL_STRENGTH Example updates Orion: Allow frontend to handle RIG_LEVEL_STRENGTH Minor comment re rit/xit Downgrade ERR to WARN (i/o retry) Init revision - tnx Stephane Autofixer sets up for libtool v1 or v2 autofixer.sh supportin libtool v1 and v2 minor update repair echo cmd Max Lock (1): Addition of support for CM108B PTT Michael Black (1340): TenTec Omni VII update from W9MDB New XG3 backend Fixes to termios.c on W32 targets xg3 patch Check TS-590S for EU or US firmware New backend for FT-991 Flush the debug stream Omni VII to set VFO_CURR correctly Omni VII patch for WSJT-X FT-991 patch Small FT-991 patch for WSJT support Omni VII patch FT-857 and FT-991 patches Fix possible frequency overflow on Kenwood and Yaesu Add get_freq to FRG-100 Clean up clang warnings on adat.c Clear up a clang compiler warning in kenwood/elecraft.h Clean up clang warnings in tentec Fix port->pathname checks Quell clang warnings in tests directory Various Yaesu updates Simply define TRUE to 1 in omnivii.c Allow the ft757gx to work with WSJT-X. Remove input redirects in autogen.sh Initial support for the IC-7300 Add send_morse to icom rigs tmd710 patch Icom frame patch Exposed constants via function calls Remove define Merge branch 'master' of https://github.com/N0NB/hamlib Changed some modules to LGPL in lieu of GPL Fixed buffer overflow in rigctl_parse and rotctl_parse Merge branch 'master' of https://github.com/N0NB/hamlib Move K3 DT0 before mode switch, add version info to electraft rig open, WSJT-X VOX rig split now works Merge branch 'master' of https://github.com/N0NB/hamlib Added IC-7850/51 -- works with WSJT-X Merge branch 'master' of https://github.com/N0NB/hamlib Add ic7850 ic7851 -- works with wsjtx Add ic7850 ic7851 -- works with wsjtx Merger 7850/51 into 785x Fix ft991_get_mode Added ft891 backend Fix ic785x default addr to 0x8e Fix FT-891 recognition IC-M710 now working with WSJST-X Add icm710.h to icmarine Makefile.am Merge pull request #1 from Hamlib/master Fix FT857 to return the SMeter-based value Reduce debug info in flrig.c Change RIG_MODE and RIG_FUNC to 64-bit values Merge hamlib head Add PRXll macro for 64-bit use Fixup for 64-bit in memcsv.c 64 bit mods to netrigctl.c testrig.c Add TS-890S as derivative of TS-480 plus new modes Add XHCG to ic706.c Change rmode_t to uint64_t and remove unneeded casts Fix RIG_MODE structure in src/msic.c Fix some 64bit items and add RIG_FUNC_NB2 for TS-890S Suppress GCC unused-return warning Fix rig_idx2settings for 64-bit sprintf_list functions Fix flrig when WSJT-X startup causes rig mode change Increase flrig timeout value Add USB mode to flrig Fix flrig memory leak Fix bug where constant value was being trashed Add PKT modes to ts590.c Add BC2 and NB2 functions for newer kenwoods Change RIG_SETTING_MAX for 64-bit compatibility All kenwoods to have 3-char commands for functions and return whatever value the rig returns instead of 0/1 Changes to add more ts890 capabilities, e.g. NB2, BC2 Fix kenwoood BC BC2 returns Fix kenwood BC BC2 return merge master New utility to allow non-hamlib-aware programs to use hamlib rigs via COM ports Virtual com ports providing a TS-2000 Emulator Example connecting N1MM or such to FLRig via COM5/COM6 virtual COM pair rigctlcom -m 4 -R COM5 -S 115200 N1MM connects to COM6 TS-2000 115200 8N1 Add TUNER on/off fnction for Yaesu rigs Fix segfault in rigctlcom with no args and improve usage Add rigctlcom to install scripts Add FT847UNI for early serial number units that are one-way comm Add rigctlcom to gitignore Reduce verbosity in FLRig Ensure buf is zeroed in kenwood_safe_transaction to avoid return random data Reduce verbosity of rig_strrmode and read_string Improve error handling in network_flush when disconnect happens Reduce verbosity of rig_strvfo netrigctl can now do vfo mode -- has automatic detection of rigctld vfo mode rigctl automatically detects vfo mode of rigctld rigctli and rigctld recommend vfo mode if not selected Merge branch 'master' of https://github.com/Hamlib/Hamlib Fix memset in kenwood.c Fix network_flush as it was not actually flushing before This was causing an infinite loop and WSJT-X to lock up u... [truncated message content] |
From: Nate B. <n0...@us...> - 2021-12-02 23:48:37
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, Hamlib-4.4 has been created at 5f8c4cd5c2c0830c8e363762c4255c6e3e4d3e3f (commit) - Log ----------------------------------------------------------------- commit 5f8c4cd5c2c0830c8e363762c4255c6e3e4d3e3f Author: Nate Bargmann <n0...@n0...> Date: Thu Dec 2 17:46:51 2021 -0600 Advance to 4.4 stable diff --git a/configure.ac b/configure.ac index 540c0baf..f3fed5b2 100644 --- a/configure.ac +++ b/configure.ac @@ -14,7 +14,7 @@ dnl Please do not use '-' in the version number, as package managers will fail, 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.4~git],[ham...@li...],[hamlib],[http://www.hamlib.org]) +AC_INIT([Hamlib],[4.4],[ham...@li...],[hamlib],[http://www.hamlib.org]) AC_CONFIG_SRCDIR([include/hamlib/rig.h]) AC_CONFIG_MACRO_DIR([macros]) commit 712a5f3f046f66b2f2cc4a15b12275efe5a3b27a Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 2 17:37:17 2021 -0600 Update NEWS diff --git a/NEWS b/NEWS index 585bb53a..8c34da14 100644 --- a/NEWS +++ b/NEWS @@ -7,7 +7,7 @@ Copyright (C) 2000-2021 Michael Black W9MDB, and others Please send Hamlib bug reports to ham...@li... Version 4.4 - * 2021-12-01 + * 2021-12-02 * Icom rigs now default filter 2 when setting PKTUSB but user can override * Fix FTDX9000 meter readings * Add Android sensor as a rotator commit 1a22f5caf73973208c4c2c3ac6686ed47b17660e Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 2 17:36:54 2021 -0600 Update NEWS diff --git a/NEWS b/NEWS index 6e336a13..585bb53a 100644 --- a/NEWS +++ b/NEWS @@ -16,6 +16,7 @@ Version 4.4 * Added M0NKA mcHF URP rig * Faster serial i/o noticeable on higher baud rates * IC7300/9700/7800/785x set_clock/get_clock routines added -- no auto set yet + * Yaesu FT1200/891/991/DX10/DX101/DX101MP set_clock/get_clock routines added Version 4.3.1 * 2021-09-14 commit a1da584bc13b9b4481e4bde21eed0e708dd2d10e Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 2 16:53:22 2021 -0600 Add HAMLIB_CACHE_ALWAYS to rig_get_mode https://github.com/Hamlib/Hamlib/issues/880 diff --git a/src/rig.c b/src/rig.c index 4bc17aae..b61fc01e 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2492,6 +2492,14 @@ int HAMLIB_API rig_get_mode(RIG *rig, cache_show(rig, __func__, __LINE__); + if (rig->state.cache.timeout_ms == HAMLIB_CACHE_ALWAYS) + { + rig_debug(RIG_DEBUG_TRACE, "%s: cache hit age mode=%dms, width=%dms\n", + __func__, cache_ms_mode, cache_ms_width); + + ELAPSED2; + RETURNFUNC(RIG_OK); + } if ((*mode != RIG_MODE_NONE && cache_ms_mode < rig->state.cache.timeout_ms) && cache_ms_width < rig->state.cache.timeout_ms) { commit b5a4e99a3e9a39c073c5567ce22d80831216b31e Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 2 16:44:39 2021 -0600 Add HAMLIB_CACHE_ALWAYS Enable for rig_get_freq https://github.com/Hamlib/Hamlib/issues/880 diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index ddc05cb3..64a06369 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -2199,6 +2199,8 @@ typedef hamlib_port_t port_t; #define HAMLIB_ELAPSED_SET 1 #define HAMLIB_ELAPSED_INVALIDATE 2 +#define HAMLIB_CACHE_ALWAYS -1 /*< value to set cache timeout to always use cache */ + typedef enum { HAMLIB_CACHE_ALL, // to set all cache timeouts at once HAMLIB_CACHE_VFO, diff --git a/src/rig.c b/src/rig.c index 3a66c15a..4bc17aae 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2177,7 +2177,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) cache_show(rig, __func__, __LINE__); - if (*freq != 0 && cache_ms_freq < rig->state.cache.timeout_ms) + if (*freq != 0 && (cache_ms_freq < rig->state.cache.timeout_ms || rig->state.cache.timeout_ms == HAMLIB_CACHE_ALWAYS)) { rig_debug(RIG_DEBUG_TRACE, "%s: %s cache hit age=%dms, freq=%.0f\n", __func__, rig_strvfo(vfo), cache_ms_freq, *freq); commit cab48cecfae7a21377379fedb12bc76aed0ebfb8 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Dec 2 16:08:08 2021 -0600 Add get/set clock for Yaesu FT1200/891/991/DX10/DX101/DX101MP https://github.com/Hamlib/Hamlib/issues/851 diff --git a/rigs/yaesu/ft1200.c b/rigs/yaesu/ft1200.c index 06e43e36..d6b11cb3 100644 --- a/rigs/yaesu/ft1200.c +++ b/rigs/yaesu/ft1200.c @@ -152,7 +152,7 @@ const struct rig_caps ftdx1200_caps = RIG_MODEL(RIG_MODEL_FTDX1200), .model_name = "FTDX-1200", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".2", + .version = NEWCAT_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -320,4 +320,6 @@ const struct rig_caps ftdx1200_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; diff --git a/rigs/yaesu/ft891.c b/rigs/yaesu/ft891.c index 0c38dfa3..c004cd63 100644 --- a/rigs/yaesu/ft891.c +++ b/rigs/yaesu/ft891.c @@ -135,7 +135,7 @@ const struct rig_caps ft891_caps = RIG_MODEL(RIG_MODEL_FT891), .model_name = "FT-891", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".4", + .version = NEWCAT_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -320,6 +320,8 @@ const struct rig_caps ft891_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; /* diff --git a/rigs/yaesu/ft991.c b/rigs/yaesu/ft991.c index d2b93143..c59f5f40 100644 --- a/rigs/yaesu/ft991.c +++ b/rigs/yaesu/ft991.c @@ -143,7 +143,7 @@ const struct rig_caps ft991_caps = RIG_MODEL(RIG_MODEL_FT991), .model_name = "FT-991", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".7", + .version = NEWCAT_VER ".8", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -329,6 +329,8 @@ const struct rig_caps ft991_caps = .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, .send_voice_mem = newcat_send_voice_mem, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; diff --git a/rigs/yaesu/ftdx10.c b/rigs/yaesu/ftdx10.c index bc3d6542..41738e4c 100644 --- a/rigs/yaesu/ftdx10.c +++ b/rigs/yaesu/ftdx10.c @@ -139,7 +139,7 @@ const struct rig_caps ftdx10_caps = RIG_MODEL(RIG_MODEL_FTDX10), .model_name = "FTDX-10", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".0", + .version = NEWCAT_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -308,4 +308,6 @@ const struct rig_caps ftdx10_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; diff --git a/rigs/yaesu/ftdx101.c b/rigs/yaesu/ftdx101.c index db9fdd7a..00ca222f 100644 --- a/rigs/yaesu/ftdx101.c +++ b/rigs/yaesu/ftdx101.c @@ -139,7 +139,7 @@ const struct rig_caps ftdx101d_caps = RIG_MODEL(RIG_MODEL_FTDX101D), .model_name = "FTDX-101D", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".12", + .version = NEWCAT_VER ".13", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -309,4 +309,6 @@ const struct rig_caps ftdx101d_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; diff --git a/rigs/yaesu/ftdx101mp.c b/rigs/yaesu/ftdx101mp.c index a1157b5a..4fbcebfb 100644 --- a/rigs/yaesu/ftdx101mp.c +++ b/rigs/yaesu/ftdx101mp.c @@ -77,7 +77,7 @@ const struct rig_caps ftdx101mp_caps = RIG_MODEL(RIG_MODEL_FTDX101MP), .model_name = "FTDX-101MP", .mfg_name = "Yaesu", - .version = NEWCAT_VER ".3", + .version = NEWCAT_VER ".4", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -247,4 +247,6 @@ const struct rig_caps ftdx101mp_caps = .set_ext_level = newcat_set_ext_level, .get_ext_level = newcat_get_ext_level, .send_morse = newcat_send_morse, + .set_clock = newcat_set_clock, + .get_clock = newcat_get_clock }; diff --git a/rigs/yaesu/newcat.c b/rigs/yaesu/newcat.c index 35916383..85d6ad2c 100644 --- a/rigs/yaesu/newcat.c +++ b/rigs/yaesu/newcat.c @@ -11026,3 +11026,112 @@ static int newcat_get_contour_width(RIG *rig, vfo_t vfo, int *width) RETURNFUNC(RIG_OK); } + +int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int retval = RIG_OK; + int err; + struct newcat_priv_data *priv = (struct newcat_priv_data *)rig->state.priv; + + if (!newcat_valid_command(rig, "DT")) + { + RETURNFUNC(-RIG_ENAVAIL); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT0%04d%02d%02d%c", year, month, + day, cat_term); + + if (RIG_OK != (err = newcat_set_cmd(rig))) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, + err); + RETURNFUNC(err); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT1%02d%02d%02d%c", hour, min, sec, cat_term); + + if (RIG_OK != (err = newcat_set_cmd(rig))) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, + err); + RETURNFUNC(err); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT2%c%04d%c", utc_offset>=0?'+':'-', utc_offset, cat_term); + + if (RIG_OK != (err = newcat_set_cmd(rig))) + { + rig_debug(RIG_DEBUG_VERBOSE, "%s:%d command err = %d\n", __func__, __LINE__, + err); + RETURNFUNC(err); + } + + RETURNFUNC(retval); +} + +int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset) +{ + int retval = RIG_OK; + int err; + int n; + struct newcat_priv_data *priv = (struct newcat_priv_data *)rig->state.priv; + + if (!newcat_valid_command(rig, "DT")) + { + RETURNFUNC(-RIG_ENAVAIL); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT0%c", cat_term); + + if ((err = newcat_get_cmd(rig)) != RIG_OK) + { + RETURNFUNC(err); + } + + n = sscanf(priv->ret_data, "DT0%04d%02d%02d", year, month, day); + + if (n != 3) + { + rig_debug(RIG_DEBUG_ERR, "%s: DT0 unable to parse '%s'\n", __func__, + priv->ret_data); + RETURNFUNC(-RIG_EPROTO); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT1%c", cat_term); + + if ((err = newcat_get_cmd(rig)) != RIG_OK) + { + RETURNFUNC(err); + } + + n = sscanf(priv->ret_data, "DT1%02d%02d%02d", hour, min, sec); + + if (n != 3) + { + rig_debug(RIG_DEBUG_ERR, "%s: DT1 unable to parse '%s'\n", __func__, + priv->ret_data); + RETURNFUNC(-RIG_EPROTO); + } + + snprintf(priv->cmd_str, sizeof(priv->cmd_str), "DT2%c", cat_term); + + if ((err = newcat_get_cmd(rig)) != RIG_OK) + { + RETURNFUNC(err); + } + + // we keep utc_offset in HHMM format rather than converting + n = sscanf(priv->ret_data, "DT2%d", utc_offset); + + if (n != 1) + { + rig_debug(RIG_DEBUG_ERR, "%s: DT2 unable to parse '%s'\n", __func__, + priv->ret_data); + RETURNFUNC(-RIG_EPROTO); + } + + RETURNFUNC(retval); +} + diff --git a/rigs/yaesu/newcat.h b/rigs/yaesu/newcat.h index 7daac880..89108f4b 100644 --- a/rigs/yaesu/newcat.h +++ b/rigs/yaesu/newcat.h @@ -50,7 +50,7 @@ typedef char ncboolean; /* shared function version */ -#define NEWCAT_VER "20211114" +#define NEWCAT_VER "20211202" /* Hopefully large enough for future use, 128 chars plus '\0' */ #define NEWCAT_DATA_LEN 129 @@ -222,6 +222,11 @@ int newcat_get_ext_level(RIG *rig, vfo_t vfo, token_t token, value_t *val); int newcat_send_morse(RIG *rig, vfo_t vfo, const char *msg); int newcat_send_voice_mem(RIG *rig, vfo_t vfo, int ch); +int newcat_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset); +int newcat_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset); + #define TOKEN_BACKEND(t) (t) commit 9ed36ffe548f0a5e14329851980b59f46aa47fe6 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 23:30:19 2021 -0600 Clean up compilation warning on ic7100.c diff --git a/rigs/icom/ic7100.c b/rigs/icom/ic7100.c index 2071350a..68fdc540 100644 --- a/rigs/icom/ic7100.c +++ b/rigs/icom/ic7100.c @@ -32,6 +32,7 @@ #include "idx_builtin.h" #include "bandplan.h" #include "token.h" +#include "misc.h" #define IC7100_MODES (RIG_MODE_SSB|RIG_MODE_CW|RIG_MODE_CWR|\ commit d38a248fdaa6c65320e736b3bd255dda73b1246b Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 22:52:55 2021 -0600 set/get_clock routines for IC7100/7300/7600/7610/7700/7800/785x/9700 https://github.com/Hamlib/Hamlib/issues/851 diff --git a/NEWS b/NEWS index a272440a..6e336a13 100644 --- a/NEWS +++ b/NEWS @@ -15,7 +15,7 @@ Version 4.4 * Added ability to build hamlib with docker * Added M0NKA mcHF URP rig * Faster serial i/o noticeable on higher baud rates - * IC7300 set_clock/get_clock routines added -- no auto set yet + * IC7300/9700/7800/785x set_clock/get_clock routines added -- no auto set yet Version 4.3.1 * 2021-09-14 diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index 7d3e7dea..3aad329e 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -1149,6 +1149,11 @@ YYYY-MM-DDTHH:MM:SS.SSS+ZZ (where +ZZ is either -/+ UTC offset) YYYY-MM-DDTHH:MM:SS+ZZ YYYY-MM-DDTHH:MM+ZZ YYYY-MM-DD (sets date only) +Note: Icom rigs expect you to set local time and the hours off to UTC. +So...4PM EST example would be 2021-12-01T16:00:00+05 +But...if you want to display GMT you must set the clock for GMT with zero UTC offset. +Hopefully Icom will allow displaying either clock in the future + .EE . .TP diff --git a/rigs/icom/frame.c b/rigs/icom/frame.c index 2317b14f..a43324d7 100644 --- a/rigs/icom/frame.c +++ b/rigs/icom/frame.c @@ -377,7 +377,8 @@ read_another_frame: Unhold_Decode(rig); *data_len = frm_data_len; - if (data != NULL && data_len != NULL) memcpy(data, buf + 4, *data_len); + + if (data != NULL && data_len != NULL) { memcpy(data, buf + 4, *data_len); } /* * TODO: check addresses in reply frame diff --git a/rigs/icom/ic7100.c b/rigs/icom/ic7100.c index 5b484739..2071350a 100644 --- a/rigs/icom/ic7100.c +++ b/rigs/icom/ic7100.c @@ -202,6 +202,106 @@ static const struct icom_priv_caps ic7100_priv_caps = .ant_count = 2 }; +// if hour < 0 then only date will be set +int ic7100_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + unsigned char prmbuf[MAXFRAMELEN]; + + if (year >= 0) + { + prmbuf[0] = 0x01; + prmbuf[1] = 0x20; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + if (hour >= 0) + { + prmbuf[0] = 0x01; + prmbuf[1] = 0x21; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + + prmbuf[0] = 0x01; + prmbuf[1] = 0x23; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + return retval; +} + +int ic7100_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + int resplen; + unsigned char prmbuf[MAXFRAMELEN]; + unsigned char respbuf[MAXFRAMELEN]; + + prmbuf[0] = 0x01; + prmbuf[1] = 0x20; + resplen = sizeof(respbuf); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); + + if (hour != NULL) + { + prmbuf[0] = 0x01; + prmbuf[1] = 0x21; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x01; + prmbuf[1] = 0x23; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); + } + + return retval; +} + const struct rig_caps ic7100_caps = { RIG_MODEL(RIG_MODEL_IC7100), @@ -407,5 +507,7 @@ const struct rig_caps ic7100_caps = .get_powerstat = icom_get_powerstat, .send_morse = icom_send_morse, .stop_morse = icom_stop_morse, - .wait_morse = rig_wait_morse + .wait_morse = rig_wait_morse, + .set_clock = ic7100_set_clock, + .get_clock = ic7100_get_clock }; diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 3436604b..d0d7fc06 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -543,7 +543,7 @@ const struct rig_caps ic7300_caps = RIG_MODEL(RIG_MODEL_IC7300), .model_name = "IC-7300", .mfg_name = "Icom", - .version = BACKEND_VER ".5", + .version = BACKEND_VER ".6", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -772,7 +772,7 @@ const struct rig_caps ic9700_caps = RIG_MODEL(RIG_MODEL_IC9700), .model_name = "IC-9700", .mfg_name = "Icom", - .version = BACKEND_VER ".4", + .version = BACKEND_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -1482,10 +1482,10 @@ int ic7300_set_clock(RIG *rig, int year, int month, int day, int hour, int min, { prmbuf[0] = 0x00; prmbuf[1] = 0x94; - prmbuf[2] = year / 100; - prmbuf[3] = year % 100; - prmbuf[4] = month; - prmbuf[5] = day; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); if (retval != RIG_OK) @@ -1498,8 +1498,8 @@ int ic7300_set_clock(RIG *rig, int year, int month, int day, int hour, int min, { prmbuf[0] = 0x00; prmbuf[1] = 0x95; - prmbuf[2] = hour; - prmbuf[3] = min; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); if (retval != RIG_OK) @@ -1509,9 +1509,10 @@ int ic7300_set_clock(RIG *rig, int year, int month, int day, int hour, int min, prmbuf[0] = 0x00; prmbuf[1] = 0x96; - prmbuf[2] = utc_offset / 100; - prmbuf[3] = utc_offset % 100; - prmbuf[4] = utc_offset >= 0 ? 0 : 1; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); if (retval != RIG_OK) @@ -1537,8 +1538,7 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, prmbuf[1] = 0x94; resplen = sizeof(respbuf); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *year = from_bcd(&respbuf[4], 2)*1000+from_bcd(&respbuf[5],2); + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); *month = from_bcd(&respbuf[6], 2); *day = from_bcd(&respbuf[7], 2); @@ -1547,7 +1547,6 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, prmbuf[0] = 0x00; prmbuf[1] = 0x95; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); *hour = from_bcd(&respbuf[4], 2); *min = from_bcd(&respbuf[5], 2); *sec = 0; @@ -1556,11 +1555,15 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, prmbuf[0] = 0x00; prmbuf[1] = 0x96; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - *utc_offset = from_bcd(&respbuf[4], 2); - rig_debug(RIG_DEBUG_VERBOSE, - "%s: %02d-%02d-%02dT%02d:%02d:%02d:%0.3lf%s%02d\n'", - __func__, *year, *month, *day, *hour, *min, *sec, *msec, - *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); } return retval; @@ -1577,12 +1580,12 @@ int ic9700_set_clock(RIG *rig, int year, int month, int day, int hour, int min, if (year >= 0) { - prmbuf[0] = 0x00; - prmbuf[1] = 0x94; - prmbuf[2] = year / 100; - prmbuf[3] = year % 100; - prmbuf[4] = month; - prmbuf[5] = day; + prmbuf[0] = 0x01; + prmbuf[1] = 0x79; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); if (retval != RIG_OK) @@ -1593,10 +1596,10 @@ int ic9700_set_clock(RIG *rig, int year, int month, int day, int hour, int min, if (hour >= 0) { - prmbuf[0] = 0x00; - prmbuf[1] = 0x95; - prmbuf[2] = hour; - prmbuf[3] = min; + prmbuf[0] = 0x01; + prmbuf[1] = 0x80; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); if (retval != RIG_OK) @@ -1604,11 +1607,12 @@ int ic9700_set_clock(RIG *rig, int year, int month, int day, int hour, int min, rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); } - prmbuf[0] = 0x00; - prmbuf[1] = 0x96; - prmbuf[2] = utc_offset / 100; - prmbuf[3] = utc_offset % 100; - prmbuf[4] = utc_offset >= 0 ? 0 : 1; + prmbuf[0] = 0x01; + prmbuf[1] = 0x84; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); if (retval != RIG_OK) @@ -1634,30 +1638,32 @@ int ic9700_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, prmbuf[1] = 0x79; resplen = sizeof(respbuf); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *year = respbuf[4]; - *month = respbuf[5]; - *day = respbuf[6]; + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); if (hour != NULL) { prmbuf[0] = 0x01; prmbuf[1] = 0x80; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *hour = respbuf[4]; - *min = respbuf[5]; - *sec = respbuf[6]; + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; *msec = 0; - rig_debug(RIG_DEBUG_VERBOSE, "%s: %02d-%02d-%02dT%02d:%02d:%02d:%0.3lf\n'", - __func__, *year, *month, *day, *hour, *min, *sec, *msec); + prmbuf[0] = 0x01; - prmbuf[1] = 0x81; + prmbuf[1] = 0x84; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *utc_offset = respbuf[4]; + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } - if (respbuf[5] > 0) { *utc_offset = *utc_offset * 100 + respbuf[5]; } + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); } return retval; diff --git a/rigs/icom/ic7600.c b/rigs/icom/ic7600.c index 7f997b95..909933dc 100644 --- a/rigs/icom/ic7600.c +++ b/rigs/icom/ic7600.c @@ -23,7 +23,8 @@ #include "config.h" #endif -#include <string.h> /* String function definitions */ +#include <string.h> +#include <stdlib.h> #include <hamlib/rig.h> #include "token.h" @@ -32,6 +33,8 @@ #include "icom.h" #include "icom_defs.h" #include "bandplan.h" +#include "frame.h" +#include "misc.h" #define IC7600_ALL_RX_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_FM|RIG_MODE_PSK|RIG_MODE_PSKR|RIG_MODE_PKTLSB|RIG_MODE_PKTUSB|RIG_MODE_PKTAM|RIG_MODE_PKTFM) #define IC7600_1HZ_TS_MODES IC7600_ALL_RX_MODES @@ -163,12 +166,113 @@ static const struct icom_priv_caps ic7600_priv_caps = .extcmds = ic7600_extcmds, /* Custom op parameters */ }; + +// if hour < 0 then only date will be set +int ic7600_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + unsigned char prmbuf[MAXFRAMELEN]; + + if (year >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x53; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + if (hour >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x54; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + + prmbuf[0] = 0x00; + prmbuf[1] = 0x56; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + return retval; +} + +int ic7600_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + int resplen; + unsigned char prmbuf[MAXFRAMELEN]; + unsigned char respbuf[MAXFRAMELEN]; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x53; + resplen = sizeof(respbuf); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); + + if (hour != NULL) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x54; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x56; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); + } + + return retval; +} + const struct rig_caps ic7600_caps = { RIG_MODEL(RIG_MODEL_IC7600), .model_name = "IC-7600", .mfg_name = "Icom", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -343,5 +447,7 @@ const struct rig_caps ic7600_caps = .get_split_vfo = icom_get_split_vfo, .set_powerstat = icom_set_powerstat, .get_powerstat = icom_get_powerstat, - .send_morse = icom_send_morse + .send_morse = icom_send_morse, + .set_clock = ic7600_set_clock, + .get_clock = ic7600_get_clock }; diff --git a/rigs/icom/ic7610.c b/rigs/icom/ic7610.c index 3cfeb1be..1559e845 100644 --- a/rigs/icom/ic7610.c +++ b/rigs/icom/ic7610.c @@ -24,7 +24,8 @@ #include "config.h" #endif -#include <string.h> /* String function definitions */ +#include <string.h> +#include <stdlib.h> #include <hamlib/rig.h> #include "token.h" @@ -33,6 +34,8 @@ #include "icom.h" #include "icom_defs.h" #include "bandplan.h" +#include "frame.h" +#include "misc.h" #define IC7610_ALL_RX_MODES (RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_FM|RIG_MODE_PSK|RIG_MODE_PSKR|RIG_MODE_PKTLSB|RIG_MODE_PKTUSB|RIG_MODE_PKTAM|RIG_MODE_PKTFM) #define IC7610_1HZ_TS_MODES IC7610_ALL_RX_MODES @@ -243,12 +246,113 @@ static const struct icom_priv_caps ic7610_priv_caps = .extcmds = ic7610_extcmds, }; + +// if hour < 0 then only date will be set +int ic7610_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + unsigned char prmbuf[MAXFRAMELEN]; + + if (year >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x58; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + if (hour >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x59; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + + prmbuf[0] = 0x00; + prmbuf[1] = 0x62; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + return retval; +} + +int ic7610_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + int resplen; + unsigned char prmbuf[MAXFRAMELEN]; + unsigned char respbuf[MAXFRAMELEN]; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x58; + resplen = sizeof(respbuf); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); + + if (hour != NULL) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x59; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x62; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); + } + + return retval; +} + const struct rig_caps ic7610_caps = { RIG_MODEL(RIG_MODEL_IC7610), .model_name = "IC-7610", .mfg_name = "Icom", - .version = BACKEND_VER ".4", + .version = BACKEND_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -478,5 +582,7 @@ const struct rig_caps ic7610_caps = .send_morse = icom_send_morse, .stop_morse = icom_stop_morse, .wait_morse = rig_wait_morse, - .send_voice_mem = rig_send_voice_mem + .send_voice_mem = rig_send_voice_mem, + .set_clock = ic7610_set_clock, + .get_clock = ic7610_get_clock }; diff --git a/rigs/icom/ic7700.c b/rigs/icom/ic7700.c index 9b020452..7e215ca7 100644 --- a/rigs/icom/ic7700.c +++ b/rigs/icom/ic7700.c @@ -23,7 +23,8 @@ #include "config.h" #endif -#include <string.h> /* String function definitions */ +#include <string.h> +#include <stdlib.h> #include <hamlib/rig.h> #include "token.h" @@ -32,6 +33,8 @@ #include "icom.h" #include "icom_defs.h" #include "bandplan.h" +#include "frame.h" +#include "misc.h" #define IC7700_OTHER_TX_MODES (RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_FM|RIG_MODE_PKTLSB|RIG_MODE_PKTUSB|RIG_MODE_PKTFM|RIG_MODE_PSK|RIG_MODE_PSKR) #define IC7700_AM_TX_MODES (RIG_MODE_AM|RIG_MODE_PKTAM) @@ -146,6 +149,106 @@ static const struct icom_priv_caps ic7700_priv_caps = .extcmds = ic7700_extcmds, }; +// if hour < 0 then only date will be set +int ic7700_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + unsigned char prmbuf[MAXFRAMELEN]; + + if (year >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x58; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + if (hour >= 0) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x59; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + + prmbuf[0] = 0x00; + prmbuf[1] = 0x61; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); + + if (retval != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); + } + } + + return retval; +} + +int ic7700_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, + int *min, int *sec, double *msec, int *utc_offset) +{ + int cmd = 0x1a; + int subcmd = 0x05; + int retval = RIG_OK; + int resplen; + unsigned char prmbuf[MAXFRAMELEN]; + unsigned char respbuf[MAXFRAMELEN]; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x58; + resplen = sizeof(respbuf); + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); + + if (hour != NULL) + { + prmbuf[0] = 0x00; + prmbuf[1] = 0x59; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x61; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); + } + + return retval; +} + const struct rig_caps ic7700_caps = { RIG_MODEL(RIG_MODEL_IC7700), @@ -325,5 +428,7 @@ const struct rig_caps ic7700_caps = .get_powerstat = icom_get_powerstat, .send_morse = icom_send_morse, .stop_morse = icom_stop_morse, - .wait_morse = rig_wait_morse + .wait_morse = rig_wait_morse, + .set_clock = ic7700_set_clock, + .get_clock = ic7700_get_clock }; diff --git a/rigs/icom/ic7800.c b/rigs/icom/ic7800.c index 31d8a183..e878aba8 100644 --- a/rigs/icom/ic7800.c +++ b/rigs/icom/ic7800.c @@ -24,6 +24,7 @@ #endif #include <string.h> /* String function definitions */ +#include <stdlib.h> #include <hamlib/rig.h> #include "token.h" @@ -155,7 +156,7 @@ const struct rig_caps ic7800_caps = RIG_MODEL(RIG_MODEL_IC7800), .model_name = "IC-7800", .mfg_name = "Icom", - .version = BACKEND_VER ".4", + .version = BACKEND_VER ".5", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -417,12 +418,12 @@ int ic7800_set_clock(RIG *rig, int year, int month, int day, int hour, int min, if (year >= 0) { - prmbuf[0] = 0x01; - prmbuf[1] = 0x20; - prmbuf[2] = year / 100; - prmbuf[3] = year % 100; - prmbuf[4] = month; - prmbuf[5] = day; + prmbuf[0] = 0x00; + prmbuf[1] = 0x59; + to_bcd(&prmbuf[2], year / 100, 2); + to_bcd(&prmbuf[3], year % 100, 2); + to_bcd(&prmbuf[4], month, 2); + to_bcd(&prmbuf[5], day, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 6, NULL, NULL); if (retval != RIG_OK) @@ -433,10 +434,10 @@ int ic7800_set_clock(RIG *rig, int year, int month, int day, int hour, int min, if (hour >= 0) { - prmbuf[0] = 0x01; - prmbuf[1] = 0x21; - prmbuf[2] = hour; - prmbuf[3] = min; + prmbuf[0] = 0x00; + prmbuf[1] = 0x60; + to_bcd(&prmbuf[2], hour, 2); + to_bcd(&prmbuf[3], min, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 4, NULL, NULL); if (retval != RIG_OK) @@ -444,11 +445,12 @@ int ic7800_set_clock(RIG *rig, int year, int month, int day, int hour, int min, rig_debug(RIG_DEBUG_ERR, "%s(%d): %s\b", __func__, __LINE__, rigerror(retval)); } - prmbuf[0] = 0x01; - prmbuf[1] = 0x23; - prmbuf[2] = utc_offset / 100; - prmbuf[3] = utc_offset % 100; - prmbuf[4] = utc_offset >= 0 ? 0 : 1; + prmbuf[0] = 0x00; + prmbuf[1] = 0x62; + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + to_bcd(&prmbuf[2], abs(utc_offset) / 100, 2); + to_bcd(&prmbuf[3], abs(utc_offset) % 100, 2); + to_bcd(&prmbuf[4], utc_offset >= 0 ? 0 : 1, 2); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 5, NULL, NULL); if (retval != RIG_OK) @@ -460,7 +462,6 @@ int ic7800_set_clock(RIG *rig, int year, int month, int day, int hour, int min, return retval; } - int ic7800_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, int *min, int *sec, double *msec, int *utc_offset) { @@ -472,30 +473,36 @@ int ic7800_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, unsigned char respbuf[MAXFRAMELEN]; prmbuf[0] = 0x00; - prmbuf[1] = 0x94; + prmbuf[1] = 0x59; resplen = sizeof(respbuf); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *year = respbuf[4]; - *month = respbuf[5]; - *day = respbuf[6]; + *year = from_bcd(&respbuf[4], 2) * 100 + from_bcd(&respbuf[5], 2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); - if (hour >= 0) // + if (hour != NULL) { prmbuf[0] = 0x00; - prmbuf[1] = 0x95; + prmbuf[1] = 0x60; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - rig_debug(RIG_DEBUG_VERBOSE, "%s: %02d-%02d-%02dT%02d:%02d:%02d:%0.3lf\n'", - __func__, *year, *month, *day, *hour, *min, *sec, *msec); - prmbuf[0] = 0x01; - prmbuf[1] = 0x81; + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x62; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); - dump_hex(respbuf, resplen); - *utc_offset = respbuf[4]; - if (respbuf[5] > 0) *utc_offset = *utc_offset*100 + respbuf[5]; + *utc_offset = from_bcd(&respbuf[4], 2) * 100; + *utc_offset += from_bcd(&respbuf[5], 2); + + if (respbuf[6] != 0x00) { *utc_offset *= -1; } + + //rig_debug(RIG_DEBUG_VERBOSE, + // "%s: %02d-%02d-%02dT%02d:%02d:%06.3lf%s%04d\n'", + // __func__, *year, *month, *day, *hour, *min, *sec + *msec / 1000, + // *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); } return retval; } - diff --git a/rigs/icom/ic785x.c b/rigs/icom/ic785x.c index 0d0c5304..db2e58c3 100644 --- a/rigs/icom/ic785x.c +++ b/rigs/icom/ic785x.c @@ -243,7 +243,7 @@ const struct rig_caps ic785x_caps = RIG_MODEL(RIG_MODEL_IC785x), .model_name = "IC-7850/7851", .mfg_name = "Icom", - .version = BACKEND_VER ".2", + .version = BACKEND_VER ".3", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, diff --git a/tests/rigctl_parse.c b/tests/rigctl_parse.c index f0393f19..9cd33966 100644 --- a/tests/rigctl_parse.c +++ b/tests/rigctl_parse.c @@ -346,7 +346,8 @@ static struct test_table test_list[] = { 0xf5, "get_rig_info", ACTION(get_rig_info), ARG_NOVFO | ARG_OUT, "RigInfo" }, /* get several vfo parameters at once */ { 0xf4, "get_vfo_list", ACTION(get_vfo_list), ARG_OUT | ARG_NOVFO, "VFOs" }, { 0xf6, "get_modes", ACTION(get_modes), ARG_OUT | ARG_NOVFO, "Modes" }, - { 0xf9, "get_clock", ACTION(get_clock), ARG_IN | ARG_NOVFO, "local/utc" }, +// { 0xf9, "get_clock", ACTION(get_clock), ARG_IN | ARG_NOVFO, "local/utc" }, + { 0xf9, "get_clock", ACTION(get_clock), ARG_NOVFO }, { 0xf8, "set_clock", ACTION(set_clock), ARG_IN | ARG_NOVFO, "YYYYMMDDHHMMSS.sss+ZZ" }, { 0xf1, "halt", ACTION(halt), ARG_NOVFO }, /* rigctld only--halt the daemon */ { 0x8c, "pause", ACTION(pause), ARG_IN, "Seconds" }, @@ -5228,6 +5229,10 @@ declare_proto_rig(set_clock) __func__, n, year, mon, day, hour, min, sec, msec, utc_offset >= 0 ? "+" : "-", (unsigned)abs(utc_offset)); + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + if (utc_offset < 24) utc_offset *= 100; // allow for minutes offset too + rig_debug(RIG_DEBUG_ERR, "%s: utc_offset=%d\n", __func__, utc_offset); + RETURNFUNC(rig_set_clock(rig, year, mon, day, hour, min, sec, msec, utc_offset)); } @@ -5235,20 +5240,21 @@ declare_proto_rig(set_clock) /* '0xf9' */ declare_proto_rig(get_clock) { - char option[64]; - int year, month, day, hour, min, sec, utc_offset; + //char option[64]; + int year, month, day, hour, min, sec, utc_offset, aoffset; int retval; double msec; ENTERFUNC; - CHKSCN1ARG(sscanf(arg1, "%63s", option)); + //CHKSCN1ARG(sscanf(arg1, "%63s", option)); retval = rig_get_clock(rig, &year, &month, &day, &hour, &min, &sec, &msec, &utc_offset); - - fprintf(fout, "%04d-%02d-%02dT%02d:%02d:%02d.%0.3f%s%02d\n", year, month, day, - hour, min, sec, msec, utc_offset >= 0 ? "+" : "-", (unsigned)abs(utc_offset)); + aoffset = abs(utc_offset); + fprintf(fout, "%04d-%02d-%02dT%02d:%02d:%06.3f%s%02d:%02d\n", year, month, day, + hour, min, sec + msec / 1000, utc_offset >= 0 ? "+" : "-", + aoffset/100, aoffset % 100); return retval; } commit 41990372da5c697f8b0fe6a4799866aafdd1b490 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 12:53:10 2021 -0600 Progress on get_clock diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index a0447a39..3436604b 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -1538,9 +1538,9 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, resplen = sizeof(respbuf); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); dump_hex(respbuf, resplen); - *year = from_bcd(&respbuf[4], 4); - *month = from_bcd(&respbuf[5], 2); - *day = from_bcd(&respbuf[6], 2); + *year = from_bcd(&respbuf[4], 2)*1000+from_bcd(&respbuf[5],2); + *month = from_bcd(&respbuf[6], 2); + *day = from_bcd(&respbuf[7], 2); if (hour != NULL) { commit 8e28c68d3e892c94e35ecb19b41fd6be466487f8 Merge: 23d291de 26d1b57d Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 12:46:17 2021 -0600 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit 23d291de3ce0adaecf19432013a286313fbe1e04 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 12:45:07 2021 -0600 Progress on get_clock https://github.com/Hamlib/Hamlib/issues/851 diff --git a/rigs/icom/ic7300.c b/rigs/icom/ic7300.c index 9b3af86a..a0447a39 100644 --- a/rigs/icom/ic7300.c +++ b/rigs/icom/ic7300.c @@ -24,7 +24,8 @@ #include "config.h" #endif -#include <string.h> /* String function definitions */ +#include <string.h> +#include <stdlib.h> #include <hamlib/rig.h> #include "idx_builtin.h" @@ -41,10 +42,10 @@ static int ic7300_set_parm(RIG *rig, setting_t parm, value_t val); static int ic7300_get_parm(RIG *rig, setting_t parm, value_t *val); int ic7300_set_clock(RIG *rig, int year, int month, int day, int hour, - int min, int sec, double msec, int utc_offset); + int min, int sec, double msec, int utc_offset); int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, - int *hour, - int *min, int *sec, double *msec, int *utc_offset); + int *hour, + int *min, int *sec, double *msec, int *utc_offset); #define IC7300_ALL_RX_MODES (RIG_MODE_FM|RIG_MODE_AM|RIG_MODE_CW|RIG_MODE_CWR|RIG_MODE_SSB|RIG_MODE_RTTY|RIG_MODE_RTTYR|RIG_MODE_PKTLSB|RIG_MODE_PKTUSB|RIG_MODE_PKTFM|RIG_MODE_PKTAM) @@ -1537,18 +1538,29 @@ int ic7300_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, resplen = sizeof(respbuf); retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); dump_hex(respbuf, resplen); - *year = respbuf[4]; - *month = respbuf[5]; - *day = respbuf[6]; + *year = from_bcd(&respbuf[4], 4); + *month = from_bcd(&respbuf[5], 2); + *day = from_bcd(&respbuf[6], 2); - if (hour >= 0) // + if (hour != NULL) { prmbuf[0] = 0x00; prmbuf[1] = 0x95; retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); dump_hex(respbuf, resplen); - rig_debug(RIG_DEBUG_VERBOSE, "%s: %02d-%02d-%02dT%02d:%02d:%02d:%0.3lf\n'", - __func__, *year, *month, *day, *hour, *min, *sec, *msec); + *hour = from_bcd(&respbuf[4], 2); + *min = from_bcd(&respbuf[5], 2); + *sec = 0; + *msec = 0; + + prmbuf[0] = 0x00; + prmbuf[1] = 0x96; + retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); + *utc_offset = from_bcd(&respbuf[4], 2); + rig_debug(RIG_DEBUG_VERBOSE, + "%s: %02d-%02d-%02dT%02d:%02d:%02d:%0.3lf%s%02d\n'", + __func__, *year, *month, *day, *hour, *min, *sec, *msec, + *utc_offset >= 0 ? "+" : "-", (unsigned)abs(*utc_offset)); } return retval; @@ -1627,7 +1639,7 @@ int ic9700_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, *month = respbuf[5]; *day = respbuf[6]; - if (hour != NULL) + if (hour != NULL) { prmbuf[0] = 0x01; prmbuf[1] = 0x80; @@ -1644,7 +1656,8 @@ int ic9700_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, retval = icom_transaction(rig, cmd, subcmd, prmbuf, 2, respbuf, &resplen); dump_hex(respbuf, resplen); *utc_offset = respbuf[4]; - if (respbuf[5] > 0) *utc_offset = *utc_offset*100 + respbuf[5]; + + if (respbuf[5] > 0) { *utc_offset = *utc_offset * 100 + respbuf[5]; } } return retval; commit 26d1b57d8f5a37322f0609a610022ae2ecab8423 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 12:30:14 2021 -0600 Add ic7300.h to Makefile.am diff --git a/rigs/icom/Makefile.am b/rigs/icom/Makefile.am index ebb2ecab..56fb9a63 100644 --- a/rigs/icom/Makefile.am +++ b/rigs/icom/Makefile.am @@ -9,7 +9,7 @@ ICOMSRC = ic706.c icr8500.c ic735.c ic775.c ic756.c \ ic707.c ic728.c ic751.c ic761.c \ ic78.c ic7800.c ic785x.c \ ic7000.c ic7100.c ic7200.c ic7300.c ic7600.c ic7610.c ic7700.c \ - icom.c icom.h icom_defs.h frame.c frame.h optoscan.c optoscan.h x108g.c + icom.c icom.h icom_defs.h frame.c frame.h ic7300.h optoscan.c optoscan.h x108g.c noinst_LTLIBRARIES = libhamlib-icom.la libhamlib_icom_la_SOURCES = $(ICOMSRC) commit a1c8493c62d309488e2f41f50850372bc41e6052 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Dec 1 11:50:33 2021 -0600 First cut at clock setting for IC7300/7800/785x/9700 https://github.com/Hamlib/Hamlib/issues/851 diff --git a/NEWS b/NEWS index 595ce892..a272440a 100644 --- a/NEWS +++ b/NEWS @@ -7,13 +7,15 @@ Copyright (C) 2000-2021 Michael Black W9MDB, and others Please send Hamlib bug reports to ham...@li... Version 4.4 - * 2021-??-?? + * 2021-12-01 * Icom rigs now default filter 2 when setting PKTUSB but user can override * Fix FTDX9000 meter readings * Add Android sensor as a rotator * Added rig_get_vfo to some Icom rigs that have XCHG or 0x25 command capability * Added ability to build hamlib with docker * Added M0NKA mcHF URP rig + * Faster serial i/o noticeable on higher baud rates + * IC7300 set_clock/get_clock routines added -- no auto set yet Version 4.3.1 * 2021-09-14 diff --git a/cppcheck.sh b/cppcheck.sh index d71b45ba..8389b07c 100755 --- a/cppcheck.sh +++ b/cppcheck.sh @@ -80,7 +80,7 @@ CHECK="\ if test $# -eq 0 ; then echo "See cppcheck.log when done" echo "This takes a while to run" - cppcheck --inline-suppr \ + strace -f cppcheck --inline-suppr \ -I src \ -I include \ --include=include/config.h \ diff --git a/doc/man1/rigctl.1 b/doc/man1/rigctl.1 index 71f0a822..7d3e7dea 100644 --- a/doc/man1/rigctl.1 +++ b/doc/man1/rigctl.1 @@ -1136,6 +1136,30 @@ option above, will terminate each command string sent to the radio. This character should not be a part of the input string. . .TP +.BR set_clock " \(aq" \fIDateTime\fP \(aq +Set +.RI \(aq DateTime \(aq +.IP +Sets rig clock -- note that some rigs do not handle seconds or milliseconds. +If you try to set sec/msec and rig does not support it you will get a debug warning message. +Format is ISO8601, +.EX +Formats accepted +YYYY-MM-DDTHH:MM:SS.SSS+ZZ (where +ZZ is either -/+ UTC offset) +YYYY-MM-DDTHH:MM:SS+ZZ +YYYY-MM-DDTHH:MM+ZZ +YYYY-MM-DD (sets date only) +.EE +. +.TP +.BR get_clock +Get +.RI \(aq RigTime \(aq +.IP +Gets rig clock -- note that some rigs do not handle seconds or milliseconds. +Format is ISO8601 YYYY-MM-DDTHH:MM:SS.sss+ZZ where +ZZ is either -/+ UTC offset +. +.TP .BR chk_vfo Get .RI \(aq Status \(aq diff --git a/doc/man1/rigctld.1 b/doc/man1/rigctld.1 index 09ba8c02..e5d4fcd9 100644 --- a/doc/man1/rigctld.1 +++ b/doc/man1/rigctld.1 @@ -1077,6 +1077,29 @@ and also need to be provided as output power may vary according to these values. .IP VFO parameter is not used in VFO mode. +.TP +.BR set_clock " \(aq" \fIDateTime\fP \(aq +Set +.RI \(aq DateTime \(aq +.IP +Sets rig clock -- note that some rigs do not handle seconds or milliseconds. +If you try to set that you will get a debug warning message. +Format is ISO8601. +.EX +Formats accepted +YYYY-MM-DDTHH:MM:SS.sss+ZZ (where +ZZ is either -/+ UTC offset) +YYYY-MM-DDTHH:MM:SS+ZZ +YYYY-MM-DDTHH:MM+ZZ +YYYY-MM-DD (sets date only) +.EE +. +.TP +.BR get_clock +Get +.RI \(aq RigTime \(aq +.IP +Gets rig clock -- note that some rigs do not handle seconds or milliseconds. +Format is ISO8601 YYYY-MM-DDTHH:MM:SS.sss+ZZ where +ZZ is either -/+ UTC offset . .TP .B chk_vfo diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index b041a430..ddc05cb3 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -1980,6 +1980,8 @@ struct rig_caps { rmode_t *mode, pbwidth_t *width, split_t *split); + int(*set_clock) (RIG *rig, int year, int month, int day, int hour, int min, int sec, double msec, int utc_offset); + int(*get_clock) (RIG *rig, int *year, int *month, int *day, int *hour, int *min, int *sec, double *msec, int *utc_offset); const char *clone_combo_set; /*!< String describing key combination to enter load cloning mode */ const char *clone_combo_get; /*!< String describing key combination to enter save cloning mode */ @@ -3175,6 +3177,8 @@ extern HAMLIB_EXPORT(int) rig_get_vfo_info(RIG *rig, vfo_t vfo, freq_t *freq, rm extern HAMLIB_EXPORT(int) rig_get_rig_info(RIG *rig, char *response, int max_response_len); extern HAMLIB_EXPORT(int) rig_get_cache(RIG *rig, vfo_t vfo, freq_t *freq, int * cache_ms_freq, rmode_t *mode, int *cache_ms_mode, pbwidth_t *width, int *cache_ms_width); +extern HAMLIB_EXPORT(int) rig_set_clock(RIG *rig, int year, int month, int day, int hour, int min, int sec, double msec, int utc_offset); +extern HAMLIB_EXPORT(int) rig_get_clock(RIG *rig, int *year, int *month, int *day, int *hour, int *min, int *sec, double *msec, int *utc_offset); typedef unsigned long rig_useconds_t; extern HAMLIB_EXPORT(int) hl_usleep(rig_useconds_t msec); diff --git a/rigs/dummy/dummy.c b/rigs/dummy/dummy.c index 9c5c8fae..df01574d 100644 --- a/rigs/dummy/dummy.c +++ b/rigs/dummy/dummy.c @@ -2140,6 +2140,55 @@ static int dummy_mW2power(RIG *rig, float *power, unsigned int mwpower, RETURNFUNC(RIG_OK); } +static int m_year, m_month, m_day, m_hour, m_min, m_sec, m_utc_offset; +static double m_msec; + +int dummy_set_clock(RIG *rig, int year, int month, int day, int hour, int min, + int sec, double msec, int utc_offset) +{ + int retval = RIG_OK; + + rig_debug(RIG_DEBUG_VERBOSE, "%s: %04d-%02d-%02dT%02d:%02d:%02d.%.03f%s%02d\n", + __func__, year, + month, day,... [truncated message content] |
From: Nate B. <n0...@us...> - 2021-10-10 22:38:06
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via d5a1b125cd8dd441adf974e7bc9685d9f7495cf1 (commit) via 7e6f948bf72c974de1cf57ddd9f67fdbb281011c (commit) via 75408098a4af8a9645413bb7873db8db8341e24e (commit) via 2ff6b5ebebac03a6e78b8d859a1169d6f65483e1 (commit) via d90d3eb0d0651706795e1c7965974f819d0f1ed0 (commit) via 4b77fc1eb36995abb4070973a4fac53783e90f40 (commit) via 2319d17389a9853fa8c243a8f25c10312daef99e (commit) via 2103428c37021af312900c18da81439d3961eab6 (commit) via 7f27917dbcbd07ac1fed1c72f0c85d447c82da09 (commit) via fecc7d42aa1b13e083a761fa1d8315224f0a7cf5 (commit) via ca9a45c93e36566a5a44b31664281cbfd2ad4966 (commit) via 486b9ac252c59ceb4b6fbd1264d875c9e80fbe6c (commit) via c85a4b9224c1f815a018a6b8496d209ef4902854 (commit) via 0b966412f4a9f319241c9625771dcfaa838b4158 (commit) via 068544eccbf3aaa6dfc3855bb6b243f5326f60ed (commit) via 0018422d4649e655b6d1c463483ef837214101bc (commit) via eadd1da0097faa40258ac9fb8920e7c56cca1491 (commit) via a5ad107c636cc56e57b52926ce10c5b9b1dfdfa9 (commit) via a2b3a8d67e82dc3b8475fbeecdc46434cc91a357 (commit) via dd1376becf82a05a30ac389051d0a00cbea621cc (commit) via da87903e3c16c0baea0b98faf2ce5a470504bf27 (commit) via 7c42d6ddb049c1ab44756b51064c683f55ee3aab (commit) via 43251254c50f25f399fd25c924c58c354ca0e9ea (commit) via 8399b4b4dc10541fb68d1cd265bfc718df202f5e (commit) via 3a76cb1b40d465e641a7f0d8032c0f7e8638b72b (commit) via f076d135bc4c30aeb709e339e27b6f1dd7d7dafc (commit) via de5cb713f08eeb1a37bab0331fca8dd0373946a0 (commit) via 9c272dd5f773268158a9f4bcaf83929d4761910f (commit) via aae3ec49960d0a3805057971d731ed18051165da (commit) from 7bd407beda8e3c020572cd39ae18a9bd2142ccde (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit d5a1b125cd8dd441adf974e7bc9685d9f7495cf1 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 10 17:17:30 2021 -0500 Fix frame.c diff --git a/rigs/icom/frame.c b/rigs/icom/frame.c index 43c01d2f..1e44f194 100644 --- a/rigs/icom/frame.c +++ b/rigs/icom/frame.c @@ -439,8 +439,8 @@ int icom_transaction(RIG *rig, int cmd, int subcmd, } /* used in read_icom_frame as end of block */ -static const char icom_block_end[3] = { FA, FI, COL}; -#define icom_block_end_length 3 +static const char icom_block_end[2] = { FI, COL}; +#define icom_block_end_length 2 /* * read_icom_frame commit 7e6f948bf72c974de1cf57ddd9f67fdbb281011c Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 10 17:12:07 2021 -0500 Undo frame.c commit -- misunderstood use diff --git a/rigs/icom/frame.c b/rigs/icom/frame.c index bf525d77..43c01d2f 100644 --- a/rigs/icom/frame.c +++ b/rigs/icom/frame.c @@ -439,8 +439,8 @@ int icom_transaction(RIG *rig, int cmd, int subcmd, } /* used in read_icom_frame as end of block */ -static const char icom_block_end[1] = {COL}; -#define icom_block_end_length 1 +static const char icom_block_end[3] = { FA, FI, COL}; +#define icom_block_end_length 3 /* * read_icom_frame commit 75408098a4af8a9645413bb7873db8db8341e24e Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 10 16:27:58 2021 -0500 Change Icom frame.c to only look for 0xfd for end of frame. Was not seeing error frames] https://github.com/Hamlib/Hamlib/issues/818 diff --git a/rigs/icom/frame.c b/rigs/icom/frame.c index 79c67c7c..bf525d77 100644 --- a/rigs/icom/frame.c +++ b/rigs/icom/frame.c @@ -439,8 +439,8 @@ int icom_transaction(RIG *rig, int cmd, int subcmd, } /* used in read_icom_frame as end of block */ -static const char icom_block_end[2] = {FI, COL}; -#define icom_block_end_length 2 +static const char icom_block_end[1] = {COL}; +#define icom_block_end_length 1 /* * read_icom_frame @@ -469,7 +469,7 @@ int read_icom_frame(hamlib_port_t *p, unsigned char rxbuffer[], int i = read_string(p, rx_ptr, MAXFRAMELEN - read, icom_block_end, icom_block_end_length); - if (i < 0) /* die on errors */ + if (i < 0 && i != RIG_BUSBUSY) /* die on errors */ { RETURNFUNC(i); } @@ -483,8 +483,11 @@ int read_icom_frame(hamlib_port_t *p, unsigned char rxbuffer[], } /* OK, we got something. add it in and continue */ - read += i; - rx_ptr += i; + if (i > 0) + { + read += i; + rx_ptr += i; + } } while ((read < rxbuffer_len) && (rxbuffer[read - 1] != FI) && (rxbuffer[read - 1] != COL)); diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index fe150d2a..911ba548 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20211005" +#define BACKEND_VER "20211010" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit 2ff6b5ebebac03a6e78b8d859a1169d6f65483e1 Merge: d90d3eb0 2103428c Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 10 08:34:06 2021 -0500 Merge branch 'master' of https://github.com/Hamlib/Hamlib commit d90d3eb0d0651706795e1c7965974f819d0f1ed0 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 10 08:33:31 2021 -0500 Use EAGAIN error to retry when serial port is unavailable https://github.com/Hamlib/Hamlib/issues/818 diff --git a/src/iofunc.c b/src/iofunc.c index 9e27c429..4114d57e 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -767,7 +767,7 @@ int HAMLIB_API read_string(hamlib_port_t *p, do { rd_count = port_read(p, &rxbuffer[total_count], 1); - if (errno == EBUSY) + if (errno == EAGAIN) { hl_usleep(5*1000); rig_debug(RIG_DEBUG_WARN, "%s: port_read is busy?\n", __func__); commit 4b77fc1eb36995abb4070973a4fac53783e90f40 Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 8 23:58:07 2021 -0500 Allow for EBUSY return during port read and retry 10x5ms for 50ms total before returning an error https://github.com/Hamlib/Hamlib/issues/818 diff --git a/src/iofunc.c b/src/iofunc.c index 9f210924..9e27c429 100644 --- a/src/iofunc.c +++ b/src/iofunc.c @@ -676,6 +676,7 @@ int HAMLIB_API read_string(hamlib_port_t *p, fd_set rfds, efds; struct timeval tv, tv_timeout, start_time, end_time, elapsed_time; int total_count = 0; + int i=0; rig_debug(RIG_DEBUG_TRACE, "%s called, rxmax=%d\n", __func__, (int)rxmax); @@ -763,7 +764,16 @@ int HAMLIB_API read_string(hamlib_port_t *p, * read 1 character from the rig, (check if in stop set) * The file descriptor must have been set up non blocking. */ - rd_count = port_read(p, &rxbuffer[total_count], 1); + do + { + rd_count = port_read(p, &rxbuffer[total_count], 1); + if (errno == EBUSY) + { + hl_usleep(5*1000); + rig_debug(RIG_DEBUG_WARN, "%s: port_read is busy?\n", __func__); + } + + } while( ++i < 10 && errno == EBUSY); // 50ms should be enough /* if we get 0 bytes or an error something is wrong */ if (rd_count <= 0) commit 2319d17389a9853fa8c243a8f25c10312daef99e Author: Mike Black W9MDB <mdb...@ya...> Date: Fri Oct 8 23:55:48 2021 -0500 Fix rigs so that VFOB/A split works as well as VFOA/B https://github.com/Hamlib/Hamlib/issues/745 diff --git a/rigs/kenwood/kenwood.c b/rigs/kenwood/kenwood.c index b4e981f8..5e48aa75 100644 --- a/rigs/kenwood/kenwood.c +++ b/rigs/kenwood/kenwood.c @@ -962,13 +962,6 @@ int kenwood_open(RIG *rig) rig->state.rigport.retry = retry_save; - // Default to 1st VFO and split off -- but only 1 time - if (rig->caps->set_vfo && priv->opened == 0) - { - rig_set_vfo(rig, vfo_fixup(rig, RIG_VFO_A, 0)); - priv->opened = 1; - } - RETURNFUNC(RIG_OK); } diff --git a/rigs/kenwood/kenwood.h b/rigs/kenwood/kenwood.h index 801fdb1b..e3c36b77 100644 --- a/rigs/kenwood/kenwood.h +++ b/rigs/kenwood/kenwood.h @@ -28,7 +28,7 @@ #include "token.h" #include "misc.h" -#define BACKEND_VER "20210911" +#define BACKEND_VER "20211008" #define EOM_KEN ';' #define EOM_TH '\r' diff --git a/src/misc.c b/src/misc.c index 3e79c6f9..d321bbd5 100644 --- a/src/misc.c +++ b/src/misc.c @@ -1768,7 +1768,7 @@ vfo_t HAMLIB_API vfo_fixup(RIG *rig, vfo_t vfo, split_t split) int satmode = rig->state.cache.satmode; - if (split && vfo == RIG_VFO_TX) { vfo = RIG_VFO_B; } + if (split && vfo == RIG_VFO_TX) { vfo = rig->state.tx_vfo; } if (VFO_HAS_MAIN_SUB_ONLY && !split && !satmode && vfo != RIG_VFO_B) { vfo = RIG_VFO_MAIN; } commit 2103428c37021af312900c18da81439d3961eab6 Merge: fecc7d42 7f27917d Author: Michael Black <mdb...@ya...> Date: Wed Oct 6 07:54:26 2021 -0500 Merge pull request #817 from AuroraRAS/androidsensor AndroidSensor codes improvement commit 7f27917dbcbd07ac1fed1c72f0c85d447c82da09 Author: AuroraRAS <ch...@gm...> Date: Wed Oct 6 13:45:33 2021 +0800 AndroidSensor codes improvement append rotctl CLI tool to android.mk file save target az/el to priv pointor, make them accessible more. remove some c++ warnings. bug fixes. codes optimization. Signed-off-by: AuroraRAS <ch...@gm...> diff --git a/rotators/androidsensor/androidsensor.cpp b/rotators/androidsensor/androidsensor.cpp index e53c1257..35049505 100644 --- a/rotators/androidsensor/androidsensor.cpp +++ b/rotators/androidsensor/androidsensor.cpp @@ -39,13 +39,21 @@ /* ************************************************************************* */ -static NdkImu *imu; +struct androidsensor_rot_priv_data +{ + NdkImu *imu; + azimuth_t target_az; + elevation_t target_el; +}; static int androidsensor_rot_set_position(ROT *rot, azimuth_t az, elevation_t el) { rig_debug(RIG_DEBUG_TRACE, "%s called: %f %f\n", __func__, az, el); - // To-Do + struct androidsensor_rot_priv_data *priv = (struct androidsensor_rot_priv_data *)rot->state.priv; + + priv->target_az = az; + priv->target_el = el; return RIG_OK; } @@ -53,31 +61,24 @@ static int androidsensor_rot_get_position(ROT *rot, azimuth_t *az, elevation_t *el) { rig_debug(RIG_DEBUG_TRACE, "%s called: ", __func__); + struct androidsensor_rot_priv_data *priv = (struct androidsensor_rot_priv_data *)rot->state.priv; - imu->update(); + priv->imu->update(); float accData[3], magData[3]; - imu->getAccData(accData); - imu->getMagData(magData); + priv->imu->getAccData(accData); + priv->imu->getMagData(magData); float R[9] = {0}, I[9] = {0}, orientation[3] = {0}; - bool status = imu->getRotationMatrix(R, 9, I, 9, accData, magData); + bool status = priv->imu->getRotationMatrix(R, 9, I, 9, accData, magData); if(status) - imu->getOrientation(R, 9, orientation); + priv->imu->getOrientation(R, 9, orientation); *az = (orientation[0] / M_PI * 180 ); *el = (orientation[1] / M_PI * 180 ) * -1; - rig_debug(RIG_DEBUG_TRACE, "%f %f\n", az, el); - - return RIG_OK; -} + rig_debug(RIG_DEBUG_TRACE, "%f %f\n", *az, *el); -static int -androidsensor_rot_stop(ROT *rot) -{ - rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); - // To-Do return RIG_OK; } @@ -85,7 +86,17 @@ static int androidsensor_rot_init(ROT *rot) { rig_debug(RIG_DEBUG_TRACE, "%s called, make new NdkImu\n", __func__); - imu = new NdkImu(); + rot->state.priv = (struct androidsensor_rot_priv_data *)malloc(sizeof(struct androidsensor_rot_priv_data)); + struct androidsensor_rot_priv_data *priv = (struct androidsensor_rot_priv_data *)rot->state.priv; + + if (!rot->state.priv) + { + return -RIG_ENOMEM; + } + + priv->imu = new NdkImu(); + priv->target_az = 0; + priv->target_el = 0; return RIG_OK; } @@ -93,7 +104,10 @@ static int androidsensor_rot_cleanup(ROT *rot) { rig_debug(RIG_DEBUG_TRACE, "%s called, delete imu\n", __func__); - delete imu; + struct androidsensor_rot_priv_data *priv = (struct androidsensor_rot_priv_data *)rot->state.priv; + + delete priv->imu; + free(rot->state.priv); return RIG_OK; } @@ -104,7 +118,7 @@ const struct rot_caps androidsensor_rot_caps = ROT_MODEL(ROT_MODEL_ANDROIDSENSOR), .model_name = "ACC/MAG", .mfg_name = "Android Sensor", - .version = "20210925.0", + .version = "20211006.0", .copyright = "LGPL", .rot_type = ROT_TYPE_AZEL, .port_type = RIG_PORT_NONE, @@ -116,11 +130,10 @@ const struct rot_caps androidsensor_rot_caps = .priv = NULL, /* priv */ - .set_position = androidsensor_rot_set_position, - .get_position = androidsensor_rot_get_position, - .stop = androidsensor_rot_stop, .rot_init = androidsensor_rot_init, .rot_cleanup = androidsensor_rot_cleanup, + .set_position = androidsensor_rot_set_position, + .get_position = androidsensor_rot_get_position, }; /* ************************************************************************* */ diff --git a/tests/Android.mk b/tests/Android.mk index 785b6d6f..82208f94 100644 --- a/tests/Android.mk +++ b/tests/Android.mk @@ -10,3 +10,14 @@ LOCAL_C_INCLUDES := android include src LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_EXECUTABLE) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := rotctl.c rotctl_parse.c dumpcaps_rot.c ../src/rot_settings.c +LOCAL_MODULE := rotctl + +LOCAL_CFLAGS := -DHAVE_CONFIG_H +LOCAL_C_INCLUDES := android include src +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) + +include $(BUILD_EXECUTABLE) commit fecc7d42aa1b13e083a761fa1d8315224f0a7cf5 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Oct 5 11:40:54 2021 -0500 Hopefully fixed auto_power_on for IC-7610 and IC-9700 But it takes ~4 seconds on IC-7300 to power on 14 seconds to time out when the rig does not respond at all https://github.com/Hamlib/Hamlib/issues/815 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 93b04403..0c67faeb 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -7629,13 +7629,13 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) // sending more than enough 0xfe's to wake up the rs232 write_block(&rs->rigport, (char *) fe_buf, fe_max); - hl_usleep(100 * 1000); // we'll try 0x18 0x01 now -- should work on STBY rigs too pwr_sc = S_PWR_ON; fe_buf[0] = 0; priv->serial_USB_echo_off = 1; retval = icom_transaction(rig, C_SET_PWR, pwr_sc, NULL, 0, ackbuf, &ack_len); + hl_usleep(4000*1000); // give some time to wake up break; @@ -7647,7 +7647,7 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) } i = 0; - retry = 2; + retry = 3; if (status == RIG_POWER_ON) // wait for wakeup only { @@ -7657,7 +7657,10 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) // need to see if echo is on or not first // until such time as rig is awake we don't know retval = icom_get_usb_echo_off(rig); - if (retval == -RIG_ETIMEOUT) continue; + if (retval == -RIG_ETIMEOUT) { + rig_debug(RIG_DEBUG_WARN, "%s: get_usb_echo_off timeout...try#%d\n", __func__, i+1); + continue; + } // Use get_freq as all rigs should repond to this retval = rig_get_freq(rig, RIG_VFO_CURR, &freq); diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index ad352eef..fe150d2a 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20211004" +#define BACKEND_VER "20211005" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit ca9a45c93e36566a5a44b31664281cbfd2ad4966 Author: Mike Black W9MDB <mdb...@ya...> Date: Mon Oct 4 17:34:09 2021 -0500 Reduce icom auto_power_on timeout from 15 seconds to just over 5 seconds https://github.com/Hamlib/Hamlib/issues/815 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index bfc65a8d..93b04403 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -7604,13 +7604,18 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) int fe_max = 175; unsigned char fe_buf[fe_max]; // for FE's to power up int i; - int retry; + int retry, retry_save; struct rig_state *rs = &rig->state; struct icom_priv_data *priv = (struct icom_priv_data *) rs->priv; rig_debug(RIG_DEBUG_VERBOSE, "%s called status=%d\n", __func__, (int) status); + // elimininate retries to speed this up + // especially important when rig is not turned on + retry_save = rs->rigport.retry; + rs->rigport.retry = 0; + switch (status) { case RIG_POWER_ON: @@ -7628,40 +7633,31 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) // we'll try 0x18 0x01 now -- should work on STBY rigs too pwr_sc = S_PWR_ON; fe_buf[0] = 0; - retry = rs->rigport.retry; - rs->rigport.retry = 0; priv->serial_USB_echo_off = 1; retval = icom_transaction(rig, C_SET_PWR, pwr_sc, NULL, 0, ackbuf, &ack_len); - rs->rigport.retry = retry; - // why was this sleep here? We'll try without it - //hl_usleep(3000 * 1000); // give it 3 seconds to wake up break; default: pwr_sc = S_PWR_OFF; fe_buf[0] = 0; - retry = rs->rigport.retry; - rs->rigport.retry = 0; retval = icom_transaction(rig, C_SET_PWR, pwr_sc, NULL, 0, ackbuf, &ack_len); - rs->rigport.retry = retry; } i = 0; - retry = 3; + retry = 2; if (status == RIG_POWER_ON) // wait for wakeup only { - for (i = 0; i < retry; ++i) // up to 10 attempts { freq_t freq; - sleep(1); // need to see if echo is on or not first // until such time as rig is awake we don't know - icom_get_usb_echo_off(rig); + retval = icom_get_usb_echo_off(rig); + if (retval == -RIG_ETIMEOUT) continue; // Use get_freq as all rigs should repond to this retval = rig_get_freq(rig, RIG_VFO_CURR, &freq); @@ -7680,6 +7676,7 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) __func__, i + 1, retry); } } + rs->rigport.retry = retry_save; if (i == retry) { diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 36200b0d..ad352eef 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20211002" +#define BACKEND_VER "20211004" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit 486b9ac252c59ceb4b6fbd1264d875c9e80fbe6c Merge: 0b966412 c85a4b92 Author: Michael Black <mdb...@ya...> Date: Mon Oct 4 08:43:31 2021 -0500 Merge pull request #816 from sq6emm/master Add method to build inside docker commit c85a4b9224c1f815a018a6b8496d209ef4902854 Author: Dawid SQ6EMM <sq...@ha...> Date: Mon Oct 4 15:31:04 2021 +0200 Add method to build inside docker diff --git a/docker-build/Dockerfile b/docker-build/Dockerfile new file mode 100644 index 00000000..0700fbca --- /dev/null +++ b/docker-build/Dockerfile @@ -0,0 +1,21 @@ +# Idea from https://github.com/ok2cqr/cqrlog + +FROM ubuntu:latest + +RUN apt-get update && apt-get -y upgrade + +ENV DEBIAN_FRONTEND="noninteractive" TZ="Europe/London" + +RUN apt-get install -y git build-essential automake libtool + +RUN mkdir -p /usr/local/hamlib-alpha /home/hamlib/build + +# Mount point for the git repository: +VOLUME ["/home/hamlib/build"] + +# Mount point for the result of the build: +VOLUME ["/usr/local/hamlib-alpha"] + +WORKDIR /home/hamlib/build + +ENTRYPOINT rm -rf build && mkdir -p build && cd build && ../bootstrap && ../configure --prefix=/usr/local/hamlib-alpha && make clean && make && make install diff --git a/docker-build/README.docker b/docker-build/README.docker new file mode 100644 index 00000000..ea9ad0f5 --- /dev/null +++ b/docker-build/README.docker @@ -0,0 +1,13 @@ +This is all about building hamlib inside docker contariner - so that you do not need to install dependencied on your local machine. + +1. Build docker container + +(cd docker-build && docker build --no-cache -t this.registry.is.invalid/hamlib-build .) + +2. Build hamlib + +docker run -ti -u root -v $(pwd):/home/hamlib/build -v /usr/local/hamlib-alpha:/usr/local/hamlib-alpha this.registry.is.invalid/hamlib-build + +3. Execute hamlib + +/usr/local/hamlib-alpha/bin/rigctl <your options here> commit 0b966412f4a9f319241c9625771dcfaa838b4158 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Oct 3 08:10:03 2021 -0500 For FT100 add swap to VFOB when in split and PTT on to allow power reading of VFOB Also add 100ms delay after PTT off as Fake It was not resetting rx freq after tx https://github.com/Hamlib/Hamlib/issues/808 diff --git a/rigs/yaesu/ft100.c b/rigs/yaesu/ft100.c index 6e72b2ac..0c698255 100644 --- a/rigs/yaesu/ft100.c +++ b/rigs/yaesu/ft100.c @@ -316,7 +316,7 @@ const struct rig_caps ft100_caps = RIG_MODEL(RIG_MODEL_FT100), .model_name = "FT-100", .mfg_name = "Yaesu", - .version = "20210928.0", + .version = "20210929.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -912,6 +912,7 @@ int ft100_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) { unsigned char cmd_index; + int split = rig->state.cache.split; rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); @@ -919,16 +920,18 @@ int ft100_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt) { case RIG_PTT_ON: cmd_index = FT100_NATIVE_CAT_PTT_ON; + if (split) rig_set_vfo(rig,RIG_VFO_B); break; case RIG_PTT_OFF: cmd_index = FT100_NATIVE_CAT_PTT_OFF; + if (split) rig_set_vfo(rig,RIG_VFO_A); + hl_usleep(100*1000); // give ptt some time to do it's thing -- fake it was not reseting freq after tx break; default: return -RIG_EINVAL; } - return ft100_send_priv_cmd(rig, cmd_index); } commit 068544eccbf3aaa6dfc3855bb6b243f5326f60ed Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Oct 2 23:17:36 2021 -0500 Fix icom_set_mode_with_data to also set filter width https://github.com/Hamlib/Hamlib/issues/811 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index bbf8be2a..bfc65a8d 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2008,7 +2008,7 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode, RETURNFUNC(retval); } - if (tmode == mode && ((width == RIG_PASSBAND_NOCHANGE) || (width == twidth)) + if (tmode == mode && ((width == RIG_PASSBAND_NOCHANGE) || (width == twidth))) { rig_debug(RIG_DEBUG_TRACE, "%s: mode/width not changing\n", __func__); RETURNFUNC(RIG_OK); @@ -2122,6 +2122,7 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode, } } } + icom_set_dsp_flt(rig, mode, width); RETURNFUNC(retval); } commit 0018422d4649e655b6d1c463483ef837214101bc Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Oct 2 22:59:19 2021 -0500 Add another check for icom_set_mode to skip if both mode and width are not changing diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 906adc58..bbf8be2a 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2008,7 +2008,7 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode, RETURNFUNC(retval); } - if (tmode == mode && width == RIG_PASSBAND_NOCHANGE) + if (tmode == mode && ((width == RIG_PASSBAND_NOCHANGE) || (width == twidth)) { rig_debug(RIG_DEBUG_TRACE, "%s: mode/width not changing\n", __func__); RETURNFUNC(RIG_OK); commit eadd1da0097faa40258ac9fb8920e7c56cca1491 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Oct 2 17:33:21 2021 -0500 Fix IC7300 (and other Icoms) set/get_dsp_filter All Icoms will now try the 1A 03 command once and if it is rejected won't try again. https://github.com/Hamlib/Hamlib/issues/811 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index f4bb41ef..906adc58 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -1738,6 +1738,7 @@ int icom_set_xit_new(RIG *rig, vfo_t vfo, shortfreq_t ts) this subcommand */ +int filtericom[] = { 50,100,150,200,250,300,350,400,450,500,600,700,800,900,1000,1100,1200,1300,1400,1500,1600,1700,1800,1900,2000,2100,2200,2300,2400,2500,2600,2700,2800,2900,3000,3100,3200,3300,3400,3500,3600 }; pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) { @@ -1752,9 +1753,6 @@ pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) rig_debug(RIG_DEBUG_VERBOSE, "%s called, mode=%s\n", __func__, rig_strrmode(mode)); - // only these models that we know of -- keep set_dsp_flt in sync - if ((rig->caps->rig_model & (RIG_MODEL_IC7000 | RIG_MODEL_IC7800 | RIG_MODEL_IC7300 || RIG_MODEL_IC9700 || RIG_MODEL_IC7610)) == 0) RETURNFUNC(RIG_OK); - if (rig_has_get_func(rig, RIG_FUNC_RF) && (mode & (RIG_MODE_RTTY | RIG_MODE_RTTYR))) { @@ -1790,14 +1788,14 @@ pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) if (-RIG_ERJCTED == retval) { priv->no_1a_03_cmd = -1; /* do not keep asking */ - return (0); + return (RIG_OK); } if (retval != RIG_OK) { rig_debug(RIG_DEBUG_ERR, "%s: protocol error (%#.2x), " "len=%d\n", __func__, resbuf[0], res_len); - return (0); /* use default */ + return (RIG_OK); /* use default */ } if (res_len == 3 && resbuf[0] == C_CTL_MEM) @@ -1809,18 +1807,22 @@ pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) if (mode & RIG_MODE_AM) { - return ((i + 1) * 200); /* Ic_7800 */ + if (i > 49) { + rig_debug(RIG_DEBUG_ERR, "%s: Expected max 49, got %d for filter\n", __func__, i); + RETURNFUNC(-RIG_EPROTO); + } + return ((i + 1) * 200); /* All Icoms that we know of */ } else if (mode & (RIG_MODE_CW | RIG_MODE_USB | RIG_MODE_LSB | RIG_MODE_RTTY | RIG_MODE_RTTYR | RIG_MODE_PKTUSB | RIG_MODE_PKTLSB)) { - rig_debug(RIG_DEBUG_TRACE, "%s: using width=%d\n", __func__, i); - RETURNFUNC(i < 10 ? (i + 1) * 50 : (i - 4) * 100); + rig_debug(RIG_DEBUG_TRACE, "%s: using filtericom width=%d\n", __func__, i); + RETURNFUNC(filtericom[i]); } } - RETURNFUNC(0); + RETURNFUNC(RIG_OK); } int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) @@ -1830,14 +1832,13 @@ int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) unsigned char flt_ext; value_t rfwidth; int ack_len = sizeof(ackbuf), flt_idx; + struct icom_priv_data *priv = (struct icom_priv_data *) rig->state.priv; unsigned char fw_sub_cmd = RIG_MODEL_IC7200 == rig->caps->rig_model ? 0x02 : S_MEM_FILT_WDTH; ENTERFUNC; - // only these models that we know of -- keep get_dsp in sync here - if ((rig->caps->rig_model & (RIG_MODEL_IC7000 | RIG_MODEL_IC7800 | RIG_MODEL_IC7300 || RIG_MODEL_IC9700 || RIG_MODEL_IC7610)) == 0) RETURNFUNC(RIG_OK); - + if (RIG_PASSBAND_NOCHANGE == width) { RETURNFUNC(RIG_OK); @@ -1869,47 +1870,26 @@ int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) RETURNFUNC(-RIG_EINVAL); } } + if (priv->no_1a_03_cmd) RETURNFUNC(RIG_OK); // don't bother to try since it doesn't work - switch (rig->caps->rig_model) + if (mode & RIG_MODE_AM) { - case RIG_MODEL_IC7000: - case RIG_MODEL_IC7800: - if (mode & RIG_MODE_AM) - { - flt_idx = (width / 200) - 1; /* TBC: IC_7800? */ - } - else if (mode & (RIG_MODE_CW | RIG_MODE_USB | RIG_MODE_LSB | RIG_MODE_RTTY | - RIG_MODE_RTTYR)) - { - if (width == 0) - { - width = 1; - } - - flt_idx = - width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; - } - else - { - RETURNFUNC(RIG_OK); - } - - break; - - case RIG_MODEL_IC7300: - if (mode & RIG_MODE_AM) - { - flt_idx = (width / 200) - 1; /* TBC: IC_7800? */ - } - else + flt_idx = (width / 200) - 1; /* TBC: IC_7800? */ + } + else if (mode & (RIG_MODE_CW | RIG_MODE_USB | RIG_MODE_LSB | RIG_MODE_RTTY | + RIG_MODE_RTTYR)) + { + if (width == 0) { - flt_idx = - width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; + width = 1; } - break; - - default: + flt_idx = + width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; + } + else + { + rig_debug(RIG_DEBUG_VERBOSE, "%s: unknown mode=%s\n", __func__, rig_strrmode(mode)); RETURNFUNC(RIG_OK); } @@ -1918,6 +1898,12 @@ int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) retval = icom_transaction(rig, C_CTL_MEM, fw_sub_cmd, &flt_ext, 1, ackbuf, &ack_len); + if (-RIG_ERJCTED == retval) + { + priv->no_1a_03_cmd = -1; /* do not keep asking */ + return (RIG_OK); + } + if (retval != RIG_OK) { rig_debug(RIG_DEBUG_ERR, "%s: protocol error (%#.2x), " @@ -7663,7 +7649,7 @@ int icom_set_powerstat(RIG *rig, powerstat_t status) } i = 0; - retry = 1; + retry = 3; if (status == RIG_POWER_ON) // wait for wakeup only { diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index f76d01a8..36200b0d 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210929" +#define BACKEND_VER "20211002" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit a5ad107c636cc56e57b52926ce10c5b9b1dfdfa9 Author: Mike Black W9MDB <mdb...@ya...> Date: Thu Sep 30 09:09:51 2021 -0500 Adding NOTES.txt to rig model directories to keep track of rig behaviors This could be turned into a help facility eventually diff --git a/rigs/kenwood/NOTES.txt b/rigs/kenwood/NOTES.txt new file mode 100644 index 00000000..fd796c23 --- /dev/null +++ b/rigs/kenwood/NOTES.txt @@ -0,0 +1 @@ +FT-100 PTT source is determined by mode, rear connector used in data mode commit a2b3a8d67e82dc3b8475fbeecdc46434cc91a357 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Sep 29 05:46:53 2021 -0500 Disable icom_get_vfo as user twiddling VFO knob does not work while polling current_vfo is still determined at startup https://github.com/Hamlib/Hamlib/issues/806 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index ebe2b4ed..f4bb41ef 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -967,10 +967,6 @@ icom_rig_open(RIG *rig) rig_debug(RIG_DEBUG_ERR, "%s: Unable to determine USB echo status\n", __func__); RETURNFUNC(retval); } - - // Determine active vfo again since it would have failed the 1st time - rig->state.current_vfo = icom_current_vfo(rig); - icom_current_vfo(rig); } rig->state.current_vfo = icom_current_vfo(rig); @@ -1736,7 +1732,12 @@ int icom_set_xit_new(RIG *rig, vfo_t vfo, shortfreq_t ts) Has been tested for IC-746pro, Should work on the all dsp rigs ie pro models. The 746 documentation says it has the get_if_filter, but doesn't give any decoding information ? Please test. + + DSP filter setting ($1A$03), but not supported by every rig, + and some models like IC910/Omni VI Plus have a different meaning for + this subcommand */ + pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) { @@ -1751,6 +1752,9 @@ pbwidth_t icom_get_dsp_flt(RIG *rig, rmode_t mode) rig_debug(RIG_DEBUG_VERBOSE, "%s called, mode=%s\n", __func__, rig_strrmode(mode)); + // only these models that we know of -- keep set_dsp_flt in sync + if ((rig->caps->rig_model & (RIG_MODEL_IC7000 | RIG_MODEL_IC7800 | RIG_MODEL_IC7300 || RIG_MODEL_IC9700 || RIG_MODEL_IC7610)) == 0) RETURNFUNC(RIG_OK); + if (rig_has_get_func(rig, RIG_FUNC_RF) && (mode & (RIG_MODE_RTTY | RIG_MODE_RTTYR))) { @@ -1831,6 +1835,9 @@ int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) ENTERFUNC; + // only these models that we know of -- keep get_dsp in sync here + if ((rig->caps->rig_model & (RIG_MODEL_IC7000 | RIG_MODEL_IC7800 | RIG_MODEL_IC7300 || RIG_MODEL_IC9700 || RIG_MODEL_IC7610)) == 0) RETURNFUNC(RIG_OK); + if (RIG_PASSBAND_NOCHANGE == width) { RETURNFUNC(RIG_OK); @@ -2238,14 +2245,7 @@ int icom_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) RETURNFUNC(-RIG_ERJCTED); } - /* DSP filter setting ($1A$03), but not supported by every rig, - * and some models like IC910/Omni VI Plus have a different meaning for - * this subcommand - */ - if (rig->caps->rig_model == RIG_MODEL_IC7000) - { - icom_set_dsp_flt(rig, mode, width); - } + icom_set_dsp_flt(rig, mode, width); RETURNFUNC(RIG_OK); } @@ -2552,6 +2552,9 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) RETURNFUNC(RIG_OK); } +#if 0 +// this seems to work but not for cqrlog and user twiddling VFO knob. +// may be able to use twiddle but will disable for now /* * icom_get_vfo * Assumes rig!=NULL, rig->state.priv!=NULL @@ -2564,6 +2567,7 @@ int icom_get_vfo(RIG *rig, vfo_t *vfo) RETURNFUNC(RIG_OK); } +#endif /* * icom_set_vfo diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 3650b601..f76d01a8 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210928" +#define BACKEND_VER "20210929" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) @@ -308,7 +308,11 @@ int icom_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width); int icom_get_mode_with_data(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width); int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width); +#if 0 // see icom_get_vfo in icom.c int icom_get_vfo(RIG *rig, vfo_t *vfo); +#else +#define icom_get_vfo NULL +#endif int icom_set_vfo(RIG *rig, vfo_t vfo); int icom_set_rptr_shift(RIG *rig, vfo_t vfo, rptr_shift_t rptr_shift); int icom_get_rptr_shift(RIG *rig, vfo_t vfo, rptr_shift_t *rptr_shift); commit dd1376becf82a05a30ac389051d0a00cbea621cc Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 23:13:37 2021 -0500 Fix debug statement https://github.com/Hamlib/Hamlib/issues/812 diff --git a/src/rig.c b/src/rig.c index faada6ef..c59c5265 100644 --- a/src/rig.c +++ b/src/rig.c @@ -1866,8 +1866,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) RIG_OK); // would be better as error but other software won't handle errors } - rig_debug(RIG_DEBUG_TRACE, "%s: TARGETABLE_FREQ vfo=%s\n", __func__, - rig_strvfo(vfo)); + rig_debug(RIG_DEBUG_TRACE, "%s: TARGETABLE_FREQ vfo=%s\n", __func__, rig_strvfo(vfo)); int retry = 3; freq_t tfreq = 0; @@ -1916,8 +1915,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) } else { - rig_debug(RIG_DEBUG_TRACE, "%s: not a TARGETABLE_FREQ vfo=%s\n", __func__, - rig_strvfo(vfo)); + rig_debug(RIG_DEBUG_TRACE, "%s: not a TARGETABLE_FREQ vfo=%s\n", __func__, rig_strvfo(vfo)); if (!caps->set_vfo) { @@ -1929,7 +1927,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) if (retcode != RIG_OK) { rig_debug(RIG_DEBUG_ERR, "%s: set_vfo failed: %s\n", __func__, - rig_strerror(retcode)); + rigerror(retcode)); } commit da87903e3c16c0baea0b98faf2ce5a470504bf27 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 23:03:56 2021 -0500 Fix set_vfo for non TARGETABLE_FREQ rigs like the FT100 Was not setting VFOB when requested https://github.com/Hamlib/Hamlib/issues/812 diff --git a/src/rig.c b/src/rig.c index 150da075..faada6ef 100644 --- a/src/rig.c +++ b/src/rig.c @@ -1924,6 +1924,15 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) RETURNFUNC(-RIG_ENAVAIL); } + retcode = rig_set_vfo(rig, vfo); + + if (retcode != RIG_OK) + { + rig_debug(RIG_DEBUG_ERR, "%s: set_vfo failed: %s\n", __func__, + rig_strerror(retcode)); + } + + if (twiddling(rig)) { rig_debug(RIG_DEBUG_TRACE, "%s: Ignoring set_freq due to VFO twiddling\n", commit 7c42d6ddb049c1ab44756b51064c683f55ee3aab Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 23:03:06 2021 -0500 Fix LOCK macros diff --git a/src/rig.c b/src/rig.c index be2cd872..150da075 100644 --- a/src/rig.c +++ b/src/rig.c @@ -6800,13 +6800,13 @@ const char *HAMLIB_API rig_copyright() #ifdef PTHREAD #define MUTEX_LOCK(var) pthread_mutex_lock(var) #else -#define MUTEX_LOCK1(var) +#define MUTEX_LOCK(var) #endif #ifdef PTHREAD #define MUTEX_UNLOCK(var) pthread_mutex_unlock(var) #else -#define MUTEX_UNLOCK2(var) +#define MUTEX_UNLOCK(var) #endif /** commit 43251254c50f25f399fd25c924c58c354ca0e9ea Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 22:57:35 2021 -0500 New mutex macros to be resued across all rig functions to support async multicast actions diff --git a/src/rig.c b/src/rig.c index 8fb69daa..be2cd872 100644 --- a/src/rig.c +++ b/src/rig.c @@ -160,6 +160,8 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */ #define ELAPSED1 clock_t __begin = clock() #define ELAPSED2 rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, ((double)clock() - __begin) / CLOCKS_PER_SEC * 1000) +#define LOCK \ + /* * Data structure to track the opened rig (by rig_open) */ @@ -2266,6 +2268,7 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) { RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; // do not mess with mode while PTT is on @@ -6788,6 +6791,24 @@ const char *HAMLIB_API rig_copyright() return hamlib_copyright2; } +#ifdef PTHREAD +#define MUTEX(var) static pthread_mutex_t var = PTHREAD_MUTEX_INITIALIZER +#else +#define MUTEX(var) +#endif + +#ifdef PTHREAD +#define MUTEX_LOCK(var) pthread_mutex_lock(var) +#else +#define MUTEX_LOCK1(var) +#endif + +#ifdef PTHREAD +#define MUTEX_UNLOCK(var) pthread_mutex_unlock(var) +#else +#define MUTEX_UNLOCK2(var) +#endif + /** * \brief get a cookie to grab rig control * \param rig Not used @@ -6823,9 +6844,7 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, static double time_last_used; struct timespec tp; int ret; -#ifdef HAVE_PTHREAD - static pthread_mutex_t cookie_lock = PTHREAD_MUTEX_INITIALIZER; -#endif + MUTEX(mutex_rig_cookie); /* This is not needed for RIG_COOKIE_RELEASE but keep it simple. */ if (cookie_len < HAMLIB_COOKIE_SIZE) @@ -6844,9 +6863,7 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, /* Accesing cookie_save and time_last_used must be done with lock held. * So keep code simple and lock it during the whole operation. */ -#ifdef HAVE_PTHREAD - pthread_mutex_lock(&cookie_lock); -#endif + MUTEX_LOCK(mutex_rig_cookie); switch (cookie_cmd) { @@ -6937,11 +6954,8 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, break; } -#ifdef HAVE_PTHREAD - pthread_mutex_unlock(&cookie_lock); -#endif + MUTEX_UNLOCK(mutex_rig_cookie); return ret; - } HAMLIB_EXPORT(void) sync_callback(int lock) commit 8399b4b4dc10541fb68d1cd265bfc718df202f5e Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 14:06:50 2021 -0500 For Icom get_vfo make the same change as last commit for other Icom rigs https://github.com/Hamlib/Hamlib/issues/806 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index ad257452..ebe2b4ed 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -876,6 +876,15 @@ static vfo_t icom_current_vfo(RIG *rig) if (fCurr == f2) { + if (priv->vfo_flag != 0) + { + // we can't change freqs unless rig is idle and we don't know that + // so we only check vfo once when freqs are equal + rig_debug(RIG_DEBUG_TRACE,"%s: vfo already determined...returning current_vfo", __func__); + return rig->state.current_vfo; + } + priv->vfo_flag = 1; + fOffset = 100; rig_set_freq(rig, RIG_VFO_CURR, fCurr + fOffset); } commit 3a76cb1b40d465e641a7f0d8032c0f7e8638b72b Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 12:01:50 2021 -0500 For Icom get_vfo when freqs are equal will only check vfo 1 time This means get_vfo will not follow rig button pushes when freqs are equal https://github.com/Hamlib/Hamlib/issues/806 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index f1c88fb7..ad257452 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -775,12 +775,23 @@ static vfo_t icom_current_vfo_x25(RIG *rig) freq_t fCurr, f2, f3; vfo_t currVFO = RIG_VFO_NONE; vfo_t chkVFO = RIG_VFO_A; + struct rig_state *rs = &rig->state; + struct icom_priv_data *priv = (struct icom_priv_data *) rs->priv; rig_get_freq(rig, RIG_VFO_CURR, &fCurr); rig_get_freq(rig, RIG_VFO_OTHER, &f2); if (fCurr == f2) { + if (priv->vfo_flag != 0) + { + // we can't change freqs unless rig is idle and we don't know that + // so we only check vfo once when freqs are equal + rig_debug(RIG_DEBUG_TRACE,"%s: vfo already determined...returning current_vfo", __func__); + return rig->state.current_vfo; + } + priv->vfo_flag = 1; + fOffset = 100; rig_set_freq(rig, RIG_VFO_CURR, fCurr + fOffset); } @@ -822,10 +833,7 @@ static vfo_t icom_current_vfo(RIG *rig) if (priv->x25cmdfails == 0) // these newer rigs get special treatment { - if (access("w9mdb.txt", F_OK) != -1) - { - return icom_current_vfo_x25(rig); - } + return icom_current_vfo_x25(rig); } else if (rig->state.cache.ptt) // don't do this if transmitting -- XCHG would mess it up { @@ -1846,23 +1854,46 @@ int icom_set_dsp_flt(RIG *rig, rmode_t mode, pbwidth_t width) } } - if (mode & RIG_MODE_AM) - { - flt_idx = (width / 200) - 1; /* TBC: Ic_7800? */ - } - else if (mode & (RIG_MODE_CW | RIG_MODE_USB | RIG_MODE_LSB | RIG_MODE_RTTY | - RIG_MODE_RTTYR)) + switch (rig->caps->rig_model) { - if (width == 0) + case RIG_MODEL_IC7000: + case RIG_MODEL_IC7800: + if (mode & RIG_MODE_AM) { - width = 1; + flt_idx = (width / 200) - 1; /* TBC: IC_7800? */ } + else if (mode & (RIG_MODE_CW | RIG_MODE_USB | RIG_MODE_LSB | RIG_MODE_RTTY | + RIG_MODE_RTTYR)) + { + if (width == 0) + { + width = 1; + } - flt_idx = - width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; - } - else - { + flt_idx = + width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; + } + else + { + RETURNFUNC(RIG_OK); + } + + break; + + case RIG_MODEL_IC7300: + if (mode & RIG_MODE_AM) + { + flt_idx = (width / 200) - 1; /* TBC: IC_7800? */ + } + else + { + flt_idx = + width <= 500 ? ((width + 49) / 50) - 1 : ((width + 99) / 100) + 4; + } + + break; + + default: RETURNFUNC(RIG_OK); } diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 743b4148..3650b601 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210926" +#define BACKEND_VER "20210928" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) @@ -266,6 +266,7 @@ struct icom_priv_data int spectrum_scope_count; /*!< Number of spectrum scopes, calculated from caps */ struct icom_spectrum_scope_cache spectrum_scope_cache[HAMLIB_MAX_SPECTRUM_SCOPES]; /*!< Cached Icom spectrum scope data used during reception of the data. The array index must match the scope ID. */ freq_t other_freq; /*!< Our other freq depending on which vfo is selected */ + int vfo_flag; // used to skip vfo check when frequencies are equal }; extern const struct ts_sc_list r8500_ts_sc_list[]; commit f076d135bc4c30aeb709e339e27b6f1dd7d7dafc Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 28 07:07:54 2021 -0500 Fix FT100 reading of power when in split mode https://github.com/Hamlib/Hamlib/issues/808 diff --git a/rigs/yaesu/ft100.c b/rigs/yaesu/ft100.c index bc49462b..6e72b2ac 100644 --- a/rigs/yaesu/ft100.c +++ b/rigs/yaesu/ft100.c @@ -316,7 +316,7 @@ const struct rig_caps ft100_caps = RIG_MODEL(RIG_MODEL_FT100), .model_name = "FT-100", .mfg_name = "Yaesu", - .version = "20210110.0", + .version = "20210928.0", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -955,15 +955,13 @@ int ft100_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt) /* * Rem: The FT-100(D) has no set_level ability */ - -/* - * blind implementation of get_level. - * Please test on real hardware and send report on hamlib mailing list - */ int ft100_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) { int ret; + int split = rig->state.cache.split; + int ptt = rig->state.cache.ptt; + FT100_METER_INFO ft100_meter; if (!rig) { return -RIG_EINVAL; } @@ -972,7 +970,10 @@ int ft100_get_level(RIG *rig, vfo_t vfo, setting_t level, value_t *val) rig_debug(RIG_DEBUG_VERBOSE, "%s: %s\n", __func__, rig_strlevel(level)); + // if in split have to switch to VFOB to read power and back to VFOA + if (split && ptt) rig_set_vfo(rig, RIG_VFO_B); ret = ft100_send_priv_cmd(rig, FT100_NATIVE_CAT_READ_METERS); + if (split && ptt) rig_set_vfo(rig, RIG_VFO_A); if (ret != RIG_OK) { commit de5cb713f08eeb1a37bab0331fca8dd0373946a0 Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Sep 26 23:45:26 2021 -0500 Align some more code diff --git a/rigs/icom/icom_defs.h b/rigs/icom/icom_defs.h index 8314478d..c066b810 100644 --- a/rigs/icom/icom_defs.h +++ b/rigs/icom/icom_defs.h @@ -373,23 +373,23 @@ /* * RIT/XIT control (C_CTL_RIT) subcommands */ -#define S_RIT_FREQ 0x00 -#define S_RIT 0x01 /* RIT 0 = OFF, 1 = ON */ -#define S_XIT 0x02 /* XIT (delta TX) 0 = OFF, 1 = ON */ +#define S_RIT_FREQ 0x00 +#define S_RIT 0x01 /* RIT 0 = OFF, 1 = ON */ +#define S_XIT 0x02 /* XIT (delta TX) 0 = OFF, 1 = ON */ /* * Misc contents (C_CTL_MEM) subcommands applies to newer rigs. * * Beware the IC-7200 which is non-standard. */ -#define S_MEM_CNTNT 0x00 /* Memory content 2 bigendian */ -#define S_MEM_BAND_REG 0x01 /* band stacking register */ -#define S_MEM_FILT_WDTH 0x03 /* current passband filter width */ -#define S_MEM_PARM 0x05 /* rig parameters; extended parm # + param value: should be coded */ - /* in the rig files because they are different for each rig */ -#define S_MEM_DATA_MODE 0x06 /* data mode */ -#define S_MEM_TX_PB 0x07 /* SSB tx passband */ -#define S_MEM_FLTR_SHAPE 0x08 /* DSP filter shape 0=sharp 1=soft */ +#define S_MEM_CNTNT 0x00 /* Memory content 2 bigendian */ +#define S_MEM_BAND_REG 0x01 /* band stacking register */ +#define S_MEM_FILT_WDTH 0x03 /* current passband filter width */ +#define S_MEM_PARM 0x05 /* rig parameters; extended parm # + param value: should be coded */ + /* in the rig files because they are different for each rig */ +#define S_MEM_DATA_MODE 0x06 /* data mode */ +#define S_MEM_TX_PB 0x07 /* SSB tx passband */ +#define S_MEM_FLTR_SHAPE 0x08 /* DSP filter shape 0=sharp 1=soft */ /* Icr75c */ #define S_MEM_CNTNT_SLCT 0x01 @@ -431,18 +431,18 @@ /* * Tone control (C_SET_TONE) subcommands */ -#define S_TONE_RPTR 0x00 /* Tone frequency setting for repeater receive */ -#define S_TONE_SQL 0x01 /* Tone frequency setting for squelch */ -#define S_TONE_DTCS 0x02 /* DTCS code and polarity for squelch */ -#define S_TONE_P25NAC 0x03 /* P25 NAC */ -#define S_TONE_DSCSQL 0x07 /* D-STAR CSQL */ -#define S_TONE_DPCOM 0x08 /* dPMR COM ID */ -#define S_TONE_DPCC 0x09 /* dPMR CC */ -#define S_TONE_NXRAN 0x0A /* NXDN RAN */ -#define S_TONE_DCUC 0x0B /* DCR UC */ -#define S_TONE_DPSCK 0x0C /* dPMR scrambler key */ -#define S_TONE_NXENK 0x0D /* NXDN encryption key */ -#define S_TONE_DCENK 0x0E /* DCR encryption key */ +#define S_TONE_RPTR 0x00 /* Tone frequency setting for repeater receive */ +#define S_TONE_SQL 0x01 /* Tone frequency setting for squelch */ +#define S_TONE_DTCS 0x02 /* DTCS code and polarity for squelch */ +#define S_TONE_P25NAC 0x03 /* P25 NAC */ +#define S_TONE_DSCSQL 0x07 /* D-STAR CSQL */ +#define S_TONE_DPCOM 0x08 /* dPMR COM ID */ +#define S_TONE_DPCC 0x09 /* dPMR CC */ +#define S_TONE_NXRAN 0x0A /* NXDN RAN */ +#define S_TONE_DCUC 0x0B /* DCR UC */ +#define S_TONE_DPSCK 0x0C /* dPMR scrambler key */ +#define S_TONE_NXENK 0x0D /* NXDN encryption key */ +#define S_TONE_DCENK 0x0E /* DCR encryption key */ /* * Transceiver ID (C_RD_TRXID) subcommands commit 9c272dd5f773268158a9f4bcaf83929d4761910f Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Sep 26 23:39:37 2021 -0500 Align some code diff --git a/rigs/icom/icom_defs.h b/rigs/icom/icom_defs.h index c6abfdd8..8314478d 100644 --- a/rigs/icom/icom_defs.h +++ b/rigs/icom/icom_defs.h @@ -305,49 +305,49 @@ /* * Function settings (C_CTL_FUNC) subcommands Set and Read */ -#define S_FUNC_PAMP 0x02 /* Preamp setting */ -#define S_FUNC_AGCOFF 0x10 /* IC-R8500 only */ -#define S_FUNC_AGCON 0x11 /* IC-R8500 only */ -#define S_FUNC_AGC 0x12 /* AGC setting presets: the dsp models allow these to be modified */ -#define S_FUNC_NBOFF 0x20 /* IC-R8500 only */ -#define S_FUNC_NBON 0x21 /* IC-R8500 only */ -#define S_FUNC_NB 0x22 /* NB setting */ -#define S_FUNC_APFOFF 0x30 /* IC-R8500 only */ -#define S_FUNC_APFON 0x31 /* IC-R8500 only */ -#define S_FUNC_APF 0x32 /* APF setting */ -#define S_FUNC_NR 0x40 /* NR setting */ -#define S_FUNC_ANF 0x41 /* ANF setting */ -#define S_FUNC_TONE 0x42 /* TONE setting */ -#define S_FUNC_TSQL 0x43 /* TSQL setting */ -#define S_FUNC_COMP 0x44 /* COMP setting */ -#define S_FUNC_MON 0x45 /* Monitor setting */ -#define S_FUNC_VOX 0x46 /* VOX setting */ -#define S_FUNC_BKIN 0x47 /* BK-IN setting */ -#define S_FUNC_MN 0x48 /* Manual notch setting */ -#define S_FUNC_RF 0x49 /* RTTY Filter setting */ -#define S_FUNC_AFC 0x4A /* Auto Frequency Control (AFC) setting */ -#define S_FUNC_CSQL 0x4B /* DTCS tone code squelch setting*/ -#define S_FUNC_VSC 0x4C /* voice squelch control useful for scanning*/ -#define S_FUNC_MANAGC 0x4D /* manual AGC */ -#define S_FUNC_DIGISEL 0x4E /* DIGI-SEL */ -#define S_FUNC_TW_PK 0x4F /* RTTY Twin Peak filter 0= off 1 = on */ -#define S_FUNC_DIAL_LK 0x50 /* Dial lock */ -#define S_FUNC_P25SQL 0x52 /* P25 DSQL */ -#define S_FUNC_ANTRX 0x53 /* ANT-RX */ -#define S_FUNC_IF1F 0x55 /* 1st IF filter */ -#define S_FUNC_DSPF 0x56 /* DSP filter */ -#define S_FUNC_MANN 0x57 /* Manual notch width */ -#define S_FUNC_SSBT 0x58 /* SSB Tx bandwidth */ -#define S_FUNC_SUBB 0x59 /* Sub band */ -#define S_FUNC_SATM 0x5A /* Satellite mode */ -#define S_FUNC_DSSQL 0x5B /* D-STAR DSQL */ -#define S_FUNC_DPSQL 0x5F /* dPMR DSQL */ -#define S_FUNC_NXSQL 0x60 /* NXDN DSQL */ -#define S_FUNC_DCSQL 0x61 /* DCR DSQL */ -#define S_FUNC_DPSCM 0x62 /* dPMR scrambler */ -#define S_FUNC_NXENC 0x63 /* NXDN encryption */ -#define S_FUNC_DCENC 0x64 /* DCR encryption */ -#define S_FUNC_IPP 0x65 /* IP+ setting */ +#define S_FUNC_PAMP 0x02 /* Preamp setting */ +#define S_FUNC_AGCOFF 0x10 /* IC-R8500 only */ +#define S_FUNC_AGCON 0x11 /* IC-R8500 only */ +#define S_FUNC_AGC 0x12 /* AGC setting presets: the dsp models allow these to be modified */ +#define S_FUNC_NBOFF 0x20 /* IC-R8500 only */ +#define S_FUNC_NBON 0x21 /* IC-R8500 only */ +#define S_FUNC_NB 0x22 /* NB setting */ +#define S_FUNC_APFOFF 0x30 /* IC-R8500 only */ +#define S_FUNC_APFON 0x31 /* IC-R8500 only */ +#define S_FUNC_APF 0x32 /* APF setting */ +#define S_FUNC_NR 0x40 /* NR setting */ +#define S_FUNC_ANF 0x41 /* ANF setting */ +#define S_FUNC_TONE 0x42 /* TONE setting */ +#define S_FUNC_TSQL 0x43 /* TSQL setting */ +#define S_FUNC_COMP 0x44 /* COMP setting */ +#define S_FUNC_MON 0x45 /* Monitor setting */ +#define S_FUNC_VOX 0x46 /* VOX setting */ +#define S_FUNC_BKIN 0x47 /* BK-IN setting */ +#define S_FUNC_MN 0x48 /* Manual notch setting */ +#define S_FUNC_RF 0x49 /* RTTY Filter setting */ +#define S_FUNC_AFC 0x4A /* Auto Frequency Control (AFC) setting */ +#define S_FUNC_CSQL 0x4B /* DTCS tone code squelch setting*/ +#define S_FUNC_VSC 0x4C /* voice squelch control useful for scanning*/ +#define S_FUNC_MANAGC 0x4D /* manual AGC */ +#define S_FUNC_DIGISEL 0x4E /* DIGI-SEL */ +#define S_FUNC_TW_PK 0x4F /* RTTY Twin Peak filter 0= off 1 = on */ +#define S_FUNC_DIAL_LK 0x50 /* Dial lock */ +#define S_FUNC_P25SQL 0x52 /* P25 DSQL */ +#define S_FUNC_ANTRX 0x53 /* ANT-RX */ +#define S_FUNC_IF1F 0x55 /* 1st IF filter */ +#define S_FUNC_DSPF 0x56 /* DSP filter */ +#define S_FUNC_MANN 0x57 /* Manual notch width */ +#define S_FUNC_SSBT 0x58 /* SSB Tx bandwidth */ +#define S_FUNC_SUBB 0x59 /* Sub band */ +#define S_FUNC_SATM 0x5A /* Satellite mode */ +#define S_FUNC_DSSQL 0x5B /* D-STAR DSQL */ +#define S_FUNC_DPSQL 0x5F /* dPMR DSQL */ +#define S_FUNC_NXSQL 0x60 /* NXDN DSQL */ +#define S_FUNC_DCSQL 0x61 /* DCR DSQL */ +#define S_FUNC_DPSCM 0x62 /* dPMR scrambler */ +#define S_FUNC_NXENC 0x63 /* NXDN encryption */ +#define S_FUNC_DCENC 0x64 /* DCR encryption */ +#define S_FUNC_IPP 0x65 /* IP+ setting */ /* * Set Power On/Off (C_SET_PWR) subcommands commit aae3ec49960d0a3805057971d731ed18051165da Author: Mike Black W9MDB <mdb...@ya...> Date: Sun Sep 26 17:03:47 2021 -0500 Allow IC-7300 and many other Icom rigs to find current vfo on startup Icom rigs that do not have 0x25 or XCHG cannot do this yet which are older Icom rigs XCHG rigs cannot get_vfo while transmitting but 0x25 rigs can https://github.com/Hamlib/Hamlib/issues/806 diff --git a/NEWS b/NEWS index 8d172c9d..05fb10f7 100644 --- a/NEWS +++ b/NEWS @@ -10,6 +10,8 @@ Version 4.4 * 2021-??-?? * Icom rigs now default filter 2 when setting PKTUSB but user can override * Fix FTDX9000 meter readings + * Add Android sensor as a rotator + * Added rig_get_vfo to some Icom rigs that have XCHG or 0x25 command capability Version 4.3.1 * 2021-09-14 diff --git a/rigs/icom/ic7000.c b/rigs/icom/ic7000.c index 25b8cbfa..edf9255b 100644 --- a/rigs/icom/ic7000.c +++ b/rigs/icom/ic7000.c @@ -197,7 +197,7 @@ const struct rig_caps ic7000_caps = RIG_MODEL(RIG_MODEL_IC7000), .model_name = "IC-7000", .mfg_name = "Icom", - .version = BACKEND_VER ".1", + .version = BACKEND_VER ".2", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_TRANSCEIVER, @@ -336,6 +336,7 @@ const struct rig_caps ic7000_caps = .get_freq = icom_get_freq, .set_mode = icom_set_mode, .get_mode = icom_get_mode, + .get_vfo = icom_get_vfo, .set_vfo = icom_set_vfo, .set_ant = NULL, /*automatically set by rig depending band */ .get_ant = NULL, diff --git a/rigs/icom/ic703.c b/rigs/icom/ic703.c index 419bc17b..d48ba807 100644 --- a/rigs/icom/ic703.c +++ b/rigs/icom/ic703.c @@ -89,7 +89,7 @@ const struct rig_caps ic703_caps = RIG_MODEL(RIG_MODEL_IC703), .model_name = "IC-703", .mfg_name = "Icom", - .version = BACKEND_VER ".0", + .version = BACKEND_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -202,6 +202,7 @@ const struct rig_caps ic703_caps = .set_mode = icom_set_mode, .get_mode = icom_get_mode, .set_vfo = icom_set_vfo, + .get_vfo = icom_get_vfo, .decode_event = icom_decode_event, .set_level = icom_set_level, diff --git a/rigs/icom/ic706.c b/rigs/icom/ic706.c index f420f617..7d84d5b9 100644 --- a/rigs/icom/ic706.c +++ b/rigs/icom/ic706.c @@ -153,7 +153,7 @@ const struct rig_caps ic706_caps = RIG_MODEL(RIG_MODEL_IC706), .model_name = "IC-706", .mfg_name = "Icom", - .version = BACKEND_VER ".0", + .version = BACKEND_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -257,6 +257,7 @@ const struct rig_caps ic706_caps = .get_freq = icom_get_freq, .set_mode = icom_set_mode, .get_mode = icom_get_mode, + .get_vfo = icom_get_vfo, .set_vfo = icom_set_vfo, .decode_event = icom_decode_event, @@ -291,7 +292,7 @@ const struct rig_caps ic706mkii_caps = RIG_MODEL(RIG_MODEL_IC706MKII), .model_name = "IC-706MkII", .mfg_name = "Icom", - .version = BACKEND_VER ".0", + .version = BACKEND_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -399,6 +400,7 @@ const struct rig_caps ic706mkii_caps = .get_freq = icom_get_freq, .set_mode = icom_set_mode, .get_mode = icom_get_mode, + .get_vfo = icom_get_vfo, .set_vfo = icom_set_vfo, .decode_event = icom_decode_event, @@ -453,7 +455,7 @@ const struct rig_caps ic706mkiig_caps = RIG_MODEL(RIG_MODEL_IC706MKIIG), .model_name = "IC-706MkIIG", .mfg_name = "Icom", - .version = BACKEND_VER ".0", + .version = BACKEND_VER ".1", .copyright = "LGPL", .status = RIG_STATUS_STABLE, .rig_type = RIG_TYPE_MOBILE, @@ -590,6 +592,7 @@ c... [truncated message content] |
From: Michael B. <mdb...@us...> - 2021-09-26 04:28:04
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 7bd407beda8e3c020572cd39ae18a9bd2142ccde (commit) via 2e2543a0fce5cd39d2b439aff8db64272b7ddb8d (commit) via cc5010d0e3bed0415cc3974c62d5f22cc45b2399 (commit) via fc765a48cc964bdcd034c76bdb8fde0206abca4f (commit) via 0b9b71999772a2dd035691709e642c813afeb2c1 (commit) via 1f9ffe30357a491639dfc24f9ee426e1fac8a077 (commit) via 186ed2ae43a93425c0f14f45bdb384b00a804707 (commit) via 1c3250f6f43f5c872e637ab0bf768fe441e63b9f (commit) via 782ad2a03464c42f57aca820634e1f68aae64553 (commit) via e51e645d2a99dd79ac9e60cbe8470c6002dbd8a9 (commit) via 376db9e2e7268e13121f0497ee5ddf00ebefb5d2 (commit) via 875104c395622795d4f74b18206a6d29fe96dc5b (commit) from 421c6e7c4e4d6ef552ca39241463c71244b424a2 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 7bd407beda8e3c020572cd39ae18a9bd2142ccde Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Sep 25 23:26:49 2021 -0500 Add some more elapsed time entries and reduce ELAPSED2 macro diff --git a/src/rig.c b/src/rig.c index e2b8387b..8fb69daa 100644 --- a/src/rig.c +++ b/src/rig.c @@ -158,7 +158,7 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */ #define CHECK_RIG_ARG(r) (!(r) || !(r)->caps || !(r)->state.comm_state) #define ELAPSED1 clock_t __begin = clock() -#define ELAPSED2 double __elapsed = ((double)clock() - __begin) / CLOCKS_PER_SEC*1000; rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, __elapsed) +#define ELAPSED2 rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, ((double)clock() - __begin) / CLOCKS_PER_SEC * 1000) /* * Data structure to track the opened rig (by rig_open) @@ -2266,6 +2266,7 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) { RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; // do not mess with mode while PTT is on if (rig->state.cache.ptt) @@ -2328,6 +2329,7 @@ int HAMLIB_API rig_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width) set_cache_mode(rig, vfo, mode, width); + ELAPSED2; RETURNFUNC(retcode); } @@ -2363,6 +2365,7 @@ int HAMLIB_API rig_get_mode(RIG *rig, freq_t freq; ENTERFUNC; + ELAPSED1; if (CHECK_RIG_ARG(rig)) { @@ -2397,6 +2400,7 @@ int HAMLIB_API rig_get_mode(RIG *rig, rig_debug(RIG_DEBUG_TRACE, "%s: cache hit age mode=%dms, width=%dms\n", __func__, cache_ms_mode, cache_ms_width); + ELAPSED2; RETURNFUNC(RIG_OK); } else @@ -2468,6 +2472,7 @@ int HAMLIB_API rig_get_mode(RIG *rig, set_cache_mode(rig, vfo, *mode, *width); cache_show(rig, __func__, __LINE__); + ELAPSED2; RETURNFUNC(retcode); } commit 2e2543a0fce5cd39d2b439aff8db64272b7ddb8d Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Sep 25 23:16:08 2021 -0500 Fix ELAPSED2 time diff --git a/src/rig.c b/src/rig.c index 333ef849..e2b8387b 100644 --- a/src/rig.c +++ b/src/rig.c @@ -158,7 +158,7 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */ #define CHECK_RIG_ARG(r) (!(r) || !(r)->caps || !(r)->state.comm_state) #define ELAPSED1 clock_t __begin = clock() -#define ELAPSED2 double __elapsed = ((double)clock() - __begin) / CLOCKS_PER_SEC; rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, __elapsed) +#define ELAPSED2 double __elapsed = ((double)clock() - __begin) / CLOCKS_PER_SEC*1000; rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, __elapsed) /* * Data structure to track the opened rig (by rig_open) @@ -2017,6 +2017,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) { RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; if (!freq) commit cc5010d0e3bed0415cc3974c62d5f22cc45b2399 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Sep 25 11:45:42 2021 -0500 Add otherVFO to misc.c diff --git a/src/misc.c b/src/misc.c index c4a6e0c0..3e79c6f9 100644 --- a/src/misc.c +++ b/src/misc.c @@ -577,6 +577,7 @@ static const struct { RIG_VFO_SUB_B, "SubB" }, { RIG_VFO_SUB_C, "SubC" }, { RIG_VFO_NONE, "None" }, + { RIG_VFO_OTHER, "otherVFO" }, { 0xffffff, "" }, }; commit fc765a48cc964bdcd034c76bdb8fde0206abca4f Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Sep 25 11:14:33 2021 -0500 Add VFO_OTHER for Icom rigs so they can request unselected VFO items diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index a649a448..572dfda6 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -463,6 +463,9 @@ typedef unsigned int vfo_t; /** \brief \c MainC -- alias for MAIN_C */ #define RIG_VFO_MAIN_C RIG_VFO_N(4) +/** \brief \c Other -- alias for OTHER -- e.g. Icom rigs without get_vfo capability */ +#define RIG_VFO_OTHER RIG_VFO_N(5) + /** \brief \c Sub -- alias for SUB */ #define RIG_VFO_SUB RIG_VFO_N(25) commit 0b9b71999772a2dd035691709e642c813afeb2c1 Author: Mike Black W9MDB <mdb...@ya...> Date: Sat Sep 25 08:59:57 2021 -0500 Add elapsed time macros and put in vfo and freq calls diff --git a/src/rig.c b/src/rig.c index 5c4ab9aa..333ef849 100644 --- a/src/rig.c +++ b/src/rig.c @@ -157,6 +157,8 @@ const char hamlib_copyright[231] = /* hamlib 1.2 ABI specifies 231 bytes */ #define CHECK_RIG_ARG(r) (!(r) || !(r)->caps || !(r)->state.comm_state) +#define ELAPSED1 clock_t __begin = clock() +#define ELAPSED2 double __elapsed = ((double)clock() - __begin) / CLOCKS_PER_SEC; rig_debug(RIG_DEBUG_TRACE, "%s: elapsed=%.0lfms\n", __func__, __elapsed) /* * Data structure to track the opened rig (by rig_open) @@ -1812,6 +1814,8 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; + if (rig->state.twiddle_state == TWIDDLE_ON) { // we keep skipping set_freq while the vfo knob is in motion @@ -1855,6 +1859,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_set_vfo(rig, vfo_save); } + ELAPSED2; RETURNFUNC( RIG_OK); // would be better as error but other software won't handle errors } @@ -1928,6 +1933,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_set_vfo(rig, vfo_save); } + ELAPSED2; RETURNFUNC( RIG_OK); // would be better as error but other software won't handle errors } @@ -1978,6 +1984,7 @@ int HAMLIB_API rig_set_freq(RIG *rig, vfo_t vfo, freq_t freq) rig_set_vfo(rig, vfo_save); } + ELAPSED2; RETURNFUNC(retcode); } @@ -2010,6 +2017,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) { RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; if (!freq) { @@ -2044,6 +2052,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) int cache_ms_freq, cache_ms_mode, cache_ms_width; rig_get_cache(rig, vfo, freq, &cache_ms_freq, &mode, &cache_ms_mode, &width, &cache_ms_width); + ELAPSED2; RETURNFUNC(RIG_OK); } @@ -2087,6 +2096,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) { rig_debug(RIG_DEBUG_TRACE, "%s: %s cache hit age=%dms, freq=%.0f\n", __func__, rig_strvfo(vfo), cache_ms_freq, *freq); + ELAPSED2; RETURNFUNC(RIG_OK); } else @@ -2195,6 +2205,7 @@ int HAMLIB_API rig_get_freq(RIG *rig, vfo_t vfo, freq_t *freq) set_cache_freq(rig, vfo, *freq); cache_show(rig, __func__, __LINE__); + ELAPSED2; RETURNFUNC(retcode); } @@ -2776,6 +2787,7 @@ int HAMLIB_API rig_get_vfo(RIG *rig, vfo_t *vfo) int cache_ms; ENTERFUNC; + ELAPSED1; if (CHECK_RIG_ARG(rig) || !vfo) { @@ -2804,6 +2816,7 @@ int HAMLIB_API rig_get_vfo(RIG *rig, vfo_t *vfo) { rig_debug(RIG_DEBUG_TRACE, "%s: cache hit age=%dms\n", __func__, cache_ms); *vfo = rig->state.cache.vfo; + ELAPSED2; RETURNFUNC(RIG_OK); } else @@ -2831,6 +2844,7 @@ int HAMLIB_API rig_get_vfo(RIG *rig, vfo_t *vfo) rigerror(retcode)); } + ELAPSED2; RETURNFUNC(retcode); } @@ -4577,7 +4591,8 @@ int HAMLIB_API rig_set_split_vfo(RIG *rig, // We fix up vfos for non-satmode rigs only if (rig->caps->has_get_func & RIG_FUNC_SATMODE) { - rig_debug(RIG_DEBUG_TRACE, "%s: satmode rig...not fixing up vfos rx=%s tx=%s\n", __func__, rig_strvfo(rx_vfo), rig_strvfo(tx_vfo)); + rig_debug(RIG_DEBUG_TRACE, "%s: satmode rig...not fixing up vfos rx=%s tx=%s\n", + __func__, rig_strvfo(rx_vfo), rig_strvfo(tx_vfo)); } else { @@ -6197,6 +6212,7 @@ int HAMLIB_API rig_stop_morse(RIG *rig, vfo_t vfo) vfo_t curr_vfo; ENTERFUNC; + if (CHECK_RIG_ARG(rig)) { RETURNFUNC(-RIG_EINVAL); @@ -6300,6 +6316,7 @@ int HAMLIB_API rig_wait_morse(RIG *rig, vfo_t vfo) vfo_t curr_vfo; ENTERFUNC; + if (CHECK_RIG_ARG(rig)) { RETURNFUNC(-RIG_EINVAL); @@ -6466,6 +6483,7 @@ int HAMLIB_API rig_set_vfo_opt(RIG *rig, int status) int retcode; ENTERFUNC; + ELAPSED1; if CHECK_RIG_ARG(rig) { @@ -6477,8 +6495,8 @@ int HAMLIB_API rig_set_vfo_opt(RIG *rig, int status) RETURNFUNC(-RIG_ENAVAIL); } - TRACE; retcode = rig->caps->set_vfo_opt(rig, status); + ELAPSED2; RETURNFUNC(retcode); } @@ -6580,6 +6598,8 @@ int HAMLIB_API rig_get_rig_info(RIG *rig, char *response, int max_response_len) RETURNFUNC(-RIG_EINVAL); } + ELAPSED1; + vfoA = vfo_fixup(rig, RIG_VFO_A, rig->state.cache.split); vfoB = vfo_fixup(rig, RIG_VFO_B, rig->state.cache.split); ret = rig_get_vfo_info(rig, vfoA, &freqA, &modeA, &widthA, &split, &satmode); @@ -6633,6 +6653,7 @@ int HAMLIB_API rig_get_rig_info(RIG *rig, char *response, int max_response_len) RETURNFUNC(RIG_EINTERNAL); } + ELAPSED2; RETURNFUNC(RIG_OK); } @@ -6811,7 +6832,7 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, if (!cookie) { rig_debug(RIG_DEBUG_ERR, "%s(%d): cookie == NULL\n", - __FILE__, __LINE__); + __FILE__, __LINE__); return -RIG_EINVAL; // nothing to do } @@ -6858,8 +6879,8 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, else { rig_debug(RIG_DEBUG_ERR, - "%s(%d): %s renew request refused %s is active\n", - __FILE__, __LINE__, cookie, cookie_save); + "%s(%d): %s renew request refused %s is active\n", + __FILE__, __LINE__, cookie, cookie_save); ret = -RIG_EINVAL; // wrong cookie } @@ -6886,8 +6907,8 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, if (cookie_save[0] != 0) { rig_debug(RIG_DEBUG_ERR, - "%s(%d): %s cookie has expired after %.3f seconds....overriding with new cookie\n", - __FILE__, __LINE__, cookie_save, time_curr - time_last_used); + "%s(%d): %s cookie has expired after %.3f seconds....overriding with new cookie\n", + __FILE__, __LINE__, cookie_save, time_curr - time_last_used); } date_strget(cookie, cookie_len); @@ -6898,9 +6919,10 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, strcpy(cookie_save, cookie); time_last_used = time_curr; rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): %s new cookie request granted\n", - __FILE__, __LINE__, cookie_save); + __FILE__, __LINE__, cookie_save); ret = RIG_OK; } + break; default: commit 1f9ffe30357a491639dfc24f9ee426e1fac8a077 Merge: 186ed2ae 1c3250f6 Author: Michael Black <mdb...@ya...> Date: Fri Sep 24 22:24:15 2021 -0500 Merge pull request #810 from AuroraRAS/androidsensor add androidsensor rotator commit 186ed2ae43a93425c0f14f45bdb384b00a804707 Merge: e51e645d 782ad2a0 Author: Michael Black <mdb...@ya...> Date: Fri Sep 24 22:23:57 2021 -0500 Merge pull request #809 from AuroraRAS/keepgoingndk make the Android.mk files adapt to multi arch commit 1c3250f6f43f5c872e637ab0bf768fe441e63b9f Author: AuroraRAS <ch...@gm...> Date: Sat Sep 25 07:12:08 2021 +0800 add androidsensor rotator The androidsensor rotator is not a real rotator, it uses the accelerometer sensor and magnetic field sensor of the cell phone or tablet to perform attitude determination for your antenna and the phone tied to it. Now you can wave your antenna to find radio signals. Signed-off-by: AuroraRAS <ch...@gm...> diff --git a/Android.mk b/Android.mk index e59ea0b8..fd6cb4dc 100644 --- a/Android.mk +++ b/Android.mk @@ -49,3 +49,6 @@ include $(TOP_PATH)/rotators/satel/Android.mk include $(TOP_PATH)/rotators/spid/Android.mk include $(TOP_PATH)/rotators/ts7400/Android.mk include $(TOP_PATH)/rotators/radant/Android.mk +include $(TOP_PATH)/rotators/androidsensor/Android.mk + +include $(TOP_PATH)/tests/Android.mk diff --git a/include/hamlib/rotlist.h b/include/hamlib/rotlist.h index 939cad56..522d4acb 100644 --- a/include/hamlib/rotlist.h +++ b/include/hamlib/rotlist.h @@ -619,6 +619,11 @@ #define ROT_MODEL_RADANT ROT_MAKE_MODEL(ROT_RADANT, 1) +#define ROT_ANDROIDSENSOR 23 +#define ROT_BACKEND_ANDROIDSENSOR "androidsensor" +#define ROT_MODEL_ANDROIDSENSOR ROT_MAKE_MODEL(ROT_ANDROIDSENSOR, 1) + + /** * \brief Convenience type definition for a rotator model. * diff --git a/rotators/androidsensor/Android.mk b/rotators/androidsensor/Android.mk new file mode 100644 index 00000000..8c0ab815 --- /dev/null +++ b/rotators/androidsensor/Android.mk @@ -0,0 +1,12 @@ +LOCAL_PATH:= $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := androidsensor.cpp ndkimu.cpp +LOCAL_MODULE := androidsensor + +LOCAL_CFLAGS := -DHAVE_CONFIG_H +LOCAL_C_INCLUDES := android include src +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) + +include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/androidsensor/androidsensor.cpp b/rotators/androidsensor/androidsensor.cpp new file mode 100644 index 00000000..e53c1257 --- /dev/null +++ b/rotators/androidsensor/androidsensor.cpp @@ -0,0 +1,137 @@ +/* + * Hamlib Rotator backend - Radant + * Copyright (c) 2001-2003 by Stephane Fillod + * Contributed by Francois Retief <fgr...@su...> + * Copyright (c) 2014 by Alexander Schultze <ale...@gm...> + * + * + * 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 + * + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include <stdio.h> +#include <stdlib.h> +#include <string.h> /* String function definitions */ +#include <unistd.h> /* UNIX standard function definitions */ +#include <math.h> + +#include "hamlib/rotator.h" +#include "register.h" + +#include "androidsensor.h" +#include "ndkimu.cpp" + +/* ************************************************************************* */ + +static NdkImu *imu; + +static int +androidsensor_rot_set_position(ROT *rot, azimuth_t az, elevation_t el) +{ + rig_debug(RIG_DEBUG_TRACE, "%s called: %f %f\n", __func__, az, el); + // To-Do + return RIG_OK; +} + +static int +androidsensor_rot_get_position(ROT *rot, azimuth_t *az, elevation_t *el) +{ + rig_debug(RIG_DEBUG_TRACE, "%s called: ", __func__); + + imu->update(); + + float accData[3], magData[3]; + imu->getAccData(accData); + imu->getMagData(magData); + + float R[9] = {0}, I[9] = {0}, orientation[3] = {0}; + bool status = imu->getRotationMatrix(R, 9, I, 9, accData, magData); + if(status) + imu->getOrientation(R, 9, orientation); + + *az = (orientation[0] / M_PI * 180 ); + *el = (orientation[1] / M_PI * 180 ) * -1; + + rig_debug(RIG_DEBUG_TRACE, "%f %f\n", az, el); + + return RIG_OK; +} + +static int +androidsensor_rot_stop(ROT *rot) +{ + rig_debug(RIG_DEBUG_TRACE, "%s called\n", __func__); + // To-Do + return RIG_OK; +} + +static int +androidsensor_rot_init(ROT *rot) +{ + rig_debug(RIG_DEBUG_TRACE, "%s called, make new NdkImu\n", __func__); + imu = new NdkImu(); + return RIG_OK; +} + +static int +androidsensor_rot_cleanup(ROT *rot) +{ + rig_debug(RIG_DEBUG_TRACE, "%s called, delete imu\n", __func__); + delete imu; + return RIG_OK; +} + +/* ************************************************************************* */ + +const struct rot_caps androidsensor_rot_caps = +{ + ROT_MODEL(ROT_MODEL_ANDROIDSENSOR), + .model_name = "ACC/MAG", + .mfg_name = "Android Sensor", + .version = "20210925.0", + .copyright = "LGPL", + .rot_type = ROT_TYPE_AZEL, + .port_type = RIG_PORT_NONE, + + .min_az = -180.0, + .max_az = 180.0, + .min_el = -180.0, + .max_el = 180.0, + + .priv = NULL, /* priv */ + + .set_position = androidsensor_rot_set_position, + .get_position = androidsensor_rot_get_position, + .stop = androidsensor_rot_stop, + .rot_init = androidsensor_rot_init, + .rot_cleanup = androidsensor_rot_cleanup, +}; + +/* ************************************************************************* */ + +DECLARE_INITROT_BACKEND(androidsensor) +{ + rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__); + + rot_register(&androidsensor_rot_caps); + return RIG_OK; +} + +/* ************************************************************************* */ +/* end of file */ diff --git a/rotators/androidsensor/androidsensor.h b/rotators/androidsensor/androidsensor.h new file mode 100644 index 00000000..89878a5d --- /dev/null +++ b/rotators/androidsensor/androidsensor.h @@ -0,0 +1,29 @@ +/* + * Hamlib Rotator backend - Easycomm interface protocol + * Copyright (c) 2001-2003 by Stephane Fillod + * Contributed by Francois Retief <fgr...@su...> + * Copyright (c) 2014 by Alexander Schultze <ale...@gm...> + * + * + * 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 _ROT_ANDROIDSENSOR_H +#define _ROT_ANDROIDSENSOR_H 1 + +extern const struct rot_caps androidsensor_rot_caps; + +#endif /* _ROT_ANDROIDSENSOR_H */ diff --git a/rotators/androidsensor/ndkimu.cpp b/rotators/androidsensor/ndkimu.cpp new file mode 100644 index 00000000..36d8ea51 --- /dev/null +++ b/rotators/androidsensor/ndkimu.cpp @@ -0,0 +1,207 @@ +#include "ndkimu.h" + +#include <cmath> + +NdkImu::NdkImu(char kPackageName[]) +{ + sensorManager = AcquireASensorManagerInstance(kPackageName); + assert(sensorManager != NULL); + accelerometer = ASensorManager_getDefaultSensor(sensorManager, ASENSOR_TYPE_ACCELEROMETER); + geomagnetic = ASensorManager_getDefaultSensor(sensorManager, ASENSOR_TYPE_MAGNETIC_FIELD); + assert(accelerometer != NULL); + looper = ALooper_prepare(ALOOPER_PREPARE_ALLOW_NON_CALLBACKS); + assert(looper != NULL); + accelerometerEventQueue = ASensorManager_createEventQueue(sensorManager, looper, + LOOPER_ID_USER, NULL, NULL); + geomagneticEventQueue = ASensorManager_createEventQueue(sensorManager, looper, + LOOPER_ID_USER, NULL, NULL); + assert(accelerometerEventQueue != NULL); + auto status = ASensorEventQueue_enableSensor(accelerometerEventQueue, + accelerometer); + assert(status >= 0); + + status = ASensorEventQueue_setEventRate(accelerometerEventQueue, + accelerometer, + SENSOR_REFRESH_PERIOD_US); + assert(status >= 0); + + status = ASensorEventQueue_enableSensor(geomagneticEventQueue, + geomagnetic); + assert(status >= 0); + + status = ASensorEventQueue_setEventRate(geomagneticEventQueue, + geomagnetic, + SENSOR_REFRESH_PERIOD_US); + assert(status >= 0); +} + +NdkImu::~NdkImu() +{ + auto status = ASensorEventQueue_disableSensor(accelerometerEventQueue, + accelerometer); + assert(status >= 0); + + status = ASensorEventQueue_disableSensor(geomagneticEventQueue, + geomagnetic); + assert(status >= 0); +} + +ASensorManager *NdkImu::AcquireASensorManagerInstance(char kPackageName[]) +{ + typedef ASensorManager *(*PF_GETINSTANCEFORPACKAGE)(const char *name); + void* androidHandle = dlopen("libandroid.so", RTLD_NOW); + PF_GETINSTANCEFORPACKAGE getInstanceForPackageFunc = (PF_GETINSTANCEFORPACKAGE) + dlsym(androidHandle, "ASensorManager_getInstanceForPackage"); + if (getInstanceForPackageFunc) { + return getInstanceForPackageFunc(kPackageName); + } + + typedef ASensorManager *(*PF_GETINSTANCE)(); + PF_GETINSTANCE getInstanceFunc = (PF_GETINSTANCE) + dlsym(androidHandle, "ASensorManager_getInstance"); + // by all means at this point, ASensorManager_getInstance should be available + assert(getInstanceFunc); + return getInstanceFunc(); +} + +/* + * https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/hardware/SensorManager.java + * blob: 9e78a6bb476061b4e20378ba20a00a2761e1ed7e + * line 1174 + */ +bool NdkImu::getRotationMatrix(float R[], size_t Rlength, float I[], size_t Ilength, float gravity[], float geomagnetic[]) +{ + // TODO: move this to native code for efficiency + float Ax = gravity[0]; + float Ay = gravity[1]; + float Az = gravity[2]; + const float normsqA = (Ax * Ax + Ay * Ay + Az * Az); + const float g = 9.81f; + const float freeFallGravitySquared = 0.01f * g * g; + if (normsqA < freeFallGravitySquared) { + // gravity less than 10% of normal value + return false; + } + const float Ex = geomagnetic[0]; + const float Ey = geomagnetic[1]; + const float Ez = geomagnetic[2]; + float Hx = Ey * Az - Ez * Ay; + float Hy = Ez * Ax - Ex * Az; + float Hz = Ex * Ay - Ey * Ax; + const float normH = (float) std::sqrt(Hx * Hx + Hy * Hy + Hz * Hz); + if (normH < 0.1f) { + // device is close to free fall (or in space?), or close to + // magnetic north pole. Typical values are > 100. + return false; + } + const float invH = 1.0f / normH; + Hx *= invH; + Hy *= invH; + Hz *= invH; + const float invA = 1.0f / (float) std::sqrt(Ax * Ax + Ay * Ay + Az * Az); + Ax *= invA; + Ay *= invA; + Az *= invA; + const float Mx = Ay * Hz - Az * Hy; + const float My = Az * Hx - Ax * Hz; + const float Mz = Ax * Hy - Ay * Hx; + if (R != NULL) { + if (Rlength == 9) { + R[0] = Hx; R[1] = Hy; R[2] = Hz; + R[3] = Mx; R[4] = My; R[5] = Mz; + R[6] = Ax; R[7] = Ay; R[8] = Az; + } else if (Rlength == 16) { + R[0] = Hx; R[1] = Hy; R[2] = Hz; R[3] = 0; + R[4] = Mx; R[5] = My; R[6] = Mz; R[7] = 0; + R[8] = Ax; R[9] = Ay; R[10] = Az; R[11] = 0; + R[12] = 0; R[13] = 0; R[14] = 0; R[15] = 1; + } + } + if (I != NULL) { + // compute the inclination matrix by projecting the geomagnetic + // vector onto the Z (gravity) and X (horizontal component + // of geomagnetic vector) axes. + const float invE = 1.0f / (float) std::sqrt(Ex * Ex + Ey * Ey + Ez * Ez); + const float c = (Ex * Mx + Ey * My + Ez * Mz) * invE; + const float s = (Ex * Ax + Ey * Ay + Ez * Az) * invE; + if (Ilength == 9) { + I[0] = 1; I[1] = 0; I[2] = 0; + I[3] = 0; I[4] = c; I[5] = s; + I[6] = 0; I[7] = -s; I[8] = c; + } else if (Ilength == 16) { + I[0] = 1; I[1] = 0; I[2] = 0; + I[4] = 0; I[5] = c; I[6] = s; + I[8] = 0; I[9] = -s; I[10] = c; + I[3] = I[7] = I[11] = I[12] = I[13] = I[14] = 0; + I[15] = 1; + } + } + return true; +} + +/* + * https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/hardware/SensorManager.java + * blob: 9e78a6bb476061b4e20378ba20a00a2761e1ed7e + * line 1469 + */ +float *NdkImu::getOrientation(float R[], size_t Rlength, float valuesBuf[]) +{ + if(valuesBuf == NULL) + valuesBuf = (float*)malloc(sizeof (float)*3); + + if (Rlength == 9) { + valuesBuf[0] = (float) std::atan2(R[1], R[4]); + valuesBuf[1] = (float) std::asin(-R[7]); + valuesBuf[2] = (float) std::atan2(-R[6], R[8]); + } else { + valuesBuf[0] = (float) std::atan2(R[1], R[5]); + valuesBuf[1] = (float) std::asin(-R[9]); + valuesBuf[2] = (float) std::atan2(-R[8], R[10]); + } + return valuesBuf; +} + +void NdkImu::update() +{ + ALooper_pollAll(0, NULL, NULL, NULL); + ASensorEvent event; + const float a = SENSOR_FILTER_ALPHA; + + while (ASensorEventQueue_getEvents(accelerometerEventQueue, &event, 1) > 0) { + sensorAccDataFilter.x = a * event.acceleration.x + (1.0f - a) * sensorAccDataFilter.x; + sensorAccDataFilter.y = a * event.acceleration.y + (1.0f - a) * sensorAccDataFilter.y; + sensorAccDataFilter.z = a * event.acceleration.z + (1.0f - a) * sensorAccDataFilter.z; + } + sensorAccData[sensorAccDataIndex] = sensorAccDataFilter; + sensorAccData[SENSOR_HISTORY_LENGTH+sensorAccDataIndex] = sensorAccDataFilter; + sensorAccDataIndex = (sensorAccDataIndex + 1) % SENSOR_HISTORY_LENGTH; + + while (ASensorEventQueue_getEvents(geomagneticEventQueue, &event, 1) > 0) { + sensorMagDataFilter.x = a * event.magnetic.x + (1.0f - a) * sensorMagDataFilter.x; + sensorMagDataFilter.y = a * event.magnetic.y + (1.0f - a) * sensorMagDataFilter.y; + sensorMagDataFilter.z = a * event.magnetic.z + (1.0f - a) * sensorMagDataFilter.z; + } + sensorMagData[sensorMagDataIndex] = sensorMagDataFilter; + sensorMagData[SENSOR_HISTORY_LENGTH+sensorMagDataIndex] = sensorMagDataFilter; + sensorMagDataIndex = (sensorMagDataIndex + 1) % SENSOR_HISTORY_LENGTH; +} + +float *NdkImu::getAccData(float accDataBuf[]) +{ + if(accDataBuf == NULL) + accDataBuf = (float*)malloc(sizeof (float)*3); + accDataBuf[0] = sensorAccDataFilter.x; + accDataBuf[1] = sensorAccDataFilter.y; + accDataBuf[2] = sensorAccDataFilter.z; + return accDataBuf; +} + +float *NdkImu::getMagData(float magDataBuf[]) +{ + if(magDataBuf == NULL) + magDataBuf = (float*)malloc(sizeof (float)*3); + magDataBuf[0] = sensorMagDataFilter.x; + magDataBuf[1] = sensorMagDataFilter.y; + magDataBuf[2] = sensorMagDataFilter.z; + return magDataBuf; +} diff --git a/rotators/androidsensor/ndkimu.h b/rotators/androidsensor/ndkimu.h new file mode 100644 index 00000000..9225d9bf --- /dev/null +++ b/rotators/androidsensor/ndkimu.h @@ -0,0 +1,57 @@ +#ifndef NDKIMU_H +#define NDKIMU_H + +#include <dlfcn.h> +#include <GLES2/gl2.h> + +#include <android/looper.h> +#include <android/sensor.h> + +#include <cstdint> +#include <cassert> +#include <string> + + +static const int LOOPER_ID_USER = 3; +static const int SENSOR_HISTORY_LENGTH = 100; +static const int SENSOR_REFRESH_RATE_HZ = 100; +static constexpr int32_t SENSOR_REFRESH_PERIOD_US = int32_t(1000000 / SENSOR_REFRESH_RATE_HZ); +static const float SENSOR_FILTER_ALPHA = 0.1f; + +class NdkImu +{ +public: + NdkImu(char kPackageName[] = NULL); + ~NdkImu(); + static ASensorManager *AcquireASensorManagerInstance(char kPackageName[]); + static bool getRotationMatrix(float R[], size_t Rlength, float I[], size_t Ilength, float gravity[], float geomagnetic[]); + static float *getOrientation(float R[], size_t Rlength, float valuesBuf[] = NULL); + +private: + ASensorManager *sensorManager; + const ASensor *accelerometer; + ASensorEventQueue *accelerometerEventQueue; + const ASensor *geomagnetic; + ASensorEventQueue *geomagneticEventQueue; + ALooper *looper; + + struct SensorData { + GLfloat x; + GLfloat y; + GLfloat z; + }; + SensorData sensorAccData[SENSOR_HISTORY_LENGTH*2]; + SensorData sensorAccDataFilter; + SensorData sensorMagData[SENSOR_HISTORY_LENGTH*2]; + SensorData sensorMagDataFilter; + + int sensorAccDataIndex; + int sensorMagDataIndex; + +public: + void update(); + float *getAccData(float accDataBuf[] = NULL); + float *getMagData(float magDataBuf[] = NULL); +}; + +#endif // NDKIMU_H diff --git a/src/Android.mk b/src/Android.mk index d4a1f315..24090e7c 100644 --- a/src/Android.mk +++ b/src/Android.mk @@ -39,8 +39,8 @@ LOCAL_STATIC_LIBRARIES := adat alinco amsat aor ars barrett celestron cnctrk \ gs232a heathkit icmarine icom ioptron jrc kachina kenwood kit \ lowe m2 meade pcr prm80 prosistel racal rft \ rotorez rs sartek satel skanti spid tapr tentec ts7400 tuner \ - uniden wj yaesu radant + uniden wj yaesu radant androidsensor -LOCAL_LDLIBS := -llog +LOCAL_LDLIBS := -llog -landroid include $(BUILD_SHARED_LIBRARY) diff --git a/src/rot_reg.c b/src/rot_reg.c index 3a97ed71..05494a9c 100644 --- a/src/rot_reg.c +++ b/src/rot_reg.c @@ -89,6 +89,9 @@ DEFINE_INITROT_BACKEND(radant); #if HAVE_LIBINDI DEFINE_INITROT_BACKEND(indi); #endif +#if defined(ANDROID) || defined(__ANDROID__) +DEFINE_INITROT_BACKEND(androidsensor); +#endif //! @endcond /** @@ -132,6 +135,9 @@ static struct { ROT_RADANT, ROT_BACKEND_RADANT, ROT_FUNCNAMA(radant)}, #if HAVE_LIBINDI { ROT_INDI, ROT_BACKEND_INDI, ROT_FUNCNAMA(indi) }, +#endif +#if defined(ANDROID) || defined(__ANDROID__) + { ROT_ANDROIDSENSOR, ROT_BACKEND_ANDROIDSENSOR, ROT_FUNCNAMA(androidsensor) }, #endif { 0, NULL }, /* end */ }; diff --git a/tests/Android.mk b/tests/Android.mk new file mode 100644 index 00000000..785b6d6f --- /dev/null +++ b/tests/Android.mk @@ -0,0 +1,12 @@ +LOCAL_PATH:= $(call my-dir) + +include $(CLEAR_VARS) + +LOCAL_SRC_FILES := rotctld.c rotctl_parse.c dumpcaps_rot.c ../src/rot_settings.c +LOCAL_MODULE := rotctld + +LOCAL_CFLAGS := -DHAVE_CONFIG_H +LOCAL_C_INCLUDES := android include src +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) + +include $(BUILD_EXECUTABLE) diff --git a/tests/rotctld.c b/tests/rotctld.c index b714265b..19b12ce3 100644 --- a/tests/rotctld.c +++ b/tests/rotctld.c @@ -664,6 +664,9 @@ void *handle_socket(void *arg) } fsockin = _fdopen(sock_osfhandle, "rb"); +#elif defined(ANDROID) || defined(__ANDROID__) + // fdsan does not allow fdopen the same fd twice in Android + fsockin = fdopen(dup(handle_data_arg->sock), "rb"); #else fsockin = fdopen(handle_data_arg->sock, "rb"); #endif @@ -676,6 +679,9 @@ void *handle_socket(void *arg) #ifdef __MINGW32__ fsockout = _fdopen(sock_osfhandle, "wb"); +#elif defined(ANDROID) || defined(__ANDROID__) + // fdsan does not allow fdopen the same fd twice in Android + fsockout = fdopen(dup(handle_data_arg->sock), "wb"); #else fsockout = fdopen(handle_data_arg->sock, "wb"); #endif commit 782ad2a03464c42f57aca820634e1f68aae64553 Author: AuroraRAS <ch...@gm...> Date: Sat Sep 25 07:03:23 2021 +0800 make the Android.mk files adapt to multi arch diff --git a/rigs/adat/Android.mk b/rigs/adat/Android.mk index ebc6d6c1..f7879829 100644 --- a/rigs/adat/Android.mk +++ b/rigs/adat/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := adat LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := $(LOCAL_SHARED_LIBRARIES) -Lobj/local/armeabi +LOCAL_LDLIBS := $(LOCAL_SHARED_LIBRARIES) -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/alinco/Android.mk b/rigs/alinco/Android.mk index a9e1eb66..e3c64ab0 100644 --- a/rigs/alinco/Android.mk +++ b/rigs/alinco/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := alinco LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/aor/Android.mk b/rigs/aor/Android.mk index 2d595d87..08ed00ca 100644 --- a/rigs/aor/Android.mk +++ b/rigs/aor/Android.mk @@ -8,6 +8,6 @@ LOCAL_MODULE := aor LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/barrett/Android.mk b/rigs/barrett/Android.mk index c04de178..658ef13f 100644 --- a/rigs/barrett/Android.mk +++ b/rigs/barrett/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := barrett LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/dorji/Android.mk b/rigs/dorji/Android.mk index d236abb2..1494e341 100644 --- a/rigs/dorji/Android.mk +++ b/rigs/dorji/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := dorji LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/drake/Android.mk b/rigs/drake/Android.mk index 92027e48..75d91ff7 100644 --- a/rigs/drake/Android.mk +++ b/rigs/drake/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := drake LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/dummy/Android.mk b/rigs/dummy/Android.mk index d981a291..aebc5c9e 100644 --- a/rigs/dummy/Android.mk +++ b/rigs/dummy/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := dummy LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/elad/Android.mk b/rigs/elad/Android.mk index 603ab915..81e393e2 100644 --- a/rigs/elad/Android.mk +++ b/rigs/elad/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := elad LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/flexradio/Android.mk b/rigs/flexradio/Android.mk index 5f56e060..5751e4a2 100644 --- a/rigs/flexradio/Android.mk +++ b/rigs/flexradio/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := flexradio LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/icmarine/Android.mk b/rigs/icmarine/Android.mk index 18bfe8e2..0cfc41d8 100644 --- a/rigs/icmarine/Android.mk +++ b/rigs/icmarine/Android.mk @@ -8,6 +8,6 @@ LOCAL_MODULE := icmarine LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/icom/Android.mk b/rigs/icom/Android.mk index a66e6fa7..0440f849 100644 --- a/rigs/icom/Android.mk +++ b/rigs/icom/Android.mk @@ -18,6 +18,6 @@ LOCAL_MODULE := icom LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/jrc/Android.mk b/rigs/jrc/Android.mk index 0c526517..f4f01f33 100644 --- a/rigs/jrc/Android.mk +++ b/rigs/jrc/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := jrc LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/kachina/Android.mk b/rigs/kachina/Android.mk index c845668e..a755e7f2 100644 --- a/rigs/kachina/Android.mk +++ b/rigs/kachina/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := kachina LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/kenwood/Android.mk b/rigs/kenwood/Android.mk index 9a7d39c9..44faf752 100644 --- a/rigs/kenwood/Android.mk +++ b/rigs/kenwood/Android.mk @@ -13,6 +13,6 @@ LOCAL_MODULE := kenwood LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/kit/Android.mk b/rigs/kit/Android.mk index e0988cd7..1bcd8c51 100644 --- a/rigs/kit/Android.mk +++ b/rigs/kit/Android.mk @@ -9,6 +9,6 @@ LOCAL_MODULE := kit LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/lowe/Android.mk b/rigs/lowe/Android.mk index 7370a0a2..871a0aa0 100644 --- a/rigs/lowe/Android.mk +++ b/rigs/lowe/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := lowe LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/pcr/Android.mk b/rigs/pcr/Android.mk index 86388976..8b4202e0 100644 --- a/rigs/pcr/Android.mk +++ b/rigs/pcr/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := pcr LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/prm80/Android.mk b/rigs/prm80/Android.mk index d3051f12..3438b302 100644 --- a/rigs/prm80/Android.mk +++ b/rigs/prm80/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := prm80 LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/racal/Android.mk b/rigs/racal/Android.mk index e26b0482..adeec4e6 100644 --- a/rigs/racal/Android.mk +++ b/rigs/racal/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := racal LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/rft/Android.mk b/rigs/rft/Android.mk index d90c5e24..724e10b4 100644 --- a/rigs/rft/Android.mk +++ b/rigs/rft/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := rft LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/rs/Android.mk b/rigs/rs/Android.mk index 04f88066..74e9fa25 100644 --- a/rigs/rs/Android.mk +++ b/rigs/rs/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := rs LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/skanti/Android.mk b/rigs/skanti/Android.mk index b13f20fb..d62a0b1a 100644 --- a/rigs/skanti/Android.mk +++ b/rigs/skanti/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := skanti LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/tapr/Android.mk b/rigs/tapr/Android.mk index c5a0191b..4e1d5166 100644 --- a/rigs/tapr/Android.mk +++ b/rigs/tapr/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := tapr LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/tentec/Android.mk b/rigs/tentec/Android.mk index 6a9935ae..40aa9cc1 100644 --- a/rigs/tentec/Android.mk +++ b/rigs/tentec/Android.mk @@ -9,6 +9,6 @@ LOCAL_MODULE := tentec LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/tuner/Android.mk b/rigs/tuner/Android.mk index d335f283..d05f290f 100644 --- a/rigs/tuner/Android.mk +++ b/rigs/tuner/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := tuner LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/uniden/Android.mk b/rigs/uniden/Android.mk index 748cbeb1..1a621d54 100644 --- a/rigs/uniden/Android.mk +++ b/rigs/uniden/Android.mk @@ -9,6 +9,6 @@ LOCAL_MODULE := uniden LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/winradio/Android.mk b/rigs/winradio/Android.mk index 261a1629..a4f19496 100644 --- a/rigs/winradio/Android.mk +++ b/rigs/winradio/Android.mk @@ -8,6 +8,6 @@ LOCAL_MODULE := winradio LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/wj/Android.mk b/rigs/wj/Android.mk index 633e4bce..a3e6b9f1 100644 --- a/rigs/wj/Android.mk +++ b/rigs/wj/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := wj LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rigs/yaesu/Android.mk b/rigs/yaesu/Android.mk index 501a8a68..a277423f 100644 --- a/rigs/yaesu/Android.mk +++ b/rigs/yaesu/Android.mk @@ -15,6 +15,6 @@ LOCAL_MODULE := yaesu LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -Lobj/local/armeabi +LOCAL_LDLIBS := -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/amsat/Android.mk b/rotators/amsat/Android.mk index 12aaf34a..7c1dd693 100644 --- a/rotators/amsat/Android.mk +++ b/rotators/amsat/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := amsat LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/ars/Android.mk b/rotators/ars/Android.mk index 785d38ea..e9dfa024 100644 --- a/rotators/ars/Android.mk +++ b/rotators/ars/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := ars LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/celestron/Android.mk b/rotators/celestron/Android.mk index 52340ff7..8429df13 100644 --- a/rotators/celestron/Android.mk +++ b/rotators/celestron/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := celestron LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/cnctrk/Android.mk b/rotators/cnctrk/Android.mk index 2392e6e1..3c6fb4e3 100644 --- a/rotators/cnctrk/Android.mk +++ b/rotators/cnctrk/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := cnctrk LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/easycomm/Android.mk b/rotators/easycomm/Android.mk index 84e2864a..808a2ecf 100644 --- a/rotators/easycomm/Android.mk +++ b/rotators/easycomm/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := easycomm LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/ether6/Android.mk b/rotators/ether6/Android.mk index 0655b9dc..cea491be 100644 --- a/rotators/ether6/Android.mk +++ b/rotators/ether6/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := ether6 LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/fodtrack/Android.mk b/rotators/fodtrack/Android.mk index b69f7351..bbac6b36 100644 --- a/rotators/fodtrack/Android.mk +++ b/rotators/fodtrack/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := fodtrack LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/gs232a/Android.mk b/rotators/gs232a/Android.mk index 7e42b2a1..1430b1f7 100644 --- a/rotators/gs232a/Android.mk +++ b/rotators/gs232a/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := gs232a LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/heathkit/Android.mk b/rotators/heathkit/Android.mk index 1a38dbdd..c368c1fe 100644 --- a/rotators/heathkit/Android.mk +++ b/rotators/heathkit/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := heathkit LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/indi/Android.mk b/rotators/indi/Android.mk index 4152c67a..650fa100 100644 --- a/rotators/indi/Android.mk +++ b/rotators/indi/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := indi LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/ioptron/Android.mk b/rotators/ioptron/Android.mk index 9f5a86f7..2af395ed 100644 --- a/rotators/ioptron/Android.mk +++ b/rotators/ioptron/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := ioptron LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -Lobj/local/armeabi +LOCAL_LDLIBS := -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/m2/Android.mk b/rotators/m2/Android.mk index d60e87a5..4c0b1b43 100644 --- a/rotators/m2/Android.mk +++ b/rotators/m2/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := m2 LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/meade/Android.mk b/rotators/meade/Android.mk index 2cb4e71b..aee5a231 100644 --- a/rotators/meade/Android.mk +++ b/rotators/meade/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := meade LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) \ No newline at end of file diff --git a/rotators/prosistel/Android.mk b/rotators/prosistel/Android.mk index 54acb1c0..9734efa7 100644 --- a/rotators/prosistel/Android.mk +++ b/rotators/prosistel/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := prosistel LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/radant/Android.mk b/rotators/radant/Android.mk index f66b69e9..be6ae097 100644 --- a/rotators/radant/Android.mk +++ b/rotators/radant/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := radant LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/rotorez/Android.mk b/rotators/rotorez/Android.mk index b1326884..ca583b21 100644 --- a/rotators/rotorez/Android.mk +++ b/rotators/rotorez/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := rotorez LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/sartek/Android.mk b/rotators/sartek/Android.mk index 49bbf76c..6bf426d2 100644 --- a/rotators/sartek/Android.mk +++ b/rotators/sartek/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := sartek LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/satel/Android.mk b/rotators/satel/Android.mk index 7925dd54..450412f3 100644 --- a/rotators/satel/Android.mk +++ b/rotators/satel/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := satel LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/spid/Android.mk b/rotators/spid/Android.mk index 1e920d1e..172254f4 100644 --- a/rotators/spid/Android.mk +++ b/rotators/spid/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := spid LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) diff --git a/rotators/ts7400/Android.mk b/rotators/ts7400/Android.mk index 7069bacd..3543d5a9 100644 --- a/rotators/ts7400/Android.mk +++ b/rotators/ts7400/Android.mk @@ -7,6 +7,6 @@ LOCAL_MODULE := ts7400 LOCAL_CFLAGS := -DHAVE_CONFIG_H LOCAL_C_INCLUDES := android include src -LOCAL_LDLIBS := -lhamlib -Lobj/local/armeabi +LOCAL_LDLIBS := -lhamlib -Lobj/local/$(TARGET_ARCH_ABI) include $(BUILD_STATIC_LIBRARY) commit e51e645d2a99dd79ac9e60cbe8470c6002dbd8a9 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Sep 22 22:38:04 2021 -0500 Fix rigtestlibusb.c to include config.h diff --git a/tests/rigtestlibusb.c b/tests/rigtestlibusb.c index 4689ff7e..d6eaeed8 100644 --- a/tests/rigtestlibusb.c +++ b/tests/rigtestlibusb.c @@ -24,6 +24,7 @@ #include <stdio.h> #include <string.h> +#include "config.h" #if defined(HAVE_LIBUSB_H) #include "libusb.h" #elif defined(HAVE_LIBUSB_1_0_LIBUSB_H) commit 376db9e2e7268e13121f0497ee5ddf00ebefb5d2 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Sep 22 22:34:31 2021 -0500 Fix compilation when OS does have libusb installed https://github.com/Hamlib/Hamlib/issues/803 diff --git a/configure.ac b/configure.ac index 03a99f95..540c0baf 100644 --- a/configure.ac +++ b/configure.ac @@ -324,8 +324,8 @@ AC_ARG_VAR([LIBUSB_LIBS], [linker flags for libusb, overriding configure check ( AS_IF([test x"${cf_with_libusb}" = "xyes"], [ AS_IF([test -z $LIBUSB_LIBS], [AC_CHECK_LIB([usb-1.0], [libusb_init], [LIBUSB_LIBS="-lusb-1.0"], - [AC_MSG_WARN([libusb_init was not found in libusb-1.0--USB backends will be disabled])]) - [cf_with_libusb="no"] + [AC_MSG_WARN([libusb_init was not found in libusb-1.0--USB backends will be disabled])] + [cf_with_libusb="no"]) ], [cf_with_libusb="yes"]) AS_IF([test x"${cf_with_libusb}" = "xyes"], commit 875104c395622795d4f74b18206a6d29fe96dc5b Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Sep 22 13:25:07 2021 -0500 Update comments in tests/Makefile.am diff --git a/tests/Makefile.am b/tests/Makefile.am index 7778a378..ca13581e 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -4,6 +4,8 @@ # AUTOMAKE_OPTIONS = dejagnu # DEJATOOL = testfreq testbcd testloc rigctl +# For some reason this "if" is not working -- rigtestlibusb is still being included +# Fix for now is to change rigtestlibusb.c instead if HAVE_LIBUSB TESTLIBUSB = rigtestlibusb else ----------------------------------------------------------------------- Summary of changes: Android.mk | 3 + configure.ac | 4 +- include/hamlib/rig.h | 3 + include/hamlib/rotlist.h | 5 + rigs/adat/Android.mk | 2 +- rigs/alinco/Android.mk | 2 +- rigs/aor/Android.mk | 2 +- rigs/barrett/Android.mk | 2 +- rigs/dorji/Android.mk | 2 +- rigs/drake/Android.mk | 2 +- rigs/dummy/Android.mk | 2 +- rigs/elad/Android.mk | 2 +- rigs/flexradio/Android.mk | 2 +- rigs/icmarine/Android.mk | 2 +- rigs/icom/Android.mk | 2 +- rigs/jrc/Android.mk | 2 +- rigs/kachina/Android.mk | 2 +- rigs/kenwood/Android.mk | 2 +- rigs/kit/Android.mk | 2 +- rigs/lowe/Android.mk | 2 +- rigs/pcr/Android.mk | 2 +- rigs/prm80/Android.mk | 2 +- rigs/racal/Android.mk | 2 +- rigs/rft/Android.mk | 2 +- rigs/rs/Android.mk | 2 +- rigs/skanti/Android.mk | 2 +- rigs/tapr/Android.mk | 2 +- rigs/tentec/Android.mk | 2 +- rigs/tuner/Android.mk | 2 +- rigs/uniden/Android.mk | 2 +- rigs/winradio/Android.mk | 2 +- rigs/wj/Android.mk | 2 +- rigs/yaesu/Android.mk | 2 +- rotators/amsat/Android.mk | 2 +- .../elecraft => rotators/androidsensor}/Android.mk | 6 +- rotators/androidsensor/androidsensor.cpp | 137 ++++++++++++++ .../fodtrack.h => androidsensor/androidsensor.h} | 12 +- rotators/androidsensor/ndkimu.cpp | 207 +++++++++++++++++++++ rotators/androidsensor/ndkimu.h | 57 ++++++ rotators/ars/Android.mk | 2 +- rotators/celestron/Android.mk | 2 +- rotators/cnctrk/Android.mk | 2 +- rotators/easycomm/Android.mk | 2 +- rotators/ether6/Android.mk | 2 +- rotators/fodtrack/Android.mk | 2 +- rotators/gs232a/Android.mk | 2 +- rotators/heathkit/Android.mk | 2 +- rotators/indi/Android.mk | 2 +- rotators/ioptron/Android.mk | 2 +- rotators/m2/Android.mk | 2 +- rotators/meade/Android.mk | 2 +- rotators/prosistel/Android.mk | 2 +- rotators/radant/Android.mk | 2 +- rotators/rotorez/Android.mk | 2 +- rotators/sartek/Android.mk | 2 +- rotators/satel/Android.mk | 2 +- rotators/spid/Android.mk | 2 +- rotators/ts7400/Android.mk | 2 +- src/Android.mk | 4 +- src/misc.c | 1 + src/rig.c | 44 ++++- src/rot_reg.c | 6 + tests/Android.mk | 12 ++ tests/Makefile.am | 2 + tests/rigtestlibusb.c | 1 + tests/rotctld.c | 6 + 66 files changed, 539 insertions(+), 69 deletions(-) copy {amplifiers/elecraft => rotators/androidsensor}/Android.mk (54%) create mode 100644 rotators/androidsensor/androidsensor.cpp copy rotators/{fodtrack/fodtrack.h => androidsensor/androidsensor.h} (71%) create mode 100644 rotators/androidsensor/ndkimu.cpp create mode 100644 rotators/androidsensor/ndkimu.h create mode 100644 tests/Android.mk hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Michael B. <mdb...@us...> - 2021-09-22 15:42:28
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 421c6e7c4e4d6ef552ca39241463c71244b424a2 (commit) from 0806896e3be5f2465f52b5352d2ec5bf684616f9 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 421c6e7c4e4d6ef552ca39241463c71244b424a2 Author: Mike Black W9MDB <mdb...@ya...> Date: Wed Sep 22 10:40:56 2021 -0500 Fix icom.c get_mode to not ask for unselected VFO when VFO_CURR is requested https://github.com/Hamlib/Hamlib/issues/806 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 2438fd4e..05d9f7b6 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2196,7 +2196,7 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) vfo_t vfoask = vfo_fixup(rig, vfo, 0); vfo_t vfocurr = vfo_fixup(rig, rig->state.current_vfo, 0); - if (vfoask != vfocurr) { vfosel = 0x01; } + if (vfo != RIG_VFO_CURR && vfoask != vfocurr) { vfosel = 0x01; } // use cache for the non-selected VFO -- can't get it by VFO // this avoids vfo swapping but accurate answers for these rigs diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index acdfeed1..e6459b7f 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210921" +#define BACKEND_VER "20210922" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) ----------------------------------------------------------------------- Summary of changes: rigs/icom/icom.c | 2 +- rigs/icom/icom.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |
From: Michael B. <mdb...@us...> - 2021-09-22 04:34:00
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Hamlib -- Ham radio control libraries". The branch, master has been updated via 0806896e3be5f2465f52b5352d2ec5bf684616f9 (commit) via 9671a26858404400b05dd9f47511a2dea9dd28d3 (commit) via a94dcddcf44c5ee1942f5c04a037edfb806f2878 (commit) via 4c0633bf6256af2ce64d7f0aff9b8ea9bc674209 (commit) via 3fb38741aa0a87fa2fa9a19f4eec433941a8dd92 (commit) via 0ad5f4c3dbe07be92b7e76968f1ecd38315cd03a (commit) via 8024fba14d364d3ed5f0fb290fa6d801b1853677 (commit) via a3ab4a4312a76e2b8eca9b0e088988bfb0083bc6 (commit) from c0c941a9d0d942fe374b607ff48a827c0d15017e (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 0806896e3be5f2465f52b5352d2ec5bf684616f9 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 21 23:32:12 2021 -0500 Fix compilation when OS does not have libusb installed https://github.com/Hamlib/Hamlib/issues/803 diff --git a/configure.ac b/configure.ac index 21d98847..03a99f95 100644 --- a/configure.ac +++ b/configure.ac @@ -321,10 +321,11 @@ LIBUSB="" AC_ARG_VAR([LIBUSB_CFLAGS], [C compiler flags for libusb, overriding configure defaults]) AC_ARG_VAR([LIBUSB_LIBS], [linker flags for libusb, overriding configure check (useful for specifying static libusb-1.0.a (see INSTALL))]) -AS_IF([test x"${cf_with_libusb}" = "xyes"], - [AS_IF([test -z $LIBUSB_LIBS], +AS_IF([test x"${cf_with_libusb}" = "xyes"], [ + AS_IF([test -z $LIBUSB_LIBS], [AC_CHECK_LIB([usb-1.0], [libusb_init], [LIBUSB_LIBS="-lusb-1.0"], [AC_MSG_WARN([libusb_init was not found in libusb-1.0--USB backends will be disabled])]) + [cf_with_libusb="no"] ], [cf_with_libusb="yes"]) AS_IF([test x"${cf_with_libusb}" = "xyes"], diff --git a/tests/rigtestlibusb.c b/tests/rigtestlibusb.c index 29156cc0..4689ff7e 100644 --- a/tests/rigtestlibusb.c +++ b/tests/rigtestlibusb.c @@ -24,12 +24,13 @@ #include <stdio.h> #include <string.h> -#if __has_include("libusb.h") +#if defined(HAVE_LIBUSB_H) #include "libusb.h" -#else +#elif defined(HAVE_LIBUSB_1_0_LIBUSB_H) #include <libusb-1.0/libusb.h> #endif +#if HAVE_LIBUSB int verbose = 0; static void print_endpoint_comp(const struct @@ -410,3 +411,10 @@ int main(int argc, char *argv[]) libusb_exit(NULL); return r; } +#else +int main() +{ + puts("libusb not installed"); + return 0; +} +#endif commit 9671a26858404400b05dd9f47511a2dea9dd28d3 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 21 23:30:45 2021 -0500 Add mutex back to rigctld. Migrating to mutext locks on all rig functions https://github.com/Hamlib/Hamlib/issues/695 diff --git a/tests/rigctld.c b/tests/rigctld.c index 854227e0..39110629 100644 --- a/tests/rigctld.c +++ b/tests/rigctld.c @@ -148,9 +148,8 @@ const char *multicast_addr = "0.0.0.0"; #define MAXCONFLEN 1024 -extern void sync_callback(int lock); -#if 0 -void sync_callback(int lock) + +void mutex_rigctld(int lock) { #ifdef HAVE_PTHREAD static pthread_mutex_t client_lock = PTHREAD_MUTEX_INITIALIZER; @@ -168,7 +167,6 @@ void sync_callback(int lock) #endif } -#endif #ifdef WIN32 static BOOL WINAPI CtrlHandler(DWORD fdwCtrlType) @@ -999,7 +997,7 @@ int main(int argc, char *argv[]) #ifdef HAVE_PTHREAD /* allow threads to finish current action */ - sync_callback(1); + mutex_rigctld(1); if (client_count) { @@ -1007,7 +1005,7 @@ int main(int argc, char *argv[]) } rig_close(my_rig); - sync_callback(0); + mutex_rigctld(0); #else rig_close(my_rig); /* close port */ #endif @@ -1085,7 +1083,7 @@ void *handle_socket(void *arg) } #ifdef HAVE_PTHREAD - sync_callback(1); + mutex_rigctld(1); // ++client_count; #if 0 @@ -1104,7 +1102,7 @@ void *handle_socket(void *arg) #endif - sync_callback(0); + mutex_rigctld(0); #else retcode = rig_open(my_rig); @@ -1134,7 +1132,7 @@ void *handle_socket(void *arg) rig_debug(RIG_DEBUG_TRACE, "%s: doing rigctl_parse vfo_mode=%d\n", __func__, handle_data_arg->vfo_mode); retcode = rigctl_parse(handle_data_arg->rig, fsockin, fsockout, NULL, 0, - sync_callback, + mutex_rigctld, 1, 0, &handle_data_arg->vfo_mode, send_cmd_term, &ext_resp, &resp_sep); if (retcode != 0) { rig_debug(RIG_DEBUG_VERBOSE, "%s: rigctl_parse retcode=%d\n", __func__, retcode); } @@ -1168,7 +1166,7 @@ void *handle_socket(void *arg) #ifdef HAVE_PTHREAD #if 0 - sync_callback(1); + mutex_rigctld(1); /* Release rig if there are no clients */ if (!--client_count) @@ -1183,7 +1181,7 @@ void *handle_socket(void *arg) } } - sync_callback(0); + mutex_rigctld(0); #endif #else rig_close(my_rig); commit a94dcddcf44c5ee1942f5c04a037edfb806f2878 Author: Mike Black W9MDB <mdb...@ya...> Date: Tue Sep 21 12:17:17 2021 -0500 Fix ICOM request for VFOB info when VFOB is active vfo https://github.com/Hamlib/Hamlib/issues/806 diff --git a/rigs/icom/icom.c b/rigs/icom/icom.c index 60daccfa..2438fd4e 100644 --- a/rigs/icom/icom.c +++ b/rigs/icom/icom.c @@ -2193,8 +2193,10 @@ int icom_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) && rig->caps->rig_model != RIG_MODEL_IC7800) { int vfosel = 0x00; + vfo_t vfoask = vfo_fixup(rig, vfo, 0); + vfo_t vfocurr = vfo_fixup(rig, rig->state.current_vfo, 0); - if (vfo & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) { vfosel = 0x01; } + if (vfoask != vfocurr) { vfosel = 0x01; } // use cache for the non-selected VFO -- can't get it by VFO // this avoids vfo swapping but accurate answers for these rigs @@ -6947,6 +6949,7 @@ int icom_set_parm(RIG *rig, setting_t parm, value_t val) rig_strparm(parm)); RETURNFUNC(-RIG_EINVAL); } + RETURNFUNC(-RIG_EINVAL); } diff --git a/rigs/icom/icom.h b/rigs/icom/icom.h index 9127b6e2..acdfeed1 100644 --- a/rigs/icom/icom.h +++ b/rigs/icom/icom.h @@ -30,7 +30,7 @@ #include <sys/time.h> #endif -#define BACKEND_VER "20210911" +#define BACKEND_VER "20210921" #define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B)) #define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00) commit 4c0633bf6256af2ce64d7f0aff9b8ea9bc674209 Merge: 3fb38741 a3ab4a43 Author: Michael Black <mdb...@ya...> Date: Tue Sep 21 09:26:11 2021 -0500 Merge pull request #804 from wutje/improve_rig Fix rig_cookie: use lock for reads and write. commit 3fb38741aa0a87fa2fa9a19f4eec433941a8dd92 Merge: c0c941a9 0ad5f4c3 Author: Michael Black <mdb...@ya...> Date: Mon Sep 20 16:31:56 2021 -0500 Merge pull request #805 from wutje/fix_yaesu_detect Fix Yaesu and Adat detect commit 0ad5f4c3dbe07be92b7e76968f1ecd38315cd03a Author: Wouter van Gulik <pa...@gm...> Date: Mon Sep 20 23:19:59 2021 +0200 Drop debug printf diff --git a/rigs/yaesu/yaesu.c b/rigs/yaesu/yaesu.c index 9a7b8cb5..ff209154 100644 --- a/rigs/yaesu/yaesu.c +++ b/rigs/yaesu/yaesu.c @@ -159,7 +159,6 @@ DECLARE_PROBERIG_BACKEND(yaesu) port->parm.serial.rate = rates[rates_idx]; port->timeout = 2 * 1000 / rates[rates_idx] + 50; - printf("Yaesu trying rate = %d\n", rates[rates_idx]); retval = serial_open(port); if (retval != RIG_OK) commit 8024fba14d364d3ed5f0fb290fa6d801b1853677 Author: Wouter van Gulik <pa...@gm...> Date: Mon Sep 20 23:06:25 2021 +0200 Fix bug yaesu and adat probe: Yaesu probe code never left the loop, even if it did find something. Adat tried stop_bits 0, which serial_setup rightfully refused. THIS IS UNTESTED. diff --git a/rigs/adat/adat.c b/rigs/adat/adat.c index bab7a946..c1503a52 100644 --- a/rigs/adat/adat.c +++ b/rigs/adat/adat.c @@ -3706,7 +3706,7 @@ DECLARE_PROBERIG_BACKEND(adat) } port->write_delay = port->post_write_delay = 10; - port->parm.serial.stop_bits = 0; + port->parm.serial.stop_bits = 2; port->retry = 1; diff --git a/rigs/yaesu/yaesu.c b/rigs/yaesu/yaesu.c index 09296e00..9a7b8cb5 100644 --- a/rigs/yaesu/yaesu.c +++ b/rigs/yaesu/yaesu.c @@ -134,7 +134,7 @@ DECLARE_PROBERIG_BACKEND(yaesu) static const unsigned char cmd[YAESU_CMD_LENGTH] = { 0x00, 0x00, 0x00, 0x00, 0xfa}; int id_len = -1, i, id1, id2; int retval = -1; - int rates[] = { 4800, 57600, 9600, 38400, 0 }; /* possible baud rates */ + static const int rates[] = { 4800, 57600, 9600, 38400, 0 }; /* possible baud rates */ int rates_idx; if (!port) @@ -159,6 +159,7 @@ DECLARE_PROBERIG_BACKEND(yaesu) port->parm.serial.rate = rates[rates_idx]; port->timeout = 2 * 1000 / rates[rates_idx] + 50; + printf("Yaesu trying rate = %d\n", rates[rates_idx]); retval = serial_open(port); if (retval != RIG_OK) @@ -172,9 +173,9 @@ DECLARE_PROBERIG_BACKEND(yaesu) close(port->fd); - if (retval != RIG_OK || id_len < 0) + if (retval == RIG_OK && id_len > 0) { - continue; + break; } } commit a3ab4a4312a76e2b8eca9b0e088988bfb0083bc6 Author: Wouter van Gulik <pa...@gm...> Date: Mon Sep 20 22:10:55 2021 +0200 Fix rig_cookie: use lock for reads and write. Ensure we never print more then HAMLIB_COOKIE_SIZE otherwise we read out-of-bounds. Drop stray printf. Add tests for invalid input and overly large input. Fix test2 to release the cookie. diff --git a/src/rig.c b/src/rig.c index 3ef58153..5c4ab9aa 100644 --- a/src/rig.c +++ b/src/rig.c @@ -6791,16 +6791,16 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, // only 1 client can have the cookie so these can be static // this should also prevent problems with DLLs & shared libraies // the debug_msg is another non-thread-safe which this will help fix - // 27 char cookie will last until the year 10000 static char - cookie_save[HAMLIB_COOKIE_SIZE]; // only one client can have the 26-char cookie + cookie_save[HAMLIB_COOKIE_SIZE]; // only one client can have the cookie static double time_last_used; - double time_curr; struct timespec tp; + int ret; #ifdef HAVE_PTHREAD static pthread_mutex_t cookie_lock = PTHREAD_MUTEX_INITIALIZER; #endif + /* This is not needed for RIG_COOKIE_RELEASE but keep it simple. */ if (cookie_len < HAMLIB_COOKIE_SIZE) { rig_debug(RIG_DEBUG_ERR, "%s(%d): cookie_len < %d\n", @@ -6815,6 +6815,12 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, return -RIG_EINVAL; // nothing to do } + /* Accesing cookie_save and time_last_used must be done with lock held. + * So keep code simple and lock it during the whole operation. */ +#ifdef HAVE_PTHREAD + pthread_mutex_lock(&cookie_lock); +#endif + switch (cookie_cmd) { case RIG_COOKIE_RELEASE: @@ -6824,14 +6830,14 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): %s cookie released\n", __FILE__, __LINE__, cookie_save); memset(cookie_save, 0, sizeof(cookie_save)); - return RIG_OK; + ret = RIG_OK; } else // not the right cookie!! { rig_debug(RIG_DEBUG_ERR, "%s(%d): %s can't release cookie as cookie %s is active\n", __FILE__, __LINE__, cookie, cookie_save); - return -RIG_BUSBUSY; + ret = -RIG_BUSBUSY; } break; @@ -6847,13 +6853,15 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, __LINE__, cookie); clock_gettime(CLOCK_REALTIME, &tp); time_last_used = tp.tv_sec + tp.tv_nsec / 1e9; - return RIG_OK; + ret = RIG_OK; + } + else + { + rig_debug(RIG_DEBUG_ERR, + "%s(%d): %s renew request refused %s is active\n", + __FILE__, __LINE__, cookie, cookie_save); + ret = -RIG_EINVAL; // wrong cookie } - - rig_debug(RIG_DEBUG_ERR, - "%s(%d): %s renew request refused %s is active\n", - __FILE__, __LINE__, cookie, cookie_save); - return -RIG_EINVAL; // wrong cookie break; @@ -6864,48 +6872,48 @@ int HAMLIB_API rig_cookie(RIG *rig, enum cookie_e cookie_cmd, char *cookie, // we are just allow for a crashed client that fails to release:q clock_gettime(CLOCK_REALTIME, &tp); - time_curr = tp.tv_sec + tp.tv_nsec / 1e9; - -#ifdef HAVE_PTHREAD - pthread_mutex_lock(&cookie_lock); -#endif + double time_curr = tp.tv_sec + tp.tv_nsec / 1e9; if (cookie_save[0] != 0 && (strcmp(cookie_save, cookie) == 0) && (time_curr - time_last_used < 1)) // then we will deny the request { - printf("Cookie %s in use\n", cookie_save); rig_debug(RIG_DEBUG_ERR, "%s(%d): %s cookie is in use\n", __FILE__, __LINE__, cookie_save); -#ifdef HAVE_PTHREAD - pthread_mutex_unlock(&cookie_lock); -#endif - return -RIG_BUSBUSY; + ret = -RIG_BUSBUSY; } - - - if (cookie_save[0] != 0) + else { - rig_debug(RIG_DEBUG_ERR, + if (cookie_save[0] != 0) + { + rig_debug(RIG_DEBUG_ERR, "%s(%d): %s cookie has expired after %.3f seconds....overriding with new cookie\n", __FILE__, __LINE__, cookie_save, time_curr - time_last_used); + } + + date_strget(cookie, cookie_len); + size_t len = strlen(cookie); + // add on our random number to ensure uniqueness + // The cookie should never be longer then HAMLIB_COOKIE_SIZE + snprintf(cookie + len, HAMLIB_COOKIE_SIZE - len, " %d\n", rand()); + strcpy(cookie_save, cookie); + time_last_used = time_curr; + rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): %s new cookie request granted\n", + __FILE__, __LINE__, cookie_save); + ret = RIG_OK; } + break; - date_strget(cookie_save, sizeof(cookie_save)); - // add on our random number to ensure uniqueness - snprintf(cookie, cookie_len, "%s %d\n", cookie_save, rand()); - strcpy(cookie_save, cookie); - time_last_used = time_curr; - rig_debug(RIG_DEBUG_VERBOSE, "%s(%d): %s new cookie request granted\n", - __FILE__, __LINE__, cookie_save); -#ifdef HAVE_PTHREAD - pthread_mutex_unlock(&cookie_lock); -#endif - return RIG_OK; + default: + rig_debug(RIG_DEBUG_ERR, "%s(%d): unknown cmd!!\n'", __FILE__, __LINE__); + ret = -RIG_EPROTO; break; } - rig_debug(RIG_DEBUG_ERR, "%s(%d): unknown cmd!!\n'", __FILE__, __LINE__); - return -RIG_EPROTO; +#ifdef HAVE_PTHREAD + pthread_mutex_unlock(&cookie_lock); +#endif + return ret; + } HAMLIB_EXPORT(void) sync_callback(int lock) diff --git a/tests/testcookie.c b/tests/testcookie.c index bdb22e7b..94c5fa65 100644 --- a/tests/testcookie.c +++ b/tests/testcookie.c @@ -1,7 +1,7 @@ #include <hamlib/rig.h> // GET tests -int test1() +static int test1() { int retcode; // Normal get @@ -45,7 +45,7 @@ int test1() } // RENEW tests -int test2() +static int test2() { int retcode; char cookie[HAMLIB_COOKIE_SIZE]; @@ -72,9 +72,61 @@ int test2() if (retcode != RIG_OK) { printf("Test#2d OK\n"); } else {printf("Test#2d Failed cookie=%s\n", cookie); return 1;} +// release cookie2 again to clean up test + retcode = rig_cookie(NULL, RIG_COOKIE_RELEASE, cookie2, sizeof(cookie2)); + + if (retcode == RIG_OK) { printf("Test#2e OK\n"); } + else {printf("Test#2e Failed\n"); return 1;} return 0; } +// Input sanity checks +static int test3_invalid_input() +{ + int retcode; + char cookie[HAMLIB_COOKIE_SIZE]; + /* Make sure any value smaller then HAMLIB_COOKIE_SIZE is rejected */ + for(unsigned int i = 0; i < HAMLIB_COOKIE_SIZE; i++) + { + retcode = rig_cookie(NULL, RIG_COOKIE_GET, cookie, i); + if (retcode == -RIG_EINVAL) { printf("Test#3a OK\n"); } + else {printf("Test#3a Failed\n"); return 1;} + } + + /* Make sure a NULL cookie is ignored */ + retcode = rig_cookie(NULL, RIG_COOKIE_GET, NULL, sizeof(cookie)); + if (retcode == -RIG_EINVAL) { printf("Test#3b OK\n"); } + else {printf("Test#3b Failed\n"); return 1;} + + /* Make sure an invalid command is dropped with proto error */ + retcode = rig_cookie(NULL, RIG_COOKIE_RENEW + 1, cookie, sizeof(cookie)); + if (retcode == -RIG_EPROTO) { printf("Test#3c OK\n"); } + else {printf("Test#3c Failed\n"); return 1;} + + return 0; +} + +static int test4_large_cookie_size() +{ + int retcode; + char cookie[HAMLIB_COOKIE_SIZE * 2]; + + /* Using a larger cookie should also work */ + retcode = rig_cookie(NULL, RIG_COOKIE_GET, cookie, sizeof(cookie)); + if (retcode == RIG_OK) { printf("Test#4a OK\n"); } + else {printf("Test#4a Failed\n"); return 1;} + + /* Cookie should be smaller the maximum specified by lib */ + if (strlen(cookie) < HAMLIB_COOKIE_SIZE) { printf("Test#4b OK\n"); } + else {printf("Test#4b Failed\n"); return 1;} + + /* Release the cookie again to clean up */ + retcode = rig_cookie(NULL, RIG_COOKIE_RELEASE, cookie, sizeof(cookie)); + if (retcode == RIG_OK) { printf("Test#4c OK\n"); } + else {printf("Test#4c Failed\n"); return 1;} + + return 0; +} int main() { @@ -84,5 +136,9 @@ int main() if (test2()) { return 1; } + if (test3_invalid_input()) { return 1; } + + if (test4_large_cookie_size()) { return 1; } + return 0; } ----------------------------------------------------------------------- Summary of changes: configure.ac | 5 +-- rigs/adat/adat.c | 2 +- rigs/icom/icom.c | 5 ++- rigs/icom/icom.h | 2 +- rigs/yaesu/yaesu.c | 6 ++-- src/rig.c | 84 ++++++++++++++++++++++++++++----------------------- tests/rigctld.c | 20 ++++++------ tests/rigtestlibusb.c | 12 ++++++-- tests/testcookie.c | 60 ++++++++++++++++++++++++++++++++++-- 9 files changed, 135 insertions(+), 61 deletions(-) hooks/post-receive -- Hamlib -- Ham radio control libraries |