RadioReference on Facebook   RadioReference on Twitter   RadioReference Blog
 

Go Back   The RadioReference.com Forums > Computer Aided Monitoring and Programming > Streaming / Broadcasting / Audio Recording

Streaming / Broadcasting / Audio Recording Interested in putting your scanner online for others to hear? Want to listen to other radios on the internet. This forum is here for you to discuss these topics related to streaming scanners online.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #21 (permalink)  
Old 10-21-2013, 11:39 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default Using Python to Update Icecast Scanner Audio Feeds with a Raspberry Pi

You're welcome. Glad you got it working!
Reply With Quote
Sponsored links
  #22 (permalink)  
Old 02-18-2014, 7:28 PM
Member
  Premium Subscriber
Premium Subscriber
 
Join Date: Feb 2011
Posts: 6
Default

Any chance I could persuade you to get this working on the bcd536hp? Also, can you modify it to display the radio identifiers as well?
Reply With Quote
  #23 (permalink)  
Old 02-18-2014, 10:38 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

Sure. It would be a great functionality to add. I'm glad you suggested it. I might need your help to develop/test it since I don't have either of the new units. The first thing I'll have to find out is if UPMan has published the serial comm protocol on his website as he's done for the other models. Once I figure out what commands the new models use, then we can easily modify/create a version of the Python script to support them.

As for radio IDs, we should be able to add that to the display, as long as it's one of the items of data returned via the serial queries. The data is customizable by the user to modify order, length, etc of items displayed.
Reply With Quote
  #24 (permalink)  
Old 02-18-2014, 11:02 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

I just checked the Uniden wiki and can't see the serial protocol listed for the 536 yet. If anyone knows if/when and where this might be published, let me know. You could try the 996XT Python script and see if it works. From the 536 manual It looks like from the serial port uses 4800 baud, so you might start there. You'll also probably need a null modem also. I don't know if the USB connection will work with the Raspberry Pi. It looks like there's an .inf driver file needed, so probably that would preclude it's use with the RPi, unless someone can write a linux driver for it. So if the serial port can be used like in older models and we can get the comm protocol, then we should be able to make it work.
Reply With Quote
  #25 (permalink)  
Old 02-19-2014, 2:48 PM
Member
  Premium Subscriber
Premium Subscriber
 
Join Date: Feb 2011
Posts: 6
Default

I'm probably in over my head, but I will do what I can to help.
Reply With Quote
Sponsored links
  #26 (permalink)  
Old 02-19-2014, 2:55 PM
Member
  Premium Subscriber
Premium Subscriber
 
Join Date: Feb 2011
Posts: 6
Default

Does this help answer any of your questions?

http://forums.radioreference.com/uni...ml#post2128386
Reply With Quote
  #27 (permalink)  
Old 02-22-2014, 6:13 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default Using Python to Update Icecast Scanner Audio Feeds with a Raspberry Pi

From looking around other threads it looks like the serial commands are the same as the 996XT in terms of getting the talkgroup info. If the serial/GPS jack really does provide serial data, then you should be able to use the existing 996XT script I already wrote along with a serial cable, null modem and USB to serial adapter and get the data into your raspberry pi.
Reply With Quote
  #28 (permalink)  
Old 02-22-2014, 11:52 PM
frazpo's Avatar
Member
  Shack Photos
Shack photos
Premium Subscriber
Premium Subscriber
 
Join Date: Jan 2007
Posts: 674
Default

Quote:
Originally Posted by Uplink View Post
Gordon's Scanner Radio app too!
What is this?? Have I missed something?
Reply With Quote
  #29 (permalink)  
Old 02-23-2014, 9:32 AM
Member
  Premium Subscriber
Premium Subscriber
 
Join Date: Feb 2011
Posts: 6
Default

Do you know of any easy way to determine if the serial port is providing serial data with my windows pc? I am afraid if it does not work I won't have enough knowledge of the subject to determine if it is really not transmitting serial data or if I have done something else wrong. I am actually currently broadcasting on my 996xt, so maybe I will get the script running on that first to eliminate some possibility of other errors. My 536 will be headed back to Uniden soon for the recall, maybe it should just make a stop at your house on the way...
Reply With Quote
Sponsored links
        
  #30 (permalink)  
Old 02-23-2014, 11:20 AM
frazpo's Avatar
Member
  Shack Photos
Shack photos
Premium Subscriber
Premium Subscriber
 
Join Date: Jan 2007
Posts: 674
Default

