A timekeeping method, device, electronic device and storage medium

By using constant temperature crystal oscillator and optimal calibration weight in radar networking system, the problem of difficult to achieve high-precision punctual function in complex environments is solved, and the punctual effect of time error less than 1us within 48 hours is achieved, satisfying the radar Time synchronization requirements for networking systems.

CN115032665BActive Publication Date: 2025-02-07四川九洲防控科技有限责任公司
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210238393.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-11
Publication Date
2025-02-07
Estimated Expiration
2042-03-11

AI Technical Summary

Technical Problem

In the low-altitude defense radar networking system, there are problems that high-precision punctuality functions are difficult to achieve, especially when the power supply is powered off for a long time, satellite signal disappears, extreme temperatures or strong electromagnetic interference.

Method used

By using constant temperature crystal oscillator and corresponding optimal calibration weights, high-precision punctuality for 48 hours in complex environments, with a time error of less than 1 us. The method includes obtaining the power supply method indication signal, crystal oscillator status information and time reference signal when determining the satellite time signal reception abnormality, selecting the target constant temperature crystal oscillator, determining the optimal calibration weight according to the power supply method and crystal oscillator status, and adjusting the time count to generate a perpetual calendar time.

Benefits of technology

It achieves high-precision and punctuality for a long time in extreme environments, meets the time synchronization needs of the radar networking system, and ensures the stability and reliability of the radar system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115032665B_ABST
    Figure CN115032665B_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of radar, and specifically relates to a timekeeping method, device, electronic device and storage medium. The invention proposes a timekeeping method, device, electronic device and storage medium. This application uses a constant temperature crystal oscillator and the corresponding optimal calibration weights to achieve a timekeeping accuracy of less than 1us for 48 consecutive hours under conditions of long-term power failure, disappearance of satellite signals, extreme temperatures, and strong electromagnetic interference, meeting the time synchronization requirements of the radar networking system. A timekeeping method, suitable for a timekeeping module of a radar, includes: when determining that the reception of a satellite time signal is abnormal, obtaining a power supply mode indication signal, crystal oscillator status information, and a time reference signal issued by a control end; selecting a target constant temperature crystal oscillator according to the crystal oscillator status information; and determining a power supply mode according to the power supply mode indication signal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of radar, and specifically relates to a timekeeping method, device, electronic equipment and storage medium. Background Art

[0002] In the low-altitude defense radar networking system, the time synchronization requirements are very high, and each subsystem radar is required to have a high-precision timekeeping function. Due to the complex use environment, it is easy to have power failures for a long time, satellite signals disappear, extreme temperatures, strong electromagnetic interference, etc. in wartime or special geographical environments. In this case, it is difficult to achieve high-precision and long-term timekeeping functions. Radar networking, each radar needs to report real-time processed data to a terminal.

[0003] In order to ensure the accuracy of the local PPS signal, the existing radar clock timing module is mostly implemented with a high-precision atomic clock. It is highly dependent on the indicators of the atomic clock. The timing accuracy is mainly determined by the atomic clock, and the cost is relatively high. Summary of the invention

[0004] In view of the above technical problems, the present invention proposes a timekeeping method, device, electronic device and storage medium. The present application achieves a timekeeping accuracy of less than 1us for 48 consecutive hours under the conditions of long-term power failure, disappearance of satellite signals, extreme temperature and strong electromagnetic interference through a constant temperature crystal oscillator and the corresponding optimal calibration weight, meeting the time synchronization requirements of the radar networking system.

[0005] To solve the above technical problems, the technical solution adopted by the present invention includes four aspects.

[0006] In a first aspect, a timekeeping method is provided, which is applicable to a timekeeping module of a radar, including: when it is determined that the reception of a satellite time signal is abnormal, obtaining a power supply mode indication signal, crystal oscillator status information, and a time reference signal issued by a control terminal; selecting a target constant temperature crystal oscillator according to the crystal oscillator status information; determining a power supply mode according to the power supply mode indication signal; determining a target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode; and adjusting a time count according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time.

[0007] In some embodiments, the power supply method includes: powering by a power adapter, and determining the optimal calibration weight based on the target constant temperature crystal oscillator and the power supply method includes: when the power supply method is powering by the power adapter, obtaining the target optimal calibration weight corresponding to the target constant temperature crystal oscillator in the storage device.

[0008] In some embodiments, the power supply mode includes: battery power supply; determining the optimal calibration weight based on the target constant temperature crystal oscillator and the power supply mode includes: when the power supply mode is battery power supply, obtaining the power weight coefficient table corresponding to the target constant temperature crystal oscillator and the current power value of the battery, wherein the power weight coefficient table includes the correspondence between the power value and the optimal calibration weight; determining the target optimal calibration weight based on the current power value and the power weight coefficient table.

[0009] In some embodiments, determining the optimal calibration weight based on the current power value and the power weight coefficient table includes: when the current power value is less than the minimum power value in the power weight coefficient table, calculating the target optimal calibration weight based on the current power value to the functional relationship, wherein the functional relationship is obtained by fitting the power value in the power weight coefficient table with the optimal calibration weight.

[0010] In some embodiments, the method also includes: determining whether the power supply of the external input power supply is normal; when it is determined that the external input power supply is normal, using a power adapter for power supply and generating a power supply mode indication signal; when it is determined that the external input power supply is abnormal, using a battery for power supply, generating a power supply mode indication signal and outputting the current battery power value in real time.

[0011] In some embodiments, the constant temperature crystal oscillator includes: a main constant temperature crystal oscillator and a backup constant temperature crystal oscillator; the selecting a target constant temperature crystal oscillator according to the crystal oscillator status information includes: determining whether there is a high-level signal based on the crystal oscillator status information; determining the constant temperature crystal oscillator corresponding to the high-level signal as the target constant temperature crystal oscillator; wherein, when a high-level signal exists in the main constant temperature crystal oscillator, the main constant temperature crystal oscillator is preferentially selected as the target constant temperature crystal oscillator.

[0012] In some embodiments, the method also includes: preheating the constant temperature crystal oscillator to stabilize the frequency output by the constant temperature crystal oscillator; obtaining the calibration status flag of the constant temperature crystal oscillator; when the calibration status flag is at a high level, determining whether a calibration command sent by a control end is received; when the calibration command is received, performing adaptive frequency calibration on the constant temperature crystal oscillator; when the calibration status flag is at a low level, performing adaptive frequency calibration on the constant temperature crystal oscillator.

[0013] In some embodiments, the temperature controlled crystal oscillator is adaptively calibrated, including: firstly performing the adaptive frequency calibration on the main temperature controlled crystal oscillator under the power supply of a power adapter, and then performing the adaptive frequency calibration on the backup temperature controlled crystal oscillator; then performing the adaptive frequency calibration on the main temperature controlled crystal oscillator under the power supply of a battery, and then performing the adaptive frequency calibration on the backup temperature controlled crystal oscillator.

[0014] In some embodiments, the method further includes: determining whether the power supply mode satisfies a calibration sequence; and generating an error self-check code to prompt a change in the power supply mode if the power supply mode does not satisfy the calibration sequence.

