-
Notifications
You must be signed in to change notification settings - Fork 48
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
Feature Request: Customize unit settings per entity #308
Comments
To confirm: you're wanting to choose the units per entity category (temperature, etc.), not per each individual entity? |
Hi @bachya, Thanks for your quick reply. Yes, that's correct. Category would be sufficient. |
Got it; thanks! |
Putting down some thoughts. Underneath the hood, this isn't challenging. We can abstract unit conversion logic into a set of The more challenging part is configuration – what is the least "breaking," most user-friendly way to implement this? More specifically:
Will start working on the backend while I chew on this. EDIT: Okay, I think I have a plan:
|
@ketilmo Thanks for your patience! I've been hard at work and I'm now starting to implement the final user-facing portion of this: #338 In particular, take a look at what I'm proposing in the docs and see if it makes sense to you. Thanks! |
Wow @bachya, That was fast! Thanks a lot for your efforts, they are much appreciated. I checked the docs, and this looks like a great solution on how to handle the settings from a user perspective. |
Alright, with #346, this is completed for all unit categories. I have a few other PRs to add, but I will cut a release later today (and post back here when I do). |
@ketilmo 2022.10.1 release with this functionality. Enjoy! |
Awesome, @bachya! I can't wait to check it out! I'm running it as an add-on. Is there a way to change the settings through the UI? |
After investigating a bit, perhaps that thinking is erroneous – HASS only appears to allow you to alter some units (like temperature), but not others. Has that been your experience, too, @ketilmo? |
Nice! I wasn't aware of the possibility of changing the sensor type per entity. But you're right, it doesn't seem to work wind, rain and irradiance. |
Thanks for checking. I'll expose my options to the add-on and will report back. |
For clarity: Changing the type in the native UI works for temperature and pressure. |
Give me your thoughts: would it be worth exposing all of our options in the add-on, or only those options that HASS doesn't already cover (i.e., everything except temperature and pressure)? The former is probably the easiest/clearest to do, but appreciate your opinion. |
+1 for the second option. Hopefully, Home Assistant will eventually implement the UI unit setting for more types. So this might be a temporary workaround. |
I have raised a feature request for this over at the Home Assistant forums: https://community.home-assistant.io/t/customisable-units-for-more-sensor-types/476474?u=ketil |
@ketilmo Okay, version 2022.10.1 of the add-in is building, and once it's complete (and you upgrade), you'll be able to configure units other than temperature and pressure: To configure these options in the add-on, you'll need to toggle "Show unused optional configuration options" first. P.S., that strange UI – where a config option with two possible values shows radio buttons, and >2 shows a dropdown – Is in Home Assistant OS and not something I can change, unfortunately. |
This works like a charm, @bachya! Thanks for your efforts and making this happen! 👏🏻 |
Is your feature request related to a problem? Please describe.
Thanks for creating an amazing weather solution. It works great. An extension I would enjoy is being able to choose unit settings per entity, in the same way that the Ecowitt UI allows for.
Describe the solution you'd like
Be able to choose the unit types for
Additional context
See screenshot from Ecowitt GW1100 settings page.
The text was updated successfully, but these errors were encountered: