This project is used to control a webcam's orientation from any web browser. I developed this so that I could monitor my back yard remotely (via VNC while at work) to see what animal(s) are eating my plants.
The project hardware consists of two servos for controlling the pan and tilt of a webcam by the Netdunio+. The Netduino accepts commands via the network and moves the appropriate servo using the Servo_API from Chris Seto. It uses pins 9 and 10 for the servos. Make sure that you hook the Netduino via the power jack to a 9v brick since the USB connector can not supplied the required current for the servos.
The commands are sent from any browser by using the Netduino+ IP address (e.c: http://192.168.0.104) followed by /PanTilt.htm as the URL. In my setup I use: http://192.168.0.104/PanTilt.htm.
PanTilt.htm is a small HTML file that resides on the Netduino+ SD card. It displays arrows for controlling the camera position. When you press on the left arrow, the browser send a 'L' to the netduino via Javascript. The Netduino+ PantAndTilt application (which is a modification of my MicroServer application) server the page of the SD card and translate the commands, in this case into a 'left' command for the servo that controls the x-axis. There are commands for up, down, left, right and center.
I got the following Parts from SparkFun for this project:
Servo - Medium (ROB-10333)
Pan/Tilt Bracket (ROB-10335)
I believe SparkFun recommends the smaller servos for the bracket, but I was able use the
medium servos. You will need to play around with the servos, especially the one for the Y-axix (tilt) to make sure the alignment is straight one the application starts the servo's at the default 90 degrees.
Make sure you copy the contents of the web folder to the root directory of the SD card before testing the application. Good luck finding those animals!