MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    MMM-google-route and coordinates

    Scheduled Pinned Locked Moved Solved Troubleshooting
    7 Posts 2 Posters 1.7k Views 2 Watching
    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.
    • Z Offline
      Zippyczech
      last edited by

      Hey guys,

      I´m working on my MM, and I found module MMM-google-route which I want to use for showing the route from my home to my work, but I´m not able to set the coordinates from google.maps.DirectionsRequest interface because of my lack of skills :) Any help would be welcomed.

      Btw, for anyone who want to use the module, there is mistake on github example, its missing , at end of the exaple, its should be

                 {
                  module: 'MMM-google-route',
                  position: 'top_left',
                  config: {
                      key: '<YOUR_KEY>',
                      directionsRequest:{
                          origin: '<ROUTE START>',
                          destination: '<ROUTE FINISH>'
                      }
                  }
              },
      

      code_text

      S 1 Reply Last reply Reply Quote 0
      • S Offline
        sdetweil @Zippyczech
        last edited by sdetweil

        @Zippyczech use the latitude/longitude…

        open google maps, find the location
        in the address bar/location

        for New York, Ny, USA

        maps/place/New+York,+NY/@40.6971478,-74.2605536,
        

        the 2 numbers are the latitude (above/below equator), and longitude (east/west of London, approx)

        use one set for origin and one for destination

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 Reply Last reply Reply Quote 1
        • Z Offline
          Zippyczech
          last edited by

          I´m retarded, of course, it worked. I tried the first time and did some mistake so it didnt work.
          Thank you

          Btw, do you know how to specify that the route should use subway only?

          S 1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil @Zippyczech
            last edited by

            @Zippyczech sorry. Don’t know anything about the module

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 1
            • S Offline
              sdetweil
              last edited by

              Looking at the code, it appears u could change the code to support train

              travelMode: 'DRIVING'
              

              But not thru config altho that would be an easy change I think.

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 1
              • Z Offline
                Zippyczech
                last edited by

                Thank you, again, solved it moments later :) I used https://github.com/jclarke0000/MMM-MyCommute which has better configuration options

                S 1 Reply Last reply Reply Quote 1
                • S Offline
                  sdetweil @Zippyczech
                  last edited by

                  @Zippyczech cool. Thanks for providing feedback.

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 Reply Last reply Reply Quote 0
                  • 1 / 1
                  • First post
                    Last post
                  Enjoying MagicMirror? Please consider a donation!
                  MagicMirror created by Michael Teeuw.
                  Forum managed by Sam, technical setup by Karsten.
                  This forum is using NodeBB as its core | Contributors
                  Contact | Privacy Policy