A phase encoding method and absolute value encoder for permanent magnet synchronous motor

By using multiple linear Hall sensors to calculate the characteristic value and the mid-time point value in a small-volume permanent magnet synchronous motor, high-precision phase encoding is achieved, which solves the problem of insufficient accuracy of absolute value encoder in small-volume motors and improves the control accuracy and performance of the motor.

CN119743068APending Publication Date: 2025-04-01WUHAN BAOJIU ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411950602.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-27
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

The existing high-precision absolute value encoder is large in size and cannot meet the space requirements of small-volume permanent magnet synchronous motors. The small-volume absolute value encoder lacks accuracy and cannot meet the needs of high-precision control of small-volume motors.

Method used

Using at least three linear Hall sensors, the phase encoding is calculated by calculating the eigenvalues ​​of the initial sensing data and the mid-time point value to achieve high-precision phase encoding. The method includes the initial angle measurement phase of the motor and the motor operation phase, using the median and time midpoint values ​​to obtain rough or accurate phase encoding.

Benefits of technology

The sensing accuracy and coding accuracy of the absolute value encoder are improved, and the permanent magnet synchronous motor can be controlled more accurately, reducing unnecessary energy consumption and losses, thereby improving the performance of the motor under the same volume.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119743068A_ABST
    Figure CN119743068A_ABST
Patent Text Reader

Abstract

The present invention relates to the field of absolute value encoders, and in particular to a phase encoding method and an absolute value encoder for a permanent magnet synchronous motor. The method comprises: in the initial angle measurement stage of the motor, obtaining the initial sensing data of at least three linear Hall sensors within a specified time period; wherein the electrical angles or phase angles of adjacent linear Hall sensors differ by 120 degrees; calculating the characteristic values ​​of the initial sensing data, and calculating the time midpoint value between adjacent characteristic values; in the motor operation stage, obtaining the current sensing data of at least three linear Hall sensors within a specified time period, obtaining a rough phase encoding based on the current sensing data and the median value, and / or obtaining an accurate phase encoding based on the current sensing data and the time midpoint value. The present invention improves the sensing accuracy and encoding accuracy of the absolute value encoder, performs more precise control on the permanent magnet synchronous motor, and thus reduces the energy consumption and loss of the permanent magnet synchronous motor.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of absolute value encoders, and in particular to a phase encoding method of a permanent magnet synchronous motor and an absolute value encoder. Background Art

[0002] Fast doors and industrial doors usually use permanent magnet synchronous motors (PMSM, hereinafter referred to as motors) to drive the door body up or down. In actual use, small-volume motors have some significant advantages, such as smooth operation and less noise. In the application scenarios of fast doors and industrial doors such as warehouses, factories, and garages, the installation space of motors for fast doors and industrial doors may be limited. Larger motor size means that more space is required during installation, which will have a negative impact on space utilization and overall layout, and even cause the installation of fast doors and industrial doors to fail. In places that require a quiet environment, such as residential areas, office areas, or inside factories, smaller motor size helps reduce noise pollution and provide a comfortable working environment. In places that require frequent switching, such as logistics channels and production lines, small-volume motors usually have lighter weight and smaller starting and stopping inertia, allowing the door body to start and stop faster, thereby increasing the opening and closing speed of the door and significantly improving work efficiency.

[0003] In actual use, for motors with the same technical solution, the smaller the size, the smaller the driving capacity. If the motor size is simply reduced, it will only reduce the driving capacity of the motor, which will make it difficult for small motors to adapt to fast doors and industrial doors. Especially in low-temperature environments such as cold storage, mechanical structures that are not completely sealed, such as motors and transmission systems, will condense due to low-temperature condensation, causing the static friction of the motor and transmission system to increase, requiring the motor to burst out greater torque performance. Therefore, it is necessary to rely on higher-precision control to reduce the energy consumption and loss during the operation of the motor and improve the driving capacity per unit energy consumption. In order to achieve higher-precision control, a high-precision absolute encoder is required to obtain the current operating position of the motor. However, the existing high-precision absolute encoders are usually large in size and cannot meet the space requirements of small-volume motors; and the accuracy of small-volume absolute encoders is usually low, which cannot meet the control accuracy requirements of small-volume motors.

[0004] In view of this, how to overcome the defects of the prior art and solve the problem that the existing absolute value encoding cannot meet the needs of high-precision control of small-volume motors is a problem to be solved in this technical field. Summary of the invention

[0005] In view of the above defects or improvement requirements of the prior art, the present invention solves the problem that the existing absolute value encoding cannot meet the needs of high-precision control of small-volume motors.

[0006] The embodiment of the present invention adopts the following technical solution:

[0007] In a first aspect, the present invention provides a phase encoding method for a permanent magnet synchronous motor, specifically: in the initial angle measurement stage of the motor, initial sensing data of at least three linear Hall sensors within a specified time period are obtained; wherein the electrical angles or phase angles of adjacent linear Hall sensors differ by 120 degrees; characteristic values ​​of the initial sensing data are calculated, and the time midpoint values ​​between adjacent characteristic values ​​are calculated; wherein the characteristic values ​​include: median values, lower intersection values, and upper intersection values; in the motor operation stage, current sensing data of at least three linear Hall sensors within a specified time period are obtained, and rough phase encoding is obtained based on the current sensing data and the median value, and / or, precise phase encoding is obtained based on the current sensing data and the time midpoint value.

[0008] Preferably, the calculation of the characteristic values ​​of the initial sensor data, when calculating the median, specifically includes: taking the average of the minimum and maximum values ​​of the sensor data of each channel as the median of the channel; and / or, taking the average of all the sensor data of each channel as the median of the channel.

[0009] Preferably, the calculation of the characteristic value of the initial sensor data, when calculating the lower intersection value and the upper intersection value, specifically includes: in the initial sensor data of every two channels, obtaining sensor data with the same value at the same time point; when the obtained sensor data is less than the median value, using the sensor data as the lower intersection value; when the obtained sensor data is greater than or equal to the median value, using the sensor data as the upper intersection value.

[0010] Preferably, the calculation of the time midpoint value between adjacent eigenvalues ​​specifically includes: in the rising edge of the sensor data, obtaining the time midpoint between the time point corresponding to the lower intersection value and the time point corresponding to the median, and taking the sensor data corresponding to the time midpoint as time midpoint value 1; in the rising edge of the sensor data, obtaining the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median, and taking the sensor data corresponding to the time midpoint as time midpoint value 2; in the falling edge of the sensor data, obtaining the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median, and taking the sensor data corresponding to the time midpoint as time midpoint value 3; in the falling edge of the sensor data, obtaining the time midpoint between the time point corresponding to the lower intersection value and the time point corresponding to the median, and taking the sensor data corresponding to the time midpoint as time midpoint value 4.

[0011] Preferably, the method of obtaining a rough phase encoding based on the current sensing data and the median value specifically includes, at each time point: obtaining the current sensing data at the current time point in at least three consecutive channels, comparing each current sensing data obtained with the median value, and obtaining a rough phase encoding based on the comparison result distribution of all channels; wherein the number of bits of the phase encoding is determined according to the number of comparison result distributions, and each comparison result corresponds to a rough phase encoding.

[0012] Preferably, the method of obtaining accurate phase encoding based on current sensor data and time midpoint value specifically includes: obtaining current sensor data at the current time point in at least three consecutive channels, comparing each current sensor data obtained with the median and each time midpoint value, and obtaining a rough phase encoding based on the comparison result distribution of all channels; wherein the number of bits of the phase encoding is determined according to the number of comparison result distributions, and each comparison result corresponds to an accurate phase encoding.

[0013] On the other hand, the present invention provides an absolute value encoder for a permanent magnet synchronous motor, specifically comprising: at least three linear Hall sensors and a microprocessor, specifically comprising: each linear Hall sensor is used to obtain the sensing data of a channel and output the sensing data to the microprocessor, and the electrical angle or phase angle of adjacent linear Hall sensors differs by 120 degrees; each analog-to-digital conversion pin of the microprocessor is respectively connected to each Hall sensor, and is used to obtain corresponding phase encoding according to the phase encoding method of the permanent magnet synchronous motor provided in the first aspect.

[0014] Preferably, when the motor includes 12 stator windings, the absolute encoder specifically includes: the sensor head of each linear Hall sensor is placed in the space between a group of adjacent stator windings on the motor and is located on the side close to the rotor, and the sensor heads of each linear Hall sensor are located in a continuous space.

[0015] Preferably, the microprocessor comprises at least three analog-to-digital conversion modules, each of which is used to convert the sensing data of a channel from a voltage analog signal into corresponding voltage data.

[0016] Preferably, the absolute value encoder further comprises a level conversion chip, which is connected to the communication pin of the microprocessor and to the driver of the motor, and is used for sending the phase code obtained by the microprocessor to the driver of the motor.

[0017] Compared with the prior art, the beneficial effects of the present invention are: based on the waveform characteristics of the sensing data, the sensing data of a specific relative position sensor is used to obtain the characteristic value and the time midpoint value in a static state, and then the sensing data of the sensor during operation is compared with the characteristic value and the time midpoint value to obtain a rough or precise phase encoding, thereby improving the sensing accuracy and encoding accuracy of the absolute encoder. By improving the accuracy of the absolute encoder, the permanent magnet synchronous motor can be more accurately controlled in current and flux, reducing unnecessary energy consumption and losses, so as to improve the performance of the permanent magnet synchronous motor at the same volume. BRIEF DESCRIPTION OF THE DRAWINGS

[0018] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.

[0019] Figure 1 A method flow chart of a phase encoding method for a permanent magnet synchronous motor provided by an embodiment of the present invention;

[0020] Figure 2 A waveform diagram of sensing data of a single linear Hall sensor;

[0021] Figure 3 A schematic diagram of a waveform of sensing data collected by a Hall sensor in the method provided by an embodiment of the present invention;

[0022] Figure 4 A schematic diagram of waveforms after waveform superposition of sensing data collected by the Hall sensor in the method provided in an embodiment of the present invention;

[0023] Figure 5 A schematic diagram of the relationship between the characteristic value and the time midpoint value and the sensor data waveform in the method provided by an embodiment of the present invention;

[0024] Figure 6 A schematic diagram of the relationship between rough phase encoding and sensing data waveform in the method provided in an embodiment of the present invention;

[0025] Figure 7 A schematic diagram of the relationship between precise phase encoding and sensing data waveform in the method provided in an embodiment of the present invention;

[0026] Figure 8 A schematic diagram of the structure of an absolute value encoder of a permanent magnet synchronous motor provided by an embodiment of the present invention;

[0027] Fig. 9 A schematic diagram of the structure of a microprocessor in an absolute value encoder provided in an embodiment of the present invention;

[0028] Fig.10 A schematic diagram of a configuration method of a linear Hall sensor in an absolute encoder provided in an embodiment of the present invention in a permanent magnet synchronous motor;

[0029] Fig.11 A schematic diagram of the structure of another absolute value encoder of a permanent magnet synchronous motor provided in an embodiment of the present invention. DETAILED DESCRIPTION

[0030] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. 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.

[0031] The present invention is an architecture of a specific functional system, so the specific embodiments mainly illustrate the functional logical relationship between the various structural modules, and do not limit the specific software and hardware implementation methods.

[0032] In addition, the technical features involved in the various embodiments of the present invention described below can be combined with each other as long as they do not conflict with each other. The present invention will be described in detail below with reference to the accompanying drawings and embodiments.

[0033] High-precision absolute encoders are of great significance in reducing the size of permanent magnet synchronous motors, mainly in the following aspects:

[0034] 1. Improve the starting torque performance of the motor in low temperature environment: In low temperature environment, due to the freezing of mechanical structures such as the motor and transmission system of the industrial fast door, the motor needs to overcome greater static friction than in normal temperature environment when starting, especially when starting quickly in cold storage. Through higher-precision absolute value encoding, the motor driver can use the precise rotor electrical angle to give a more accurate current vector output, thereby driving the motor to generate greater torque when starting to overcome the static friction in low temperature environment.

[0035] 2. Improve control accuracy: High-precision absolute encoders can accurately feedback the motor's rotor position in real time. Through accurate rotor position feedback, the motor control system can achieve higher-precision torque and speed control, thereby optimizing the motor's operating efficiency. Accurate control helps the motor achieve higher performance in a smaller volume, further reducing the size of the motor.

[0036] 3. Improve dynamic performance: High-precision absolute encoders can provide more detailed position information, allowing the motor to respond faster to load changes, especially in high-speed and high-dynamic applications. This high dynamic response helps the motor maintain good operating conditions in a compact space and avoid performance degradation caused by inaccurate control.

[0037] 4. Reduce motor size and weight: Since the high-precision absolute encoder can provide accurate rotor position feedback, the motor control system can more effectively adjust the motor output, thereby reducing the need for redundant design and excessive power output. This means that the same output power can be achieved in a smaller size and lighter weight, which directly promotes the reduction of motor size.

[0038] 5. Optimize the matching of motor and control system: High-precision absolute encoder can be used in combination with efficient control systems (such as vector control or direct torque control) to accurately control the torque and speed characteristics of the motor, so that the motor and control system can be more closely matched. This matching can achieve better performance, so that the motor does not need to be over-designed, thereby reducing the size of the motor.

[0039] In summary, high-precision absolute encoders can effectively improve the control accuracy, dynamic response and system stability of motors, so that permanent magnet synchronous motors can provide the same or even higher performance in a smaller size. This is of great significance to reducing the size and weight of motors, especially in application scenarios that require compact design (such as electric vehicles, robots, industrial automation, industrial doors and fast doors, etc.), and plays an indispensable role.

[0040] Embodiment 1:

