hmatuschek / qdmr

A GUI application for configuring and programming cheap DMR radios under Linux and MacOS X.
https://dm3mat.darc.de/qdmr/
GNU General Public License v3.0
223 stars 46 forks source link

D878UVII How can I load my own UserDB? #345

Closed hmatuschek closed 1 year ago

hmatuschek commented 1 year ago

Discussed in https://github.com/hmatuschek/qdmr/discussions/343

Originally posted by **swissalpsboy** June 18, 2023 Hello Hannes First of all, thanks for the great program! I use the original Anytone CPS in VirtualBox to write the code plug. I create the data (including UserDB) itself with Calc and then import it into the CPS. This works quite well. My problem is the UserDB. With my installation it takes about 6 hours until all entries are written. Your software does it much faster. Hi Is it possible to upload a self created UserDB? If so, what is its structure? Thanks and vy 73
hmatuschek commented 1 year ago

Within the GUI, I would like to keep the automatic user-db population for the sake of simplicity. I've added a command line option --database to the CLI dmrconf. So

> dmrconf write-db --database=YOUR_JSON_FILE 

should work.

The changes are in the cli-allow-for-userdb-file branch. If it works for you, I will merge it into master.

swissalpsboy commented 1 year ago

Thanks for the very fast implementation of the function. Despite error message the upload works fine:

/user/local/bin/dmrconf write-db --database kontakte_20230619.json

QCommandLineOption: Option names cannot be empty ERROR in lib/userdatabase.cc@82: Cannot open user list '/home/werner/.local/share/DM3MAT/dmrconf/user.json': No such file or directory Warning in cli/writecallsigndb.cc@56: No ID is specified, a more or less random set of call-signs will be used if the radio cannot hold the entire call-sign DB of 240488 entries. Specify your DMR ID with --id=YOUR_DMR_ID. dmrconf will then select those entries 'closest' to you. I.e., DMR IDs with the same prefix. [==================================================] 100%

hmatuschek commented 1 year ago

The 'QCommandLineOption' is my fault, the '/home/werner/.local/share/DM3MAT/dmrconf/user.json' is missing on the first start and gets downloaded. The warning is only relevant, if not all entries in you DB fit into the radio. I'll fix the first issue and then merge it into master.