[go: up one dir, main page]

TWI640751B - Step counting method - Google Patents

Step counting method Download PDF

Info

Publication number
TWI640751B
TWI640751B TW106119177A TW106119177A TWI640751B TW I640751 B TWI640751 B TW I640751B TW 106119177 A TW106119177 A TW 106119177A TW 106119177 A TW106119177 A TW 106119177A TW I640751 B TWI640751 B TW I640751B
Authority
TW
Taiwan
Prior art keywords
value
peak
gravity
gravity value
current
Prior art date
Application number
TW106119177A
Other languages
Chinese (zh)
Other versions
TW201903359A (en
Inventor
黃煜傑
陳俊傑
李正軒
Original Assignee
研鼎智能股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 研鼎智能股份有限公司 filed Critical 研鼎智能股份有限公司
Priority to TW106119177A priority Critical patent/TWI640751B/en
Application granted granted Critical
Publication of TWI640751B publication Critical patent/TWI640751B/en
Publication of TW201903359A publication Critical patent/TW201903359A/en

Links

Landscapes

  • Telephone Function (AREA)

Abstract

一種計步方法,一電子裝置感測一使用者於一當前單位時間的動作,以獲得一當前重力值,並根據所儲存的一偏差強度值及一偏差變異度值計算出用於決定該當前重力值對應的峰谷狀態的一第一門檻值及一第二門檻值,且判定一前一重力值與該當前重力值對應的峰谷狀態是否不同,當不同時,該電子裝置判定所儲存的重力值資料是否存在有一重力值符合一判定條件,當符合時,該電子裝置儲存該當前重力值,並將所儲存的計步資訊的一步數進行累加,且根據所儲存的重力值更新該偏差變異度值及該偏差強度值,並刪除該當前重力值以外的重力值。A step counting method, an electronic device senses a user's action at a current unit time to obtain a current gravity value, and calculates a current value according to the stored deviation intensity value and a deviation variability value for determining the current a first threshold value and a second threshold value of the peak-to-valley state corresponding to the gravity value, and determining whether the peak-to-valley state corresponding to the current gravity value is different when the previous gravity value is different, and when not different, the electronic device determines to store Whether the gravity value data has a gravity value conforming to a determination condition, when the object meets, the electronic device stores the current gravity value, and accumulates one step of the stored step information, and updates the step according to the stored gravity value. The deviation variability value and the deviation intensity value, and delete the gravity value other than the current gravity value.

Description

計步方法Step counting method

本發明是有關於一種計步方法,特別是指一種由一包含一三軸加速度計的電子裝置來實施的計步方法。The present invention relates to a step counting method, and more particularly to a step counting method implemented by an electronic device including a three-axis accelerometer.

在越來越注重運動的社會中,智慧型裝置中的計步功能已漸趨重要,智慧型裝置中的計步功能用於計算使用者的行走步數,幫助使用者隨時掌握自身運動狀況,使用者可從這些數據制定一個完整的運動計劃。其中步數計算的精準度尤為重要,若步數精準度低會影響使用者的運動計劃。In a society that pays more and more attention to sports, the step counting function in smart devices has become more and more important. The step counting function in smart devices is used to calculate the number of walking steps of users, and helps users to grasp their own movements at any time. Users can develop a complete exercise plan from these data. The accuracy of the step calculation is particularly important. If the accuracy of the steps is low, the user's exercise plan will be affected.

然而,現有的計步方法容易受到外部因素的干擾導致計步不準確,例如使用者將智慧型裝置放在口袋裡行走或者使用者配戴智慧型裝置,會有不同的計步結果。而使用者運動狀態發生變換時亦會導致計步不準確,例如使用者跑步與走路擺動的幅度不同,若是以相同判斷基準,會使計步不準確。However, the existing step counting method is easily interfered by external factors, resulting in inaccurate step counting. For example, if the user walks the smart device in the pocket or the user wears the smart device, there will be different step results. When the user's exercise state changes, it will also lead to inaccurate step counting. For example, the amplitude of the user's running and walking swing is different. If the same judgment criterion is used, the step counting will be inaccurate.

因此,如何解決因外部因素的干擾或是使用者運動狀態發生變換而導致計步不準確,遂成為亟待解決的問題。Therefore, how to solve the problem of inaccurate counting due to the interference of external factors or the change of the user's motion state becomes an urgent problem to be solved.

因此,本發明的目的,即在提供一種更精準的計步方法。Accordingly, it is an object of the present invention to provide a more accurate step counting method.

於是,本發明計步方法,由一包含一三軸加速度計的電子裝置來實施,用來持續感測一使用者的移動以獲得相關於每一單位時間的三軸加速度值的重力值,每一重力值對應一峰谷狀態,該峰谷狀態包含一波峰狀態及一波谷狀態,該電子裝置包含一第一儲存區及一第二儲存區,該第一儲存區儲存有一偏差強度值、一相關於該偏差強度值的偏差變異度值及包含一步數的計步資訊,該第二儲存區用於儲存相關於該使用者之移動所獲得之重力值的重力值資料,該計步方法包含以下步驟:Thus, the step counting method of the present invention is implemented by an electronic device including a three-axis accelerometer for continuously sensing a user's movement to obtain a gravity value associated with a triaxial acceleration value per unit time, each A gravity value corresponds to a peak-to-valley state, the peak-and-valley state includes a peak state and a valley state, the electronic device includes a first storage area and a second storage area, the first storage area stores a deviation intensity value, and a correlation a deviation variability value of the deviation intensity value and a step information including a step number, wherein the second storage area is configured to store gravity value data related to a gravity value obtained by the movement of the user, and the step counting method includes the following step:

(A)感測該使用者於一當前單位時間的動作,以獲得一相關於該當前單位時間的三軸加速度值的一當前重力值;(A) sensing the user's action at a current unit time to obtain a current gravity value associated with the triaxial acceleration value of the current unit time;

(B)根據該偏差強度值及該偏差變異度值計算出一第一門檻值及一第二門檻值;(B) calculating a first threshold value and a second threshold value according to the deviation intensity value and the deviation variability value;

(C)根據該第一門檻值及該第二門檻值決定該當前重力值對應的峰谷狀態;(C) determining a peak-to-valley state corresponding to the current gravity value according to the first threshold value and the second threshold value;

(D)判定一相關於從前一單位時間所獲得的前一重力值對應的峰谷狀態是否不同於該當前重力值對應的峰谷狀態;(D) determining whether a peak-to-valley state corresponding to a previous gravity value obtained from a previous unit time is different from a peak-valley state corresponding to the current gravity value;

(E)當判定出該前一重力值對應的峰谷狀態不同於該當前重力值對應的峰谷狀態時,判定該第二儲存區所儲存的重力值資料是否存在有一重力值符合一相關於該當前重力值的判定條件;(E) determining that the peak-to-valley state corresponding to the previous gravity value is different from the peak-valley state corresponding to the current gravity value, determining whether the gravity value data stored in the second storage area has a gravity value consistent with a correlation a determination condition of the current gravity value;

(F)當判定出該第二儲存區所儲存的重力值資料存在有一重力值符合該判定條件時,儲存該當前重力值至該第二儲存區,並將該計步資訊的該步數進行累加;及(F) when it is determined that the gravity value data stored in the second storage area has a gravity value meeting the determination condition, storing the current gravity value to the second storage area, and performing the step of the step information Accumulate; and

(G)根據該第二儲存區所儲存的重力值更新該偏差變異度值及該偏差強度值,並刪除該當前重力值以外的重力值。(G) updating the deviation variability value and the deviation intensity value according to the gravity value stored in the second storage area, and deleting the gravity value other than the current gravity value.

本發明之功效在於:藉由該電子裝置感測該使用者於該當前單位時間的動作獲得的該當前重力值,並根據該當前重力判定是否更新該偏差變異度值及該偏差強度值,藉此,當使用者以不同的方式配戴該電子裝置或是運動狀態發生變換時,該電子裝置能即時調整計步的判定基準(即該第一門檻值及該第二門檻值),以提高計步的準確度。The effect of the present invention is that the electronic device senses the current gravity value obtained by the user at the current unit time, and determines whether to update the deviation variability value and the deviation intensity value according to the current gravity. Therefore, when the user wears the electronic device in a different manner or the motion state changes, the electronic device can instantly adjust the judgment criterion of the step (ie, the first threshold value and the second threshold value) to improve The accuracy of the step.

參閱圖1,說明用來實施本發明計步方法之一實施例的一電子裝置100包含一感測單元11、一儲存單元12,及一電連接該感測單元11及該儲存單元12的處理單元13。Referring to FIG. 1 , an electronic device 100 for implementing an embodiment of the step counting method of the present invention includes a sensing unit 11 , a storage unit 12 , and a processing for electrically connecting the sensing unit 11 and the storage unit 12 . Unit 13.

該感測單元11用來持續感測一使用者的移動以獲得相關於每一單位時間的三軸加速度值的重力值,每一重力值對應一峰谷狀態,該峰谷狀態包含一波峰狀態及一波谷狀態。在本實施例中,該感測單元11例如為一三軸加速度計(3-Axis-Accelerometer)。The sensing unit 11 is configured to continuously sense a movement of a user to obtain a gravity value related to a triaxial acceleration value per unit time, and each gravity value corresponds to a peak-to-valley state, the peak-valley state including a peak state and A trough state. In the embodiment, the sensing unit 11 is, for example, a 3-Axis-Accelerometer.

該儲存單元12包含一第一儲存區121及一第二儲存區122,該第一儲存區121儲存有一偏差強度值、一相關於該偏差強度值的偏差變異度值、包含一步數的計步資訊、一計數值,及一狀態旗標,該狀態旗標的一旗標值是一指示出一相關於該感測單元11從前一單位時間所獲得的前一重力值對應的峰谷狀態為該波峰狀態的第一預定值、及一異於該第一預定值並指示出該前一重力值對應的峰谷狀態為該波谷狀態的一第二預定值,該第二儲存區122用於儲存相關於該感測單元11感測該使用者之移動所獲得之重力值的重力值資料。The storage unit 12 includes a first storage area 121 and a second storage area 122. The first storage area 121 stores a deviation intensity value, a deviation variability value related to the deviation intensity value, and a step number including one step. Information, a count value, and a status flag, the flag value of the status flag is a flag indicating a peak-to-valley state corresponding to the previous gravity value obtained by the sensing unit 11 from the previous unit time. a first predetermined value of the peak state, and a peak-to-valley state different from the first predetermined value and indicating the previous gravity value is a second predetermined value of the valley state, and the second storage area 122 is configured to store The gravity value data related to the gravity value obtained by the sensing unit 11 sensing the movement of the user.

參閱圖1、圖2、圖3,示例說明了該電子裝置100如何實施本發明計步方法的該實施例。Referring to Figures 1, 2 and 3, an example of how the electronic device 100 implements the step counting method of the present invention is illustrated.

在步驟201中,該感測單元11感測該使用者於一當前單位時間的動作,以獲得一相關於該當前單位時間的三軸加速度值的一當前重力值。在本實施例中,該當前重力值例如為該三軸加速度值的強度純量(三軸加速度值平方和的平方根)。In step 201, the sensing unit 11 senses the action of the user at a current unit time to obtain a current gravity value related to the triaxial acceleration value of the current unit time. In the present embodiment, the current gravity value is, for example, the intensity scalar of the triaxial acceleration value (the square root of the sum of the squares of the triaxial acceleration values).

在步驟202中,該處理單元13根據該偏差強度值及該偏差變異度值計算出一第一門檻值及一第二門檻值,該第一門檻值為該偏差強度值加上二分之一該偏差變異值再加上該偏差變異值與一第一變數的乘積,該第一門檻值係以下式表示: 第一門檻值=偏差強度值+(偏差變異值×0.5)+第一變數×偏差變異值。 該第二門檻值為該偏差強度值加上二分之一該偏差變異值再減去該偏差變異值與一第二變數的乘積,該第二門檻值係以下式表示: 第二門檻值=偏差強度值+(偏差變異值*0.5)-第二變數×偏差變異值。In step 202, the processing unit 13 calculates a first threshold value and a second threshold value according to the deviation intensity value and the deviation variability value, and the first threshold value is the deviation intensity value plus one-half The deviation variation value is further added to the product of the deviation variation value and a first variable, and the first threshold value is expressed by the following formula: First threshold value = deviation intensity value + (deviation variation value × 0.5) + first variable × Deviation variation value. The second threshold value is the deviation intensity value plus one-half of the deviation variation value and then the product of the deviation variation value and a second variable, the second threshold value is expressed by the following formula: The second threshold value = Deviation intensity value + (deviation variation value * 0.5) - second variable × deviation variation value.

在步驟203中,該處理單元13根據該第一門檻值及該第二門檻值決定該當前重力值對應的峰谷狀態,當該當前重力值大於該第一門檻值時,該處理單元13決定該當前重力值對應的峰谷狀態為該波峰狀態,當該當前重力值小於該第二門檻值時,該處理單元13決定該當前重力值對應的峰谷狀態為該波谷狀態,當該當前重力值小於等於該第一門檻值且大於等於該第二門檻值時,該處理單元13決定該當前重力值對應的峰谷狀態為該前一重力值對應的峰谷狀態。In step 203, the processing unit 13 determines a peak-to-valley state corresponding to the current gravity value according to the first threshold value and the second threshold value, and when the current gravity value is greater than the first threshold value, the processing unit 13 determines The peak-to-valley state corresponding to the current gravity value is the peak state. When the current gravity value is less than the second threshold value, the processing unit 13 determines that the peak-to-valley state corresponding to the current gravity value is the valley state, when the current gravity When the value is less than or equal to the first threshold and greater than or equal to the second threshold, the processing unit 13 determines that the peak-to-valley state corresponding to the current gravity value is the peak-to-valley state corresponding to the previous gravity value.

在步驟204中,該處理單元13將該計數值進行累加,在本實施例中,該處理單元13例如將該計數值加一。要特別注意的是,在本實施例中,步驟204是在步驟203之後執行,但在其它實施例中,步驟204可以與步驟201、步驟202、步驟203同時執行,或在步驟201、步驟202、步驟203之前執行。In step 204, the processing unit 13 accumulates the count value. In the present embodiment, the processing unit 13 increments the count value by one, for example. It is to be noted that, in this embodiment, step 204 is performed after step 203, but in other embodiments, step 204 may be performed simultaneously with step 201, step 202, step 203, or in step 201, step 202. Executed before step 203.

在步驟205中,該處理單元13判定該第二儲存區122是否儲存有任何重力值。若該判定結果為肯定時,該流程進行步驟207,否則,該流程進行步驟206。In step 205, the processing unit 13 determines whether the second storage area 122 stores any gravity value. If the result of the determination is affirmative, the flow proceeds to step 207. Otherwise, the flow proceeds to step 206.

在步驟206中,當該處理單元13於步驟205判定出該第二儲存區122不儲存有任何重力值時,該處理單元13儲存該當前重力值,並根據對應該當前重力值對應的峰谷狀態更新該第一儲存區121的該狀態旗標的該旗標值,當在步驟203中決定出該當前重力值對應的峰谷狀態為該波峰狀態時,該狀態旗標的該旗標值被更新為該第一預定值,而當在步驟203中決定出該當前重力值對應的峰谷狀態為該波谷狀態時,該狀態旗標的該旗標值被更新為該第二預定值。In step 206, when the processing unit 13 determines in step 205 that the second storage area 122 does not store any gravity value, the processing unit 13 stores the current gravity value and according to the peak and valley corresponding to the current gravity value. The state updates the flag value of the status flag of the first storage area 121. When it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the peak state, the flag value of the status flag is updated. For the first predetermined value, when it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the trough state, the flag value of the state flag is updated to the second predetermined value.

在步驟207中,當該處理單元13於步驟205判定出該第二儲存區122儲存有重力值時,該處理單元13根據該狀態旗標的該旗標值判定該前一重力值對應的峰谷狀態是否不同於該當前重力值對應的峰谷狀態,亦即當在步驟203中決定出該當前重力值對應的峰谷狀態為該波峰狀態時,該處理單元13判定該狀態旗標的該旗標值是否為該第二預定值,而當在步驟203中決定出該當前重力值對應的峰谷狀態為該波谷狀態時,該處理單元13判定該狀態旗標的該旗標值是否為該第一預定值。若該判定結果為肯定時,該流程進行步驟211,否則,該流程進行步驟208。In step 207, when the processing unit 13 determines in step 205 that the second storage area 122 stores the gravity value, the processing unit 13 determines the peak and valley corresponding to the previous gravity value according to the flag value of the status flag. Whether the state is different from the peak-to-valley state corresponding to the current gravity value, that is, when it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the peak state, the processing unit 13 determines the flag of the state flag. Whether the value is the second predetermined value, and when it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the trough state, the processing unit 13 determines whether the flag value of the status flag is the first Predetermined value. If the result of the determination is affirmative, the flow proceeds to step 211. Otherwise, the flow proceeds to step 208.

在步驟208中,當該處理單元13於步驟207判定出該前一重力值對應的峰谷狀態相同於該當前重力值對應的峰谷狀態時,該處理單元13判定該當前重力值是否大於該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值或小於該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值。若該判定結果為肯定時,該流程進行步驟209,否則,該流程進行步驟210。In step 208, when the processing unit 13 determines in step 207 that the peak-to-valley state corresponding to the previous gravity value is the same as the peak-valley state corresponding to the current gravity value, the processing unit 13 determines whether the current gravity value is greater than the The peak-to-valley state stored in the second storage area 122 is the maximum value of the gravity values of the peak state or less than the minimum value among the gravity values stored in the second storage area 122. If the result of the determination is affirmative, the flow proceeds to step 209; otherwise, the flow proceeds to step 210.

在步驟209中,當該處理單元13於步驟208判定出該當前重力值大於該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值或小於該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值時,該處理單元13儲存該當前重力值至該儲存單元12的該第二儲存區122。在本實施例中,當該當前重力值大於該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值時,該處理單元13將該當前重力值取代該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值,而當前重力值小於該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值時,該處理單元13將該當前重力值取代該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值。In step 209, when the processing unit 13 determines in step 208 that the current gravity value is greater than the maximum value of the peak value of the peak state stored in the second storage area 122 or less than the second storage area When the stored peak-to-valley state is the minimum of the gravity values of the trough state, the processing unit 13 stores the current gravity value to the second storage region 122 of the storage unit 12. In this embodiment, when the current gravity value is greater than the maximum value of the peak value stored in the second storage area 122 as the peak value of the peak state, the processing unit 13 replaces the current gravity value with the second The peak-to-valley state stored in the storage area 122 is the maximum value of the gravity values of the peak state, and the current gravity value is less than the minimum value among the gravity values stored in the second storage area 122. The processing unit 13 replaces the current gravity value with the peak-to-valley state stored in the second storage area 122 as the minimum value of the gravity values of the trough state.

在步驟210中,在步驟209之後或當該處理單元13於步驟208判定出該當前重力值小於等於該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值且大於等於該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值時,該處理單元13將該偏差變異度值減去一第三預定值,以更新該第一儲存區121的該偏差變異度值,且將該偏差強度值減去一第四預定值,以更新該第一儲存區121的該偏差強度值。值得注意的是,在本實施例中,當該偏差變異度值減少到一第一下限值時不再減少,且當該偏差強度值減少到一第二下限值時亦不再減少。In step 210, after step 209 or when the processing unit 13 determines in step 208 that the current gravity value is less than or equal to the peak value stored in the second storage area 122 is the maximum value of the gravity value of the peak state and When the peak-to-valley state stored in the second storage area 122 is the minimum value of the gravity values of the trough state, the processing unit 13 subtracts the deviation variability value by a third predetermined value to update the first The deviation variability value of the storage area 121 is subtracted from the deviation intensity value by a fourth predetermined value to update the deviation intensity value of the first storage area 121. It should be noted that, in this embodiment, when the deviation variability value is reduced to a first lower limit value, it is no longer reduced, and when the deviation intensity value is decreased to a second lower limit value, it is no longer reduced.

在步驟211中,當該處理單元13於步驟207判定出該前一重力值對應的峰谷狀態不同於該當前重力值對應的峰谷狀態時,該處理單元13更新該第一儲存區121的該狀態旗標的該旗標值,亦即當在步驟203中決定出該當前重力值對應的峰谷狀態為該波峰狀態時,該處理單元13更新該第一儲存區121的該狀態旗標的該旗標值為該第一預定值,而當在步驟203中決定出該當前重力值對應的峰谷狀態為該波谷狀態時,該處理單元13更新該第一儲存區121的該狀態旗標的該旗標值為該第二預定值,並判定該第二儲存區122所儲存的重力值資料是否存在有一重力值符合一相關於該當前重力值的判定條件,該判定條件為該第二儲存區122所儲存的重力值資料中的該重力值的峰谷狀態與該當前重力值之峰谷狀態相同。若該判定結果為肯定時,該流程進行步驟213,否則,該流程進行步驟212。In step 211, when the processing unit 13 determines in step 207 that the peak-to-valley state corresponding to the previous gravity value is different from the peak-to-valley state corresponding to the current gravity value, the processing unit 13 updates the first storage area 121. The flag value of the status flag, that is, when it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the peak state, the processing unit 13 updates the state flag of the first storage area 121. The flag value is the first predetermined value, and when it is determined in step 203 that the peak-to-valley state corresponding to the current gravity value is the trough state, the processing unit 13 updates the state flag of the first storage area 121. The flag value is the second predetermined value, and it is determined whether the gravity value data stored in the second storage area 122 has a gravity value conforming to a determination condition related to the current gravity value, and the determination condition is the second storage area. The peak-to-valley state of the gravity value in the stored gravity value data of 122 is the same as the peak-valley state of the current gravity value. If the result of the determination is affirmative, the flow proceeds to step 213. Otherwise, the flow proceeds to step 212.

在步驟212中,當該處理單元13於步驟211判定出該第二儲存區122所儲存的重力值資料不存在有一重力值符合該判定條件時,該處理單元13儲存該當前重力值至該第二儲存區122,並根據該第二儲存區122所儲存的重力值資料更新該第一儲存區121的該偏差變異度值及該偏差強度值。In step 212, when the processing unit 13 determines in step 211 that the gravity value data stored in the second storage area 122 does not have a gravity value that meets the determination condition, the processing unit 13 stores the current gravity value to the first The storage area 122 is updated, and the deviation variability value and the deviation intensity value of the first storage area 121 are updated according to the gravity value data stored in the second storage area 122.

在步驟213中,當該處理單元13於步驟211判定出該第二儲存區122所儲存的重力值資料存在有一重力值符合該判定條件時,該處理單元13判定該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值及該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值之差是否大於一第五預定值,且該第一儲存區121所儲存的該計數值是否大於一第六預定值。若該判定結果為肯定時,該流程進行步驟215,否則,該流程進行步驟214。In step 213, when the processing unit 13 determines in step 211 that the gravity value stored in the second storage area 122 has a gravity value that meets the determination condition, the processing unit 13 determines that the second storage area 122 is stored. The peak-to-valley state is a maximum value of the gravity values of the peak state and a peak-to-valley state stored in the second storage region 122 is a difference between the minimum values of the gravity values of the valley state is greater than a fifth predetermined value, and Whether the count value stored in the first storage area 121 is greater than a sixth predetermined value. If the result of the determination is affirmative, the flow proceeds to step 215; otherwise, the flow proceeds to step 214.

在步驟214中,當該處理單元13於步驟213判定出該第二儲存區122所儲存的之峰谷狀態為該波峰狀態的重力值中的最大值及該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值之差小於等於該第五預定值,或該計數值小於等於該第六預定值時,該處理單元13根據對應該前一重力值對應的峰谷狀態更新該第一儲存區121的該狀態旗標的該旗標值,亦即當該前一重力值對應的峰谷狀態為該波峰狀態時,該狀態旗標的該旗標值被更新為該第一預定值,當該前一重力值對應的峰谷狀態為該波谷狀態時,該狀態旗標的該旗標值被更新為該第二預定值,該處理單元13並根據該第二儲存區122所儲存的重力值資料更新該第一儲存區121的該偏差變異度值及該偏差強度值。In step 214, when the processing unit 13 determines in step 213 that the peak-to-valley state stored in the second storage area 122 is the maximum value of the gravity values of the peak state and the peak stored in the second storage area 122 When the valley state is that the difference between the minimum values of the gravity values of the trough state is less than or equal to the fifth predetermined value, or the count value is less than or equal to the sixth predetermined value, the processing unit 13 is configured to correspond to the peak corresponding to the previous gravity value. The valley state updates the flag value of the status flag of the first storage area 121, that is, when the peak-to-valley state corresponding to the previous gravity value is the peak state, the flag value of the status flag is updated to the flag value. a first predetermined value, when the peak-to-valley state corresponding to the previous gravity value is the trough state, the flag value of the state flag is updated to the second predetermined value, and the processing unit 13 is further configured according to the second storage area The stored gravity value data of 122 stores the deviation variability value of the first storage area 121 and the deviation intensity value.

在步驟215中,當該處理單元13於步驟213判定出該第二儲存區122所儲存之峰谷狀態為該波峰狀態的重力值中的最大值及該第二儲存區122所儲存之峰谷狀態為該波谷狀態的重力值中的最小值之差大於該第五預定值且該計數值大於該第六預定值時,該處理單元13儲存該當前重力值至該第二儲存區122,並將該計步資訊的該步數進行累加,在本實施例中,該處理單元13例如將該步數加一。In step 215, when the processing unit 13 determines in step 213 that the peak-to-valley state stored in the second storage area 122 is the maximum value of the gravity values of the peak state and the peaks and valleys stored in the second storage area 122 When the difference between the minimum value of the gravity values of the trough state is greater than the fifth predetermined value and the count value is greater than the sixth predetermined value, the processing unit 13 stores the current gravity value to the second storage area 122, and The number of steps of the step information is accumulated. In the present embodiment, the processing unit 13 increases the number of steps by one, for example.

在步驟216中,根據該第二儲存區122所儲存的重力值更新該第一儲存區121的該偏差變異度值及該偏差強度值,並將該計數值歸零且刪除該當前重力值以外的重力值。In step 216, the deviation variability value and the deviation intensity value of the first storage area 121 are updated according to the gravity value stored in the second storage area 122, and the count value is zeroed and the current gravity value is deleted. The gravity value.

要再注意的是,在本實施例步驟212、步驟214及步驟216中,該處理單元13將該第二儲存區122所儲存之重力值的最大值及最小值之平均與一第三變數之乘積加上該偏差強度值與一第四變數之乘積,其中,該第三變數與該第四變數總和為一,以更新該第一儲存區121的該偏差強度值,更新後的該偏差強度值以下式表示: 更新後的該偏差強度值=(重力值的最大值+重力值的最小值)÷2×第三變數+偏差強度值×第四變數。 該處理單元13將該第二儲存區122所儲存之重力值的最大值及最小值之平均與該偏差強度值之差取絕對值與一第五變數之乘積加上該偏差變異度值,再乘以一第六變數,其中,該第五變數與該第六變數總和為一,以更新該第一儲存區121的該偏差變異度值,更新後的該偏差變異度值以下式表示: 更新後的該偏差變異度值=[|(重力值的最大值+重力值的最小值)÷2-更新後的偏差強度值|×第五變數]+[偏差變異度值×第六變數]。It should be noted that, in step 212, step 214 and step 216 of the embodiment, the processing unit 13 averages the maximum value and the minimum value of the gravity values stored in the second storage area 122 with a third variable. The product is a product of the deviation intensity value and a fourth variable, wherein the third variable and the fourth variable are summed to update the deviation intensity value of the first storage area 121, and the updated deviation strength The value is expressed by the following formula: The updated deviation intensity value = (maximum value of gravity value + minimum value of gravity value) ÷ 2 × third variable + deviation intensity value × fourth variable. The processing unit 13 adds the difference between the average value of the maximum value and the minimum value of the gravity value stored in the second storage area 122 and the deviation intensity value to the product of the absolute value and the fifth variable, and adds the deviation variability value. Multiplied by a sixth variable, wherein the sum of the fifth variable and the sixth variable is one to update the deviation variability value of the first storage area 121, and the updated deviation variability value is expressed by the following formula: The following deviation variability value = [| (maximum value of gravity value + minimum value of gravity value) ÷ 2 - updated deviation intensity value | × fifth variable] + [deviation variability value × sixth variable].

綜上所述,本發明計步方法,藉由該感測單元11感測該使用者於該當前單位時間的動作獲得的該當前重力值,該處理單元13根據該當前重力判定是否更新該偏差強度值及該偏差變異度值,且決定該偏差強度值及該偏差變異度值的更新方式,藉此,當該使用者以不同的方式配戴該電子裝置100或是運動狀態發生變換時,該處理單元13能即時調整計步的判定基準(即該第一門檻值及該第二門檻值),以提高計步準確度,故確實能達成本發明的目的。In summary, in the step counting method of the present invention, the sensing unit 11 senses the current gravity value obtained by the user's action at the current unit time, and the processing unit 13 determines whether to update the deviation according to the current gravity. The intensity value and the deviation variability value, and determining the deviation intensity value and the manner of updating the deviation variability value, whereby when the user wears the electronic device 100 in a different manner or the motion state changes, The processing unit 13 can adjust the decision criterion of the step (ie, the first threshold value and the second threshold value) in real time to improve the step counting accuracy, so that the object of the present invention can be achieved.

惟以上所述者,僅為本發明的實施例而已,當不能以此限定本發明實施的範圍,凡是依本發明申請專利範圍及專利說明書內容所作的簡單的等效變化與修飾,皆仍屬本發明專利涵蓋的範圍內。However, the above is only the embodiment of the present invention, and the scope of the invention is not limited thereto, and all the simple equivalent changes and modifications according to the scope of the patent application and the patent specification of the present invention are still Within the scope of the invention patent.

100‧‧‧電子裝置
11‧‧‧感測單元
12‧‧‧儲存單元
121‧‧‧第一儲存區
122‧‧‧第二儲存區
13‧‧‧處理單元
201~216‧‧‧步驟
100‧‧‧Electronic devices
11‧‧‧Sensor unit
12‧‧‧ storage unit
121‧‧‧First storage area
122‧‧‧Second storage area
13‧‧‧Processing unit
201~216‧‧‧Steps

本發明的其他的特徵及功效,將於參照圖式的實施方式中清楚地呈現,其中:  圖1是一方塊圖,示例地繪示一用來實施本發明計步方法之一實施例的電子裝置;  圖2是一流程圖,說明本發明計步方法的該實施例;及  圖3是一流程圖,輔助圖2說明該實施例。Other features and advantages of the present invention will be apparent from the embodiments of the present invention, wherein: Figure 1 is a block diagram illustrating an example of an embodiment of an embodiment of the present invention. FIG. 2 is a flow chart illustrating the embodiment of the step counting method of the present invention; and FIG. 3 is a flow chart, and FIG. 2 illustrates the embodiment.

Claims (4)

一種計步方法,由一包含一三軸加速度計的電子裝置來實施,用來持續感測一使用者的移動以獲得相關於每一單位時間的三軸加速度值的重力值,每一重力值對應一峰谷狀態,該峰谷狀態包含一波峰狀態及一波谷狀態,該電子裝置包含一第一儲存區及一第二儲存區,該第一儲存區儲存有一偏差強度值、一相關於該偏差強度值的偏差變異度值及包含一步數的計步資訊,該第二儲存區用於儲存相關於該使用者之移動所獲得之重力值的重力值資料,該計步方法包含以下步驟: (A)感測該使用者於一當前單位時間的動作,以獲得一相關於該當前單位時間的三軸加速度值的一當前重力值; (B)根據該偏差強度值及該偏差變異度值計算出一第一門檻值及一第二門檻值; (C)根據該第一門檻值及該第二門檻值決定該當前重力值對應的峰谷狀態; (D)判定一相關於從前一單位時間所獲得的前一重力值對應的峰谷狀態是否不同於該當前重力值對應的峰谷狀態; (E)當判定出該前一重力值對應的峰谷狀態不同於該當前重力值對應的峰谷狀態時,判定該第二儲存區所儲存的重力值資料是否存在有一重力值符合一相關於該當前重力值的判定條件; (F)當判定出該第二儲存區所儲存的重力值資料存在有一重力值符合該判定條件時,儲存該當前重力值至該第二儲存區,並將該計步資訊的該步數進行累加;及 (G)根據該第二儲存區所儲存的重力值更新該偏差變異度值及該偏差強度值,並刪除該當前重力值以外的重力值。A step counting method is implemented by an electronic device including a three-axis accelerometer for continuously sensing a user's movement to obtain a gravity value associated with a triaxial acceleration value per unit time, each gravity value Corresponding to a peak-to-valley state, the peak-to-valley state includes a peak state and a valley state, the electronic device includes a first storage area and a second storage area, the first storage area stores a deviation intensity value, and a correlation The deviation variability value of the intensity value and the step information including the one-step number, the second storage area is configured to store the gravity value data related to the gravity value obtained by the movement of the user, and the step counting method comprises the following steps: A) sensing the action of the user at a current unit time to obtain a current gravity value related to the triaxial acceleration value of the current unit time; (B) calculating the deviation intensity value and the deviation variability value Determining a first threshold and a second threshold; (C) determining a peak-to-valley state corresponding to the current gravity value according to the first threshold and the second threshold; (D) determining one related to the previous one Whether the peak-to-valley state corresponding to the previous gravity value obtained by the unit time is different from the peak-valley state corresponding to the current gravity value; (E) when it is determined that the peak-to-valley state corresponding to the previous gravity value is different from the current gravity value In the peak-to-valley state, determining whether the gravity value data stored in the second storage area has a gravity value conforming to a determination condition related to the current gravity value; (F) determining the gravity stored in the second storage area When the value data has a gravity value meeting the determination condition, storing the current gravity value to the second storage area, and accumulating the step number of the step information; and (G) storing according to the second storage area The gravity value updates the deviation variability value and the deviation intensity value, and deletes the gravity value other than the current gravity value. 如請求項1所述的計步方法,其中,在步驟(B)中,該第一門檻值為該偏差強度值加上二分之一該偏差變異值再加上該偏差變異值與一第一變數的乘積,該第二門檻值為該偏差強度值加上二分之一該偏差變異值再減去該偏差變異值與一第二變數的乘積。The step counting method according to claim 1, wherein in the step (B), the first threshold is the deviation intensity value plus one-half of the deviation variation value plus the deviation variation value and a first a product of a variable, the second threshold being the deviation strength value plus one-half of the deviation variation value minus the product of the deviation variation value and a second variable. 如請求項1所述的計步方法,其中,在步驟(C)中,當該當前重力值大於該第一門檻值時,決定該當前重力值對應的峰谷狀態為該波峰狀態,當該當前重力值小於該第二門檻值時,決定該當前重力值對應的峰谷狀態為該波谷狀態,當該當前重力值小於等於該第一門檻值且大於等於該第二門檻值時,決定該當前重力值對應的峰谷狀態為該前一重力值對應的峰谷狀態。The step counting method of claim 1, wherein, in the step (C), when the current gravity value is greater than the first threshold value, determining a peak-to-valley state corresponding to the current gravity value is the peak state, when the When the current gravity value is less than the second threshold value, determining a peak-to-valley state corresponding to the current gravity value is the valley state, and when the current gravity value is less than or equal to the first threshold value and greater than or equal to the second threshold value, determining the The peak-to-valley state corresponding to the current gravity value is the peak-to-valley state corresponding to the previous gravity value. 如請求項1所述的計步方法,該電子裝置的第一儲存區還儲存一狀態旗標,該狀態旗標的一旗標值是一指示出該前一重力值對應的峰谷狀態為該波峰狀態的第一預定值、及一異於該第一預定值並指示出該前一重力值對應的峰谷狀態為該波谷狀態的一第二預定值,其中,在步驟(D)中,當在步驟(C)中決定出該當前重力值對應的峰谷狀態為該波峰狀態時,判定該狀態旗標的該旗標值是否為該第二預定值,而當在步驟(C)中決定出該當前重力值對應的峰谷狀態為該波谷狀態時,判定該狀態旗標的該旗標值是否為該第一預定值。In the step counting method of claim 1, the first storage area of the electronic device further stores a status flag, wherein a flag value of the status flag is a peak-to-valley state corresponding to the previous gravity value. a first predetermined value of the peak state, and a peak-to-valley state different from the first predetermined value and indicating the previous gravity value is a second predetermined value of the valley state, wherein in step (D), When it is determined in step (C) that the peak-to-valley state corresponding to the current gravity value is the peak state, it is determined whether the flag value of the state flag is the second predetermined value, and when determined in step (C) When the peak-to-valley state corresponding to the current gravity value is the trough state, it is determined whether the flag value of the state flag is the first predetermined value.
TW106119177A 2017-06-09 2017-06-09 Step counting method TWI640751B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW106119177A TWI640751B (en) 2017-06-09 2017-06-09 Step counting method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW106119177A TWI640751B (en) 2017-06-09 2017-06-09 Step counting method

Publications (2)

Publication Number Publication Date
TWI640751B true TWI640751B (en) 2018-11-11
TW201903359A TW201903359A (en) 2019-01-16

Family

ID=65034271

Family Applications (1)

Application Number Title Priority Date Filing Date
TW106119177A TWI640751B (en) 2017-06-09 2017-06-09 Step counting method

Country Status (1)

Country Link
TW (1) TWI640751B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI502167B (en) * 2014-02-25 2015-10-01 Acer Inc Step counting method and electronic device thereof
US20160131500A1 (en) * 2009-09-02 2016-05-12 Apple Inc. Systems and methods for transitioning between pedometer modes
US20160334433A1 (en) * 2015-05-14 2016-11-17 Apple Inc. Pedestrian Pace Estimation with Pace Change Updating

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160131500A1 (en) * 2009-09-02 2016-05-12 Apple Inc. Systems and methods for transitioning between pedometer modes
TWI502167B (en) * 2014-02-25 2015-10-01 Acer Inc Step counting method and electronic device thereof
US20160334433A1 (en) * 2015-05-14 2016-11-17 Apple Inc. Pedestrian Pace Estimation with Pace Change Updating

Also Published As

Publication number Publication date
TW201903359A (en) 2019-01-16

Similar Documents

Publication Publication Date Title
TWI518304B (en) A step counting method and pedometer based on 3-axis accelerometer
CN102944240B (en) A kind of inertial navigation system based on smart mobile phone and method
JP6567658B2 (en) Device and method for classifying user activity and / or counting user steps
CN104406604B (en) A kind of step-recording method
JP6788350B2 (en) Wrist-mounted pedometer with multi-axis inertial sensor
CN103954295B (en) A kind of step-recording method based on acceleration transducer
CN104596537B (en) A kind of step-recording method
CN105320269B (en) Data analysis device and data analysis method
EP3090684A1 (en) Pedometer and method for analyzing motion data
Tumkur et al. Modeling human walking for step detection and stride determination by 3-axis accelerometer readings in pedometer
US10976180B2 (en) Accelerometer-based systems and methods for quantifying steps
TWI502167B (en) Step counting method and electronic device thereof
CN107289966A (en) Method and apparatus for counting step number
TWI640751B (en) Step counting method
JP6794793B2 (en) Walking state estimation method, walking state estimation program and information processing device
TWI480517B (en) Step count method
CN108195395A (en) Mobile terminal and its step-recording method, storage device
CN113551687B (en) Step counting method, step counting device, step counting equipment, computer storage medium and chip
CN111238527B (en) Step counting method based on triaxial acceleration sensor
CN108072386B (en) Method and device for counting steps
US20180252549A1 (en) Method and apparatus for realizing step counting
CN113008242A (en) User behavior data processing method, device, equipment and storage medium
CN107631736B (en) A method and device for estimating stride length
CN110021144B (en) Tumble detection method, terminal device and storage medium
TWI515432B (en) Method and device for estimating periodic motion of a moving object

Legal Events

Date Code Title Description
MM4A Annulment or lapse of patent due to non-payment of fees