A method, system, computer device and medium for calibrating an electronic compass

By using a high-precision positioning receiver to calculate the angle difference and calibrate the deviation angle of the electronic compass, the accuracy problem of compass calibration in scenarios without a true point is solved, achieving high-precision electronic compass calibration and avoiding external magnetic field interference.

CN119915265BActive Publication Date: 2025-11-25HUBEI JIUZHIYANG INFRARED SYST CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510083344.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-20
Publication Date
2025-11-25
Estimated Expiration
2045-01-20

AI Technical Summary

Technical Problem

In scenarios without a true value point, it is difficult to achieve high-precision orientation angle calibration in the electronic compass calibration process, especially under the influence of external magnetic field interference and temperature changes. The cumulative error from multiple measurements leads to a decrease in compass measurement accuracy.

Method used

Two high-precision positioning receivers are used to obtain the latitude and longitude of the location, and the angle value of the line formed by the two receivers is calculated. An electronic compass is then aligned with the line formed by the two positioning receivers, and the angle values ​​are compared to determine the deviation angle of the electronic compass for calibration.

Benefits of technology

High-precision electronic compass calibration was achieved without a true point, with a calibration accuracy of less than 0.1°, avoiding the influence of external magnetic field interference and improving the accuracy of compass measurements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119915265B_ABST
    Figure CN119915265B_ABST
Patent Text Reader

Abstract

The application discloses a kind of method, system, computer device and medium for calibrating electronic compass using two positioning receivers, and relates to the field of orientation and measurement, including two high-precision positioning equipment and electronic compass system;The longitude and latitude of each antenna is positioned using two high-precision receivers respectively, the angle of straight line formed by two antennas relative to the angle of true north is calculated, and then the direction of straight line formed by two antennas is aligned using electronic compass to obtain the angle of true north, the deviation angle of electronic compass and two antennas is obtained, and finally the deviation angle of electronic compass is corrected.Compared with calibrating electronic compass using true value point, using two high-precision receivers has the advantage of calibration not being limited by the location of true value point, and can be performed at any time in an open field, and the angle of true north of two antennas calculated by two high-precision receivers has high precision, and is suitable for electronic compass correction in true value point-free scenarios.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of orientation and measurement, and particularly relates to a method and system for calibrating an electronic compass using two positioning receivers, a computer device and a medium. BACKGROUND

[0002] An electronic compass is used to measure a direction angle based on the natural magnetic field of the earth. During use, the electronic compass is disturbed by various external magnetic fields and temperature changes, which affect the hardware of the electronic compass. The measurement errors generated by multiple measurements are accumulated, and other reasons cause errors in the measurement of the electronic compass. In order to obtain a high-precision direction angle, the electronic compass is usually calibrated with a true value point. However, the true value point is usually a fixed point and a fixed direction. When the electronic compass is used for a long time in a place without a true value point, one of the difficulties in the calibration process of the electronic compass is to find a true value point. SUMMARY

[0003] The present application aims to provide a method, system, computer device and medium for calibrating an electronic compass with high precision in a true value point-free scene, to solve the problem of no high-precision true value point calibration for the electronic compass in a true value point-free state.

[0004] In a first aspect, the present application provides a calibration method for an electronic compass, which is realized based on a first positioning receiver and a second positioning receiver. The method comprises the following steps:

[0005] Obtaining the longitude and latitude of a first position where the first positioning receiver is located and the longitude and latitude of a second position where the second positioning receiver is located;

[0006] Obtaining a line angle value of a straight line formed by the first positioning receiver and the second positioning receiver based on the longitude and latitude of the first position and the longitude and latitude of the second position;

[0007] Obtaining an angle value of a direction of the straight line formed by the first positioning receiver and the second positioning receiver by the electronic compass;

[0008] Comparing the angle value obtained by the electronic compass with the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver to determine a deviation angle that needs to be corrected by the electronic compass.

[0009] In some examples, the step of obtaining the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver based on the longitude and latitude of the first position and the longitude and latitude of the second position comprises the following steps:

[0010] Calculating the average values of the longitude and latitude of the first position and the longitude and latitude of the second position, calculating the difference between the average longitude of the first position and the average longitude of the second position, and calculating the difference between the average latitude of the first position and the average latitude of the second position;

[0011] Based on the difference between the first position longitude average value and the second position longitude average value, the difference between the first position latitude average value and the second position latitude average value, the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained.

