briis / hass-weatherflow

Home Assistant Integration for WeatherFlow Stations
MIT License
67 stars 11 forks source link

Feels Like Temperature (1.0.0) Is Inaccurate #22

Closed Colorado4Wheeler closed 2 years ago

Colorado4Wheeler commented 2 years ago

I love that the hourly forecast now includes a "feels like" apparent temperature, very nice to know in advance! Having just created some feels like sensors and wind chill sensors for other devices just recently it looks like the apparent temperature in the attribute might be metric and not converting to imperial for those of us that use imperial as our default in Home Assistant.

For instance:

forecast:
  - datetime: '2021-12-29T15:00:00+00:00'
    temperature: 10.4
    precipitation: 0
    precipitation_probability: 0
    condition: partlycloudy
    wind_speed: 4.5
    wind_gust: 4.5
    wind_bearing: 9
    feels_like: -14
    uv_index: 0

Says that 10.4 F with humidity unknown and wind speed of 4.5 MPH calculates the apparent temperature at 14 below zero, when the actual calculation would be 2.4 F. This is assuming that since humidity is not known and the temperature is below 50 F that the apparent temperature is based in wind chill instead of the Steadman formula for apparent temperatures when humidity is known. Converted to Celsius, the value would be -16.4, much closer to the value represented in the attribute.

I love the new values for the rest of the update. I don't know when I would use a freeze line but being a weather nerd means I'm now going to have to see what I can do with my newfound values! Thanks for writing this component, it was the reason I purchased a WeatherFlow in the first place!

briis commented 2 years ago

Thanks for writing this component, it was the reason I purchased a WeatherFlow in the first place!

Thank you very much. Appreciate it👏🏻

I will look in to the Feels Like temperature. The thing is that sometimes HA converts Temperature Values itself, based on the Unit System and sometimes is doesn't. As this is a Non Standard attribute, it most likely does not do any conversion and I send the value as Metric. But I will just double check.

Btw. in the README.md you can see what values I use a local formula for and which are done directly by WeatherFlow. The column Calculated Sensor displays Yes if I do the calculation, else the value comes directly from WeatherFlow. You can read more about what formulas they use here - now that you are a Weather Geek 😁

briis commented 2 years ago

I was right - as this is a Non Standard Temperature attribute, Home Assistant does not auto convert the value between Celsius and Fahrenheit, so I will have to send the right value based on Unit System. This is now fixed and I will soon push an update.

UPDATE: There are some issues with http://pypi.org, that prevents me from uploading the latest IO module. As soon as they are back up, I will release this.

briis commented 2 years ago

Released 1.0.1, which fixes the issue.