Code Monkey home page Code Monkey logo

Comments (53)

thoukydides avatar thoukydides commented on May 17, 2024

However, I have a connected hood vent and would like to control the fan (0 thru 4 speeds - 0 = off and 4 is the highest) and the lights (dimmer control). (see screenshots) I figure these services are defined in HomeKit already so was hoping it would be possible to start there with this plug in.

Hood appliances are probably the only ones that do have reasonable HomeKit mappings. Unfortunately, I don't have a Home Connect Hood, and there isn't a simulator provided at https://developer.home-connect.com/simulator. This means that I am unable to test any support that I add. I could try coding something, but you would need to test and debug it.

Looking at the API documentation Hoods support two different types of light:

Presumably it is the first of these that your Hood has...

It would be nice to know if my connected dishwasher is on or if the cycle has ended. And if my connected oven is on or not. But I am OK with trying to get the hood vent above working first!

Both of those should already be supported as described in the README.

The Active and Status Active characteristics on the Home Appliance service indicate when the dishwasher or oven are on, and the Remaining Duration indicates how long is left in the current program. Unfortunately, none of these are supported by Apple's own Home app. However, they can be viewed (and used as triggers) in third-party apps such as Elgato's Eve and Matthias Hochgatterer's Home+.

Additionally, Stateless Programmable Switch services are provided as automation triggers. These work in any HomeKit app, including Apple's Home. For the Oven the triggers are:

  1. Program finished
  2. Timer finished
  3. Preheat finished

For the dishwasher they are:

  1. Program finished
  2. Program aborted

Once again, Apple's Home app is more limited - it only shows the numeric label for these triggers. However,the Eve and Home+ apps show their names which makes them easier to use.

If these don't work with your appliances then please provide the log output. Make sure that you run homebridge in debug mode (i.e. launched with DEBUG=* homebridge -D) to provide more detail. Please also perform a HomeKit Identify operation (with version 0.4.0 or later of this plugin) and include the log output for that. (Make sure you remove any ClientID or OAuth tokens from the log output before posting...)

I am not an AppDev coder but I am a tinkerer. If you need me to TCPDUMP and grab PCAPs from the Thermador HomeConnect app to help out

Unfortunately that would not be of any use. The Home Connect API uses https so the connections are encrypted.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

There is now some prototype support for hoods in version 0.5.0 (c902042). This attempts to support the fan and functional light.

As mentioned above, I am unable to perform any testing of the hood support, so this version is likely to have serious problems. Please thoroughly test:

  • That the status shown by HomeKit accurately reflects changes made on the hood itself (or via the Home Connect app).
  • That control of the fan and light from HomeKit work as expected. Please try all combinations of settings.

For anything that does not work as expected please provide the log output (in debug mode, DEBUG=* homebridge -D) with an explanation of what you tried to do, what you expected, and what actually happened. Please also provide the log output for a HomeKit Identify operation.

The current code is a bit of a hack to get some quick feedback about how the hood appliances behave. It needs to be rewritten, e.g. to query the supported programs and their options and to only present appropriate services, characteristics, and ranges. Based on your description my expectation is that with your model the fan speeds will map to 0-80% in HomeKit, with 100% being unsupported.

Let me know how you get on...

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Thanks - That was a quick response!

Let me try it out and get back to you.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I have just released version 0.6.0. There are a lot of changes under-the-hood, but the main functional difference is that it now attempts to autodetect the type(s) of light supported by Hood appliances.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

haha!! just saw this - and I had updated to 0.5.0 after I wrote but will now update to 0.6.0 to try it out. will keep you posted. thanks!

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Just spotted a small bug in the fan control. When starting the manual program it incorrectly sets Cooking.Common.Option.Hood.IntensiveLevel instead of Cooking.Common.Option.Hood.VentingLevel. Hence, turning on the fan from HomeKit will not set the initial speed.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Just spotted a small bug in the fan control. When starting the manual program it incorrectly sets Cooking.Common.Option.Hood.IntensiveLevel instead of Cooking.Common.Option.Hood.VentingLevel. Hence, turning on the fan from HomeKit will not set the initial speed.

That should now be fixed in version 0.7.0. This version should also autodetect the fan capabilities (number of power levels and whether it has an auto mode).

This version always attempts to start a program to set the fan speed and mode. I suspect that this might fail if the fan is already running, so please let me know (and provide logs, with debugging enabled).

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

I didn't get a chance to test anything out yesterday but just saw the 0.8.0 update so will grab that. I should have time today to test it out. Thanks again!

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Just installed 0.8.0 and did get an error on startup for the first time but looks like it is still running the plug-in. See below (5th from the bottom):

[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Program inactive; 0 seconds remaining
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Inactive
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Door closed
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Program inactive; 0 seconds remaining
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Inactive
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Door closed
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Program inactive; 0 seconds remaining
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Inactive
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Door closed
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Adding services for 6 programs
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] 'Topbottom heating' (Cooking.Oven.Program.HeatingMode.TopBottomHeating)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] '4D Hot air' (Cooking.Oven.Program.HeatingMode.HotAir)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] 'Intensive heat' (Cooking.Oven.Program.HeatingMode.IntensiveHeat)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] 'Hot air grilling' (Cooking.Oven.Program.HeatingMode.HotAirGrilling)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] 'Keep warm' (Cooking.Oven.Program.HeatingMode.KeepWarm)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] 'Proof' (Cooking.Oven.Program.HeatingMode.Proof)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Removing services for 0 programs
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Right] Programs cannot be controlled without Control scope
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] Door closed
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] Program inactive; 0 seconds remaining
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] Inactive
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Hood] Off
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] Adding services for 5 programs
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] 'Intensive 70C' (Dishcare.Dishwasher.Program.Intensiv70)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] 'Auto 45-65C' (Dishcare.Dishwasher.Program.Auto2)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] 'Eco 50C' (Dishcare.Dishwasher.Program.Eco50)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] 'Glass 40C' (Dishcare.Dishwasher.Program.Glas40)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] 'Quick wash 45C' (Dishcare.Dishwasher.Program.Quick45)
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Dishwasher] Removing services for 0 programs
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Error GET programs: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]
[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Will retry when next connected: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]
[Homebridge] [12/30/2019, 11:23:15 AM] [HomeConnect] [Oven Right] Off
[Homebridge] [12/30/2019, 11:23:15 AM] [HomeConnect] [Dishwasher] Off
[Homebridge] [12/30/2019, 11:23:15 AM] [HomeConnect] [Oven Left] Off

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Just installed 0.8.0 and did get an error on startup for the first time but looks like it is still running the plug-in. See below (5th from the bottom):

[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Error GET programs: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]

The only thing that error should affect is the creation of Switch services to allow programs to be started on your Oven Left. Everything else should operate as intended. You should be able to test the Hood fan and light control, as well as starting/stopping programs on your Dishwasher, and monitoring programs on your Oven Right.

Curiously, that BSH.Common.Error.InvalidUIDValue error is not one of those documented at https://developer.home-connect.com/docs/general/apierrors, there are no matches on Google, and I have never seen that error myself. The error code doesn't suggest any particular cause, so I have no idea why it occurred or how to fix it. Please can you try switching the Oven Left on and then restarting homebridge; it is possible that the oven may not respond correctly to the API when not switched on.

The log that you provided does not have debugging enabled, so only provides limited information. As requested in my earlier responses, for anything that does not work as expected please provide the log output (in debug mode, DEBUG=* homebridge -D). It probably won't help in this particular case though since I know exactly which operation failed.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I just noticed from your original comment that Oven Left and Oven Right are both the same model (Thermador Oven PRD486WDHU/01), and both were switched off, which makes it particularly odd that one returned the list of supported programs but the other returned an error. Can you think of any difference that might be relevant, such as one having remote start enabled but the other not?

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

I will turn debug on - I just wanted to send you a quick log of Homebridge starting up and getting those errors since those were the first errors I have seen on start up with your plugin. I am testing out the hood light/fans now and documenting some idiosyncrasies to reply to in a bit.

As for the oven - you are correct. My model PRD486WDHU which you mentioned has a main oven (right) which has support for remote start and also a smaller side oven (left) which does not support remote start.

Not that you need to look through the User Manual for it but page 11 here shows you what the range looks like with the 2 ovens. Page 38 talks about the HomeConnect features of the main oven (right)

https://media3.bsh-group.com/Documents/8001145887_C.pdf

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I am testing out the hood light/fans now and documenting some idiosyncrasies to reply to in a bit.

Thank you. I wasn't expecting the Hood control to work perfectly first-time. Neither the simulators nor my own physical appliances operate quite how I would expect based on the API documentation (or even the same as each other). I look forward to your feedback.

As for the oven - you are correct. My model PRD486WDHU which you mentioned has a main oven (right) which has support for remote start and also a smaller side oven (left) which does not support remote start.

OK, that sort of makes sense... although I would have expected the API to either not advertise the left oven at all, or to return an empty list of programs in that case. There does not appear to be anything obvious in the API that can be used to determine that the left oven does not support programs, so I don't think there is any alternative to issuing the request and receiving the error.

I have contacted the Home Connect developer support to ask about this error, but unless they provide a useful response I probably won't do anything about this. Other than the entry in the log file the current behaviour is perfectly safe and should not affect any of the plugin's other functionality.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Did some testing on the Hood/Fan only to start. The fan turns on and off but I can't adjust the speed. Also, you are kind of right in regards to if the fan is already on before going into the app or using Siri to turn it off, it won't turn off. I got it to turn off after trying to turn off the button 3 times. I was able to reproduce that issue every time the fan was on prior to turning it on with Siri/HomeKit.

The light turned on fine but the weird thing was - sometimes even though the app showed the dimmer as off, the light would still be on at 10% brightness. Sometimes it would go off when turning it all the way off, but most of the time it would stop at 10% brightness and looking at the app, it would think it was off.

I'm not sure what the circle button below the light dimmer is for? I pressed it but it didn't seem to do anything. Also, as you can see in the UI screenshots, it says there is an unconfigured button but I don't see anything that is unconfigured?

I have included the debug and tried to remove any of the other plugin debug info so you don't have to be distracted.

Let me know what you think.

Thanks!
IMG_0465
IMG_0464
IMG_0463
debug.txt

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Thank you @JerGitHub for this useful feedback. The log file is especially helpful, so starting with that...

  1. Both the Hood's fan and its functional light are controlled by multiple HomeKit characteristics. Whilst Homekit/Homebridge wait for a change to a characteristic to complete (either successfully or with an error) before issuing another request for the same characteristic, it overlaps changes to different characteristics. This is particularly common when a single action within the Home app results in multiple characeristics changing, e.g. turning on the light sets both On and Brightness. The plugin currently generates independent Home Connect requests for each HomeKit characteristic change, which ends up with unpredictable results when they are attempting to control the same feature. It also makes it more likely that the strict Home Connect rate limits will be exceeded. This problem is exacerbated by the Home Connect API being quite slow - usually taking 1 or 2 seconds to complete each request. I will change the plugin to wait to allow multiple simultaneous characteristic changes before issuing a Home Control request, and to ensure that successive requests triggered by different characteristics are sequences rather than overlapped. This should make the behaviour more reliable. It should also reduce the number of Home Connect requests, making it less likely that the rate limits will be exceeded, and resulting in quicker responses to HomeKit.
  2. The plugin currently attempts to change the fan speed by starting a new program. When you attempted to quickly change the speed multiple times this exceeded the Home Connect rate limits, resulting in the error The rate limit "5 start program calls in 1 minute" was reached. Requests are blocked during the remaining period of 35 seconds. [429]. I will try changing the plugin to adjust the fan speed without starting a new program. However, this may not work; the Home Connect documentation states that "Please note that changing options of the running program is currently only supported by ovens". If this does not work then I will need to revert to the current method.
  3. When you operated the Hood manually it locked out remote control via the Home Connect API. This resulted in the error Request cannot be performed temporarily! due to local actuated user intervention [BSH.Common.Error.LockedByLocalControl]. That is a Home Connect limitation which I cannot do anything about. However, the improvements that I am planning should reduce the number of requests issued in this state, which in turn should result in less chance of exceeding Home Connect rate limits, and quicker error responses back to HomeKit.

Did some testing on the Hood/Fan only to start. The fan turns on and off but I can't adjust the speed.

Looking at the log, the fan speed changes did actually work (which is a pleasant surprise because I was not expecting it to work):

