Node-red-contrib-dashboard-sum-bars & Average-bars- Input payload


#1

Hello all

I would appreciate an example of the input message payload for this nodes

node-red-contrib-dashboard-sum-bars
node-red-contrib-dashboard-average-bars

Thank You
JLG


#2

Maybe best to contact the author direct via an issue on his github page as I'm not sure they are a regular here..


#3

Hi Jose,

Here below an example flow using node-red-contrib-dashboard-sum-bars
It will gradually populate the chart.

[{"id":"c979d154.d1f55","type":"tab","label":"average-bars example","disabled":false,"info":""},{"id":"c85336b7.c96a58","type":"average-bars","z":"c979d154.d1f55","name":"average-bars","title":"","period":"hour","yMin":"auto","yMax":"auto","showBarsValue":true,"showScaleValue":true,"showLastValue":true,"showAverageValue":true,"showMinimumValue":true,"showMaximumValue":true,"maxBar":30,"topColor":"#ff0000","bottomColor":"#ffff00","unit":"","fontColor":"#aaaaaa","barStyle":"Rectangle","decimal":1,"x":740.5,"y":74,"wires":[["7b2bbbf8.f70004"]]},{"id":"7b2bbbf8.f70004","type":"ui_template","z":"c979d154.d1f55","group":"d4a26f5b.429be","name":"","order":0,"width":"21","height":"5","format":"<div ng-bind-html=\"msg.payload\"></div>","storeOutMessages":true,"fwdInMessages":true,"templateScope":"local","x":923,"y":73,"wires":[[]]},{"id":"b54708f3.8d3188","type":"random","z":"c979d154.d1f55","name":"","low":"1","high":"10","inte":"false","property":"payload","x":542.5,"y":76,"wires":[["c85336b7.c96a58","2d670b94.499564"]]},{"id":"667dade6.9bac44","type":"inject","z":"c979d154.d1f55","name":"trigger every 20 seconds","topic":"","payload":"","payloadType":"date","repeat":"20","crontab":"","once":false,"onceDelay":0.1,"x":311,"y":76,"wires":[["b54708f3.8d3188"]]},{"id":"2d670b94.499564","type":"debug","z":"c979d154.d1f55","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","x":760,"y":26,"wires":[]},{"id":"d4a26f5b.429be","type":"ui_group","z":"","name":"Default","tab":"a452820.76da38","disp":true,"width":"21","collapse":false},{"id":"a452820.76da38","type":"ui_tab","z":"","name":"Home","icon":"dashboard"}]

#4

Hello Jandva

Can we feed an array to this node? and if so what is the configuration of it ?

Thank you

JLG


#5

Hi Jose,

I am only a user of that node. I don't think it is possible to feed an array to this node.
At least it is not documented (https://github.com/nazcasun/node-red-contrib-dashboard-sum-bars)

kr
Jan