port of Arduino LPD8806 code to javascript for beaglebone black