Rotary transformer zero point alignment method, device, electronic device and storage medium
By calculating the time required for the construction and initialization of the rotation transformer excitation signal, determining the delay correction time, and delay compensation for the excitation signal or sample trigger signal, the zero-point alignment of the rotation transformer is achieved, solving the problems of increased hardware cost and failure efficiency in the prior art, and achieving accurate analysis of motor angles and high precision of motor control.
Patent Information
- Application Number
- CN202411871258.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-18
- Publication Date
- 2025-04-04
AI Technical Summary
In the prior art, when implementing the rotation transformer for motor angle analysis, there are problems of increased hardware cost and increased random hardware failure.
By determining the duration required for the excitation signal for the rotation transformer, the duration required for the initialization of the functional layer, the duration required for the initialization of the monitoring layer, and the duration required for the interrupt response of the monitoring layer, the delay correction time is calculated, and the excitation signal or sample trigger signal is delayed compensation based on the duration to achieve zero-point alignment.
It realizes accurate analysis of motor angle at low cost, avoids the problems of increasing hardware costs and increasing random hardware failure efficiency, and improves the accuracy of motor control and the overall performance and reliability of the electric drive system.
Smart Images

Figure CN119766050A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of electric drive technology, and in particular to a method, a device, an electronic device and a storage medium for zero point alignment of a rotary transformer. Background Art
[0002] With the rapid development of the new energy vehicle market, the safety of the electric drive system, as the core component of the power system of new energy vehicles, has received increasing attention. Especially in the field of functional safety, such as the motor controller of the electric drive system, which is used to control the motor output, once the motor controller fails, it may cause unexpected acceleration or deceleration of the vehicle, directly threatening the life safety of the driver and passengers. As a motor angle analysis device widely used in electric drive systems, the rotary transformer is used to cooperate with the motor controller to achieve high-precision motor output control. Specifically, the motor controller can accurately control the motor output based on the motor output parameters fed back by the rotary transformer.
[0003] Based on the rotary transformer, in order to achieve accurate analysis of the motor angle, the relevant technology generally adopts the method of adding an excitation zero-crossing comparison circuit, triggering the functional safety layer rotary transformer sampling through the zero-crossing signal, ensuring that the signal sampling is performed at the correct time point, thereby ensuring that the Sin and Cos feedback signals output by the rotary transformer are consistent in time with the excitation signal used for the rotary transformer, thereby achieving accurate analysis of the motor angle. However, it has the problems of increased hardware cost and increased random hardware failure rate. Summary of the invention
[0004] The problem solved by the present invention is: how to realize accurate analysis of the motor angle at low cost.
[0005] In order to solve the above problems, the present invention provides a method, device, electronic device and storage medium for zero point alignment of a rotary transformer.
[0006] In a first aspect, the present invention provides a method for zero point alignment of a rotary transformer, comprising:
[0007] Determine a first duration required for an excitation signal for a rotary transformer to be constructed through a functional layer, a second duration required for the functional layer to be initialized, a third duration required for a monitoring layer to be initialized, and a fourth duration required for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and the output signal of the rotary transformer;
[0008] Determine a delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration;
[0009] Based on the excitation signal obtained by sampling the monitoring layer and used to input the rotary transformer, and the sampling trigger signal used to trigger the monitoring layer to sample the output signal, the delay correction duration is used to perform delay compensation on the sampled excitation signal or the sampling trigger signal, and a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed is determined;
[0010] If the zero point alignment error is less than or equal to a first preset value, it is determined that the delay correction duration meets the motor angle resolution accuracy requirement.
[0011] Optionally, determining a first time length required for an excitation signal for a rotary transformer to be constructed through a functional layer includes:
[0012] It is determined that the time required from receiving the excitation wave enabling signal from the functional layer to sampling by the monitoring layer to obtain the excitation signal for inputting into the rotary transformer is the first time length.
[0013] Optionally, determining a second duration required for the functional layer to be initialized includes:
[0014] Determine the time length required for the functional layer to be initialized according to the excitation wave enabling signal as the second time length, wherein the initialization includes configuring characteristic parameters of the excitation signal.
[0015] Optionally, determining a third time duration required for the monitoring layer to be initialized includes:
[0016] The duration required for initialization of the monitoring layer is determined to be the third duration, wherein the initialization includes configuring sampling characteristic parameters for the excitation signal and the output signal.
[0017] Optionally, determining a fourth duration required for the monitoring layer interrupt response includes:
[0018] It is determined that the time required from the monitoring layer receiving the interrupt enable signal to the monitoring layer entering the interrupt is the fourth time period.
[0019] Optionally, determining the delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration includes:
[0020] The difference between the first duration and the cumulative response duration is determined as the delay correction duration, wherein the cumulative response duration is the sum of the second duration, the third duration and the fourth duration.
[0021] Optionally, based on the excitation signal obtained by sampling the monitoring layer and input to the rotary transformer, and the sampling trigger signal used to trigger the monitoring layer to sample the output signal, delay compensation is performed on the sampled excitation signal or the sampling trigger signal using the delay correction duration, and a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed is determined, including:
[0022] The delay correction time length is used to perform delay compensation on the time axis for the excitation signal obtained by sampling, and a first zero point on the time axis corresponding to the waveform of the excitation signal after delay compensation is determined, and a second zero point on the time axis corresponding to the waveform of the sampling trigger signal is determined; and an absolute value of the minimum time difference between the first zero point and the second zero point is determined as the zero point alignment error;
[0023] Or, use the delay correction time length to perform delay compensation on the sampling trigger signal on the time axis, determine the second zero point of the waveform corresponding to the sampling trigger signal after delay compensation on the time axis, and determine the first zero point of the waveform corresponding to the sampled excitation signal on the time axis; determine the absolute value of the minimum time difference between the first zero point and the second zero point as the zero point alignment error.
[0024] Optionally, the monitoring layer includes a sampling period synchronization module, a first sampling module and a second sampling module that are cascaded to each other; the first sampling module is used for sampling the excitation signal, the second sampling module is used for sampling the output signal, and the sampling period synchronization module is used to synchronize the sampling periods of the first sampling module and the second sampling module.
[0025] In a second aspect, the present invention provides a rotary transformer zero point alignment device, comprising:
[0026] A timing module, used to determine a first duration required for an excitation signal for a rotary transformer to be constructed through a functional layer, a second duration required for the functional layer to be initialized, a third duration required for a monitoring layer to be initialized, and a fourth duration required for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and the output signal of the rotary transformer;
[0027] A calculation module, used to determine a delay correction duration according to the first duration, the second duration, the third duration and the fourth duration;
[0028] A delay module, for performing delay compensation on the sampled excitation signal or the sampling trigger signal using the delay correction duration based on the excitation signal for inputting the rotary transformer obtained by sampling the monitoring layer and the sampling trigger signal for triggering the monitoring layer to sample the output signal, and determining a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed;
[0029] The verification module is used to determine whether the delay correction duration meets the motor angle resolution accuracy requirement if the zero point alignment error is less than or equal to a first preset value.
[0030] In a third aspect, the present invention provides an electronic device, including a memory and a processor;
[0031] The memory is used to store computer programs;
[0032] The processor is used to implement the resolver zero point alignment method as described in the first aspect when executing the computer program.
[0033] In a fourth aspect, the present invention provides a computer-readable storage medium storing a computer program. When the computer program is read and executed by a processor, the rotary transformer zero point alignment method as described in the first aspect is implemented.
[0034] The beneficial effects of the rotary transformer zero point alignment method, device, electronic device and storage medium of the present invention are as follows: the present invention is used to realize the zero point alignment of the excitation signal of the rotary transformer and the sampling trigger signal for sampling the output signal of the rotary transformer, specifically by determining the delay correction duration, and verifying the accuracy and effectiveness of the delay correction duration based on the zero point alignment error corresponding to the delay correction duration, so as to obtain the delay correction duration that meets the motor angle resolution accuracy requirements, which is used for the delay correction (or delay compensation) of the sampling trigger signal, ensuring that the sampling trigger occurs at the correct time point of the excitation signal cycle, thereby achieving higher precision motor control. Wherein, based on the first duration required for the excitation signal for the rotary transformer to be constructed through the functional layer, the second duration required for the functional layer to be initialized, the third duration required for the monitoring layer for sampling the excitation signal and the output signal of the rotary transformer to be initialized, and the fourth duration required for determining the interrupt response of the monitoring layer, the delay correction duration is determined, and the time delay factors that may affect the construction of the excitation signal and the sampling trigger are fully and comprehensively considered, so as to improve the reliability and accuracy of the calculation result of the delay correction duration. In addition, the present invention can be implemented based on the existing hardware equipment of the electric drive system, without adding additional hardware such as an excitation zero-crossing comparison circuit, and can achieve accurate analysis of the motor angle at a low cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] Figure 1 A schematic diagram of a process flow of a rotary transformer zero point alignment method according to an embodiment of the present invention;
[0036] Figure 2 A schematic diagram of waveforms corresponding to an excitation signal and a sampling trigger signal in an embodiment of the present invention;
[0037] Figure 3 : is a structural block diagram of a rotary transformer zero point alignment device in an embodiment of the present invention;
[0038] Figure 4 The figure is a schematic diagram of the structure of the communication connection between the memory and the processor of the electronic device in the embodiment of the present invention. DETAILED DESCRIPTION
[0039] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, specific embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0040] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein.
[0041] Combination Figure 1 , Figure 2 As shown, an embodiment of the present invention provides a method for zero point alignment of a rotary transformer, comprising:
[0042] Step 100, determine the first time duration required for the excitation signal for the rotary transformer to be constructed through the functional layer, determine the second time duration required for the functional layer to be initialized, determine the third time duration required for the monitoring layer to be initialized, and determine the fourth time duration required for the monitoring layer to interrupt the response, wherein the monitoring layer is used to sample the excitation signal and the output signal of the rotary transformer.
[0043] Based on the rotary transformer, in order to achieve accurate analysis of the motor angle, it is necessary to ensure that the excitation signal for the rotary transformer is zero-aligned with the sampling trigger signal for sampling the output signal of the rotary transformer (that is, the corresponding zero point of the waveform corresponding to the signal is at the same time or the interval is less than or equal to the first preset value on the time axis), so as to ensure that the collected rotary transformer output signal (that is, the corresponding Sin and Cos signals, reflecting the actual position of the motor rotor) maintains a strict time synchronization relationship with the excitation signal, avoiding signal phase offset and motor rotor angle analysis error caused by the sampling moment and the excitation signal reference point (such as zero point) being out of sync. Among them, through zero point alignment, it can be ensured that the sampling trigger occurs at the correct time point of the excitation signal cycle, so that the sampling result accurately reflects the actual value of the Sin and Cos signals at the corresponding time, and ensures that the motor angle analysis corresponds accurately to the actual rotor position and the corresponding time, so as to facilitate the realization of higher-precision motor control and improve the overall performance and reliability of the electric drive system.
[0044] The method of this embodiment is used to implement the above-mentioned excitation signal for the rotary transformer, and to align the zero point with the sampling trigger signal for sampling the output signal of the rotary transformer. Specifically, through step 100, the time required for the excitation signal for the rotary transformer to be constructed through the functional layer is determined (recorded as the first time), and the first time is the time required for the functional layer to complete the construction of the corresponding excitation signal from receiving the excitation wave enable signal, wherein the functional layer is used to realize the construction of the excitation signal. Determine the time required for the functional layer to be initialized (recorded as the second time), that is, the second time is the time required for the functional layer to complete the initialization. Determine the time required for the monitoring layer for sampling the excitation signal and the output signal of the rotary transformer to be initialized (recorded as the third time), that is, the third time is the time required for the monitoring layer to complete the initialization, wherein the monitoring layer is used for sampling the excitation signal and the output signal of the rotary transformer. Determine the fourth time required for the monitoring layer to interrupt the response, that is, determine the time required for the monitoring layer to interrupt and enable to enter the interrupt (recorded as the fourth time). By determining the above time parameters, we can accurately grasp the time characteristics of key links such as excitation signal construction, functional layer and monitoring layer initialization, and sampling triggering, providing an accurate and reliable basis for the calculation of delay correction duration in subsequent steps.
[0045] Step 200: Determine a delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration.
[0046] Since the construction of the excitation signal and the sampling of the rotary transformer output signal may be affected by the hardware and software response delays, in order to ensure that the excitation signal and the sampling trigger signal of the output signal are strictly aligned at zero point, it is necessary to accurately correct the timing of the excitation signal or the sampling trigger signal. Specifically, in step 200, according to the various time parameters determined in step 100, the delay correction duration of the sampling trigger signal for the excitation signal or the output signal sampling is quantitatively calculated. Exemplarily, the delay correction duration = the first duration - the second duration - the third duration - the fourth duration.
[0047] Step 300, based on the excitation signal for inputting into the rotating transformer obtained by sampling the monitoring layer, and the sampling trigger signal for triggering the monitoring layer to sample the output signal, the delay correction duration is used to perform delay compensation on the sampled excitation signal or the sampling trigger signal, and the zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for delay compensation is determined.
[0048] Specifically, in step 300, based on the acquisition of the input end of the rotary transformer, an excitation signal for inputting the rotary transformer and a sampling trigger signal for inputting the monitoring layer to trigger the monitoring layer to sample the output signal of the rotary transformer are obtained, and the delay correction duration is used to compensate for the delay of one of the two, and the compensated one is compared with the other one that is not compensated, and the zero point alignment error of the compensated one and the other one that is not compensated is determined (which is the absolute value of the minimum time difference of the zero point of the waveform corresponding to the two for comparison), which is used to verify whether the determined delay correction duration can effectively correct the corresponding timing deviation and ensure the synchronization of the excitation signal and the sampling trigger signal in time. Among them, considering that the excitation signal directly constructed by the functional layer may have a timing difference with the excitation signal actually received by the rotary transformer due to the delay in the hardware transmission path, therefore, the excitation signal for inputting the rotary transformer (such as the excitation signal collected at the input end of the rotary transformer) can reflect the real state of the signal after being constructed by the functional layer and transmitted to the input end of the rotary transformer, ensuring that the zero point alignment is closer to the actual operation of the rotary transformer. Moreover, considering that the output signal of the resolver is generated by coupling of the internal coil, its phase and amplitude may be affected by the electromagnetic coupling characteristics, signal processing links, etc. Therefore, a sampling trigger signal directly used to trigger the sampling of the resolver output signal is used to align the zero point with the excitation signal to ensure that the sampling trigger occurs at the correct time point of the excitation signal cycle, that is, to ensure that the actual output of the motor is accurately obtained at the corresponding moment of the excitation signal cycle without considering the internal interference factors of the resolver, reducing the uncertainty of the signal processing delay, thereby ensuring that the sampling trigger within the excitation signal cycle is more accurate, and ultimately achieving efficient and precise collaboration between the resolver and the motor control system.
[0049] Step 400: If the zero point alignment error is less than or equal to the first preset value, determine whether the delay correction duration meets the motor angle resolution accuracy requirement.
[0050] Specifically, if the zero point alignment error determined in step 300 is less than or equal to the first preset value (such as 3 microseconds), it is considered that the use of the currently determined delay correction duration can effectively correct the timing deviation between the excitation signal and the sampling trigger signal to meet the motor (rotor) angle resolution accuracy requirements. In this case, based on the delay correction duration, it is possible to ensure that the collected rotary transformer output signal and the excitation signal maintain strict time synchronization, thereby improving the motor angle resolution accuracy. Exemplarily, the delay correction duration is compensated on the sampling trigger signal, that is, by adjusting the trigger time point of the sampling trigger signal, ensuring that the sampling trigger occurs at the correct time point of the excitation signal cycle, so that the sampling result can accurately reflect the actual values of the Sin and Cos signals at the corresponding time, thereby ensuring that the motor angle resolution corresponds accurately to the actual rotor position and the corresponding time, which is convenient for achieving higher-precision motor control and improving the overall performance and reliability of the electric drive system.
[0051] In this way, the method of this embodiment is used to achieve zero point alignment between the excitation signal of the rotary transformer and the sampling trigger signal for sampling the output signal of the rotary transformer, specifically by determining the delay correction duration, and verifying the accuracy and effectiveness of the delay correction duration based on the zero point alignment error corresponding to the delay correction duration, so as to obtain a delay correction duration that meets the motor angle resolution accuracy requirements, which is used for delay correction (or delay compensation) of the sampling trigger signal to ensure that the sampling trigger occurs at the correct time point of the excitation signal cycle, thereby achieving higher precision motor control. Among them, based on the first duration required for the excitation signal for the rotary transformer to be constructed through the functional layer, the second duration required for the functional layer to be initialized, the third duration required for the monitoring layer for sampling the excitation signal and the output signal of the rotary transformer to be initialized, and the fourth duration required for determining the interrupt response of the monitoring layer, the delay correction duration is determined, which fully and comprehensively considers the time delay factors that may affect the construction of the excitation signal and the sampling trigger, and improves the reliability and accuracy of the calculation result of the delay correction duration. In addition, the method of this embodiment can be implemented based on the existing hardware equipment of the electric drive system, without adding additional hardware such as an excitation zero-crossing comparison circuit, and can achieve accurate analysis of the motor angle at a low cost.
[0052] Optionally, the method of this embodiment is applicable to the research and development stage (such as the algorithm verification stage of the motor controller) or the pre-delivery debugging stage (such as the calibration stage of the control system) of the electric drive system or the vehicle with the electric drive system. In these stages, the zero point alignment of the rotary transformer excitation signal and the sampling trigger signal is completed by the method of this embodiment, and the delay correction duration that meets the motor angle resolution accuracy requirement is determined. Exemplarily, in the research and development stage, the engineer uses the method of this embodiment to calibrate the delay correction duration to compensate for the timing deviation introduced by the hardware signal path, processing delay and other factors in the electric drive system, and ensure that it can meet the working accuracy requirements of the target motor; and the delay correction duration is written as a delay parameter to the fixed configuration item of the motor controller (such as stored in a non-volatile memory), and no subsequent changes or adjustments are required. In this way, the optimization of the delay correction duration parameters is completed through the research and development and debugging stages, and no modification or recalibration is required in the later use, which reduces the difficulty of operation and maintenance, and realizes the fixation and standardization of the delay correction duration, which is convenient for the consistent production of different batches of motor controllers, ensuring performance standardization, and so on.
[0053] Optionally, the functional layer and the monitoring layer are functional modules or components of the motor controller. The functional layer can be used to be responsible for the core calculation and signal processing tasks of the motor controller, such as generating excitation signals, configuring motor operating parameters, executing control algorithms, etc.; the monitoring layer can be used to monitor and sample the status of the corresponding components of the electric drive system, including collecting the output signal of the rotary transformer, triggering signal sampling, performing signal analysis and diagnosis, etc. Exemplarily, both the functional layer and the monitoring layer can be integrated into the MCU (Microcontroller Unit) of the motor controller as corresponding modules. Based on this, the delay correction duration is the time difference from the initialization of the internal function of the MCU to the establishment of the function. For the MCU, this time difference has a high consistency, so the delay correction duration is measured once, which can be applied to all motor controllers with the MCU without measuring each time.
[0054] Optionally, determining a first time length required for an excitation signal for the rotary transformer to be constructed through a functional layer includes:
[0055] It is determined that the time required from the functional layer receiving the excitation wave enabling signal to the monitoring layer sampling to obtain the excitation signal for inputting into the rotary transformer is the first time length.
[0056] The first duration is used to characterize the time delay required for the construction of the rotary transformer excitation signal, that is, the time delay for the rotary transformer excitation signal to be generated at the functional layer and transmitted to the sampleable state of the monitoring layer (or generated at the functional layer and input to the rotary transformer). Specifically, after receiving the excitation wave enable signal, the functional layer starts to generate an excitation signal with predetermined characteristic parameters, and transmits it to the input end of the rotary transformer through the corresponding hardware signal path. Among them, the predetermined characteristic parameters of the excitation signal include signal frequency, amplitude, phase and period, etc. For the timing of the first duration, it starts from the time when the functional layer receives the excitation wave enable signal until the monitoring layer samples the corresponding excitation signal at the input end of the rotary transformer.
[0057] In this way, it is ensured that the determined first duration can truly reflect the total duration of the entire process from the functional layer generating the excitation signal to the monitoring layer successfully sampling.
[0058] Optionally, determining a second duration required for the functional layer to be initialized includes:
[0059] Determine the time length required for the functional layer to be initialized according to the excitation wave enabling signal as the second time length, wherein the initialization includes configuring characteristic parameters of the excitation signal.
[0060] Specifically, in the process of constructing the excitation signal of the functional layer, initialization is required first, including completing the configuration of the characteristic parameters of the excitation signal (such as frequency, amplitude, phase and period, etc.), so as to ensure that the functional layer that has completed the initialization can directly generate the corresponding excitation signal for the rotary transformer according to the excitation wave enable signal, and ensure that the generated signal meets the requirements of motor operation and angle resolution. After receiving the excitation wave enable signal, the functional layer needs to complete a series of initialization operations, such as setting hardware registers, configuring the characteristic parameters of the excitation signal, and verifying whether the configuration is effective, etc. These operations require a certain time delay, which is defined as the second duration. For the timing of the second duration, it starts from the time when the functional layer receives the excitation wave enable signal until the functional layer completes the initialization. In some embodiments, the flag that the functional layer completes the initialization can be determined by: setting a flag signal or register bit inside the functional layer, which is set when the initialization is completed; or sampling the signal at the output end of the functional layer through the monitoring layer, and sampling the corresponding excitation signal at the output end of the functional layer to consider that the functional layer is initialized. In this way, by determining the second duration, the time required for the functional layer to complete the initialization is accurately quantified to avoid the timing deviation of the excitation signal caused by the fluctuation of the initialization delay.
[0061] Optionally, determining a third time duration required for initializing a monitoring layer for sampling an excitation signal and an output signal of a rotary transformer comprises:
[0062] The time required for initialization of the monitoring layer is determined to be a third time, wherein the initialization includes configuring sampling characteristic parameters for the excitation signal and the output signal.
[0063] Specifically, the third duration is used to characterize the time delay required for the monitoring layer to perform the initialization operation. The initialization of the monitoring layer mainly includes completing the configuration of the relevant characteristic parameters required for sampling the excitation signal and the rotary transformer output signal; by accurately measuring the initialization time of the monitoring layer, it is ensured that the subsequent sampling tasks can meet the needs of signal analysis. Exemplarily, in the monitoring layer, according to the hardware circuit structure or signal characteristics, a sampling channel for collecting the excitation signal is selected, and parameters such as sampling frequency, resolution, trigger mode, etc. are configured to ensure that the sampling result has sufficient accuracy and real-time performance; similarly, to collect the rotary transformer output signal, the monitoring layer needs to configure a dedicated sampling channel, and this process involves the setting of the sampling trigger source (such as timer interrupt or external signal trigger), the definition of the sampling window, and the signal gain adjustment. Among them, in order to ensure that the configured parameters can take effect normally, the monitoring layer can be verified by reading the hardware register or detecting the signal sampling results. For the timing of the third duration, it starts from the moment when the monitoring layer receives the initialization command to the moment when the monitoring layer completes the sampling preparation (such as completing all sampling characteristic parameter configurations and verifying that they are effective). In some embodiments, it can be determined whether the initialization is completed by detecting the completion flag bit of the status register of the monitoring layer. In this way, by accurately measuring the third duration, the time requirement for initialization of the monitoring layer can be quantified, providing a reliable basis for determining the delay correction duration.
[0064] Optionally, the method based on this embodiment is performed during the research and development stage or pre-delivery debugging stage of an electric drive system or a vehicle having an electric drive system. Considering that the monitoring layer is put into use of the electric drive system for the first time, the monitoring layer starts initialization when it receives a sampling trigger signal (as an initialization command).
[0065] Optionally, determining a fourth time duration required for the monitoring layer interrupt response includes:
[0066] It is determined that the time required from the monitoring layer receiving the interrupt enable signal to the monitoring layer entering the interrupt is the fourth time period.
[0067] Specifically, the fourth duration is used to characterize the time delay from when the monitoring layer receives the interrupt enable signal to when it enters the interrupt (such as interrupting the currently executed task), and is an important indicator for evaluating the responsiveness of the monitoring layer. This indicator not only reflects the real-time performance of the interrupt logic used for the monitoring layer, but also can reveal potential delay bottlenecks in the interrupt response process of the monitoring layer, and provide accurate and reliable quantitative data. The timing of the fourth duration starts from when the monitoring layer receives the interrupt enable signal to when it enters the interrupt (such as interrupting the currently executed task). In this way, by determining the fourth duration, it is determined that when the monitoring layer needs to perform a sampling task, the time required for the monitoring layer to interrupt other low-priority tasks being processed to start responding to the sampling trigger signal provides a reliable basis for determining the delay correction duration.
[0068] Optionally, determining the delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration includes:
[0069] The difference between the first duration and the cumulative response duration is determined as the delay correction duration, wherein the cumulative response duration is the sum of the second duration, the third duration and the fourth duration.
[0070] Specifically, the delay correction time is used to compensate for the delay in the actual construction process of the rotary transformer excitation signal in the electric drive system, ensuring that the motor controller can accurately analyze the angle information during operation, thereby improving the control accuracy of the electric drive system. Delay The determination is based on the first duration T 1 The difference between the cumulative duration of the response and the first duration T 1 It indicates the total time required for the functional layer to complete the construction of the excitation signal and for the monitoring layer to be able to sample the signal. The cumulative response time is the second time length T 2 , the third duration T 3 And the fourth period T 4 The accumulated result of T corresponds to the time required for the functional layer initialization, the monitoring layer initialization, and the monitoring layer interrupt response. Delay =T 1 -(T 2 +T 3 +T 4 ).
[0071] In this way, the delay correction duration is determined, thereby providing the motor controller with accurate delay compensation parameters, ensuring the time synchronization between the generation of the excitation signal and the corresponding sampling process, and meeting the requirements of motor angle resolution accuracy.
[0072] Optionally, based on the excitation signal for inputting into the rotary transformer obtained by sampling the monitoring layer and the sampling trigger signal for triggering the monitoring layer to sample the output signal, delay compensation is performed on the sampled excitation signal or the sampling trigger signal using the delay correction duration, and determining the zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which delay compensation is performed includes:
[0073] The delay correction time length is used to perform delay compensation on the time axis of the sampled excitation signal, determine the first zero point on the time axis of the waveform corresponding to the delay-compensated excitation signal, and determine the second zero point on the time axis of the waveform corresponding to the sampling trigger signal; determine the absolute value of the minimum time difference between the first zero point and the second zero point as the zero point alignment error;
[0074] Alternatively, use the delay correction time to perform delay compensation on the sampling trigger signal on the time axis, determine the second zero point on the time axis of the waveform corresponding to the sampling trigger signal after delay compensation, and determine the first zero point on the time axis of the waveform corresponding to the sampled excitation signal; determine the absolute value of the minimum time difference between the first zero point and the second zero point as the zero point alignment error.
[0075] When determining the zero point alignment error, the currently determined delay correction duration may be compensated on the excitation signal for inputting the rotary transformer obtained by monitoring layer sampling, or compensated on the sampling trigger signal for output signal sampling.
[0076] Exemplarily, if the delay correction duration is compensated to the excitation signal obtained by sampling, the delay correction duration is applied to the excitation signal for inputting the rotary transformer obtained by sampling the monitoring layer on the time axis, so that the waveform corresponding to the excitation signal moves backward as a whole (the corresponding delay correction duration is greater than 0), and the corresponding waveform of the excitation signal after delay compensation is obtained. Compare the corresponding waveform of the excitation signal after delay compensation with the corresponding waveform of the sampling trigger signal, determine the zero point of the corresponding waveform of the excitation signal after delay compensation on the time axis (recorded as the first zero point), and determine the zero point of the waveform corresponding to the sampling trigger signal on the time axis (recorded as the second zero point), and determine the absolute value of the minimum time difference between two adjacent zero points (the first zero point and the second zero point) as the zero point alignment error.
[0077] Combination Figure 2 As shown, if the delay correction time T DelayTo compensate the sampling trigger signal, a delay correction duration is applied to the sampling trigger signal of the input monitoring layer on the time axis, so that the waveform corresponding to the sampling trigger signal moves backward as a whole (the corresponding delay correction duration is greater than 0), and the corresponding waveform of the sampling trigger signal after delay compensation is obtained. Compare the corresponding waveform of the sampling trigger signal after delay compensation with the corresponding waveform of the sampled excitation signal, determine the zero point of the corresponding waveform of the sampling trigger signal after delay compensation on the time axis (recorded as the second zero point), and determine the zero point of the waveform corresponding to the sampled excitation signal on the time axis (recorded as the first zero point), and determine the absolute value of the minimum time difference between two adjacent zero points (the first zero point and the second zero point) as the zero point alignment error.
[0078] In this way, the zero-point alignment error can be determined intuitively and clearly to ensure the alignment accuracy of the output signal of the rotary transformer sampled by the monitoring layer with the actual input excitation signal or sampling trigger signal on the time axis, thereby improving the accuracy of motor rotor angle analysis based on the rotary transformer in the electric drive system.
[0079] Optionally, when comparing the waveforms to determine the zero point alignment error, it can be done automatically or by manually observing the zero point alignment error.
[0080] Optionally, after step 300, the resolver zero point alignment method further includes:
[0081] If the zero point alignment error is greater than the first preset value, it is determined that the delay correction duration does not meet the motor angle resolution accuracy requirement, and steps 100 to 300 are repeated until the zero point alignment error is less than or equal to the first preset value.
[0082] Specifically, considering that the reason why the zero-point alignment error is greater than the first preset value may be that there are accidental errors in the determination of the corresponding duration and the sampling of the corresponding signal, after determining that the delay correction duration does not meet the motor angle resolution accuracy requirements, steps 100-300 are repeated until the zero-point alignment error is less than or equal to the first preset value, thereby eliminating the impact of accidental errors.
[0083] Optionally, there are multiple monitoring layers; repeating steps 100 to 300 until the zero point alignment error is less than or equal to a first preset value includes:
[0084] Based on other monitoring layers, steps 100 to 300 are repeatedly executed until the zero point alignment error is less than or equal to the first preset value.
[0085] Exemplarily, the system architecture of the monitoring layer is a distributed structure, including multiple monitoring layers. In order to further improve the accuracy of zero-point alignment, especially when the delay correction duration calculation result of one monitoring layer fails to meet the motor angle resolution accuracy requirement, steps 100 to 300 can be repeatedly executed based on other monitoring layers until the zero-point alignment error meets the accuracy requirement. Among them, there are multiple monitoring layers to achieve redundant design of signal sampling, avoid affecting the smooth progress of the method of this embodiment due to the failure of a certain monitoring layer, meet the requirements of functional safety independence, reduce the random hardware failure rate, and improve the robustness and reliability of the method of this embodiment.
[0086] Optionally, the monitoring layer includes a sampling period synchronization module, a first sampling module and a second sampling module which are cascaded to each other; the first sampling module is used for excitation signal sampling, the second sampling module is used for output signal sampling, and the sampling period synchronization module is used to synchronize the sampling periods of the first sampling module and the second sampling module.
[0087] Specifically, the monitoring layer includes a sampling period synchronization module, a first sampling module, and a second sampling module that are cascaded with each other. The module cascade structure realizes accurate synchronization of the sampling period. Specifically, the sampling period synchronization module realizes synchronization of the sampling period of the first sampling module and the second sampling module, ensuring strict alignment of the excitation signal and the output signal in the time dimension, thereby optimizing the accuracy and efficiency of zero point alignment. Among them, the first sampling module is used for sampling the excitation signal, and the second sampling module is used for sampling the output signal, so that the first sampling module and the second sampling module can configure sampling parameters respectively, so as to realize effective and smooth sampling of the excitation signal and the output signal respectively.
[0088] Exemplarily, the motor controller adopts the corresponding chip, and the functional layer and the monitoring layer are integrated on the chip. By designing three cascaded ATOM (ARU-connected Timer Output Module, timer output module connected to ARU) trigger channels, ATOM2_2 (i.e., sampling period synchronization module) is used as the main channel for synchronous periodic update of the three cascaded ATOM channels, ATOM2_3 (i.e., the first sampling module) is used for rotary transformer excitation feedback trigger sampling, and ATOM2_4 (the second sampling module) is used for Sin and Cos feedback trigger sampling.
[0089] Combination Figure 3 As shown, another embodiment of the present invention provides a rotary transformer zero point alignment device, comprising:
[0090] A timing module, used to determine a first duration required for an excitation signal for a rotary transformer to be constructed through a functional layer, a second duration required for the functional layer to be initialized, a third duration required for the monitoring layer to be initialized, and a fourth duration required for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and an output signal of the rotary transformer;
[0091] A calculation module, used to determine a delay correction duration according to the first duration, the second duration, the third duration and the fourth duration;
[0092] A delay module is used to perform delay compensation on the sampled excitation signal or the sampling trigger signal using a delay correction duration based on the excitation signal for inputting into the rotary transformer obtained by sampling the monitoring layer and the sampling trigger signal for triggering the monitoring layer to sample the output signal, and determine a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for delay compensation;
[0093] The verification module is used to determine whether the delay correction duration meets the motor angle resolution accuracy requirement if the zero point alignment error is less than or equal to a first preset value.
[0094] The rotary transformer zero point alignment device of this embodiment is used to implement the above-mentioned rotary transformer zero point alignment method. Its advantages over the prior art are the same as the advantages of the above-mentioned rotary transformer zero point alignment method over the prior art, and will not be repeated here.
[0095] Combination Figure 4 As shown, another embodiment of the present invention provides an electronic device, including a memory 401 and a processor 402;
[0096] Memory 401, used for storing computer programs;
[0097] The processor 402 is used to implement the above resolver zero point alignment method when executing the computer program.
[0098] In other words, an electronic device includes a memory 401 and a processor 402 coupled to the memory 401; the memory 401 is configured to store a computer program; and the processor 402 is configured to perform the following operations when executing the computer program:
[0099] Determine a first duration for an excitation signal for a rotary transformer to be constructed through a functional layer, determine a second duration for the functional layer to be initialized, determine a third duration for the monitoring layer to be initialized, and determine a fourth duration for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and an output signal of the rotary transformer;
[0100] Determine the delay correction duration according to the first duration, the second duration, the third duration and the fourth duration;
[0101] Based on the excitation signal for inputting into the rotary transformer obtained by sampling the monitoring layer, and the sampling trigger signal for triggering the monitoring layer to sample the output signal, delay compensation is performed on the sampled excitation signal or the sampling trigger signal using the delay correction duration, and a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which delay compensation is performed is determined;
[0102] If the zero point alignment error is less than or equal to the first preset value, it is determined that the delay correction duration meets the motor angle resolution accuracy requirement.
[0103] The electronic device of this embodiment can be used to implement the above-mentioned rotary transformer zero point alignment method. Its advantages over the prior art are the same as the advantages of the above-mentioned rotary transformer zero point alignment method over the prior art, and will not be repeated here.
[0104] Another embodiment of the present invention provides a computer-readable storage medium, which stores a computer program. When the computer program is read and executed by a processor, the above-mentioned resolver zero point alignment method is implemented.
[0105] In other words, a non-volatile computer-readable storage medium stores a computer program, which, when executed by a processor, causes the processor to perform the following operations:
[0106] Determine a first duration for an excitation signal for a rotary transformer to be constructed through a functional layer, determine a second duration for the functional layer to be initialized, determine a third duration for the monitoring layer to be initialized, and determine a fourth duration for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and an output signal of the rotary transformer;
[0107] Determine the delay correction duration according to the first duration, the second duration, the third duration and the fourth duration;
[0108] Based on the excitation signal for inputting into the rotary transformer obtained by sampling the monitoring layer, and the sampling trigger signal for triggering the monitoring layer to sample the output signal, delay compensation is performed on the sampled excitation signal or the sampling trigger signal using the delay correction duration, and a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which delay compensation is performed is determined;
[0109] If the zero point alignment error is less than or equal to the first preset value, it is determined that the delay correction duration meets the motor angle resolution accuracy requirement.
[0110] The technical solution of the embodiment of the present invention, in essence or in other words, the part that contributes to the prior art, or the whole or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for making a computer device (which can be a personal computer, server, or network device, etc.) or a processor perform all or part of the steps of the method of the embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a ROM, a RAM, a magnetic disk, or an optical disk.
[0111] The computer-readable storage medium of this embodiment can be used to implement the above-mentioned rotary transformer zero point alignment method. Its advantages over the prior art are the same as the advantages of the above-mentioned rotary transformer zero point alignment method over the prior art, and will not be repeated here.
[0112] Although the present invention is disclosed as above, the protection scope of the present invention is not limited thereto. Those skilled in the art may make various changes and modifications without departing from the spirit and scope of the present invention, and these changes and modifications will fall within the protection scope of the present invention.
Claims
1. A method for zero point alignment of a rotary transformer, characterized in that: include: Determine a first duration required for an excitation signal for a rotary transformer to be constructed through a functional layer, a second duration required for the functional layer to be initialized, a third duration required for a monitoring layer to be initialized, and a fourth duration required for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and the output signal of the rotary transformer; Determine a delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration; Based on the excitation signal obtained by sampling the monitoring layer and used to input the rotary transformer, and the sampling trigger signal used to trigger the monitoring layer to sample the output signal, the delay correction duration is used to perform delay compensation on the sampled excitation signal or the sampling trigger signal, and a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed is determined; If the zero point alignment error is less than or equal to a first preset value, it is determined that the delay correction duration meets the motor angle resolution accuracy requirement.
2. The rotary transformer zero point alignment method according to claim 1, characterized in that: The step of determining a first time length required for the excitation signal for the rotary transformer to be constructed through the functional layer includes: It is determined that the time required from receiving the excitation wave enabling signal from the functional layer to sampling by the monitoring layer to obtain the excitation signal for inputting into the rotary transformer is the first time length.
3. The rotary transformer zero point alignment method according to claim 1, characterized in that: The determining the second duration required for the functional layer to be initialized comprises: Determine the time length required for the functional layer to be initialized according to the excitation wave enabling signal as the second time length, wherein the initialization includes configuring characteristic parameters of the excitation signal.
4. The rotary transformer zero point alignment method according to claim 1, characterized in that: Determining the third time required for the monitoring layer to be initialized includes: The duration required for initialization of the monitoring layer is determined to be the third duration, wherein the initialization includes configuring sampling characteristic parameters for the excitation signal and the output signal.
5. The rotary transformer zero point alignment method according to claim 1, characterized in that: The determining of the fourth duration required for the monitoring layer interrupt response comprises: It is determined that the time required from the monitoring layer receiving the interrupt enable signal to the monitoring layer entering the interrupt is the fourth time period.
6. The rotary transformer zero point alignment method according to any one of claims 1 to 5, characterized in that: Determining the delay correction duration according to the first duration, the second duration, the third duration, and the fourth duration includes: The difference between the first duration and the cumulative response duration is determined as the delay correction duration, wherein the cumulative response duration is the sum of the second duration, the third duration and the fourth duration.
7. The method for zero point alignment of a rotary transformer according to any one of claims 1 to 5, characterized in that: The excitation signal for inputting into the rotary transformer obtained by sampling the monitoring layer and the sampling trigger signal for triggering the monitoring layer to sample the output signal are used to perform delay compensation on the sampled excitation signal or the sampling trigger signal using the delay correction duration, and determining a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed, including: The delay correction time length is used to perform delay compensation on the time axis for the excitation signal obtained by sampling, and a first zero point on the time axis corresponding to the waveform of the excitation signal after delay compensation is determined, and a second zero point on the time axis corresponding to the waveform of the sampling trigger signal is determined; and an absolute value of the minimum time difference between the first zero point and the second zero point is determined as the zero point alignment error; Or, use the delay correction time length to perform delay compensation on the sampling trigger signal on the time axis, determine the second zero point of the waveform corresponding to the sampling trigger signal after delay compensation on the time axis, and determine the first zero point of the waveform corresponding to the sampled excitation signal on the time axis; determine the absolute value of the minimum time difference between the first zero point and the second zero point as the zero point alignment error.
8. The method for zero point alignment of a rotary transformer according to any one of claims 1 to 5, characterized in that: The monitoring layer includes a sampling period synchronization module, a first sampling module and a second sampling module which are cascaded to each other; the first sampling module is used for sampling the excitation signal, the second sampling module is used for sampling the output signal, and the sampling period synchronization module is used to synchronize the sampling periods of the first sampling module and the second sampling module.
9. A rotary transformer zero point alignment device, characterized in that: include: A timing module, used to determine a first duration required for an excitation signal for a rotary transformer to be constructed through a functional layer, a second duration required for the functional layer to be initialized, a third duration required for a monitoring layer to be initialized, and a fourth duration required for an interrupt response of the monitoring layer, wherein the monitoring layer is used to sample the excitation signal and the output signal of the rotary transformer; A calculation module, used to determine a delay correction duration according to the first duration, the second duration, the third duration and the fourth duration; A delay module, for performing delay compensation on the sampled excitation signal or the sampling trigger signal using the delay correction duration based on the excitation signal for inputting the rotary transformer obtained by sampling the monitoring layer and the sampling trigger signal for triggering the monitoring layer to sample the output signal, and determining a zero point alignment error between one of the sampled excitation signal and the sampling trigger signal and the other for which the delay compensation is performed; The verification module is used to determine whether the delay correction duration meets the motor angle resolution accuracy requirement if the zero point alignment error is less than or equal to a first preset value.
10. An electronic device, characterized in that: including memory and processor; The memory is used to store computer programs; The processor is configured to implement the resolver zero point alignment method according to any one of claims 1 to 8 when executing the computer program.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is read and executed by a processor, the resolver zero point alignment method according to any one of claims 1 to 8 is implemented.
Citation Information
Cited By
Sampling time determination method and device, medium, product and transformer demodulation system
CN121164746A