How do you detect the phase angle of BEMF?
lardom
Posts: 1,659
I'm studying sensorless BLDC motors and I plan to breadboard my own ESC as part of the learning process. I read that commutation should occur at the back-emf zero-crossing points. It seems pretty clear that the commutation instruction should execute somewhere before 180° and 360°. Moreover the speed of the motor demands that the execution of the commutation instruction be fine tuned. Is there a counter mode for this?.
Comments
Catching the zero crossing points can be a real challenge, and there is different ways to get there. I like the Mchip system because it uses a software comparing algorithm rather than hardware comparators. It works reasonably well for me in my application, although at super high electrical rpm its a bit tough. I run a 7 pole motor at up to 4500rpm which makes 31500 erpm. This requires close to a 30khz sampling rate to work properly.
Not sure if you can use a counter for this, probably some way.
MarkT was just on yesterday. I don't think he's been scared off...yet.
Test #1 - http://www.youtube.com/watch?v=s-T-zPbFwSg
Test #2 - http://www.youtube.com/watch?v=4tB_rH8evgc
The idea is to energize two coils at a time in proper sync and use the non energized coil for feedback.
In the video, this was just a proof of concept test and I'm only energizing 1 coil at a time (thus the reason for the kick start in rotation, which may not entirely be a bad feature to implement ... <- think old prop planes) the adjacent coil feeds a comparator providing an output signal to the Propeller. The Propeller in turn provides a properly timed pulse to turn on the Mosfet which drive the coil to move the motor ... and the process repeats.
So to answer the question within the title of this thread "How do you detect the phase angle of BEMF?" ... it can be done with a comparator connected to 2 of the three phases... you could use 3 comparators staggered among the phases to obtain a timing pulse from each phase.
Note: Keep in mind your mosfets need to handle current spikes in upwards of 190 Amps ! ... Yes, this is insane, but these are very brief pulses, and in order to create enough drive and motor torque, you need to be able to provide that kind of energy in very short bursts.
You mean like this?
http://www.mouser.com/Search/ProductDetail.aspx?R=STGE200NB60Svirtualkey51120000virtualkey511-STGE200NB60S
or MOSFET's only?
... Tim
@SRLM, Good thread, I'll subscribe to it. What are your formulas about?
BTW, I don't have an o'scope so I can't see hysteresis or the phase difference between voltage, current and magnetic flux so I'll be doing a lot of guessing. If I'm 'in the neighborhood' it'll be satisfactory. My goal is only to understand how it works.
That mosfet would seem overkill to me.
There is no code for the Hard Drive motor spin, it's all analog circuitry ... here is a link to the schematic and other info ... http://forums.parallax.com/showthread.php?119874-Hard-Drive-Stepper-Motor-with-high-speed-spin-up-circuit
The idea is the same though, although the Hard Drive motor uses far less current to operate.
Edit: Initially I used the same circuit for the Brush-less motors as I did with the Hard Drive motor. An all analog approach. What I found is that it did work, but my mosfets were getting extremely hot. Using the Propeller to condition the pulse to the mosfet (width and timing position) reduced the amount of heat generated by the mosfet significantly. It still could be done with a pure analog approach with careful design but it was much easier just to insert a Propeller in-line of the signal to produce a 'cleaner' signal to the gate of the mosfet and to keep the time spent in the linear operating region to a minimum.
Indeed! My technique was to use 3 comparators to determine cross-overs and they share common reference - IIRC I tried both using supply/2 and averaging the three phases to get the reference. Some LPF to reduce PWM noise before the comparators. One comparator left over from the LM339 quad comparator for future current-limit sense.
Prop code maintained some PID-like state to track phase (in other words feed back some of the error as phase correction, some as frequency correction). To lock rpm the PWM ratio was similarly controlled from the rpm error. I also believe my PWM scheme was different from the usual.
You need to be able to detect loss of lock, I think I settled with convolving the comparator outputs with the expected perfect 3-phase signals and detecting several cycles in a row with a below-threshold score - backing off to open-loop startup routine (more sophisticated method would be to try to determine current rpm and re-establish lock).
I should go back and look at what I ended up with and post more info about it in Projects forum: I got good behaviour eventually (although the startup open-loop phase needs tuning, I used tiny, medium and large motors for testing and never got all of them truly happy with same startup loop.