Search code examples
androidmobilebroadcastinternet-radio

Platform to use for radio server?


I'm making a mobile app where users should be able to start their own radio broadcast channels from their mobile phone. Other users will then be able to browse broadcasts and connect. It also includes some special perks to make it unique.

I've got the general concept of it thought out.

The thing is, I'm not sure how to implement some kind of "server" for it. I could think of two solutions to my problem currently:

  • Running a server which manages both the list of broadcasts channels, and also broadcasts the channel to all users.

  • Running a server which manages the list. It stores a handle for connecting directly to the broadcasters phone.

Now I'm a total beginner when it comes to how demanding something is. Am I thinking correctly if i say that the first solution would overload the server when there are many users on it?

That would make the second option seem good, although if a channel gets popular enough, wouldn't it require insane amounts of bandwidth for the broadcaster?

Help me out guys, as I said I'm a total beginner when it comes to these kinds of things.


Solution

  • I would just use SHOUTcast or Icecast. It is very easy to start up either of these from another application.

    These servers are very simple in their operation. Data comes in (usually encoded in MP3 by the source client [your mobile app]), and the server sends the exact data right out the door to any connected clients. It does implement a small buffer so that receiving clients can be initially flooded with data, to speed up the time before audio is played. You could always implement one of these yourself, but there is no sense in re-inventing the wheel.

    You absolutely cannot run a server on the phone itself. Not only won't there be enough bandwidth, but each connection consumes some resources, which are extremely limited on a mobile device. You should host the streams on your own servers, and use the mobile device as a source client.