CN114569117A - Exercise consumption calculation method and device, storage medium and mobile terminal - Google Patents

Exercise consumption calculation method and device, storage medium and mobile terminal Download PDF

Info

Publication number
CN114569117A
CN114569117A CN202210192552.1A CN202210192552A CN114569117A CN 114569117 A CN114569117 A CN 114569117A CN 202210192552 A CN202210192552 A CN 202210192552A CN 114569117 A CN114569117 A CN 114569117A
Authority
CN
China
Prior art keywords
consumption
unit time
per unit
vertical direction
horizontal direction
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202210192552.1A
Other languages
Chinese (zh)
Inventor
刘浩臣
陆开中
阳思民
银雪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huizhou TCL Mobile Communication Co Ltd
Original Assignee
Huizhou TCL Mobile Communication Co Ltd
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 Huizhou TCL Mobile Communication Co Ltd filed Critical Huizhou TCL Mobile Communication Co Ltd
Priority to CN202210192552.1A priority Critical patent/CN114569117A/en
Publication of CN114569117A publication Critical patent/CN114569117A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/103Detecting, measuring or recording devices for testing the shape, pattern, colour, size or movement of the body or parts thereof, for diagnostic purposes
    • A61B5/11Measuring movement of the entire body or parts thereof, e.g. head or hand tremor, mobility of a limb
    • A61B5/1118Determining activity level
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/103Detecting, measuring or recording devices for testing the shape, pattern, colour, size or movement of the body or parts thereof, for diagnostic purposes
    • A61B5/11Measuring movement of the entire body or parts thereof, e.g. head or hand tremor, mobility of a limb
    • A61B5/1112Global tracking of patients, e.g. by using GPS
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/103Detecting, measuring or recording devices for testing the shape, pattern, colour, size or movement of the body or parts thereof, for diagnostic purposes
    • A61B5/11Measuring movement of the entire body or parts thereof, e.g. head or hand tremor, mobility of a limb
    • A61B5/1126Measuring movement of the entire body or parts thereof, e.g. head or hand tremor, mobility of a limb using a particular sensing technique
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/10Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 by using measurements of speed or acceleration
    • G01C21/12Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 by using measurements of speed or acceleration executed aboard the object being navigated; Dead reckoning
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C22/00Measuring distance traversed on the ground by vehicles, persons, animals or other moving solid bodies, e.g. using odometers, using pedometers
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C5/00Measuring height; Measuring distances transverse to line of sight; Levelling between separated points; Surveyors' levels
    • G01C5/06Measuring height; Measuring distances transverse to line of sight; Levelling between separated points; Surveyors' levels by using barometric means
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01GWEIGHING
    • G01G19/00Weighing apparatus or methods adapted for special purposes not provided for in the preceding groups
    • G01G19/44Weighing apparatus or methods adapted for special purposes not provided for in the preceding groups for weighing persons
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S19/00Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
    • G01S19/01Satellite radio beacon positioning systems transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
    • G01S19/13Receivers
    • G01S19/14Receivers specially adapted for specific applications
    • G01S19/19Sporting applications

Abstract

The embodiment of the application discloses a method and a device for calculating exercise consumption, a computer readable storage medium and a mobile terminal, wherein the method comprises the following steps: determining consumption in a horizontal direction per unit time based on the GPS positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time. The consumption in the horizontal direction per unit time is determined by a GPS positioning system, and the consumption in the vertical direction per unit time is determined by an acceleration sensor and the barometer, so that when the movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, and the total consumption can be determined.

Description

Exercise consumption calculation method and device, storage medium and mobile terminal
Technical Field
The application relates to the field of mobile terminals, in particular to a motion consumption calculation method and device, a computer readable storage medium and a mobile terminal.
Background
With the improvement of living standard of people, obesity has become a serious problem endangering human health. Published data from the international obesity problem working group show that 1 out of every 4 people on earth is too obese; nearly one third of the death cases worldwide are associated with obesity, lack of exercise, and smoking; some obese people have a 5 to 8 year shorter life span than the average.
The diabetic patients are highly coincident with the obese. For obese people, in addition to diet modification, increasing energy expenditure through exercise is also an important means of reducing body weight. And the mobile terminal can just calculate the consumption of the user, such as calories, etc., according to the motion of the user in the horizontal direction.
In the process of research and practice on the prior art, the inventor of the present application finds that in the prior art, the consumption amount can be calculated only for the motion situation of the user in the horizontal direction, but when the user involves motion in the vertical direction, such as climbing a mountain, the consumption amount calculation in the vertical direction cannot be performed, and the calculation scenario is low in applicability.
Disclosure of Invention
The embodiment of the application provides a method and a device for calculating exercise consumption, which can expand the application scene of consumption calculation.
In order to solve the above technical problem, an embodiment of the present application provides the following technical solutions:
a motion consumption calculation method is applied to a mobile terminal with an acceleration sensor, a GPS (global positioning system) and a barometer, and comprises the following steps:
determining consumption in a horizontal direction per unit time based on the GPS positioning system;
determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer;
and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time.
A motion consumption calculation device applied to a mobile terminal provided with an acceleration sensor, a GPS positioning system and a barometer comprises:
a first determination module for determining consumption in a horizontal direction per unit time based on the GPS positioning system;
a second determination module for determining consumption in a vertical direction per unit time based on the acceleration sensor and the barometer;
and the calculating module is used for calculating the total consumption of the unit time according to the consumption of the unit time in the horizontal direction and the consumption of the unit time in the vertical direction.
In some embodiments, the first determining module comprises:
a first determining submodule for determining a total horizontal direction movement distance based on the GPS positioning system;
the first calculation submodule is used for calculating the ratio of the total horizontal direction movement distance to the total movement time to obtain the movement speed of the current horizontal direction;
and the second determining submodule is used for determining the consumption in the horizontal direction per unit time based on the movement speed in the current horizontal direction and the weight information of the user.
In some embodiments, the second determining sub-module is configured to:
determining the current metabolic equivalent corresponding to the movement speed in the current horizontal direction based on the mapping relation between the movement speed and the metabolic equivalent;
and determining the consumption in the horizontal direction per unit time according to the weight information of the user and the current metabolic equivalent.
In some embodiments, the second determining module comprises:
the third determining submodule is used for determining a total air pressure change value based on the barometer and acquiring current acceleration based on the acceleration sensor;
the fourth determining submodule is used for determining the total vertical movement height according to the mapping relation between the air pressure change value and the height in the vertical direction;
the second calculation submodule is used for calculating the ratio of the total vertical movement distance to the total movement time to obtain the unit time movement distance of the current vertical direction;
and the fifth determining submodule is used for determining the consumption in the vertical direction per unit time based on the movement distance per unit time in the current vertical direction, the weight information of the user and the current acceleration.
In some embodiments, the fifth determination submodule is configured to:
judging whether the current acceleration value is 0 or not;
and if the current acceleration value is 0, calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the gravity constant to obtain the consumption in the vertical direction in the unit time.
In some embodiments, the fifth determining sub-module is further configured to:
if the current acceleration value is not 0, calculating the sum of the current acceleration value and a gravity constant to obtain a calculation result;
and calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the calculation result to obtain the consumption in the vertical direction in unit time.
In some embodiments, the calculation module comprises:
and the third calculation submodule is used for calculating the sum of the consumption in the horizontal direction of the unit time and the consumption in the vertical direction of the unit time to obtain the total consumption of the unit time.
A computer readable storage medium, storing a plurality of instructions, the instructions being suitable for being loaded by a processor to execute the steps of the above-mentioned exercise consumption calculation method.
A mobile terminal comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps in the method of calculating sports consumption as described above when executing the program.
The embodiment of the application determines the consumption in the horizontal direction per unit time by the GPS-based positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time. Thus, the consumption in the horizontal direction per unit time is determined by the GPS positioning system, and the consumption in the vertical direction per unit time is determined by the acceleration sensor and the barometer, so that when a movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, and the total consumption can be determined.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1a is a scene schematic diagram of a motion consumption calculation method according to an embodiment of the present application.
Fig. 1b is a schematic flow chart of a motion consumption calculation method according to an embodiment of the present application.
Fig. 2 is a schematic structural diagram of an exercise consumption calculation apparatus according to an embodiment of the present application.
Fig. 3 is a schematic structural diagram of a mobile terminal according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It is to be understood that the embodiments described are only a few embodiments of the present application and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The embodiment of the application provides a sports consumption calculation method and device and a computer readable storage medium.
Referring to fig. 1a, fig. 1a is a system diagram of a system for calculating exercise consumption according to an embodiment of the present application, the system may include a user and a mobile terminal 1000, the mobile terminal 1000 has an acceleration sensor, a GPS positioning system and a barometer, and may have application software of different service types installed thereon, for example: weight loss management applications, health monitoring applications, and the like.
The embodiment of the application provides a motion consumption calculation method, which can be implemented by a mobile terminal through real-time detection or by a weight loss management application on the mobile terminal and a real-time detection of internal parts in a time period when a health monitoring application is started. As shown in fig. 1a, the mobile terminal 1000 determines the consumption amount in the horizontal direction per unit time based on the GPS positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time. On the basis of this, the consumption in the horizontal direction per unit time is determined by means of the GPS positioning system, and the consumption in the vertical direction per unit time is determined by means of the acceleration sensor and said barometer, so that when a movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, so that the total consumption is determined.
It should be noted that the scenario diagram of the sports consumption computing system shown in fig. 1a is only an example, and the sports consumption computing system and the scenario described in the embodiment of the present application are for more clearly illustrating the technical solution of the embodiment of the present application, and do not form a limitation on the technical solution provided in the embodiment of the present application, and as a person having ordinary skill in the art knows that as the sports consumption computing system evolves and a new business scenario appears, the technical solution provided in the embodiment of the present application is also applicable to similar technical problems.
In the present embodiment, a description will be made from the viewpoint of a sports consumption calculation device that can be specifically integrated in a mobile terminal having an arithmetic capability with a storage unit and a microprocessor mounted thereon.
Referring to fig. 1b, fig. 1b is a schematic flow chart of a exercise consumption calculation method according to an embodiment of the present application. The exercise consumption calculation method includes:
in step 101, the consumption per unit time in the horizontal direction is determined based on the GPS positioning system.
Among them, the Global Positioning System (GPS) is a Positioning System for high-precision radio navigation based on artificial earth satellites, and can provide accurate geographical position, vehicle speed and precise time information anywhere in the world and in the near-earth space. The GPS positioning comprises pseudo-range single-point positioning, carrier phase positioning and real-time differential positioning.
Specifically, the pseudorange measurement is the distance from the satellite to the receiver, i.e., the distance obtained by multiplying the propagation time of the ranging code signal transmitted by the satellite to the GPS receiver by the speed of light. The pseudo-range method single-point positioning is to measure pseudo ranges of more than 4 GPS satellites at a certain moment by using a GPS receiver and instantaneous coordinates of the satellites obtained from satellite navigation messages, and to obtain three-dimensional coordinates of the antenna in a WGS-84 coordinate system by using a distance intersection method. The carrier phase measurement is a determination of the phase delay between the GPS satellite carrier signal to the receiver antenna. The GPS satellite carrier wave modulates the ranging code and the navigation message, after the receiver receives the satellite signal, the ranging code and the satellite message on the carrier wave are removed, and the carrier wave is obtained again and called as a reconstructed carrier wave. The GPS receiver compares the satellite reconstruction carrier with a local oscillation signal generated by an oscillator in the receiver through a phase meter, and then the phase difference can be obtained. The principle of differential positioning is to place a GPS receiver (called a reference station) at an existing precise earth-centered coordinate point, calculate corrections to the GPS observations using the known earth-centered coordinates and ephemeris, and transmit the corrections to the moving GPS receiver (called a rover) via a radio communication device (called a data link). And the rover station corrects the GPS observation value by using the correction value to eliminate the error, so that the real-time positioning precision is improved. There are various dynamic differential methods of GPS, mainly including position differential, pseudo-range differential (RTD), carrier phase real time differential (RTK), and wide area differential.
The GPS is mainly used for monitoring the position information, so that the movement track of the user on the ground during the movement, namely the movement track in the horizontal direction can be determined according to the user position information fed back by the GPS system, and the consumption in the horizontal direction per unit time can be determined according to the movement track in the horizontal direction.
In some embodiments, the step of determining the horizontal consumption per unit time based on the GPS location system comprises:
(1) a total horizontal direction movement distance determined based on the GPS positioning system;
(2) calculating the ratio of the total horizontal direction movement distance to the total movement time to obtain the movement speed of the current horizontal direction;
(3) and determining the consumption in the horizontal direction per unit time based on the movement speed in the current horizontal direction and the weight information of the user.
The method comprises the steps of establishing a moving path in the horizontal direction according to position information of a mobile terminal held by a user and recorded by a GPS, and calculating the total length of the moving path, namely the total moving distance in the horizontal direction. And calculating the movement speed of the current horizontal direction in a mode of s/t based on the movement time recorded by a timer or a health monitoring application of the mobile terminal. And finally, determining the consumption in the horizontal direction in unit time according to the calculated movement speed in the current horizontal direction and the weight information of the user.
In some embodiments, the step of determining the consumption amount in the horizontal direction per unit time based on the exercise speed in the current horizontal direction and the weight information of the user includes:
(1.1) determining a current metabolic equivalent corresponding to the movement speed in the current horizontal direction based on a mapping relation between the movement speed and the metabolic equivalent;
and (1.2) determining the consumption in the horizontal direction per unit time according to the weight information of the user and the current metabolic equivalent.
Referring to table 1, table 1 is a table of mapping relationship between preset exercise speed and metabolic equivalent.
TABLE 1
Walking speed 4.8km/h 4.2
Running speed 8km/h 9.4
Running speed of 16km/h 18.8
Running speed of 24km/h 29.3
Running speed of 32km/h 38.7
Specifically, after the movement speed in the current horizontal direction is calculated, the current metabolic equivalent corresponding to the movement speed in the current horizontal direction can be determined according to the mapping relationship between the movement speed and the metabolic equivalent shown in table 1. And then calculating a formula according to a preset consumption, for example: the calorie burned per minute W1 was 0.0175 metabolic equivalent weight, and thus the amount of consumption in the horizontal direction per unit time was calculated. Wherein, 0.0175 is a preset constant, and the weight is the weight recorded by the weight information of the user. The weight information may be entered by the user within a direct interface of the mobile terminal or within a designated location of the health monitoring application, without limitation.
In step 102, the consumption in the vertical direction per unit time is determined based on the acceleration sensor and the barometer.
Wherein the acceleration sensor is used for determining whether a motion state of the user when performing a motion in a vertical direction is an acceleration or deceleration motion; the barometer can be an empty box barometer, and the barometer utilizes the elastic deformation displacement of the diaphragm box under the atmospheric pressure to record the self-recording pen point on time barometric coordinate recording paper by a corresponding barometric numerical value through a transmission conversion mechanism to form a time recording curve to measure the atmospheric pressure. The working principle of the barometer is known, so that the height change of the mobile terminal held by a user in the vertical direction can be determined through the change of the air pressure, the moving track of the mobile terminal in the vertical direction is determined, and the consumption of the mobile terminal in the vertical direction in unit time is determined by combining with the acceleration sensor.
In some embodiments, the step of determining the consumption of the vertical direction per unit time based on the gravity sensor and the barometer comprises:
(1) determining a total barometric pressure change value based on the barometer, and acquiring a current acceleration based on the acceleration sensor;
(2) determining the total vertical movement height according to the mapping relation between the air pressure change value and the height in the vertical direction;
(3) calculating the ratio of the total vertical movement distance to the total movement time to obtain the unit time movement distance in the current vertical direction;
(4) and determining the consumption of the vertical direction in the unit time based on the movement distance of the current vertical direction in the unit time, the weight information of the user and the current acceleration.
The height change of the mobile terminal in the vertical direction can cause the air pressure recorded by the air pressure meter to change, so that the total vertical direction movement height in the vertical direction can be determined according to the total air pressure change value. The determination mode may be determined according to a mapping relationship between the air pressure change value and the height in the vertical direction. And calculating the ratio of the total vertical movement distance to the total movement time to obtain the unit time movement distance in the current vertical direction. And determining the consumption of the vertical direction in the unit time based on the movement distance of the current vertical direction in the unit time, the weight information of the user and the current acceleration.
In some embodiments, the step of determining the consumption amount in the vertical direction per unit time based on the moving distance per unit time in the current vertical direction, the weight information of the user, and the current acceleration includes:
(1.1) judging whether the current acceleration value is 0 or not;
(1.2) if the current acceleration value is 0, calculating the product of the unit time movement distance of the current vertical direction, the weight information of the user and the gravity constant to obtain the consumption of the unit time in the vertical direction.
The motion can be divided into uniform, accelerated and decelerated motion according to different motion states. And the mode of judging the motion state is determined according to the current acceleration value acquired by the acceleration sensor. And if the current acceleration value is 0, the motion is indicated as uniform motion. Then according to the formula of doing work: w2 ═ mgh; the consumption in the vertical direction per unit time is calculated. Wherein m is the weight of the user, h is the unit time movement distance in the current vertical direction, and g is a gravity constant.
In some embodiments, the method further comprises:
(1.1) if the current acceleration value is not 0, calculating the sum of the current acceleration value and a gravity constant to obtain a calculation result;
and (1.2) calculating the product of the unit time movement distance of the current vertical direction, the weight information of the user and the calculation result to obtain the consumption of the unit time in the vertical direction.
If the current acceleration value is not 0, the state is in an acceleration or deceleration motion state, the current acceleration value is a positive value during acceleration, and the current acceleration value is a negative value during deceleration. And calculating the sum of the current acceleration value and the gravity constant to obtain a calculation result. And calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the calculation result to obtain the consumption in the vertical direction in unit time.
And 103, calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction of the unit time.
After the consumption in the horizontal direction and the consumption in the vertical direction in the unit time are obtained, the total consumption in the unit time can be calculated.
In some embodiments, the calculating of the total consumption per unit time based on the consumption per unit time in the horizontal direction and the consumption per unit time in the vertical direction includes:
and calculating the sum of the consumption in the horizontal direction of the unit time and the consumption in the vertical direction of the unit time to obtain the total consumption of the unit time.
Wherein the consumption in the horizontal direction per unit time and the consumption in the vertical direction per unit time may be directly summed as a total consumption per unit time.
Specifically, a weight value may be assigned to each of the consumption amount in the horizontal direction per unit time and the consumption amount in the vertical direction per unit time, so as to calculate the total consumption amount per unit time, for example, W — C1 — W1+ C2 — W2, which is not limited herein.
As can be seen from the above, the embodiment of the present application determines the consumption in the horizontal direction per unit time by using the GPS positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time. Thus, the consumption in the horizontal direction per unit time is determined by the GPS positioning system, and the consumption in the vertical direction per unit time is determined by the acceleration sensor and the barometer, so that when a movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, and the total consumption can be determined.
In order to better implement the exercise consumption calculation method provided by the embodiment of the present application, an embodiment of the present application further provides a device based on the exercise consumption calculation method. The terms are the same as those in the exercise consumption calculation method, and details of implementation may refer to the description in the method embodiment.
Referring to fig. 2, fig. 2 is a schematic structural diagram of a sports consumption calculating device according to an embodiment of the present application. The exercise consumption calculation apparatus applied to a mobile terminal having an acceleration sensor, a GPS positioning system, and a barometer may include a first determination module 201, a second determination module 202, a calculation module 203, and the like.
A first determining module 201, configured to determine consumption in a horizontal direction per unit time based on the GPS positioning system;
a second determination module 202, configured to determine consumption in a vertical direction per unit time based on the acceleration sensor and the barometer;
a calculating module 203, configured to calculate a total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction of the unit time.
In some embodiments, the first determining module 201 includes:
a first determining submodule for determining a total horizontal direction movement distance based on the GPS positioning system;
the first calculation submodule is used for calculating the ratio of the total horizontal direction movement distance to the total movement time to obtain the movement speed of the current horizontal direction;
and the second determining submodule is used for determining the consumption in the horizontal direction per unit time based on the movement speed in the current horizontal direction and the weight information of the user.
In some embodiments, the second determining submodule is configured to:
determining the current metabolic equivalent corresponding to the movement speed in the current horizontal direction based on the mapping relation between the movement speed and the metabolic equivalent;
and determining the consumption in the horizontal direction per unit time according to the weight information of the user and the current metabolic equivalent.
In some embodiments, the second determining module 202 includes:
the third determining submodule is used for determining a total air pressure change value based on the barometer and acquiring current acceleration based on the acceleration sensor;
the fourth determination submodule is used for determining the total vertical movement height according to the mapping relation between the air pressure change value and the height in the vertical direction;
the second calculation submodule is used for calculating the ratio of the total vertical movement distance to the total movement time to obtain the unit time movement distance of the current vertical direction;
and the fifth determining submodule is used for determining the consumption in the vertical direction per unit time based on the movement distance per unit time in the current vertical direction, the weight information of the user and the current acceleration.
In some embodiments, the fifth determining submodule is configured to:
judging whether the current acceleration value is 0 or not;
and if the current acceleration value is 0, calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the gravity constant to obtain the consumption in the vertical direction in the unit time.
In some embodiments, the fifth determining sub-module is further configured to:
if the current acceleration value is not 0, calculating the sum of the current acceleration value and a gravity constant to obtain a calculation result;
and calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the calculation result to obtain the consumption in the vertical direction in unit time.
In some embodiments, the calculation module 203 includes:
and the third calculation submodule is used for calculating the sum of the consumption in the horizontal direction of the unit time and the consumption in the vertical direction of the unit time to obtain the total consumption of the unit time.
As can be seen from the above, in the embodiment of the present application, the consumption amount in the horizontal direction per unit time is determined by the first determining module 201 based on the GPS positioning system; the second determination module 202 determines the consumption amount in the vertical direction per unit time based on the acceleration sensor and the barometer; the calculation module 203 calculates the total consumption per unit time according to the consumption per unit time in the horizontal direction and the consumption per unit time in the vertical direction. Thus, the consumption in the horizontal direction per unit time is determined by the GPS positioning system, and the consumption in the vertical direction per unit time is determined by the acceleration sensor and the barometer, so that when a movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, and the total consumption can be determined.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
Correspondingly, the embodiment of the application further provides a mobile terminal, which may be a terminal device such as a smart phone, a tablet Computer, a notebook Computer, a touch screen, a game console, a Personal Computer (PC), a Personal Digital Assistant (PDA), and the like. As shown in fig. 3, fig. 3 is a schematic structural diagram of a mobile terminal according to an embodiment of the present application. The mobile terminal 1000 includes a processor 301 having one or more processing cores, a memory 302 having one or more computer-readable storage media, and a computer program stored on the memory 302 and executable on the processor. The processor 301 is electrically connected to the memory 302. Those skilled in the art will appreciate that the mobile terminal architecture shown in the figures is not intended to be limiting of mobile terminals and may include more or fewer components than those shown, or some of the components may be combined, or a different arrangement of components.
The processor 301 is a control center of the mobile terminal 1000, connects various parts of the entire mobile terminal 1000 using various interfaces and lines, and performs various functions of the mobile terminal 1000 and processes data by running or loading software programs and/or modules stored in the memory 302 and calling data stored in the memory 302, thereby integrally monitoring the mobile terminal 1000.
In this embodiment, the processor 301 in the mobile terminal 1000 loads instructions corresponding to processes of one or more application programs into the memory 302 according to the following steps, and the processor 301 runs the application programs stored in the memory 302, thereby implementing various functions:
determining consumption in a horizontal direction per unit time based on the GPS positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time.
Optionally, as shown in fig. 3, the mobile terminal 1000 further includes: a touch display 303, a radio frequency circuit 304, an audio circuit 305, an input unit 306, and a power source 307. The processor 301 is electrically connected to the touch display 303, the radio frequency circuit 304, the audio circuit 305, the input unit 306, and the power source 307. Those skilled in the art will appreciate that the mobile terminal architecture shown in fig. 3 is not intended to be limiting of mobile terminals and may include more or fewer components than shown, or a combination of certain components, or a different arrangement of components.
The touch display screen 303 may be used for displaying a graphical user interface and receiving operation instructions generated by a user acting on the graphical user interface. The touch display screen 303 may include a display panel and a touch panel. Among other things, the display panel may be used to display information input by or provided to a user and various graphical user interfaces of the mobile terminal, which may be made up of graphics, text, icons, video, and any combination thereof. Alternatively, the Display panel may be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like. The touch panel may be used to collect touch operations of a user (for example, operations of the user on or near the touch panel by using a finger, a stylus pen, or any other suitable object or accessory) and generate corresponding operation instructions, and the operation instructions execute corresponding programs. Alternatively, the touch panel may include two parts, a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 301, and can receive and execute commands sent by the processor 301. The touch panel may overlay the display panel, and when the touch panel detects a touch operation thereon or nearby, the touch panel transmits the touch operation to the processor 301 to determine the type of the touch event, and then the processor 301 provides a corresponding visual output on the display panel according to the type of the touch event. In the embodiment of the present application, the touch panel and the display panel may be integrated into the touch display screen 303 to realize input and output functions. However, in some embodiments, the touch panel and the touch panel can be implemented as two separate components to perform the input and output functions. That is, the touch display screen 303 may also be used as a part of the input unit 306 to implement an input function.
In the embodiment of the present application, a processor 301 executes a game application to generate a graphical user interface on a touch display screen 303, where a virtual scene on the graphical user interface includes at least one skill control area, and the skill control area includes at least one skill control. The touch display screen 303 is used for presenting a graphical user interface and receiving an operation instruction generated by a user acting on the graphical user interface.
The rf circuit 304 may be used for transceiving rf signals to establish wireless communication with a network device or other mobile terminal through wireless communication, and for transceiving signals with the network device or other mobile terminal.
The audio circuit 305 may be used to provide an audio interface between the user and the mobile terminal through a speaker, microphone. The audio circuit 305 may transmit the electrical signal converted from the received audio data to a speaker, and convert the electrical signal into a sound signal for output; on the other hand, the microphone converts the collected sound signal into an electric signal, which is received by the audio circuit 305 and converted into audio data, and then the audio data is processed by the audio data output processor 301, and then transmitted to, for example, another mobile terminal via the radio frequency circuit 304, or the audio data is output to the memory 302 for further processing. The audio circuit 305 may also include an earpiece jack to provide communication of a peripheral headset with the mobile terminal.
The input unit 306 may be used to receive input numbers, character information, or user characteristic information (e.g., fingerprint, iris, facial information, etc.), and to generate keyboard, mouse, joystick, optical, or trackball signal inputs related to user settings and function control.
Power supply 307 is used to power the various components of mobile terminal 1000. Optionally, the power supply 307 may be logically connected to the processor 301 through a power management system, so as to implement functions of managing charging, discharging, and power consumption management through the power management system. Power supply 307 may also include any component of one or more dc or ac power sources, recharging systems, power failure detection circuitry, power converters or inverters, power status indicators, and the like.
Although not shown in fig. 3, the mobile terminal 1000 may further include a camera, a sensor, a wireless fidelity module, a bluetooth module, etc., which are not described in detail herein.
In the foregoing embodiments, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
As can be seen from the above, the mobile terminal provided in this embodiment determines the consumption in the horizontal direction per unit time by using the GPS-based positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time. Thus, the consumption in the horizontal direction per unit time is determined by the GPS positioning system, and the consumption in the vertical direction per unit time is determined by the acceleration sensor and the barometer, so that when a movement in the vertical direction is involved, the consumption in the horizontal and vertical directions can be calculated, and the total consumption can be determined.
It will be understood by those skilled in the art that all or part of the steps of the methods of the above embodiments may be performed by instructions, or by instructions controlling associated hardware, which may be stored in a computer-readable storage medium and loaded and executed by a processor.
To this end, the present application provides a computer-readable storage medium, in which a plurality of computer programs are stored, where the computer programs can be loaded by a processor to execute the steps in the control method according to any one of the techniques provided in the present application. For example, the computer program may perform the steps of:
determining consumption in a horizontal direction per unit time based on the GPS positioning system; determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer; and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time.
The above operations can be implemented in the foregoing embodiments, and are not described in detail herein.
Wherein the storage medium may include: read Only Memory (ROM), Random Access Memory (RAM), magnetic or optical disks, and the like.
Since the computer program stored in the storage medium can execute the steps in any exercise consumption calculation method provided in the embodiments of the present application, the beneficial effects that can be achieved by any exercise consumption calculation method provided in the embodiments of the present application can be achieved, and detailed descriptions are omitted here for the foregoing embodiments.
The method, the apparatus, the computer-readable storage medium, and the mobile terminal for calculating exercise consumption provided by the embodiments of the present application are described in detail above, and a specific example is applied in the description to explain the principles and embodiments of the present application, and the description of the embodiments is only used to help understand the method and the core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. An exercise consumption calculation method applied to a mobile terminal equipped with an acceleration sensor, a GPS positioning system, and a barometer, comprising:
determining consumption in a horizontal direction per unit time based on the GPS positioning system;
determining a consumption amount in a vertical direction per unit time based on the acceleration sensor and the barometer;
and calculating the total consumption per unit time according to the consumption in the horizontal direction and the consumption in the vertical direction per unit time.
2. The athletic consumption calculation method of claim 1, wherein the step of determining the consumption of the GPS-based positioning system in the horizontal direction per unit time comprises:
a total horizontal direction movement distance determined based on the GPS positioning system;
calculating the ratio of the total horizontal direction movement distance to the total movement time to obtain the movement speed of the current horizontal direction;
and determining the consumption in the horizontal direction per unit time based on the movement speed in the current horizontal direction and the weight information of the user.
3. The exercise consumption calculation method according to claim 2, wherein the step of determining the consumption amount in the horizontal direction per unit time based on the exercise speed in the current horizontal direction and the weight information of the user comprises:
determining the current metabolic equivalent corresponding to the movement speed in the current horizontal direction based on the mapping relation between the movement speed and the metabolic equivalent;
and determining the consumption in the horizontal direction per unit time according to the weight information of the user and the current metabolic equivalent.
4. The athletic consumption calculation method of claim 1, wherein the step of determining the consumption amount in the vertical direction per unit time based on the gravity sensor and the barometer comprises:
determining a total barometric pressure change value based on the barometer, and acquiring a current acceleration based on the acceleration sensor;
determining the total vertical movement height according to the mapping relation between the air pressure change value and the height in the vertical direction;
calculating the ratio of the total vertical movement distance to the total movement time to obtain the unit time movement distance in the current vertical direction;
and determining the consumption of the vertical direction in the unit time based on the movement distance of the current vertical direction in the unit time, the weight information of the user and the current acceleration.
5. The exercise consumption calculation method according to claim 4, wherein the step of determining the consumption amount in the vertical direction per unit time based on the exercise distance per unit time in the current vertical direction, the weight information of the user, and the current acceleration includes:
judging whether the current acceleration value is 0 or not;
and if the current acceleration value is 0, calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the gravity constant to obtain the consumption in the vertical direction in the unit time.
6. The athletic consumption calculation method of claim 5, wherein the method further comprises:
if the current acceleration value is not 0, calculating the sum of the current acceleration value and a gravity constant to obtain a calculation result;
and calculating the product of the unit time movement distance in the current vertical direction, the weight information of the user and the calculation result to obtain the consumption in the vertical direction in unit time.
7. The sports consumption calculation method according to claim 1, wherein the step of calculating the total consumption per unit time from the consumption per unit time in the horizontal direction and the consumption per unit time in the vertical direction includes:
and calculating the sum of the consumption in the horizontal direction of the unit time and the consumption in the vertical direction of the unit time to obtain the total consumption of the unit time.
8. An exercise consumption calculation device applied to a mobile terminal equipped with an acceleration sensor, a GPS positioning system, and a barometer, comprising:
the first determining module is used for determining the consumption in the horizontal direction per unit time based on the GPS positioning system;
a second determination module for determining consumption in a vertical direction per unit time based on the acceleration sensor and the barometer;
and the calculating module is used for calculating the total consumption in unit time according to the consumption in the horizontal direction of the unit time and the consumption in the vertical direction of the unit time.
9. A computer readable storage medium storing a plurality of instructions adapted to be loaded by a processor to perform the steps of the method for calculating exercise consumption according to any of claims 1 to 7.
10. A mobile terminal comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps in the method for calculating exercise consumption according to any of claims 1 to 7 when executing the program.
CN202210192552.1A 2022-03-01 2022-03-01 Exercise consumption calculation method and device, storage medium and mobile terminal Pending CN114569117A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210192552.1A CN114569117A (en) 2022-03-01 2022-03-01 Exercise consumption calculation method and device, storage medium and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210192552.1A CN114569117A (en) 2022-03-01 2022-03-01 Exercise consumption calculation method and device, storage medium and mobile terminal

