dvmarinoff / Auuki

Indoor Cycling App for Structured Training
https://auuki.com
GNU Affero General Public License v3.0
565 stars 94 forks source link

add Power Match #92

Open dvmarinoff opened 2 years ago

dvmarinoff commented 2 years ago

Match the controllable ERG target to the power meter output. Possibly by using a dynamic offset.

Things to consider:

MedTechCD commented 2 years ago

Power Match is a challenging thing but I can see that you have a good understanding of where things can go wrong ;-) There are as far as I know three basic situations and 2 of them can be handled quite easily. The third one is very difficult...

  1. The trainer is accurate and stable but the point where power is measured is different resulting in a fixed offset: Power pedals measure drive train power where the trainer isn't for example. To simplify the workout creation and to avoid the need for 2 different FTP's (indoor /outdoor), you could add a setting to specify this fixed offset.
  2. The trainer has a difference that is gradually increasing with the power: you could at a fixed multiplier to correct that situation
  3. The trainer's power is dependent on heat production: most (all) wheel-on trainers have this. When generating more power, the friction tire/roller increases and more heat is produced. That heats up the air in the tire and increases pressure, making the resistance drop because the contact patch between tire and roller slightly decreases. This is really difficult to correct for. There is a big forum thread on it at TrainerRoad for example. They seem to finally have found a satisfying solution. This topic was also discussed on Golden Cheetah and Mark Liversedge came up with some "predicting algorithm". I'm not 100% sure but I think that TrainerRoad found its solution with that. TrainerDay also has a PowerMatch function. It's not as good as TrainerRoad's solution but is helpfull in a lot of cases. For longer steady state intervals, it works pretty good but it fails for short intervals like HIIT workouts for example.

If you could add the first 2 corrections, most people with direct drive trainers will have all they need. The third situation will probably need considerable development time and testing so I really understand that it is not the right time for that at this moment.

TClin76 commented 2 years ago

I always have a question for Power Match in TrainerRoad. Is it still in ERG mode for a smart trainer if APP use the power data from other pairing power meter? In this case, I think APP send resistance command to trainer, rather than target power. Is that correct?

mjunkmyjunk commented 2 years ago

In this case, I think APP send resistance command to trainer, rather than target power. Is that correct?

The app can send 1) target power (using a fixed or dynamic offset to the Pedal Power Meter for eg) 2) A combo of Slope / Wind / Draft and such called "simulation mode" (ala zwift)

TClin76 commented 2 years ago

@dvmarinoff This is something related to the topic of power match, so I write in this thread. Currently when trainer is pairing to FLUX, APP will occupy both power meter and controllable.

Is it possible to separate the pairing procedure for controllable and power meter? Just like what the most APP does. In some cases, I would like to pair power meter and controllable to different APP. (like ROUVY and FLUX in the same time) Thanks

mjunkmyjunk commented 2 years ago

if you're connecting via bluetooth, I don't think this is possible. Or are you on ANT+?

TClin76 commented 2 years ago

@mjunkmyjunk OK ! I see. Both are actually one device, but different profiles. I did it on ANT+ before, but haven’t tried on BLUETOOTH. Thank u for prompt comment

MedTechCD commented 2 years ago

Smart trainers can be paired in two ways: as a Controllable or as a Power source. Power meters obviously only as a Power source. Most Controllables and Power meters have only one BLE channel thus in BLE you can only pair one app to each. If they also have ANT+, you can pair any number of apps/devices in ANT+. Just make sure that only one app/device is controlling the Smart Trainer! For the rest there are lots of possibilities. I have used flux paired to the controllable and the power meter in BLE while my power meter was connected to my Garmin in ANT+. This way you can see on flux what the difference is between both.

mjunkmyjunk commented 2 years ago

https://groups.google.com/g/golden-cheetah-users/c/vpUq4jn587Q/m/6sHmDPEKAgAJ

some discussion there.

z0nt commented 2 weeks ago

I implemented simple PowerMatch functionality which is watching for the average recent power and average power on the interval and makes adjustments up or down depending if averages are too high or too low. It has 4 self explanatory settings which you can change to your taste. I'm pretty happy with the results. The average power is +/- 1 watt on 5 minutes steady state intervals compare to the target. I like that the load slightly changes over time which simulates outdoor experience when you constantly need to change gears which requires small power and cadence adjustments as well.

Let me know if you want to try it yourself or you have any questions.

dvmarinoff commented 2 weeks ago

@z0nt nice, currently I am on the road so I don't have a trainer or a power meter with me, but will take a look when I am back.