Ask HackADay: Network Security Camera

Today we received the question,

“How to control a web cam via internet,
i want to use it for security reasons, always out of the house and my PC connected want to open the cam from time to time to checkout if something wrong!!”

– [Mohamed Saleh]

What a fun project we thought! And so many different ways of tackling it. Find out what we suggested to [Mohamed] after the break.

Initially we wanted to create an extremely complicated setup, using a USB camera, server, webhosting, and a ton of scripts/programming to create a rather sweet camera setup.

But of course, complication breads problems, and while digging through our box of parts and supplies we stumbled upon an old Axis 206 IP Network Camera. What could be easier than all of the above built into one slick device!

The camera comes with an Ethernet cable, wall-wort for power, and a CD with instructions – we just threw the latter away and winged it, by finding out how to reset the device, then its default ip, we had view of the camera within our network in no time.

A simple port forward of 80 and we could view it outside of our network (so long as we typed in our IP). What we would recommend however, is setting up a DNS (DynDNS is great) service on a computer within the network that points to the cameras IP. That way the URL becomes, a lot easier than (Both are fake URLs sorry).

Taking it further, if you had a computer nearby you could setup a simple stepper motor and control the position of the camera.

This is of course our take on the matter and part of Ask HackADay is what our readers would do, so how would you setup a home security camera?