[0015] In some embodiments, the method first performs the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of a power adapter, and then performs the adaptive frequency calibration on the standby constant temperature crystal oscillator, including: presetting a calibration period of T, and dividing the calibration period into D unit time lengths; obtaining the jth second pulse output by the positioning and orientation card in the i-th unit time; obtaining the kth second pulse output by the main constant temperature crystal oscillator in the i-th unit time; determining the i-th clock deviation number of the k-th second pulse relative to the j-th second pulse according to the number of rising edges of the j-th second pulse and the number of rising edges of the k-th second pulse; comparing the i-th clock deviation number with a first threshold; when the i-th clock deviation number is greater than the first threshold, determining the i-th correction weight according to the i-th clock deviation number; determining whether the i-th correction weight meets the optimization condition; when it is determined that the i-th correction weight meets the optimization condition, writing the i-th correction weight into the storage device as the first optimal calibration weight; wherein i, j, and k are all positive integers less than or equal to D.

[0016] In some embodiments, when it is determined that the i-th corrected weight satisfies the optimization conditions, the i-th corrected weight is regarded as the first optimal calibration weight and written into the storage device, including: when the number of i+1-th clock deviations is less than the first threshold, the i-th corrected weight is regarded as the first optimal calibration weight and written into the storage device; when i is equal to D, the i-th corrected weight is regarded as the first optimal calibration weight and written into the storage device.

[0017] In some embodiments, the adaptive frequency calibration is first performed on the main constant temperature crystal oscillator under battery power, and then the adaptive frequency calibration is performed on the backup constant temperature crystal oscillator, including: calibrating the main constant temperature crystal oscillator for N calibration cycles, and the total duration of the N calibration cycles is greater than or equal to a first time threshold; obtaining a first optimal calibration weight; obtaining the corresponding number of rising edges of second pulses generated by the main constant temperature crystal oscillator for each unit duration in the current cycle; determining the number of clock deviations corresponding to each unit duration in the current cycle according to the corresponding number of rising edges of second pulses and the first optimal calibration weight; obtaining the number of clock deviations corresponding to each unit duration in all the current cycles, and weighted averaging all the clock deviation numbers to obtain a second optimal calibration weight corresponding to the current cycle; obtaining the battery power of the current cycle, and writing the battery power and the second optimal calibration weight corresponding to the storage device to form the power weight coefficient table corresponding to the main constant temperature crystal oscillator.

[0018] In some embodiments, the method also includes: when it is determined that the reception of the satellite time signal is normal, receiving the satellite time signal and the satellite second pulse; selecting a target constant temperature crystal oscillator; generating a perpetual calendar and a crystal second pulse using the frequency of the constant temperature crystal oscillator as the clock frequency; and performing timing alignment on the perpetual calendar and the crystal second pulse according to the satellite time signal and the satellite second pulse.

[0019] In the second aspect, the present application provides a timekeeping device, including: a first determination module, used to determine the reception of satellite time signals and determine whether the reception of the satellite time signals is normal. A first acquisition module, used to obtain a power supply mode indication signal, crystal oscillator status information and a time reference signal issued by a control terminal when it is determined that the reception of the satellite time signal is abnormal; a selection module, used to select a target constant temperature crystal oscillator according to the crystal oscillator status information; a second determination module, used to determine the power supply mode according to the power supply mode indication signal; a second acquisition module, used to determine the target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode; a first working module, used to adjust the time count according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time.

[0020] A third aspect provides an electronic device, comprising a storage and a processor, wherein the storage stores a computer program, and the processor implements the steps of any one of the timekeeping methods in the first aspect when executing the computer program.

[0021] The fourth aspect provides a storage medium, which stores a computer program that can be executed by one or more processors, and the computer program can be used to implement the steps of any timekeeping method in the first aspect.

[0022] Beneficial effects of the invention: The invention uses a constant temperature crystal oscillator and the corresponding optimal calibration weights to achieve a timekeeping accuracy of less than 1us for 48 consecutive hours when the satellite signal disappears for a long time, meeting the time synchronization requirements of the radar networking system. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] The scope of the present disclosure may be better understood by reading the following detailed description of exemplary embodiments in conjunction with the accompanying drawings. The drawings included are:

[0024] Figure 1 An overall flow chart of a timekeeping method provided in an embodiment of the present application;

[0025] Figure 2 An overall flow chart of another timekeeping method provided in an embodiment of the present application;

[0026] Figure 3 An overall flow chart of the operation of a timekeeping module provided in an embodiment of the present application;

[0027] Figure 4 A flow chart of maintaining the temperature of a timekeeping module provided in an embodiment of the present application;

[0028] Figure 5 A flow chart of adaptive frequency calibration of a constant temperature crystal oscillator provided in an embodiment of the present application;

[0029] Figure 6 An overall flow chart of a timekeeping function provided in an embodiment of the present application;

[0030] Figure 7 A structural block diagram of a timekeeping device provided in an embodiment of the present application;

[0031] Figure 8 A structural block diagram of a radar timekeeping module provided in an embodiment of the present application. DETAILED DESCRIPTION

[0032] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.

[0033] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0034] If similar descriptions of "first\second\third" appear in the application documents, the following instructions will be added. In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged in a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.

[0035] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.

[0036] Embodiment 1:

[0037] In view of the problems existing in the background technology, such as Figure 1As shown, the present application provides a timekeeping method, which is applied to a timekeeping module of a radar. The function implemented by the device data processing provided in the embodiment of the present application can be implemented by calling a program code by a processor of an electronic device, wherein the program code can be stored in a computer storage medium, and the timekeeping method includes:

[0038] Step S11: Determine the reception status of the satellite time signal and determine whether the reception of the satellite time signal is normal.

[0039] Here, judging the reception of the satellite time signal refers to whether the radar can receive the satellite time signal or whether the radar can correctly analyze the satellite time signal after receiving the satellite time signal. If the radar cannot receive the satellite time signal or cannot correctly analyze the satellite time signal, it is judged that the reception of the satellite time signal is abnormal.

[0040] Step S12: When it is determined that the satellite time signal reception is abnormal, a power supply mode indication signal, crystal oscillator status information and a time reference signal sent by the control terminal are obtained.

[0041] Since this application is aimed at the low-altitude defense radar networking system, the time synchronization in the entire low-altitude defense radar networking system needs to be consistent. Therefore, the time of the control end needs to be used as the reference. Therefore, it is necessary to obtain the time reference signal issued by the control end.

[0042] Step S13: selecting a target constant temperature crystal oscillator according to the crystal oscillator status information.

[0043] In order to ensure the stability of the timekeeping and increase the fault tolerance of the radar, two constant temperature crystal oscillators are installed in the radar. They are the main constant temperature crystal oscillator and the backup constant temperature crystal oscillator. Due to product differences, the output frequencies of the main constant temperature crystal oscillator and the backup constant temperature crystal oscillator will be different. Therefore, when executing the timekeeping, you need to select the constant temperature crystal oscillator first.

[0044] In some embodiments, step S13 of "selecting a target constant temperature crystal oscillator according to the crystal oscillator state information" includes:

[0045] Step S131: determining whether there is a high level signal based on the crystal oscillator status information.

[0046] Step S132: determining the constant temperature crystal oscillator corresponding to the high-level signal as the target constant temperature crystal oscillator.

[0047] When a high-level signal exists in the main constant-temperature crystal oscillator, the main constant-temperature crystal oscillator is preferentially selected as the target constant-temperature crystal oscillator.

[0048] When selecting a constant temperature crystal oscillator, it is necessary to perform a self-test on the constant temperature crystal oscillator. During the self-test, the system clock and the clock of the constant temperature crystal oscillator need to be input into the internal phase-locked loop. The constant temperature crystal oscillator is judged to be normal based on the signal carried by the internal phase-locked loop.

[0049] First, the main constant temperature crystal oscillator is self-checked. If the internal phase-locked loop's carrying signal is high during the self-check of the main constant temperature crystal oscillator, the main constant temperature is the target constant temperature crystal oscillator. If the internal phase-locked loop's carrying signal is low, the standby constant temperature crystal oscillator is self-checked. The self-check method of the standby constant temperature crystal oscillator is the same as that of the main constant temperature crystal oscillator, so it will not be repeated here.

[0050] Step S14: determining a power supply mode according to the power supply mode indication signal.

[0051] For radar, there are two power supply modes: one is powered by a power adapter, and the other is powered by a battery. Different power supply modes will generate corresponding power supply mode indication signals, so the power supply mode can be judged by the power supply mode indication signal.

[0052] In some embodiments, the method further comprises:

[0053] Step S21: Determine whether the power supply of the external input power is normal.

[0054] Here, the power supply condition of the external input power supply is judged on the stability of the external input power supply. If the voltage of the external input power supply is stable, it is considered that the power supply of the external input power supply is normal. If the power supply condition of the external input power supply cannot be obtained or the voltage of the external input power supply is unstable, it is considered that the power supply of the external input power supply is abnormal.

[0055] Step S22: When it is determined that the external input power supply is normal, a power adapter is used for power supply, and a power supply mode indication signal is generated.

[0056] Step S23: When it is determined that the external input power supply is abnormal, the battery is used for power supply, a power supply mode indication signal is generated, and the current battery power value is output in real time.

[0057] In this application, the two power supply modes can be switched automatically. When the external power supply is off, it automatically switches to battery power supply. When the external input power supply is normal, it switches back to the power adapter power supply mode, so that the two power supply modes are automatically and seamlessly switched. When the power is supplied by the power adapter, the battery is also charged at the same time to ensure the effective working time of the radar.

[0058] The two power supply modes switch seamlessly, making the radar work longer and better ensuring the accuracy of radar timekeeping.

[0059] Step S15: determining a target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode.

[0060] Since there are product differences between constant temperature crystal oscillators, the output frequencies of the main constant temperature crystal oscillator and the backup constant temperature crystal oscillator will be different, so when performing timekeeping, the corresponding optimal calibration weights are also different. Therefore, the target optimal calibration weight here needs to correspond to the constant temperature crystal oscillator used.

[0061] Under different power supply modes, the output frequency of the same constant temperature crystal oscillator will be different, so the target optimal calibration weight corresponding to the constant temperature crystal oscillator will also be different. Therefore, it is also necessary to select the target optimal calibration weight corresponding to the constant temperature crystal oscillator according to the synchronous power supply mode.

[0062] In some embodiments, step S15 "determining an optimal calibration weight according to the target constant temperature crystal oscillator and the power supply mode" includes:

[0063] Step S151: when the power supply mode is powering by the power adapter, obtaining a target optimal calibration weight corresponding to the target constant temperature crystal oscillator in a storage device.

[0064] The optimal calibration weight of the constant temperature crystal oscillator is determined at the time of shipment or debugging, and the determined optimal calibration weight is recorded in a non-erasable storage device. Therefore, the storage device records the optimal calibration weight corresponding to each constant temperature crystal oscillator when the power adapter is powered. Therefore, it is necessary to determine the corresponding target optimal calibration weight according to the selected constant temperature crystal oscillator and power supply method.

[0065] In some embodiments, step S15 "determining an optimal calibration weight according to the target constant temperature crystal oscillator and the power supply mode" includes:

[0066] In step S152, when the power supply mode is battery power supply, a power weight coefficient table corresponding to the target constant temperature crystal oscillator and a current power value of the battery are obtained, wherein the power weight coefficient table includes a correspondence between power values ​​and optimal calibration weights.

[0067] Step S153: Determine the target optimal calibration weight according to the current power value and the power weight coefficient table.

[0068] Since the battery power will gradually decrease with the working time, and the general reduction of battery power will affect the battery voltage, and when the voltage changes, the output frequency of the constant temperature crystal oscillator will also change, and then its corresponding optimal calibration weight will also change. Therefore, a relationship table between the battery power value and the optimal calibration weight under battery power supply, that is, a power weight coefficient table, is stored in the storage device. Different optimal calibration weights are recorded for different power values ​​in the power weight coefficient table. Therefore, when determining the target optimal calibration weight corresponding to the target constant temperature crystal oscillator, it is necessary to first obtain the current power value of the battery, and determine the corresponding optimal calibration weight in the power weight coefficient according to the current power value as the target optimal calibration weight.

[0069] In some embodiments, step S153 of "determining the optimal calibration weight according to the current power value and the power weight coefficient table" includes:

[0070] Step S1531: When the current power value is less than the minimum power value in the power weight coefficient table, the target optimal calibration weight is calculated based on the current power to sum function relationship.

[0071] The power weight coefficient represents a table obtained by measurement, but the data obtained by measurement is limited. Therefore, in actual use, the current power value may be less than the minimum power value in the power weight coefficient table, making it impossible to obtain the optimal calibration weight corresponding to the current power value through the power weight coefficient table. Therefore, it is necessary to calculate the optimal calibration weight corresponding to the current power value through a functional relationship. The functional relationship is obtained by fitting the optimal calibration weight corresponding to the power value in the power weight coefficient table.

[0072] Step S16: adjusting the time count according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time.

[0073] The constant temperature crystal oscillator needs to reach a certain temperature to run stably. Therefore, before the time is set, it is necessary to preheat the constant temperature crystal oscillator and determine whether the constant temperature crystal oscillator needs adaptive frequency calibration.

[0074] In some embodiments, the method further comprises:

[0075] Step S31: preheating the constant temperature crystal oscillator to stabilize the frequency output by the constant temperature crystal oscillator.

[0076] After the constant temperature crystal oscillator has completed preheating, it is necessary to confirm the status of the constant temperature crystal oscillator to confirm whether the constant temperature crystal oscillator needs to be calibrated for adaptive frequency.

[0077] Step S32: obtaining the calibration status flag of the constant temperature crystal oscillator.

[0078] Step S33: When the calibration status flag is at a high level, determining whether a calibration command sent by the control terminal is received.

[0079] Step S34: when the calibration command is received, adaptive frequency calibration is performed on the constant temperature crystal oscillator.

[0080] Step S35: When the calibration status flag is at a low level, adaptive frequency calibration is performed on the constant temperature crystal oscillator.

[0081] There are two conditions for determining the adaptive frequency calibration. One is that when the calibration status flag is at a low level, the constant temperature crystal oscillator is adaptively calibrated. The other is that when the calibration command sent by the control end is received, the constant temperature crystal oscillator is calibrated. The calibration status flag is used to reflect whether the constant temperature crystal oscillator has been calibrated. When the calibration status flag is at a low level, it means that the constant temperature crystal oscillator has not been calibrated and needs to be calibrated before use.