Quote:
Originally Posted by H2orescue View Post
Do you know of any easy way to determine if the serial port is providing serial data with my windows pc? I am afraid if it does not work I won't have enough knowledge of the subject to determine if it is really not transmitting serial data or if I have done something else wrong. I am actually currently broadcasting on my 996xt, so maybe I will get the script running on that first to eliminate some possibility of other errors. My 536 will be headed back to Uniden soon for the recall, maybe it should just make a stop at your house on the way...
If you are simply trying to confirm serial data to the computer from the scanner you can use hyperterminal in windows. I am using a 396xt so I can only assume the 436 is similar. Set the C-Ch output on scanner and <hold> on a trunked system. Set hyperterminal to 8-n-1 and the flow control xon - xoff. You should see data flashing and the system type in the terminal window.
Reply With Quote
  #31 (permalink)  
Old 04-08-2014, 11:48 PM
Member
  Audio Feed Provider
Audio Feed Provider
 
Join Date: Mar 2009
Location: Minneapolis, Ks
Posts: 7
Default BC780XLT

Has anyone got this to work with the 780XLT? I got the MetaPy8.py script working well with it, but I'd like to have the full alpha tag functionality, and I never got the MetaPy.py script working with the 780.

It doesn't seem to like my .csv file either, as it has made no difference on what shows up on the player.

Thanks,
Justin
Reply With Quote
  #32 (permalink)  
Old 08-24-2014, 10:32 PM
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Oct 2012
Location: Jackson, Wyoming
Posts: 9
Question My Own Web Page

Hello, and thank you for all of your work. Not sure I have a clear understanding about the internet side of this, for the end user. Can the information from a BCD 996XT be displayed on my own web page along with the audio? I don't really want to use it on a public site.

Mick - W7CAT
Reply With Quote
  #33 (permalink)  
Old 08-25-2014, 12:49 AM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

Sure. You can display the metadata on your own website if you wish. You would have to have your own Icecast2 server setup. The Python script takes the alpha tag info from the scanner and sends it to an Icecast2 server which sends the metadata to the listener along with the audio. If you have a personal feed/website it should work just fine. You just have to enter in the server info in the configuration area of the script and you're good to go.

