Here is another experimental version, with changes from both Colin G4EML and I
This version sets the CC to the detected CC, because the DMR chip does not seem to decode the Talker Alias if CC set into the DMR chip is not the CC of the received signal.
I found that Colin's version was prone to leaving the CC on a different CC to the received signal, because at the end of transmissions there appears to be digital noise which is interpreted as a signal on a different CC.
This is especially bad on hotspots, but I also observed it even on my local repeater, which is a Motorola DR3000.
I think in the case of my local repeater, QSB probably caused the CC to be set incorrectly.
The version in this firmware, uses my algorithm which uses the most prevalent CC code.
My algorithm generates an internal histogram if the received CC (
https://en.wikipedia.org/wiki/Histogram ), and then uses the CC with the highest peak in the graph.
The histogram is only reset when the frequency is changes, which seems to result in a better "lock" onto the correct CC even on hotspots.
However, my algorithm can initially lock onto the wrong CC, for about 1 second, especially on hotspots, where I've noticed the beginning of the transmission can also include incorrect CC.
Anyway. Give this version a try and see if its better or worse.
PS. This version also includes 3 other PR's, from various contributors (who I will fully credit when I release the next "Latest" version)
1. Filter: option on FM allows the Rx CTCSS to be disabled, regardless of the CTCSS setting in the Channel or VFO
2. Improved handling of the audio amplifier enable and disable control, to hopefully remove the possibility of the amplifier being left enabled when there is no signal and no beep etc
3. Finnish language update