[
    {
        "id": "a640a000.d83cb",
        "type": "tab",
        "label": "1-get-devices",
        "disabled": false,
        "info": "# get-devices: basic example\n\nIssues a _get-devices_ broadcast command and displays the received information for the access controller with serial number 405419896.\n\nThe _get-devices_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "f0ca7ab6.b09058",
        "type": "tab",
        "label": "2-get-device",
        "disabled": false,
        "info": "# get-device: basic example\n\nIssues a _get-device_ command to the controller with serial number 405419896.\n\nThe _get-device_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "8bcf2d43.2e243",
        "type": "tab",
        "label": "3-IPv4",
        "disabled": false,
        "info": "# set-ip: basic example\n\nIssues a _set-ip_ command to set the IPv4 address, netmask and gateway for the controller with serial number 405419896.\n\nThe _IPv4_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "c56e1667.998748",
        "type": "tab",
        "label": "4-listen",
        "disabled": false,
        "info": "# event-listener: basic examples\n\nBasic examples for the _listen_, _get-listener_ and _set-listener_ nodes.\n\n - The _listen_ example establishes a listening node on startup that publishes received events to the debug window\n\n - the _get-listener_ example retrieves the current event listener IP address and port for the controller with serial number 405419896.\n\n - the _set-listener_ example sets '192.168.1.100:60001' as the event listener IP address and port for the controller with serial number 405419896.\n\nThe _listen_ flow in the _dashboard_ flowset contains a more complete example.\n"
    },
    {
        "id": "b2b669ed.2b50b8",
        "type": "tab",
        "label": "5-status",
        "disabled": false,
        "info": "# get-status: basic example\n\nIssues a _get-status_ command to the controller with serial number 405419896 and publishes the received status to the debug pane.\n\nThe _status_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "f7a455cc.3fefe8",
        "type": "tab",
        "label": "6-time",
        "disabled": false,
        "info": "# system date/time: basic examples\n\nBasic examples for the _get-time_ and _set-time_ nodes.\n\n - the _get-time_ example retrieves the current system date and time from the controller with serial number 405419896.\n\n - the _set-time_ example sets the system date and time for the controller with serial number 405419896 to the current time\n\nThe _time_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "86bbf50e.a7f188",
        "type": "tab",
        "label": "7-doors",
        "disabled": false,
        "info": "# door control: basic examples\n\nBasic examples for the _get-door-control_, _set-door-control_ and _open-door_ nodes.\n\n - the _get-door-control_ example retrieves the current open delay to 5 seconds and control state for door 1 from the controller with serial number 405419896.\n\n - the _set-door-control_ example sets the open delay to 5 seconds and control state to 'normally closed' for door 1 on the controller with serial number 405419896.\n\n - the _open-door_ example opens door 1 on the controller with serial number 405419896 to the current time\n\nThe _doors_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "2a36b650.4b9b7a",
        "type": "tab",
        "label": "8-cards",
        "disabled": false,
        "info": "# card management: basic examples\n\nBasic examples for the _get-cards_, _get-card_, _get-card-by-index_, _put-card_, _delete-card_ and _delete-cards_ nodes.\n\n - the _get-cards_ example retrieves the number of stored card records from the controller with serial number 405419896.\n\n - the _get-card_ example retrieves the card record for card number 65538 from the controller with serial number 405419896.\n\n- the _get-card-by-index_ example retrieves the card record at record #3 from the controller with serial number 405419896.\n\n - the _put-card_ example stores card number 61532836 (valid from 2021-01-01 to 2021-13-31 and with access to doors 1, 3 and 4) to the controller with serial number 405419896.\n\n - the _delete-card_ example deletes the card record for card number 61532836 from the controller with serial number 405419896.\n\n - the _delete-cards_ example deletes all card records from the controller with serial number 405419896.\n\nThe _cards_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "590b5d52.6f70e4",
        "type": "tab",
        "label": "9-time-profiles",
        "disabled": false,
        "info": ""
    },
    {
        "id": "66c3d22e.434c7c",
        "type": "tab",
        "label": "10-tasklist",
        "disabled": false,
        "info": ""
    },
    {
        "id": "b5da19a5.72a0c8",
        "type": "tab",
        "label": "11-events",
        "disabled": false,
        "info": "# event retrieval: basic examples\n\nBasic examples for the _get-event-index_, _set-event-index_ and _get-event_ nodes.\n\n - the _get-event-index_ example retrieves the current 'downloaded event index' from the controller with serial number 405419896.\n\n - the _set-event-index_ example set the 'downloaded event index' to 17 for the controller with serial number 405419896.\n\n - the _get-event_ example retrieves the event record at record #3 from the controller with serial number 405419896.\n\nThe _events_ flow in the _dashboard_ flowset contains a more complete example."
    },
    {
        "id": "084b05a6c596f92a",
        "type": "tab",
        "label": "12-set-pc-control",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "093e8f2cad65974a",
        "type": "tab",
        "label": "13-restore-default-parameters",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "cf35d9904542f0af",
        "type": "uhppoted-config",
        "name": "examples",
        "timeout": "2500",
        "bind": "192.168.1.100",
        "broadcast": "192.168.1.255:60000",
        "listen": "192.168.1.100:60001",
        "controllers": "{\"303986753\":{\"address\":\"192.168.1.100:60000\",\"broadcast\":false},\"405419896\":{\"address\":\"192.168.1.100:60000\",\"broadcast\":true}}",
        "debug": true
    },
    {
        "id": "31429769.0664e8",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 520,
        "y": 60,
        "wires": []
    },
    {
        "id": "82a8517a.6ef88",
        "type": "inject",
        "z": "a640a000.d83cb",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "test-get-controllers",
        "payload": "{}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "fa5c3f4666ddf394"
            ]
        ]
    },
    {
        "id": "6699677.c355098",
        "type": "function",
        "z": "a640a000.d83cb",
        "name": "parse",
        "func": "for (i=0; i<msg.payload.length; i++) {\n    deviceId = msg.payload[i].deviceId\n    device = msg.payload[i].device;\n    if (deviceId == 405419896) {\n        return msg.payload[i];        \n    }\n}\n\nreturn { device: {} }",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "x": 510,
        "y": 100,
        "wires": [
            [
                "86fc5747.ceaf78",
                "27be4ab8.2eac96",
                "301b11ef.dbf73e",
                "10c3ab90.e85124",
                "5707c80e.570f78",
                "86dd1102.ee59d",
                "c6be71d1.b0f19"
            ]
        ]
    },
    {
        "id": "86fc5747.ceaf78",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "serial-number",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.serialNumber",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 720,
        "y": 100,
        "wires": []
    },
    {
        "id": "27be4ab8.2eac96",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "address",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.address",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 140,
        "wires": []
    },
    {
        "id": "301b11ef.dbf73e",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "netmask",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.netmask",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 180,
        "wires": []
    },
    {
        "id": "10c3ab90.e85124",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "gateway",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.gateway",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 220,
        "wires": []
    },
    {
        "id": "5707c80e.570f78",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "MAC",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.MAC",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 690,
        "y": 260,
        "wires": []
    },
    {
        "id": "86dd1102.ee59d",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "version",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.version",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 300,
        "wires": []
    },
    {
        "id": "c6be71d1.b0f19",
        "type": "debug",
        "z": "a640a000.d83cb",
        "name": "date",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.date",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 690,
        "y": 340,
        "wires": []
    },
    {
        "id": "fa5c3f4666ddf394",
        "type": "uhppoted-get-devices",
        "z": "a640a000.d83cb",
        "name": "get-devices",
        "topic": "get-devices",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 100,
        "wires": [
            [
                "31429769.0664e8",
                "6699677.c355098"
            ]
        ]
    },
    {
        "id": "a308f042.ba17e",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 660,
        "y": 100,
        "wires": []
    },
    {
        "id": "661f7370.91414c",
        "type": "inject",
        "z": "f0ca7ab6.b09058",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "cf961bd6.504938"
            ]
        ]
    },
    {
        "id": "cf961bd6.504938",
        "type": "uhppoted-get-device",
        "z": "f0ca7ab6.b09058",
        "name": "get-device",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 100,
        "wires": [
            [
                "1b475bda78fb39d0"
            ]
        ]
    },
    {
        "id": "6114aece.3cdf7",
        "type": "function",
        "z": "f0ca7ab6.b09058",
        "name": "parse",
        "func": "return { \n    device: msg.payload.device \n}\n",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "x": 650,
        "y": 140,
        "wires": [
            [
                "58ed0404.db248c",
                "61911f03.0d3d8",
                "d091e3d4.0b37",
                "97b9824d.da92d",
                "b539bbe4.6eb9d8",
                "8e4bb15a.08e78",
                "73a68892.3598d8"
            ]
        ]
    },
    {
        "id": "58ed0404.db248c",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "serial-number",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.serialNumber",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 140,
        "wires": []
    },
    {
        "id": "61911f03.0d3d8",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "address",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.address",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 180,
        "wires": []
    },
    {
        "id": "d091e3d4.0b37",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "netmask",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.netmask",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 220,
        "wires": []
    },
    {
        "id": "97b9824d.da92d",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "gateway",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.gateway",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 260,
        "wires": []
    },
    {
        "id": "b539bbe4.6eb9d8",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "MAC",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.MAC",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 300,
        "wires": []
    },
    {
        "id": "8e4bb15a.08e78",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "version",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.version",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 340,
        "wires": []
    },
    {
        "id": "73a68892.3598d8",
        "type": "debug",
        "z": "f0ca7ab6.b09058",
        "name": "date",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "device.date",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 380,
        "wires": []
    },
    {
        "id": "4cfaeb95fa7b0084",
        "type": "inject",
        "z": "f0ca7ab6.b09058",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 180,
        "wires": [
            [
                "f12b1459d211e6d6"
            ]
        ]
    },
    {
        "id": "f12b1459d211e6d6",
        "type": "uhppoted-get-device",
        "z": "f0ca7ab6.b09058",
        "name": "get-device-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 180,
        "wires": [
            [
                "68a62e02b458d87a"
            ]
        ]
    },
    {
        "id": "e31739459dec6f32",
        "type": "link in",
        "z": "f0ca7ab6.b09058",
        "name": "received",
        "links": [
            "1b475bda78fb39d0",
            "68a62e02b458d87a",
            "ef8850a20f5f68b0"
        ],
        "x": 545,
        "y": 100,
        "wires": [
            [
                "a308f042.ba17e"
            ]
        ]
    },
    {
        "id": "45d6c42b45d140b7",
        "type": "link in",
        "z": "f0ca7ab6.b09058",
        "name": "get-device",
        "links": [
            "1b475bda78fb39d0",
            "68a62e02b458d87a",
            "ef8850a20f5f68b0"
        ],
        "x": 545,
        "y": 140,
        "wires": [
            [
                "6114aece.3cdf7"
            ]
        ]
    },
    {
        "id": "1b475bda78fb39d0",
        "type": "link out",
        "z": "f0ca7ab6.b09058",
        "name": "get-device-udp",
        "mode": "link",
        "links": [
            "45d6c42b45d140b7",
            "e31739459dec6f32"
        ],
        "x": 435,
        "y": 100,
        "wires": []
    },
    {
        "id": "68a62e02b458d87a",
        "type": "link out",
        "z": "f0ca7ab6.b09058",
        "name": "get-device-tcp",
        "mode": "link",
        "links": [
            "45d6c42b45d140b7",
            "e31739459dec6f32"
        ],
        "x": 435,
        "y": 180,
        "wires": []
    },
    {
        "id": "441f9cddf524f6bb",
        "type": "inject",
        "z": "f0ca7ab6.b09058",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "05b93141d184148d"
            ]
        ]
    },
    {
        "id": "05b93141d184148d",
        "type": "uhppoted-get-device",
        "z": "f0ca7ab6.b09058",
        "name": "get-device-udp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 140,
        "wires": [
            [
                "ef8850a20f5f68b0"
            ]
        ]
    },
    {
        "id": "ef8850a20f5f68b0",
        "type": "link out",
        "z": "f0ca7ab6.b09058",
        "name": "get-device-tcp",
        "mode": "link",
        "links": [
            "45d6c42b45d140b7",
            "e31739459dec6f32"
        ],
        "x": 435,
        "y": 140,
        "wires": []
    },
    {
        "id": "c601d685.422838",
        "type": "debug",
        "z": "8bcf2d43.2e243",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 620,
        "y": 100,
        "wires": []
    },
    {
        "id": "da41e071.55ece",
        "type": "inject",
        "z": "8bcf2d43.2e243",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-address",
        "payload": "{\"controller\":{\"id\":405419896},\"address\":\"192.168.1.125\",\"netmask\":\"255.255.255.0\",\"gateway\":\"192.168.1.1\"}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "13a984d5.221c9b"
            ]
        ]
    },
    {
        "id": "13a984d5.221c9b",
        "type": "uhppoted-set-ip",
        "z": "8bcf2d43.2e243",
        "name": "set-ip",
        "config": "cf35d9904542f0af",
        "x": 270,
        "y": 100,
        "wires": [
            [
                "142d6c4246ae8ffb"
            ]
        ]
    },
    {
        "id": "b267a94cc5f28f8e",
        "type": "inject",
        "z": "8bcf2d43.2e243",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-address",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"address\":\"192.168.1.125\",\"netmask\":\"255.255.255.0\",\"gateway\":\"192.168.1.1\"}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "2312b07b0bdde6e8"
            ]
        ]
    },
    {
        "id": "2312b07b0bdde6e8",
        "type": "uhppoted-set-ip",
        "z": "8bcf2d43.2e243",
        "name": "set-ip-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 280,
        "y": 140,
        "wires": [
            [
                "6c1d1b24d0c2e59f"
            ]
        ]
    },
    {
        "id": "6936a212ffa86446",
        "type": "link in",
        "z": "8bcf2d43.2e243",
        "name": "received",
        "links": [
            "142d6c4246ae8ffb",
            "6c1d1b24d0c2e59f"
        ],
        "x": 505,
        "y": 100,
        "wires": [
            [
                "c601d685.422838"
            ]
        ]
    },
    {
        "id": "142d6c4246ae8ffb",
        "type": "link out",
        "z": "8bcf2d43.2e243",
        "name": "set-ip-udp",
        "mode": "link",
        "links": [
            "6936a212ffa86446"
        ],
        "x": 395,
        "y": 100,
        "wires": []
    },
    {
        "id": "6c1d1b24d0c2e59f",
        "type": "link out",
        "z": "8bcf2d43.2e243",
        "name": "set-ip-tcp",
        "mode": "link",
        "links": [
            "6936a212ffa86446"
        ],
        "x": 395,
        "y": 140,
        "wires": []
    },
    {
        "id": "b94136c7.ef3808",
        "type": "debug",
        "z": "c56e1667.998748",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 80,
        "wires": []
    },
    {
        "id": "19dfdabc.2fc645",
        "type": "inject",
        "z": "c56e1667.998748",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 180,
        "wires": [
            [
                "75e6f5f0.c7e47c"
            ]
        ]
    },
    {
        "id": "75e6f5f0.c7e47c",
        "type": "uhppoted-get-listener",
        "z": "c56e1667.998748",
        "name": "get-listener",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 180,
        "wires": [
            [
                "dd4eef340b555843"
            ]
        ]
    },
    {
        "id": "48b92667.8a59b8",
        "type": "uhppoted-set-listener",
        "z": "c56e1667.998748",
        "name": "set-listener",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 300,
        "wires": [
            [
                "2be6914f23d7b2a5"
            ]
        ]
    },
    {
        "id": "87c6a583.0bc8c8",
        "type": "inject",
        "z": "c56e1667.998748",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-listener",
        "payload": "{\"controller\":{\"id\":405419896},\"address\":\"192.168.1.100\",\"port\":60001,\"interval\":15}",
        "payloadType": "json",
        "x": 130,
        "y": 300,
        "wires": [
            [
                "48b92667.8a59b8"
            ]
        ]
    },
    {
        "id": "4a5cf0bf.725ff",
        "type": "debug",
        "z": "c56e1667.998748",
        "name": "listener-address",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.address",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 780,
        "y": 120,
        "wires": []
    },
    {
        "id": "e37a3ee9.78969",
        "type": "debug",
        "z": "c56e1667.998748",
        "name": "listener-port",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.port",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 770,
        "y": 160,
        "wires": []
    },
    {
        "id": "18a61437.de498c",
        "type": "uhppoted-listen",
        "z": "c56e1667.998748",
        "name": "listen",
        "config": "cf35d9904542f0af",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "b8dcd439.9a0448"
            ]
        ]
    },
    {
        "id": "b8dcd439.9a0448",
        "type": "debug",
        "z": "c56e1667.998748",
        "name": "event",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 270,
        "y": 100,
        "wires": []
    },
    {
        "id": "86aa48a9e620c6cf",
        "type": "inject",
        "z": "c56e1667.998748",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "c7466e083310bf9b"
            ]
        ]
    },
    {
        "id": "c7466e083310bf9b",
        "type": "uhppoted-get-listener",
        "z": "c56e1667.998748",
        "name": "get-listener-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 220,
        "wires": [
            [
                "11b333706a2d406b"
            ]
        ]
    },
    {
        "id": "8dc08c333b80e03c",
        "type": "uhppoted-set-listener",
        "z": "c56e1667.998748",
        "name": "set-listener-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 340,
        "wires": [
            [
                "822c4512104ba471"
            ]
        ]
    },
    {
        "id": "22512f8ce8fabe30",
        "type": "inject",
        "z": "c56e1667.998748",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-listener",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"address\":\"192.168.1.100\",\"port\":60001,\"interval\":15}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "8dc08c333b80e03c"
            ]
        ]
    },
    {
        "id": "fac10babfa379001",
        "type": "link in",
        "z": "c56e1667.998748",
        "name": "received",
        "links": [
            "dd4eef340b555843",
            "11b333706a2d406b",
            "2be6914f23d7b2a5",
            "822c4512104ba471"
        ],
        "x": 615,
        "y": 80,
        "wires": [
            [
                "b94136c7.ef3808"
            ]
        ]
    },
    {
        "id": "6732b5b29ab98d3a",
        "type": "link in",
        "z": "c56e1667.998748",
        "name": "get-listener",
        "links": [
            "dd4eef340b555843",
            "11b333706a2d406b"
        ],
        "x": 615,
        "y": 120,
        "wires": [
            [
                "4a5cf0bf.725ff",
                "e37a3ee9.78969",
                "7957838146c94697"
            ]
        ]
    },
    {
        "id": "dd4eef340b555843",
        "type": "link out",
        "z": "c56e1667.998748",
        "name": "get-listener-udp",
        "mode": "link",
        "links": [
            "6732b5b29ab98d3a",
            "fac10babfa379001"
        ],
        "x": 435,
        "y": 180,
        "wires": []
    },
    {
        "id": "11b333706a2d406b",
        "type": "link out",
        "z": "c56e1667.998748",
        "name": "get-listener-tcp",
        "mode": "link",
        "links": [
            "6732b5b29ab98d3a",
            "fac10babfa379001"
        ],
        "x": 435,
        "y": 220,
        "wires": []
    },
    {
        "id": "2be6914f23d7b2a5",
        "type": "link out",
        "z": "c56e1667.998748",
        "name": "set-listener-udp",
        "mode": "link",
        "links": [
            "fac10babfa379001"
        ],
        "x": 425,
        "y": 300,
        "wires": []
    },
    {
        "id": "822c4512104ba471",
        "type": "link out",
        "z": "c56e1667.998748",
        "name": "set-listener-tcp",
        "mode": "link",
        "links": [
            "fac10babfa379001"
        ],
        "x": 425,
        "y": 340,
        "wires": []
    },
    {
        "id": "7957838146c94697",
        "type": "debug",
        "z": "c56e1667.998748",
        "name": "auto-send-interval",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.interval",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 790,
        "y": 200,
        "wires": []
    },
    {
        "id": "2dc88a53.cf8646",
        "type": "inject",
        "z": "b2b669ed.2b50b8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "1d2d547f.68acbc"
            ]
        ]
    },
    {
        "id": "1d2d547f.68acbc",
        "type": "uhppoted-get-status",
        "z": "b2b669ed.2b50b8",
        "name": "get-status",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 100,
        "wires": [
            [
                "5d4523a5d21855c8"
            ]
        ]
    },
    {
        "id": "52d5b0c5.0e178",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 680,
        "y": 100,
        "wires": []
    },
    {
        "id": "66b13a53.2d40c4",
        "type": "function",
        "z": "b2b669ed.2b50b8",
        "name": "parse",
        "func": "return { state: msg.payload.state }\n",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "x": 670,
        "y": 140,
        "wires": [
            [
                "ef31d4ba.63efa8",
                "29ce6298.a64dbe",
                "556bdbce.b524f4",
                "6111d895.7465d8",
                "4fb75951.33bd28",
                "b2228a25.b93978",
                "cd1868d9.6cea48",
                "e838e0df.3d412",
                "a0e71bbf.291688",
                "ae4ad5b4.12a328",
                "68b25cad.09ccb4",
                "8dcc56b2.9d3838",
                "b6e7e1e1.f8ea5",
                "b67b2038.bdb01",
                "8e8ff17a.6d6b9",
                "87389d80.11682",
                "69fc31ff.ef909",
                "16fccb9a.92d2e4",
                "ad99bfe8.44984",
                "1d9c039d.3e3e1c",
                "6a7fa162.6c726",
                "6d6a1058.fbb0d",
                "8927a0c3.ec594",
                "dbbde5d.034b118",
                "26e811ba.7bad4e",
                "b0a7a2ad.4e775"
            ]
        ]
    },
    {
        "id": "ef31d4ba.63efa8",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "serial-number",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.serialNumber",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 140,
        "wires": []
    },
    {
        "id": "29ce6298.a64dbe",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.index",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.index",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 320,
        "wires": []
    },
    {
        "id": "556bdbce.b524f4",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.type",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.type.event",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 360,
        "wires": []
    },
    {
        "id": "6111d895.7465d8",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.granted",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.granted",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 400,
        "wires": []
    },
    {
        "id": "4fb75951.33bd28",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.door",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.door",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 440,
        "wires": []
    },
    {
        "id": "b2228a25.b93978",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.direction",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.direction.direction",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 480,
        "wires": []
    },
    {
        "id": "cd1868d9.6cea48",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.card",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.card",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 520,
        "wires": []
    },
    {
        "id": "e838e0df.3d412",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "event.timestamp",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.event.timestamp",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 930,
        "y": 560,
        "wires": []
    },
    {
        "id": "a0e71bbf.291688",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "door-1",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.doors[1]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 620,
        "wires": []
    },
    {
        "id": "ae4ad5b4.12a328",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "door-2",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.doors[2]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 660,
        "wires": []
    },
    {
        "id": "68b25cad.09ccb4",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "door-3",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.doors[3]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 700,
        "wires": []
    },
    {
        "id": "8dcc56b2.9d3838",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "door-4",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.doors[4]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 740,
        "wires": []
    },
    {
        "id": "b6e7e1e1.f8ea5",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "button-1",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.buttons[1]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 800,
        "wires": []
    },
    {
        "id": "b67b2038.bdb01",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "button-2",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.buttons[2]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 840,
        "wires": []
    },
    {
        "id": "8e8ff17a.6d6b9",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "button-3",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.buttons[3]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 880,
        "wires": []
    },
    {
        "id": "87389d80.11682",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "button-4",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.buttons[4]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 920,
        "wires": []
    },
    {
        "id": "69fc31ff.ef909",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "system-status",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.system.status",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 180,
        "wires": []
    },
    {
        "id": "16fccb9a.92d2e4",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "system-date",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.system.date",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 220,
        "wires": []
    },
    {
        "id": "ad99bfe8.44984",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "system-time",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.system.time",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 260,
        "wires": []
    },
    {
        "id": "1d9c039d.3e3e1c",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "special-info",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.specialInfo",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 1160,
        "wires": []
    },
    {
        "id": "6a7fa162.6c726",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "relay-1",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.relays.relays[1]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 980,
        "wires": []
    },
    {
        "id": "6d6a1058.fbb0d",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "relay-2",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.relays.relays[2]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 1020,
        "wires": []
    },
    {
        "id": "8927a0c3.ec594",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "relay-3",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.relays.relays[3]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 1060,
        "wires": []
    },
    {
        "id": "dbbde5d.034b118",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "relay-4",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.relays.relays[4]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 890,
        "y": 1100,
        "wires": []
    },
    {
        "id": "26e811ba.7bad4e",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "force-locked",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.inputs.forceLock",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 910,
        "y": 1200,
        "wires": []
    },
    {
        "id": "b0a7a2ad.4e775",
        "type": "debug",
        "z": "b2b669ed.2b50b8",
        "name": "fire-alarm",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "state.inputs.fireAlarm",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 900,
        "y": 1240,
        "wires": []
    },
    {
        "id": "345ecd1b51ecbc87",
        "type": "inject",
        "z": "b2b669ed.2b50b8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "c1164d125de7fb37"
            ]
        ]
    },
    {
        "id": "c1164d125de7fb37",
        "type": "uhppoted-get-status",
        "z": "b2b669ed.2b50b8",
        "name": "get-status-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 140,
        "wires": [
            [
                "0116cfccc8a58852"
            ]
        ]
    },
    {
        "id": "a4fd2e7b593a4f6e",
        "type": "link in",
        "z": "b2b669ed.2b50b8",
        "name": "received",
        "links": [
            "5d4523a5d21855c8",
            "0116cfccc8a58852"
        ],
        "x": 565,
        "y": 100,
        "wires": [
            [
                "52d5b0c5.0e178"
            ]
        ]
    },
    {
        "id": "665c34da74b0cd5c",
        "type": "link in",
        "z": "b2b669ed.2b50b8",
        "name": "get-status",
        "links": [
            "5d4523a5d21855c8",
            "0116cfccc8a58852"
        ],
        "x": 565,
        "y": 140,
        "wires": [
            [
                "66b13a53.2d40c4"
            ]
        ]
    },
    {
        "id": "5d4523a5d21855c8",
        "type": "link out",
        "z": "b2b669ed.2b50b8",
        "name": "get-status-udp",
        "mode": "link",
        "links": [
            "665c34da74b0cd5c",
            "a4fd2e7b593a4f6e"
        ],
        "x": 435,
        "y": 100,
        "wires": []
    },
    {
        "id": "0116cfccc8a58852",
        "type": "link out",
        "z": "b2b669ed.2b50b8",
        "name": "get-status-tcp",
        "mode": "link",
        "links": [
            "665c34da74b0cd5c",
            "a4fd2e7b593a4f6e"
        ],
        "x": 435,
        "y": 140,
        "wires": []
    },
    {
        "id": "6a3d799.3fe3688",
        "type": "uhppoted-get-time",
        "z": "f7a455cc.3fefe8",
        "name": "get-time",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 280,
        "y": 100,
        "wires": [
            [
                "9aad52af6b62af8c"
            ]
        ]
    },
    {
        "id": "2c2ab991.619516",
        "type": "debug",
        "z": "f7a455cc.3fefe8",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 780,
        "y": 100,
        "wires": []
    },
    {
        "id": "d84c21e5.b2692",
        "type": "inject",
        "z": "f7a455cc.3fefe8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "6a3d799.3fe3688"
            ]
        ]
    },
    {
        "id": "9d254489.c08578",
        "type": "inject",
        "z": "f7a455cc.3fefe8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-time",
        "payload": "{}",
        "payloadType": "json",
        "x": 130,
        "y": 240,
        "wires": [
            [
                "50ebe86.e579018"
            ]
        ]
    },
    {
        "id": "ea3bdfee.bf0d1",
        "type": "uhppoted-set-time",
        "z": "f7a455cc.3fefe8",
        "name": "set-time",
        "config": "cf35d9904542f0af",
        "x": 420,
        "y": 240,
        "wires": [
            [
                "ef82c758f4a627fe"
            ]
        ]
    },
    {
        "id": "cab00341.6e077",
        "type": "debug",
        "z": "f7a455cc.3fefe8",
        "name": "date-time",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.datetime",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 780,
        "y": 140,
        "wires": []
    },
    {
        "id": "50ebe86.e579018",
        "type": "function",
        "z": "f7a455cc.3fefe8",
        "name": "format",
        "func": "const format = (n, l) => String(n).padStart(l, '0')\nconst datetime = new Date()\n\nconst year = format(datetime.getFullYear(), 4)\nconst month = format(datetime.getMonth()+1, 2)\nconst day = format(datetime.getDate(), 2)\nconst hours = format(datetime.getHours(), 2)\nconst minutes = format(datetime.getMinutes(), 2)\nconst seconds = format(datetime.getSeconds(), 2)\n\nmsg.payload = { \n     controller: {\n        \"id\": 405419896\n     },\n     datetime: year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds\n}\n        \nreturn msg",
        "outputs": 1,
        "timeout": "",
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 270,
        "y": 240,
        "wires": [
            [
                "ea3bdfee.bf0d1"
            ]
        ]
    },
    {
        "id": "296aa0e2884f2bf7",
        "type": "uhppoted-get-time",
        "z": "f7a455cc.3fefe8",
        "name": "get-time-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 140,
        "wires": [
            [
                "1f5c7ad7c4d8e3d6"
            ]
        ]
    },
    {
        "id": "71e32904692a6463",
        "type": "inject",
        "z": "f7a455cc.3fefe8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "296aa0e2884f2bf7"
            ]
        ]
    },
    {
        "id": "a195b6e24d2fb8e0",
        "type": "inject",
        "z": "f7a455cc.3fefe8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "set-time",
        "payload": "{}",
        "payloadType": "json",
        "x": 130,
        "y": 280,
        "wires": [
            [
                "a582159b9006a6a5"
            ]
        ]
    },
    {
        "id": "0d96f9c39f461e84",
        "type": "uhppoted-set-time",
        "z": "f7a455cc.3fefe8",
        "name": "set-time-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 430,
        "y": 280,
        "wires": [
            [
                "ebd4ba354bada159"
            ]
        ]
    },
    {
        "id": "a582159b9006a6a5",
        "type": "function",
        "z": "f7a455cc.3fefe8",
        "name": "format",
        "func": "const format = (n, l) => String(n).padStart(l, '0')\nconst datetime = new Date()\n\nconst year = format(datetime.getFullYear(), 4)\nconst month = format(datetime.getMonth()+1, 2)\nconst day = format(datetime.getDate(), 2)\nconst hours = format(datetime.getHours(), 2)\nconst minutes = format(datetime.getMinutes(), 2)\nconst seconds = format(datetime.getSeconds(), 2)\n\nmsg.payload = { \n    controller: {\n        id: 405419896,\n        address: \"192.168.1.100\",\n        protocol: \"tcp\"\n     },\n    datetime: year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds\n}\n        \nreturn msg",
        "outputs": 1,
        "timeout": "",
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 270,
        "y": 280,
        "wires": [
            [
                "0d96f9c39f461e84"
            ]
        ]
    },
    {
        "id": "ebbb06164d63fc83",
        "type": "link in",
        "z": "f7a455cc.3fefe8",
        "name": "received",
        "links": [
            "9aad52af6b62af8c",
            "1f5c7ad7c4d8e3d6",
            "ef82c758f4a627fe",
            "ebd4ba354bada159"
        ],
        "x": 665,
        "y": 100,
        "wires": [
            [
                "2c2ab991.619516"
            ]
        ]
    },
    {
        "id": "ec9d863bf948c0c0",
        "type": "link in",
        "z": "f7a455cc.3fefe8",
        "name": "get-time",
        "links": [
            "9aad52af6b62af8c",
            "1f5c7ad7c4d8e3d6"
        ],
        "x": 665,
        "y": 140,
        "wires": [
            [
                "cab00341.6e077"
            ]
        ]
    },
    {
        "id": "9aad52af6b62af8c",
        "type": "link out",
        "z": "f7a455cc.3fefe8",
        "name": "get-time-udp",
        "mode": "link",
        "links": [
            "ebbb06164d63fc83",
            "ec9d863bf948c0c0"
        ],
        "x": 415,
        "y": 100,
        "wires": []
    },
    {
        "id": "1f5c7ad7c4d8e3d6",
        "type": "link out",
        "z": "f7a455cc.3fefe8",
        "name": "get-time-tcp",
        "mode": "link",
        "links": [
            "ebbb06164d63fc83",
            "ec9d863bf948c0c0"
        ],
        "x": 415,
        "y": 140,
        "wires": []
    },
    {
        "id": "ef82c758f4a627fe",
        "type": "link out",
        "z": "f7a455cc.3fefe8",
        "name": "set-time-udp",
        "mode": "link",
        "links": [
            "ebbb06164d63fc83"
        ],
        "x": 555,
        "y": 240,
        "wires": []
    },
    {
        "id": "ebd4ba354bada159",
        "type": "link out",
        "z": "f7a455cc.3fefe8",
        "name": "set-time-tcp",
        "mode": "link",
        "links": [
            "ebbb06164d63fc83"
        ],
        "x": 555,
        "y": 280,
        "wires": []
    },
    {
        "id": "7317e0e6.862af",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"door\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 101,
        "wires": [
            [
                "bedb99cc.cc0768"
            ]
        ]
    },
    {
        "id": "bedb99cc.cc0768",
        "type": "uhppoted-get-door-control",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 101,
        "wires": [
            [
                "e73ce23aa19abe5b"
            ]
        ]
    },
    {
        "id": "6d8d48f7.397bb8",
        "type": "uhppoted-set-door-control",
        "z": "86bbf50e.a7f188",
        "name": "set-door-control",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 220,
        "wires": [
            [
                "170a8997f0f967f4"
            ]
        ]
    },
    {
        "id": "5fb4202c.0de66",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"door\":1,\"delay\":6,\"control\":\"controlled\"}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "6d8d48f7.397bb8"
            ]
        ]
    },
    {
        "id": "6c1b3177.30bd2",
        "type": "uhppoted-open-door",
        "z": "86bbf50e.a7f188",
        "name": "open-door",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 340,
        "wires": [
            [
                "f294c9c72caecaf3"
            ]
        ]
    },
    {
        "id": "23ed32e1.98a00e",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"door\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "6c1b3177.30bd2"
            ]
        ]
    },
    {
        "id": "ed5427f.86328d8",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "door-1.delay",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doorControlState.delay",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 750,
        "y": 140,
        "wires": []
    },
    {
        "id": "e6a2598d.e7f958",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "door-1.control",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doorControlState.control.state",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 180,
        "wires": []
    },
    {
        "id": "e35ca985.ab1a28",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "door-1.opened",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.opened",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 220,
        "wires": []
    },
    {
        "id": "5cebf8a91adb13bb",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"keypads\":{\"1\":true,\"2\":true,\"3\":false,\"4\":true}}",
        "payloadType": "json",
        "x": 130,
        "y": 460,
        "wires": [
            [
                "76ada944ebac3023"
            ]
        ]
    },
    {
        "id": "4de9ec54d837178c",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "keypads",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.keypads",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 740,
        "y": 260,
        "wires": []
    },
    {
        "id": "76ada944ebac3023",
        "type": "uhppoted-activate-keypads",
        "z": "86bbf50e.a7f188",
        "name": "activate-keypads",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 460,
        "wires": [
            [
                "fc496019bae03531"
            ]
        ]
    },
    {
        "id": "92cf53d41bac1edc",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "updated",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.updated",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 740,
        "y": 300,
        "wires": []
    },
    {
        "id": "e6843ed2f354d55e",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"door\":3,\"passcodes\":[12345,999999,54321]}",
        "payloadType": "json",
        "x": 130,
        "y": 700,
        "wires": [
            [
                "d642fe8a140a7ba2"
            ]
        ]
    },
    {
        "id": "b67a695c34e6a8f8",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "ok",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.ok",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 730,
        "y": 380,
        "wires": []
    },
    {
        "id": "d642fe8a140a7ba2",
        "type": "uhppoted-set-door-passcodes",
        "z": "86bbf50e.a7f188",
        "name": "set-door-passcodes",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 700,
        "wires": [
            [
                "6787ef29ca04b5cc"
            ]
        ]
    },
    {
        "id": "d6a948ce207fa5f8",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"door\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "5201a1df3a6ee4f7"
            ]
        ]
    },
    {
        "id": "5201a1df3a6ee4f7",
        "type": "uhppoted-get-door-control",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 140,
        "wires": [
            [
                "b897e63817f2cb2c"
            ]
        ]
    },
    {
        "id": "dead4074a99e4f8d",
        "type": "uhppoted-set-door-control",
        "z": "86bbf50e.a7f188",
        "name": "set-door-control-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 260,
        "wires": [
            [
                "0f881fcbd72d349b"
            ]
        ]
    },
    {
        "id": "7c0d25f83ae1467c",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"door\":1,\"delay\":6,\"control\":\"controlled\"}",
        "payloadType": "json",
        "x": 130,
        "y": 260,
        "wires": [
            [
                "dead4074a99e4f8d"
            ]
        ]
    },
    {
        "id": "cff6891472c50262",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 740,
        "y": 100,
        "wires": []
    },
    {
        "id": "d874dfb06a4698ca",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "received",
        "links": [
            "e73ce23aa19abe5b",
            "b897e63817f2cb2c",
            "170a8997f0f967f4",
            "0f881fcbd72d349b",
            "f294c9c72caecaf3",
            "a1e0d05308b13aa7",
            "fc496019bae03531",
            "d91dcf9c43d204bc",
            "6787ef29ca04b5cc",
            "7eb5ceccaa9a254f",
            "0eb1407bfc40f24c",
            "abf8e4f13a69d570",
            "e646c18d505fcd6f",
            "d3175c9b3379689b",
            "e4b06e7eeeeef37b"
        ],
        "x": 605,
        "y": 100,
        "wires": [
            [
                "cff6891472c50262"
            ]
        ]
    },
    {
        "id": "e73ce23aa19abe5b",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "eb7d6e1b706abf04"
        ],
        "x": 455,
        "y": 101,
        "wires": []
    },
    {
        "id": "eb7d6e1b706abf04",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "door-control",
        "links": [
            "0f881fcbd72d349b",
            "170a8997f0f967f4",
            "b897e63817f2cb2c",
            "e73ce23aa19abe5b",
            "e646c18d505fcd6f"
        ],
        "x": 605,
        "y": 140,
        "wires": [
            [
                "ed5427f.86328d8",
                "e6a2598d.e7f958"
            ]
        ]
    },
    {
        "id": "b897e63817f2cb2c",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "eb7d6e1b706abf04"
        ],
        "x": 455,
        "y": 140,
        "wires": []
    },
    {
        "id": "170a8997f0f967f4",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-door-control",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "eb7d6e1b706abf04"
        ],
        "x": 465,
        "y": 220,
        "wires": []
    },
    {
        "id": "0f881fcbd72d349b",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-door-control",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "eb7d6e1b706abf04"
        ],
        "x": 465,
        "y": 260,
        "wires": []
    },
    {
        "id": "f27e6d7fd8dce889",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "open-door",
        "links": [
            "f294c9c72caecaf3",
            "a1e0d05308b13aa7"
        ],
        "x": 605,
        "y": 220,
        "wires": [
            [
                "e35ca985.ab1a28"
            ]
        ]
    },
    {
        "id": "f294c9c72caecaf3",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "open-door",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "f27e6d7fd8dce889"
        ],
        "x": 465,
        "y": 340,
        "wires": []
    },
    {
        "id": "094e6132ad3273c7",
        "type": "uhppoted-open-door",
        "z": "86bbf50e.a7f188",
        "name": "open-door-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 380,
        "wires": [
            [
                "a1e0d05308b13aa7"
            ]
        ]
    },
    {
        "id": "954d9da7d9090e4c",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"door\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 380,
        "wires": [
            [
                "094e6132ad3273c7"
            ]
        ]
    },
    {
        "id": "a1e0d05308b13aa7",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "open-door",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "f27e6d7fd8dce889"
        ],
        "x": 465,
        "y": 380,
        "wires": []
    },
    {
        "id": "63171c88ba09fd77",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "activate-keypads",
        "links": [
            "fc496019bae03531",
            "d91dcf9c43d204bc"
        ],
        "x": 605,
        "y": 260,
        "wires": [
            [
                "4de9ec54d837178c",
                "92cf53d41bac1edc"
            ]
        ]
    },
    {
        "id": "fc496019bae03531",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "activate-keypads",
        "mode": "link",
        "links": [
            "63171c88ba09fd77",
            "d874dfb06a4698ca"
        ],
        "x": 465,
        "y": 460,
        "wires": []
    },
    {
        "id": "f2bb7abbb67ee78c",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"keypads\":{\"1\":true,\"2\":true,\"3\":false,\"4\":true}}",
        "payloadType": "json",
        "x": 130,
        "y": 500,
        "wires": [
            [
                "a75f73ebbaa467c6"
            ]
        ]
    },
    {
        "id": "a75f73ebbaa467c6",
        "type": "uhppoted-activate-keypads",
        "z": "86bbf50e.a7f188",
        "name": "activate-keypads-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 500,
        "wires": [
            [
                "d91dcf9c43d204bc"
            ]
        ]
    },
    {
        "id": "d91dcf9c43d204bc",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "activate-keypads",
        "mode": "link",
        "links": [
            "63171c88ba09fd77",
            "d874dfb06a4698ca"
        ],
        "x": 465,
        "y": 500,
        "wires": []
    },
    {
        "id": "5ea032df07f2af52",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"interlock\":4}",
        "payloadType": "json",
        "x": 130,
        "y": 580,
        "wires": [
            [
                "de3b45665b6aec40"
            ]
        ]
    },
    {
        "id": "4dd316821f27ffc7",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "updated",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.updated",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 740,
        "y": 340,
        "wires": []
    },
    {
        "id": "de3b45665b6aec40",
        "type": "uhppoted-set-interlock",
        "z": "86bbf50e.a7f188",
        "name": "set-interlock",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 580,
        "wires": [
            [
                "7eb5ceccaa9a254f"
            ]
        ]
    },
    {
        "id": "ac4ac298e9509a82",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "set-interlock",
        "links": [
            "7eb5ceccaa9a254f",
            "0eb1407bfc40f24c"
        ],
        "x": 605,
        "y": 340,
        "wires": [
            [
                "4dd316821f27ffc7"
            ]
        ]
    },
    {
        "id": "7eb5ceccaa9a254f",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-interlock",
        "mode": "link",
        "links": [
            "ac4ac298e9509a82",
            "d874dfb06a4698ca"
        ],
        "x": 435,
        "y": 580,
        "wires": []
    },
    {
        "id": "7ac327cd0bfbb29f",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"interlock\":4}",
        "payloadType": "json",
        "x": 130,
        "y": 620,
        "wires": [
            [
                "8cf93a80729e7a1f"
            ]
        ]
    },
    {
        "id": "8cf93a80729e7a1f",
        "type": "uhppoted-set-interlock",
        "z": "86bbf50e.a7f188",
        "name": "set-interlock-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 620,
        "wires": [
            [
                "0eb1407bfc40f24c"
            ]
        ]
    },
    {
        "id": "0eb1407bfc40f24c",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-interlock",
        "mode": "link",
        "links": [
            "ac4ac298e9509a82",
            "d874dfb06a4698ca"
        ],
        "x": 435,
        "y": 620,
        "wires": []
    },
    {
        "id": "8b8fd882c7c39b2d",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "set-door-passcodes",
        "links": [
            "6787ef29ca04b5cc",
            "abf8e4f13a69d570"
        ],
        "x": 605,
        "y": 380,
        "wires": [
            [
                "b67a695c34e6a8f8"
            ]
        ]
    },
    {
        "id": "6787ef29ca04b5cc",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-door-passcodes",
        "mode": "link",
        "links": [
            "8b8fd882c7c39b2d",
            "d874dfb06a4698ca"
        ],
        "x": 495,
        "y": 700,
        "wires": []
    },
    {
        "id": "23b2963a3061710b",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"door\":3,\"passcodes\":[12345,999999,54321]}",
        "payloadType": "json",
        "x": 130,
        "y": 740,
        "wires": [
            [
                "c6418d53588430c8"
            ]
        ]
    },
    {
        "id": "c6418d53588430c8",
        "type": "uhppoted-set-door-passcodes",
        "z": "86bbf50e.a7f188",
        "name": "set-door-passcodes-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 740,
        "wires": [
            [
                "abf8e4f13a69d570"
            ]
        ]
    },
    {
        "id": "abf8e4f13a69d570",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-door-passcodes",
        "mode": "link",
        "links": [
            "8b8fd882c7c39b2d",
            "d874dfb06a4698ca"
        ],
        "x": 495,
        "y": 740,
        "wires": []
    },
    {
        "id": "7ae9f15ee4af768d",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"door\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 820,
        "wires": [
            [
                "8d528298028a11f7"
            ]
        ]
    },
    {
        "id": "e646c18d505fcd6f",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "eb7d6e1b706abf04"
        ],
        "x": 455,
        "y": 820,
        "wires": []
    },
    {
        "id": "8d528298028a11f7",
        "type": "uhppoted-get-door-control",
        "z": "86bbf50e.a7f188",
        "name": "get-door-control",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 820,
        "wires": [
            [
                "e646c18d505fcd6f"
            ]
        ]
    },
    {
        "id": "f3ca4fdad9a78df3",
        "type": "uhppoted-get-antipassback",
        "z": "86bbf50e.a7f188",
        "name": "get-antipassback",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 900,
        "wires": [
            [
                "d3175c9b3379689b"
            ]
        ]
    },
    {
        "id": "6d211686854c910a",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 900,
        "wires": [
            [
                "f3ca4fdad9a78df3"
            ]
        ]
    },
    {
        "id": "b8a2eb444a16be65",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "antipassback.code",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.antipassback.code",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 690,
        "y": 900,
        "wires": []
    },
    {
        "id": "086b806382d5b15c",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "antipassback.mode",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.antipassback.mode",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 690,
        "y": 940,
        "wires": []
    },
    {
        "id": "d3175c9b3379689b",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "get-antipassback",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "750a149ea7b6ea73"
        ],
        "x": 455,
        "y": 900,
        "wires": []
    },
    {
        "id": "750a149ea7b6ea73",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "get-antipassback",
        "links": [
            "d3175c9b3379689b"
        ],
        "x": 555,
        "y": 900,
        "wires": [
            [
                "b8a2eb444a16be65",
                "086b806382d5b15c"
            ]
        ]
    },
    {
        "id": "7bcdefd1c479efe1",
        "type": "uhppoted-set-antipassback",
        "z": "86bbf50e.a7f188",
        "name": "set-antipassback",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 1000,
        "wires": [
            [
                "e4b06e7eeeeef37b"
            ]
        ]
    },
    {
        "id": "005ec5f8ced155f3",
        "type": "inject",
        "z": "86bbf50e.a7f188",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"antipassback\":\"1:(2,3)\"}",
        "payloadType": "json",
        "x": 130,
        "y": 1000,
        "wires": [
            [
                "7bcdefd1c479efe1"
            ]
        ]
    },
    {
        "id": "e4b06e7eeeeef37b",
        "type": "link out",
        "z": "86bbf50e.a7f188",
        "name": "set-antipassback",
        "mode": "link",
        "links": [
            "d874dfb06a4698ca",
            "be4b68ccf5ca253e"
        ],
        "x": 455,
        "y": 1000,
        "wires": []
    },
    {
        "id": "36d242ec039f4458",
        "type": "debug",
        "z": "86bbf50e.a7f188",
        "name": "antipassback.ok",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.ok",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 680,
        "y": 1000,
        "wires": []
    },
    {
        "id": "be4b68ccf5ca253e",
        "type": "link in",
        "z": "86bbf50e.a7f188",
        "name": "set-antipassback",
        "links": [
            "e4b06e7eeeeef37b"
        ],
        "x": 555,
        "y": 1000,
        "wires": [
            [
                "36d242ec039f4458"
            ]
        ]
    },
    {
        "id": "60dcbb9f.c0dfa4",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 100,
        "wires": []
    },
    {
        "id": "3c02f9ca.0d36c6",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "4f2ad0e3.4c05e"
            ]
        ]
    },
    {
        "id": "4f2ad0e3.4c05e",
        "type": "uhppoted-get-cards",
        "z": "2a36b650.4b9b7a",
        "name": "get-cards",
        "config": "cf35d9904542f0af",
        "x": 280,
        "y": 100,
        "wires": [
            [
                "3218358125a216fe"
            ]
        ]
    },
    {
        "id": "6ce7f877.625e48",
        "type": "uhppoted-get-card",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "config": "cf35d9904542f0af",
        "x": 280,
        "y": 220,
        "wires": [
            [
                "329a1f747c65c6cd"
            ]
        ]
    },
    {
        "id": "356a2abe.2ea636",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"cardNumber\":8165537}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "6ce7f877.625e48"
            ]
        ]
    },
    {
        "id": "75f21b8.86ccbe4",
        "type": "function",
        "z": "2a36b650.4b9b7a",
        "name": "parse",
        "func": "if (msg.payload.card) {\n    msg.payload = msg.payload.card    \n} else {\n    msg.payload = {\n        number: '', \n        valid: { \n            from: '', \n            to: '' \n        }, \n        doors: { \n            1: '', \n            2: '', \n            3: '', \n            4: '' \n        },\n        PIN: ''\n    }\n}\n\nreturn msg\n\n",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 750,
        "y": 220,
        "wires": [
            [
                "b2fd1c17.3bc25",
                "975dcdef.367a6",
                "296d7d38.b2ed42",
                "7df632fc.3db16c",
                "cf4a8622.c08938",
                "9e2a41a9.a89d2",
                "6b38aa75.455224",
                "40085138d2d899c4"
            ]
        ]
    },
    {
        "id": "e6da52cd.93a8e",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"cardNumber\":6153283}",
        "payloadType": "json",
        "x": 130,
        "y": 620,
        "wires": [
            [
                "4ac01a83.a74ec4"
            ]
        ]
    },
    {
        "id": "4ac01a83.a74ec4",
        "type": "uhppoted-delete-card",
        "z": "2a36b650.4b9b7a",
        "name": "delete-card",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 620,
        "wires": [
            [
                "f5d8c5e3aba68de1"
            ]
        ]
    },
    {
        "id": "6f571cdf.961f74",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"index\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "13f668be.c2e417"
            ]
        ]
    },
    {
        "id": "13f668be.c2e417",
        "type": "uhppoted-get-card-by-index",
        "z": "2a36b650.4b9b7a",
        "name": "get-card-by-index",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 340,
        "wires": [
            [
                "7f6215b1dc38bd29"
            ]
        ]
    },
    {
        "id": "f6b826f5.187ae8",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 740,
        "wires": [
            [
                "874f55c6.6f00b8"
            ]
        ]
    },
    {
        "id": "874f55c6.6f00b8",
        "type": "uhppoted-delete-all-cards",
        "z": "2a36b650.4b9b7a",
        "name": "delete-all-cards",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 740,
        "wires": [
            [
                "b5d3ac7437ee33cb"
            ]
        ]
    },
    {
        "id": "650c4dc7.5f9424",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "cards",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.cards",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 750,
        "y": 140,
        "wires": []
    },
    {
        "id": "54d0141d.4fa96c",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card.status",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 180,
        "wires": []
    },
    {
        "id": "975dcdef.367a6",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-from",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.valid.from",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1020,
        "y": 260,
        "wires": []
    },
    {
        "id": "b2fd1c17.3bc25",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card.number",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.number",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 220,
        "wires": []
    },
    {
        "id": "296d7d38.b2ed42",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-to",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.valid.to",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1020,
        "y": 300,
        "wires": []
    },
    {
        "id": "7df632fc.3db16c",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-door-1",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doors[\"1\"]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 340,
        "wires": []
    },
    {
        "id": "cf4a8622.c08938",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-door-2",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doors[\"2\"]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 380,
        "wires": []
    },
    {
        "id": "9e2a41a9.a89d2",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-door-3",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doors[\"3\"]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 420,
        "wires": []
    },
    {
        "id": "6b38aa75.455224",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-door-4",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.doors[\"4\"]",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1030,
        "y": 460,
        "wires": []
    },
    {
        "id": "7fe3bec1.b4483",
        "type": "uhppoted-put-card",
        "z": "2a36b650.4b9b7a",
        "name": "put-card",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 460,
        "wires": [
            [
                "06a54e9cc496a9b1"
            ]
        ]
    },
    {
        "id": "83d878a.58b0188",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "test",
        "payload": "{\"controller\":{\"id\":405419896},\"card\":{\"number\":8165537,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"doors\":{\"1\":true,\"2\":false,\"3\":true,\"4\":true}}}",
        "payloadType": "json",
        "x": 130,
        "y": 460,
        "wires": [
            [
                "7fe3bec1.b4483"
            ]
        ]
    },
    {
        "id": "e7d56173.84b31",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "stored",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.stored",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 750,
        "y": 260,
        "wires": []
    },
    {
        "id": "626b62f3.eadd9c",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "deleted",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.deleted",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 300,
        "wires": []
    },
    {
        "id": "b2143813.901048",
        "type": "change",
        "z": "2a36b650.4b9b7a",
        "name": "card-status",
        "rules": [
            {
                "t": "set",
                "p": "payload",
                "pt": "msg",
                "to": "payload.status",
                "tot": "msg"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 770,
        "y": 180,
        "wires": [
            [
                "54d0141d.4fa96c"
            ]
        ]
    },
    {
        "id": "ad7a666aecfc6823",
        "type": "uhppoted-put-card",
        "z": "2a36b650.4b9b7a",
        "name": "put-card (with PIN)",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 540,
        "wires": [
            [
                "74aa6083d9145953"
            ]
        ]
    },
    {
        "id": "5da4edd44196b9d3",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "test",
        "payload": "{\"controller\":{\"id\":405419896},\"card\":{\"number\":8165537,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"doors\":{\"1\":true,\"2\":false,\"3\":true,\"4\":true},\"PIN\":7531}}",
        "payloadType": "json",
        "x": 130,
        "y": 540,
        "wires": [
            [
                "ad7a666aecfc6823"
            ]
        ]
    },
    {
        "id": "40085138d2d899c4",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "card-PIN",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.PIN",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 1020,
        "y": 500,
        "wires": []
    },
    {
        "id": "b3b669b59009998b",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "75d18b525b9132f8"
            ]
        ]
    },
    {
        "id": "75d18b525b9132f8",
        "type": "uhppoted-get-cards",
        "z": "2a36b650.4b9b7a",
        "name": "get-cards-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 140,
        "wires": [
            [
                "eb1459e5190e077a"
            ]
        ]
    },
    {
        "id": "46a3ef6fd389597b",
        "type": "uhppoted-get-card",
        "z": "2a36b650.4b9b7a",
        "name": "get-card-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 290,
        "y": 260,
        "wires": [
            [
                "ada671e280c97d16"
            ]
        ]
    },
    {
        "id": "da8d239ff79d6eb3",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"cardNumber\":8165537}",
        "payloadType": "json",
        "x": 130,
        "y": 260,
        "wires": [
            [
                "46a3ef6fd389597b"
            ]
        ]
    },
    {
        "id": "789cb23f60bbb0b8",
        "type": "uhppoted-get-card-by-index",
        "z": "2a36b650.4b9b7a",
        "name": "get-card-by-index-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 380,
        "wires": [
            [
                "00acb44fa5fd76bd"
            ]
        ]
    },
    {
        "id": "56f90807cc8a7a63",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"index\":1}",
        "payloadType": "json",
        "x": 130,
        "y": 380,
        "wires": [
            [
                "789cb23f60bbb0b8"
            ]
        ]
    },
    {
        "id": "56be19dff1557f05",
        "type": "uhppoted-put-card",
        "z": "2a36b650.4b9b7a",
        "name": "put-card-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 500,
        "wires": [
            [
                "488169bbfb8ecdea"
            ]
        ]
    },
    {
        "id": "fa54e33c2508f8b8",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "test",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"card\":{\"number\":8165537,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"doors\":{\"1\":true,\"2\":false,\"3\":true,\"4\":true}}}",
        "payloadType": "json",
        "x": 130,
        "y": 500,
        "wires": [
            [
                "56be19dff1557f05"
            ]
        ]
    },
    {
        "id": "6002d1604b71e586",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"cardNumber\":6153283}",
        "payloadType": "json",
        "x": 130,
        "y": 660,
        "wires": [
            [
                "99b25039f798f1f8"
            ]
        ]
    },
    {
        "id": "99b25039f798f1f8",
        "type": "uhppoted-delete-card",
        "z": "2a36b650.4b9b7a",
        "name": "delete-card-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 660,
        "wires": [
            [
                "676755979613d8aa"
            ]
        ]
    },
    {
        "id": "40c21733e205a361",
        "type": "inject",
        "z": "2a36b650.4b9b7a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 780,
        "wires": [
            [
                "87cc932dc94baab1"
            ]
        ]
    },
    {
        "id": "87cc932dc94baab1",
        "type": "uhppoted-delete-all-cards",
        "z": "2a36b650.4b9b7a",
        "name": "delete-all-cards-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 780,
        "wires": [
            [
                "c76240aecddccda5"
            ]
        ]
    },
    {
        "id": "f95f35e062ec0a83",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "received",
        "links": [
            "3218358125a216fe",
            "329a1f747c65c6cd",
            "eb1459e5190e077a",
            "ada671e280c97d16",
            "7f6215b1dc38bd29",
            "00acb44fa5fd76bd",
            "f5d8c5e3aba68de1",
            "676755979613d8aa",
            "06a54e9cc496a9b1",
            "488169bbfb8ecdea",
            "74aa6083d9145953",
            "b5d3ac7437ee33cb",
            "c76240aecddccda5"
        ],
        "x": 645,
        "y": 100,
        "wires": [
            [
                "60dcbb9f.c0dfa4"
            ]
        ]
    },
    {
        "id": "3218358125a216fe",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-cards",
        "mode": "link",
        "links": [
            "30ad27180e45dcea",
            "f95f35e062ec0a83"
        ],
        "x": 425,
        "y": 100,
        "wires": []
    },
    {
        "id": "eb1459e5190e077a",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-cards",
        "mode": "link",
        "links": [
            "30ad27180e45dcea",
            "f95f35e062ec0a83"
        ],
        "x": 425,
        "y": 140,
        "wires": []
    },
    {
        "id": "30ad27180e45dcea",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "get-cards",
        "links": [
            "3218358125a216fe",
            "eb1459e5190e077a"
        ],
        "x": 645,
        "y": 140,
        "wires": [
            [
                "650c4dc7.5f9424"
            ]
        ]
    },
    {
        "id": "329a1f747c65c6cd",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "mode": "link",
        "links": [
            "2799c87996665b8d",
            "7c894665dc241e28",
            "f95f35e062ec0a83"
        ],
        "x": 425,
        "y": 220,
        "wires": []
    },
    {
        "id": "2799c87996665b8d",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "card-status",
        "links": [
            "329a1f747c65c6cd",
            "ada671e280c97d16",
            "7f6215b1dc38bd29",
            "00acb44fa5fd76bd"
        ],
        "x": 645,
        "y": 180,
        "wires": [
            [
                "b2143813.901048"
            ]
        ]
    },
    {
        "id": "7c894665dc241e28",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "links": [
            "329a1f747c65c6cd",
            "ada671e280c97d16",
            "7f6215b1dc38bd29",
            "00acb44fa5fd76bd"
        ],
        "x": 645,
        "y": 220,
        "wires": [
            [
                "75f21b8.86ccbe4"
            ]
        ]
    },
    {
        "id": "ada671e280c97d16",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "mode": "link",
        "links": [
            "2799c87996665b8d",
            "7c894665dc241e28",
            "f95f35e062ec0a83"
        ],
        "x": 425,
        "y": 260,
        "wires": []
    },
    {
        "id": "7f6215b1dc38bd29",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "mode": "link",
        "links": [
            "2799c87996665b8d",
            "7c894665dc241e28",
            "f95f35e062ec0a83"
        ],
        "x": 455,
        "y": 340,
        "wires": []
    },
    {
        "id": "00acb44fa5fd76bd",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "get-card",
        "mode": "link",
        "links": [
            "2799c87996665b8d",
            "7c894665dc241e28",
            "f95f35e062ec0a83"
        ],
        "x": 455,
        "y": 380,
        "wires": []
    },
    {
        "id": "4c2446cee3c427e1",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "delete-card",
        "links": [
            "f5d8c5e3aba68de1",
            "676755979613d8aa"
        ],
        "x": 645,
        "y": 300,
        "wires": [
            [
                "626b62f3.eadd9c"
            ]
        ]
    },
    {
        "id": "f5d8c5e3aba68de1",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "delete-card",
        "mode": "link",
        "links": [
            "4c2446cee3c427e1",
            "f95f35e062ec0a83"
        ],
        "x": 445,
        "y": 620,
        "wires": []
    },
    {
        "id": "676755979613d8aa",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "delete-card",
        "mode": "link",
        "links": [
            "4c2446cee3c427e1",
            "f95f35e062ec0a83"
        ],
        "x": 445,
        "y": 660,
        "wires": []
    },
    {
        "id": "3b6b2e76daa8bc9e",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "put-card",
        "links": [
            "06a54e9cc496a9b1",
            "488169bbfb8ecdea",
            "74aa6083d9145953"
        ],
        "x": 645,
        "y": 260,
        "wires": [
            [
                "e7d56173.84b31"
            ]
        ]
    },
    {
        "id": "06a54e9cc496a9b1",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "put-card",
        "mode": "link",
        "links": [
            "3b6b2e76daa8bc9e",
            "f95f35e062ec0a83"
        ],
        "x": 475,
        "y": 460,
        "wires": []
    },
    {
        "id": "488169bbfb8ecdea",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "put-card",
        "mode": "link",
        "links": [
            "3b6b2e76daa8bc9e",
            "f95f35e062ec0a83"
        ],
        "x": 475,
        "y": 500,
        "wires": []
    },
    {
        "id": "74aa6083d9145953",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "put-card",
        "mode": "link",
        "links": [
            "3b6b2e76daa8bc9e",
            "f95f35e062ec0a83"
        ],
        "x": 475,
        "y": 540,
        "wires": []
    },
    {
        "id": "479105d505562652",
        "type": "debug",
        "z": "2a36b650.4b9b7a",
        "name": "cleared",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.deleted",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 340,
        "wires": []
    },
    {
        "id": "49e4d34f12a40fbc",
        "type": "link in",
        "z": "2a36b650.4b9b7a",
        "name": "delete-all-cards",
        "links": [
            "b5d3ac7437ee33cb",
            "c76240aecddccda5"
        ],
        "x": 645,
        "y": 340,
        "wires": [
            [
                "479105d505562652"
            ]
        ]
    },
    {
        "id": "b5d3ac7437ee33cb",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "delete-all-cards",
        "mode": "link",
        "links": [
            "49e4d34f12a40fbc",
            "f95f35e062ec0a83"
        ],
        "x": 475,
        "y": 740,
        "wires": []
    },
    {
        "id": "c76240aecddccda5",
        "type": "link out",
        "z": "2a36b650.4b9b7a",
        "name": "delete-all-cards",
        "mode": "link",
        "links": [
            "49e4d34f12a40fbc",
            "f95f35e062ec0a83"
        ],
        "x": 475,
        "y": 780,
        "wires": []
    },
    {
        "id": "d9f2a76f.385308",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"profileId\":29}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "8a160494.ad27f8"
            ]
        ]
    },
    {
        "id": "8a160494.ad27f8",
        "type": "uhppoted-get-time-profile",
        "z": "590b5d52.6f70e4",
        "name": "get-time-profile",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 100,
        "wires": [
            [
                "3494593bc9cd6bf1"
            ]
        ]
    },
    {
        "id": "1a80cd98.b11242",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"profile\":{\"id\":29,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Thursday\",\"Friday\"],\"segments\":[{\"start\":\"08:00\",\"end\":\"11:30\"},{\"start\":\"13:15\",\"end\":\"17:45\"}],\"linkedTo\":3}}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "eff19860.5c6da8"
            ]
        ]
    },
    {
        "id": "eff19860.5c6da8",
        "type": "uhppoted-set-time-profile",
        "z": "590b5d52.6f70e4",
        "name": "set-time-profile",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 220,
        "wires": [
            [
                "58d5705778105785"
            ]
        ]
    },
    {
        "id": "3c1aa5c1.4d2a0a",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "5bf5bd59.814154"
            ]
        ]
    },
    {
        "id": "5bf5bd59.814154",
        "type": "uhppoted-clear-time-profiles",
        "z": "590b5d52.6f70e4",
        "name": "clear-time-profiles",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 340,
        "wires": [
            [
                "69166d5189bb2574"
            ]
        ]
    },
    {
        "id": "8c3a28ff.bb9a08",
        "type": "uhppoted-put-card",
        "z": "590b5d52.6f70e4",
        "name": "put-card-with-time-profile",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 460,
        "wires": [
            [
                "435613e79ff3d582"
            ]
        ]
    },
    {
        "id": "924ed50d.855988",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "test",
        "payload": "{\"controller\":{\"id\":405419896},\"card\":{\"number\":6153283,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"doors\":{\"1\":true,\"2\":false,\"3\":29,\"4\":true}}}",
        "payloadType": "json",
        "x": 130,
        "y": 460,
        "wires": [
            [
                "8c3a28ff.bb9a08"
            ]
        ]
    },
    {
        "id": "75098299.b6febc",
        "type": "uhppoted-get-card",
        "z": "590b5d52.6f70e4",
        "name": "get-card-with-time-profile",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 500,
        "wires": [
            [
                "880c7565008b1f60"
            ]
        ]
    },
    {
        "id": "94300170.74219",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"deviceId\":405419896,\"cardNumber\":6153283}",
        "payloadType": "json",
        "x": 130,
        "y": 500,
        "wires": [
            [
                "75098299.b6febc"
            ]
        ]
    },
    {
        "id": "bf8e93c924c9d1c7",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"profileId\":29}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "6a4c3d472a4385cc"
            ]
        ]
    },
    {
        "id": "6a4c3d472a4385cc",
        "type": "uhppoted-get-time-profile",
        "z": "590b5d52.6f70e4",
        "name": "get-time-profile-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 140,
        "wires": [
            [
                "d2fcef09d4fdf17c"
            ]
        ]
    },
    {
        "id": "df9190fa18eb9767",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"profile\":{\"id\":29,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Thursday\",\"Friday\"],\"segments\":[{\"start\":\"08:00\",\"end\":\"11:30\"},{\"start\":\"13:15\",\"end\":\"17:45\"}],\"linkedTo\":3}}",
        "payloadType": "json",
        "x": 130,
        "y": 260,
        "wires": [
            [
                "eced523df6c0d668"
            ]
        ]
    },
    {
        "id": "eced523df6c0d668",
        "type": "uhppoted-set-time-profile",
        "z": "590b5d52.6f70e4",
        "name": "set-time-profile-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 260,
        "wires": [
            [
                "d7c812e325c09939"
            ]
        ]
    },
    {
        "id": "1e8ff653aa074d13",
        "type": "inject",
        "z": "590b5d52.6f70e4",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 380,
        "wires": [
            [
                "2627e8571d29c1d7"
            ]
        ]
    },
    {
        "id": "2627e8571d29c1d7",
        "type": "uhppoted-clear-time-profiles",
        "z": "590b5d52.6f70e4",
        "name": "clear-time-profiles-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 380,
        "wires": [
            [
                "1a3dda2f2505302d"
            ]
        ]
    },
    {
        "id": "28066563a0e05d51",
        "type": "link in",
        "z": "590b5d52.6f70e4",
        "name": "received",
        "links": [
            "121cb192bc3b8618",
            "1a3dda2f2505302d",
            "2d3c1a5a5885d602",
            "3494593bc9cd6bf1",
            "35c9f9d4a30e34e2",
            "435613e79ff3d582",
            "58d5705778105785",
            "69166d5189bb2574",
            "819316292d1aee2b",
            "880c7565008b1f60",
            "9bd3326c04e55986",
            "a6dbc452a08a5021",
            "d2fcef09d4fdf17c",
            "d7c812e325c09939",
            "f3f91ce72d015bfc"
        ],
        "x": 655,
        "y": 100,
        "wires": [
            [
                "2613b6884c8abff0"
            ]
        ]
    },
    {
        "id": "2613b6884c8abff0",
        "type": "debug",
        "z": "590b5d52.6f70e4",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 100,
        "wires": []
    },
    {
        "id": "3494593bc9cd6bf1",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 100,
        "wires": []
    },
    {
        "id": "d2fcef09d4fdf17c",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 140,
        "wires": []
    },
    {
        "id": "58d5705778105785",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 220,
        "wires": []
    },
    {
        "id": "d7c812e325c09939",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 260,
        "wires": []
    },
    {
        "id": "69166d5189bb2574",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 340,
        "wires": []
    },
    {
        "id": "1a3dda2f2505302d",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 455,
        "y": 380,
        "wires": []
    },
    {
        "id": "435613e79ff3d582",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 495,
        "y": 460,
        "wires": []
    },
    {
        "id": "880c7565008b1f60",
        "type": "link out",
        "z": "590b5d52.6f70e4",
        "name": "debug",
        "mode": "link",
        "links": [
            "28066563a0e05d51"
        ],
        "x": 495,
        "y": 500,
        "wires": []
    },
    {
        "id": "a9922968.8bbee8",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "f980b203.9b821"
            ]
        ]
    },
    {
        "id": "f980b203.9b821",
        "type": "uhppoted-clear-task-list",
        "z": "66c3d22e.434c7c",
        "name": "clear-task-list",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 100,
        "wires": [
            [
                "a6dbc452a08a5021"
            ]
        ]
    },
    {
        "id": "5dac42cd.fc4c8c",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 460,
        "wires": [
            [
                "13d7bc91.a53133"
            ]
        ]
    },
    {
        "id": "13d7bc91.a53133",
        "type": "uhppoted-refresh-task-list",
        "z": "66c3d22e.434c7c",
        "name": "refresh-tasklist",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 460,
        "wires": [
            [
                "65d2bb446e743803"
            ]
        ]
    },
    {
        "id": "885f0991.1066e8",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"task\":{\"task\":5,\"door\":3,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Wednesday\",\"Friday\"],\"start\":\"08:30\",\"cards\":7}}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "cdc76803.768e88"
            ]
        ]
    },
    {
        "id": "cdc76803.768e88",
        "type": "uhppoted-add-task",
        "z": "66c3d22e.434c7c",
        "name": "add-numeric-task",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 220,
        "wires": [
            [
                "f3f91ce72d015bfc"
            ]
        ]
    },
    {
        "id": "6c00cf3a.3fe4d",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"task\":{\"task\":\"enable time profile\",\"door\":3,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Wednesday\",\"Friday\"],\"start\":\"08:30\",\"cards\":7}}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "cc7f21cd.1853b"
            ]
        ]
    },
    {
        "id": "cc7f21cd.1853b",
        "type": "uhppoted-add-task",
        "z": "66c3d22e.434c7c",
        "name": "add-text-task",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 340,
        "wires": [
            [
                "121cb192bc3b8618"
            ]
        ]
    },
    {
        "id": "c39ce007ded20d5f",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"task\":{\"task\":5,\"door\":3,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Wednesday\",\"Friday\"],\"start\":\"08:30\",\"cards\":7}}",
        "payloadType": "json",
        "x": 130,
        "y": 260,
        "wires": [
            [
                "f0d5e84dd2cf4647"
            ]
        ]
    },
    {
        "id": "f0d5e84dd2cf4647",
        "type": "uhppoted-add-task",
        "z": "66c3d22e.434c7c",
        "name": "add-numeric-task-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 260,
        "wires": [
            [
                "35c9f9d4a30e34e2"
            ]
        ]
    },
    {
        "id": "1adb548b8ceb841f",
        "type": "uhppoted-add-task",
        "z": "66c3d22e.434c7c",
        "name": "add-text-task-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 380,
        "wires": [
            [
                "9bd3326c04e55986"
            ]
        ]
    },
    {
        "id": "04bb740ae4534f9d",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"task\":{\"task\":\"enable time profile\",\"door\":3,\"valid\":{\"from\":\"2021-01-01\",\"to\":\"2021-12-31\"},\"weekdays\":[\"Monday\",\"Wednesday\",\"Friday\"],\"start\":\"08:30\",\"cards\":7}}",
        "payloadType": "json",
        "x": 130,
        "y": 380,
        "wires": [
            [
                "1adb548b8ceb841f"
            ]
        ]
    },
    {
        "id": "557f359eb41f42e6",
        "type": "link in",
        "z": "66c3d22e.434c7c",
        "name": "received",
        "links": [
            "a6dbc452a08a5021",
            "f3f91ce72d015bfc",
            "35c9f9d4a30e34e2",
            "121cb192bc3b8618",
            "9bd3326c04e55986",
            "65d2bb446e743803",
            "2d3c1a5a5885d602",
            "819316292d1aee2b"
        ],
        "x": 655,
        "y": 100,
        "wires": [
            [
                "92eb38760f8be20a"
            ]
        ]
    },
    {
        "id": "92eb38760f8be20a",
        "type": "debug",
        "z": "66c3d22e.434c7c",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 100,
        "wires": []
    },
    {
        "id": "f3f91ce72d015bfc",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 220,
        "wires": []
    },
    {
        "id": "35c9f9d4a30e34e2",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 260,
        "wires": []
    },
    {
        "id": "121cb192bc3b8618",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 340,
        "wires": []
    },
    {
        "id": "9bd3326c04e55986",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 380,
        "wires": []
    },
    {
        "id": "65d2bb446e743803",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6"
        ],
        "x": 475,
        "y": 460,
        "wires": []
    },
    {
        "id": "a6dbc452a08a5021",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 100,
        "wires": []
    },
    {
        "id": "29e68d484d463771",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "b0707aebb18358c0"
            ]
        ]
    },
    {
        "id": "b0707aebb18358c0",
        "type": "uhppoted-clear-task-list",
        "z": "66c3d22e.434c7c",
        "name": "clear-tasklist-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 140,
        "wires": [
            [
                "2d3c1a5a5885d602"
            ]
        ]
    },
    {
        "id": "2d3c1a5a5885d602",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 140,
        "wires": []
    },
    {
        "id": "129bd51bf5c508fc",
        "type": "inject",
        "z": "66c3d22e.434c7c",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 500,
        "wires": [
            [
                "cffb69d4674cf72d"
            ]
        ]
    },
    {
        "id": "cffb69d4674cf72d",
        "type": "uhppoted-refresh-task-list",
        "z": "66c3d22e.434c7c",
        "name": "refresh-tasklist-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 310,
        "y": 500,
        "wires": [
            [
                "819316292d1aee2b"
            ]
        ]
    },
    {
        "id": "819316292d1aee2b",
        "type": "link out",
        "z": "66c3d22e.434c7c",
        "name": "debug",
        "mode": "link",
        "links": [
            "557f359eb41f42e6",
            "28066563a0e05d51"
        ],
        "x": 475,
        "y": 500,
        "wires": []
    },
    {
        "id": "3be8dcd9.c0ec74",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "9e7ddaee.4eaa48"
            ]
        ]
    },
    {
        "id": "9e7ddaee.4eaa48",
        "type": "uhppoted-get-event-index",
        "z": "b5da19a5.72a0c8",
        "name": "get-event-index",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 220,
        "wires": [
            [
                "93720d51e19ed5ef"
            ]
        ]
    },
    {
        "id": "701112a1.4079dc",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"index\":14}",
        "payloadType": "json",
        "x": 130,
        "y": 340,
        "wires": [
            [
                "738563e5.ad729c"
            ]
        ]
    },
    {
        "id": "738563e5.ad729c",
        "type": "uhppoted-set-event-index",
        "z": "b5da19a5.72a0c8",
        "name": "set-event-index",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 300,
        "y": 340,
        "wires": [
            [
                "06c6c0cbc28d7a2b"
            ]
        ]
    },
    {
        "id": "959338c3.e9e528",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"index\":17}",
        "payloadType": "json",
        "x": 130,
        "y": 460,
        "wires": [
            [
                "7cf7e46b.641d4c"
            ]
        ]
    },
    {
        "id": "7cf7e46b.641d4c",
        "type": "uhppoted-get-event",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 380,
        "y": 460,
        "wires": [
            [
                "2be2e9d5d77c54d9"
            ]
        ]
    },
    {
        "id": "a9cd7169.9f80b",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "serial-number",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.deviceId",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 820,
        "y": 180,
        "wires": []
    },
    {
        "id": "d0248137.40611",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.index",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.index",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 810,
        "y": 220,
        "wires": []
    },
    {
        "id": "efd22b62.f8dd98",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.timestamp",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.timestamp",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 830,
        "y": 260,
        "wires": []
    },
    {
        "id": "528f92e2.4cc88c",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.type",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.type.event",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 810,
        "y": 300,
        "wires": []
    },
    {
        "id": "10303c8c.5ee653",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.granted",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.granted",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 820,
        "y": 340,
        "wires": []
    },
    {
        "id": "6b2ec04b.e162e",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.direction",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.direction.direction",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 820,
        "y": 380,
        "wires": []
    },
    {
        "id": "3e133140.9cd2ce",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "event.reason",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.event.reason.reason",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 810,
        "y": 420,
        "wires": []
    },
    {
        "id": "8321868.c35fa78",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 800,
        "y": 100,
        "wires": []
    },
    {
        "id": "1dd15bdb.488f04",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"enable\":true}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "6f2638b.e4c53c8"
            ]
        ]
    },
    {
        "id": "2b58807c.84593",
        "type": "debug",
        "z": "b5da19a5.72a0c8",
        "name": "updated",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.updated",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 800,
        "y": 140,
        "wires": []
    },
    {
        "id": "6f2638b.e4c53c8",
        "type": "uhppoted-record-special-events",
        "z": "b5da19a5.72a0c8",
        "name": "record-special-events",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 100,
        "wires": [
            [
                "5cc40db6d9f925d3"
            ]
        ]
    },
    {
        "id": "711dac43b52c5446",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test-overwritten-event",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"index\":73}",
        "payloadType": "json",
        "x": 180,
        "y": 540,
        "wires": [
            [
                "0f093ad785df38d1"
            ]
        ]
    },
    {
        "id": "0f093ad785df38d1",
        "type": "uhppoted-get-event",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 380,
        "y": 540,
        "wires": [
            [
                "dd522d0b58b29a6b"
            ]
        ]
    },
    {
        "id": "2b28e0b04eb5932c",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"enable\":true}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "e1a931b276724b43"
            ]
        ]
    },
    {
        "id": "e1a931b276724b43",
        "type": "uhppoted-record-special-events",
        "z": "b5da19a5.72a0c8",
        "name": "record-special-events-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 330,
        "y": 140,
        "wires": [
            [
                "5f4fe1a469cb67c5"
            ]
        ]
    },
    {
        "id": "b990cf094cd11447",
        "type": "link in",
        "z": "b5da19a5.72a0c8",
        "name": "received",
        "links": [
            "06c6c0cbc28d7a2b",
            "5cc40db6d9f925d3",
            "5f4fe1a469cb67c5",
            "93720d51e19ed5ef",
            "ac4d232bf71b7dd9",
            "add09a1b97f51d1e",
            "2be2e9d5d77c54d9",
            "dd522d0b58b29a6b",
            "a66eaca2a0b98aae"
        ],
        "x": 655,
        "y": 100,
        "wires": [
            [
                "8321868.c35fa78"
            ]
        ]
    },
    {
        "id": "1d3b15ec44a91b94",
        "type": "link in",
        "z": "b5da19a5.72a0c8",
        "name": "updated",
        "links": [
            "06c6c0cbc28d7a2b",
            "5cc40db6d9f925d3",
            "5f4fe1a469cb67c5",
            "add09a1b97f51d1e"
        ],
        "x": 655,
        "y": 140,
        "wires": [
            [
                "2b58807c.84593"
            ]
        ]
    },
    {
        "id": "5cc40db6d9f925d3",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "record-special-events",
        "mode": "link",
        "links": [
            "1d3b15ec44a91b94",
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 100,
        "wires": []
    },
    {
        "id": "5f4fe1a469cb67c5",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "record-special-events",
        "mode": "link",
        "links": [
            "1d3b15ec44a91b94",
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 140,
        "wires": []
    },
    {
        "id": "93720d51e19ed5ef",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "get-event-index",
        "mode": "link",
        "links": [
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 220,
        "wires": []
    },
    {
        "id": "97cffd0c62fae4c4",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 260,
        "wires": [
            [
                "402b143d8493ddc5"
            ]
        ]
    },
    {
        "id": "402b143d8493ddc5",
        "type": "uhppoted-get-event-index",
        "z": "b5da19a5.72a0c8",
        "name": "get-event-index-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 260,
        "wires": [
            [
                "ac4d232bf71b7dd9"
            ]
        ]
    },
    {
        "id": "ac4d232bf71b7dd9",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "get-event-index",
        "mode": "link",
        "links": [
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 260,
        "wires": []
    },
    {
        "id": "06c6c0cbc28d7a2b",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "set-event-index",
        "mode": "link",
        "links": [
            "1d3b15ec44a91b94",
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 340,
        "wires": []
    },
    {
        "id": "5f2772ca8c65f298",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"index\":14}",
        "payloadType": "json",
        "x": 130,
        "y": 380,
        "wires": [
            [
                "ab64d6ba6fc5a49a"
            ]
        ]
    },
    {
        "id": "ab64d6ba6fc5a49a",
        "type": "uhppoted-set-event-index",
        "z": "b5da19a5.72a0c8",
        "name": "set-event-index-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 320,
        "y": 380,
        "wires": [
            [
                "add09a1b97f51d1e"
            ]
        ]
    },
    {
        "id": "add09a1b97f51d1e",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "set-event-index",
        "mode": "link",
        "links": [
            "1d3b15ec44a91b94",
            "b990cf094cd11447"
        ],
        "x": 495,
        "y": 380,
        "wires": []
    },
    {
        "id": "ce7525a4e7180451",
        "type": "link in",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "links": [
            "2be2e9d5d77c54d9",
            "dd522d0b58b29a6b",
            "a66eaca2a0b98aae"
        ],
        "x": 655,
        "y": 180,
        "wires": [
            [
                "a9cd7169.9f80b",
                "d0248137.40611",
                "efd22b62.f8dd98",
                "528f92e2.4cc88c",
                "10303c8c.5ee653",
                "6b2ec04b.e162e",
                "3e133140.9cd2ce"
            ]
        ]
    },
    {
        "id": "2be2e9d5d77c54d9",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "mode": "link",
        "links": [
            "b990cf094cd11447",
            "ce7525a4e7180451"
        ],
        "x": 525,
        "y": 460,
        "wires": []
    },
    {
        "id": "dd522d0b58b29a6b",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "mode": "link",
        "links": [
            "b990cf094cd11447",
            "ce7525a4e7180451"
        ],
        "x": 525,
        "y": 540,
        "wires": []
    },
    {
        "id": "07f844fb94bc5be0",
        "type": "inject",
        "z": "b5da19a5.72a0c8",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"index\":17}",
        "payloadType": "json",
        "x": 130,
        "y": 500,
        "wires": [
            [
                "46d0db7d4370b8d1"
            ]
        ]
    },
    {
        "id": "46d0db7d4370b8d1",
        "type": "uhppoted-get-event",
        "z": "b5da19a5.72a0c8",
        "name": "get-event-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 400,
        "y": 500,
        "wires": [
            [
                "a66eaca2a0b98aae"
            ]
        ]
    },
    {
        "id": "a66eaca2a0b98aae",
        "type": "link out",
        "z": "b5da19a5.72a0c8",
        "name": "get-event",
        "mode": "link",
        "links": [
            "b990cf094cd11447",
            "ce7525a4e7180451"
        ],
        "x": 525,
        "y": 500,
        "wires": []
    },
    {
        "id": "8a7531d7b8109a99",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 100,
        "wires": []
    },
    {
        "id": "132f4b6bcbb8c39c",
        "type": "inject",
        "z": "084b05a6c596f92a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896},\"enable\":true}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "fc341cfabe5d9a38"
            ]
        ]
    },
    {
        "id": "66ebd6872aee5190",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "updated",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.updated",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 920,
        "y": 140,
        "wires": []
    },
    {
        "id": "533ddcf57003f6c5",
        "type": "uhppoted-set-pc-control",
        "z": "084b05a6c596f92a",
        "name": "set-pc-control",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 500,
        "y": 100,
        "wires": [
            [
                "97abc613d2ae57c9"
            ]
        ]
    },
    {
        "id": "f8ce8d9c686eec75",
        "type": "uhppoted-listen",
        "z": "084b05a6c596f92a",
        "name": "listen",
        "config": "cf35d9904542f0af",
        "x": 110,
        "y": 340,
        "wires": [
            [
                "2190c4453a0eb105",
                "49437c908c4fe007"
            ]
        ]
    },
    {
        "id": "2190c4453a0eb105",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "event",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 290,
        "y": 280,
        "wires": []
    },
    {
        "id": "49437c908c4fe007",
        "type": "function",
        "z": "084b05a6c596f92a",
        "name": "event handler",
        "func": "const cards = [ 8165538, 10058399 ]\nconst event = msg.payload.state.event\nlet swipe = null\nlet granted = null\nlet denied = null\nlet open = null\n\n// card swipe?\nif (event.type.code === 1) {\n    swipe = msg.payload.state.event    \n}\n\n// card swipe and remote access control ?\nif (event.type.code === 1 && event.reason.code === 5 && event.granted == false) {\n    if (cards.includes(event.card)) {\n        granted = { \"timestamp\": event.timestamp,\n                    \"card\": event.card,\n                    \"door\": event.door\n                  }\n\n        open = msg\n        open.payload = {\n                  controller: {\n                    id: msg.payload.deviceId,\n                  },\n                  door: event.door\n               }\n    } else {\n        denied = { \n                   \"timestamp\": event.timestamp,\n                   \"card\": event.card,\n                   \"door\": event.door\n                 }\n    }\n}\n\nreturn [ swipe, granted, denied, open ]\n",
        "outputs": 4,
        "timeout": "",
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 300,
        "y": 340,
        "wires": [
            [
                "0974ea4cdb46c4d0"
            ],
            [
                "7ba7c37174572581"
            ],
            [
                "3b3c95833152d702"
            ],
            [
                "39d3e1563d8382f4"
            ]
        ]
    },
    {
        "id": "0974ea4cdb46c4d0",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "swipe",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 490,
        "y": 280,
        "wires": []
    },
    {
        "id": "7ba7c37174572581",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "granted",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 500,
        "y": 320,
        "wires": []
    },
    {
        "id": "3b3c95833152d702",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "denied",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "true",
        "targetType": "full",
        "statusVal": "",
        "statusType": "auto",
        "x": 490,
        "y": 360,
        "wires": []
    },
    {
        "id": "39d3e1563d8382f4",
        "type": "uhppoted-open-door",
        "z": "084b05a6c596f92a",
        "name": "open-door",
        "config": "cf35d9904542f0af",
        "x": 510,
        "y": 400,
        "wires": [
            [
                "131a0ec7a483a6c6"
            ]
        ]
    },
    {
        "id": "a942a9ad5d0ab0ca",
        "type": "debug",
        "z": "084b05a6c596f92a",
        "name": "door-opened",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.opened",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 930,
        "y": 180,
        "wires": []
    },
    {
        "id": "fc341cfabe5d9a38",
        "type": "trigger",
        "z": "084b05a6c596f92a",
        "name": "send",
        "op1": "",
        "op2": "",
        "op1type": "pay",
        "op2type": "pay",
        "duration": "250",
        "extend": false,
        "overrideDelay": false,
        "units": "ms",
        "reset": "",
        "bytopic": "all",
        "topic": "topic",
        "outputs": 2,
        "x": 290,
        "y": 100,
        "wires": [
            [
                "533ddcf57003f6c5"
            ],
            [
                "b54620d8e5822dc6"
            ]
        ]
    },
    {
        "id": "b54620d8e5822dc6",
        "type": "delay",
        "z": "084b05a6c596f92a",
        "name": "",
        "pauseType": "delay",
        "timeout": "15",
        "timeoutUnits": "seconds",
        "rate": "1",
        "nbRateUnits": "1",
        "rateUnits": "second",
        "randomFirst": "1",
        "randomLast": "5",
        "randomUnits": "seconds",
        "drop": false,
        "allowrate": false,
        "outputs": 1,
        "x": 300,
        "y": 40,
        "wires": [
            [
                "fc341cfabe5d9a38"
            ]
        ]
    },
    {
        "id": "97abc613d2ae57c9",
        "type": "link out",
        "z": "084b05a6c596f92a",
        "name": "set-pc-control",
        "mode": "link",
        "links": [
            "4673fbe24b57e489",
            "d745375e148f24be"
        ],
        "x": 655,
        "y": 100,
        "wires": []
    },
    {
        "id": "4673fbe24b57e489",
        "type": "link in",
        "z": "084b05a6c596f92a",
        "name": "received",
        "links": [
            "97abc613d2ae57c9",
            "d3536688fd49afd7",
            "131a0ec7a483a6c6"
        ],
        "x": 795,
        "y": 100,
        "wires": [
            [
                "8a7531d7b8109a99"
            ]
        ]
    },
    {
        "id": "d745375e148f24be",
        "type": "link in",
        "z": "084b05a6c596f92a",
        "name": "set-pc-control",
        "links": [
            "97abc613d2ae57c9",
            "d3536688fd49afd7"
        ],
        "x": 795,
        "y": 140,
        "wires": [
            [
                "66ebd6872aee5190"
            ]
        ]
    },
    {
        "id": "6d8447065f249ef3",
        "type": "inject",
        "z": "084b05a6c596f92a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"},\"enable\":true}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "8fd48c489217ae19"
            ]
        ]
    },
    {
        "id": "4b2b86039e25553d",
        "type": "uhppoted-set-pc-control",
        "z": "084b05a6c596f92a",
        "name": "set-pc-control-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 510,
        "y": 140,
        "wires": [
            [
                "d3536688fd49afd7"
            ]
        ]
    },
    {
        "id": "8fd48c489217ae19",
        "type": "trigger",
        "z": "084b05a6c596f92a",
        "name": "send",
        "op1": "",
        "op2": "",
        "op1type": "pay",
        "op2type": "pay",
        "duration": "250",
        "extend": false,
        "overrideDelay": false,
        "units": "ms",
        "reset": "",
        "bytopic": "all",
        "topic": "topic",
        "outputs": 2,
        "x": 290,
        "y": 140,
        "wires": [
            [
                "4b2b86039e25553d"
            ],
            [
                "e3c9453e1a5378c9"
            ]
        ]
    },
    {
        "id": "e3c9453e1a5378c9",
        "type": "delay",
        "z": "084b05a6c596f92a",
        "name": "",
        "pauseType": "delay",
        "timeout": "15",
        "timeoutUnits": "seconds",
        "rate": "1",
        "nbRateUnits": "1",
        "rateUnits": "second",
        "randomFirst": "1",
        "randomLast": "5",
        "randomUnits": "seconds",
        "drop": false,
        "allowrate": false,
        "outputs": 1,
        "x": 300,
        "y": 200,
        "wires": [
            [
                "8fd48c489217ae19"
            ]
        ]
    },
    {
        "id": "d3536688fd49afd7",
        "type": "link out",
        "z": "084b05a6c596f92a",
        "name": "set-pc-control",
        "mode": "link",
        "links": [
            "4673fbe24b57e489",
            "d745375e148f24be"
        ],
        "x": 655,
        "y": 140,
        "wires": []
    },
    {
        "id": "401ed47b9894ba1d",
        "type": "link in",
        "z": "084b05a6c596f92a",
        "name": "open-door",
        "links": [
            "131a0ec7a483a6c6"
        ],
        "x": 795,
        "y": 180,
        "wires": [
            [
                "a942a9ad5d0ab0ca"
            ]
        ]
    },
    {
        "id": "131a0ec7a483a6c6",
        "type": "link out",
        "z": "084b05a6c596f92a",
        "name": "open-door",
        "mode": "link",
        "links": [
            "401ed47b9894ba1d",
            "4673fbe24b57e489"
        ],
        "x": 635,
        "y": 400,
        "wires": []
    },
    {
        "id": "7c3b3f494d28c28a",
        "type": "debug",
        "z": "093e8f2cad65974a",
        "name": "received",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 820,
        "y": 100,
        "wires": []
    },
    {
        "id": "3e20f74de8a23794",
        "type": "inject",
        "z": "093e8f2cad65974a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896}}",
        "payloadType": "json",
        "x": 130,
        "y": 100,
        "wires": [
            [
                "02373e6ceb8dbcd1"
            ]
        ]
    },
    {
        "id": "d125c3764b05339d",
        "type": "debug",
        "z": "093e8f2cad65974a",
        "name": "reset",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload.reset",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 810,
        "y": 140,
        "wires": []
    },
    {
        "id": "02373e6ceb8dbcd1",
        "type": "uhppoted-restore-default-parameters",
        "z": "093e8f2cad65974a",
        "name": "restore-default-parameters",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 360,
        "y": 100,
        "wires": [
            [
                "1a192599528121a1"
            ]
        ]
    },
    {
        "id": "820d2c7b4f5cbb9c",
        "type": "link in",
        "z": "093e8f2cad65974a",
        "name": "received",
        "links": [
            "1a192599528121a1",
            "c9c56e7282c0f292"
        ],
        "x": 705,
        "y": 100,
        "wires": [
            [
                "7c3b3f494d28c28a"
            ]
        ]
    },
    {
        "id": "0653b2aabdd562d9",
        "type": "link in",
        "z": "093e8f2cad65974a",
        "name": "restore-default-parameters",
        "links": [
            "1a192599528121a1",
            "c9c56e7282c0f292"
        ],
        "x": 705,
        "y": 140,
        "wires": [
            [
                "d125c3764b05339d"
            ]
        ]
    },
    {
        "id": "1a192599528121a1",
        "type": "link out",
        "z": "093e8f2cad65974a",
        "name": "restore-default-parameters",
        "mode": "link",
        "links": [
            "0653b2aabdd562d9",
            "820d2c7b4f5cbb9c"
        ],
        "x": 545,
        "y": 100,
        "wires": []
    },
    {
        "id": "9966acb4248618ed",
        "type": "inject",
        "z": "093e8f2cad65974a",
        "name": "test",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "{\"controller\":{\"id\":405419896,\"address\":\"192.168.1.100\",\"protocol\":\"tcp\"}}",
        "payloadType": "json",
        "x": 130,
        "y": 140,
        "wires": [
            [
                "682c0d79b58201f3"
            ]
        ]
    },
    {
        "id": "682c0d79b58201f3",
        "type": "uhppoted-restore-default-parameters",
        "z": "093e8f2cad65974a",
        "name": "restore-default-parameters-tcp",
        "topic": "",
        "config": "cf35d9904542f0af",
        "x": 370,
        "y": 140,
        "wires": [
            [
                "c9c56e7282c0f292"
            ]
        ]
    },
    {
        "id": "c9c56e7282c0f292",
        "type": "link out",
        "z": "093e8f2cad65974a",
        "name": "restore-default-parameters",
        "mode": "link",
        "links": [
            "0653b2aabdd562d9",
            "820d2c7b4f5cbb9c"
        ],
        "x": 545,
        "y": 140,
        "wires": []
    }
]