-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Delta values for setting bulb brightness / hue / saturation. #1348
Comments
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Could we keep this open please? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Please don't close |
@uncle-fed maybe you can follow this tutorial? https://www.zigbee2mqtt.io/how_tos/how_to_support_new_devices.html |
@rsalunga29: that tutorial has nothing to do with the topic discussed here. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Bump. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Megabump. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Uberbump |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Should be fixed now, since it's not valid JSON this message is not processed anymore and an error will be logged
should also be fixed in the latest dev branch in a few hours from now. |
More testing here.. I know that there is a different issue opened about this, and that issues looks kinda fixed, but there is still some mess with the 0 and 1 values. Assuming my understanding is correct that at least for Hue lights (or any Zigbee lights?) brightness = 1, it is the same as brightness = 0 or brightness = null, that is lights turns OFF. So with this in mind, consider the following examples:
OK this was about ordinary
|
Unfortunately not, Hue/Inrr lights indeed seem to turn off, but e.g. TRADFRI stays on. For Zigbee2MQTT, brightness 0 == OFF, anything else is ON. Fixed the issues you mentioned. About:
Now an error will be logged when the value >= 256, or < 0: Changes will be available in the latest dev branch in a few hours (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html) |
Slowly getting there.. :-) But not quite.. publish Also, still did not fully get what is z2m's concept regarding Hue lights and brightness And it wouldn't be such a major thing and one could make a disclaimer that people should avoid using "ambiguous" value of Here is an example that demonstrates why the concept "is very strange" currently, to say the least: publish So basically, to sum it up,
One other thing, maybe my eyes deceive me, but I've checked it multiple times and with my particular Hue bulb here it looks like when I use "brightness_move" with negative value, the bulb slowly fades to minimum brightness but does not stop and goes a tiny bit brighter again before it stops changing brightness level. This was when I used -50 as a value. P.S. It looks like the commit 3c3ed3c did not pass some checks and has a cross near it. Does it mean that I was testing the code that you did not intend to be tested? ;-) |
This should be fixed now.
We don't treat all lights equally, specific code is enabled by setting Koenkk/zigbee-herdsman-converters@3c3ed3c#diff-6c9a6acf22f90d1c6e524d9f3c5c1745R2039. However I accidentally reverted everything in Koenkk/zigbee-herdsman-converters@2a8513b which may be the reason why you are not seeing any changes. With this we try to provide the same behaviour for all bulbs, brightness 0 is off, anything else is on. It would be annoying if this wasn't the case, I feel Zigbee2MQTT is the layer that should abstract this. For bulbs having However, I noticed some inconsistency in the bulb itself, brightness 1 is not always off! E.g.: Set brightness 2, brightness_step -1, get brightness -> bulb returns brightness 1 and it is still ON. Changes will be available in the latest dev branch in a few hours (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html) |
Thanks for the explanations and fixes, so far looks good, I've tested around and can see that brightness = 1 does not cause lights being OFF anymore. Perhaps one more irregular behaviour (assume light is at full brightness at the start of each command):
|
@uncle-fed you are very good at finding bugs :) fixed it! Changes will be available in the latest dev branch in a few hours (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html) |
Thanks very much. I think I am now ready for more testing of |
…_move` and `hue_move`. Koenkk/zigbee2mqtt#1348
…nd `hue_move` docs. Koenkk/zigbee2mqtt#1348
I've added the following commands: Docs (I've unified it a bit): https://github.com/Koenkk/zigbee2mqtt.io/blob/develop/docs/information/mqtt_topics_and_message_structure.md Changes will be available in the latest dev branch in a few hours (https://www.zigbee2mqtt.io/how_tos/how-to-switch-to-dev-branch.html) |
Something strange... I can use |
Might just not be hooked up yet, I had to do some extra work to get them working for Innr bulbs which are nearly feature compatible with Hue. |
but... I thought simple |
@uncle-fed |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days |
Was unable to test due to lack of time but will resume shortly. |
Where did you document these commands? does something fun :). Would be great if this would be exposed more for others to read and know as well |
It's documented here: https://www.zigbee2mqtt.io/devices/7146060PH.html#movingstepping |
While trying to abandon Philips Hue bridge in favour of pure zigbee2mqtt based solution, found an important feature missing.
Philips Hue API supports setting several light's parameters via a relative / delta value as per the following documentation (account/login required): https://developers.meethue.com/develop/hue-api/lights-api/#set-light-state
It would be great to be able to control bulbs in a similar way with zigbee2mqtt.
Not sure if this is easily possible, if the devices do not support delta values directly (you'd then need to know current value, which might lead to a whole new set of possible issues).
The text was updated successfully, but these errors were encountered: