spark/core-firmware — pull request #286 by jacobrosenthal (2014-09-03 09:29:15+00:00)
Title: input and output enum was reversed, fixes #282

In arduino world the enum for input is canonically 0, however spark swapped them and made theirs 1.

Over the years developers have been somewhat lazy and might just use pinmode(pin,0) and mean input . Firmata specifically does this.

Seems easy enough to match that behavior before Spark has too much legacy code.