Commit Graph

21 Commits

Author SHA1 Message Date
Adrien Guinet
77bbca0a16 ErgFile: fix distance precision issues (#3435)
When parsing a "distance slope wind" type, a truncate to integers was done
after computation to meters. This involved rounding issues that were
accumulated, and were quite visible when such a file was used to synchronized
with an RLV video (the slope changes happened "too early").
2020-06-01 20:53:53 -03:00
Eric Christoffersen
d52fb5a68f Fixes for interpolation and gpx file load
Interpolation math fixes: Slope and interpolation behave correctly when
ride point location doesnt change.
In gpx read: do not open same file twice with different read flags.
2020-05-25 13:34:27 -03:00
peterbrant14
0fab9b901a Fix indexing bugs in the original TTS code (#3423) 2020-04-28 17:45:21 +01:00
ericchristoffersen
426c28b961 Remove CRS_LOC. (#3352) 2020-02-27 15:58:37 +00:00
ericchristoffersen
da3e8212cf Allow TTS Files for VideoSync. (#3354)
Rewrite TTSReader Stream Merge

Add gpi reset.
2020-02-27 15:56:42 +00:00
ericchristoffersen
d755a3a892 Trainmode must honor slope unless ergfile opts out. (#3346) 2020-02-17 08:22:17 +00:00
ericchristoffersen
127166a0e9 Support for TTS files. (#3333)
Support training with Tacx TTS files:

TTS distance and gradient are honored meaning training
load should exactly match tacx. Ride altitude is recomputed
based on distance and gradient, so training work will
match The Tacx Experience and might not match reality.

When TTS file contains no location, altitude is still computed
from distance and gradient but will start from 0.

Gradient during training is interpolated from distance and
altitude so will change smoothly while summing perfectly
to the correct load.

The TTS Reader source was adapted from the WattzApp
Community Edition java source.

Highly recommended that 'Use Simulated Speed' option
is enabled when riding TTS files.

This change was only tested against a small number of
dvds that I own. I would appreciate feedback and problem
reports. I would especially appreciate anyone that can
compare this behavior against Tacx as I only tested with
my Wahoo Kickr.

Issues and Future work:

I guessed about how to set starting distance and might
have got it wrong.

TTS Files contain video synchronization data. Currently
this is ignored and rlv file must be specified. I've not
even looked at the video sync data and no idea if it is
better than the rlv.

There are data fields in the TTS that Ive not investigated
and they might contain useful info, for example a starting
altitude for rides that have no location info.

Other changes:

Fix numerical stability around zero in blinn and quadratic
solvers. Improve quadratic solver accuracy.

Fix issues with computing gradient from non-uniform
cubic splines.

RideFiles now record additional altitude accuracy.
2020-02-13 21:58:31 +00:00
Ale Martinez
48670ff566 Setup Duration, initial sample bracketing and metrics for erg2 files
Parsing is correct, but without this initialization they cannot be executed.
Fixes #3338
2020-02-11 20:56:34 -03:00
ericchristoffersen
9018ad7a28 Use tangent vector to compute interpolated grade.
Use tangent vector to compute interpolated grade.
Implement correct bracket mapping for cubic spline
Case sensitive include file name.

#Fixes #3283
2020-02-02 08:26:21 +00:00
peterbrant14
3f177cae9e Fix truncation of Workouts with respect to pgmf file and corresponding rlv
Add a final point to the ErgFilePoint list to terminate the last section of the ride
2020-01-07 17:48:56 +00:00
ericchristoffersen
2b291f28b7 Issue 3230: Train mode compute altitude from slope (#3231)
Implements #3230
2019-11-27 21:49:13 -03:00
grauser
0e08a7b8bc ErgDB : download from ergdb.org 2019-04-30 22:05:33 +02:00
Eric Christoffersen
1402f6ad6a Ride GPX files in Train View
.. ErgFile now supports gpx format as well as .erg,.mrc et al
.. Location data is include in realtime data and passed through
.. the CSV file format has been fixed to record GPS with higher precision

Fixes #3021
Fixes #3024
2019-02-18 08:01:21 +00:00
Pascal Obry
04b6bab3e5 Minor typo fixes in comment. 2019-01-27 10:25:21 +01:00
Ben Walding
5a065ca07c Add Lap Distance and Lap Distance Remaining dials and telemetry 2018-04-29 14:24:13 +10:00
Mark Liversedge
49d78e6c7b Remove TrainingPeaks Trademarks
.. renaming the 3 metrics they trademarked in 2013:

   TSS => BikeStress
   IF => BikeIntensity
   NP => IsoPower

.. this will break data filters, user formula and
   R and Python charts.

.. in the next commit will add user metrics to ensure
   backward compatibility.
2018-02-17 11:12:50 +00:00
Joern
dba6f6f1af Fix Static Code Check results
... incomplete class initialization
... duplicate if statements
... typos in objects names (copy&paste) (AllPlot)
... missing else (CPPlot)
... missing DELETEs for objects (only if obvious that object is not used somewhere else)
... copy&paste errors (e.g. ModelPlot)
... small floats instead of integer evaluating to 0
... potential SEGV since pointer is not checked for NULL
... misleading code formatting (hard to read) in *zones.cpp
2017-03-23 20:07:09 +01:00
Mark Liversedge
50d269a0e3 MRC Files format fixup
.. MINUTES FTP or MINUTES PERCENT are allowed
2017-01-06 16:30:40 +00:00
Erik Botö
ed99a1f202 Train: Add lap handling to qwkcode 2016-08-08 17:35:33 +02:00
Mark Liversedge
3399a4dc6f Compile time nits
.. cleaning out warnings.
2016-03-06 08:57:24 +00:00
Mark Liversedge
4b5201c4c5 Restructure source directory
Introducing a directory structure to make it a bit less
daunting for new developers and perhaps even old hands.

The main folders all start with an upper character, so src
files are now located in;

* Core - Core data structures
* Gui - Main GUI elements
* Metrics - Models and Metrics
* FileIO - Device and File I/O
* Charts - All the chart types
* Cloud - Working with Web Resources
* Train - Anything Train View specific
* ANT - Our ANT+ Stack
* Resources - Images, Translations, Web etc

Apologies to anyone who needs to merge across this update.
2016-02-25 14:51:53 +00:00