Skip to content

Instantly share code, notes, and snippets.

@waywardone
Last active September 14, 2018 04:03
Show Gist options
  • Save waywardone/fa8cb01462790aa8a26fab97477b80e1 to your computer and use it in GitHub Desktop.
Save waywardone/fa8cb01462790aa8a26fab97477b80e1 to your computer and use it in GitHub Desktop.
Garmin FIT filename decoding
#!/bin/bash
# The following is from the Garmin forums: https://forums.garmin.com/forum/garmin-express/garmin-express-pc/76831-
# The Garmin Forerunner 220 and 620 (FR220 and FR620) save their activity
# files with a cryptic name on the watch. Based on Jeff Pethybridge's
# (ZUKJEFF) analysis and my own findings, these would be the filename codes:
#
# Example: 43S64121.FIT
#
# Char 1 is year: 3 (2013), 4 (2014) ... Will clash in ten years time!
# Char 2 is month: 1-9 and A, B, C (10, 11, 12).
# Char 3 is daynr: 1-9 and A-V (10-31).
# Char 4 is hour: 0-9 and A-N (10-23).
# Chars 5 and 6 are the minutes: 00-59.
# Chars 7 and 8 are the seconds: 00-59.
#
# Above .FIT is 201(4), March (3), the 28:th (S), 6 AM (6), min (41), sec (21)
# and that is when the activity was _started_. In this shell script I pad
# single digit month, daynr and hour with a leading zero. I also retain the
# original codes, thus: 2014-03-28_06-41-21_43S64121.FIT
# Other relevant links
# https://www.dropbox.com/s/16frs902kz17uzg/copy-garmin-fit-files-2018-01-05.bash?dl=0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment