Motor deflection angle calibration method, system and equipment and computer storage medium

The controller sends the virtual electrical angle to the synchronous motor, obtains the collected electrical angle and determines the motor deflection angle value, which solves the problem that traditional motor deflection angle calibration can only be mechanically calibrated at a specific station, and realizes high-precision software calibration.

CN120281218APending Publication Date: 2025-07-08HANGZHOU KINGWAY TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311758471.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-12-19
Publication Date
2025-07-08

AI Technical Summary

Technical Problem

The traditional motor deflection angle calibration method can only be mechanically calibrated at specific workstations and cannot meet the high-precision requirements of modern steering control.

Method used

The controller uses the controller to adjust the step size based on the preset electrical angle to send the virtual electrical angle to the synchronous motor, obtain the collected electrical angle, determine the positive and reverse motor deflection angle values, and determine the target motor deflection angle based on these values, so as to realize software calibration.

Benefits of technology

Software calibration of motor deflection angle is realized, avoiding the need for mechanical calibration of specific stations, reducing calibration costs, and improving calibration accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120281218A_ABST
    Figure CN120281218A_ABST
Patent Text Reader

Abstract

The invention relates to the field of motors, and discloses a motor deflection angle calibration method, system and device and a computer storage medium, the motor deflection angle calibration method is used for a controller, and the method comprises the following steps: sending a virtual electrical angle to a synchronous motor based on a preset electrical angle adjustment step length, acquiring an acquisition electrical angle acquired by the synchronous motor for each virtual electrical angle; determining a forward and reverse motor deflection angle value according to the virtual electrical angle and an acquisition electrical angle acquired under the virtual electrical angle; and determining a target motor deflection angle according to the positive and negative motor deflection angle values. According to the invention, software calibration of the motor deflection angle is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of motors, and particularly to a method, system, device, and computer storage medium for calibrating the deflection angle of a motor. Background Art

[0002] With the rapid development of SBW (Steering By Wire System), users' requirements for steering control are getting higher and higher. As one of the effective ways to improve the steering control accuracy, the calibration of the motor deflection angle also puts forward higher requirements for the calibration of the motor deflection angle.

[0003] The traditional method for calibrating the motor deflection angle is that during the production of the motor, the manufacturer performs mechanical calibration through a specific workstation and then ships it out. This method for calibrating the motor deflection angle has great defects and has the problem that it can only be mechanically calibrated by the manufacturer through a specific workstation. Therefore, there is an urgent need for a new method for calibrating the motor deflection angle to achieve software calibration of the motor deflection angle. Summary of the Invention

[0004] The main purpose of this application is to provide a method, system, device, and storage medium for calibrating the deflection angle of a motor, aiming at the technical problem of how to achieve software calibration of the motor deflection angle.

[0005] To achieve the above object, this application provides a method for calibrating the deflection angle of a motor. The method for calibrating the deflection angle of a motor is used for a controller, and the steps of the method for calibrating the deflection angle of a motor include:

[0006] Sending a virtual electrical angle to a synchronous motor based on a preset electrical angle adjustment step size, and obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle;

[0007] Determining the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle;

[0008] Determining the target motor deflection angle according to the positive and negative motor deflection angle values.

[0009] Optionally, before the step of sending a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, it includes:

[0010] Outputting a preset given voltage to the synchronous motor, and after executing the step of outputting a preset given voltage to the synchronous motor, executing the step of sending a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size.

[0011] Optionally, before the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle, it includes:

[0012] After a preset time for performing the sending operation of the virtual electrical angle, perform the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle.

[0013] Optionally, the step of determining the forward and reverse motor offset angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle includes:

[0014] For each virtual electrical angle, determine the angle difference between the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle;

[0015] Determine the total angle value of the angle differences corresponding to each of the virtual electrical angles, and determine the set value of the virtual electrical angle;

[0016] Determine the forward and reverse motor offset angle values according to the total angle value and the set value.

[0017] Optionally, the preset electrical angle adjustment step includes a forward rotation electrical angle adjustment step and a reverse rotation electrical angle adjustment step, and the step of determining the forward and reverse motor offset angle values according to the total angle value and the set value includes:

[0018] If the preset electrical angle adjustment step is the forward rotation electrical angle adjustment step, determine the ratio of the total angle value to the set value as the forward rotation motor offset angle value;

[0019] If the preset electrical angle adjustment step is the reverse rotation electrical angle adjustment step, determine the ratio of the total angle value to the set value as the reverse rotation motor offset angle value, and use the forward rotation motor offset angle value and the reverse rotation motor offset angle value as the forward and reverse motor offset angle values.

[0020] Optionally, the step of determining the target motor offset angle according to the forward and reverse motor offset angle values includes:

[0021] Determine the forward rotation motor offset angle value and the reverse rotation motor offset angle value in the forward and reverse motor offset angle values, and use the average value between the forward rotation motor offset angle value and the reverse rotation motor offset angle value as the target motor offset angle.

[0022] Optionally, before the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step:

[0023] Determine the number of magnetic poles of the synchronous motor, determine the theoretical adjustment step based on the number of magnetic poles, and use the theoretical adjustment step as the preset electrical angle adjustment step.

[0024] In addition, to achieve the above object, the present invention further provides a method for calibrating the deflection angle of a motor. The method for calibrating the deflection angle of the motor is used for a synchronous motor that is powered without load and equipped with a sensor. The steps of the method for calibrating the deflection angle of the motor include:

[0025] Obtain the virtual electrical angle sent by the controller;

[0026] Determine the collected electrical angle according to the virtual electrical angle, and send the collected electrical angle to the controller.

[0027] Optionally, before the step of obtaining the virtual electrical angle sent by the controller, it includes:

