Home

DRM020 Reference Manual

image

Contents

1. The corresponding voltage amplitude is calculated according to the Volt per Hertz ramp Thus both parameters for PWM generation are available Table inc Amplitude Designer Reference Manual DRMO20 Rev 0 46 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Software Implementation PI CONST timeout Deceleration Over Voltage Protection NO Over Voltage Overvoltage Acceleration Deceleration Ramp Tacho Speed Calculation PI Speed Controller Figure 4 6 Pl CONST Timeout Routine DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 47 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 5 Software Listing The software listing is also available for this application Special attention was given to the modularity of the code The code is written in C Metrowerks CodeWarrior for MC68HCO08 microcontrollers The software consists of the following parts Designer Reference Manual MAIN C It is the entry point following a Reset It contains the Initialize Software Routine code the Main state machine with the Software Timer SPEED C It contains READ_CONST Timeout code Scan Inputs OM Distribution Speed Calculation Manual OM Speed Calculation Demo OM Fault Detection Run Enable Fault Recovery LED Driver RAMP
2. Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator Section 3 Hardware Design 3 1 Contents 3 2 System Configuration ssaa vr CORR RR Eo 19 3 4 MC68HC908MR32 Control Board 2 2 ossa 21 3 4 3 Phase AC BLDC High Voltage Power Stage 23 3 5 Optoisolation Board c ccscecrveeecassecensceadween ed ss 25 3 6 AC Induction Motor with Speed Tachogenerator 27 E oes cds E AA NU EE Od Rd 27 48 Hardware Documentation n a cided deca aeaea 29 3 2 System Configuration The application is designed to drive the 3 phase AC motor It consists of the following modules see Figure 3 1 e MC68HC908MR32 control board e 3 phase AC BLDC high voltage power stage e Optoisolation board e 3 phase AC induction motor with speed tachogenerator DRM020 Rev 0 Designer Reference Manual MOTOROLA Hardware Design 19 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design J032euuo pieog J9J 0 3u05D ajqeo uoqqu 32l MOb 1dOO4 peog uogejosiogdo z rar T Tac 2Q I82VAIH L dOOH EN A ys a L 1 Te vit LL 1 L 1 Ll 1 9 ge uoqqu 3ey MOb QNS lt DAAT uononpu Ov eseud e oDe1js J9MOd obe3oA ubiH oqi1g ov ydg cn ZH I9 6r OVAOVvcC 00T Figure 3 1 Hardware Configuration DRMO20 Rev 0 Designer Reference
3. flag is analyzed and the state of the drive is set The state diagram of the drive describes Figure 4 2 The status LED s are controlled according to the system state The calculated speed command V command is a 2 byte variable with format 8 8 1Hz 0x10 This format is kept through all the program for all the speed variables Designer Reference Manual MOTOROLA Software Design 35 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 3 2 Acceleration Deceleration Ramp 4 3 3 Speed Sensor 4 3 4 PI Controller Designer Reference Manual The process calculates the new actual speed command based on the required speed according to the acceleration deceleration ramp During deceleration the motor can work as a generator In the generator state the DC Bus capacitor is charged and its voltage can easily exceed its maximal limit Therefore the DC Bus voltage is measured and compared with the limit In case of deceleration over voltage the deceleration is interrupted and the motor runs with constant speed in order to discharge the capacitor Then the deceleration can continue The speed sensor process utilizes the IC function It reads the time between the following rising edges of the speed sensor output and calculates the actual motor speed V tacho Also a software filter of the speed measurement can be incorporated in the process for better noise immunit
4. 0x00 pos center PWM COP and LVI enabled 0x60 neg center PWM COP and LVI enabled Designer Reference Manual DRM020 Rev 0 42 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Software Implementation PMOD 0x00e6 set up PWM modulus gt PWM frequency for 7 3728MHz Bus Frequency PWM MODULUS 0x00e6 gives 16kHz PWM DEADTM 15 2usec deadtime 15 for Bus freq 7 3728MHz DISMAP Oxff when PWM disabled disable PWM1 6 PCTL2 0x80 PWM interrupt every 4th PWM loads PCTL1 0xc0 disable MCPWM PWMOUT 0x00 output port control is PWM gen PCTL1 0x02 set LDOK bit FCR 0x08 Flt2 enabled in manual mode PVAL1 PWM MODULUS 2 set phase A pwm to 50 PVAL3 PWM MODULUS 2 set phase B pwm to 50 PVAL5 PWM MODULUS 2 set phase C pwm to 50 ll When all modules of the microcontroller are initialised enable the PWM module PCTL1 0x20 enables PWM interrupts PCTL1 0x01 enables PWM 4 4 2 Software Timer The software timer routine provides the timing sequence for required subroutines The software timer is performed instead of an Output Capture interrupt handler because of lack of interrupt priority in the HCO8 MCU The main program has several time demanding interrupt routines and more interrupt requirements can cause a soft
5. For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup Jumper Settings of Controller Board oscilloscope grounds are at different potentials unless the oscilloscope is floating Note that probe grounds and therefore the case of a floated oscilloscope are subjected to dangerous voltages The user should be aware that e Before moving scope probes making connections etc it is generally advisable to power down the high voltage supply To avoid inadvertent touching live parts use plastic covers e When high voltage is applied using only one hand for operating the test setup minimizes the possibility of electrical shock e Operation in lab setups that have grounded tables and or chairs should be avoided e Wearing safety glasses avoiding ties and jewelry using shields and operation by a personnel trained in high voltage lab techniques is also advisable e Power transistors the PFC coil and the motor can reach temperatures hot enough to cause burns e When powering down due to storage in the bus capacitors dangerous voltages are present until the power on LED is off 5 4 Jumper Settings of Controller Board DRMO020 Rev 0 The MC68HC908MR32 control board jumper settings shown in Figure 5 2 and Table 5 1 are required to execute the 3 phase AC motor control application with tachogenerator For a detailed description of the jumper settings refer to the MC6
6. 8 bit MCUs MCS Motor Control System MCU Microcontroller Unit A complete computer system including a CPU memory a clock oscillator and input output I O on a single integrated circuit MR32 908MR32 Motorola MC68HC908MR32 microcontroller dedicated for motor control applications phase locked loop PLL A clock generator circuit in which a voltage controlled oscillator produces an oscillation which is synchronized to a reference signal PVAL PWM value register of motor control PWM module of MC68HC908MR32 microcontroller It defines the duty cycle of generated PWM signal PWM Pulse Width Modulation reset To force a device to the known condition SCI See serial communications interface module SCI serial communications interface module SCI A module that supports asynchronous communication serial peripheral interface module SPI A module that supports synchronous communication software s w 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 SR switched reluctance motor timer A module used to relate events in a system to a point in time Designer Reference Manual DRMO20 Rev 0 64 Glossary MOTOROLA For More Information On This Product Go to www freescale com Freescale Semic
7. Designer Reference Manual DRMO20 Rev 0 4 MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRMO020 Rev 0 List of Sections Section 1 Introduction 13 Section 2 System Description 15 Section 3 Hardware Design 19 Section 4 Software Design 31 Section 5 System Setup 53 Appendix A References 61 Appendix B Glossary ees 63 Designer Reference Manual MOTOROLA 5 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc List of Sections Designer Reference Manual DRMO20 Rev 0 6 MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRMO020 Rev 0 1 2 1 3 2 1 2 2 2 3 3 1 3 2 3 3 3 4 3 5 3 6 3 7 3 8 4 1 4 2 Table of Contents Section 1 Introduction COMETE TNR CETT TITTEN 13 Application Functionality secu adware se RT Ran 13 Benefits of the Solution 020 0 eee eaee 14 Section 2 System Description c quc C os ad doe ch ee E E E COLO eh ae oe 15 System Concept s osanaan hah
8. Manual MOTOROLA Hardware Design For More Information On This Product 20 Go to www freescale com Freescale Semiconductor Inc Hardware Design MC68HC908MR32 Control Board 3 3 MC68HC908MR32 Control Board Motorola s embedded motion control series MR32 motor control board is designed to provide control signals for 3 phase AC induction 3 phase brushless DC BLDC and 3 phase switched reluctance SR motors In combination with one of the embedded motion control series power stages and an optoisolation board it provides a software development platform that allows algorithms to be written and tested without the need to design and build hardware With software supplied on the CD ROM the control board supports a wide variety of algorithms for AC induction SR and BLDC motors User control inputs are accepted from START STOP FWD REV switches and a SPEED potentiometer located on the control board Alternately motor commands can be entered via a PC and transmitted over a serial cable to DB 9 connector Output connections and power stage feedback signals are grouped together on 40 pin ribbon cable connector Motor feedback signals can be connected to Hall sensor encoder connector Power is supplied through the 40 pin ribbon cable from the optoisolation board or low voltage power stage The control board is designed to run in two configurations It can be connected to an MG8EMO8MR32 emulator via an M68CBLO8A impedance matched ri
9. Power 370 W Nominal Current 1 1A Speed Sensor Type Speed Tachogenerator Pole Number 16 3 7 Sensors 3 7 1 Speed Sensor DRMO020 Rev 0 The control algorithm requires speed and DC Bus voltage sensing and DC Bus over current detection Therefore these sensors are built on the power stage board Detailed schematics of the sensor circuits can be found in the user s manuals belonging to each board A 16 pole AC tachogenerator senses the actual speed of the motor The output of the tachogenerator is an AC sinewave signal its frequency corresponds to the motor speed For a motor speed of 3000 rpm 100Hz synchronous the tachogenerator output frequency is 400Hz 4 pole motor 16 pole tachogenerator The sinusoidal signal of the tachogenerator is filtered and transformed to a logic level square wave Designer Reference Manual MOTOROLA Hardware Design 27 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design Speed Sensor by a squaring circuit The generated square signal is fed to the microcontroller Input Capture block of the Timer A Channel3 The Input Capture function reads the time between two subsequent rising edges of the generated square wave The measured time corresponds to actual speed of the motor Low Pass Squaring Filter Circuit A Speed gt Input Capt
10. automatically because of complementary PWM mode selected during the PWM module initialisation Phase B 1 The phase B wave pointer is calculated as phase A wave pointer 1 3 of wave period 1 3 of ox f equals to 0x5555 2 Seecorresponding points 2 5 of the Phase A calculation 3 The result is loaded to the PVAL3 register PVAL4 register is loaded automatically because of complementary PWM mode Phase C 1 The phase C wave pointer is calculated as phase A wave pointer 2 3 of wave period 2 3 of ox f equals to 0xaaaa 2 Seecorresponding points 2 5 of the Phase A calculation 3 The result is loaded to the PVAL5 register PVAL6 register is loaded automatically because of complementary PWM mode DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 39 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 3 7 Fault Control The process is accessed regularly in the rate given by the set PWM frequency and the selected PWM interrupt prescaller register pcriz This process has to be repeated often enough compared to the wave frequency in order to generate the correct wave shape Therefore for 16kHz PWM frequency it is called each fourth PWM pulse and thus the PWM registers are updated in 4kHz rate each 250usec This process is responsible for fault handling The software accommodates two fault inputs DC Bus over current and DC Bus
11. over voltage DC Bus over current In case of over current the external hardware provides a rising edge on the fault input of the microcontroller FAULT2 This signal disables all motor control PWM s outputs PWM1 PWM6 and sets general fault flag Gf_ flag DC Bus over voltage The sensed DC Bus voltage is compared with the limit within the software In case of over voltage all motor control PWM outputs are disabled PCTL1 and the general fault flag G 1ag is set If any of the faults occurs the recovery time for the individual fault is loaded and till this time expires the system remains disabled 4 4 Software Implementation Designer Reference Manual The processes described above are implemented in a single state machine as illustrated in Figure 4 4 Figure 4 5 and Figure 4 6 The general software implementation incorporates the main routine entered from Reset and three interrupt states The Main Routine includes the initialisation of the microcontroller and a Software Timer for the control algorithm time base The interrupt states provide calculation of actual speed of the motor over current fault handler and PWM generation process DRMO20 Rev 0 40 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc 4 4 1 Initialisation Software Design Software Implementation The Main Routine provides initialisation of the microcontroller e cle
12. 1 Introduction 1 1 Contents 1 2 Application Functionality ace acr see dase Y SCR RR dads 13 1 3 Benefits of the Sall cuca wesc dees 6 eeeewe ee ee es 14 1 2 Application Functionality This Reference Design describes the design of a 3 phase AC induction motor drive with tachogenerator speed sensor It is based on Motorola s MC68HC908MR32 microcontroller which is dedicated for motor control applications The system is designed as a low cost motor drive system for medium power three phase AC induction motors and is targeted for applications in both industrial and appliance fields e g washing machines compressors air conditioning units pumps or simple industrial drives The drive runs in a speed closed loop using a speed sensor The code can easily be modified to run the drive in open loop if it is required by the application The drive to be introduced is intended as a reference platform for a 3 phase AC induction motor drive It can be used as a good starting point for user s own design of his application according to his special requirements It can save a lot of development engineering time and speed up the time to market The Reference Design incorporates both hardware and software parts of the system including hardware schematics and layout with a bill of material and a software listing DRMO020 Rev 0 Designer Reference Manual MOTOROLA Introduction 13 For More Information On This Product Go to www f
13. 53 Congo RIGGING 5 44 ioe Kee RHOD DEO CRURA ROC CC 58 5 5 USER LEDs PWM LEDs and RESET 59 Designer Reference Manuals MOTOROLA 9 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc List of Figures Designer Reference Manuals DRM020 Rev 0 10 MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRMO020 Rev 0 Table List of Tables Title Page Electrical Characteristics of Control Board 22 Electrical Characteristics of Power Stage 25 Electrical Characteristics of Optoisolation Board 26 Motor Specifications Lua aa e ace oi Ok ow AO REOR RR R Ewa 27 Memory UGA unns done R Ed dog a we R9 odd RC oa dor ra 51 MR32 Modules Usage 4 css sch ee ede iG ds coe ROIG RR 51 MC68HC908MR32EVM Jumper Settings 56 Motor Application States icio luas s sr mmm ER REG 60 Designer Reference Manual MOTOROLA 11 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc List of Tables Designer Reference Manual DRM020 Rev 0 12 MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator Section
14. 8HC908MR32 Control Board User s Manual Motorola document order number MEMCMR32CBUM D Designer Reference Manual MOTOROLA System Setup 55 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup sfo 6 Pafo o o o JP1 om vP7Lo e D e p6 Di 2 2 2 2 2 EJE e E F 5 EJE amp amp amp 39 Mod intense tete a Hel 40 2 JPT 12 JP5 JP4 JP3 JP2 JP1 Motorola Te o o jolole 3t F x Lu 3 O lg 3 A n a n x o 5 eo I e nc e eo O I 5 J2 TO EMULATOR E JP6 1 irtiejein ts tete o el 40 2 2 D o C22 GNDA sw4 1 SPEED O O Lref Vref STOP F START RE Figure 5 2 MC68HC908MR32 Jumper Reference Table 5 1 MC68HC908MR32EVM Jumper Settings Jumper Group Comment Connections JP1 Tachometer input selected 1 2 JP2 Encoder input selected No connection JP3 Back EMF signals selected No connection Power factor correction zero cross JP4 No connection signal selected JP5 Power factor correction PWM signal selected No connection JP7 Power Supply connected to jack J3 1 2 Designer Reference Manual DRMO20 Rev 0 56 System Setup
15. C It contains code for ramps Acceleration Deceleration Ramp V Hz Ramp PI C It contains Pl CONST Timeout code Deceleration Over voltage Protection Tacho Speed Calculation PI Speed Controller and calls Acceleration Deceleration Ramp and V Hz Ramp appropriately FAULT C It contains Fault Interrupt Handler code PWMCALC C It contains PWM Calculation Interrupt Handler code TACHO C It contains Tacho Interrupt Handler code 3RDHQUAD H DRMO20 Rev 0 48 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Software Listing The header file contains the first quadrant of sinewave with its 3rd harmonic injection 256 unsigned 2 byte entries e RAM H It contains the global RAM variable definitions for the whole project e CONST H It contains the global constant definitions for the whole project e VECTORS H It contains the interrupt vectors DRM020 Rev 0 Designer Reference Manual MOTOROLA Software Design 49 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 6 Open Loop Drive Designer Reference Manual The system presented in this application note can also run in an open loop mode In this case the actual motor speed is not measured and the generated voltage frequency directly corresponds to the externally set speed command and is not cor
16. Freescale Semiconductor Inc eto ye mE digital dna intelligence everywhere 3 Phase AC Induction Motor Drive with Tachogenerator Using MC68HC908MR32 Designer Reference Manual M68HC08 Microcontrollers DRM020 D Rev 0 03 2003 MOTOROLA COM SEMICONDUCTORS For More Information On This Product Go to www freescale com Freescale Semiconductor Inc For More Information On This Product Go to www freescale com Freescale Semiconductor Inc 3 Phase AC Induction Motor Drive with Tachogenerator Using MC68HC908MR32 Designer Reference Manual Rev 0 by Radim Visinka Ph D Motorola Czech Systems Laboratories Roznov pod Radhostem Czech Republic DRMO020 Rev 0 Designer Reference Manual MOTOROLA 3 For More Information On This Product o to www freescale com Freescale Semiconductor Inc Revision history To provide the most up to date information the revision of our documents on the World Wide Web will be the most current Your printed copy may be an earlier revision To verify you have the latest information available refer to http www motorola com semiconductors The following revision history table summarizes changes contained in this document For your convenience the page number designators have been linked to the appropriate location Revision history Revision a Page Date Lavel Description Number s Feb 2003 1 Initial version N A
17. In case of a fault the fault recovery routine is entered and till the recovery time expires the drive stays disabled Finally the LED driver controls individual LEDs according to the status of the drive DRMO20 Rev 0 44 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Software Implementation READ_CONST timeout Operating Mode Distribution Speed Calculation Speed Calculation Manual OM Demo OM done done Fault Detection done Fault Recovery Run Enable Fault Recovery Return to scheduler Figure 4 5 READ_CONST Timeout Routine DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 45 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 4 4 PI CONST Timeout Routine This routine is accessed from the main software timer in Pl CONST rate The rate defines the time constant of the PI controller The following sequence is performed see Figure 4 6 During deceleration the DC Bus voltage is checked and in case of deceleration over voltage the deceleration is interrupted until the capacitor is discharged e When no deceleration over voltage is measured the acceleration deceleration speed profile is calculated e Actual motor speed is calculated e Pl speed controller is performed and the corrected motor frequency calculated
18. MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup Required Software Tools 5 5 Required Software Tools The application requires the following software development tools e Metrowerks CodeWarrior 2 for MC68HCO8 microcontrollers version 1 2 or later e PC master software version 1 2 0 11 or later 5 6 Building the Application To build this application open the 3ph acim vhz mop project file and execute the Make command see Figure 5 3 This command will build and link the motor control application along with all needed Metrowerks libraries jMetrowerks CodeWarrior File Edit View Search Project Debug Window Help a mn ub Ej vy Add Window Add Files g3ph AC VHz mcp Create Group 9 mms Greate Target MM Greate Seament Overlay Files Link Order Ta chec bax Cir Prepracess File SE Precompile E13 Dependencies AI NS EMEQSSDK Configu AMPIE GUT E n appcontig Disassemble GErl4 Shift F7 B config c 3 BB bspconfig Bring Up To Date Ctrl U Bl interrupts c B sys c Stop Build Ghrl Break C Sources H ASM Sources Remove Object Code Ctri Figure 5 3 Execute Make Command 1 Metrowerks and the Metrowerks logo are registered trademarks of Metrowerks Inc a wholly owned subsidiary of Motorola Inc 2 CodeWarrior is a registered trademark of Metrowerks Inc a wholly
19. Semiconductor Inc Software Design 4 3 1 Speed Command and LED Control The process has the following input parameters DIP Operating Mode Manual OM or Demo OM DIP OFF Demo Operating Mode DIP ON Manual Operating Mode Control Switches Start Stop Forward Reverse A D Converters potentiometer output for required speed DC Bus Voltage sensing General fault flag GE_flag The process has the following output parameters DC Bus voltage Dc bus volt Speed command V command DRMO20 Rev 0 34 Software Design For More Information On This Product Go to www freescale com MOTOROLA V_command lt gt 0 Start Stop 1 Run PWM enabled V_command 0 v_pi_out 0 DRM020 Rev 0 MCS State V_command lt gt 0 Freescale Semiconductor Inc Software Design Data Flow Reset Stand By MCS State PWM disabled General Fault Recovery 0 Fault Recovery MCS State PWM disabled Start Stop 1 V_command 0 General Fault 0 Start Stop 0 Fault MCS State PWM disabled Stop MCS State PWM disabled Over Current Over Voltage Figure 4 2 State Diagram of the Drive The input parameters of the process are evaluated and the speed command V command is calculated accordingly Also the DC Bus voltage Dc bus volt is measured The general fault G
20. The voltage signal is transferred through an optoisolation amplifier optional The measured DC Bus current is compared with the threshold and in case of over current a fault signal is generated The fault signal is connected to the microcontroller fault input FAULT2 Opto i Gain ifi Filter Amplifier Comparator DC Bus Over Current __ p Fault I gt D gt gt Fisense Optional i L 4 DC Bus Current Sensor SEE OE Figure 3 6 DC Bus Current Sensor Block Diagram 3 8 Hardware Documentation All the system parts are supplied and documented according to the following references e U1 MC68HC908MR32 Control Board supplied as ECCTR908MR32 DRMO020 Rev 0 Designer Reference Manual MOTOROLA Hardware Design 29 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design described in Motorola Embedded Motion Control MC68HC908MR32 Control Board User s Manual MEMCMR32CBUM D e U2 3 phase AC BLDC High Voltage Power Stage supplied in kit with Optoisolation Board as ECOPTHIVACBLDC described in Motorola Embedded Motion Control 3 Phase AC BLDC High Voltage Power Stage User s Manual MEMC3PBLDCPSUM D e U3 Optoisolation Board supplied with 3 ph AC BLDC High Voltage Power Stage as ECOPTHIVACBLDC orsupplied alone as ECOPT optoiso
21. a ER RR RRERS A 15 Volt per Hertz Control Technique 0055 17 Section 3 Hardware Design EONTIBEUS pedi dab d REO ee eh IDEA Caio c Pinar den o ees 19 System Cond 9a OL uad dd RU GE EROR dC seed ER 19 MC68HC908MR32 Control Board 2 00 5 21 3 Phase AC BLDC High Voltage Power Stage 23 DINSIBOIBRO Board i accio cde Rol oh RUF CE ORARE WR ER CR 25 AC Induction Motor with Speed Tachogenerator 27 CBS Leia ux did Ex EA P REP LIU OES d ure RET ia 27 Hardware Documaentelion iaa casser Rh RR RR 8 29 Section 4 Software Design COMENGE COLLA PAARE eee eae RE dn PREMO AR eee 31 MOCO 2 ed ood utr d ade api oca Red deba teh ey Wa BES 31 Designer Reference Manual MOTOROLA 7 For More Information On This Product Go to www freescale com Designer Reference Manual Freescale Semiconductor Inc Table of Contents 4 3 4 4 4 5 4 6 4 7 5 1 5 2 5 3 5 4 5 5 5 6 5 7 nk de bh a ee a ee ehh ds aan E i 2 31 Software Implementation 0 0 0 0 cece eee 40 Software Listing 2 0 254se0ccecisenderrivaddecbeerend 48 Open Loop Cs on dude eh Vb rd ene cM a Med ee dal 50 Microcontroller Usage L isoee sese rna ae ena 51 Section 5 System Setup iol p mPTCPE 53 Hardware DU Lusausawedada dades Mox Beard dade di dr 53 CIC ODD ONYRTTTTIILI QS 10100 ETTITTE 54 Jumper Settings of Controller Board 55 Required Software Tool
22. any of the above mentioned faults occurs the motor control PWM outputs are disabled in order to protect the drive and fault state of the system is displayed It is strongly recommended to use an opto isolation optocouplers and optoisolation amplifiers during the development time to avoid any damage to the development system 2 3 Volt per Hertz Control Technique DRMO020 Rev 0 The drive is designed as a Volt per Hertz drive It means that the control algorithm keeps constant magnetizing current flux of the motor by varying the stator voltage with frequency The commonly used Volt per Hertz ramp of a 3 phase AC induction motor illustrates Figure 2 2 Designer Reference Manual MOTOROLA System Description 17 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Description Designer Reference Manual Phase Voltage A Base Point 100 Boost v Voltage Z 4 Boost Base Frequency rpm Frequency Frequency Figure 2 2 Volt per Hertz Ramp The Volt per Hertz ramp is defined by the following parameters Base Point defined by Base Frequency usually 50Hz or 60Hz e Boost Defined by Boost Voltage and Boost Frequency The ramp profile is set to the specific motor and can be easily changed to accommodate different ones DRMO20 Rev 0 18 System Description For More Information On This Product Go to www freescale com MOTOROLA
23. ars RAM e initialises PLL Clock e initialises PWM module center aligned complementary PWM mode positive polarity MOR register COP and LVI enable MOR register PWM modulus defines the PWM frequency PMOD register 2usec dead time DEADTM register PWM interrupt reload every fourth PWM pulse PCTL2 register FAULT2 over current fault in manual mode interrupt enabled FCR register e sets up I O ports e initialises Timer B for IC and for software timer reference initialises Analog to Digital Converter sets up Operating Mode Manual OM or Demo OM e enables interrupts DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 41 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Input Capture Interrupt Reset IC Interrupt Handler Initialise Software Fault Interrupt timeout Fault Interrupt Handler Software Timer READ_CONST done timeout PWM Interrupt PWM Interrupt Handler done Figure 4 4 Software Implementation General Overview An example of initialisation of PLL Clock and Motor Control PWM Modules for MC68MC908MR32 is the following setup PLL clock PBWC 0x80 set Auto Bandwidth Control while PBWC amp 0x40 wait for PLL lock PCTL 0x30 use PLL clock setup Motor Control PWM module MOR 0x00
24. ate that the software takes some values from the user interface and sensors processes them and generates 3 phase PWM signals for motor control Designer Reference Manual MOTOROLA Software Design 31 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design The control algorithm of closed loop AC drive is described in Figure 4 1 It consists of processes described in the following sub sections The special attention is given to the 3 phase PWM calculation subroutines Also initialisation of the microcontroller is described in a detail Designer Reference Manual DRM020 Rev 0 32 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Data Flow Switches A D converters Operation Mode Jumper Process Speed Command Process Operating Mode Tacho IC Process Speed Sensor Dc bus volt V command Process Acceleration Deceleration Ramp V com actual Process PI Controller Process Fault Control V pi out Process OC Fault PCTL1 V Hz Ramp Amplitude Table inc Process PWM Generation PVAL1 PVAL3 PVAL5 Figure 4 1 Data Flow DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 33 For More Information On This Product Go to www freescale com Designer Reference Manual Freescale
25. bbon cable or it can operate using the daughter board The M68EMO8MR32 emulator board may be used in either an MMDS05 08 or MMEVS05 08 emulation system Figure 3 2 shows a block diagram of the board s circuitry DRMO020 Rev 0 Designer Reference Manual MOTOROLA Hardware Design 21 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design FORWARD REVERSE SPEED K OPTOISOLATED SWITCH POT TACHOMETER RS 232 I F TERMINAL START STOP TRI VF SPUR HALL EFFECT INPUTS 3 RESET EMULATOR cog Vica PROCESSOR Et CONNECTOR 6 E 2 OPTION SWITCHES REGULATED 000000 oe Poia POWER SUPPLY PWM LEDs 6 12 Vdc OPTO POWER DRIVER I O CONNECTOR E P dd N 40 PIN RIBBON OVERCURRENT en EOR ENIF CONNECTOR OVERVOLTAGE SENSE NPU INPUTS INPUTS PWM 6 MISC POWER AND OUTPUTS CONTROL I O Figure 3 2 MC68HC908MR32 Control Board The electrical characteristics in Table 3 1 apply to operation at 25 C Table 3 1 Electrical Characteristics of Control Board Characteristic Symbol Min Typ Max Units DC power supply voltage Vdc 10 8 12 16 5 V Quiescent current loc 80 mA Min logic 1 input voltage V D m MR32 IH an Max logic 0 input voltage V u MR32 IL Sp ow Propagation delay t
26. c 70 20002 500 mA DC DC converter Min Logic 1 Input Voltage Vin 2 0 V HCT logic Max Logic 0 Input Voltage ViL 0 8 V HCT logic Analog Input Range Vin 0 3 3 V Input Resistance Rin 10 kQ Analog Output Range Vout 0 3 3 V Digital Delay Time toby 0 25 us Analog Delay Time tADLY 2 us 1 Power supply powers optoisolation board only 2 Current consumption of optoisolation board plus DSP EVM board powered from this power supply 3 Maximum current handled by DC DC converters Designer Reference Manual DRMO20 Rev 0 26 Hardware Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design AC Induction Motor with Speed Tachogenerator 3 6 AC Induction Motor with Speed Tachogenerator In the application a general purpose 4 pole AC induction motor is used The 16 pole speed tachogenerator is coupled to the motor shaft Output of the tachogenerator is the AC sinewave signal corresponding to the motor speed It allows speed sensing of the motor required by the control algorithm Detailed specifications are listed in Table 3 4 In a target application a customer specific motor will be used Table 3 4 Motor Specifications JO i Sg 71 4B Motor Specification Motor Type 3 Phase AC Induction Motor Pole Number 4 Nominal Speed 1380 rpm Nominal Voltage 3 x 220 380 V Nominal
27. cessing Input Capture Microcontroller Figure 2 1 System Concept Designer Reference Manual DRMO20 Rev 0 16 System Description MOTOROLA For More Information On This Product Go to www freescale com WARNING Freescale Semiconductor Inc System Description Volt per Hertz Control Technique The control process is following The state of the sensors is periodically scanned in the software timer loop while the speed of the motor is calculated utilizing the Input Capture interrupt According to the operating mode setup and state of the control signals Start Stop switch Forward Reverse switch speed potentiometer the speed command is calculated using an acceleration deceleration ramp The comparison between the actual speed command and the tacho speed generates a speed error E The speed error is brought to the speed PI controller that generates a new corrected motor frequency Using a V Hz ramp the corresponding voltage is calculated The PWM generation process calculates a system of three phase voltages with required amplitude and frequency includes dead time and finally the 3 phase PWM motor control signals are generated The DC Bus voltage and DC Bus current are measured during the control process They are used for over voltage and over current protection of the drive The over voltage protection is performed by software while the over current fault signal utilizes a fault input of the microcontroller If
28. control algorithm According to the user interface input and feedback signals it generates 3 phase PWM output signals for the motor inverter For the drive a standard system concept is chosen see Figure 2 1 The system incorporates the following hardware parts e power supply rectifier e three phase inverter e optoisolation e feedback sensors DC Bus voltage DC Bus current tachogenerator for motor speed measurement e microcontroller MC68HC908MR32 The drive can basically be controlled in two different ways or operating modes that can be set by an on board jumper e In the Manual Operating Mode the required speed is set by Start Stop switch Forward Reverse switch and speed potentiometer DRM020 Rev 0 Designer Reference Manual MOTOROLA System Description 15 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Description In the Demo Operating Mode the required speed profile is pre programmed and the only control input is the Start switch Rectifier Three Phase Inverter DC Bus Q Line A Voltage J J 230V 50Hz Zs A Current amp BEES Isolation Barrier BEES Speed Sensing DC Bus Current Over amp C i PW DC Bus Voltage iu t po i OC Fault oltage P Processing rocessing V V Hz PWM Generator Speed Ee E with Setup i pee PI i Z Dead Time Command x Controller Processing Speed Actual Speed x Pro
29. ets 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 designed 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 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 Affirmat
30. gn MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator 5 1 Contents 5 2 5 3 5 4 99 5 6 5 7 5 2 Hardware Setup Section 5 System Setup Hardware Setup nnana annann 53 p E AEAEE a A E eee ITI TT 54 Jumper Settings of Controller Board 55 Required Software 1008 cccesacaciede vance we ea os 57 Building the Application i issus 3r XR Rd 57 Executing the Application nnana xor ore RR RERO C Rl 58 Figure 5 1 illustrates the hardware setup for the application It incorporates the following modules DRMO020 Rev 0 MC68HC908MR32 Control Board 3 phase AC BLDC High Voltage Power Stage Optoisolation Board 3 phase AC induction motor with speed tachogenerator Designer Reference Manual MOTOROLA System Setup 53 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup Freescale Semiconductor Inc AC Induction Motor apang Tachogenerator achogenerator Connector 125 Power Supply Moti Power M SS EL 12voc Connector l B i 3 ph AC BLDC 77 Power Stage l E E E D AC PowerLine ED Optoisolation B8HC90BMR32 Connector 7 1 Board zi Control Board Figure 5 1 Setup of the Application 5 3 Warning Designer Reference Manual DRMO020 Rev 0 54 System Setup MOTOROLA
31. iconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRM020 Rev 0 Appendix B Glossary AC Alternating Current ACIM AC Induction Motor ADC analogue to digital converter A D Converter analogue to digital converter BLDC brushless DC motor DC Direct Current DT see Dead Time DT Dead Time DT short time that must be inserted between the turning off of one transistor in the inverter half bridge and turning on of the complementary transistor 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 usually represented by a percentage interrupt A temporary break in the sequential execution of a program to respond to signals from peripheral devices by executing a subroutine input output I O Input output interfaces between a computer system and the external world A CPU reads an input to sense the level of an external signal and writes to an output to change the level on an external signal logic 1 A voltage level approximately equal to the input power voltage Voo logic 0 A voltage level approximately equal to the ground voltage Vss Designer Reference Manual MOTOROLA Glossary 63 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc MC68HC08 A Motorola family of
32. ive Action Employer Motorola Inc 2003 DRMO20 D For More Information On This Product Go to www freescale com
33. lation board described in Motorola Embedded Motion Optoisolation Board User s Manual MEMCOBUM D Detailed descriptions of individual boards can be found in comprehensive User s Manuals belonging to each board The manuals are available on the Motorola Web The User s Manual incorporates the schematic of the board description of individual function blocks and a bill of materials An individual board can be ordered from Motorola as a standard product Designer Reference Manual DRMO20 Rev 0 30 Hardware Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator 4 1 Contents 4 2 Introduction 4 3 Data Flow DRM020 Rev 0 4 2 4 3 4 4 4 5 4 6 4 7 Section 4 Software Design isos scenes ete dob der UR Ede P OU oed E deba 31 lk ucl FEM ae rc 31 Software Implementation 00 000 cee eee eee 40 Software Listing usa Od edem REA dnd OSE OREO RES 48 Open Loop Cees ob cia Xapiieic a hot dd a RC a CR eR Ee 50 Micr controller Usage 1 acaacieanie dei ao A GE CR CR RR CR CR RC 51 This section describes the design of the software blocks of the drive The software will be described in terms of Control Algorithm Data Flow State Transition Software Listing Software Modifications for Open Loop Drive Microcontroller Memory and Peripheral Usage The requirements of the drive dict
34. n Table 3 2 apply to operation at 25 C with a 160 Vdc power supply voltage DRMO20 Rev 0 24 Hardware Design For More Information On This Product Go to www freescale com MOTOROLA Freescale Semiconductor Inc Hardware Design Optoisolation Board Table 3 2 Electrical Characteristics of Power Stage Characteristic Symbol Min Typ Max Units DC input voltage Vdc 140 160 230 V AC input voltage Vac 100 208 240 V Quiescent current loc 70 mA Min logic 1 input voltage Vin 2 0 V Max logic 0 input voltage Vit E 0 8 V Input resistance Rin 10kQ Analog output range Vout 0 3 3 V Bus current sense voltage Isense 563 mV A Bus voltage sense voltage VBus 8 09 mV V Peak output current lpk 2 8 A ea dissipation Pai m 50 W nt dissipation Papi 100 Total power dissipation Pdiss 85 3 5 Optoisolation Board DRM020 Rev 0 Motorola s embedded motion control series optoisolation board links signals from a controller to a high voltage power stage The board isolates the controller and peripherals that may be attached to the controller from dangerous voltages that are present on the power stage The optoisolation board s galvanic isolation barrier also isolates control signals from high noise in the power stage and provides a noise robust systems architecture Signal translation is virtually
35. nnector J11 Current measuring circuitry is set up for 2 93 amps full scale Both bus and phase leg currents are measured A cycle by cycle over current trip point is set at 2 69 amps The high voltage AC power stage has both a printed circuit board anda power substrate The printed circuit board contains IGBT gate drive circuits analog signal conditioning low voltage power supplies power factor control circuitry and some of the large passive power components All of the power electronics which need to dissipate heat are mounted on the power substrate This substrate includes the power IGBTs brake resistors current sensing resistors a power factor correction MOSFET and temperature sensing diodes Figure 3 3 shows a block diagram DRM020 Rev 0 Designer Reference Manual MOTOROLA Hardware Design 23 For More Information On This Product Go to www freescale com Hardware Design Designer Reference Manual Freescale Semiconductor Inc HV POWER INPUT SIGNALS TO FROM CONTROL BOARD px BOARD ID BLOCK M el SWITCH MODE PFC CONTROL POWER SUPPLY DC BUS BRAKE 3 PHASE IGBT POWER MODULE GATE DRIVERS PHASE CURRENT PHASE VOLTAGE BUS CURRENT BUS VOLTAGE MONITOR N A ZERO CROSS BACK EMF SENSE 3 PHASE AC TO MOTOR Figure 3 3 3 Phase AC High Voltage Power Stage The electrical characteristics i
36. o u Hall sensor encoder input diy one Dis Analog input range Vin 0 5 0 V RS 232 connection speed 9600 Baud PWM sink current lpk 20 mA 1 When operated and powered separately from other Embedded Motion Control tool set products Designer Reference Manual DRMO20 Rev 0 22 Hardware Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design 3 Phase AC BLDC High Voltage Power Stage 3 4 3 Phase AC BLDC High Voltage Power Stage Motorola s embedded motion control series high voltage HV AC power stage is a 180 watt one fourth horsepower 3 phase power stage that will operate off of DC input voltages from 140 to 230 volts and AC line voltages from 100 to 240 volts In combination with one of the embedded motion control series control boards and an optoisolation board it provides a software development platform that allows algorithms to be written and tested without the need to design and build a power stage It supports a wide variety of algorithms for both AC induction and brushless DC BLDC motors Input connections are made via 40 pin ribbon cable connector J14 Power connections to the motor are made on output connector J13 Phase A phase B and phase C are labeled PH_A Ph_B and Ph_C on the board Power requirements are met with a single external 140 to 230 volt DC power supply or an AC line voltage Either input is supplied through co
37. on On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Microcontroller Usage 4 7 Microcontroller Usage Table 4 1 shows how much of memory is needed to run the 3 phase AC drive in the speed closed loop A significant part of the microcontroller memory is still available for other tasks Table 4 1 Memory Usage Kanior Available Used y MC68HC908MR32 FLASH 32 kBytes 3 7 kBytes RAM 768 Bytes 82 Bytes The MC68HC908MR32 microcontroller offers many features that simplify the drive design The following table describes individual available blocks and their usage for the introduced system Table 4 2 MR32 Modules Usage Module available on MC68HC908MR32 Used Purpose 3 phase PWM PWMMC yes generation fault protection Time base for control algorithm TACNT Timer A 4 channel yes Input Capture for measurement of actual motor speed TA3 Timer B 2 channel no SPI no SCI no I O ports yes User interface LEDs COP yes S W runaway protection IRQ no LVI yes Low voltage protection Speed set up ADC yes DC Bus voltage measurement POR yes Reset after Power ON DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 51 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Designer Reference Manual DRMO20 Rev 0 52 Software Desi
38. onductor Inc For More Information On This Product Go to www freescale com Freescale Semiconductor Inc 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 particular purpose nor does Motorola assume any liability arising out of the application or use of any product or circuit and specifically disclaims any and all liability including without limitation consequential or incidental damages Typical parameters which may be provided in Motorola data she
39. one for one Gate drive signals are passed from controller to power stage via high speed high dV dt digital optocouplers Analog feedback signals are passed back through HCNR201 high linearity analog optocouplers Delay times are typically Designer Reference Manual MOTOROLA Hardware Design 25 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design 250 ns for digital signals and 2 us for analog signals Grounds are separated by the optocouplers galvanic isolation barrier Both input and output connections are made via 40 pin ribbon cable connectors The pin assignments for both connectors are the same For example signal PWM_AT appears on pin 1 of the input connector and also on pin 1 of the output connector In addition to the usual motor control signals an MC68HC705JJ7CDW serves as a Serial link which allows controller software to identify the power board Power requirements for controller side circuitry are met with a single external 12 Vdc power supply Power for power stage side circuitry is supplied from the power stage through the 40 pin output connector The electrical characteristics in Table 3 3 apply to operation at 25 C and a 12 Vdc power supply voltage Table 3 3 Electrical Characteristics of Optoisolation Board Characteristic Symbol Min Typ Max Units Notes Power Supply Voltage Vdc 10 12 30 V Quiescent Current lo
40. owned subsidiary of Motorola Inc DRMO020 Rev 0 Designer Reference Manual MOTOROLA System Setup 57 For More Information On This Product Go to www freescale com Designer Reference Manual Freescale Semiconductor Inc System Setup 5 7 Executing the Application To execute the motor control application choose the Project Debug command in the CodeWarrior IDE followed by the Run command If the MMDS target is selected CodeWarrior will automatically download to the MMDS05 08 emulator The application can operate in two modes 1 Manual Operating Mode The drive is controlled by the START STOP switch SW3 The direction of the motor rotation is set by the FWD REV switch SW4 The motor speed is set by the SPEED potentiometer P1 Refer to Figure 5 4 for this description Forward Reverse Switch SW4 Fault POT Over Voltage Fault POT Over Current Start Stop Switch SW3 Figure 5 4 Control Elements DRM020 Rev 0 58 System Setup MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup Executing the Application RIESE I ea A nw bcleteramooerecmeneeres li AB se bL ELLE LL EAI i Sous 8 d 7 a gra ter rt SEIT Figure 5 5 USER LEDs PWM LEDs and RESET 2 Demo Operating Mode In the Demo Operating Mode the required speed profile is pre programmed and the only control input i
41. rected by any controller according to the actual motor speed Because the motor is asynchronous the actual motor speed varies with the mechanical motor load The higher mechanical load the higher slip of the motor and the lower motor speed Therefore the speed precision of the drive is not so high For some application such behaviour of the drive is not acceptable like washing machine some other can withstand it An example of the application can be a fan a compressor a pump etc where performance of the open loop drive is sufficient The advantage of the open loop drive is its relative simplicity of both hardware and software design compared to the closed loop system The open loop system design has the following modifications The hardware design doesn t require the speed transducer and speed sensing circuitry The software for Open Loop drive requires the following modifications see Figure 4 2 e Remove Process PI Controller e Remove Process Speed Sensor and disable IC Interrupt e Load an output of the Process Acceleration Deceleration ramp to an input of the Process Volt per Hertz ramp Set variable V out V com actual In the provided software the open loop control can be set during the software initialisation Speed control OPEN LOOP for open speed control loop Or Speed control CLOSED LOOP for closed speed control loop DRMO20 Rev 0 50 Software Design MOTOROLA For More Informati
42. reescale com Freescale Semiconductor Inc Introduction 1 3 Benefits of the Solution The design of very low cost variable speed 3 phase motor control drives has become a prime focus point for the appliance designers and semiconductor suppliers Replacing variable speed universal motors by maintenance free low noise asynchronous induction motors is a trend that supposes total system costs being equivalent The big push in this direction is given by several factors e new regulations dealing with electrical noise in power distribution lines and low power consumption e the flexibility that can be achieved in using asynchronous motors with variable frequency e the maturity level and affordable price trend of power devices e the system efficiency optimization that microprocessor controlled drives can provide e the size weight and dissipated power reduction of the motors for a given mechanical power Designer Reference Manual DRMO20 Rev 0 14 Introduction MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator Section 2 System Description 2 1 Contents 2 2 System LOI a is ed ed eke ade wieder as eweeeek ees 15 2 3 Volt per Hertz Control Technique 20055 17 2 2 System Concept The system is designed to drive a 3 phase AC induction motor The microcontroller runs the main
43. rs corresponds to the ZERO phase voltage But in the wave table the ZERO phase voltage corresponds to the number 0x00 Therefore the fetched wave value from the table must be added to the 50 PWM Modulation for quadrant 1 and 2 or substracted from the 50 PWM Modulation for quadrant 3 and 4 see point 5 of the process description Thus the correct PWM value is loaded The input parameters of the process are e The table increment Table inc that is used for the wave pointer update e Amplitude Amplitude of the generated inverter voltage The output parameters of the process are e PWM value for phase A PVAL1 register e PWM value for phase B PVALS register e PWM value for phase C PVAL5 register DRMO20 Rev 0 38 Software Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design Data Flow The process can be described by following points Phase A 1 Wave pointer for phase A is updated by the Table Increment 2 Based on the wave pointer of the phase the required wave quadrant is selected 3 The quadrant pointer is calculated from the wave pointer with respect to the related quadrant 4 Table value determined by quadrant pointer is fetched from the wave table 5 The table value is added to or substracted from the 50 modulus with respect to the related quadrant 6 The result is loaded to the PVAL1 register PVAL2 register is loaded
44. s cccs ceieiad Rue ERRARE RD 57 Building the Application nnana aaan aaa 57 Executing the Application naaa a aaaea aaan 58 Appendix A References Appendix B Glossary DRMO20 Rev 0 8 MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRMO020 Rev 0 List of Figures Figure Title Page 2 1 System CODnSODL Lad eex Xie bike RR e seed 16 2 2 Volt per Hertz Mamp ssaesassnseezusa ion ER ERESR ARE REA 18 3 1 Hardware Configuration isess oru Rh Ry RR RC e 20 3 2 MC68HC908MR32 Control Board 22 3 3 3 Phase AC High Voltage Power Stage 24 3 4 Speed Sensor Block Diagram slusls uss 28 3 5 DC Bus Voltage Sensor Block Diagram 28 3 6 DC Bus Current Sensor Block Diagram 29 S NS BIS FLY EIE OH X Vx ee OXON 33 4 2 State Diagram of the Drive lllllllslsslsssn 35 4 3 Closed Loop Control System lll sllslsus 37 4 4 Software Implementation General Overview 42 4 5 READ CONST Timeout Routine 5 45 4 6 PI CONST Timeout Routine 20000 47 5 1 Setup of the Application eked cb EG OKCCRORCE OR ER OC ds 54 5 2 MC68HC908MR32 Jumper Reference 56 5 3 Execute Make Command cccccassaewincceceaceuaeas 57
45. s the switch Start The pre programmed profile can be changed in the s w The drive is enabled by the START STOP switch which can be used to safely stop the application at any time The application states are displayed with on board LEDs If the application runs and motor spinning is disabled i e the system is ready the yellow status LED will be on When motor rotation is enabled the green status LED will be on and the actual state of the pulse width modulator PWM outputs are indicated with PWM output LEDs labeled PWM1 PWM6 If DC Bus over current DC Bus over voltage occurs the red fault LED will be turned on This fault state can be exited when the fault condition disappears and the safety fault time out expires Refer to Table 5 2 for a description of the application states and to Figure 5 5 for the on board LEDs position DRMO020 Rev 0 Designer Reference Manual MOTOROLA System Setup 59 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc System Setup Table 5 2 Motor Application States NOTE Designer Reference Manual Application State Motor State LED s State Stand By Stopped Yellow LED ON Run Spinning Green LED ON Fault Stopped Red LED ON Once the application is running e Move the START STOP switch SW3 from STOP to START e Select the direction of rotation by the FWD REV switch SW4 e Set the required speed by the SPEED poten
46. tiometer If successful the 3 phase AC induction motor will be spinning If the START STOP switch is set to the STAHT position when the application starts toggle the switch between the STOP and START positions to enable motor spinning This is a protection feature preventing the motor to start spinning when the application is executed from CodeWarrior DRMO20 Rev 0 60 System Setup MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Designer Reference Manual 3 Phase ACIM Drive with Tachogenerator DRM020 Rev 0 Appendix A References Motorola Inc 2001 68BHC908MR32 User s Manual MC68HC908MR32 D Motorola Inc 2000 Motorola Embedded Motion Control MC68HC908MR3 2 Control Board User s Manual MEMCMR32CBUM D Motorola Inc 2000 Motorola Embedded Motion Control 3 Phase AC BLDC High Voltage Power Stage User s Manual MEMC3PBLDCPSUM D Motorola Inc 2000 Motorola Embedded Motion Optoisolation Board User s Manual MEMCOBUM D Motorola Inc 1997 Making Low Distortion Motor Waveforms with the MC68HC708MP16 AN1728 Designer Reference Manual MOTOROLA References 61 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc References Designer Reference Manual DRM020 Rev 0 62 References MOTOROLA For More Information On This Product Go to www freescale com Freescale Sem
47. ure Figure 3 4 Speed Sensor Block Diagram 3 7 2 DC Bus Voltage Sensor The DC Bus voltage must be checked because of the over voltage protection requirement A simple voltage sensor is created by a resistor divider The voltage signal is transferred through the isolation amplifier and then amplified to the 5V reference level The amplifier output is connected to the A D converter of the microcontroller ATD1 Voltage Opto Divider Gain Amplifier DC Bus Voltage DC Bus Voltage E p gt gem to ADC Optional Figure 3 5 DC Bus Voltage Sensor Block Diagram Designer Reference Manual DRMO20 Rev 0 28 Hardware Design MOTOROLA For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Hardware Design Hardware Documentation 3 7 3 DC Bus Current Sensor The DC Bus current is checked because of the over current protection requirement A current sensing resistor is inserted into the ground path of the DC Bus lines The ground of the drive is created on the inverter side of the sense resistor This configuration advantage us that the voltage drop across the current sensing resistor has no influence on the gate driver signals Because of this configuration a positive DC Bus current creates a negative voltage drop on the current sensing resistor The voltage drop is amplified using an operational amplifier
48. ut of this process is the generated inverter frequency V pi out The outputs of this process are parameters required by PWM generation process e The table increment Table inc that corresponds to the frequency V pi out and is used to roll through the wave table in order to generate the output inverter frequency e Amplitude Amplitude ofthe generated inverter voltage Designer Reference Manual MOTOROLA Software Design 37 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design 4 3 6 PWM Generation Designer Reference Manual This process generates a system of three phase sinewaves or sinewaves with addition of third harmonic component shifted 120 each other The calculation is based on the wave table stored in ROM of the microcontroller The table describes either a pure sinewave or sinewave with third harmonic addition The second case is often preferred because it allows to generate a first harmonic sine voltage equal to the input AC line voltage Because of sine symmetry only one quadrant of the wave period is stored in the table The wave values for other quadrants are calculated from the first one The format of the stored wave table data is from 0x00 for ZERO Voltage up to PWM Modulus 2 for the 100 Voltage Thus the proper data scaling is secured It is important to note that 50 PWM or 50 of PWM Modulus loaded to the corresponding PVAL registe
49. ware fault The software timer routine has two timed outputs in READ CONST timeout there is a routine that scans inputs calculates speed command handles fault routines and the LED driver DRMO020 Rev 0 Designer Reference Manual MOTOROLA Software Design 43 For More Information On This Product Go to www freescale com Freescale Semiconductor Inc Software Design in PI_ CONST timeout there is a routine that provides over voltage protection during deceleration speed ramp acceleration deceleration Pl controller V Hz ramp and provides parameters for PWM generation The interrupt handlers have the following functions Input Capture Interrupt Handler reads the time between the two subsequent IC edges basic part of the Process Speed Sensor Fault Interrupt Handler takes care of over current fault interrupt over current part of the Process Fault Control PWM Interrupt Handler generates system of three phase voltages for the motor Process PWM Generation 4 4 3 READ CONST Timeout State This state is accessed from the main software timer in READ CONST rate Designer Reference Manual The following sequence is performed see Figure 4 5 All the inputs are scanned DC Bus voltage speed pot Start Stop switch Forward Reverse switch According to the operating mode the speed command is calculated The DC Bus voltage is compared with the over voltage limit Also over current fault flag is checked
50. y In this case the actual motor speed is calculated as average value of several measurements The speed closed loop control is characterized by a measurement of the actual motor speed This information is compared with the reference set point and the error signal is generated The magnitude and polarity of the error signal corresponds to the difference between actual and required speed Based on the speed error the PI controller generates the corrected motor frequency in order to compensate the error The general principle of the speed PI control loop is illustrated in Figure 4 3 DRMO20 Rev 0 36 Software Design MOTOROLA For More Information On This Product Go to www freescale com Reference Speed V_com_actual _ gt 4 3 5 V Hz Ramp DRM020 Rev 0 Freescale Semiconductor Inc Software Design Data Flow Corrected Speed Speed Eng PI WPL out Controlled Controller System Actual Motor Speed V_tacho Figure 4 3 Closed Loop Control System Process Description This process takes the input parameters actual speed command V_com_actual and actual motor speed measured by a tachogenerator V_tacho It calculates a speed error and performs the speed PI control algorithm The output of the PI controller is a frequency of the first harmonic sine wave to be generated by the inverter V pi out This process provides voltage calculation according to V Hz ramp The inp

Download Pdf Manuals

image

Related Search

Related Contents

Installation, Utilisation Et Entretien Des  取扱説明書  Samsung LA40F81B User Manual  Manuel d`utilisation  2016 Instructions  Willkommen  Tarseer user manual  BDB-250 - Super B    

Copyright © All rights reserved.
Failed to retrieve file