[0082] In some embodiments, in step S34 or step S35, “the constant temperature crystal oscillator performs adaptive frequency calibration” includes:

[0083] Step S341: firstly perform the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of the power adapter, and then perform the adaptive frequency calibration on the standby constant temperature crystal oscillator.

[0084] Step S342: firstly perform the adaptive frequency calibration on the main constant temperature crystal oscillator and then perform the adaptive frequency calibration on the standby constant temperature crystal oscillator under the power supply of the battery.

[0085] When calibrating the constant temperature crystal oscillator, there are two constant temperature crystal oscillators, namely the main constant temperature crystal oscillator and the backup constant temperature crystal oscillator. The main constant temperature crystal oscillator needs to be calibrated first. The calibration of the main constant temperature crystal oscillator is generally performed before use or when leaving the factory. The backup constant temperature crystal oscillator can be calibrated during the process of the main constant temperature crystal oscillator being calibrated, which can also save a lot of time.

[0086] During the calibration process, since the output frequency of the constant temperature crystal oscillator will be affected by the voltage, and when the power adapter is powered, the voltage is stable, so only one calibration cycle is required. When powered by a battery, the optimal calibration weight corresponding to different power values ​​needs to be obtained, so multiple calibration cycles are required when powered by a battery. Therefore, the main constant temperature crystal oscillator is calibrated when powered by the power adapter first.

[0087] Therefore, in some embodiments, when performing adaptive frequency calibration, it is also necessary to consider whether the power supply method meets the calibration sequence. The method further includes:

[0088] Step S41: Determine whether the power supply mode satisfies the calibration sequence.

[0089] Step S42: When the power supply mode does not satisfy the calibration sequence, an error self-check code is generated to prompt a change in the power supply mode.

[0090] The calibration sequence referred to here is only the power supply sequence for adaptive calibration according to different power supply modes. The power adapter needs to be powered first, and then the battery is used for calibration.

[0091] In some embodiments, step S341 of "first performing the adaptive frequency calibration on the main constant temperature crystal oscillator under power supply of the power adapter, and then performing the adaptive frequency calibration on the standby constant temperature crystal oscillator" includes:

[0092] Step S3411: preset a calibration period of duration T, and divide the calibration period into D unit time lengths.

[0093] Since the power adapter has the characteristic of stable voltage when supplying power, the output frequency of the constant temperature crystal oscillator is stable and only one calibration cycle is required.

[0094] Step S3412: Obtain the j-th second pulse output by the positioning and orientation card in the i-th unit time.

[0095] The second pulse output by the positioning and orientation card board is generated based on the satellite time signal, so the number of rising edges of the second pulse generated by the positioning and orientation card board is used as a reference.

[0096] Step S3413: Obtain the kth second pulse output by the main constant temperature crystal oscillator in the i-th unit time.

[0097] While the positioning and orientation card generates a second pulse, the main constant temperature crystal oscillator also generates a second pulse.

[0098] Step S3414: Determine the number of i-th clock deviations of the k-th second pulse relative to the j-th second pulse according to the number of rising edges of the j-th second pulse and the number of rising edges on the k-th second pulse.

[0099] The duration of the two second pulses is the same, which is the length of one unit time. At this time, the number of rising edges of the two second pulses is obtained, and the number of rising edges of the two second pulses is compared, and then the clock deviation number of the second pulse generated by the constant temperature crystal oscillator and the second pulse generated by the directional card board can be obtained.

[0100] Step S3415: Compare the i-th clock deviation number with a first threshold.

[0101] Step S3416: When the number of the i-th clock deviation is greater than the first threshold, determine the i-th correction weight according to the number of the i-th clock deviation.

[0102] For radar timing, the timing deviation is required to be less than 1us, and the output frequency of a general constant temperature crystal oscillator is 200M. Therefore, when the number of clock deviations is greater than 2, it is considered that the constant temperature crystal oscillator needs to be calibrated, so the number of clock deviations is used as the correction weight.

[0103] Step S3417: Determine whether the i-th modified weight satisfies the optimization condition.

[0104] Step S3418: When it is determined that the i-th modified weight value satisfies the optimization condition, the i-th modified weight value is regarded as the first optimal calibration weight value and written into the storage device.

[0105] Since the number of clock deviations obtained is greater than the first threshold, the number of clocks per unit time of the main constant temperature crystal oscillator is modified according to the number of clock deviations, so that the number of clocks per unit time after modification is more consistent with the output frequency of the main constant temperature crystal oscillator itself. Then continue to calibrate the next unit time. Where i, j, and k are all positive integers less than or equal to D.

[0106] In some embodiments, step S3418 "when it is determined that the i-th modified weight value satisfies the optimization condition, writing the i-th modified weight value into the storage device as the first optimal calibration weight value" includes:

[0107] Step S34181: When the number of the (i+1)th clock deviation is less than the first threshold, the (i)th corrected weight is regarded as the first optimal calibration weight and written into the storage device.

[0108] Step S34182: When i is equal to D, the i-th corrected weight is regarded as the first optimal calibration weight and written into the storage device.

[0109] There are two optimization conditions in step S3418. One is that when the number of clock deviations corresponding to a certain time unit is less than the first threshold, it means that the correction weight obtained at this time is the correction result. Then the correction weight obtained in the previous unit time is recorded in the storage device as the optimal calibration weight of the main constant temperature crystal oscillator when powered by the power adapter.

[0110] Another situation is that when it reaches the Dth unit time, a calibration cycle is completed, but at this time, the Dth clock deviation number is still greater than the first threshold. At this time, the Dth correction weight determined according to the Dth clock deviation number is recorded in the storage device as the optimal calibration weight of the main constant temperature crystal oscillator when powered by the power adapter.

[0111] In some embodiments, step S342 of "first performing the adaptive frequency calibration on the main constant temperature crystal oscillator and then performing the adaptive frequency calibration on the standby constant temperature crystal oscillator under battery power supply" includes:

[0112] Step S3421: calibrating the master oven controlled crystal oscillator for N calibration cycles, and the total duration of the N calibration cycles is greater than or equal to a first time threshold.

[0113] Since the battery power will change with the power supply time, and the battery voltage will also change with the battery power, the output frequency of the constant temperature crystal oscillator will be affected by the battery power when it is powered by a battery. Therefore, multiple cycles of calibration are required to obtain the corresponding relationship between the optimal calibration weight and the battery power. Considering the working time of the radar, it is necessary to obtain sufficient data to support the radar to keep time for more than 48 hours. Therefore, the total time required for calibration is greater than 48 hours.

[0114] Step S3422: Obtain the first optimal calibration weight.

[0115] The first optimal calibration weight is the optimal calibration weight obtained by the main constant temperature crystal oscillator under the condition of stable voltage. Therefore, the first optimal calibration weight can be used as a reference here to reduce the dependence on the satellite time signal when performing adaptive frequency calibration, so that the optimal calibration weight when powered by battery can be performed when the satellite time signal cannot be obtained normally.

[0116] Step S3423: Obtain the corresponding number of rising edges of second pulses generated by the main constant temperature crystal oscillator in each unit time in the current cycle.

[0117] Step S3424: Determine the number of clock deviations corresponding to each unit time length in the current cycle according to the corresponding number of rising edges of the second pulse and the first optimal calibration weight.

