• Effective immediately we will be deleting, without notice, any negative threads or posts that deal with the use of encryption and streaming of scanner audio.

    We've noticed a huge increase in rants and negative posts that revolve around agencies going to encryption due to the broadcasting of scanner audio on the internet. It's now worn out and continues to be the same recycled rants. These rants hijack the threads and derail the conversation. They no longer have a place anywhere on this forum other than in the designated threads in the Rants forum in the Tavern.

    If you violate these guidelines your post will be deleted without notice and an infraction will be issued. We are not against discussion of this issue. You just need to do it in the right place. For example:
    https://forums.radioreference.com/rants/224104-official-thread-live-audio-feeds-scanners-wait-encryption.html

OP25: How To Configure cfg.json File To Listen To DMR

Joined
Feb 14, 2008
Messages
1,906
#1
I have a local DMR frequency of 460.8500 MHz that I wanna listen to on OP25, but I'm not getting any audio out the computer speaker. This is using VMWare with Ubuntu inside Windows 7. I made a copy of the cfg.json file and called it cfgcopy.json, so, I can experiment and still keep the original cfg.json file. When I run the following command, I get a screen plus 3 graphs that it won't let you close out:

./multi_rx.py -c cfgcopy.json

Here is the screen:



Here's what I've inside the cfgcopy.json file:

Code:
{
    "channels": [
        {
            "demod_type": "cqpsk",
            "destination": "udp://127.0.0.1:56120",
            "excess_bw": 0.2,
            "filter_type": "rc",
            "frequency": 460850000,
            "if_rate": 24000,
            "name": "p25",
            "plot": "symbol",
            "symbol_rate": 4800
        },
        {
            "demod_type": "fsk4",
            "destination": "file:///tmp/out1.raw",
            "excess_bw": 0.2,
            "filter_type": "rrc",
            "frequency": 460850000,
            "if_rate": 24000,
            "name": "ysf",
            "plot": "datascope",
            "symbol_rate": 4800
        },
        {
            "demod_type": "fsk4",
            "destination": "udp://127.0.0.1:56122",
            "excess_bw": 0.2,
            "filter_type": "rrc",
            "frequency": 460850000,
            "if_rate": 24000,
            "name": "dmr",
            "plot": "symbol",
            "symbol_rate": 4800
        }
    ],
    "devices": [
        {
            "args": "airspy",
            "frequency": 460850000,
            "gains": "LNA:15,MIX:15,IF:15",
            "name": "airspy",
            "offset": 0,
            "ppm": 38,
            "rate": 3000000,
            "tunable": false
        }
    ]
}
So, any idea what I'm doing wrong and how come I get no audio (even though I can hear people talking on the scanner)?
 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#2
When you are using multi_rx.py there is no equivalent to the -U parameter used by rx.py to turn on the audio player. You are going to have to do that yourself in a second terminal window, and how you do it will depend which version of the op25 repo you are using.

boatbod:
./audio.py -u 56120
or
./audio.py -u 56122

max/osmocom:
nc -kluvw 1 127.0.0.1 56120 | aplay -c1 -f S16_LE -r 8000
or
nc -kluvw 1 127.0.0.1 56122 | aplay -c1 -f S16_LE -r 8000
 
Joined
Feb 14, 2008
Messages
1,906
#3
Thanks. I'm using the "boatbod" version (I'm not sure what "repo" means, though). So If I wanna listen to both slots at the same time, do we hafta use 2 additional terminal windows for a total of 3? And, is there anyway to close out of the pop-up graphs? When you click on the 'X', they just come right back.
 
Joined
Feb 14, 2008
Messages
1,906
#4
Well, the readme says to add 2 for slot 2, so I been tryin both ./audio.py -u 56122 and ./audio.py -u 56124, but still don't hear anything.
 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#5
Well, the readme says to add 2 for slot 2, so I been tryin both ./audio.py -u 56122 and ./audio.py -u 56124, but still don't hear anything.
So... boatbod version you should be able to use "./audio.py -2 -u 56120" and this will attempt to play both slots (udp port 56120 and 56122) but the catch is that one plays in the left channel and the other plays in the right channel of the stereo audio :)

If you want two channels on independent audio devices you'd have to run two instances of ./audio.py (without the -2) and set the -u port# appropriately.

gnuplot graphs on multi_rx.py can only be turned on/off from the command line (which means not in real-time, unlike rx.py).
 
Joined
Feb 14, 2008
Messages
1,906
#6
Am I allowed to shorten the code like this if I just wanna listen to only 1 DMR frequency:

Code:
{
    "channels": [
        {
            "demod_type": "fsk4",
            "destination": "udp://127.0.0.1:56122",
            "excess_bw": 0.2,
            "filter_type": "rrc",
            "frequency": 461487500,
            "if_rate": 24000,
            "name": "dmr",
            "plot": "symbol",
            "symbol_rate": 4800
        }
    ],
    "devices": [
        {
            "args": "airspy",
            "frequency": 461487500,
            "gains": "LNA:15,MIX:15,IF:15",
            "name": "airspy",
            "offset": 0,
            "ppm": 38,
            "rate": 3000000,
            "tunable": false
        }
    ]
}
 