[0028] Supply power to the stator coil based on a preset given voltage, and perform the step of obtaining the virtual electrical angle sent by the controller after the power supply to the stator coil.

[0029] Optionally, the step of determining the collected electrical angle according to the virtual electrical angle includes:

[0030] After a preset time of performing the control operation of the virtual electrical angle, read the real-time electrical angle based on the sensor as the collected electrical angle.

[0031] In addition, to achieve the above object, the present invention further provides a system for calibrating the deflection angle of a motor. The system for calibrating the deflection angle of the motor includes a controller and a synchronous motor that is powered without load and equipped with a sensor. The controller is communicatively connected to the synchronous motor,

[0032] The controller is configured to send the virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step, and obtain the collected electrical angle collected by the synchronous motor for each virtual electrical angle; determine the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected under the virtual electrical angle; determine the target motor deflection angle according to the positive and negative motor deflection angle values;

[0033] The synchronous motor is configured to obtain the virtual electrical angle sent by the controller; determine the collected electrical angle according to the virtual electrical angle, and send the collected electrical angle to the controller.

[0034] This application also provides a device for calibrating the deflection angle of a motor. The device for calibrating the deflection angle of the motor includes: a memory, a processor, and a program of the method for calibrating the deflection angle of the motor stored on the memory and executable on the processor. When the program of the method for calibrating the deflection angle of the motor is executed by the processor, the steps of the method for calibrating the deflection angle of the motor as described above can be implemented.

[0035] The present application also provides a computer storage medium. A program for implementing the calibration method of the motor deflection angle is stored on the computer storage medium. The program for implementing the calibration method of the motor deflection angle is executed by a processor to implement the steps of the calibration method of the motor deflection angle as described above.

[0036] The technical solution of the present application sends a virtual electrical angle to a synchronous motor by a controller based on a preset electrical angle adjustment step, and obtains the collected electrical angle collected by the synchronous motor for each virtual electrical angle; determines the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; determines the target motor deflection angle according to the positive and negative motor deflection angle values, and obtains the virtual electrical angle sent by the controller through the synchronous motor; determines the collected electrical angle according to the virtual electrical angle, and sends the collected electrical angle to the controller. By controlling the synchronous motor with the virtual electrical angle to determine the collected electrical angle, and then determining the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle, and then the target motor deflection angle can be determined according to the positive and negative motor deflection angle values, and the phenomenon that mechanical calibration can only be performed at a specific station by the manufacturer can be avoided. The calibration method of the motor deflection angle of the present application can control the synchronous motor with the virtual electrical angle to determine the collected electrical angle, and finally realize the effect of determining the positive and negative motor deflection angle values to determine the target motor deflection angle, and realize the software calibration of the motor deflection angle. BRIEF DESCRIPTION OF THE DRAWINGS

[0037] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present application, and are used together with the specification to explain the principles of the present application.

[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the accompanying drawings required for use in the description of the embodiments or the prior art. Obviously, for those of ordinary skill in the art, other drawings can also be obtained according to these drawings without creative efforts.

[0039] Figure 1 It is a schematic structural diagram of a calibration device for the motor deflection angle in the hardware operating environment related to the embodiment solution of the present invention;

[0040] Figure 2 It is a schematic flowchart of the first embodiment of the calibration method of the motor deflection angle of the present application;

[0041] Figure 3 It is a schematic diagram of the calibration system module of the motor deflection angle of the present application;

[0042] Figure 4 It is a schematic diagram of a system framework of a steer-by-wire system;

[0043] Figure 5A schematic diagram of a scenario of the positional relationship between a motor and a position sensor;

[0044] Figure 6 A schematic diagram of a scenario of a position sensor, a motor rotor, and a motor stator;

[0045] Figure 7 A schematic flowchart of a method for calibrating the deflection angle of the motor of the present application.

[0046] The realization of the purpose, functional features, and advantages of the present invention will be further described with reference to the embodiments and the accompanying drawings. Detailed implementation manners

[0047] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0048] Refer to Figure 1 , Figure 1 A schematic structural diagram of a device for calibrating the deflection angle of a motor in a hardware operating environment related to the embodiment solution of the present invention.

[0049] As Figure 1 shown, the device for calibrating the deflection angle of the motor may include: a processor 0003, such as a central processing unit (CPU), a communication bus 0001, an acquisition interface 0002, a processing interface 0004, and a memory 0005. Among them, the communication bus 0001 is used to realize the connection and communication between these components. The acquisition interface 0002 may include an information acquisition system and an acquisition unit such as a computer. Optionally, the acquisition interface 0002 may further include a standard wired interface and a wireless interface. The processing interface 0004 may optionally include a standard wired interface and a wireless interface. The memory 0005 may be a high-speed random access memory (RAM) or a stable non-volatile memory (NVM), such as a disk memory. Optionally, the memory 0005 may also be a storage system independent of the aforementioned processor 0003.

[0050] Those skilled in the art can understand that Figure 1 the structure shown in

[0051] does not constitute a limitation on the device for calibrating the deflection angle of the motor, and may include more or fewer components than shown, or combine certain components, or have different component arrangements. Figure 1 shown, in the memory 0005 as a storage medium, there may be included an operating system, an acquisition interface module, an execution interface module, and a program for calibrating the deflection angle of the motor.

[0052] In Figure 1In the calibration device of the motor deflection angle shown, the communication bus 0001 is mainly used to realize the connection and communication between components; the acquisition interface 0002 is mainly used to connect to the background server and conduct data communication with the background server; the processing interface 0004 is mainly used to connect to the deployment end (user end) and conduct data communication with the deployment end; the processor 0003 and the memory 0005 in the calibration device of the motor deflection angle of the present invention can be arranged in the calibration device of the motor deflection angle. The calibration device of the motor deflection angle calls the calibration program of the motor deflection angle stored in the memory 0005 through the processor 0003 and executes the calibration method of the motor deflection angle provided by the embodiments of the present invention.

