Part Number Hot Search : 
2E334 RB160 4621CS SRF104 MBR1060 BZG03C15 ADT7463 VCO190
Product Description
Full Text Search
 

To Download DRM018 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  motorola.com/semiconductors 56800 hybrid controller DRM018/d rev. 0, 03/2003 using 56f805 designer reference manual torque vector control synchronous motor 3-phase pm f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola 3 3-phase pm synchronous motor torque vector control using 56f805 designer reference manual ? rev. 0 by: peter balazovic motorola czech s ystem laboratories roznov pod radhostem, czech republic f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
revision history designer reference manual DRM018 ? rev. 0 4 motorola to provide the most up-to-date info rmation, the re vision of our documents on the world wide web will be the most current. your printed copy may be an earlier revision. to veri fy you have the latest information available, refer to: http://www.motorol a.com/semiconductors the following revision history table summarizes cha nges contained in this document. for your conven ience, the page number designators have been linked to the appropriate location. revision history date revision level description page number(s) january 2003 1 initial release n/a f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola 5 designer reference manual ? 3-ph . pmsm torque vector control list of sections section 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 section 2. target motor theory . . . . . . . . . . . . . . . . . . . . 19 section 3. system description. . . . . . . . . . . . . . . . . . . . . 35 section 4. hardware design. . . . . . . . . . . . . . . . . . . . . . . 53 section 5. software design . . . . . . . . . . . . . . . . . . . . . . . 63 section 6. system setup . . . . . . . . . . . . . . . . . . . . . . . . . 87 appendix a. references. . . . . . . . . . . . . . . . . . . . . . . . . 103 appendix b. glossary. . . . . . . . . . . . . . . . . . . . . . . . . . . 105 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
list of sections designer reference manual DRM018 ? rev. 0 6 motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola 7 designer reference manual ? 3-ph . pmsm torque vector control table of contents section 1. introduction 1.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .13 1.2 application benefit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 1.3 motorola dsp advantages and features . . . . . . . . . . . . . . . . . 14 section 2. target motor theory 2.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .19 2.2 permanent magnet synchro nous motor . . . . . . . . . . . . . . . . . . 19 2.3 mathematical descript ion of pm synchronous motor. . . . . . . . 20 2.4 digital control of pm synchronous mo tor. . . . . . . . . . . . . . . . . 26 section 3. system description 3.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .35 3.2 system specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 3.3 vector control drive concept . . . . . . . . . . . . . . . . . . . . . . . . . . 36 3.4 system blocks concept . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 section 4. hardware design 4.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .53 4.2 hardware set-up. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 4.3 dsp56f805evm controller board . . . . . . . . . . . . . . . . . . . . . . 55 4.4 3-ph bldc low voltage po wer stage . . . . . . . . . . . . . . . . . . . 57 4.5 motor-brake specif ications. . . . . . . . . . . . . . . . . . . . . . . . . . . .59 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
table of contents designer reference manual DRM018 ? rev. 0 8 motorola 4.6 hardware documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 section 5. software design 5.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .63 5.2 main software flow chart . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 5.3 data flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 5.4 state diagram. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 5.5 scaling of quantities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81 5.6 pi controller tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86 5.7 subprocesses relation and state transitions . . . . . . . . . . . . . 86 section 6. system setup 6.1 contents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .87 6.2 application description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 6.3 application set-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 6.4 projects files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .97 6.5 application build & execute . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 6.6 warning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100 appendix a. references appendix b. glossary f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola 9 designer reference manual ? 3-ph . pmsm torque vector control list of figures figure title page 2-1 pm synchronous motor - cross section. . . . . . . . . . . . . . . . . . 19 2-2 stator current space ve ctor and its projection . . . . . . . . . . . . 21 2-3 application of the general referenc e frame . . . . . . . . . . . . . . 24 2-4 3- phase inverter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 2-5 pulse width modulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 2-6 block diagram of pm synchronous motor vector control . . . . 29 2-7 clarke transformation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .30 2-8 establishing the d-q coordinate system (park transformation). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 2-9 normal operation and field-weakening . . . . . . . . . . . . . . . . . 34 3-1 drive concept . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 3-2 quadrature encoder signals . . . . . . . . . . . . . . . . . . . . . . . . . . 39 3-3 quad timer module a conf iguration . . . . . . . . . . . . . . . . . . . . 40 3-4 speed processing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .42 3-5 rotor alignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 3-6 rotor alignment fl ow chart . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 3-7 current shunt resistors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 3-8 current amplifier. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 3-9 time diagram of pwm and adc sync hronization . . . . . . . . . . 48 3-10 voltage shapes of tw o different pwm periods . . . . . . . . . . . . 49 3-11 3-phase sinewave volt ages and corresponding sector value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 3-12 temperature sensing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 4-1 high-voltage hardware system config uration . . . . . . . . . . . . . 54 4-2 block diagram of the dsp56f805evm . . . . . . . . . . . . . . . . . . 57 4-3 block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 5-1 software flow chart - g eneral overview i . . . . . . . . . . . . . . . . 65 5-2 software flow chart - adc interrupt . . . . . . . . . . . . . . . . . . . . 66 5-3 software flow chart - pwm a fault interrupt. . . . . . . . . . . . . . 67 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
list of figures designer reference manual DRM018 ? rev. 0 10 motorola 5-4 s/w flow chart - general overview. . . . . . . . . . . . . . . . . . . . .68 5-5 data flow - part 1. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .69 5-6 data flow - part 2. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .70 5-7 data flow - pmsm cont rol - current control . . . . . . . . . . . . . . 73 5-8 state diagram - applicat ion control . . . . . . . . . . . . . . . . . . . . .76 5-9 state diagram - pmsm control . . . . . . . . . . . . . . . . . . . . . . . .78 5-10 state diagram fault control . . . . . . . . . . . . . . . . . . . . . . . . . . . 80 5-11 state diagram - analog se nsing . . . . . . . . . . . . . . . . . . . . . . . 81 6-1 run/stop switch and up/down buttons at dsp56f805evm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 6-2 user and pwm leds at dsp56f805evm. . . . . . . . . . . . . . . 91 6-3 pc master software control window . . . . . . . . . . . . . . . . . . . . 93 6-4 set-up of the 3-phase pm synchr onous motor control application using dsp56f805evm. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 6-5 dsp56f805evm jumper reference . . . . . . . . . . . . . . . . . . . . 96 6-6 target build selection. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 6-7 execute make command . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola 11 designer reference manual ? 3-ph . pmsm torque vector control list of tables table title page 1-1 memory configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .15 3-1 high voltage hardware se t specifications . . . . . . . . . . . . . . . . 36 4-1 electrical chatacteri stics of the 3-ph bldc low voltage power stage . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 4-2 motor - brake specificati ons. . . . . . . . . . . . . . . . . . . . . . . . . . . 60 6-1 motor--brake specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . 88 6-2 motor application states. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92 6-3 dsp56f805evm jumper sett ings . . . . . . . . . . . . . . . . . . . . . . 96 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
list of tables designer reference manual DRM018 ? rev. 0 12 motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola introduction 13 designer reference manual ? 3-ph . pmsm torque vector control section 1. introduction 1.1 contents 1.2 application benefit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 1.3 motorola dsp advantages and features . . . . . . . . . . . . . . . . . 14 1.2 application benefit this reference design manual describes the design of a 3-phase permanent magnet (pm) synchronous motor torque vector control based on motorola?s dsp56f805 dedicated motor control device. pm synchronous motors are very p opular in a wide application area. the pm synchronous motor lacks a commut ator and is therefore more reliable than the dc motor. the pm synchronous motor also has advantages when compared to an ac in duction motor. because a pm synchronous motor achieves higher ef ficiency by generating the rotor magnetic flux with rotor magnets, a pm synchronous motors is used in high-end white goods (such as re frigerators, wa shing machines, dishwashers); high-end pumps; fans ; and in other appliances which require high reliab ility and efficiency. the concept of the application is a close-loop pm synchronous drive using a vector control technique. this reference design in cludes basic motor th eory, system design concept, hardware implementation and software design, including the pc master software visualization tool. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
introduction designer reference manual DRM018 ? rev. 0 14 introduction motorola 1.3 motorola dsp ad vantages and features the motorola dsp56f80x family is well suited for digita l motor control, combining a dsp?s com putational ability with an mcu?s controller features on a single chip. these d sps offer many dedicated peripherals like a pulse width modulation (pwm) unit, analog-to-digital converter (adc), timers, communications periphe rals (sci, spi, can), on-board flash and ram. generally , all family members are well-suited for pm synchornous motor control. one typical member of the fami ly, the dsp56f805, provides the following peripheral blocks:  two pulse width modulator modules (pwma & pwmb), each with six pwm outputs, three curr ent sense inputs, and four fault inputs; fault tolerant design with deadtime insertion; supports both center- and edge- aligned modes  twelve bit, analog to digital converters (adcs), supporting two simultaneous conversions with dual 4-pin mult iplexed inputs; the adc can be synch ronized by pwm  two quadrature decoders (quad de c0 & quad dec1), each with four inputs, or two addi tional quad timers a & b  two dedicated general purpose quad timers totaling 6 pins: timer c with 2 pins and timer d with 4 pins  can 2.0 a/b module with 2-pin po rts used to transmit and receive  two serial communication interfac es (sci0 & sci1), each with two pins, or four additional gpio lines  serial peripheral interf ace (spi), with confi gurable 4-pin port, or four additional gpio lines  computer operating proper ly (cop) watchdog timer  two dedicated exter nal interrupt pins  fourteen dedicated general pu rpose i/o (gpi o) pins, 18 multiplexed gpio pins  external reset pin for hardware reset  jtag/on-chip emulation (once) f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
introduction motorola dsp advantages and features DRM018 ? rev. 0 designer reference manual motorola introduction 15  software-programmable, phas e lock loop-based frequency synthesizer for the dsp core clock the most interesting pe ripherals, from the pm synchronous motor control point of view, are the fast analog-to-digital converter (adc) and the pulse-width-modul ation (pwm) on-chip modules. they offer extensive freedom of configuration, enabling efficient control of sr motors. the pwm module incorporates a pwm generator, enabling the generation of control si gnals for the motor power stage. the module has the following features:  three complementary pwm signal pairs, or six independent pwm signals  complementary channel operation  deadtime insertion  separate top and bottom pulse width correction via current status inputs or software  separate top and bottom polarity control  edge-aligned or ce nter-aligned pwm signals  15 bits of resolution  half-cycle reload capability  integral reload rates from one to 16  individual software-controlled pwm output table 1-1. memory configuration dsp56f801 dsp56f803 d sp56f805 dsp56f807 program flash 8188 x 16-bit 32252 x 16-bit 32252 x 16-bit 61436 x 16-bit data flash 2k x 16-bit 4k x 16-bit 4k x 16-bit 8k x 16-bit program ram 1k x 16-bit 512 x 16-bit 512 x 16-bit 2k x 16-bit data ram 1k x 16-bit 2k x 16-bit 2k x 16-bit 4k x 16-bit boot flash 2k x 16-bit 2k x 16-bit 2k x 16-bit 2k x 16-bit f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
introduction designer reference manual DRM018 ? rev. 0 16 introduction motorola  programmable fault protection  polarity control  20ma current sink c apability on pwm pins  write-protectable registers the pm synchronous motor control util izes the pwm block set in the complementary pwm mode , permitting generation of control signals for all switches of the power stage with inserted deadtime. the pwm block generates three sinewave outputs mutually shifted by 120 degrees. the analog-to-digital converter (adc) consists of a digital control module and two analog sample and hol d (s/h) circuits. it has the following features:  12-bit resolution  maximum adc clock frequency is 5mhz with 200ns period  single conversion time of 8.5 adc clock cycles (8.5 x 200 ns = 1.7 s)  additional conversion time of 6 adc clock cycles (6 x 200 ns = 1.2 s)  eight conversions in 26.5 adc clock cycl es (26.5 x 200 ns = 5.3 s) using simultaneous mode  adc can be synchronized to the pwm via the sync signal  simultaneous or sequential sampling  internal multiplexer to se lect two of eight inputs  ability to sequentially scan and store up to eight measurements  ability to simultaneously sa mple and hold two inputs  optional interrupts at end of sc an at zero crossing or if an out-of-range limit is exceeded  optional sample correction by subtracting a pre-programmed offset value  signed or unsigned result  single ended or di fferential inputs f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
introduction motorola dsp advantages and features DRM018 ? rev. 0 designer reference manual motorola introduction 17 the application utilizes t he adc on-chip module in simultaneous mode and sequential scan. the sampling is synchronized with the pwm pulses for precise sampling and recons truction of phase currents. such a configuration allows in stant conversion of the desired ana log values of all phase currents, vo ltages and temperatures. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
introduction designer reference manual DRM018 ? rev. 0 18 introduction motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola target motor theory 19 designer reference manual ? 3-ph . pmsm torque vector control section 2. target motor theory 2.1 contents 2.2 permanent magnet synchro nous motor . . . . . . . . . . . . . . . . . . 19 2.3 mathematical descript ion of pm synchronous motor. . . . . . . . 20 2.4 digital control of pm synchronous mo tor. . . . . . . . . . . . . . . . . 26 2.2 permanent magnet synchronous motor the pm synchronous motor is a rotati ng electric machine with a classic 3-phase stator like that of an induction motor; the rotor has surface-mounted pe rmanent magnets (see figure 2-1 ). figure 2-1. pm synchronous motor - cross section stator stator winding (in slots) shaft rotor air gap permanent magnets f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 20 target motor theory motorola in this respect, the pm synchronous motor is equivalent to an induction motor, where the air gap magnetic field is pr oduced by a permanent magnet, so the rotor magnet ic field is constant. pm synchronous motors offer a number of advantages in designing modern motion control systems. the use of a permanent magn et to generate substantial air gap magnetic flux makes it possible to design highly efficient pm motors. 2.3 mathematical descriptio n of pm synchronous motor the model used for vector control design can be understood by using space vector theory. the three- phase motor quanti ties (such as voltages, currents, magnetic flux, etc.) are expressed in terms of complex space vectors. such a mo del is valid for any instantaneous variation of voltage and curr ent and adequately describes the performance of the machine under both steady-state and transient operation. the complex space vector s can be described using only two orthogonal axes. we can look at the motor as a two-phase machine. using a two-phase motor model reduc es the number of equations and simplifies the control design. 2.3.1 space vector definition assume i sa , i sb , i sc are the instantaneous bal anced three-phase stator currents: (eq 2-1.) then we can define the stator curr ent space vector as follows: (eq 2-2.) where a and a 2 are the spatial operators, a = e j2 /3 , a 2 = e j4 /3 and k is the transformation constant, chosen as k=2/3 . figure 2-2 shows the stator current space vector projection: i sa i sb i sc 0 = ++ i s k =i sa ai sb a 2 i sc ++ () , , . , . . . . .
target motor theory mathematical description of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 21 figure 2-2. stator current space vector and its projection the space vector defined by (eq 2-2.) can be expressed utilizing two-axis theory. the r eal part of the space ve ctor is equal to the instantaneous value of the direct -axis stator cu rrent component, i s , and whose imaginary part is equal to the quadrature-axis stator current component, i s . thus, the stator current sp ace vector, in the stationary reference frame attached to t he stator can be expressed as: (eq 2-3.) in symmetrical three-phase machines , the direct and quadrature axis stator currents i s , i s are fictitious quadrat ure-phase (two-phase) i s phase- b i s i s ji s + = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 22 target motor theory motorola current components, whic h are related to the ac tual three-phase stator currents as follows: (eq 2-4.) (eq 2-5.) where k=2/3 is a transformation constant. the space vectors of other motor quantities (voltages, currents, magnetic fluxes etc.) ca n be defined in the same way as the stator current space vector. for a description of the pm synchronous motor, the symmetrical three-phase smooth-air- gap machine with sinusoi dally-distributed windings is considered. the volt age equations of stator in the instantaneous form can then be expressed as: (eq 2-6.) (eq 2-7.) (eq 2-8.) where u sa , u sb and u sc are the instantaneous values of stator voltages, i sa , i sb and i sc are the instantaneous values of stator currents, and sa , sb , sc are instantaneous values of stat or flux linkages, in phase sa, sb and sc. due to the large number of equations in the instantaneous form, the equations (eq 2-6.) , (eq 2-7.) and (eq 2-8.) , it is more practical to i s ki sa 1 2 -- -i sb ? 1 2 -- -i sc ? ?? ?? = i s k 3 2 ------ -i sb i sc ? () = u sa r s i sa t d d sa + = u sb r s i sb t d d sb + = u sc r s i sc t d d sc + = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory mathematical description of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 23 rewrite the instantaneous equations using two axis theory (clarke transformation). the pm synchron ous motor can be expressed as: (eq 2-9.) (eq 2-10.) (eq 2-11.) (eq 2-12.) (eq 2-13.) where: , is the stator orthogonal coordinate system u s , is the stator voltage i s , is the stator current s , is the stator magnetic flux m is the rotor magnetic flux r s is the stator phase resistance l s is the stator phase inductance / f is the electrical rotor speed / fields speed p is the number of poles per phase j is the inertia t l is the load torque r is the rotor position in , coordinate system the equations (eq 2-9.) through (eq 2-13.) represent the model of pm synchronous motor in the stationary frame , fixed to the stator. besides the stationary reference fr ame attached to t he stator, motor model voltage space vector equations can be formulated in a general reference frame, which ro tates at a gen eral speed g . if a general reference frame is used, wi th direct and quadrature axes x,y rotating at a general instantaneous speed g =d g /d t , as shown in figure 2-3 , where g is the angle between the direct ax is of the stati onary reference u s r s i s t d d s + = u s r s i s t d d s + = s l s i s m r () cos + = s l s i s m r () sin + = t d d p j -- - 3 2 -- -p s i s s i s ? () t l ? = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 24 target motor theory motorola frame ( ) attached to the stator and the real axis ( x ) of the general reference frame, then (eq 2-14.) defines the stator current space vector in general reference frame: (eq 2-14.) figure 2-3. application of the general reference frame the stator voltage and flux-linkage space vect ors can be similarly obtained in the general reference frame. similar considerations ho ld for the space vectors of the rotor voltages, currents and flux linkages. the real axis (r ) of the reference frame attached to the rotor is displaced from the direct axis of the stator reference frame by the rotor angle r. since it can be s een that the angle between the real axis ( x ) of the general reference frame and the real axis of the reference frame ro tating with the rotor (r ) is g - r , in the general reference frame, the spac e vector of the rotor currents can be expressed as: (eq 2-15.) i sg i s e j g ? i sx ji sy + = = x y g i rg i r e j g r ? () ? i rx ji ry + = = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory mathematical description of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 25 where is the space vector of the rotor current in the rotor reference frame. the space vectors of the rotor volt ages and rotor flux linkages in the general reference frame can be similarly expressed. the motor model voltage eq uations in the general reference frame can be expressed by utilizing introduc ed transformations of the motor quantities from one refer ence frame to the general reference frame. the pm synchronous motor mode l is often used in vector control algorithms. the aim of vector cont rol is to implement control schemes which produce high dynamic performance a nd are similar to those used to control dc machines. to achieve th is, the reference frames may be aligned with the stat or flux-linkage space vect or, the rotor flux-linkage space vector or the magnetizi ng space vector. the most popular reference frame is the reference fram e attached to the rotor flux linkage space vector, with direct axis ( d ) and quadrature axis ( q ). after transformation into d-q coordinates, the mo tor model as follows: (eq 2-16.) (eq 2-17.) (eq 2-18.) (eq 2-19.) (eq 2-20.) by considering that below base speed i sd =0 , the equation (eq 2-20.) can be reduced to t he following form: (eq 2-21.) i r u sd r s i sd t d d sd f sq ? + = u sq r s i sq t d d sq f sd ++ = sd l s i sd m + = sq l s i sq = t d d p j -- - 3 2 -- -p sd i sq sq i sd ? () t l ? = t d d p j -- - 3 2 -- -p m i sq () t l ? = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 26 target motor theory motorola from the equation (eq 2-21.) , it can be seen t hat the torque is dependent and can be directly controlled by the current i sq only. it is obvious to obtain pm synchornous motor torque eqaution as follwos: (eq 2-22.) 2.4 digital control of pm synchronous motor usually the applications of the pm synch ronous motors are powered by inverters. the inverter converts dc power to ac power at the required frequency and amplitude. the typical 3-phase inverter is illustrated in figure 2-4 . figure 2-4. 3- phase inverter the inverter consists of three hal f-bridge units where the upper and lower switches are controlled comple mentarily, meaning when the upper one is turned on, the lower one must be turned off, a nd vice versa. because the power device?s turn off ti me is longer than its turn on time, some deadtime must be in serted between the turn off of one transistor of the half-bridge, and the turn on of its complementary device. the t e 3 2 -- -p m i sq () = q1 pwm_q5 q6 q4 c1 phase_c pwm_q1 pwm_q4 pwm_q3 phase_b gnd q2 u dcb pwm_q2 phase_a q3 pwm_q6 q5 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory digital control of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 27 output voltage is mostly created by a pulse width modulation (pwm) technique, where an isosceles triangle ca rrier wave is compared with a fundamental-frequency sine modulating wa ve, and the natural points of intersection determine the switching poi nts of the power devices of a half bridge inverter. this te chnique is shown in figure 2-5 . the 3-phase voltage waves are shifted 120 o to each other and, thus, a 3-phase motor can be supplied. figure 2-5. pulse width modulation the most popular power devices for motor control applications are power mosfets and igbts. a power mosfet is a voltage-contro lled transistor. it is designed for high-frequency operation and has a low voltage drop ; thus, it has low power losses. however, the saturation temperatur e sensitivity limits the mosfet application in high-power applications. an insulated-gate bipolar transisto r (igbt) is a bipolar transistor controlled by a mosfet on its ba se. the igbt requires low drive current, has fast switching time, and is suitable for high switching pwm carrier wave generated sine wave pwm output t 1 (upper switch) 0 1 0 1 pwm output t 2 (lower switch) 1 0 -1 t t f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 28 target motor theory motorola frequencies. the disadv antage is the higher volt age drop of a bipolar transistor, causing higher conduction losses. 2.4.1 vector contro l of pm synchronous motor vector control is an elegant control method of a pm synchronous motor, where field-oriented theory is used to control space vect ors of magnetic flux, current, and voltag e. it is possible to se t up the coordinate system to decompose the vector s into a magnetic fi eld-generating part and a torque-generating part. the structure of the motor controller (vector control controller) is then almost the same as for a separately-excited dc motor, which simplifie s the control of pm syn chronous motor. this vector control techniqu e was developed specifically to achieve a similarly dynamic performance in pm synchronous motors. as explained in 3.3 vector cont rol drive concept , there is chosen a torque control with inner current closed-loop, w here the rotor flux is considered as zero input. this method is broken down ont o the field-generating and torque-generating pa rts of the stator current to be ab le to separately control the magnetic flux and the tor que. in order to do so, we need to set up the rotary coordinate system connected to the rotor magnetic field; this system is g enerally called a ?d-q coordinate system?. very high cpu performance is needed to perform the transform ation from rotary to stationary coordinate systems. theref ore, the motorola dsp56f80x is very well suited for use in a vector control algorithm. a ll transformations which are needed for vector control wi ll be described in the next section. 2.4.2 block diagram of vector control figure 2-6 shows the basic st ructure of vector control of the pm synchronous motor. to perform vector control, follow these steps:  measure the motor quantities (phase voltages and currents)  transform them into the two-phase system ( , ) using clarke transformation  calculate the rotor flux space vector magnitu de and position angle f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory digital control of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 29  transform stator cu rrents into the d-q c oordinate system using park transformation  the stator current torque- ( i sq ) and flux- ( i sd ) producing components are controlled separ ately by the controllers  the output stator voltage space ve ctor is calculated using the decoupling block  the stator voltage space vector is transformed back from the d-q coordinate system into the tw o-phase system and fixed with the stator by inverse park transformation  using sinewave modulation, t he output 3-phase voltage is generated figure 2-6. block diagram of pm synchronous motor vector control 2.4.3 vector cont rol transformations transforming the pm syn chronous motor into a dc motor is based on points of view. as shown in 2.4.2 block diagram of vector control , a coordinate transformation is required. 3-phase power stage position/spee d se n so r pmsm motor sinewave generation forward clarke transformation forward park transformation decoupling i s i s i sq i sd u u u u u sd sd_lin sq_lin s s u sq i i i sa sb sc - - to r q u e command line input position pwm a pwm b pwm c flux command f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 30 target motor theory motorola the following transformations are involved in vector control:  transformations from a 3-phas e to a 2-phase system (clarke transformation)  rotation of orthogonal system ? , to d-q (park transformation) ? d-q to , (inverse park transformation) 2.4.3.1 clarke transformation figure 2-7 shows how the three-phase syst em is transformed into a two-phase system. figure 2-7. clarke transformation , phase-a i s i s i s i sa - measured i sb - measured i sc - calculated phase- b phase- c f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory digital control of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 31 to transfer the graphical representa tion into mathematical language: (eq 2-23.) in most cases, the 3-pha se system is symmetrical , which means that the sum of the phase quantities is always zero. (eq 2-24.) the constant ? k ? can be freely chosen and equalizing the -quantity and a-phase quantity is recommended. then: (eq 2-25.) we can fully define the pa rk-clarke transformation: (eq 2-26.) 2.4.3.2 transfo rmation from , to d-q coordinates and backwards vector control is perfo rmed entirely in the d- q coordinate system to make the contro l of pm synchronous motors elegant and easy; see 2.4.2 block diagram of vector control . of course, this requires transformati on in both directions and the control action must be transformed back to the motor side. k 1 1 2 -- - ? 1 2 -- - ? 0 3 2 ------ - 3 2 ------ - ? a b c = ka 1 2 -- -b ? 1 2 -- -c ? ?? ?? abc ++ 0 =k 3 2 -- -a == = a =k 2 3 -- - = ? 2 3 -- - 1 3 -- - ? 1 3 -- - ? 0 1 3 ------ - 1 3 ------ - ? a b c abc ++ 0 = 100 0 1 3 ------ - 1 3 ------ - ? a b c === f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 32 target motor theory motorola first, establish the d-q coordinate system: (eq 2-27.) (eq 2-28.) then transform from , to d-q coordinates: (eq 2-29.) figure 2-8 illustrates this transformation. figure 2-8. establishing t he d-q coordinate system (park transformation) m m m + = ? field sin m md ---------- - = ? field cos m md ----------- = d q ? field cos ? field sin ? field sin ? ? field cos = m ? field m m q d f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory digital control of pm synchronous motor DRM018 ? rev. 0 designer reference manual motorola target motor theory 33 the backward (inverse park) tr ansformation (from d-q to ,) is: (eq 2-30.) 2.4.4 pmsm vector control this section describes the control re garding the requir ed stator current vectors i sd , i sq . there are two speed ranges (shown in figure 2-9 ), which differ by controlled current vector:  control in normal operating r ange is a control mode for a speed required below nominal motor speed  control in field-weakening range is a control m ode for a speed required above nominal motor speed. this application does not utilize control in field-weakening range. 2.4.4.1 control in normal operating range assume an ideal pm synchronous motor with constant st ator reluctance, l s = const. the equations (eq 2-17.) , (eq 2-18.) and (eq 2-19.) can then be written as: (eq 2-31.) as demonstrated from pm synchr onous motor equations, the maximum efficiency of the ideal pm synchronous mo tor is obtained when maintaining the current flux-producing component i sd at zero. therefore, in the drive from figure 2-6 , the field-weakeni ng controller sets i sd = 0 in the normal operating range. the torq ue regulator cont rols the current torque-produci ng component i sq . a real 3-phase power invert er has voltage and curr ent rating limitations: 1. the absolute value of stator voltage u s is physically limited according to dcbus voltage to u_sdq_max limit ? field cos ? field sin ? ? field sin ? field cos d q = u sq r s i sq l s t d d i sq f l s i sd m + () ++ = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
target motor theory designer reference manual DRM018 ? rev. 0 34 target motor theory motorola 2. the absolute value of the stator current i s should be maintained below a limit of i_sdq_max given by the maximum current rating in the normal operati ng range, the current to rque-producing component i sq can be set up to i_sdq_max , since i sd = 0. due to the voltage limitation, the maximum speed in the normal motor operating range is limited for i sd = 0, to a nominal motor speed as shown in figure 2-9 and (eq 2-31.) . figure 2-9. normal oper ation and field-weakening field weakenning range speed nominal speed stator voltage u s stator current i d u_sdq_max 0 normal operating range f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola system description 35 designer reference manual ? 3-ph . pmsm torque vector control section 3. system description 3.1 contents 3.2 system specification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 3.3 vector control drive concept . . . . . . . . . . . . . . . . . . . . . . . . . . 36 3.4 system blocks concept . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 3.2 system specification the motor control system is de signed to drive a 3-phase pm synchronous motor in a closed-loop of torque-generating part of current i sq . the application meets the foll owing performance specifications:  torque vector control of pm mo tor using the quadrature encoder as a position sensor  targeted for dsp56f805evm  running on a 3-phase low-volat ge pm synchronous motor control development platform at 12 dc  control technique incorporates: ? vector control with torque-g enerating part of current i sq ? rotation in both directions ? motoring and generat or mode with brake ? start from any motor po sition with rotor alignment  manual interface (start/stop swit ch, up/down push button control, led indicator)  pc master software control in terface (motor start/stop, speed set-up) f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 36 system description motorola  pc master software remote monitor  power stage boar d identification  overvoltage, undervo ltage, overcurrent and overheating fault protection the pm synchronous driv e introduced here is designed to power a high-voltage pm synchronous moto r with a quadrature encoder. it has the following specifications: 3.3 vector cont rol drive concept a standard system concept is used with this drive; see figure 3-1 . the system incorporates the following hardware parts:  three-phase pm synchronous mo tor high-voltage development platform  feedback sensors for: ? position (quadrature encoder) ? dcbus voltage table 3-1. high voltage ha rdware set specifications motor characteristics: motor type 6 poles, 3-phase, star connected, bldc motor speed range 3000 rpm (at 12v) maximum electrical power: 150 w phase voltage 3*6.5 v phase current 17 a drive characteristics: speed range < 3000 rpm input voltage 12v dc maximum dcbus voltage 15.8 v control algorithm torque closed-loop control optoisolation required f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description vector control drive concept DRM018 ? rev. 0 designer reference manual motorola system description 37 ? phase currents ? dcbus overcurrent detection ? temperature  the dsp56f805 evaluation module the drive can be controlled in two different operational modes: in the manual operational mode, the required speed is set by the start/stop switch and t he up/down push buttons. in the pc master software operational mode, t he required speed and start/stop switch ar e set by the pc. figure 3-1. drive concept f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 38 system description motorola the control process is as follows: when the start command is accepted (using the start/stop switch or pc master software command), the r equired torque gen erating part of current is calculated according to the up/down push buttons or pc master software comm ands. the required tor que generating part of current reference command is put to the current controller. the comparison between the required torq ue generating pa rt of current command and the actual m easured current generates a current error. based on the error, t he current controller generates a volatge, us_qreq. a second part of stator current is_dreq , which corresponds to flux might be given by the field-w eakening controller but in this application is considered as zero current. simultaneously, the stator currents is_a , is_b, and is_c are measured and transfo rmed from instantaneous values into the stationary reference frame , , and consecutively into the rotary reference frame d-q (par k - clarke transfo rmation). based on the errors between requir ed and actual currents in the rotary reference frame, the current controlle rs generate output voltages us_q and us_d (in the rotary reference frame d-q). the voltages us_q and us_d are transformed back into the st ationary reference frame , and, after dcbus ripple elimination, are re calculated to t he 3-phase voltage system, which is applied to the motor. th e actual speed is calculated from the pulses of the quadrature encoder. beside the main control loop, the dcbus voltag e, dcbus cu rrent and power stage temperature are measured during the control process. they are used for overvoltage, undervo ltage, overcurrent and overheating protection of the drive. the undervoltage and ov erheating protection is performed by software, while the ov ercurrent and ov ervoltage fault signal utilizes a faul t input of the dsp. if any of the previously-mentioned f aults occur, the motor control pwm outputs are disabled in orde r to protect the drive, and the fault state of the system is display ed by the on-board led. a hardware error is also detected if the wrong power stage is used. each power stage contains a simple module generating a logic sequence unique for that type of pow er stage. during chip initialization, this sequence is read and evalua ted according to the decoding table. if the correct power stage is identified, t he program can continue. in the case f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 39 of wrong hardware, the program stays in an infinite loop, displaying the fault condition. 3.4 system blocks concept 3.4.1 position and speed sensing all members of motorola?s dsp 56f80x family, exc ept the dsp56f801 device , have a quadrature decoder. this peripheral is commonly used for position and spee d sensing. the quadr ature decoder position counter counts up/down each edge of phase a and phase b signals according to their order. on each revolution, the position counter is cleared by an index pulse; see figure 3-2 . figure 3-2. quadrat ure encoder signals this means that the zero position is linked with the index pulse, but vector control requires the zero posi tion, where the roto r is aligned to the d axis; see 3.4.1.4 position reset with rotor alignment . therefore, using a quadrature decode r to decode the encoder?s signal requires either the calc ulation of an offset wh ich aligns the quadrature decoder position counter wi th the aligned rotor po sition (zero position), or the coupling of the zero rotor position with the in dex pulse of a quadrature encoder. to avoid the calcul ation of the rotor position offset, the quadrature decoder is not used in th is application. the decoder?s digital processing capabilities are then free to be used by another application and the application pres ented can then run on the dsp56f801, which lacks a quadrature decoder. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 40 system description motorola in addition to th e quadrature decoder , the input signal s (phase a, phase b and index) are connected to quad timer module a. the quad timer module consists of four quadrature ti mers. due to the wide variability of quad timer modules, it is possibl e to use this module to decode quadrature encoder signals, sense posi tion, and speed. a configuration of the quad timer m odule is shown in figure 3-3 . figure 3-3. quad timer m odule a configuration 3.4.1.1 position sensing the position and speed sens ing algorithm uses al l of the timers in module a and an additional ti mer as a time base. ti mers a0 and a1 are used for position sensing. timer a0 permits con nection of three input signals to the quadrature timer a1, ev en if timer a1 has only two inputs (primary and secondary), accomp lished by using timer a0 as a quadrature decoder only. it is set to count in th e quadrature mode, count to zero, and then reinitialize. th is timer setting is used to decode f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 41 quadrature signals only. timer a1 is connected to timer a0 in cascade mode. in this mode, the information about counting up/down is connected internally to timer a1; thus , the secondary input of timer a1 is free to be used for the index pulse. the counter a1 is set to count to +/- ((4*number of pulses per revolution) - 1) and rein itialize after compare. the value of the timer a1 corr esponds to the rotor position. the position of the index pulse is sensed to avoid the loss of some pulses under the influence of noise during extended motor operation, which can result in incorrect rotor position sensing. if some pulses are lost, a different position of the inde x pulse is detect ed, and a position sensing error is signaled. if a check of the index pulse is not required, timer a1 can be removed and timer a0 set as the position counter a1. the resulting value of timer a1 is scaled to range <-1; 1), which corresponds to <- ; ). 3.4.1.2 speed sensing there are two common ways to me asure speed. the first method measures the time between two fo llowing edges of quadrature encoder, and the second method measures a po sition difference (a number of pulses) per constant period. the first method is used at low speed. at the moment when the m easured period is very shor t, the speed calculation algorithm switches to the second method. the proposed algorithm combines both methods. the algorithm simultaneously measures the number of quadrature encoder pulses per constant period, and an a ccurate time interval bet ween the first and last pulse is counted during that constant period. the speed can then be expressed as: (eq 3-1.) where: speed alculated speed k scaling constant n number of pulses per constant period speed kn ? t ----------- = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 42 system description motorola t accurate period of n pulses the algorithm requires tw o timers for counting pulses and measuring their period, and a third ti mer as a time base; see figure 3-3 . timer a2 counts the pulses of t he quadrature encoder, and timer a3 counts a system clock divided by 2. the values in both timers can be captured by each edge of the phase a signal. the time base is provided by timer d0, which is set to call the s peed processing algorithm every 900 s. an explanation of how the speed proc essing algorithm works follows. first, the new captured va lues of both timers ar e read. the difference in the number of pulses and their accurate time interval ar e calculated from actual and previous val ues. the new values are then saved for the next period, and the capture register is enabled. from that moment, the first edge of phase a signal capt ures the values of bot h timers (a2, a3) and the capture register is disabled. this process is repeated on each call of the speed processing algorithm; see figure 3-4 . figure 3-4. speed processing f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 43 3.4.1.3 minimum and ma ximum speed calculation the minimum speed is calculat ed with the following equation: (eq 3-2.) where: min minimum obtainable speed [rpm] n number of pulses per revolution [1/rev] t calc period of speed measurement (calculation period) [s] in the application, the quadrature encode r has 1024 pulses per revolution and a calcul ation period of 900 s was chosen on the basis of a motor mechanical constant. thus, (eq 3-2.) calculates the minimum speed as 16.3 rpm. the maximum speed can be expressed as: (eq 3-3.) where: max maximum obtainable speed [rpm] n number of pulses per revolution [1/rev] t clkt2 period of input clock to timer a2 [s] substitution in (eq 3-3.) for n and t clkt2 (timer a2 input clock = system clock 36 mhz/2) yields a ma ximum speed of 263672rpm. as demonstrated, the algorit hm can measure spee d across a wide range. because such high speed is not prac tical, the maximu m speed can be reduced to a required r ange by the constant k in (eq 3-1.) . the constant k can be calculated as: (eq 3-4.) where: min 60 4nt calc ------------------- = max 60 4nt clkt2 ---------------------- - = k 60 4nt clkt2 max ----------------------------------- = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 44 system description motorola k scaling constant in (eq 3-1.) max maximum of the speed range [rpm] n number of pulses per revolution [1/rev] t clkt2 period of input clock to timer a2 [s] in this application, the maximum m easurable speed is limited to 6000rpm. note: to ensure an accurate speed calculat ion, you must choose the input clock of timer a2 so that the calc ulation period of s peed processing (in this case, 900 s) is represented in timer a2 as a value lower than 0x7fffh (900.10 -6 /t clkt2 <=0x7fffh). 3.4.1.4 position reset with rotor alignment after reset, the rotor position is unknown, becaus e a quadrature encoder does not give an absolute position until the index pul se arrives. as shown in figure 3-5 , the rotor position mu st be aligned with the d axis of the d-q coordinate system before a motor begin s running. the alignment algorithm is shown in figure 3-6 . first, the positi on is set to zero, independent of the ac tual rotor positio n. (the value of the quadrature encoder does not affect this setting). then the i d current is set to alignment current. the rotor is now al igned to the required position. after rotor stabilization, the encoder is re set to the zero position, then the i d current is set back to zero, and ali gnment is finished. the alignment is executed only once during the first tr ansition from the stop to run state of the run/stop switch. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 45 figure 3-5. rotor alignment figure 3-6. rotor alignment flow chart 0 = field ? m q d unknown rotor position (not aligned) zero rotor position (aligned) alignment set fixed position (0) i q =0 i d =i alignment wait for rotor stabilization set position from encoder i q =0 i d =0 end reset encoder position f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 46 system description motorola 3.4.2 current sensing phase currents are measured by a s hunt resistor in each phase. a voltage drop on the shunt resistor is amplified by an operational amplifier, and shifted up by 1.65v. the resultant vo ltage is converted by an a/d converter (see figure 3-7 and figure 3-8 ). figure 3-7. current shunt resistors figure 3-8. current amplifier q5 skb04n60 gate_cb q4 skb04n60 phase_a phase_b gate_bb source_ab i_sense_b2 q1 skb04n60 gate_ab i_sense_c2 i_sense_c1 i_sense_a2 sense sense r2 0.1 1% phase_c q3 skb04n60 i_sense_b1 gate_ct sense sense r3 0.1 1% i_sense_a1 gate_at gate_bt source_cb sense sense r1 0.1 1% q2 skb04n60 q6 skb04n60 source_bb r321 10k-1% + c306 3.3uf/10v i_sense_c1 c307 100nf +3.3v_a 1.65v ref gnda u304 lm285m 8 5 4 r320 10k-1% r323 390 r318 75k-1% r325 33k-1% 1.65v +/- 1.65v @ +/- imax r324 100k-1% + - u301b mc33502d 5 6 7 i_sense_c i_sense_c2 gnda r322 75k-1% f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 47 as shown in figure 3-7 , the currents cannot be measured at any moment. for example, t he current flows throu gh phase a (and shunt resistor r1) only if tran sistor q2 is switched on. likewise, the current in phase b can be measured if transistor q4 is switched on, and the current in phase c can be measured if trans istor q6 is switched on. to get a moment of current sensing, a vo ltage shape anal ysis must be done. the voltage shapes of two different pwm periods are shown in figure 3-11 . the voltage shapes correspond to center-aligned pwm sinewave modulation. as s hown, the best moment of current sampling is in the middle of the pwm period, where all bottom transistors are switched on. to set the exact moment of samplin g, the dsp56f80x family offers the ability to synchronize adc and pwm modules via the sync signal. this exceptional hardware fe ature, patented by motoro la, is used for current sensing. the pwm outputs a synchroni zation pulse, which is connected as an input to the synchroniza tion module tc2 (quad timer c, counter/timer 2). a high -true pulse occurs for ea ch reload of the pwm, regardless of the state of the ldok bit. the intended purpose of tc2 is to provide a user-sel ectable delay between th e pwm sync signal and the updating of t he adc values. a conversion process can be initiated by the sync input, which is an output of tc2. the time diagram of the automatic synchronization betw een pwm and adc is shown in figure 3-9 . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 48 system description motorola figure 3-9. time diagram of pwm and adc synchronization however, all three currents c annot be measured from one voltage shape. the pwm period ii in figure 3-11 shows a moment when the bottom transistor of phase a is switched on for a ve ry short time. if the on-time is shorter than a critical ti me, the current can not be accurately measured. the critical time is given by hardware configuration (transistor commutation times, re sponse delays of the processing pwm counter pwm sync pwm generator outputs 0, 1 pwm pins 0, 1 power stage voltage tc2 t1 t2 counter tc2 output adc conversion adc isr dead-time/2 dead-time dead-time dead-time/2 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 49 electronics, etc.). ther efore, only two currents are measured and a third current is calculated fr om the following equation: (eq 3-5.) figure 3-10. voltage shapes of two diff erent pwm periods 0i a i b i c ++ = phase_a phase_b phase_c pwm period adc samplin g point critical pulse width pwm reload i . ii . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 50 system description motorola figure 3-11. 3-phase sinewa ve voltages and corresponding sector value a decision must now be m ade about which phase current should be calculated. the simplest technique is to calculate the current of the most positive voltage phase. for exampl e, phase a generates the most positive voltage with in section 0 - 60 , phase b within section 60 - 120, and so on; see figure 3-11 . in this case, the output voltages are divided into six sectors, as shown in figure 3-11 . the current calculation is then made according to the actual sector value. sectors 1 and 6: (eq 3-6.) sectors 2 and 3: (eq 3-7.) 0 60 120 180 240 300 360 0 0.2 0.4 0.6 0.8 1 phase a phase b phase c angle duty cycle ratios 0 60 120 180 240 300 360 0 60 120 180 240 300 360 0 0.2 0.4 0.6 0.8 1 0 0.2 0.4 0.6 0.8 1 phase a phase b phase c phase a phase b phase c angle duty cycle ratios sector 1 sector 2 sector 3 sector 4 sector 5 sector 6 sector 1 sector 2 sector 3 sector 4 sector 5 sector 6 ii. i. i a i b ?i c ? = i b i a ?i c ? = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description system blocks concept DRM018 ? rev. 0 designer reference manual motorola system description 51 sectors 4 and 5: (eq 3-8.) note: the sector value is used for current calculation only, and has no other meaning in the sinewave m odulation. but if we us e any type of space vector modulation, we can get the se ctor value as part of space vector calculation. 3.4.3 voltage sensing the dcbus voltage sensor is represen ted by a simple voltage divider. the dcbus voltage does not c hange rapidly. it is nearly constant, with the ripple given by the power supply stru cture. if a bridge rectifier is used for rectification of the ac line voltage, the rippl e frequency is twice the ac line frequency. if the power stage is desi gned correctly, the ripple amplitude should not exceed 10% of the nomina l dcbus value. the measured dcbus volt age must be filtered to eliminate noise. one of the easiest and fastes t techniques is the fi rst order filter, which calculates the average filtered value recursivel y from the last two samples and coefficient c: (eq 3-9.) to speed up the initialization of t he voltage sensing (the filter has exponential dependency with constant of 1/n samples), the moving average filter, which calculates t he average value fr om the last n samples, can be used for initialization: (eq 3-10.) 3.4.4 power modul e temperature sensing the measured power module temperatur e is used for thermal protection the hardware realization is shown in figure 3-12 . the circuit consists of four diodes connected in series, a bias resistor, and a noise suppression i c i b ?i a ? = u dcbusfilt n1 + () cu dcbusfilt n1 + () cu dcbusfilt n () ? () u ? dcbusfilt n () = u dcbusfilt u dcbus n () n1 = n ? = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system description designer reference manual DRM018 ? rev. 0 52 system description motorola capacitor. the four diodes have a comb ined temperature coefficient of 8.8 mv/ c. the resulting signal, temp_sense , is fed back to an a/d input, where software ca n be used to set safe oper ating limits. in this application, the temperature, in cels ius, is calculated according to the conversion equation: (eq 3-11.) where: temp power module temperature in centigrades temp_sense voltage drop on the diodes, which is measured by adc [v] a diodes-dependent conversion constant b diodes-dependent conversion constant figure 3-12. temperature sensing temp temp_sense b ? a ------------------------------------- - = c1 100nf d1 bav99lt1 r1 2.2k - 1% d2 bav99lt1 temp_sense +3.3v_a f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola hardware design 53 designer reference manual ? 3-ph . pmsm torque vector control section 4. hardware design 4.1 contents 4.2 hardware set-up. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 4.3 dsp56f805evm controller board . . . . . . . . . . . . . . . . . . . . . . 55 4.4 3-ph bldc low voltage po wer stage . . . . . . . . . . . . . . . . . . . 57 4.5 motor-brake specif ications. . . . . . . . . . . . . . . . . . . . . . . . . . . .59 4.6 hardware documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60 4.2 hardware set-up the application can run on motorola?s motor control dsps using the dsp56f803evm, dsp56f8 05evm, or dsp56f807evm, motorola?s 3-phase ac/bldc high voltage power stage and the bldc high voltage motor with a quadrature encoder and integrated brak e. all components are an integral part of motorola?s embedded moti on control development tools. application hardware set-up is shown in figure 4-1 . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design designer reference manual DRM018 ? rev. 0 54 hardware design motorola figure 4-1. high-voltage hardwa re system c onfiguration f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design dsp56f805evm controller board DRM018 ? rev. 0 designer reference manual motorola hardware design 55 all system parts are supplied and documented in these references:  u1 - dsp56f805 controll er board for the: ? supplied as dsp56f805evm ? described in the dsp56f805 eval uation module hardware user?s manual  u2 - 3-phase ac/bldc low -voltage power stage ? described in the 3-phase brushless dc low voltage power stage manual  supplied in a kit with the 3- phase ac/bldc low voltage power stage (order #eclovacbldc)  mb1 motor-brake sm40v + sg40n ? supplied as order #ecmtrlovbldc note: the application software is targeted for a pm synchronous motor with sinewave back-emf shape. in this dem o application, a bldc motor is used instead, due to the availability of the bldc motor (mb1). although the back-emf shape of this motor is not an ideal sinew ave, it can be controlled by the application softwa re. the drive paramet ers will be ideal with a pmsm motor with an exact sinewave back-emf shape. a detailed description of the indi vidual board can be found in the appropriate dsp56f80x evaluation mo dule user?s manual , or on the motorola web site, http://www.m otorola.com . the user?s manual includes the schematic of the board, description of individual function blocks, and a bill of mate rials. the individual bo ards can be ordered from motorola as standard products. 4.3 dsp56f805evm controller board the dsp56f805evm is used to demon strate the abilities of the dsp56f805 and to provid e a hardware tool allo wing the development of applications that use the dsp56f805. the dsp56f805evm is an evaluation module boar d that includes a dsp56f805 part, per ipheral expansion connecto rs, external memory f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design designer reference manual DRM018 ? rev. 0 56 hardware design motorola and a can interface. the expansio n connectors are for signal monitoring and user feature expandability. the dsp56f805evm is designed for the following purposes:  allowing new users to become fa miliar with the f eatures of the 56800 architecture. the tools and examples provided with the dsp56f805evm facilitate evaluati on of the feature set and the benefits of the family.  serving as a platform for real-t ime software devel opment. the tool suite enables the user to develop and simulate r outines, download the software to on-chip or on-b oard ram, run it, and debug it using a debugger via the jtag/once tm port. the break point features of the once port enable the user to easily sp ecify complex break conditions and to execut e user-developed softwa re at full-speed, until the break conditi ons are satisfied. t he ability to examine and modify all user accessible re gisters, memory and peripherals through the once port greatly faci litates the task of the developer.  serving as a platform for hardw are development. the hardware platform enables the user to connect exter nal hardware peripherals. the on-boar d peripherals can be disabled, providing the user with the ability to re assign any and all of the dsp's peripherals. the once port's un obtrusive design means that all of the memory on the board and on the dsp chip are available to the user. the dsp56f805evm provides t he features necessary for a user to write and debug software, demonstr ate the functionality of that software and interface with the customer's app lication-specific device(s). the dsp56f805evm is flexible enough to allow a user to fully exploit the dsp56f805's features to optimize the performance of their product, as shown in figure 4-2 . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design 3-ph bldc low voltage power stage DRM018 ? rev. 0 designer reference manual motorola hardware design 57 figure 4-2. block diag ram of the dsp56f805evm 4.4 3-ph bldc low voltage power stage motorola?s embedded motion control se ries low-voltage (lv) brushless dc (bldc) power stage is de signed to run 3-ph. bldc and pm synchronous motors. it operates from a nominal 12-volt motor supply, and delivers up to 30 amps of rms moto r current from a dc bus that can deliver peak currents up to 46 amps. in comb ination with one of motorola?s embedded motion control seri es control boards, it provides a software development platform that allows algorithms to be written and tested, without the need to design and build a po wer stage. it supports a wide variety of algorithms for co ntrolling bldc motors and pm synchronous motors. dsp56f805 reset mode/irq address, data & control jtag/once xtal/extal spi sci #0 sci #1 can timer gpio pwm #1 a/d pwm #2 3.3 v & gnd peripheral expansion connector(s) reset logic mode/irq logic program memory 64kx16-bit memory expansion connector(s) jtag connector parallel jtag interface low freq crystal dsub 25-pin data memory 64kx16-bit dsub 9-pin can interface debug leds pwm leds over v sense over i sense zero crossing detect secondary uni-3 primary uni-3 rs-232 interface 4-channel 10-bit d/a power supply 3.3v, 5.0v & 3.3va f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design designer reference manual DRM018 ? rev. 0 58 hardware design motorola input connections are made via 40-pin ri bbon cable connector j13. power connections to the motor are made with fast-on co nnectors j16, j17, and j18. they ar e located along the ba ck edge of the board, and are labeled phase a, ph ase b, and phase c. po wer requirements are met with a 12-volt power supply that has a 10- to 16-volt tolerance. fast-on connectors j19 and j20 are used for the power supply. j19 is labeled +12v and is located on th e back edge of the board. j20 is labeled 0v and is located along t he front edge. cu rrent measuring circuitry is set up for 50 amps full scale. both bus and phase leg currents are measured. a cycle by cycle overcurrent trip po int is set at 46 amps. the lv bldc power stage has both a pr inted circuit board and a power substrate. the printed circuit b oard contains mo sfet gate drive circuits, analog signal conditioning, low-voltage power supplies, and some of the large pa ssive power components. this board also has a 68hc705jj7 microcontroller us ed for board conf iguration and identification. all of t he power electronics that need to dissipate heat are mounted on the power substrate. this substr ate includes the power mosfets, brake resistors, current-s ensing resistors, bus capacitors, and temperature sensing diodes. figure 4-3 shows a block diagram. figure 4-3. block diagram power input bias power brake mosfet gate phase current phase voltage bus current bus voltage monitor zero cross back-emf sense board id block signals to/from control board power module drivers motor to f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design motor-brake specifications DRM018 ? rev. 0 designer reference manual motorola hardware design 59 the electrical characteristics in table 4-1 apply to operation at 25 c with a 12-vdc supply voltage. 4.5 motor-brake specifications the ac induction motor-brake set in corporates a 3-phase ac induction motor and attached bldc motor brak e. the ac induction motor has four poles. the incremental position encoder is coupled to t he motor shaft, and position hall sensor s are mounted between motor and brake. they allow sensing of the posit ion if required by the c ontrol algorithm. detailed motor-brake specificat ions are listed in table 4-2 . in a target application a customer specific motor is used. table 4-1. electrical chat acteristics of the 3-ph bldc low voltage power stage characteristic symbol min typ max units motor supply voltage vac 10 12 16 v quiescent current i cc ?175?ma min logic 1 input voltage v ih 2.0 ? ? v max logic 0 input voltage v il ??0.8v analog output range v out 0?3.3v bus current sense voltage i sense ?33?mv/a bus voltage sense voltage v bus ?60?mv/v peak output current (300 ms) i pk ??46a continuous output current i rms ??30a brake resistor dissipation (continuous) p bk ??50w brake resistor dissipation (15 sec pk) p bk(pk) ? ? 100 w total power dissipation p diss ??85w f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design designer reference manual DRM018 ? rev. 0 60 hardware design motorola 4.6 hardware documentation all the system parts are suppli ed and documented according to the following references:  u1 controller board for dsp56f805: ? supplied as: dsp56805evm ? described in: dsp evaluation module ha rdware user?s manual  u2 - 3 ph ac/bldc low voltage power stage ? described in: motorola embedded moti on control 3-phase bldc low-voltage powe r stage user?s manual memc3pbldclvum/d  mb1 motor-brake am40v + sg40n table 4-2. motor - brake specifications set manufactured em brno, czech republic motor specification: e motor type: am40v 3-phase ac induction motor pole-number: 4 nominal speed: 1300 rpm nominal voltage: 3 x 200 v nominal current: 0.88 a brake specification: brake type: sg40n 3-phase bldc motor nominal voltage: 3 x 27 v nominal current: 2.6 a pole-number: 6 nominal speed: 1500 rpm position encoder type: baumer electric bhk 16.05a 1024-12-5 pulses per revolution: 1024 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design hardware documentation DRM018 ? rev. 0 designer reference manual motorola hardware design 61 ? supplied as: ecmtrhivac detailed descriptions of indi vidual boards can be found in comprehensive user?s manuals belonging to eac h board. the manuals are available on the motorola web . the user?s manual incorporates the schematic of the board, description of individual function bl ocks and a bill of materials. an indi vidual board can be ordered from motorola as a standard product. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
hardware design designer reference manual DRM018 ? rev. 0 62 hardware design motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola software design 63 designer reference manual ? 3-ph . pmsm torque vector control section 5. software design 5.1 contents 5.2 main software flow chart . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 5.3 data flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 5.4 state diagram. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 5.5 scaling of quantities. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81 5.6 pi controller tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86 5.7 subprocesses relation and state transitions . . . . . . . . . . . . . 86 5.2 main software flow chart the main software flow chart incorpor ates the main routine entered from reset (see figure 5-1 ) and interrupt states (see figure 5-2 , figure 5-4 ). the main routine includes t he initialization of the dsp and the main loop. the software consist of processe s: application control, pm synchronous motor (pmsm) control, analog sensing, position and speed measurement, and fault control. the application control process is the highest software level which precedes settings for other software le vels. the input of this level is the run/stop switch, up/down buttons fo r manual control, and pc master software (via the registers shown in 5.3 data flow ). this process is handled by drive control called from main; see figure 5-1 . the pmsm (pm synchronous motor) c ontrol process provides most of the motor control functi onality. it is executed mainly in current processing. current processing is ca lled from adc complete interrupt f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 64 software design motorola (see figure 5-2 ) once per two pwm reloads, with a period 125 s. it can also be set to each pwm reload (62.5 s), but the pc ma ster software recorder pcmasterdrvrecorder() must be removed from the code. the speed measurment is preformed from the quadrature timer d0 interrupt (see figure 5-4 ) with the period per_tm r_pos_speed_us (900 s). the current control is executed with a high priority and frequency of calls. the analog sensing process handles sens ing, filtering and correction of analog variables (phase cu rrents, temperature, dcbus voltage). it is provided by analog sensing processing (see figure 5-2 ) and analog sensing adc phase set. analog sens ing adc phase set is split from analog sensing processing because it sets adc according to the svmsector variable, calculated after pmsm control current processing. position and speed measur ement processes are provided by hardware timer modules and the functions givi ng the actual spee d and position; see figure 3-2 . led indication processing is called from quadrature time r d0 interrupt, which provides the time base for led flashing. the fault control process is split into background and pwm fault isr. background (see figure 5-1 ) checks the overheating, undervoltage and position sensing faults. the pwm fault isr part (see figure 5-2 ) takes care of overvoltage and overcu rrent faults, which causes a pwm a fault interrupt. the brake control process is dedicated to the brake transistor control, which maintains the dcbus voltage le vel. it is called from main (see figure 5-1 ). the up/down button processes are split into button processing interrupt, called from quadrat ure timer d0 interrupt (see figure 5-4 ); button processing background (insi de analog sensing); interrupt up button; and interrupt down button (see figure 5-2 ). f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design main software flow chart DRM018 ? rev. 0 designer reference manual motorola software design 65 figure 5-1. software flow chart - general overview i the check switch state routine handl es manual switch control. this routine is called regular ly in drive control pr ocessing state. it is responsible for software control flow due to reading t he state of the run/stop switch. reset dsp initialization drive control - processing: control/check switch set i sq trigger drivestatus run/stop/init/ set pmsm control run/stop set fault control status set led indication} fault control - background: if faultctrlstatus - analogfaultenbl {check undervoltage, overheating faults} if position sensing,overvoltage, overcurrent faults {set appfaultstatus trigger beginning of fault state} f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 66 software design motorola figure 5-2. software flow chart - adc interrupt interrupt adc complete return analog sensing- processing according to ansensingctrlstatus sensing/initialization: {sense temperature calculate filtered temperature sense, correct 2 phase currents calculate 3 phase currents sense voltage correct voltage calculate filtered voltage} sin cos generation: get position from position measurement sin ( theta_actual_el ) cos ( theta_actual_el ) current control: currents transformation (a,b,c to d-q) current d regulator current q regulator voltages transformation ( d-q to , ) dcbus ripple compensation space vector module sets pwmabc pmsm control -current processing: proceeds according to pmsmctrlstatus analog sensing-adc phase set set adc converter phase current sam- ples - two (easily measured) phases pwm: set duty cycles to pwmabc f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design main software flow chart DRM018 ? rev. 0 designer reference manual motorola software design 67 figure 5-3. software flow chart - pwm a fault interrupt return fault control - pwm fault isr part: if overcurrent or overvoltage: {set appfaultstatus = overvoltage / overcurrent triggers beginning of fault state (disable pwm...)} interrupt pwm a fault f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 68 software design motorola figure 5-4. s/w flow ch art - general overview 5.3 data flow the pm synchronous motor vector control drive control algorithm is described in the data fl ow charts shown in figure 5-5 and figure 5-6 . return alignment: software timer if timeout {pmsm control - end alignment} speed measurement processing pmsmctrlstatus ? alignflag runflag others pmsm control torque, and alignment processing: proceeds according to its status get speed from speed measurement led indication processing interrupt d0 qtimer f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design data flow DRM018 ? rev. 0 designer reference manual motorola software design 69 the variables and constants descr ibed should be clear from their names. figure 5-5. data flow - part 1 phasea,phaseb,index theta_actual_el position, speed measurement pmsm control omega_actual_mech svmsector pwm_at pwm_ab pwm_bt pwm_bb pwm_ct pwm_cb pwm generation pwm outputs pwmabc appstate pmsmctrlstatus start/stop switch pc master up/down buttons application control appfaultstatus reloadswtmralignment analog sensing (temperature, dcbus volt. i_sa , i_sb , i_sc u_dc_bus phase currents a,b,c) temperature i_sabc_comp temperature_filt u_dc_bus u_dc_bus_filt ansensingctrlstatus green led faultctrlstatus theta_align_el_c i_sd_alignment reloadswtmrspeedcontrol led indication i_sdq_max svm_inv_index, u_reserve_fw svm_inv_index, u_overmax coefbemf, coefbemfshift pc master software apppcmctrlstatus i_q_desired i_q_desired f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 70 software design motorola figure 5-6. data flow - part 2 the data flows consist of the proc esses described in the following sections. 5.3.1 application control process the application control process is t he highest software level, which precedes settings for other software levels. the process state is det ermined by the variable appstate . the application can be controlled either:  manually  from pc master software pwmen bit pwm faults (overvoltage/overcurrent) fault control temperature_filt u_dc_bus_filt pwm_at pwm_ab pwm_bt pwm_bb pwm_ct pwm_cb pwm generation pwm outputs i_sabc_comp appfaultstatus u_dc_bus_min_fault_c temperature_max_f16 faultctrlstatus pmsmctrlstatus pc master check index position software f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design data flow DRM018 ? rev. 0 designer reference manual motorola software design 71 for manual control, the i nput of this process is the run/stop switch and up/down buttons. the pc master software communicates via omega_reqpcm_mech , which is the required angular s peed from pc master software; apppcmctrlstatus , which consists of the flags startstopctrl for start/stop; requestctrl for changing the applicat ion?s operating mode appopmode to manual or pc control; and appfaultstatus , indicating faults. the other processes are controlled by setting pmsmctrlstatus , omega_required_mech , apppcmctrlstatus , brakectrlstatus , faultctrlstatus . 5.3.2 led indication process this process contro ls the led flashi ng according to appstate . 5.3.3 analog sensing process the analog sensing process handles sens ing, filtering and correction of analog variables (phase currents, temperature, dc bus voltage). 5.3.4 position and s peed measurement process the position and speed measurement process gives mechanical angular speed omega_actual_mech and electrical position theta_actual_el . 5.3.5 pmsm (pm synchro nous motor) control process the pmsm (pm synchronous motor) c ontrol process provides most of the motor control functionality. figure 5-7 shows the data flow insi de the process pmsm current control. it shows essential subproce sses of the process: sine; cosine transformations; curr ent control; speed; and alignment control. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 72 software design motorola the sine and cosine tr ansformations generate sincos_theta_el with the components sine , cosine according to el ectrical position theta_actual_el . it is provided in a look-up table. the data flow inside the process current control is detailed in figure 5-7 . the measured phase currents i_sabc_comp are transformed into i_sdq_lin using sincos_theta_el ; see 2.4.3 vector control transformations . both d and q components ar e regulated by independent pi regulators to i_sdq_desired values. the outputs of the regulators are u_sdq_lin . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design data flow DRM018 ? rev. 0 designer reference manual motorola software design 73 figure 5-7. data flow - pmsm control - current control current q regulator current transformation a,b,c -> d-q i_sdq.d_axis i_sabc_comp current d regulator i_sdq.q_axis u_sdq_lin.d_axis u_sdq_lin.q_axis feed forward voltage transformation d-q -> alpha, beta u_salphabeta u_dc_bus_filt scaling dcbus ripple space vector modulation u_salpha_ripelim i_sdq_desired.q_axis i_sdq_desired.d_axis sincos_theta_el svmsector omega_actual_mech pmsmctrlstatus svm_inv_index/2* i_sdq_max_f16 pwmabc compensation u_limitf16 u_sdq svm_inv_index, *u_dc_bus_filt + +u_overmax u_overmax u_limitf16 sincos_theta_el coefbemf, coefbemfshift f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 74 software design motorola the feed forward process provides the following calculations: (eq 5-1.) (eq 5-2.) the u_sdq voltages are transformed into u_salphabeta (see 2.4.3 vector control transformations ) by the voltage transformation process. the scaling dcbus rip ple compensation block scales u_salphabeta (according u_dc_bus_filt ) to u_salpha_ripelim, described in the svmlimdcbusrip function in the motor control library . the space vector modulation process generates duty cycle pwmabc and svmsector according to u_salpha_ripelim . the u_limitf16 is a voltage limit for cu rrent controllers. the u_overmax constant is used to incr ease the lim itation of u_sdq voltages over maximum svm_inv_index / 2* u_dc_bus_filt determined by the dcbus voltage and space vector modulation. although the pwmabc will be limited by the space vector modulati on process functions, the reserve might be used for field-we akening controlle r dynamics. in the stable state, the u_sdq voltages vector will not exceed u_s_max_fwlimit . the process controls the i_sdq_desired.q_axis current according to the pmsm control process status. fo r alignment stat us, it sets i_sdq_desired.d_axis to i_sd_alignment and i_sdq_desired.q_axis to 0. 5.3.6 pwm generation process the pwm generation proce ss controls the generat ion of pwm signals, driving the 3-phase inverter. the input is pwmabc , with three pwm componen ts scaled to the range <0,1> of type frac16. the scaling (a ccording to pwm module setting) and the pwm module cont rol (on the dsp) is provided by the pwm driver. u_sdq.q_axis coefbemf 2 coefbemfshft omega_actual_mech ?? u_sdq_lin.q_axis + = u_sdq.d_axis u_sdq_lin.d_axis = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design state diagram DRM018 ? rev. 0 designer reference manual motorola software design 75 5.3.7 fault control process the fault control process checks th e overheating, undervoltage, overvoltage, overcurrent and position sensing faults. overheating and undervo ltage are checked by the comparisons temperature_filt < temperature_max_f16 and u_dc_bus_filt < u_dc_bus_min_fault_c , where u_dc_bus_min_fault_c is initialized with u_dcb_min_fault_mains230_f16 or u_dcb_min_fault_mains115_f16 . the position sensing fault is checked with the check index position process. the overvoltage and overcurrent f aults are set in the pwma fault interrupt. 5.4 state diagram the software can be split into the processes shown in 5.3 data flow . the following processes are described below:  application control sate diagram  pmsm control state diagram  fault control state diagram  analog sensing state diagram all processes start wi th the dsp initializat ion state after reset. 5.4.1 dsp initialization the dsp initializ ation state:  initializes: ?pwm ? application control ? pm synchronous motor control ? analog sensing f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 76 software design motorola ? fault control ? led indication  sets manual applicat ion operating mode  enables masked interrupts  application control: in itialization triggers, which set all affected processes to the begin appl ication initialization state 5.4.2 application control state diagram the application control pr ocess is detailed in figure 5-8 . figure 5-8. state diagram - application control application control: stop application control: fault begin application control: begin run fault control: switchstate = run switchstate = stop application control: run application control: begin stop done done clear pmsmctrlstatus.runflag dsp initialization reset application control: fault done fault control: faults cleared switchstate = stop & switchstate = stop & fault control: begin fault done appstate = app_stop set appstate = app_run begin fault apppcmctrlstatus. requestctrl = 1 set appstate = app_stop appstate = app_run initializations finished clear pmsmctrlstatus.alignflag set appstate = app_fault application control: init initializations proceeding appstate = app_init f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design state diagram DRM018 ? rev. 0 designer reference manual motorola software design 77 after reset, the dsp initialization state is entered. the peripherals and variables are initialized in this state, and the application is set to manual control . when the state is finished , the application control init state follows. as shown in figure 5-8 , appstate = app_init ; all subprocesses requiring initialization are proceeding; the pw m is disabled; and so no voltage is applied on motor phases. if the apppcmctrlstatus .requestctrl flag is set from pc master software. if the switchstate = stop , the application control enters the stop state. the switchstate is set according to the manual switch on the evm or pc master software register apppcmctrlstatus.startstopctrl , depending on the application operating mode. in the stop state, appstate = app_stop and the pwm is disabled, so no voltage is applied on motor phases. when switchstate = run , the begin run state is processed. if t here is a request to change application operating mode, apppcmctrlstatus.requestctrl = 1 , the application init is entered and the appl ication operating mode request can only be accepted in the init or stop state by transition to the init state. in the begin run st ate, all the processes prov ide settings to the run state. in the run state, t he pwm is enabled, so voltage is applied on motor phases. the motor is running according to the state of all subprocesses. if switchstate = stop , the stop state is entered. if fault is detected during the begin fault state, which is a subprocess of fault control, the b egin fault state is entered. it sets appstate = app_fault ; the pwm is disabled; and t he subprocess pmsm control is set to stop. the fault state can on ly move onto the init state when switchstate = stop , and the fault control subp rocess has successfully cleared all faults. 5.4.3 pmsm control state diagram a state diagram of the commutation cont rol process is illustrated in figure 5-9 . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 78 software design motorola figure 5-9. state diagr am - pmsm control when application control initializ es, the pmsm control subprocess initialization state is entered. the aligninitdoneflag is cleared, which means that alignment can proceed. the next pmsm control state is begin stop or fault . runflag and alignflag are cleared and the stop or fault state is entered. when applicat ion control: begin run, the pmsm control subprocess enters the begin alignment or begin run state, depending on whether or not the alignment initia lization has already proceeded (flagged by aligninitdoneflag ). the alignment state is necessary for setting the zero pos ition of positi on sensing; see 3.4.1.4 position reset with rotor alignment . in the state begin alignment , the alignment current and duration are set; the ali gnment is provided by setting desired current for d_axis to i_sd_alignment and q_axis to 0. the pmsm control: stop or fault pmsm control: pmsm control: initialization application control: begin running alignment timeout pmsm control: begin alignment set alignment current application control: begin stop/fault done done application control: init pmsm control: run pmsm control: begin run done pmsm control: begin stop or fault pmsmctrlstatus.aligninitdoneflag = no clear aligninitdoneflag begin running aligninitdoneflag = 1 set runflag pmsm control: end alignment done set zero position set alignment timeout clear runflag clear alignflag timeout search current ramp set aligninitdoneflag clear alignflag set alignflag done alignment f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design state diagram DRM018 ? rev. 0 designer reference manual motorola software design 79 alignment state provides current control and timeout search. when alignment timeout occurs, end alignment is entered. in that state, the position sensing zero position is set, so the po sition sensor is aligned with the real vector of the rotor fl ux. when the end alig nment state ends, the pmsm control enters a regular run state, where the motor is running at the required speed. if t he application contro l state is set to begin stop or begin fault , the pmsm control enters the begin stop or fault , then the stop or fault . 5.4.4 fault control state diagram the state diagram of the fault control subproce ss is illustrated in figure 5-10 . after the initialization, the f ault conditions are searched. if any fault occurs, the appfaultstatus variable is set according to detected error; pwm is switched on (pwmen bit = 0); the fault stat e is entered. this state also caus es application control: fault state. if the faults are successfully cleared, this is signaled to the application control process. the fault state is left when the applic ation control init state is entered. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 80 software design motorola figure 5-10. state di agram fault control 5.4.5 analog sensing state diagram the state diagram of the analog se nsing subprocess is shown in figure 5-11 . the dsp initialization state initializes hardware modules like adc, synchronizati on with pwm, etc. in begin init , initialization is started, so the variables fo r initialization sum and the initdoneflag are cleared. in the init proceed state, the temperat ure, dcbus voltage and phase current samples are sensed and summed. after required analog sensing, init samples are sensed, and the init finished state is entered. fault control: application initialization application control: init clear appfaultstatus fault control: no fault searching faults fault control: begin fault application control begin fault setting of appfaultstatus fault control: fault clear/test faults fault: undervoltage (filtered) overheating (filtered) overcurrent (fault pin) overvoltage (fault pin) done fault control: dsp initialization wrong pcb pcb identification reset done pwmen bit = 0 position sensing fault f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design scaling of quantities DRM018 ? rev. 0 designer reference manual motorola software design 81 there, the samples? average is calc ulated, from the su m divided by the number of analog sensing init samples. according to th e phase currents? average value, the phase curren t offsets are initialized. all variable sensing is initialized and the state init done is entered, so the variables from analog sensing are valid fo r other processes. in this state, temperature and dcbus voltage are filtered in first order filters. figure 5-11. state di agram - analog sensing 5.5 scaling of quantities the pm synchronous motor vector control applicat ion uses a fractional representation for all real quantities except time. the n-bit signed fractional format is represented using 1.[n-1] format (1 sign bit, n-1 fractional bi ts). signed fractional num bers (sf) lie in the following range: (eq 5-3.) analog sensing: begin init analog sensing init done, analog sensing init. proceed: analog sensing dsp initialization reset clear variables application control: begin init samples counter = application control: begin init clear initdoneflag analog sensing init finished: samples average done done set current offsets sense and sum samples count samples analog sensing init samples set initdoneflag normal operation: 1.0 ?sf+1.0 -2 n1 ? [] ? ? , , . , . . . . .
software design designer reference manual DRM018 ? rev. 0 82 software design motorola for words and long-word signed fractions, the most negative number that can be represented is -1.0, whos e internal representation is $8000 and $80000000, respectively. the most positive word is $7fff or 1.0 - 2 -15 , and the most positive l ong-word is $7fffffff or 1.0 - 2 -31 . the following equation show s the relationship between the real and fractional representations: (eq 5-4.) where: fractional value is the fractional representation of the real value [frac16] real value s is the real value of the quantity [v, a, rpm, etc.] real quantity range max is the maximum of the quantity range, defined in the application [v, a, rpm, etc.] the c language standard doe s not have any frac tional variable type defined. therefore, fract ional operations are pr ovided by codewarrior intrinsics functions (e.g. mult_r() ). as a substitution fo r the fractional type variables, the application us es types frac16 and frac32. these are in fact defined as integer 16-bit signed variables and integer 32-bit signed variables. the difference between frac16 and pure integer variables is that frac16 and frac32 declared variables should only be used with fractional operatio ns (intrinsics functions). a recalculation from real to a fractional form a nd frac16, frac32 value is made with the fo llowing equations: (eq 5-5.) for frac16 16-bit signed value and: (eq 5-6.) fractional value real value real quantity range max -------------------------------------------------------------- = frac16 value 32768 real value real quantity range max -------------------------------------------------------------- ? = frac32 value 2 31 real value real quantity range max -------------------------------------------------------------- ? = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design scaling of quantities DRM018 ? rev. 0 designer reference manual motorola software design 83 for frac32 32-bit signed value. (eq 5-7.) fractional form, a conver sion from fraction value to frac16 and frac32 value can be provided by the c language macro. 5.5.1 voltage scaling voltage scaling results fr om the sensing circuits of the hardware used; for details see the 3-phase ac/bldc low- voltage power stage user?s manual . voltage quantities are scaled to the maximum measurable voltage, which is dependent on the hardware. the relationship between real and fractional representations of voltage quantities is: (eq 5-8.) where: u frac fractional representation of voltage [-] u real real voltage quantities in physical units [v] volt_range_maxdefined voltage range maximum used for scaling in physical units [v] in the application, the volt_range_max value is the maximum measurable dcbus voltage: volt_range_max = 407 v all application voltage variables are scaled in the same way ( u_dc_bus , u_dc_bus_filt , u_salphabeta , u_sdq , u_salphabeta , and so on). fractional value real value real quantity range max -------------------------------------------------------------- = u frac u real volt_range_max -------------------------------------------------------- = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 84 software design motorola 5.5.2 current scaling current scaling also results from the sensing circuits of the hardware used; for details see 3-phase ac/bldc low- voltage power stage user?s manual . the relationship between real and frac tional representation of current quantities is: (eq 5-9.) where: i frac fractional representation of current quantities [-] i real real current quantities in physical units [a] curr_range_maxdefined current range maximum used for scaling in physical units[a] in the application, the curr_range_max va lue is the maximum measurable current: curr_range_max = 5.86 a all application current variables are scale d in the same way (components of i_sabc_comp , i_salphabeta , i_sdq , i_sdq_desired , i_sd_alignment and so forth). note: as shown in 3-phase ac/bldc low-volt age power stage user?s manual , the current sensing circuit prov ides measurement of the current in the range from curr _min = -2.93a to cur r_max = +2.93a, giving the voltage for the adc i nput ranges from 0 to 3.3v with 1.65v offset. the dsp5680x?s adc converter is ab le to automatically cancel (subtract) the offset. the fraction al representation of the measured current is then in the r ange <-0.5, 0.5), while the possible representation of a fractional value is <-1,1), as shown in (eq 5-5.) . therefore, curr_range_max is calc ulated according to th e following equation: (eq 5-10.) i frac i real curr_range_max -------------------------------------------------------- - = curr_range_max curr_max-curr_min 2 curr_max ? == f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design scaling of quantities DRM018 ? rev. 0 designer reference manual motorola software design 85 5.5.3 speed scaling speed quantities are scaled to t he defined speed range maximum, which should be set lower than all speed variables in the application, so it was set higher than the maximum me chanical speed of the drive. the relationship between real and frac tional representation of speed quantities is: (eq 5-11.) where: frac fractional representation of speed quantities [-] real real speed quantities in physical units [rpm] omega_range_maxdefined speed range maximum used for scaling in physical units[rpm] in the application, t he omega_range_max va lue is defined as: omega_range_max = 6000rpm the relation between speed scaling and speed measurement with encoder is described in 3.4.1.2 speed sensing . in the final software, the constant omega_scale is identical with t he scaling constant k in equations (eq 3-3.) and (eq 3-4.) , and omega_range_max is max . 5.5.4 position scaling position scaling is described in 3.4.1.1 position sensing 5.5.5 temperature scaling as shown in 3.4.4 power module temperature sensing , the temperature variable does not have a linear dependency. frac real omega_range_max -------------------------------------------------------------- = f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
software design designer reference manual DRM018 ? rev. 0 86 software design motorola 5.6 pi controller tuning the application consists of four pi c ontrollers. two controllers are used for the i d and i q currents. the controller?s constants are given by simulation in mathlab and were ex perimentally specified. a detailed description of controller tuning is beyond the scope of this reference design. 5.7 subprocesses relation and state transitions as shown in 5.3 data flow and 5.4 state diagram , the software is split into subprocesses according to func tionality. the appl ication code is designed to be able to extract indivi dual processes, such as analog sensing, and use them for cust omer applicati ons. the c language functions dedicated for each proces s are located in one place in the software, so they can be easily used for other applications. the function naming usually starts wi th the name of the pr ocess, for example, analogsensinginitproceed() . as 5.4 state diagram shows, the processes? or subprocesses?, state transients have some mutual rela tions. for example, application control: begin initialization is a condition for transi ent of the analog sensing process: init done to begin init state. in the code, the interface between processes is provided vi a ?trigger? functions. the naming convention is for these functions is: < processname >< state > trig() . the functionality will be expl ained in following example: the ?trigger? function process1statetrig() is called from process1 . the transient functions of process2 , process3 ,etc., which must be triggered by process1state , are put inside the process1statetrig(). f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola system setup 87 designer reference manual ? 3-ph . pmsm torque vector control section 6. system setup 6.1 contents 6.2 application description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87 6.3 application set-up . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 6.4 projects files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .97 6.5 application build & execute . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 6.6 warning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100 6.2 application description the vector control algorithm is ca lculated on the mo torola dsp56f805. the algorithm generates the 3-pha se pwm signals for permanent magnet (pm) synchr onous motor inverter accord ing to the user-required inputs, measured and calculated signals. the concept of the pmsm drive inco rporates the foll owing hardware components:  bldc motor-brake set  3-phase ac/bldc high voltage power stage  dsp56f805evm boards  ecoptinl - in-line optoisola tion box, which is connected between the host comput er and the dsp56f805evm the bldc motor--brake set incor porates a 3-phase bldc motor and attached bldc motor brake. the bl dc motor has si x poles. the incremental position sensor (encoder) is coupled on the motor shaft and position hall sensors are mounted between the motor and the brake. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 88 system setup motorola they allow to position sensing if r equired by the cont rol algorithm. the detailed motor--brake spec ifications are listed in table 6-1. note: the application software is targeted for pm synchrono us motor with sine-wave back-emf shape. in this particular demo application, the bldc motor is used instead, due to the availability of the bldc motor--brake sm40v+sg40n, suppl ied as ecmtrhi vbldc. although the back-emf shape of this motor is not ideally sine-wave, it can be controlled by the application soft ware. the drive parameters will be improved when a pmsm motor with an exact sine-wave back-emf shape is used. the drive can be controlled in two different operating modes:  manual operating mode - the r equired speed is set by up/down push buttons and the drive is started and stopped by the run/stop switch on the evm board. table 6-1. motor--brake specifications motor characteristics motor type 6 poles, 3-phase, star connected, bldc motor speed range 2500 rpm (at 310v) max. electrical power 150 w phase voltage 3*220v phase current 0.55a drive characteristics speed range < 2500 rpm input voltage 310v dc max dc bus voltage 380 v control algorithm current closed loop control optoisolation required motor characteristics motor type 6 poles,3-phase, star connected, bldc motor speed range 2500 rpm (at 310v) max. electrical power 150 w f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup application description DRM018 ? rev. 0 designer reference manual motorola system setup 89  pc master software operati ng mode - the required torque producing current is set by the pc master software. measured quantities:  dc bus voltage  phase currents (phase a, phase b, phase c)  power module temperature  rotor speed the faults used for drive protection:  overvoltage (pc master software error message = overvoltage fault )  undervoltage (pc master software error message = undervoltage fault )  overcurrent (pc master software error message = overcurrent fault )  overheating (pc master software error message = overheating fault ) 6.2.1 drive protection the dc bus voltage, dc bus current and power stage temperature are measured during t he control process. they prot ect the drive from over voltage, undervoltage, ov ercurrent and overheati ng. the undervoltage and overheating protection is pe rformed by software, while the overcurrent and over volt age fault signal util izes a fault input of the dsp. the power stage is identified using boa rd identification. if the correct power stage is not identi fied, the fault ?wrong po wer stage? disables the drive operation. line voltage is measured during a pplication initialization and the application automatically adjusts itself to run at either 115v ac or 230v ac, depending on the measured value. if any of the above-ment ioned faults occur, the motor control pwm outputs are disabled to protect the dr ive, and the application enters the fault state. the f ault state can be left only when the fault conditions f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 90 system setup motorola disappear and the run/stop switch is move d to the stop position manual mode and by the pc master soft ware in the pc master software remote mode. the application can run on:  external ram or flash  3-phase ac/bldc low-voltage po wer stage powered by 12 dc  manual or pc master software operating mode the correct power stage and vo ltage level is identifi ed automatically and the appropriate c onstants are set. the 3-phase pm synchronous motor co ntrol application can operate in two modes: 1. manual operating mode the drive is controlled by the ru n/stop switch (s6). the motor torque producing current is set by the up (s2-irqb) and down (s1-irqa) push buttons; see figure 6-1 . if the application runs and motor spinning is disabled (i .e., the system is ready) the user led (led3, shown in figure 6-2 ) will blink. when motor spinning is enabled, the user led is on . refer to table 6-2 for application states. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup application description DRM018 ? rev. 0 designer reference manual motorola system setup 91 figure 6-1. run/stop switch and up/down buttons at dsp56f805evm figure 6-2. user and pw m leds at dsp56f805evm f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 92 system setup motorola 2. pc master software the drive is controlled remotely from a pc through the sci communication channel of the dsp device vi a an rs-232 physical interface. the drive is enabled by the run/stop switch, which can be used to safely stop the appl ication at any time. pc master software enables to set the requi red torque producing current of the motor. the following pc master software control actions are supported, pc master software displays th e following information:  required torque produci ng current of the motor  actual torque producing current of the motor  application status - init/stop/run/fault  dc bus voltage level  identified line voltage  fault status - no_fault/overvoltage/overcu rrent/undervoltage/overheating  identified power stage start the pc master software window?s application, 3ph_pmsm_vector_control.pmp . figure 6-3 illustrates the pc master software control window after this project has been launched. note: if the pc master softwa re project (.pmp file) is unable to control the application, it is possible that th e wrong load map (. elf file) has been selected. pc master software uses the load m ap to determine addresses for global variables being monitored. once the pc master table 6-2. motor application states application state motor state green led state stopped stopped blinking at a frequency of 2hz running spinning on fault stopped blinking at a frequency of 8hz f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup application set-up DRM018 ? rev. 0 designer reference manual motorola system setup 93 software project has been launched, this option may be selected in the pc master software window under proj ect/select other map filereload. figure 6-3. pc master software control window 6.3 application set-up figure 6-4 illustrates the hardware set-up for the 3-phase pm synchronous motor c ontrol application. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 94 system setup motorola figure 6-4. set-up of t he 3-phase pm synchronous mo tor control application using dsp56f805evm the correct order of phases (phase a, phase b, phase c) for the pm synchronous motor is:  phase a = white wire  phase b = red wire  phase c = black wire when facing a motor shaft, if the phase order is: phas e a, phase b, phase c, the motor shaft should rotate clockwise (i.e., positive direction, positive speed). f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup application set-up DRM018 ? rev. 0 designer reference manual motorola system setup 95 for detailed information, see the dsp56f805 eval uation module hardware reference manual. the serial cable is needed for the pc master software debugging/control. the system consists of the following components:  bldc motor type sm 40v, em brno s.r.o., czech republic  load type sg 40n, em brno s.r.o., czech republicdsp56f805 board:  encoder bhk 16.05a1024-12-5, baumer electric, switzerland  3-ph ac bldc lv power stage 180w  serial cable - needed for the pc master software debugging tool only.  the parallel cable - needed for the metrowerks code warrior debugging and s/w loading.  command converter cable - needed for th e dsp56f805 controller board only. for detailed information, refer to the dedicated applic ation note (see references). 6.3.1 application se tup using dsp56f805evm to execute the three-phase pm sync hronous motor vector control, the dsp56f805evm board requires t he strap settings shown in figure 6-5 and table 6-3 . f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 96 system setup motorola figure 6-5. dsp56f805e vm jumper reference jg8 jg9 dsp56f805evm jg3 1 j29 jtag jg14 1 p3 user s/n led3 p1 y1 u1 u15 s2 s3 3 1 2 jg13 s1 s4 s5 s6 p1 pwm 4 7 3 6 9 jg12 1 3 2 jg13 1 3 2 j23 j24 jg6 jg1 jg2 1 1 jg9 jg7 jg5 u9 u10 jg4 1 jg8 reset irqb irqa run/stop gp2 gp1 1 2 7 8 jg4 1 2 7 8 jg3 3 1 2 jg12 31 4 jg14 jg10 6 9 7 jg10 1 jg1 3 1 jg6 3 1 jg2 3 jg5 jg15 3 1 jg11 3 1 jg16 3 1 jg15 1 jg16 1 jg11 1 jg18 jg17 jg17 jg18 jg7 table 6-3. dsp56f805 evm jumper settings jumper group comment connections jg1 pd0 input selected as a high 1-2 jg2 pd1 input selected as a high 1-2 jg3 primary uni-3 serial selected 1-2, 3-4, 5-6, 7-8 jg4 secondary uni-3 serial selected 1-2, 3-4, 5-6, 7-8 jg5 enable on-board parallel jtag command converter interface nc jg6 use on-board crystal for dsp oscillator input 2-3 jg7 select dsp?s mode 0 operation upon exit from reset 1-2 jg8 enable on-board sram 1-2 jg9 enable rs-232 output 1-2 f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup projects files DRM018 ? rev. 0 designer reference manual motorola system setup 97 note: when running the evm target system in a stand-alone mode from flash, the jg5 jumper must be set in the 1-2 configur ation to disable the command converter para llel port interface. 6.4 projects files the three-phase pm synchronous motor torque vector control application is composed of the following files:  ...\3pmsm_tvc_sa\3pmsm_tvc.c, main program  ...\3pmsm_tvc_sa\3pmsm_tvc.mcp, application project file  ....\3pmsm_tvc_sa\applic ationconfig\appconfig.h, application configuration file  ...\3pmsm_tvc_sa\systemconfig \extram\linker_ram.cmd, linker command file for external ram  ...\3pmsm_tvc_sa\systemconfig \flash\linker_flash.cmd, linker command file for flash  ...\3pmsm_tvc_sa\systemconfig\flash\flash.cfg, configuration file for flash jg10 secondary uni-3 analog temperature input unused nc jg11 use host power for host target interface 1-2 jg12 primary encoder input selected for hall sensor signals 2-3, 5-6, 8-9 jg13 secondary encoder input selected 2-3, 5-6, 8-9 jg14 primary uni-3 3-phase current sense selected as analog inputs 2-3, 5-6, 8-9 jg15 secondary uni-3 phase a over current selected for faulta1 1-2 jg16 secondary uni-3 phase b overcurrent selected for faultb1 1-2 jg17 can terminat ion unselected nc jg18 use on-board crystal for dsp oscillator input 1-2 table 6-3. dsp56f805 evm jumper settings jumper group comment connections f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 98 system setup motorola  ...\3pmsm_tvc_sa\pcmast er\3pmsm_tvc.pmp , pc master software file these files are located in the application folder.  ...\controller_new.c, .h : source and header f iles for pi controller  ...\ramp.c, .h : source and header f iles for ramp generation  ...\svm.c, .h : source and header files for space vector modulation  ...\cptrfm.c, .h : source and header f iles for clark and park transformation  ...\mfr16.c, .h, mfr32.c, .h, mfr3 2sqrt.asm, portasm.h : source, header and asm files providing fractional math intrinsics all the necessary resources (algorit hms and peripheral drivers) are part of the application project file.  ...\3pmsm_tvc\src\include , folder for general c-header files  ...\3pmsm_tvc\src\dsp56805 , folder for the device specific source files, e.g. drivers  ...\3ph_pmsm_vector_contro l_sa\src\pc_master_support , folder for pc master software source files  ...\3pmsm_tvc\src\algorithms\ , folder for algorithms 6.5 application build & execute when building the three-phase pm sy nchronous motor vector control, the user can create an appl ication that runs from internal flash or external ram . to select the type of appl ication to build, open the 3ph_pmsm_vector_control.mcp project and select t he target build type, as shown in figure 6-6 . a definition of the projec ts associated with these target build types ma y be viewed under the targets tab of the project window. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup application build & execute DRM018 ? rev. 0 designer reference manual motorola system setup 99 figure 6-6. target build selection the project may now be bui lt by executing the make command, as shown in figure 6-7 . this will build and lin k the three-phase pm synchronous motor torque vect or control application. figure 6-7. execute make command f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 100 system setup motorola to execute the three-phase pm sync hronous motor vector control application, select project\debug in the codewarrior ide, followed by the run command. for more help with these comm ands, refer to the codewarrior tutorial documentation in the following file located in the codewarrior installation folder: <...>\codewarrior documentation\pdf\ targeting_dsp56800.pdf if the flash target is selected, c odewarrior will autom atically program the internal flash of the dsp with the executable generated during build . if the external ram target is sele cted, the executable will be loaded to off-chip ram. once flash has been progr ammed with the execut able, the evm target system may be run in a stand-alone m ode from flash. to do this, set the jg5 jumper in the 1-2 co nfiguration to disable t he parallel port, and press the reset button. once the applicat ion is running, move the ru n/stop switch to the run position and set the r equired speed using the up/ down push buttons. pressing the up/down buttons shou ld incrementally increase the motor speed until it r eaches maximum speed. if successful, the motor will be spinning. note: if the run/stop switch is set to t he run position when the application starts, toggle the run/stop s witch between the stop and run positions to enable motor spinning. this is a pr otection feature that prevents the motor from starting when the applicat ion is executed from codewarrior. you should also see a lighted green led, which indicates that the application is running. if the application is stop ped, the gree n led will blink at a 2hz frequency. if an under voltage fault occurs, the green led will blink at a frequency of 8hz. 6.6 warning this application operates in an en vironment that includes dangerous voltages and rotating machinery. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup warning DRM018 ? rev. 0 designer reference manual motorola system setup 101 be aware that the ap plication power stage and optoisolation board are not electrically isol ated from the main s voltage - they ar e live with risk of electric shock when touched. an isolation transformer should be used when operating off an ac power line. if an isolation transformer is not used, power stage grounds and oscilloscope grounds are at differen t potentials, unless the oscilloscope is floating. note that probe grounds and, therefore, the case of a floated oscilloscope are subjec ted to dangerous voltages. the user should be aware that:  before moving scope probes, maki ng connections, etc., it is generally advisable to power down the high- voltage supply.  to avoid inadvertently touching li ve parts, use plastic covers.  when high voltage is applied, us ing only one hand for operating the test setup minimizes the po ssibility of el ectrical shock.  operation in lab setups that have grounded tables and/or chairs should be avoided.  wearing safety glasses, avoiding ties and jewelry, using shields, and operation by personnel trained in high-voltage lab techniques are also advisable.  power transistors, the pfc coil, and the motor can reach temperatures hot e nough to cause burns.  when powering down; due to stor age in the bus capacitors, dangerous voltages are present unt il the power-on led is off. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
system setup designer reference manual DRM018 ? rev. 0 102 system setup motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola references 103 designer reference manual ? 3-ph . pmsm torque vector control appendix a. references 1. design of brushless permanent-magnet motors , j.r. hendershot jr and t.j.e. miller, magna physics publishing and clarendon press, 1994 2. sensorless vector and direct torque control , p. vas (1998), oxford university press, isbn 0-19-856465-1, new york. 3. dsp56f80x 16-bit digital signa l processor, user?s manual, dsp56f801-7um/d, motorola, 2001 4. dsp56f800 16-bit di gital signal processor, family manual, dsp56f800fm/d, motorola, 2001 5. 3-phase ac/bldc low-voltage power stage user?s manual, memc3pbldclvum/d , motorola, 2000 6. user?s manual for pc master software , motorola, 2001 7. evaluation motor board user?s manual , memcevmbum/d, motorola 8. motorola embedded motion optois olation board user?s manual, memcobum/d, motorola, 2000 9. dsp parallel command converte r hardware user?s manual, mcsl, mc108um2r1 10. codewarrior for motorola dsp56800 emb edded systems, cwdsp56800, metrowerks, 2001. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
references designer reference manual DRM018 ? rev. 0 104 references motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
DRM018 ? rev. 0 designer reference manual motorola glossary 105 designer reference manual ? 3-ph . pmsm torque vector control appendix b. glossary ac ? alternating current adc ? analogue-to-digital converter brush ? a component transfering elektric al power from non-rotational terminals, mounted on t he stator, to the rotor. bldc ? brushless dc motor commutation ? a process providing the cr eation of a rotation field by switching of power transistor (ele ctronic replacement of brush and commutator). commutator ? a mechanical device alte rnating dc current in dc commutator motor and providing rotation of dc commutator motor. cop ? computer operat ing properly timer dc ? direct current dsp ? digital signal prosessor dsp56f80x ? a motorola family of 16- bit dsps dedicated for motor control. dt ? see ?dead time (dt)? dead time (dt) ? a short time that must be inserted between the turning off of one transistor in the inverter half bridge and turning on of the complementary transi stor due to the limited switching speed of the transistors. duty cycle ? a ratio of the amount of time the signal is on versus the time it is off. duty cycle is us ually represented by a percentage. gpio ? general purpose input/output f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
glossary designer reference manual DRM018 ? rev. 0 106 glossary motorola hall sensors - a position sensor giving six defined events (each 60 electrical degrees) per el ectrical revolution (f or 3-phase motor). hv - high voltage interrupt ? a temporary break in the sequential exec ution of a program to respond to signals fro m peripheral devices by executing a subroutine. input/output (i/o) ? input/output interfac es between a computer system and the external world. a cpu reads an input to sense the level of an external signal an d writes to an output to change the level on an external signal. jtag ? interface allowing on-chi p emulation and programming led ? lignt emiting diode logic 1 ? a voltage level approximately equal to the inpu t power voltage (v dd ). logic 0 ? a voltage level approximatel y equal to t he ground voltage (v ss ). lv - low voltage pi controller ? proportional-in tegral controller phase-locked loop (pll) ? a clock generator circuit in which a voltage controlled oscillator produces an osci llation which is synchronized to a reference signal. pm ? permanent magnet pmsm - permanent magnet synchronous motor pwm ? pulse width modulation quadrature decoder ? a module providing de coding of po sition from a quadrature encoder mounted on a motor shaft. quad timer ? a module with four 16-bit timers reset ? to force a device to a known condition. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
glossary DRM018 ? rev. 0 designer reference manual motorola glossary 107 rpm ? revolutions per minute sci ? see "serial communicati on interface module (sci)" serial communications inte rface module (sci) ? a module that supports asynchronous communication. serial peripheral inte rface module (spi) ? a module that supports synchronous communication. software ? instructions and data that control the operation of a microcontroller. software interrupt (swi) ? an instruction that causes an interrupt and its associated vector fetch. spi ? see "serial peripheral interface module (spi)." timer ? a module used to relate events in a system to a point in time. f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
glossary designer reference manual DRM018 ? rev. 0 108 glossary motorola f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .
how to reach us: usa/europe/locations not listed: motorola literature distribution; p.o. box 5405, denver, colorado 80217 1-303-675-2140 or 1-800-441-2447 japan: motorola japan ltd.; sps, technical information center, 3-20-1, minami-azabu minato-ku, tokyo 106-8573 japan 81-3-3440-3569 asia/pacific: motorola semiconductors h.k. ltd.; silicon harbour centre, 2 dai king street, tai po industrial estate, tai po, n.t., hong kong 852-26668334 technical information center: 1-800-521-6274 home page: http://motorola.com/semiconductors information in this document is provided solely to enable system and software implementers to use motorola products. there are no express or implied copyright licenses granted hereunder to design or fabricate any integrated circuits or integrated circuits based on the information in this document. motorola reserves the right to make changes without further notice to any products herein. motorola makes no warranty, representation or guarantee regarding the suitability of its products for any partic ular purpose, nor does motorola assume any liability arising out of the app lication or use of any product or circuit, and specifically disclaims any and all liability, including withou t limitation consequential or incidental damages. ?typical? parameters which may be provided in motorola data sheets and/or specifications can and do vary in different applications and actual performance may vary over time. all operating parameters, including ?typicals? must be validated for each customer application by customer?s technical experts. motorola does not convey any license under its patent rights nor the rights of others. motorola products are not desig ned, intended, or authorized for use as components in systems intended for surgical implant into the body, or other applications intended to support or sustain life, or for any other application in which the failure of the motorola product could create a situation where personal injury or death may occur. should buyer purchase or use motorola products for any such unintended or unauthorized application, buyer shall indemnify and hold motorola and its officers, employees, subsidiaries, affiliates, and distributors harmless against all claims, costs, damages, and expenses, and reasonable attorney fees arising out of, directly or indirectly, any claim of personal injury or death associated with such unintended or unauthorized use, even if such claim alleges that motorola was negligent regarding the design or manufacture of the part. motorola and the stylized m logo are registered in the u.s. patent and trademark office. digital dna is a trademark of motorola, inc. all other product or service names are the property of their respective owners. motorola, inc. is an equal opportunity/affirmative action employer. ? motorola, inc. 2003 DRM018/d f r e e s c a l e s e m i c o n d u c t o r , i freescale semiconductor, inc. f o r m o r e i n f o r m a t i o n o n t h i s p r o d u c t , g o t o : w w w . f r e e s c a l e . c o m n c . . .


▲Up To Search▲   

 
Price & Availability of DRM018

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X