View rpc-validation.json
[
{
"id": "63240eaa.bba928",
"type": "subflow",
"name": "RPC Out",
"info": "",
"in": [
{
"x": 200,
"y": 120,
View canvas_to_artnet.json
[{"id":"114a5d8c.c2b092","type":"inject","z":"be63dfb5.edca6","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":160,"y":120,"wires":[["94f49e0d.136bb8"]]},{"id":"94f49e0d.136bb8","type":"function","z":"be63dfb5.edca6","name":"[0,255,0]","func":"msg.payload = Buffer.alloc(64*3, Buffer.from([0,255,0]));\nreturn msg;","outputs":1,"noerr":0,"x":320,"y":120,"wires":[["32b2de23.568a02"]]},{"id":"ee2e23c1.8721d","type":"function","z":"be63dfb5.edca6","name":"black","func":"msg.payload = Buffer.alloc(64*3, Buffer.from([0,0,0]));\nreturn msg;","outputs":1,"noerr":0,"x":310,"y":220,"wires":[["32b2de23.568a02"]]},{"id":"1b558bf5.5f2984","type":"inject","z":"be63dfb5.edca6","name":"","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":160,"y":220,"wires":[["ee2e23c1.8721d"]]},{"id":"23a4922f.e7fbae","type":"function","z":"be63dfb5.edca6","name":"[0,0,255]","func":"msg.payload = Buffer.alloc(64*3, Buffer.from(
View rpi-ws281x-native.js
const NUM_LEDS = 64;
if (!context.ws281x) {
context.ws281x = require('rpi-ws281x-native');
context.finalArray = new Uint32Array(NUM_LEDS);
context.ws281x.init(NUM_LEDS, {dmaNum: 10});
}
if (context.ws281x) {
View flows.json
[{"id":"da36d92a.fdbea","type":"comment","z":"f3e76b7c.c6075","name":"init flow.devices to empty object","info":"","x":190,"y":60,"wires":[]},{"id":"7fae03dc.30d794","type":"inject","z":"f3e76b7c.c6075","name":"","topic":"A","payload":"{\"host\":\"A\",\"status\":\"online\"}","payloadType":"json","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":210,"y":260,"wires":[["6b94ce72.3e99b8"]]},{"id":"45b494a3.7dfc5c","type":"inject","z":"f3e76b7c.c6075","name":"","topic":"B","payload":"{\"host\":\"B\",\"status\":\"online\"}","payloadType":"json","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":210,"y":300,"wires":[["6b94ce72.3e99b8"]]},{"id":"6b94ce72.3e99b8","type":"change","z":"f3e76b7c.c6075","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"{\t payload.host : payload\t}\t ","tot":"jsonata"},{"t":"set","p":"devices","pt":"flow","to":"$merge([$flowContext('devices'), payload])","tot":"jsonata"}],"action":"","property":"","from":"","to":"","reg":false,"x":540,"y":260,"wires":[["bd5
View Dockerfile
FROM nodered/node-red-docker:0.17.5
USER root
RUN apt-get update
RUN apt-get install -y libavahi-compat-libdnssd-dev avahi-daemon avahi-utils
RUN npm install node-red-node-discovery
COPY start.sh /
View docker-compose.yaml
version: '2'
services:
nodered:
image: nodered/node-red-docker:0.17.5
restart: always
environment:
- TZ=America/Montreal
logging:
driver: syslog
options:
View mqtt_rpc.json
[
{
"id": "64220941.ddbd78",
"type": "subflow",
"name": "mqtt request",
"info": "",
"in": [
{
"x": 60,
"y": 220,
View settings.xml
<artnet>
<send>1</send>
<console>1</console>
<networkAdapterIP>2.0.1.1</networkAdapterIP>
<nodeIP>2.0.1.12</nodeIP>
<nodePort>6454</nodePort>
<subnet>0</subnet>
<universe>0</universe>
<shortName>MF Banff Node</shortName>
<longName>MF Banff Video to Art-Net</longName>
View interolator.js
//Node gameloop
var NanoTimer = require('nanotimer');
var count = 0;
var source = msg.payload.source;
var target = msg.payload.target;
var interval = 16;
View docker-compose.yml
version: '2'
services:
nodered1:
depends_on:
- mosquitto
image: nodered/node-red-docker:0.17.5
ports:
- "1884:1880"
restart: always