[0118] Step S3425: Obtain the number of clock deviations corresponding to each unit time length in all the current cycles, and perform weighted averaging on all the clock deviations to obtain a second optimal calibration weight corresponding to the current cycle.

[0119] Step S3426: Acquire the battery power of the current cycle, write the battery power and the second optimal calibration weight into the storage device in correspondence, and form the power weight coefficient table corresponding to the main constant temperature crystal oscillator.

[0120] The above process is the working method for a single calibration cycle. To complete the optimal calibration weights of the main constant temperature crystal oscillator under battery power supply, the above steps need to be performed N times until the calibration of N calibration cycles is completed, and finally the power weight coefficient table is obtained. Only in this way can it be ensured that there is enough data in the power weight data table so that the radar can achieve accurate timekeeping within 48 hours.

[0121] Of course, the above content is for the adaptive frequency calibration process of the main constant temperature crystal oscillator. For the standby constant temperature crystal oscillator, the process of adaptive frequency calibration of the standby constant temperature crystal oscillator is the same, except that the adaptive frequency calibration of the standby constant temperature crystal oscillator can be performed during the timekeeping work of the main constant temperature crystal oscillator. Therefore, how to perform adaptive frequency calibration of the standby constant temperature crystal oscillator will not be described here.

[0122] The above methods are all proposed for how to accurately keep time when the radar cannot receive the satellite time signal or the radar cannot correctly interpret the satellite time signal. When the radar can receive the satellite time signal and can correctly interpret the satellite time signal.

[0123] In some embodiments, Figure 2 As shown, the method also includes:

[0124] Step S41: When it is determined that the satellite time signal is received normally, the satellite time signal and the satellite second pulse are received.

[0125] Step S42: Select a target oven-controlled crystal oscillator.

[0126] The specific method for selecting a constant temperature crystal oscillator is the same as that of the above step S13.

[0127] Step S43: Generate a perpetual calendar and a crystal oscillator second pulse using the frequency of the constant temperature crystal oscillator as the clock frequency.

[0128] Step S44: performing timing alignment on the perpetual calendar and the crystal oscillator second pulse according to the satellite time signal and the satellite second pulse.

[0129] Since satellite time signals can be obtained, there is no need to consider whether the output frequency of the constant temperature crystal oscillator is the same as the standard time. It is only necessary to correct the perpetual calendar and second pulse according to the satellite time signal after a certain period of time.

[0130] The method proposed in this application can enable the radar to keep time for 48 consecutive hours in adverse conditions such as long-term power failure and disappearance of satellite signals, and the error of the time keeping result is less than 1us, which can fully meet the time synchronization requirements of the radar networking system.

[0131] Of course, this application also takes into account the situation of extreme temperature and strong electromagnetic interference. The radar in this application is equipped with an electromagnetic shielding structure and a power filter to prevent interference signals from affecting the work of the timekeeping module.

[0132] In order to prevent the radar from not working properly under extreme temperature conditions, the method of this application also includes:

[0133] Step S51: During power-on and operation, the current temperature of the timekeeping module is obtained in real time.

[0134] Step S52: Determine whether to take temperature correction measures according to the current temperature and the temperature threshold.

[0135] Step S53: When the current temperature is greater than the temperature threshold, the refrigeration equipment is started.

[0136] Step S54: When the current temperature is less than the temperature threshold, the heating device is started.

[0137] Finally, the timekeeping module of the radar of the present application can work normally in an environment of -55° to 80°.

[0138] like Figure 3 As shown in FIG. 1 , the overall workflow of the radar timekeeping module in this application is shown. The following steps are included in the figure:

[0139] Step S61: The radar is powered on and started.

[0140] Step S62: Automatically select a power supply and generate a power indication signal.

[0141] Step S63: preheating the constant temperature crystal oscillator.

[0142] Step S64: After preheating, determine whether the constant temperature crystal oscillator needs to be calibrated for adaptive frequency. If yes, jump to step S652; if no, jump to step S651.

[0143] Step S651: Determine whether the reception of the satellite time signal is normal. If yes, jump to step S661; if not, jump to step S663.

[0144] Step S661: The constant temperature crystal oscillator outputs a perpetual calendar and a second pulse;

[0145] Step S662: Acquire satellite time signals, perform timing alignment on the perpetual calendar and second pulse output by the constant temperature crystal oscillator, and jump to S67.

[0146] Step S652: performing adaptive frequency calibration;

[0147] Step S653: Update the adaptive frequency calibration result to the storage device, and jump to step S651.

[0148] Step S663: Obtain the time reference sent by the control terminal;

[0149] Step S664: Acquire the optimal calibration weight in the storage device.

[0150] Step S665: Generate a perpetual calendar and a second pulse based on the optimal calibration weights and time reference.

[0151] Step S67: Complete the time keeping.

[0152] Of course, if Figure 4 The above step S62 also includes:

[0153] Step S72: Obtain the current temperature of the timekeeping module.

[0154] Step S73: Determine whether the current temperature is within a threshold range.

[0155] Step S74: When the current temperature is not within the threshold range, determine whether the current temperature is greater than the threshold. If yes, jump to step S75; if not, jump to step S76.

[0156] Step S75: Start the refrigeration equipment.

[0157] Step S76: Determine whether the current temperature is less than the threshold, if so, jump to step S77.

[0158] Step S77: Start the heating device.

[0159] like Figure 5 As shown in FIG. 1 , it is a flow chart of the adaptive frequency calibration of the constant temperature crystal oscillator, which includes the following steps:

[0160] Step S81: Acquire satellite time reference;

[0161] Step S82: Correcting the frequency of the oven controlled crystal oscillator according to the satellite time;

[0162] Step S83: Calculate and obtain the correction weight.

[0163] Step S84: Determine whether the frequency of the constant temperature crystal oscillator converges to the correction weight. If yes, jump to step S85; if not, jump to step S87.

[0164] Step S85: Update and store the modified weight as the optimal cultivation weight in the storage device.

[0165] Step S86: Calibration is completed.

[0166] Step S87: Determine whether the number of taming times reaches the maximum number of iterations. If yes, jump to step S85; if not, jump to step S88.

[0167] Step S88: Update the number of count clocks of the constant temperature crystal oscillator according to the corrected weight, and jump to step S81.

[0168] When the timekeeping module is performing timekeeping work, if Figure 6 The figure includes the following steps:

[0169] Step S91: Complete constant temperature crystal oscillator preheating and calibration.

[0170] Step S92: Determine whether the satellite time signal is received normally. If yes, jump to step S931; if not, jump to step S941.

[0171] Step S931: Acquire the satellite time reference and select a normal target constant temperature crystal oscillator;

[0172] Step S932: Generate a perpetual calendar and a second pulse through the target constant temperature crystal oscillator.

[0173] Step S933: Perform timing alignment on the perpetual calendar and second pulse generated by the target constant temperature crystal oscillator based on the satellite time reference.

[0174] Step S941: Obtain the time reference sent by the control terminal and select a normal target constant temperature crystal oscillator.

[0175] Step S942: Determine whether the power source is adapter powered, if yes, jump to step S951; if no, jump to step S961.

[0176] Step S951: Obtain the optimal calibration weight corresponding to the target constant temperature crystal oscillator powered by the power adapter.

