(home)

Flashduino

Demos

Code

Project Log

( 11 January 2009 )

( 17 January 2009 )

( 19 January 2009 )

( 23 February 2009 )

( 1 March 2009 )

  urlDispatcher.addHandler("/", handleShow);
  urlDispatcher.addHandler("/r/a/*", handleReadAnalog);
  urlDispatcher.addHandler("/r/d/*", handleReadDigital);

( 1 March 2009 )

( 24 July 2009 )

<html>
<head>
<style>
img#image {visibility: hidden}
</style>
<script>
state = 0;
function toggle() {
  document["image"].src = "http://169.254.254.169/w/d/7/" + state;
  if (state == 0) {
    state = 1;
  } else {
    state = 0;
  }
  return false;
}

intervalId = 0;
function start() {
  intervalId = setInterval("toggle()",1000)
}

function stop() {
  clearInterval(intervalId);
}
</script>
</head>
<body>
<img name="image" id="image" src="http://169.254.254.169/w/d/7/1" >
<p><a href="#" onClick="javascript:toggle();">toggle</a></p>
<p><a href="#" onClick="javascript:start();">start</a></p>
<p><a href="#" onClick="javascript:stop();">stop</a></p>
</body>
</html>

Old notes

code@rancidbacon.com