Joined
Apr 8, 2003
Messages
114
Location
Green Bay, WI
#9
Am I allowed to shorten the code like this if I just wanna listen to only 1 DMR frequency:
<snip>
That should work. I have used a chopped down json file like that and it worked for me.

As mentioned, you might need to adjust your PPM.

It would be great if there was a way to white/black list group id's (aka: talkgroups)
 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#10
That should work. I have used a chopped down json file like that and it worked for me.

As mentioned, you might need to adjust your PPM.

It would be great if there was a way to white/black list group id's (aka: talkgroups)
DMR (and other non-P25 protocols) don't have any trunking or protocol handling logic built in to op25 so whitelist/blacklist isn't currently possible.
 
Joined
Feb 14, 2008
Messages
1,906
#11
I have OP25 working great on P25 trunking systems with good audio. Here's a screenshot of what the graph looked like during a DMR voice transmission that came through on the scanner:



And here's screenshots of the 2 terminal windows:



 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#12
The random constellation plot says you're not receiving a signal. Either there isn't one being transmitted at the moment you did the screen capture, or your frequency is incorrect. Ideally you are looking for a diagram with tight clusters of X's in four corners of a square.
 
Joined
Feb 14, 2008
Messages
1,906
#13
I've been trying a couple different active local DMR frequencies and can hearem on the scanner. Hopefully I've got the code formatted with the right syntax? If the frequency is 461.4875 MHz, then does this look right?

Code:
{
    "channels": [
        {
            "demod_type": "fsk4",
            "destination": "udp://127.0.0.1:56122",
            "excess_bw": 0.2,
            "filter_type": "rrc",
            "frequency": 461487500,
            "if_rate": 24000,
            "name": "dmr",
            "plot": "symbol",
            "symbol_rate": 4800
        }
    ],
    "devices": [
        {
            "args": "airspy",
            "frequency": 461487500,
            "gains": "LNA:15,MIX:15,IF:15",
            "name": "airspy",
            "offset": 0,
            "ppm": 38,
            "rate": 3000000,
            "tunable": false
        }
    ]
}
 
Joined
Feb 14, 2008
Messages
1,906
#14
The ReadMe file says: "Note: DMR audio for the second time slot is sent on the specified port number plus two. In the example 'udp://127.0.0.1:56122', audio for the first slot would use 56122; and 56124 for the second."

But ./audio.py -2 -u 56120 is the right command to get audio out the speaker? And I'm wondering if the "destination": "udp://127.0.0.1:56122" part should only have single quotes, since the ReadMe file shows it as 'udp://127.0.0.1:56122' with only single quotes.
 
Joined
Feb 14, 2008
Messages
1,906
#15
Well I just tried a different DMR frequency that has a stronger signal and am now getting audio! It's broken up, but at least it's doing something now. So maybe it's a signal strength issue and OP25 needs a good strong signal for DMR. For P25, it does pretty decent on weaker signals. The .json file has a couple parameters in it that aren't in the ReadMe doc. And I'm not sure what "PCM underrun" means:



Is there any way to tune different frequencies without having to go in and out of the .json file?
 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#16
Well I just tried a different DMR frequency that has a stronger signal and am now getting audio! It's broken up, but at least it's doing something now. So maybe it's a signal strength issue and OP25 needs a good strong signal for DMR. For P25, it does pretty decent on weaker signals. The .json file has a couple parameters in it that aren't in the ReadMe doc. And I'm not sure what "PCM underrun" means:

Is there any way to tune different frequencies without having to go in and out of the .json file?
PCM underrun means the audio stream stopped coming out of op25 but the PCM (alsa) subsystem expected it to continue. For the most part you can ignore these warnings if they are occasional. If they happen frequently and are accompanied by glitchy audio, it points to signal strength or tuning issues, or hardware with too low a spec.

I'm not aware of a way to retune multi_rx.py on-the-fly, but then I have never personally used it. Perhaps Max (or Matt) can give a better answer with respect to how they anticipate this to evolve over time.
 
Joined
Apr 8, 2003
Messages
114
Location
Green Bay, WI
#17
Has anyone been able to get multi_rx.py to display DMR talkgroup/group address ID's? (Kind of a shame there isn't a wireshark dump option for this like with op25, I'd like to think I could sniff the group ID out that way.)
 
Last edited:

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#18
Has anyone been able to get multi_rx.py to display DMR talkgroup/group address ID's? (Kind of a shame there isn't a wireshark dump option for this like with op25, I'd like to think I could sniff the group ID out that way.)
A terminal hasn't been implemented yet for multi_rx - it's on my todo: list but life has been getting in the way.
In the interim, you can turn the logging up to level 10 and see the info in the protocol logged to stderr.2 in the DSTADDR and SRCADDR parameters.
 

boatbod

Member
Premium Subscriber
Joined
Mar 3, 2007
Messages
1,615
Location
Talbot Co, MD
#20
Thanks, hadn't tried logging set that high
For both rx.py and multi_rx.py the protocol is generally logged at level 10. That said, not all protocols are equally decoded/logged; P25 and DMR probably have the best support at present while DSTAR and YSF the least.
 
Top