[0177] Step S952: Generate a perpetual calendar and a second pulse according to the optimal calibration weights.

[0178] Step S961: Obtain a weighted power coefficient table corresponding to the target constant temperature crystal oscillator.

[0179] Step S962: Obtain the current battery power.

[0180] Step S963: Determine the optimal calibration weight according to the current power value and the weight power coefficient table, and jump to step S952.

[0181] This application proposes a method that uses a domestic military-grade FPGA as a controller and a 200M constant temperature crystal oscillator as a frequency reference. It adopts satellite time calibration and self-feedback principles to adaptively and accurately calibrate the constant temperature crystal oscillator frequency under different power supply modes. At the same time, it adopts dual power supply automatic seamless switching power supply, anti-electromagnetic interference design, and real-time temperature sensing and correction to achieve 48 hours of continuous operation in extremely complex environments with a time error of less than 1us.

[0182] Embodiment 2:

[0183] Based on the foregoing embodiments, the embodiments of the present application provide a timekeeping device, and the modules included in the device, as well as the units included in the modules, can be implemented by a processor in a computer device; of course, they can also be implemented by a specific logic circuit; in the implementation process, the processor can be a central processing unit (CPU, Central Processing Unit), a microprocessor (MPU, Microprocessor Unit), a digital signal processor (DSP, Digital Signal Processing) or a field programmable gate array (FPGA, Field Programmable Gate Array), etc.

[0184] like Figure 7 As shown, the second aspect provides a timekeeping device, including: a first determination module 1, a first acquisition module 2, a selection module 3, a second determination module 4, a second acquisition module 5 and a first working module 6.

[0185] The first determination module 1 is used to determine the reception status of the satellite time signal and determine whether the reception of the satellite time signal is normal. The first acquisition module 2 is used to obtain the power supply mode indication signal, the crystal oscillator status information and the time reference signal issued by the control end when it is determined that the reception of the satellite time signal is abnormal. The selection module 3 is used to select the target constant temperature crystal oscillator according to the crystal oscillator status information. The second determination module 4 is used to determine the power supply mode according to the power supply mode indication signal. The second acquisition module 5 is used to determine the target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode. The first working module 6 is used to adjust the time count according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time.

[0186] In some embodiments, the second acquisition module 5 includes: a third acquisition module, a fourth acquisition module and a third determination module.

[0187] The third acquisition module is used to acquire the target optimal calibration weight corresponding to the target constant temperature crystal oscillator in the storage device when the power supply mode is powered by the power adapter. The fourth acquisition module is used to acquire the power weight coefficient table corresponding to the target constant temperature crystal oscillator and the current power value of the battery when the power supply mode is powered by the battery. The third determination module is used to determine the target optimal calibration weight according to the current power value and the power weight coefficient table.

[0188] In some embodiments, the second acquisition module 5 further includes: a fourth determination module.

[0189] The fourth determination module is used to calculate the target optimal calibration weight based on the current power value to sum function relationship when the current power value is less than the minimum power value in the power weight coefficient table.

[0190] In some implementations, the timekeeping device further includes: a fifth determination module, a first execution module, and a second execution module.

[0191] The fifth determination module is used to determine whether the power supply of the external input power source is normal. The first execution module is used to use the power adapter to supply power and generate a power supply mode indication signal when it is determined that the power supply of the external input power source is normal. The second execution module is used to use the battery to supply power, generate a power supply mode indication signal and output the current battery power value in real time when it is determined that the power supply of the external input power source is abnormal.

[0192] In some embodiments, the selection module 3 includes: a sixth determination module and a third execution module.

[0193] The sixth determination module is used to determine whether there is a high level signal based on the crystal oscillator state information. The third execution module is used to determine the constant temperature crystal oscillator corresponding to the high level signal as the target constant temperature crystal oscillator.

[0194] In some embodiments, the timekeeping device further includes: a preheating module, a fifth acquisition module, a receiving module, a seventh determination module and a fourth execution module.

[0195] The preheating module is used to preheat the constant temperature crystal oscillator so that the frequency output by the constant temperature crystal oscillator is stable. The fifth acquisition module is used to obtain the calibration status flag of the constant temperature crystal oscillator. The receiving module is used to receive the calibration command sent by the control end. The seventh determination module is used to determine whether the calibration command sent by the control end is received when the calibration status flag is at a high level. The fourth execution module is used to perform adaptive frequency calibration on the constant temperature crystal oscillator when the calibration command is received or when the calibration status flag is at a low level.

[0196] In some embodiments, the fourth execution module includes: a fifth execution module and a sixth execution module.

[0197] The fifth execution module is used to first perform the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of the power adapter, and then perform the adaptive frequency calibration on the standby constant temperature crystal oscillator. The sixth execution module is used to first perform the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of the battery, and then perform the adaptive frequency calibration on the standby constant temperature crystal oscillator.

[0198] In some embodiments, the timekeeping device further includes: an eighth determination module and a seventh execution module.

[0199] The eighth determination module is used to determine whether the power supply mode meets the calibration sequence. The seventh execution module is used to generate an error self-check code when the power supply mode does not meet the calibration sequence to prompt the user to change the power supply mode.

[0200] In some embodiments, the fifth execution module includes: a first preset module, a sixth acquisition module, a seventh acquisition module, a first comparison module, a ninth determination module, a tenth determination module, an eleventh determination module and an eighth execution module.

[0201] The first preset module is used to preset a calibration cycle with a duration of T, and divide the calibration cycle into D unit time lengths. The sixth acquisition module is used to obtain the jth second pulse output by the positioning and orientation card in the i-th unit time. The seventh acquisition module is used to obtain the kth second pulse output by the main constant temperature crystal oscillator in the i-th unit time. The ninth determination module is used to determine the i-th clock deviation number of the k-th second pulse relative to the j-th second pulse according to the number of rising edges of the j-th second pulse and the number of rising edges of the k-th second pulse. The first comparison module is used to compare the i-th clock deviation number with the first threshold. The tenth determination module is used to determine the i-th correction weight according to the i-th clock deviation number when the i-th clock deviation number is greater than the first threshold. The eleventh determination module is used to determine whether the i-th correction weight meets the optimization condition. The eighth execution module is used to write the i-th correction weight into the storage device as the first optimal calibration weight when it is determined that the i-th correction weight meets the optimization condition.

[0202] In some embodiments, the eighth execution module includes: a ninth execution module and a tenth execution module.

[0203] The ninth execution module is used for, when the number of the i+1th clock deviation is less than the first threshold, writing the i-th correction weight value as the first optimal calibration weight value into the storage device. The tenth execution module is used for, when i is equal to D, writing the i-th correction weight value as the first optimal calibration weight value into the storage device.

[0204] In some embodiments, the sixth execution module includes: a second preset module, an eighth acquisition module, a ninth acquisition module, a twelfth determination module, a first calculation module and an eleventh execution module.

