I'm starting my next electronics project which is to create my own version of Google's Nest Thermostat. I like the whole circular dial for temperature selection and I've been having a think about how to create this myself. GUI programming is not my area of expertise (CLI all the way!).
So far I'm think along one of two lines, both involving custom widgets:
- Create a widget that inherits from the pushbutton class. This subclass will contain lots of buttons, one for each step in the temperature scale, arranged in a 3/4 circle.
- Create a widget that inherits from the slider class, defining an object that is curved around 3/4 of a circle. Each step is a temperature.
Now... I have no idea if these are practical solutions to this problem or if there is a much easier way of doing this. I've had a look at the style sheets and I don't THINK that is going to do it. I've had a root around Google for anything similar and not found anything yet; that said, AnalogWidgets from 3electrons at least creates dials, but these are for output rather than input.
I tried this out yesterday and it works rather nicely if you want to simulate the nest thermostat in an app this includes the js and SVG image: https://www.svidget.io/examples/nestthermostat
HTML snippet: