The End of Internet Radio Stations?

ClouwdNine

For those of you that don’t know together with some other heads I run things for clouwdnine.com. Our website was recently attacked, presumably because of the availability of Low Orbit Ion Cannon or similar simple tools for ddos-attacks. While the attack in itself is not that much of an issue, and can be mitigated, the consequences for us and maybe radio stations as a whole is a bit upsetting.

ClouwdNine is like several other radio stations, managed by a small team of people who are mainly making sure that there is infrastructure, DJs streaming and some communication on social media. In my opinion we are doing a good job, steadily growing our following, organizing sound clashes (both internal and against FKOF), and hosting some bigger names DJs (looking at you Fill Spectre). We even had a small introduction to promoting with a night in Dalston.

All of this is mainly costing us manpower, making sure everything runs the way it should. When it comes to our other resources, we run very basic and cheap servers, which is also our main vulnerability. Just one icecast server can be taken down easily and all of a sudden we are not functioning anymore.

What are our alternatives?

In order to really be safe from these types of attacks you need the resources of social streaming service like a mixlr or chew.tv. The thing is, we don’t want to move to social streaming. We are not a bunch of individuals, we are a collective that has a common goal of sharing our view on music with those who want to know. The radio station is our means to that end. And now it shows that our means are rather vulnerable to attacks.

We did find a way to increase our robustness. We moved to several smaller, cheaper servers. We moved our webspace to a host that offers ddos-protection. And most importantly, subsource magazine is helping us out with streaming through a more protected icecast server, for which we are very grateful. However, getting all of this up and running has spread us out rather thin. We’re still in the process of finetuning all of our systems and trying to get grip on how our new software deals with the software our DJs use to connect to us. But if all goes well we should be up and running again in the coming few days.

All in the same boat…

The painful thing is that we are not the only station under attack. As a sub.fm regular listener I found out that they were having some issues as well. We received accusations from another radio station of attacking them. Rumor has it that even the big rinse.fm got attacked. And to be honest, it’s a sad thing, if radio stations have to struggle to stay alive. While I do believe that social streaming is a nice way forward, especially for the individuals, there is value in a curated radio station. Internet radio stations provide new, less popular DJs to band together and get some exposure together. And if a radio station does have bigger name DJs, the less popular DJs benefit from this tremendously. All the while the listener benefits from curated, quality controlled content.

What I would love to see is more collaboration between radio stations. Everyone is dealing with the same challenges, trying to combine a streaming service, some social media scripts, a web frontend and some chat functionality. There’s a lot of reinventing the wheel. The thing is, it doesn’t have to be that hard. Even though there’s a lot of different building blocks, once you have some servers, it’s a matter of installing and configuring a small number of software programs and you’re good to go. So in that light over the coming weeks I will be sharing all scripts we use (liquidsoap, python, php and custom javascript) in a public github for anyone that feels like having a look at how we’re running things under the bonnet. And of course I would love to get some input on how others are running their things.

Raspberry Pi as chew.tv Streaming Camera

After having moved recently I started to think about having a proper camera setup for my attic studio. I’ve been using a action cam that doubles as webcam, but image quality cannot be altered at all, leading to some issues with white balance mainly. I still have a spare raspberry pi somewhere, that I will be trying to convert into a small streaming box. Normally I use OBS and BUTT on my serato laptop to connect to both chew.tv and our clouwdnine icecast. In OBS I overlay chat and a logo to end up with a nice streaming setup.

Untitled

I’m hoping that with the Raspberry Pi I can put the box with camera nice and close to the setup and use a cable to connect to the USB sound card next to the decks.

I hope that the raspberry pi camera module provides good enough image quality. I will be using gstreamer and possibly nginx to send audio and video to chew.tv and audio only to our icecast server.

Video encoding through omxh264enc

Some resources I found for streaming:

Using omxh264enc for gstreamer:

And using nginx for forwarding audio/video to multiple streams:

The basic setup will be capturing audio and video, muxing it into a h264/AAC .mp4 stream which I send to nginx, where it is split into an audio/video stream that is forwarded to chew and an audio stream that is forwarded to clouwdnine. I’ll try to create a control page in nginx that will allow me to control and monitor both streams from my phone or another computer.

A challenge I’m unsure about is the chat overlay. Gstreamer allows text overlay, but I don’t know to what extent I’ll be able to overlay a stream…

If this idea works out, the next cool thing would definitely be using several Pi’s to get a multi-camera setup.

Streaming Webcam to Tunemelt with Logo Overlay

I still need to test it properly, but I think it is very much possible to use ffmpeg to stream to tunemelt (a video CDN) directly. We can stream ffmpegs DirectShow input to the Tunemelt RTMP.

Update: Apparently even though Tunemelt accepts the stream, it is not properly linked to the Stream Name. I suspect the problem lays in the unconventional way of authenticating, where user/pass have to be entered in the path. I’m not sure if there’s any way around this…

In order to do so, the first step is to find the device name of the webcam and sound input. Do this by typing the following command:

ffmpeg -list_devices true -f dshow -i dummy

Example output is:
ffmpeg device
In my case, we need the “General Image Devic” and “Line In (2- IDT High Definition”.
Use the following command to start streaming this device to tunemelt (-r for frame rate of 30, if necessary, specify the proper output resolution of -s 1280×720).

ffmpeg -f dshow -i video=”General Image Devic”:audio=”Line In (2- IDT High Definition” -c:v libx264 -r 30 -f flv rtmp://live.tunemelt.tv/stream/live/[email:password]/[stream-name]

For added bonuspoints integrate a logo overlay. Use a png with transparency and use the -vf overlay command.

ffmpeg -f dshow -i video=”General Image Devic”:audio=”Line In (2- IDT High Definition” -vf “movie=logo1.png,scale=120:120 [watermark]; [in][watermark] overlay=10:10 [out]” -c:v libx264 -preset ultrafast -r 30 -f flv rtmp://live.tunemelt.tv/stream/live/[email:password]/[stream-name]

The end result is a nice video stream with logo overlay sent directly to Tunemelt.
ss

First Mix

One of the presents I got for myself after graduation is a set of turntables and a proper mixer. I’ve been playing around a little with it and finally recorded my first mix. It’s rough, but I’m happy enough about it to post it.

Tracklist is:

  1. Mala – Level 9
  2. Skream – Snarled
  3. Killawatt – 71
  4. Skream – Midnight Request Line
  5. Coki – Badman Place (DMZ Remix)
  6. Skream – X-mas Day Swagger
  7. Hudson Mohawke – Thunder Bay
  8. Dismantle – Computation