CN117191076A - Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium - Google Patents

Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium Download PDF

Info

Publication number
CN117191076A
CN117191076A CN202210707476.3A CN202210707476A CN117191076A CN 117191076 A CN117191076 A CN 117191076A CN 202210707476 A CN202210707476 A CN 202210707476A CN 117191076 A CN117191076 A CN 117191076A
Authority
CN
China
Prior art keywords
motion sensor
data
vibration
motion
state
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
CN202210707476.3A
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 CN202210707476.3A priority Critical patent/CN117191076A/en
Publication of CN117191076A publication Critical patent/CN117191076A/en
Pending legal-status Critical Current

Links

Landscapes

  • Gyroscopes (AREA)

Abstract

The invention provides a motion sensor correction method, a motion sensor correction device, electronic equipment and a storage medium, wherein the motion sensor correction method comprises the following steps: judging the current state of the motion sensor, wherein the current state comprises a first state and a second state; if the current state is the first state, controlling a preset vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor; if the current state is the second state, controlling a preset vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor; wherein the preset vibration system is configured to output vibration information to be detected by the motion sensor, the first mode being different from the second mode. The invention has controllable function and performance of the motion sensor, has detection and repair functions, and improves the user experience of related applications of the motion sensor.

Description

Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of functional device correction technologies, and in particular, to a method and apparatus for correcting a motion sensor, an electronic device, and a storage medium.
Background
Motion sensors are numerous consumer electronic devices such as: cell phones, TWS headphones, wearable designs, tablets, and the like. Motion sensors are mainly divided into two categories: acceleration sensors and gyro sensors; an acceleration sensor for recognizing the movement of the object by detecting the change of the acceleration of the object; the gyro sensor recognizes the rotation or direction change of the object by detecting the change of the angular momentum of the object. In practical application, the acceleration sensor and the gyroscope sensor are integrated on one IC chip, and through the sensor chip, the electronic device can detect motion, movement, direction change and rotation, so that various colorful applications such as movement step counting, jump recognition, navigation, knocking response, head movement Tracking (Head Tracking) and the like are developed.
Current consumer electronic device motion sensor design applications do not have mechanisms to detect and repair motion sensor functionality. When the user finds that the practical application is problematic, the system can only be restarted to restore to normal.
Disclosure of Invention
The invention provides a motion sensor correction method, a motion sensor correction device, electronic equipment and a storage medium, which are used for solving the problem that a motion sensor in the prior art does not have detection and repair functions.
In a first aspect, the present invention provides a motion sensor correction method, comprising:
judging the current state of the motion sensor, wherein the current state comprises a first state and a second state;
if the current state is the first state, controlling a preset vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor;
if the current state is the second state, controlling a preset vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor;
wherein the preset vibration system is configured to output vibration information to be detected by the motion sensor, the first mode being different from the second mode.
In an embodiment of the present invention, the step of determining the current state of the motion sensor includes:
reading the data of the motion sensor at intervals of preset time;
comparing whether the current read data is consistent with the previous read data or not;
if the current states of the motion sensors are consistent, judging that the current states of the motion sensors are first states;
and if the current states of the motion sensors are inconsistent, judging that the current states of the motion sensors are second states.
In an embodiment of the present invention, the step of controlling the preset vibration system to output first vibration information in a first mode to perform function detection on the motion sensor includes:
controlling the preset vibration system to output the first vibration information with fixed vibration intensity within a preset time period;
reading the data of the motion sensor, and comparing whether the current read data is consistent with the previous read data or not in a preset period;
if the motion sensor function detection is consistent, the motion sensor is reset and restarted if the motion sensor function detection is abnormal;
if the motion sensor function detection is inconsistent, the motion sensor function detection is normal.
In an embodiment of the present invention, the step of performing a reset restart operation on the motion sensor includes:
and sending an interrupt control signal to the motion sensor to control the motion sensor to perform reset restarting operation.
In an embodiment of the present invention, the step of controlling the preset vibration system to output the second vibration information in the second mode to perform performance detection on the motion sensor includes:
controlling the preset vibration system to output second vibration information according to the vibration intensity and the time length;
reading the data of the motion sensor, and comparing whether the deviation between the currently read data and the data originally stored in the system is within a preset range or not;
if the deviation is not in the preset range, the performance of the motion sensor is detected to be abnormal, and the motion sensor is controlled to start self-correcting repair operation;
and if the deviation is within a preset range, the performance of the motion sensor is detected to be normal, and the data of the motion sensor are recorded.
In a second aspect, an embodiment of the present invention further provides a motion sensor correction apparatus, applied to an electronic device, where the apparatus includes:
a vibration system including a power module and a vibration module for outputting vibration information to be detected by the motion sensor;
a motion sensor for detecting data of an action of the electronic device caused by the vibration information or a user motion;
the processor is respectively connected with the power supply module and the motion sensor and is used for judging the current state of the motion sensor, wherein the current state comprises a first state and a second state; if the current state is the first state, controlling the vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor; and if the current state is the second state, controlling the vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor, wherein the first mode is different from the second mode.
In an embodiment of the invention, the processor is further configured to:
reading the data of the motion sensor at intervals of preset time;
comparing whether the current read data is consistent with the previous read data or not;
if the current states of the motion sensors are consistent, judging that the current states of the motion sensors are first states;
if the current states of the motion sensors are inconsistent, judging that the current states of the motion sensors are second states;
wherein the data includes acceleration data and angular momentum data.
In an embodiment of the invention, the processor is further configured to:
controlling the vibration system to output the first vibration information with fixed vibration intensity within a preset time period;
reading the data of the motion sensor, and comparing whether the current read data is consistent with the previous read data or not in a preset period;
if the motion sensor function detection is consistent, the motion sensor is reset and restarted if the motion sensor function detection is abnormal;
if the motion sensor function detection is inconsistent, the motion sensor function detection is normal.
In an embodiment of the invention, the processor is further configured to:
controlling the vibration system to output second vibration information according to the vibration intensity and the time length;
reading the data of the motion sensor, and comparing whether the deviation between the currently read data and the data originally stored in the system is within a preset range or not;
if the deviation is not in the preset range, the performance of the motion sensor is detected to be abnormal, and the motion sensor is controlled to start self-correcting repair operation;
and if the deviation is within a preset range, the performance of the motion sensor is detected to be normal, and the data of the motion sensor are recorded.
In an embodiment of the present invention, the processor is further configured to send an interrupt control signal to the motion sensor to control the motion sensor to perform a reset restart operation.
In an embodiment of the present invention, the processor is connected to the power module through an SPI interface, and the processor is connected to the motion sensor through an I2C interface or an SPI interface.
In a third aspect, an embodiment of the present invention further provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements the steps of the method for correcting a motion sensor according to any one of the first aspect, when the processor executes the program.
In a fourth aspect, embodiments of the present invention also provide a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the motion sensor correction method as described in any of the first aspects above.
According to the motion sensor correction method, the motion sensor correction device, the electronic equipment and the storage medium, the vibration information is sent out through the preset vibration system to perform function detection and performance detection on the motion sensor, so that the function and performance of the motion sensor are controllable, the detection and repair functions are achieved, and user experience of related applications of the motion sensor is improved.
Drawings
In order to more clearly illustrate the invention or the technical solutions of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are some embodiments of the invention, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flow chart of a method for motion sensor calibration provided by an embodiment of the present invention;
FIG. 2 is a flow chart of a method for motion sensor calibration according to another embodiment of the present invention;
FIG. 3 is a schematic diagram of a motion sensor calibration apparatus according to the present invention;
fig. 4 is a schematic structural diagram of an electronic device provided by the present invention.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the present invention more apparent, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some embodiments of the present invention, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The terms first, second and the like in the description and in the claims and in the above-described figures, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments described herein may be implemented in other sequences than those illustrated or otherwise described herein.
Technical terms related to the present invention are described as follows:
motion sensors are mainly divided into two categories: acceleration sensors and gyro sensors; an acceleration sensor for recognizing the movement of the object by detecting the change of the acceleration of the object; the gyro sensor recognizes the rotation or direction change of the object by detecting the change of the angular momentum of the object.
Acceleration sensor (Accelerometer Sensor): a sensor capable of measuring acceleration of an electronic product is characterized in that the acceleration is obtained through calculation by testing inertia acting force applied to a mass block in the sensor. The acceleration of the electronic product in a three-dimensional space can be detected by the 3-axis acceleration sensor of the consumer electronic product, and the motion information of the consumer electronic product is acquired, so that the motion step counting is realized.
Gyro Sensor (gyroscillope Sensor): a sensor for acquiring rotation and direction information of an object by measuring angular momentum change using a gyro principle. Consumer electronic products are usually 3-axis gyroscopic sensors, so that rotation and direction information of the electronic product in a three-dimensional space can be detected, and the sensor is commonly used for navigation direction recognition, hand rotation operation, head motion tracking and the like. In an implementation form, the 3-axis acceleration sensor and the 3-axis gyro sensor are typically integrated into one IC chip.
Because in the existing design scheme, the application of the motion sensor depends on the original calibration of the electronic product when leaving the factory, the application of the motion sensor cannot be effectively self-checked and self-calibrated due to the influence of physical effects (such as static electricity and electromagnetic influence), environmental factors (such as temperature and humidity), human factors (such as careless drop and sweat/cosmetic pollution) and the like during the use of the electronic product, so that the motion sensor can be restored to a better working state, and the application experience of the electronic device is reduced. Therefore, the following problems occur: for example, the user has run a few kilometers, but the electronic device is still a zero motion step counter; the navigation direction is inaccurate; the speed of the movement is matched and the path is erratic; the VR/AR head movement tracking is not timely and accurate, so that the problems of dizziness and the like caused by mismatching of picture and sound positioning are caused.
Therefore, in order to solve the technical problem that the motion sensor in the prior art does not have the function self-checking and repairing function, the invention provides a motion sensor correcting method, a device, electronic equipment and a storage medium, which can perform the self-checking and repairing on the motion sensor, effectively solve the problem caused by the response speed, the precision and the function reliability in the application process of the motion sensor and improve the user experience of products.
The motion sensor correction method, apparatus, electronic device, and storage medium of the present invention are described below with reference to fig. 1 to 4.
Referring to fig. 1, fig. 1 is a flowchart of a motion sensor calibration method according to an embodiment of the invention. The method for correcting the motion sensor provided by the embodiment of the invention comprises the following steps:
step 110, determining a current state of the motion sensor, wherein the current state comprises a first state and a second state.
Illustratively, the current state of the motion sensor is a state for feeding back whether the user is in motion. The first state comprises a static state in which the motion sensor has abnormal conditions and a real static state in which the motion sensor is normal in function, and the real static state indicates that the user does not move. The second state is a real motion state, and represents that the user is in the real motion state.
Illustratively, the step of determining the current state of the motion sensor includes:
and step 111, reading the data of the motion sensor every preset time.
The preset duration may be customized according to a user, for example, every 10 minutes may be set. The data mainly comprise acceleration data and angular momentum data, but the data can also comprise other physical quantities according to actual application requirements.
For example, the data of the motion sensor may be read periodically by the application processor.
Step 112, comparing whether the currently read data is consistent with the previously read data.
For example, the acceleration data and angular momentum data fed back by the motion sensor currently read may be compared with the acceleration data and angular momentum data previously read for whether there is a change.
And 113, if the motion sensor is consistent, judging that the current state of the motion sensor is a first state.
For example, if the acceleration data and the angular momentum data fed back by the motion sensor read currently are consistent with the acceleration data and the angular momentum data read previously, the motion sensor is judged to be in the first state.
Step 114, if the current state of the motion sensor is inconsistent, it is determined that the current state of the motion sensor is the second state.
For example, if the acceleration data and the angular momentum data fed back by the motion sensor currently read are inconsistent with the acceleration data and the angular momentum data previously read, the current state of the motion sensor is judged to be the second state.
And step 120, if the current state is the first state, controlling the preset vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor.
By way of example, functional detection refers to detection of the action or use of the motion sensor, e.g. functional detection refers to whether the motion sensor can detect angular velocity data and angular momentum data. Whereas performance detection refers to the detection of the mass of the motion sensor, performance detection refers to how accurate the acceleration data and angular momentum data detected by the motion sensor are, for example.
Illustratively, the preset vibration system is configured to output vibration information for detection by the motion sensor. For example, the preset vibration system may be a system formed by a motor assembly, the motor may cause the electronic device to which the motion sensor is applied to generate a change in acceleration and angular momentum during vibration, and the change in acceleration and angular momentum may be detected by the motion sensor.
Illustratively, the step of controlling the preset vibration system to output the first vibration information in the first mode to functionally detect the motion sensor includes:
and step 121, controlling the preset vibration system to output the first vibration information in a first mode with fixed vibration intensity in a preset time period.
For example, the first vibration information may be output at a vibration acceleration of a fixed vibration intensity of 0.8G for a 30ms duration (i.e., 30ms interval) by the processor controlling the preset vibration system.
And step 122, reading the data of the motion sensor, and comparing whether the currently read data is consistent with the previously read data or not in a preset period.
For example, 3 periods may be set, and whether or not the acceleration data and the angular momentum data of the first period, the second period, and the third period are changed may be compared.
And step 123, if the motion sensor functions are consistent, the motion sensor is reset and restarted if the motion sensor functions are abnormal.
For example, if there is coincidence, which means that the data read every cycle is unchanged, i.e., the motion sensor function detects an abnormality, a reset restart operation of the motion sensor is required. For example, an interrupt control signal is sent by the processor to the motion sensor to control the motion sensor to perform a reset restart operation.
Therefore, the problem that the user moves for a long time, the motion count is still zero or the motion count is seriously deviated is avoided by controlling the motion sensor to reset and restart through interruption.
Step 124, if the motion sensor function detection is not consistent, indicating that the motion sensor function detection is normal.
Illustratively, inconsistencies indicate that the data read every cycle has changed, i.e., the motion sensor function detects normal, when the user is not moving, in a truly stationary state.
And 130, if the current state is the second state, controlling the preset vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor.
Illustratively, the step of controlling the preset vibration system to output the second vibration information in the second mode to perform performance detection on the motion sensor includes:
and 131, controlling the preset vibration system to output second vibration information in a second mode with variable vibration intensity and duration.
For example, the first vibration information may be output by controlling the preset vibration system by the processor to gradually change the vibration acceleration of the vibration intensity of 0.3G to the vibration acceleration of 1.2G and then gradually change the vibration acceleration of 1.2G to the vibration acceleration of 0.3G.
The first mode of the present invention is different from the second mode, and the first mode is a vibration mode with a fixed intensity and a fixed duration, and the second mode is a vibration mode with a variable intensity and a variable duration. The first mode is a vibration mode for identifying and judging the first state, and is a relatively simple mode. The second mode is used for identifying and judging the vibration mode of the second state, and the vibration mode provided by the vibration system is required to contain the intensity change and the rhythm speed due to the comparison of the accuracy of data and the calibration of the data of the motion sensor, so that whether the accuracy and the response speed of the motion sensor are normal or not is judged.
And step 132, reading the data of the motion sensor, and comparing whether the deviation between the currently read data and the data originally stored in the system is within a preset range.
And step 133, if the deviation is not within the preset range, which indicates that the performance of the motion sensor is abnormal, controlling the motion sensor to start self-correcting repair operation.
For example, if the deviation is not within the preset range, that is, the deviation between the data of the motion sensor at this time and the data originally stored in the system is relatively large, in order to avoid a large deviation between the data output and the actual occurrence, the motion sensor should be calibrated at this time to obtain accurate data. Because the vibration mode, the intensity and the speed provided by the feedback of the vibration system are all known, the precision and the response speed of the motion sensor can be detected and self-calibrated. Therefore, the problems of user experience caused by data record losing and actual asynchronism and the like due to inaccurate data are avoided.
Step 134, if the deviation is within the preset range, it indicates that the performance of the motion sensor is detected to be normal and the data of the motion sensor is recorded.
In summary, in the electronic device, the motion sensor is an indispensable functional device. In the existing design scheme, the motion sensor is only an interface for feeding back motion information, and in the application process, the precision, the response speed and the reliability of the motion sensor can only be configured by depending on factory parameters. Also because of this, motion sensors often become pain and sink points of the user experience in various types of electronic devices.
The vibration feedback in the electronic equipment design system is adopted as the calibration input of the motion information of the motion sensor, and the function detection, the performance self-checking and the self-calibration can be performed in the static state and the called initial stage of the motion sensor due to the control of the vibration intensity, the initial speed and the vibration waveform of the vibration system, so that the reliability of the motion sensor in practical application and the accuracy of the motion information are improved, and the user experience of the motion sensor related application is effectively improved.
Referring to fig. 2, fig. 2 is a flowchart of a motion sensor calibration method according to another embodiment of the invention. The invention discloses a motion sensor correction method, which comprises the following steps:
step 201, data of a motion sensor is read periodically.
Illustratively, the user may set each 10 minutes to read the motion sensor data. The data includes acceleration data and angular momentum data.
Step 202, judging whether the acceleration data and the angular momentum data fed back by the motion sensor change.
If there is no change, it indicates that the current state of the motion sensor is the first state, i.e. in an abnormal state or in a truly stationary state, and step 203 is performed.
If there is a change, it indicates that the current state of the motion sensor is the second state, i.e. in the real motion state, and step 207 is performed.
In step 203, the vibration system outputs first vibration information in a first mode of fixed intensity and duration.
The first mode of the fixed intensity and the duration is a vibration mode for identifying and judging the first state, and is a relatively simple mode.
Step 204, determining whether the acceleration data and the angular momentum data fed back by the motion sensor change.
If there is a change, indicating that the motion sensor function detection is normal, step 205 is performed.
If there is no change, indicating that the motion sensor function is detecting an abnormality, step 206 is performed.
In step 205, the motion sensor function detects normal, when the user has no motion, and is in a true stationary state.
In step 206, the motion sensor detects an abnormality, and a reset operation is required to be performed on the motion sensor.
In step 207, the current state of the motion sensor is the second state, i.e. the user is in the real motion state, and the motion data of the motion sensor needs to be accurately recorded.
Since the user is in a real motion state at this time, and the motion sensor also detects motion data of the user motion, the function is not problematic, but further detection of the performance of the motion sensor is required to detect how accurate the motion data fed back by the motion sensor is.
The vibration system outputs 208 second vibration information in a second mode of varying intensity and duration.
The second mode of intensity and duration change is a vibration mode for identifying and judging the second state, and the vibration mode provided by the vibration system needs to contain intensity change and rhythm speed due to the comparison of data accuracy and the data calibration of the motion sensor, so that whether the accuracy and the response speed of the motion sensor are normal or not is judged.
Step 209, comparing whether the deviation between the motion data recorded at this time and the originally stored motion data is within a preset range.
The motion data recorded at this time refers to the motion data obtained by detecting the second vibration information output in step 208 by the motion sensor. Since the second mode is a vibration mode provided by the vibration system and is used for detecting the performance of the motion sensor, the accuracy and the response speed of the motion sensor are judged whether to be normal or not by changing the intensity and the rhythm. The invention is not limited to how the intensity and the duration of the second mode are changed, and only the change is required to be satisfied.
If the deviation is within the preset range, the deviation is smaller, and step 210 is performed.
If the deviation is not within the preset range, it indicates that the deviation is larger, step 211 is performed.
In step 210, the performance of the motion sensor detects normal and motion data of the motion sensor is recorded normally.
Step 211, performing self-correction repair operation on the motion sensor when the performance of the motion sensor detects abnormality.
In order to avoid large deviation of motion data output and actual occurrence, the motion sensor should be calibrated at the moment to acquire accurate motion information. Because the vibration mode, the intensity and the speed provided by the vibration system are all known, the precision and the response speed of the motion sensor can be detected and self-calibrated, and thus the problems of user experience caused by inaccurate data recording, asynchronous data recording and the like due to inaccurate motion data are avoided.
The motion sensor correction device provided by the invention is described below, and the motion sensor correction device described below and the motion sensor correction method described above can be referred to correspondingly to each other.
Referring to fig. 3, fig. 3 is a schematic structural diagram of a motion sensor calibration apparatus according to the present invention. The motion sensor correction device provided by the embodiment of the invention is applied to electronic equipment, and comprises a vibration system 310, a motion sensor 320 and a processor 330. Wherein the vibration system 310 includes a power module 311 and a vibration module 312.
Illustratively, the vibration system 310 includes a power module 311 and a vibration module 312, the vibration system 310 for outputting vibration information to be detected by the motion sensor 320. For example, the vibration system 310 may be composed of a vibration motor (Vibrator) and a power management chip (PMIC). The processor 330 is connected to the power module 311 through an SPI interface, and the processor 330 is connected to the motion sensor 320 through an I2C interface or an SPI interface.
Illustratively, the motion sensor 320 is used to detect data that is caused by vibration information or user motion to the action of the electronic device.
Specifically, the motion Sensor generally integrates an acceleration Sensor (Accelerometer Sensor) and a gyro Sensor (gyroscillope Sensor) inside one IC chip. The IC chip is connected and communicated with A Processor (AP) 330 of the electronic equipment through an I2C interface or an SPI interface, changes of physical quantities such as acceleration, angular momentum and the like detected by the motion sensor are fed back to the processor 330, and the processor 330 calculates through a processing algorithm to obtain motion information of the electronic equipment at the moment. Various apks (Android application package, application packages) inside the electronic device can acquire motion information, so that various functions such as motion step counting, navigation direction recognition, gesture detection, head motion tracking and the like are realized. The SPI interface adopted by the embodiment of the invention has the advantage of being capable of being used for transmitting the motion data of the electronic equipment or the application scene with larger data demand.
The processor 330 is connected to the power module 311 and the motion sensor 320, and is configured to determine a current state of the motion sensor 320, where the current state includes a first state and a second state; if the current state is the first state, controlling the vibration system 310 to output first vibration information in a first mode to perform function detection on the motion sensor 320; if the current state is the second state, the vibration system 310 is controlled to output the second vibration information in a second mode to perform performance detection on the motion sensor 320, wherein the first mode is different from the second mode.
Specifically, the processor 330 is connected with the power module 311 through an SPI interface, and is responsible for scheduling the vibration application process of the vibration system 310; the power module 311 provides power supply and vibration initiation, intensity, duration, mode, etc. control for the vibration system 312. For example, during motor vibration, changes in acceleration and angular momentum of the electronic device may be induced. Because the motor vibration can be accurately controlled by the processor 330, the motor vibration can be used as the self-checking input of the motion sensor function, and the self-calibration input of the precision and the response speed, so that the function and the performance of the motion sensor are controllable, and the user experience of the motion sensor system and related applications is improved.
Further, the motion sensor 320 is controlled by an INT (interrupt control) signal connected to the processor 330, and the INT (interrupt control) signal controls operations such as resetting and restarting the motion sensor 320.
Illustratively, the processor 330 is further configured to:
reading data of the motion sensor 320 every preset time period;
comparing whether the current read data is consistent with the previous read data or not;
if so, judging that the current state of the motion sensor 320 is the first state;
if not, judging that the current state of the motion sensor 320 is the second state;
wherein the data includes acceleration data and angular momentum data.
Illustratively, the processor 330 is further configured to:
controlling the vibration system 310 to output the first vibration information with a fixed vibration intensity for a preset period of time;
reading data of the motion sensor 320, and comparing whether the currently read data is consistent with the previously read data in a preset period;
if the motion sensor 320 is consistent, the motion sensor 320 is reset and restarted if the motion sensor 320 is abnormal in function detection;
if not, it indicates that the motion sensor 320 function is detecting normal.
Illustratively, the processor 330 is further configured to:
controlling the vibration system 310 to output the second vibration information with a vibration intensity and a time period change;
reading data of the motion sensor 320, and comparing whether deviation of the currently read data and data originally stored in the system is within a preset range;
if the deviation is not within the preset range, which indicates that the performance of the motion sensor 320 is abnormal, the motion sensor 320 is controlled to start self-correcting repair operation;
if the deviation is within the preset range, it indicates that the performance of the motion sensor 320 is detected as normal and the data of the motion sensor 320 is recorded.
It should be noted that, the motion sensor correction device provided in the embodiment of the present invention can implement all the method steps implemented in the motion sensor correction method embodiment, and can achieve the same technical effects, and detailed descriptions of the same parts and beneficial effects as those in the method embodiment in the embodiment are omitted.
Fig. 4 illustrates a physical schematic diagram of an electronic device, as shown in fig. 4, which may include: processor (Processor) 410, communication interface (Communications Interface) 420, memory (Memory) 430, and communication bus 440, wherein Processor 410, communication interface 420, and Memory 430 communicate with each other via communication bus 440. The processor 410 may invoke logic instructions in the memory 430 to perform a motion sensor correction method comprising:
judging the current state of the motion sensor, wherein the current state comprises a first state and a second state;
if the current state is the first state, controlling a preset vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor;
if the current state is the second state, controlling a preset vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor;
wherein the preset vibration system is configured to output vibration information to be detected by the motion sensor, the first mode being different from the second mode.
Further, the logic instructions in the memory 430 described above may be implemented in the form of software functional units and may be stored in a computer-readable storage medium when sold or used as a stand-alone product. Based on this understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution, in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
In another aspect, the present invention also provides a computer program product comprising a computer program stored on a non-transitory computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, are capable of performing the method of motion sensor correction provided by the methods described above.
In yet another aspect, the present invention also provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, is implemented to perform the above provided motion sensor correction methods.
The electronic device, the computer program product, and the computer readable storage medium provided by the embodiments of the present invention have the advantage that the computer program stored thereon enables the processor to implement all the method steps implemented by the embodiments of the method and achieve the same technical effects, and detailed descriptions of the same parts and advantages as those of the embodiments of the method are omitted herein.
The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment. Those of ordinary skill in the art will understand and implement the present invention without undue burden.
From the above description of the embodiments, it will be apparent to those skilled in the art that the embodiments may be implemented by means of software plus necessary general hardware platforms, or of course may be implemented by means of hardware. Based on this understanding, the foregoing technical solution may be embodied essentially or in a part contributing to the prior art in the form of a software product, which may be stored in a computer readable storage medium, such as ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the respective embodiments or some parts of the embodiments.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (13)

1. A method of motion sensor calibration, comprising:
judging the current state of the motion sensor, wherein the current state comprises a first state and a second state;
if the current state is the first state, controlling a preset vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor;
if the current state is the second state, controlling a preset vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor;
wherein the preset vibration system is configured to output vibration information to be detected by the motion sensor, the first mode being different from the second mode.
2. The method of claim 1, wherein the step of determining the current state of the motion sensor comprises:
reading the data of the motion sensor at intervals of preset time;
comparing whether the current read data is consistent with the previous read data or not;
if the current states of the motion sensors are consistent, judging that the current states of the motion sensors are first states;
and if the current states of the motion sensors are inconsistent, judging that the current states of the motion sensors are second states.
3. The method of claim 1, wherein the step of controlling the preset vibration system to output first vibration information in a first mode to functionally detect the motion sensor comprises:
controlling the preset vibration system to output the first vibration information with fixed vibration intensity within a preset time period;
reading the data of the motion sensor, and comparing whether the current read data is consistent with the previous read data or not in a preset period;
if the motion sensor function detection is consistent, the motion sensor is reset and restarted if the motion sensor function detection is abnormal;
if the motion sensor function detection is inconsistent, the motion sensor function detection is normal.
4. A motion sensor calibration method according to claim 3, wherein the step of resetting the motion sensor comprises:
and sending an interrupt control signal to the motion sensor to control the motion sensor to perform reset restarting operation.
5. The method of claim 1, wherein the step of controlling the preset vibration system to output second vibration information in a second mode to perform performance detection of the motion sensor comprises:
controlling the preset vibration system to output second vibration information according to the vibration intensity and the time length;
reading the data of the motion sensor, and comparing whether the deviation between the currently read data and the data originally stored in the system is within a preset range or not;
if the deviation is not in the preset range, the performance of the motion sensor is detected to be abnormal, and the motion sensor is controlled to start self-correcting repair operation;
and if the deviation is within a preset range, the performance of the motion sensor is detected to be normal, and the data of the motion sensor are recorded.
6. A motion sensor correction apparatus for use in an electronic device, the apparatus comprising:
a vibration system including a power module and a vibration module for outputting vibration information to be detected by the motion sensor;
a motion sensor for detecting data of an action of the electronic device caused by the vibration information or a user motion;
the processor is respectively connected with the power supply module and the motion sensor and is used for judging the current state of the motion sensor, wherein the current state comprises a first state and a second state; if the current state is the first state, controlling the vibration system to output first vibration information in a first mode so as to perform function detection on the motion sensor; and if the current state is the second state, controlling the vibration system to output second vibration information in a second mode so as to perform performance detection on the motion sensor, wherein the first mode is different from the second mode.
7. The motion sensor calibration apparatus of claim 6 wherein the processor is further configured to:
reading the data of the motion sensor at intervals of preset time;
comparing whether the current read data is consistent with the previous read data or not;
if the current states of the motion sensors are consistent, judging that the current states of the motion sensors are first states;
if the current states of the motion sensors are inconsistent, judging that the current states of the motion sensors are second states;
wherein the data includes acceleration data and angular momentum data.
8. The motion sensor calibration apparatus of claim 6 wherein the processor is further configured to:
controlling the vibration system to output the first vibration information with fixed vibration intensity within a preset time period;
reading the data of the motion sensor, and comparing whether the current read data is consistent with the previous read data or not in a preset period;
if the motion sensor function detection is consistent, the motion sensor is reset and restarted if the motion sensor function detection is abnormal;
if the motion sensor function detection is inconsistent, the motion sensor function detection is normal.
9. The motion sensor calibration apparatus of claim 6 wherein the processor is further configured to:
controlling the vibration system to output second vibration information according to the vibration intensity and the time length;
reading the data of the motion sensor, and comparing whether the deviation between the currently read data and the data originally stored in the system is within a preset range or not;
if the deviation is not in the preset range, the performance of the motion sensor is detected to be abnormal, and the motion sensor is controlled to start self-correcting repair operation;
and if the deviation is within a preset range, the performance of the motion sensor is detected to be normal, and the data of the motion sensor are recorded.
10. The motion sensor calibration apparatus of claim 8 wherein the processor is further configured to send an interrupt control signal to the motion sensor to control the motion sensor to perform a reset restart operation.
11. The motion sensor calibration apparatus of claim 6 wherein the processor is coupled to the power module via an SPI interface and the processor is coupled to the motion sensor via an I2C interface or an SPI interface.
12. An electronic device 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 of the motion sensor correction method according to any one of claims 1 to 5 when the program is executed.
13. A non-transitory computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when executed by a processor, implements the steps of the motion sensor correction method according to any one of claims 1 to 5.
CN202210707476.3A 2022-06-21 2022-06-21 Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium Pending CN117191076A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210707476.3A CN117191076A (en) 2022-06-21 2022-06-21 Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210707476.3A CN117191076A (en) 2022-06-21 2022-06-21 Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117191076A true CN117191076A (en) 2023-12-08

