This is a quick page I put together to provide some info on how I made a simple "mouse click" web based control panel for my webcams (see the projects at the bottom of this page for more stuff). As usual, all origional programs, content, graphics and images on the zoomkat site are copyright 2001, with all rights reserved. I've put counters on the pages to see what is popular and what is not so things can be adjusted accordingly. Reports on successful use of this type of setup with other web servers (I seem to have problems with other types) can be sent to zoomkat at hotmail.com, mentioning the webpage in the subject line. "How do I..." questions are probably best answered in the discussion groups such as the alt.comp.periphs.webcam usenet newsgroup) where everybody benefits from the info. Thanks! Update 3/23/02: Added for download the basic source files I wrote to control the servos over the net (compiled program is there too) here. Not very fancy, but they work. You might want to "roll your own" using quickbasic or firstbasic to do the compiling, or just see what they do. Also added a web page showing the basic code here and the readme file here.
Update 7/31/03: I've found that my Windows XP machine does not like the quickbasic compiled files for controlling the servo controller. As a different approach I've found that the appropriate bytes can be written to the com1 and com2 ports in Windows XP and 95/98 using batch files. Set up your own webcam remote control and do it all with notepad! Info on this new setup can be found here.
New 5/29/04, make your own inexpensive (~$16) webcam pan/tilt servo controller here.
Various webcam test pages that may or may not be in operation.
Note that as of 4/11/09, Webcam32, Ivista, and Webmedia are no longer sold (Webmedia did have a free version at one time). Webcam2000 is open source, free, and still available!
DIY ezservo pan/tilt webcam page here.
Streaming Webcam2000 video using javascript and a java applet.
Webcam2000 webcam page here and here, setup info here.
Webcam2000 multi webcam applet page here and javascript page here.
New 4/12/09, Webcam2000 JavaScript pull pan/tilt cam page here.
Webcam32 image pull page here.
Multiple Webcam32 webcams here.
Webcam popout test page here.
The below webcams are probably OOS (as of 4/11/09), but page source is still there:
Webcam page with javascript dropdown menus here.
Old 486X66 webcam machine here.
Pan/tilt cam and parallel port video switcher demo page here.
Multiple Ivista webcams here.
Webcam32 video and audio page here.
Webcam32 audio only page here.
Webmedia 1.7.6 page here, and download here.
WIFI
A simple directional WIFI antenna here.
Web Based Control Panel
This control panel came out of an effort to control my Mini SSC II servo controller via the web. Could never get the .exe file to execute by itself in the cgi folder of the apache webserver module that comes with the Ivista webcam software. After hearing about using "batch wrappers" in cgi applications (never actually found an example), I noticed that a .bat file would run with out making any changes in the apache config. This led me to running older command line programs by putting them as a command line in a batch file first. The control panel page kept wanting to refresh with a new page. I finally found how to include the proper status code in the batch file to keep the control panel from updating. This makes the control panel useable. The in the revised Mini SSC II control program (8/1/01), the zkpt2.exe program ("web control test program" on down the page) works with the Apache Windows web server (free), Xitami Windows web server (free), and the origional MS PWS web server (apache seems to be more stable). Update 10/10/03: The SimpleServer webserver (free) from AnalogX also performs the cgi functions executing the batch file, but does not handle the get/query_string request. The port that the simple server operates on can be changed from 80 to what is desired by changing the server settings in the registry. The Apache server module included in the Ivista webcam software still needs the zkpt2.bat file (included in the zkpt2.zip file) to run the zkpt2.exe program. New 6/26/04: Go here to see how to use qbasic (included with win95/98) with the basic servo control .bas files. This eliminates having to compile the application into an .exe file and makes changing the source code to what ever you want it to do very easy. After not having found something quite like this after a long search, this particular use of a batch file as a cgi interface for a control panel could be a *zoomkat origional!*. So much for my 15 min. of fame. Below is the basic batch file used to execute the programs. Copy, paste in note pad, add your command line, save as a .bat file, put it in the cgi folder, and you are on your way. The zoomkat part is mostly shameless self promotion. ;-)
@echo off
echo Status: 204 zoomkat's amazing batch file
echo.
echo.
*your command line here*
cls
Perl users can try this type of script to run the pan/tilt command line program.
#!c:/apps/perl/bin/perl
print "Content-type: text/plain", "\n";
print "Status: 204 No Content", "\n\n";
system("zk2pt2c.exe -q");
exit (0);
Qbasic users can use the below to output the status: 204 code.
OPEN "CONS:" FOR OUTPUT AS #1 'rem if using bat file for 204
PRINT #1, "Status: 204"
PRINT #1, ""
PRINT #1, ""
CLOSE #1
Here is my test control panel where the video and pan/tilt controls are are active. When you click on it, it should load, displaying the control panel with video and pan/tilt controls (if my home computer is currently online). Right click on the page and click "view source", copy the source, and paste in notepad (remove the stuff below the popup window line). You can pretty much see what is going on there. Save it as something like test.htm and put in the webcast folder (or other folder depending on your web server). The IP addresses in the html click control lines are set to zoomkat.d2g.com for testing on the computer where the webserver software is running. Put your own video applet in to replace the demo one. For real net use, you will need to use your valid IP address to replace the zoomkat.d2g.com ones. Here is some info on what may be on the current control panel page (it changes often).
Streaming Video
The panel is set to display streaming video using a Winnov ISA AV capture card and using the Ivista webcam software. You should be able to use most any other webcam program with this setup, but you will need to provide a web server and change the html to match.
Pan/Tilt Cam Controls
The positions for the cams take up most of the page html (when the source is viewed). Each * on the line is a specific postion for a servo. I broke up the ~170 deg pan range of each servo into sort of equal parts. In one direction of rotation, the servo may be hard against the travel stop. You want to adjust the position so the servo doesn't strain against a traval stop and gradually heat up. I'll try to put up more about servos and the Mini-ssc later, and some related links. Working with the mini-ssc and a previous project with some servo control chips from NCD, I found there just isn't much in the way of web control software for the servo controllers. With help from the usenet news groups I made a web control test program (~144K, updated on 8/19/01 with more control strings, support for the SSC-12 and other controlers, and command line use, including two more programs for running servo routines via a web brouser, which don't send the 204 status code) to use with the mini-ssc and the control panel. It is very basic and more info, including setup and use, is included in the readme.txt file in the zkpt2.zip file (see links at the top of this page for source page). You can see the html control lines in the test control panel page source. The test control panel is set to use the ZK2PTB.EXE and ZK2PTB.BAT programs (the origional control programs prior to the recent updates, change names to match the new names) on com port 2, so connect your mini-ssc to com port 2 if you try the test control panel. The test page is set to use the mini-ssc servo 00 as the pan servo and servo 01 as the tilt servo. The preset P/T cam positions are just a combo of two servo positions. Note: Try the batch file method here first, as it may do all you need. If you need the extra functions of the compiled files, then give them a try.
Parallel port webcam switcher
See Zoomkat's "El Cheapo" web controlled parallel port video/audio switcher link down the page for info on building one.
Winnov Zoom/Cam/Controls
To remotely control the Winnov capture card to switch cams and cam settings, and use the zoom/out function, I use VB scripting sendkeys to control the Videum Zoom application. This will allow remote web control of the winnov capture card. Info on the setup is located here. Kind of klunky, but it works. The "Winnov Videum Zoom" control panel is made active on the desktop, and the VB scripting sendkeys runs to change cams and zoom in and out. Move the videum control panel on the server desktop so just a little is visible on the screen and it is out of the way. To test, you can just put the vbs sendkeys files in any folder together with the .bat files and double click on the .vbs files or .bat files. This way you can see it work with out running the webserver. Also, you can see a few more Winnov items here including the MXC connector pinouts, and how to make a simple S-video/composite adapter from Radio Shack parts (it works either direction).
Turn Light ON/OFF
To turn a light ON and OFF, I use the basic control panel batch file to run a free command line program called CM17A to operate an X-10 Firecracker. Another free programs is mscm17a, which also works well being executed by a batch file. The Firecracker attaches to the computer serial port and sends commands to the various X10 devices.
Chime
I use this to play a .wav file on the speakers of the server machine. I origionally used it to play DTMF tones to control some relays, but now it has more use playing things like "OK slackers, back to work!", "Warning, Warning, step back from the missle launch control panel!", and (in a female voice) "Ohhh zoomkat, you are such a burning hunk O' love...". If you havewin95/98/me, copy the below batch script, paste in notepad, save as chime.bat, put in the cgi folder, and make a link to it. You can just double click on it to see how it works. You just make a simple link to it like hostname/cgi/chime.bat and it should work via the web.
@echo off
echo Status: 204 zoomkat's amazing batch file
echo.
echo.
sndrec32.exe /play /close %windir%\media\chimes.wav
cls
Popout Window
Putting your controls in a popout window is almost a *must*. This is what gives it a small border and saves space on the desktop. Once you get your control page worked out and tested, go here, here, or here, and put it in a popout.
Projects
===================================
Some homebrew pan/tilt cams here.
===================================
Mini-SSC setup here.
Web controlled 6 cam servo operated video and/or audio switcher (or reversing motor switch!) here.
===================================
Web controlled IR remote control for using the channel "UP" button over the web. Write a zero byte to the serial port. Pix here.
===================================
Zoomkat's "El Cheapo" web controlled parallel port video/audio switcher here, with a demo page here.
===================================
NEW 1/19/03: Zoomkat's "El Cheapo #2" web controlled parallel port video/audio switcher here.
===================================
NEW 2/11/03: Zoomkat's "El Cheapo #3" web controlled parallel port multicam (up to 40 cams) video/audio switcher here.
===================================
Zoomkat's web controlled serial port video switcher here.
===================================
NEW 1/02/04: Zoomkat's "El Cheapo" web controlled parallel port contact/switch status monitor here.
===================================
NEW 1/02/04: Zoomkat's "El Cheapo" web controlled parallel port 74HCT259 chip multi line control for controlling up to 120 devices here.
===================================
NEW 3/21/04: Zoomkat's "El Cheapo" web and computer controlled Mini Blind Tilt Control for computer home automation. Also controlling and automating blind tilting via the web. Uses inexpensive RC airplane servos here.
===================================
NEW 4/23/05:Servo controlled thermostat for computer controlled home automation setups here.
===================================
Links to sources of inexpensive cams
Supercircuits
Matco
CCTV Outlet
Polaris USA
Computer Geeks
"Runt", the main house "zoomkat" (of three).
The End
zoomkat
page established May 25, 2001
page last updated April 30, 2009