How to get my Android device GPS location via here-api?
I want to know my current latitude and longitude in order to center the Here-maps to that location. I am using the JavaScript API.
Thank you.
PositioningManager class should be helpful for this. PositioningManager.getPosition() should give you the current position of the device after PositioningManager.start(LocationMethod) is called.
Related
I have 1 input address inside Textbox. How to know if there is a Ocean Port around that address within a radius of 1km? I am using Google Maps API v3. However I found no documentation regarding it.
Any help is worth it. Thank you!
I am working on a GSM based tracking device . i have successfully able to plot the approximate location on google maps using Gmap.net library for windows application and google maps api for android application.I want to mainly do the tracking of the Rail coach .with my current device i gets the approximate location near the railway track.I want to shift that Location /Maker on the near by Rail track.i need help and suggestions on how to achieve this task.please help.
Afaik the gmap.net library does not provide any feature around pinning tracking data, so I guess some manual work might be necessary.
The naive approach is to map your track on your own, google maps etc. is fine. I fact I've used gmap.net once itself to create exactly that.
Then all you need to do is some math (useful key word here is 'shortest path'), to locate the closest matching tracking point and use interpolation to distinguish your anticipated position on the track. You can also add some plausibility checks to speed up the whole process such as "knowing" where on your track you've already been.
I've got experience in real-time tracking for TV events and can go in deeper detail if you want.
I'm developing an asp.net web app and i need to detect the current Geo location and save it to a variable and than show to user its current place name and through this I will guide the user to where he want to go, and than user will in put the destination and I will guide that what the root will be suitable for him and I will provide full detail.
I'm getting its current location but don't how to show to user by displaying on label or in textbox.
I don't know where to start this.
If you are able to access the current geolocation of the user then you need to do the following things-
Get Destination
Now you need to get the destination name from the user using some mode of text input or, speech to text etc.
Geo Code destination
Now you need a good geocoding API to get the coordinate of the destination that user has entered. You can use google's geocoding API. It is available for both client(JavaScript) and server(C#, Java, PHP -etc) side. All you need is an API key.
Find Route
Now you have to find the route between the two coordinates (your current location and destination coordinates). Google provides a direction API for the same. Again you can implement this both on the client or, server side (I will prefer client side to reduce the load on the server end). This API returns a long polyline string which can be decoded into a list of coordinates to plot the route on the map. It also returns a list of maneuver data containing the direction info and road names etc. This maneuver info will help you to direct your user to the destination at the time of navigation.
Plotting the route
Now is the time to add a map canvas to your application and then plot the route to it. You can now use the list of coordinates that you decoded from the polyline to draw a polygon on the map. See this below screenshot from one of my application where I drew the path on the map and also marked all the maneuver points on the path.
Navigation
Well, now you are almost done. Now you can start navigating to the destination. Now use whatever mechanism you use to get the user location periodically and then update it as a marker (you can use a car's icon) on the map and then whenever you reach (calculate the distance) a maneuver point show user the maneuver message like "Turn right"/"Turn left"/"Continue straight for 100 meter" -etc.
If you are stuck with getting the current user's location then you can use HTML5 to get devices location using the network.
Hope this is helpful for you.
I realize that the question is pretty complicated and may require much research. Hope anybody can help me to get useful resources to achieve my goal.
I want to have a Google or Bing map on my ASP.NET 4 application (C#) to display all my logged in users as points on the map.
I understand that this involves five major problems
Get the location of the device (most likely standard laptop with IE9 browser) based on its unique IP address.
Integrate Google or Bing map with ASP.NET or Silverlight application.
Display the right portion of the map with the right Zooming depending on logged-in users locations.
Finally, mark the addresses as points on the map.
Note that the locations points should be dynamically reflected when any of the locations is changed.
The database is implemented using SQL SERVER 2005/2008R2
There are geo location services that can give you the latitude and longitude given an ip address.
As you mention you would be storing these in a database, getting all the current users would be simple database call.
Integrating a google map into a html page is very simple. You would only have to emit the necessary javascript from your page.
You should mark the points on the map first.
Google maps api has calls to fit the map to show all current points(fitBounds). I am guessing bing would have something similar.
To reflect the current points, you would have to fresh your locations from the database. I highly recommend an ajax call that returns json and using that to replot the points.
I'm doing some research on route distance calculation APIs, and I came across this API from Ovi/Nokia: http://api.maps.ovi.com/devguide/getting_started.html#Services
Does anyone know if they have an equivalent REST API that can be used outside of a client browser scenario?
If not, what's the best option for route distance calculation APIs? I've looked into Google, Bing, and MapQuest, but I would like to be able to use it internally without a daily rate limit.
Thanks for your help.
There is the maps image API, if showing the routes as images are sufficient. This page has the complete list if Nokia Maps APIs.
I do not want to repeat what is done, so please refer to the Nokia API reference, but to be more accurate use distance method from nokia.maps.geo.Coordinate. The complete documentation is here
Click here!