[0053] For the sake of clear and concise description of the following embodiments, a brief introduction to the implementation of a calibration method for the motor deflection angle is given first:

[0054] In the existing technical solution of a motor equipped with a position sensor, the EPS (Electric Power System, Electric Power Steering System) motor uses a resolver component, and the motor position is obtained by hardware decoding of the angle and speed. Moreover, the factory line can automatically calibrate the angle between the motor stator and the motor position. Subsequently, in the motor control software, there is no need to calibrate the motor deflection angle twice. Refer to Figure 6 , Figure 6 is a schematic diagram of a scene of the position sensor, the motor rotor, and the motor stator. The d_axis axis is the motor rotor axis, ia, ib, ic are the motor three-phase stator axes, TMR0° is the zero position of the TMR. When the motor rotor d axis coincides with the motor A phase axis ( Figure 6The deviation between the angle parsed by the TMR (Tunnel Magnetoresistance Effect) sensor and the rotor zero position (the d_axis and ia axis in it) is called the motor deflection angle. Therefore, the finally determined motor position information is the angle measured by the TMR sensor minus the motor deflection angle, which is the actual angle of the motor rotor rotation. The traditional calibration method of the motor deflection angle is to directly calibrate the deflection angle through a resolver and an integrated hardware decoding chip at the motor end, and then supply it to the client after factory inspection. The client no longer needs to calibrate the deflection angle through software. In recent years, due to cost reduction and the update of the motor manufacturer's production line, the motor manufacturer no longer uses the traditional mode to calibrate the deflection angle of the motor position on the motor production line. The mainstream solution of the current motor manufacturer is to select a TMR sensor and integrate a novel TMR decoding chip. The novel TMR decoding chip outputs four analog signals sin-, sin+, cos-, cos+. Then, the software at the controller end collects the four analog signals and performs soft decoding inside the software. Since the motor manufacturer does not calibrate the deflection angle of the motor with a TMR position sensor on the production line, the controller end needs to calibrate the motor position deflection angle through a software solution inside the software. Therefore, based on the fact that the existing motor production line manufacturers no longer perform mechanical calibration, the calibration method of the motor deflection angle of this application is proposed.

[0055] This application provides a calibration method for the motor deflection angle. The controller sends a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step, and obtains the collected electrical angle collected by the synchronous motor for each virtual electrical angle; determines the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; determines the target motor deflection angle according to the positive and negative motor deflection angle values, and the synchronous motor obtains the virtual electrical angle sent by the controller; determines the collected electrical angle according to the virtual electrical angle and sends the collected electrical angle to the controller. By controlling the synchronous motor with the virtual electrical angle to determine the collected electrical angle, and then determining the positive and negative motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle, and then it is possible to determine the target motor deflection angle according to the positive and negative motor deflection angle values, and then it is possible to avoid the phenomenon that mechanical calibration can only be performed at the manufacturer through specific workstations. The calibration method of the motor deflection angle of this application can control the synchronous motor with the virtual electrical angle to determine the collected electrical angle, and finally achieve the effect of determining the positive and negative motor deflection angle values to determine the target motor deflection angle, realizing the software calibration of the motor deflection angle.

[0056] Based on the above hardware structure, an embodiment of the calibration method for the motor deflection angle of the present invention is proposed.

[0057] An embodiment of the present invention provides a calibration method for the motor deflection angle, referring to Figure 2, Figure 2 It is a schematic flow chart of the first embodiment of a method for calibrating the deflection angle of a motor according to the present invention.

[0058] In this embodiment, the method for calibrating the deflection angle of the motor is used for a controller, and the method for calibrating the deflection angle of the motor includes:

[0059] Step S10: Send a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, and obtain the collected electrical angle collected by the synchronous motor for each virtual electrical angle;

[0060] Exemplarily, the present application belongs to the technical field of SBW (Steering By Wire System, chassis by-wire steering system). Refer to Figure 4 , Figure 4 It is a schematic diagram of a system framework of a by-wire steering system. The by-wire steering system cancels the mechanical connection between the steering wheel and the steering wheel, and completely realizes the information transmission and control of steering by electrical signals. The working principle is as follows: When the driver has a steering demand, the steering wheel will be rotated, and the direct-drive road feel simulation motor under the steering wheel will provide the steering resistance according to the vehicle condition parameters (communicate through the wire harness with the ECU (Electric Control Unit, electronic control unit)) to simulate the road surface steering feeling during mechanical steering. At the same time, the ECU control system will collect information from various sensors of the SBW (collect vehicle speed / lateral acceleration, etc. through the CAN bus, and transmit the total rack force / steering wheel angle at the same time), analyze and process it, and then transmit it to the logic calculation unit inside the ECU. After calculation by the internal control algorithm, the expected torque is output through the wire harness to the power steering motor, and the power steering motor drives the tie rod and the wheel to complete the by-wire steering operation (controlled by an angular displacement sensor).

[0061] From the control of the above chassis by-wire steering system, it can be seen that in the chassis by-wire steering system, the power steering motor is the actuator of the SBW, which directly affects the steering performance of the SBW and the safety of the driver. And in the power steering motor control scheme, a motor position sensor is required to detect the motor position information. Refer to Figure 5 , Figure 5It is a schematic diagram of a scenario of the positional relationship between a motor and a position sensor. The commonly used type of motor position detection chip is TMR. There is a small magnetic ring a few millimeters above the decoding chip. The small magnetic ring is rigidly connected to the motor rotor. When the motor rotor rotates, it drives the magnetic ring to rotate. At this time, the TMR chip will output signals of sin-, sin+, cos-, and cos+ with motor position information. The main chip MCU obtains the digital signals of sin-, sin+, cos-, and cos+ through AD sampling. The internal software of the MCU can obtain the motor position information through mathematical calculations. Since the installation position of the TMR position sensor and the relative position of the three-phase lines of the motor stator are random and the motor manufacturer no longer performs mechanical calibration, it is necessary to use software to calibrate the angle between the zero position of the TMR position sensor and the A-phase axis of the motor electronic three-phase line. Therefore, the software calibration method for the motor deflection angle of this application is proposed.

[0062] In this embodiment, the motor deflection angle is calibrated by means of software calibration, which can greatly reduce the calibration cost that needs to be mechanically calibrated. The entire software calibration process is to send a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, and for each virtual electrical angle, obtain the collected electrical angle collected by the synchronous motor. Among them, the preset electrical angle adjustment step size is a rotation step size defined by the user. For example, if the step size is 10°, the virtual electrical angle sent to the synchronous motor changes by 10° each time, such as 0°, 10°, 20°..., or 0°, -10°, -20°..., and then the synchronous motor is controlled to rotate via the virtual electrical angle sent to the synchronous motor. At the same time, the collected electrical angle corresponding to each virtual electrical angle is obtained through the synchronous motor, and then software calibration can be performed based on the collected electrical angle and the actually controlled virtual electrical angle, and thus it is not necessary to use the method of mechanical calibration, which can greatly reduce the entire calibration cost.

[0063] It should be noted that before the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size, it includes:

[0064] Step S01, output a preset given voltage to the synchronous motor, and after executing the step of outputting the preset given voltage to the synchronous motor, execute the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size.

[0065] Exemplarily, the entire calibration method needs to supply power to the stator of the synchronous motor, and then the stator generates a magnetic field to control the rotation of the synchronous motor to implement the subsequent calibration method. That is, output a preset given voltage to the synchronous motor. The preset given voltage refers to a voltage value defined by the user and can be selected based on the actual situation. At the same time, before the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle, it includes:

[0066] Step S02, after a preset time for performing the sending operation of the virtual electrical angle, perform the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle.

[0067] Exemplarily, when the synchronous motor executes the control of the virtual electrical angle, Figure 6 the d_axis of the motor rotor shaft and the ia of the motor stator shaft in [reference] will not be aligned immediately. Therefore, it is necessary to wait for a certain time before the collected electrical angle is the collected electrical angle in the state where the d_axis of the actual motor rotor shaft and the ia of the motor stator shaft are aligned, that is, the angle to be measured. Therefore, after the preset time for performing the sending operation of the virtual electrical angle, the collection step needs to be executed, which can ensure the accuracy of the collected electrical angle. The preset time can be set according to the actual situation and user requirements, and will not be limited here.

[0068] Step S20, determine the forward and reverse motor offset angles according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle;

[0069] In this embodiment, after obtaining the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle, the forward and reverse motor offset angles will be determined based on each virtual electrical angle and the collected electrical angle collected at the virtual electrical angle. Among them, the forward and reverse motor offset angles are the motor offset angles obtained by controlling the synchronous motor to rotate forward through the virtual electrical angle and the motor offset angles obtained by controlling the synchronous motor to rotate backward through the virtual electrical angle. That is, the entire solution is to determine the forward and reverse motor offset angles based on multiple virtual electrical angles and the corresponding collected electrical angles. The determination method is to determine the difference between the virtual electrical angle and the corresponding collected electrical angle, and then average the differences to obtain the forward and reverse motor offset angles of forward and reverse rotation. Thus, it is possible to calibrate the motor offset angle value without using hardware, realizing software calibration of the motor offset angle value.

[0070] Step S30, determine the target motor offset angle according to the forward and reverse motor offset angles.

[0071] In this embodiment, by determining the forward and reverse motor offset angles, the entire calibration process takes into account the phenomenon of inaccurate calibration caused by different environments during forward and reverse rotation of the motor. Finally, the target motor offset angle can be determined based on the forward and reverse motor offset angles. The target motor offset angle refers to the motor offset angle of the synchronous motor that needs to be calibrated. Thus, software calibration of the motor offset angle value is realized. At the same time, through the solution of the forward and reverse offset angle values and the design of the electrical angle adjustment step size, the accuracy of software calibration is improved.

[0072] Exemplarily, the calibration method for the overall motor deflection angle is applicable to the combined form where the selected motor position sensor is a TMR and the analog chip software decodes the angle, and when the motor manufacturer does not perform the deflection angle calibration on the motor production line. Furthermore, without increasing the hardware cost, the motor deflection angle can be calibrated through a software algorithm, and the mass production scheme of the steer-by-wire assist steering controller for calibrating the motor deflection angle by software is realized at low cost.

[0073] Further, this embodiment also provides a flow schematic diagram of a calibration method for the motor deflection angle. Referring to Figure 7 , in this embodiment, taking a permanent magnet synchronous motor with 8 poles and 12 slots as an example, the deflection angle calibration is described. When the motor is in use, ensure that the motor is no-load and the ECU is powered on. At this time, start from zero to give the virtual electrical angle and the d-axis voltage Ud, as Figure 6As shown, the d-axis voltage Ud is the voltage value of the given rotor. It should be noted that at this time, it is also possible to start from a fixed angle and ensure that the step size of the angle adjustment is equal. Then, after each virtual electrical angle is given, the TMR angle is read, and the deviation between the given virtual electrical angle and the TMR angle is calculated. This deviation refers to the difference between the two. At this time, the upper limit of the angle designed for the 8-pole 12-slot permanent magnet synchronous motor is 1440 degrees (because there are 4 pole pairs, so the actual angle is 4 * 360 = 1440). By detecting the relationship between the given virtual electrical angle and 1440 degrees. When the given virtual electrical angle is less than or equal to 1440 degrees, the given virtual electrical angle is increased by 30° electrical angle in the positive direction. Conversely, when the given virtual electrical angle is greater than 1440 degrees, the average value of the deviation between the given virtual electrical angle and the TMR angle obtained previously is calculated. Since each increase is 30°, the adjustment step size is 30°, so the number of adjustments is 1440 / 30 = 48. Therefore, at this time, the average value Angle1 of the 48 positive deviations is calculated. It should be noted that the adjustment step size of 30° can be custom-set according to user needs. For example, for an 8-pole 12-slot permanent magnet synchronous motor, it can be adjusted only 4 times, each time by 360°. To avoid the differences between the forward and reverse rotations of the synchronous motor, the calculation of the deflection angle of the reverse rotation of the motor is proposed. At this time, the virtual electrical angle and the d-axis voltage Ud are given starting from zero again, and after each virtual electrical angle is given, the TMR angle is read, and the deviation between the given virtual electrical angle and the TMR angle is calculated. This deviation refers to the difference between the two. Then, the determination of the relationship between the given virtual electrical angle and 1440 degrees is performed. When the given virtual electrical angle is less than or equal to 1440 degrees, the given virtual electrical angle is increased by 30° electrical angle in the negative direction. Conversely, when the given virtual electrical angle is greater than 1440 degrees, the average value of the deviation between the given virtual electrical angle and the TMR angle obtained previously is calculated. Since each increase is 30°, the adjustment step size is 30°, so the number of adjustments is 1440 / 30 = 48. Therefore, at this time, the average value Angle2 of the 48 positive deviations is calculated. Then, the deflection angle Angle is the average value of Angle2 and Angle1. It should be noted that the calculation order of the forward and reverse rotations can be interchanged, which is not limited here. Thus, the software calibration of the motor deflection angle value is realized. At the same time, through the solution of the deflection angle values of the forward and reverse rotations and the design of the electrical angle adjustment step size, the accuracy of the software calibration is improved.

[0074] In this embodiment, the controller sends a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step, and acquires the acquired electrical angle collected by the synchronous motor for each virtual electrical angle; determines the positive and negative motor offset angles according to the virtual electrical angle and the acquired electrical angle acquired at the virtual electrical angle; determines the target motor offset angle according to the positive and negative motor offset angles, and acquires the virtual electrical angle sent by the controller through the synchronous motor; determines the acquired electrical angle according to the virtual electrical angle, and sends the acquired electrical angle to the controller. By controlling the synchronous motor with the virtual electrical angle to determine the acquired electrical angle, and then determining the positive and negative motor offset angles according to the virtual electrical angle and the acquired electrical angle acquired at the virtual electrical angle, the target motor offset angle can be determined according to the positive and negative motor offset angles, thereby avoiding the phenomenon that mechanical calibration can only be performed at specific workstations by manufacturers. The calibration method of the motor deflection angle in this application can control the synchronous motor with the virtual electrical angle to determine the acquired electrical angle, and finally achieve the effect of determining the positive and negative motor offset angles to determine the target motor offset angle, realizing the software calibration of the motor deflection angle.

[0075] Further, based on the first embodiment of the calibration method of the motor deflection angle of the present invention, a second embodiment of the calibration method of the motor deflection angle of the present invention is proposed. The step of determining the positive and negative motor offset angles according to the virtual electrical angle and the acquired electrical angle acquired at the virtual electrical angle includes:

[0076] Step S21, for each virtual electrical angle, determine the angle difference between the virtual electrical angle and the acquired electrical angle acquired at the virtual electrical angle;

[0077] In this embodiment, in the controller, for each virtual electrical angle, the angle difference between the virtual electrical angle and the acquired electrical angle acquired at the virtual electrical angle is determined, that is, the given virtual electrical angle and the acquired electrical angle collected by the sensor at the given virtual electrical angle are determined. At this time, the angle difference can be calculated for each given virtual electrical angle, or all virtual electrical angles and their corresponding acquired electrical angles can be summarized, and then calculated after the control of the entire virtual electrical angle is completed. It should be noted that the execution subject controller of this embodiment can be integrated with the sensor installed on the synchronous motor.

[0078] Exemplarily, in the entire calibration control process, the no-load motor is correctly connected to the ECU, and the ECU is powered by 12V (it can also be other power supplies); inside the ECU controller, through the upper computer calibration, the Ud value is given as 0.8V. The reason for 0.8V - a small voltage ensures the safety of the motor, which defines the magnitude of the stator magnetic field of the motor, and the virtual electrical angle is set as θ d , rotate in the positive direction, where Ud represents the d-axis voltage value inside the controller software.

[0079] Step S22: Determine the angular sum value of the angular differences corresponding to each of the virtual electrical angles, and determine the set value of the virtual electrical angle;

[0080] Step S23: Determine the forward and reverse motor offset angle values based on the angular sum value and the set value.

[0081] In this embodiment, after determining the angular difference corresponding to each virtual electrical angle, the angular sum value of each angular difference is determined, and then the set value of the virtual electrical angle is determined. Finally, the forward and reverse motor offset angle values can be determined based on the angular sum value and the set value. Here, the set value refers to the number of transformation times of the virtual electrical angle designed based on different synchronous motors. Taking an 8-pole 12-slot permanent magnet synchronous motor as an example, the actual angle to be calibrated is 260 * 4 (8 poles are 4 pairs of poles) = 1440. If the adjustment step of the virtual electrical angle is A, the set value is 1440 / A. Then, the forward and reverse motor offset angle values of the angular sum value B and the set value 1440 / A are determined. The forward and reverse motor offset angle value refers to the motor offset angle value determined based on controlling the motor to rotate forward and reverse under the virtual electrical angle.

[0082] Exemplarily, taking an 8-pole 12-slot permanent magnet synchronous motor as an example, by controlling the virtual electrical angle θd to control the synchronous motor to rotate in the positive direction, after the motor rotates 30 degrees (the designed adjustment step is 30°) of electrical angle and stops, the TMR reading value at this time is collected as the collected electrical angle (the first setting is 30 degrees, the second is 60 degrees, the third is 90 degrees...); repeat the above 48 times (the custom adjustment step is 30°). At this time, the motor rotates 30 * 48 = 1440 electrical angles, that is, 1440 / 4 = 360 degrees of mechanical angle. At this time, 48 electrical angles θtrm read from the TMR will be obtained, which are respectively recorded as θtrm1, θtrm2...θtrm48, and the given virtual electrical angle θd is synchronously recorded, which are respectively recorded as θd1, θd2...θd48, where θd1 = 30°, θd2 = 60°...θd48 = 1440°. Then calculate the deviation between the virtual electrical angle and the angle read by the TMR each time, which are respectively defined as θbia1, θbia2...θbia48. The formula for calculating the angular difference is as follows: θbia1 = θtrm1 - θd1, θbia2 = θtrm2 - θd2...

[0083] θbia48 = θtrm48 - θd48. At this time, the angular difference between the virtual electrical angle and the acquired electrical angle collected at the virtual electrical angle is calculated for each virtual electrical angle. Then, the average value of the calculated angular differences is obtained, that is, the average value of 48 angular differences is calculated, namely θbia_pos = (θbia1 + θbia2... + θbia48) / 48. This value is the motor deflection angle when the motor rotates in the positive direction. At the same time, the motor is rotated in the reverse direction, and the above steps are repeated to obtain the motor deflection angle θbia_neg when the motor rotates in the reverse direction. Then, these two values are used as the positive and negative motor deflection angle values, thus realizing the calculation of the positive and negative motor deflection angle values in the positive and negative directions. Considering from the positive and reverse rotation directions, the accuracy of the motor deflection angle calibration is ensured.

[0084] Further, the preset electrical angle adjustment step includes a forward rotation electrical angle adjustment step and a reverse rotation electrical angle adjustment step. The step of determining the positive and negative motor deflection angle values according to the angle sum value and the set value includes:

[0085] Step S231, if the preset electrical angle adjustment step is the forward rotation electrical angle adjustment step, then determine the ratio of the angle sum value to the set value as the forward rotation motor deflection angle value;

[0086] Step S232, if the preset electrical angle adjustment step is the reverse rotation electrical angle adjustment step, then determine the ratio of the angle sum value to the set value as the reverse rotation motor deflection angle value, and use the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the positive and negative motor deflection angle values.

[0087] In this embodiment, to avoid the problem of low calibration accuracy caused by single-direction calibration, the determination of the motor deflection angle of the synchronous motor rotating in the positive and negative directions is realized through the design of the preset electrical angle adjustment step. When the preset electrical angle adjustment step is the forward rotation electrical angle adjustment step, then determine the ratio of the angle sum value to the set value as the forward rotation motor deflection angle value. Conversely, when the preset electrical angle adjustment step is the reverse rotation electrical angle adjustment step, then determine the ratio of the angle sum value to the set value as the reverse rotation motor deflection angle value, and then use the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the positive and negative motor deflection angle values. Among them, the forward rotation electrical angle adjustment step is an adjustment method for forward rotation based on a specific step, such as 0 - 30 - 60, and the reverse rotation electrical angle adjustment step is an adjustment method for reverse rotation based on a specific step, such as 0 - -30 - -60. Thus, in the whole calibration process, the positive and negative factors are considered, and then the positive and negative calibration is carried out to ensure the accuracy of the motor deflection angle calibration.

[0088] Furthermore, based on the first and second embodiments of the calibration method for the motor deflection angle of the present invention, a third embodiment of the calibration method for the motor deflection angle of the present invention is proposed. The step of determining the target motor deflection angle according to the positive and negative motor deflection angle values includes:

[0089] Step a, determine the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value in the positive and negative motor deflection angle values, and take the average value between the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the target motor deflection angle.

[0090] In this embodiment, after determining the positive and negative motor deflection angle values, the average value between the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value will be determined, and then this average value is used as the target motor deflection angle. That is, by determining the forward rotation motor deflection angle value as θbia_pos and the reverse rotation motor deflection angle value θbia_neg, the target motor deflection angle is θbias = (θbia_pos + θbia_neg) / 2. Thus, the target motor deflection angle in the positive and negative cases can be determined, ensuring the accuracy of the determination of the entire motor deflection angle.

[0091] Further, before the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size, it includes:

[0092] Step b, determine the number of poles of the synchronous motor, and determine the theoretical adjustment step size based on the number of poles, and take the theoretical adjustment step size as the preset electrical angle adjustment step size.

[0093] In this embodiment, the electrical angle adjustment step size can be determined based on the number of poles of the synchronous motor. For example, for a permanent magnet synchronous motor with 8 poles and 12 slots, the number of poles is 8 poles, that is, 4 pairs of poles. At this time, the electrical angle is 360 * 4. The preset adjustment accuracy refers to the adjustment accuracy required defined by the user, such as 1°, 30°, etc. If it is 1°, the theoretical adjustment step size is 1°. If there is no preset adjustment accuracy, for a synchronous motor with 4 pairs of poles, the maximum step size is 360°, that is, the adjustment step size is 360°, and the minimum adjustment step size can be 1° or even lower, which is not limited here.

[0094] Furthermore, based on the first, second, and third embodiments of the calibration method for the motor deflection angle of the present invention, a fourth embodiment of the calibration method for the motor deflection angle of the present invention is proposed. The calibration method for the motor deflection angle is used for a synchronous motor with no-load power supply and equipped with a sensor. The steps of the calibration method for the motor deflection angle include:

[0095] Step S40, obtain the virtual electrical angle sent by the controller;

[0096] In this embodiment, the no-load motor is connected to the ECU and supplies 12V power to the ECU. Inside the ECU controller, through calibration by the host computer, the Ud value is set to 0.8V. The reason for 0.8V - a small voltage ensures the safety of the motor and defines the magnitude of the magnetic field of the motor stator. At the same time, the synchronous motor is equipped with a TMR sensor and integrated with an analog chip software for decoding the angle in a combined form. Thus, after obtaining the virtual electrical angle sent by the controller, corresponding control can be executed to achieve the calibration of the motor deflection angle.

[0097] Step S50: Determine the collected electrical angle according to the virtual electrical angle and send the collected electrical angle to the controller.

[0098] In this embodiment, after determining the virtual electrical angle, the motor performs a rotation operation to determine the collected electrical angle and sends the collected electrical angle to the controller for the controller to execute the operation of determining the forward and reverse motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; and determining the target motor deflection angle according to the forward and reverse motor deflection angle values.

[0099] Further, before the step of obtaining the virtual electrical angle sent by the controller, it includes:

[0100] Step S41: Supply power to the stator coil based on a preset given voltage and execute the step of obtaining the virtual electrical angle sent by the controller after the power supply to the stator coil.

[0101] In this embodiment, since the entire calibration process requires controlling and collecting operations on the motor, the motor ECU needs to be powered on and a preset given voltage is applied to the stator coil of the synchronous motor, and then subsequent calibration operations are performed. The preset given voltage refers to a user-defined voltage value that can be selected based on actual conditions.

[0102] Further, the step of determining the collected electrical angle according to the virtual electrical angle includes:

[0103] Step S51: After a preset time of executing the control operation of the virtual electrical angle, read the real-time electrical angle based on the sensor as the collected electrical angle.

[0104] In this embodiment, after a preset time of executing the control operation of the virtual electrical angle, the real-time electrical angle is read based on the sensor as the collected electrical angle. For example, after waiting for 500ms, the angle θtrm of the TMR sensor is read, which can be referred to Figure 6 , after 500ms, the d_axis axis of the motor rotor and the ia axis of the motor stator are aligned and coincident through software definition, thus ensuring the accuracy of the collected electrical angle at this time and further ensuring the accuracy of the entire calibration.

[0105] The present invention also provides a calibration system for the motor deflection angle. Referring to Figure 3 , the calibration system for the motor deflection angle includes a controller and a synchronous motor powered without load and equipped with sensors. The controller is communicatively connected to the synchronous motor. The calibration system for the motor deflection angle further includes:

[0106] Controller A01, configured to send a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, and obtain the collected electrical angle collected by the synchronous motor for each virtual electrical angle; determine the forward and reverse motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; determine the target motor deflection angle according to the forward and reverse motor deflection angle values;

[0107] Synchronous motor A02, configured to obtain the virtual electrical angle sent by the controller; determine the collected electrical angle according to the virtual electrical angle, and send the collected electrical angle to the controller.

[0108] Optionally, the controller A01 is further configured to:

[0109] For each virtual electrical angle, determine the angle difference between the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle;

[0110] Determine the total angle value of the angle differences corresponding to each of the virtual electrical angles, and determine the set value of the virtual electrical angle;

[0111] Determine the forward and reverse motor deflection angle values according to the total angle value and the set value.

[0112] Optionally, the controller A01 is further configured to:

[0113] If the preset electrical angle adjustment step size is the forward rotation electrical angle adjustment step size, then determine the ratio of the total angle value to the set value as the forward rotation motor deflection angle value;

[0114] If the preset electrical angle adjustment step size is the reverse rotation electrical angle adjustment step size, then determine the ratio of the total angle value to the set value as the reverse rotation motor deflection angle value, and use the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the forward and reverse motor deflection angle values.

[0115] Optionally, the controller A01 is further configured to:

[0116] Determine the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value among the forward and reverse motor deflection angle values, and use the average value between the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the target motor deflection angle.

[0117] Optionally, the controller A01 is further configured to:

[0118] Determine the number of magnetic poles of the synchronous motor, determine the theoretical adjustment step based on the number of magnetic poles, and use the theoretical adjustment step as the preset electrical angle adjustment step.

[0119] Optionally, the synchronous motor A02 is further configured to:

[0120] After a preset time of performing the control operation of the virtual electrical angle, read the real-time electrical angle based on the sensor as the collected electrical angle.

[0121] The methods executed by the above program modules can refer to the various embodiments of the calibration method of the motor deflection angle of the present invention, and will not be elaborated here.

[0122] The present invention also provides a calibration device for the motor deflection angle.

[0123] The device of the present invention includes: a memory, a processor, and a calibration program for the motor deflection angle stored on the memory and executable on the processor. When the calibration program for the motor deflection angle is executed by the processor, the steps of the calibration method of the motor deflection angle as described above are implemented.

[0124] The present invention also provides a storage medium.

[0125] The storage medium of the present invention stores a calibration program for the motor deflection angle. When the calibration program for the motor deflection angle is executed by the processor, the steps of the calibration method of the motor deflection angle as described above are implemented.

[0126] Among them, the method implemented when the calibration program for the motor deflection angle running on the processor is executed can refer to the various embodiments of the calibration method of the motor deflection angle of the present invention, and will not be elaborated here.

[0127] It should be noted that in this article, the terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or system. Without further limitation, an element defined by the statement "including a..." does not exclude the existence of additional identical elements in the process, method, article or system including that element.

[0128] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages and disadvantages of the embodiments.

[0129] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-described example methods can be implemented by means of software plus a necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium as described above (such as ROM / RAM, magnetic disk, optical disk), and includes several instructions for causing a terminal device (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0130] The above are only the preferred embodiments of the present invention, and do not limit the patent scope of the present invention accordingly. Any equivalent structure or equivalent process transformation made by using the content of the specification and drawings of the present invention, or directly or indirectly applied in other related technical fields, shall be equally included in the patent protection scope of the present invention.

Claims

1. A calibration method for the deflection angle of a motor, characterized in that, The calibration method of the motor deflection angle is used for a controller, and the steps of the calibration method of the motor deflection angle include: Sending a virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, and obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle; Determining the forward and reverse motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; Determining the target motor deflection angle according to the forward and reverse motor deflection angle values.

2. The calibration method of the motor deflection angle according to claim 1, characterized in that Before the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size, it includes: Outputting a preset given voltage to the synchronous motor, and after executing the step of outputting the preset given voltage to the synchronous motor, executing the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size.

3. The calibration method of the motor deflection angle according to claim 1, characterized in that Before the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle, it includes: After a preset time of executing the sending operation of the virtual electrical angle, executing the step of obtaining the collected electrical angle collected by the synchronous motor for each virtual electrical angle.

4. The calibration method for the deflection angle of the motor according to claim 1, characterized in that, The step of determining the forward and reverse motor deflection angle values according to the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle includes: For each virtual electrical angle, determining the angle difference between the virtual electrical angle and the collected electrical angle collected at the virtual electrical angle; Determining the total angle value of the angle differences corresponding to each virtual electrical angle, and determining the set value of the virtual electrical angle; Determining the forward and reverse motor deflection angle values according to the total angle value and the set value.

5. The calibration method of the motor deflection angle according to claim 4, characterized in that The preset electrical angle adjustment step size includes a forward rotation electrical angle adjustment step size and a reverse rotation electrical angle adjustment step size, and the step of determining the forward and reverse motor deflection angle values according to the total angle value and the set value includes: If the preset electrical angle adjustment step size is the forward rotation electrical angle adjustment step size, then determining the ratio of the total angle value to the set value as the forward rotation motor deflection angle value; If the preset electrical angle adjustment step size is the reverse rotation electrical angle adjustment step size, then determining the ratio of the total angle value to the set value as the reverse rotation motor deflection angle value, and taking the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the forward and reverse motor deflection angle values.

6. The calibration method for the motor deflection angle according to claim 5, characterized in that The step of determining the target motor deflection angle according to the forward and reverse motor deflection angle values includes: Determining the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value among the forward and reverse motor deflection angle values, and taking the average value between the forward rotation motor deflection angle value and the reverse rotation motor deflection angle value as the target motor deflection angle.

7. The calibration method of the motor deflection angle according to claim 1, characterized in that Before the step of sending the virtual electrical angle to the synchronous motor based on the preset electrical angle adjustment step size, it includes: Determining the number of magnetic poles of the synchronous motor, and determining the theoretical adjustment step size based on the number of magnetic poles, and taking the theoretical adjustment step size as the preset electrical angle adjustment step size.

8. A calibration method for the deflection angle of a motor, characterized in that, The calibration method of the motor deflection angle is used for a synchronous motor with no-load power supply and equipped with a sensor, and the steps of the calibration method of the motor deflection angle include: Obtaining the virtual electrical angle sent by the controller; Determining the collected electrical angle according to the virtual electrical angle, and sending the collected electrical angle to the controller.

9. The calibration method of the motor deflection angle according to claim 8, characterized in that Before the step of obtaining the virtual electrical angle sent by the acquisition controller, it includes: Power the stator coil based on a preset given voltage, and after powering the stator coil, execute the step of obtaining the virtual electrical angle sent by the acquisition controller.

10. The calibration method of the motor deflection angle according to claim 8, characterized in that, The step of determining the acquisition electrical angle according to the virtual electrical angle includes: After a preset time of performing the control operation of the virtual electrical angle, read the real-time electrical angle based on the sensor as the acquisition electrical angle.

11. A calibration system for the deflection angle of a motor, characterized in that, The calibration system of the motor deflection angle includes a controller and a synchronous motor with no-load power supply and loaded with a sensor. The controller is communicatively connected to the synchronous motor. The controller is configured to send the virtual electrical angle to the synchronous motor based on a preset electrical angle adjustment step size, and obtain the acquisition electrical angle collected by the synchronous motor for each virtual electrical angle; determine the positive and negative motor deflection angle values according to the virtual electrical angle and the acquisition electrical angle collected at the virtual electrical angle; determine the target motor deflection angle according to the positive and negative motor deflection angle values. The synchronous motor is configured to obtain the virtual electrical angle sent by the controller. Determine the acquisition electrical angle according to the virtual electrical angle, and send the acquisition electrical angle to the controller.

12. A calibration device for the deflection angle of a motor, characterized in that The calibration device of the motor deflection angle includes: a memory, a processor, and a calibration program of the motor deflection angle stored on the memory and executable on the processor. When the calibration program of the motor deflection angle is executed by the processor, it implements the steps of the calibration method of the motor deflection angle as described in any one of claims 1 to 10.

13. A computer storage medium, characterized in that, A program for implementing the calibration method of the motor deflection angle is stored on the computer storage medium. When the program for implementing the calibration method of the motor deflection angle is executed by the processor, it implements the steps of the calibration method of the motor deflection angle as described in any one of claims 1 to 10.