Page 2 of 2

Re: Add Temp Gauge As A Widget In HMI Builder

Posted: Wed Oct 19, 2011 11:50 am
by Baron Ken
Thanks to a tip from ECC, I added setpoint indicator colors! :D

Actual temp > ±5 degrees from setpoint the color is red
Actual temp <= ±5 and >±2 degrees from setpoint the color is yellow
Actual temp <= ±2 degrees from setpoint the color is green
These values can be changed in the external.js if desired.

Image

Re: Add Temp Gauge As A Widget In HMI Builder

Posted: Sun Oct 23, 2011 7:51 pm
by clearwaterbrewer
how about buttons to raise and lower setpoint?

Re: Add Temp Gauge As A Widget In HMI Builder

Posted: Thu Nov 12, 2015 9:17 am
by Baron Ken
It's been 4 years since I worked on this stuff (and since I brewed!). Digging out my brewing gear, including BCS.

I updated some image links in this thread. They are pre-4.0 stuff.

I have to dig back into the code to figure out how to make changes to 4.0. It used to be as simple as adding or overloading functions in the external.js file. It doesn't appear to be so easy to overload anymore. :lol:

Re: Add Temp Gauge As A Widget In HMI Builder

Posted: Thu Nov 12, 2015 10:13 am
by JonW
Please keep this updated with your progress. Examples like this are very helpful for people looking to enhance their displays.

Re: Add Temp Gauge As A Widget In HMI Builder

Posted: Fri Nov 13, 2015 7:55 pm
by Baron Ken
Ok, it took me a couple of days to get up to speed. :)

I figured out how to make changes now, so I've added the bezel setpoint indicators (and removed the setpoint needle):
Image
Note that for the picture, I hardcoded the temp values at 152F so they wouldn't all show 0 and I could show the color changes as the temp nears the setpoint (or for the example, the setpoint nears the temp :lol: ).
Note also that I changed the lower end temp to 60F since I would rarely be below that for brewing (if you have fermenters set up, you probably want the original value (20F)).

Variables allow for the degrees off from setpoint before a color change happens.
In the example:
temp within +/- 2 ºF from the setpoint and the setpoint indicator and the temp reading are in green
temp within +/- 5 ºF from the setpoint and the setpoint indicator and the temp reading are in orange (yellow was too hard to see)
temp > +/- 5 ºF from the setpoint and the setpoint indicator and the temp reading are in red

Variables allow for different colors:

Code: Select all

var greencolor      = "green"    
var orangecolor     = "chocolate"
var redcolor        = "red"      
var greencolortext  = "green"    
var orangecolortext = "chocolate"
var redcolortext    = "red"
You can set the *color colors to all the same if you don't want changing colors.
You can set *colortext colors to "black" is you don't want the temp reading to change colors.

Note that if there is no setpoint, the temp text is black.
If setpoint is out of range of the gauge, the setpoint text value is in red (I didn't get a pic of this condition).

Also, if the temp value is out of the range of the gauge, the temp needle turns red:
Image
In the example above, the Mash Probe and Kettle Probe have setpoints (and since the temp is not near the setpoint, the color is red).
For the Test Probe, there is no setpoint, so the color is black.
For all 3, the temp is out of range, so the temp needle is red.

Thanks for looking. Comments are welcome.