-1

i need to come true a function use GPS position to find out the correct GMT time.

i can use GPS position to find out which city we are in now ;

but i can not know how to use timezone ID,eg:Europe/Berlin

to look up the correct UTC offsite value compare with UTC time?

Europe/Berlin should be : GMT+2

Anybody knows that ?

iknow34languages
  • 173
  • 2
  • 12
  • It depends entirely on what tools you are using. It’s good to know 34 languages, it would also be good to know which of them you are using here. :-) In the meantime you may start here: [List of tz database time zones](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones). – Ole V.V. Jul 16 '18 at 12:03
  • 1
    For GPS position to time zone [see this answer](https://stackoverflow.com/a/16086964/634824). For time zone to UTC offset - you will need a point-in-time also, and most languages and platforms have functions for this built-in, or via libraries. – Matt Johnson-Pint Jul 16 '18 at 16:48
  • Europe/Berlin should be +2 at this time of year, but standard time in Berlin is only +1. Which is why you need a point in time, for example. – Ole V.V. Jul 16 '18 at 17:34

1 Answers1

0

i solved it by this way:

1.use "timezone builder" to get time shape file;

2.use tools like ogr2ogr to get geojson from time shape files; coz i use java to look up time zone id;

3.use the open api to look up time zone ID when you input position

iknow34languages
  • 173
  • 2
  • 12