Shelly integration add duration, last_direction and current_pos for roller entity

I’m using the Shelly relays to control my rollers and it would be quite nice to be able to add 3 missing attributes: duration, last_direction and current_pos for roller.

  1. duration will be extremely useful to be able to tilt the blades of the big rollers. Right now only position is available, and the minimum 1% is too big to tilt the blades up or down. The most accurate approach will be to use time, since you can use fractions.
  2. last_direction will allow to know wether to tilt up or down, once the roller has moved to a desired position.
  3. current_pos will allow to calculate how much to move a roller to get the desired position based on the current position (if not using time).

Thank you very much.