I have a project to complete and I am searching for some suggestions on how to do this. Basically I need to scan the available HotSpots which I am doing with this code:
JSONArray array = new JSONArray();
for (int i = 0; i < mScanResults.size(); i++){
JSONObject myobj = new JSONObject();
try {
myobj.put("ssid", mScanResults.get(i).SSID);
myobj.put("security", mScanResults.get(i).capabilities);
/*
//here i would like to put the coordinates (lat, lon)
*/
array.put(myobj);
} catch (JSONException e) {
e.printStackTrace();
}
. I searched but I could not find something concrete. I need this because the final goal is to show on the map (using Google Maps API) each hotspot with the relative area of coverage (eventually coloured): Like this: [https://i.stack.imgur.com/xp7nP.png
My idea to achieve this was to collect the coordinates, save them with SQLite and after with Polygons color the area calculated with some maths. Is this approach correct? Please let me know how to do this and thank you for your time.