Home

STM3210B-MCKIT User Manual

image

Contents

1. For more information on how the demo works and on how a PMSM can be controlled with the STM32 refer to the UM0492 STM32 Sensorless Field oriented control software library ky 15 28 Running the starter kit UM0486 16 28 Starting the motor 1 Once you have checked the hardware configuration and connected the power supply as explained in Section 1 2 on page 9 press the Reset pushbutton Figure 4 shows the main screen of the PMSM demo Figure 4 PMSM main screen STM32 Motor Control PMSM FOC ver 1 0 Sensorless Demo Speed control Target Measured 01500 rpm 00000 Move tl Change 2 Press the Key pushbutton to start the motor Pressing the Key pushbutton again will stop the motor LCD display in speed control mode In Speed control mode the firmware allows modifying in real time the speed set point Figure 5 Main screen in run state STM32 Motor Control PMSM FOC ver 1 0 Measured 01500 rpm 01512 Move ti Change When the motor is running the LCD indicates the target as well as the measured speed Pressing the joystick up down increases or decreases the speed set point respectively Pressing the joystick to the right enters the Speed PI regulator set up screen Figure 6 Speed PI regulator set up screen STM32 Motor Control PMSM FOC ver 1 0 Speed P I 01000 00700 Target 01500 rpm Measured 00000 rpm Move tl Change The P
2. wy UM0486 Sf i User manual STM3210B MCKIT motor control starter kit Introduction The STM3210B MCKIT starter kit is an integrated system designed to provide a complete ready to use motor control application developed around the STMicroelectronics STM32 microcontroller This starter kit is particularly suited to drive 3 phase brushless motors either AC induction or permanent magnet types and demonstrates how effectively the STM32 microcontrollers can be used in real world motor control applications Drive is based on sensored field oriented control FOC for three phase motors using the shunt resistor current measurement method for closed loop torque control Position measurement is implemented using Encoder sensor or Tachometer The inverter is driven using the space vector PWM modulation technique You can run the STM3210B MCKIT starter kit in several ways Asaplug and play demo out of the box with the provided PMSM motor in open or closed loop e With an AC induction motor in standalone mode after programming the microcontroller However the main advantage of the STM3210B MCKIT is that you can use it to create your own applications and re program the STM32 microcontroller You can develop your own applications using the dedicated software libraries provided in the starter kit in conjunction with the EWARM KickStart Edition development environment from IAR In addition the PMSM and AC induction motor applications deli
3. 5 The motor included in the STM32 MCKIT starter kit is a SHINANO Inner rotor type 4 pole brushless DC motor with Hall sensor and encoder For electrical specifications and mechanical dimensions refer to the SHINANO datasheets on the STM32 MCKIT CD ROM e An auxiliary power supply block TR30R 6 e The following cables Motor cables 7 A motor connector HE10 34 pin cable 8 A USB cable 9 Two JTAG cables 10 A bag with three 0 1ohm resistors are included to configure the MB459B board for driving an AC induction motor The STM32 MCKIT CD ROM 1 1 2 Firmware The STM32 MCKIT provides two firmware binary files e The firmware for the PMSM motor e The firmware for the Selni AC induction motor When you receive the STM32 MCKIT the STM32 microcontroller is programmed by default with the PMSM standalone firmware 1 1 3 Software The STM32 MCKIT CD ROM includes the following software The PMSM and AC induction motor software libraries 6 28 Ti UM0486 STM32 MCKIT hardware setup 1 1 4 Documentation The STM32 MCKIT CD ROM also includes the following product documentation in PDF format STM82 MCKIT Motor Control Kit User Manual UM0486 the present manual e PMSM Field Oriented Control Software Library User Manual UM0492 AC Induction Motor IFOC Software Library User Manual UM0483 STM3210B EVAL User Manual UM0426 e MB459B Motor Control Evaluation Board User Manual UM0379 e JTAG Opt
4. proportional coefficient is active by default pressing the joystick up down increases or decreases its value respectively This can be done while the motor is running ky UM0486 Running the starter kit Pressing the joystick to the right a second time allows you to modify the integral coefficient Pressing the joystick to the right another time enters the Torque PI regulator set up screen Figure 7 Torque PI regulator set up screen STM32 Motor Control PMSM FOC ver 1 0 Torque F I 08000 01000 Target 01500 Iq Measured 00000 Iq Move ti Change This regulator can be tuned in the same way as the speed regulator Pushing the joystick twice to the right enters the Flux regulator settings screen Figure 8 Flux PI regulator set up screen STM32 Motor Control PMSM FOC ver 1 0 Flux P I 07500 01000 Target 07500 Id Measured 00000 Id gt Move ti Change Pushing the joystick twice to the right enters the Power stage status screen giving the current heat sink temperature and DC bus voltage Figure 9 Power stage status screen STM32 Motor Control PMSM FOC ver 1 0 Power Stage Status DC bus 024 Volt 020 Celsius Move Pushing the joystick on the right enters the Sensorless control settings screen to modify the rotor position observer gains K1 and K2 as well as the PLL gains this PLL provides the speed feedback for the spe
5. A IFOC ver 1 0 Speed P I D o6000 01000 00100 Target o3000 r pm Measured O0OO0000 rpm Move T4 Change STM32 Motor Control Am IFOC ver 1 0 Power stage status DCbus 000 Volt T 20 Celsius Move STM32 Motor Control AON IFOC ver 1 0 Torque P I D 00100 00020 o0000 Target o8sooo Iq Measured OOOOO Iq Move ti Change STMS2 Motor Control AOM IFOC ver 1 0 Signal on PBO iq Signal on PB1 iqref Move ti Change Pressing the joystick or the Key pushbutton starts the motor During the Speed control demo start up a linear torque ramp is applied to the motor until it reaches the minimum speed allowing to enter closed loop operation for torque and flux Then the speed PID regulator is enabled and takes over control of the torque reference 21 28 Running the starter kit UM0486 The final torque reference value is applied until the motor reaches the target speed or until a 3 seconds period is elapsed If the target speed is not reached after 3 seconds the state machine goes into FAULT state for two seconds and the Start up failed error message is displayed on the LCD If this happens you are strongly advised to check the speed sensor feedback connections first and if this is not sufficient to increase the STARTUP_FINAL_TORQUE parameter because the load torque is probably too high This parameter cannot be modified using the LCD interface It is necessary to rebuild the firmware library a
6. This indicates that the correct start up criteria were not met during the motor start up sequence Error on speed fdbck This returns an error on the speed position estimation by the sensorless algorithm the quality of the speed measurement expressed in terms of distribution around the mean value is not satisfactory This typically means that either the observer is not properly tuned or that the speed is so low that a good observation of the induced B emf is not possible e g rotor is locked Running your own PMSM motor To run your own motor using the standalone PMSM firmware follow the indications given in the Getting Started with the Library section of the UM0492 User Manual STM32 Sensored PMSM field oriented control software library TBD Based on your own motor parameters and hardware configuration you must edit and update the following files STM32F10x_conf h configuration header file MC_Control_Param h MC_encoder_Param h MC_PMSM_param h MC_State_Observer_param h MC_hall_param h Using the EWARM KickStart Edition with 32 KB limitation from IAR software you must then rebuild the project and load it onto the STM32 microcontroller The procedure for installing the IAR EWARM software and creating your own application is outlined in Section 3 on page 25 lt UM0486 Running the starter kit 2 2 2 2 1 Running an AC induction motor The AC induction motor firmware allows you to run the
7. is detected due to a problem with speed sensor connections or because the load torque is higher than the defined value for example then the final torque reference remains constant for 3 seconds Finally if if there s no valid information coming from the motor after 3 seconds the main state machine goes into FAULT state for two seconds and the Start up failed error message is displayed on the LCD If this happens you are strongly advised to check the speed sensor feedback connections first and if this is not sufficient to increase the final ramp torque reference because the load torque is probably too high UM0486 Running the starter kit Caution 2 2 3 2 2 4 In torque control mode operation a constant torque reference is produced Depending on the applied load torque this could lead to a constant acceleration of the motor making the speed rise up to the physical limits of the motor For more information about driving an AC induction motor refer to the UM0483 User Manual STM32 AC induction motor IFOC software library AC motor control variables that can be monitored You can select the following internal variables to be monitored la lb Phase a and b currents from ADC reading results alpha beta outputs of the clarke transformation Iq Id direct and quadrature currents output of the park transformation lq ref Id ref direct and quadrature current components set points Vq Vd direct and quadrat
8. motor in open or closed loop and to monitor and change various parameters on the fly This section provides a summary of the screen displays and settings Before you can use the STM32 MCKIT with an AC induction motor you must re program the STM32 microcontroller to use the AC induction motor firmware To do this you must 1 2 3 6 Set up the hardware as described in Section 1 3 on page 11 Connect the J link debugger to the opto isolation board with the 20 pin JTAG cable Connect the J link debugger to the host PC with the USB cable provided The POWER LED on the instrument turns on Power up the motor control kit Load the AC induction motor firmware into the flash memory of the STM32 microcontroller Disconnect the PC from the motor control kit Starting the motor 1 2 To initialize the system press the Reset pushbutton Press the Key pushbutton to start the motor Pressing the Key pushbutton again will stop the motor At this stage the joystick and the Key pushbutton can be used to navigate between the different menus as described at the beginning of this section LCD display in speed control mode Figure 14 AC motor screens speed control STM32 Motor Control AM IFOC ver 1 0 Target Measured 03000 rpm O00000 lt NMove tl Change STM32 Motor Control AOM IFOC ver 1 0 Fi ux P I D O00300 00100 O00000 Target O9837 Id Measured OOOOO Id Move ti Change STNS2 Motor Control
9. the cause of the fault is no longer present Pressing the Key button causes the main state machine to switch from FAULT to IDLE state Six different fault sources are monitored during operation Refer to the UM0492 STM32 sensorless PMSM field oriented control software library user manual for more implementation details 19 28 Running the starter kit UM0486 2 1 4 20 28 Table 5 PMSM motor faults Error Message Description Overcurrent This occurs if a low level triggers the emergency stop on the PWM peripheral dedicated input pin BKIN on pin1 of motor control connector CN14 It means that either the hardware over temperature protection or the hardware over current protection was triggered Over current trip is defined by the L6386 gate driver s comparators level 0 5V and the shunt resistors 3 3A for 0 22 ohm shunt resistor default PMSM configuration 7A for 0 1 ohm shunt resistor Overheating This is monitored by reading the voltage value on a NTC resistor with the This occurs if the power stage heat sink temperature goes above 60 C STM32 ADC on pin26 of motor control connector CN14 Bus Overvoltage using the STM32 ADC pin14 of the motor control connector CN14 anda This occurs if the DC bus voltage goes above 350Vdc This value is read resistor network in parallel with the power stage bulk capacitors Bus Undervoltage This occurs if the bus voltage is below 20V DC Start up failed
10. Jumper W1 2 The shortcircuit replacing the D3 diode footprint must be open This is to avoid having reverse current in the L7815 voltage regulator ky 13 28 Running the starter kit UM0486 2 14 28 Running the starter kit When you receive the STM32 MCKIT starter kit the STM32 microcontroller is already programmed with the PMSM standalone mode firmware allowing to immediately run the PMSM motor included in the kit Section 2 1 explains how to do this The STM32 MCKIT can also run an AC induction motor To do this you must first reconfigure the hardware and load the AC induction motor standalone firmware into the flash memory of the STM32 microcontroller Section 2 2 explains how to do this For both types of motors once you have checked the motor connections and jumper settings on the motor control board you can use the joystick push button and LCD display on the STM3210B EVAL evaluation board to monitor and change parameters of the motor The joystick and the button labelled Key are used to navigate between the different menus see Figure 2 Figure 2 Joystick and pushbutton DATA a FUNCTION 4 gt FUNCTION y gt ENTER Key connected to PB3 DATA The conventions for actions on the Key pushbutton and the joystick are as follows 1 The Function concerned by a setting is displayed in red on the LCD 2 Right Left movement of the joystick allows a Inside a given screen to pass fr
11. OR CONTROL a sre MB459B EVAL BOARD MB525 TR30R AC DC bie Adapter 6 The STM32 MCKIT starter kit includes the following items e The MB459B motor control evaluation board 1 This board is described in the MB459B Motor Control Board User Manual UM0379 provided on the STM32 MCKIT CD ROM The MB525 STM32 evaluation board 2 This board is described in the STM3210B EVAL User Manual UM0426 provided on the STM32 MCKIT CD ROM 1 1 1 Hardware ky 5 28 STM32 MCKIT hardware setup UM0486 e An MB535B opto isolation JTAG board 3 This board is described in the JTAG Opto isolation Board User Manual UM0378 provided on the STM32 MCKIT CD ROM The purpose of the JTAG opto isolation board is to provide galvanic isolation between the J link debugger programmer and the STM32 evaluation board It helps to prevent accidental damage to the PC in the event of a catastrophic failure on the motor control board This isolation barrier also solves the problem of the PC JTAG debugger and motor control board being at different ground potentials e A J link USB JTAG debugger 4 The SEGGER J link USB JTAG debugger used in conjunction with the IAR Embedded Workbench C C 32 KB compiler allows you to re program the Flash memory of the STM82 microcontroller and to debug the software before using the application in standalone mode A24V DC SHINANO PMSM motor
12. ae ea eh hee aoe 6 1 1 4 Documentation ssri kee hed eee ead edhe whe OY Eee tenn Pe 7 1 1 5 Components not provided 0 000 eee ee eee 7 1 1 6 Permanent magnet synchronous motor PMSM 4 7 1 1 7 AC induction motor aaea 8 1 2 Hardware configuration for PMSM motor default 9 1 3 Hardware configuration for AC induction motor 00 11 1 4 Power supply connections ces scee cease eeR beeen eet eet ese ee eet eer 13 2 Running the starter Kit 2222 c eee eee 14 2 1 Running the PMSM motor 22s0s5c4 becew st oedd deb ES eee ee ee eee 15 2 1 1 LCD display in speed control mode 000 cece eee eee 16 2 1 2 LCD display in torque control mode 000e cee eee eee 19 2 1 3 PMSM motor fault messages 0000 cece eee 19 2 1 4 Running your own PMSM motor 000 0c e eee ee eee 20 2 2 Running an AC induction motor 0 0c eee eee 21 2 2 1 LCD display in speed control mode 00 0c eee ee eee 21 2 2 2 LCD display in torque control mode 00 eee e eee eee 22 2 2 3 AC motor control variables that can be monitored 23 2 2 4 AC induction motor fault messages 000 cece eee eee 23 2 2 5 Running your own AC motor 0 000 eee 24 3 Creating your custom application 0 0c eee eee eee 25 3 1 Installing the IAR EWARM KickStart Edition 32KB limitation 25 3 2 Developing your own
13. application s aasa cee eee 25 Appendix A Additional information 0000 e eee eee 26 A 1 Recommended reading 000 c eee eee eee 26 A 2 Software upgrades nunaa wee heh ei See eee es Gee w ee ees 26 2 28 ky UM0486 Contents A 3 Getting technical support 2 00 0 c eee eee 26 Revision history 3 28 UM0486 4 28 Safety warnings General In operation the STM32 MCKIT starter kit has uninsulated wires moving or rotating parts when connected to a motor as well as hot surfaces In case of improper use incorrect installation or misuse there is danger of serious personal injury and damage to property All operations installation and maintenance are to be carried out by skilled technical personnel applicable accident prevention rules must be observed When the motor control board is supplied with voltages greater than 30 V AC DC all of the board and components must be considered hot and any contact with the board must be avoided The operator should stay away from the board as well risk of projection of material in case of components destruction especially when powering the board with high voltages The rotating parts of motors are also a source of danger The STM32 MCKIT starter kit contains electrostatic sensitive components which may be damaged through improper use Intended use The STM32 MCKIT starter kit is made of components designed for demo
14. cables to the J6 connector 6 Verify that the STM3210B EVAL evaluation board and the JTAG opto isolation board MB535B are connected with the provided 20 pin JTAG cable In this way the STM3210B EVAL evaluation board automatically supplies the opto isolation board 7 Power up the STM3210B EVAL evaluation board with the auxiliary power supply block TR3OR 8 Power up the motor control board by connecting the output terminals of your DC power supply to the MAINS connector J3 The provided voltage must not be higher than 42V DC or 32Ve AC GND recommended The STM32 MCKIT is ready to run with your AC induction motor Caution Before supplying the board double check proper connections make sure that there are no metal parts on below or around the PCB and that there are no undesired earth ground loops due to measuring equipment such as an oscilloscope Table 3 MB459B motor control board jumper settings for an AC induction motor Jumper Settings for AC induction motor with tachometer feedback w1 lt 35V only or HIGH VOLTAGE W4 Present W5 Not present W6 Present 11 28 STM32 MCKIT hardware setup UM0486 Table 3 MB459B motor control board jumper settings for an AC induction motor Jumper Settings for AC induction motor with tachometer feedback W7 Present and set on default position of silk screen printing w8 Present w9 Present W10 Soldered in the positio
15. cted Observed El ectrical angle output of the rotor position estimator Observed rotor speed output of the speed reconstruction PLL Observed alpha beta B emf alpha B emf beta rotor position estimator internal variables A last push to the right returns to the very 1st screen UM0486 Running the starter kit 2 1 2 LCD display in torque control mode In torque control mode the firmware allows modifying in real time the torque and flux set points for constant torque operation From the speed control menu an up or down push enters this demo mode Figure 12 Torque Control demo STM32 Motor Control PMSM FOC ver 1 0 Sensorless Demo Torque control Target Measured Iq 04500 00000 Id 00000 00000 Speed rpm 00000 gt Move ti Change When the motor is running the LCD indicates the target Id and Iq current components set points as well as the measured values Pressing the joystick up down increases resp decreases these settings Actual speed is also reported Pressing the joystick on the right enters the same screen than for speed control mode at the exception of Speed PI regulator settings PMSM motor fault messages During the demo you can potentially get error messages as shown in Figure 13 Figure 13 Fault screen STM32 Motor Control PMSM FOC ver 1 0 II FAULT ty Error on Speed Fdbck Press Key to return to menu Press Key to return to menu is displayed only if
16. e motor control board MB459B are in their default position Refer to Table 1 for information on jumper settings and if necessary to the MB459B Motor Control Board User Manual for the location of the jumpers on the board Verify that all of the STM32 evaluation board MB525 jumpers are in their default position Refer to Table 2 for information on jumper settings and if necessary to the STM3210B EVAL board User Manual for the location of jumpers on the board Verify that the PMSM motor cables are correctly plugged into the motor control board s MOTOR connectors J5 and J8 The motor control board MB459B the STM32 evaluation board MB525 the opto isolation JTAG board MB535B and the provided PMSM motor are already assembled together over a metal support when you receive the kit Verify that the STM32 evaluation board and the JTAG opto isolation board MB535B are connected with the provided 20 pin JTAG cable In this way the STM32 evaluation board automatically supplies the opto isolation board Power up the STM32 evaluation board with the auxiliary power supply block TR30R Power up the motor control board by connecting the output terminals of your DC power supply to the MAINS connector J3 The provided voltage must be 24V DC and your power supply must be able to provide a current of 3A The STM32 MCKIT is ready to run with the PMSM motor Caution Before supplying the board double check proper connections mak
17. e sure that there are no metal parts on below or around the PCB and that there are no undesired earth ground loops due to measuring equipment such as an oscilloscope 9 28 STM32 MCKIT hardware setup UM0486 10 28 Table 1 MB459B motor control board jumper settings for a PMSM motor default Jumper Settings for the provided Settings for a high voltage PMSM SHINANO 24V PMSM motor motor wi lt 35V only lt 35V only or HIGH VOLTAGE W4 Present W5 Not present W6 Present W7 Present and set on default position of silk screen printing W8 Present w9 Present W10 Present and soldered on default position of silk screen printing W11 Present W12 Not present W13 Not present W14 Not present W15 Not present W16 Present and set on reverse position of silk screen printing W17 Present W18 Present W19 Present Table 2 STM32 evaluation board jumper settings for a PMSM motor default Jumper Description Set to PSU position to supply the STM32 evaluation board through the jack JP4 CN3 JP12 Not fitted tachogenerator signal filtering for AC induction motor JP10 Not fitted TRST JTAG and NRESET MCU do not need to be connected SW1 SW2 Both set to 0 position to boot from embedded user flash lt 4 UM0486 STM32 MCKIT hardware setup 1 3 Hardware configuration for AC induction motor This section describes the procedure for operati
18. ed regulator using the rotor angle computed by the observer ky 17 28 Running the starter kit UM0486 18 28 Figure 10 Sensorless screen STM32 Motor Control PMSM FOC ver 1 0 Observer Gains K1 K2 01200 00852 PLL Gains P li 00237 00046 gt Move ti Change After 4 consecutive pushes the last settings screen is entered it allows the I Os of the micro PBO and PB1 to be used as DACs to monitor internal variables in real time with an oscilloscope These outputs provide PWM signals with a duty cycle proportional to the value of the variable it must be low pass filtered by a 6 8K 47nF low pass filter to remove all high frequency components due to the PWM fundamental frequency Figure 11 DAC screen STM32 Motor Control PMSM FOC ver 1 0 Signal on PBO la Signal on PB1 Observed B emf beta Move ti Change You can select the following internal variables to be monitored la lb Phase a and b currents from ADC reading results alpha beta outputs of the clarke transformation Iq Id direct and quadrature currents output of the park transformation lq ref Id ref direct and quadrature current components set points Vq Vd direct and quadrature voltage commands V alpha V beta output voltages from the reverse park transform Measured El ectrical angle rotor position computed from the encoder if connected Measured rotor speed speed measured with the encoder if conne
19. es in conjunction with the EWARM KickStart Edition with 32 KB limitation from IAR to develop build and debug your own applications The EWARM KickStart Edition with 32 KB limitation is available for free download from the IAR web site In addition the source files for the standalone PMSM and AC induction motor firmware are delivered with the starter kit They are intended to provide a sound basis for your own application developments Do not hesitate to fine tune them to fit your specific requirements Installing the IAR EWARM KickStart Edition 32KB limitation You can download the IAR Embedded Workbench with a 32 KB KickStart version of the C C compiler and built in flash loader from www iar com from the IAR web site Go to www iar com then Downloads and under Evaluation Software select IAR Embedded Workbench Kickstart edition Then select the ARM architecture 32 KB edition from the list of processor families Follow the instructions on the IAR web site and in the IAR documentation to install and use the IAR Embedded Workbench Before installing the software make sure that the J Link USB JTAG debugger is not connected to the PC Note that to use the debugging function of the IAR EWARM workbench you must install specific hardware debugger drivers To do this return to the welcome screen of the IAR Embedded Workbench installation procedure and select the Install Drivers option Developing your own application This section s
20. he ST products and services described herein No license express or implied by estoppel or otherwise to any intellectual property rights is granted under this document If any part of this document refers to any third party products or services it shall not be deemed a license grant by ST for the use of such third party products or services or any intellectual property contained therein or considered as a warranty covering the use in any manner whatsoever of such third party products or services or any intellectual property contained therein UNLESS OTHERWISE SET FORTH IN ST S TERMS AND CONDITIONS OF SALE ST DISCLAIMS ANY EXPRESS OR IMPLIED WARRANTY WITH RESPECT TO THE USE AND OR SALE OF ST PRODUCTS INCLUDING WITHOUT LIMITATION IMPLIED WARRANTIES OF MERCHANTABILITY FITNESS FOR A PARTICULAR PURPOSE AND THEIR EQUIVALENTS UNDER THE LAWS OF ANY JURISDICTION OR INFRINGEMENT OF ANY PATENT COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT UNLESS EXPRESSLY APPROVED IN WRITING BY AN AUTHORIZED ST REPRESENTATIVE ST PRODUCTS ARE NOT RECOMMENDED AUTHORIZED OR WARRANTED FOR USE IN MILITARY AIR CRAFT SPACE LIFE SAVING OR LIFE SUSTAINING APPLICATIONS NOR IN PRODUCTS OR SYSTEMS WHERE FAILURE OR MALFUNCTION MAY RESULT IN PERSONAL INJURY DEATH OR SEVERE PROPERTY OR ENVIRONMENTAL DAMAGE ST PRODUCTS WHICH ARE NOT SPECIFIED AS AUTOMOTIVE GRADE MAY ONLY BE USED IN AUTOMOTIVE APPLICATIONS AT USER S OWN RISK Resale of ST products with provisions differen
21. magnetic flux makes it possible to design highly efficient PM motors A PM synchronous motor is driven by sine wave voltage coupled with the given rotor position The generated stator flux together with the rotor flux which is generated by a rotor magnet defines the torque and thus speed of the motor The sine wave voltage output have to be applied to the 3 phase winding system in a way that angle between the stator flux and the rotor flux is kept close to 90 to get the maximum generated torque To meet this criterion the motor requires electronic control for proper operation 7 28 STM32 MCKIT hardware setup UM0486 8 28 For a common 3 phase PM synchronous motor a standard 3 phase power stage is used The same power stage is used for AC induction and PMSM motors The power stage utilizes six power transistors with independent switching The power transistors are switched in the complementary mode The sine wave output is generated using the space vector PWM technique AC induction motor The AC induction motor is a rotating electric machine designed to operate from a three phase source of alternating voltage The stator is a classic three phase stator with the winding displaced by 120 The most common type of induction motor has a squirrel cage rotor in which aluminum conductors or bars are shorted together at both ends of the rotor by cast aluminum end rings When three currents flow through the three symmetrically placed wi
22. n represented on silk screen printing W11 Present W12 Present W13 Not present W14 Not present W15 Not present W16 Present and set to the reverse position vs silk screen printing W17 Not present W18 Not present W19 Not present Table 4 STM3210B EVAL evaluation board jumper settings for an AC induction motor Jumper Description Set to PSU position to supply the STM32 evaluation board through the jack JP4 CN4 JP12 Fitted tachogenerator signal filter for AC induction motor JP10 Not fitted TRST JTAG and NRESET MCU do not need to be connected SW1 SW2 Both set to 0 position to boot from embedded user flash Note To use the STM3210B EVAL evaluation board with an AC induction motor the three shunt resistors R3 R4 and R5 of the motor control board MB459B must be replaced by the 0 10hm resistors included in the bag delivered with the kit 12 28 ky UM0486 STM32 MCKIT hardware setup 1 4 Power supply connections J1 connector provides a completely independent control of the DC bus voltage power and the 15V supply for the gate drivers This is interesting for development purposes when one needs to smoothly increase the motor s operating voltage from zero while having gate drivers operating with their nominal supply When supplying the power stage with an external 15V power supply using the J1 connector special care must be taken that 1 Nojumpers are connected on
23. nd re flash the STM32 to change the value Note that the STARTUP_FINAL_TORQUE and STARTUP_TIMEOUT parameters are fully configurable so that you can customize the start up phase to adapt it to the motor you are using and to load conditions For more information about driving an AC induction motor refer to the UM0483 User Manual STM32 AC induction motor IFOC software library 2 2 2 LCD display in torque control mode Figure 15 AC motor screens torque conirol 22 28 STNS2 Motor Control AM I1FOC ver 1 0 TORGLE CONIL MIE Target Measured os000 oooo0o0 o9837 oo0oo000 Speed rpm oo0oo000 STM32 Motor Control AOM IFOC ver 1 0 Torque I P D 00100 O00020 O00000 Target o8ao0oo00 Iq Measured OOOOO lq lt Move tl Change Move ti Change STM32 Motor Control Am IFOC ver 1 0 Flux STM32 Motor Control AM IFOC ver 1 0 STM32 Motor Control AOM IFOC ver 1 0 I D Power stage status 00300 00100 O000O0O Iq DCbus OOO Volt Signal on PBO Target O9837 id Measured OOOOO Id Signal on PB1 20 Celsius iqref Move 1t1Change Move 1tiChange When you press the Key pushbutton or the joystick the motor starts the main state machine goes from IDLE to START state After startup following a linear ramp if valid information from the speed sensor tachometer or encoder is detected you can adjust the torque reference on the fly using the joystick However if no valid information from the speed sensor
24. ndings a sinusoidally distributed air gap flux generating the rotor current is produced The interaction of the sinusoidally distributed air gap flux and induced rotor currents produces a torque on the rotor The mechanical angular velocity of the rotor is lower then the angular velocity of the flux wave by so called slip velocity In adjustable speed applications AC induction motors are powered by inverters The inverter converts DC power to AC power at the required frequency and amplitude The inverter consists of three half bridge units where the upper and lower switches are controlled complementarily As the power device s turn off time is longer than its turn on time some dead time must be inserted between the turn off of one transistor of the half bridge and turn on of its complementary device The output voltage is mostly created by a pulse width modulation PWM technique The three phase voltage waves are shifted 120 to each other and thus a three phase motor can be supplied UM0486 STM32 MCKIT hardware setup 1 2 Hardware configuration for PMSM motor default This section describes the procedure for operating the STM32 MCKIT with a PMSM motor The default settings that are present on the STM32 evaluation board and on the motor control evaluation board when you receive the STM32 MCKIT starter kit are intended for a PMSM motor When you are running the PMSM motor follow these steps 1 Verify that all the jumpers on th
25. ng the STM32 MCKIT with an AC induction motor You must change the default settings that are present on the STM32 evaluation board and on the motor control evaluation board when you receive the STM32 MCKIT starter kit because they are intended for a PMSM motor When you are running the AC induction motor follow these steps 1 Change the jumpers on the motor control board MB459B to the settings required for running with an AC induction motor Refer to Table 3 for information on jumper settings and if necessary to the MB459B Motor Control Board User Manual for the location of the jumpers on the board 2 Replace the three shunt resistors R3 R4 and R5 on the motor control board MB459B by the 0 10hm resistors included in the bag delivered with the kit 3 Verify that the jumpers on the STM3210B EVAL evaluation board MB469B are in their default position Refer to Table 4 for information on jumper settings and if necessary to the STM3210B EVAL board User Manual for the location of jumpers on the board 4 Disconnect the PMSM motor from the motor control board s MOTOR connectors J5 and J8 The motor control board MB459B the STM3210B EVAL evaluation board MB469B the opto isolation JTAG board MB535B and the provided PMSM motor are already assembled together over a metal support when you receive the kit 5 Connect your AC induction motor to the motor control board by connecting the three phases to the J5 connector and the tachometer
26. nstration purposes and must not be included in electrical installations or machinery Instructions about the setup and use of the STM32 MCKIT starter kit must be strictly observed Operation After disconnecting the board from the voltage supply several parts and power terminals must not be touched immediately because of possible energized capacitors or hot surfaces Important notice to users While every effort has been made to ensure the accuracy of all information in this document STMicroelectronics assumes no liability to any party for any loss or damage caused by errors or omissions or by statements of any kind in this document its updates supplements or special editions whether such errors are omissions or statements resulting from negligence accident or any other cause UM0486 STM32 MCKIT hardware setup 1 STM32 MCKIT hardware setup This section provides a detailed description of the components included in the STM32 MCKIT starter kit It also describes the default settings for a permanent magnet sensored motor PMSM and explains how to change them to use an AC induction motor 1 1 Package checklist Figure 1 shows the layout and connections of the major components of the STM32 MCKIT starter kit Figure 1 STM32 MCKIT layout JLINK LO USB JTA DEBUGGER Encoder EO LAHON BOARD MB535B SHINANO MOTOR 5 Ld MOT
27. o isolation Board User Manual UM0378 In the box with the STM32 MCKIT you will also find e A startup color poster which summarizes the main steps for running the motor control kit The MCD product finder Product flyers and brochures The MCD minirom A guarantee record card 1 1 5 Components not provided The STM32 MCKIT starter kit does not include A power supply To use the STM32 MCKIT starter kit with the provided PMSM motor you need a 24V 3A minimum power supply You can order the SPU65 108 24V 3 3A 80W with S amp T Type connector code POO from SINPRO www trcelectronics com Sinpro e An AC induction motor The STM32 MCKIT can operate with an AC induction motor The provided graphical user interface is designed to operate with the SELNI induction motor It can be ordered as an accessory with the following order code ST7MC MOT IND To use the STM32 MCKIT starter kit with the Selni AC induction motor you need a 42V DC or 32V 4 AC power supply polarity not important GND recommended 1 1 6 Permanent magnet synchronous motor PMSM The PM synchronous motor is a rotating electric machine where the stator is a classic three phase stator like that of an induction motor and the rotor has surface mounted permanent magnets In this respect the PM synchronous motor is equivalent to an induction motor where the air gap magnetic field is produced by a permanent magnet The use of a permanent magnet to generate a substantial air gap
28. om one function to another b to pass from one screen to the other using a circular path 3 Up Down movement of the joystick changes the data for the selected function A simple state machine handles the motor control tasks in the main loop and monitors the power stage This state machine is described in Figure 3 it does not differentiate speed control from torque control demos UM0486 Running the starter kit Figure 3 PMSM and AC induction motor main state machine Initialization button pressed Motor still HW or start up fault elapsed The power stage is monitored using the A D converter and the PWM peripheral Emergency Stop Break in input These peripherals check for the following conditions e Heatsink over temperature e DC bus over voltage or under voltage Over current protection Any of these three conditions will cause the PWM to be stopped and the state machine to go into FAULT state for 2 seconds before going back to IDLE state Depending on the source of the fault an error message is also displayed on the LCD for the duration of the FAULT condition 2 1 Running the PMSM motor The PMSM firmware allows you to run the motor in open or closed loop and to monitor and change various parameters on the fly This section provides a summary of the screen displays and settings The active parameter the one that is selected to be modified with the joystick is displayed in red
29. or information on how to set up basic debugging sessions with the EWARM KickStart Edition with 32 KB limitation from IAR refer to the IAR documentation and online help Software upgrades The latest versions of the STM32 motor control libraries are available free of charge from our sales offices The latest version of the IAR EWARM KickStart Edition with 32 KB limitation is available for free download from the IAR web site www iar com Getting technical support Technical assistance is provided free to all customers For technical assistance documentation and information about products and services please refer to your local STMicroelectronics partner UM0486 Revision history Revision history Table 7 Document revision history Date Revision Changes 13 Dec 2007 1 Initial release 27 28 UM0486 Please Read Carefully Information in this document is provided solely in connection with ST products STMicroelectronics NV and its subsidiaries ST reserve the right to make changes corrections modifications or improvements to this document and the products and services described herein at any time without notice All ST products are sold pursuant to ST s terms and conditions of sale Purchasers are solely responsible for the choice selection and use of the ST products and services described herein and ST assumes no liability whatsoever relating to the choice selection or use of t
30. ring the Start up failed motor start up sequence This indicates a time out on tachogenerator feedback signal it can be Error on speed fdbck either a cable disconnection or a motor stall because of an unsufficient torque reference or supply voltage for instance 23 28 Running the starter kit UM0486 2 2 5 24 28 Running your own AC motor To run your own motor using the AC firmware follow the indications given in the Getting Started section of the UM0483 User Manual STM32 AC induction motor IFOC software library Based on your own motor parameters and hardware configuration you must edit and update the following files STM32F10x_conf h configuration header file MC_Control_Param h MC_encoder_Param h MC_acmotor_prm h MC_tacho_prm h Using the EWARM KickStart Edition with 32 KB limitation from IAR software you must then rebuild the project and load it onto the STM32 microcontroller The procedure for installing the IAR EWARM software and creating your own application is outlined in Section 3 on page 25 UM0486 Creating your custom application 3 3 1 3 2 Creating your custom application The main benefit of the STM32 MCKIT starter kit is that you can use it to create your own applications and re program the STM32 microcontroller In the toolkit you will find the dedicated software libraries for PMSM and AC induction motors and the STM32 standard library Use these librari
31. t from the statements and or technical features set forth in this document shall immediately void any warranty granted by ST for the ST product or service described herein and shall not create or extend in any manner whatsoever any liability of ST ST and the ST logo are trademarks or registered trademarks of ST in various countries Information in this document supersedes and replaces all information previously supplied The ST logo is a registered trademark of STMicroelectronics All other names are the property of their respective owners 2007 STMicroelectronics All rights reserved STMicroelectronics group of companies Australia Belgium Brazil Canada China Czech Republic Finland France Germany Hong Kong India Israel Italy Japan Malaysia Malta Morocco Singapore Spain Sweden Switzerland United Kingdom United States of America www st com lt 28 28
32. ummarizes the steps that you must follow to develop your own application using the EWARM KickStart Edition with 32 KB limitation from IAR For detailed explanations on performing these tasks refer to the IAR documentation 1 Start the IAR EWARM tool 2 Open the workspace corresponding to your type of motor in EWARM The source files for the standalone PMSM and AC induction motor firmware are delivered with the STM32 MCKIT starter kit 3 Modify and fine tune the source files to suit the requirements of your application 4 Build the application 5 Re program the STM32 microcontroller You are now ready to run the motor control kit in standalone mode with your own application 25 28 Additional information UM0486 Appendix A Additional information A 1 A 2 A 3 26 28 Recommended reading This documentation describes how to use the STM32 MCKIT Starter Kit Additional information can be found in the following documents STM82F101x and STM32F103x datasheets STM32 Reference Manual RM0008 STMicroelectronics Motor Control Application Notes STM3210B Eval evaluation board user manual UM0426 Motor control evaluation board user manual UM0379 JTAG opto isolation board user manual UM0378 STM32 AC induction motor IFOC software library user manual UM0483 STM82 Sensored PMSM field oriented control software library user manual UM0312 Most of the above documents are present on the STM32 MCKIT CD ROM F
33. ure voltage commands V alpha V beta output voltages from the reverse park transform Measured El ectrical angle rotor position computed from speed feedback Measured rotor speed speed measured with the tachogenerator AC induction motor fault messages Table 6 gives the list of fault messages that can be displayed using the demo firmware Table 6 AC induction motor faults Error Message Description This occurs if a low level triggers the emergency stop on the PWM peripheral dedicated input pin BKIN on pin1 of motor control connector CN14 It means that either the hardware over temperature protection or the hardware over current protection was triggered Over current trip is Overcurrent defined by the L6386 gate driver s comparators level 0 5V and the shunt resistors 3 3A for 0 22 ohm shunt resistor default PMSM configuration 7A for 0 1 ohm shunt resistor This occurs if the power stage heat sink temperature goes above 60 C Overheating This is monitored by reading the voltage value on a NTC resistor with the STM32 ADC on pin26 of motor control connector CN14 This occurs if the DC bus voltage goes above 350Vdc This value is read Bus Overvoltage using the STM32 ADC pin14 of the motor control connector CN14 anda resistor network in parallel with the power stage bulk capacitors Bus Undervoltage This occurs if the bus voltage is below 20V DC This indicates that the correct start up criteria were not met du
34. vered with the starter kit are intended to provide a sound basis for your own application developments Do not hesitate to fine tune them to fit your specific requirements In this manual you will find information on The STM3210B MCKIT starter kit components and how to set up the hardware to run the provided PMSM motor or an AC induction motor e How to run the STM3210B MCKIT starter kit in standalone mode e How to re program the STM32 microcontroller to run your own application For information on the features of the STM32 microcontroller refer to the datasheet The STM32 evaluation board features peripherals and connectors are described in the STM3210B EVAL User Manual UM0426 For information on the PMSM and AC induction motor software libraries and how to use them in motor control application development projects refer to the PMSM Field Oriented Control Software Library User Manual UM0492 and the AC Induction Motor IFOC Software Library User Manual UM0483 respectively You will find these manuals and all related documentation on the STM3210B MCKIT CD ROM December 2007 Rev 1 1 28 www st com Contents UM0486 Contents 1 STM32 MCKIT hardware setup 2000 cece eee eee eee 5 1 1 Package checklist evcuueseetaatesseetedcteenuasnadaakeceweears 5 1 1 1 Haw ss che ien AE a a e E Sake Boeke phen p E 5 1 1 2 FIRNWANCG cn eeraa EErEE AETERNE eb ee de Meda Ree eae See ato ws 6 1 1 3 SOMWANC ehh aa ee wad Pinedo asi d

Download Pdf Manuals

image

Related Search

Related Contents

  Manuel - Wallenstein  AsciiDoc Syntax Quick Reference  ABUS FU9050  FY-6V FY-8V FY-10V  AVG AntiVirus Free Edition User Manual  User Manual - SharePoint  HSG260-PRT Visitor Gateway Kit  Water Boiler, 10 Gallon – Service Manual  

Copyright © All rights reserved.
Failed to retrieve file