A kind of acquisition motor rotor position, the method and device of speed
Technical field
The present invention relates to the control technology field of permagnetic synchronous motor.Specifically, it is related to a kind of acquisition rotor position
Put, the method and device of speed.
Background technology
With modern power electronics technology, microelectric technique, the raising of motor process technology and modern control theory
Develop rapidly, high power density, permagnetic synchronous motor (PMSM, Permanent the Magnet Synchronous of high reliability
Motor the every field such as military, industry and daily life) are increasingly being applied to.In the control system of permagnetic synchronous motor
, it is necessary to position and the rotating speed of rotor be obtained in real time, to realize the oriented control in magnetic field in system.
In the prior art, typically motor rotor position is examined in real time using Hall sensor or rotary transformer
Survey, as shown in figure 1, still because the signal that Hall sensor or rotary transformer are exported all be it is related to rotor position just
String sin θ and cosine con θ, when carrying out rotor position calculating, it is necessary to be passed through anyway according to above-mentioned sinusoidal sin θ and cosine con θ
Cut calculating and obtain rotor position;Then, motor turn can just be obtained by then carrying out differential calculation to the motor rotor position θ calculated
Rotor speed ω.But, because arc tangent and differential calculation have, speed is slow, low precision defect, causes current permanent magnet synchronous electric
The control performance and job stability of machine are all poor.
The content of the invention
Therefore, the technical problems to be solved by the invention are to need in the prior art by arc tangent and differential calculation
Motor rotor position can be obtained, calculating speed is slow, low precision, causes the control performance and job stability of motor all poor,
So as to provide, a kind of speed is fast, precision is high, and can improve the acquisition rotor of motor control performance and job stability
Position and the method for speed.
In order to solve the above technical problems, technical scheme is as follows:
A kind of method for obtaining motor rotor position and speed, including:
Obtain rotor angular accelerationcalc;
Obtain rotor angle of electric machine acceleration bias αerr;
According to the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias αerr, obtain motor and turn
Sub- angular acceleration correction value αpll;
According to the rotor angle of electric machine acceleration correction value αpllObtain motor rotor speed ωpllAnd motor rotor position
θpll。
In the above method, the acquisition rotor angular accelerationcalcIncluding:
Obtain Motor torque Tqcalc;
Obtain motor speed rotary inertia J;
By the Motor torque TqcalcIt is divided by with the motor speed rotary inertia J, obtains rotor angular acceleration
αcalc。
In the above method, the acquisition Motor torque Tqcalc, including,
Calculated using equation below and obtain Motor torque:
Wherein, idAnd iqRespectively d-axis actual current and quadrature axis actual current, TqcalcFor the actual torque of motor, LdWith
LqRespectively d-axis inductance and quadrature axis inductance, p are the number of pole-pairs of motor, ψmFor rotor permanent magnet flux linkage.
In the above method, the acquisition rotor angle of electric machine acceleration bias αerrIncluding:
Obtained the motor rotor position θ in a upper cyclepll, and calculate cos (θPLL) and sin (θPLL) value;
Obtain the sin (θ of sensor measurementmea) and cos (θmea) value;
According to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain the first deviation θerr;
To the first deviation θerrPID control is carried out, rotor angle of electric machine acceleration bias α is obtainederr。
It is described according to cos (θ in the above methodPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain the first deviation θerr
Including:
Calculated using equation below and obtain the first deviation θerr:
θerr=sin (θmea)*cos(θPLL)-cos(θmea)*sin(θPLL)。
In the above method, the motor rotor position θ in a cycle in the acquisitionpll, and calculate cos (θPLL) and sin
(θPLL) value, including cos (θ are calculated by phaselocked loopPLL) and sin (θPLL) value.
It is described according to the rotor angular acceleration in the above methodcalcWith the rotor angle of electric machine acceleration bias
αerr, obtain rotor angle of electric machine acceleration correction value αpllIncluding:
By the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias αerrIt is added;
To αcalc+αerrLow-pass filtering treatment is carried out, rotor angle of electric machine acceleration correction value α is obtainedpll。
It is described according to the rotor angle of electric machine acceleration correction value α in the above methodpllObtain motor rotor speed ωpll
With motor rotor position θpllIncluding:
To the rotor angle of electric machine acceleration correction value αpllIt is integrated, obtains motor rotor speed ωpll;
To the motor rotor speed ωpllIt is integrated, obtains motor rotor position θpll。
A kind of device of acquisition motor rotor position and speed, including:
Angular acceleration acquiring unit, for obtaining rotor angular accelerationcalc;
Deviation acquiring unit, for obtaining rotor angle of electric machine acceleration bias αerr;
Correction value acquiring unit, for according to the rotor angular accelerationcalcWith the rotor angular acceleration
Deviation αerr, obtain rotor angle of electric machine acceleration correction value αpll;
Velocity location acquiring unit, for according to the rotor angle of electric machine acceleration correction value αpllObtain rotor speed
Spend ωpllWith motor rotor position θpll。
In said apparatus, the angular acceleration acquiring unit includes:
Moment of torsion obtains subelement, for obtaining Motor torque Tqcalc;
Inertia obtains subelement, for obtaining motor speed rotary inertia J;
Angular acceleration computation subunit, for by the Motor torque TqcalcWith the motor speed rotary inertia J phases
Remove, obtain rotor angular accelerationcalc。
In said apparatus, the moment of torsion obtains subelement, is calculated using equation below and obtains Motor torque Tqcalc:
Wherein, idAnd iqRespectively d-axis actual current and quadrature axis actual current, TqcalcFor the actual torque of motor, LdWith
LqRespectively d-axis inductance and quadrature axis inductance, p are the number of pole-pairs of motor, ψmFor rotor permanent magnet flux linkage.
In said apparatus, the deviation acquiring unit includes:
Rotor-position introduces subelement, the motor rotor position θ for obtaining a upper cyclepll, and calculate cos (θPLL)
With sin (θPLL) value;
Sensor values introduce subelement, the sin (θ for obtaining sensor measurementmea) and cos (θmea) value;
First deviation obtains subelement, for according to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain the
One deviation θerr;
Deviation computation subunit, for the first deviation θerrPID control is carried out, rotor angular acceleration is obtained
Deviation αerr。
In said apparatus, first deviation obtains subelement, is calculated using equation below and obtains the first deviation θerr:
θerr=sin (θmea)*cos(θPLL)-cos(θmea)*sin(θPLL)。
In said apparatus, the correction value acquiring unit includes:
Subelement is superimposed, for by the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias
αerrIt is added;
Filtering subunit, for αcalc+αerrLow-pass filtering treatment is carried out, rotor angle of electric machine acceleration correction value is obtained
αpll。
In said apparatus, the velocity location acquiring unit includes:
First integral subelement, for the rotor angle of electric machine acceleration correction value αpllIt is integrated, obtains motor and turn
Sub- speed omegapll;
Second integral subelement, for the motor rotor speed ωpllIt is integrated, obtains motor rotor position
θpll。
The above-mentioned technical proposal of the present invention has advantages below compared with prior art:
(1) acquisition motor rotor position of the invention, the method and device of speed, are accelerated by obtaining rotor angle of electric machine
Degree, acquisition rotor angle of electric machine acceleration bias, afterwards according to rotor angular acceleration and rotor angle of electric machine acceleration bias, just
Rotor angle of electric machine acceleration correction value can be obtained, rotor speed can be obtained by according to rotor angle of electric machine acceleration correction value
Degree and motor rotor position.Without obtaining motor rotor position by arc tangent and differential calculation, calculating speed is fast, precision
Height, makes the control performance of motor more stablize.
(2) acquisition motor rotor position of the invention, the method and device of speed, to αcalc+αerrAt LPF
Reason, reduces influence of noise, therefore the input of sine, consine signal is not necessarily to directly carry out low pass filtered processing again, and this enters
One step reduces the time for performing algorithm consumption.
(3) acquisition motor rotor position of the invention, the method and device of speed, calculating and position signalling due to speed
Employ identical sampling rate, therefore phase shift during speed calculating will be reduced such that the same of motor speed and position
More preferably, the control effect of whole system is also more preferable for step property.
(4) acquisition motor rotor position of the invention, the method and device of speed, are not related to and differentiate, therefore to the greatest extent
Pipe has used high speed acquisition speed, and influence of noise when speed is calculated also can be reduced significantly.
Brief description of the drawings
In order that present disclosure is more likely to be clearly understood, specific embodiment and combination below according to the present invention
Accompanying drawing, the present invention is further detailed explanation, wherein
Fig. 1 is existing acquisition motor rotor position, the involved whole control scheme schematic diagram of speed method;
Fig. 2 is that the present invention obtains motor rotor position, the whole control scheme schematic diagram involved by speed method;
Fig. 3 present invention obtains motor rotor position, the flow chart of the method for speed;
Fig. 4 is that the present invention obtains the flow chart that rotor angular acceleration is obtained in motor rotor position, the method for speed;
Fig. 5 is that the present invention obtains the stream that rotor angle of electric machine acceleration bias is obtained in motor rotor position, the method for speed
Cheng Tu;
Fig. 6 is that the present invention is obtained in motor rotor position, the method for speed according to rotor angular acceleration and motor turn
Sub- angular acceleration deviation obtains the flow chart of rotor angle of electric machine acceleration correction value;
Fig. 7 is that the present invention obtains motor rotor position, is worth according to rotor angle of electric machine acceleration correction in the method for speed
To motor rotor speed and the flow chart of motor rotor position;
Fig. 8 is that the present invention obtains motor rotor position, the overall control schematic diagram of the method for speed;
Fig. 9 is that the present invention obtains motor rotor position, the structured flowchart of the device of speed.
Reference is expressed as in figure:1- angular acceleration acquiring units, 2- deviation acquiring units, 3- correction values obtain single
Member, 4- velocity location acquiring units, 11- moments of torsion obtain subelement, and 12- inertia obtains subelement, 13- angular accelerometer operator lists
Member, 21- rotor-positions introduce subelement, and 22- sensor values introduce subelement, and the deviations of 23- first obtain subelement, and 24- is inclined
Poor computation subunit, 31- superposition subelements, 32- filtering subunits, 41- first integral subelements, 42- second integral subelements.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.It is based on
Embodiment in the present invention, it is every other that those of ordinary skill in the art are obtained under the premise of creative work is not made
Embodiment, belongs to the scope of protection of the invention.
As shown in Fig. 2 being to obtain motor rotor position, the whole control scheme schematic diagram involved by speed method.In Fig. 2
In, iaAnd icIt is A phase currents and C phase currents respectively;idAnd iqIt is d-axis actual current and quadrature axis actual current respectively.
A kind of acquisition motor rotor position, the method for speed are present embodiments provided, as shown in figure 3, including:
S1. rotor angular acceleration is obtainedcalc;
S2. rotor angle of electric machine acceleration bias α is obtainederr;
S3. according to the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias αerr, obtain motor
Rotor angle acceleration correction value αpll;
S4. according to the rotor angle of electric machine acceleration correction value αpllObtain motor rotor speed ωpllWith rotor position
Put θpll。
Preferably, as shown in Fig. 4, Fig. 8, the acquisition rotor angular accelerationcalcIt can include:
S11. Motor torque Tq is obtainedcalc;
S12. motor speed rotary inertia J is obtained;
S13. by the Motor torque TqcalcIt is divided by with the motor speed rotary inertia J, obtains rotor angle of electric machine acceleration
Spend αcalc。
Preferably, the acquisition Motor torque Tqcalc, can include:
Calculated using equation below and obtain Motor torque:
Wherein, idAnd iqRespectively d-axis actual current and quadrature axis actual current, TqcalcFor the actual torque of motor, LdWith
LqRespectively d-axis inductance and quadrature axis inductance, p are the number of pole-pairs of motor, ψmFor rotor permanent magnet flux linkage.
Specifically, above-mentioned id、iq、Ld、Lq, p and ψmCan in real time it be obtained from entire car controller, motor speed is rotated
Inertia J can be calculated according to inertia calculation formula and obtained.
Preferably, as shown in Figure 5, Figure 8, the acquisition rotor angle of electric machine acceleration bias αerrIt can include:
S21. the motor rotor position θ in a upper cycle was obtainedpll, and calculate cos (θPLL) and sin (θPLL) value;
S22. sin (the θ of sensor measurement are obtainedmea) and cos (θmea) value;
S23. according to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain the first deviation θerr;
S24. to the first deviation θerrPID control is carried out, rotor angle of electric machine acceleration bias α is obtainederr。
Specifically, the motor rotor position θ in a upper cyclepllIt can be obtained from phaselocked loop, because flowing into the electric current of phaselocked loop
The negative-sequence current obtained after filtered processing is the rotatory current vector of rotor-position angle function, and rotor is constructed by heterodyne method
Position angle error, passes through phaselocked loop adjusting position angle error to 0, so that it may so that observation position angle tracking motor rotor-position always
Angle, so as to extract motor rotor position θpll, by the motor rotor position θ in a upper cyclepllCirculation substitutes into the meter in next cycle
Calculate, it is possible to get new rotor angle of electric machine acceleration bias α in real timeerr, afterwards according to rotor angular accelerationcalcWith
Rotor angle of electric machine acceleration bias αerr, it is possible to obtain rotor angle of electric machine acceleration correction value α in real timepll, and it is real-time accordingly
Get motor rotor speed ωpllWith motor rotor position θpll。
cos(θPLL) and sin (θPLL) value calculated by phaselocked loop, sin (θmea) and cos (θmea) can directly from
Sensor is obtained, then according to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) it can be obtained by the first deviation θerr,
To the first deviation θerrCarry out PID control, it is possible to obtain rotor angle of electric machine acceleration bias αerr.
To the first deviation θerrPID (ratio (Proportion), integration (Integration), differential can be passed through
(Differentiation)) controller carries out PID control to it, therefrom inclined by PID controller output motor rotor angular acceleration
Poor αerr。
Preferably, as shown in figure 8, described according to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain first
Deviation θerrIt can include:
Calculated using equation below and obtain the first deviation θerr:
θerr=sin (θmea)*cos(θPLL)-cos(θmea)*sin(θPLL).The amount of calculation of above-mentioned calculating is very small, can be with
Efficiently obtain very much the first deviation θerr。
Preferably, it is described according to the rotor angular acceleration as shown in Fig. 6, Fig. 8calcWith the rotor angle of electric machine
Acceleration bias αerr, obtain rotor angle of electric machine acceleration correction value αpllIt can include:
S31. by the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias αerrIt is added;
S32. to αcalc+αerrLow-pass filtering treatment is carried out, rotor angle of electric machine acceleration correction value α is obtainedpll。
Specifically, by by rotor angular accelerationcalcWith rotor angle of electric machine acceleration bias αerrGone forward side by side after superposition
Row low-pass filtering treatment, can filter out noise, so as to get rotor angle of electric machine acceleration correction value αpllIt is more accurate.
Preferably, as shown in Figure 7, Figure 8, it is described according to the rotor angle of electric machine acceleration correction value αpllMotor is obtained to turn
Sub- speed omegapllWith motor rotor position θpllIt can include:
S41. to the rotor angle of electric machine acceleration correction value αpllIt is integrated, obtains motor rotor speed ωpll;
S42. to the motor rotor speed ωpllIt is integrated, obtains motor rotor speed ωpll。
Specifically, simply by rotor angle acceleration correction value αpllIt is integrated, it is possible to obtain motor rotor speed
ωpll, simply by motor rotor speed ωpllIt is integrated, it is possible to obtain motor rotor position θpll, without carrying out
The calculating of arc tangent and differential, greatly reduces amount of calculation, improves calculating speed and precision.
By obtained motor rotor speed ωpllWith motor rotor speed ωpllEntire car controller is fed back to, motor is turned
Speed is adjusted correspondingly, and can be very good to realize the oriented control in magnetic field, it is ensured that the even running of permagnetic synchronous motor, has
Beneficial to the running efficiency for improving permagnetic synchronous motor, energy consumption is reduced.
The present embodiment additionally provides a kind of acquisition motor rotor position and the device of speed, as shown in figure 9, including:
Angular acceleration acquiring unit 1, for obtaining rotor angular accelerationcalc;
Deviation acquiring unit 2, for obtaining rotor angle of electric machine acceleration bias αerr;
Correction value acquiring unit 3, for according to the rotor angular accelerationcalcAccelerate with the rotor angle of electric machine
Spend deviation αerr, obtain rotor angle of electric machine acceleration correction value αpll;
Velocity location acquiring unit 4, for according to the rotor angle of electric machine acceleration correction value αpllObtain rotor speed
Spend ωpllWith motor rotor position θpll。
Preferably, the angular acceleration acquiring unit 1 can include:
Moment of torsion obtains subelement 11, for obtaining Motor torque Tqcalc;
Inertia obtains subelement 12, for obtaining motor speed rotary inertia J;
Angular acceleration computation subunit 13, for by the Motor torque TqcalcWith the motor speed rotary inertia J phases
Remove, obtain rotor angular accelerationcalc。
Preferably, the moment of torsion obtains subelement 11, can be calculated using equation below and obtain Motor torque Tqcalc:
Wherein, idAnd iqRespectively d-axis actual current and quadrature axis actual current, TqcalcFor the actual torque of motor, LdWith
LqRespectively d-axis inductance and quadrature axis inductance, p are the number of pole-pairs of motor, ψmFor rotor permanent magnet flux linkage.
Preferably, the deviation acquiring unit 2 can include:
Rotor-position introduces subelement 21, the motor rotor position θ for obtaining a upper cyclepll, and calculate cos
(θPLL) and sin (θPLL) value;
Sensor values introduce subelement 22, the sin (θ for obtaining sensor measurementmea) and cos (θmea) value;
First deviation obtains subelement 23, for according to cos (θPLL)、sin(θPLL)、sin(θmea)、cos(θmea) obtain
First deviation θerr;
Deviation computation subunit 24, for the first deviation θerrPID control is carried out, rotor angle of electric machine acceleration is obtained
Spend deviation αerr。
Preferably, first deviation obtains subelement 23, can be calculated using equation below and obtain the first deviation θerr:
θerr=sin (θmea)*cos(θPLL)-cos(θmea)*sin(θPLL)。
Preferably, the correction value acquiring unit 3 can include:
Subelement 31 is superimposed, for by the rotor angular accelerationcalcWith the rotor angle of electric machine acceleration bias
αerrIt is added;
Filtering subunit 32, for αcalc+αerrLow-pass filtering treatment is carried out, rotor angle of electric machine acceleration correction is obtained
Value αpll。
Preferably, the velocity location acquiring unit 4 can include:
First integral subelement 41, for the rotor angle of electric machine acceleration correction value αpllIt is integrated, obtains motor
Rotor speed omegapll;
Second integral subelement 42, for the motor rotor speed ωpllIt is integrated, obtains motor rotor position
θpll。
The device of motor rotor position speed and speed is obtained described in the present embodiment, without passing through arc tangent and differential calculation
To obtain motor rotor position, calculating speed is fast, and precision is high, the control performance of motor is more stablized.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or computer program
Product.Therefore, the present invention can be using the reality in terms of complete hardware embodiment, complete software embodiment or combination software and hardware
Apply the form of example.Moreover, the present invention can be used in one or more computers for wherein including computer usable program code
The computer program production that usable storage medium is implemented on (including but is not limited to magnetic disk storage, CD-ROM, optical memory etc.)
The form of product.
The present invention is the flow with reference to method according to embodiments of the present invention, equipment (system) and computer program product
Figure and/or block diagram are described.It should be understood that can be by every first-class in computer program instructions implementation process figure and/or block diagram
Journey and/or the flow in square frame and flow chart and/or block diagram and/or the combination of square frame.These computer programs can be provided
The processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce
A raw machine so that produced by the instruction of computer or the computing device of other programmable data processing devices for real
The device for the function of being specified in present one flow of flow chart or one square frame of multiple flows and/or block diagram or multiple square frames.
These computer program instructions, which may be alternatively stored in, can guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works so that the instruction being stored in the computer-readable memory, which is produced, to be included referring to
Make the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one square frame of block diagram or
The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter
Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented processing, thus in computer or
The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one
The step of function of being specified in individual square frame or multiple square frames.
, but those skilled in the art once know basic creation although preferred embodiments of the present invention have been described
Property concept, then can make other change and modification to these embodiments.So, appended claims are intended to be construed to include excellent
Select embodiment and fall into having altered and changing for the scope of the invention.