Running an AC Servo Motor from a propeller
n_ermosh
Posts: 294
I have an AC servo motor that I would like to build a controller for using a propeller. The motor is 24V and 2.1A, and I believe functions under the same principles as standard AC Induction motors. Is this possible? Essentially I need to generate 3 variable frequency waves between -12V and 12V. Ideally, they would be pure sine waves, but I'll start with plain square waves and work from there. I know for a DC motor, I would need an H-bridge, but does something like this exist for an AC motor? I know I can use an LC circuit with some transistors to generate the wave, but I can only get one frequency out of that.
Any help is appreciated
Any help is appreciated
Comments
PS - Should have added that VFD stands for Variable Frequency Driver.
Could you go into some detail about using half bridges? That was my first instinct too, but that will only give me a signal between 0 and 12V but I need to go down to -12V
It this context, you have three of them driving pulses that are 120 degrees apart in phase, or three phase.
You could use TIP120 and TIP125 Darlingtons for this these, but they would be a bit hot and would drop about 2 volts off the supply voltage that is driving the motor (So for a 24 volt motor, you would ideally want a 26volt supply).
To get around the heat and the voltage drops, manufacturers now prefer Power Mosfets.
It may be easiest to drive the three pairs of Power Mosfet in a final stage from conventional small transistors. Conventional transistors work well with the 3.3volt logic of the Propeller and can boost the control voltage up to a level that the Power MOSfets are operating well. Trying to design an all MOSfet solution might be a bit more tedious than it is worth.
I think you can use the half-bridge with a dual supply and have it swing from -12 to 12 to cover the 24 volt range. You might have a bit more complex front end and if you want sine wave, you may have to create it via PWM or another form of pulse modulation.
You can monitor speed with hall-effect sensors for feedback as the Propeller has enough cogs to do that as well.
The design process usually starts with the design of the final power stage, and then both ends of the design work toward resolving what is in the middle to make it work. A good power output stage is very important to a successful design.
There are complete 3 phase half-bridge MOSfet output stages that come as one chunk of IC, but they might be a bit difficult to buy in small quantity.
http://www.digikey.com/product-detail/en/DRV8312DDW/296-27707-5-ND/2355295
That chip may work. Depends on how your motor is wound and connected to the power.
This is the best I've found: http://www.yaskawa.com/site/dmservo.nsf/link2/MNEN-5CLKDZ/$file/SIE-S800-27.pdf
Here is an update to my experiments: I have the VFD that Yaskawa sells for the motors, but its big and bulky, which is why I want to scale it down. I got the motor running and connected 6 LEDs between the phases, in both polarities, so I can see the signal running through the phases. When running at a slow speed, I can clearly see 3 sine waves oscillating between the LEDs, offset by 120 phase degrees, between -12V and 12V. So this is a standard AC motor. Now, how do I replicate those 3 sine waves (I bet even square waves will work), using the propeller? The above chip appears to be just to be 3 half-bridges with current and thermal protection. Any ideas?
If you want nice smooth motion you will need to use 3 half bridges and a +-12V or 24V power supply.
The pseudo sine waves, do they use PWM to control the amplitude of the sine wave at time t? If so, sounds like all I need is 3 half bridges and some clever programming.
So something like 8 kHz, 16 kHz would be a good modulation frequency.
as for producing the sine waves, start out with just one PWM sine wave that you can adjust its frequency.
http://www.ti.com/product/drv8313
I seen TI showing that perfect sine wave is not needed and that a trapezoid is just fine.
Better than the only-3-levels ( +1 0 -1) cheap dc to ac converters do.
Hm. I'll start with square waves, and see where it goes. Will the 8312 or 8313 create trapezoid waves for me? Or will I have to use PWM to do it?
EDIT: I read the documentation, looks like both the 8312 and the 8313 are both essentially 3 half-bridges with current and temperature monitoring. I'm gonna order a few of these drivers and see what they do.
Thanks, I'll play with it when the drivers come in from Digikey. Is there any optimal slope for the trapezoid? And a 50% duty cycle on the PWM would be the 0 point of the wave, right?
to sense that the motor have made it to this deg and then you start energize the next 2/3 and so on.
http://www.ti.com/lit/ug/slvu815/slvu815.pdf
But for testing and slow speed without ramping of speed etc, you can just guestimate.
It was pretty simple to modify the sine table to actual sine wave (The one in the demo is optimized for visual efffect for the LEDs), and for 3 phases instead of eight. I modified the WaitCnt value to provide the desired drive frequency. Looks good on the 'scope.
I haven't explored the upper limit for the AC frequency yet (I have the PWM at 4 KHZ). I think I will need to do this in PASM ultimately. My next experiment will be with lowering the number of steps. My motor has a 1024 count encoder and I want to see how few sine steps I can get away with and still hold within a few counts once I get the control loop right.
And one more question, what state should the phases be to stop the motor? It's a fairly low inertia motor, so will just putting 0 on each phase work?
Pulling all 3 phases to 0V (gnd) will short them together and provide a rapid stop. If you need to stop at a precise position you need a controlled deceleration.
Yesterday, I hooked up a QuickStart board and wrote the wave generating object, using LEDs as my 3 "phases" I found that spin alone isn't fast enough to pulse faster than about 200 Hz, which limits my wave frequency to about 75 Hz, which may be fast enough for what I'm doing.
This is my current pulse code. one function call = 1 pulse. Can I create a similar function in PASM to call from spin?
BTW, what RPM are you trying to obtain?
I think you will have to do it in PASM, but it would probably be to have a variable that tells the pasm routine how quickly to step through a table of pulse widths to produce the waveform you want.
Can you give me any specific help to make that happen? I'm not that great with PASM.
I'm not sure what RPM I want yet, I haven't picked a stage, but I think my wave frequency will be between 100 mHz to the fastest the motor can handle.
A min of 0.1Hz is no problem. The maximum will depend on how many steps you need in the waveform to get smooth motion at all speeds.