[0012] In some examples, the first position longitude average value and the second position longitude average value are obtained by The line angle value θ of the straight line formed by the first positioning receiver and the second positioning receiver is obtained by deg wherein θ = arctan2((sin(ΔLon)*cos(LatB), cos(LatA)*sin(LatB)-sin(LatA)*cos(LatB)*cos(ΔLon)), ΔLon = LonB-LonA, ΔLat = LatB-LatA, LatA represents the longitude average value of the first positioning receiver, LonA represents the latitude average value of the first positioning receiver, LatB represents the longitude average value of the second positioning receiver, and LonB represents the latitude average value of the second positioning receiver.

[0013] In some examples, the deviation angle Δθ that the electronic compass needs to correct is determined by Δθ = θ deg - α, wherein α represents the angle value obtained by the electronic compass.

[0014] In a second aspect, the present application provides a calibration system for an electronic compass, comprising a first positioning receiver, a second positioning receiver and a terminal, wherein the terminal is configured to perform the following steps:

[0015] Obtaining the longitude and latitude of a first position where the first positioning receiver is located and the longitude and latitude of a second position where the second positioning receiver is located;

[0016] Based on the longitude and latitude of the first position and the longitude and latitude of the second position, the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained.

[0017] Obtaining the angle value of the straight line direction formed by the first positioning receiver and the second positioning receiver as aligned by the electronic compass;

[0018] Comparing the angle value obtained by the electronic compass with the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver to determine the deviation angle that the electronic compass needs to correct.

[0019] In some examples, the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained based on the longitude and latitude of the first position and the longitude and latitude of the second position, comprising:

[0020] Calculating the average value of the longitude and latitude of the first position and the longitude and latitude of the second position, calculating the difference between the first position longitude average value and the second position longitude average value, and the difference between the first position latitude average value and the second position latitude average value.

[0021] Based on the difference between the first position longitude average value and the second position longitude average value, the difference between the first position latitude average value and the second position latitude average value obtains the line angle value of the straight line composed of the first positioning receiver and the second positioning receiver.

[0022] In some examples, the first positioning receiver and the second positioning receiver are obtained by The line angle value θ of the straight line composed of the first positioning receiver and the second positioning receiver is obtained by deg Wherein, θ = arctan2((sin(ΔLon)*cos(LatB),cos(LatA)*sin(LatB)-sin(LatA)*cos(LatB)*cos(ΔLon)), ΔLon = LonB-LonA, ΔLAt = LatB-LatA, LatA represents the longitude average value of the first positioning receiver, LonA represents the latitude average value of the first positioning receiver, LatB represents the longitude average value of the second positioning receiver, and LonB represents the latitude average value of the second positioning receiver.

[0023] In some examples, the deviation angle Δθ required for the electronic compass to be corrected is determined by Δθ = θ deg -α, and α represents the angle value obtained by the electronic compass.

[0024] In a third aspect, the present application provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the steps of the method of any one of the above aspects when executing the computer program.

[0025] In a fourth aspect, the present application provides a computer readable storage medium, which stores a computer program, and the computer program implements the steps of the method of any one of the above aspects when executed by a processor.

[0026] Overall, compared with the prior art, the above technical solutions conceived by the present application can achieve the following beneficial effects:

[0027] 1. The present application can calibrate the electronic compass using double high-precision positioning receivers when there is no true value point;

[0028] 2. When a high-precision receiver and a multi-band antenna are selected, the accuracy of the marked true value point is less than 0.1°, and the accuracy is high;

[0029] 3. Compared with using a compass for calibration, there is no problem of interference by external factors such as magnetic fields. BRIEF DESCRIPTION OF DRAWINGS

[0030] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following will briefly introduce the drawings needed in the embodiments description. Obviously, the drawings in the following description only represent some of the embodiments of the present application, and all of the other drawings can be obtained by those skilled in the art without any creative effort.

[0031] Figure 1 FIG. 1 is a schematic diagram of a calibration method of an electronic compass provided by an embodiment of the present application;

[0032] Figure 2 FIG. 2 is a schematic diagram of a calibration state of an electronic compass provided by an embodiment of the present application;

[0033] Figure 3 FIG. 3 is a schematic diagram of an antenna feed circuit provided by an embodiment of the present application.

[0034] Figure 4 FIG. 4 is a schematic diagram of an embodiment structure of a computer device provided by an embodiment of the present application. DETAILED DESCRIPTION

[0035] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments only represent some of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all the other embodiments obtained by those skilled in the art without any creative effort fall within the scope of the present application.

[0036] In the following description, specific embodiments of the present application will be described with reference to steps and symbols executed by one or more computers, unless otherwise specified. Therefore, these steps and operations will be mentioned several times by computers, and the computer execution referred to herein includes the operation of a computer processing unit represented by an electronic signal in a structured form. This operation transforms the data or maintains it at a location in the memory system of the computer, which can reconfigure or otherwise change the operation of the computer in a manner known to those skilled in the art. The data structure maintained by the data is the physical location of the memory, which has specific characteristics defined by the data format. However, the principles of the present application are described in the above description, which does not represent a limitation, and those skilled in the art will understand that the following steps and operations can also be implemented in hardware.

[0037] The term "module" or "unit" used herein can be regarded as a software object executed on the operating system. Different components, modules, engines and services herein can be regarded as implementation objects on the operating system. The apparatus and method herein are preferably implemented in software, and of course can also be implemented in hardware, all within the scope of the present application.

[0038] Those skilled in the art can understand that, unless specifically stated, the singular forms "a," "an," and "the" as used herein include plural referents. It should further be understood that the word "comprising" as used in the specification herein is used to mean that there are features, integers, steps, operations, elements, and / or components that are present, but not excluding the presence of one or more other features, integers, steps, operations, elements, components, and / or groups thereof. It should be understood that when we say an element is "connected" or "coupled" to another element, it can be directly connected or coupled to the other element, or intervening elements can be present. Also, "connected" or "coupled" as used herein can include wirelessly connected or wirelessly coupled. The word "and / or" as used herein encompasses all of the associated possibilities that the phrase refers to, both the individual and all combinations of the items in the list.

[0039] In the first embodiment, the present application provides a method for calibrating an electronic compass, which is implemented based on a first positioning receiver and a second positioning receiver, as shown in the following figure: Figure 1 The method comprises the following steps:

[0040] S101: Obtain the longitude and latitude of a first position where the first positioning receiver is located and the longitude and latitude of a second position where the second positioning receiver is located;

[0041] The two positioning receivers A and B can receive four-star full-band high-precision positioning signals. The positioning receivers A and B each comprise a receiver antenna and a tripod for fixed receivers, a device with an electronic compass and the ability to perform differential compensation, and a terminal. The positioning receivers are used to position two points in an open field and display the corresponding longitude and latitude values of the two points.

[0042] S102: Obtain the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver based on the longitude and latitude of the first position and the longitude and latitude of the second position;

[0043] S103: Obtain the angle value of the direction of the straight line formed by the first positioning receiver and the second positioning receiver as aligned by the electronic compass;

[0044] The position of the first positioning receiver can be taken as the main antenna, and the position of the second positioning receiver can be taken as the slave antenna. The electronic compass can be aimed at the slave antenna from the main antenna to obtain the angle value.

[0045] S104: Compare the angle value obtained by the electronic compass with the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver to determine the deviation angle that needs to be corrected by the electronic compass.

[0046] In some examples, the step of obtaining the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver based on the longitude and latitude of the first position and the longitude and latitude of the second position comprises:

[0047] Calculate the average of the latitude and longitude of the first location and the second location; calculate the difference between the average longitude of the first location and the average longitude of the second location; calculate the difference between the average latitude of the first location and the average latitude of the second location.

[0048] Based on the difference between the average longitude of the first position and the average longitude of the second position, the difference between the average latitude of the first position and the average latitude of the second position is used to obtain the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver.

[0049] In some instances, by The linear angle θ of the straight line formed by the first positioning receiver and the second positioning receiver is obtained. deg Where θ=arctan2((sin(ΔLon)*cos(LatB),cos(LatA)*sin(LatB)-sin(LatA)*cos(LatB)*cos(ΔLon)), ΔLon=LonB-LonA, ΔLat=LatB-LatA, LatA represents the average longitude of the first positioning receiver, LatB represents the average latitude of the first positioning receiver, and LonB represents the average longitude of the second positioning receiver.

[0050] In some instances, Δθ=θ deg -α determines the deviation angle Δθ that the electronic compass needs to correct, where α represents the angle value obtained by the electronic compass.

[0051] In a second embodiment, the present invention provides a method for calibrating an electronic compass in an environment without a truth point. For example... Figure 2 The diagram shown is a block diagram of the device layout for this invention; it includes two high-precision positioning receivers A and B, receiver antennas, a tripod for fixing the receivers, a device with an electronic compass capable of differential compensation, and a terminal. The positioning receivers and antennas are selected to be capable of receiving the full frequency bands of four satellites to improve positioning accuracy. Figure 3 The diagram shows the antenna feeding circuit and an open area. Two positioning receivers are used to receive positioning latitude and longitude information. The terminal records and calculates the angle values ​​of the positioning points of the two receivers. The center point of the electronic compass is aimed at the midpoint of the antenna of receiver A, which is used as the main antenna. Then, the center point of the antenna of receiver B is aimed at the midpoint of the antenna, which is used as the secondary antenna. The midpoints of the electronic compass, receiver A, and receiver B are aligned.

[0052] The first step is to place two positioning receivers, A and B, on tripods in an open area. To improve the accuracy of the orientation angle formed by the two receivers, the distance between the two positioning receivers should be greater than 6m. Turn on the positioning receivers and wait for successful positioning. When the changes in the obtained latitude and longitude values ​​are minimal, read the latitude and longitude values ​​of point A and point B obtained by receivers A and B, respectively. Point A (longitude LatA, latitude LonA) and point B (longitude LatB, latitude LonB).

[0053] The second step is to align the electronic compass with the midpoint of the receiver antenna at point A and the midpoint of the receiver antenna at point B, and record the angle value α of the electronic compass at this time.

[0054] The third step is to calculate the azimuth angle formed by receiver A and receiver B, in radians. First, calculate the difference between the average latitude and longitude values:

[0055] ΔLon=LonB-LonA

[0056] ΔLat=LatB-LatA

[0057] Calculate the azimuth angle (in radians) using the following formula:

[0058] θ=arctan2(sin(ΔLon)*cos(LatB),cos(LatA)*sin(LatB)-sin(LatA)*cos(LatB)*cos(ΔLon))

[0059] Finally, convert the azimuth angle from radians to degrees:

[0060]

[0061] The deviation angle of the electronic compass is the difference that the electronic compass needs to be calibrated for.

[0062] Δθ=θ deg -α

[0063] In the third embodiment, to facilitate better implementation of the method provided by the embodiments of the present invention, the embodiments of the present invention also provide a system based on the above method. The meanings of the terms are the same as in the above method, and specific implementation details can be found in the description of the method embodiments. The system includes: a first positioning receiver, a second positioning receiver, and a terminal, wherein the terminal is used to perform the following steps:

[0064] Obtain the latitude and longitude of the first positioning receiver at the first location and the second positioning receiver at the second location;

[0065] The line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained based on the latitude and longitude of the first position and the second position.

[0066] Obtain the angle value of the electronic compass aligned with the straight line formed by the first positioning receiver and the second positioning receiver;

[0067] The angle value obtained by the electronic compass is compared with the angle value of the line formed by the first positioning receiver and the second positioning receiver to determine the deviation angle that the electronic compass needs to correct.

[0068] In the fourth embodiment, the present invention also provides a computer device, such as... Figure 4 As shown, it illustrates a structural schematic diagram of a computer device involved in an embodiment of the present invention, specifically:

[0069] The computer device may include components such as a processor 401 with one or more processing cores, a memory 402 with one or more computer-readable storage media, a power supply 403, and an input unit 404. Those skilled in the art will understand that... Figure 4 The computer device structure shown does not constitute a limitation on the computer device and may include more or fewer components than shown, or combine certain components, or have different component arrangements. Wherein:

[0070] The processor 401 is the control center of the computer device. It connects various parts of the computer device via various interfaces and lines, and performs various functions and processes data by running or executing software programs and / or modules stored in the memory 402, and by calling data stored in the memory 402, thereby providing overall monitoring of the computer device. Optionally, the processor 401 may include one or more processing cores; preferably, the processor 401 may integrate an application processor and a modem processor, wherein the application processor mainly handles the operation of the storage medium, user interface, and application programs, and the modem processor mainly handles wireless communication. It is understood that the modem processor may not be integrated into the processor 401.

[0071] The memory 402 can be used to store software programs and modules. The processor 401 executes various functional applications and data processing by running the software programs and modules stored in the memory 402. The memory 402 may mainly include a program storage area and a data storage area. The program storage area may store applications required for operating the storage medium and at least one function (such as sound playback function, image playback function, etc.); the data storage area may store data created according to the use of the computer device. In addition, the memory 402 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 402 may also include a controller to provide the processor 401 with access to the memory 402.

[0072] The computer device also includes a power supply 403 that supplies power to the various components. Preferably, the power supply 403 can be logically connected to the processor 401 via a power management storage medium, thereby enabling functions such as charging, discharging, and power consumption management through the power management storage medium. The power supply 403 may also include one or more DC or AC power supplies, recharge storage media, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components.

[0073] The computer device may also include an input unit 404, which can be used to receive input digital or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.

[0074] Although not shown, the computer device may also include a display unit, etc., which will not be described in detail here. Specifically, in this embodiment, the processor 401 in the computer device loads the executable files corresponding to the processes of one or more applications into the memory 402 according to the following instructions, and the processor 401 runs the applications stored in the memory 402, thereby implementing the steps in the above method embodiment.

[0075] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be performed by instructions, or by instructions controlling related hardware. These instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0076] Therefore, embodiments of the present invention provide a computer-readable storage medium having a computer program stored thereon, the computer program being loaded by a processor to execute the steps of any method provided in the embodiments of the present invention.

[0077] For details on the implementation of each of the above operations, please refer to the previous examples, which will not be repeated here.

[0078] The computer-readable storage medium may include: read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0079] Since the computer program stored in the computer-readable storage medium can execute the steps of any of the methods provided in the embodiments of the present invention, the beneficial effects that any of the methods provided in the embodiments of the present invention can achieve can be realized, as detailed in the preceding embodiments, and will not be repeated here.

[0080] The calibration method, system, computer equipment, and medium of an electronic compass provided by the embodiments of the present invention have been described in detail above. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A calibration method for an electronic compass, characterized in that, Based on a first positioning receiver and a second positioning receiver, the method includes: Obtain the latitude and longitude of the first positioning receiver at the first location and the second positioning receiver at the second location; The line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained based on the latitude and longitude of the first position and the second position. Obtain the angle value of the electronic compass aligned with the straight line formed by the first positioning receiver and the second positioning receiver; The angle value obtained by the electronic compass is compared with the angle value of the line formed by the first positioning receiver and the second positioning receiver to determine the deviation angle that the electronic compass needs to correct. The method of obtaining the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver based on the latitude and longitude of the first location and the second location includes: Calculate the average of the latitude and longitude of the first location and the second location; calculate the difference between the average longitude of the first location and the average longitude of the second location; calculate the difference between the average latitude of the first location and the average latitude of the second location. Based on the difference between the average longitude of the first position and the average longitude of the second position, the difference between the average latitude of the first position and the average latitude of the second position is used to obtain the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver.

2. The calibration method according to claim 1, characterized in that, Depend on Obtain the linear angle value of the straight line formed by the first positioning receiver and the second positioning receiver. ,in, , , , This represents the average longitude of the first positioning receiver. This represents the average latitude of the first positioning receiver. This represents the average longitude of the second positioning receiver. This represents the average latitude of the second positioning receiver.

3. The calibration method according to claim 2, characterized in that, Depend on α determines the deviation angle that the electronic compass needs to correct. α represents the angle value obtained by the electronic compass.

4. A calibration system for an electronic compass, characterized in that, include: A first positioning receiver, a second positioning receiver, and a terminal, wherein the terminal is used to perform the following steps: Obtain the latitude and longitude of the first positioning receiver at the first location and the second positioning receiver at the second location; The line angle value of the straight line formed by the first positioning receiver and the second positioning receiver is obtained based on the latitude and longitude of the first position and the second position. Obtain the angle value of the electronic compass aligned with the straight line formed by the first positioning receiver and the second positioning receiver; The angle value obtained by the electronic compass is compared with the angle value of the line formed by the first positioning receiver and the second positioning receiver to determine the deviation angle that the electronic compass needs to correct. The method of obtaining the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver based on the latitude and longitude of the first location and the second location includes: Calculate the average of the latitude and longitude of the first location and the second location; calculate the difference between the average longitude of the first location and the average longitude of the second location; calculate the difference between the average latitude of the first location and the average latitude of the second location. Based on the difference between the average longitude of the first position and the average longitude of the second position, the difference between the average latitude of the first position and the average latitude of the second position is used to obtain the line angle value of the straight line formed by the first positioning receiver and the second positioning receiver.

5. The calibration system according to claim 4, characterized in that, Depend on Obtain the linear angle value of the straight line formed by the first positioning receiver and the second positioning receiver. ,in, , , , This represents the average longitude of the first positioning receiver. This represents the average latitude of the first positioning receiver. This represents the average longitude of the second positioning receiver. This represents the average latitude of the second positioning receiver.

6. The calibration system according to claim 5, characterized in that, Depend on α determines the deviation angle that the electronic compass needs to correct. α represents the angle value obtained by the electronic compass.

7. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method of any one of claims 1 to 3.

8. A computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method according to any one of claims 1 to 3.

Citation Information

Patent Citations

  • Electronic compass calibrating method and terminal

    CN104884895A

  • Magnetic declination measuring method based on high-precision electronic compass

    CN113670283A