bike erg import from C2 log
This commit is contained in:
@@ -205,7 +205,7 @@ def create_c2_stroke_data_db(
|
||||
|
||||
# Saves C2 stroke data to CSV and database
|
||||
def add_c2_stroke_data_db(strokedata,workoutid,starttimeunix,csvfilename,
|
||||
debug=False):
|
||||
debug=False,workouttype='rower'):
|
||||
|
||||
res = make_cumvalues(0.1*strokedata['t'])
|
||||
cum_time = res[0]
|
||||
@@ -246,7 +246,10 @@ def add_c2_stroke_data_db(strokedata,workoutid,starttimeunix,csvfilename,
|
||||
pace = pace.replace(0,300)
|
||||
|
||||
velo = 500./pace
|
||||
if workouttype == 'bike':
|
||||
velo = 1000./pace
|
||||
|
||||
# This may be wrong for the bike erg
|
||||
power = 2.8*velo**3
|
||||
|
||||
# save csv
|
||||
|
||||
Reference in New Issue
Block a user