Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for more manufacturers and lap types #22

Open
wants to merge 176 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
176 commits
Select commit Hold shift + click to select a range
2d122d2
Add support for more manufacturers
jimmykane May 3, 2018
f7f5ff0
Merge remote-tracking branch 'pierremtb/master'
jimmykane May 4, 2018
50b9b21
Compile src
jimmykane May 4, 2018
dcf42a1
Add support for other lap types
jimmykane May 4, 2018
ee4aa00
Compile src
jimmykane May 4, 2018
aacaa04
chore(devices): add forerunner 735 xt
jimmykane Jun 8, 2018
2282c06
Fix readme typo
jim-englert-zocdoc Jun 26, 2018
9aea666
Makes parsing of fit files with developer defined fields possible (#1)
joelso Jul 9, 2018
6fa9258
Merge remote-tracking branch 'FrostDigital/master'
jimmykane Jul 9, 2018
a4b237a
fix missing buffer dependency and compile dst
jimmykane Jul 16, 2018
819d78e
Merge remote-tracking branch 'jenglert/master'
jimmykane Jul 19, 2018
9ed802c
fix: Typo leading to uint16 to never be invalidated
Sep 17, 2018
1ff0fa4
fix: Adjusted offset for all altitude-related fields
Sep 17, 2018
a54b270
fix: Typo leading to uint16 to never be invalidated
Sep 17, 2018
65a4dca
fix: Adjusted offset for all altitude-related fields
Sep 17, 2018
3eef5f7
chore: preparing to release fork internally
Sep 17, 2018
3dd185e
⏩ [PUB] (release) 1.0.0
Sep 17, 2018
be3b336
Merge remote-tracking branch 'JoeTheFkingFrypan/fix/uint16-invalidation'
jimmykane Sep 17, 2018
70b3eb6
fix: Applied to src/fit offset adjustments from commit 9ed802
Sep 18, 2018
2ebd036
⏩ [PUB] (release) 1.0.1
Sep 18, 2018
e7f2017
fix: Applied to src/fit offset adjustments from commit 9ed802
Sep 18, 2018
11ec1d0
Add support for reading sint16, uint16, sint32, uint32, float32 and f…
Oct 9, 2018
656b159
Merge pull request #1 from PolideaInternal/master
jimmykane Oct 13, 2018
0b00497
wip sdk update
dylandevs Nov 21, 2018
cc2af53
adding exercise names
dylandevs Nov 21, 2018
6f97398
Updating SDK and logging some info for research
dylandevs Nov 21, 2018
e311323
typo
dylandevs Nov 21, 2018
be00bb8
typo
dylandevs Nov 22, 2018
7ccc6e2
typo
dylandevs Nov 22, 2018
eb23ff5
Added diving
dylandevs Nov 22, 2018
e7062b0
Added dive definitions
dylandevs Nov 23, 2018
f286f2f
Updated timestamp
dylandevs Nov 24, 2018
ab6822a
Added parsing for new data types
dylandevs Jan 22, 2019
a44e4db
Merge remote-tracking branch 'JoeTheFkingFrypan/master'
jimmykane Jan 25, 2019
ae10fb3
parse hrv
jimmykane Jan 27, 2019
c3077d6
remove
jimmykane Jan 27, 2019
dd66317
kill this as it breaks deps
jimmykane Jan 27, 2019
b6853e0
Merge branch 'master' into updating-fit-sdk
dylandevs Jan 28, 2019
0d4ec23
Added new data types to src
dylandevs Jan 28, 2019
d178ffb
Better support for uintz types and commenting for my sanity
dylandevs Jan 28, 2019
1e9deef
Added garmin descent as a product
dylandevs Jan 28, 2019
0ff932e
return all field descriptions
dpwiese Feb 6, 2019
8fc19ed
Merge remote-tracking branch 'PolideaInternal/return-all-field-descri…
jimmykane Feb 18, 2019
04e85fd
Merge pull request #1 from PolideaInternal/return-all-field-descriptions
Feb 21, 2019
af15fae
Return devices in array instead of single device_info field (#2)
Feb 21, 2019
6f7ea05
Add developer data ids (#3)
Feb 25, 2019
7fbce22
Allow false for force flag
Feb 26, 2019
41ab8fa
Add missing question mark
Feb 26, 2019
0d39634
Merge remote-tracking branch 'PolideaInternal/master'
jimmykane Mar 1, 2019
41b0e17
chore: add support for uint16_array for hrv messages
jimmykane Mar 1, 2019
06f93e6
chore: bump version
jimmykane Mar 1, 2019
e844900
chore: better array support
jimmykane Mar 1, 2019
7e1abcf
chore: bump version
jimmykane Mar 1, 2019
ea9b8eb
chore: release fork as new module for npm
jimmykane Mar 2, 2019
a8ffe12
chore: fixes
jimmykane Mar 2, 2019
85d2ee3
chore: change package name
jimmykane Mar 2, 2019
a9c5c33
Merge remote-tracking branch 'origin/master'
jimmykane Mar 2, 2019
f52ed25
chore: fix npm package
jimmykane Mar 2, 2019
fe0cee3
chore: fix also require
jimmykane Mar 2, 2019
9fcd29a
chore: fix version
jimmykane Mar 2, 2019
57c3bc6
chore: update readme
jimmykane Mar 2, 2019
98740bf
chore: create an activity object
jimmykane Mar 11, 2019
74bf262
fix: typo
jimmykane Mar 11, 2019
81656fe
Merge remote-tracking branch 'Dylan/updating-fit-sdk'
jimmykane Mar 12, 2019
28efc31
chore: bump version
jimmykane Mar 12, 2019
c1b4f6c
fix: readme
jimmykane Mar 17, 2019
3b4f183
Added new fit sdk type
dylandevs Mar 20, 2019
d417ac0
Merge branch 'master' into updating-fit-sdk
dylandevs Mar 20, 2019
11885a6
Rebuilding dist
dylandevs Mar 20, 2019
4e07570
Added multi-gas support
dylandevs Mar 20, 2019
34f7838
Built multi-gas support
dylandevs Mar 20, 2019
b6309c7
Merge pull request #2 from dylandevs/updating-fit-sdk
jimmykane Mar 21, 2019
1b449ee
chore: bump version
jimmykane Mar 21, 2019
043928e
Add `timer_time` field to `record`
nholden Mar 24, 2019
c5b7368
Merge remote-tracking branch 'nholden/master'
jimmykane Mar 30, 2019
8fb0fbd
chore: bump version
jimmykane Mar 30, 2019
b177077
chore: fix developer fields
jimmykane Apr 2, 2019
73b045b
chore: bump version
jimmykane Apr 2, 2019
80cb242
chore: support device type and fix index overrides
jimmykane Apr 18, 2019
1f0f7f7
chore: bump version
jimmykane Apr 18, 2019
257bfba
chore: use numerical index
jimmykane Apr 21, 2019
0c2a2a8
chore: add more session and lap stats
jimmykane Apr 21, 2019
2fac0ea
chore: compile and bump version
jimmykane Apr 21, 2019
9f452c4
Use require 'buffer/' instead of 'buffer'
joecorkerton Jun 2, 2019
7a85223
Merge pull request #3 from joecorkerton/master
jimmykane Jun 2, 2019
288a2af
chore: bump version
jimmykane Jun 2, 2019
eb023da
chore: parse developer fields based on their scale offset etc
jimmykane Jun 5, 2019
f4a6f64
chore: bump version
jimmykane Jun 5, 2019
5b8cada
chore: in case there is an error fallback silently
jimmykane Jun 6, 2019
7ef8282
chore: bump version
jimmykane Jun 6, 2019
43d3bf3
chore: remove debugger
jimmykane Jun 6, 2019
1741053
chore: bump version
jimmykane Jun 6, 2019
713ee4f
chore: try to get the data
jimmykane Jun 6, 2019
eda839c
chore: bump version
jimmykane Jun 6, 2019
7b78fe2
chore: fix vertical speed
jimmykane Jul 26, 2019
6eacf80
fix: fahrenheit
jimmykane Jul 26, 2019
d9772f2
chore: bump version
jimmykane Jul 26, 2019
6631ebf
chore: fix l_r balance and support mask
jimmykane Aug 13, 2019
2d8eee1
chore: add scale and units
jimmykane Aug 13, 2019
5d0ff61
chore: fix stance time balance
jimmykane Aug 29, 2019
e3d6877
fix: vertical_ratio
jimmykane Aug 29, 2019
a17fb45
chore: fix step length scale
jimmykane Aug 29, 2019
2041ed2
chore: fix issue with vertical speed and sint16
jimmykane Sep 2, 2019
68c93fc
store course_points as array rather than just the last one
jamespeek Sep 25, 2019
4ccf94a
Merge pull request #10 from jamespeek/course-points
jimmykane Sep 30, 2019
5baf8a5
chore: bump version
jimmykane Sep 30, 2019
c592628
chore: deps
jimmykane Sep 30, 2019
fed5ee5
chore: add package lock ?
jimmykane Sep 30, 2019
77c15c8
chore: compile binary
jimmykane Sep 30, 2019
ef2ffc3
chore: fix time in zones and support uint32 array data
jimmykane Jan 3, 2020
7af7a22
chore: bump version
jimmykane Jan 3, 2020
2614966
chore: use scale and offset for uint8 as well
jimmykane Jan 8, 2020
15d2be0
chore: bump version
jimmykane Jan 8, 2020
357c1c5
fixed speed conversion to 'mph' (miles per hour)
thomas-gruen Apr 5, 2020
1ef078f
Merge pull request #12 from thomas-gruen/fix-mph
jimmykane Apr 6, 2020
847a05d
chore: compile
jimmykane Apr 6, 2020
88ca0a8
chore: bump version
jimmykane Apr 6, 2020
81c8a16
fix: sports and cascade mode
jimmykane Jul 27, 2020
068107f
chore: bump version
jimmykane Jul 27, 2020
1ab4c95
Revert "chore: bump version "
jimmykane Jul 27, 2020
aa8a366
Revert "fix: sports and cascade mode"
jimmykane Jul 27, 2020
48fe8c4
Revert "Revert "fix: sports and cascade mode""
jimmykane Jul 27, 2020
46fca62
Revert "Revert "chore: bump version ""
jimmykane Jul 27, 2020
d453eb9
chore: support compressed fields
jimmykane Jul 28, 2020
eb3ad9f
chore: add comment
jimmykane Jul 28, 2020
fbeff12
chore: support monitoring and stress messages
jimmykane Jul 28, 2020
15496f0
chore: add monitoring_info
jimmykane Jul 28, 2020
37856fa
chore: compile dist
jimmykane Jul 28, 2020
16aaecb
chore: add definitions
jimmykane Jul 28, 2020
66e218c
chore: definitions build fix
jimmykane Jul 28, 2020
e622d10
chore: bump version
jimmykane Jul 28, 2020
51c1f2b
chore: support lengths for swimming
jimmykane Jul 29, 2020
f23756c
chore: bump version
jimmykane Jul 29, 2020
63c7a91
fix: rename serial_number to device_id
filipekiss Aug 18, 2020
2922bae
Merge pull request #22 from filipekiss/serial_number-device_id
jimmykane Aug 18, 2020
1a33fe5
chore: bump version
jimmykane Aug 18, 2020
fd4a5ca
chore: add forgotten dist
jimmykane Aug 18, 2020
b002184
chore: bump version
jimmykane Aug 18, 2020
d1b1ed2
Revert "Merge pull request #22 from filipekiss/serial_number-device_id"
jimmykane Aug 18, 2020
ff93858
Revert "chore: add forgotten dist"
jimmykane Aug 18, 2020
2133f91
chore: bump version
jimmykane Aug 27, 2020
9becc23
take option name in quotes
andrusha19 Jan 26, 2021
171ebf1
change variable name
andrusha19 Jan 26, 2021
9425b8d
Merge pull request #24 from andrusha19/master
jimmykane Feb 2, 2021
1e0a0bb
Update binary.js
cgack Sep 17, 2021
b57f48a
Merge pull request #29 from cgack/cgack-patch-1
jimmykane Sep 27, 2021
fe9ef3b
support both summary first and last
gie3d Nov 14, 2023
dc5a20c
fixed incorrect logic while map relationship
gie3d Nov 14, 2023
214d7de
fixed incorrect logic
gie3d Nov 14, 2023
b7a5d42
compare time using timestamp rather than ISO date
gie3d Nov 19, 2023
829be9e
added myself into the contributor list
gie3d Nov 19, 2023
99df665
changed the example mode to both
gie3d Nov 19, 2023
a1f9405
Merge pull request #32 from gie3d/support-both-summary-first-and-last
jimmykane Nov 21, 2023
e1a641f
bump version
jimmykane Nov 21, 2023
f1894ee
fixed incorrect parsing lap start_time and the scope of records in se…
gie3d Nov 21, 2023
a5ba5fa
moved lap mapping out of the helper function. So in mode: both can ha…
gie3d Nov 21, 2023
4ced953
use array spreading instead of JSON.parse and stringify to prevent ty…
gie3d Nov 22, 2023
dfbe894
Merge pull request #33 from gie3d/fix-support-both-summary-first-and-…
jimmykane Nov 23, 2023
61ef7bf
Bump version
jimmykane Nov 23, 2023
3c6f524
working on extract tank_update from fit file
gie3d Aug 26, 2024
1ecdd98
added tank_summary
gie3d Aug 27, 2024
a6ce9fb
units
gie3d Aug 27, 2024
518eabb
added test case for diving
gie3d Aug 28, 2024
3c1c5a9
added example
gie3d Aug 28, 2024
27973a4
removed nvmrc
gie3d Aug 28, 2024
442a3a3
added support unit for pressure
gie3d Aug 28, 2024
fab2a0d
change tank_summary to tank_summaries
gie3d Aug 28, 2024
f9db281
Merge pull request #37 from gie3d/features/support-tank-pressure
jimmykane Aug 29, 2024
2a9ba1c
Bump version
jimmykane Aug 29, 2024
6246a81
feat: add new intensity values
michal-grzelak Aug 30, 2024
ccd4d68
fix: fix spelling
michal-grzelak Aug 30, 2024
7d228de
Merge pull request #39 from michal-grzelak/features/lap-intensity
jimmykane Sep 2, 2024
be792c3
Bump version
jimmykane Sep 2, 2024
3595ba7
feat: add new values for session & user profile
Dec 17, 2024
f76c86a
Merge pull request #40 from mbpzn/add-missing-user-profile-fields
jimmykane Jan 2, 2025
22cf22e
Bump version
jimmykane Jan 2, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Change Log

<a name="1.5.4"></a>
## [1.5.4](https://github.com/jimmykane/fit-parser/compare/v1.0.0...v1.5.3) (2019-03-01)
* **Features**: HRV, Developer fields, devices and much more
* **Miscellaneous**: Fix most of the issues parsing fit files

<a name="1.0.1"></a>
## [1.0.1](https://github.com/pierremtb/easy-fit/compare/v1.0.0...v1.0.1) (2018-09-18)


### 😭 Unclassified (not [following convention](https://github.com/sportheroes/bk-conventional-changelog#types-of-commits))

* **Miscellaneous**: fix: Applied to src/fit offset adjustments from commit 9ed802 ([70b3eb6](https://github.com/pierremtb/easy-fit/commit/70b3eb6) - [JoeTheFkingFrypan](https://github.com/JoeTheFkingFrypan))



<a name="1.0.0"></a>
# [1.0.0](https://github.com/pierremtb/easy-fit/compare/0.0.7...1.0.0) (2018-09-17)


### 😭 Unclassified (not [following convention](https://github.com/sportheroes/bk-conventional-changelog#types-of-commits))

* **Miscellaneous**: Fix readme typo ([2282c06](https://github.com/pierremtb/easy-fit/commit/2282c06)))
* **Miscellaneous**: chore: preparing to release fork internally ([3eef5f7](https://github.com/pierremtb/easy-fit/commit/3eef5f7) - [JoeTheFkingFrypan](https://github.com/JoeTheFkingFrypan))
* **Miscellaneous**: fix: Typo leading to uint16 to never be invalidated ([9ed802c](https://github.com/pierremtb/easy-fit/commit/9ed802c) - [JoeTheFkingFrypan](https://github.com/JoeTheFkingFrypan))
* **Miscellaneous**: Merge remote-tracking branch 'jenglert/master' ([819d78e](https://github.com/pierremtb/easy-fit/commit/819d78e)))
* **Miscellaneous**: fix missing buffer dependency and compile dst ([a4b237a](https://github.com/pierremtb/easy-fit/commit/a4b237a)))
* **Miscellaneous**: Merge remote-tracking branch 'FrostDigital/master' ([6fa9258](https://github.com/pierremtb/easy-fit/commit/6fa9258)))
* **Miscellaneous**: Makes parsing of fit files with developer defined fields possible (#1) ([9aea666](https://github.com/pierremtb/easy-fit/commit/9aea666))), closes [#1](https://github.com/pierremtb/easy-fit/issues/1)
* **Miscellaneous**: fix: Adjusted offset for all altitude-related fields ([1ff0fa4](https://github.com/pierremtb/easy-fit/commit/1ff0fa4) - [JoeTheFkingFrypan](https://github.com/JoeTheFkingFrypan))
* **Miscellaneous**: chore(devices): add forerunner 735 xt ([aacaa04](https://github.com/pierremtb/easy-fit/commit/aacaa04)))
* **Miscellaneous**: Compile src ([ee4aa00](https://github.com/pierremtb/easy-fit/commit/ee4aa00)))
* **Miscellaneous**: Add support for other lap types ([dcf42a1](https://github.com/pierremtb/easy-fit/commit/dcf42a1)))
* **Miscellaneous**: Compile src ([50b9b21](https://github.com/pierremtb/easy-fit/commit/50b9b21)))
* **Miscellaneous**: Merge remote-tracking branch 'pierremtb/master' ([f7f5ff0](https://github.com/pierremtb/easy-fit/commit/f7f5ff0)))
* **Miscellaneous**: Add support for more manufacturers ([2d122d2](https://github.com/pierremtb/easy-fit/commit/2d122d2)))
* **Miscellaneous**: Really compiled last changes on binary.js this time, small details on package.json file -> bumped to 0.0.8 ([e5dc98f](https://github.com/pierremtb/easy-fit/commit/e5dc98f)))
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# easy-fit
# fit-file-parser

> Parse your .FIT files easily, directly from JS.
> Written in ES6.
> Written in ES6. (Hope to change)


## Install

```
$ npm install easy-fit --save
$ npm install fit-file-parser --save
```

## How to use
Expand All @@ -16,24 +16,25 @@ See in [examples](./examples) folder:

```javascript
// Require the module
var EasyFit = require('./../dist/easy-fit.js').default;
var FitParser = require('./../dist/fit-file-parser.js').default;

// Read a .FIT file
var fs = require('fs');
fs.readFile('./example.fit', function (err, content) {

// Create a EasyFit instance (options argument is optional)
var easyFit = new EasyFit({
// Create a FitParser instance (options argument is optional)
var fitParser = new FitParser({
force: true,
speedUnit: 'km/h',
lengthUnit: 'km',
temperatureUnit: 'kelvin',
pressureUnit: 'bar', // accept bar, cbar and psi (default is bar)
elapsedRecordField: true,
mode: 'cascade',
});

// Parse your file
easyFit.parse(content, function (error, data) {
fitParser.parse(content, function (error, data) {

// Handle result of parse method
if (error) {
Expand All @@ -48,7 +49,7 @@ fs.readFile('./example.fit', function (err, content) {
```

## API Documentation
### new EasyFit(Object _options_)
### new FitParser(Object _options_)
Needed to create a new instance. _options_ is optional, and is used to customize the returned object.

Allowed properties :
Expand All @@ -63,7 +64,7 @@ Allowed properties :
- `temperatureUnit`: String
- `celsius`:Temperatures are in °C (**default**)
- `kelvin`: Temperatures are in °K
- `farhenheit`: Temperatures are in °F
- `fahrenheit`: Temperatures are in °F
- `speedUnit`: String
- `m/s`: Speeds are in meters per seconds (**default**)
- `km/h`: Speeds are in kilometers per hour
Expand All @@ -72,13 +73,14 @@ Allowed properties :
- `true`: Continues even if they are errors (**default for now**)
- `false`: Stops if an error occurs
- `elapsedRecordField`: Boolean
- `true`: Includes a `elapsed_time` field inside each `record` field, containing the elapsed time in seconds since the first record (**default**)
- `false`
- `true`: Includes `elapsed_time`, containing the elapsed time in seconds since the first record, and `timer_time`, containing the time shown on the device, inside each `record` field
- `false` (**default**)

### easyFit.parse(Buffer _file_, Function _callback_)
### fitParser.parse(Buffer _file_, Function _callback_)
_callback_ receives two arguments, the first as a error String, and the second as Object, result of parsing.

## Contributors
All started thanks to [Pierre Jacquier](https://github.com/pierremtb)

Big thanks to [Mikael Lofjärd](https://github.com/mlofjard) for [his early prototype](https://github.com/mlofjard/jsonfit).
See [CONTRIBUTORS](./CONTRIBUTORS.md).
Expand All @@ -87,4 +89,4 @@ See [CONTRIBUTORS](./CONTRIBUTORS.md).

MIT license; see [LICENSE](./LICENSE).

(c) 2016 by Pierre Jacquier
(c) 2019 Dimitrios Kanellopoulos
Loading