Tuesday, November 16, 2010

View Sensr Cams with iPhone App


A friend of mine showed me the Live Cams app for iPhone and iPad today. It let's you view live webcams from your iPhone. There are a few other apps out there that let you watch cameras, but Live Cams seems to be unique in that it also lets you view your private IP cameras as well. When I saw this I realized that there should be a way to view Sensr cameras with this app.

Warning: Complicated setup ahead.

Basically Live Cams will view any motion JPEG stream. On the Sensr site we also generate motion JPEG streams for cameras. It's a bit hidden, but we could easily expose this in the future to make this easier. For now, go to the "View Live Stream" link for a camera. This pops up a window and sends a motion JPEG stream. If you right-click on that window and select View Source, you'll be able to find the stream url. In this example it looks like this:
http://f2.sensr.net/stream/8fdab6c1ea27828b5185704622b7b0838bcbb7ce

If you grab the stream URL from the source, you can then use that URL to add a private camera in Live Cams, allowing you to get a live view of your Sensr camera on the iPhone. Since the URL is difficult to type, you might want to email it to yourself so you can cut and paste it on the iPhone. (I warned you that it was complicated!)



This is a hack right now, but there are things we can do make this easier in the future.
  • Expose the stream urls in the web page
  • Convince Live Cams to use our API, letting the user add Sensr cameras easily
The advantage of using Sensr is that the user doesn't need to punch holes in their firewall. The user also gets archiving, sharing, and alerting on the Sensr site. Eventually it would be nice to integrate those into an iPhone app as well at some point.