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

MQTT device target_temperature configurable value min/max/decimals/step capabilityOptions #82

Open
oh2th opened this issue Oct 31, 2022 · 0 comments

Comments

@oh2th
Copy link

oh2th commented Oct 31, 2022

MQTT devices as thermostats should allow configurable minimum and maximum values for target_temperature similar to what Virtual Devices does.

811A368F-8BAC-4144-B780-52100B655B60

Then this type of device would be usable for thermostats in saunas (over 60C) or a spa (at 36-37C), which are outside the Homey default 35C maximum.

So when adding a device with target_temperature capability, allow editing decimals, min, max and step value:
Screenshot 2023-02-01 at 11 33 51

And store them with the settings.topics JSON for future edits to the capability. For example in my se case for the Spa I would have:

{
  "measure_temperature": {
    "capability": "measure_temperature",
    "valueDecimals": "1",
    "stateTopic": "ble/vaasanrinne7/spa_vesi",
    "setTopic": "",
    "valueTemplate": "t / 10",
    "outputTemplate": "",
    "displayName": "Water"
  },
  "target_temperature": {
    "capability": "target_temperature",
    "valueDecimals": "1",
    "valueMin": "15",
    "valueMax": "40",
    "valueStep": "0.5",
    "stateTopic": "ble/vaasanrinne7/spa_vesi",
    "setTopic": "ble/vaasanrinne7/spa_vesi/set",
    "valueTemplate": "tt / 10",
    "outputTemplate": "",
    "displayName": "Set Temperature",
  }
}

This min/max/step option should be there for any number type as is described in the API docs for number:
https://apps.developer.homey.app/the-basics/devices/capabilities#number-capability-options

Including also units would be a bonus, but is off topic for target_temperature.

@oh2th oh2th changed the title MQTT device thermostat configurable range value limits MQTT device target_temperature configurable value min/max/decimals/step capabilityOptions Feb 1, 2023
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

No branches or pull requests

1 participant