Update test script
This commit is contained in:
parent
d0ba6312c2
commit
7eba49d07f
@ -1,2 +1,60 @@
|
||||
const mod = require('.')
|
||||
console.log(mod.hello())
|
||||
|
||||
const o = mod.openOutput("/dev/ttyUSB0")
|
||||
|
||||
if (o.type !== "success") {
|
||||
return
|
||||
}
|
||||
|
||||
const movingHeads = [
|
||||
{
|
||||
startAddress: 1,
|
||||
pan: 0,
|
||||
tilt: 0,
|
||||
brightness: {
|
||||
type: "dimmer",
|
||||
value: 1,
|
||||
},
|
||||
rgbw: [255, 0, 0, 0],
|
||||
speed: 0,
|
||||
},
|
||||
{
|
||||
startAddress: 15,
|
||||
pan: 0,
|
||||
tilt: 0,
|
||||
brightness: {
|
||||
type: "dimmer",
|
||||
value: 1,
|
||||
},
|
||||
rgbw: [255, 0, 0, 0],
|
||||
speed: 0,
|
||||
},
|
||||
{
|
||||
startAddress: 29,
|
||||
pan: 0,
|
||||
tilt: 0,
|
||||
brightness: {
|
||||
type: "dimmer",
|
||||
value: 1,
|
||||
},
|
||||
rgbw: [255, 0, 0, 0],
|
||||
speed: 0,
|
||||
},
|
||||
{
|
||||
startAddress: 43,
|
||||
pan: 0,
|
||||
tilt: 0,
|
||||
brightness: {
|
||||
type: "dimmer",
|
||||
value: 1,
|
||||
},
|
||||
rgbw: [0, 0, 0, 255],
|
||||
speed: 0,
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
r = o.set(movingHeads);
|
||||
console.log(r);
|
||||
|
||||
o.close();
|
||||
|
Loading…
Reference in New Issue
Block a user