[Homebridge] [12/30/2019, 3:20:36 PM] [HomeConnect] [Hood] SET fan manual 33%
[Homebridge] [12/30/2019, 3:20:36 PM] [HomeConnect] Home Connect request #71: PUT https://api.home-connect.com/api/homeappliances/THERMADOR-VCIN48GWS-68A40E1C48FB/programs/active
[Homebridge] [12/30/2019, 3:20:36 PM] [HomeConnect] [Hood] SET fan manual 67%
[Homebridge] [12/30/2019, 3:20:36 PM] [HomeConnect] Home Connect request #72: PUT https://api.home-connect.com/api/homeappliances/THERMADOR-VCIN48GWS-68A40E1C48FB/programs/active
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] Home Connect request #2: STREAM DATA +216669ms
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Event NOTIFY (2 items)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Cooking.Common.Option.Hood.VentingLevel=Cooking.Hood.EnumType.Stage.FanStage03 (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan 67%
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] BSH.Common.Option.ElapsedProgramTime=22 seconds (0 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] Home Connect request #72: OK +1037ms
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] BSH.Common.Root.ActiveProgram=Cooking.Common.Program.Hood.Venting (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan manual control
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Cooking.Common.Option.Hood.VentingLevel=Cooking.Hood.EnumType.Stage.FanStage03 (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan 67%
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] Home Connect request #71: OK +1140ms
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] BSH.Common.Root.ActiveProgram=Cooking.Common.Program.Hood.Venting (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan manual control
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Cooking.Common.Option.Hood.VentingLevel=Cooking.Hood.EnumType.Stage.FanStage02 (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan 33%
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] Home Connect request #2: STREAM DATA +216827ms
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Event NOTIFY (1 item)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Cooking.Common.Option.Hood.VentingLevel=Cooking.Hood.EnumType.Stage.FanStage02 (1 listeners)
[Homebridge] [12/30/2019, 3:20:37 PM] [HomeConnect] [Hood] Fan 33%

The problem is that there are two overlapping requests:

  • The first request was probably triggered by either the Active (inactive/active) or the Target Fan State (manual/auto) characteristic, preserving the old Cooking.Hood.EnumType.Stage.FanStage02 (33%) fan speed. This resulted in Home Connect request #71.
  • The second request was presumably for the Rotation Speed characteristic, increasing the fan speed to Cooking.Hood.EnumType.Stage.FanStage03 (67%). This resulted in Home Connect request #72.

Both requests are attempting to start the same Cooking.Common.Program.Hood.Venting program, but with different options.

These requests completed in reverse order, resulting in the fan speed being increased, but then immediately being returned to its previous speed. Home Connect events are received confirming that the speed was really changed twice in quick succession.

The change that I am planning to defer and serialise Home Connect actions in response to multiple HomeKit characteristics changing should fix this problem. (Of course, the other change to try updating program options without starting a new program could break it again...)

By the way, does your fan support Automatic Mode and/or Delay Shut Off? I could not see any evidence of either being used in the log.

Also, you are kind of right in regards to if the fan is already on before going into the app or using Siri to turn it off, it won't turn off. I got it to turn off after trying to turn off the button 3 times. I was able to reproduce that issue every time the fan was on prior to turning it on with Siri/HomeKit.

I think this is a completely different issue.

It looks like operating the appliance locally locks out the Home Connect API for a period of time afterwards. There is nothing that I can do about that; it is a Home Connect limitation.

The light turned on fine but the weird thing was - sometimes even though the app showed the dimmer as off, the light would still be on at 10% brightness. Sometimes it would go off when turning it all the way off, but most of the time it would stop at 10% brightness and looking at the app, it would think it was off.

HomeKit treats On and Brightness as separate characteristics for a Lightbulb. Apple's Home app combines both of these into a single slider. For most of its range it controls the brightness; the minimum brightness for the Hood functional light is 10%, so the slider range is 10-100%. However, when the slide is pulled right to the bottom (or slightly below) it controls the power instead and shows the symbol of a bulb with a line through it.

I suspect that the inconsistent behaviour that you are seeing is due to the issue described above, where the actions triggered separately by the Brightness and On characteristics changing overlap. It should behave more predictably once I fix that.

I'm not sure what the circle button below the light dimmer is for? I pressed it but it didn't seem to do anything.

For coloured lights the Home app shows six circles below the slider to quickly change the colour - five with preset colours and one that can be edited. For simple on/off lights it just shows a switch instead of a slider, and there are no circles underneath.

The Hood functional light supports brightness control, but not colour. I don't have any dimmable lights without colour control so cannot test this. However, my guess is that the Home app is either adding a single circle to select a preset brightness, or is just putting a dummy placeholder so that it can use the same layour as for lights with colour control. Either way, this is a Home app specific issue that is nothing to do with this plugin.

Also, as you can see in the UI screenshots, it says there is an unconfigured button but I don't see anything that is unconfigured?

That is the Stateless Programmable Switch service that the plugin uses to report events. In the case of a Hood there is a single Stateless Programmable Switch that is used to generate an automation trigger from the BSH.Common.Event.ProgramFinished notification.

You should see two separate tiles for the Hood appliance within the Home app. One is the Switch tile that you have been using that has the fan and light controls. The second one will be paler with an icon of a square with a circle inside. That will show a BUTTON 1 with Single Press and Double Press that can be used to trigger automations.

Unless you want to trigger an automation when the fan switches off then you don't need to do anything with this.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I'm not sure what the circle button below the light dimmer is for? I pressed it but it didn't seem to do anything.

For coloured lights the Home app shows six circles below the slider to quickly change the colour - five with preset colours and one that can be edited. For simple on/off lights it just shows a switch instead of a slider, and there are no circles underneath.

If I fake a Hood then I get one circle underneath the fan speed control slider (which switches between manual and auto mode) and six underneath the ambient light slider (to quickly select different colours). However, there are no circles underneath the functional light slider.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Version 0.9.0 contains all of the changes that I described above.
Please let me know how you get on with it.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Happy New Year! And thanks for all of this. I just grabbed 0.9.1 and will test it out in debug and provide feedback.

Let me see if I can answer and/or comment on what you wrote above.

This problem is exacerbated by the Home Connect API being quite slow - usually taking 1 or 2 seconds to complete each request.

I definitely see this lag and even see it within their own Thermador HomeConnect app as well. When I get a chance to test 0.9.1, I will let you know how this performs.

  1. I was never able to change the fan speed in the last version I sent you the debug logs for at all so it's weird that it gave that error. I'm not sure what was shown in the log for fan speed was me attempting to change via homebridge or if that was me manually changing it and testing if I could change speeds and/or turn on and off when it was going? Either way, I will test it in this new build and see if I can adjust the fan speed from via HomeKit/HomeBridge/Your Plugin.

  2. I'll test the Hood fan manual start vs. app start response in 0.9.1

By the way, does your fan support Automatic Mode and/or Delay Shut Off? I could not see any evidence of either being used in the log.

My fan has both Auto Mode and Delay Shut Off mode. I have included screenshots below. I didn't test any of that in debug mode but I can for 0.9.1 and send you the debug logs.

the minimum brightness for the Hood functional light is 10%, so the slider range is 10-100%. However, when the slide is pulled right to the bottom (or slightly below) it controls the power instead and shows the symbol of a bulb with a line through it.I suspect that the inconsistent behaviour that you are seeing is due to the issue described above, where the actions triggered separately by the Brightness and On characteristics changing overlap. It should behave more predictably once I fix that.

I'll definitely test this and let you know if it is fixed. Thanks for the explanation - that makes complete sense. Also, I noticed in the Thermador HomeConnect app that the slider for the light does not go below 10% either, so then I was thinking that's why it was stuck at 10% even when the UI was showing the symbol with a line through it meaning it was off. Your explanation makes more sense so hopefully it is fixed in 0.9.1.

  1. Thanks for the explanation on the circle. I didn't even think of the HomeKit option of multicolor lights even though I have some. I had never seen just a single circle but I get it. No big deal - was just wondering what it was since when I pressed it, nothing happened.

The second one will be paler with an icon of a square with a circle inside. That will show a BUTTON 1 with Single Press and Double Press that can be used to trigger automations.

I had noticed this second icon but didn't think it did anything and thought it was just a status and/or a stateless switch that didn't have a function. Now looking into it, I see the single and double press. I will have to set something up and test it - thanks!

Thanks again for all of this - this is great stuff!

IMG_0472
IMG_0471
IMG_0470
IMG_0469
IMG_0468

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

This wasn't debug mode so I will get more logs for you but just realized I updated to 0.9.1 while writing the reply above, and was using the Thermador HomeConnect app to grab screenshots for you. Looks like whatever I did in the Thermador HomeConnect app killed homebridge. I didn't realize it until I just went to make sure everything was running after I updated to 0.9.1.

See below:

[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] Active and program running
[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] Fan running
[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] On
[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] Fan automatic control
[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] Fan 67%
[Homebridge] [1/1/2020, 2:34:58 PM] [HomeConnect] [Hood] Program 600 seconds remaining
[Homebridge] [1/1/2020, 2:35:04 PM] [HomeConnect] [Hood] Program 594 seconds remaining
[Homebridge] [1/1/2020, 2:35:10 PM] [HomeConnect] [Hood] Program 588 seconds remaining
[Homebridge] [1/1/2020, 2:35:13 PM] [HomeConnect] [Hood] Program inactive; 0 seconds remaining
[Homebridge] [1/1/2020, 2:35:13 PM] [HomeConnect] [Hood] Inactive
[Homebridge] [1/1/2020, 2:35:13 PM] [HomeConnect] [Hood] Fan off
[Homebridge] [1/1/2020, 2:35:13 PM] [HomeConnect] [Hood] Off
[Homebridge] [1/1/2020, 2:35:13 PM] [HomeConnect] [Hood] Fan manual control
[Homebridge] [1/1/2020, 2:35:28 PM] [HomeConnect] [Hood] Active and program running
[Homebridge] [1/1/2020, 2:35:28 PM] [HomeConnect] [Hood] Fan running
[Homebridge] [1/1/2020, 2:35:28 PM] [HomeConnect] [Hood] On
[Homebridge] [1/1/2020, 2:35:28 PM] [HomeConnect] [Hood] Fan automatic control
[Homebridge] [1/1/2020, 2:35:28 PM] Error: Unsupported VentingLevel: Cooking.Hood.EnumType.Stage.FanOff
[Homebridge] at ApplianceHood.toFanSpeedPercent (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/has_fan.js:157:32)
[Homebridge] at HomeConnectDevice. (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/has_fan.js:90:32)
[Homebridge] at HomeConnectDevice.emit (events.js:210:5)
[Homebridge] at /private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_device.js:65:18
[Homebridge] at Array.forEach ()
[Homebridge] at HomeConnectDevice.update (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_device.js:62:15)
[Homebridge] at HomeConnectAPI.listener (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_device.js:351:22)
[Homebridge] at HomeConnectAPI.emit (events.js:210:5)
[Homebridge] at /private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_api.js:677:61
[Homebridge] at /private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_api.js:723:31
[Homebridge] at /private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_api.js:762:58
[Homebridge] at Array.forEach ()
[Homebridge] at IncomingMessage. (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/homeconnect_api.js:762:42)
[Homebridge] at IncomingMessage.emit (events.js:215:7)
[Homebridge] at addChunk (_stream_readable.js:309:12)
[Homebridge] at readableAddChunk (_stream_readable.js:286:13)
[Homebridge] at IncomingMessage.Readable.push (_stream_readable.js:224:10)
[Homebridge] at HTTPParser.parserOnBody (_http_common.js:128:22)
[Homebridge] at TLSSocket.socketOnData (_http_client.js:456:22)
[Homebridge] at TLSSocket.emit (events.js:210:5)
[Homebridge] at addChunk (_stream_readable.js:309:12)
[Homebridge] at readableAddChunk (_stream_readable.js:290:11)
[Homebridge] at TLSSocket.Readable.push (_stream_readable.js:224:10)
[Homebridge] at TLSWrap.onStreamRead (internal/stream_base_commons.js:182:23)
[Homebridge] [1/1/2020, 2:35:28 PM] Got SIGTERM, shutting down service...

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

By the way, does your fan support Automatic Mode and/or Delay Shut Off? I could not see any evidence of either being used in the log.

My fan has both Auto Mode and Delay Shut Off mode. I have included screenshots below. I didn't test any of that in debug mode but I can for 0.9.1 and send you the debug logs.

  1. Thanks for the explanation on the circle. I didn't even think of the HomeKit option of multicolor lights even though I have some. I had never seen just a single circle but I get it. No big deal - was just wondering what it was since when I pressed it, nothing happened.

In that case, the circle that you see underneath the sliders is almost certainly a toggle between manual and auto mode for the fan. It is nothing to do with the lightbulb. You should be able to confirm this by looking at the Homebridge log when pressing the circle.

This is one of the many examples of Apple's Home app having a poor user interface. I strongly recommend using a third-party HomeKit app instead. Elgato's Eve app is free, so there really is no reason not to use it.

[Homebridge] [1/1/2020, 2:35:28 PM] Error: Unsupported VentingLevel: Cooking.Hood.EnumType.Stage.FanOff
[Homebridge] at ApplianceHood.toFanSpeedPercent (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/has_fan.js:157:32)

I can see where this error is being thrown, but cannot immediately spot why it would happen, but will take a closer look this evening when I get home from work.

Hopefully a log with debug enabled will help...

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

[Homebridge] [1/1/2020, 2:35:28 PM] Error: Unsupported VentingLevel: Cooking.Hood.EnumType.Stage.FanOff
[Homebridge] at ApplianceHood.toFanSpeedPercent (/private/var/root/.hoobs/node_modules/homebridge-homeconnect/has_fan.js:157:32)

I can see where this error is being thrown, but cannot immediately spot why it would happen, but will take a closer look this evening when I get home from work.

I have tried, but an unable to either reproduce that error or spot anything that might cause it. I will investigate further when you provide a log with debug enabled.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Sorry - haven't had a chance to test yet. Will try to get to it today and send it over. I was able to get it to stop homebridge again when using the Thermador HomeConnect app so I'll try and capture when it happens and what I was doing.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Version 0.10.0 logs some additional information that may help with diagnosing the Unsupported VentingLevel crashes that you are seeing. It should also fail more gracefully in that case - just logging the problem rather than bringing down the whole Homebridge instance.

Please let me know how you get on.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Thanks - just grabbed 0.10.0 and started it up without debug on and received a few new HAP warnings I hadn't seen before that I thought I would pass along below. I'm going to start testing everything now in debug and let you know what happens.

[Homebridge] [1/4/2020, 3:19:47 PM] [HomeConnect] Adding new accessory 'Hood'
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Hood] Thermador Hood (E-Nr: VCIN48GWS/01)
[Homebridge] HAP Warning: Characteristic 000000D1-0000-1000-8000-0026BB765291 not in required or optional characteristics for service 61908960-e7a1-4eca-be29-9ab6027289d4. Adding anyway.
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] Adding new accessory 'Oven Left'
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Oven Left] Thermador Oven (E-Nr: PRD486WDHU/01)
[Homebridge] HAP Warning: Characteristic 000000D1-0000-1000-8000-0026BB765291 not in required or optional characteristics for service 61908960-e7a1-4eca-be29-9ab6027289d4. Adding anyway.
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] Adding new accessory 'Oven Right'
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Oven Right] Thermador Oven (E-Nr: PRD486WDHU/01)
[Homebridge] HAP Warning: Characteristic 000000D1-0000-1000-8000-0026BB765291 not in required or optional characteristics for service 61908960-e7a1-4eca-be29-9ab6027289d4. Adding anyway.
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] Adding new accessory 'Dishwasher'
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Dishwasher] Thermador Dishwasher (E-Nr: DWHD660WPR/01)
[Homebridge] HAP Warning: Characteristic 000000D1-0000-1000-8000-0026BB765291 not in required or optional characteristics for service 61908960-e7a1-4eca-be29-9ab6027289d4. Adding anyway.
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Hood] Connected
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Oven Left] Connected
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Oven Right] Connected
[Homebridge] [1/4/2020, 3:19:48 PM] [HomeConnect] [Dishwasher] Connected
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Hood] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Hood] Program inactive; 0 seconds remaining
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Hood] Inactive
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Hood] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Hood] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Program inactive; 0 seconds remaining
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Inactive
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Normal operation
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Door closed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Remote control/start not allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Left] Remote control/start not allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Program inactive; 0 seconds remaining
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Inactive
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Normal operation
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Door closed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Remote control/start not allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Remote control/start not allowed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Program inactive; 0 seconds remaining
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Inactive
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Normal operation
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Door closed
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Adding services for 6 programs
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] 'Topbottom heating' (Cooking.Oven.Program.HeatingMode.TopBottomHeating)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] '4D Hot air' (Cooking.Oven.Program.HeatingMode.HotAir)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] 'Intensive heat' (Cooking.Oven.Program.HeatingMode.IntensiveHeat)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] 'Hot air grilling' (Cooking.Oven.Program.HeatingMode.HotAirGrilling)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] 'Keep warm' (Cooking.Oven.Program.HeatingMode.KeepWarm)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] 'Proof' (Cooking.Oven.Program.HeatingMode.Proof)
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Removing services for 0 programs
[Homebridge] [1/4/2020, 3:19:49 PM] [HomeConnect] [Oven Right] Programs cannot be controlled without Control scope
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] GET programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] GET https://api.home-connect.com/api/homeappliances/THERMADOR-PRD486WDHU-68A40E268B0A-120/programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Ignoring BSH.Common.Error.InvalidUIDValue error
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Does not support any programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Adding services for 0 programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Removing services for 0 programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Remote control/start allowed
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Remote control/start not allowed
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Door closed
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Program inactive; 0 seconds remaining
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Inactive
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Normal operation
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] No commands supported
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Adding services for 5 programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] 'Intensive 70C' (Dishcare.Dishwasher.Program.Intensiv70)
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] 'Auto 45-65C' (Dishcare.Dishwasher.Program.Auto2)
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] 'Eco 50C' (Dishcare.Dishwasher.Program.Eco50)
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] 'Glass 40C' (Dishcare.Dishwasher.Program.Glas40)
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] 'Quick wash 45C' (Dishcare.Dishwasher.Program.Quick45)
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Dishwasher] Removing services for 0 programs
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Hood] Off
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Right] Off
[Homebridge] [1/4/2020, 3:19:50 PM] [HomeConnect] [Oven Left] Off
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Dishwasher] Off
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Hood] Home Connect API error: Setting not found for HomeAppliance [SDK.Error.UnsupportedSetting]
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Hood] GET BSH.Common.Setting.AmbientLightEnabled
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Hood] GET https://api.home-connect.com/api/homeappliances/THERMADOR-VCIN48GWS-68A40E1C48FB/settings/BSH.Common.Setting.AmbientLightEnabled
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Hood] Ignoring SDK.Error.UnsupportedSetting error
[Homebridge] [1/4/2020, 3:19:51 PM] [HomeConnect] [Hood] Does not support ambient light

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

