OP25 Op25 alpha tag format question?

Status
Not open for further replies.

jrs2ua4

Member
Joined
Mar 9, 2019
Messages
9
I've been running 2 streams to broadcastify for about a year and a half now without any major issues. I was just curious if it is possible to change how my alpha tags show up? There's two things specifically I'm wondering about, and I've pointed them out in the attached pictures. Is it possible to not have the TGID preceding the alpha tag? Like in the first picture, do away with the [19003] and just have "TPD Team2" show as the alpha tag? Also, is it possible to stop it from showing [idle] when there's no activity on the feed as shown in the second picture? I've seen feeds with both of these things gone, but I wasn't sure if it was possible when using Op25? It's not that big of a deal, I was just curious if it was something that could be tweaked. Thanks!
IMG_2345.PNGIMG_2346.PNG
 

nick0909

Antenna flicker
Feed Provider
Joined
Jan 4, 2003
Messages
117
Yes, but you have to edit rx.py

Search that file for 'idle' and you will see where it is. Right now it is line 493.
You can change the [idle] to whatever you want, I changed mine to [scanning...]

Then a few lines below that is where it builds the string for the talkgroup name. I changed mine from
Code:
        if tag is not None:
            metadata += " " + tag
to

Code:
        if tag is not None:
            metadata = tag
Just get rid of the += and space and just use a regular = which just drops the TGID number if the name is known. This will get wiped out if you update OP25 and you will have to make the changes again. I have considered trying to write an update that lets you set this via config option and see if they want to merge it in but haven't gotten around to it yet.
 

jrs2ua4

Member
Joined
Mar 9, 2019
Messages
9
Thanks for the help! I thought it was possible to change, but I wasn't sure what code to change. That did the trick though.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
2,953
Location
Talbot Co, MD
Old thread revival...
I made some changes to support customization of the metadata formats. These are presently only available in the boatbod repo's "dev" branch, but assuming they run for a while I'll promote them to the main line in due course.

A brief description can be found in ~/op25/op25/gr-op25_repeater/appsREADME-metadata as follows:
Code:
OP25 supports sending of metadata updates to an icecast streaming server.
Configuration depends on which variant of op25 you are running; rx.py or multi_rx.py

rx.py
-----
Make a local copy of meta.json (e.g. cp meta.json my_meta.json) and edit it so that it matches your
streaming server mount point and password

    {
        "icecastPass": "password",
        "icecastMountpoint": "mountpoint",
        "icecastServerAddress": "server.name:port",
        "delay": "0.0", "icecastMountExt": ".m3u",
        "meta_format_idle": "[idle]",
        "meta_format_tgid": "[%TGID%]",
        "meta_format_tag":  "[%TGID%] %TAG%"
    }

Add the "-M my_meta.json" command line option to rx.py

multi_rx.py
-----------
Metadata information is entered in the "metadata" section of the main cfg.json configuration file.
Format and content is the same as used by rx.py

Metatag Format
--------------
The user has some control over the format of the metadata presented to the streaming server. The following
pieces of information are available:
    %TGID% - numeric talkgroup id
    %TAG%  - descriptive talkgroup string (from tgid-tags.tsv file)

By modifying the content of the meta_format_* parameters you can customize the text for the three typical
use cases.
    meta_format_idle - sent when op25 is idle/waiting for a call
    meta_format_tgid - sent during a call when only the tgid is known
    meta_format_tag  - sent during a call when both tgid and tag are known
%TGID% and %TAG% will be substituted with the in-call data at runtime
 

jrs2ua4

Member
Joined
Mar 9, 2019
Messages
9
I' trying to switch from rx.py to multi_rx.py and I have a similar question regarding metadata format. If I want to change the metadata format in multi_rx.py do I just add the metadata format lines from my meta.json file I used for rx.py under the "metadata" section in my cfg.json?
For example, the lines from my meta.json are:

"meta_format_idle": "Scanning...",
"meta_format_tgid": "[%TGID%]",
"meta_format_tag": "%TAG%"

Would I just add this under "metadata" section of my cfg.json? Or should I just change it in icemeta.py?
 

boatbod

Member
Joined
Mar 3, 2007
Messages
2,953
Location
Talbot Co, MD
I' trying to switch from rx.py to multi_rx.py and I have a similar question regarding metadata format. If I want to change the metadata format in multi_rx.py do I just add the metadata format lines from my meta.json file I used for rx.py under the "metadata" section in my cfg.json?
For example, the lines from my meta.json are:

"meta_format_idle": "Scanning...",
"meta_format_tgid": "[%TGID%]",
"meta_format_tag": "%TAG%"

Would I just add this under "metadata" section of my cfg.json? Or should I just change it in icemeta.py?
You just edit the parameter values in each of the metadata streams. You might look at the "p25_rtl_example.json" file for where these parameters are located relative to the meta stream instance name.
 
Status
Not open for further replies.
Top