SDR with Alpha Tagging

Status
Not open for further replies.

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
Is there anyone that has been able to use a raspberry pi and get both the audio and alpha taging to work with uploading to Broadcastify?

I have my Pi receiveing the audio and able to send it to Broadcastify for my scanner channel, but can't find anything on how to send the alpha tags as well. Anyone had any luck with this?
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
Is there anyone that has been able to use a raspberry pi and get both the audio and alpha taging to work with uploading to Broadcastify?

I have my Pi receiveing the audio and able to send it to Broadcastify for my scanner channel, but can't find anything on how to send the alpha tags as well. Anyone had any luck with this?

op25 doesn't support sending tags at present, but I've been working on something that may change that in the near future. [I conducted a successful proof of concept test last night, now it needs to be re-written in a form that is configurable and suitable for deployment]

Keep an eye on this space over the next week or so.
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
I would be happy to do testing with instructions on how to get it going. I am very interested in getting the alpha tagging to work so that I can go away from my clunky scanner to the SDR direction mainly because I can use my Raspiberry Pi with a built in UPS rather than having to have a larger UPS to handle both the scanner and the Pi.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
I would be happy to do testing with instructions on how to get it going. I am very interested in getting the alpha tagging to work so that I can go away from my clunky scanner to the SDR direction mainly because I can use my Raspiberry Pi with a built in UPS rather than having to have a larger UPS to handle both the scanner and the Pi.

I'd be interested to hear opinions on what the alpha tag should contain? Candidates are:
-freq, slot, tgid, tag, nac, sysname, sysid, wacn
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
From looking at the scanner apps that I use on my phone (3 different ones) I think the only main things to have is the rabid and the tag. I think most people only really need or want to know what group is talking. This is very important for feeds like mine that cover an entire county with all emergencies services. My feed is for my local block watch group and that is what they are looking for from my feed. Another local feed doesn’t have that and that is why I started my feed.
 

NebraskaCoder

Member
Joined
Oct 26, 2016
Messages
325
Location
Omaha, NE
Talkgroup (label) and radio ID (or label). Or let user customize by using variables like %tgid% and let it be custom.

Sent from my SM-G965U using Tapatalk
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
I've pushed some changes that add basic meta tag support. It could probably get a lot better, but at least this is something that should prove if it's worthwhile going further.

Biggest issue right now seems to be broadcastify latency/lack of synchronization between metadata display and the audio playing, and unfortunately I don't think there's really anything I can do about it.

Wanna play? You'll need to do the following:

Add a "-M meta.json" to your rx.py command line options, where 'meta.json' is a json formatted text file containing your icecast server name, mount point and password.

There is an example meta.json file which you can copy and customize as needed.
Code:
{"icecastPass": "password", "icecastMountpoint": "mountpoint", "icecastServerAddress": "server.name:port"}
on my test server it looks like this:
Code:
{"icecastPass": "password", "icecastMountpoint": "op25", "icecastServerAddress": "192.168.1.24:8000"}

Please note that the formatting is somewhat picky and you cannot add comments. If the file barfs when it is read in there will be a log message but that's about it. If you want to experiment with contents of the metadata, look in rx.py at the meta_update() method.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
Note: to use this new metatags feature the "python-requests" module must be installed.
Code:
sudo apt-get install python-requests

I have updated the install.sh script.
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
So I added the -M meta.json and put the meta.json file in the op25/op25/gr-op25_repeater/apps folder.

This is my op25.sh command line to start the feed:./rx.py --args 'rtl' -N 'LNA:47' -M meta.json -S 250000 -f 855.8625e6 -o 17e3 -O loop0 -T trunk.tsv -V -2 -U 2> stderr-stream0.2

Here is what the meta.json file looks like using the info from broadcastify:( I did not post the password or mount point for obvious reasons but am doing the server address. Your server address looks like a local server though.
{"icecastPass": "my password", "icecastMountpoint": "my mount point", "icecastServerAddress": "audio9.broadcastify.com:80"}

am I missing something?
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
So I added the -M meta.json and put the meta.json file in the op25/op25/gr-op25_repeater/apps folder.

This is my op25.sh command line to start the feed:./rx.py --args 'rtl' -N 'LNA:47' -M meta.json -S 250000 -f 855.8625e6 -o 17e3 -O loop0 -T trunk.tsv -V -2 -U 2> stderr-stream0.2

Here is what the meta.json file looks like using the info from broadcastify:( I did not post the password or mount point for obvious reasons but am doing the server address. Your server address looks like a local server though.
{"icecastPass": "my password", "icecastMountpoint": "my mount point", "icecastServerAddress": "audio9.broadcastify.com:80"}

am I missing something?

Do you see any errors in the log?
e.g. "Error reading metadata config file: "
or "Icecast Update Error: "

You could add in an extra sys.stderr.write() line in icemeta.py around line 78 to have it print out when a successful message is sent.
e.g.
Code:
            else:
                self.last_metadata = metadata
                sys.stderr.write("Icecast Metadata: %s\n" % metadata)
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
What is interesting is that when I add -M meta.json the program does not start at all. When I remove the -M meta.json from the command line it starts fine.
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
I got it figured out. I had to start from scratch be the install.sh was not installing all the new stuff that was needed.

The display is a bit much to read though on my app when tagged but it is a start. You can look at my stream by searching for Ohio, Lake County, and it is the Eastlake, Willowick, (and so on) feed.
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
it is all working now. however I am not sure if there is anything that can be done, but the tagging is way off from the audio. basically makes is worthless. I know that Broadcastify has some latency issues, but with my Bearcat scanner it flows through fine with the tags and the audio at the same time.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
it is all working now. however I am not sure if there is anything that can be done, but the tagging is way off from the audio. basically makes is worthless. I know that Broadcastify has some latency issues, but with my Bearcat scanner it flows through fine with the tags and the audio at the same time.

The synchronization is way off for me too - my broadcastify stream's audio precedes the associated tags by a good couple seconds, if not longer.

At the source end, the tags are created and sent prior to the tuning taking place, then they reset to "{Idle]" right before tuning changes back to the control channel. Once tuned, the pcm audio streams out to darkice (which probably delays it a little more) but somehow the tags are still coming out later than the audio. Beats me how that can happen, but it's not a fault in the op25 code.
 

faff29

Member
Feed Provider
Joined
Jul 30, 2008
Messages
51
Location
Eastlake, OH
I’m not a programmer, but I wonder how the other system is built that pulls from my physical scanners data and puts it up at the same time.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
I’m not a programmer, but I wonder how the other system is built that pulls from my physical scanners data and puts it up at the same time.

Unless there is a different api then I can't explain it.
The way I'm doing it is to send the metadata over an http connection to the icecast server.
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,339
Location
Talbot Co, MD
Status
Not open for further replies.
Top