just grabbed 0.10.0 and started it up without debug on and received a few new HAP warnings I hadn't seen before that I thought I would pass along below
[Homebridge] HAP Warning: Characteristic 000000D1-0000-1000-8000-0026BB765291 not in required or optional characteristics for service 61908960-e7a1-4eca-be29-9ab6027289d4. Adding anyway.

These HAP warnings are perfectly safe. I added a new Program Mode characteristic in this version, but forgot to mark it as being an optional characteristic in the Home Appliance service. This does not affect the functionality - it just results in this spurious warning.

I have fixed this in version 0.10.1. This is the only change, so there is no point upgrading.

The other two errors in this log are expected:

[HomeConnect] [Oven Left] Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]
[HomeConnect] [Oven Left] GET programs
[HomeConnect] [Oven Left] GET https://api.home-connect.com/api/homeappliances/THERMADOR-PRD486WDHU-68A40E268B0A-120/programs
[HomeConnect] [Oven Left] Ignoring BSH.Common.Error.InvalidUIDValue error

This is the issue that we discussed previously where your smaller (left) oven does not support remote start, so it does not return a list of programs. (I am still waiting to hear back from Home Connect developer support about this...)

[HomeConnect] [Hood] Home Connect API error: Setting not found for HomeAppliance [SDK.Error.UnsupportedSetting]
[HomeConnect] [Hood] GET BSH.Common.Setting.AmbientLightEnabled
[HomeConnect] [Hood] GET https://api.home-connect.com/api/homeappliances/THERMADOR-VCIN48GWS-68A40E1C48FB/settings/BSH.Common.Setting.AmbientLightEnabled
[HomeConnect] [Hood] Ignoring SDK.Error.UnsupportedSetting error

This is checking whether the Hood includes an ambient light. It looks like your appliance only has a functional light.

I am not aware of anything in the Home Connect API that allows discovery of these capabilities, other than by issuing these requests and checking for the errors. This is rather annoying given that Home Connect has a rate limit of 10 successive requests in 10 minutes that result in an error, with further requests blocked for 10 minutes...


I'm going to start testing everything now in debug and let you know what happens.

Thank you. I look forward to seeing the debug log. Hopefully it will reveal what is going wrong.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

I figured those HAP warnings I sent above were no big deal but just wanted to make sure you were aware of them since they were new from previous versions of the plugin.

OK - just tested all of the options with the hood fan/lights (I hope!) using 0.10.0 (I will upgrade to 0.10.1 later). For your own info, I agree with you on the Eve app vs. native Home app in iOS giving more functionality. I am trying to make this family proof so everyone in the house can use the native Home app and Siri to control things. That's more of an FYI for you but I wanted you to know I use/test the Eve app as well.

For the testing, I first started everything using the native Home app UI to control the fan and lights. The first thing I noticed was that the fan slider UI would only allow the fan speeds to be set to 33% or 66%. There are 5 setting buttons on the hood vent fan itself:
0 = off
1 = 0% (according to the logs attached)
2 = 33% (according to the logs attached)
3 = 66% (according to the logs attached)
4 = 100% (according to the logs attached)
I could never get the fan to set to 1 or 4 via the slider in the Home app UI - only 2 and 3 and 0. The slider would show 100% (4) in the UI but the fan would stay on 66% (3).
Also, many times trying to go from 2 to 3 with the slider would not work. The fan would stay on 2.
I could only set the fan on 1 or 4 using the buttons on the hood vent itself - not the UI - but the debug logs did record the correct button presses when done manually for 1 (0%) and 4 (100%).

