Development stopped: [APP] CellTower2KML [2011-07-20] 1.0

Search This thread

ZuinigeRijder

Retired Recognized Developer
Jun 13, 2008
2,854
208
www.zuinigerijder.com
I did make a conversion program to convert Cell Tower information to actual locations. You can download the version on SourceForge here..

Contents of the zip:
- Cell2KML.exe: Program which converts the input.txt into output.kml
- cells.txt: cache from www.opencellid.org, but in stripped form and with format: id,mcc,mnc,lac,cellid, lat, lon
- cellsNew.txt: will be appended with found locations via internet service of Google Maps with format id,mcc,mnc,lac,cellid, lat, lon
- input.txt: input file in format: datetime,mcc,mnc,lac,cellid
- output.kml: output file suitable for Google Earth, Google Maps or Google Mobile

Some notes:
- Cell2KML.exe works on PC and on Windows Mobile, but on Windows Mobile it is really slow......and progress information is not yet available on Windows Mobile (only a debug log file)
- When location is not in cells.txt or cellsNew.txt, then internet is used for getting the actual location and the positive result is added to cellsNew.txt
- output.kml can be used immediately in Google Earth (if installed on your PC) and Google Mobile Maps by double clicking on the file
- if you want to use the output.kml in Google Maps, then your kml must be public accessible on the internet. You can use a public folder of DropBox or as in my example on SourceForge, e.g.:
<br>
Code:
http://maps.google.com/maps?q=http://touchlockpro.sourceforge.net/CellTower2KML/battclock.kml

BattClock can now monitor the nearest cell tower with your phone using GSM. Why is this interesting?
- This Cell Tower Info can be used for getting an approximate location using several services (Google, OpenCellId, Celldb, location-api)
- No GPS needed! Works on any Windows Mobile phone supported by BattClock!
- If you have a GPS this is more accurate, but also drains battery.
- No internet access needed on your phone, the monitored data can be translated offline to actual locations on a PC with internet access.
- With that you can keep track of where you have been when or which approximate route you did take.
- With triangulation in combination with Tower Signal Strength even more accurate positioning could be computed.
- If you can map the cellid to a approximate Location (Langitude, Longitude) via an offline database, you even do not need internet access.

The input.txt can you be a battclock.csv file, when you only selected to log to file mcc,mnc,lac,cellid, otherwise you must make sure the columns are in the order datetime,mcc,mnc,lac,cellid. Copy your battclock.csv file in the same directory as the Cell2KML.exe program and name it input.txt.

When you convert this Cell Tower Information to kml format, you can show this on Map applications, like Google Earth, Google Maps or an offline Map application which supports kml.
Example kml file here, which opens in Google Maps.




The following information can be monitored (displayed, logged to BattClock.csv file or to registry):
-Mobile Country Code
-Mobile Network Code
-Location Area Code
-Cell ID
-Tower Signal Strength
-Base Station ID (not filled on my Touch Diamond)
-GPRS Cell ID (not seen filled on my Touch Diamond)
-GPRS Base Station ID (not seen filled on my Touch Diamond)

The following registry values can be filled, below HKEY_CURRENT_USER\Software\ZuinigeRijder\Status, so other programs (e.g. MortScript) can react on it:
- MobileCountryCode
- MobileNetworkCode
- LocationAreaCode
- CellId
- TowerSignalStrength
- BaseStationId
- GPRSCellId
- GPRSBaseStationId

For offline converting the Cell Tower Info, you need to enable at least the logging for the following info:
- Mobile Country Code
- Mobile Network Code
- Location Area Code
- Cell ID

The default check time is once per 30 seconds (if one of the items is enabled). You can set the number of seconds via registry key or via BattConfig: "TowerInfoSeconds".
Note that the monitoring does not occur in a deep sleep. At power on after a deep sleep, the monitoring resumes immediately (without the wait of the configured seconds).
 
Last edited:
  • Like
Reactions: Tokl and jdpl@

jdpl@

Senior Member
Sep 20, 2010
516
358
Miami, FL
Hi ZuinigeRijder,

Thank you very much for sharing another great app and keeping WinMo alive.

