• 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

Streaming with Raspberry Pi3 using Darkice/Darksnow

Status
Not open for further replies.

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#1
Since the Pi3 was introduced over a year ago, setting up a reliable audio streamer using it has been challenging. Most of the instructions were based on the previous versions of the Pi and the earlier Raspbian OS.

Darksnow is a graphical user interface (gui) for the darkice streaming program. Others had reported problems making it work on a RPi and likewise I couldn't get it working when I first tried using it. That was unfortunate as many people dislike working at the command line and using text editors that are not intuitive. The problem I discovered is that the package managers included with Raspbian retrieve the 0.6 version of Darksnow rather than the 0.7.1 version. The 0.6 version does not work.

The newest release of Rasbian Jessie (PIXEL) has many improvements including a much shinier desktop that is much more responsive. The most recent release is available at the downloads section of raspberrrypi.org.

Here are the steps to make it work:

Darkice/darksnow on Raspberry Pi3



Image an SD card with the most current version of Raspbian Jessie (the full version, not lite)



Insert card into pi3 with keyboard/mouse, usb sound card, ethernet, and hdmi monitor connected.



Turn on monitor to hdmi input and power up pi.



Click on raspberry in upper left of menu bar. Choose Preferences/Raspberry Pi Configuration. In the first tab, enable vnc. In the second tab, optionally change hostname to darksnow. In the localization tab, set all your local information. Close the configuration windows. You do not need to reboot at this time.



Open the chromium web browser. Navigate to darksnow.radiolivre.org. (A Portuguese language version opens by default. Click Nope in the translation box and a link to the English version is behind it.) In the download source section click 0.7.1 to start the download. This only takes a few seconds, then close the web browser.



Open a Terminal window using the Terminal icon in the menu bar. At the command prompt ($), make the following entries:



$ sudo apt-get update

(Takes about a minute)



$ sudo apt-get install gtk+2.0

(Takes about 5 min)

$ sudo apt-get install darkice



$ cd Downloads

$ tar -zxvf darksnow-0.7.1.tar.gz

$ cd darksnow-0.7.1

$ ./configure --prefix=/usr

$ make

$ sudo make install

$ sudo reboot



This will reboot your pi. After it reboots and returns to the Pixel desktop,open a Terminal window. At the prompt:



$ darksnow



This will launch a window where you enter your broadcastify information in the server tab. In the audio settings tab use:
mp3
constant
16
22050
0.1
16
1-mono
10
hw;1,0.

Then File/Save Configuration




Then start your stream using the start button at the bottom of the page.





If you want to use wifi it can be enabled from the icon in the upper right.



If you want to work headless and connect through VNC you can connect to the pi at darksnow.local::5900 from another computer on the same network as the pi. This assumes that you changed the hostname to darksnow near the beginning of these instructions.


Try this out and let us know if it works!
 
Last edited:
Joined
Sep 27, 2009
Messages
14
Location
Lompoc, Santa Barbara County, CA
#4
RPi-3 Feed

Looking for help setting up the DarkSnow Server Options and Streaming Description tabs. Myold feed used ProScan.
Any hope of displaying MetaData (channel ID) tags?

Thank you!
 
Last edited:

Fillup502

Newbie
Premium Subscriber
Joined
Nov 15, 2015
Messages
2
Location
Falmouth, Maine
#5
PI 3 Darksnow/Darkice working

Since the Pi3 was introduced over a year ago, setting up a reliable audio streamer using it has been challenging.
DC31, thanks for the input on the programming for the Pi3. All very helpful. I was able to get the noobs jessie build to work with your instructions above (and reading your other posts).

I had several problems with the audio input. I did change the sample rate to 44100 and had to adjust the capture level/scanner output.

Do you have any direction on getting alpha tags to work with darkice?
I tried adding auto start originally but it didn't work. Have you had success with a Pi3 darkice running on startup?

I'm running a BCT-15x with a Pi3 and I am using the GUI now but started with putty headless. It's going to be nice to shut my tower down without loosing the feed.
 

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#6
Fillup502;2707437 Do you have any direction on getting alpha tags to work with darkice? I tried adding auto start originally but it didn't work. Have you had success with a Pi3 darkice running on startup? [/QUOTE said:
I don't have any experience myself running alpha tags. I know that it can be done from the pi with a separate program. That program works only with one brand of scanners and right now i can't think which. The instructions for it are in these forums somewhere. If i find it I will edit this post.

I start my darkice feeds on boot using a line in the crontab file. However, i am not running the darksnow GUI. I am not sure how autostart would work with darksnow. I have found darkice to run very reliably on my pi's with the only interruptions due to power failure. With bcfy set up to text me when my feed goes down i think that the downtime in the rare instance of a power failure until i could restart darksnow manually would be tolerable.

Jim

