Map course correction method and device
By obtaining navigation information and correcting it at the hardware abstraction layer of the terminal device, the problem of real-time and stability of navigation software in processing navigation information is solved, ensuring that the user is always in the right direction, improving the real-time performance and user experience of navigation. .
Patent Information
- Application Number
- CN202310188069.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-01
- Publication Date
- 2024-09-03
AI Technical Summary
Due to the real-time requirements when processing navigation information, existing navigation software results in a large amount of data processing and a long time, which increases the risk of crash and affects the real-time performance and user experience of navigation. Heading errors are prone to occur especially when the vehicle is stopped.
By obtaining navigation information at the hardware abstraction layer of the terminal device, extracting heading information, correcting it when the driving speed or distance difference changes, and deciding whether to send new heading information to avoid repeated processing of COG data on the application side, using the system HAL layer Process heading information.
It reduces the processing burden on the application side, avoids heading errors, ensures that users are always in the correct direction, and improves the real-time nature of navigation and user experience.
Smart Images

Figure CN118584518A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of heading correction, and in particular to a map heading correction method and device. Background Art
[0002] At present, most terminal devices are equipped with software with navigation functions. These software are also called application terminals. When running the navigation function, they will first receive navigation information such as GPS data, and then the application terminal will directly process the navigation information to generate the direction information of the user's movement. Under this processing method, when the car is about to stop at a traffic light, due to the error in the navigation information, the heading information obtained by the navigation APP installed by the customer is wrong, and the entire navigation map will rotate from the correct direction to the wrong direction, causing the user to drive in the wrong direction.
[0003] However, in response to this problem, some terminal devices on the market have applications that can correct navigation information, thereby locking the direction and preventing it from rotating to the wrong direction. However, due to the real-time nature of navigation information, the application is required to correct each navigation information in real time, which greatly increases the amount of data and processing time of the application, increases the likelihood of crashes, affects the real-time nature of navigation, and affects the display of navigation information on the application during data processing, causing discomfort to the user experience in some navigation scenarios.
[0004] Therefore, a solution is urgently needed. Summary of the invention
[0005] The present invention aims to provide a method and device for correcting map heading, which are used to solve the problems existing in the background technology, so as to correct the map heading and avoid the occurrence of heading errors.
[0006] In order to achieve the above object, the technical solutions of the present invention are: A map heading correction method comprises the following steps: obtaining first navigation information of a moving object at a first time, extracting first heading information from the first navigation information, and sending the first heading information to an application end; obtaining second navigation information of the moving object at a second time, extracting second heading information from the second navigation information, and obtaining the driving speed of the moving object; judging whether the driving speed is within a preset speed range; if the driving speed is within the preset speed range, continuing to send the first heading information to the application end, and the application end generating relative moving direction information of the moving object according to the first heading information; and If the driving speed is not within the preset speed range, the second heading information is sent to the application end, and the application end generates relative moving direction information of the moving object according to the second heading information.
[0007] Optionally, acquiring first navigation information of a moving object at a first time and extracting first heading information from the first navigation information includes the following steps: acquiring the first navigation information through a hardware abstraction layer on a terminal; and obtaining the first heading information by decoding after the hardware abstraction layer obtains the first navigation information.
[0008] Optionally, the preset speed value is 5KM / H.
[0009] In order to further achieve the above object, the technical solution of the present invention also includes: A map heading correction method comprises the following steps: obtaining first navigation information of a mobile object at a first time and extracting first heading information from the first navigation information, sending the first heading information to an application end, and recording first driving position information at the first time; obtaining second navigation information of the mobile object at a second time and extracting second heading information from the second navigation information, obtaining second driving position information at the second time, and calculating a distance difference between the second driving position information and the first driving position information; judging whether the distance difference is within a preset distance range; if the distance difference is within the preset distance range, continuing to send the first heading information to the application end, and the application end generates relative moving direction information of the mobile object according to the first heading information; and if the distance difference is not within the preset distance range, sending the second heading information to the application end, and the application end generates relative moving direction information of the mobile object according to the second heading information.
[0010] Optionally, obtaining first navigation information of a mobile object and extracting first heading information from the first navigation information includes the following steps: obtaining the first navigation information through a hardware abstraction layer on a terminal; and obtaining the first heading information by decoding after the hardware abstraction layer obtains the first navigation information.
[0011] In order to further achieve the above object, the technical solution of the present invention also includes: A map heading correction method comprises the following steps: obtaining first navigation information of a moving object at a first time, extracting first heading information from the first navigation information, and sending the first heading information to an application end; obtaining first auxiliary correction information at the first time through a direction sensor; obtaining second navigation information of the moving object at a second time and extracting second heading information from the second navigation information; obtaining second auxiliary correction information at the second time through the direction sensor; judging whether the second auxiliary correction information is the same as the first auxiliary correction information; if the second auxiliary correction information is the same as the first auxiliary correction information, continuing to send the first heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the first heading information; if the second auxiliary correction information is not the same as the first auxiliary correction information, sending the second heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the second heading information.
[0012] Optionally, the first auxiliary correction information and the second auxiliary correction information are both numerical information acquired by the direction sensor.
[0013] In order to further achieve the above object, the technical solution of the present invention also includes: A map heading correction device comprises a first acquisition module, which is used to acquire first navigation information of a moving object at a first time and extract first heading information from the first navigation information; a second acquisition module, which is used to acquire second navigation information at a second time and extract second heading information from the second navigation information, and acquire the driving speed of the moving object at the second time; a judgment module, which is used to judge whether the driving speed is within a preset speed range; a first execution module, which is used to continue to send the first heading information to the application end if the driving speed is within the preset speed range, and enable the application end to generate relative moving direction information of the moving object according to the first heading information; and a second execution module, which is used to send the second heading information to the application end if the driving speed is not within the preset speed range, and enable the application end to generate relative moving direction information of the moving object according to the second heading information.
[0014] In order to further achieve the above object, the technical solution of the present invention also includes: A map heading correction device comprises: a first acquisition module, used to acquire first navigation information of a mobile object at a first time and extract first heading information from the first navigation information, send the first heading information to an application end, and record first driving position information at the first time; a second acquisition module, used to acquire second navigation information of the mobile object at a second time and extract second heading information from the second navigation information, acquire second driving position information at the second time, and calculate the distance difference between the second driving position information and the first driving position information; a judgment module, used to judge whether the distance difference is within a preset distance range; a first execution module, used to continue to send the first heading information to the application end if the distance difference is within the preset distance range, and the application end generates relative moving direction information of the mobile object according to the first heading information; and a second execution module, used to send the second heading information to the application end if the distance difference is not within the preset distance range, and the application end generates relative moving direction information of the mobile object according to the second heading information.
[0015] In order to further achieve the above object, the technical solution of the present invention also includes: A terminal device comprises a GPS module, a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of a map heading correction method as described above are implemented.
[0016] The present invention utilizes the technical solution provided by the present invention above. Before sending the second heading information, the driving speed, or the distance difference, or other auxiliary correction information is first confirmed. If the result after confirmation is within the preset range, the original first heading information is kept unchanged and the first heading information continues to be sent to the application end. If the result after confirmation is not within the preset range, the heading information needs to be changed, and the second heading information is sent to the application end instead, so as to ensure that the user is always in the correct direction when using it. The most important thing is that when processing COG data, it no longer relies on the application end to process, but uses the system HAL layer to directly process the COG data. When the HAL receives the COG data, it first processes the auxiliary correction information such as speed or distance. The value is corrected, and then it is decided whether to send new heading information, i.e., the second heading information, or to maintain the heading information already displayed on the user side, i.e., the first heading information. In this way, the application side no longer needs to process the COG data, but instead the system HAL layer executes it, thereby reducing the burden of data processing on the application side and avoiding the disadvantage of heading errors caused by not processing the COG but directly sending it to the user. It can be understood that the present invention provides a method for processing COG data before the COG data is directly sent to the application side, thereby realizing the correction of the map heading and avoiding the occurrence of heading errors, which well solves the shortcomings of the background technology, ensures that the user's driving direction is always in the correct direction, and provides an excellent user experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 A flowchart of a first embodiment of a map heading correction method of the present invention; Figure 2 is a flow chart of a second embodiment of a method for correcting map heading according to the present invention; Figure 3 is a flow chart of a third embodiment of a map heading correction method of the present invention; Figure 4 A schematic diagram of a terminal device according to an embodiment of the present invention; Figure 5 A schematic diagram of a map heading correction device according to an embodiment of the present invention; Figure 6 A schematic diagram of a terminal device according to another embodiment of the present invention. DETAILED DESCRIPTION
[0018] In order to make the technical problems, technical solutions and beneficial effects to be solved by the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0019] It should be noted that when an element is referred to as being "fixed to" or "disposed on" another element, it can be directly on the other element or indirectly on the other element. When an element is referred to as being "connected to" another element, it can be directly connected to the other element or indirectly connected to the other element.
[0020] It should be understood that the orientation or position relationship indicated by terms such as "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside" and "outside" are based on the orientation or position relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operate in a specific orientation, and therefore cannot be understood as a limitation on the present invention.
[0021] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined. Embodiment 1
[0022] Figure 1 The flowchart of a method for correcting the heading of a map in an embodiment of the present application is shown. The execution subject of the method may be an OS system in a terminal device. The terminal device may be a mobile phone, a tablet, a wearable device, or a notebook, etc., which has a GPS function. In other words, the execution subject of the method may be an operating system in a mobile phone, such as an Android system or an IOS system. The execution subject may also be an Android system or an iPadOS operating system in a tablet, or a watchOS or wearOS operating system in a smart wearable device, but is not limited thereto. Next, the method for correcting the heading of a map disclosed in the present embodiment is as follows: Figure 1 As shown, it includes the following steps: Step S101, obtaining first navigation information of a mobile object at a first time, extracting first heading information from the first navigation information, and sending the first heading information to the application end. In some embodiments, the mobile object can be a vehicle, a bicycle, an unmanned vehicle, a person, etc. Navigation information refers to a real-time display of traffic congestion and smoothness, which facilitates the driver to better choose the driving route, avoid congestion, accidents, etc., and reach the destination faster. In other words, navigation information is used to indicate one or more location-related information, such as longitude and latitude, speed, and direction angle, etc. (also called GPS data).
[0023] The heading information is the information in the navigation information that can be used to indicate the relative moving direction of the mobile object. To be more specific, the heading information can also be indicated as COG data in GPS data. COG, which stands for course over ground in English, can also be called ground heading (ground heading is the moving direction relative to the ground position). Its function is to indicate the relative moving direction information of the mobile object. In this embodiment, the first navigation information indicates the navigation information obtained in step S101. The first navigation information includes the first heading information. The first heading information refers to the information used to indicate the relative moving direction information of the mobile object. When the application end of the mobile object receives the first heading information in the first navigation information, the application end will generate the relative moving direction information of the mobile object according to the first heading information, thereby indicating that the mobile object moves in a specified direction.
[0024] It should be noted that, in this embodiment, step S101 is to obtain COG data and send the COG data to the navigation software of the terminal. Here, the COG data obtained in step S101 is defined as the first heading information.
[0025] In addition, the relative moving direction information generated after the application end recognizes the first heading information directly indicates the direction in which the mobile object needs to move. That is to say, in the corresponding step S101, the first heading information sent to the application end will include the above-mentioned relative moving direction information. Through the relative moving direction information, the mobile object is guided to move in a specific direction to realize the navigation function.
[0026] Next, as a preferred implementation, the implementation step of obtaining the first navigation information of the mobile object and extracting the first heading information from the first navigation information also includes obtaining the first navigation information through the hardware abstraction layer on the terminal, and the hardware abstraction layer obtains the first navigation information by decoding. In this embodiment, obtaining the first navigation information through the hardware abstraction layer on the terminal specifically refers to obtaining the first navigation information through the hardware abstraction layer on the terminal system. The hardware abstraction layer, the English name is Hardware Abstraction Layer), abbreviated as HAL, HAL can extract the first heading information in the first navigation information. For example, the HAL layer has an acquisition unit, and the acquisition unit can specifically read the first heading information in the GPS data (first navigation information). After receiving the GPS data sent by the GPS, the acquisition unit acquires the corresponding first heading information at this time, such as specific azimuth data, and then the HAL layer will send the azimuth data to the user's application end, and the application end will display the information of the relative moving direction used for the movement of the mobile object at this time.
[0027] In addition, regarding the acquisition of the azimuth data, the specific acquisition method is as follows: Since the GPS data includes NMEA (National Marine Electronics Association) data, the NMEA data will carry an RMC statement containing the above-mentioned azimuth data information, so after the acquisition unit identifies the GPS data, it will read the RMC statement in the corresponding NMEA data, thereby obtaining the azimuth data, and then the HAL layer will send the azimuth data to the application end of the terminal system.
[0028] More specifically, in the RMC statement, each sentence consists of multiple fields. When the azimuth data needs to be obtained, since the data displayed in the eighth field is the azimuth data, when obtaining the specific azimuth data, it is only necessary to obtain the eighth field of the RMC statement through the HAL acquisition unit. The following is an example of an RMC statement: $GNRMC,125248.00,A,4045.521096,N,07359.547364,W,18.4,215.7,180222,10.5,W,A,V*59.
[0029] In the above RMC statements, the styles can be simply divided into: $GPRMC, <1> , <2> , <3> , <4> , <5> , <6> , <7> , <8> , <9> , <10> , <11> , <12> *hh <cr> <lf>; From here we can see that the eighth field contains the direction angle data 215.7, so the acquisition unit only needs to acquire the eighth field of the RMC statement.
[0030] It should be noted that the above-mentioned direction angle data shows the direction information that a specific moving object needs to move, that is, the COG data, that is, the above-mentioned first heading information.
[0031] Then, after completing step S101, proceed to step S102, obtain the second navigation information of the mobile object at a second time, extract the second heading information from the second navigation information, and obtain the driving speed of the mobile object. Since the navigation information is updated in real time to ensure that the user always stays in the correct direction of movement, the navigation information obtained again after obtaining the first navigation information is defined as the second navigation information in step S102, and the heading information extracted from the second navigation information is positioned as the second heading information. It should be understood that the second time of step S102 refers to the first time that is slightly later than step S101, and the time difference between the first time and the second time can be determined based on the update time of the navigation information, so that the judgment of the subsequent steps is more accurate and timely, but is not limited to this.
[0032] Specifically, in step S102, the method of obtaining the second navigation information and the second heading information is consistent with the method of obtaining the first navigation information and the first heading information. However, after obtaining the second navigation information, it is not directly sent to the application end, but the driving speed at that time is first determined.
[0033] In addition, as a preferred implementation manner, the speed value of the driving speed is mainly referenced by the speed value of the GPS, and the speed value of the GPS has the highest accuracy. The system mainly obtains the speed value of the GPS through the HAL. When the HAL layer obtains the speed value of the GPS, the speed value of the GPS will be temporarily stored in the storage unit to form a variable value, which is convenient for subsequent calling during judgment.
[0034] Then, after completing step S102, enter step S103 to determine whether the driving speed is within the preset speed range. If it is within the preset speed range, continue to send the first heading information to the application end; if it is not within the preset speed range, send the second heading information to the application end.
[0035] The driving speed at this time refers to the driving speed of the object when the second navigation information is obtained, and the purpose of obtaining the speed value is to determine in step S103 whether new COG information, namely the second heading information, needs to be sent to the application end at this time.
[0036] In this embodiment, the system has pre-set a reference value of the speed to determine the value of the preset speed in step S103. For example, in some specific embodiments, the value of the preset speed can be set to 5 kilometers per hour, but it is not limited to this. The setting of the value can also be adjusted according to the actual road conditions and the characteristics of the moving object such as the vehicle itself. In other words, the speed value of the preset speed can be adjusted according to the actual usage requirements to meet different usage scenarios.
[0037] Furthermore, after obtaining the current speed of the moving object, the speed will be compared with the preset speed. After comparison, if the current speed is less than the preset speed, step S104 will be executed. If the speed is within the preset speed range, the first heading information will continue to be sent to the application end, and the application end will generate the relative moving direction information of the moving object according to the first heading information. That is, the first heading information will continue to be sent to the application end, and the application end will generate the relative moving direction information of the moving object according to the first heading information, and the navigation direction will remain unchanged.
[0038] In other words, the relative moving direction information of the moving object generated by the application at the second time can be the same as that generated at the first time. For example, if the moving object is a vehicle, when the user in the vehicle stops at a traffic light, the driving speed will be lower than the preset speed, and the application will still use the relative moving direction information generated by the first heading information, and will not use the second heading information generated at the second time, to prevent misjudgment and rotation of the entire navigation map to the wrong direction.
[0039] On the contrary, if the driving speed is greater than the preset speed, step S105 is executed. If the driving speed is not within the preset speed range, the second heading information is sent to the application end, and the application end generates the relative moving direction information of the moving object according to the second heading information. That is to say, the second heading information is sent to the application end at this time, and the application end generates the relative moving direction information of the moving object according to the second heading information, and reminds the user of the change in heading at this time.
[0040] In the traditional way, when the user stops in the car while waiting for the traffic light and the map on the application side needs to turn, the COG data is usually not processed and the heading information (i.e., the second heading information) obtained at this time is directly sent to the application side. Due to the error of GPS at this time, the system will assume that the car has turned successfully and use the new COG data to turn the heading of the map. After receiving the new map information, the user will default to driving on the new route, thereby wasting the user's time and affecting the user experience. However, through the above-mentioned embodiment of the present invention, the above-mentioned defects can be well overcome. In the above-mentioned embodiment, setting the value to 5km / h can be understood as the vehicle state is a low-speed driving state or a state of waiting for the traffic light. At this time, the heading information on the map is particularly critical, which determines the direction of the user's next drive. In this embodiment, through the above-mentioned processing method, the accuracy of the COG data is ensured, and the correctness of the client's map heading is guaranteed, thereby avoiding the wrong heading information provided in the traditional way and causing the navigation map to turn incorrectly.
[0041] The most critical point is that the method completes the special processing of this part of information in the HAL layer. Specifically, the HAL layer will first call the variable value, that is, the driving speed, from the above-mentioned storage unit and send it to the comparison unit. The comparison unit will compare the driving speed with the preset speed. Finally, the comparison result is returned to the HAL layer and the comparison result is used to determine whether to send the first heading information or the second heading information. Traditionally, if the navigation software wants to perform special processing on the COG data for correction, each COG data must be specially processed, which will greatly increase the processing volume of the navigation software and greatly increase the occurrence of the navigation software crash. The present invention can use the above-mentioned processing method. Under the intervention of the HAL layer, it is no longer necessary to rely on the function in the application end to realize the correction of the COG data, so that the display speed of the heading information in the application end is faster and more accurate. In addition to greatly avoiding the occurrence of heading errors, it can also avoid the application end crashing due to processing a large amount of COG data, and the user experience is excellent. Embodiment 2
[0042] Figure 2 This is a flow chart of a map heading correction method in an embodiment of the present application. The execution subject of this method is the same as the execution subject in Embodiment 1, and will not be repeated here.
[0043] like Figure 2 As shown, in this embodiment, the map heading correction method may include the following steps: step S201, obtaining first navigation information of a mobile object at a first time and extracting first heading information from the first navigation information, sending the first heading information to the application end, and recording the first driving position information at the first time; step S202, obtaining second navigation information of the mobile object at a second time and extracting second heading information from the second navigation information, and obtaining second driving position information at the second time, and calculating the distance difference between the second driving position information and the first driving position information; step S203, judging whether the distance difference is within the range of a preset distance; step S204, if the distance difference is within the range of the preset distance, continuing to send the first heading information to the application end, and the application end generates the relative moving direction information of the mobile object according to the first heading information; step S205, if the distance difference is not within the range of the preset distance, sending the second heading information to the application end, and the application end generates the relative moving direction information of the mobile object according to the second heading information.
[0044] In step S201 and step S202, the manner of obtaining the first navigation information, the first heading information, the second navigation information and the second heading information and other feasible methods are all consistent with the manner of obtaining the first navigation information, the first heading information, the second navigation information and the second heading information in embodiment one and other feasible methods are all consistent with the method of obtaining the first navigation information, the first heading information, the second navigation information and the second heading information in embodiment one, and will not be repeated here.
[0045] Then, the first driving position information is obtained mainly by obtaining the position information in the GPS data. When the first heading information is obtained, the position information at this time is also obtained and temporarily marked as the first position.
[0046] Then in step S202, the second heading information of the moving object is obtained at a second time and extracted therefrom, and the second driving position information at this time is recorded and temporarily marked as the second position, and then the difference between the first position and the second position is calculated, and the difference is the distance difference, and then step S203 is executed.
[0047] In step S203, the distance difference at this time is determined to determine whether the distance difference is within a preset distance range, thereby determining whether to execute step S204 or step S205.
[0048] In addition, the distance difference is mainly obtained by calculating the difference between the first position and the second position, wherein the system mainly obtains the distance difference through the HAL layer. After the HAL layer obtains the distance difference, it temporarily stores the distance difference in the storage unit to form a variable value, so as to facilitate its subsequent call during judgment.
[0049] In this embodiment, the system has pre-set a reference value of the difference, so as to determine the value of the preset distance in step S203, which can be set to 2 meters. In combination with step S203, after obtaining the distance difference between the second driving position information and the first driving position information, the distance difference will be compared with the preset distance. If the distance difference at this time is less than the preset distance, step S204 will be executed to continue to send the first heading information to the application end, and the application end will generate the relative moving direction information of the mobile object according to the first heading information, and keep the navigation direction unchanged. If the distance difference is greater than the preset distance at this time, step S205 will be executed to send the second heading information to the application end, and the application end will generate the relative moving direction information of the mobile object according to the first heading information, and remind the user of the heading change information at this time.
[0050] In addition, there may be a situation where the distance difference is negative, for example, when the user is reversing. In this case, it can be understood that the user missed a certain intersection and reversed. In this case, the first heading information should continue to be sent to the application to maintain the heading.
[0051] Then, in step S203, if the distance difference is greater than the preset distance, it is considered that the user is driving at a faster speed and the heading information needs to be updated in real time. In this case, the second heading information will be directly sent to the user end to ensure that the user can receive the latest heading information in time.
[0052] Through the above processing method, the accuracy of COG data is ensured, and the correctness of the client's map heading is guaranteed. The most critical point is that this method completes the special processing of this part of information in the HAL layer. In detail, the HAL layer will first call the variable value, that is, the distance difference, from the above storage unit, and send it to the comparison unit, and the comparison unit will compare the distance difference with the preset distance. Finally, the comparison result is returned to the HAL layer and the comparison result is used to decide whether to send the first heading information or the second heading information. Through the above processing method, with the intervention of the HAL layer, there is no need to rely on the functions in the application end to realize the correction of COG data, so that the display speed of the heading information in the application end is faster and more accurate, which greatly avoids the occurrence of heading errors, and can also avoid the application end crashing due to processing a large amount of COG data, and the user experience is excellent.
[0053] In addition, in step S202, obtaining the second navigation information of the mobile object at the second time and extracting the second heading information therefrom can be specifically understood as: the time for obtaining the second heading information at the second time is the unit time after obtaining the first heading information at the first time, and the unit time at this time is obtained by subtracting the first time from the second time, and can be set to 1 second, so that the difference between the first time and the second time is 1 second. The reason for this setting is: because the GPS data reporting frequency is 1Hz, when setting the unit time, it can be set to 1 second. If it is in some usage scenarios that do not require higher accuracy, it can also be set to 2 seconds, which can be changed according to the actual usage needs of the user.
[0054] It should be noted that, since the second driving position information is obtained while the second heading information is obtained, the above unit time is also the time difference between the first driving position information and the second driving position information.
[0055] In addition, it should be noted that the acquisition of the above-mentioned first heading information or the operation of numerical comparison are all performed in the HAL layer, so there is no need to rely on the application's own functions to realize the correction of COG data, so that the response of the heading information in the application is faster and more accurate, which greatly avoids heading errors.
[0056] In this embodiment, the HAL layer first calls the variable value, that is, the distance difference, from the storage unit and sends it to the comparison unit. The comparison unit compares the distance difference with the preset distance and finally returns the comparison result to the HAL layer and decides whether to send the first heading information or the second heading information based on the comparison result. Embodiment 3
[0057] Figure 3 The figure is a flow chart of a map heading correction method in an embodiment of the present application. The execution subject of the method is the same as that in the first embodiment, and will not be repeated here.
[0058] like Figure 3 As shown, the map heading correction method may include the following steps: step S301, obtaining first navigation information of a moving object at a first time, extracting first heading information from the first navigation information, and sending the first heading information to an application end; step S302, obtaining first auxiliary correction information at the first time through a direction sensor; step S303, obtaining second navigation information of the moving object at a second time and extracting second heading information from the second navigation information; step S304, obtaining second auxiliary correction information at the second time through the direction sensor; step S305, judging whether the second auxiliary correction information is the same as the first auxiliary correction information; step S306, if the second auxiliary correction information is the same as the first auxiliary correction information, continuing to send the first heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the first heading information; step S307, if the second auxiliary correction information is not the same as the first auxiliary correction information, sending the second heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the second heading information.
[0059] In step S301 and step S303, the manner of obtaining the first navigation information, the first heading information, the second navigation information and the second heading information and other achievable methods are consistent with the method of obtaining the first navigation information, the first heading information, the second navigation information and the second heading information in Example 1, and are not repeated here.
[0060] Next, the first auxiliary correction information in step S302 and the second auxiliary correction information in step S304 can both be understood as auxiliary information for correcting the map heading, so as to determine whether to send the first heading information or the second heading information to the application end, which can be various types of information such as: time information, speed information, distance information and other information realized by other systems or transmission data. Their use in this embodiment is to determine whether it is necessary to send new heading information to the user. Among them, in step S102 and step S104, the first auxiliary correction information and the second auxiliary correction information can be obtained through a direction sensor. The direction sensor is a relatively common device for providing a specific driving direction. Specifically, the first auxiliary correction information can be the value of the direction sensor at the first time, and the second auxiliary correction information can be the value of the direction sensor at the second time. At this time, the value on the direction sensor represents a specific direction. The function of this direction is the same as that of the heading information, which also refers to the direction information of the moving object. In layman's terms, in actual use, the user only needs to determine whether the values of the two direction sensors are consistent. If they are consistent, it means that the directions are consistent, and the first heading information will continue to be sent to the user end. If they are inconsistent, it means that the value of the direction sensor has changed. At this time, the actual direction that the moving object needs to travel has changed. Therefore, new heading information, namely the second heading information, needs to be sent to the user end to ensure the correct direction of travel.
[0061] In this embodiment, the acquisition of the value of the direction sensor is also implemented in the HAL layer. When the HAL layer obtains the value of the direction sensor, it will temporarily store the value of the direction sensor in a storage unit to form a variable value, so that it can be called later during judgment. Then the HAL layer will call the variable value, that is, the value of the direction sensor, from the storage unit and send it to the judgment unit. The judgment unit will judge whether the value of the direction sensor has changed. Finally, the result is returned to the HAL layer and the comparison result is used to decide whether to send the first heading information or the second heading information to the user application end. Embodiment 4
[0062] See also Figure 4 In this embodiment, a terminal device 400 is provided, including a GPS module 410, a memory 420, a processor 430, and a computer program 422 stored in the memory 420 and executable on the processor 430. When the processor 430 executes the computer program 422, the steps of the map heading correction method described in any one of the above embodiments 1-2 are implemented. In order to implement the above functions, the terminal device 400 of this embodiment includes: at least one processor 430 ( Figure 4 Only one is shown in the figure), a memory 420 that is in communication with the processor 430, and a computer program 422 stored in the memory 420 and executable on the at least one processor 430, such as a navigation information acquisition program, a driving speed acquisition program, or a speed determination program. When the processor 430 executes the computer program 422, the following is realized as in Example 1. Figure 1 Steps S101 to S105 shown in the figure and in Example 2 Figure 2 Steps 201 to S205 are shown.
[0063] Exemplarily, the computer program 422 may be divided into one or more modules, which are stored in the memory 420 and executed by the processor 430 to implement the present invention. The one or more modules may be a series of computer program instruction segments capable of implementing specific functions, which are used to describe the execution process of the computer program 522 in the terminal device 400.
[0064] In addition, it should be noted that the processor 430 may be a central processing unit (CPU), and the processor 430 may also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.
[0065] In some embodiments, the memory 420 may be an internal storage unit of the terminal device 4, such as a hard disk or memory of the terminal device 4. In other embodiments, the memory 420 may also be an external storage device of the terminal device 4, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the terminal device 4. Further, the memory 420 may include both an internal storage unit and an external storage device of the terminal device 4. The memory 420 is used to store an operating system, an application program, a boot loader, data, and other programs, such as the program code of the computer program. The memory 420 may also be used to temporarily store data that has been output or is to be output.
[0066] As an optional implementation, taking the example of Embodiment 1 of the present invention as an example, refer to Figure 5 , a map heading correction device 500 is provided, which is connected to a GPS module 510, and includes a first acquisition module 501, a second acquisition module 502, a judgment module 503, a first execution module 504 and a second execution module 505. The first acquisition module 501 is used to acquire first navigation information of a mobile object at a first time and extract first heading information from the first navigation information; the second acquisition module 502 is used to acquire second navigation information at a second time and extract second heading information from the second navigation information, and acquire the driving speed of the mobile object at the second time; the judgment module 503 is used to determine whether the driving speed is within a preset speed range; the first execution module 504 is used to continue to send the first heading information to the application end if the driving speed is within the preset speed range, and enable the application end to generate the relative moving direction information of the mobile object according to the first heading information; the second execution module 505 is used to send the second heading information to the application end if the driving speed is not within the preset speed range, and enable the application end to generate the relative moving direction information of the mobile object according to the second heading information. The methods and principles of each module to implement its respective functions are the same as those in the first embodiment, and will not be repeated here. Figure 5 The GPS module 510 is outside the map heading correction device 500 , but the present invention is not limited thereto. In one embodiment, the GPS module 510 may also be included in the map heading correction device 500 .
[0067] As another optional implementation, taking the example of Embodiment 2 of the present invention as an example, refer to Figure 5 , a map heading correction device 500 is provided which is connected to a GPS module 510 and includes a first acquisition module 501 , a second acquisition module 502 , a judgment module 503 , a first execution module 504 and a second execution module 505 . Among them, the first acquisition module 501 is used to acquire the first navigation information of a mobile object at a first time and extract the first heading information from the first navigation information, and send the first heading information to the application end, and record the first driving position information at the first time; the second acquisition module 502 is used to acquire the second navigation information of the mobile object at a second time and extract the second heading information from the second navigation information, and acquire the second driving position information at the second time, and calculate the distance difference between the second driving position information and the first driving position information; the judgment module 503 is used to judge whether the distance difference is within the range of the preset distance; the first execution module 504 is used to continue to send the first heading information to the application end if the distance difference is within the range of the preset distance, and the application end generates the relative moving direction information of the mobile object according to the first heading information; and the second execution module 505 is used to send the second heading information to the application end if the distance difference is not within the range of the preset distance, and the application end generates the relative moving direction information of the mobile object according to the second heading information. The methods and principles of each module to implement its respective functions are the same as those in the second embodiment, and will not be repeated here. Figure 5 The GPS module 510 is outside the map heading correction device 500, but the present invention is not limited thereto. In one embodiment, the GPS module 510 may also be included in the map heading correction device 500. Embodiment 5
[0068] See also Figure 6 In this embodiment, a terminal device 600 is provided, which includes a GPS module 610, a memory 620, a processor 630, a computer program 622 stored in the memory 620 and executable on the processor 630, and a direction sensor 640. When the processor 630 executes the computer program 622, steps S301-S307 of the map heading correction method described in the above embodiment 3 are implemented. In order to implement the above functions, the terminal device 600 of this embodiment includes: at least one processor 630 ( Figure 6 Only one is shown in the figure), a memory 620 that is in communication with the processor 630, and a computer program 622 stored in the memory 620 and executable on the at least one processor 630, such as a navigation information acquisition program, a driving speed acquisition program, or a speed determination program. When the processor 630 executes the computer program 622, the following is realized as in Example 3. Figure 3 The terminal device 600 may include, but is not limited to, a processor 630, a memory 620, and a direction sensor 640. Those skilled in the art will appreciate that Figure 6 It is only an example of the terminal device 600 and does not constitute a limitation on the terminal device 600. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, it may also include input and output devices, network access devices, buses, etc.
[0069] As an optional implementation, taking the example of Embodiment 3 of the present invention as an example, refer to Figure 5 , a map heading correction device 500 is provided which is connected to a GPS module 510 and includes a first acquisition module 501 , a second acquisition module 502 , a judgment module 503 , a first execution module 504 and a second execution module 505 . Among them, the first acquisition module 501 is used to acquire the first navigation information of a mobile object at the first time, and extract the first heading information from the first navigation information, and send the first heading information to the application end, and acquire the first auxiliary correction information at the first time through a direction sensor; the second acquisition module 502 is used to acquire the second navigation information of the mobile object at the second time and extract the second heading information from the second navigation information, and acquire the second auxiliary correction information at the second time through the direction sensor; the judgment module 503 is used to judge whether the second auxiliary correction information is the same as the first auxiliary correction information; the first execution module 504 is used to continue to send the first heading information to the application end if the second auxiliary correction information is the same as the first auxiliary correction information, and the application end generates the relative moving direction information of the mobile object according to the first heading information; the second execution module 505 is used to send the second heading information to the application end if the second auxiliary correction information is not the same as the first auxiliary correction information, and the application end generates the relative moving direction information of the mobile object according to the second heading information. Among them, the methods and principles for each module to implement its respective functions are the same as the methods and principles in Example 3, and will not be repeated here. It should be noted that although in Figure 5 The GPS module 510 is outside the map heading correction device 500 , but the present invention is not limited thereto. In one embodiment, the GPS module 510 may also be included in the map heading correction device 500 .
[0070] In summary, by utilizing the technical solution provided by the present invention, before sending the second heading information, the driving speed, or the distance difference, or other auxiliary correction information is first confirmed. If the result after confirmation is within the preset range, the original first heading information is kept unchanged and the first heading information continues to be sent to the application end. If the result after confirmation is not within the preset range, the heading information needs to be changed, and the second heading information is sent to the application end instead, thereby ensuring that the user is always in the correct direction when using it. The most important thing is that when processing COG data, it no longer relies on the application end to process, but uses the system HAL layer to directly process the COG data. When the HAL receives the COG data, it first processes the auxiliary correction information such as speed or distance. The value is corrected, and then it is decided whether to send new heading information, i.e., the second heading information, or to maintain the heading information already displayed on the user side, i.e., the first heading information. In this way, the application side no longer needs to process the COG data, but instead the system HAL layer executes it, thereby reducing the burden of data processing on the application side and avoiding the disadvantage of heading errors caused by not processing the COG but directly sending it to the user. It can be understood that the present invention provides a method for processing COG data before the COG data is directly sent to the application side, thereby realizing the correction of the map heading and avoiding the occurrence of heading errors, which well solves the shortcomings of the background technology, ensures that the user's driving direction is always in the correct direction, and provides an excellent user experience.
[0071] In addition, those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the above-mentioned device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0072] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0073] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0074] In the embodiments provided in the present application, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are only schematic. For example, the division of the above modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0075] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0076] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0077] If the above-mentioned integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program. The above-mentioned computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the above-mentioned computer program includes computer program code, and the above-mentioned computer program code can be in source code form, object code form, executable file or some intermediate form. The above-mentioned computer-readable medium may at least include: any entity or device that can carry the computer program code to the camera / terminal device, recording medium, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, RandomAccess Memory), electric carrier signal, telecommunication signal and software distribution medium. For example, a USB flash drive, a mobile hard disk, a disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.
[0078] According to the disclosure and teaching of the above description, those skilled in the art to which the present invention belongs may also make changes and modifications to the above embodiments. Therefore, the present invention is not limited to the specific embodiments disclosed and described above, and some modifications and changes to the present invention should also fall within the scope of protection of the claims of the present invention. In addition, although some specific terms are used in this specification, these terms are only for the convenience of description and do not constitute any limitation to the present invention.< / lf> < / cr>
Claims
1. A map heading correction method, characterized in that: The steps include: Acquire first navigation information of a mobile object at a first time, extract first heading information from the first navigation information, and send the first heading information to an application end; Acquire second navigation information of the mobile object at a second time, extract second heading information from the second navigation information, and acquire a travel speed of the mobile object; Determining whether the driving speed is within a preset speed range; If the driving speed is within the range of the preset speed, the first heading information continues to be sent to the application end, and the application end generates the relative moving direction information of the moving object according to the first heading information; and If the driving speed is not within the preset speed range, the second heading information is sent to the application end, and the application end generates relative moving direction information of the moving object according to the second heading information.
2. The map heading correction method according to claim 1, characterized in that: Acquiring first navigation information of a mobile object at a first time and extracting first heading information from the first navigation information comprises the following steps: Acquiring the first navigation information through a hardware abstraction layer on the terminal; and After obtaining the first navigation information, the hardware abstraction layer obtains the first heading information through decoding.
3. The map heading correction method according to claim 1, characterized in that: The speed value of the preset speed is 5KM / H.
4. A map heading correction method, characterized in that: The steps include: Acquire first navigation information of a moving object at a first time, extract first heading information from the first navigation information, send the first heading information to an application, and record first driving position information at the first time; Acquire second navigation information of the mobile object at a second time, extract second heading information from the second navigation information, acquire second driving position information at the second time, and calculate a distance difference between the second driving position information and the first driving position information; Determining whether the distance difference is within a preset distance range; If the distance difference is within the range of the preset distance, continue to send the first heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the first heading information; and If the distance difference is not within the preset distance range, the second heading information is sent to the application end, and the application end generates relative moving direction information of the moving object according to the second heading information.
5. The map heading correction method according to claim 4, characterized in that: Acquiring first navigation information of a mobile object and extracting first heading information from the first navigation information comprises the following steps: Acquiring the first navigation information through a hardware abstraction layer on the terminal; and After obtaining the first navigation information, the hardware abstraction layer obtains the first heading information through decoding.
6. A map heading correction method, characterized in that: The steps include: Acquire first navigation information of a mobile object at a first time, extract first heading information from the first navigation information, and send the first heading information to an application end; Acquiring first auxiliary correction information at the first time through a direction sensor; Acquire second navigation information of the mobile object at a second time and extract second heading information from the second navigation information; acquiring, by the direction sensor, second auxiliary correction information at the second time; determining whether the second auxiliary correction information is the same as the first auxiliary correction information; If the second auxiliary correction information is the same as the first auxiliary correction information, continue to send the first heading information to the application end, and the application end generates the relative moving direction information of the moving object according to the first heading information; If the second auxiliary correction information is different from the first auxiliary correction information, the second heading information is sent to the application end, and the application end generates relative moving direction information of the moving object according to the second heading information.
7. The map heading correction method according to claim 6, characterized in that: The first auxiliary correction information and the second auxiliary correction information are both numerical information acquired by the direction sensor.
8. A map heading correction device, characterized in that: include: A first acquisition module, used for acquiring first navigation information of a mobile object at a first time and extracting first heading information from the first navigation information; A second acquisition module, configured to acquire second navigation information at a second time, extract second heading information from the second navigation information, and acquire a travel speed of the mobile object at the second time; A judging module, used for judging whether the driving speed is within a preset speed range; A first execution module, configured to continue to send the first heading information to the application end if the driving speed is within the preset speed range, and enable the application end to generate relative moving direction information of the moving object according to the first heading information; The second execution module is used to send the second heading information to the application end if the driving speed is not within the preset speed range, and enable the application end to generate the relative moving direction information of the moving object according to the second heading information.
9. A map heading correction device, characterized in that: include: A first acquisition module, configured to acquire first navigation information of a moving object at a first time, extract first heading information from the first navigation information, send the first heading information to an application end, and record first driving position information at the first time; a second acquisition module, configured to acquire second navigation information of the mobile object at a second time, extract second heading information from the second navigation information, acquire second driving position information at the second time, and calculate a distance difference between the second driving position information and the first driving position information; A judging module, used to judge whether the distance difference is within a preset distance range; A first execution module, configured to continue to send the first heading information to the application end if the distance difference is within the preset distance range, and the application end generates relative moving direction information of the moving object according to the first heading information; and The second execution module is used to send the second heading information to the application end if the distance difference is not within the preset distance range, and the application end generates the relative moving direction information of the moving object according to the second heading information.
10. A terminal device, comprising a GPS module, a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the map heading correction method according to any one of claims 1 to 3 are implemented.
