chrisjshull / homebridge-nest

Nest plugin for HomeBridge
699 stars 112 forks source link

Feature: select active temperature sensor #587

Closed etiennedub closed 1 year ago

etiennedub commented 1 year ago

close #470

New feature: Add selection for the active temperature sensor.

It works by adding new Service.Switches, for the main thermostat and for each temperature sensor. When pressed the selected sensor is set to active and others are disable. IMO the behavior is a bit weird, because we don't use the switch as intended (it's more like a button press with state for visualization).

I was looking for some drop-down menu or radio button-like service but I haven't found any. If you have any better idea fell free to comment or commit.

adriancable commented 1 year ago

This only works for thermostats on the REST API (which is only about 30% of total thermostats). Since thermostat assignment to the REST vs protobuf API is random, your PR will only work for 30% of people (without people being able to know in advance whether they are in the 30% or 70%). So I cannot accept it in this form.

etiennedub commented 1 year ago

I understand, to be honest I could not say that I really understand the whole API. I mostly mimic what I have on my network.

Is there a way to "switch" the API selection? Does it depends on devices or it's really random?

adriancable commented 1 year ago

@etiennedub - there's no way to influence the API used for devices. For the 3rd gen Learning Thermostat, it appears to be random. (Probably internally it's selected based on serial number or something similar, but I don't have any insight into how that occurs.)