[0205] The second preset module is used to preset the calibration of N calibration cycles for the main constant temperature crystal oscillator, and the total duration of the N calibration cycles is greater than or equal to the first time threshold. The eighth acquisition module is used to obtain the first optimal calibration weight. The ninth acquisition module is used to obtain the corresponding number of rising edges of second pulses generated by the main constant temperature crystal oscillator for each unit duration in the current cycle. The twelfth determination module is used to determine the number of clock deviations corresponding to each unit duration in the current cycle based on the corresponding number of rising edges of second pulses and the first optimal calibration weight. The first calculation module is used to obtain the number of clock deviations corresponding to each unit duration in all the current cycles, and perform weighted averaging on all the clock deviation numbers to obtain the second optimal calibration weight corresponding to the current cycle. The eleventh execution module is used to obtain the battery power of the current cycle, and write the battery power and the second optimal calibration weight corresponding to the storage device to form the power weight coefficient table corresponding to the main constant temperature crystal oscillator.

[0206] In some embodiments, the timekeeping device further includes: a tenth acquisition module, a selection module 3, a second working module and an alignment module.

[0207] The tenth acquisition module is used to receive the satellite time signal and the satellite second pulse when it is determined that the satellite time signal is received normally. The selection module 3 is used to select a target constant temperature crystal oscillator. The second working module is used to generate a perpetual calendar and a crystal second pulse using the frequency of the constant temperature crystal oscillator as the clock frequency. The alignment module is used to perform timing alignment of the perpetual calendar and the crystal second pulse according to the satellite time signal and the satellite second pulse.

[0208] This application proposes a device that uses a domestic military-grade FPGA as a controller and a 200M constant temperature crystal oscillator as a frequency reference. It adopts satellite time calibration and self-feedback principles to adaptively and accurately calibrate the constant temperature crystal oscillator frequency under different power supply modes. At the same time, it adopts dual power supplies for automatic seamless switching of power supply, anti-electromagnetic interference design, and real-time temperature sensing and correction to achieve a precise timekeeping device that can work continuously for 48 hours in extremely complex environments with a time error of less than 1us.

[0209] Each module in the above-mentioned timekeeping device can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the robot device in the form of hardware, or can be stored in the memory in the processing device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.

[0210] Embodiment 3:

[0211] The third aspect provides an electronic device, including a storage device and a processor, wherein the storage device stores a computer program, and the processor implements the steps of a timekeeping method when executing the computer program.

[0212] Embodiment 4:

[0213] The fourth aspect provides a storage medium, which stores a computer program that can be executed by one or more processors, and the computer program can be used to implement the steps of any timekeeping method in the first aspect.

[0214] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).

[0215] Embodiment 5:

[0216] like Figure 8 As shown, of course, the present application also discloses a fifth aspect. The fifth aspect provides a timekeeping module, including: an FPGA controller, a frequency source module, a storage device, a power supply module, a temperature correction module and an external communication module.

[0217] The frequency source module includes: a main constant temperature crystal oscillator, a backup constant temperature crystal oscillator and a system clock crystal oscillator. The main constant temperature crystal oscillator and the backup constant temperature crystal oscillator are used to generate second pulses and complete timekeeping in combination with the optimal calibration weight stored in the storage device. The system clock crystal oscillator is used to perform self-test on the main constant temperature crystal oscillator and the backup constant temperature crystal oscillator.

[0218] The power module includes: power adapter, lithium battery pack, power filter and DC / DC module. The power module is used to power the FPGA controller and other modules.

[0219] The temperature correction module includes: temperature sensor, refrigeration equipment and heating equipment. The temperature correction module is used to obtain the current temperature of the timekeeping module and adjust the temperature of the timekeeping module.

[0220] The external communication module includes: radar positioning and orientation component, radar signal processing component, radar data processing component and radar general section display and control. The radar positioning and orientation component is used to obtain satellite time signals. The radar signal processing component is used to analyze various received information.

[0221] It should be understood that "one embodiment" or "an embodiment" mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present application, the size of the sequence number of the above-mentioned processes does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application. The above-mentioned sequence numbers of the embodiments of the present application are only for description and do not represent the advantages and disadvantages of the embodiments.

[0222] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0223] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the 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 can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.

[0224] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units; 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 present embodiment.

[0225] In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be a separate unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0226] A person of ordinary skill in the art can understand that: all or part of the steps of implementing the above-mentioned method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above-mentioned method embodiment; and the aforementioned storage medium includes: mobile storage devices, read-only memories (ROM, Read Only Memory), disks or optical disks, etc. Various media that can store program codes.

[0227] Alternatively, if the above-mentioned integrated unit of the present application is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application can essentially or in other words, the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions for a controller to execute all or part of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROMs, magnetic disks, or optical disks.

[0228] The above is only an implementation method of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A time keeping method, characterized in that: Timing modules for radars, including: When it is determined that the satellite time signal reception is abnormal, a power supply mode indication signal, crystal oscillator status information of a constant temperature crystal oscillator and a time reference signal issued by a control terminal are obtained, wherein the constant temperature crystal oscillator includes: a main constant temperature crystal oscillator and a standby constant temperature crystal oscillator; Preheating the constant temperature crystal oscillator to stabilize the frequency output by the constant temperature crystal oscillator; Obtaining a calibration status flag of the constant temperature crystal oscillator; When the calibration status flag is at a high level, determining whether a calibration command sent by the control terminal is received; When receiving the calibration command, performing adaptive frequency calibration on the constant temperature crystal oscillator; When the calibration status flag is at a low level, performing adaptive frequency calibration on the constant temperature crystal oscillator; The oven controlled crystal oscillator is subjected to adaptive frequency calibration, comprising: First, the main constant temperature crystal oscillator is calibrated for the adaptive frequency under the power supply of the power adapter, and then the standby constant temperature crystal oscillator is calibrated for the adaptive frequency; Then, the main constant temperature crystal oscillator is firstly calibrated for the adaptive frequency under the power supply of the battery, and then the standby constant temperature crystal oscillator is calibrated for the adaptive frequency; The method of first performing the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of the power adapter, and then performing the adaptive frequency calibration on the standby constant temperature crystal oscillator, comprises: Preset a calibration period of length T, and divide the calibration period into D unit time lengths; Get the j-th second pulse output by the positioning and orientation card in the i-th unit time; Get the kth second pulse output by the main constant temperature crystal oscillator in the i-th unit time; Determine the number of i-th clock deviations of the k-th second pulse relative to the j-th second pulse according to the number of rising edges of the j-th second pulse and the number of rising edges of the k-th second pulse; Comparing the i-th clock deviation number with a first threshold; When the i-th clock deviation number is greater than the first threshold, determining the i-th correction weight according to the i-th clock deviation number; Determining whether the i-th modified weight satisfies the optimization condition; When it is determined that the i-th modified weight value satisfies the optimization condition, writing the i-th modified weight value into a storage device as a first optimal calibration weight value; Where i, j, and k are all positive integers less than or equal to D; Selecting a target constant temperature crystal oscillator according to the crystal oscillator state information; determining a power supply mode according to the power supply mode indication signal; Determining a target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode; The time count is adjusted according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time.

2. A time keeping method according to claim 1, characterized in that: The power supply mode includes: power supply by a power adapter, and determining the optimal calibration weight according to the target constant temperature crystal oscillator and the power supply mode includes: When the power supply mode is powering by the power adapter, a target optimal calibration weight corresponding to the target constant temperature crystal oscillator in a storage device is obtained.

