Inevitably, the server url was deleted.
[
{
"id": "7fe048f505bd8db7",
"type": "subflow",
"name": "setCurTemp",
"info": "",
"category": "",
"in": [],
"out": [
{
"x": 980,
"y": 100,
"wires": [
{
"id": "dc479e888e57b1b3",
"port": 0
}
]
},
{
"x": 1000,
"y": 140,
"wires": [
{
"id": "5c3172c721d90656",
"port": 0
}
]
},
{
"x": 1370,
"y": 280,
"wires": [
{
"id": "3825b36d60f9a406",
"port": 0
},
{
"id": "d62a7614f23834f6",
"port": 0
}
]
},
{
"x": 1360,
"y": 360,
"wires": [
{
"id": "f5f3e42d7fdbb76f",
"port": 0
},
{
"id": "27b4409555559201",
"port": 0
}
]
},
{
"x": 1360,
"y": 480,
"wires": [
{
"id": "f13490c1f51eb4e9",
"port": 0
},
{
"id": "bae6c4d3c0aed585",
"port": 0
}
]
},
{
"x": 1320,
"y": 560,
"wires": [
{
"id": "e564c003e5bf429b",
"port": 0
}
]
},
{
"x": 1190,
"y": 640,
"wires": [
{
"id": "349cc561ea512842",
"port": 0
}
]
}
],
"env": [
{
"name": "SECTOR",
"type": "str",
"value": "oc/"
}
],
"meta": {},
"color": "#3FADB5",
"outputLabels": [
"setTemp",
"setCurrentTemp",
"setDefrostingWay",
"setVentilateCtrlDefro",
"setVentilateCtrlFrozen",
"setSystemCondition",
"setErrorConditoin"
]
},
{
"id": "e50167dbfa994cf0",
"type": "switch",
"z": "7fe048f505bd8db7",
"name": "switch",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "hask",
"v": "setTemp",
"vt": "str"
},
{
"t": "hask",
"v": "setCurrentTemp",
"vt": "str"
},
{
"t": "hask",
"v": "setDefrostingWay",
"vt": "str"
},
{
"t": "hask",
"v": "setVentilateCtrlDefro",
"vt": "str"
},
{
"t": "hask",
"v": "setVentilateCtrlFrozen",
"vt": "str"
},
{
"t": "hask",
"v": "setSystemCondition",
"vt": "str"
},
{
"t": "hask",
"v": "setErrorConditoin",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 7,
"x": 490,
"y": 300,
"wires": [
[
"dc479e888e57b1b3"
],
[
"5c3172c721d90656"
],
[
"e33acc35d8534b59"
],
[
"8bec506697faebc0"
],
[
"f3613415739f3849"
],
[
"70791a51d7dffa32"
],
[
"349cc561ea512842"
]
],
"outputLabels": [
"temp",
"",
"",
"",
"",
"",
""
]
},
{
"id": "4c9cf01d71ef2434",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.value",
"tot": "jsonata"
},
{
"t": "set",
"p": "slaveNum",
"pt": "msg",
"to": "payload.slaveNum",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 260,
"y": 300,
"wires": [
[
"e50167dbfa994cf0"
]
]
},
{
"id": "dc479e888e57b1b3",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setTemp}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 760,
"y": 100,
"wires": [
[]
]
},
{
"id": "5c3172c721d90656",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setCurrentTemp}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 760,
"y": 140,
"wires": [
[]
]
},
{
"id": "e33acc35d8534b59",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setDefrostingWay}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 700,
"y": 280,
"wires": [
[
"9e11f788737b6f6a"
]
]
},
{
"id": "8bec506697faebc0",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setVentilateCtrlDefro}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 700,
"y": 340,
"wires": [
[
"69329fd4c611a2f2"
]
]
},
{
"id": "f3613415739f3849",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setVentilateCtrlFrozen}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 720,
"y": 480,
"wires": [
[
"3df537af39f2ac6c"
]
]
},
{
"id": "70791a51d7dffa32",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setSystemCondition}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 720,
"y": 560,
"wires": [
[
"e564c003e5bf429b"
]
]
},
{
"id": "349cc561ea512842",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "{\"value\": payload.setErrorConditoin}",
"tot": "jsonata"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 720,
"y": 640,
"wires": [
[]
]
},
{
"id": "9e11f788737b6f6a",
"type": "switch",
"z": "7fe048f505bd8db7",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "0",
"vt": "num"
},
{
"t": "eq",
"v": "1",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 870,
"y": 280,
"wires": [
[
"3825b36d60f9a406"
],
[
"d62a7614f23834f6"
]
]
},
{
"id": "3825b36d60f9a406",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 260,
"wires": [
[]
]
},
{
"id": "d62a7614f23834f6",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 300,
"wires": [
[]
]
},
{
"id": "69329fd4c611a2f2",
"type": "switch",
"z": "7fe048f505bd8db7",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "0",
"vt": "num"
},
{
"t": "eq",
"v": "1",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 870,
"y": 340,
"wires": [
[
"f5f3e42d7fdbb76f"
],
[
"27b4409555559201"
]
]
},
{
"id": "f5f3e42d7fdbb76f",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 360,
"wires": [
[]
]
},
{
"id": "27b4409555559201",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 400,
"wires": [
[]
]
},
{
"id": "3df537af39f2ac6c",
"type": "switch",
"z": "7fe048f505bd8db7",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "0",
"vt": "num"
},
{
"t": "eq",
"v": "1",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 2,
"x": 890,
"y": 480,
"wires": [
[
"f13490c1f51eb4e9"
],
[
"bae6c4d3c0aed585"
]
]
},
{
"id": "f13490c1f51eb4e9",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1070,
"y": 460,
"wires": [
[]
]
},
{
"id": "bae6c4d3c0aed585",
"type": "change",
"z": "7fe048f505bd8db7",
"name": "",
"rules": [
{
"t": "set",
"p": "data",
"pt": "msg",
"to": "false",
"tot": "bool"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1030,
"y": 500,
"wires": [
[]
]
},
{
"id": "e564c003e5bf429b",
"type": "function",
"z": "7fe048f505bd8db7",
"name": "",
"func": "// error masking table \nconst status_mask = [\"power\", \"frozen\", \"solenoid\", \"compresher\",\n \"fan\", \"frozenHeater\", \"roomHeater\"\n ];\n\nconst value = msg.payload.value;\nlet mask = 1;\n\n\nfor (let status of status_mask) {\n if ((value & mask) && status !== null) {\n msg.payload[status] = \"ON\";\n }\n msg.payload[status] = \"OFF\"\n mask = mask<<1;\n}\n\nreturn msg;",
"outputs": 1,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1000,
"y": 560,
"wires": [
[]
]
},
{
"id": "9adfcda93e8526d7",
"type": "mqtt in",
"z": "7fe048f505bd8db7",
"name": "",
"topic": "",
"qos": "2",
"datatype": "auto",
"broker": "",
"nl": false,
"rap": true,
"rh": 0,
"inputs": 0,
"x": 50,
"y": 300,
"wires": [
[
"4c9cf01d71ef2434"
]
]
}
]