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
216 stars 45 forks source link

Open-GD77: Index issue with channel <-> contact & group lists. #27

Closed hmatuschek closed 3 years ago

hmatuschek commented 3 years ago

There appears to be an index issue with the association between the channel and the corresponding contact and group lists. They all appear to be off by one. I.e. the TX contact and RX group list of channel 2 gets associated with channel 1.

DC7IA commented 3 years ago

Not all of them are off by one, some are correct.

hmatuschek commented 3 years ago

Here is what I have written to the radio

Digital Name                Receive   Transmit  Power Scan TOT RO Admit  CC TS RxGL TxC GPS
1       "DB0LDS TS1"        439.56250 -7.60000  High  -    -   -  Color  1  1  1    -   -
2       "Sa/Th DB0LDS TS1"  439.56250 -7.60000  High  -    -   -  Color  1  1  3    8   -   # Sa/Th
3       "TG8 DB0LDS TS2"    439.56250 -7.60000  High  -    -   -  Color  1  2  2    5   -   # Regional
4       "TG9 DB0LDS TS2"    439.56250 -7.60000  High  1    -   -  Color  1  2  2    6   1   # Lokal
5       "BB DB0LDS TS2"     439.56250 -7.60000  High  1    -   -  Color  1  2  2    7   1   # Bln/Brb
6       "DM0TZN TS1"        438.82500 -7.60000  High  -    -   -  Color  1  1  1    -   -
7       "TG8 DM0TZN TS2"    438.82500 -7.60000  High  -    -   -  Color  1  2  2    5   -   # Regional
8       "TG9 DM0TZN TS2"    438.82500 -7.60000  High  -    -   -  Color  1  2  2    6   -   # Lokal
9       "BB DM0TZN TS2"     438.82500 -7.60000  High  -    -   -  Color  1  2  2    7   -   # Bln/Brb
10      "DB0LOS TS1"        438.47500 -7.60000  High  -    -   -  Color  1  1  1    -   -
11      "R/TG9 DB0LOS TS2"  438.47500 -7.60000  High  -    -   -  Color  1  2  2    6   -   # Lokal

and this is what I read back

Digital Name                Receive    Transmit   Power Scan TOT RO Admit  CC TS RxGL TxC GPS
1       "DB0LDS TS1"        439.56250  -7.60000   High  -    -   -  Color  1  1  3    8   -   # Sa/Th
2       "Sa/Th DB0LDS TS1"  439.56250  -7.60000   High  -    -   -  Color  1  1  2    5   -   # Regional
3       "TG8 DB0LDS TS2"    439.56250  -7.60000   High  1    -   -  Color  1  2  2    6   -   # Lokal
4       "TG9 DB0LDS TS2"    439.56250  -7.60000   High  1    -   -  Color  1  2  2    7   -   # Bln/Brb
5       "BB DB0LDS TS2"     439.56250  -7.60000   High  -    -   -  Color  1  2  1    -   -
6       "DM0TZN TS1"        438.82500  -7.60000   High  -    -   -  Color  1  1  2    5   -   # Regional
7       "TG8 DM0TZN TS2"    438.82500  -7.60000   High  -    -   -  Color  1  2  2    6   -   # Lokal
8       "TG9 DM0TZN TS2"    438.82500  -7.60000   High  -    -   -  Color  1  2  2    7   -   # Bln/Brb
9       "BB DM0TZN TS2"     438.82500  -7.60000   High  -    -   -  Color  1  2  1    -   -
10      "DB0LOS TS1"        438.47500  -7.60000   High  -    -   -  Color  1  1  2    6   -   # Lokal
11      "R/TG9 DB0LOS TS2"  438.47500  -7.60000   High  -    -   -  Color  1  2  2    6   -   # Lokal

This appears to be exactly off by one.

DC7IA commented 3 years ago

I have one channels that is correct:

grafik

Hotspot should be "Favourite TGs", which is correct.

DC7IA commented 3 years ago

Oh, that is because they are off by one. :D

hmatuschek commented 3 years ago

I found the issue: There was an index-off-by-one error in the linking code. This affected almost all radios. That is, RD-5R, GD77 and OpenGD77. This should be fixed with commit cd05dcd6d52628e278a098f8c2198416aafa0501.

DC7IA commented 3 years ago

Can confirm.

DC7IA commented 3 years ago

Since I don't use Scan Lists (yet), qdmr is now fully usable for me. :D

Thank you!

hmatuschek commented 3 years ago

Ok, perfect. I'll close this issue then. Can you create a scanlist, upload the codeplug to the radio using the "official" CPS and download it as a binary codeplug using dmrconf? I have no means to generate a proper codeplug here. This way I can find where within the binary codeplug the scanlists are stored. Ideally, you may create two different scanlists. (So I can infer the size)

DC7IA commented 3 years ago

I will have a look.

DC7IA commented 3 years ago

The OpenGD77CPS does not have scan lists, since OpenGD77 does not support them:

Scan Lists are not supported because Channel or Zone scan feature provides almost identical functionality.

https://github.com/rogerclarkmelbourne/OpenGD77/blob/master/docs/OpenGD77_User_Guide.md#codeplug-compatibility

Just remove it and done. :D

hmatuschek commented 3 years ago

I'll remove it from OpenGD77, however. The OpenGD77 code-plug is almost identical to the original GD77 code-plug. Hence, if there is an issue here, that it will affect at least the original GD77 scan list. Anyway, I already found everything that went wrong.

Although no scan list is enabled in your binary code-plug, there are 3 example scan-lists defined. I'll use them as templates to infer everything.