Edit: uniden scanners. Here is the thread: http://forums.radioreference.com/st...ner-audio-feeds-raspberry-pi.html#post1986345
 
Last edited:
Joined
Oct 7, 2014
Messages
8
Location
NKY
#7
Audio Delay/Slowed Down.

This tutorial was a godsend, I almost gave up, because my Pi 3 wasn't holding a connection after reboot. I have this working and have copied the the directions to a T however, I have noticed upon playback through Broadcastify, the audio is extremely delayed and the audio has been extremely slowed down. It is as if you are playing a video at .25% of the normal speed and everything sounds super slowed down. Please help!
 
Joined
Oct 7, 2014
Messages
8
Location
NKY
#8
This tutorial was a godsend, I almost gave up, because my Pi 3 wasn't holding a connection after reboot. I have this working and have copied the the directions to a T however, I have noticed upon playback through Broadcastify, the audio is extremely delayed and the audio has been extremely slowed down. It is as if you are playing a video at .25% of the normal speed and everything sounds super slowed down. Please help!
To add to this, I am using ICECAST 2, if I attempt to use ICECAST 1, I simply get errors and won't start the feed. I have completely redone the preferences and saved to a new file without any luck. The audio still sounds extremely slowed down. Thanks!
 

Fillup502

Newbie
Premium Subscriber
Joined
Nov 15, 2015
Messages
2
Location
Falmouth, Maine
#9
To add to this, I am using ICECAST 2, if I attempt to use ICECAST 1, I simply get errors and won't start the feed. I have completely redone the preferences and saved to a new file without any luck. The audio still sounds extremely slowed down. Thanks!
You may want to try adjusting the sample rate to 44100. This worked for me. I am using ICECAST 2.
 
Last edited:
Joined
Oct 7, 2014
Messages
8
Location
NKY
#10
Thank you for your response. I have adjusted the sample rate to 44100 as I saw that it has fixed others in the past without any luck. I have also removed the keyboard/mouse usb dongle from the usb bus as I read that may cause the issue, still without any success. I am running this Pi headless and adjusting using VNC.
 
Joined
Feb 28, 2006
Messages
24
Location
Atlanta, Ga
#11
Is this expected to work on a Pi2 and not a 3? I dont have my Gen 3 Pi's at the house. My audio is all buzzing off the stream. I had to connect it back to windows to keep the feed active.
 

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#12
Is this expected to work on a Pi2 and not a 3? I dont have my Gen 3 Pi's at the house. My audio is all buzzing off the stream. I had to connect it back to windows to keep the feed active.
All testing was done on a pi3. As long as you are running Jessie with the PIXEL desktop on your pi2, i think it would work. It might slow down browser response, but i don't think would cause audio issues. Based on some of the other comments above you may need to experiment with sample rate and radio output volume.
 
Joined
Feb 28, 2006
Messages
24
Location
Atlanta, Ga
#13
Since the Pi3 was introduced over a year ago, setting up a reliable audio streamer using it has been challenging. Most of the instructions were based on the previous versions of the Pi and the earlier Raspbian OS.

Darksnow is a graphical user interface (gui) for the darkice streaming program. Others had reported problems making it work on a RPi and likewise I couldn't get it working when I first tried using it. That was unfortunate as many people dislike working at the command line and using text editors that are not intuitive. The problem I discovered is that the package managers included with Raspbian retrieve the 0.6 version of Darksnow rather than the 0.7.1 version. The 0.6 version does not work.

The newest release of Rasbian Jessie (PIXEL) has many improvements including a much shinier desktop that is much more responsive. The most recent release is available at the downloads section of raspberrrypi.org.

Here are the steps to make it work:

Darkice/darksnow on Raspberry Pi3



Image an SD card with the most current version of Raspbian Jessie (the full version, not lite)



Insert card into pi3 with keyboard/mouse, usb sound card, ethernet, and hdmi monitor connected.



Turn on monitor to hdmi input and power up pi.



Click on raspberry in upper left of menu bar. Choose Preferences/Raspberry Pi Configuration. In the first tab, enable vnc. In the second tab, optionally change hostname to darksnow. In the localization tab, set all your local information. Close the configuration windows. You do not need to reboot at this time.



Open the chromium web browser. Navigate to darksnow.radiolivre.org. (A Portuguese language version opens by default. Click Nope in the translation box and a link to the English version is behind it.) In the download source section click 0.7.1 to start the download. This only takes a few seconds, then close the web browser.



Open a Terminal window using the Terminal icon in the menu bar. At the command prompt ($), make the following entries:



$ sudo apt-get update

(Takes about a minute)



$ sudo apt-get install gtk+2.0

(Takes about 5 min)

$ sudo apt-get install darkice



$ cd Downloads

$ tar -zxvf darksnow-0.7.1.tar.gz

$ cd darksnow-0.7.1