75 thoughts on “Ask HackADay: Network Security Camera

  1. Must not be getting very many Ask Hackaday submissions.

    Anyway, on the subject of buying something off the shelf, the Rovio works as a pretty good IP cam and you can also drive it around. About $100 these days, Hackaday covered the Woot sale a while ago.

    WowWee has been stonewalling on the sourcecode for the Rovio the past two years. However, last week I asked nicely and they finally released the code:

  2. I would go the harder route. Since I love python, and its super easy for web programming, I would write a server script that shows the images from the webcam. Python already has several library’s for webcams, and even more for web support.

    Or if it needed to be a quick setup, I would find a cam-chat site, make a privet profile, and use the site for monitoring needs. My uncle went this route to check on his daughter after she came home from school while he is at work. He said it works great.

  3. Is it actually the true spirit of the whole project to go out and buy an ip camera that does it all already for you?
    I think it would be far better to have the pc and an existing webcam and have the python scripts to capture the images and then host them on your own webserver

  4. This is just sad. What is the point of asking HaD when they are just going to tell you to use a commercial product? It started out good, until this part:

    “But of course, complication breads problems, and while digging through our box of parts and supplies we stumbled upon an old Axis 206 IP Network Camera. What could be easier than all of the above built into one slick device!”

    Seriously? If this had been a comment left on a HaD post about putting together your own networked camera, it would be considered trolling. This is absolutely counter to everything HaD is about. If every project followed this line of logic, we wouldn’t have any content on this site.

    You might as well rename this to “Ask Google”, since that would have given you the same answer.

  5. I’m sorry, but I have to agree with MS3FGX; getting a pre-made camera is the opposite of an hack.

    Anyway, nice tip, Steve – I’m installing ZoneMinder in my headless server right now. And according to the docs it has scripting support, so I may be able to set up a warning system using SMSes.

    Unfortunately, although I have 100 free SMSs per month in my provider’s website, they use a captcha, which is fucking stupid since they use authentication too.

    this little bugger is amazing just got one for myself. little arm linux computer with 2 stepper motors to control pan and tilt. got mine for 39 dollers uses USB camera!!! spair USB header for internal wireless card. Working on some amazing ideas with this little guy. nice to have 2 USB 1.1 ports serial and ethernet. oh yea plus 2 way audio!

  7. I VPN into my Macintosh remotely, then run “Photobooth” or any other application that shows a webcam preview. Since you can see the desktop, you can see the video feed, too.

    If it’s a fast connection, it’s pretty good, and it’s free (assuming you have a camera already).

  8. I once duck taped a usb web cam to the turret of a USB controlled toy rocket launcher. I used skype, configured with video and auto answer to view the cam. Then controlled the rocket launcher by logging in with gotomypc and just running the little aiming application to point the camera where I wanted to look. No, I did not shoot the little rockets at the cats. Kids, cats, and the wife thought I was really weird, though.

  9. Uh…yeah, my thoughts exactly…I would be coming to this site to do a hack in order to save some money as well as actually hack something together. Otherwise I’m not going to be able to tell the difference between ads and posts anymore…

  10. Meanwhile, at the Evil Axis corporate headquarters –

    HaD has come to visit. Jakob Griffith and Caleb Kraft are in attendance.

    EA – “All we need to do is to devise a scam to run an advertisement on HaD and drive traffic to our Evil website, but at the same time, fool its readers into thinking that it’s not really an ad!”

    JG – “I know, how about we say that we’ve got an old Axis product in our parts box, provide a link to it on your website, and our readers will be none the wiser!”

    CK – “Make sure you write ‘after the break’ somewhere in your article”


  11. (Off-the-shelf product -> not-a-hack.)

    I suggest:
    * Linux Ubuntu Server
    * Motion (web-cam software)

    sudo apt-get install motion
    man motion

    or look a

    Motion has a lot of awesome web-cam features wrapped up in a *nix command-line app. So you get all the usual hackability / creative-flexibility of linux, scripting and the command-line.

    At the basic level, Motion can serve up images over HTTP to a web-browser (web-cam style). But its much more. (Read the doco.)

    Eg You could install Ubuntu Server and Motion on a SheevaPlug or other tiny computer and do all sorts of cool things like turning house lights on and off with movement. Or wire up an old Nokia for SMS when house internet or power goes off.

  12. Well, considering the never said what Operating System this needs to run on, here are a few Linux options.

    VPN and run cheese (works on other OS’s as well, but it’s obvious you are monitoring).

    “ssh -X” then run cheese (covert, but the interface laggs).

    “ssh -L:localhost: then run cheese (much faster than ssh -X and very customizable, also supports multiple cameras.)

  13. usb cams might be nice but what do you do when you want cams on the 4 corners of your house? usb cables don’t work nice with those types of lengths. you pretty much have to go ip-camera or composite cams running into a pc server.

  14. Haha, Frank, thank you for taking a lighthearted approach to this.

    I suppose it should be written in the article that we actually have no affiliation with Axis, and were not sponsored, in short – this is not an ad. We really did have it in our parts bin, back from the FIRST robotics competition (see for yourself, check out our article a few weeks back, all the robots had an Axis camera).

    This article was a test for me and HAD, we’ve got a lot of plans in the future (yes I know, we’re a bit slow, but trust us!) and how we want to treat AskHAD. One aspect of it that we are really incorporating (and thus far is a rousing success) is not only HAD answering the question, but our readers input as well.

    I would like to point out if we feel the asker might just want something quick and easy (such as in this case) we answer as such. If the question was “I would like to find a way to interface my usb camera over the internet and include the functionality to take over the world while you’re at it”, we might have gone more indepth with the specifics that he/she asked for.

    In closing, keep it awesome,
    Jakob Griffith

  15. Jakob – Teehee :) Made you bite :)

    I don’t think I wanna bother verifying your claim and check out that article “from a few weeks back”, as that would just ruin the story for me! :)

    “One aspect of it that we are really incorporating (and thus far is a rousing success) is not only HAD answering the question, but our readers input as well.”

    And that aspect I do appreciate – I got a couple of good links out of it, which is great. Here’s another one I used a couple of years back –

    I was interstate visiting the inlaws (in Queensland) a couple of years back, was gone for a couple of weeks and that served its purpose quite nicely with the 2 spare webcams I had lying about.


    h_2_o – To run USB over long distances, you could use a USB/Cat5/5e/6 balun – I think you can get about 50 metres out of ordinary cat 5 for use with USB.

  16. but do you really want to run usb cams to a pc. I wasn’t initially thinking about usb over cat5 similar to hdmi over cat5 i guess but still IMHO not the most elegant or even practical solution at that. I would still rather run ip or another solution for multitude of reasons.

  17. Yawcam, free..uses any usb capture ive got easycap with auto rotate camera…self configures..can open stream from my android backflip any where (opera 5 mini ) have fun

  18. Don’t get so annoyed when people say just buy a PTZ IP camera. After you get an old PC, a USB webcam, some steppers or servos and a controller for them (parport or dedicated) you’ve easily spent the money on something that takes up a ton more space.

    Try this solution: grab a few PTZ *webcams* and get some cheap USB over ethernet adapters (check out dealextreme or fleabay) and get a linux box with Zoneminder. You’ll have to string your own CAT5e for the cameras but that’s not a hassle.

    You could go and use real network cameras but you might need a more powerful linux box to handle multiple MJPEG streams.

  19. I’ve used axis stuff before and its really nice. Expensive as shit but nice. Also I second zoneminder. It does everything the $1000+ software does but for free.

    (note: I do security for a living)

  20. Another free alternative is
    This allows you to view USB cams, record events to HDD and even view on a smart phone remotely, in addition to allowing you to listen to your entire MP3 collection on the move. If your machine is fast enough it will also transcode your movies into mobile format for viewing on the go too.


  21. another thing to think about and granted it is but a small thing is the power usage. Lately i’ve really been keeping an eye on what is using what with a kill a watt and my ip cameras use very little power. if i had to use a couple pc’s even low power ones to control usb cams the difference is massive.

  22. several IP cams +apache+python+stepper motors+and maybe a touch of C++ just because=something thats not just port forwarding and advertising DynDNS
    just my 2 cents on it…

  23. I’m currently doing a similar project, but I’m using a webcam, integrated ePIR module, and a FTDI FT245R in combination with some .Net code to glue it all together. The basic idea is to make the computer do all of the hard work: sense motion, send me a notification, and automatically record video to a remote server.

    After that, the only thing I need to do is go watch the video when I get notified. That way I don’t have to spend my time watching a camera while nothing’s happening. The best part is that the code is so simple a child could write it.

  24. We have a “cat camera” set up in our house. It is kind of funny but Logitech had the software built in and you can tweak it’s sensitivity to image change (our first pics were of the blinds moving from AC vent) but afterwards, works great. It can do movies or still images. Otherwise you can google for “Catspy” which is over at sourceforge and is free and works with most webcams.
    Alas we had to move the cam to watch the parking lot to bust the school kids that like to set off car alarms and try to set off airbags as they walk thru. I did get one of the lil dirtbags with his foot through a headlight which is getting mailed to his mother along with a note warning her that the cops are involved next time. Lil tubby Pokemon master kid. Anyway, best of luck.

  25. Heh, my first take was same as comment #1 – what a contrived-sounding question, of the pedestrian variety no less.

    PS I was unable to make zoneminder work with the built-in cam on my HP tx2000.

  26. People’s comments:
    “This is not a hack”
    …true, this problem has been solved so many different ways there are COTS products for just about any scenario.
    “Can’t use (cheep) USB cameras in the 4 corners of your house”
    …true, but there are USB extending scheme and one can place cheep PCs around the house and cluster cheep USB cameras around them. However the price point of wired network cameras makes this a 50/50 decision.
    “People can hack into these things”
    …true, but making it more difficult is the usual defence. The down side, it’s usually harder to access your cameras from the outside the more security you put into place. For instance, you may use so much security you need special software making access from a public computer impossible. Your choice.

    I like zoneminder, but have always found it a bit unstable.

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.