Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Simply making you aware of the extension i made, may be it can be of use. If not ignore my pr.
Nice and clear code btw :)
I needed a slider support. (as some others also requested i think)
I included a command topic "set_position_topic" as documented here https://www.home-assistant.io/integrations/cover.mqtt/
the topic is only "activated" for HACover::PositionFeature
I introduced a new callback to get the slider values back.
Borrowed from your HANumber implementation. You might want to check that part.
I have not checked if this value also needs to/ can be feed back to HA, yet (Like you do with the number slider, because i think cover gets that information from the "position_topic") I'm just happy that it works!
I have not written any test cases to verify my code, yet. May be i do.