Publications (1)

Publication Number Publication Date
CN114569117A true CN114569117A (en) 2022-06-03

Family

ID=81772332

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210192552.1A Pending CN114569117A (en) 2022-03-01 2022-03-01 Exercise consumption calculation method and device, storage medium and mobile terminal

Country Status (1)

Country Link
CN (1) CN114569117A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115187605A (en) * 2022-09-13 2022-10-14 飞狐信息技术(天津)有限公司 Method and device for determining heat value

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115187605A (en) * 2022-09-13 2022-10-14 飞狐信息技术(天津)有限公司 Method and device for determining heat value

Similar Documents

Publication Publication Date Title
US11960012B2 (en) Positioning method and electronic device
CN112558125B (en) Vehicle positioning method, related device, equipment and storage medium
CN106054219A (en) Electronic device and positioning control method
CN109445425B (en) Performance detection method and device of automatic driving system and storage medium
US11237017B2 (en) Stride length calibration method and system, and related device
US20130103348A1 (en) Methods and apparatuses for controlling invocation of a sensor
US20170052030A1 (en) Adjustable data transmissions by navigation devices
WO2013063122A1 (en) Dead reckoning using proximity sensors
US20230213343A1 (en) Method for obtaining confidence of measurement value based on multi-sensor fusion and autonomous vehicle
US20140010043A1 (en) Portable Sonar Imaging System and Method
CN114569117A (en) Exercise consumption calculation method and device, storage medium and mobile terminal
CN111986250A (en) Object volume measuring method, device, measuring equipment and storage medium
CN112444829A (en) GNSS satellite selection method, device, chip, equipment and storage medium
CN110824516B (en) Positioning method and electronic equipment
CN110992196B (en) Social relation establishment method, system, terminal equipment and server
US11237001B2 (en) Method, apparatus, and terminal for obtaining route
CN113432620B (en) Error estimation method and device, vehicle-mounted terminal and storage medium
CN113326800B (en) Lane line position determination method and device, vehicle-mounted terminal and storage medium
CN111159551B (en) User-generated content display method and device and computer equipment
CN111158033B (en) Differential positioning method, device, equipment and storage medium based on GNSS
CN111986251A (en) Object volume measuring method, device, measuring equipment and storage medium
EP4290895A1 (en) Method for controlling a positioning chip and electronic device
CN115900644B (en) Laser scanning imaging method and device for hydraulic support robot working face bottom plate
CN116772884A (en) Method, device, equipment and storage medium for planning energy source supplementing path
WO2021027621A1 (en) Navigation method, apparatus device, electronic device, and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination