This is a test of making eyeballs respond to a keyboard up/down left/right arrows.
The code works out the hypotenuse
position of the x,y of the iris and pupil separately to give more realism.
It is a prototype for twitr_janus, a project to build a remote control puppet over the internet using open source and common tech.
It will eventually be converted to an Arduino control sketch to move physical eyeballs remotely, based on data sent via the web.
feel free to blag the code.
For more info check out Making Weird Things blog: