TOC | | |
gpswk - Date Conversion to/from the GPS Week
gpswk yr mon day or
gpswk yr DOY or
where DOY = day-of-year and GPSWK is the GPS week number.
gpswk takes a user input date, given as year, month and day or
year and day-of-year, converts to the GPS week number and writes the result
to stdout. Conversely, gpswk will convert a GPS week number to the
year, month and day of the Sunday of that week.
NOTE: GPS week 0 started on January 6, 1980.
gpswk recognizes three input forms
- gpswk yr mon day -> GPSWK
- gpswk yr DOY -> GPSWK
- gpswk GPSWK -> yr mon day
Values returned by the program will be shown in
fixed width font.
- Generate the GPS week number of the week containing a given year, month
- gpswk 97 12 1
- Generate the GPS week number of the week containing a given year
- gpswk 97 335
- Find the GPS week number of the current system date (shell dependent).
- gpswk $(date +"%y %m %d")
TOC | | |
January 14, 2000