Value through switch permanently

Hello There,

I use switch nodes to set Lines for a Chart node. Everything was working fine.

Then i wanted to Change the Label of the switches to the Name of the values, so you can read the switch label and activate the needed line.
The renaming of the label works fine to. below is a part of the flow. the whole flow would be to big.

That flow part is a pass by of the normal payload and is joined after the last Change node with the original payload.

My Problem is that with my renaming the value is permanently shown in the Chart, without changing the switch Position in the Dashboard.

how can i do the renaming without "activating" the switch?

[{"id":"e9b9dd78.e10f1","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"{{topic}}","tooltip":"","group":"22029319.b38d4c","order":1,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3530,"y":2370,"wires":[["fef7d669.96ce98"]]},{"id":"fef7d669.96ce98","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck1","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3820,"y":2370,"wires":[["1de859ba.09be96"]]},{"id":"ff5e497e.748c38","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"set","p":"topic","pt":"msg","to":"payload.MQTTWert1name","tot":"msg"},{"t":"delete","p":"payload","pt":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3350,"y":2370,"wires":[["e9b9dd78.e10f1"]]},{"id":"22029319.b38d4c","type":"ui_group","z":"","name":"Messwerte auswählen","tab":"ec7a53af.4ac29","order":1,"disp":true,"width":"29","collapse":false},{"id":"ec7a53af.4ac29","type":"ui_tab","z":"","name":"W16-Chart","icon":"dashboard","order":11,"disabled":false,"hidden":false}]

Greetings
Chorum

I think you are going to have to share more of the flow than the part you did.

One possible problem is that you delete the message payload in the first change node.

So there won't be anything coming out to the second one.

Dunno, but that's just a guess.

But considering the chart usually uses the msg.payload, deleting it won't be helping.

And/or:

Moving an empty (deleted) msg.payload to what it is there also won't help.

Unless you mean to set the msg.payload to the second one.
I got caught with to and move a few times myself.

Ok, so there is the part of the Chart.

please dont Judge me too hard if it could be done better :slight_smile:

[{"id":"8d8bbb3b.66fa58","type":"ui_chart","z":"af61c022.bc96e","name":"","group":"aec4cb8b.d20ef8","order":1,"width":"28","height":"13","label":"W16 Livescreen","chartType":"line","legend":"true","xformat":"HH:mm:ss","interpolate":"bezier","nodata":"","dot":false,"ymin":"-","ymax":"-","removeOlder":"60","removeOlderPoints":"","removeOlderUnit":"1","cutout":0,"useOneColor":false,"colors":["#1f77b4","#aec7e8","#ff7f0e","#2ca02c","#98df8a","#d62728","#ff9896","#9467bd","#c5b0d5"],"useOldStyle":false,"outputs":1,"x":4910,"y":2670,"wires":[[]]},{"id":"1658fa2d.bb5476","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":10,"width":"3","height":"1","name":"","label":"Messwert 1","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2130,"wires":[]},{"id":"8ee0516.3862cb","type":"function","z":"af61c022.bc96e","name":"","func":"var msg1  ={};\nvar msg2  ={};\nvar msg3  ={};\nvar msg4  ={};\nvar msg5  ={};\nvar msg6  ={};\nvar msg7  ={};\nvar msg8  ={};\nvar msg9  ={};\nvar msg10 ={};\nvar msg11 ={};\nvar msg12 ={};\nvar msg13 ={};\nvar msg14 ={};\nvar msg15 ={};\nvar msg16 ={};\nvar msg17 ={};\nvar msg18 ={};\n\n\n\nvar x1  = 0;\nvar x2  = 0;\nvar x3  = 0;\nvar x4  = 0;\nvar x5  = 0;\nvar x6  = 0;\nvar x7  = 0;\nvar x8  = 0;\nvar x9  = 0;\nvar x10 = 0;\nvar x11 = 0;\nvar x12 = 0;\nvar x13 = 0;\nvar x14 = 0;\nvar x15 = 0;\nvar x16 = 0;\nvar x17 = 0;\nvar x18 = 0;\n\n\nvar wert1name;\nvar wert2name;\nvar wert3name;\nvar wert4name;\nvar wert5name;\nvar wert6name;\nvar wert7name;\nvar wert8name;\nvar wert9name;\nvar wert10name;\nvar wert11name;\nvar wert12name;\nvar wert13name;\nvar wert14name;\nvar wert15name;\nvar wert16name;\nvar wert17name;\nvar wert18name;\n\n\nvar start = \"true\";\nvar turbo1 = \"False\";\n\nwert1name   = msg.payload.MQTTWert1name;\nwert2name   = msg.payload.MQTTWert2name;\nwert3name   = msg.payload.MQTTWert3name;\nwert4name   = msg.payload.MQTTWert4name;\nwert5name   = msg.payload.MQTTWert5name;\nwert6name   = msg.payload.MQTTWert6name;\nwert7name   = msg.payload.MQTTWert7name;\nwert8name   = msg.payload.MQTTWert8name;\nwert9name   = msg.payload.MQTTWert9name;\nwert10name = msg.payload.MQTTWert10name;\nwert11name = msg.payload.MQTTWert11name;\nwert12name = msg.payload.MQTTWert12name;\nwert13name = msg.payload.MQTTWert13name;\nwert14name = msg.payload.MQTTWert14name;\nwert15name = msg.payload.MQTTWert15name;\nwert16name = msg.payload.MQTTWert16name;\nwert17name = msg.payload.MQTTWert17name;\nwert18name = msg.payload.MQTTWert18name;\n\n\n\n\n//Allen Switch's Initialwerte zuweisen\nvar x1check  = \"initial\";\nvar x2check  = \"initial\";\nvar x3check  = \"initial\";\nvar x4check  = \"initial\";\nvar x5check  = \"initial\";\nvar x6check  = \"initial\";\nvar x7check  = \"initial\";\nvar x8check  = \"initial\";\nvar x9check  = \"initial\";\nvar x10check = \"initial\";\nvar x11check = \"initial\";\nvar x12check = \"initial\";\nvar x13check = \"initial\";\nvar x14check = \"initial\";\nvar x15check = \"initial\";\nvar x16check = \"initial\";\nvar x17check = \"initial\";\nvar x18check = \"initial\";\n\n\n//var x2  = msg.payload.MQTTWert2;\n//var vergleich = x1check.localeCompare(start);\n//Messwerte übergeben\n//--------------------------------------------\n//x1  = msg.payload.MQTTWert1;\n//var x2  = parseInt(String(msg.payload.MQTTWert2))\n//x2  = msg.payload.MQTTWert2;\n/*\nvar x3  = msg.payload.MQTTWert3;\nvar x4  = msg.payload.MQTTWert4;\nvar x5  = msg.payload.MQTTWert5;\nvar x6  = msg.payload.MQTTWert6;\nvar x7  = msg.payload.MQTTWert7;\nvar x8  = msg.payload.MQTTWert8;\nvar x9  = msg.payload.MQTTWert9;\nvar x10 = msg.payload.MQTTWert10;\nvar x11 = msg.payload.MQTTWert11;\nvar x12 = msg.payload.MQTTWert12;\nvar x13 = msg.payload.MQTTWert13;\nvar x14 = msg.payload.MQTTWert14;\nvar x15 = msg.payload.MQTTWert15;\nvar x16 = msg.payload.MQTTWert16;\nvar x17 = msg.payload.MQTTWert17;\nvar x18 = msg.payload.MQTTWert18;\n*/\n\n\n//Allen Switches Schalterwerte zuweisen\n//------------------------------------\nx1check  = msg.payload.Wertcheck1;\nx2check  = msg.payload.Wertcheck2;\nx3check  = msg.payload.Wertcheck3;\nx4check  = msg.payload.Wertcheck4;\nx5check  = msg.payload.Wertcheck5;\nx6check  = msg.payload.Wertcheck6;\nx7check  = msg.payload.Wertcheck7;\nx8check  = msg.payload.Wertcheck8;\nx9check  = msg.payload.Wertcheck9;\nx10check = msg.payload.Wertcheck10;\nx11check = msg.payload.Wertcheck11;\nx12check = msg.payload.Wertcheck12;\nx13check = msg.payload.Wertcheck13;\nx14check = msg.payload.Wertcheck14;\nx15check = msg.payload.Wertcheck15;\nx16check = msg.payload.Wertcheck16;\nx17check = msg.payload.Wertcheck17;\nx18check = msg.payload.Wertcheck18;\n//------------------------------------\n\n\n//Switch Abfrage\n//-----------------------------------\n\nif (x1check == \"true\"){\n    x1 = msg.payload.MQTTWert1\n    //turbo1 = \"True\"\n    msg1.topic = wert1name\n    msg1.payload = x1\n    //Den Namen mit reinnehmen\n}else{\n    x1 = 0\n    //turbo1 = \"False\"\n    msg1.topic = wert1name\n    msg1.topic = null\n    msg1.payload = x1\n}\n\n\nif (x2check == \"true\"){\n    x2 = msg.payload.MQTTWert2; \n    //x2 = 22;\n    //turbo1 = \"True\"\n  //  msg2._topic = \"ATESTEO/Wolfsburg/W16\"\n    msg2.topic = wert2name\n    msg2.payload = x2\n}else{\n    x2 = 0\n    //turbo1 = \"False\"\n    msg2.topic = wert2name\n    msg2.payload = x2\n}\n\nif (x3check == \"true\"){\n    x3 = msg.payload.MQTTWert3; \n    //x3 = 33;\n    //turbo1 = \"True\"\n    msg3.topic = wert3name\n    msg3.payload = x3\n}else{\n    x3 = 0\n    //turbo1 = \"False\"\n    //msg3.topic = wert3name\n    msg3.topic = null\n    msg3.payload = x3\n}\n\nif (x4check == \"true\"){\n    x4 = msg.payload.MQTTWert4\n    //turbo1 = \"True\"\n    msg4.topic = wert4name\n    msg4.payload = x4\n    //Den Namen mit reinnehmen\n}else{\n    x4 = 0\n    //turbo1 = \"False\"\n    //msg4.topic = wert4name\n    msg4.topic = null\n    msg4.payload = x4\n}\n\n// Testweise alle Daten auf msg.payload.MQTTWert3 gesetzt !!!!!!!!!!!!!!!!!!!!!!!!!!!\n\nif (x5check == \"true\"){\n    x5 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg5.topic = 'Line5'\n    msg5.payload = x5\n}else{\n    x5 = 0\n    //turbo1 = \"False\"\n    msg5.topic = 'Line5'\n    msg5.payload = x5\n}\n\n\n\nif (x6check == \"true\"){\n    x6 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg6.topic = 'Line6'\n    msg6.payload = x6\n}else{\n    x6 = 0\n    //turbo1 = \"False\"\n    msg6.topic = 'Line5'\n    msg6.payload = x6\n}\n\n\nif (x7check == \"true\"){\n    x7 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg7.topic = 'Line7'\n    msg7.payload = x\n}else{\n    x = 0\n    //turbo1 = \"False\"\n    msg7.topic = 'Line7'\n    msg7.payload = x7\n}\n\n\nif (x8check == \"true\"){\n    x8 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg8.topic = 'Line8'\n    msg8.payload = x8\n}else{\n    x8= 0\n    //turbo1 = \"False\"\n    msg8.topic = 'Line8'\n    msg8.payload = x8\n}\n\n\nif (x9check == \"true\"){\n    x9 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg9.topic = 'Line9'\n    msg9.payload = x9\n}else{\n    x9 = 0\n    //turbo1 = \"False\"\n    msg9.topic = 'Line9'\n    msg9.payload = x9\n}\n\n\nif (x10check == \"true\"){\n    x10 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg10.topic = 'Line10'\n    msg10.payload = x10\n}else{\n    x10 = 0\n    //turbo1 = \"False\"\n    msg10.topic = 'Line10'\n    msg10.payload = x10\n}\n\n\nif (x11check == \"true\"){\n    x11 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg11.topic = 'Line11'\n    msg11.payload = x11\n}else{\n    x11 = 0\n    //turbo1 = \"False\"\n    msg11.topic = 'Line11'\n    msg11.payload = x11\n}\n\n\nif (x12check == \"true\"){\n    x12 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg12.topic = 'Line12'\n    msg12.payload = x12\n}else{\n    x12 = 0\n    //turbo1 = \"False\"\n    msg12.topic = 'Line12'\n    msg12.payload = x12\n}\n\n\nif (x13check == \"true\"){\n    x13 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg13.topic = 'Line13'\n    msg13.payload = x13\n}else{\n    x13 = 0\n    //turbo1 = \"False\"\n    msg13.topic = 'Line13'\n    msg13.payload = x13\n}\n\n\nif (x14check == \"true\"){\n    x14 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg14.topic = 'Line14'\n    msg14.payload = x14\n}else{\n    x14 = 0\n    //turbo1 = \"False\"\n    msg14.topic = 'Line14'\n    msg14.payload = x14\n}\n\n\nif (x15check == \"true\"){\n    x15 = msg.payload.MQTTWert3 \n    //turbo1 = \"True\"\n    msg15.topic = 'Line15'\n    msg15.payload = x15\n}else{\n    x15 = 0\n    //turbo1 = \"False\"\n    msg15.topic = 'Line15'\n    msg15.payload = x15\n}\n\n\nif (x16check == \"true\"){\n    x16 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg16.topic = 'Line16'\n    msg16.payload = x16\n}else{\n    x16 = 0\n    //turbo1 = \"False\"\n    msg16.topic = 'Line16'\n    msg16.payload = x16\n}\n\n\nif (x17check == \"true\"){\n    x17 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg17.topic = 'Line17'\n    msg17.payload = x17\n}else{\n    x17 = 0\n    //turbo1 = \"False\"\n    msg17.topic = 'Line17'\n    msg17.payload = x17\n}\n\n\nif (x18check == \"true\"){\n    x18 = msg.payload.MQTTWert3\n    //turbo1 = \"True\"\n    msg18.topic = 'Line18'\n    msg18.payload = x18\n}else{\n    x18 = 0\n    //turbo1 = \"False\"\n    msg18.topic = 'Line18'\n    msg18.payload = x18\n}\n\n\n//Zum Säubern\n/*\n//msg.topic     = null\n//msg1.topic    = null\n//msg2.topic    = null\n//msg3.topic    = null\n//msg4.topic    = null\nmsg5.topic    = null\nmsg6.topic    = null\nmsg7.topic    = null\nmsg8.topic    = null\nmsg9.topic    = null\nmsg10.topic   = null\nmsg11.topic   = null\nmsg12.topic   = null\nmsg13.topic   = null\nmsg14.topic   = null\nmsg15.topic   = null\nmsg16.topic   = null\nmsg17.topic   = null\nmsg18.topic   = null\n\n//msg.payload  = \"0\"\n//msg1.payload = \"0\"\n//msg2.payload = \"0\"\n//msg3.payload = \"0\"\n//msg4.payload = \"0\"\nmsg5.payload = \"0\"\nmsg6.payload = \"0\"\nmsg7.payload = \"0\"\nmsg8.payload = \"0\"\nmsg9.payload  = \"0\"\nmsg10.payload = \"0\"\nmsg11.payload = \"0\"\nmsg12.payload = \"0\"\nmsg13.payload = \"0\"\nmsg14.payload = \"0\"\nmsg15.payload = \"0\"\nmsg16.payload = \"0\"\nmsg17.payload = \"0\"\nmsg18.payload = \"0\"\n*/\n\n/*\nIf (turbo1 == True){\n    msg1337.payload.turbo = 1\n}\n\nIf (turbo1 == False){\n    msg1337.payload.turbo = 0\n}\n*/\n/*\n  x1 = msg.payload.MQTTtemp1 \n    //turbo1 = \"True\"\n    msg1.topic = 'Line1'\n    msg1.payload = x1\n*/\n\n\n//Topics und Payload setzen\n//----------------------------------\n//msg2.topic = 'Line2'\n//msg2.payload = x2\n//msg3.topic = 'Line3'\n//msg3.payload = x3\n//msg4.topic = 'Line4'\n//msg4.payload = x4\n//msg5.topic = 'Line5'\n//msg5.payload = sliderwert;\n//----------------------------------\n\n\n//Ausgaben definieren\n//return [[msg],[msg1],[msg2]];\nreturn [msg1, msg2, msg3, msg4, msg5, msg6, msg7, msg8, msg9, msg10, msg11, msg12, msg13, msg14, msg15, msg16, msg17, msg18];","outputs":18,"noerr":0,"x":4370,"y":2670,"wires":[["8d8bbb3b.66fa58","1658fa2d.bb5476"],["4e1ba7d6.bc5c48","8d8bbb3b.66fa58"],["aa0840de.e64d5","8d8bbb3b.66fa58"],["880603f6.c4f7a","8d8bbb3b.66fa58"],["8707ba3b.632568","8d8bbb3b.66fa58"],["20016f77.d2e31","8d8bbb3b.66fa58"],["bc0bb02a.f437b","8d8bbb3b.66fa58"],["da27ab19.672cd8","8d8bbb3b.66fa58"],["35502e26.fcbc72","8d8bbb3b.66fa58"],["751c5f9d.aeed","8d8bbb3b.66fa58"],["d92eeb6e.790ef8","8d8bbb3b.66fa58"],["285a486e.828968","8d8bbb3b.66fa58"],["5d9c545a.b852dc","8d8bbb3b.66fa58"],["800f7cd8.4800a","8d8bbb3b.66fa58"],["3e630a.fed69cf6","8d8bbb3b.66fa58"],["175d4f88.f2de1","8d8bbb3b.66fa58"],["945196d9.2b2a88","8d8bbb3b.66fa58"],["bc4613ad.bd65c","8d8bbb3b.66fa58"]]},{"id":"e9b9dd78.e10f1","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"{{topic}}","tooltip":"","group":"22029319.b38d4c","order":1,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3650,"y":2370,"wires":[["fef7d669.96ce98"]]},{"id":"f00708fb.1f1058","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert2Switch","tooltip":"","group":"22029319.b38d4c","order":2,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2400,"wires":[["ca7da786.1bf968"]]},{"id":"e31b177f.2b1168","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert3Switch","tooltip":"","group":"22029319.b38d4c","order":3,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2430,"wires":[["2137750.930a48c"]]},{"id":"73b043d7.beb70c","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert4Switch","tooltip":"","group":"22029319.b38d4c","order":4,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2460,"wires":[["73a0446a.041d4c"]]},{"id":"d060c3f1.3048d","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert5Switch","tooltip":"","group":"22029319.b38d4c","order":5,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2490,"wires":[["dc3c05c7.97d898"]]},{"id":"fef7d669.96ce98","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck1","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2370,"wires":[["1de859ba.09be96"]]},{"id":"1de859ba.09be96","type":"join","z":"af61c022.bc96e","name":"","mode":"custom","build":"merged","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":true,"timeout":"","count":"2","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":4130,"y":2670,"wires":[["8ee0516.3862cb"]]},{"id":"beee5a1a.fcb688","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert6Switch","tooltip":"","group":"22029319.b38d4c","order":6,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2520,"wires":[["b1c77f3d.4ead4"]]},{"id":"1ed45b8d.aacf14","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert7Switch","tooltip":"","group":"22029319.b38d4c","order":7,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2550,"wires":[["2daaa3e0.4e7d8c"]]},{"id":"4d4f26d2.f254c8","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert8Switch","tooltip":"","group":"22029319.b38d4c","order":8,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2580,"wires":[["1ad6fc35.4abeb4"]]},{"id":"e53a296e.012a88","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert9Switch","tooltip":"","group":"22029319.b38d4c","order":9,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2610,"wires":[["fc9b15ae.8311a8"]]},{"id":"ca7da786.1bf968","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck2","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2400,"wires":[["1de859ba.09be96"]]},{"id":"2137750.930a48c","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck3","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2430,"wires":[["1de859ba.09be96"]]},{"id":"73a0446a.041d4c","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck4","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2460,"wires":[["1de859ba.09be96"]]},{"id":"dc3c05c7.97d898","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck5","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2490,"wires":[["1de859ba.09be96"]]},{"id":"b1c77f3d.4ead4","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck6","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2520,"wires":[["1de859ba.09be96"]]},{"id":"2daaa3e0.4e7d8c","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck7","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2550,"wires":[["1de859ba.09be96"]]},{"id":"1ad6fc35.4abeb4","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck8","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2580,"wires":[["1de859ba.09be96"]]},{"id":"fc9b15ae.8311a8","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck9","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2610,"wires":[["1de859ba.09be96"]]},{"id":"4e1ba7d6.bc5c48","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":11,"width":"3","height":"1","name":"","label":"Messwert 2","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2190,"wires":[]},{"id":"aa0840de.e64d5","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":12,"width":"3","height":"1","name":"","label":"Messwert 3","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2250,"wires":[]},{"id":"880603f6.c4f7a","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":13,"width":"3","height":"1","name":"","label":"Messwert 4","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2310,"wires":[]},{"id":"8707ba3b.632568","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":14,"width":"3","height":"1","name":"","label":"Messwert 5","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2370,"wires":[]},{"id":"20016f77.d2e31","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":15,"width":"3","height":"1","name":"","label":"Messwert 6","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2430,"wires":[]},{"id":"bc0bb02a.f437b","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":16,"width":"3","height":"1","name":"","label":"Messwert 7","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2490,"wires":[]},{"id":"da27ab19.672cd8","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":17,"width":"3","height":"1","name":"","label":"Messwert 8","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2550,"wires":[]},{"id":"35502e26.fcbc72","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":18,"width":"3","height":"1","name":"","label":"Messwert 9","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2610,"wires":[]},{"id":"751c5f9d.aeed","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":28,"width":"3","height":"1","name":"","label":"Messwert 10","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2700,"wires":[]},{"id":"15c5bdf5.d5e812","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert10Switch","tooltip":"","group":"22029319.b38d4c","order":19,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2730,"wires":[["2a2238dd.632f28"]]},{"id":"fb88c92f.079918","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert11Switch","tooltip":"","group":"22029319.b38d4c","order":20,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2760,"wires":[["8f091dc6.93382"]]},{"id":"56aa3062.d3dbe","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert12Switch","tooltip":"","group":"22029319.b38d4c","order":21,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2790,"wires":[["8a784e9.9587bb"]]},{"id":"f8cb15b8.173d78","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert13Switch","tooltip":"","group":"22029319.b38d4c","order":22,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2820,"wires":[["9e909a3e.03a658"]]},{"id":"5557ee6c.7c3f5","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert14Switch","tooltip":"","group":"22029319.b38d4c","order":23,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2850,"wires":[["2c2723aa.c7cb9c"]]},{"id":"38056462.c63f7c","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert15Switch","tooltip":"","group":"22029319.b38d4c","order":24,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2880,"wires":[["a2c8e482.f4f6c8"]]},{"id":"3fe0097c.5527a6","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert16Switch","tooltip":"","group":"22029319.b38d4c","order":25,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2910,"wires":[["eab19bc4.558d58"]]},{"id":"5a7f8cfe.0f3aa4","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert17Switch","tooltip":"","group":"22029319.b38d4c","order":26,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2940,"wires":[["8e0077b7.ec7708"]]},{"id":"d61c17ca.8c40d8","type":"ui_switch","z":"af61c022.bc96e","name":"","label":"Messwert18Switch","tooltip":"","group":"22029319.b38d4c","order":27,"width":"3","height":"1","passthru":true,"decouple":"false","topic":"ATESTEO/Wolfsburg/W16","style":"","onvalue":"true","onvalueType":"str","onicon":"","oncolor":"","offvalue":"false","offvalueType":"str","officon":"","offcolor":"","x":3690,"y":2970,"wires":[["c3526947.986b98"]]},{"id":"2a2238dd.632f28","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck10","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2730,"wires":[["1de859ba.09be96"]]},{"id":"8f091dc6.93382","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck11","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2760,"wires":[["1de859ba.09be96"]]},{"id":"8a784e9.9587bb","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck12","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2790,"wires":[["1de859ba.09be96"]]},{"id":"9e909a3e.03a658","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck13","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2820,"wires":[["1de859ba.09be96"]]},{"id":"2c2723aa.c7cb9c","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck14","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2850,"wires":[["1de859ba.09be96"]]},{"id":"a2c8e482.f4f6c8","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck15","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2880,"wires":[["1de859ba.09be96"]]},{"id":"eab19bc4.558d58","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck16","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2910,"wires":[["1de859ba.09be96"]]},{"id":"8e0077b7.ec7708","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck17","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2940,"wires":[["1de859ba.09be96"]]},{"id":"c3526947.986b98","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Wertcheck18","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2970,"wires":[["1de859ba.09be96"]]},{"id":"d92eeb6e.790ef8","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":29,"width":"3","height":"1","name":"","label":"Messwert 11","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2760,"wires":[]},{"id":"285a486e.828968","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":30,"width":"3","height":"1","name":"","label":"Messwert 12","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2820,"wires":[]},{"id":"5d9c545a.b852dc","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":31,"width":"3","height":"1","name":"","label":"Messwert 13","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2880,"wires":[]},{"id":"800f7cd8.4800a","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":32,"width":"3","height":"1","name":"","label":"Messwert 14","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":2940,"wires":[]},{"id":"3e630a.fed69cf6","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":33,"width":"3","height":"1","name":"","label":"Messwert 15","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":3000,"wires":[]},{"id":"175d4f88.f2de1","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":34,"width":"3","height":"1","name":"","label":"Messwert 16","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":3060,"wires":[]},{"id":"945196d9.2b2a88","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":35,"width":"3","height":"1","name":"","label":"Messwert 17","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":3120,"wires":[]},{"id":"bc4613ad.bd65c","type":"ui_text","z":"af61c022.bc96e","group":"22029319.b38d4c","order":36,"width":"3","height":"1","name":"","label":"Messwert 18","format":"{{msg.payload}}","layout":"row-spread","x":4900,"y":3180,"wires":[]},{"id":"41e05be2.d46e04","type":"ui_button","z":"af61c022.bc96e","name":"","group":"22029319.b38d4c","order":37,"width":"2","height":"1","passthru":false,"label":"Reset Button","tooltip":"","color":"","bgcolor":"","icon":"","payload":"True","payloadType":"str","topic":"ATESTEO/Wolfsburg/W16","x":3670,"y":2640,"wires":[["4d50d71e.a540e8"]]},{"id":"4d50d71e.a540e8","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"move","p":"payload","pt":"msg","to":"payload.Reset","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3940,"y":2640,"wires":[["1de859ba.09be96"]]},{"id":"22820868.e54128","type":"function","z":"af61c022.bc96e","name":"","func":"\nreturn msg;","outputs":1,"noerr":0,"x":3470,"y":2670,"wires":[["ff5e497e.748c38","1de859ba.09be96"]]},{"id":"ff5e497e.748c38","type":"change","z":"af61c022.bc96e","name":"","rules":[{"t":"set","p":"topic","pt":"msg","to":"payload.MQTTWert1name","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":3500,"y":2370,"wires":[["e9b9dd78.e10f1"]]},{"id":"aec4cb8b.d20ef8","type":"ui_group","z":"","name":"Livescreen","tab":"ec7a53af.4ac29","order":2,"disp":true,"width":"29","collapse":false},{"id":"22029319.b38d4c","type":"ui_group","z":"","name":"Messwerte auswählen","tab":"ec7a53af.4ac29","order":1,"disp":true,"width":"29","collapse":false},{"id":"ec7a53af.4ac29","type":"ui_tab","z":"","name":"W16-Chart","icon":"dashboard","order":11,"disabled":false,"hidden":false}]

May be i need some hints for better Performance later :slight_smile:

The Input of the flow:
chartinput

Greetings
Chorum

I didn't mean the post to be judgemental of you. We all start with no knowledge.

I was merely stating what I see/saw.

The msg.payload is deleted in the first node.

Then in the third node it is moved to the other named thing..... payload.Wertcheck1

If it was deleted, you won't see anything on the chart.

(Ok, scratch that. Seems you have shown the data)

Also, suggestion, add some debug nodes to the flow.
When you add them, double click and tick the show entire message (or what ever it is called) button then you will see the message going along.

Oh, also name the debug nodes or you will go crazy trying to see what is where.

So as an example name the first debug node in the sequence 1 then the next one 2 and so on.

It will greatly help you.

But do you understand what I mean with the msg.payload part?

Check the chart node and make sure at which part of the msg it is looking for data.

i couldnt post the flow with my debug notes :slight_smile: it was too big sorry
taking out the payload deleting didnt help

It isn't quite as simple as deleting the delete msg.payload.

You are moving the msg.payload to ..... msg.payload.Wertcheck1 at the end.

Again: If the chart is looking at msg.payload and you are sending it in the other one, it still won't work.
For the sake of it, delete (or wire around) the last change node.

I've just looked at the second part you posted.

Again I shall stress: Make sure the data you are sending to the chart is correct.

It would seem you are sending it the modified msg.payload.Wertcheck1 when - looking at the chart node - it is looking for the data to be in msg.payload which is blank/empty.

But after that i cannot join the switch value with my original payload with the join node…

"Cannot merge non-object-types"

The flow works fine but the renaming of the switch labels Troubles me...

Hang on....

I'm looking at the bigger picture.

Ok, thoughts:

Set up the debug node as shown.

Then connect up the debug node here like the chart node.

Now indulge me:

You are wanting to set the names of the switches (the GUI ones) to what is the msg.topic - correct?

The flow you posted (the bigger one):

The part shown in red....

That is an example and you want to do it with all the switches?
Just as this will be a fixed message, I don't understand why you don't edit the switch nodes and set their names manually. As there is no way this can vary as you are specifying in the change node that is setting the topic to a fixed value.

Sorry, just asking.

So here is the payload after the join node with payload deleting in the first Change node:

payload after join with payloaddeleting

And here without payload deleting:

payload after join without payloaddeleting

Nothing changed...

I think i have to reduce the values for the Chart. with 18 values i have 70% CPU usage without a line in the Chart :frowning:

Yeah, well, maybe.

For the sake of trying, just delete some of the connections from the function node to the chart.

Oh, when posting the debug output, click as shown.....

Then, here click the </> button at the top and paste the output.
This makes it easier for people to look at the output and understanding it.

  1. i set up the debug node ut i cant give it you like you wanted:

chart data

So here are some of the 18 payloads. As i wanted i get 18 msg's for 18 lines.
the payload should be "0" but with my rename test (yep the red part) i get a payload .

yes i would like to dynamicly Change the switch names in the Dashboard. because there will be 20 Charts and in every Chart the values can Change in month or weeks.

Mhmm i have to check out the one msg with empty Topic....dont know where it came from…
Ahh found it, now every message got its Topic...

That's good to hear.

So just to check: Is it now working?

Going a bit off topic: What is the use of the function node? To set initial values?

I am only thinking: Maybe there is another way to do what you are doing.

Another thought: Put 18 debug nodes - rather than the one I showed you - as it would be easier to see what is happening and from whom. Name each of the debug nodes 1 to 18 and set them to show the entire message body.

You can then turn them all off.... Turn one on at a time and make sure the messages are correctly formatted with the topic etc.

With the naming of the switches, the change node before the switch should only need to set the topic to the name you want for the switch.

Back to what you said about the names changing from week to week or month to month:
That will still need you to edit the change node.

Also looking at the switch (GUI) node:
the label field:

The way you are doing it seems different to how it is described in the documentation:

(extract)

The label can also be set by a message property by setting the field to the name of the property, for example {{msg.topic}}.

So why don't you have {{msg.topic}} in that field?

Nope , i only fixed some msg's with no Topic :frowning:

the Problem stays.

Sorry, see edited post.

Oh, ok. I see that one (the first) one has {{topic}} in the label filed.

But I am not sure it should be {{topic}} or {{msg.topic}}. Sorry you need to check that.

Just to get things a bit better under control, how about you make the flow look like this:

That is the initial function node, the change node, the switch node, the second change node, the join node and the chart node.

Add the debug node and have it set to show the entire message.

If it does, paste the debug node and we can work from there.

By the way: What is the link for that I crossed out? If you send the message up via the other path, it doesn't make sense that the other one is also there.

(That could be causing problems too.)

Yeap the spaces were filled with debug nodes :slight_smile:
i couldnt post them, because it was to big…

the function node brings the if condition for the switches, Setting the line names, and at the end i want to send a value to the payload Sender with that function node

in my solution i dont Need to Change anything in node red if the valuename changes.
the Name Comes with the payload and is set as Topic in the Change node.

so far so good. my Problem is that this solution activates the payload for that switch somehow.

for {{msg.topic}} - it worked with Topic and msg.topic the same way

Sorry. I don't understand.

But reading it more, I think that other line I showed crossed out may be causing problems.

The switch node is used to turn on/off the data passing. So having that second link would over-ride the switch's function/operation.

The Bypass for the Change node before the switch Wanst there bevor the switch node.
so the crossed line was the main "payload Pipeline"

Because i Change the Topic in the Change node i cannot use this way for my values as payload….

Sorry, I am still not understanding that.

I am guessing that payloads (all) would go through something like that extra part you showed to name the switch node.

So therefore: All messages need to have this structure to name their switches. Or am I missing something?

Sorry. I am asking to try and get a picture in my mind of what you are wanting to do.
I don't really want to use the flow, as I don't know what to inject into it to get results.

But the way it is (the bigger one) structured, I really can't see how it will/can work.
As I said, unless you expand what you did for the first (top) one to all.