node-red-contrib-vban
Version:
Nodes to interact with vban protocol
120 lines (119 loc) • 2.87 kB
JSON
[
{
"id": "f1e7fd77e114d902",
"type": "tab",
"label": "Receive Text Example",
"disabled": false,
"info": "",
"env": []
},
{
"id": "8da3b003ac708e5a",
"type": "vban-receiver",
"z": "f1e7fd77e114d902",
"name": "",
"VBANServerNodeId": "",
"x": 330,
"y": 300,
"wires": [["e900fb332f048d32"]]
},
{
"id": "e900fb332f048d32",
"type": "vban-ip-filter",
"z": "f1e7fd77e114d902",
"name": "",
"allowedIps": "::1 ; 127.0.0.1 ; 192.168.0.0/16 ; 10.0.0.0/8 ; 172.16.0.0/12",
"x": 590,
"y": 300,
"wires": [["e9a924df53cff516"], ["ac3e8e327af22312"]]
},
{
"id": "e9a924df53cff516",
"type": "function",
"z": "f1e7fd77e114d902",
"name": "",
"func": "// 0x40 === TEXT\nif(msg.payload.packet.subProtocol === 0x40) {\n return msg\n}",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 860,
"y": 280,
"wires": [["91bf2ed04b657faf"]]
},
{
"id": "91bf2ed04b657faf",
"type": "debug",
"z": "f1e7fd77e114d902",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 1210,
"y": 280,
"wires": []
},
{
"id": "ac3e8e327af22312",
"type": "debug",
"z": "f1e7fd77e114d902",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 850,
"y": 440,
"wires": []
},
{
"id": "6a3719997d40b851",
"type": "comment",
"z": "f1e7fd77e114d902",
"name": "receive VBAN event",
"info": "",
"x": 350,
"y": 260,
"wires": []
},
{
"id": "4597d9a7c87010de",
"type": "comment",
"z": "f1e7fd77e114d902",
"name": "check the sender ip",
"info": "",
"x": 630,
"y": 340,
"wires": []
},
{
"id": "2ba4560878de30ea",
"type": "comment",
"z": "f1e7fd77e114d902",
"name": "filter on subProtocol (TEXT / 0x40)",
"info": "",
"x": 940,
"y": 240,
"wires": []
},
{
"id": "bbc59510e348b5bb",
"type": "comment",
"z": "f1e7fd77e114d902",
"name": "only TEXT packet comes here",
"info": "",
"x": 1270,
"y": 240,
"wires": []
}
]