$ ./configure --prefix=/usr

$ make

$ sudo make install

$ sudo reboot



This will reboot your pi. After it reboots and returns to the Pixel desktop,open a Terminal window. At the prompt:



$ darksnow



This will launch a window where you enter your broadcastify information in the server tab. In the audio settings tab use:
mp3
constant
16
22050
0.1
16
1-mono
10
hw;1,0.

Then File/Save Configuration




Then start your stream using the start button at the bottom of the page.





If you want to use wifi it can be enabled from the icon in the upper right.



If you want to work headless and connect through VNC you can connect to the pi at darksnow.local::5900 from another computer on the same network as the pi. This assumes that you changed the hostname to darksnow near the beginning of these instructions.


Try this out and let us know if it works!

I still cannot get this to work. I re imaged the CD card.

The audio sucks and is slowed down, even after adjusting the sample rate.
 
Last edited:
Joined
Feb 28, 2006
Messages
24
Location
Atlanta, Ga
#14
Thank you for your response. I have adjusted the sample rate to 44100 as I saw that it has fixed others in the past without any luck. I have also removed the keyboard/mouse usb dongle from the usb bus as I read that may cause the issue, still without any success. I am running this Pi headless and adjusting using VNC.
I did the same even reimaged and started over and no luck its just not working. have you been able to get this resolved?
 

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#16
Something to try, I am not sure how well it will work.

Darksnow is really just a GUI for configuration of darkice. When you click start stream it really just starts darkice using the configuration parameters that you have entered.

Get the configuration the way that you want it in darksnow, click start streaming. Then click Save Configuration under the File menu. Save it wherever you choose.

If you click on Show Details in darksnow when you have it streaming it will show you what configuration it is loading with darkice. In mine, and probably yours it will show:

darkice -v 0 -c /home/pi/.darksnow/darkice.cfg

Put that command into an @reboot line in crontab and it should start at boot.

To get to crontab the command is $ crontab -e

then the line that you want to add at the end of the file is:

@reboot darkice -v 0 -c /home/pi/.darksnow/darkice.cfg

You can leave out the -v 0 if you like.

Again, I haven't really tested this so good luck.

Jim
 

faff29

Member
Premium Subscriber
Joined
Jul 30, 2008
Messages
36
Location
Eastlake, OH
#17
I finally have been able to get the feed to broadcast using dark ice but cannot after many hours and many scenarios figure out how to get darkice to restart on the boot of the rpi. I have tried crontab, init.d, and several other ways. Any one have direction on how to do this? My rpi is less than a year old.
 

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#18
I finally have been able to get the feed to broadcast using dark ice but cannot after many hours and many scenarios figure out how to get darkice to restart on the boot of the rpi. I have tried crontab, init.d, and several other ways. Any one have direction on how to do this? My rpi is less than a year old.

In your /home/pi directory you should find a hidden directory /.config. In this directory, create a subdirectory titled /autostart. In that autostart directory create a file titled darkice.desktop. Paste the following text into that file, save, and exit.

[Desktop Entry]
Version=1.0
Name=Darkice Audio Streamer
Exec=darkice
Terminal=false
Type=Application
X-GNOME-Autostart-Phase=Initialization
NotShowIn=KDE;


You can adjust the Name= line to your liking. The text after Exec= is the command that runs. If you need to specify the path to your darkice configuration file, it would be like this: darkice -c /etc/darkice.cfg.

You can read more by googling Raspbian .desktop file.

Hope this helps.

PS when you start darkice like this you won’t see any evidence that it is running. BCFY can take five minutes for the status to update. In a terminal window run the top command to see if darkice is in the list of programs running. End the top command with Cntrl-c
 

Attachments

Last edited:

DC31

Member
Premium Subscriber
Joined
Feb 19, 2011
Messages
1,067
Location
Massachusetts
#19
Starting darkice

Sorry,

I made the assumption that you are running the full Stretch version of Raspbian with the GUI. Ifyou are running the Lite version with command line only, the above may work or may not. If that is the case don’t waste a lot of time on it. Post back here that you are running Lite and we can go from there.
 

faff29

Member
Premium Subscriber
Joined
Jul 30, 2008
Messages
36
Location
Eastlake, OH
#20
So I did a complete rebuild of my RPI today to have only the scanner stuff on it. I followed the build information and what I have right not is completely up and working with the exception of the boot. I am using the GUI version of Rasbian. I have done nothing additional to setup other than what the direction from the build wiki guide has with the exception of using sudo darkice -c /etc/darkice1.cfg to run the program for testing.

I used your above information and changed the file name and location to show: Exec= sudo /usr/bin/darkice -c /etc/darkice1.cfg (I also tried without sudo as well as without /usr/bin to see if that mattered)

Still will not work on boot.
 
Status
Not open for further replies.
Top