U.S. patent application number 15/420105 was filed with the patent office on 2017-05-18 for system and method for detecting transitions between sitting and standing states.
The applicant listed for this patent is Lumo BodyTech, Inc. Invention is credited to Andrew Robert Chang, Andreas Martin Hauenstein.
Application Number | 20170135611 15/420105 |
Document ID | / |
Family ID | 52006040 |
Filed Date | 2017-05-18 |
United States Patent
Application |
20170135611 |
Kind Code |
A1 |
Chang; Andrew Robert ; et
al. |
May 18, 2017 |
SYSTEM AND METHOD FOR DETECTING TRANSITIONS BETWEEN SITTING AND
STANDING STATES
Abstract
A system and method are described herein for detecting a user's
transition between sitting and standing postures. Transitions
between sitting and standing states are reliably detected using an
accelerometer attached to the user. By modeling error introduced by
the accelerometer, and correcting for this error, transitions
between sitting and standing states are reliably detected. A
microprocessor coupled to the accelerometer converts the captured
accelerometer data to approximate vertical acceleration. Vertical
velocity, which includes accelerometer error, is determined from
the approximate vertical acceleration. The vertical velocity is
corrected, and the corrected vertical velocity used to determine
vertical displacement. Transitions between sitting and standing
states are determined from the vertical displacement.
Inventors: |
Chang; Andrew Robert;
(Sunnyvale, CA) ; Hauenstein; Andreas Martin; (San
Mateo, CA) |
|
Applicant: |
Name |
City |
State |
Country |
Type |
Lumo BodyTech, Inc |
Mountain View |
CA |
US |
|
|
Family ID: |
52006040 |
Appl. No.: |
15/420105 |
Filed: |
January 31, 2017 |
Related U.S. Patent Documents
|
|
|
|
|
|
Application
Number |
Filing Date |
Patent Number |
|
|
13912999 |
Jun 7, 2013 |
9591996 |
|
|
15420105 |
|
|
|
|
Current U.S.
Class: |
1/1 |
Current CPC
Class: |
A61B 5/1116 20130101;
A61B 5/6814 20130101; A61B 5/0022 20130101; A61B 5/6822 20130101;
A61B 5/1126 20130101; A61B 5/6823 20130101; G01P 15/18
20130101 |
International
Class: |
A61B 5/11 20060101
A61B005/11; G01P 15/18 20060101 G01P015/18; A61B 5/00 20060101
A61B005/00 |
Claims
1. A method of detecting a user transition between sitting and
standing states comprising: capturing, by a tri-axial accelerometer
attached to a user, a plurality of points of accelerometer data
over a period of time, determining, by a microprocessor, a
plurality of points of approximate vertical acceleration due to
user motion from the plurality of points of accelerometer data,
determining, by the microprocessor, a plurality of points of
vertical velocity from the plurality of points of approximate
vertical acceleration due to user motion, segmenting, by the
microprocessor, the plurality of points of vertical velocity,
correcting, by the microprocessor, each of the segments of points
of vertical velocity, determining, by the microprocessor, a segment
of points of vertical displacement for each corrected segment of
points of vertical velocity, and detecting, by the microprocessor,
a user transition between sitting and standing states from the
segments of points of vertical displacement.
Description
CROSS-REFERENCE TO RELATED APPLICATIONS
[0001] This Application is a continuation of U.S. application Ser.
No. 13/912,999, entitled "SYSTEM AND METHOD FOR DETECTING
TRANSITIONS BETWEEN SITTING AND STANDING STATES", filed 7 Jun.
2013, which is incorporated in its entirety by this reference.
BACKGROUND OF THE INVENTION
[0002] Field of the Invention
[0003] The present invention relates generally to biomechanical
sensors used for biofeedback, to biomechanical sensors that
interface with computing devices, and to detecting transitions
between sitting and standing states using such devices attached to
a user.
[0004] Description of the Prior Art
[0005] Monitoring and tracking posture, postural changes, and
activity of a user presents many challenges. One system for
monitoring and tracking posture, postural changes, and activity
uses a sensor attached to the user to collect data. The sensor
produces a stream of three-dimensional data which is processed by a
microprocessor.
[0006] A challenge in such a system is detecting transitions
between sitting and standing states; the user moving from standing
to sitting, or the user moving from sitting to standing.
Information on whether the user is sitting or standing is needed,
for example, to collect reliable statistics about the time the user
spends sitting versus the time the user spends standing.
Transitions between sitting and standing states must be detected to
collect these statistics.
[0007] One type of sensor attached to the user to detect such
transitions, as well as to track posture, postural changes, and
user activity is an accelerometer which measures acceleration of
the user in three orthogonal axes: y (up and down), z (forward and
backward), and x (side to side). The accelerometer is attached to
the user, for example as a belt attaching the accelerometer along
the spine, a pendant or necklace attaching the accelerometer along
the sternum or chest, or using other means of attaching the
accelerometer to the user's torso, head, or neck. Particularly when
attached to the user along the spine or torso, the accelerometer is
in almost the same orientation when the user is sitting as when the
user is standing.
[0008] This means a transition between sitting and standing states
cannot be detected by simply examining or comparing data from the
accelerometer for example when the user is sitting and when the
user is standing. Rather, the transition must be detected by
analyzing the motion of the user as reported by the accelerometer
during the movement from sitting to standing states, or from
standing to sitting states.
[0009] On initial examination, the problem of detecting transitions
between sitting and standing states using data from an
accelerometer seems simple.
[0010] The output of the accelerometer at any point in time is a
combination of two sets of forces: an acceleration due to gravity,
and an acceleration due to user motion. Since the acceleration due
to gravity is a constant, it should be possible to separate out the
acceleration due to gravity, leaving the acceleration due to user
motion.
[0011] Then, as taught by basic physics, the vertical velocity of
the accelerometer over time is calculated from the acceleration due
to user motion over time, and similarly the vertical distance the
user moved over time is calculated from the vertical velocity over
time. Using the vertical distance the user moved over time to
detect vertical displacement, that is, changes in the up and down y
distance over time, we can detect when the user transitions from
the standing to sitting state, as y goes down a small amount, and
when the user transitions from the sitting to standing state, with
y going up a small amount. Conceptually this process seems
simple.
[0012] But producing vertical distance over time using only data
from an accelerometer in the real world is a problem with many
challenges. One challenge is that accelerometers introduce errors
into the acceleration data, including noise, offset errors, and
scaling errors. These errors change with environmental factors such
as temperature, change over time, and are different with respect to
each axis measured. Errors in the acceleration data are magnified
by the process of converting acceleration to velocity and then to
distance, resulting in errors which increase over time as distance
is determined.
[0013] Another challenge is separating acceleration due to gravity
from acceleration due to user motion. One approach commonly used in
other contexts, known as frequency analysis, is not applicable to
detecting changes from sitting to standing and vice versa.
[0014] Another approach to separating acceleration due to gravity
from acceleration due to user motion is to incorporate additional
data from another type of sensor such as a gyroscope. Data from the
gyroscope is used to compute angular data. This additional angular
data simplifies the process of separating accelerometer data into
acceleration due to gravity and acceleration due to user
motion.
[0015] But gyroscopes introduce their own set of challenges,
including the electrical power needed to run them, and more
important, the computational power required to combine the output
of the gyroscope with the output of the accelerometer. For the
scale of small battery-operated devices meant to be worn
inconspicuously by the user, the amount of computational power
required to incorporate data from a gyroscope is relatively large.
Such amounts of computational power require large amounts of
electrical energy, which means either large batteries, or short
battery life with frequent recharging, neither of which are
desirable in a small, portable, consumer device.
[0016] These challenges introduced by using a gyroscope in addition
to an accelerometer are easily avoided by not using a gyroscope.
But that brings back the problem of detecting transitions between
sitting and standing states using only an accelerometer, with its
inherent sources of error.
[0017] What is needed is a method for detecting transitions between
sitting and standing states, using an accelerometer attached to the
user.
SUMMARY
[0018] In an embodiment is a method of detecting a user transition
between sitting and standing states comprising: capturing, by a
tri-axial accelerometer attached to a user, a plurality of points
of accelerometer data over a period of time, determining, by a
microprocessor, a plurality of points of approximate vertical
acceleration due to user motion from the plurality of points of
accelerometer data over a period of time, determining, by the
microprocessor, a plurality of points of vertical velocity from the
plurality of points of approximate vertical acceleration due to
user motion, segmenting, by the microprocessor, the plurality of
points of vertical velocity, correcting, by the microprocessor,
each of the segments of points of vertical velocity, determining,
by the microprocessor, segments of points of vertical displacement
from the corrected segments of points of vertical velocity, and
detecting, by the microprocessor, a user transition between sitting
and standing states from the segments of points of vertical
displacement.
[0019] In an embodiment the method of segmenting the plurality of
points of vertical velocity comprises: selecting, by the
microprocessor, a first point of the plurality of points of
vertical velocity as a beginning of a segment, and selecting, by
the microprocessor, a second point of the plurality of points of
vertical velocity as an end of the segment, wherein the segment
contains a number of points of the plurality of points of vertical
velocity, and determining that a minimal amount of user motion is
present at the first and second points.
[0020] In an embodiment the method of correcting each of the
segments of points of vertical velocity comprises: determining, by
the microprocessor, a linear error for each of the segments of
points of vertical velocity, and removing, by the microprocessor,
the linear error from each of the segments of points of vertical
velocity.
[0021] In an embodiment the method of determining that a minimal
amount of user motion is present at the first and second points
comprises, for each of the first and second points: setting a
motion threshold to be a first predetermined value if a user motion
at the point is less than a predetermined motion limit, setting the
motion threshold to be a second predetermined value if the user
motion at the point is greater than or equal to the predetermined
motion limit, and determining that a degree of user motion over a
neighboring period of time ending at the point is less than the set
motion threshold.
[0022] In an embodiment is an apparatus for detecting a user
transition between sitting and standing states comprising: a
tri-axial accelerometer attached to a user configured to capture a
plurality of points of accelerometer data over a period of time,
and a microprocessor, coupled to the tri-axial accelerometer, the
microprocessor configured to: determine a plurality of points of
approximate vertical acceleration due to user motion from the
plurality of points of accelerometer data, determine a plurality of
points of vertical velocity from the plurality of points of
approximate vertical acceleration due to user motion, segment the
plurality of points of vertical velocity, correct each of the
segments of points of vertical velocity, determine segments of
points of vertical displacement from the corrected segments of
points of vertical velocity, and detect a user transition between
sitting and standing states from the segments of points of vertical
displacement.
[0023] In an embodiment is an apparatus where the microprocessor is
configured to segment the plurality of points of vertical velocity
by being configured to: select a first point of the plurality of
points of vertical velocity as a beginning of a segment, and select
a second point of the plurality of points of vertical velocity as
an end of the segment, wherein the segment contains a number of
points of the plurality of points of vertical velocity, and
determine that a minimal amount of user motion is present at the
first and second points.
[0024] In an embodiment is an apparatus where the microprocessor is
configured to determine that a minimal amount of user motion is
present at the first and second points by being configured to, for
each of the first and second points: set a motion threshold to be a
first predetermined value if a user motion at the point is less
than a predetermined motion limit, set the motion threshold to be a
second predetermined value if the user motion at the point is
greater than or equal to the predetermined motion limit, and
determine that a degree of user motion over a neighboring period of
time ending at the point is less than the set motion threshold.
[0025] In an embodiment is an apparatus where the microprocessor is
configured to correct the segments of points of vertical velocity
by being configured to: determine a linear error for each segment
of points of vertical velocity, and remove the linear error from
each segment of points of vertical velocity.
[0026] In an embodiment is a non-transitory computer readable
medium having stored thereupon computing instructions comprising: a
code segment to capture from a tri-axial accelerometer attached to
a user a plurality of points of accelerometer data over a period of
time, a code segment to determine a plurality of points of
approximate vertical acceleration due to user motion from the
plurality of points of accelerometer data over a period of time, a
code segment to determine a plurality of points of vertical
velocity from the plurality of points of approximate vertical
acceleration due to user motion, a code segment to segment the
plurality of points of vertical velocity, a code segment to correct
each of the segments of points of vertical velocity, a code segment
to determine segments of points of vertical displacement from the
corrected segments of points of vertical velocity, and a code
segment to detect a user transition between sitting and standing
states from the segments of points of vertical displacement.
[0027] In an embodiment is a non transitory computer readable
medium where the code segment to segment the plurality of points of
vertical velocity further comprises: a code segment to select a
first point of the plurality of points of vertical velocity as a
beginning of a segment, and to select a second point of the
plurality of points of vertical velocity as an end of the segment,
wherein the segment contains a number of points of the plurality of
points of vertical velocity, and determine that a minimal amount of
user motion is present at the first and second points.
[0028] In an embodiment is a non transitory computer readable
medium where the code segment to determine that a minimal amount of
user motion is present at the first and second points further
comprises a code segment to, for each of the first and second
points: set a motion threshold to be a first predetermined value if
a user motion at the point is less than a predetermined motion
limit, set the motion threshold to be a second predetermined value
if the user motion at the point is greater than or equal to the
predetermined motion limit, and determine that a degree of user
motion over a neighboring period of time ending at the point is
less than the set motion threshold.
[0029] In an embodiment is a non-transitory computer readable
medium where the code segment to correct the segments of points of
vertical velocity further comprises: a code segment to determine a
linear error for each segment of points of vertical velocity, and a
code segment to remove the linear error from each segment of points
of vertical velocity.
BRIEF DESCRIPTION OF DRAWINGS
[0030] FIG. 1 is a diagram illustrating user posture in standing
and sitting states.
[0031] FIG. 2 is a block diagram of a sensor device according to an
embodiment.
[0032] FIG. 3 is a flowchart detailing a method of detecting a
transition between sitting and standing states according to an
embodiment.
[0033] FIG. 4 is a flowchart detailing a method of determining
vertical acceleration according to an embodiment.
[0034] FIG. 5 is a graph of determining vertical displacement from
accelerometer data,
[0035] FIG. 6 is a graph of determining vertical displacement from
accelerometer data according to an embodiment.
[0036] FIG. 7 is a flowchart detailing a method of correcting
vertical velocity according to an embodiment.
DETAILED DESCRIPTION OF THE INVENTION
[0037] Presented herein are various embodiments of a sensor device
and methods for using the sensor device to detect a transition
between sitting and standing states.
[0038] The sensor device comprises a tri-axial accelerometer
coupled to a microprocessor which analyzes directional movement
data captured by the accelerometer. When the accelerometer is
attached to a user, the microprocessor analyzes captured
accelerometer data indicative of a user's motion in three
dimensions (x, y, z) in real-time to determine a user's movement
state (e.g., standing, sitting, lying, running, or walking) and to
detect transitions between states, such as detecting transitions
between sitting and standing states.
[0039] To detect a transition between sitting and standing states,
the accelerometer can be attached anywhere on the head or torso of
the user, including but not limited to the head or neck, or on the
torso such as along the spine, or on the chest or abdomen.
[0040] In an embodiment, accelerometer data is captured over time
and processed by the microprocessor coupled to the accelerometer.
The captured accelerometer data is a composite of two forces: an
acceleration due to gravity, and an acceleration due to user
motion. While vertical acceleration due to user motion is difficult
to determine from accelerometer data alone, an approximation can be
used. The magnitude of the accelerometer data is determined; as is
known in the art, this is the square root of the sums of the
squares of the individual x, y, and z acceleration values. The
amount this magnitude differs from the acceleration due to gravity,
the excess magnitude, provides a suitable approximation for
vertical acceleration due to user motion. Thus, an approximate
vertical acceleration due to user motion is determined from the
plurality of points of accelerometer data by determining a
magnitude of each of the plurality of points of accelerometer data,
and subtracting the acceleration due to gravity from the magnitude
of each of the plurality of points of accelerometer data.
[0041] A running estimate of user vertical motion is determined
from the y accelerometer data. This user vertical motion gives an
estimate of the user's motion in the y direction at a point in
time.
[0042] When the user is not moving, the accelerometer data includes
only the acceleration due to gravity, and therefore the magnitude
of the accelerometer data when the user is not moving should equal
the acceleration due to gravity. Therefore, a long-term running
average of the magnitude of each of the plurality of points of
accelerometer data is maintained and this value is used as the
value for the acceleration due to gravity. This long-term running
average may include only magnitude samples when user motion is
minimal, determined by user vertical motion below a threshold.
[0043] Vertical velocity is determined by integrating the
approximate vertical acceleration due to user motion. This vertical
velocity includes a linear error which increases with time. This
linear error in vertical velocity can be determined and
corrected.
[0044] The vertical velocity is segmented, and each of the segments
of points of vertical velocity are corrected by determining a
linear error for each of the segments of points of vertical
velocity, and removing the linear error from each of the segments
of points vertical velocity, thereby determining a corrected
segment of points of vertical velocity for each segment of points
of vertical velocity.
[0045] A segment of points of vertical displacement is determined
for each corrected segment of points of vertical velocity.
[0046] Transitions between sitting and standing states are
determined using the segments of points of vertical displacement.
The vertical displacements at the beginning and end of a segment of
points of vertical displacement are compared and a change in
vertical displacement determined. If the change in vertical
displacement is positive and greater than a predefined limit, a
transition between sitting and standing states has been detected.
If the change in vertical displacement is negative and less than
the predefined limit, a transition between standing and sitting
states has been detected.
[0047] Turning now to FIG. 1, a diagram of a user 100 is shown
standing 100a and sitting 100b in a chair 120. This abbreviated and
schematic form shows user 100's head 102 and spine, divided into
cervical 104, thoracic 106, lumbar 108, and sacral 110 regions as
known in the art. Also illustrated are hips 112, upper legs 114,
lower legs 116, and feet 118. As known in the art, the torso is an
anatomical term referring to the central part of the body from
which extend the neck and limbs. As known in the art, anterior
refers to the front portion of user 100, and posterior refers to
the rear of user 100.
[0048] FIG. 1 shows placement of accelerometer 150 on the user's
chest, which for example could be in the form of a necklace, a
pendant, or a belt or other means securing accelerometer 150 to the
user's chest. In other embodiments, to detect a transition between
sitting and standing states accelerometer 150 may be placed on the
head, neck, or torso, or may be embedded in or attached to clothing
worn by the user.
[0049] FIG. 1 also shows a representation of the axes of motion
sensed by accelerometer 150, with the y axis representing vertical
acceleration and motion up and down, the z axis representing
horizontal acceleration and motion forward and backward, and the x
axis representing horizontal acceleration and motion from side to
side.
[0050] While an ideal orientation of accelerometer 150 on user 100
would have accelerometer 150 positioned such that the vertical y
axis of accelerometer 150 is vertical to the ground, and the
horizontal x and z axes of accelerometer 150 are parallel to the
ground, such is seldom the case. As is illustrated in FIG. 1,
accelerometer 150 as shown is positioned on the chest of user 100
rotated about the x axis.
[0051] This orientation error introduces error into the
accelerometer data. If, for example, accelerometer 150 is sitting
on a flat surface positioned such that the vertical y axis of
accelerometer 150 is vertical to the ground, and the horizontal x
and z axes of accelerometer 150 are parallel to the ground, the
acceleration on the horizontal x and z axes would be zero, and the
acceleration on the vertical y axis would be equal to the
acceleration due to gravity, g. As an example, if accelerometer 150
is rotated about the x axis, the acceleration due to gravity on the
horizontal x axis would still be zero, but the acceleration due to
gravity on the horizontal z axis due to gravity would increase, and
the acceleration due to gravity on the vertical y axis would
decrease. The orientation error is also compounded by the
orientation of the user shifting during motion, for example the
torso shifting position as the user sits or stands. This
orientation error is corrected as described later herein.
[0052] Turning now to FIG. 2, a block diagram of a sensor device
according to an embodiment is shown. Sensor device 200 comprises
tri-axial accelerometer 150, which is coupled to a microprocessor
220. Microprocessor 220 is coupled to memory 230, and to optional
interfaces 240 and 250. In one embodiment, interface 240 is a
wireless interface with antenna 250. Suitable technologies for
wireless interface 240 include but are not limited to IEEE 802.15.1
Bluetooth.RTM. wireless communications, IEEE 802.15 ZigBee.RTM.
wireless communications, or IEEE 802.11 Wi-Fi wireless
communications. Optional interface 250 can be a visible display
such as a light emitting diode (LED) display, organic light
emitting diode (OLED) display, liquid crystal display (LCD), or the
like. Components and subsystems known in the art such as batteries,
charging, and power control are not shown for clarity.
[0053] Suitable accelerometers for tri-axial accelerometer 150 are
produced by companies such as Analog Devices.RTM.,
STMicroelectronics.RTM., Freescale.RTM. Semiconductor, and others.
While these tri-axial accelerometers incorporate three
accelerometers mounted mutually orthogonally in one package, three
separate accelerometers, mounted mutually orthogonally, may also be
used. In an embodiment, a tri-axial accelerometer from
STMicroelectronics is used.
[0054] It should be noted that while the discussions herein make
use of measurements and quantities in meters, meters/sec, meters
sec.sup.2 and so on, accelerometers produce data in their own
reference system. As an example, the LIS3DH tri-axial accelerometer
from STMicroelectronics captures 10-bit accelerometer data with
selectable ranges of .+-.2 g, .+-.4 g, .+-.8 g, or .+-.16 g. As is
known in the art, results of computation using this captured
accelerometer data need only be scaled to familiar units such as
meters and meters/sec when such results are presented to a
user.
[0055] Suitable microprocessors for microprocessor 220 are produced
by Intel.RTM., Texas Instruments.RTM., ARM.RTM. Ltd, NXP.RTM., and
others. In an embodiment a Cortex.RTM. M3 microprocessor from NXP
is used.
[0056] Memory 230 comprises high-speed read-write memory such as
random access memory (RAM) or synchronous dynamic random access
memory (SDRAM) for storing instructions and data during
microprocessor operation, as well as nonvolatile memory such as
electrically erasable programmable read only memory (EEPROM) or
Flash for storing instructions comprising the operating software of
sensor device 200 and its data. It should be noted that memory 230
may be an integral part of microprocessor 220 in a system on a chip
(SOC) design, or may be separate components coupled to
microprocessor 220. In an embodiment, the Cortex M3 microprocessor
includes up to 1 megabyte of non-volatile storage (Flash) and up to
200 thousand bytes of high speed volatile memory (RAM).
[0057] Tri-axial accelerometer 150 may be mounted in the same
enclosure as microprocessor 220, memory 230, and optional
interfaces 240 and 250; or tri-axial accelerometer 150 may be
mounted separately from microprocessor 220, memory 230, and
optional interfaces 240 and 250 and coupled to microprocessor 220
through wired or wireless means known in the art.
[0058] Turning now to FIG. 3, a flowchart detailing a method of
detecting a transition between sitting and standing states
according to an embodiment is shown.
[0059] In step 310, accelerometer data is captured by a tri-axial
accelerometer as a series of points over time. This captured
accelerometer data represents motion of the user to which the
tri-axial accelerometer is attached. In an embodiment, tri-axial
accelerometer 150 captures a plurality of points of accelerometer
data over time as acceleration data x(t), y(t), z(t) at a periodic
sample rate, for example 25 points per second.
[0060] In an embodiment, a running determination of user vertical
motion is performed with each sample of accelerometer data. This
user vertical motion gives an estimate of the user's motion in the
y direction at a point in time.
[0061] Samples of the y-axis accelerometer data are bandpass
filtered over the range 2 to 5 cycles per second (Hertz, Hz). User
vertical motion is determined from this bandpass filtered y-axis
accelerometer data. This determination of user vertical motion is
continuously updated, with each incoming sample of accelerometer
data for the y axis, and provides a measure of user vertical motion
at a point in time. While a Butterworth filter is used in an
embodiment, other filter topologies may also be used.
[0062] In step 320, approximate vertical acceleration is determined
from the captured accelerometer data. The captured accelerometer
data is a composite of two sources of acceleration: the
acceleration due to gravity g, and the acceleration due to user
motion.
[0063] This process of determining approximate vertical
acceleration from accelerometer data is shown in more detail in the
flowchart of FIG. 4.
[0064] Recall that the captured accelerometer data is a composite
of two forces: the acceleration due to gravity, and the
acceleration due to user motion.
[0065] In step 410, a magnitude is determined by the microprocessor
from the captured accelerometer data using the x, y, and z axis
components of acceleration at a time t, x(t), y(t), and z(t):
{square root over (x.sup.2(t)+y.sup.2(t)+z.sup.2(t))}
[0066] By determining the magnitude of the combined horizontal x,
vertical y and the forward-backward z acceleration, this
computation corrects for orientation errors as shown in FIG. 1, as
well as orientation changes for the user leaning forward while
transitioning from sitting to standing states, as the computation
is insensitive to body position changes.
[0067] In step 420, the acceleration due to gravity, g, is
subtracted from this magnitude to determine approximate vertical
acceleration due to user motion a.sub.v(t) at a time t as:
a.sub.v(t).apprxeq. {square root over
(x.sup.2(t)+y.sup.2(t)+z.sup.2(t))}-g
[0068] In an embodiment, rather than treat the acceleration due to
gravity as a constant, the value for the acceleration due to
gravity is instead determined by accelerometer data. Using
accelerometer data to determine the acceleration due to gravity
corrects for certain types of accelerometer error including
accelerometer drift over time. It has been observed that over a
long period of time, the user to whom the accelerometer is attached
is stationary. When the user, and therefore the accelerometer
attached to the user is stationary, the magnitude of the
acceleration (x, y, z) reported by the accelerometer equals the
acceleration due to gravity:
{square root over (x.sup.2+y.sup.2+z.sup.2)}=g when stationary
[0069] Therefore, in an embodiment, a long--term running average of
the magnitude of captured accelerometer data {square root over
(x.sup.2+y.sup.2z.sup.2)} when the user is stationary is maintained
and used as the constant for the acceleration due to gravity.
[0070] Thus, for each point of captured accelerometer data where
the user vertical motion is below a threshold, the running average
value of {tilde over (g)} is determined as:
{tilde over (g)}=a{tilde over (g)}+(1-a) {square root over
(x.sup.2+y.sup.2+z.sup.2)}
where in an embodiment a is approximately 0.999, producing a
gradual shift. In this long-term running average, each new point of
captured accelerometer data only alters the running average {tilde
over (g)} slightly. Periodically, for example once per minute, the
value of g used in determining vertical acceleration due to user
motion from vertical acceleration in step 320 above is updated with
the value of {tilde over (g)} determined in the running
average.
[0071] Returning to FIG. 3, now that approximate vertical
acceleration due to user motion a.sub.v(t) has been determined from
the captured plurality of points of accelerometer data, in step 330
a vertical velocity v.sub.v(t) is determined from the approximate
vertical acceleration due to user motion a.sub.v(t). As understood
from basic physics, the integral of acceleration is velocity. In an
embodiment, numerical integration is used. While many methods of
numerical integration are known to the art and may be used, one
method of numerical integration is to sum the area of rectangles of
height a.sub.v(t) and width .DELTA.t, where .DELTA.t is the time
between samples. The area of such a rectangle is the height times
the width: a.sub.v(t).DELTA.t. By defining .DELTA.t=1, the process
of numerical integration becomes a summing of the approximate
vertical acceleration due to user motion a.sub.v(t) at a time t,
such that
v v ( t ) .apprxeq. i = 0 t a v ( i ) ##EQU00001##
where v.sub.v(t) is the vertical velocity at a time t, and
a.sub.v(i) is the approximate vertical acceleration due to user
motion as determined previously.
[0072] As is known in the art, real world accelerometers have
errors, including but not limited to offset errors, scaling errors,
and non-linearity errors. With a tri-axial accelerometer
incorporating three accelerometers mounted mutually orthogonally in
one package, or an alternate embodiment using three separate
accelerometers mounted mutually orthogonally, these errors are
present for each accelerometer, and are expected to be different
for each axis, and vary with time and environmental conditions such
as temperature.
[0073] In an embodiment, these errors are addressed by being
modeled as a constant which is added to the approximate vertical
acceleration due to user motion. Accordingly, rather than just
integrating vertical acceleration due to user motion to obtain
vertical velocity in step 330, the sum of vertical acceleration due
to user motion, plus an error, is integrated, which produces
vertical velocity plus a linear error that increases with time:
.intg.(a.sub.v(t)+e)dt=.intg.a.sub.v(t)dt+.intg.e
dt=v.sub.v(t)+et
where e represents the error in the vertical acceleration due to
user motion.
[0074] Examining this equation, consider two points in time,
t.sub.1 and t.sub.2 with t.sub.2>t.sub.1. Assume that the values
of velocity at t.sub.1 and t.sub.2 are the same, that is,
v.sub.v(t.sub.2)=v.sub.v(t.sub.1). But from the equation above,
because of the linear error:
v.sub.v(t.sub.2)=v.sub.v(t.sub.1)+e(t.sub.2-t.sub.1)
the linear error e(t.sub.2-t.sub.1) added to the vertical velocity
v.sub.v(t.sub.2) at point t.sub.2.
[0075] The effects of such error is shown in the graph of FIG. 5.
Line 510 shows the approximate acceleration due to user motion a(t)
over time as captured from the accelerometer attached to the user.
Line 520 shows vertical velocity v.sub.v(t) over time, and line 530
shows vertical displacement s.sub.v(t) over time. The horizontal
axis is time in seconds; the vertical axis is vertical displacement
in meters. The effects of error in the approximate acceleration due
to user motion a(t) 510 on vertical velocity v.sub.v(t) are readily
apparent. In the interval from zero to three seconds, for example,
approximate acceleration due to user motion a(t) 510 is close to
zero, yet vertical velocity v.sub.v(t) 520 is drifting negative,
and vertical displacement s.sub.v(t) 530 is going increasingly
negative. A similar error growth is shown in the interval from ten
to twelve seconds, where once again, approximate acceleration due
to user motion a(t) 510 is close to zero, yet vertical velocity
v.sub.v(t) 520 is drifting increasingly negative, and vertical
displacement s.sub.v(t) 530 reaches an alarming value of nearly
negative ten meters.
[0076] The linear error in the vertical velocity can be corrected.
Then, using a corrected vertical velocity to determine a vertical
displacement produces an accurate vertical displacement, which can
be used for detecting transitions between sitting and standing
states.
[0077] The correction process determines this linear error in the
points of vertical velocity and removes it. In the discussion which
follows, reference will be made to the graph of FIG. 6, in which
line 510 again shows the approximate acceleration due to user
motion a(t) over time as captured from a tri-axial accelerometer
attached to the user; this approximate acceleration due to user
motion a(t) 510 is the same data as is used in FIG. 5 and the
accompanying discussion. Line 620 shows corrected vertical velocity
{tilde over (v)}.sub.v(t) over time, and line 630 shows vertical
displacement s.sub.v(t) over time as determined from corrected
vertical velocity {tilde over (v)}.sub.v(t). Segments 640a through
640h shown in the graph as applied to corrected vertical velocity
{tilde over (v)}.sub.v(t) 620 over time, and vertical displacement
s.sub.v(t) 630 over time will be discussed further herein. The
horizontal axis is time in seconds; the vertical axis is vertical
displacement in meters.
[0078] The correction process models the errors in the vertical
velocity v.sub.v(t) as linear in nature. To correct for this linear
error, first the plurality of points of vertical velocity
v.sub.v(t) are segmented, for example, into the segments 640a
through 640h of FIG. 6. Segments of points of vertical velocity
v.sub.v(t) are chosen to include a plurality of points of vertical
velocity v.sub.v(t) in a range of time from a minimum to a maximum,
for example, from one to five seconds in length.
[0079] To understand the correction process, assume beginning and
end points for a segment of points of vertical velocity v.sub.v(t)
have been chosen. When a user motion of a point is close to zero,
the point is considered quiet. When the beginning and end points of
the segment are both quiet, the difference in vertical velocity
between the beginning point and the end point of the segment is the
linear error. A linear equation for a line between the beginning
point and the end point of the segment is determined. The value of
this equation at each point tin the segment is the linear error at
that point. This linear error is subtracted from the vertical
velocity v.sub.v(t) to produce a point of corrected vertical
velocity {tilde over (v)}.sub.v(t).
[0080] In an embodiment, determining that the user motion at a
point is close to zero uses the criteria that the approximate
vertical acceleration due to user motion at the point is close to
zero.
[0081] In another embodiment, determining that the user motion at a
point is close to zero uses the criteria that a bumpiness
neighboring the point is below a threshold determined by user
vertical motion at that point. When the user vertical motion at the
point is below a threshold, a low amount of bumpiness is accepted,
and when the user vertical motion is above the threshold, a higher
amount of bumpiness is accepted.
[0082] Returning to the flowchart of FIG. 3, in step 340, the
plurality of points of vertical velocity are segmented. Beginning
and end points for a segment are chosen, such that:
[0083] the length of the segment from t.sub.1 and t.sub.2 is within
predetermined limits:
.theta.<t.sub.2-t.sub.1<.rho., and
[0084] a minimal amount of user motion is present at the beginning
and end points.
[0085] .theta. and .rho. determine the minimum and maximum length
of a segment, and are selected based on a number of factors such as
the sample rate and expected error. In operation, once beginning
point t.sub.1 is chosen, end point t.sub.2 is chosen initially as
t.sub.2=t.sub.1+.theta.. In an embodiment, the limits set by
minimum and maximum times .theta. and .rho. are equal to .theta.=1
second and .rho.=5 seconds. In terms of points, at a 25 point per
second rate, .theta.=25 points and .rho.=125 points.
[0086] In an embodiment, once the beginning point t.sub.1has been
chosen, points are evaluated starting with the end point at
t.sub.2=t.sub.1+.theta.. The end point for the segment, t.sub.2, is
chosen at a point which meets the criteria described above. In an
embodiment, if an end point t.sub.2 for a segment does not meet the
criteria, a new candidate for t.sub.2 is chosen as
t.sub.2=t.sub.2+one sample, until the limit
t.sub.2>t.sub.1+.rho. is reached, and a new starting point for
t1 is chosen. In alternate embodiments, other increments may also
be used, for example, the next point, or a minimum segment length
of 5 samples.
[0087] In an embodiment, the end point t.sub.2 for the segment just
defined is then used as the starting point t.sub.1 for the next
segment. In such an embodiment, only the new candidate for the end
point of a segment need be tested to meet the criteria that user
motion at the candidate end point is below a threshold.
[0088] Returning to the graph of FIG. 6, the results of this
segmentation process are shown. User motion is determined on a
running basis as described previously herein from y-axis
accelerometer samples. Initial segments 640a and 640b have user
motion as shown by approximate vertical acceleration a.sub.v(t)
510, and uncorrected velocity v.sub.v(t), (as shown in 530 of FIG.
5) close to zero, and are of minimum time .theta. according to the
criteria.
[0089] Examining segment 640d, an end point t.sub.2 meeting the
criteria is not found until the approximately six and one half
second point, as user motion shown by approximate vertical
acceleration a.sub.v(t) 510 does not return to near zero until the
approximately six and one half second point. Segment 640f once more
shows significant approximate vertical acceleration a.sub.v(t) 510,
such that an end point t.sub.2 meeting the criteria is not found
until the approximately ten and a half seconds.
[0090] In an embodiment, the criteria that a minimal amount of user
motion is present at the beginning and end points is determined by
the following criteria:
[0091] vertical acceleration due to user motion at t.sub.1 and
t.sub.2 is close to zero:
a.sub.v(t.sub.1).apprxeq.0 and a.sub.v(t.sub.2).apprxeq.0
[0092] In an embodiment, vertical acceleration due to user motion
a.sub.v(t) is considered close to zero when a.sub.v(t) is less than
a threshold, for example, 0.1 meters/sec.sup.2.
[0093] In another embodiment, the criteria that a minimal amount of
user motion is present at the beginning and end points is instead
determined by evaluating the bumpiness of vertical velocity
v.sub.v(t) in the neighborhood of endpoint t.sub.2. Bumpiness is a
measure of the degree of user motion over a neighboring period of
time ending at the endpoint.
[0094] This bumpiness is defined by constructing a straight line
from a point in the past, v.sub.v(t-.delta.), where .delta.
represents a point in time in the past, for example five seconds in
the past, to the current value of the proposed endpoint
v.sub.v(t.sub.2) to estimate bumpiness in the neighborhood
.epsilon. of t.sub.2. This line, f.sub.t(k), at a point k is
defined by:
f t ( k ) = v v ( t 2 ) - k v v ( t 2 ) - v v ( t 2 - .delta. )
.delta. ##EQU00002##
[0095] In an embodiment, the value of .delta. is chosen to be, for
example five seconds, .delta.=125 points at 25 points per
second.
[0096] Next, bumpiness B(t) at point t.sub.2 is calculated as:
B ( t 2 ) = k = 0 ( v v ( t 2 - k ) f t ( k ) ) 2 ##EQU00003##
where .epsilon. selects points in the recent past, for example 1
second, or .epsilon.=25 points at 25 points per second, and
bumpiness B(t.sub.2) sums the squares of the distances between
vertical velocity points v.sub.v(t) and the point on the line
f.sub.t(k). Thus the bumpiness B(t.sub.2) is a measure of user
motion in the one second interval preceding point t.sub.2.
[0097] If the bumpiness B(t.sub.2) is above a motion threshold,
there cannot be a segment boundary at point t.sub.2. The motion
threshold is determined by the user vertical motion at point
t.sub.2. The motion threshold is set to a first predetermined value
if the user vertical motion at end point t.sub.2 is less than a
predetermined motion limit. The motion threshold is set to a second
predetermined value if the user vertical motion at end point
t.sub.2 is greater than or equal to the predetermined motion limit.
The end point t.sub.2 can be used as a segment boundary if the
bumpiness B(t.sub.2) is not above the motion threshold.
[0098] In an embodiment, the predetermined motion limit is 7.5. The
first predetermined value for the motion threshold is 3 and the
second predetermined value for the motion threshold is 6.75. These
values result from analyzing data captured over a number of sitting
and standing sequences.
[0099] Returning to FIG. 3, in step 350 the segments of vertical
velocity determined in step 340 are corrected for the identified
linear error. This process is shown in greater detail in FIG.
7.
[0100] By modeling the errors in the vertical velocity v.sub.v(t)
as linear in nature as discussed previously herein, the corrected
vertical velocity {tilde over (v)}.sub.v(t.sub.2) at end point
t.sub.2 representing the end of a segment should be the same as the
vertical velocity {tilde over (v)}.sub.v(t.sub.1) at beginning
point t.sub.1 representing the beginning of the segment. In step
710, this linear error is determined by determining a linear
equation for a line between the beginning vertical velocity
v.sub.v(t.sub.1) and ending vertical velocity v.sub.v(t.sub.2) of
the segment. In an embodiment, a slope m for a straight line
between the beginning vertical velocity v.sub.v(t.sub.1) and ending
vertical velocity v.sub.v(t.sub.2) of the segment is calculated
as:
m=(v.sub.v(t.sub.2)-v.sub.v(t.sub.1))/n-1
where n is the number of points in the segment from t.sub.1 to
t.sub.2.
[0101] In step 720, this linear error is removed from each point in
the segment by evaluating the linear equation just determined at a
point t in the segment, and subtracting that value of the linear
equation, which is the linear error, from the vertical velocity
v.sub.v(t) to produce a point of corrected vertical velocity {tilde
over (v)}.sub.v(t). In an embodiment, the corrected vertical
velocity {tilde over (v)}.sub.v(t) for a point t.sub.i in the
interval from t.sub.1 to t.sub.2 is:
{tilde over (v)}.sub.v(t.sub.i)=v.sub.v(t.sub.i)-(im/n-1) for i=0
to n-1
where this is performed for each point, from t.sub.1to t.sub.2, in
the segment of vertical velocity, and for each of the segments of
points of vertical velocity.
[0102] Comparing the graphs of FIG. 5 and FIG. 6, the difference
between vertical velocity v.sub.v(t) 520 and corrected vertical
velocity {tilde over (v)}.sub.v(t) 620 are readily apparent. In the
period from zero to four seconds covering segments 640a, 640b, and
640c, vertical velocity v.sub.v(t) 520 has drifted negative from
zero. In contrast, removing the linear error in each segment 640a
through 640c, as shown in FIG. 6, corrected vertical velocity
{tilde over (v)}.sub.v(t) in these segments remains at zero. The
effect of this correction is also visible in the differences
between vertical velocity v.sub.v(t) 520 and corrected vertical
velocity {tilde over (v)}.sub.v(t) 620 in segments 640d and
640f.
[0103] Returning to FIG. 3, in step 360 vertical displacement
s.sub.v(t) is determined using these corrected segments of points
of vertical velocity {tilde over (v)}.sub.v(t) determined in step
350. A segment of points of vertical displacement s.sub.v(t) is
determined for each corrected segment of points of vertical
velocity {tilde over (v)}.sub.v(t). Once again, this step is
performed using numerical integration of the corrected vertical
velocity {tilde over (v)}.sub.v(t) to determine vertical
displacement s.sub.v(t). In an embodiment, as described previously
herein, by defining .DELTA.t=1, the process of numerical
integration becomes a summing of the corrected vertical velocity
{tilde over (v)}.sub.v(t) such that
s v ( t ) .apprxeq. i = 0 t v ~ v ( i ) ##EQU00004##
where {tilde over (v)}.sub.v(t) is the corrected vertical velocity
at a time i and s.sub.v(t) is the displacement at a time t.
[0104] In step 370, transitions between sitting and standing states
are detected using the segments of points of vertical displacement
s.sub.v(t). For each segment of points of vertical displacement
s.sub.v(t), the vertical displacements of the beginning point of
the segment s.sub.v(t.sub.1) and the end point of the segment
s.sub.v(t.sub.2) are compared. If the difference between
s.sub.v(t.sub.1) and s.sub.v(t.sub.2) is above a lower limit:
r.sub.1<|s.sub.v(t.sub.1)-s.sub.v(t.sub.2)|
where r.sub.1 is the lower limit of the range, then a transition
has been detected. If the vertical displacement
s.sub.v(t.sub.1)-s.sub.v(t.sub.2) is negative, a transition from
standing to sitting has been detected. If the vertical displacement
s.sub.v(t.sub.1)-s.sub.v(t.sub.2) is positive, a transition from
sitting to standing has been detected. In an embodiment, the lower
limit r.sub.1 is approximately 0.25 meters.
[0105] Placing a lower limit on the vertical displacement
distinguishes between standing up, and for example standing on
one's toes. Testing the vertical displacement at the beginning and
end points of segments of points of vertical displacement also
insures that the points at the beginning of the segment and the end
of the segment are quiet; recall that as described previously
herein, a quiet point is one where user motion and vertical
velocity are close to zero.
[0106] Referring again to the graphs of FIG. 5 and FIG. 6, the
effect of the correction mechanism described herein on vertical
displacement and the resulting detection of transitions between
sitting and standing states is illustrated,
[0107] In FIG. 5, vertical displacement s.sub.v(t) 530 drifts more
and more negative. In comparison, in FIG. 6, vertical displacement
s.sub.v(t) 630 based on corrected vertical velocity {tilde over
(v)}.sub.v(t) decreases by approximately one meter in segment 640d;
the user sat down, and a transition between standing and sitting
states is detected. Similarly, in segment 640f, vertical
displacement s.sub.v(t) 630 increases by approximately one meter;
the user stood up, and a transition between sitting and standing
states is detected.
[0108] The disclosed method and apparatus has been explained above
with reference to several embodiments. Other embodiments will be
apparent to those skilled in the art in light of this disclosure.
Certain aspects of the described method and apparatus may readily
be implemented using configurations other than those described in
the embodiments above, or in conjunction with elements other than
those described above. For example, although embodiments of the
sensor device described herein discuss placement of the sensor
device on the front of the torso, the sensor device can be placed
on other parts of the body (e.g., back, head, or neck) as well.
[0109] As an example, while placing the sensor device on an
extremity, such as on the arm, forearm, wrist, hand, leg, ankle, or
foot does not support detecting transitions between sitting and
standing, such sensor placement does allows the described method
and apparatus to reliably determine vertical displacement in these
extremities, such as raising of a hand, arm, leg, or foot.
[0110] Further, it should also be appreciated that the described
method and apparatus can be implemented in numerous ways, including
as a process, an apparatus, or a system. The methods described
herein may be implemented by program instructions for instructing a
processor to perform such methods, and such instructions recorded
on a non-transitory computer readable storage medium such as a hard
disk drive, floppy disk, optical disc such as a compact disc (CD)
or digital versatile disc (DVD), flash memory, etc., or a computer
network wherein the program instructions are sent over optical or
electronic communication links. It should be noted that the order
of the steps of the methods described herein may be altered and
still be within the scope of the disclosure.
[0111] It is to be understood that the examples given are for
illustrative purposes only and may be extended to other
implementations and embodiments with different conventions and
techniques. While a number of embodiments are described, there is
no intent to limit the disclosure to the embodiment(s) disclosed
herein. On the contrary, the intent is to cover all alternatives,
modifications, and equivalents apparent to those familiar with the
art.
[0112] In the foregoing specification, the invention is described
with reference to specific embodiments thereof, but those skilled
in the art will recognize that the invention is not limited
thereto. Various features and aspects of the above-described
invention may be used individually or jointly. Further, the
invention can be utilized in any number of environments and
applications beyond those described herein without departing from
the broader spirit and scope of the specification. The
specification and drawings are, accordingly, to be regarded as
illustrative rather than restrictive. It will be recognized that
the terms "comprising," "including," and "having," as used herein,
are specifically intended to be read as open-ended terms of
art.
* * * * *