Skip to content
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

[avmfritz] Fritz DECT 500 lightbulb - not possible to change from color to white mode #14287

Closed
outerSpaceToast opened this issue Jan 28, 2023 · 9 comments · Fixed by #14373
Closed

Comments

@outerSpaceToast
Copy link

outerSpaceToast commented Jan 28, 2023

It seems that with the current version of openHAB 3.5 changing color is working now, BUT obviously it is not possible to change back to white mode, after once having set a color option.
Did I miss something?

Expected Behavior

There is an option to chose white mode (or even better to chose the color temperature) on a Fritz DECT 500 light bulb (created as HAN_FUN_COLOR_BULB).
There should be a separate channel for the brightness.

Current Behavior

As soon as you select a certain color value, the bulb switches to color mode, no more change to white mode possible via openHAB.
Brightness can only be changed, when another manual Dimmer item is linked to the color chaannel.

Possible Solution

I've tested this changeset from @sommer and @vich-667, which implements a temperature color channel. It is working fine:
https://github.com/vich-667/openhab-addons/pull/1/files
Discussion here: #12427
What is missing to bring this change into the main development branch?
Can I support somehow?

Steps to Reproduce (for Bugs)

  1. Add bulb as avmfritz:HAN_FUN_COLOR_BULB
  2. Connect Color item to its color channel
  3. Select a color

Your Environment

openHAB 3.4.0

Best regards,
Thomas.

@lolodomo lolodomo changed the title Fritz DECT 500 lightbulb - not possible to change from color to white mode nor to change brightness [avmfritz) Fritz DECT 500 lightbulb - not possible to change from color to white mode nor to change brightness Jan 28, 2023
@lolodomo lolodomo changed the title [avmfritz) Fritz DECT 500 lightbulb - not possible to change from color to white mode nor to change brightness [avmfritz] Fritz DECT 500 lightbulb - not possible to change from color to white mode nor to change brightness Jan 28, 2023
@outerSpaceToast outerSpaceToast changed the title [avmfritz] Fritz DECT 500 lightbulb - not possible to change from color to white mode nor to change brightness [avmfritz] Fritz DECT 500 lightbulb - not possible to change from color to white mode Feb 7, 2023
@vich-667
Copy link
Contributor

vich-667 commented Feb 7, 2023

Hi @outerSpaceToast!

Thanks four interest on that light blub. I saw that you already mentioned that problem in the old issue! I'm also not happy with the behavior of that Light Blub Thing, but when I had some of my very limited time to play with openhab I had was busy with other things. Yesterday I re setup the dev enviroment, so I hope I can give that old PR a more detailed look and finalize it.

I remember there still was some problem with swiching the light blub totally off. Did it work to you?

I hope my very limited java knowlage is enought to get it working.

KR Vich

@outerSpaceToast
Copy link
Author

Yesterday I re setup the dev enviroment, so I hope I can give that old PR a more detailed look and finalize it.

That would be geat :-)

I remember there still was some problem with swiching the light blub totally off. Did it work to you?

The behaviour is not intuitive, but it works, when you create separate items for the switch, the brightness and the color, which are linked to the color channel.
I think it would be more intuitive, if there were separate channels for that. However, if you know how to do it, then it works well as it is.

I hope my very limited java knowlage is enought to get it working.

Same situation here, only working with plain C at work.
However, I could merge your changes into the current 3.4-branch locally.

@vich-667
Copy link
Contributor

vich-667 commented Feb 9, 2023

I check that issue with ON/OFF:

  • Fritz box has an seperate channel for on/off and brightness. You can see the brightness value in fritz box GUI
  • In OpenHAB you can attach a conrol for on/off, Percantage or HSB to the color channel. all depend on the brightness value
    This ended up in you swith off in FritzBox gui but in open hab it's still on. I asume I found a way that it works much more intuitive.

I finally added also the update of color temperature is reflected to OpenHAB GUI.

Here is my PR to fix this issue: #14373

Thanks to @sommer for providing the base code of this PR. Without it my knowlage is currently not enought to do this changes.

@outerSpaceToast
Copy link
Author

Thank you very much for your time and good work!
I am looking forward to the next release including this update.

One question: I saw that the brightness is coupled to the On/Off-switch. If you set brightness to 50%, then switch off, then switch on again: Does it remember the brightness with your changes?

@vich-667
Copy link
Contributor

vich-667 commented Feb 9, 2023

  • If you switch on/off via a button, it remembers the brightness. Because OH only sends on off commands to fritz box and fritz box takes care of the value.
  • If you set brightness to zero it's the same behavior, becuse in this case I send now just off to the fritz box and do not change the brightness itself. You finally can swith on with an switch in OH of via APP.
  • If it's off OH always show a brightness of 0 because it dosn't know the fritz box value. If you just place the brightness to 50% it sends a on command + 50% command to fritz box that it's finally on in last mode.
  • If you move the brightness slider from 0% to 50% in an HSB element to switch on and white mode was set before, the mode will be canged, because a new color value is send as well.

@outerSpaceToast
Copy link
Author

That sounds like a good solution.
Thanks for the explanation!

@vich-667
Copy link
Contributor

vich-667 commented Feb 19, 2023

I created a branch to make it OH3.4.x compatible, what I use currently in my "produktive" setup: https://github.com/vich-667/openhab-addons/tree/task/3.4.x/colortemp
I don't know it's common to create also PRs for old versions, but I created one.

@vich-667
Copy link
Contributor

vich-667 commented Feb 20, 2023

I learned that the PR for 3.4.x version is not welcome. If someone is interrested either see the branch or here you can find the jar file: org.openhab.binding.avmfritz-3.4.3-SNAPSHOT.zip

@vich-667
Copy link
Contributor

Rebuild on base of latest 3.4.x release:
org.openhab.binding.avmfritz-3.4.5-SNAPSHOT.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants