-
Notifications
You must be signed in to change notification settings - Fork 83
How to add Thermostat / HeaterCooler that just Heats? #108
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
Comments
You would adjust the TargetHeaterCoolMode characteristic to have an allowed value of only Off and Heat; but that's not currently possible. |
Hello, I'm trying to modify library to support "heating-only" mode. I modified EnumCharacteristic, metod makeBuilder. I replaced minValue/maxValue by list of valid-values. Its works, I have device only with on/off switch without "auto-heat-cool-off" switch. But it works only few (~20) seconds after pairing. Then some update is started and all devices again have "auto-heat-cool-off" switch. Is there any other place in the code that needs to be modified?
|
i would suggest to change
|
I dunno, that seems like a pain to create specific enum/characteristic every time we need to restrict the possible values. b) for targetheatingcoolingstate, there are multiple combinations that make sense:
Seems like a better solution would be for enum-type characteristics, we add a way to define them with a list of valid values. then just keep re-using the existing Enum for them (you can only restrict, you can't add). @jvaclavovic : maybe you need to also restrict the values for the CurrentHeatingCoolingState for HomeKit to accept it? |
just checked in HAP specification, sub-set of defined enum values is supported by HAP |
This is exactly what I'm doing: I have implemented valid-values for EnumCharacteristic, instead of minValue and maxValue, because I think that min,max do not make sense for enum values. I set only INACTIVE and HEATING for CurrentHeaterCoolerStateEnum and HEAT for TargetHeaterCoolerStateEnum and it works - but only for few seconds (~ 30 seconds). After pairing I have Heating with on/off switch. But after few seconds the Heating switches to off/cool/heat/auto mode. It is some update from HomeKit, not from my side, because I have only implemented initial state and temperature, without any updates. I tried to remove unnecessary values from both enums, but it had no effect :/ |
Oh, I was my stupid mistake... I use repeately JsonArrayBuilder for creating list of valid values, but method build() on this object after creating list removes all values... so this works only for the first time and after accessories update valid-values was sent empty... So, valid-values on EnumCharacteristics works perfectly and I have "heats-only" HeaterCooler. Thank you for your help and I apologize for the inconvenience |
a recent PR implemented proper enums, so you can now build a heating only accessory |
The questions says it all. I have a fan that can just heat but not cool. Which Accessory should I use?
The text was updated successfully, but these errors were encountered: