Closed srskc closed 6 years ago
Mmh okay, it seems indeed wrong. Didn't use this library for a long time so I don't remember if the time was correct (definitely need to get back into it and improve it). Could you make a pull request?
@pierremtb Pull request sent. Will you be able to push a new version to npm so we don't need to maintain a workaround?
@srskc Sorry I forgot to answer. I'll merge the pull request and push to npm ASAP
easy-fit uses the following code to convert FIT time to unix epoch time:
case 'date_time': return new Date((data * 1000) + 631062000000);
When we read our FIT files, this turns out to be one hour wrong.
The constant 631065600000, as used in the following library, does work: https://github.com/dgaff/fitsdk/blob/master/java/com/garmin/fit/LocalDateTime.java