[0041] In order to improve the sensing accuracy and encoding accuracy of the absolute encoder, this embodiment provides a phase encoding method for a permanent magnet synchronous motor. The accuracy of the absolute encoder is improved through an optimized algorithm, so that the motor driver can provide more precise current and flux control to the permanent magnet synchronous motor, reduce unnecessary energy consumption and loss, and thus improve the performance of the permanent magnet synchronous motor at the same volume.

[0042] like Figure 1 As shown, the phase encoding method of the permanent magnet synchronous motor provided by the embodiment of the present invention has the following specific steps:

[0043] Step 101: In the motor initial angle measurement phase, initial sensing data of at least three linear Hall sensors within a specified time period are obtained.

[0044] Before the motor starts running, it is necessary to obtain the initial sensor data of the motor, and use the initial sensor data as a reference point to control the rotation direction and position of the motor. The initial sensor data usually includes: the initial position of the rotor, the initial position of the stator, the angle between the initial position of the rotor and the initial position of the stator (i.e., the initial angle), etc.

[0045] A single linear Hall sensor can only realize single-point sensing, and the single-point sensing data at each moment may correspond to multiple points on the sensing data sinusoidal curve. Figure 2 As shown in the figure, in one cycle of the sine curve, the sensor data d1 corresponds to 2 values, and the sensor data d2 corresponds to 3 values. Therefore, single-point sensing cannot parse the initial angle of the motor start from the sensor data. At the same time, a single linear Hall sensor used in an absolute encoder cannot know the direction of motor rotation.

[0046] In an absolute encoder, two linear Hall sensors with an electrical angle of 90 degrees can be used to generate a sine curve with a phase difference of 90 degrees, which is used to determine the absolute value of the rotor's motion angle and the direction of motor motion. That is, two linear Hall sensors with an electrical angle of 90 degrees are used to collect the sensing data of two channels, and the sensing data of the two channels are used to demodulate the motor's starting angle and the absolute value of the angle during motion.

[0047] In a permanent magnet synchronous motor, the stator winding uses a three-phase winding, and the phase angle between adjacent stator windings is 120 degrees to achieve the maximum magnetic field force and obtain the best performance. In this scenario, if the electrical angle of adjacent linear Hall sensors needs to be 90 degrees, it is difficult to accurately calculate the mechanical angle of adjacent linear Hall sensors, making it impossible to accurately set the slots of two linear Hall sensors between adjacent windings of the motor stator.

[0048] Therefore, in the method provided in this embodiment, at least three linear Hall sensors are used, and when the mechanical angle between adjacent linear Hall sensors is 30 degrees, the electrical angle or phase angle thereof differs by 120 degrees. When the number of stator windings is 12, three linear Hall sensors can be placed in the continuous gap between adjacent stator windings, without the need to calculate the position of the linear Hall sensors or to perform additional slotting.

[0049] In a specific scenario, the sensing data waveforms of three channels collected by three linear Hall sensors with a mechanical angle of 30 degrees are as follows: Figure 3 As shown, it can be seen that the phase angle is exactly 120 degrees; superimposing the waveforms of the three channels using the same coordinate system, we get Figure 4 The waveform shown; Figure 3 and Figure 4In the figure, the vertical axis represents the sensor value and the horizontal axis represents the time axis. In the initial angle measurement phase after the motor is installed, each linear Hall sensor collects the sensor data of each channel for subsequent calculation of the characteristic value and the time midpoint value. This method is not only convenient for mechanical design and assembly, but also can provide the required reference value for subsequent phase encoding calculation.

[0050] Step 102: Calculate the characteristic values ​​of the initial sensing data, and calculate the time midpoint value between adjacent characteristic values.

[0051] In the present embodiment, since at least three linear Hall sensors are used, a single initial angle and phase difference are not used directly to calculate the phase encoding. Instead, multiple characteristic values ​​are used as reference values, and the values ​​of multiple linear Hall sensors are compared with the multiple characteristic values. The size relationship of the sensing data of multiple linear Hall sensors is obtained based on the comparison results, thereby obtaining the corresponding phase encoding.

[0052] In the specific implementation, the eigenvalues ​​include: median value, lower cross-point value and upper cross-point value. In the actual implementation, since the waveform of the sensor data is a sine wave, the lower cross-point value can be divided into the lower cross-point value of the rising edge and the lower cross-point value of the falling edge, and the upper cross-point value can also be divided into the upper cross-point value of the rising edge and the upper cross-point value of the falling edge. Correspondingly, the time midpoint value between each eigenvalue includes: time midpoint value 1, time midpoint value 2, time midpoint value 3, and time midpoint value 4. The distribution of each eigenvalue on the sensor data waveform is shown in the figure. Figure 5 As shown, among them: label 1 is the time midpoint value 1, label 2 is the time midpoint value 2, label 3 is the time midpoint value 3, label 4 is the time midpoint value 4, label 5 is the median, label 6 is the upper intersection value and the lower intersection value.

