Get all values from dashboard elements at once

Hello every one, i am new to node-red, i am trying to get a msg.payload with all dashboard elements values. In particular i have four sliders, once i set one of them to some value i would like to print in debug all four sliders values. My flow :

[{"id":"f192ad43.71313","type":"tab","label":"Flow 1","disabled":false,"info":""},{"id":"51f126d1.9b4d88","type":"ui_slider","z":"f192ad43.71313","name":"","label":"Fan North Upper","tooltip":"","group":"91c81e9d.3aea8","order":2,"width":"0","height":"0","passthru":true,"outs":"end","topic":"gid_1_fnu","min":0,"max":"100","step":"10","x":150,"y":60,"wires":[[]]},{"id":"830eec47.5760f","type":"ui_slider","z":"f192ad43.71313","name":"","label":"Fan North Lower","tooltip":"","group":"91c81e9d.3aea8","order":3,"width":0,"height":0,"passthru":false,"outs":"end","topic":"gid_1_fnl","min":0,"max":"100","step":"10","x":150,"y":100,"wires":[[]]},{"id":"818164a7.7c0d68","type":"ui_slider","z":"f192ad43.71313","name":"","label":"Fan South Upper","tooltip":"","group":"91c81e9d.3aea8","order":4,"width":0,"height":0,"passthru":false,"outs":"end","topic":"{gid:1}","min":0,"max":"100","step":"10","x":150,"y":140,"wires":[[]]},{"id":"34c0f46d.6a3adc","type":"ui_slider","z":"f192ad43.71313","name":"","label":"Fan South Lower","tooltip":"","group":"91c81e9d.3aea8","order":5,"width":0,"height":0,"passthru":false,"outs":"end","topic":"{gid:1}","min":0,"max":"100","step":"10","x":150,"y":180,"wires":[[]]},{"id":"91c81e9d.3aea8","type":"ui_group","z":"","name":"Gamlon 1","tab":"faac9adb.2b2198","order":1,"disp":true,"width":"8","collapse":false},{"id":"faac9adb.2b2198","type":"ui_tab","z":"","name":"Power Control","icon":"dashboard","disabled":false,"hidden":false}]

Thanks very much for help.

Not checked your flow but Dashboard doesn't really work that way. Each element is separate.

So the way to do this is to save each output in a variable and then whenever any of them change, grab all of the variables and process accordingly.

I understand, thank you very much.

The join node set into manual mode - to create key/value object - and send after 4 messages and then every subsequent message. Each slider needs to be set to a different topic.

Yes, but "join" node waits for all connected nodes to inject. (i tried it), thanks.

no it doesn't - can set to send after just one if you want.

Oh really? how should i configure it?

Thanks, i tried it, it works partially, i still need to slid each one to get a complete payload of four of them - once its done, each time i move one i get the history of previously slid sliders.

I think that is just interpretation. When you move one you get plus the values of the other 3. They haven’t moved so they will be old values until you change them. Not sure what else you could expect.

If you use an inject node or nodes to send initial values for all the sliders into the Join node (and into the sliders if necessary) then you won't need to move all the sliders before getting the first message out.

Thanks for the reply, unfortunately using inject nodes here isn't an option.

Why not? It is only for initialisation. Set them to inject once on startup with whatever initial setting you want for each slider.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.