home-assistant / home-assistant/android
Device Controls - Temperature sensors support
- Dominant language
- Kotlin
- Stars
- 3.9k
- Forks
- 1.1k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 81
Description
**Is your feature request related to a problem? Please describe.**
Adding Home Assistant to Device Controls with the built-in mode allows to use a wide range of entities from lights to automations, but temperature sensors are still missing.
**Describe the solution you'd like**
Add support to temperature sensors through the built-in mode for Device Controls, the [`ControlTemplate.getNoTemplateObject()`](https://developer.android.com/reference/android/service/controls/templates/ControlTemplate#getNoTemplateObject()) template should work, since it's supposed to be used when "the application might use this to convey information about the control, but the user can't interact with it", as said in the [Device Controls documentation](https://developer.android.com/develop/ui/views/device-control).
**Describe alternatives you've considered, if any**
If there are issues with `ControlTemplate.getNoTemplateObject()`, a workaround could be using the [`TemperatureControlTemplate`](https://developer.android.com/reference/android/service/controls/templates/TemperatureControlTemplate) while waiting for a better solution.
**Additional context**
I'm currently using the dashboard mode as a workaround, it works okay, but a webview will obviously never be as quick to load as native controls.
Contributor guide
Assessment
This issue has not been assessed yet.