1 of 7

Arduino Step Tracker

Chung Shun Ko, Leon Ge

2 of 7

What to achieve

Challenges

  • With Arduino to create a compact and low power consumption device to count step
  • Implement smoothing and filtering algorithm
  • Implement peak detection algorithm
  • Able to reset the count without restarting whole system

  • We designed our own 3d printed case
  • We also had a lot of challenges dealing with data types during the implementation.
  • Fit the data and improve accuracy under constrained resource such as small RAM and processing speed

3 of 7

Technical knowledge

  • We applied the in-class knowledge of step detection by calculating magnitude
  • Since it's almost impossible to run scipy and other libraries, we needed a different algorithm for smoothing and detection.
  • We implemented an simplified version of the Z-score smoothing algorithm.
  • By using a z-score peak detection, we can detect steps in real time.

4 of 7

Implementation

- We used an accelerometer similar to a phone to detect leg movements as well as forward acceleration.

- Using a moving average array to do smoothing. A z-score peak detection will allow for peak detection based on previous values instead of hard coding.

- Based on the z-score plot, we can see that when the is a z-score above 2-2.5 or so, there is a step taken.

- Using the z-score method can accommodate for different intensity of acceleration, instead of hard-coding a magnitude threshold.

5 of 7

Problem Statement

Potential usage of the project

  • Although we have learned to do step detection with pre-recorded data and potentially using phone data, we decided to do a little challenge.
  • We wanted to see if it's possible to do real-time data processing on a small arduino microcontroller to make a step tracker.
  • There may not be a lot of practical application of this project because there are way better step detection algorithms out there, including phones and wearables.
  • This project was done as a learning experience and for fun, and it's also always cool to make hardware stuff.

6 of 7

Summary

  • Result
    • We are able to implement a variation of the z-score smoothing algorithm to combine data smoothing and peak detection.
    • The device is functional and counting steps.
  • Future improvements
    • Dynamically adjust z-score threshold for variation in steps.
    • Improve the smoothing and filtering algorithm to better process accelerometer data, including “fake” steps.
    • Also include activity recognition

7 of 7

References