REXYGEN Community Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Login

    Solved Degrees to compass direction

    REXYGEN Studio
    2
    4
    305
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      MikeyH
      last edited by

      Hi Team,

      I'm using open weather map. Wind direction is in degrees. If I wanted to convert degrees to a compass direction, NNE for example. What's the best way to do that?

      Cheers

      Mike

      1 Reply Last reply Reply Quote 0
      • cechuratC
        cechurat
        last edited by

        Hi Mike,

        have a look at function block CNDR and PARE - it should do the job. CNDR could be used to transfer range of wind direction to an integer value. Integer could be represented using PARE by number and string (PARE:sy).

        5fc44f03-15a0-460a-b4ff-e5185adc982e-image.png

        Kind Regards,
        Tomas

        M 1 Reply Last reply Reply Quote 0
        • M
          MikeyH @cechurat
          last edited by

          @cechurat Hi Tomas,

          That works very well
          81d1743a-02e5-45a1-a0df-93cbb00e1990-image.png

          I ended up doing it in intervals of 22.5deg. But used 17 values all together to allow for 0 and 360 = N.
          Thank you for the help.

          Cheers

          Mike

          1 Reply Last reply Reply Quote 0
          • cechuratC
            cechurat
            last edited by

            Hi Mike,

            Thanks for your feedback - I'm glad I could help.

            Kind Regards.
            Tomas

            1 Reply Last reply Reply Quote 0
            • First post
              Last post

            This is a community forum for REXYGEN users and fans. Detailed information can be found at REXYGEN homepage.

            There is also an outdated REXYGEN community forum.

            Powered by NodeBB.