As for the auto setting - Turning on fan, setting it to auto, then turning auto off turned the fan on at lowest setting (logs show 0% but is ‘1’ setting for Thermador). I thought that was weird since I couldn't get the speed to turn on to 1 via the slider as stated above.

Next I tried the lights via the Home app and these worked perfectly this time. The only thing I noticed was what you had already pointed out was a limitation with the HomeConnect APIs. When the lights were turned on manually, I can’t use the UI right away to change.

Next I tried to use the Thermador HomeConnect app to see if that would crash homebridge like it did the other day. The good news is - I couldn't get it to stop homebridge by turning on the fans, lights, and even testing a few buttons on the dishwasher too. Maybe that was a fluke thing or something you have fixed in 0.10.0? Either way - good news that using the Thermador app didn't cause any issues.

The final section of the logs I used Siri to control the fan and lights. I could only do low saying "Hey Siri turn on the hood fan to low" (which shows as 2 @ 33%), high saying "Hey Siri turn on the hood fan to high" (which shows as 3 @ 66%) and off for the fan. If I said "Hey Siri turn on the hood fan to 100%", it wouldn't do anything. Same for 66%, 33%, and 0%.

Obviously ignore the [webos-tv] logs.

Thanks for all the support and new builds! Let me know if you want me to try anything else.

HomeConnect Logs 1-4-2020.txt

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Thank you @JerGitHub for thoroughly testing this version and providing the very helpful debug log.

Next I tried to use the Thermador HomeConnect app to see if that would crash homebridge like it did the other day. The good news is - I couldn't get it to stop homebridge by turning on the fans, lights, and even testing a few buttons on the dishwasher too. Maybe that was a fluke thing or something you have fixed in 0.10.0? Either way - good news that using the Thermador app didn't cause any issues.

The problem is still there. It is just that in 0.10.0 it is treated as being non-fatal. Fortunately, the logging also reveals the cause:

[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Being controlled locally
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] Home Connect request #2: STREAM DATA +251308ms 
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Event NOTIFY (2 items)
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Cooking.Common.Option.Hood.VentingLevel=Cooking.Hood.EnumType.Stage.FanOff (1 listeners)
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Unsupported VentingLevel: Cooking.Hood.EnumType.Stage.FanOff
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Please copy the following to https://github.com/thoukydides/homebridge-homeconnect/issues/2
Thermador Hood (E-Nr: VCIN48GWS/01)
{
    "ventingLevel": "Cooking.Hood.EnumType.Stage.FanOff",
    "fanPrograms": {
        "manual": {
            "key": "Cooking.Common.Program.Hood.Venting",
            "name": "Fan setting",
            "constraints": {
                "execution": "selectandstart"
            },
            "options": [
                {
                    "key": "Cooking.Common.Option.Hood.VentingLevel",
                    "type": "Cooking.Hood.EnumType.Stage",
                    "constraints": {
                        "allowedvalues": [
                            "Cooking.Hood.EnumType.Stage.FanStage01",
                            "Cooking.Hood.EnumType.Stage.FanStage02",
                            "Cooking.Hood.EnumType.Stage.FanStage03",
                            "Cooking.Hood.EnumType.Stage.FanStage04"
                        ],
                        "displayvalues": [
                            "1",
                            "2",
                            "3",
                            "4"
                        ],
                        "default": "Cooking.Hood.EnumType.Stage.FanStage02"
                    },
                    "name": "Fan setting"
                }
            ]
        },
        "auto": {
            "key": "Cooking.Common.Program.Hood.Automatic",
            "name": "Automatic mode",
            "constraints": {
                "execution": "selectandstart"
            },
            "options": []
        }
    },
    "fanLevels": [
        "Cooking.Hood.EnumType.Stage.FanStage01",
        "Cooking.Hood.EnumType.Stage.FanStage02",
        "Cooking.Hood.EnumType.Stage.FanStage03",
        "Cooking.Hood.EnumType.Stage.FanStage04"
    ]
}
[Homebridge] [1/4/2020, 3:40:16 PM] [HomeConnect] [Hood] Fan 0%

The cause of the problem is that the Home Connect documentation states that the VentingLevel includes Cooking.Hood.EnumType.Stage.FanOff for fan off, and this is being returned as an event, but it is not being listed as one of the allowedvalues.

This is also why there is the mismatch between HomeKit and Home Connect speeds. The plugin is expecting the first entry in the allowedvalues to be off, so with four values returned it treats this as off plus three speeds.

I will think about how to handle this tomorrow. Presumably some Hoods may include off in their list of allowedvalues. I also want to add support for IntensiveLevel at the same time...

The final section of the logs I used Siri to control the fan and lights. I could only do low saying "Hey Siri turn on the hood fan to low" (which shows as 2 @ 33%), high saying "Hey Siri turn on the hood fan to high" (which shows as 3 @ 66%) and off for the fan. If I said "Hey Siri turn on the hood fan to 100%", it wouldn't do anything. Same for 66%, 33%, and 0%.

My experience of Siri with fans is that it likes low=25%, medium=50% and high=100%. The other issue is that when percentage step size from 0 to 100% is not an integer things tend not to work reliably. Looking at the log the step size is currently being rounded to 33.333333333333336%.

For my ceiling fan I had to create a non-linear scale for it to work properly. This is fine with a hardcoded configuration, but different Home Connect Hoods support different numbers of venting levels (and it gets even more complicated with those that also support intensive levels). Again, something to think about tomorrow...

