Commit graph

4835 commits

Author SHA1 Message Date
Dan Smith
37d8b94de2 Fix updating repeaterbook cache on windows
Apparently windows can't do atomic rename, which means we have to
remove and rename (and hope we don't fail in between).

Fixes #10479
2023-03-26 18:13:54 -07:00
Dan Smith
e6473aa729 Squelch warnings about "Windows bitmap file" 2023-03-21 17:05:01 -07:00
Dan Smith
a1a7db08d7 Fix including locale files in setup-based builds
We weren't including the locale files in the builds that get generated
from setup.py, so sdist, bdist_whl. Note that the include mechanics
seem to grab more than we want, so we need an extra exclude to avoid
bundling the source files, which aren't used at runtime.
2023-03-21 17:05:01 -07:00
Dan Smith
986ad4e94f Install desktop icon on linux 2023-03-21 17:05:01 -07:00
Mel Terechenok
f952e1f8fd Fix Power setting for factory CPS
clear bit5 for consistency with CPS
2023-03-21 16:34:18 -07:00
Mel Terechenok
7f16a8605a Correct Raw Memory Index
Correct index for displaying raw memory on Wouxun 9 series
2023-03-21 16:34:18 -07:00
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
Mel Terechenok
e592eff6bd Clean Up Wouxun 9 series mem valid checks
Replace multiple != checks with not in check
2023-03-20 15:59:38 -07:00
Mel Terechenok
f8b1a80d30 Update KG-UV9PX manual channel entry
Update driver to accept a newly found value as for a valid memory location.
2023-03-20 15:59:38 -07:00
Jim Unroe
44694d6702 Add Ruyage UV58Plus - fixes #10334 2023-03-18 18:23:35 -07:00
lunapiercook
33402b7c54 Remove "Language" option from SHX8800 family
Fixes #10456
2023-03-18 10:18:22 -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
Dan Smith
40cd6f64d3 Update tdh8 to stricter style standard 2023-03-18 09:21:38 -07:00
cong
9c348b180b New driver UV68 and TDH8
Fixes #10059
2023-03-18 09:21:38 -07:00
Dan Smith
44cab4d434 Convert ft4.py to stricter style standard
While I'm here working on it, convert ft4.py to pass the stricter
style rules.
2023-03-18 08:32:57 -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
Andrew Rodland
ab259b1958 Fix editing entries for TH-D74
Editing a memory in a D74 file in the GUI currently fails with a message
"no such attribute 'dv_urcall'", because every memory is created as a
DVMemory, but not every memory actually has the DV fields, and this
blows up in some serialization code.

Do like other drivers do and only create a DVMemory for DV memories.
Some of the number/extd_number was assigning to mem before we even
called _get_raw_memory (and therefore before we could tell whether the
mode is DV or not), so it had to be reorganized slightly.

Tested with my own D74.
2023-03-18 06:54:45 -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
c55eb23996 Baofeng BF-T1: Support new FM frequency storage method - fixes #10445 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
97d8af35ff Avoid confusing __( for _( in check_commit 2023-03-14 21:28:20 -07:00
Dan Smith
96b45ef6fe Fix invalid extd_number behavior in px888k
This driver was always setting extd_number, even for non-special
memories, which was incorrect, and confuses the UI.

Fixes #10446
2023-03-14 21:28:20 -07:00
Dan Smith
191240ab02 Add docstrings for get_memory() and set_memory()
It may not be exactly clear what each of these should be doing and
what the "rules" are for behavior, so add docstrings to (hopefully)
clarify.
2023-03-14 21:28:20 -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
Jim Unroe
5c9805e9f6 btech.py: add limit checking for most settings - fixes #10420 2023-03-14 14:49:22 -07:00
Dan Smith
df426d0e09 Make UI better handle default steps
This makes us only take the bandplan-provided default step if it is
one of those valid for the radio. If not, or no default step is noted,
we will attempt to find an appropriate step for the channel that is
supported by the radio (which may not be the default) and if none is
found, report the actually-required one to the user.

Fixes #10439
2023-03-12 15:09:58 -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
b1783d4035 Fix VX8 tuning_steps list
This driver wasn't properly exposing the right list of tuning steps,
as it copied the master list and modified it. That master list has
changed since, which makes it not work as intended anymore.

Related to #10439
2023-03-12 15:09:58 -07:00
Dan Smith
6041443ddd Correct a number of issues with tk760g
This driver has some serious quality issues, which get in the way of
an upcoming refactor concerning tuning steps. This patch:

1. Makes sure the valid_bands are integers
2. Fixes the obviously-incorrect double-condition check for memory
   emptiness. The _prep_data() method was certainly not calculating
   the correct (for the usage) upper bound on the memory channels,
   nor does doing that check really make any sense.
3. The get_memory() method should not be changing memory, but it was.
4. Fixes the use of floats with no decimal places.
2023-03-12 15:09:58 -07:00
Dan Smith
a6a0ff98a4 Avoid exporting specials to CSV
These don't have a conventional number anyway, likely have other
restrictions, and won't import correctly.

Fixes #10437
2023-03-11 12:59:53 -08:00
Abdullah YILMAZ
9b702aa8b8 Update tr_TR.po 2023-03-11 12:26:29 -08:00
Mel Terechenok
a3f8d5e845 Fix BCL-A and BCL-B writes for Wouxun KG935G and KG935G+
Fixes: #10436
Correct BCL-A and BCL-B writes so they no longer update the opposite setting.
2023-03-11 09:18:21 -08:00
Abdullah YILMAZ
42f10c425f Update turkish language 2023-03-11 09:16:42 -08:00
Dan Smith
5ba6da22eb Update locale files
No changes, just rebuild them for file locations.
2023-03-11 09:16:42 -08: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
Jim Unroe
d59f0ca655 radtel_t18.py: update syntax prior to adding Retevis RB87 2023-03-10 20:08:52 -08:00
Dan Smith
360d75e995 Add warning to top of cpep8.manifest 2023-03-10 18:07:04 -08:00
Dan Smith
8902b7b82a Move drivers with two errors to flake8 2023-03-10 18:07:04 -08:00
Dan Smith
9be9368e24 Move drivers with one error to flake8 2023-03-10 18:07:04 -08:00
Dan Smith
3074abacfb Fix some trivial flake8 fails on the blacklist 2023-03-10 18:07:04 -08:00
Dan Smith
fec7443b6b Fix flake8 errors in pyPEG 2023-03-10 18:07:04 -08:00
Dan Smith
3aedd76cd3 Fix flake8 errors in chirp_common 2023-03-10 18:07:04 -08:00
Dan Smith
cdc0c95bb9 Fix trivial chirp/ flake8 failures 2023-03-10 18:07:04 -08:00
Dan Smith
22cca139c2 Remove some old tools and orphaned files
bitdiff.py is from before we had GUI developer tools, and is not py3
  compliant anyway.
img2thd72.py is no longer useful now that the thd72 driver can open
  those files directly, and is not py3 compliant anyway.
elib_intl.py is something to do with internationalization on win32
  (it seems). Not sure if/when we ever used that, but we don't anymore
  and thus it is removed.
2023-03-10 18:07:04 -08:00
Dan Smith
9315b15a07 Remove old rfinder driver still in the tree 2023-03-10 18:07:04 -08:00
Dan Smith
2f5eb1503a Remove flake8-compliant files from cpep8
These files already adhere to the stricter rules, so keep them that
way.
2023-03-10 18:07:04 -08:00
Dan Smith
32e6548b61 Make flake8 default style linter for new files
This makes cpep8 run flake8 on anything *not* in the manifest or
*not* in the blacklist. Thus, all new files will get flake8 run against
them by default. It adds a bunch of files to the blacklist that were
not in manifest and thus still aren't compliant. Those need to get
cleaned up, obviously.

No new files should be added to cpep8.manifest going forward so that
the stricter flake8 rules get applied by default. Ideally we'd also
remove files from cpep8.manifest as well so we can move to just one
set of rules for everything, but that will take a while.
2023-03-10 18:07:04 -08:00
Dan Smith
94f09aad42 Fix style issues on some dist tooling 2023-03-10 18:07:04 -08:00