Best regards.
 

the dragonlord

Senior Member
May 5, 2008
121
1
52
www.thedragonlord.com
Location name on windows mobile?

Hi, would it be possible to use some of the cell feature combined with script or other plugin to display near the operator name or in the taskbar the name (description) of the location where "I am now"? For example if I'm in london to display somewhere "London" (in "nokia style")

Thanks
Andrea
 

ZuinigeRijder

Retired Recognized Developer
Jun 13, 2008
2,854
208
www.zuinigerijder.com
Hi, would it be possible to use some of the cell feature combined with script or other plugin to display near the operator name or in the taskbar the name (description) of the location where "I am now"? For example if I'm in london to display somewhere "London" (in "nokia style")

Thanks
Andrea

Currently I store the RAW data in BattClock:
YYYY-MM-DD HH:MM:SS,MOBILE_COUNTRY_CODE,MOBILE_NETWORK_CODE,LOCATION_AREA_CODE,CELLID

And transform via a local textfile (based on opencellid) to KML or if the Cell id is not in the local textfile, I use google (internet).

So I still only know the coordinates. Via internet (google maps) you can even get the approx. address via the coordinates.

In principle it would be possible to store all this data locally, and have a lookup of the approx. address or City.

But if you have internet on your mobile, even that could be used as fallback.

The question is if you want to use this functionality with or without internet on your phone :confused:

Note that till now, I kept BattClock as simple as possible, but getting this information from a local textfile will be a bit harder (consume more CPU for finding).
 

the dragonlord

Senior Member
May 5, 2008
121
1
52
www.thedragonlord.com
Currently I store the RAW data in BattClock:
YYYY-MM-DD HH:MM:SS,MOBILE_COUNTRY_CODE,MOBILE_NETWORK_CODE,LOCATION_AREA_CODE,CELLID

And transform via a local textfile (based on opencellid) to KML or if the Cell id is not in the local textfile, I use google (internet).

So I still only know the coordinates. Via internet (google maps) you can even get the approx. address via the coordinates.

In principle it would be possible to store all this data locally, and have a lookup of the approx. address or City.

But if you have internet on your mobile, even that could be used as fallback.

The question is if you want to use this functionality with or without internet on your phone :confused:

Note that till now, I kept BattClock as simple as possible, but getting this information from a local textfile will be a bit harder (consume more CPU for finding).
Hi, thanks for the answer! My phone is aways connected to internet...
 

Tokl

Senior Member
Sep 19, 2007
377
76
Heart of BW
For the lazy people here (like me :D),
i have written an small Batch Script to convert automatically the log-file generated by Battclock and start Google Earth :)

1.: You have to "Google Earth" installed on your PC (if not already)
2.: Download and extract ZuinigeRijder´s "CellTower2KML (if not already)
3.: Download, extract and Copy the "Run.bat" into the same folder of CellTower2KML
4.: Place your battclock.csv generated by "BattClock" in the same folder of CellTower2KML (For details what kind of data should/can be logged look at the first Post ;) )
5.: Click on Run.bat

Thats it!
When everything is fine, Google Earth should start and show your Track :D
Of course for your next Tracks you have to do only Step 4 and 5, no more.

Greetz Tokl

P.S.: Maybe Zuinige is packing this batch inside his CellTower2KML.1.0.zip so its provided from start... ;)
 

Attachments

  • Run.zip
    233 bytes · Views: 61
  • Like
Reactions: ZuinigeRijder

