• Resolved FinnSommer

    (@finnsommer)


    Hello
    I have noticed a difference in the wind speed display. OWM shows a lower wind speed than openweather itself.
    You can see the difference here https://finnsommer.eu/owm-weather/ (Same city and same city ID)
    It affects the way the text is displayed by the wind speed.
    At this moment the plugin shows wind as Gentle Breeze but the openweathermap widget shows at ?Fresh Breeze.

    It seems like the plugin show a wind terminology that are a little lower that the actually weather from openweathermap.

    Can you follow me?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Uwe Jacobs

    (@uwejacobs)

    Thanks for pointing this out! You’re right, OWM Weather isn’t showing the same wind speed labels as OpenWeather since they are not part of their data. Honestly, I’m not sure where my current scale came from.

    In the next version of OWM Weather, I am switching to the Beaufort Wind Scale, which should help getting our wind speed labels more in line with OpenWeather.

    Appreciate your patience while we sort this out.

    function owmw_getWindspeedText($speed)
    {
        // Beaufort Wind Scale
        $windDescriptions = [
            73 => __('Hurricane', 'owm-weather'),
            64 => __('Violent Storm', 'owm-weather'),
            55 => __('Whole Gale/Storm', 'owm-weather'),
            47 => __('Strong Gale', 'owm-weather'),
            39 => __('Gale', 'owm-weather'),
            32 => __('Near Gale', 'owm-weather'),
            25 => __('Strong Breeze', 'owm-weather'),
            19 => __('Fresh Breeze', 'owm-weather'),
            13 => __('Moderate Breeze', 'owm-weather'),
            8 => __('Gentle Breeze', 'owm-weather'),
            4 => __('Light Breeze', 'owm-weather'),
            1 => __('Light Air', 'owm-weather'),
            0 => __('Calm', 'owm-weather')
        ];
    
        foreach ($windDescriptions as $windSpeed => $description) {
            if ($speed >= $windSpeed) {
                return $description;
            }
        }
    }
    Thread Starter FinnSommer

    (@finnsommer)

    Hi @uwejacobs

    Thank you.
    I looking foreward to get your new update of your great plugin.

    Plugin Author Uwe Jacobs

    (@uwejacobs)

    I just committed OWM Weather 5.6.15.

    Thread Starter FinnSommer

    (@finnsommer)

    Thanks @uwejacobs

    Sofare it’s looks good.

    Thread Starter FinnSommer

    (@finnsommer)

    @uwejacobs

    I was too fast writing it was good.
    Now the wind has change and the plugin still show the wrong text of wind speed.

    Please see the difference: https://finnsommer.eu/owm-weather/
    (Moderate breeze bs. Light breeze)

    • This reply was modified 1 year, 9 months ago by FinnSommer.
    Plugin Author Uwe Jacobs

    (@uwejacobs)

    The wind speed wasn’t converted to mi/h before applying the Beaufort Wind Scale. This should be corrected with 5.6.16.

    Thread Starter FinnSommer

    (@finnsommer)

    @uwejacobs
    Thank you.
    It works correct now with the 5.6.16 update.

    • This reply was modified 1 year, 9 months ago by FinnSommer.
Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Display wrong wind speed’ is closed to new replies.