Family

ID=89004055

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210707476.3A Pending CN117191076A (en) 2022-06-21 2022-06-21 Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117191076A (en)

Similar Documents

Publication Publication Date Title
CN106500728B (en) A kind of method for temperature drift compensation and device of gyroscope
US8294572B2 (en) Method and mechanism for assisted diagnosis and maintenance of health monitoring system
RU2501063C2 (en) Residue analysis apparatus and method for detecting system errors in aircraft system behaviour
CN105783900B (en) A kind of calibration method and device of sensing data
CN109005002B (en) Sensor data processing device, sensor system and method for determining a conversion parameter using a sensor system
CN108628451A (en) Data correcting method and device, virtual reality device
CN113377054B (en) Data synchronization method and device
CN113391551B (en) Motor electric angle compensation method and device, electronic equipment and storage medium
CN117191076A (en) Motion sensor correction method, motion sensor correction device, electronic equipment and storage medium
CN114185512A (en) Sensor data processing method, electronic device and readable storage medium
CN105979100B (en) A kind of method and mobile terminal for restoring inertial sensor working condition
CN111275769B (en) Monocular vision parameter correction method and device
US11245763B2 (en) Data processing method, computer device and storage medium
RU2719310C2 (en) System and method for measurement of path length using pocket electronic device
CN109408252B (en) Data transmission method, device and medium
CN110940352B (en) Automatic calibration system of micro-electro-mechanical system inertia measurement unit and calibration verification method thereof
US11964390B2 (en) Counter unit, counter unit control method, control device, and control system
CN111784661A (en) Adjusting method, device, equipment and medium of power transmission line detection equipment
KR20210000095A (en) Method for posture estimation and apparatus thereof
CN110687773A (en) Method, device and system for measuring time service precision of time unification system
JP2998727B2 (en) Pulse width measuring device and pulse width measuring method for rotation detection
KR100286043B1 (en) speed detecting system and method thereof
JPH10269007A (en) Writing tool type coordinate input device
EP4375618A1 (en) Dynamic gravity vector estimation for memory constrained devices
CN113383281B (en) Control 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