I'm writing a server side java application that takes location updates from an android device. The device is traveling along a route and I want to be able to determine if it had arrived at its location.
The obvious solution is to define a geo-fence...of the current location of the android device is within this fence then it has arrived at its location.
My question is whether this is possible to do in serverside java. I know there are probably ways to do it with google maps API on the client side but that's not possible for me.
Are there any libraries out there that will provide this functionality?
Thanks in advance
B
Actually, most of these answers don't solve the problem. A geofence is a regular n-gon and the original question isn't trying to determine the distance to a point within the fence (i.e. am I close to a lat/lon) but rather whether or not they are within a box of geometry.
For that, the best answer is to do the following:
http://www.codeproject.com/Articles/62482/A-Simple-Geo-Fencing-Using-Polygon-Method
Related
i'm developing a java desktop application for tracking device like PC,
My code is based on examples giving in https://www.teamdev.com/jxmaps#code
Please how can i get current position
thanks
Unfortunately, current version of JxMaps doesn't provide possibility to get current location. But you can use any third party solution to get coordinates of current position and pass them to LatLng objects.
I am new to android programming and I am trying to create an application that helps me to send a message/post (based on intended location) to those users using the same app in that particular location.
Can i get some resources on this?
Also currently i am trying to implement the feature wherein i post a message about a particular location on my wall and that same message has to seen by the users in that location. How can i implement this.
please post suggestions/open-srouce codes, examples etc.
thank you
You're probably looking for solutions related to the Geo-Fences concept.
There are plenty of applications that can use your mobile coordinates to interact and provide feedback. Notice that the accuracy of the mobile phone GPS is not THAT good, but people can play :-)
Take a look on this application -- https://www.onx.ms/#!landingPage
Official Android docs about geofencing here -- http://developer.android.com/intl/pt-br/training/location/geofencing.html
I'm doing some work for my theses in networking, and have stumbled into a little problem. One of the first steps in the work I must do consists on having a computer working as an AP (I am using hostapd for this) and with it, detect all the devices in the room which currently have wifi turned on (do not need to be associated with any AP).
I have found a thread that pretty much asks the same ( discover mobil devices using wifi ), and I understand the answers that were given, but they don't give any hint as to how this can be done. The post ends saying that the person was able to do this using Kismet, however I can only seem to use Kismet to discover clients already associated with an AP.
Can someone point me in the right direction here please? If not using Kismet, then maybe suggest a different tool that works with Ubuntu.
Ps. I will need to run a continuous scan of the "room" to find any new devices and then send this information to an event manager written in Java.
I guess you could have a WiFi card, in monitor mode, scanning every channel for beacons. On Linux, aircrack-ng is the tool suite you are looking for. airodump-ng is the tool that shows you a list of devices present around your location. It is designed to display first the hotspots with the potentials clients, but also shows all the devices that are connected to an AP or trying to probe to an AP.
However, you won't be able to scan devices having their WiFi connection turned down. I'm not sure about devices not associated to an AP, my guess is you will be able to detect them if they send beacons one way or another (for example, to detect WiFi hotspots).
If you need this in Java, you can write a wrapper to airodump-ng, or you can launch airodump-ng as a service outputing to a file and read this file from a Java app.
No concrete answer I'm afraid, but I hope these will help you figure a way to solve your problem.
I'm in the process of starting a new Android project that will:
Display a Google map
Track and record users movements
Display the route on the map
Show local points on interest on the map
My question is what extra tools will I need to accomplish this? I can already get a basic Google Map working with zoom controls and place overlays etc. but my main concern is how I will track the users movements. I was thinking there maybe some sort of fleet management API but I really have no idea.
A link to some sort of tutorial would be great or even just to possible tools.
Use the class http://developer.android.com/reference/android/location/LocationManager.html to obtain the device geographical location
A Caltrans planning grant went towards creating an Android app called CycleTracks that does all of your bulleted items except the last one about points of interest.
You can download the source code here: http://www.sfcta.org/downloads/cycletracks/CycleTracks-android.zip
I haven't looked at the license to see how free you are to use it as a starting point, but I have to imagine it might be helpful just to be able to look at it even if the license is restrictive.
You can read more about it at http://www.sfcta.org/content/view/666/375.
You don't need any extra tools. Use the GPS or radio cells to get the location of the phone. This thread explains how you can get the location:
How do I get the current GPS location programmatically in Android?
If you want to Track the users movement you'll need to run a webservice on a server and have the app report the location of a user at regular intervals.
Be careful though, if you don't tell the user this is what you are doing, and provide an opt out, you could be pulled from the market pretty quickly.
Be sure you aren't recording any sensitive information as well. Usually position, phone type and OS type is allowed but much more could get you in trouble.
I have been wondering how the iPhone determines location based on wifi, because I want to integrate this functionality into a java app of mine.
When I run a location check on my ip, it throws me all the way into some other neighborhood... But when I use my iPhone's location feature, it points right too me. (and GPS is turned off)
How does the iPhone determine location? Because I know it's not using an ip location.
It uses a wifi access point database. See: http://skyhookwireless.com/ and specifically http://www.skyhookwireless.com/press/skyhookapple.php.
It's using a triangulation scheme based off of known wifi access points. When this was first announced, I heard the name Skyhook Wireless thrown around, so it's possible that the iPhone is using their databases for location.
Cell tower triangulation? It can see the neighbouring GSM antennas and knows the relative signal strengths. This allows a pretty good estimate