added function getTimeOffset to check if time offset is larger than 15 minutes (automaticaly called every 2min)