Of course, for your particular Hood once I fix the missing Cooking.Hood.EnumType.Stage.FanOff in the allowedvalues for VentingLevel the speeds will be 25%, 50%, 75% and 100%.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Version 0.11.0 should hopefully fix the issues with fan speed control:

  • It no longer matters whether the FanOff or IntensiveStageOff are returned in the fan program's allowedvalues.
  • Any intensive modes that the Hood supports are treated as the highest fan speeds. (This does not apply to your Thermador VCIN48GWS/01.)
  • The HomeKit rotation speed step size is now selected to be an integer that allows Siri to use low=25%, medium=50%, and high=100%.
  • If 0% is selected then it stops the program rather than attempting to set an unsupported speed.

Please let me know of any problems.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I have rewritten the handling of fan percentage speeds again in version 0.12.0. With a Hood that supports four speeds like yours it should not make any difference, but it should behave more consistently for Hood appliances that support a different number of speeds. The main differences are that the plugin will preferentially use 25%/50%/100% to match Siri, and that HomeKit is now told about the valid values (although no apps appear to respect this).

This version also attempts to avoid issuing requests to the Home Connect servers in some common cases where they would be expected to return an error. This should make it less likely that the plugin will exceed the Home Connect Rate Limits, especially:

10 successive requests per client and Home Connect user account per 10 minutes which result in an error

Hopefully these changes won't break anything.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Thanks! I haven't had a chance to get to it yesterday or today but will get back to you once I have had a chance to try it out and will report back.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Regarding this error...

[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Error GET programs: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]

As for the oven - you are correct. My model PRD486WDHU which you mentioned has a main oven (right) which has support for remote start and also a smaller side oven (left) which does not support remote start.

OK, that sort of makes sense... although I would have expected the API to either not advertise the left oven at all, or to return an empty list of programs in that case. There does not appear to be anything obvious in the API that can be used to determine that the left oven does not support programs, so I don't think there is any alternative to issuing the request and receiving the error.

Home Connect developer support have now responded with:

This error mean that this device – under specific UID is not supported by the API. From what I understand both ovens are recognized by our API after call GET /homeappliances? In correct behaviour API should return one oven only if device support Home Connect only on main one.

We are looking into that case, to make sure that nothing like that will appear in API, while it seems that user won't be able to use this specific oven remotely.

It appears to have been a bug in their server code...

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

It appears to have been a bug in their server code...

Ah interesting!

Sorry I haven't had a chance to test - crazy week at work. Will hopefully get to testing the latest today or tomorrow.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Error GET programs: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]

Home Connect developer support have now responded with:

This error mean that this device – under specific UID is not supported by the API. From what I understand both ovens are recognized by our API after call GET /homeappliances? In correct behaviour API should return one oven only if device support Home Connect only on main one.
We are looking into that case, to make sure that nothing like that will appear in API, while it seems that user won't be able to use this specific oven remotely.

Further feedback from Home Connect developer support:

We checked this problem carefully, and result is, that indeed API shouldn't provide any information regarding not supported oven. This will be solved by update on our side – user will see only oven which is fully supported by Home Connect.

Thank you very much for reporting this case, thanks to that we are able to provide better software for our users.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Good to know we are finding bugs in their SaaS apps!

I still haven't had a chance to test but will report back once I do.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

[Homebridge] [12/30/2019, 11:23:14 AM] [HomeConnect] [Oven Left] Error GET programs: Home Connect API error: HomeAppliance reported an error [BSH.Common.Error.InvalidUIDValue]

Latest from Home Connect developer support:

For your knowledge – update was released, and change should be visible on client side already. We would appreciate if you could let us know if everything is behaving correctly right now.

@JerGitHub, if you have any feedback on this issue then I will pass it back to the Home Connect team.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Sorry I have been MIA. Finally had a chance to try out the latest home-connect 0.14.0

Unfortunately, it looks like we took a step backwards. Now the hood fan doesn't work at all when using the app or Siri. The hood light ("Functional Light" button) still works perfectly though!

The only time the fan turns on is by using the "Hood Power Button" in the 4 toggles within the Hood accessory in the Home app (screenshots attached). This just turns the fan on and off. I cannot use the "Hood Fan" button to control fan speed as before. The "Hood Fan" button does not turn on the fan either if I just go straight to that button - there is no action sent in the logs to homebridge when I use the "Hood Fan" button either.

The last button "Hood Functional Light" has the same issue as the "Hood Fan" button as well. It does not do anything when pressed and does not post any action/event in the homebridge logs to show I pressed or slid the slider when used.

Hopefully the logs will be helpful in determining what is going on.

Thanks!

IMG_0490
IMG_0491
IMG_0492
IMG_0493
home-connect logs 1-20-2020.txt

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Sorry I have been MIA. Finally had a chance to try out the latest home-connect 0.14.0

No problem. I really appreciate the time you take to test this plugin and provide very helpful feedback.

Unfortunately, it looks like we took a step backwards. Now the hood fan doesn't work at all when using the app or Siri.

Looking at the log, the plugin’s fan control failed very early during its initialisation due to a stupid error that I introduced when tidying up the code as part of an unrelated change. Unfortunately, this error stopped any of the fan functionality from being enabled. 😞

Really sorry about that. At least it will be trivial to rectify.

The power switch and light are handled completely independently so are unaffected by this screw-up.

The only time the fan turns on is by using the "Hood Power Button" in the 4 toggles within the Hood accessory in the Home app (screenshots attached). This just turns the fan on and off.

The hood light ("Functional Light" button) still works perfectly though!

That’s encouraging. 😌

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Unfortunately, it looks like we took a step backwards. Now the hood fan doesn't work at all when using the app or Siri.

Looking at the log, the plugin’s fan control failed very early during its initialisation due to a stupid error that I introduced when tidying up the code as part of an unrelated change. Unfortunately, this error stopped any of the fan functionality from being enabled. 😞

Really sorry about that. At least it will be trivial to rectify.

Should be rectified in v0.15.0.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

ha! OK - glad to see you knew right away what the issue looks to be. Let me try 0.15.0 out and report back. Thanks!

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Thanks @JerGitHub. I look forward to seeing whether the new version works...

On the plus side, it looks like the changes that I made to improve error handling worked well. Earlier versions of the plugin would have logged an unhelpful message unrelated to the actual error cause, and all Hood functionality (and any appliances enumerated after it) would have failed completely. This time it logged the actual problem, and all functionality other than the fan control (and remaining duration, which is added to the Fan service) continued to work.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Unfortunately, running into the same issue as 0.14.0. Fan won't work via Home app or Siri. The only time the fan turns on is by using the "Hood Power Button" in the 4 toggles within the Hood accessory in the Home app. This just turns the fan on and off.

I had tried this on 0.15.0 and ran into the same issue but didn't tell you since I didn't have a chance to set it to debug mode. I just updated to 0.16.3 and tried again with the same issues as well.

Same exact tests and results as my 0.14.0 note above. #2 (comment)

HomeConnect 1-26-2020.txt

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

That’s very disappointing. Based on a quick look at the log this is a new problem parsing the fan programs returned by the appliance... but the net result is the same, i.e. the fan speed handling failed to initialise.

Unfortunately nothing obvious is leaping out as the cause, so I will look at it more carefully this evening.

Thank you @JerGitHub for your patience trying this again, and for the very helpful log file.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

OK, just had an idea about the cause. To improve the handling of programs for all other cooking and cleaning appliance I split the function that reads the program details into two separate functions, but had not updated the fan speed code to use both of them. The net result is that it is only retrieving the list of programs but not their supported options... so it inevitably breaks when trying to parse the options.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Fingers crossed for 0.16.4...

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

ha! ok - here goes....give me a little bit to try it and get back to you. thanks!

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

Sorry - haven't had a chance to grab logs but the hood light isn't working anymore - that's the bad news. The good news is the hood fan looks to be fixed!

Will grab logs and post later today.This is on the latest 0.16.7 I grabbed when I saw there was an update.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

Sorry - haven't had a chance to grab logs but the hood light isn't working anymore - that's the bad news.

I would guess that it is most likely to be due to a change in v0.16.7 the code that deals with lights. If you have the opportunity to try v0.16.6 then I would be interested in whether that is also broken.

The good news is the hood fan looks to be fixed!

Yeah! Finally... :-)

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

HomeBridge Logs 2-9-2020.txt
I didn't get a chance to revert back to v0.16.6 yet. I wanted to get you logs from the current v0.16.7 in case there was something in there that would pop up for you. I don't see any logs being written when I use the Home app or Siri to try and turn on the hood light. I'm not sure if these logs help you at all given the lack of any events logging.

I have to figure out how to revert back to v0.16.6 using HOOBS. I started using HOOBS at the end of last year because I like the UI and ease of use from a web interface. It's good at abstracting the details but not so good when you need to get advanced and revert to an older plugin it seems!

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I think that I have spotted the bug that I introduced in v0.16.7. Don’t worry about v0.16.6.

I don’t use HOOBS myself - I prefer to manage everything manually. I took a quick look at what would be required to integrate this plugin with it properly, but it doesn’t look feasible. Unfortunately, it’s configuration system isn’t particularly good - it forces plugins to use a particular non-standard and inflexible configuration structure that is incompatible with other tools. Even worse, it attempts to use the schema created for homebridge-config-ui-x, doesn’t pick up the dynamically generated replacement schema, and throws half of it away anyway.

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

I didn't get a chance to revert back to v0.16.6 yet. I wanted to get you logs from the current v0.16.7 in case there was something in there that would pop up for you. I don't see any logs being written when I use the Home app or Siri to try and turn on the hood light. I'm not sure if these logs help you at all given the lack of any events logging.

The log did confirm what I suspected:

[Homebridge] [2/9/2020, 9:17:01 PM] [HomeConnect] Home Connect request #19: GET https://api.home-connect.com/api/homeappliances/THERMADOR-VCIN48GWS-68A40E1C48FB/settings
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] Home Connect request #19: OK +987ms 
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] [Hood] BSH.Common.Setting.PowerState=BSH.Common.EnumType.PowerState.Off (1 listeners)
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] [Hood] Off
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] [Hood] Cooking.Common.Setting.Lighting=false (0 listeners)
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] [Hood] Cooking.Common.Setting.LightingBrightness=10 % (0 listeners)
[Homebridge] [2/9/2020, 9:17:02 PM] [HomeConnect] [Hood] Does not support Functional Light

The plugin was correctly reading the supported settings, which included the controls for the functional light. However, it then failed to read the details of those settings but instead just claimed that the functional light is not supported. This was caused by a bug in the code that avoids asking for details of unsupported settings.

Should be fixed in v0.16.8.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

All fixed in v0.16.8 - both hood fan and hood light working via Siri and the Home app. Thanks!

One question since I don't know if this is possible - not sure if this is a Siri/Homekit limitation but could you make the plugin work so if you say:
"Hey Siri, turn the hood fan to 1", it would be equivalent to saying "Hey Siri, turn the hood fan to 25%"
"Hey Siri, turn the hood fan to 2", it would be equivalent to saying "Hey Siri, turn the hood fan to 50%"
"Hey Siri, turn the hood fan to 3", it would be equivalent to saying "Hey Siri, turn the hood fan to 75%"
"Hey Siri, turn the hood fan to 4", it would be equivalent to saying "Hey Siri, turn the hood fan to 100%"

If not, no big deal. Just wondering if that's possible.

As for HOOBS - I agree with you. I used to do everything via CLI but I saw HOOBS v3.x new UI and liked what I saw and wanted to give it a try. I like it so far but I still debate throwing it out and going with homebridge-config-ui-x. I don't blame you for not writing a "certified" plugin for HOOBS either. No real need. All "non-certified" plugins work perfectly with it since it is homebridge and all.

Time to test out the dishwasher and oven part of your plugin - I haven't focused on that since you were helping me with the hood and lights which we use every day.

Thanks again!

from homebridge-homeconnect.

thoukydides avatar thoukydides commented on May 17, 2024

All fixed in v0.16.8 - both hood fan and hood light working via Siri and the Home app.

Wonderful!

Sorry that it took so long to reach this stage. I really appreciate your patience, clear feedback, and helpful log files.

One question since I don't know if this is possible - not sure if this is a Siri/Homekit limitation but could you make the plugin work so if you say:
"Hey Siri, turn the hood fan to 1", it would be equivalent to saying "Hey Siri, turn the hood fan to 25%"
"Hey Siri, turn the hood fan to 2", it would be equivalent to saying "Hey Siri, turn the hood fan to 50%"
"Hey Siri, turn the hood fan to 3", it would be equivalent to saying "Hey Siri, turn the hood fan to 75%"
"Hey Siri, turn the hood fan to 4", it would be equivalent to saying "Hey Siri, turn the hood fan to 100%"

Sorry, no. You can, however, use low, medium, and high to specify the fan speeds from Siri.

HomeKit defines the Rotation Speed characteristic for a Fan service to be a percentage. The only things that can be changes are the minimum and maximum percentages, and the step size. Siri further restricts it by always using 25%, 50%, and 100% for low, medium and, high.

Time to test out the dishwasher and oven part of your plugin - I haven't focused on that since you were helping me with the hood and lights which we use every day.

I will close this bug now since the hood support appears to be working.

However, if you find any new problems - with either the hood or dishwasher/oven support - then please raise separate issues for them.

from homebridge-homeconnect.

JerGitHub avatar JerGitHub commented on May 17, 2024

No need to apologize to me - you are doing me a huge favor by releasing this and tweaking it and taking feedback to make things better. I appreciate all your work!

As far as the speed characteristics, that makes sense. I'm good with the way it is, but thought I would ask.

Thanks again and I will test out the dishwasher and oven and give you feedback.

from homebridge-homeconnect.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.