[0053] Step 103: During the motor operation phase, current sensing data of at least three linear Hall sensors within a specified time period are obtained, and a rough phase encoding is obtained based on the current sensing data and the median value, and / or, a precise phase encoding is obtained based on the current sensing data and the time midpoint value.

[0054] After obtaining the reference value, at least three linear Hall sensor data can be collected during the actual use of the motor, and the median value can be used to generate a phase encoding for rough position division, or the median value and the time midpoint value can be used to generate a phase encoding for precise position division. Figure 6 As shown, it is a rough phase encoding, such as Figure 7 As shown, it is the precise phase encoding. In the figure, the area between two adjacent vertical lines corresponds to the rotor position range represented by a phase encoding.

[0055] In actual implementation, one of the coarse phase encoding and the precise phase encoding can be selected for use as required, or the two phase encodings can be used in combination to meet different motor control accuracy requirements.

[0056] After steps 101 to 103 provided in this embodiment, high-precision phase encoding can be obtained through at least three linear Hall sensors to meet the control requirements of a small-volume motor.

[0057] Since the waveform of the sensor signal can be regarded as a sine wave, the location of the median roughly corresponds to the midpoint of the rising edge or the falling edge. In specific implementation, in general scenarios, the average of the minimum and maximum values ​​of the sensor data of each channel can be used as the median of the channel; in actual implementation, since the sensor data corresponds to the angle change of the rotor, the minimum and maximum values ​​of the sensor data of each channel are consistent, and the minimum and maximum values ​​of the sensor data of any channel can be taken, and their average value can be used as the median of all channels. In scenarios that require higher precision, the average value of all sensor data of each channel can also be used as the median of the channel; in actual implementation, since the sine wave has the characteristic of periodic repetition, all sensor data within a sine wave cycle can be obtained, and the average value of all sensor data within a sine wave cycle can be used as the median of all channels.

[0058] After obtaining the median, the current sensing data at each time point can be compared with the median to obtain a rough phase encoding. Specifically: the current sensing data at the current time point in at least three consecutive channels are obtained, and each current sensing data obtained is compared with the median, and a rough phase encoding is obtained according to the distribution of the comparison results of all channels; wherein the number of bits of the phase encoding is determined according to the number of comparison result distributions, and each comparison result corresponds to a rough phase encoding.

[0059] like Figure 6 As shown in the figure, in a specific scenario: A, B, and C are the current sampling values ​​of the three linear Hall sensors. Taking the phase encoding in a sine wave cycle as an example, the horizontal axis in the figure is the time axis, the sine wave represents the sensor signal, and the square wave represents the division of the phase encoding:

[0060] When A is greater than or equal to the median, B is less than the median, and C is greater than or equal to the median, the code for the coarse position division is binary 001;

[0061] When A is less than the median and B is less than the median and C is greater than or equal to the median, the code for the rough position division is binary 010;

[0062] When A is less than the median, B is greater than or equal to the median, and C is greater than or equal to the median, the code for the rough position division is binary 011;

[0063] When A is less than the median, B is greater than or equal to the median, and C is less than the median, the code for the coarse position division is binary 100;

[0064] When A is greater than or equal to the median, B is greater than or equal to the median, and C is less than the median, the code for the coarse position division is binary 101;

[0065] When A is greater than or equal to the median, B is less than the median, and C is less than the median, the encoding of the coarse position division is binary 110.

[0066] In scenarios with higher accuracy requirements, the intersection point values ​​of the three-channel sensor signal waveforms can be further calculated, and the rotor position range corresponding to each phase encoding can be subdivided through the time midpoint value of the intersection point value to obtain accurate phase encoding.

[0067] According to the characteristics of the sine wave, the sine wave signals of the three channels will cross after overlapping, and the value of the intersection point represents the sensor data value when the sensor data of the two channels are equal at the same time. In this embodiment, the rotor position range corresponding to each phase encoding can be further subdivided by the intersection point value. Specifically, in the initial sensor data of each two adjacent channels, the sensor data with the same value at the same time point is obtained; when the obtained sensor data is less than the median value, the sensor data is used as the lower intersection point value; when the obtained sensor data is greater than or equal to the median value, the sensor data is used as the upper intersection point value.

[0068] (1) Time midpoint value 1: On the rising edge of the sensor data, obtain the time midpoint between the time point corresponding to the lower cross point value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as time midpoint value 1. This value represents: the signal value at the time midpoint between the lower cross point and the median point on the rising edge.

[0069] (2) Time midpoint value 2: On the rising edge of the sensor data, obtain the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as time midpoint value 2. This value represents the signal value at the time midpoint between the upper intersection point and the median point on the rising edge.

[0070] (3) Time midpoint value 3: On the falling edge of the sensor data, obtain the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as time midpoint value 3. This value represents the signal value at the time midpoint between the upper intersection point and the median point on the falling edge.

[0071] (4) Time midpoint value 4: In the falling edge of the sensing data, obtain the time midpoint between the time point corresponding to the lower intersection value and the time point corresponding to the median value, and use the sensing data corresponding to the time midpoint as the time midpoint value 4. This value represents: the signal value at the time midpoint between the lower intersection point and the median point in the falling edge.

[0072] After obtaining the time midpoint value, the current sensing data at each time point can be compared with the median value and the time midpoint value to obtain an accurate phase encoding. Specifically: obtain the current sensing data at the current time point in at least three consecutive channels, compare each obtained current sensing data with the median value and each time midpoint value respectively, and obtain a rough phase encoding according to the distribution of the comparison results of all channels; among them, the number of bits of the phase encoding is determined according to the number of the comparison result distributions, and each comparison result corresponds to an accurate phase encoding respectively.

[0073] As Figure 7 shown, in a specific scenario: A, B, and C are the current sampling values of three linear Hall sensors respectively. Taking the phase encoding in a sine wave period as an example, the horizontal axis in the figure is the time axis, the sine wave represents the sensing signal, and the square wave represents the division of the phase encoding:

[0074] A ≥ C, and A < time midpoint value 1, and A < B, at this time the phase encoding is 0;

[0075] A ≥ time midpoint value 1, and A < median point, and A > C, and A < B, at this time the phase encoding is 1;

[0076] A ≥ median point, and A < time midpoint value 2, and A > C, and A < B, at this time the phase encoding is 2;

[0077] A ≥ time midpoint value 2, and A < B, and A > C, at this time the phase encoding is 3;

[0078] B ≥ time midpoint value 3, and B < A, and B > C, at this time the phase encoding is 4;

[0079] B ≥ median point, and B < time midpoint value 3, and B > C, and B < A, at this time the phase encoding is 5;

[0080] B ≥ time midpoint value 4, and B < median point, and B > C, and B < A, at this time the phase encoding is 6;

[0081] B ≥ C, and B < time midpoint value 4, and B < A, at this time the phase encoding is 7;

[0082] C > B, and C < time midpoint value 1, and C < A, at this time the phase encoding is 8;

[0083] C ≥ time midpoint value 1, and C < median point, and C > B, and C < A, at this time the phase encoding is 9;

[0084] C ≥ median point, and C < mid - time value 2, and C > B, and C < A, at this time the phase encoding is 10;

[0085] C ≥ mid - time value 2, and C < A, and C > B, at this time the phase encoding is 11;

[0086] A ≥ mid - time value 3, and A < C, and A > B, at this time the phase encoding is 12;

[0087] A ≥ median point, and A < mid - time value 3, and A > B, and A < C, at this time the phase encoding is 13;

[0088] A ≥ mid - time value 4, and A < median point, and A > B, and A < C, at this time the phase encoding is 14;

[0089] A ≥ B, and A < mid - time value 4, and A < C, at this time the phase encoding is 15;

[0090] B ≥ A, and B < mid - time value 1, and B < C, at this time the phase encoding is 16;

[0091] B ≥ mid - time 1, and B < median point, and B > A, and B < C, at this time the phase encoding is 17;

[0092] B ≥ median point, and B < mid - time value 2, and B > A, and B < C, at this time the phase encoding is 18;

[0093] B ≥ mid - time value 2, and B < C, and B > A, at this time the phase encoding is 19;

[0094] C ≥ mid - time value 3, and 2 < B, and C > A, at this time the phase encoding is 20;

[0095] C ≥ median point, and C < mid - time value 3, and C > A, and 2 < B, at this time the phase encoding is 21;

[0096] C ≥ mid - time value 4, and C < median point, and C > A, and C < B, at this time the phase encoding is 22;

[0097] C ≥ A, and C < mid - time value 4, and C < B, at this time the phase encoding is 23.

[0098] When the number of linear Hall sensors is greater than three, the corresponding eigenvalue and mid - time value can be obtained by referring to the calculation method, and the phase encoding division rule can be obtained, so as to complete a more accurate phase encoding division.

[0099] The phase encoding method of the permanent magnet synchronous motor provided in this embodiment uses multiple linear Hall sensors with specific mechanical angles and phase angles, overlaps the sensing data curves of the linear Hall sensors, and divides the rotor position range represented by the phase encoding according to the overlapped characteristic values ​​and time midpoint values. The generated phase encoding accuracy greatly exceeds the phase encoding data of the encoding accuracy of a single nonlinear Hall sensor. The motor driver can output more accurate current and flux control signals to the permanent magnet synchronous motor with the help of high-precision phase encoding data, so that the permanent magnet synchronous motor has a higher speed, a more stable speed, and less noise.

[0100] Embodiment 2:

[0101] Based on the phase encoding method of the permanent magnet synchronous motor provided in the above embodiment 1, the present invention also provides an absolute value encoder of the permanent magnet synchronous motor that can be used to implement the above method.

[0102] like Figure 8 The absolute value encoder provided in this embodiment includes at least three linear Hall sensors and a microprocessor. Figure 8 Three linear Hall sensors are taken as an example.

[0103] Each linear Hall sensor is used to obtain the sensing data of a channel and output the sensing data to the microprocessor. In actual implementation, the sensing data is output to the microprocessor in the form of a voltage output signal. In order to make the sensing data obtained by the linear Hall sensor meet the requirements of the phase encoding method in Example 1, the electrical angle or phase angle of adjacent linear Hall sensors differs by 120 degrees. In actual implementation, the linear Hall sensor can be fixed at a mechanical angle of 30 degrees, or a linear Hall sensor installation position with a mechanical angle of 30 degrees can be reserved. The linear Hall sensor model can use the MT9101 of the MT910X series, and this model of Hall sensor is a linear Hall sensor.

[0104] Each analog-to-digital conversion pin of the microprocessor is connected to each Hall sensor, respectively, and is used to obtain the corresponding phase encoding according to the phase encoding method of the permanent magnet synchronous motor provided in Example 1. Since the linear Hall sensor outputs the sensing data in the form of a voltage output signal, analog-to-digital conversion is required for subsequent calculation processing, such as Fig. 9As shown, the microprocessor includes at least three analog-to-digital conversion modules, each of which is used to convert the sensing data of a channel from a voltage analog signal to corresponding voltage data. Each analog-to-digital conversion module corresponds to an analog-to-digital conversion pin of the microprocessor, and each analog-to-digital conversion pin is respectively connected to each linear Hall sensor, for collecting the voltage output signal of the linear Hall sensor, and converting it into a digital signal through the built-in analog-to-digital converter of the microprocessor for use in subsequent calculations. In the method provided in Example 1, only simple numerical calculations and comparisons are required in the calculation process of phase encoding. Therefore, there is no need to use a high-performance microprocessor, which simplifies the writing of the control program, reduces the size of the absolute encoder, and reduces the cost of the equipment. In the specific implementation, the model can be selected as HC32L130E8PA, which has a built-in analog-to-digital converter with at least three input channels, and an analog-to-digital converter module containing 29 input channels is integrated internally.

[0105] In a specific scenario, such as Fig.10 As shown, when the motor includes 12 stator windings, the absolute value encoder specifically includes: the sensor head of each linear Hall sensor is placed in the space between a group of adjacent stator windings on the motor, and is located on the side close to the rotor, and the sensor heads of each linear Hall sensor are located in a continuous space. The sensor heads of the three Hall sensors respectively extend into the side of the three consecutive and adjacent stator windings of the permanent magnet synchronous motor stator close to the rotor, so that the mechanical angle between two adjacent Hall sensors in the permanent magnet synchronous motor is 30 degrees, and the electrical angle or phase angle differs by 120 degrees, which meets the use requirements of the sensor data in Example 1. In a specific implementation, when the permanent magnet synchronous motor has 12 slots and 8 poles, 9 slots and 6 poles, and 6 slots and 4 poles, the adjacent windings all meet the requirements of a phase angle or electrical angle of 120 degrees, and a similar method can be used. Fig.10 Set up the sensing head of the linear Hall sensor in the manner described in the previous section.

[0106] In order to enable the permanent magnet synchronous motor driver to obtain the phase encoding calculated by the microprocessor, such as Fig.11 As shown, the absolute encoder also includes a level conversion chip, which is connected to the communication pin of the microprocessor and to the driver of the motor, and is used to send the phase code obtained by the microprocessor to the driver of the motor. In actual implementation, the level conversion chip can use an RS485 level conversion chip, and the microprocessor and the motor driver can use the UART serial port communication pin to connect to the RS485 level conversion chip.

