Add ability to connect to hear rate sensor and post data back to server on workout complete, currently not rendering graphing data

This commit is contained in:
Peter Stockings
2023-05-07 18:15:31 +10:00
parent 5f1a5e6a4a
commit 43e5f66cc1
3 changed files with 138 additions and 6 deletions

View File

@@ -25,6 +25,14 @@ CREATE TABLE
CONSTRAINT unique_cadence_reading_per_workout_time UNIQUE (workout_id, created_at)
);
CREATE TABLE
heartrate_readings (
id SERIAL PRIMARY KEY,
workout_id INTEGER NOT NULL REFERENCES workouts (id) ON DELETE CASCADE,
created_at TIMESTAMP NOT NULL,
bpm INTEGER NOT NULL
);
CREATE TABLE
bikes (
id SERIAL PRIMARY KEY,