Convert int to hex color

Hi,

In my flow I recall the value from a sensor and it can be between 0 and 1000.

I want to change the int to a hex color, where 0 will be blue, 500 green and 1000 red.

This will be use in World map to change the icon color from blue all the way to red relative the the sensor value.

Do you have an suggestions?

Thanks

Thanks that is brilliant.

Only question what nodes are these? image

You don't need them really, they were for demonstration only. But if you do, then look in the palette for node-red-contrib-image-tools.

Thanks, I saw they were only for the demo, just could not recall what they were, used them long time ago.

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