Thanks Micky! A Java expert I am not, so I did get confused with the function code (no fault of yours, TotallyInformation, I appreciate the help you've given me on a few things now) and sought out another route as I don't know how to work with the outputs.
I ended up doing this- when I revisited and saw your suggestion I was pleasantly surprised to see I wasn't too far off from your idea. While the backend is bulky, it will allow me to show a functional and clean iteration for a meeting I have in 17 minutes with higher ups! Now I just need to figure out how to change the order of the dashboard elements.
[
{
"id": "d7584b9aa54104a5",
"type": "mqtt in",
"z": "3346a6d4cdae435b",
"name": "",
"topic": "Valve Status",
"qos": "2",
"datatype": "auto",
"broker": "de3df31c4a66b745",
"nl": false,
"rap": true,
"rh": 0,
"inputs": 0,
"x": 170,
"y": 640,
"wires": [
[
"11d74977c1615f88",
"85c0ac576a78ec41"
]
]
},
{
"id": "11d74977c1615f88",
"type": "debug",
"z": "3346a6d4cdae435b",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 350,
"y": 720,
"wires": []
},
{
"id": "8e57e6bf0767e24b",
"type": "ui_text",
"z": "3346a6d4cdae435b",
"group": "f987d5aa965097c5",
"order": 2,
"width": 0,
"height": 0,
"name": "",
"label": "Municipal Valve is",
"format": "{{msg.payload}}",
"layout": "row-center",
"className": "",
"x": 990,
"y": 580,
"wires": []
},
{
"id": "48bb2962a3f0b9e4",
"type": "link out",
"z": "3346a6d4cdae435b",
"name": "",
"mode": "link",
"links": [
"13537af4a3f6ee3c"
],
"x": 975,
"y": 500,
"wires": []
},
{
"id": "85c0ac576a78ec41",
"type": "split",
"z": "3346a6d4cdae435b",
"name": "",
"splt": "/",
"spltType": "str",
"arraySplt": 1,
"arraySpltType": "len",
"stream": false,
"addname": "",
"x": 370,
"y": 640,
"wires": [
[
"c716ca04366c2555",
"46661a5491cd5622"
]
]
},
{
"id": "c716ca04366c2555",
"type": "switch",
"z": "3346a6d4cdae435b",
"name": "",
"property": "payload",
"propertyType": "msg",
"rules": [
{
"t": "cont",
"v": "Municipal",
"vt": "str"
},
{
"t": "cont",
"v": "Feed",
"vt": "str"
},
{
"t": "cont",
"v": "Drain",
"vt": "str"
},
{
"t": "cont",
"v": "Transfer",
"vt": "str"
},
{
"t": "cont",
"v": "Rinse",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 5,
"x": 550,
"y": 640,
"wires": [
[
"efbe98f752def4d9",
"b7f91f14dac1d47a"
],
[
"fd1d08618b13fb1e"
],
[
"f6bf78efd8527c12"
],
[
"3c28bc4b6d8bb2d2"
],
[
"961aa7409f8ab9aa"
]
]
},
{
"id": "7ec3c9d4dad71848",
"type": "ui_text",
"z": "3346a6d4cdae435b",
"group": "f987d5aa965097c5",
"order": 11,
"width": 0,
"height": 0,
"name": "",
"label": "Feed Valve is",
"format": "{{msg.payload}}",
"layout": "row-spread",
"className": "",
"x": 980,
"y": 620,
"wires": []
},
{
"id": "d9c642600e7fdd6a",
"type": "ui_text",
"z": "3346a6d4cdae435b",
"group": "f987d5aa965097c5",
"order": 12,
"width": 0,
"height": 0,
"name": "",
"label": "Drain Valve is",
"format": "{{msg.payload}}",
"layout": "row-spread",
"className": "",
"x": 980,
"y": 660,
"wires": []
},
{
"id": "ed932e42e5023963",
"type": "ui_text",
"z": "3346a6d4cdae435b",
"group": "f987d5aa965097c5",
"order": 13,
"width": 0,
"height": 0,
"name": "",
"label": "Transfer Valve is",
"format": "{{msg.payload}}",
"layout": "row-spread",
"className": "",
"x": 980,
"y": 700,
"wires": []
},
{
"id": "4efd4064c343398f",
"type": "ui_text",
"z": "3346a6d4cdae435b",
"group": "f987d5aa965097c5",
"order": 14,
"width": 0,
"height": 0,
"name": "",
"label": "Rinse Valve is",
"format": "{{msg.payload}}",
"layout": "row-spread",
"className": "",
"x": 980,
"y": 740,
"wires": []
},
{
"id": "46661a5491cd5622",
"type": "debug",
"z": "3346a6d4cdae435b",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 550,
"y": 720,
"wires": []
},
{
"id": "efbe98f752def4d9",
"type": "change",
"z": "3346a6d4cdae435b",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "MunicipalON",
"fromt": "str",
"to": "ON",
"tot": "str"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "MunicipalOFF",
"fromt": "str",
"to": "OFF",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 780,
"y": 580,
"wires": [
[
"8e57e6bf0767e24b",
"48bb2962a3f0b9e4",
"5872c83f42fabfbe"
]
]
},
{
"id": "fd1d08618b13fb1e",
"type": "change",
"z": "3346a6d4cdae435b",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "FeedON",
"fromt": "str",
"to": "ON",
"tot": "str"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "FeedOFF",
"fromt": "str",
"to": "OFF",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 780,
"y": 620,
"wires": [
[
"7ec3c9d4dad71848"
]
]
},
{
"id": "f6bf78efd8527c12",
"type": "change",
"z": "3346a6d4cdae435b",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "DrainON",
"fromt": "str",
"to": "ON",
"tot": "str"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "DrainOFF",
"fromt": "str",
"to": "OFF",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 780,
"y": 660,
"wires": [
[
"d9c642600e7fdd6a"
]
]
},
{
"id": "961aa7409f8ab9aa",
"type": "change",
"z": "3346a6d4cdae435b",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "RinseON",
"fromt": "str",
"to": "ON",
"tot": "str"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "RinseOFF",
"fromt": "str",
"to": "OFF",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 780,
"y": 740,
"wires": [
[
"4efd4064c343398f"
]
]
},
{
"id": "3c28bc4b6d8bb2d2",
"type": "change",
"z": "3346a6d4cdae435b",
"name": "",
"rules": [
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "TransferON",
"fromt": "str",
"to": "ON",
"tot": "str"
},
{
"t": "change",
"p": "payload",
"pt": "msg",
"from": "TransferOFF",
"fromt": "str",
"to": "OFF",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 780,
"y": 700,
"wires": [
[
"ed932e42e5023963"
]
]
},
{
"id": "b7f91f14dac1d47a",
"type": "debug",
"z": "3346a6d4cdae435b",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 770,
"y": 540,
"wires": []
},
{
"id": "5872c83f42fabfbe",
"type": "debug",
"z": "3346a6d4cdae435b",
"name": "",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "false",
"statusVal": "",
"statusType": "auto",
"x": 1030,
"y": 540,
"wires": []
},
{
"id": "de3df31c4a66b745",
"type": "mqtt-broker",
"name": "",
"broker": "localhost",
"port": "1883",
"clientid": "Node-RED",
"autoConnect": true,
"usetls": false,
"protocolVersion": "5",
"keepalive": "60",
"cleansession": true,
"birthTopic": "Import",
"birthQos": "0",
"birthRetain": "true",
"birthPayload": "Testing Node-RED",
"birthMsg": {},
"closeTopic": "Import",
"closeQos": "0",
"closeRetain": "true",
"closePayload": "Leaving Node-RED scheduled",
"closeMsg": {},
"willTopic": "Import",
"willQos": "0",
"willRetain": "true",
"willPayload": "Disconnected unexpectedly",
"willMsg": {},
"sessionExpiry": ""
},
{
"id": "f987d5aa965097c5",
"type": "ui_group",
"name": "ClickPlus PLC Test",
"tab": "20b3095113f94d70",
"order": 1,
"disp": true,
"width": "6",
"collapse": false,
"className": ""
},
{
"id": "20b3095113f94d70",
"type": "ui_tab",
"name": "Home",
"icon": "dashboard",
"disabled": false,
"hidden": false
}
]