Close

Reading the slope using the MPU

A project log for Adding BLE to a "dumb" treadmill

I have a Gold Gym 410 which is perfect for my purposes. But I always had an itch about tapping into speed and inclination data.

enzo-lombardiEnzo Lombardi 08/24/2022 at 01:430 Comments

Today I spent some time with a trivial task. When you forget to call Wire.begin() bad things happen when you try to use I2C.

Anyway, the code now reads the Y acceleration from the MPU and I built a table of  slope % as function of Y-accel.

The LCD display was helpful in this and I am glad it worked. Now it's time to build a BLE service around this and start publishing values.

Code in github is up to date.

Discussions