Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register

   

Java FitToCSV - what am I doing wrong?

Rank

Total Posts: 3

Joined 2017-03-29

PM

Hello,

I tried to convert a .fit file with the FitCSVTool.jar from the Fit SDK by running bash
java -jar FitCSVToll.jar <file.fit

Easy enough it does convert the file into something, but the output doesn't seem quite right. The .csv file contains alot of empty fields and fields containing 'unknown'.
Even after cleaning up the file the result isn't right.
The Timestamp looks something like this
765721583 
which appears to be Unix Epoch?? but after conversion I get a date in 1994 whereas the original activity is from 2015.

The coordinates in the .csv look something like this
position_lat,"349325551",semicircles,position_long,"-1131593019"
in the GPX it looks like this:
<trkpt lat="29.2768200" l>
Atleast here the underlying info seems right since the relationship is:
gpx_coordinates*1.19 *10^~== csv_coordinates 

But I am still not sure what standard I am looking at in the CSV file.

So my quetions: is the .csv file supposed to look like this? What format am I looking at regarding the timestamp and coordinates?

Any directions would be greatly appreciated since I am only a highschool student with very limited programming /data processing experience.

Thanks in advance Julius.
.csv file attached, (cut it off after a few lines so it's not too big)

     

File Attachments

  • file.csv (File Size: 36KB - Downloads: 583)
Rank

Total Posts: 3

Joined 2017-03-29

PM

Ok so I realized that the Fit time is:

Unix-Epoch(activity) - Unix-Epoch(31.december.1989 00:00)

now only the problem with the coordinates remaining...

Did they define the Garmin headquarters as 0°,0° or something? They must really hate standards at Garmin...      
RankRankRank

Total Posts: 68

Joined 0

PM

Coordinates are stored using semicircles, checkout http://gis.stackexchange.com/questions/156887/conversion-between-semicircles-and-latitude-units for a description on how to convert to degrees if you need.      
Rank

Total Posts: 3

Joined 2017-03-29

PM

Thanks alot Caufield! I Guess I have to take the last sentence back, nothing weird about that!