3. A timekeeping method according to claim 2, characterized in that: The power supply mode includes: battery power supply; the determining the optimal calibration weight according to the target constant temperature crystal oscillator and the power supply mode includes: When the power supply mode is power supply by the battery, obtaining a power weight coefficient table corresponding to the target constant temperature crystal oscillator and a current power value of the battery, wherein the power weight coefficient table includes a corresponding relationship between the power value and the optimal calibration weight; The target optimal calibration weight is determined according to the current power value and the power weight coefficient table.

4. A timekeeping method according to claim 3, characterized in that: The determining the optimal calibration weight according to the current power value and the power weight coefficient table includes: When the current power value is less than the minimum power value in the power weight coefficient table, the target optimal calibration weight is calculated based on the current power value and a functional relationship, wherein the functional relationship is obtained by fitting the power value in the power weight coefficient table with the optimal calibration weight.

5. A timekeeping method according to claim 2, characterized in that: The method further comprises: Determine whether the external input power supply is normal; When it is determined that the external input power supply is normal, the power adapter is used for power supply and a power supply mode indication signal is generated; When it is determined that the external input power supply is abnormal, the battery is used for power supply, a power supply mode indication signal is generated and the current battery power value is output in real time.

6. A time keeping method according to claim 1, characterized in that: The step of selecting a target constant temperature crystal oscillator according to the crystal oscillator state information includes: Determine whether there is a high level signal based on the crystal oscillator state information; The constant temperature crystal oscillator corresponding to the high level signal is determined as the target constant temperature crystal oscillator; When a high-level signal exists in the main constant-temperature crystal oscillator, the main constant-temperature crystal oscillator is preferentially selected as the target constant-temperature crystal oscillator.

7. A timekeeping method according to claim 1, characterized in that: The method further comprises: Determine whether the power supply mode meets the calibration sequence; When the power supply mode does not meet the calibration sequence, an error self-check code is generated to prompt the user to change the power supply mode.

8. A timekeeping method according to claim 1, characterized in that: The step of treating the i-th modified weight as a first optimal calibration weight and writing it into the storage device when it is determined that the i-th modified weight satisfies the optimization condition comprises: When the number of the (i+1)th clock deviation is less than the first threshold, the i-th corrected weight is regarded as a first optimal calibration weight and written into the storage device; When i is equal to D, the i-th corrected weight is regarded as the first optimal calibration weight and written into the storage device.

9. A timekeeping method according to claim 1, characterized in that: The method of first performing the adaptive frequency calibration on the main constant temperature crystal oscillator and then performing the adaptive frequency calibration on the standby constant temperature crystal oscillator under battery power supply includes: Preset calibration of N calibration cycles for the main constant temperature crystal oscillator, and the total duration of the N calibration cycles is greater than or equal to the first time threshold; Obtaining a first optimal calibration weight; Obtain the corresponding number of rising edges of second pulses generated by the main constant temperature crystal oscillator for each unit time in the current cycle; Determine the number of clock deviations corresponding to each unit time length in the current cycle according to the corresponding number of rising edges of the second pulse and the first optimal calibration weight; Obtaining the number of clock deviations corresponding to each unit time length in all the current cycles, performing weighted averaging on all the clock deviations, and obtaining a second optimal calibration weight corresponding to the current cycle; The battery power of the current cycle is obtained, and the battery power and the second optimal calibration weight are correspondingly written into the storage device to form the power weight coefficient table corresponding to the main constant temperature crystal oscillator.

10. A time keeping method according to claim 1, characterized in that: The method further comprises: When it is determined that the satellite time signal is received normally, receiving the satellite time signal and the satellite second pulse; Select the target constant temperature crystal oscillator; Using the frequency of the constant temperature crystal oscillator as the clock frequency to generate a perpetual calendar and a crystal oscillator second pulse; The perpetual calendar and the crystal oscillator second pulse are timed and aligned according to the satellite time signal and the satellite second pulse.

11. A timekeeping device, characterized in that: include: The first acquisition module is used to acquire the power supply mode indication signal, the crystal oscillator status information and the time reference signal sent by the control terminal when it is determined that the satellite time signal reception is abnormal; A selection module, used for selecting a target constant temperature crystal oscillator according to the crystal oscillator state information; A second determining module, used to determine a power supply mode according to the power supply mode indication signal; A second acquisition module is used to determine a target optimal calibration weight corresponding to the target constant temperature crystal oscillator according to the target constant temperature crystal oscillator and the power supply mode; A first working module, used for adjusting the time count according to the target optimal calibration weight and the time reference signal to generate a perpetual calendar time; The timekeeping device further comprises: a preheating module, a fifth acquisition module, a receiving module, a seventh determination module and a fourth execution module; The preheating module is used to preheat the constant temperature crystal oscillator to stabilize the frequency output by the constant temperature crystal oscillator; The fifth acquisition module is used to obtain the calibration status flag of the constant temperature crystal oscillator; The receiving module is used to receive the calibration command sent by the control terminal; The seventh determination module is used to determine whether a calibration command sent by the control terminal is received when the calibration status flag is at a high level; The fourth execution module is used to perform adaptive frequency calibration on the constant temperature crystal oscillator when the calibration command is received or when the calibration status flag is at a low level; The fourth execution module includes: a fifth execution module and a sixth execution module; The fifth execution module is used to first perform the adaptive frequency calibration on the main constant temperature crystal oscillator under the power supply of the power adapter, and then perform the adaptive frequency calibration on the standby constant temperature crystal oscillator; The sixth execution module is used for first performing the adaptive frequency calibration on the main constant temperature crystal oscillator and then performing the adaptive frequency calibration on the standby constant temperature crystal oscillator when powered by a battery; The fifth execution module includes: a first preset module, a sixth acquisition module, a seventh acquisition module, a first comparison module, a ninth determination module, a tenth determination module, an eleventh determination module and an eighth execution module; The first preset module is used to preset a calibration period with a duration of T, and divide the calibration period into D unit time lengths; The sixth acquisition module is used to acquire the j-th second pulse output by the positioning and orientation card in the i-th unit time; The seventh acquisition module is used to obtain the kth second pulse output by the main constant temperature crystal oscillator in the i-th unit time; The ninth determination module is used to determine the number of i-th clock deviations of the k-th second pulse relative to the j-th second pulse according to the number of rising edges of the j-th second pulse and the number of rising edges of the k-th second pulse; The first comparison module is used to compare the number of the i-th clock deviation with a first threshold; The tenth determination module is used to determine the i-th correction weight according to the i-th clock deviation number when the i-th clock deviation number is greater than the first threshold; The eleventh determination module is used to determine whether the i-th modified weight satisfies the optimization condition; The eighth execution module is used for writing the i-th modified weight value into the storage device as the first optimal calibration weight value when it is determined that the i-th modified weight value satisfies the optimization condition.

12. An electronic device, characterized in that: include: A memory and a processor, wherein a computer program is stored in the memory, and when the computer program is executed by the processor, a timekeeping method as claimed in any one of claims 1 to 10 is executed.

13. A storage medium, characterized in that: The computer program stored in the storage medium can be executed by one or more processors, and the computer program can be used to implement the steps of a timekeeping method as claimed in any one of claims 1 to 10.

Citation Information

Patent Citations

  • Navigation satellite high-precision time service system with constant temperature circuit and method

    CN105446128A