Jump to content
pyth0n3

Locate address

Recommended Posts

d.jpg

59-75 Carson St
Inyo National Forest, June Lake, CA 93529, Statele Unite ale Americii

e.jpg

9 Holmwood Close
Harrow, Greater London HA2 6JX, Regatul Unit al Marii Britanii ?i al Irlandei de Nord

exiftool + google maps.

//

Pot macar sa scriu un program sa-mi extraga coordonatele GPS din fisere? Sau nici macar asa? Pur si simplu hexeditor si manual cu Google maps?

$ exiftool poza.jpg |grep 'GPS Position'

Edited by pr00f
Link to comment
Share on other sites

Pot macar sa scriu un program sa-mi extraga coordonatele GPS din fisiere? Sau nici macar asa? Pur si simplu hexeditor si manual cu Google maps?

[...]

//

$ exiftool poza.jpg |grep 'GPS Position'

pyth0n3 a spus manual sau cred ca a intuit cel putin sa iti scrii tu propriul program si sa inveti sa extragi acele informatii nu mura-n gura cu un tool facut deja de cineva.

Edited by Flubber
Link to comment
Share on other sites

pyth0n3 a spus manual sau cred ca a intuit cel putin sa iti scrii tu propriul program si sa inveti sa extragi acele informatii nu mura-n gura cu un tool facut deja de cineva.

Cum hexedit-ul nu prea m-a ajutat, m-am folosit de exifprobe ca s? g?sesc adresa loca?iei (pentru e.jpg latitudinea este la 0x1316=4886 <- no idea what's this). Am fost la acea adres?, îns? nu am g?sit nimic care m-ar ajuta. O s? citesc mai mult din link-ul pus de tine ?i o s? v?d cam ce rezolv. Totu?i, ce-i cu acel egal de dup? adres? ?

Link to comment
Share on other sites

Cum hexedit-ul nu prea m-a ajutat, m-am folosit de exifprobe ca s? g?sesc adresa loca?iei (pentru e.jpg latitudinea este la 0x1316=4886 <- no idea what's this). Am fost la acea adres?, îns? nu am g?sit nimic care m-ar ajuta. O s? citesc mai mult din link-ul pus de tine ?i o s? v?d cam ce rezolv. Totu?i, ce-i cu acel egal de dup? adres? ?

GRESIT: La offset-ul respectiv s-a gasit acea valoare.

Corect: Este de fapt valoarea in hexa tradusa in baza 10 (decimal). 1316h = 4886d si reprezinta latitudinea calculata.

Din cate am citit eu si ce am inteles, mi-as lua ca reper coordonatele "N" si "W" si dupa acestea as gasi datele, asa cum sunt reprezentate pe wikipedia:



+ [GPS directory with 5 entries]
| 0) GPSVersionID = 2 2 0 0
| - Tag 0x0000 (4 bytes, int8u[4]):
| dump: 02 02 00 00
| 1) GPSLatitudeRef = N
| - [B][COLOR=red]Tag 0x0001 (2 bytes, string[2]):
| dump: 4e 00 [ASCII "N\0"][/COLOR][/B]
| 2) [COLOR=#0000ff][B]GPSLatitude = 57 38 56.83 (57/1 38/1 5683/100)
| - Tag 0x0002 (24 bytes, rational64u[3]):
| dump: 00 00 00 39 00 00 00 01 00 00 00 26 00 00 00 01
| dump: 00 00 16 33 00 00 00 64[/B][/COLOR]
| 3) GPSLongitudeRef = W
| - [B][COLOR=red]Tag 0x0003 (2 bytes, string[2]):
| dump: 57 00 [ASCII "W\0"][/COLOR][/B]
| 4) [COLOR=#0000ff][B]GPSLongitude = 10 24 26.79 (10/1 24/1 2679/100)
| - Tag 0x0004 (24 bytes, rational64u[3]):
| dump: 00 00 00 0a 00 00 00 01 00 00 00 18 00 00 00 01
| dump: 00 00 0a 77 00 00 00 6[/B][/COLOR]

Insa aici sunt in big-endian (primul byte este cel mai semnificativ -- adaugare: adica de la stanga la dreapta se iau octetii si se transforma din hexa in decimal).

Adica, pentru N cu datele din dump-ul respectiv:


>>> data = [39,00,01,00,26,00,01,00,1633,00,64]
>>> for x in data:
... x = int("0x"+str(x), 16)
... print x
...
57
0
1
[B][COLOR=red]57/1[/COLOR][/B]

0

38
0
1
[B][COLOR=red]38/1[/COLOR][/B]

0

5683
0
100
[B][COLOR=red]5683/100[/COLOR][/B]

Astea sunt coordonatele GPS pentru latitudine (cardinalul Nord). Wikipedia ne spune ca ele reprezinta:

GPS Latitude : 57 deg 38' 56.83" N

Asta fiindca:


>>> str(57.0/1.0) + ' ' + str(38.0/1.0) + ' ' + str(5683.0/100.0)
'57.0 38.0 56.83'

Poftim pentru d.jpg:

Cardinalul N (latitudine):


+ 4E 00 N.

Data:

0x24D   00 00  00 02 00 05
00000250 00 00 00 03 00 00 02 9E 00 03 00 02 00 00 00 02

Transformat:

>>> data = [02,00,05,00,03,00,'029E',00,03,00,02,00,02]
>>> for x in data:
... x = int("0x"+str(x),16)
... print x
...
2
0
5
[B][COLOR=red]2/5[/COLOR][/B]

0

3
0
670
[B][COLOR=red]3/670[/COLOR][/B]

0

3
0
2
[B][COLOR=red]3/2[/COLOR][/B]

Cardinalul W (longitudine):


+ 57 00 W.

Data:


0x262 00 00 00 04 00 05 00 00 00 03 00 00 02 B6
00000270 00 05 00 01 00 00 00 01 00 00 00 00 00 06 00 05

Transformat:

>>> for x in data:
... x = int("0x"+str(x), 16)
... print x
...
4
0
5
[B][COLOR=red]4/5[/COLOR][/B]

0

3
0
694
[B][COLOR=red]3/694[/COLOR][/B]

0

5
0
1
[B][COLOR=red]5/1[/COLOR][/B]

N:


>>> str(2.0/5.0) + ' ' + str(3.0/670.0) + ' ' + str(3.0/2.0)
'[B]0.4[/B] [B]0.0044776119403[/B] [B]1.5[/B]'

W:

>>> str(4.0/5.0) + ' ' + str(3.0/694.0) + ' ' + str(5.0/1.0)
'[B]0.8 0.00432276657061 5.0[/B]'

Manual.

Sper sa fie corecte.

Ceea ce nu prea cred, insa:

[B]Output from NADCON for station[/B]


'0.4 0.0044776119403 1.5 0.8 0.00432276657061 5.0'
It must be within one of the following grid areas;
Latitude Longitude
Area Name MIN MAX MIN MAX (degrees)
'Conus ' 20 50 63 131
'Puerto Rico,Vi ' 17 19 64 68
'Stgeorge ' 56 57 169 171
'St Paul ' 57 58 169 171
'St Lawrence ' 62 64 168 172
'Hawaii ' 18 23 154 161
[B][COLOR=red]'Alaska ' 46 77 128 194[/COLOR][/B]

Cu ajutorul lui Google:

http://www.unlimitedchoice.org/blog/creative/9-cracking-shots-taken-with-my-iphone/

Deci d.jpg = June Lake. Am gresit. Oh well...

Edited by Flubber
inca o adaugare
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...