On 02/23/2015 02:47 PM, Patrick Lang wrote:
Can you elaborate a bit more on your plan? I have been thinking of how I could achieve batch transformations from a master CSV to get similar memory layouts between all my radios. Does this sound at all like what you have in mind?
That kind of functionality is on my agenda. I also want to be able to display/modify the radio settings in the radio images, not just the channel definitions.
To avoid confusion, I see manipulations of CSV files as outside the scope of a chirp CLI. Those files are already trivial to modify programmatically using sed, python, or other languages. I think the CLI should limit itself to importing/exporting CSV files from radio image files.
I was thinking of adding a way to parse model specific columns such as bank settings and priority scans at import as a first step. Hopefully from there I can use a shell script for transforming the CSV to each models bin or doing a convert and sync.
I am still a relatively newbie when it comes to CHIRP, so I don't know what capabilities that it already has in the code. That said, I personally expect the chirp CLI to become a general purpose tool that manipulates every possible aspect of radio image files. It should be implemented in a way that every action can be trivially scriptable (e.g. via bash).
In that paradigm, I think that the chirp CLI should only make "atomic" changes to an image. Complex transformations would be accomplished by running it as many times as needed with the proper options. Happily, this design goal should prevent it from suffering from feature creep.
It think it could be useful to encapsulate the resulting CLI engine. Then, other python scripts can reuse it directly to perform complex transformations in a single process. Again, some of this functionality may already exist; I'm still learning the code.