[0107] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A phase encoding method for a permanent magnet synchronous motor, characterized in that: include: In the motor initial angle measurement phase, initial sensing data of at least three linear Hall sensors within a specified time period are obtained; wherein the electrical angles or phase angles of adjacent linear Hall sensors differ by 120 degrees; Calculate the characteristic values ​​of the initial sensing data, and calculate the time midpoint value between adjacent characteristic values; wherein the characteristic values ​​include: the median value, the lower intersection value and the upper intersection value; During the motor operation phase, current sensing data of at least three linear Hall sensors within a specified time period are obtained, and a rough phase encoding is obtained based on the current sensing data and a median value, and / or, an accurate phase encoding is obtained based on the current sensing data and a time midpoint value.

2. The phase encoding method of a permanent magnet synchronous motor according to claim 1, characterized in that: The calculation of the characteristic value of the initial sensing data, when calculating the median, specifically includes: The average of the minimum and maximum values ​​of the sensing data of each channel is taken as the median value of the channel; And / or, the average value of all sensing data of each channel is taken as the median value of the channel.

3. The phase encoding method of a permanent magnet synchronous motor according to claim 1, characterized in that: The calculation of the characteristic value of the initial sensing data, when calculating the lower intersection value and the upper intersection value, specifically includes: In the initial sensing data of every two channels, sensing data with the same value at the same time point are obtained; When the acquired sensor data is less than the median value, the sensor data is used as the lower intersection value; When the acquired sensor data is greater than or equal to the median value, the sensor data is used as the upper intersection value.

4. The phase encoding method of a permanent magnet synchronous motor according to claim 1, characterized in that: The calculating of the time midpoint value between adjacent characteristic values ​​specifically includes: On the rising edge of the sensor data, obtain the time midpoint between the time point corresponding to the lower intersection value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as the time midpoint value 1; On the rising edge of the sensor data, obtain the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as the time midpoint value 2; In the falling edge of the sensor data, the time midpoint between the time point corresponding to the upper intersection value and the time point corresponding to the median value is obtained, and the sensor data corresponding to the time midpoint is used as the time midpoint value 3; On the falling edge of the sensor data, obtain the time midpoint between the time point corresponding to the lower intersection value and the time point corresponding to the median value, and use the sensor data corresponding to the time midpoint as the time midpoint value 4.

5. The phase encoding method of a permanent magnet synchronous motor according to claim 1, characterized in that: The step of obtaining a rough phase encoding according to the current sensing data and the median value at each time point specifically includes: The current sensing data at the current time point in at least three consecutive channels are obtained, each current sensing data obtained is compared with the median value, and a rough phase encoding is obtained according to the comparison result distribution of all channels; wherein the number of bits of the phase encoding is determined according to the number of comparison result distributions, and each comparison result corresponds to a rough phase encoding.

6. The phase encoding method of a permanent magnet synchronous motor according to claim 1, characterized in that: The step of obtaining accurate phase encoding according to current sensing data and a time midpoint value specifically includes: The current sensing data at the current time point in at least three consecutive channels are obtained, and each current sensing data obtained is compared with the median and each time midpoint value respectively, and a rough phase encoding is obtained according to the comparison result distribution of all channels; wherein the number of bits of the phase encoding is determined according to the number of comparison result distributions, and each comparison result corresponds to an accurate phase encoding.

7. An absolute value encoder for a permanent magnet synchronous motor, characterized in that: include: At least three linear Hall sensors and a microprocessor, specifically including: Each linear Hall sensor is used to obtain the sensing data of one channel and output the sensing data to the microprocessor. The electrical angle or phase angle of adjacent linear Hall sensors differs by 120 degrees. Each analog-to-digital conversion pin of the microprocessor is respectively connected to each Hall sensor, and is used to obtain corresponding phase encoding according to the phase encoding method of the permanent magnet synchronous motor provided in any one of claims 1-6.

8. The absolute value encoder of the permanent magnet synchronous motor according to claim 7, characterized in that: When the motor includes 12 stator windings, the absolute encoder specifically includes: The sensing head of each linear Hall sensor is placed in the space between a group of adjacent stator windings on the motor and is located on the side close to the rotor. The sensing heads of each linear Hall sensor are located in a continuous space.

9. The absolute value encoder of the permanent magnet synchronous motor according to claim 7, characterized in that: The microprocessor includes at least three analog-to-digital conversion modules, each of which is used to convert the sensing data of a channel from a voltage analog signal into corresponding voltage data.

10. The absolute value encoder of the permanent magnet synchronous motor according to claim 7, characterized in that: The absolute value encoder also includes a level conversion chip, which is connected to the communication pin of the microprocessor and to the driver of the motor, and is used to send the phase code obtained by the microprocessor to the driver of the motor.