Top Liked Posts

  • There are no posts matching your filters.
  • 2
    I did make a conversion program to convert Cell Tower information to actual locations. You can download the version on SourceForge here..

    Contents of the zip:
    - Cell2KML.exe: Program which converts the input.txt into output.kml
    - cells.txt: cache from www.opencellid.org, but in stripped form and with format: id,mcc,mnc,lac,cellid, lat, lon
    - cellsNew.txt: will be appended with found locations via internet service of Google Maps with format id,mcc,mnc,lac,cellid, lat, lon
    - input.txt: input file in format: datetime,mcc,mnc,lac,cellid
    - output.kml: output file suitable for Google Earth, Google Maps or Google Mobile

    Some notes:
    - Cell2KML.exe works on PC and on Windows Mobile, but on Windows Mobile it is really slow......and progress information is not yet available on Windows Mobile (only a debug log file)
    - When location is not in cells.txt or cellsNew.txt, then internet is used for getting the actual location and the positive result is added to cellsNew.txt
    - output.kml can be used immediately in Google Earth (if installed on your PC) and Google Mobile Maps by double clicking on the file
    - if you want to use the output.kml in Google Maps, then your kml must be public accessible on the internet. You can use a public folder of DropBox or as in my example on SourceForge, e.g.:
    <br>
    Code:
    http://maps.google.com/maps?q=http://touchlockpro.sourceforge.net/CellTower2KML/battclock.kml

    BattClock can now monitor the nearest cell tower with your phone using GSM. Why is this interesting?
    - This Cell Tower Info can be used for getting an approximate location using several services (Google, OpenCellId, Celldb, location-api)
    - No GPS needed! Works on any Windows Mobile phone supported by BattClock!
    - If you have a GPS this is more accurate, but also drains battery.
    - No internet access needed on your phone, the monitored data can be translated offline to actual locations on a PC with internet access.
    - With that you can keep track of where you have been when or which approximate route you did take.
    - With triangulation in combination with Tower Signal Strength even more accurate positioning could be computed.
    - If you can map the cellid to a approximate Location (Langitude, Longitude) via an offline database, you even do not need internet access.

    The input.txt can you be a battclock.csv file, when you only selected to log to file mcc,mnc,lac,cellid, otherwise you must make sure the columns are in the order datetime,mcc,mnc,lac,cellid. Copy your battclock.csv file in the same directory as the Cell2KML.exe program and name it input.txt.

    When you convert this Cell Tower Information to kml format, you can show this on Map applications, like Google Earth, Google Maps or an offline Map application which supports kml.
    Example kml file here, which opens in Google Maps.




    The following information can be monitored (displayed, logged to BattClock.csv file or to registry):
    -Mobile Country Code
    -Mobile Network Code
    -Location Area Code
    -Cell ID
    -Tower Signal Strength
    -Base Station ID (not filled on my Touch Diamond)
    -GPRS Cell ID (not seen filled on my Touch Diamond)
    -GPRS Base Station ID (not seen filled on my Touch Diamond)

    The following registry values can be filled, below HKEY_CURRENT_USER\Software\ZuinigeRijder\Status, so other programs (e.g. MortScript) can react on it:
    - MobileCountryCode
    - MobileNetworkCode
    - LocationAreaCode
    - CellId
    - TowerSignalStrength
    - BaseStationId
    - GPRSCellId
    - GPRSBaseStationId

    For offline converting the Cell Tower Info, you need to enable at least the logging for the following info:
    - Mobile Country Code
    - Mobile Network Code
    - Location Area Code
    - Cell ID

    The default check time is once per 30 seconds (if one of the items is enabled). You can set the number of seconds via registry key or via BattConfig: "TowerInfoSeconds".
    Note that the monitoring does not occur in a deep sleep. At power on after a deep sleep, the monitoring resumes immediately (without the wait of the configured seconds).
    1
    For the lazy people here (like me :D),
    i have written an small Batch Script to convert automatically the log-file generated by Battclock and start Google Earth :)

    1.: You have to "Google Earth" installed on your PC (if not already)
    2.: Download and extract ZuinigeRijder´s "CellTower2KML (if not already)
    3.: Download, extract and Copy the "Run.bat" into the same folder of CellTower2KML
    4.: Place your battclock.csv generated by "BattClock" in the same folder of CellTower2KML (For details what kind of data should/can be logged look at the first Post ;) )
    5.: Click on Run.bat

    Thats it!
    When everything is fine, Google Earth should start and show your Track :D
    Of course for your next Tracks you have to do only Step 4 and 5, no more.

    Greetz Tokl

    P.S.: Maybe Zuinige is packing this batch inside his CellTower2KML.1.0.zip so its provided from start... ;)