Commit graph

696 commits

Author SHA1 Message Date
Dan Smith
20c2691abf Rename Signus to Cignus for XTR-5
This was added under the wrong vendor name in 18295675. A compat
mapping entry is added to avoid breaking existing images.

Related to #7997
2023-03-20 16:21:57 -07:00
Jim Unroe
44694d6702 Add Ruyage UV58Plus - fixes #10334 2023-03-18 18:23:35 -07:00
Dan Smith
cdd8f9fb3e Add py3 test matrix entries for new ga510 models
This was missed in the patch to add these models.
2023-03-18 10:06:28 -07:00
cong
9c348b180b New driver UV68 and TDH8
Fixes #10059
2023-03-18 09:21:38 -07:00
Bernhard Hailer
ab0d759426 Fix offset problem on Asia version FT-25R/65R
Asia region FT-25R / FT-65R radios treat repeater offsets differently
than their US siblings. This patch adds capabilities to detect such
radios and to correct the offset accordingly.

Fixes #9713
Fixes #10286
2023-03-18 08:32:57 -07:00
Dan Smith
db3041614d Fix drivers with special-included memory bounds
Some drivers have been incorrectly including the special channels
in the memory_bounds feature attribute. This causes the UI to fetch
them as regulars in addition. This adds a test to make sure the entire
regular memory range between memory_bounds has no extd_number (which
would indicate that it's a special).
2023-03-18 08:14:32 -07:00
Dan Smith
fdece2a844 Add baofeng FM radio uni tests
This adds some unit tests for the Baofeng FM Radio frequency encoding.
Right now it only tests the BF-T1, but has provisions for the UV-5R
as well. This uncovered a bug in the driver, so once that is fixed,
we can extend and enable that one as well.
2023-03-16 19:40:10 -07:00
Jim Unroe
96c3dacfcb uv5r.py: allow full-band programming support for UV-5G - fixes #10444
The UV-5G (aka UV-5X) GMRS radios are preset from the factory (and
after a RESET) with 30 GMRS channels and 11 NOAA WX radio channels.
The programmed channels are not firmware locked from being changed
or erased, TX is not firmware blocked for unsanctioned frequencies.
In respect to channel programming, they are essentially the same as
any common UV-5R (136-174 MHz & 400-520 MHz and TX/RX on all 128
channels).

This patch gives CHIRP the ability to match the radio's factory
provided programming capability.
2023-03-16 19:15:54 -07:00
Dan Smith
3a2585ad64 Attempt to catch illegal set_memory() behavior
It has become apparent that some radios are making changes to the
Memory during set_memory(). That is not technically harmful, but
may indicate an attempt to change something of what the user provided,
or to reflect changes back to the user which will never be seen.

For now, define a FrozenMemory object that just logs this problem and
use that when setting memories from the UI. In the future, this should
turn into an error.
2023-03-14 21:28:20 -07:00
Dan Smith
2fce6f97d9 Refactor the calculation of required steps
This makes required_step() consider the supported steps when deciding
what to return as required. If not provided, the original set of steps
is used. It also makes validate_memory() provide the radio's supported
list and better reproduces the underlying check's error message.

This allows us to handle radios that don't support 5.0kHz
steps, which is generally assumed to be a safe default. It also allows
calculation of required steps below 2.5 for some that were in use in
the tree already.

Related to #10439
2023-03-12 15:09:58 -07:00
Dan Smith
cbbc4bb59a Add Q-MAC HF-90 py3 test matrix entry
I forgot to make sure this got added.

Related to #10428
2023-03-10 20:46:55 -08:00
Jim Unroe
13ed060061 radtel_t18.py: add Retevis RB87 - fixes #10435 2023-03-10 20:08:52 -08:00
Dan Smith
5ad747a0bd Style cleanups for tests/ 2023-03-10 18:07:04 -08:00
Dan Smith
0f14ee5b12 Style cleanups for tests/unit 2023-03-10 18:07:04 -08:00
Dan Smith
069d715fcc Add a test for radio prompts
This just makes sure we can get prompts from radios that support them
and that they're strings.

This can be extended to make sure that all drivers expose prompts
that are marked for translation.
2023-03-10 15:48:15 -08:00
Finn Thain
b53f51e6a7 Add test matrix entries for Q-MAC HF-90 variants 2023-03-09 21:45:12 -08:00
Finn Thain
f4735b2923 Add test images for Q-MAC HF-90 2023-03-09 21:45:12 -08:00
Dan Smith
18295675ea Add SenhaiX 8800, Radioddity GS-5B and family
Started by Dave Liske, finished by me.

Fixes #7997
2023-03-06 15:48:12 -08:00
Jim Unroe
42703f36b9 Add BTECH MURS-V2 - fixes #10409 2023-03-02 14:52:53 -08:00
Kosta A
86bcdba2c4 Adds IC-V86 test image and fix failing tests. 2023-03-01 14:43:30 -08:00
Dan Smith
ab77d1b71c Fix Quansheng TG-UV2 for Python3
Fixes #10398
2023-02-28 15:04:19 -08:00
Dan Smith
79e500b7f1 Improve skip test to catch more things
Review of a driver recently shows that this test is too simplistic to
catch some issues. This also fixes a bug in the ftlx011 driver, where
deleted memories are never resurrect-able, as poked by this test.
2023-02-23 18:13:32 -08:00
Dan Smith
86180359b1 Improve TS480 tuning_step fix
This basically reverts the ts480 part of ba88b54f to restore its
ability to select the finer tuning_step values for modes like sideband.
It adds validate_memory() to reject the memories with invalid mode
and step combinations. This also changes get_mem() in the test base
class to march through the steps as it walks up the bands and memory
channels.
2023-02-23 16:01:43 -08:00
Dan Smith
ae46b10111 Add Yaesu FT-90 test image and fix bugs
This adds a test image and fixes several issues found by running our
tests against it.
2023-02-22 20:37:15 -08:00
Dan Smith
ba88b54f4a Make required_step find 10kHz before 5kHz
This makes our required_step() function find 10kHz as a suitable
tuning step before 5kHz because of one radio (ft90) that has a bug
related to 5kHz and thus does not support it.

This also makes us set the tuning_step of our test memory to the first
supported one, which may not be the default of 5kHz. The TS480 driver
does some monkeywork with the tuning_step that changes per mode, which
isn't really compatible with the tests or the UI, so this also
makes a change there to just keep things working. But, more attention
is needed there.
2023-02-22 20:37:15 -08:00
Dan Smith
7a5c76804d Fix Yaesu FT-90 for python3
This is not actually confirmed working yet, because the upload process
seems to depend on the previous patch for opening the port early.
However, the upload isn't raising python3 errors and the download
works, so I'm calling this reported working for python3 issues
until advised otherwise.

Fixes #10386
2023-02-22 20:37:15 -08:00
Dan Smith
1981209368 Stop using mock from external packages 2023-02-22 19:23:41 -08:00
Dan Smith
f0671e9e03 Migrate old mox-based tests to mock 2023-02-22 19:23:41 -08:00
Dan Smith
9419d5b298 Remove legacy platform serial enumeration
...and mox-based tests thereof.
2023-02-22 19:23:41 -08:00
Jim Unroe
e5658b2e05 Add Retevis RT15 - fixes #6855 2023-02-18 18:04:50 -08:00
Dan Smith
b8599c7cd1 Keep the radio mmap from setup in clone tests
Avoid having a mmap of all zeroes (and of the wrong size for our
memory) in the clone tests.
2023-02-17 18:32:44 -08:00
Dan Smith
6c5391d561 Try a test frequency from each valid band
This makes us walk all the valid_bands looking for a frequency within
to test with. This will allow drivers to expose multiple bands for
RX-only and TRX capabilities, even if they are adjacent.

Further, if a memory validates with only warnings, set and get the
memory on the radio to resolve any corrections it may need to enforce,
such as mandatory TX frequency corrections, TX inhibit, or anything
else.
2023-02-17 18:32:44 -08:00
Jim Unroe
c164fa78d8 Add Retevis RT86 - fixes #10377 2023-02-17 18:12:08 -08:00
Jim Unroe
2d02008226 Add Baojie BJ-218 to Python3 Driver Testing matrix 2023-02-16 16:54:59 -08:00
Dan Smith
8a10773fba Add IC-7100 as reported working 2023-02-16 14:58:46 -08:00
Dan Smith
cbfbf68a87 Add IC-V80 clone ranges and endframe
This comes from testing with an actual radio.

Fixes #174
2023-02-16 14:58:46 -08:00
Dan Smith
1bae4e7733 Add IC-V80 test image and fix tests 2023-02-16 14:58:46 -08:00
Jim Unroe
4b256843be Add BTech GMRS-50V2 - fixes #10374 2023-02-15 14:54:45 -08:00
Jim Unroe
f178e428d7 Add Retevis RB628 - fixes #10325 2023-02-10 15:03:12 -08:00
Jim Unroe
58f6c3c210 Add Retevis RB28 - fixes #10324 2023-02-09 19:00:07 -08:00
Mel Terechenok
50f8091a0b New Model Support- Wouxun KG-935G Plus
Fixes: #10355

Add support for Wouxun KG-935G Plus
2023-02-07 15:42:07 -08:00
Thomas Russell Murphy
7dadb9032d Update py3_driver_testers.txt 2023-02-04 14:43:27 -08:00
Jim Unroe
3048b71aaa Update baofeng_wp970i.py driver to use mem.immutable - #10288 2023-02-04 14:29:01 -08:00
Dan Smith
8c0720e542 Mark IC-746 as tested
Also fix some 2022->2023 errors I've made lately.

Fixes #10346
2023-02-03 16:03:03 -08:00
Jim Unroe
d8d0707f60 Update bf_t8.py driver to use mem.immutable (revisited) - #10288
Adds validate_memory() to notify user when Duplex is forced to
a particular value.
2023-02-03 16:03:03 -08:00
Dan Smith
8084170d46 Fix up tests.base.get_mem() for some radios
We were failing to delete mem.extra for radios that return memories
without an extra field even set, which caused us to not use the
first memory as a candidate. Also, don't refuse one of the virgin
memories if only warnings are raised from validate, and only use the
non-virgin one if it has immutable fields.
2023-02-03 16:03:03 -08:00
Dan Smith
0c9baf1e31 Fix TYT UVF8 for Python 3
Also add a test image and fix a bug found in the process.

Fixes: #10340
2023-02-03 14:58:28 -08:00
Dan Smith
1665671883 Add Kenwood TK-2140/3140 support
Fixes #10339
2023-02-02 15:36:37 -08:00
Dan Smith
bc51d1df72 Expand repeaterbook tests to another state
This increases the likelihood of catching an error, especially since
Oregon is the most likely to be tested.
2023-02-02 15:36:37 -08:00
Jim Unroe
3ae18ed754 Update uv5r.py driver to use mem.immutable - #10288 2023-02-01 17:06:43 -08:00