This moves chirpc into a package called chirp.cli and makes setup.py
install it as a binary. This will make it available to people that
install the package and also makes it possible to add tests.
Tangentially related to #10263
The API for the memory channel object has changed, and so now `chirpc`
references attributes that no longer exist. The following commit has
only been tested using "TEnc" (Tone Encode) mode, but should at least
allow restoration of basic repeater manipulation functionality.
Fixes: #10263.
This looks like a lot of change, but it was pretty trivial. Many
of the conflicts came from d40963b3ed
which fixed a bunch of typos. There were some test adapter changes,
some GTK UI fixes, RR canada additions, and the usual driver
maintenance.
I didn't test the GTK UI since it seems like we're abandoning keeping
that working in python2 or python3 with pygobject (which is fine).
Icom radio detection has been broken for a long time, because the
detection code is expecting to be passed a radio instance, but is
being passed a serial port instead. Since we are trying to determine
the model, we don't have the relevant class yet. Instead, create a
minimal radio instance to allow us to query for the model.
These changes fix both the 'Detect' option in the 'Download From
Radio' menu and the 'chirpc --id' command.
Fixes#7905
Icom radio detection has been broken for a long time, because the
detection code is expecting to be passed a radio instance, but is
being passed a serial port instead. Since we are trying to determine
the model, we don't have the relevant class yet. Instead, create a
minimal radio instance to allow us to query for the model.
These changes fix both the 'Detect' option in the 'Download From
Radio' menu and the 'chirpc --id' command.
Fixes#7905
Add to chirpc the capability to list special channels if any
The string memory representation have been changed to print the extd_number when
present instead of number
Improves #2343
This patch makes the memory options more robust to a bad memory number
argument and some other exceptions. It also fixes a bug that prevented
setting an empty channel. Finally, it avoids overwriting the image file
when performaning a memory query.
This patch allows the CLI to print out the entire list of memories.
If --verbose is given, it displays empty slots too; otherwise, only
non-empty memories are displayed.
This patch groups the memory/channel modification options into an
argument group, making the --help text easier to digest. It also
eliminates redundant arguments to the relevant add_argument calls,
since those lines are being touched anyway.
This patch adds much-needed checks in the CLI, allowing an unwitting
user to stumble their way toward a working set of options that permits
downloading/uploading an image from/to a radio.
CHIRP now supports enough devices that the chirp/ directory has become
cluttered. This creates unnecessary coupling when importing all of
these modules. This patch moves all of the drivers to their own
directory and then chases down all of the stale import references.
This patch addresses some issues with the chirp.logger module in order
to use it in chirpc and chirpw. It prints the version string when
logging at DEBUG level.
In addition, it embraces and extends the "debug.log" support that was
present in chirpw, ensuring all log messages and output end up in that
file when running on Win32 or MacOS hosts. It also allows that feature
to be tested on Linux by setting CHIRP_DEBUG_LOG in the environment.
This patch adds the chirp.logger module, using it in chirpc and chirpw.
It adds a handful of optional command line arguments to control the new
logging features. In addition, CHIRP_DEBUG, CHIRP_LOG, and
CHIRP_LOG_LEVEL can be used to control the logging features from the
environment.
It also makes the version string reusable between the GUI and CLI, and
it prints that string at the start of the log file (if in use).
The optparse module is deprecated, so this patch converts chirpc to use
the argparse module. This allows chirpc and chirpw to share argument
parsing code.