var speed = 30;
var y = 1;
var x = speed + y;
var time = x - y;
var now;
campicture = new Image();

function stopClock() 
{
x = "off";
if (document.form0 != null)
{
	document.form0.clock.value = x;
}
}

function startClock() {
if (x != "off")
{
x = x - y;
if (document.form0 != null)
{
    document.form0.clock.value = x;
    if (x < .5)
    {reload()}
    timerID = setTimeout("startClock()", 1000);
    }
}
}

function reload()
{
now = new Date();
var camImg = "/nctc/cam/images/eaglecam.jpg" + "?" + now.getTime();
if (document.campicture != null)
{
	document.campicture.src = camImg;
	x = speed;
	if (document.form0 != null)
	{
		document.form0.clock.value = x;
	}
}
}