Not sure if it helps, but if you unplugged the IR LED and put it in the other way around, now it'd have 0 to 3.3v on it and would be turning on, and when A6 was 1, it'd have 0 to -3.3v and would turn off.
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.
Yes, that sounds like a good explanation...
Not sure if it helps, but if you unplugged the IR LED and put it in the other way around, now it'd have 0 to 3.3v on it and would be turning on, and when A6 was 1, it'd have 0 to -3.3v and would turn off.