Add script.

This commit is contained in:
László Monda
2017-01-16 01:00:35 +01:00
parent 941639e3da
commit c3457e33b7

9
usb/mess-up-leds.js Executable file
View File

@@ -0,0 +1,9 @@
#!/usr/bin/env node
let uhk = require('./uhk');
const LED_CONTROL_REGISTER = 0;
uhk.sendUsbPackets([
new Buffer([uhk.usbCommands.writeLedDriver, uhk.leftLedDriverAddress, 18, LED_CONTROL_REGISTER,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff]),
new Buffer([uhk.usbCommands.writeLedDriver, uhk.rightLedDriverAddress, 18, LED_CONTROL_REGISTER,
0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff])
]);