Just to add that you could probably use a simple LDR in a black tube to block out ambient light, and an LED.
IR obviously has the bonus that you can't see it, but for extra geek cred you could use a laser (pointer) instead :)
@Gordon started
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Just to add that you could probably use a simple LDR in a black tube to block out ambient light, and an LED.
IR obviously has the bonus that you can't see it, but for extra geek cred you could use a laser (pointer) instead :)