Pass segment values to DB2 chart widget

Import this and see what it gives in the page 'Test page' before and after clicking the inject.

What are you trying to enter the colour for? Post a screenshot showing where you are clicking.

[Edit]: Attached flow

[{"id":"711f15ecfcfecc05","type":"inject","z":"997da33a0beedade","name":"Go","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"str","x":170,"y":4900,"wires":[["5b4e9c9212bba6db"]]},{"id":"5b4e9c9212bba6db","type":"function","z":"997da33a0beedade","name":"ui_update","func":"msg = {\n    \"topic\":\"RAD/334/+13.8A\",\n    \"meter\":4,\n    \"payload\":13.49,\n    \"ui_update\":{\n        \"valueDecimalPlaces\":1,\n        \"min\":0,\n        \"max\":17,\n        \"sectors\": [{\"start\":10.5,\"color\":\"yellow\"},{\"start\":15,\"color\":\"red\"}]\n    }\n}\nreturn msg;","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":340,"y":4900,"wires":[["da51e43eb103f939","07eaa9bddebe289d"]]},{"id":"da51e43eb103f939","type":"debug","z":"997da33a0beedade","name":"debug 28","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":510,"y":4840,"wires":[]},{"id":"07eaa9bddebe289d","type":"ui-gauge-classic","z":"997da33a0beedade","name":"Sectors test gauge","group":"4f87bd59a15b847e","order":1,"width":0,"height":0,"min":0,"max":10,"sectors":[{"start":"0","color":"blue"},{"start":"5","color":"pink"}],"major_division":1,"minor_division":0.2,"value_decimal_places":"2","scale_decimal_places":0,"label":"","measurement":"temperature","units":"°C","needles":[{"topic":"","color":"black","lengthPercent":"100"}],"hubcolor":"black","sweep_angle":250,"keepwidth":true,"myclass":"","x":550,"y":4900,"wires":[]},{"id":"4f87bd59a15b847e","type":"ui-group","name":"test","page":"c6ff182a4185f2f2","width":"6","height":"1","order":1,"showTitle":true,"className":"","visible":"true","disabled":"false","groupType":"default"},{"id":"c6ff182a4185f2f2","type":"ui-page","name":"Test page","ui":"ID-BASE-1","path":"/testpage","icon":"home","layout":"grid","theme":"33622591401a2c6e","breakpoints":[{"name":"Default","px":"0","cols":"3"},{"name":"Tablet","px":"576","cols":"6"},{"name":"Small Desktop","px":"768","cols":"9"},{"name":"Desktop","px":"1024","cols":"12"}],"order":2,"className":"","visible":true,"disabled":false},{"id":"ID-BASE-1","type":"ui-base","name":"Dashboard","path":"/dashboard","appIcon":"","includeClientData":true,"acceptsClientConfig":["ui-control","ui-notification","ui-gauge-classic"],"showPathInSidebar":false,"headerContent":"page","titleBarStyle":"default","showReconnectNotification":false,"notificationDisplayTime":"1","showDisconnectNotification":true,"allowInstall":true},{"id":"33622591401a2c6e","type":"ui-theme","name":"Compact","colors":{"surface":"#ffffff","primary":"#0094ce","bgPage":"#eeeeee","groupBg":"#ffffff","groupOutline":"#cccccc"},"sizes":{"density":"default","pagePadding":"12px","groupGap":"12px","groupBorderRadius":"4px","widgetGap":"0px"}},{"id":"67f20132633f19a2","type":"global-config","env":[],"modules":{"@colinl/node-red-dashboard-2-ui-gauge-classic":"1.4.0","@flowfuse/node-red-dashboard":"1.26.0"}}]

Here is a screenshot of a different gauge where I’d like to enter the colors by name vs RGB value.

Imported your test flow… except for the visual difference in the gauge (3/4 vs half), worked perfectly

@Colin … I owe you a big apology… after looking at your test gauge and comparing it to my flow (which was not the one I thought I was using), the gauge I’m having problems with is NOT your classic gauge. I believe I’m using the gauge which comes with DB2. I’m very sorry for wasting your time.

So is everything working ok now that you are looking at the right docs? :slight_smile:

Yeppers :blush: