25 February 2019

GPS Week Number Roll Over, 2019 edition

I discovered this detail of GPS raw signal in 2010, when my Garmin Geko 201 showed a wrong date. The guys behind GPS (not Garmin) implemented the transmission of a 10-bit weeks counter value that rolled over in 1999, so that some devices began showing a date that was 1024 weeks behind.

It will happen again at the end April 6th, 2019 (UTC).

(Somehow) The week counter has been upgraded to 13-bit, 157 years (but week #0 is still back in 1980-01-06). Probably most devices using GPS location data built in the last 19 years have a software way to handle the rollover, so you will not be affected. Probably. Hopefully. I know too many lazy developers to be 100% sure all my devices will not be affected.

Unless the device is tested with a fake GPS signal ahead in time, all we can do is to wait for the first full weekend of April 2019.

What's worse, the device might have an embedded lookup table "GPS week vs real week" that is 19.5 years long and would roll over any time in the future. And, in most cases, all these devices are unlikely to get a firmware update.

See you in week #0 :)