IP Cam Streaming to Blackberry
So you have a IP Cam and that's pretty neat. But now you want to be able to check in on it from your Blackberry. Well get ready, this is going to be crazy.
Before getting into it, it might be worth it to review the following:
(Terrible) Adventures with WVC54GC IP Cam
(Notice the word Terrible)
Review of Streaming Technology
Understand some of the following:
RTSP: This is a protocol for streaming media to clients. It works like HTTP over Port 554. The client makes a request and the Streaming Server responds.
RTP: Protocol used to deliver audio and video. RTSP goes over RTP.
3GP: This is a container format for the stream that the Streaming Server sends out. Most phones (like the Blackberry) support 3GP.
Darwin Streaming Server: DSS is a streaming server that supports 3GP. A streaming server is like a web server but for streams.
Windows Media Services: We aren't going to use this but I just included it to illustrate that there are different streaming servers.
VLC: Amazing media player among many other things.
SDP: This is file that VLC spits out to describe the outgoing stream to DSS.
Blackberry Support Streams
Review the following:
http://www.blackberry.com/btsc/search.do?cmd=displayKC&docType=kc&externalId=KB05482&sliceId=SAL_Public&dialogID=185006185&stateId=1%200%20185004605
According to that, all Blackberries support RTSP, 3GP and MPEG4.
Solution
The easiest solution is to buy a pricey IP cam that supports MPEG4 stream. Many do as viewing the cam on your phone is a attractive feature. But if you cheaped out (like me) you will need something else:
VLC is going to pull in the stream from the cam, transcode it to MPEG4, write out the transcoded stream using RTP to DSS (announce itself to DSS). The Blackberry is going to make a request to the streaming server (like a browser request) and boom! If everything goes well the DSS will serve up the live stream.
Alternatively, VLC has a web server (a streaming server) built into it. I couldn't find any documentation on that, but it may be possible to use VLC instead of DSS.
Install and Configure DSS for Windows
- Download and install ActivePerl
- Download and install DSS
DSS requires ActivePerl to run the web based admin console. ActivePerl can be downloaded from here:
http://www.activestate.com/activeperl/
Download DSS for Windows here:
http://static.macosforge.org/dss/downloads/
Here is a guide on setting up DSS. Get it installed and tested:
http://generally.wordpress.com/2007/08/07/how-to-setup-darwin-streaming-server-on-windows/
Install VLC for Windows
VLC for Windows can be downloaded here:
http://www.videolan.org/vlc/download-windows.html
Configure VLC to RTS to DSS
Review the following:
http://wiki.videolan.org/Documentation:Streaming_HowTo/Advanced_Streaming_Using_the_Command_Line
Start VLC in command line mode with all the parameters to create a sdp in the media folder of DSS.
This one line took me a very long time to figure out. I wanted to run this on Ubuntu but I could never get it to run stable. Oddly enough it works perfectly on Windows.
Replace http://192.168.0.152/img/video.asf with the URL with whatever stream comes out of your IP Cam.
Test the Deployment
Open up Quicktime and open up the URL rtsp://server/stream.sdp if it works, try it on your Blackberry!
Conclusion
Hope you found this guide useful.