I do this for my own personal feeds (that way I can listen across the house or with my phone when I'm not at home.) The audio player would also need to support showing metadata from the Icecast stream. There are lots of programs that do this such as Winamp and lots of apps for phones, etc.

Hope that helps. Let me know if I can help you get it working.
-Brandon
Reply With Quote
  #34 (permalink)  
Old 08-25-2014, 9:18 PM
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Oct 2012
Location: Jackson, Wyoming
Posts: 9
Default

Hello Brandon, thank you for the information and I'm sure I'll need some help getting it all set up. I have an older interface that I used for IRLP that will help with this. It will give me the power supply for the Pi and also an RS232 connection. What I am lacking and will need to find out what to get, is a USB wireless device for the Pi. This setup will be at a friend's house and wireless is my only way to get internet. He also is using WPA2 so not sure how much of a hassle that is going to be. Hopefully when it is all done I can use WinSCP to get into it when and if I need to, shouldn't need in much I hope.

Mick - W7CAT
Reply With Quote
  #35 (permalink)  
Old 08-27-2014, 2:17 PM
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Oct 2012
Location: Jackson, Wyoming
Posts: 9
Question

Just wondering about hooking up a BCD996XT to a computer. I have read where the neither side of the speaker should be grounded (seems like a poor design for a mobile radio). It seems to me like connecting a RS232 cable to a computer along with an audio cable from the speaker jack of the BCD996XT to the computer input jack, would be grounding the one side of the speaker. Is my thinking wrong here?
Reply With Quote
Sponsored links
  #36 (permalink)  
Old 08-27-2014, 11:03 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

I think it's possible to have grounding issues when the serial is connected. I've had some audio bleed through in the past from multiple scanners connected to a single computer or a Raspberry Pi. If it's only one scanner I think you will be fine. You can always try a ground isolator in the audio chain if you're having issues.
Reply With Quote
  #37 (permalink)  
Old 12-21-2014, 2:36 AM
Member
  Audio Feed Provider
Audio Feed Provider
 
Join Date: Jul 2009
Location: West Seneca, NY
Posts: 3
Default Radio Shack Pro-2052

Brandon -

First off, thanks for the excellent work - I've been looking for something like this for a long time and just stumbled upon it. I took a look at your metaPy8.py script and think it would work with my Pro-2052. I'm going to fire up a virtual machine and see if I can read the port, but if I can't what information would you need to be able to make it work with the Pro-2052?

Joe
Reply With Quote
  #38 (permalink)  
Old 12-26-2014, 12:01 AM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

Hi Joe. Newer RS models won't work because they need RS's proprietary USB adapter which requires a driver that doesn't exist for Linux. But in looking at the owner's manual it looks like the 2052 just uses serial comms, so it should work.

It does use slightly different codes to query the scanner about frequency info. Not very hard to change the Python script to handle that. Unfortunately I don't have a 2052 to debug with. Particularly I'd need to see the response from the scanner to a query so we could parse the data correctly. I'd be happy to point you in the right direction to see if you could get it working. I'll have to see if I can get ahold of one.
Brandon
Reply With Quote
  #39 (permalink)  
Old 12-28-2014, 12:04 PM
Member
  Audio Feed Provider
Audio Feed Provider
 
Join Date: Jul 2009
Location: West Seneca, NY
Posts: 3
Default

Quote:
Originally Posted by bbrasmussen View Post
Hi Joe. Newer RS models won't work because they need RS's proprietary USB adapter which requires a driver that doesn't exist for Linux. But in looking at the owner's manual it looks like the 2052 just uses serial comms, so it should work.

It does use slightly different codes to query the scanner about frequency info. Not very hard to change the Python script to handle that. Unfortunately I don't have a 2052 to debug with. Particularly I'd need to see the response from the scanner to a query so we could parse the data correctly. I'd be happy to point you in the right direction to see if you could get it working. I'll have to see if I can get ahold of one.
Brandon
Brandon -

I've made some progress since my original post. I have reached out to another software creator that does metadata parsing for a Windows app and asked what he was sending to get the frequency data.

So if I do the following:

Code:
WI \r
I get the following back:

Code:
W101 F04540875
So with that information I've been able to parse the raw serial data using:
Code:
freq = serBuffer[7:10] + '.' + serBuffer[10:14]
print(freq)
I guess the biggest thing that I'd like to do is plug this into your parser code, Also I was curious as how you the calling of the CSV file with the channel names works. I know that you put the csvFile variable in the head of the script, but how does it know to look up the frequency there (using the metaPy8.py as my base). You'll have to forgive me, I'm a relatively new programmer.

Thanks.
Joe
Reply With Quote
  #40 (permalink)  
Old 12-31-2014, 4:09 PM
bbrasmussen's Avatar
Member
  Amateur Radio Operator
Amateur Radio
 
Join Date: Dec 2007
Location: Woods Cross, UT
Posts: 132
Default

Quote:
Originally Posted by JWFoxJr View Post
Brandon -

I've made some progress since my original post. I have reached out to another software creator that does metadata parsing for a Windows app and asked what he was sending to get the frequency data.

So if I do the following:

Code:
WI \r
I get the following back:

Code:
W101 F04540875
So with that information I've been able to parse the raw serial data using:
Code:
freq = serBuffer[7:10] + '.' + serBuffer[10:14]
print(freq)
I guess the biggest thing that I'd like to do is plug this into your parser code, Also I was curious as how you the calling of the CSV file with the channel names works. I know that you put the csvFile variable in the head of the script, but how does it know to look up the frequency there (using the metaPy8.py as my base). You'll have to forgive me, I'm a relatively new programmer.

Thanks.
Joe
Sorry for the slow reply...Holidays have been busy.

So it's been a while since I've done much with the script. Last fall I worked on trying to unify it so it was just one script for all cases. I got part way done and then didn't get to finish.

To look up frequencies, I set it up on mine so that I had a .txt or .csv file that had two columns:
frequency, alpha tag
128.550, ZLC Grassy Mountain
162.550, NWS

The script gets the frequency from the scanner and then uses a dictionary to look up the frequency text that was loaded from the file.

I've made a couple of modifications to a version I did for a friend with an Uniden. I think it should work with your scanner. I also have an example file of a frequencies.txt that you can use to input your data pertinent to your setup. Save the frequencies .txt file to the same directory as your metaPy2052.py file. Try it and see if it works.

One of these days I need to clean up the script and make it just one file for all scanners. No worries on being a new programmer. I'm in the same boat, it's a hobby on the side for me.

http://www.k7bbr.net/files/metaPy2052.py
http://www.k7bbr.net/files/frequencies.txt
Reply With Quote
Reply

Tags
alpha tag, icecast, python, raspberry pi

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -5. The time now is 2:05 AM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2015, vBulletin Solutions, Inc.
All information here is Copyright 2012 by RadioReference.com LLC and Lindsay C. Blanton III.Ad Management by RedTyger
Copyright 2015 by RadioReference.com LLC Privacy Policy  |  Terms and Conditions