Tools needed for embedded induction motor control

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Tools needed for embedded induction motor control

1,290 Views
siua
Contributor II

This is a general product question. Since I can't email a customer service rep and its too late to call, I hope someone here can help. I am new to Freescale, and the embedded world as well. I am working on an application to create a custom motor controller for an variable speed 3 phase induction motor. I was brought here because the Kinetis motor control suite seemed to be a good solution. I am a little confused on what is needed to create a end product. I am understanding from the website that with their micro-controller and motor control software solution I can create the embedded controller (with the needed power electronics and inverter hardware as well of course). Given the Kinetis motor suite, what exactly is needed to create an embedded motor controller? In other words, which software tools do I need to create the end embedded motor control product using their micro-controllers? I am asking because looking at the motor suite and the MC_Toolbox seems essential, but at a price tag of $8000 it is more than my team can afford.

0 Kudos
4 Replies

705 Views
daveboyle
Contributor III

Hello Joshua:

       I'm also working on a 3-phase motor controller and here are some of the lessons I have learned. I hope these can help you.

  The Freescale only solution uses a tower board and a power inverter board. That rig was too expensive for me so I went with a FRDM-K64F mcu (very powerful - too much really) and an inverter board from STMicro. The Kinetis V series is meant for motor control, but the KE series will work as well and in fact most of the FRDM boards are powerful enough. My application has a strange demand: my synchronous motor must be phase locked to the zero crossings of the ac line. Originally I thought I would sample the ac line through a small step down transformer but after looking at the distorted stuff that comes through the line I opted for generating my own pure sine wave in software.

  I built a highly precise zero crossing detector with op amps and bring that signal to the mcu as an external interrupt. I used an optocoupler for that since the op amp swings to the ends of it's dual supply and my mcu is on a single supply. I also use 6 optocouplers to connect the pwm outputs over to the inverter board. Those igbt h-bridge circuits always raise everything up to their crazy high ac voltages so opto isolating is essential. I use high speed schmidt trigger type optocouplers that are meant for logic circuits. I tried some other photo transistor types but they distorted the signals like a big capacitor. A good oscilloscope is essential.

The software I use is the Kinetis Design Studio 3.0 with Processor Expert. It's baffling at first but once you learn a few hundred acronyms it's really quite powerful. I have the KSDK installed but have never used it. Here are some tips about the Processor Expert components. There is the high level PWM component and a lower level INIT_FTM. The PWM component gives you nice methods and properties that you will need but it won't let you access the fancy onboard hardware like complementary pairing and dead time insertion. You have to realize those things yourself in your software. The INIT_FTM component gives you a nice UI to select those things but it doesn't give you any methods for run time control. So you have to pick one for the things you want and use bare metal code to supply the things that are missing.

  The PWM components are tricky to set for high level logic. The init UI seems to offer you the choice between high and low but only low is available. That's the opposite of what my invertor wants to see so I used my optocouplers to invert the signals. The mcu sinks more current anyways so that worked out for the better. Most inputs and outputs on the mcu are low level logic. Keep your schematic and pinout diagram handy as you will refer to them a lot.

I use the PPG (Programmable Pulse Generator) component to schedule the changes in my PWM components because I can change the frequency of the PPG at run time. I don't know if this is the best approach and in fact my project isn't done yet and I'm at an impasse. I hope this helps and good luck to you!

705 Views
siua
Contributor II

Thank you for your input! You answered questions I didn't know I had yet.

0 Kudos

705 Views
mjbcswitzerland
Specialist V

Hello Joshua

Are there any application notes available for what you need to achieve? Eg. there are some for 3-phase sensorless control:

3-phase PMSM Sensorless Refere|Freescale

http://cache.freescale.com/files/32bit/doc/app_note/AN4862.pdf?fpsp=1

If there is such an application note for your requirements you may be able to use it directly.

I have integrated two such on KV parts as shown here:

µTasker Kinetis TWR-KV10Z32 support

µTasker Kinetis TWR-KV31F120M support

The KVs have either m0+ or M4 cores (and there should be an M7 one shortly). They include things like HW based square root calculation, often required for such control, which may allow a cheaper part to be used but can of course also be achived with a more powerful device clocked at faster speeds (or DSPs).

From my experience with such control it is based on high priority HW interrupts (time based or synchronised to signals) doing the algorithm calculation as efficiently as possible and feedback via PWM outputs. The kit that can be purchased contains various such algorithm implementations optimised to specific processors and will no doubt save development time. Whether such a kit is absolutely necessary depends on the complications involved and the experience avaiable - it probably contains a lot which you will not need for a single project.

I would first look around for an application note because it will probably already include the main code to do what you want and then get to known well the HW available and tweak it to get the most out of it in the specific implementation.

Regards

Mark

Kinetis: µTasker Kinetis support

KV10: µTasker Kinetis TWR-KV10Z32 support

KV31: µTasker Kinetis TWR-KV31F120M support

For the complete "out-of-the-box" Kinetis experience and faster time to market

705 Views
siua
Contributor II

Thank you for those references, Ill look more into the application notes.

0 Kudos