I have two simple gauges that I have set side by side. The left side is meant to show data from -6 to 0 in a dark green, and the other side is meant to show data from 0 to 14 in a bright green. When setting this up, I wasn't able to get negative numbers to work with the simple gauge, so I flipped that half of the component across its y axis and set the numbers from 0 to 6 so that it would fill correctly from right to left.
My problem now is that the gauges are filling uniformly in each direction because they are both reading positive numbers. I need the left side to show the negative data being read from our devices. I'm sure the way to do this is something related to a script binding, but I'm not familiar with code to figure out the mental puzzle to make this do what I need. Any suggestions on how to begin?
I attempted to do that when I first set up the gauges, but the component wouldn't accept a min or max value in the negative range. My path to that solution is here:
I'm not quite sure how to make a value change transformation work, because this data is being fed in live from a device that outputs from -6 to 14. The right side of my gauge correctly reads and displays the positive values like I want. Then I essentially need the left side to ignore any positive values coming in, read the negative values, then translate those into a "reverse" (ie -3 becomes 3) so that they can be displayed by the fill on the gauge.
One needs the min() of value and zero, the other needs the max() of value and zero. (Don't add the kW suffix to the numbers--do that only in the label.)