All depends on the precision you need but you can begin with:Hi. I made a simple macro to display weather conditions as notification to have it on my watch. I use the inbuilt {weather_wind_direction} to get the wind direction but only in degree. Is it possible to show the direction in N W S O?
Thank you for replying. And how to integrate it into the macro? Attached a screenshot of my macroAll depends on the precision you need but you can begin with:
• 45⁰ < E < 135⁰
• 135⁰ < S < 225⁰
• 225⁰ < W < 315⁰
• otherwhise = N
First of all, I'm not sure you can useThank you for replying. And how to integrate it into the macro? Attached a screenshot of my macro
{weather_wind_direction}
as it's not a regular Magic Text.As I told you, all yourIf I don't made a mistake it doesn't work:
{weather_conditions} Temperatur: {weather_temperature_c}°C Wind: {weather_wind_speed_kmh} km/h IF {weather_wind_direction} > 44.9 AND {weather_wind_direction} < 135 THEN Direction = E ELSE IF {weather_wind_direction} > 134.9 AND {weather_wind_direction} < 225 THEN Direction = S ELSE IF {weather_wind_direction} > 224.9 AND {weather_wind_direction} < 315 THEN Direction = W ELSE IF {weather_wind_direction} > 314.9 ELSE Direction = N ENDIF Luftfeuchte: {weather_humidity}%
{weather_...}
variables are not built-in variables: where do you pick them up from?As I told you, all your{weather_...}
variables are not built-in variables: where do you pick them up from?
Thank you but I am not able to set it up like in your screenshot. I never used those IF/ELSE THINGS cause I don't understand it fully. Could you please tell me step by step the first two lines of your screenshot?All of @Dm114's IF/ELSE-IF statements have to be put in the macro as MacroDroid actions -- not inserted into the notification text as is:
View attachment 12877
and so forth for the other conditions...
Then you can insert the value of that local variable "wind_direction_compass" into your notification.
I think you should helpfully have a look to MacroDroid WikiThank you but I am not able to set it up like in your screenshot. I never used those IF/ELSE THINGS cause I don't understand it fully. Could you please tell me step by step the first two lines of your screenshot?
I have now spent several hours reading the instructions and trying to get a result, unfortunately without success. Do I have to create the variables {weather_wind_direction} and wind_direction_compass: myself in the main menu under Variables?I think you should helpfully have a look to MacroDroid Wiki
Just use the Weather trigger (in the top red area of the screen) then, in the blue area, add IF statements as in the example @RSF gave you above, a couple of days ago.I have now spent several hours reading the instructions and trying to get a result, unfortunately without success. Do I have to create the variables {weather_wind_direction} and wind_direction_compass: myself in the main menu under Variables?
{weather_wind_direction} is a built-in variable -- referred to as "Magic Text" in MacroDroid's documentation. You already found that and used it in your original Benachrichtigung Anzeigen action, along with the Magic Text for wind speed, temperature, and so forth.Do I have to create the variables {weather_wind_direction} and wind_direction_compass: myself in the main menu under Variables?
Please have a look if I'm on the right pathJust use the Weather trigger (in the top red area of the screen) then, in the blue area, add IF statements as in the example @RSF gave you above, a couple of days ago.
This 1st step is correct!Please have a look if I'm on the right path
Everything is right so far?Dieser 1. Schritt ist richtig!
Fügen Sie nun einer lokalen Zeichenfolgevariable zwischen der IF- und der END IF-Zeile/Anweisung eine Aktion „Variable festlegen“ hinzu (sagen wir „wind_direction_compass“, um dem Beispiel von @RSF zu folgen). Setzen Sie sie mit dem Buchstaben, der dem Test entspricht, also „E“ im 1. Zweig Ihres Tests. Fügen Sie dann eine ELSE IF-Zeile/Anweisung (2. Zweig) usw. hinzu (gemäß dem Beispiel von @RSF).
Don't use imbricated IF statements but the following structure (as shown by @RSF above, one unique IF with multiple ELSE IF) :Everything is right so far?