I use a Shelly 2 PM gen4 for handling of an awning.
There are some problems with the dashboard. It is not possible, to start the other direction (opening/closing) until the endposition is reached, even if I had stopped it.
My code is:
I guess, that the problem depends on the parameter "supported_features", but I'm not entirely sure.
What means "supported_features: 11", which possible values exists for this parameter and where can I modify this?
A link to the documentation dosn't help me, because it misses the numerical values for the bitmask and the entities are only generated by the Shelly-Plugin.
But that is not the main-problem, I'm looking for, it was only a suggestion.
The main-problem is the handling insite the dashboard, where it ist not possible to switch the direction until the endposition of the last action is reached even if it is stopped. The assigned symbol for the other direction is deactivated until the endposition is reached and visa versa.
In web-interface I see all symbols/buttons all the time, but that is not the interface I want to use. I want an integration in my homeassistant-dashboards.
Not a direct answer to your question about the desktop integration, but the Supported Features number is a bitwise OR operation over the list of possible features as given in the Cover entity documentation, as linked to by Bieniu. And this page links to the source code on GitHub, where the supported features are defined:
class CoverEntityFeature(IntFlag):
"""Supported features of the cover entity."""
OPEN = 1
CLOSE = 2
SET_POSITION = 4
STOP = 8
OPEN_TILT = 16
CLOSE_TILT = 32
STOP_TILT = 64
SET_TILT_POSITION = 128
So there are eight supported features given, which in binary format would be 00000000 when none of the features would be valid, which is 0 decimal in that case.
In your case the supported features number is 11 decimal, which is 00001011 in binary.
So in your case the first, second and fourth features are valid, which is OPEN (1), CLOSE (2) and STOP (8).
By the way: it looks like there is a mistake in the Cover documentation: the 7th and 8th feature (SET_TILT_POSITION and STOP_TILT) appear to be swapped around in the table.
Thanks for explaining the decimal values of supported_features.
I understand, that this is not the reason for my problem. With the value of 11 I should have all features I want to use.
So there must be another reason for the bad handling insite the dashboard, that I described above (changing direction before endposition is reached).