In discussions with Mark Rages, Mark believes (and the more I think about
it, the more I agree with him) that the way in which we calculate power and
cadence is incorrect.
It isn’t so much in the way that we calculate watts and cadence per se,
but more in how we handle a cyclist _not_ pedaling.
The Inherent Problem with Crank based PM’s
The inherent problem with crank based PM’s is that it is impossible to
know when a user stopped pedaling. Crank based PM’s do not update when they
are not turning. The ANT+ chip does continue to send out data but when the
pedals are not turning, they send out unchanged data.
Right now, the code handles non pedaling with an arbitrary timeout. The
code in git works off 5 seconds. If there are no changes in the ANT message
regarding power/cad in 5 seconds, we assume the user stopped pedaling and
set power and cad to 0.
Garmin does something similar to this as does Cycleops. In the case of
realtime display you do not have much choice. But when the data is recorded,
you do.
The Proposed Solution
Mark believes that the best way to handle this situation is to “peek into
the future”. The idea is as follows:
1) If an ANT power message arrives and there is no change, discard it.
2) If an ANT power message arrives and there is a change, calculate the
average watts from the last time watts was written up to the current time
that the latest change was recorded and write that average.
Example:
10 Second Sample of Watts. Each comma delimited number is 1 second in
time.
What actually happened:
100, 1000, 0, 0, 0, 0, 0, 0, 0, 100
Average = 120
Current implementation of GE’s parser would see:
100, 1000, 1000, 1000, 1000, 1000, 1000, 0, 0, 100
Average = 620 watts
New Proposed Method: (1000+100) / 7) = 157.1
100, 1000, 157.1, 157.1, 157.1, 157.1, 157.1, 157.1, 157.1, 100
Average = 229.97
There is also the possibility of mixing up the solutions. Say anything over 5 seconds with no activity, zero it out. Anything less and use Mark Rages’s method.
The downside with timeouts is that they are arbitrary. The other problem how do you know the cyclist merely didn’t just do 1 rotation over 5 seconds ? Not likely, but possible. But given the chances of this happening, mixing both solutions might be best.
Delane 23:26 on February 10, 2010 Permalink
A-W-E-S-O-M-E!!!
Dave 14:58 on February 18, 2010 Permalink
Will the Ant+ stick read Powertap Ant+ data? Will Golden Cheetah read the data real-time like in your youtube videos for the Quark?
Dave 06:23 on February 19, 2010 Permalink
Can I use this to see my real-time Powertap data?