|
1 | | -# php-FIT-File-Analysis |
| 1 | +# phpFITFileAnalysis |
2 | 2 |
|
3 | 3 | A PHP class for analysing FIT files created by Garmin GPS devices. |
4 | 4 |
|
5 | | -[Live demonstration](http://www.adriangibbons.com/php-FIT-File-Analysis/demo/) (Right-click and Open in new tab) |
| 5 | +[Live demonstration](http://www.adriangibbons.com/phpFITFileAnalysis/demo/) (Right-click and Open in new tab) |
6 | 6 |
|
7 | 7 | ##Demo Screenshots |
8 | 8 |  |
9 | 9 |  |
10 | 10 |  |
11 | 11 |
|
12 | | -Please read this page in its entirety and the [FAQ](https://github.com/adriangibbons/php-FIT-File-Analysis/wiki/Frequently-Asked-Questions-(FAQ)) first if you have any questions or need support. |
| 12 | +Please read this page in its entirety and the [FAQ](https://github.com/adriangibbons/phpFITFileAnalysis/wiki/Frequently-Asked-Questions-(FAQ)) first if you have any questions or need support. |
13 | 13 |
|
14 | 14 | ##What is a FIT file? |
15 | 15 | FIT or Flexible and Interoperable Data Transfer is a file format used for GPS tracks and routes. It is used by newer Garmin fitness GPS devices, including the Edge and Forerunner series, which are popular with cyclists and runners. |
16 | 16 |
|
17 | 17 | Visit the FAQ page within the Wiki for more information. |
18 | 18 |
|
19 | | -##How do I use php-FIT-File-Analysis with my PHP-driven website? |
| 19 | +##How do I use phpFITFileAnalysis with my PHP-driven website? |
20 | 20 |
|
21 | 21 | Download the class from GitHub and put it somewhere appropriate (e.g. classes/). A conscious effort has been made to keep everything in a single file. |
22 | 22 |
|
23 | 23 | Then include the file on the PHP page where you want to use it and instantiate an object of the class: |
24 | 24 | ```php |
25 | 25 | <?php |
26 | | - include('classes/php-FIT-File-Analysis.php'); |
27 | | - $pFFA = new phpFITFileAnalysis('fit_files/my_fit_file.fit'); |
| 26 | + include('classes/phpFITFileAnalysis.php'); |
| 27 | + $pFFA = new adriangibbons\phpFITFileAnalysis\phpFITFileAnalysis('fit_files/my_fit_file.fit'); |
28 | 28 | ?> |
29 | 29 | ``` |
30 | | -Note two things: |
31 | | - |
32 | | - 1. The PHP class name does not have hyphens. |
33 | | - 2. The only mandatory parameter required when creating an instance is the path to the FIT file that you want to load. |
| 30 | +Note that the only mandatory parameter required when creating an instance is the path to the FIT file that you want to load. |
34 | 31 |
|
35 | 32 | There are more **Optional Parameters** that can be supplied. These are described in more detail further down this page. |
36 | 33 |
|
@@ -295,7 +292,7 @@ $pFFA->critical_power($time_periods); // e.g. 300 or [300, 600, 900, 1200] |
295 | 292 | Note that ```$pFFA->critical_power``` and some power metrics (Normalised Power, Variability Index, Intensity Factor, Training Stress Score) will use the [PHP Trader](http://php.net/manual/en/book.trader.php) extension if it is loaded on the server. If the extension is not loaded then it will use the built-in Simple Moving Average algorithm, which is far less performant particularly for larger files! |
296 | 293 |
|
297 | 294 |
|
298 | | -A demo of power analysis is available [here](http://www.adriangibbons.com/php-FIT-File-Analysis-demo/analysis_power.php). |
| 295 | +A demo of power analysis is available [here](http://www.adriangibbons.com/phpFITFileAnalysis-demo/analysis_power.php). |
299 | 296 |
|
300 | 297 | ##Acknowledgement |
301 | 298 | This class has been created using information available in a Software Development Kit (SDK) made available by ANT ([thisisant.com](http://www.thisisant.com/resources/fit)). |
|
0 commit comments