This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

FitCSVTool

Hello

I was using the FitCSVTool to convert a .fit file to a .csv file. I was using the tool to look at the contents of an event. When I try to convert the file back to the .fit format I get the following error.

FIT CSV Tool - Protocol 2.0 Profile 21.40 Release

CSVReader.read(): Error on line 6 - Unknown message "unknown".

Exception in thread "main" java.lang.RuntimeException: FIT encoding error.

at com.garmin.fit.csv.CSVTool.run(CSVTool.java:258)

at com.garmin.fit.csv.CSVTool.main(CSVTool.java:332)

Can you please tell me what is generating this error. I am exporting data from a FR35 watch. Thank you.

  • TL;DR converting from FIT to CSV (using FitCSVTool from the FIT SDK) causes data to be lost, so conversion back to FIT isn't possible in general.

    In the FIT file, fields/messages are identified by number. During the conversion to CSV, field numbers are translated to names (e.g. "sport_type"), but field numbers which can't be translated are assigned the name "unknown".

    When you try to convert CSV back to FIT, it's impossible to convert these "unknown" fields, as their original ID numbers have been lost.

    If you want to edit a FIT file, you would have to edit the original FIT (and only convert from FIT to CSV to check your work).