I have some awnings on my house, that I am controlling via a shelly 2pm, so one switch is extend, the other is retract.
Full extension or retraction takes 28 seconds, and I currently have automations that will extend half way (14s extend), or the whole way (28s extend), or retract (28s retract). I have these exposed to Alexa so that I can say “extend rear awning” etc.
I’d like I way for HASS to store a value for how many seconds it has currently extended/retracted, to know the position, which I think I can do with HACS extensions (storing a value in a variable), but ideally I’d like to (as I can with my lights) be able to say “set rear awning to 30%” and have it translate that to 28x0.3s runtime, assuming it’s currently fully retracted, or say, 28x0.1s runtime if it’s variable currently tells it that it’s at 20%.
Is this something that is possible?