JASON – Juxtaposed Active Sentry on Network
     
It’s basically a mobile IP camera built from an old Roomba and a Raspberry Pi. Its got a rechargeable battery, 3 motors, a spot light, laser, buzzer, web cam, and is wifi accessable.
     
The pi is running an apache web server so it can host it’s own web based control interface. It also has php to execute the web commands as local shell scripts which control the camera and call custom built python programs which interface the GPIO pins directly.
     
GPIO interpretation is done on a custom built board with opto isolators to separate the low level 3.3v PI signals from the 12v motor signals. BJT pnp transistors are used for the simple on/off switching channels, and there are 2 dual ½ channel h-bridge DIPs so it can drive 4 motors total – 2 for the left and right wheels and the pan and tilt.
     
The camera is a high res Logitech web cam. The USB cable has been carefully spliced such that the data conductors in the USB cable go back to the pi but the power and ground conductors go to their own dedicated power supply controlled by one of the gpio channels so that the camera can be detached and reconnected remotely for added power saving or if it hangs.
     
The whole thing is powered by a 12v sealed lead acid battery with 7Ah of capacity, so it could theoretically be driven continuously non stop for about 3.5 hours. It’s also got a solar charge controller so the battery can be charged without interrupting power distribution to the rest of the bot for indefinite operation. It just drives into it’s docking station with spring loaded contacts. An indicator light shows when it’s charging. This way the battery is always topped off. So now it can be left running for a week while you travel to check up on your cats!
     
Voltage regulation for the 5v components, like the camera and pi, are done with these DC-to-DC buck converters. They’re very stable and efficient; they don’t even get warm after a few hours of use. And their cheap, got a lot of 10 on ebay for 12bucks, thats about the same price for 3705 voltage regulators which get pretty hot and need additional supporting circuitry.
     
The self hosted web interface uses HTML, Java Script, and PHP. The pi automatically connects to a preprogrammed wi-fi SSID of my choosing upon bootup so knowing its IP, I just connect to it with a standard web browser. The video works surprisingly well, the pi has the linux program mjpeg-streamer installed which has no problem handling 640x480 at 25fps. The keyboard controls are handled with java script events mapped to the onscreen buttons hosted by a pi-plugin called web-io-pi. And since apache was given sudo root access, the auxiliary controls on the right can execute shell scripts allowing you to run absolutely anything, like starting and stopping services, rebooting, or python programs.
That is awesome. Work on a model that does stairs for me. :)
Name:
sujith,india
Time:
12:35 AM
Date:
May 06, 2013
Comment:    
how it is controlled via internet
Name:
salman
Time:
10:20 PM
Date:
July 25, 2013
Comment:    
thats a great project. i want to know how to use a usb camera with raspberry pi. can u help me?
Name:
Dan Krill
Time:
12:25 PM
Date:
July 28, 2013
Comment:    
Salman, You can use almost any usb camera with the raspberry. I would stick to logitec though because the cheap ones dont support jpeg compression then you have to use the YUV mode of this program (which simply requires an extra run-time parameter). So here is how I did it:
---- install mjpg-streamer: - sudo apt-get install subversion - sudo apt-get install libv4l-dev - sudo apt-get install libjpeg8-dev - sudo apt-get install imagemagick - sudo svn co https://mjpg-streamer.svn.sourceforge.net/svnroot/mjpg-streamer mjpg-streamer - cd mjpg-streamer/mjpg-streamer - sudo make USE_LIBV4L2=true clean all - sudo make DESTDIR=/usr install
---- to run from pi console: - mjpg_streamer -i "/usr/lib/input_uvc.so -d /dev/video0 -r 80x60 -f 15" -o "/usr/lib/output_http.so -p 8090 -w /var/www/mjpg_streamer"
---- to acess in an html page: - img src="http://192.168.0.63:8090/?action=stream" width=752
Name:
Kamil
Time:
10:31 AM
Date:
August 28, 2013
Comment:    
Hi there ! Great project ! but I have one question. I made everything like you wrote with mjpg_streamer but when I use my logitech c170 webcam it does not work. I`ve got the same error in mjpg and yuv mode and it says: UVCIOC_CTRL_ADD - Error: Inappropriate ioctl for device. Can you help me with this error ?
Name:
Dennis
Time:
05:09 AM
Date:
December 18, 2013
Comment:    
Hi there! Awesome work! i work on a Project like this. My Question to you is, can i get the Source Code from the PI Webinterface? Thank you