Crystal oscillator frequency calibration method and device and electronic equipment
Through the wireless network, signal interaction is performed with the second electronic device connected to the base station, and the crystal oscillator frequency of the first electronic device is automatically calibrated, which solves the communication problem caused by the equipment frequency deviation and realizes fast and simple frequency calibration within the device.
Patent Information
- Application Number
- CN202411943709.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-26
- Publication Date
- 2025-04-25
AI Technical Summary
The frequency of the crystal oscillator in electronic equipment is very different from that of the base station frequency, which causes the equipment to be unable to make calls or use data traffic normally. The existing technology requires the equipment to be returned to the factory for calibration, which is complex in operation and high maintenance costs.
The signal is sent to the second electronic device communicating with the base station through a wireless network, and the frequency of the second signal is received and parsed, and the first frequency is calibrated according to the frequency to realize the calibration of the crystal oscillator frequency.
Without returning the electronic equipment to the factory or disassembly, users can complete frequency calibration in the equipment, which is simple to operate, reduces maintenance costs and solves communication problems caused by frequency deviation.
Smart Images

Figure CN119891957A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the technical field of electronic equipment, and specifically relates to a crystal oscillator frequency calibration method, device and electronic equipment. Background Art
[0002] The crystal oscillator inside an electronic device is a device that generates the clock signal of the electronic device. The clock signal plays an extremely important role in the circuit of the electronic device. However, if the frequency of the crystal oscillator inside the electronic device itself is offset, or the vibration frequency of the crystal oscillator inside the electronic device deviates greatly from the frequency of the base station, the electronic device will not be able to make calls or use data traffic normally.
[0003] Currently, in order to solve the above problem, the electronic device is usually returned to the factory to recalibrate its crystal oscillator. However, this solution requires disassembling the mainboard of the electronic device, which is complicated to operate. Disassembling the mainboard will affect the use of the electronic device and has high maintenance costs. Summary of the invention
[0004] The purpose of the embodiments of the present application is to provide a crystal oscillator frequency calibration method, device and electronic device. When the frequency of the crystal oscillator of the electronic device is offset from that of a base station, the frequency of the crystal oscillator can be calibrated conveniently and quickly to achieve normal communication with the base station.
[0005] In a first aspect, an embodiment of the present application provides a crystal oscillator frequency calibration method, the method is applied to a first electronic device, the first electronic device includes a first crystal oscillator, the method includes:
[0006] When the first frequency of the first crystal oscillator and the base station frequency are offset, a first signal is sent to a second electronic device via a wireless network, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is in communication connection with the base station;
[0007] receiving a second signal sent by the second electronic device, and determining a second frequency of the second signal;
[0008] The first frequency is calibrated according to the second frequency.
[0009] In a second aspect, an embodiment of the present application provides a crystal oscillator frequency calibration device, the device is applied to a first electronic device, the first electronic device includes a first crystal oscillator, the device includes:
[0010] a sending module, configured to send a first signal to a second electronic device via a wireless network when a first frequency of the first crystal oscillator and a base station frequency are offset, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is in communication connection with the base station;
[0011] a receiving module, configured to receive a second signal sent by the second electronic device, and determine a second frequency of the second signal;
[0012] A calibration module is used to calibrate the first frequency according to the second frequency.
[0013] In a third aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.
[0014] In a fourth aspect, an embodiment of the present application provides an electronic device, comprising a processor and a memory, wherein the memory stores programs or instructions that can be executed on the processor, and when the programs or instructions are executed by the processor, the above-mentioned crystal oscillator frequency calibration method is implemented.
[0015] In a fifth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.
[0016] In an embodiment of the present application, when the first frequency of the first crystal oscillator of the first electronic device and the base station frequency are offset, the first electronic device can send a first signal to the second electronic device that is communicatively connected to the base station via a wireless network, thereby receiving the second signal sent by the second electronic device and determining the second frequency of the second signal. The first frequency can be calibrated according to the second frequency, thereby eliminating the need to return the first electronic device to the factory, thereby eliminating the need to waste time on returning the device to the factory and disassembling the device, and eliminating the need to disassemble the first electronic device, thereby avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device, which is simple to operate and effectively solves the problem of a large deviation between the first frequency of the first crystal oscillator of the first electronic device and the frequency of the base station, thereby avoiding the problem of the first electronic device being unable to make calls or use data traffic normally due to the large deviation between the first frequency and the frequency of the base station. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a flow chart of a crystal oscillator frequency calibration method provided by the prior art;
[0018] Figure 2is a flow chart of a crystal oscillator frequency calibration method provided by some embodiments of the present application;
[0019] Figure 3 is a flow chart of a crystal oscillator frequency calibration method provided by some embodiments of the present application;
[0020] Figure 4 is a schematic structural diagram of a crystal oscillator frequency calibration device shown in some embodiments of the present application;
[0021] Figure 5 is a schematic structural diagram of a first electronic device shown in some embodiments of the present application;
[0022] Figure 6 It is a schematic diagram of the hardware structure of the first electronic device shown in some embodiments of the present application. DETAILED DESCRIPTION
[0023] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.
[0024] The terms "first", "second", etc. in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or N. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.
[0025] Before introducing the technical solution of the embodiment of the present application, the background technology of the embodiment of the present application is first introduced:
[0026] During use, the crystal oscillator in the electronic device will be affected by the aging of the device, the ambient temperature, the differences in the base station itself, and other issues, resulting in a large deviation between the crystal oscillator frequency and the base station frequency. For example, the aging of the crystal oscillator device will make the crystal oscillator output frequency inaccurate, the change in ambient temperature will cause the oscillation frequency of the crystal oscillator to shift, and some base stations have errors in their own frequencies, resulting in a mismatch between the crystal oscillator frequency and the base station frequency. If the crystal oscillator frequency and the base station frequency are too far apart, users will not be able to make calls or use data traffic normally.
[0027] At present, when the frequency deviation between the crystal oscillator of an electronic device and the base station is too large, field calibration cannot calibrate the crystal oscillator frequency back. At the same time, because the frequency deviation of some base stations themselves is too large, even if the crystal oscillator frequency of the mobile phone is accurate at this time, it will cause the mobile phone to be unable to make calls and communicate normally. The current method to solve the problem of users being unable to make calls due to the frequency deviation between the crystal oscillator and the base station is to send the electronic device back to the factory for recalibration, that is, to replace the crystal oscillator. After-sales service outlets cannot solve this problem. Therefore, the existing technology for solving communication problems caused by crystal oscillators has the following disadvantages:
[0028] 1. Failure to solve user problems in a timely manner seriously affects the user experience. Since the after-sales service outlets are currently unable to solve such problems, the phone can only be sent back to the factory by mail, which takes a considerable amount of time on the road.
[0029] 2. After returning to the factory, the mobile phone must be disassembled and the motherboard removed before the crystal oscillator frequency can be recalibrated, and then the calibrated motherboard must be reinstalled. Disassembling and installing the user's mobile phone will also affect the user experience of the mobile phone. At the same time, the operation process is quite complicated and requires the use of professional instruments, and the maintenance cost is very high. Figure 1 The traditional crystal oscillator frequency calibration method shown uses the instrument CMW100 to connect the test socket on the mainboard through the RF test line, and then sends instructions through the instrument to let the electronic device output a signal of a specified frequency, such as a signal with a frequency of f1. The signal transceiver of the electronic device receives the instruction and transmits it to the clock management chip of the electronic device. Then the clock management chip controls the crystal oscillator to oscillate according to the instruction to generate a signal with a frequency of f2. The signal generated by the electronic device is transmitted to the central processing unit, and the central processing unit transmits it to the signal transceiver. The signal transceiver transmits it to the amplifier circuit for amplification. The amplified signal is transmitted to the RF front-end circuit. After receiving the signal, the instrument calculates the frequency deviation between the frequency f2 of the signal and the frequency f1 of the signal output by the instruction, and calibrates the crystal oscillator according to the frequency deviation value.
[0030] 3. Currently, after the electronic equipment is returned to the factory and its crystal oscillator is calibrated, if the frequency of the calibrated crystal oscillator still has a large deviation from the frequency of the base station, the electronic equipment still cannot make calls and communicate normally.
[0031] In order to solve the problem that the above-mentioned electronic device cannot make calls and communicate normally, the embodiment of the present application provides a crystal oscillator frequency calibration method, device, first electronic device and storage medium. When the first frequency of the first crystal oscillator of the first electronic device and the base station frequency are offset, the first electronic device can send a first signal to the second electronic device connected to the base station through a wireless network, so that the second signal sent by the second electronic device can be received, and the second frequency of the second signal can be determined. The first frequency can be calibrated according to the second frequency. In this way, there is no need to return the first electronic device to the factory, and there is no need to waste time on returning to the factory and disassembling the machine, nor is there a need to disassemble the first electronic device, thereby avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device. The operation is simple, and the problem of a large deviation between the first frequency of the first crystal oscillator of the first electronic device and the frequency of the base station is effectively solved, thereby avoiding the problem that the first electronic device cannot make calls or use data traffic normally due to the large deviation between the first frequency and the frequency of the base station.
[0032] The technical solution of the embodiment of the present application can be applied to scenarios where there is a frequency deviation of the crystal oscillator of the electronic device, or the frequency of the crystal oscillator of the electronic device deviates too much from the frequency of the base station, resulting in the electronic device being unable to make calls or use data traffic normally.
[0033] The crystal oscillator frequency calibration method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.
[0034] Figure 2 It is a flow chart of a crystal oscillator frequency calibration method provided in an embodiment of the present application. The execution subject of the crystal oscillator frequency calibration method may be a first electronic device, the first electronic device includes a crystal oscillator, and the first electronic device may be, but is not limited to, a personal computer (PC), a smart phone, a tablet computer, or a personal digital assistant (PDA). Specifically, the first electronic device may have a frequency deviation in the frequency of its crystal oscillator or the frequency of the crystal oscillator deviates too much from the frequency of the base station, resulting in the first electronic device being unable to make calls or use data traffic normally.
[0035] like Figure 2 As shown, the crystal oscillator frequency calibration method provided in the embodiment of the present application may include steps 210 to 230.
[0036] Step 210: When a first frequency of the first crystal oscillator and a base station frequency offset each other, a first signal is sent to a second electronic device via a wireless network.
[0037] Among them, the second electronic device can be an electronic device that is in the same base station as the first electronic device and is different from the first electronic device. Specifically, the first electronic device and the second electronic device are connected to the same wireless network, the second electronic device is communicatively connected to the base station, and the second electronic device can make calls or use data traffic normally.
[0038] The first frequency may be a frequency of a first crystal oscillator.
[0039] It should be noted that when an electronic device leaves the factory, the frequency of its crystal oscillator is already determined. However, if the crystal oscillator ages, the frequency of the crystal oscillator may change, that is, the first frequency of the first crystal oscillator of the first electronic device is unknown.
[0040] The first signal may be a signal sent by the first electronic device to the second electronic device, for example, the first signal may be a PA instruction. The first signal is used to instruct the second electronic device to send a signal of a known frequency to the first electronic device.
[0041] In other embodiments, the above-mentioned first signal can also be sent to the second electronic device by a third-party electronic device that is different from the first electronic device and the second electronic device, that is, when the first electronic device requires the second device to send a signal of a known frequency, it can send a signal instruction to the third-party electronic device. After receiving the signal instruction, the third-party electronic device can forward the signal instruction to the second electronic device. The specific sender of the first signal is not limited in the embodiments of the present application.
[0042] It should be noted that the above-mentioned wireless network can be a network in the 2.4GHz or 5GHz frequency band. Usually, the wireless network equipment uses a crystal oscillator with a frequency error of about 50MHz. Although this is a considerable error, it will not have a significant impact on the transmission rate of the wireless network signal. Since the wireless network is not sensitive to the frequency error of the signal, and the wireless network signal has the characteristics of high signal-to-noise ratio, strong anti-interference ability, and self-correction mechanism, the crystal oscillator with a large frequency error will not have a significant impact on the signal quality in wireless network communication. Therefore, when the first electronic device cannot make a call or use the data network because of the frequency deviation of the first crystal oscillator, or the first frequency of the first electronic device has a large deviation from the frequency of the base station, the first electronic device can generally connect to the wireless network to surf the Internet, because the frequency deviation of the crystal oscillator that the wireless network signal can accept is very large compared to the main RF signal.
[0043] It should be noted that the offset between the first frequency of the first crystal oscillator and the base station frequency can be determined based on the following method: the first electronic device is unable to make calls or use data traffic normally, that is, when it is determined that the first electronic device is unable to make calls or use data traffic normally, it can be considered that the first frequency of the first crystal oscillator and the base station frequency are offset.
[0044] Step 220: Receive a second signal sent by a second electronic device, and determine a second frequency of the second signal.
[0045] The second signal may be a signal sent by the second electronic device to the first electronic device based on the first signal.
[0046] The second frequency may be a frequency of the second signal obtained after the first electronic device receives the second signal and analyzes the second signal.
[0047] It should be noted that the frequency of the second signal sent by the second electronic device is the third frequency, and the third frequency is the frequency of the second crystal oscillator of the second electronic device. The second crystal oscillator here is the crystal oscillator of the second electronic device.
[0048] In some embodiments of the present application, in order to save hardware cost, determining the second frequency of the second signal may specifically include:
[0049] The second signal is analyzed based on a receiving path of the signal transceiver in the first electronic device to obtain a second frequency.
[0050] In some embodiments of the present application, after receiving the second signal, the second signal may be parsed based on a receiving path of a signal transceiver in the first electronic device to obtain a second frequency corresponding to the second signal.
[0051] In the embodiment of the present application, the receiving path of the signal transceiver of the first electronic device itself can be used to analyze the second signal to obtain the second frequency, without the need for other equipment to analyze the second signal, thus saving hardware costs.
[0052] Step 230: calibrate the first frequency according to the second frequency.
[0053] In some embodiments of the present application, the first frequency may be calibrated according to the second frequency of the analyzed second signal.
[0054] In some embodiments of the present application, in order to calibrate the frequency of the crystal oscillator of the first electronic device conveniently, quickly and at low cost, step 230 may specifically include:
[0055] The first frequency is calibrated according to the difference between the second frequency and the third frequency.
[0056] In some embodiments of the present application, the deviation of the first frequency can be determined by the difference between the second frequency and the third frequency, and then the first frequency can be calibrated according to the difference between the second frequency and the third frequency. In this way, the deviation between the first frequency and the base station frequency can be reduced, so that the first electronic device can make calls or use data traffic normally.
[0057] In an embodiment of the present application, the first frequency is calibrated by the difference between the second frequency and the third frequency, so that the deviation between the first frequency and the base station frequency can be accurately determined, and then the first frequency is calibrated, without returning the first electronic device to the factory, and thus there is no need to waste time on returning the first electronic device to the factory and disassembling the device, nor is there a need to disassemble the first electronic device, thus avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device, and the operation is simple, thereby achieving convenient, fast and low-cost calibration of the crystal oscillator frequency of the first electronic device.
[0058] In some embodiments of the present application, calibrating the first frequency according to the difference between the second frequency and the third frequency may specifically include:
[0059] When it is determined that the difference between the second frequency and the third frequency is not zero, calibrating the first frequency according to the difference between the second frequency and the third frequency to obtain a calibrated first frequency;
[0060] The calibrated first frequency is updated as the first frequency, and the steps of receiving a second signal sent by a second electronic device, determining a second frequency of the second signal, and calibrating the first frequency according to the second frequency are returned until the difference between the second frequency and the third frequency is less than a preset threshold.
[0061] Among them, the preset threshold can be a preset threshold of the difference between the second frequency and the third frequency. The preset threshold can be set according to user needs and is not limited in the embodiment of the present application. For example, the preset threshold can be 0.05.
[0062] In some embodiments of the present application, the difference between the first frequency and the second frequency can be calculated, and then it is determined whether the difference between the second frequency and the third frequency is greater than a preset threshold value. If not, it means that the difference between the first frequency and the third frequency is not large, and there is no need to calibrate the first frequency. If so, the first frequency is calibrated according to the difference between the second frequency and the third frequency to obtain the calibrated first frequency, and then the calibrated first frequency is updated to the first frequency, and the second signal sent by the second electronic device is returned to be re-acquired, and then the second signal is re-parsed to determine the second frequency of the second signal, and the difference between the second frequency and the third frequency is calculated to determine whether the difference is greater than the preset threshold value. This cycle is repeated until the difference between the second frequency and the third frequency is less than the preset threshold value.
[0063] In the above embodiment, if the difference between the second frequency and the third frequency is less than the preset threshold, there may be a situation where the first electronic device still cannot make calls or use traffic data normally, although this situation is very rare. For example, the third frequency of the second crystal oscillator of the second electronic device is 1950HZ, the preset threshold is 0.05, and the difference between the second frequency and the third frequency is 0.03, that is, the first frequency of the first crystal oscillator of the first electronic device is 1950.03HZ, but the deviation between the first frequency 1950.03HZ of the first crystal oscillator of the first electronic device and the frequency of the base station is still a bit large, so the first electronic device still cannot make calls or use traffic data normally.
[0064] Therefore, in order to ensure that the first electronic device can make calls and use traffic data normally, after calculating the difference between the second frequency and the third frequency, it is also possible to directly determine whether the difference between the second frequency and the third frequency is 0, because the second electronic device can definitely make calls and use traffic data normally. Therefore, if the difference between the second frequency and the third frequency is 0, it means that the first frequency of the first crystal oscillator of the first electronic device is consistent with the third frequency of the second crystal oscillator of the second electronic device, and the first electronic device can definitely make calls and use data traffic normally. Therefore, there is no need to calibrate the first frequency of the first crystal oscillator of the first electronic device. If the difference between the second frequency and the third frequency is not 0, the first frequency is calibrated according to the difference between the second frequency and the third frequency to obtain the calibrated first frequency, and then the calibrated first frequency is updated to the first frequency, and the second signal of the third frequency sent by the second electronic device is returned to be re-acquired, and then the second signal is re-analyzed to determine the second frequency of the second signal, and the difference between the second frequency and the third frequency is calculated to determine whether the difference is greater than the preset threshold value. This cycle is performed until the difference between the second frequency and the third frequency is 0.
[0065] In an embodiment of the present application, the first frequency is continuously adjusted by the difference between the second frequency and the third frequency until the difference between the second frequency and the third frequency is less than a preset threshold, thereby ensuring that the first electronic device can make calls and use traffic data normally.
[0066] In some embodiments of the present application, in order to further save hardware costs, calibrating the first frequency according to the difference between the second frequency and the third frequency may specifically include:
[0067] adjusting the capacitance value of the capacitor in the first crystal oscillator according to the difference between the second frequency and the third frequency;
[0068] The first frequency is calibrated based on the adjusted capacitance value.
[0069] In some embodiments of the present application, the capacitance value of the capacitor in the first crystal oscillator may be adjusted according to the difference between the second frequency and the third frequency, and then the first frequency may be calibrated according to the adjusted capacitance value.
[0070] It should be noted that when the first electronic device receives the second signal of the third frequency, due to the aging of the first crystal oscillator, its first frequency cannot be changed, and the first frequency can only be compensated and calibrated by other means so that the first frequency can be equal to the third frequency, so that the first electronic device can make calls and use data traffic normally. Specifically, the compensation calibration of the first frequency can be to adjust the capacitance value of the oscillation circuit in the first crystal oscillator according to the difference between the second frequency and the third frequency, so that the adjusted capacitance value can compensate for the deviation between the first frequency and the third frequency, thereby realizing the calibration of the first frequency.
[0071] In an embodiment of the present application, the capacitance value of the capacitor in the first crystal oscillator is adjusted according to the difference between the second frequency and the third frequency, and then the first frequency is calibrated. In this way, there is no need to replace the first crystal oscillator, and the original physical path of the first electronic device can be reused, saving hardware costs.
[0072] In order to make it easier to understand the solution of the embodiment of the present application, the crystal oscillator frequency calibration method provided by the embodiment of the present application is described in detail below, taking the preset threshold of the difference between the second frequency and the third frequency as 0 as an example. Figure 3 , Figure 3 This is a flow chart of a crystal oscillator frequency calibration method provided in an embodiment of the present application. The execution subject of the method may be a system composed of the first electronic device and the second electronic device in the above embodiment.
[0073] like Figure 3 As shown, the crystal oscillator frequency calibration method may include steps 301 to 309.
[0074] Step 301: A first electronic device and a second electronic device are connected to the same wireless network.
[0075] Step 302: The first electronic device and the second electronic device enter a calibration mode, and send a first signal to the second electronic device.
[0076] In step 302, when calibrating the first frequency of the first crystal oscillator of the first electronic device, it is necessary to ensure that the first electronic device and the second electronic device both enter a calibration mode. In this calibration mode, the first electronic device sends a first signal to the second electronic device so that the second electronic device can send a second signal to the first electronic device based on the first signal.
[0077] Step 303: The second electronic device sends a second signal with a third frequency based on the first signal.
[0078] Step 304: The first electronic device receives a second signal.
[0079] Step 305: The first electronic device analyzes the second signal to obtain a second frequency of the second signal.
[0080] Step 306: The first electronic device calculates a difference between the second frequency and the third frequency.
[0081] Step 307 , determine whether the difference between the second frequency and the third frequency is 0, if so, execute step 308 , if not, execute step 309 .
[0082] Step 308: The calibration is completed, and the first electronic device and the second electronic device both exit the calibration mode.
[0083] Step 309: calibrate the first frequency based on the difference between the second frequency and the third frequency.
[0084] The crystal oscillator frequency calibration method provided in the embodiment of the present application can be executed by a crystal oscillator frequency calibration device. In the embodiment of the present application, the crystal oscillator frequency calibration method is executed by a crystal oscillator frequency calibration device as an example to illustrate the crystal oscillator frequency calibration device provided in the embodiment of the present application.
[0085] Figure 4 1 is a schematic diagram of a crystal oscillator frequency calibration device according to an exemplary embodiment. The crystal oscillator frequency calibration device is applied to a first electronic device, wherein the first electronic device includes a crystal oscillator, such as Figure 4 As shown, the crystal oscillator frequency calibration device 400 may include:
[0086] The sending module 410 is used to send a first signal to a second electronic device through a wireless network when the first frequency of the first crystal oscillator and the base station frequency are offset, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is in communication connection with the base station;
[0087] The receiving module 420 is configured to receive a second signal sent by the second electronic device and determine a second frequency of the second signal;
[0088] The calibration module 430 is configured to calibrate the first frequency according to the second frequency.
[0089] In an embodiment of the present application, when the first frequency of the first crystal oscillator of the first electronic device and the base station frequency are offset, the first electronic device can send a first signal to the second electronic device that is communicatively connected to the base station via a wireless network, thereby receiving the second signal sent by the second electronic device and determining the second frequency of the second signal. The first frequency can be calibrated according to the second frequency, thereby eliminating the need to return the first electronic device to the factory, thereby eliminating the need to waste time on returning the device to the factory and disassembling the device, and eliminating the need to disassemble the first electronic device, thereby avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device, which is simple to operate and effectively solves the problem of a large deviation between the first frequency of the first crystal oscillator of the first electronic device and the frequency of the base station, thereby avoiding the problem of the first electronic device being unable to make calls or use data traffic normally due to the large deviation between the first frequency and the frequency of the base station.
[0090] In some embodiments of the present application, the frequency of the second signal sent by the second electronic device is a third frequency, and the third frequency is the frequency of a second crystal oscillator of the second electronic device; the calibration module 430 may specifically include:
[0091] A calibration unit is used to calibrate the first frequency according to the difference between the second frequency and the third frequency.
[0092] In some embodiments of the present application, the calibration unit may be specifically used for:
[0093] adjusting the capacitance value of the capacitor in the first crystal oscillator according to the difference between the second frequency and the third frequency;
[0094] The first frequency is calibrated based on the adjusted capacitance value.
[0095] In some embodiments of the present application, the receiving module 420 is specifically used to:
[0096] The second signal is analyzed based on a receiving path of a signal transceiver in the first electronic device to obtain a second frequency.
[0097] The crystal oscillator frequency calibration device in the embodiment of the present application can be an electronic device, or a component in an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a vehicle-mounted electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmentedreality, AR) / virtual reality (virtualreality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobilepersonal computer, UMPC), a netbook or a personal digital assistant (personal digitalassistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., and the embodiment of the present application is not specifically limited.
[0098] The crystal oscillator frequency calibration device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.
[0099] The crystal oscillator frequency calibration device provided in the embodiment of the present application can achieve Figure 2 To avoid repetition, the various processes implemented by the method embodiment are not described here.
[0100] Alternatively, if Figure 5 As shown, an embodiment of the present application also provides a first electronic device 500, including a processor 501 and a memory 502, wherein the memory 502 stores a program or instruction that can be executed on the processor 501, and when the program or instruction is executed by the processor 501, the various steps of the above-mentioned crystal oscillator frequency calibration method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0101] It should be noted that the first electronic device in the embodiment of the present application includes the mobile electronic device and the non-mobile electronic device mentioned above.
[0102] Figure 6 A schematic diagram of the hardware structure of a first electronic device to implement an embodiment of the present application.
[0103] The first electronic device 600 includes but is not limited to: a radio frequency unit 601, a network module 602, an audio output unit 603, an input unit 604, a sensor 605, a display unit 606, a user input unit 607, an interface unit 608, a memory 609, and a processor 610.
[0104] Those skilled in the art will appreciate that the first electronic device 600 may also include a first crystal oscillator, and a power source (such as a battery) for powering each component, and the power source may be logically connected to the processor 610 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 6 The structure of the first electronic device shown in the figure does not constitute a limitation on the electronic device. The first electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.
[0105] Among them, the processor 610 is used to send a first signal to a second electronic device through a wireless network when the first frequency of the first crystal oscillator and the base station frequency offset, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is communicatively connected to the base station; receive a second signal sent by the second electronic device, determine the second frequency of the second signal; and calibrate the first frequency according to the second frequency.
[0106] In this way, when the first frequency of the first crystal oscillator of the first electronic device and the base station frequency are offset, the first electronic device can send a first signal to the second electronic device that is communicatively connected to the base station through the wireless network, so that the second signal sent by the second electronic device can be received, and the second frequency of the second signal can be determined. The first frequency can be calibrated according to the second frequency, so there is no need to return the first electronic device to the factory, and there is no need to waste time on returning the first electronic device to the factory and disassembling the device, nor is there a need to disassemble the first electronic device, thereby avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device, and the operation is simple, which effectively solves the problem of a large deviation between the first frequency of the first crystal oscillator of the first electronic device and the frequency of the base station, thereby avoiding the problem of the first electronic device being unable to make calls or use data traffic normally due to the large deviation between the first frequency and the frequency of the base station.
[0107] Optionally, the frequency of the second signal sent by the second electronic device is a third frequency, and the third frequency is the frequency of a second crystal oscillator of the second electronic device; the processor 610 is further used to calibrate the first frequency according to the difference between the second frequency and the third frequency.
[0108] In this way, the first frequency is calibrated by the difference between the second frequency and the third frequency, so that the deviation between the first frequency and the base station frequency can be accurately determined, and then the first frequency can be calibrated. There is no need to return the first electronic device to the factory, and there is no need to waste time on returning the first electronic device to the factory and disassembling the device, nor is there a need to disassemble the first electronic device, thus avoiding damage to the first electronic device. The user can complete the calibration of the first crystal oscillator frequency of the first electronic device in the first electronic device, and the operation is simple, thereby realizing convenient, fast and low-cost calibration of the crystal oscillator frequency of the first electronic device.
[0109] Optionally, the processor 610 is further configured to adjust a capacitance value of a capacitor in the first crystal oscillator according to a difference between the second frequency and the third frequency; and calibrate the first frequency based on the adjusted capacitance value.
[0110] In this way, the capacitance of the capacitor in the first crystal oscillator is adjusted according to the difference between the second frequency and the third frequency, and then the first frequency is calibrated. In this way, there is no need to replace the first crystal oscillator, and the original physical path of the first electronic device can be reused, saving hardware costs.
[0111] Optionally, the processor 610 is further configured to analyze the second signal based on a receiving path of a signal transceiver in the first electronic device to obtain a second frequency.
[0112] In this way, the second signal can be analyzed by utilizing the receiving path of the signal transceiver of the first electronic device itself, without the need to use other devices to analyze the second signal, thus saving hardware costs.
[0113] It should be understood that in the embodiment of the present application, the input unit 604 may include a graphics processor (GPU) 6041 and a microphone 6042, and the graphics processor 6041 processes the image data of a static picture or video obtained by an image capture device (such as a color camera) in a video capture mode or an image capture mode. The display unit 606 may include a display panel 6061, and the display panel 6061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 607 includes a touch panel 6071 and at least one of other input devices 6072. The touch panel 6071 is also called a touch screen. The touch panel 6071 may include two parts: a touch detection device and a touch controller. Other input devices 6072 may include, but are not limited to, a physical keyboard, function keys (such as a volume control button, a switch button, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.
[0114] The memory 609 can be used to store software programs and various data. The memory 609 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 609 may include a volatile memory or a non-volatile memory, or the memory 609 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 609 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.
[0115] The processor 610 may include one or more processing units; optionally, the processor 610 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 610.
[0116] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned crystal oscillator frequency calibration method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0117] The processor is the processor in the first electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0118] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned crystal oscillator frequency calibration method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0119] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0120] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned crystal oscillator frequency calibration method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0121] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0122] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0123] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A crystal oscillator frequency calibration method, characterized in that: The method is applied to a first electronic device, the first electronic device includes a first crystal oscillator, and the method includes: When the first frequency of the first crystal oscillator and the base station frequency are offset, a first signal is sent to a second electronic device via a wireless network, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is in communication connection with the base station; receiving a second signal sent by the second electronic device, and determining a second frequency of the second signal; The first frequency is calibrated according to the second frequency.
2. The method according to claim 1, characterized in that The frequency of the second signal sent by the second electronic device is a third frequency, and the third frequency is the frequency of a second crystal oscillator of the second electronic device; The calibrating the first frequency according to the second frequency includes: The first frequency is calibrated according to the difference between the second frequency and the third frequency.
3. The method according to claim 2, characterized in that The calibrating the first frequency according to the difference between the second frequency and the third frequency includes: adjusting the capacitance value of the capacitor in the first crystal oscillator according to the difference between the second frequency and the third frequency; The first frequency is calibrated based on the adjusted capacitance value.
4. The method according to claim 1, characterized in that: The determining a second frequency of the second signal comprises: The second signal is analyzed based on a receiving path of a signal transceiver in the first electronic device to obtain a second frequency.
5. A crystal oscillator frequency calibration device, characterized in that: The device is applied to an electronic device, the electronic device includes a first crystal oscillator, the electronic device is a first electronic device, and the device includes: a sending module, configured to send a first signal to a second electronic device via a wireless network when a first frequency of the first crystal oscillator and a base station frequency are offset, the first electronic device and the second electronic device are connected to the same wireless network, and the second electronic device is in communication connection with the base station; a receiving module, configured to receive a second signal sent by the second electronic device, and determine a second frequency of the second signal; A calibration module is used to calibrate the first frequency according to the second frequency.
6. The device according to claim 5, characterized in that The frequency of the second signal sent by the second electronic device is a third frequency, and the third frequency is the frequency of a second crystal oscillator of the second electronic device; and the calibration module includes: A calibration unit is used to calibrate the first frequency according to the difference between the second frequency and the third frequency.
7. The device according to claim 6, characterized in that The calibration unit is specifically used for: adjusting the capacitance value of the capacitor in the first crystal oscillator according to the difference between the second frequency and the third frequency; The first frequency is calibrated based on the adjusted capacitance value.
8. The device according to claim 5, characterized in that The receiving module is specifically used for: The second signal is analyzed based on a receiving path of a signal transceiver in the first electronic device to obtain a second frequency.
9. An electronic device, characterized in that: It comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the crystal oscillator frequency calibration method as described in any one of claims 1 to 4 are implemented.
10. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by the processor, the steps of the crystal oscillator frequency calibration method as described in any one of claims 1 to 4 are implemented.