Show WiGLE-data in Google Earth (WiGLE to KML)
Posted: Sun Mar 23, 2008 10:12 pm
I started an experimental project to fetch and parse WiGLE-data into a KML using Google Earth's "Network Link"-feature.
Requirements:
-PHP5 with SQLite3 support (via PDO)
(code was tested with Server2go)
Download:
here (ca. 1 MiB)
ALL FILES ARE COPYRIGHTED BY ME!
Usage/Remarks:
Put everything on a server meeting the requirements. In Google Earth add a "Network Link" to the wigle.php. On the first use, you'll be asked for a username and password - enter your WiGLE-credentials there. (The project is prepared for multi-user-use.) The PHP will check whether the needed area is already in the SQLite-cache or it will request the data from wigle.net.
For now there's no expiration of cached data. So to force it to reload a specific area, you have to use an SQLite-db-tool (such as SQLite Spy) and manually delete the desired area from the wigleareas table (using a DELETE FROM-statement).
The file CachedWigle.file.class.php is NOT working. It was meant to store everything in separate files but then I decided that SQLite is a bit easier and better to implement.
If you change the class CachedWiGLE in wigle.php to just WiGLE, you'll deactivate caching and all requests will be made directly to the server. But note that the server will block you after some few requests.
The file MAC_OUI.bin contains a MAC-address to company-mapping. You can update it by putting the files iab.txt and oui.txt from the IEEE-homepage into the directory. They will get parsed automatically and the file MAC_OUI.bin will get updated.
Have phun!
Cheers,
-mARKUS
Requirements:
-PHP5 with SQLite3 support (via PDO)
(code was tested with Server2go)
Download:
here (ca. 1 MiB)
ALL FILES ARE COPYRIGHTED BY ME!
Usage/Remarks:
Put everything on a server meeting the requirements. In Google Earth add a "Network Link" to the wigle.php. On the first use, you'll be asked for a username and password - enter your WiGLE-credentials there. (The project is prepared for multi-user-use.) The PHP will check whether the needed area is already in the SQLite-cache or it will request the data from wigle.net.
For now there's no expiration of cached data. So to force it to reload a specific area, you have to use an SQLite-db-tool (such as SQLite Spy) and manually delete the desired area from the wigleareas table (using a DELETE FROM-statement).
The file CachedWigle.file.class.php is NOT working. It was meant to store everything in separate files but then I decided that SQLite is a bit easier and better to implement.
If you change the class CachedWiGLE in wigle.php to just WiGLE, you'll deactivate caching and all requests will be made directly to the server. But note that the server will block you after some few requests.
The file MAC_OUI.bin contains a MAC-address to company-mapping. You can update it by putting the files iab.txt and oui.txt from the IEEE-homepage into the directory. They will get parsed automatically and the file MAC_OUI.bin will get updated.
Have phun!
Cheers,
-mARKUS