Shore power always present via Shelly

Hi everyone,

As a Node-RED beginner, I installed a Shelly 1PM in my motorhome and also integrated it into my Cerbo via Node-RED. The reason for this is that I can activate/deactivate the shore power and measure the power consumption. I can now switch the Shelly on and off via the Shelly app and the Victron app (as long as shore power is available).

However, I now have the problem that when I disconnect the shore power, the Shelly remains available and continues to display the last values, which means that everything is incorrect. Is there a way for the Cerbo to poll the Shelly and remove it when it is unavailable, then integrate it again when it becomes available? Here’s my code:

[
{
“id”: “c6138a722672e3a4”,
“type”: “tab”,
“label”: “Flow 1”,
“disabled”: false,
“info”: “”,
“env”:
},
{
“id”: “fff1e473d2dbd6e8”,
“type”: “shelly-gen2”,
“z”: “c6138a722672e3a4”,
“hostname”: “192.168.1.110”,
“description”: “Shelly 1PM”,
“mode”: “polling”,
“verbose”: false,
“server”: “”,
“outputmode”: “event”,
“uploadretryinterval”: 5000,
“pollinginterval”: 5000,
“pollstatus”: true,
“getstatusoncommand”: true,
“devicetype”: “SNSW-001P16EU”,
“devicetypemustmatchexactly”: true,
“captureblutooth”: false,
“outputs”: 1,
“x”: 570,
“y”: 420,
“wires”: [
[
“c65c333b706a9c30”,
“cb23c2277957bfb3”,
“ea0397b490f2b062”,
“d6ec2b310e1c6653”,
“45b8c5099165ce10”
]
]
},
{
“id”: “c65c333b706a9c30”,
“type”: “function”,
“z”: “c6138a722672e3a4”,
“name”: “Voltage”,
“func”: “msg.payload=(msg.payload.switch0.voltage);\nreturn msg;”,
“outputs”: 1,
“timeout”: 0,
“noerr”: 0,
“initialize”: “”,
“finalize”: “”,
“libs”: ,
“x”: 970,
“y”: 320,
“wires”: [
[
“7fa30c780d8b995d”
]
]
},
{
“id”: “cb23c2277957bfb3”,
“type”: “function”,
“z”: “c6138a722672e3a4”,
“name”: “Current”,
“func”: “msg.payload=(msg.payload.switch0.current);\nreturn msg;”,
“outputs”: 1,
“timeout”: 0,
“noerr”: 0,
“initialize”: “”,
“finalize”: “”,
“libs”: ,
“x”: 950,
“y”: 420,
“wires”: [
[
“35087ed2a10a86ba”
]
]
},
{
“id”: “ea0397b490f2b062”,
“type”: “function”,
“z”: “c6138a722672e3a4”,
“name”: “Power”,
“func”: “msg.payload=(msg.payload.switch0.apower)\nreturn msg;”,
“outputs”: 1,
“timeout”: 0,
“noerr”: 0,
“initialize”: “”,
“finalize”: “”,
“libs”: ,
“x”: 960,
“y”: 520,
“wires”: [
[
“b1a58d25df26d16a”
]
]
},
{
“id”: “7fa30c780d8b995d”,
“type”: “victron-output-custom”,
“z”: “c6138a722672e3a4”,
“service”: “com.victronenergy.grid/100”,
“path”: “/Ac/L1/Voltage”,
“serviceObj”: {
“service”: “com.victronenergy.grid/100”,
“name”: “Shore power (100)”
},
“pathObj”: {
“path”: “/Ac/L1/Voltage”,
“name”: “/Ac/L1/Voltage”,
“type”: “number”,
“value”: 229.6
},
“name”: “Shore power V”,
“onlyChanges”: false,
“roundValues”: “no”,
“rateLimit”: 0,
“outputs”: 0,
“conditionalMode”: false,
“condition1Operator”: “>”,
“condition2Enabled”: false,
“condition2Service”: “”,
“condition2Path”: “”,
“condition2Operator”: “>”,
“logicOperator”: “AND”,
“outputTrue”: “true”,
“outputFalse”: “false”,
“outputOnChange”: false,
“debounce”: 2000,
“x”: 1410,
“y”: 320,
“wires”:
},
{
“id”: “35087ed2a10a86ba”,
“type”: “victron-output-custom”,
“z”: “c6138a722672e3a4”,
“service”: “com.victronenergy.grid/100”,
“path”: “/Ac/L1/Current”,
“serviceObj”: {
“service”: “com.victronenergy.grid/100”,
“name”: “Shore power (100)”
},
“pathObj”: {
“path”: “/Ac/L1/Current”,
“name”: “/Ac/L1/Current”,
“type”: “number”,
“value”: 0.095
},
“name”: “Shore power A”,
“onlyChanges”: false,
“roundValues”: “no”,
“rateLimit”: 0,
“outputs”: 0,
“conditionalMode”: false,
“condition1Operator”: “>”,
“condition2Enabled”: false,
“condition2Service”: “”,
“condition2Path”: “”,
“condition2Operator”: “>”,
“logicOperator”: “AND”,
“outputTrue”: “true”,
“outputFalse”: “false”,
“outputOnChange”: false,
“debounce”: 2000,
“x”: 1410,
“y”: 420,
“wires”:
},
{
“id”: “b1a58d25df26d16a”,
“type”: “victron-output-custom”,
“z”: “c6138a722672e3a4”,
“service”: “com.victronenergy.grid/100”,
“path”: “/Ac/L1/Power”,
“serviceObj”: {
“service”: “com.victronenergy.grid/100”,
“name”: “Shore power (100)”
},
“pathObj”: {
“path”: “/Ac/L1/Power”,
“name”: “/Ac/L1/Power”,
“type”: “number”,
“value”: 3
},
“name”: “Shore power W”,
“onlyChanges”: false,
“roundValues”: “no”,
“rateLimit”: 0,
“outputs”: 0,
“conditionalMode”: false,
“condition1Operator”: “>”,
“condition2Enabled”: false,
“condition2Service”: “”,
“condition2Path”: “”,
“condition2Operator”: “>”,
“logicOperator”: “AND”,
“outputTrue”: “true”,
“outputFalse”: “false”,
“outputOnChange”: false,
“debounce”: 2000,
“x”: 1420,
“y”: 520,
“wires”:
},
{
“id”: “339af066d9f15b2b”,
“type”: “victron-virtual”,
“z”: “c6138a722672e3a4”,
“name”: “Shore power”,
“outputs”: 1,
“device”: “grid”,
“default_values”: true,
“acload_nrofphases”: 1,
“enable_s2support”: false,
“battery_capacity”: 25,
“include_battery_temperature”: false,
“battery_voltage_preset”: “24”,
“battery_voltage_custom”: 24,
“generator_type”: “ac”,
“generator_nrofphases”: 1,
“include_engine_hours”: false,
“include_starter_voltage”: false,
“include_history_energy”: false,
“grid_nrofphases”: 1,
“include_motor_temp”: false,
“include_controller_temp”: false,
“include_coolant_temp”: false,
“include_motor_rpm”: true,
“include_motor_direction”: true,
“position”: 0,
“pvinverter_nrofphases”: 1,
“switch_1_type”: 1,
“switch_1_min”: 0,
“switch_1_max”: “”,
“switch_1_initial”: 0,
“switch_1_label”: “”,
“switch_1_unit”: “”,
“switch_1_step”: 1,
“switch_1_customname”: “”,
“switch_1_group”: “”,
“switch_1_include_measurement”: false,
“switch_1_rgb_color_wheel”: false,
“switch_1_cct_wheel”: false,
“switch_1_rgb_white_dimmer”: false,
“fluid_type”: 0,
“include_tank_battery”: false,
“include_tank_temperature”: false,
“tank_battery_voltage”: 3.3,
“tank_capacity”: 0.2,
“temperature_type”: 2,
“include_humidity”: false,
“include_pressure”: false,
“include_temp_battery”: false,
“temp_battery_voltage”: 3.3,
“x”: 130,
“y”: 200,
“wires”: [

]
},
{
“id”: “d6ec2b310e1c6653”,
“type”: “function”,
“z”: “c6138a722672e3a4”,
“name”: “Energy”,
“func”: “msg.payload=(msg.payload.switch0.aenergy.total) / 1000;\nreturn msg;”,
“outputs”: 1,
“timeout”: 0,
“noerr”: 0,
“initialize”: “”,
“finalize”: “”,
“libs”: ,
“x”: 960,
“y”: 620,
“wires”: [
[
“b31e0eae13473b1e”
]
]
},
{
“id”: “45b8c5099165ce10”,
“type”: “debug”,
“z”: “c6138a722672e3a4”,
“name”: “debug 2”,
“active”: false,
“tosidebar”: true,
“console”: false,
“tostatus”: false,
“complete”: “false”,
“statusVal”: “”,
“statusType”: “auto”,
“x”: 760,
“y”: 260,
“wires”:
},
{
“id”: “b31e0eae13473b1e”,
“type”: “victron-output-custom”,
“z”: “c6138a722672e3a4”,
“service”: “com.victronenergy.grid/100”,
“path”: “/Ac/L1/Energy/Forward”,
“serviceObj”: {
“service”: “com.victronenergy.grid/100”,
“name”: “Shore power (100)”
},
“pathObj”: {
“path”: “/Ac/L1/Energy/Forward”,
“name”: “/Ac/L1/Energy/Forward”,
“type”: “number”,
“value”: 17.93982
},
“name”: “Shore power kWh”,
“onlyChanges”: false,
“roundValues”: “no”,
“rateLimit”: 0,
“outputs”: 0,
“conditionalMode”: false,
“condition1Operator”: “>”,
“condition2Enabled”: false,
“condition2Service”: “”,
“condition2Path”: “”,
“condition2Operator”: “>”,
“logicOperator”: “AND”,
“outputTrue”: “true”,
“outputFalse”: “false”,
“outputOnChange”: false,
“debounce”: 2000,
“x”: 1420,
“y”: 620,
“wires”:
},
{
“id”: “3070333cedb95a26”,
“type”: “victron-virtual-switch”,
“z”: “c6138a722672e3a4”,
“name”: “Shore”,
“outputs”: 2,
“switch_1_type”: 1,
“switch_1_initial”: 0,
“switch_1_label”: “”,
“switch_1_customname”: “Shore power”,
“switch_1_group”: “Shelly’s”,
“switch_1_include_measurement”: false,
“switch_1_rgb_color_wheel”: false,
“switch_1_cct_wheel”: false,
“switch_1_rgb_white_dimmer”: false,
“x”: 110,
“y”: 540,
“wires”: [
,
[
“bc7370cc3f4c60b0”,
“957e3f4e6a6134a6”
]
]
},
{
“id”: “bc7370cc3f4c60b0”,
“type”: “debug”,
“z”: “c6138a722672e3a4”,
“name”: “debug 1”,
“active”: false,
“tosidebar”: true,
“console”: false,
“tostatus”: false,
“complete”: “false”,
“statusVal”: “”,
“statusType”: “auto”,
“x”: 300,
“y”: 480,
“wires”:
},
{
“id”: “957e3f4e6a6134a6”,
“type”: “function”,
“z”: “c6138a722672e3a4”,
“name”: “function 1”,
“func”: “if(msg.payload == 1){\n msg.url = “http://192.168.1.110/rpc/Switch.Set?id=0&on=true\”;\n}\nelse {\n msg.url = “http://192.168.1.110/rpc/Switch.Set?id=0&on=false\”;\n}\n\nreturn msg;”,
“outputs”: 1,
“timeout”: 0,
“noerr”: 0,
“initialize”: “”,
“finalize”: “”,
“libs”: ,
“x”: 320,
“y”: 580,
“wires”: [
[
“32932baa6238b437”,
“a9ebbf3cb68e7d11”
]
]
},
{
“id”: “32932baa6238b437”,
“type”: “debug”,
“z”: “c6138a722672e3a4”,
“name”: “debug 4”,
“active”: false,
“tosidebar”: true,
“console”: false,
“tostatus”: false,
“complete”: “false”,
“statusVal”: “”,
“statusType”: “auto”,
“x”: 500,
“y”: 520,
“wires”:
},
{
“id”: “a9ebbf3cb68e7d11”,
“type”: “http request”,
“z”: “c6138a722672e3a4”,
“name”: “”,
“method”: “GET”,
“ret”: “txt”,
“paytoqs”: false,
“url”: “”,
“persist”: false,
“insecureHTTPParser”: false,
“authType”: “”,
“senderr”: false,
“headers”: ,
“x”: 530,
“y”: 660,
“wires”: [
[
“52f343d7439835e4”
]
]
},
{
“id”: “52f343d7439835e4”,
“type”: “debug”,
“z”: “c6138a722672e3a4”,
“name”: “debug 3”,
“active”: false,
“tosidebar”: true,
“console”: false,
“tostatus”: false,
“complete”: “false”,
“statusVal”: “”,
“statusType”: “auto”,
“x”: 700,
“y”: 600,
“wires”:
},
{
“id”: “dd982556fd6df3e9”,
“type”: “comment”,
“z”: “c6138a722672e3a4”,
“name”: “”,
“info”: “”,
“x”: 120,
“y”: 80,
“wires”:
},
{
“id”: “e41a6598636e7524”,
“type”: “comment”,
“z”: “c6138a722672e3a4”,
“name”: “”,
“info”: “”,
“x”: 120,
“y”: 140,
“wires”:
},
{
“id”: “7c8354003f1ad7b9”,
“type”: “global-config”,
“env”: ,
“modules”: {
“node-red-contrib-shelly”: “11.10.1”,
“@victronenergy/node-red-contrib-victron”: “1.6.64”
}
}
]

Perhaps there is a way to do this, and someone can help me.

Many thanks,

Wolfgang

Please either upload the flow here as a file for download or format it as code, OR, best of all, use the option available here in the forum to insert it as a Node-RED flow.

Thanks,

I wasn’t aware of that :+1:

As it was, you can’t import the flow elsewhere without errors…

I think there are several possibilities…
For example, you could check in another flow whether the Shelly is available

  • msg.payload.online true/false from the Shelly node
  • via ping (ping node)
  • via MQTT

and then deactivate the flow with the measurement, or set all the measured values to zero; that would of course be easier to do in the same flow.
I hope I have understood your question correctly.

First of all, thanks for the quick reply.

As I understand your answer, you’ve understood my question/problem correctly. Checking, for example, via ping or payload.online would be the right approach. I wouldn’t really mind whether Shelly is disabled or the values are set to 0. What would I need to change to set the values to 0?

Something along these lines, UNTESTED!!!
Instead of the Switch_Node, you could also do this via if, when in the 4 Function nodes, or something…

[
    {
        "id": "c6138a722672e3a4",
        "type": "tab",
        "label": "Flow 1",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "fff1e473d2dbd6e8",
        "type": "shelly-gen2",
        "z": "c6138a722672e3a4",
        "hostname": "192.168.1.110",
        "description": "Shelly 1PM",
        "mode": "polling",
        "verbose": false,
        "server": "",
        "outputmode": "event",
        "uploadretryinterval": 5000,
        "pollinginterval": 5000,
        "pollstatus": true,
        "getstatusoncommand": true,
        "devicetype": "SNSW-001P16EU",
        "devicetypemustmatchexactly": true,
        "captureblutooth": false,
        "outputs": 1,
        "x": 570,
        "y": 420,
        "wires": [
            [
                "45b8c5099165ce10",
                "1a4b1757f75dd34f"
            ]
        ]
    },
    {
        "id": "c65c333b706a9c30",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Spannung",
        "func": "msg.payload=(msg.payload.switch0.voltage);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 970,
        "y": 320,
        "wires": [
            [
                "7fa30c780d8b995d"
            ]
        ]
    },
    {
        "id": "cb23c2277957bfb3",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Strom",
        "func": "msg.payload=(msg.payload.switch0.current);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 950,
        "y": 360,
        "wires": [
            [
                "35087ed2a10a86ba"
            ]
        ]
    },
    {
        "id": "ea0397b490f2b062",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Leistung",
        "func": "msg.payload=(msg.payload.switch0.apower);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 960,
        "y": 400,
        "wires": [
            [
                "b1a58d25df26d16a"
            ]
        ]
    },
    {
        "id": "7fa30c780d8b995d",
        "type": "victron-output-custom",
        "z": "c6138a722672e3a4",
        "service": "com.victronenergy.grid/100",
        "path": "/Ac/L1/Voltage",
        "serviceObj": {
            "service": "com.victronenergy.grid/100",
            "name": "Landstrom (100)"
        },
        "pathObj": {
            "path": "/Ac/L1/Voltage",
            "name": "/Ac/L1/Voltage",
            "type": "number",
            "value": 0
        },
        "name": "Landstrom V",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1410,
        "y": 320,
        "wires": []
    },
    {
        "id": "35087ed2a10a86ba",
        "type": "victron-output-custom",
        "z": "c6138a722672e3a4",
        "service": "com.victronenergy.grid/100",
        "path": "/Ac/L1/Current",
        "serviceObj": {
            "service": "com.victronenergy.grid/100",
            "name": "Landstrom (100)"
        },
        "pathObj": {
            "path": "/Ac/L1/Current",
            "name": "/Ac/L1/Current",
            "type": "number",
            "value": 0.095
        },
        "name": "Landstrom A",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1410,
        "y": 420,
        "wires": []
    },
    {
        "id": "b1a58d25df26d16a",
        "type": "victron-output-custom",
        "z": "c6138a722672e3a4",
        "service": "com.victronenergy.grid/100",
        "path": "/Ac/L1/Power",
        "serviceObj": {
            "service": "com.victronenergy.grid/100",
            "name": "Landstrom (100)"
        },
        "pathObj": {
            "path": "/Ac/L1/Power",
            "name": "/Ac/L1/Power",
            "type": "number",
            "value": 3
        },
        "name": "Landstrom W",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1420,
        "y": 520,
        "wires": []
    },
    {
        "id": "339af066d9f15b2b",
        "type": "victron-virtual",
        "z": "c6138a722672e3a4",
        "name": "Landstrom",
        "outputs": 1,
        "device": "grid",
        "default_values": true,
        "acload_nrofphases": 1,
        "enable_s2support": false,
        "battery_capacity": 25,
        "include_battery_temperature": false,
        "battery_voltage_preset": "24",
        "battery_voltage_custom": 24,
        "generator_type": "ac",
        "generator_nrofphases": 1,
        "include_engine_hours": false,
        "include_starter_voltage": false,
        "include_history_energy": false,
        "grid_nrofphases": 1,
        "include_motor_temp": false,
        "include_controller_temp": false,
        "include_coolant_temp": false,
        "include_motor_rpm": true,
        "include_motor_direction": true,
        "position": 0,
        "pvinverter_nrofphases": 1,
        "switch_1_type": 1,
        "switch_1_min": 0,
        "switch_1_max": "",
        "switch_1_initial": 0,
        "switch_1_label": "",
        "switch_1_unit": "",
        "switch_1_step": 1,
        "switch_1_customname": "",
        "switch_1_group": "",
        "switch_1_include_measurement": false,
        "switch_1_rgb_color_wheel": false,
        "switch_1_cct_wheel": false,
        "switch_1_rgb_white_dimmer": false,
        "fluid_type": 0,
        "include_tank_battery": false,
        "include_tank_temperature": false,
        "tank_battery_voltage": 3.3,
        "tank_capacity": 0.2,
        "temperature_type": 2,
        "include_humidity": false,
        "include_pressure": false,
        "include_temp_battery": false,
        "temp_battery_voltage": 3.3,
        "x": 130,
        "y": 200,
        "wires": [
            []
        ]
    },
    {
        "id": "d6ec2b310e1c6653",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Energie",
        "func": "msg.payload=(msg.payload.switch0.aenergy.total) / 1000;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 960,
        "y": 440,
        "wires": [
            [
                "b31e0eae13473b1e"
            ]
        ]
    },
    {
        "id": "45b8c5099165ce10",
        "type": "debug",
        "z": "c6138a722672e3a4",
        "name": "debug 2",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 260,
        "wires": []
    },
    {
        "id": "b31e0eae13473b1e",
        "type": "victron-output-custom",
        "z": "c6138a722672e3a4",
        "service": "com.victronenergy.grid/100",
        "path": "/Ac/L1/Energy/Forward",
        "serviceObj": {
            "service": "com.victronenergy.grid/100",
            "name": "Landstrom (100)"
        },
        "pathObj": {
            "path": "/Ac/L1/Energy/Forward",
            "name": "/Ac/L1/Energy/Forward",
            "type": "number",
            "value": 17.93982
        },
        "name": "Landstrom kWh",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1420,
        "y": 620,
        "wires": []
    },
    {
        "id": "3070333cedb95a26",
        "type": "victron-virtual-switch",
        "z": "c6138a722672e3a4",
        "name": "Land",
        "outputs": 2,
        "switch_1_type": 1,
        "switch_1_initial": 0,
        "switch_1_label": "",
        "switch_1_customname": "Landstrom",
        "switch_1_group": "Shelly's",
        "switch_1_include_measurement": false,
        "switch_1_rgb_color_wheel": false,
        "switch_1_cct_wheel": false,
        "switch_1_rgb_white_dimmer": false,
        "x": 110,
        "y": 540,
        "wires": [
            [],
            [
                "bc7370cc3f4c60b0",
                "957e3f4e6a6134a6"
            ]
        ]
    },
    {
        "id": "bc7370cc3f4c60b0",
        "type": "debug",
        "z": "c6138a722672e3a4",
        "name": "debug 1",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 300,
        "y": 480,
        "wires": []
    },
    {
        "id": "957e3f4e6a6134a6",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "function 1",
        "func": "if(msg.payload == 1){\n    msg.url = \"http://192.168.1.110/rpc/Switch.Set?id=0&on=true\";\n}\nelse {\n    msg.url = \"http://192.168.1.110/rpc/Switch.Set?id=0&on=false\";\n}\n\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 320,
        "y": 580,
        "wires": [
            [
                "32932baa6238b437",
                "a9ebbf3cb68e7d11"
            ]
        ]
    },
    {
        "id": "32932baa6238b437",
        "type": "debug",
        "z": "c6138a722672e3a4",
        "name": "debug 4",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 500,
        "y": 520,
        "wires": []
    },
    {
        "id": "a9ebbf3cb68e7d11",
        "type": "http request",
        "z": "c6138a722672e3a4",
        "name": "",
        "method": "GET",
        "ret": "txt",
        "paytoqs": false,
        "url": "",
        "persist": false,
        "insecureHTTPParser": false,
        "authType": "",
        "senderr": false,
        "headers": [],
        "x": 530,
        "y": 660,
        "wires": [
            [
                "52f343d7439835e4"
            ]
        ]
    },
    {
        "id": "52f343d7439835e4",
        "type": "debug",
        "z": "c6138a722672e3a4",
        "name": "debug 3",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 600,
        "wires": []
    },
    {
        "id": "dd982556fd6df3e9",
        "type": "comment",
        "z": "c6138a722672e3a4",
        "name": "",
        "info": "",
        "x": 120,
        "y": 80,
        "wires": []
    },
    {
        "id": "e41a6598636e7524",
        "type": "comment",
        "z": "c6138a722672e3a4",
        "name": "",
        "info": "",
        "x": 120,
        "y": 140,
        "wires": []
    },
    {
        "id": "1a4b1757f75dd34f",
        "type": "switch",
        "z": "c6138a722672e3a4",
        "name": "Shelly vorhanden",
        "property": "payload.online",
        "propertyType": "msg",
        "rules": [
            {
                "t": "true"
            },
            {
                "t": "false"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 770,
        "y": 460,
        "wires": [
            [
                "c65c333b706a9c30",
                "cb23c2277957bfb3",
                "ea0397b490f2b062",
                "d6ec2b310e1c6653"
            ],
            [
                "b8fca4ede420218a",
                "e023c0f6e45c0746",
                "0dbddfbba25a1214",
                "c55b6af1c650cb39"
            ]
        ]
    },
    {
        "id": "b8fca4ede420218a",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Spannung",
        "func": "msg.payload=0;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 970,
        "y": 520,
        "wires": [
            [
                "7fa30c780d8b995d"
            ]
        ]
    },
    {
        "id": "e023c0f6e45c0746",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Strom",
        "func": "msg.payload=0;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 950,
        "y": 560,
        "wires": [
            [
                "35087ed2a10a86ba"
            ]
        ]
    },
    {
        "id": "0dbddfbba25a1214",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Leistung",
        "func": "msg.payload=0;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 960,
        "y": 600,
        "wires": [
            [
                "b1a58d25df26d16a"
            ]
        ]
    },
    {
        "id": "c55b6af1c650cb39",
        "type": "function",
        "z": "c6138a722672e3a4",
        "name": "Energie",
        "func": "msg.payload=0;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 960,
        "y": 640,
        "wires": [
            [
                "b31e0eae13473b1e"
            ]
        ]
    },
    {
        "id": "89adb75c4f90c3c6",
        "type": "global-config",
        "env": [],
        "modules": {
            "node-red-contrib-shelly": "11.7.5",
            "@victronenergy/node-red-contrib-victron": "1.6.63"
        }
    }
]

EDIT: No, you’re cutting power to the Shelly, aren’t you? Then this won’t work, so you’ll have to do it via ping…

That already looks better; all the values are now set to 0. However, when I plug in shore power, no values are displayed. At the very least, I should be able to see the voltage. I also can’t control the Shelly via the switch in Victron anymore:

the Shelly is in the top left

The error message in the debug output:

{“ble”:{},“cloud”:{“connected”:true},“input0”:{“id”:0,“state”:false},“mqtt”:{“connected”:false},“switch0”:{“id”:0,“source”:“SHC”,“output”:false,“apower”:0,“voltage”:236.4,“current”:0,“aenergy”:{“total”:61574.025,“by_minute”:[6590.077,7479.111,7459.996],“minute_ts”:1788701280},“temperature”:{“tC”:39.8,“tF”:103.7}},“sys”:{“mac”:“901506459DE0”,“restart_required”:false,“time”:“15:28”,“unixtime”:1788701320,“last_sync_ts”:1788700873,“uptime”:453,“ram_size”:265760,“ram_free”:119216,“ram_min_free”:108092,“fs_size”:393216,“fs_free”:126976,“cfg_rev”:23,“kvs_rev”:0,“schedule_rev”:1,“webhook_rev”:0,“btrelay_rev”:0,“available_updates”:{},“reset_reason”:1,“utc_offset”:7200},“wifi”:{“sta_ip”:“192.168.1.110”,“status”:“got ip”,“ssid”:“EtruscoWLAN”,“bssid”:“50:3d:d1:48:b6:75”,“rssi”:-50},“ws”:{“connected”:false}}

Try using ping; you may still need to install the node-red-node-ping palette.

[
    {
        "id": "6030ab7149722c5a",
        "type": "tab",
        "label": "Flow 1",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "52f534f043d024f5",
        "type": "shelly-gen2",
        "z": "6030ab7149722c5a",
        "hostname": "192.168.1.110",
        "description": "Shelly 1PM",
        "mode": "polling",
        "verbose": false,
        "server": "",
        "outputmode": "event",
        "uploadretryinterval": 5000,
        "pollinginterval": 5000,
        "pollstatus": true,
        "getstatusoncommand": true,
        "devicetype": "SNSW-001P16EU",
        "devicetypemustmatchexactly": true,
        "captureblutooth": false,
        "outputs": 1,
        "x": 550,
        "y": 280,
        "wires": [
            [
                "53bcf2985387f01d"
            ]
        ]
    },
    {
        "id": "53bcf2985387f01d",
        "type": "function",
        "z": "6030ab7149722c5a",
        "name": "Nur wenn Ping OK",
        "func": "let online = flow.get(\"shelly_192_168_1_110_online\");\n\nif (online === true) {\n    return msg;\n}\n\n// Shelly ist laut Ping offline.\n// Shelly-Messwerte werden deshalb nicht weitergegeben.\nreturn null;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 760,
        "y": 280,
        "wires": [
            [
                "945f13d078779731",
                "2b71f0988fc0e635",
                "ae8cdd06484514df",
                "a09e33c67e5dba0a",
                "7f7da46310a84c8d"
            ]
        ]
    }
]

Sorry, I’d overlooked something—I’ve updated the flow again…
I can’t test it, of course, as I don’t have the same or a similar setup available.

Hello Sender,

First of all, I have to apologise for only getting in touch now; last week was a little stressful with the Schützenfest, my boss turning 60, …

I’ve now imported the flow and got the following result:

I can switch the Shelly on and off using the switch, and with the DC loads I can see the energy currently being supplied by the shore power, but nothing is displayed for Shelly/shore power/mains (top left):

I enabled the debug on “Ping Shelly” and receive messages. Then I added a debug node to “Ping OK” — shouldn’t there be an output there too (if that’s what it’s called)?

Debug 6 on the Shelly also produces output containing, among other things, all the values, but there isn’t any with Debug 9. Perhaps that helps?

As a complete beginner when it comes to AI, I asked the AI for help and have now managed to get it working like this:

I also had the problem that the switch states between the Shelly app and Victron VRM were not synchronised, at least in one direction (Shelly → Victron). That is working now too.

[
    {
        "id": "38978352000de3ce",
        "type": "tab",
        "label": "Flow 1",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "81225186db1344dd",
        "type": "victron-virtual",
        "z": "38978352000de3ce",
        "name": "Landstrom",
        "outputs": 1,
        "device": "grid",
        "default_values": true,
        "acload_nrofphases": 1,
        "enable_s2support": false,
        "battery_capacity": 25,
        "include_battery_temperature": false,
        "battery_voltage_preset": "24",
        "battery_voltage_custom": 24,
        "generator_type": "ac",
        "generator_nrofphases": 1,
        "include_engine_hours": false,
        "include_starter_voltage": false,
        "include_history_energy": false,
        "grid_nrofphases": 1,
        "include_motor_temp": false,
        "include_controller_temp": false,
        "include_coolant_temp": false,
        "include_motor_rpm": true,
        "include_motor_direction": true,
        "position": 0,
        "pvinverter_nrofphases": 1,
        "switch_1_type": 1,
        "switch_1_min": 0,
        "switch_1_max": "",
        "switch_1_initial": 0,
        "switch_1_label": "",
        "switch_1_unit": "",
        "switch_1_step": 1,
        "switch_1_customname": "",
        "switch_1_group": "",
        "switch_1_include_measurement": false,
        "switch_1_rgb_color_wheel": false,
        "switch_1_cct_wheel": false,
        "switch_1_rgb_white_dimmer": false,
        "fluid_type": 0,
        "include_tank_battery": false,
        "include_tank_temperature": false,
        "tank_battery_voltage": 3.3,
        "tank_capacity": 0.2,
        "temperature_type": 2,
        "include_humidity": false,
        "include_pressure": false,
        "include_temp_battery": false,
        "temp_battery_voltage": 3.3,
        "x": 130,
        "y": 200,
        "wires": [
            []
        ]
    },
    {
        "id": "5065b4b8bbdfc223",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "function 1",
        "func": "if(msg.payload == 1){\n    msg.url = \"http://192.168.1.110/rpc/Switch.Set?id=0&on=true\";\n}\nelse {\n    msg.url = \"http://192.168.1.110/rpc/Switch.Set?id=0&on=false\";\n}\n\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 320,
        "y": 580,
        "wires": [
            [
                "cc6c7bd089968e52",
                "00158cf1148a4f34"
            ]
        ]
    },
    {
        "id": "cc6c7bd089968e52",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 4",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 500,
        "y": 520,
        "wires": []
    },
    {
        "id": "00158cf1148a4f34",
        "type": "http request",
        "z": "38978352000de3ce",
        "name": "",
        "method": "GET",
        "ret": "txt",
        "paytoqs": false,
        "url": "",
        "persist": false,
        "insecureHTTPParser": false,
        "authType": "",
        "senderr": false,
        "headers": [],
        "x": 530,
        "y": 660,
        "wires": [
            [
                "6caf640d8be63871"
            ]
        ]
    },
    {
        "id": "6caf640d8be63871",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 3",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 700,
        "y": 600,
        "wires": []
    },
    {
        "id": "99b126d69408e77b",
        "type": "comment",
        "z": "38978352000de3ce",
        "name": "",
        "info": "",
        "x": 120,
        "y": 80,
        "wires": []
    },
    {
        "id": "3f832febe332d826",
        "type": "comment",
        "z": "38978352000de3ce",
        "name": "",
        "info": "",
        "x": 120,
        "y": 140,
        "wires": []
    },
    {
        "id": "94ed14fed176696a",
        "type": "shelly-gen2",
        "z": "38978352000de3ce",
        "hostname": "192.168.1.110",
        "description": "Shelly 1PM",
        "mode": "polling",
        "verbose": false,
        "server": "",
        "outputmode": "event",
        "uploadretryinterval": 5000,
        "pollinginterval": 5000,
        "pollstatus": true,
        "getstatusoncommand": true,
        "devicetype": "SNSW-001P16EU",
        "devicetypemustmatchexactly": true,
        "captureblutooth": false,
        "outputs": 1,
        "x": 380,
        "y": 200,
        "wires": [
            [
                "c6542db06eb33100",
                "ba03dbd139ee8806"
            ]
        ]
    },
    {
        "id": "c6542db06eb33100",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Nur wenn Ping OK",
        "func": "let online = flow.get(\"shelly_192_168_1_110_online\");\n\nif (online === true) {\n    return msg;\n}\n\n// Shelly ist laut Ping offline.\n// Shelly-Messwerte werden deshalb nicht weitergegeben.\nreturn null;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 590,
        "y": 200,
        "wires": [
            [
                "bcd43659726eb68c",
                "37c579afd89fcea5",
                "75a6ce8b51949642",
                "fec5f097cb1f66dc",
                "5fd351c4b08bc3a7",
                "0c2b279951cd7fd4"
            ]
        ]
    },
    {
        "id": "37c579afd89fcea5",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Spannung",
        "func": "msg.payload=(msg.payload.switch0.voltage);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 800,
        "y": 240,
        "wires": [
            [
                "011b7e71cc2dc7ec",
                "172ef2df032ce64f"
            ]
        ]
    },
    {
        "id": "75a6ce8b51949642",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Strom",
        "func": "msg.payload=(msg.payload.switch0.current);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 780,
        "y": 280,
        "wires": [
            [
                "70168dcc56dc2139",
                "bd7fee9623d879d2"
            ]
        ]
    },
    {
        "id": "fec5f097cb1f66dc",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Leistung",
        "func": "msg.payload=(msg.payload.switch0.apower);\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 790,
        "y": 320,
        "wires": [
            [
                "5ba0c3d46554fb89"
            ]
        ]
    },
    {
        "id": "011b7e71cc2dc7ec",
        "type": "victron-output-custom",
        "z": "38978352000de3ce",
        "service": "com.victronenergy.grid/101",
        "path": "/Ac/L1/Voltage",
        "serviceObj": {
            "service": "com.victronenergy.grid/101",
            "name": "Landstrom (101)"
        },
        "pathObj": {
            "path": "/Ac/L1/Voltage",
            "name": "/Ac/L1/Voltage",
            "type": "number",
            "value": 0
        },
        "name": "Landstrom V",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1240,
        "y": 240,
        "wires": []
    },
    {
        "id": "70168dcc56dc2139",
        "type": "victron-output-custom",
        "z": "38978352000de3ce",
        "service": "com.victronenergy.grid/101",
        "path": "/Ac/L1/Current",
        "serviceObj": {
            "service": "com.victronenergy.grid/101",
            "name": "Landstrom (101)"
        },
        "pathObj": {
            "path": "/Ac/L1/Current",
            "name": "/Ac/L1/Current",
            "type": "number",
            "value": 0
        },
        "name": "Landstrom A",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1240,
        "y": 340,
        "wires": []
    },
    {
        "id": "5ba0c3d46554fb89",
        "type": "victron-output-custom",
        "z": "38978352000de3ce",
        "service": "com.victronenergy.grid/101",
        "path": "/Ac/L1/Power",
        "serviceObj": {
            "service": "com.victronenergy.grid/101",
            "name": "Landstrom (101)"
        },
        "pathObj": {
            "path": "/Ac/L1/Power",
            "name": "/Ac/L1/Power",
            "type": "number",
            "value": 0
        },
        "name": "Landstrom W",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1250,
        "y": 440,
        "wires": []
    },
    {
        "id": "5fd351c4b08bc3a7",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Energie",
        "func": "msg.payload=(msg.payload.switch0.aenergy.total) / 1000;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 790,
        "y": 360,
        "wires": [
            [
                "3c9c90c6555a274c"
            ]
        ]
    },
    {
        "id": "bcd43659726eb68c",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 9",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 800,
        "y": 160,
        "wires": []
    },
    {
        "id": "3c9c90c6555a274c",
        "type": "victron-output-custom",
        "z": "38978352000de3ce",
        "service": "com.victronenergy.grid/101",
        "path": "/Ac/L1/Energy/Forward",
        "serviceObj": {
            "service": "com.victronenergy.grid/101",
            "name": "Landstrom (101)"
        },
        "pathObj": {
            "path": "/Ac/L1/Energy/Forward",
            "name": "/Ac/L1/Energy/Forward",
            "type": "number",
            "value": 0
        },
        "name": "Landstrom kWh",
        "onlyChanges": false,
        "roundValues": "no",
        "rateLimit": 0,
        "outputs": 0,
        "conditionalMode": false,
        "condition1Operator": ">",
        "condition2Enabled": false,
        "condition2Service": "",
        "condition2Path": "",
        "condition2Operator": ">",
        "logicOperator": "AND",
        "outputTrue": "true",
        "outputFalse": "false",
        "outputOnChange": false,
        "debounce": 2000,
        "x": 1250,
        "y": 540,
        "wires": []
    },
    {
        "id": "3bc43160ddfcb85f",
        "type": "switch",
        "z": "38978352000de3ce",
        "name": "Shelly nicht vorhanden",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "false"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 1,
        "x": 550,
        "y": 440,
        "wires": [
            [
                "d3f1719cc10f180f"
            ]
        ]
    },
    {
        "id": "d3f1719cc10f180f",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Werte auf \"0\" setzen",
        "func": "msg.payload=0;\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 830,
        "y": 440,
        "wires": [
            [
                "011b7e71cc2dc7ec",
                "70168dcc56dc2139",
                "5ba0c3d46554fb89",
                "3c9c90c6555a274c"
            ]
        ]
    },
    {
        "id": "b8074ef1c0114d96",
        "type": "ping",
        "z": "38978352000de3ce",
        "protocol": "IPv4",
        "mode": "timed",
        "name": "Ping Shelly",
        "host": "192.168.1.110",
        "timer": "5",
        "inputs": 0,
        "x": 320,
        "y": 300,
        "wires": [
            [
                "9c69995959f2c2af",
                "94d44401f2bb78bf",
                "3bc43160ddfcb85f"
            ]
        ]
    },
    {
        "id": "9c69995959f2c2af",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "Ping OK?",
        "func": "const online = typeof msg.payload === \"number\";\n\nflow.set(\"shelly_192_168_1_110_online\", online);\n\nmsg.online = online;\n\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 530,
        "y": 360,
        "wires": [
            [
                "273bc2de0f0f4782"
            ]
        ]
    },
    {
        "id": "94d44401f2bb78bf",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "Ping Debug",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "payload",
        "targetType": "msg",
        "statusVal": "",
        "statusType": "auto",
        "x": 510,
        "y": 260,
        "wires": []
    },
    {
        "id": "22387b63d34c898a",
        "type": "comment",
        "z": "38978352000de3ce",
        "name": "Messwerte nur bei Online",
        "info": "",
        "x": 700,
        "y": 100,
        "wires": []
    },
    {
        "id": "ba03dbd139ee8806",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 6",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 440,
        "y": 60,
        "wires": []
    },
    {
        "id": "273bc2de0f0f4782",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 5",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 620,
        "y": 320,
        "wires": []
    },
    {
        "id": "172ef2df032ce64f",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 7",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 1000,
        "y": 180,
        "wires": []
    },
    {
        "id": "bd7fee9623d879d2",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 8",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 980,
        "y": 260,
        "wires": []
    },
    {
        "id": "e6b4db470993f4e5",
        "type": "victron-virtual-switch",
        "z": "38978352000de3ce",
        "name": "Landstrom",
        "outputs": 2,
        "switch_1_type": "1",
        "switch_1_initial": 0,
        "switch_1_label": "",
        "switch_1_customname": "Land",
        "switch_1_group": "Shelly's",
        "switch_1_include_measurement": false,
        "switch_1_rgb_color_wheel": false,
        "switch_1_cct_wheel": false,
        "switch_1_rgb_white_dimmer": false,
        "x": 110,
        "y": 680,
        "wires": [
            [
                "db4156c06fdea158"
            ],
            [
                "5065b4b8bbdfc223"
            ]
        ]
    },
    {
        "id": "db4156c06fdea158",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 10",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 300,
        "y": 480,
        "wires": []
    },
    {
        "id": "0c2b279951cd7fd4",
        "type": "function",
        "z": "38978352000de3ce",
        "name": "function 2",
        "func": "msg.payload = {\n    \"/SwitchableOutput/output_1/State\":\n        msg.payload.switch0.output ? 1 : 0\n};\n\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 800,
        "y": 200,
        "wires": [
            [
                "27b1d495907a549d",
                "e6b4db470993f4e5"
            ]
        ]
    },
    {
        "id": "27b1d495907a549d",
        "type": "debug",
        "z": "38978352000de3ce",
        "name": "debug 11",
        "active": false,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 980,
        "y": 120,
        "wires": []
    },
    {
        "id": "fb88127eb23c3d9c",
        "type": "global-config",
        "env": [],
        "modules": {
            "@victronenergy/node-red-contrib-victron": "1.6.64",
            "node-red-contrib-shelly": "11.10.1",
            "node-red-node-ping": "0.3.3"
        }
    }
]

Thanks anyway for the support — the basic configuration did come from sender :+1: