A kind of method and device that detects position of rotor of brushless motor
Technical field
The present invention relates to a kind of method and device that detects position of rotor of brushless motor, belong to the detection method and the device thereof of the rotor-position of brushless motor control system.
Background technology
One of key technology of brushless motor control system is the detection of rotor-position, after only detecting rotor real space position (absolute position), control system could determine the frequency and the phase place of step mode, control model and the output current of inverter, to guarantee the operate as normal of brushless electric machine.Thereby accurate detecting apparatus for rotor position is very important.In a single day position detecting device breaks down, and the motor phase change logic will cause confusion, and output torque reduction, speed descend until stall.High or some specific occasions at some reliability requirements, as: national defence, Aero-Space etc., the stall of motor may cause the loss of loss of life or personal injury and property.This just requires on the throne when putting signal and breaking down, and allows motor can continue operate as normal as much as possible, and does not influence the function of whole system, carries out troubleshooting when shutting down again.Therefore, the reliability of raising position of rotor of brushless motor signal is very necessary.
The transducer of detection position of rotor of brushless motor commonly used has absolute type grating encoder, Hall element and resolver.Absolute type grating encoder directly becomes digital signal with the rotating shaft angular transition, uses simple and conveniently, but is difficult to extensive use because of factors such as environmental suitability, price cause; Hall element is simple in structure, but is difficult to reach high accuracy angular surveying requirement and is restricted, resolver because of reliable in structure, real-time is good, environmental suitability is strong etc., and advantage is widely used in the high accuracy servo system.
In present lot of documents both domestic and external and the patent, the research of position of rotor of brushless motor detection is confined to the Opsonizing method of position signalling, research to the position of rotor of brushless motor detecting reliability only limits to hall position sensor, and the field that is difficult to satisfy more highly reliable requirements such as national defence and Aero-Space for the position of rotor of brushless motor detection method that adopts resolver.
When adopting resolver as the position of rotor of brushless motor checkout gear, resolver output two-way comprises the high frequency cosine and sine signal of rotor position information and quadrature, must or method such as resolve by signal condition and could obtain rotor position information, what be most widely used at present is to adopt special-purpose shaft angle digital quantizer (Resolver-to-DigitalConverter, letter is for RDC) etc. integrated chip add peripheral configuration circuit and resolve, this type of special use resolve chip to signal comparatively sensitivity there is no fault tolerance, so reliability is difficult to ensure.
Summary of the invention
The technical problem that solves
For fear of the deficiencies in the prior art part, the present invention proposes a kind of method and device that detects position of rotor of brushless motor, has from monitoring and fault tolerance, has improved the reliability of brushless electric machine servo system greatly.
Technical scheme
A kind of method that detects position of rotor of brushless motor is characterized in that the rotor coaxial of resolver and tested brushless electric machine is installed, and the concrete steps that detect position of rotor of brushless motor are as follows:
Step 1: the signal that the two-way of resolver secondary output is comprised rotor position angle θ information and quadrature carries out difference is changeed single-ended, obtains single-ended sinusoidal signal E
s(t, θ)=Esin (ω t) sin (θ) and single-ended cosine signal E
c(t, θ)=Esin (ω t) cos (θ); The signal that described two-way comprises rotor position angle θ information and quadrature is: the sinusoidal differential signal E of high frequency
S+(t, θ) and E
S-(t, θ), high frequency cosine differential signal E
C+(t, θ) and E
C-(t, θ); Wherein: E is the effective value of signal, and ω is the angular frequency of the reference signal Refs of sinusoidal excitation circuit generation;
Step 2: the sinusoidal differential signal Refs+ and the Refs-that are produced by the sinusoidal excitation circuit that will be input to resolver change single-ended sinusoidal reference signal-Refs=Esin (ω t) into;
Step 3: with single-ended sinusoidal signal E
s(t θ) superposes and obtains signal Refs+E with reference signal Refs
s(t, θ), with single-ended cosine signal E
c(t θ) obtains signal Refs+E with the Refs stack
c(t, θ);
Step 4: with Refs+E
s(t, θ) and Refs+E
c(t, θ) HFS in carries out filtering, obtains comprising the simulation low frequency sinusoidal signal E of rotor position information
s(θ)=Esin (θ)+E and low frequency cosine signal E
c(θ)=Ecos (θ)+E;
Step 5: will simulate low frequency sinusoidal signal E
s(θ)=Esin (θ)+E and cosine signal E
c(θ)=Ecos (θ)+E converts digital sine signal E to
s *(θ) with digital cosine signal E
c *(θ);
Step 6: ask for digital signal E
s *(θ) and E
c *Mean value U (θ);
Step 7: with digital sine signal E
s *(θ) deduct U, obtain sinusoidal signal input variable Y, with digital cosine signal E
c *(θ) deduct U, obtain cosine signal input variable X;
Step 8: judge motor rotor position place quadrant according to sinusoidal signal input variable Y and cosine signal input variable X:
When X 〉=0 and Y 〉=0, motor rotor position θ drops in 0~90 ° of scope;
When X<0 and Y 〉=0, motor rotor position θ drops in 90 °~180 ° scopes;
When X<0 and Y<0, motor rotor position θ drops in 180 °~270 ° scopes;
When X 〉=0 and Y<0, motor rotor position θ drops in 270 °~360 ° scopes;
Step 9: X, Y are mapped to first quartile, utilize cordic algorithm to calculate angle value
Determine motor rotor position θ according to the quadrant at the rapid middle θ place of previous step then:
When 0<θ≤90 °, motor rotor position
When 90 °<θ≤180 °, motor rotor position
When 180 °<θ≤270 °, motor rotor position
When 270 °<θ≤360 °, motor rotor position
When the resolver output signal broke down, the concrete steps that detect position of rotor of brushless motor were as follows:
Step a: the angle delta θ=ω that calculates motor rotation in the double sampling interval
rΔ T, wherein ω
rBe motor speed, unit is rad/s, and analog-to-digital sample frequency is f, and the time interval of double sampling is Δ T=1/f;
Step b: adopt the CORDIC inversion algorithms to obtain θ
GThe sine value E of=θ+Δ θ
SG *(θ
G) and cosine value E
CG *(θ
G), if
With
All do not exceed the limits of error, if
Exceed the limits of error, the sinusoidal signal of resolver output has fault; If
Exceed the limits of error, illustrate that then the cosine signal of resolver output has fault; The mean value U's of described limits of error peek word signal
Execution in
step 4~5;
Step c: if
With
All exceed the limits of error, utilize the CORDIC inversion algorithms to obtain θ '
GThe sine value E of=θ-Δ θ
SG *(θ '
G) and cosine value E
CG *(θ '
G), if
Exceed the limits of error, the sinusoidal signal of resolver output has fault; If
Exceed the limits of error, illustrate that then the cosine of resolver output has fault; The mean value U's of described limits of error peek word signal
Steps d: if the sinusoidal signal of resolver output breaks down, with the digital cosine signal E of step 5
c *(θ), utilize E
c *(θ) and E
s *Orthogonality relation (θ) is converted to E
s *(θ), and with E
s *(θ) Alternative digital sinusoidal signal E
s *(θ); If the cosine signal of resolver output breaks down, with the digital sine signal E of step 5
s *(θ), utilize E
s *(θ) and E
c *Orthogonality relation (θ) is converted to E
c *(θ), and with E
c *(θ) Alternative digital cosine signal E
c *(θ);
Step e: continue step 6~9, obtain motor rotor position θ.
A kind of device of realizing the method for any above-mentioned detection position of rotor of brushless motor is characterized in that comprising resolver, sinusoidal excitation circuit, differential signal transducer, accurate absolute value adder, inverter and low pass filter; Resolver and the coaxial installation of tested brushless electric motor rotor, the sinusoidal differential signal Refs+ of the high frequency that the sinusoidal excitation circuit produces, the one tunnel is input to the former limit of resolver, the E that comprises motor rotor position angle θ of resolver secondary output
S+(t, θ) and E
S-(t, θ), E
C+(t, θ) and E
C-(t θ) obtains single-ended sinusoidal signal E through two differential signal transducers respectively
s(t is θ) with single-ended cosine signal E
c(t, θ); Another road, the sinusoidal differential signal Refs+ of the high frequency of sinusoidal excitation circuit output changes single-ended sinusoidal reference signal-Refs input inverter into through the differential signal transducer, the Refs of inverter output inputs to separately accurate absolute value adder with the output signal of two differential signal transducers respectively, and the stack by accurate absolute value adder obtains output signal Refs+E
s(t, θ) and Refs+E
c(t, θ); The output signal of the accurate absolute value adder of two-way inputs to low pass filter separately, through the filtering output low frequency sinusoidal signal E relevant with rotor-position of low pass filter
s(θ)=Esin (θ)+E and cosine signal E
c(θ)=Ecos (θ)+E; The output of low pass filter is to input to DSP after the digital signal through the A/D module converts.
Beneficial effect
A kind of method and device that detects position of rotor of brushless motor that the present invention proposes, when adopting resolver as the position of rotor of brushless motor checkout gear, resolver output two-way comprises the high frequency cosine and sine signal of rotor position information and quadrature, obtains rotor position information by signal condition or method such as resolve.With what be most widely used at present is to adopt special-purpose shaft angle digital quantizer (Resolver-to-Digital Converter, letter is for RDC) etc. integrated chip add peripheral configuration circuit and resolve, this type of special use resolve chip to signal comparatively sensitivity there is no fault tolerance, so reliability is difficult to ensure.The present invention adds a simple signal conditioning circuit on the basis of RDC resolving circuit, just can realize having from the position of rotor of brushless motor of monitoring with fault tolerance and detect.Particular content comprises checkout gear and monitoring and fault-tolerance approach two large divisions certainly.
The superiority of apparatus of the present invention is: (1) hardware circuit is simple, cost is low, and the reliability of system is greatly improved; (2) CORDIC resolves the algorithm highly effective, and simple iteration of process and plus and minus calculation just can be realized the fault-tolerant detection of motor rotor position.
Description of drawings
Fig. 1: circuit theory diagrams of the present invention
Fig. 2: resolver principle schematic
Fig. 3: the sinusoidal excitation circuit of the embodiment of the invention
Fig. 4: the differential signal transducer of the embodiment of the invention
Fig. 5: the accurate absolute value adder of the embodiment of the invention
Fig. 6: the inverter of the embodiment of the invention
Fig. 7: the low-pass filter circuit of the embodiment of the invention
Embodiment
Now in conjunction with the embodiments, accompanying drawing is further described the present invention:
The exemplifying embodiment of apparatus of the present invention:
Checkout gear is divided into and coaxial mounted resolver of tested brushless electric motor rotor and signals of rotating transformer modulate circuit two large divisions, and the signals of rotating transformer modulate circuit comprises as the sinusoidal excitation circuit in signals of rotating transformer source and monitoring and tolerant fail algorithm signal conditioning circuit (comprising differential signal transducer, accurate absolute value adder, inverter and low pass filter) certainly.
The resolver principle schematic as shown in Figure 2, with resolver rotor r1 and the coaxial installation of rotor, Ur is the input of pumping signal, U1 and U2 are respectively the output of sinusoidal signal and cosine signal.
The sinusoidal excitation circuit adopts the modified model wien-bridge oscillator, and as shown in Figure 3, U34A and U34B constitute oscillating circuit, and U36A and U36B constitute emitter follower, and U35B, U37A and U37B constitute the circuit of output Refs-.The sinusoidal excitation signal Refs=(Refs+)-(Refs-) of output is 16kHz for frequency, the sine wave of peak value 5V.
The differential signal transducer is made of operational amplifier TL082, as shown in Figure 4, differential signal x-and x+ pass through the positive-negative input end that resistance R 3 and R4 receive operational amplifier, R1=R2=R3=R4 respectively, through obtaining single-ended signal x, x=(x-)-(x+) after the conversion.
Accurate absolute value adder as shown in Figure 5, signal x and signal y can finish accurate absolute value add operation after by operational amplifier U1A and U1B and peripheral circuit thereof, obtain signal z, z=|x+y|.
Inverter is very simple, constitute by an operational amplifier, circuit as shown in Figure 6, input signal x, R2=R3 output signal y, y=-x.
Low pass filter adopts the single order active filter, circuit as shown in Figure 7, bandwidth is arranged on 0~2kHz, x is an input signal, output signal y is the envelope signal of x.
The output signal of resolver can be nursed one's health into the low-frequency analog signal that digital signal processor can be discerned by above-mentioned hardware circuit, DSP uses the chip such as the TMS320F2812 of TMS320 series, the AD converter of DSP inside converts digital signal to the two-way analog signal sampling of input, just can finish detection to motor rotor position by the program that is solidificated in digital signal processor again.
Realize the exemplifying embodiment of the inventive method according to this device:
Step 1: the rotor coaxial of resolver and tested brushless electric machine is installed, and during the motor rotation, the differential signal of resolver secondary output two-way quadrature can obtain single-ended sinusoidal signal E by differential converter
s(t, θ)=Esin (ω t) sin (θ) and single-ended cosine signal E
c(t, θ)=Esin (ω t) cos (θ), wherein: E=5V, ω=16kHz; The scope of θ is 0~360 degree, and the value in the following steps goes on foot identical therewith;
Step 2: the sinusoidal differential signal Refs+ and the Refs-that are produced by the sinusoidal excitation circuit that will be input to resolver change single-ended reference signal-Refs=Esin (ω t) into;
Step 3: with signal E
s(t θ) superposes and obtains signal Refs+E with Refs
s(t, θ), with signal E
c(t θ) obtains signal Refs+E with the Refs stack
c(t, θ);
Step 4: with Refs+E
s(t, θ) and Refs+E
c(t, θ) HFS in carries out filtering, obtains comprising the simulation low frequency sinusoidal signal E of rotor position information
s(θ)=Esin (θ)+E and low frequency cosine signal E
c(θ)=Ecos (θ)+E, wherein E
s(θ) and E
cMaximum (θ) is 10V, and minimum value is 0V.
Step 5: with the low frequency sinusoidal signal E of simulation
s(θ)=Esin (θ)+E and cosine signal E
c(θ)=Ecos (θ)+E converts digital sine signal E to
s *(θ) with digital cosine signal E
c *(θ), E
s *(θ) get the corresponding E of 0~65535 integer
s0~10V (θ), E
c *(θ) get the corresponding E of 0~65535 integer
c0~10V (θ);
Step 6: the mean value U=32768 that asks for digital signal;
Step 7: with digital sine signal E
s *(θ) deduct U, obtain sinusoidal signal input variable Y, the Y scope is-32768~32767, with digital cosine signal E
c *(θ) deduct U, obtain cosine signal input variable X, the X scope is-32768~32767;
Step 8: judge motor rotor position place quadrant according to sinusoidal signal input variable Y and cosine signal input variable X:
When X 〉=0 and Y 〉=0, motor rotor position θ is positioned at first quartile;
When X<0 and Y 〉=0, motor rotor position θ is positioned at second quadrant;
When X<0 and Y<0, motor rotor position θ is positioned at third quadrant;
When X 〉=0 and Y<0, motor rotor position θ is positioned at four-quadrant;
Step 9: X, Y are mapped to first quartile, utilize cordic algorithm to calculate
angle value
Get 0~1023 integer and represent
angle 0~360 degree, then according to previous step rapid in the quadrant at θ place determine motor rotor position θ, θ gets 0~1023 integer and represent
angle 0~360 to spend:
When θ is positioned at first quartile, motor rotor position
When θ is positioned at second quadrant, motor rotor position
When θ is positioned at third quadrant, motor rotor position
When θ is positioned at four-quadrant, motor rotor position
When the resolver output signal broke down, the concrete steps that detect position of rotor of brushless motor were as follows:
Step a: the angle delta θ=ω that calculates motor rotation in the double sampling interval
rΔ T, wherein ω
rBe motor speed, unit is rad/s, and analog-to-digital sample frequency is f=100kHz, and the time interval of double sampling is Δ T=1/f=10us;
Step b: adopt the CORDIC inversion algorithms to obtain θ
GThe sine value E of=θ+Δ θ
SG *(θ
G) and cosine value E
CG *(θ
G), if
With
All do not exceed the limits of error, if
Exceed the limits of error, the sinusoidal signal of resolver output has fault; If
Exceed the limits of error, illustrate that then the cosine signal of resolver output has fault; The described limits of error gets 300, execution in step 4~5;
Step c: if
With
All exceed the limits of error, utilize the CORDIC inversion algorithms to obtain θ '
GThe sine value E of=θ-Δ θ
SG *(θ '
G) and cosine value E
CG *(θ '
G), if
Exceed the limits of error, the sinusoidal signal of resolver output has fault; If
Exceed the limits of error, illustrate that then the cosine of resolver output has fault; The described limits of error gets 300;
Steps d: if the sinusoidal signal of resolver output breaks down, with the digital cosine signal E of step 5
c *(θ), utilize E
c *(θ) and E
s *Orthogonality relation (θ) is converted to E
s *(θ), and with E
s *(θ) Alternative digital sinusoidal signal E
s *(θ); If the cosine signal of resolver output breaks down, with the digital sine signal E of step 5
s *(θ), utilize E
s *(θ) and E
c *Orthogonality relation (θ) is converted to E
c *(θ), and with E
c *(θ) Alternative digital cosine signal E
c *(θ);
Step e: continue step 6~9, obtain motor rotor position θ.