A signal loop adjustment method and device, electronic equipment and storage medium
By calculating the sine and cosine output signals of the resolver to obtain the initial angle and angular velocity, the problem of long signal loop construction time of the resolver-to-digital converter is solved, and a faster feedback control system response and higher decoding efficiency are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING TONGFANG MICROELECTRONICS
- Filing Date
- 2024-12-24
- Publication Date
- 2026-06-02
Smart Images

Figure CN119845311B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of chip technology, and in particular to a signal loop adjustment method, apparatus, electronic device, and storage medium. Background Technology
[0002] Resolvers, as electromagnetic sensors used to measure the rotation angle and angular velocity of rotating objects, are widely used in industrial production, and decoding of resolvers has become a focus of attention.
[0003] In the existing technology, signal decoding of a resolver is usually performed by a resolver-to-digital converter (i.e., a resolver-to-digital converter chip). The resolver-to-digital converter uses an externally input reference signal to control the frequency and phase of the oscillation signal inside the loop, thereby achieving automatic tracking of the output signal frequency to the input signal frequency, and thus completing the loop construction. Then, the resolver-to-digital converter performs signal decoding of the resolver based on the completed loop.
[0004] However, because resolvers need to achieve high dynamic performance and stability, they require a long loop construction time, which greatly limits the response speed of the completed feedback control system and thus reduces the decoding efficiency of the resolver chip. Summary of the Invention
[0005] This invention provides a signal loop adjustment method, apparatus, electronic device, and storage medium to solve the problem of long signal loop construction time in resolver-to-digital converters.
[0006] According to one aspect of the present invention, a signal loop adjustment method is provided, applied to the estimation module of a resolver-to-digital converter, comprising:
[0007] The first initial angle is obtained based on the sine and cosine output signals of the rotary transformer.
[0008] The first initial angular velocity is obtained based on at least two of the first initial angles and the sampling frequency of the analog-to-digital converter;
[0009] The first initial angle is sent to the numerically controlled oscillator, and the first initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity.
[0010] The step of obtaining a first initial angle based on the sine and cosine output signals of the rotary transformer includes: integrating the sine and cosine output signals respectively to obtain a sine envelope signal matching the sine output signal and a cosine envelope signal matching the cosine output signal; and obtaining the first initial angle based on the sine and cosine envelope signals.
[0011] The step of integrating the sine output signal and the cosine output signal respectively to obtain a sine envelope signal matching the sine output signal and a cosine envelope signal matching the cosine output signal includes: shaping the sine output signal and the cosine output signal respectively according to a sign flag bit to obtain a sine-shaped signal matching the sine output signal and a cosine-shaped signal matching the cosine output signal; wherein the sign flag bit is used to distinguish the positive half-axis period and the negative half-axis period of the carrier signal; and integrating the sine-shaped signal and the cosine-shaped signal respectively to obtain a sine envelope signal matching the sine-shaped signal and a cosine envelope signal matching the cosine-shaped signal.
[0012] After sending the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, the method further includes: if, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship, obtaining a second initial angle and a second initial angular velocity based on the sine and cosine output signals of the resolver; sending the second initial angle to the numerically controlled oscillator and the second initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the second initial angle and the second initial angular velocity.
[0013] After sending the second initial angle to the numerically controlled oscillator and the second initial angular velocity to the loop filter, the method further includes: if, within a second preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship, obtaining a third initial angle and a third initial angular velocity based on the sine and cosine output signals of the resolver; wherein the second preset time period is shorter than the first preset time period; sending the third initial angle to the numerically controlled oscillator and the third initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the third initial angle and the third initial angular velocity.
[0014] After sending the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, the method further includes: if, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship, updating the first initial angle and the first initial angular velocity according to the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector; sending the updated first initial angle to the numerically controlled oscillator and the updated first initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the updated first initial angle and the updated first initial angular velocity.
[0015] According to another aspect of the present invention, a signal loop adjustment device is provided, applied to the estimation module of a resolver-to-digital converter, comprising:
[0016] The initial angle acquisition module is used to acquire the first initial angle based on the sine and cosine output signals of the rotary transformer.
[0017] An initial angular velocity acquisition module is used to acquire a first initial angular velocity based on at least two first initial angles and the sampling frequency of the analog-to-digital converter;
[0018] An initial parameter sending module is used to send the first initial angle to a numerically controlled oscillator and the first initial angular velocity to a loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity.
[0019] According to another aspect of the present invention, an electronic device is provided, the electronic device comprising:
[0020] At least one processor; and
[0021] A memory communicatively connected to the at least one processor; wherein,
[0022] The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the signal loop adjustment method according to any embodiment of the present invention.
[0023] According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium storing computer instructions for causing a processor to execute and implement the signal loop adjustment method described in any embodiment of the present invention.
[0024] According to another aspect of the present invention, a computer program product is provided, comprising a computer program that, when executed by a processor, implements the signal loop adjustment method described in any embodiment of the present invention.
[0025] The technical solution of this invention involves an estimation module of a resolver-to-digital converter (RDBDC) that first obtains a first initial angle based on the sine and cosine output signals of the resolver; then, based on at least two first initial angles and the sampling frequency of the analog-to-digital converter (ADC), it obtains a first initial angular velocity; finally, it sends the first initial angle to a numerically controlled oscillator and the first initial angular velocity to a loop filter, so that the signal loop of the RDBDC performs phase synchronization based on the first initial angle and the first initial angular velocity. This reduces the construction time of the closed loop of the RDBDC, improves the response speed of the feedback control system in the RDBDC, and thus improves the decoding efficiency of the RDBDC.
[0026] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of the present invention, nor is it intended to limit the scope of the invention. Other features of the invention will become readily apparent from the following description. Attached Figure Description
[0027] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0028] Figure 1 This is a flowchart of a signal loop adjustment method provided in Embodiment 1 of the present invention;
[0029] Figure 2 This is a schematic diagram of the structure of a resolver-to-digital converter provided in Embodiment 1 of the present invention;
[0030] Figure 3 This is a schematic diagram of the signal loop establishment process of a resolver-to-digital converter in the conventional technology provided by Embodiment 1 of the present invention;
[0031] Figure 4 This is a schematic diagram of the signal loop establishment process of the resolver-to-digital converter when the first initial angular velocity is used as the initial parameter, according to Embodiment 1 of the present invention.
[0032] Figure 5 This is a schematic diagram of the signal loop establishment process of the resolver-to-digital converter when the first initial angle and the first initial angular velocity are used as initial parameters, according to Embodiment 1 of the present invention.
[0033] Figure 6 This is a flowchart of another signal loop adjustment method provided in Embodiment 2 of the present invention;
[0034] Figure 7 This is a schematic diagram of a signal loop adjustment device according to Embodiment 3 of the present invention;
[0035] Figure 8 This is a schematic diagram of the structure of an electronic device that implements the signal loop adjustment method of Embodiment 4 of the present invention. Detailed Implementation
[0036] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present invention.
[0037] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this invention are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of the invention described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0038] Example 1
[0039] Figure 1 This is a flowchart of a signal loop adjustment method provided in Embodiment 1 of the present invention. This embodiment is applicable to phase synchronization operations of a resolver-to-digital converter based on acquired initial angles and initial angular velocities. This method can be executed by the signal loop adjustment device in any embodiment of the present invention. The signal loop adjustment device can be implemented in hardware and / or software and can be configured within the resolver-to-digital converter, for example, it can be configured in… Figure 2 The estimation module of the resolver-to-digital converter shown can be configured in an electronic device. For example... Figure 1 As shown, the method includes:
[0040] S101. Obtain the first initial angle based on the sine and cosine output signals of the rotary transformer.
[0041] like Figure 2 As shown, the resolver-to-digital converter in this embodiment of the invention includes an analog-to-digital converter (ADC), an estimation module, a phase detector (PD), a loop filter (LF), and a numerically controlled oscillator (NCO); wherein the loop filter and the numerically controlled oscillator can be directly connected or connected through a delay unit.
[0042] The analog-to-digital converter (ADC) is communicatively connected to the resolver and phase detector to sample and acquire the resolver's output signals, including sine and cosine output signals. Simultaneously, it sends the sampled sine and cosine output signals to the phase detector. The sine and cosine output signals sampled by the ADC can be represented by the following equations:
[0043] Q d =E0*sin(wt)*sin(θ) (Equation 1);
[0044] I d =E0*sin(wt)*cos(θ) (Equation 2);
[0045] Among them, Q d Indicates a sinusoidal output signal; I d E0 represents the cosine output signal; w is the product of the amplitude of the output signal of the rotary transformer and the turns ratio of the rotary transformer; θ is the angular velocity of the driving carrier wave; and θ is the rotor angle of the rotary transformer.
[0046] The phase detector will acquire the sinusoidal output signal Q d The product of the phase angle φ output by the numerically controlled oscillator and the cosine value of the phase angle φ, i.e., the cosine phase angle cos(φ), is calculated; simultaneously, the acquired cosine output signal I is... d The product of the sinusoidal value of the output angle φ of the numerically controlled oscillator, i.e., the sinusoidal phase angle sin(φ), is calculated; then the difference between the two product results is calculated to obtain the difference result E. r That is, the difference result E is obtained by calculating the following equation. r :
[0047] E r =Q d *cos(φ)-I d*sin(φ)=E0*sin(wt)*sin(θ-φ) (Equation 3);
[0048] The phase detector will output the above difference result E r Multiplying this by the excitation signal sin(wt) yields the following equation:
[0049]
[0050] After filtering the signal in Equation 4 above, the output signal of the loop filter can be expressed by the following equation:
[0051]
[0052] The numerically controlled oscillator adjusts the oscillation frequency of the signal in Equation 5 so that the difference between the rotor angle θ and the phase angle φ approaches 0. After the numerically controlled oscillator eliminates the error signal, the phase angle φ is equal to the rotor angle θ, thereby completing the feedback adjustment of the feedback control system and completing the closed loop construction of the resolver-to-digital converter.
[0053] In this embodiment of the invention, at the initial moment, after the estimation module obtains the sine output signal and the cosine output signal from the analog-to-digital converter, it can directly perform arctangent calculation on the two signals, that is, obtain the first initial angle θ1 through the following equation:
[0054]
[0055] Specifically, the sampling angles obtained at multiple sampling times can be calculated using Equation 6 above, and the average value of each sampling angle can be used as the first initial angle, thereby improving the calculation accuracy of the first initial angle. In addition, since the first initial angular velocity needs to be calculated using two or more sampling angles, the first initial angle can be calculated based on the average value of the two or more sampling angles above, thereby improving the calculation accuracy of the first initial angle while ensuring the synchronous generation of the first initial angle and the first initial angular velocity.
[0056] S102. Obtain the first initial angular velocity based on at least two of the first initial angles and the sampling frequency of the analog-to-digital converter.
[0057] Since the sampling period T of the analog-to-digital converter is a fixed value, the first initial angular velocity V1 can be obtained by the following equation: where Δθ1 represents the angular difference between the first initial angle θ1 obtained between two adjacent sampling times:
[0058] V1*T=Δθ1 (Equation 7).
[0059] In addition, the sampling angular velocities obtained at multiple sampling times can be calculated using Equation 7 above, and the average value of each sampling angular velocity can be used as the first initial angular velocity, thereby improving the calculation accuracy of the first initial angular velocity.
[0060] S103. The first initial angle is sent to the numerically controlled oscillator, and the first initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity.
[0061] The estimation module sends the first initial angle as an initial input parameter to the numerically controlled oscillator, and simultaneously sends the first initial angular velocity as an initial input parameter to the loop filter. The estimated first initial angle is a value close to the actual angle. After being sent to the numerically controlled oscillator, the resolver-to-digital converter (RDBDC) uses it as the starting condition for loop establishment. Similarly, the estimated first initial angular velocity is also a value close to the actual angular velocity. After being sent to the loop filter, the RDBDC uses the first initial angle and first initial angular velocity, which are close to the actual values, as the starting conditions for loop establishment. Compared to the RDBDC's loop construction based entirely on self-feedback, the technical solution of this embodiment of the invention greatly reduces the time required for loop convergence, significantly shortening the response time of the feedback control system constructed by the RDBDC. This achieves faster and more accurate angle and angular velocity detection.
[0062] Optionally, in this embodiment of the invention, obtaining the first initial angle based on the sine output signal and the cosine output signal of the rotary transformer includes: integrating the sine output signal and the cosine output signal respectively to obtain a sine envelope signal matching the sine output signal and a cosine envelope signal matching the cosine output signal; and obtaining the first initial angle based on the sine envelope signal and the cosine envelope signal.
[0063] Specifically, the calculation method for obtaining the first initial angle using Equation 6 may be affected by the high-frequency carrier wave, leading to certain errors in the calculation results. Therefore, the envelope signal in the sinusoidal and cosine output signals can be extracted using integration to recalculate the first initial angle. For ease of calculation, the integral result Q of the sinusoidal output signal along the positive half-axis period can be extracted using the following equation. d The integral result of the cosine output signal over the positive half-axis period I d '.
[0064]
[0065] Finally, the first initial angle θ1 is calculated using the following equation:
[0066]
[0067] The envelope signal obtained by integrating the sine and cosine output signals is used to calculate the first initial angle, avoiding the influence of the high-frequency carrier on the calculation result, improving the calculation accuracy of the first initial angle, thereby reducing the construction time of the closed loop of the resolver-to-digital converter and improving the response speed of the feedback control system in the resolver-to-digital converter.
[0068] Optionally, in this embodiment of the invention, the step of integrating the sine output signal and the cosine output signal respectively to obtain a sine envelope signal matching the sine output signal and a cosine envelope signal matching the cosine output signal includes: shaping the sine output signal and the cosine output signal respectively according to a sign flag bit to obtain a sine-shaped signal matching the sine output signal and a cosine-shaped signal matching the cosine output signal; wherein the sign flag bit is used to distinguish the positive half-axis period and the negative half-axis period of the carrier signal; and integrating the sine-shaped signal and the cosine-shaped signal respectively to obtain a sine envelope signal matching the sine-shaped signal and a cosine envelope signal matching the cosine-shaped signal.
[0069] Specifically, in order to ensure the acquisition of the integral result Q of the sinusoidal output signal over the complete cycle... d ", and the integral result I of the cosine output signal over the complete cycle. d Furthermore, a carrier sign flag can be generated simultaneously with the carrier signal. The sign flag is 1 during the positive half-axis period and -1 during the negative half-axis period. Combining the sign flag with the carrier signal, the information of the negative half-axis is inverted, which is essentially equivalent to taking the absolute value of the carrier information. That is, Equation 1 in the above technical solution can be represented by Equation 11, and Equation 2 in the above technical solution can be represented by Equation 12.
[0070] Qd=E0*|sin(wt)|*sin(θ) (Equation 11);
[0071] Id = E0 * |sin(wt)| * cos(θ) (Equation XII);
[0072] Integrating the sinusoidal output signal in Equation 11 over a complete carrier cycle, and simultaneously integrating the cosine output signal in Equation 12, the integral result Q of the sinusoidal output signal over the complete carrier cycle is obtained through Equation 13. d", and the integral result I of the output signal through equation fourteen cosine over the complete carrier period. d ":
[0073]
[0074] Finally, the first initial angle θ1 is calculated using the following equation:
[0075]
[0076] By performing shaping and integration calculations on the sine and cosine output signals over the complete carrier cycle, the envelope signal is obtained, further avoiding the influence of the high-frequency carrier on the calculation results, improving the calculation accuracy of the first initial angle, thereby reducing the construction time of the closed loop of the resolver-to-digital converter and improving the response speed of the feedback control system in the resolver-to-digital converter.
[0077] Taking the above technical solution as an example, assuming the sampling frequency of the analog-to-digital converter is T = 160 kHz, the electrical frequency is 3125 rpm, the initial rotor angle of the rotary transformer is 0.5π, and the horizontal axis ts = n / T; where n is the number of simulation points in seconds (s); from Figure 3 It can be seen that when there is no first initial angle and first initial angular velocity, that is, when both the first initial angle and first initial angular velocity are 0, the loop setup time of the resolver-to-digital converter is 0.01s; Figure 4 It can be seen that when the calculated initial angular velocity is used as the initial parameter, the loop setup time of the resolver-to-digital converter is 0.0025s; Figure 5 It can be seen that when the calculated first initial angular velocity and first initial angle are used as initial parameters, the loop establishment time of the resolver-to-digital converter is 0.001s.
[0078] From the above Figure 3 and Figure 5 As can be seen, compared with traditional technical solutions, the signal loop convergence time of the resolver-to-digital converter in this embodiment of the invention is improved by 10 times; the accuracy of the estimation of the first initial angular velocity directly affects the speed of loop establishment. A more accurate estimation of the first initial angular velocity can enable the loop to converge to the correct velocity value faster, thereby reducing the adjustment time and improving the response speed of the feedback control system; similarly, the accuracy of the estimation of the first initial angle also plays a crucial role in the speed of loop establishment. A precise estimation of the first initial angle helps the loop to quickly lock the correct position information, thereby accelerating the response time of the feedback control system.
[0079] The technical solution of this invention involves an estimation module of a resolver-to-digital converter (RDBDC) that first obtains a first initial angle based on the sine and cosine output signals of the resolver; then, based on at least two first initial angles and the sampling frequency of the analog-to-digital converter (ADC), it obtains a first initial angular velocity; finally, it sends the first initial angle to a numerically controlled oscillator and the first initial angular velocity to a loop filter, so that the signal loop of the RDBDC performs phase synchronization based on the first initial angle and the first initial angular velocity. This reduces the construction time of the closed loop of the RDBDC, improves the response speed of the feedback control system in the RDBDC, and thus improves the decoding efficiency of the RDBDC.
[0080] Example 2
[0081] Figure 6 This is a flowchart of a signal loop adjustment method provided in Embodiment 2 of the present invention. The relationship between this embodiment and the above embodiments is that if the closed loop constructed by the resolver-to-digital converter is not stable within a first preset time, the initial angle and initial angular velocity are recalculated and obtained. Figure 6 As shown, the method includes:
[0082] S201. Obtain the first initial angle based on the sine and cosine output signals of the rotary transformer.
[0083] S202. Obtain the first initial angular velocity based on at least two of the first initial angles and the sampling frequency of the analog-to-digital converter.
[0084] S203. The first initial angle is sent to the numerically controlled oscillator, and the first initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity.
[0085] S204. If, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship, the second initial angle and the second initial angular velocity are obtained based on the sine and cosine output signals of the rotary transformer.
[0086] The condition for the closed loop constructed by the resolver-to-digital converter to reach stability is that the frequency and phase of the output signal of the numerically controlled oscillator are consistent with the frequency and phase of the input signal of the phase detector, that is, the phase difference between the two is eliminated, and the output signal of the numerically controlled oscillator automatically tracks the input signal of the phase detector. If the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship within the first preset time, it indicates that the closed loop constructed by the resolver-to-digital converter has not reached stability after the first preset time. At this time, it may be due to the existence of sampling error or calculation error, which makes the numerical error of the first initial angle and the first initial angular velocity obtained by calculation too large. Therefore, the second initial angle and the second initial angular velocity can be recalculated based on the sine and cosine output signals of the resolver.
[0087] S205. The second initial angle is sent to the numerically controlled oscillator, and the second initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the second initial angle and the second initial angular velocity.
[0088] The recalculated second initial angle and second initial angular velocity are sent to the resolver-to-digital converter (RDB). With the modified initial parameters, the RDB is guided to re-execute the phase synchronization operation. That is, the RDB is guided to reconstruct the closed loop of the feedback control system based on the second initial angle and second initial angular velocity, and make it tend to stabilize. This avoids the excessive time consumption of the RDB's phase synchronization operation due to the calculation error of the first initial angle and first initial angular velocity, ensures the accuracy of the initial parameter values, and improves the execution efficiency of the RDB's phase synchronization operation.
[0089] Optionally, in this embodiment of the invention, after sending the second initial angle to the numerically controlled oscillator and the second initial angular velocity to the loop filter, the method further includes: if, within a second preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship, obtaining a third initial angle and a third initial angular velocity based on the sine and cosine output signals of the resolver; wherein the second preset time period is less than the first preset time period; sending the third initial angle to the numerically controlled oscillator and the third initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the third initial angle and the third initial angular velocity.
[0090] Specifically, as described in the above technical solution, if the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship within the first preset time, and the second initial angle and the second initial angular velocity have been obtained by recalculation, guiding the resolver to re-execute the phase synchronization operation, when monitoring the loop convergence result again, the monitoring time needs to be reduced, that is, the second preset time is less than the first preset time, so as to correct the calculation error of the initial angle and the initial angular velocity in a timely manner, so as to complete the update of abnormal initial parameters in a short time.
[0091] Optionally, in this embodiment of the invention, after sending the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, the method further includes: if, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship, updating the first initial angle and the first initial angular velocity according to the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector; sending the updated first initial angle to the numerically controlled oscillator and the updated first initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the updated first initial angle and the updated first initial angular velocity.
[0092] Specifically, based on the calculated first initial angle and first initial angular velocity, according to the phase relationship between the output signal of the CNC oscillator and the input signal of the phase detector, if the phase difference between the two is large, it indicates that the parameter values of the first initial angle and first initial angular velocity have a large error. In this case, when updating the first initial angle and first initial angular velocity, the numerical change of the updated first initial angle and first initial angular velocity will be greater. Conversely, if the phase difference between the two is small, it indicates that the parameter values of the first initial angle and first initial angular velocity have a small error. In this case, when updating the first initial angle and first initial angular velocity, the numerical change of the updated first initial angle and first initial angular velocity will be smaller. Based on this phase relationship between the output signal of the CNC oscillator and the input signal of the phase detector, the first initial angle and first initial angular velocity are updated in a targeted manner, improving the accuracy and efficiency of updating the initial angle and initial angular velocity, and avoiding possible calculation errors when recalculating the initial angle and initial angular velocity.
[0093] The technical solution of this invention addresses the issue that if the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship within a first preset time period, a second initial angle and a second initial angular velocity are obtained based on the sine and cosine output signals of the resolver. The second initial angle is then sent to the numerically controlled oscillator, and the second initial angular velocity is sent to the loop filter, enabling the resolver-to-digital converter (RDBDC) to perform phase synchronization operation again based on the second initial angle and the second initial angular velocity. This avoids excessively long phase synchronization operation times for the RDBDC due to calculation errors in the first initial angle and the first initial angular velocity, ensures the accuracy of the initial parameters, and improves the execution efficiency of the RDBDC's phase synchronization operation.
[0094] Example 3
[0095] Figure 7 This is a structural block diagram of a signal loop adjustment device provided in Embodiment 3 of the present invention. This device is applied to the estimation module of a resolver-to-digital converter and specifically includes:
[0096] The initial angle acquisition module 301 is used to acquire the first initial angle based on the sine and cosine output signals of the rotary transformer.
[0097] The initial angular velocity acquisition module 302 is used to acquire the first initial angular velocity based on at least two first initial angles and the sampling frequency of the analog-to-digital converter;
[0098] The initial parameter sending module 303 is used to send the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity.
[0099] The technical solution of this invention involves an estimation module of a resolver-to-digital converter (RDBDC) that first obtains a first initial angle based on the sine and cosine output signals of the resolver; then, based on at least two first initial angles and the sampling frequency of the analog-to-digital converter (ADC), it obtains a first initial angular velocity; finally, it sends the first initial angle to a numerically controlled oscillator and the first initial angular velocity to a loop filter, so that the signal loop of the RDBDC performs phase synchronization based on the first initial angle and the first initial angular velocity. This reduces the construction time of the closed loop of the RDBDC, improves the response speed of the feedback control system in the RDBDC, and thus improves the decoding efficiency of the RDBDC.
[0100] Optionally, the initial angle acquisition module 301 is specifically used to integrate the sine output signal and the cosine output signal respectively to obtain a sine envelope signal that matches the sine output signal and a cosine envelope signal that matches the cosine output signal; and to obtain a first initial angle based on the sine envelope signal and the cosine envelope signal.
[0101] Optionally, the initial parameter sending module 303 is specifically used to perform shaping processing on the sine output signal and the cosine output signal respectively according to the sign flag bit to obtain a sine-shaped signal matching the sine output signal and a cosine-shaped signal matching the cosine output signal; wherein, the sign flag bit is used to distinguish the positive half-axis period and the negative half-axis period of the carrier signal; and to perform integration processing on the sine-shaped signal and the cosine-shaped signal respectively to obtain a sine envelope signal matching the sine-shaped signal and a cosine envelope signal matching the cosine-shaped signal.
[0102] Optionally, the signal loop adjustment device is further configured to, if the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship within a first preset time, obtain a second initial angle and a second initial angular velocity based on the sine and cosine output signals of the resolver; send the second initial angle to the numerically controlled oscillator and the second initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the second initial angle and the second initial angular velocity.
[0103] Optionally, the signal loop adjustment device is further configured to, if the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship within a second preset time, obtain a third initial angle and a third initial angular velocity based on the sine and cosine output signals of the resolver; wherein the second preset time is less than the first preset time; send the third initial angle to the numerically controlled oscillator and the third initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the third initial angle and the third initial angular velocity.
[0104] Optionally, the signal loop adjustment device is further configured to, if the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to a preset phase relationship within a first preset time period, update the first initial angle and the first initial angular velocity respectively according to the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector; send the updated first initial angle to the numerically controlled oscillator and the updated first initial angular velocity to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the updated first initial angle and the updated first initial angular velocity.
[0105] The above-described apparatus can execute the signal loop adjustment method provided in any embodiment of the present invention, and has the corresponding functional modules and beneficial effects for executing the method. Technical details not described in detail in this embodiment can be found in the signal loop adjustment method provided in any embodiment of the present invention.
[0106] Example 4
[0107] Figure 8 A schematic diagram of an electronic device 10 that can be used to implement embodiments of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, electronic devices, blade electronic devices, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (such as helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.
[0108] like Figure 8 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0109] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0110] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as signal loop conditioning methods.
[0111] In some embodiments, the signal loop conditioning method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as a storage unit. In some embodiments, part or all of the computer program may be loaded and / or installed on a heterogeneous hardware accelerator via ROM and / or a communication unit. When the computer program is loaded into RAM and executed by a processor, one or more steps of the signal loop conditioning method described above may be performed. Alternatively, in other embodiments, the processor may be configured to perform the signal loop conditioning method by any other suitable means (e.g., by means of firmware).
[0112] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0113] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or electronic device.
[0114] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.
[0115] To provide user interaction, the systems and techniques described herein can be implemented on a heterogeneous hardware accelerator, which includes: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the heterogeneous hardware accelerator. Other types of devices can also be used to provide user interaction; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or haptic feedback); and input from the user can be received in any form (including sound input, voice input, or haptic input).
[0116] The systems and technologies described herein can be implemented in computing systems that include back-end components (e.g., as data electronic devices), or computing systems that include middleware components (e.g., application electronic devices), or computing systems that include front-end components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with implementations of the systems and technologies described herein), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
[0117] A computing system can include clients and electronic devices. Clients and electronic devices are generally geographically separated and typically interact via communication networks. The client-electronic device relationship is created by computer programs running on the respective computers and establishing a client-electronic device relationship between them. Electronic devices can be cloud electronic devices, also known as cloud computing electronic devices or cloud servers, which are hosting products within the cloud computing service ecosystem. These address the shortcomings of traditional physical hosting and VPS services, such as high management difficulty and weak business scalability.
[0118] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.
[0119] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.
Claims
1. A signal loop adjustment method, characterized in that, An estimation module applied to a resolver-to-digital converter includes: A first initial angle is obtained based on the sine and cosine output signals of the rotary transformer; wherein the first initial angle is the result of calculating the arctangent of the sine and cosine output signals. The first initial angular velocity is obtained based on at least two of the first initial angles and the sampling frequency of the analog-to-digital converter; The first initial angle is sent to the numerically controlled oscillator, and the first initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity; the numerically controlled oscillator is used to adjust the oscillation frequency of the output signal of the loop filter so that the difference between the rotor angle and the phase angle approaches 0.
2. The method according to claim 1, characterized in that, The step of obtaining the first initial angle based on the sine and cosine output signals of the rotary transformer includes: The sine output signal and the cosine output signal are integrated respectively to obtain a sine envelope signal that matches the sine output signal and a cosine envelope signal that matches the cosine output signal. The first initial angle is obtained based on the sine envelope signal and the cosine envelope signal.
3. The method according to claim 2, characterized in that, The step of integrating the sine output signal and the cosine output signal respectively to obtain a sine envelope signal matching the sine output signal and a cosine envelope signal matching the cosine output signal includes: Based on the sign flag, the sine output signal and the cosine output signal are shaped to obtain a sine-shaped signal that matches the sine output signal and a cosine-shaped signal that matches the cosine output signal; wherein, the sign flag is used to distinguish the positive half-axis period and the negative half-axis period of the carrier signal. The sine-shaped signal and the cosine-shaped signal are integrated to obtain a sine envelope signal that matches the sine-shaped signal and a cosine envelope signal that matches the cosine-shaped signal.
4. The method according to claim 1, characterized in that, After sending the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, the method further includes: If, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship, the second initial angle and the second initial angular velocity are obtained based on the sine and cosine output signals of the rotary transformer. The second initial angle is sent to the numerically controlled oscillator, and the second initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the second initial angle and the second initial angular velocity.
5. The method according to claim 4, characterized in that, After sending the second initial angle to the numerically controlled oscillator and the second initial angular velocity to the loop filter, the method further includes: If, within a second preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship, a third initial angle and a third initial angular velocity are obtained based on the sine and cosine output signals of the rotary transformer; wherein, the second preset time is less than the first preset time; The third initial angle is sent to the numerically controlled oscillator, and the third initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the third initial angle and the third initial angular velocity.
6. The method according to claim 1, characterized in that, After sending the first initial angle to the numerically controlled oscillator and the first initial angular velocity to the loop filter, the method further includes: If, within a first preset time period, the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector does not conform to the preset phase relationship, the first initial angle and the first initial angular velocity are updated respectively according to the phase relationship between the output signal of the numerically controlled oscillator and the input signal of the phase detector. The updated first initial angle is sent to the numerically controlled oscillator, and the updated first initial angular velocity is sent to the loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation again based on the updated first initial angle and the updated first initial angular velocity.
7. A signal loop adjustment device, characterized in that, An estimation module applied to a resolver-to-digital converter includes: An initial angle acquisition module is used to acquire a first initial angle based on the sine and cosine output signals of the rotary transformer; wherein the first initial angle is the result of calculating the arctangent of the sine and cosine output signals; An initial angular velocity acquisition module is used to acquire a first initial angular velocity based on at least two first initial angles and the sampling frequency of the analog-to-digital converter; An initial parameter sending module is used to send the first initial angle to a numerically controlled oscillator and the first initial angular velocity to a loop filter, so that the signal loop of the resolver-to-digital converter performs phase synchronization operation based on the first initial angle and the first initial angular velocity; the numerically controlled oscillator is used to adjust the oscillation frequency of the output signal of the loop filter so that the difference between the rotor angle and the phase angle approaches 0.
8. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the signal loop adjustment method according to any one of claims 1-6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions that cause a processor to execute the signal loop adjustment method according to any one of claims 1-6.
10. A computer program product comprising a computer program that, when executed by a processor, implements the signal loop adjustment method of any one of claims 1-6.