I am able to control a servo with pi-blaster from the command line successfully. However when I try to use pi-blaster.js to do so in Node.js (either at the node command line or from within a Node file) it does nothing.
works:
sudo echo "17=0" > /dev/pi-blaster
or
sudo echo "17=0.1" > /dev/pi-blaster
does not work:
var piblaster = require('pi-blaster.js');
piblaster.setPwm(17, 1 ); # 100% brightness
piblaster.setPwm(22, 0.2 ); # 20% brightness
piblaster.setPwm(23, 0 ); # off
I have already verified that pi-blaster.js is loaded correctly by Node.js as well.