Hi @jacaré please find enclosed the flow I am currently using. First I used the Ctrlx subscription node to trigger the state. Meanwhile we have switched to an inject node with an initial start + interval. This prevents if machine is switched off that there will be no reconnect after powering on the machine. Currently we are using 15 seconds. You only have to change the READ node to your own OPC UA client state. JSON Flow to import to your node red: [ { "id": "f4f323db.8181f8", "type": "tab", "label": "01_Initial: Establish OPC-UA Connection", "disabled": false, "info": "" }, { "id": "95eedbc4.8f71f", "type": "debug", "z": "f4f323db.8181f8", "name": "", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 1130, "y": 100, "wires": [] }, { "id": "8e7e0c8e.d42da8", "type": "switch", "z": "f4f323db.8181f8", "name": "Switch", "property": "payload", "propertyType": "msg", "rules": [ { "t": "eq", "v": "{\"state\":\"CONNECTED\"}", "vt": "str" }, { "t": "eq", "v": "{\"state\":\"DISCONNECTED\"}", "vt": "str" } ], "checkall": "true", "repair": true, "outputs": 2, "x": 910, "y": 140, "wires": [ [ "95eedbc4.8f71f" ], [ "c809905d.49f848" ] ] }, { "id": "bc59e2fa.e7f1a", "type": "json", "z": "f4f323db.8181f8", "name": "JSON to String", "property": "payload", "action": "", "pretty": false, "x": 740, "y": 140, "wires": [ [ "8e7e0c8e.d42da8" ] ] }, { "id": "610fa792.374e8", "type": "ctrlx-datalayer-request", "z": "f4f323db.8181f8", "device": "3b393ef1.2b322a", "method": "WRITE", "path": "opcuaclient/Bihler GRM-NC/connect", "payloadFormat": "value_type", "name": "Connect OPC UA Client", "x": 1370, "y": 160, "wires": [ [] ] }, { "id": "c809905d.49f848", "type": "change", "z": "f4f323db.8181f8", "name": "Clear msg.payload", "rules": [ { "t": "set", "p": "payload", "pt": "msg", "to": "", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1130, "y": 160, "wires": [ [ "610fa792.374e8" ] ] }, { "id": "625a117d.50dbe8", "type": "comment", "z": "f4f323db.8181f8", "name": "JSON to String", "info": "This Node converts the JSON Object to a string", "x": 740, "y": 100, "wires": [] }, { "id": "7399ec56.b47b34", "type": "comment", "z": "f4f323db.8181f8", "name": "Switch", "info": "This Node makes a switch case wehther the OPC UA Client is connected or not", "x": 910, "y": 100, "wires": [] }, { "id": "d5ff7bd5.a031c8", "type": "comment", "z": "f4f323db.8181f8", "name": "Clear msg.payload", "info": "This Node is the not connected case of the switch before and clears the msg object of the flow, because in the next coming node, a write function to the data laye node \"opcuaclient/client1/connect\" must be performed to connet the OPC UA Client the the configured OPC UA Server ", "x": 1130, "y": 200, "wires": [] }, { "id": "714985f4.0dde1c", "type": "comment", "z": "f4f323db.8181f8", "name": "Connect OPC UA Client", "info": "A write command is performed to the data layer path \"opcuaclient/client1/connect\" to do a connection to the configured OPC UA Server", "x": 1360, "y": 120, "wires": [] }, { "id": "c2fc2f58b41274b3", "type": "inject", "z": "f4f323db.8181f8", "name": "", "props": [ { "p": "payload" }, { "p": "topic", "vt": "str" } ], "repeat": "15", "crontab": "", "once": true, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 150, "y": 140, "wires": [ [ "315932cef7469ad4" ] ] }, { "id": "315932cef7469ad4", "type": "ctrlx-datalayer-request", "z": "f4f323db.8181f8", "device": "3b393ef1.2b322a", "method": "READ", "path": "opcuaclient/Bihler GRM-NC/state", "payloadFormat": "value", "name": "", "x": 420, "y": 140, "wires": [ [ "bc59e2fa.e7f1a" ] ] }, { "id": "3934107e59bf377b", "type": "comment", "z": "f4f323db.8181f8", "name": "Inject to verify Status of OPC UA Client", "info": "An initial inject is triggered.\nAfter that an interval is used to verify\nthe connection status. ", "x": 210, "y": 100, "wires": [] }, { "id": "3b393ef1.2b322a", "type": "ctrlx-config", "name": "ctrlX-bihler1000093", "hostname": "localhost", "debug": false } ]
... View more