Analog Dialogue 44-06, June (2010) 1
Full-Featured Pedometer
Design Realized with 3-Axis
Digital Accelerometer
By Neil Zhao
Introduction
Pedometers, now popular as an everyday exercise progress
monitor and motivator, can encourage individuals to compete with
themselves in getting t and losing weight. Early designs used a
weighted mechanical switch to detect steps, plus a simple counter.
When these devices are shaken, one can hear a metal ball sliding
back and forth, or a pendulum striking stops as it swings.
Today, advanced pedometers rely on microelectromechanical
systems (MEMS) inertial sensors and sophisticated software to
detect true steps with high probability; MEMS inertial sensors
permit more accurate detection of steps and fewer false positives.
Taking advantage of the low cost and minimal space- and power
requirements of MEMS inertial sensors, pedometers are being
integrated into an increasing number of portable consumer
electronic devices—such as music players and mobile phones. The
small, thin, low-power ADXL335, ADXL345, and ADXL346
3-axis accelerometers from Analog Devices are very suitable for
such applications.
This article, based on a study of the characteristics of each step
a person takes, describes a reference design using the 3-axis
ADXL345 accelerometer in a full-featured pedometer that can
recognize and count steps, as well as measure distance, speed,
and—to an extent—calories burned.
The A DXL345’s propr ietar y (patent pending), on-chip, 32-level
rst-in, rst-out (FIFO) buffer can store data and operate on it for
pedometer applications to minimize host processor intervention,
thus saving system power—a big concern for portable devices. Its
13-bit resolution (4 mg/LSB) allows pedometers to even measure
low-speed walking (where each step represents about 55 mg of
acceleration change) with reasonable accuracy.
Understanding the Model
From the characteristics that can be used to analyze running or
walking, we choose acceleration as the relevant parameter. The
three components of motion for an individual (and their related
axes) are forward (roll), vertical ( yaw), and side (pitch), as shown i n
Figure 1. The ADXL345 senses acceleration along its three axes:
x, y, and z. The pedometer will be in an unknown orientation,
www.analog.com/analogdialogue
so the measurement accuracy should not depend critically on the
relationship between the motion axes and the accelerometer’s
measurement axes.
VERTICAL DIRECTION
(YAW-AXIS)
FORWARD
DIRECTION
(ROLL-AXIS)
SIDE DIRECTION
(PITCH-AXIS)
Figure 1. Denition of each axis.
Let’s think about the nature of walking. Figure 2 depicts a single
step, dened as a unit cycle of walking behavior, showing the
relationship between each stage of the walking cycle and the change
in vertical and forward acceleration.
Figure 3 shows a typical pattern of x-, y-, and z- measurements
corresponding to vertical, forward, and side acceleration of a
running person. At least one axis will have relatively large periodic
acceleration changes, no matter how the pedometer is worn, so
peak detection and a dynamic threshold-decision algorithm for
acceleration on all three axes are essential for detecting a unit
cycle of walking or running.
4
–4
–3
–2
–1
0
1
2
3
6138 7161
ACCELERATION (g)
SAMPLE
X-AXIS
Y-AXIS
Z-AXIS
Figure 3. Typical pattern of x-, y-, and z accelerations
measured on a running individual.
VERTICAL
ACCELERATION
FORWARD
ACCELERATION
INCREASED DECREASED
INCREASEDDECREASED
UNIT CYCLE OF WALKING
Figure 2. Walking stages and acceleration pattern.