Home
EVAL6470H-DISC : fully integrated stepper motor driver based on
Contents
1. Car UM1691 y life augmented User manual EVAL6470H DISC fully integrated stepper motor driver based on the L6470 and STM32 Introduction The EVAL6470H DISC can be used together with the STM32 firmware library V1 0 and constitutes a complete motor control evaluation and a development platform It is a demonstration board for motor control applications in the range of 8 V to 45 V of DC bus voltage using the STM32F105RB microcontroller with an internal 128 kB Flash size and a 64 kB internal RAM and the L6470H fully integrated solution suitable for driving two phase bipolar stepper motors up to 1 128 microstepping The L6470H integrates a dual DMOS full bridge with all of the power switches equipped with an accurate on chip current sensing circuitry suitable for non dissipative current control and overcurrent protection With dedicated hardware evaluation features the EVAL6470H DISC board is designed to help developers evaluate the device and develop their own applications Figure 1 Board image LE470H DISCOVERY KIT Ri w st com dapin November 2013 DoclD025486 Rev 1 1 42 www st com Contents UM1691 Contents 1 Main features 2 06 ice Re 0 a bbe eee BEER EERS KERE BREER SERE KERN 4 1 1 Target applications Ee ee ee ee 4 1 2 Description EE EE EE EE EG rn GE GE GE GE GE nn nn es ee ee se ei 4 2 Electrical characteristics of the board ss see ER cece RR RR ee 5 3 Schematics lay
2. e Adapt the settings with your specific setup motor voltage by using the dedicated PC application The user is able to save inside the board the specific parameters depending ona user setup e Using the board with user parameters directly on a site without a connected PC d 4 42 DoclD025486 Rev 1 UM1691 Electrical characteristics of the board 2 Electrical characteristics of the board Table 1 Electrical specifications I Name Value Supply voltage Vs 8 to 45 V Maximum output current each phase 3Arms Logic supply voltage VREG 3 V L6470 regulator supply Logic interface voltage Vpp 3 3 V USB supply Low level logic inputs voltage OV High level logic input voltage Vpp Stepping Up to 1 128 microstepping Operating temperature 0 to 85 C DoclD025486 Rev 1 5 42 Schematics layout and bill of material UM1691 3 Schematics layout and bill of material Figure 2 Schematic microcontroller supply part VDD VDD TP 4 UT ono ne LR KEYSTONE5000 J5 tj VOUT VOUT e q VOUT VOUT SY SHELL USB vee SO N viN Nc 3 1900F 3 SHELL USBDM 5 USBDP 9 SHELL USBDP cg LD1117D33TR SHELL ID 3 ONE E USB GND 17340351 _ L yom org E USBDM VDD de cy 21 GND vsus 4 S
3. ii T Wire NE 0 TP6 L6470H DISCOVERY KIT Ri 9 JTAG www st com dspin he di 2 i GND EO a od 5 R1 R10 25 3l I 9 a O Q r L ug w 7 mL 25 a e R R21 DEMO BOARD FOR EVALUATION J2 us 21 EE _ R20 PURPOSE ONLY U3 N o D2 R27 R28 pu gl III FIL E E aL R26 S l 68 nde XTAL A2 S VE co R25 9 c2 z 1 elis z 2 n C28 x R13 5 m kK Reavy RoHS 2E D6 EED RIB COMPLIANT m TET m Z LK Busy 2002 05 60 D5 ol p A Cs re BH EM start stop MOM herme O EN lO ADM O E Se Si 8 amp B ER Figure 6 Layout top layer and bottom layer Ly DocID025486 Rev 1 9 42 Schematics layout and bill of material UM1691 Table 2 Bill of material Item ged Reference Value Package C1 C16 2 Cap cer 10 uF 10 V X7R 0805 10 uF 0805 C2 1 Cap cer 1 uF 10 V X7R 0805 1 uF 0805 C3 C4 C10 C13 C17 C19 C21 14 Cap cer 100 nF 50 V X7R 0603 100 nF 0603 C22 C25 C27 C5 1 Cap cer 3 3 nF 50 V X7R 0603 3 3 nF 0603 C6 1 Cap cer 220 nF 35 V X7R 0603 220 nF 0603 C7 1 Cap cer 4 7 nF 50 V X7R 0603 4 7 nF 0603 C8 e 4 Cap cer 10 nF 50 V X7R 0603 10 nF 0603 c9 1 Cap tant 47 uF 6 3 V 10 PACK A 47 uF 3216 C14 1 Cap elec 100 uF 63 V 100 uF CAPES R10HXX C23 C24 2 CAP CER 20pF 50V COG 0603 20 pF 0603 D1 1 Zener regulator 3 6V SOD 523 D2 1 in
4. OR ENVIRONMENTS WHERE ST PRODUCTS ARE NOT DESIGNED FOR SUCH USE THE PURCHASER SHALL USE PRODUCTS AT PURCHASER S SOLE RISK EVEN IF ST HAS BEEN INFORMED IN WRITING OF SUCH USAGE UNLESS A PRODUCT IS EXPRESSLY DESIGNATED BY ST AS BEING INTENDED FOR AUTOMOTIVE AUTOMOTIVE SAFETY OR MEDICAL INDUSTRY DOMAINS ACCORDING TO ST PRODUCT DESIGN SPECIFICATIONS PRODUCTS FORMALLY ESCC QML OR JAN QUALIFIED ARE DEEMED SUITABLE FOR USE IN AEROSPACE BY THE CORRESPONDING GOVERNMENTAL AGENCY Resale of ST products with provisions different 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 2013 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 Philippines Singapore Spain Sweden Switzerland United Kingdom United States of America www st com d 42 42 DoclD02
5. Sstm32f10x exti c e Stm32f10x flash c e stm32f10x gpio c e Stm32f10x rcc c e stm32f10x spi c e Stm32f10x tim c For the debugger for example select the ST LINK and configure it to run to main to verify download to use the Flash loader and to override the default board file with the FlashSTM32F105xB board I DoclD025486 Rev 1 UM1691 References 5 References This user manual provides information on the hardware features and use of the EVAL6470H DISC board along with the demonstration firmware and software For additional information refer to the following 1 qa BRON STM32F105xx datasheet CD00220364 STM32F105xx reference manual RM0008 Voltage mode control operation and parameter optimization application note AN4144 dSPIN family fully integrated stepper motor drivers AN4241 dSPIN cSPIN and easySPIN family communication protocol AN4290 6 Revision history Table 4 Document revision history Date Revision Changes 29 Nov 2013 Initial release I DoclD025486 Rev 1 41 42 UM1691 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
6. IT t USBLC6 2P6 5 TONE 1 5K AM03463 12 42 I DoclD025486 Rev 1 UM1691 General description 4 2 L6470 stepper motor driver The L6470 is an advanced fully integrated solution suitable for driving two phase bipolar stepper motors with microstepping It integrates a dual low Ras on DMOS full bridge Features e Operating voltage 8 45 V e 7 0 A out peak current 3 0 ms e Low Rosson Power MOSFETs e Programmable speed profile and positioning e Programmable power MOS slew rate s Up to 1 128 microstepping e Sensorless stall detection e SPI interface e Low quiescent and standby currents e Programmable non dissipative overcurrent e Two levels of overtemperature protection Figure 8 L6470 block diagram VDD OSCIN OSCOUT ADCIN VREG CP VBOOT Ext Osc driver amp Clock gen STBYIRST L FLAG Control Logic BUSY SYNC Temperature sensing STCK SW sensing a DGND AGND I DoclD025486 Rev 1 13 42 General description UM1691 Table 3 L6470 recommended operating conditions Symbol Parameter Test condition Value Unit Vpp Logic Interface supply voltage 3 3 V Mini 8 Vs Motor supply voltage Vsa Vsp Vs Maxi 45 V Differential between voltage Vsa OUTI1A OUT2A ja Vour diff PGND and Veg OUT1B OUT2B PGND pins Vsa Yen VS Maxed N VREG in Logic supply voltage VREG internal 3 V Mini 0 VADC Integrated ADC
7. 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 the 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 ST PRODUCTS ARE NOT DESIGNED OR AUTHORIZED FOR USE IN A SAFETY CRITICAL APPLICATIONS SUCH AS LIFE SUPPORTING ACTIVE IMPLANTED DEVICES OR SYSTEMS WITH PRODUCT FUNCTIONAL SAFETY REQUIREMENTS B AERONAUTIC APPLICATIONS C AUTOMOTIVE APPLICATIONS OR ENVIRONMENTS AND OR D AEROSPACE APPLICATIONS
8. input voltage range ADCIN pin V Maxi VREG 4 2 1 Charge pump The L6470H device uses an internal charge pump for driving correctly the integrated MOSFETs a voltage higher than the motor power supply The charge pump is obtained through an oscillator and few external components Figure 9 Charge pump circuitry VS C6 220 nF CB T 10 nF 11 10 2 26 12 16 VBOOT cP VSA VSA VSB VSB U3 L6470H AM03466 14 42 d DoclD025486 Rev 1 UM1691 General description 4 2 2 4 2 3 I Voltage mode driving The configuration parameters of the voltage mode driving can be obtained through the BEMF compensation tool embedded into the SPIN family software A wrong setup of these parameters could cause several issues in particular e The phase current decreases with the speed and the motor will stall e The wrong voltage is applied to the motor and the system is very noisy e The phase current reaches the overcurrent limit The BEMF compensation form uses the application parameters as inputs in order to evaluate the proper device setup The required inputs are e Supply voltage e Target phase current r m s value at different motion conditions acceleration deceleration constant speed and holding e Target operating speed maximum speed e Motor characteristics The motor characteristics are electrical constant Ke phase inductance and resistance Th
9. 00 step s That means if you send a command to run at 2000 step s the motor speed is limited at 1000 step s This is an important safety feature in the final application but not necessarily useful to evaluate the device performances Setting the parameter to high values e g 6000 step s allows evaluating the maximum speed which can be achieved by the application under test through the speed tracking command Run but it probably limits the possibility to use positioning commands Move GoTo etc The Full step speed parameter indicates the speed at which the system switches from microstepping to full step operation In voltage mode driving devices it is always recommended to operate in microstepping and not to switch to full step Hence this parameter should be greater than the maximum speed STM32F105RB microcontroller The STM32F 105xx incorporates the high performance ARM Cortex M3 32 bit RISC core operating at a 72 MHz frequency high speed embedded memories a Flash memory up to 256 Kbytes and an SRAM 64 Kbytes and an extensive range of enhanced I O and peripherals connected to two APB buses All devices offer two 12 bit ADCs four general purpose 16 bit timers plus a PWM timer as well as standard and advanced communication interfaces up to two I Cs three SPIs two I2Ss five USARTs a USB OTG FS and two CANS The STM32F 105xx device operates in the 40 to 105 C temperature range from a 2 0 to 3 6 V power supply A c
10. 4 Channels ETR 85 AF 4 Channels ETR as AF 4 Channels ETR 80 AFC gt BS AF F ome KR iseeeee s le RX TX CTS ATS xa EE EE 722 L RX TX CTS ATS PC 15 0 cd i E CKas AF a B TX as AF rea LES 3 2 o K gt RXTXas AF PE 15 0 lt gt ES wars MOSVSD MESO MCK gt LAP SCKUCK NSSIWS as AF Vpp 2 to 3 6V MOSVSD MESO MCK SCKICK NSS WS as AF ai15411 4 DoclD025486 Rev 1 17 42 General description UM1691 4 4 4 4 1 4 4 2 18 42 Firmware loading This section describes how to load firmware to the board by using the DfuSe demonstration software DfuSe installation You need first to download the DfuSe demonstration software from www st com The DfuSe tool is referenced under the development suite STSW STM32080 Once downloaded run the setup exe file More details on the DfuSe are given in the UM0412 user manual Generate a DFU file from a HEX file If the file you want to download to the discovery board is not a DFU file but a HEX file you will need first to convert it In this purpose e Start the DFU file manager V3 0 3 or greater which has been installed with the DfuSe e Choose I want to GENERATE a DFU file from S19 HEX or BIN files Figure 11 DFU file manager action tu DFU File Manager Want to do v3 0 3 fo s Es Choose your action want to GENERATE a DFU file from 519 HEX or BIN files C want to EXTRAC
11. 5486 Rev 1
12. 9 48 dspin 2013 10 07 09 48 de src j EE A dspin config h 2013 10 07 09 48 4 d user motion p a Ci main h 2013 10 07 09 48 4 dspin T AL 0d i orm L stm32f10x conf h 2013 10 07 09 48 inc mm stm32f10x it h 2013 10 07 09 48 de src N project KU gt File name Save as type Header files h a Hide Folders 3 Then you only need to recompile your project as usual to use the exported parameters 34 42 DoclD025486 Rev 1 Ly UM1691 General description 4 6 Using the EVAL6470H DISC with the firmware library The dSPIN firmware library is supplied as an IAR workspace with a source include and project files If you are using an IAR design environment you just need to load the dspin eww file and use the fwlibrairies dspin discoverykit project which is already active If you are using a different design environment you will find instructions in this user manual to build a new project on your preferred IDE The dSPIN firmware library is also supplied as an executable file in a HEX and in a DFU format It can be loaded into the EVAL6470H DISC board as explained in Section 4 4 on page 18 4 6 1 FW library package contents e FWdSPIN library Described in Section 4 6 2 e CMSIS library stm32f10x CMSIS Library used by the dSPIN FW library e STM32F 10x standard peripherals library drivers stm32f110x STM32F10x StdPeriph Driver Library
13. AD WKUP PB14 BUTTON B 38 PA PB13 PAZ PB12 vDD pi SE Eust a rae nO 2oaot2erssansanga R20 R21 R22 R23 c uoccccraaaaoaco Ls are SEER EE EER 1k SNP One One 1UFT 10N ES L ERR d x Hola O E aH 5 SE Bea a ver a ven al E VDD VDD 8 T T c26 R28 c27 100NE 100K a R11 100NF 10K T 1 co cn 10NF s3 100NF 100NF y H H AM03464 DoclD025486 Rev 1 7 42 Schematics layout and bill of material UM1691 Figure 4 Schematic motor driver part vs R2 27K B vs R1 2 c6 200K 220NF e IP7 D2 BAV99 1 2 1 KEYSTONE5000 M d T DY e 3 6V R34 em NP CB 100NF J1 R3 VDD ATUF C8 J1 3 3NF A 755 10NF 1 S L 4 S MEL Ser C10 N o o lO NIN II 100UF _ 100NF DO a OM Qu O o NNN S fe 2222 R29 J3 NP by OSCIN OUT1A is OSCOUT es 219 OUT2A ADEN N ADCIN TY sw STEY RESET STCK sa STBY RES J2 ae 3 FLAG OUT1B 2 BUSY SYNC 119 SPI NSS o SPENCK 5 CS OUT2B SPT MOS 20 CK SPIMISU 18 SD a a aaa aS to Z q zzz OOO a LL nn eo DIN N N TIN AM03465 8 42 DoclD025486 Rev 1 ky UM1691 Schematics layout and bill of material Figure 5 Layout silk screen
14. E 3 Lasa 10244 S 8DP ene USB IT t USBLC6 2P6 TONE 1 5K AM03463 I 6 42 DoclD025486 Rev 1 UM1691 Schematics layout and bill of material Figure 3 Schematic microcontroller part OM VDD TP4 TP5 TP6 VDD VDD vDD R32 T Re R R26 Jr2s R24 40K RT R31 10K Hok AK 7k ek 4 7K EI R CON FLAT 10X2 1 J4 so 1008 c15 1 E 22 28 4023 OPEN 10NF EN i i 5 6 i 7 5 7 O mr TT 77 vDD 73 74 RESET 75 RG I Ci8 E 19 ae p C16 17 1001 g E B ake 10UF OONF 8 bh BP Re Ro Jrio d EG 2R ok dok ok SP Ca3 elalclololals olalslalal lelel aaa sistat oisi i T 20PF APABEERRIBAASSES R13 a 4M 1 CT a a i A 48 s R30 nas VBAT ES 8g VDD 2 Hr segue OK NR C24 PC13 TAMPER RTC vss 2 leue y PC14 08C32 IN PAT3 PC15 08C32 OUT PA12 sl PDO OSC IN PA11 7 PD1 OSC OUT PAO 37 e g NRST us PAS TED ERROR 200 STM32F105RBT6 E ED BUST WR CED READY T PC2 PCB 47 PC3 POT my VSSA PC6 SW MOTOR 47 VODA PB15 ETER 75 P
15. General description 8 Press the Reset button and check that the LEDs restart there two step loop after the board reset Figure 27 Starting board action reset key Note Please note that once you have connected the discovery board to the GUI the LEDs meaning is different You then need to restart the board to perform a new auto check and to have a valid status from the LEDs I DoclD025486 Rev 1 33 42 General description UM1691 4 5 2 Parameters exportation from the GUI to the FW library Once you have customized the L6470 L6472 parameters with the GUI you can export them to a header file in order to use it with the FW library In this purpose 1 Press the header file button on the main window of the GUI Figure 28 Parameters exportation E SPINFamily Evaluation Software L6470 selected sels File Tools td Hx C 1 Devices aJ 3 f ABS POS 0 RD WR HOME ET Autorefresh Ge p Fw Lew auro 2 Replace the existing dspin config h of your current FW library by the new one Figure 29 Parameters exportation save file EF Save As coo e us m I Gr di dspin user motion dspin inc v gt ci p Organize v New folder How e Documentation 2 Name Date modified 4 STM32F10x StdPeriph D E clock h 2013 10 07 09 48 inc dspin h 2013 10 07 0
16. N supply current drops HardHiz I DoclD025486 Rev 1 UM1691 General description I Go Until example 40 41 42 43 44 45 46 47 48 Interrupt configuration for SW MOTOR dSPIN motion in forward direction at speed 400 steps s until the user puts a jumper on J8 the LED SPARE yellow toggles until the user puts a jumper on J8 GoUntil ACT DIR SPD dSPIN stops The LED SPARE yellow is switched off Wait until not busy busy pin test dSPIN pin 22 dSPIN moves by 50 000 steps reverse Move DIR N STEP dSPIN moves to the position saved by the GoUntil command into the MARK register so 50000 steps forward GoMark Wait until not busy busy pin test dSPIN pin 22 Nothing happens during a few seconds Release SW example 49 50 51 52 53 54 dSPIN motion in reverse direction at minimum speed until the user removes the jumper on J8 the LED SPARE yellow toggles until the user removes the jumper on J8 ReleaseSW ACT DIR The LED SPARE yellow is switched off dSPIN moves by 100 000 steps forward Move DIR N STEP Wait until not busy busy pin test dSPIN pin 22 dSPIN goes to home position set by the ReleaseSW command GoHome Wait until not busy busy pin test dSPIN pin 22 Step clock mode example 55 56 57 Get Status to clear FLAG due to switch turn on event falling edge on the SW pin GetStatus dSPIN runs in step clock mode at 2000 st
17. T 519 HEX or BIN files from a DFU one e Click S19 or HEX button e Select in the open dialog box the file of type hex Files select the HEX file and click OK e Click on the Generate button e Give a name to the DFU file and click on the Save button I DoclD025486 Rev 1 UM1691 General description 4 Figure 12 DFU file manager generation Device Vendor ID Ox 0483 Product ID Ox 0000 Injection Target ID 0 MuliBIN Version Du 0000 Taos Nan EE Deletion Delete selected Image Image for Alternate Setting 00 ST Generate Cancel DoclD025486 Rev 1 19 42 General description UM1691 4 4 3 Board settings To be able to download firmware the discovery board should be started in the DFU mode In this purpose 1 Remove the jumper from the Boot pins 2 Plug a USB cable between the discovery board and the PC It does not matter if the VS connector is plugged or not to a supply voltage Figure 13 Board settings 20 42 DoclD025486 Rev 1 I UM1691 General description 4 4 4 DFU loading At this step you are now ready to perform the firmware upgrade 1 Start the DfuSeDemo exe 2 You must have an STM Device in DFU Mode in the list of the Available DFU Devices Else it means that your board is not correctly config
18. V DC power supply Figure 22 Starting board error case I 28 42 DoclD025486 Rev 1 UM1691 General description b Ifno problem is detected the LEDs will start an infinite two step loop In the first step the four LEDs will switch on one after the other by starting by the green one and ending by the yellow one Figure 23 Starting board board OK Loop step 1 All LEDs are switching on I DoclD025486 Rev 1 29 42 General description UM1691 In the second step only the LEDs which correspond to the board ID are switched on all at the same time For the L6470 device there are green orange red LEDs For the L6472 device there are green red yellow LEDs Figure 24 Starting board display board ID jae henne HATT Loop step 2 display board Id here L6470 30 42 DoclD025486 Rev 1 I UM1691 General description I 6 Press the Left button and check the two step loop stops after a few seconds Only green LED remains switched on Figure 25 Starting board action left key Left button stops LEDS blinking DoclD025486 Rev 1 31 42 General description UM1691 32 42 T Press the Right button and check the two step loops restarts Figure 26 Starting board action right key Right button restats LEDs loop DoclD025486 Rev 1 I UM1691
19. YSTONE 5000 TH TP3 1 Test point black KEYSTONE 5001 TH U1 1 IC REG 1300MA LN 3 3 V LD1117D33TR SO8 U2 1 USBLC6 2P6 USBLC6 2P6 SOT 666 TM i i U3 1 dSPIN microstepping motor L6470H HTSSOP28 driven IC MCU RISC 72 MHz 3 6 V U4 1 32 bit 64 pin LQFP STM32F105RBT6 LQFP64 10 x 10 Y1 1 XTAL 8 MHz 30 PPM 20 pF 8 MHz HC49 US SM d DoclD025486 Rev 1 11 42 General des cription UM1691 4 4 1 Note General description Power supply The EVAL6470H DISC board is designed to be powered via e Connector J1 power of the motor and also motor control driver s USB connector J5 power of the microcontroller and logic control The USB cable supplies the digital part through a dedicated LDO U1 providing 3 3 V The motor power must be set according to the voltage required by the user motor Both the supply sources USB connector and J1 connector must be present to make the board operative Figure 7 Microcontroller supply section um VDD tp U1 1 1 GND NC t x KEYSTONE5000 J5 l voor vor Aa i s 2 VOUT vout LZ Soue SHELL USB_VCC VIN Nc LB 7 2 USBDM 7 SHELL USBDM 5 DESDE SHELL USBDP DE LD1117D33TR 9 4 c3 SHELL ID IE ONE USB_GND 1734035 1 ua _ LU ot vote E USBDM VDD R4 2 5 ME er GND VBUS ANE S 1o23 10284 te _USBDP ENT uss
20. and change hold duty cycle to 0 5 send dSPIN command change run duty cycle to 5 SetParam PARAM VALUE dSPIN runs at constant speed of 50 steps s in reverse direction Run DIR SPD dSPIN softly stops after a few seconds SoftStop RESET KVAL_HOLD to initial value RESET KVAL_RUN to initial value SetParam PARAM VALUE Wait until not busy busy status check in Status register GetStatus dSPIN moves by 100 000 steps forward Move DIR N_STEP Wait until not busy busy status check in Status register GetStatus Test of the Flag pin dSPIN pin 24 by polling wait in endless cycle if problem is detected dSPIN moves to its home position GoHome Wait until not busy busy pin test dSPIN pin 22 dSPIN goes to absolute position 65535 through the shortest path GoTo ABS_POS Wait until not busy busy pin test dSPIN pin 22 dSPIN goes in forward direction to absolute position 131071 GoTo_DIR DIR ABS_POS Wait until not busy busy pin test dSPIN pin 22 Read run duty cycle dSPIN KVAL RUN parameter from dSPIN read intersect speed dSPIN INT SPD parameter from dSPIN GetParam PARAM Read Status register content GetStatus Read absolute position dSPIN ABS POS parameter from dSPIN GetParam PARAM Reset position counter actually ResetPos Read absolute position dSPIN ABS POS parameter from dSPIN GetParam PARAM dSPIN disable power stage High Impedance immediately as a consequence the dSPI
21. ard boot mode sse 25 Starting board motor power supply EE Ee Ee ee ee ke ee kan 26 Starting board USB connection EE eee ee 27 Starting board error case eee 28 Starting board board OK 0 2 cee cet 29 Starting board display board ID 0 cee eee 30 Starting board action left key 2 0 EE EE ra 31 Starting board action right key EE EE eee 32 Starting board action reset key EE EE eee 33 Parameters exportation EE EE EE e ns 34 Parameters exportation save lel cee eae 34 DoclD025486 Rev 1 3 42 Main features UM1691 1 Main features The characteristics of the EVAL6470H DISC board are the following e DC voltage range from 8 V to 45 V e Maximum load phase current at 3 A m s e Footprint for external resonator or crystal e Control interface through trimmer user keys and switch motor input e Control through LED indicators e Interface control by USB and debug outputs e Compatible with SPIN family evaluation tool e Autonomous board due to an embedded firmware s Up to 1 128 microstepping e Optimized layout on 2 layer board low cost and high thermal performance 1 1 Target applications The demonstration board is designed to fit all typical stepper motor applications it is an autonomous board due an embedded firmware 1 2 Description The EVAL6470_DISC is downloaded with an embedded firmware The possibility with this board is double
22. are for the GUI At the startup of the FWPSPIN a sanity check is performed to confirm the discovery board is working correctly The status is returned via the board LEDS To have a correct execution of the sanity check please follow the steps below 1 Place a jumper on the boot pins bottom left corner of the board Figure 19 Starting board boot mode J ES F 1 4 EV DoclD025486 Rev 1 25 42 General description UM1691 2 Connect the board to a 5 V 45 V DC power supply Figure 20 Starting board motor power supply a i R CN amas HOS Goan FOR Ev 12 7v PUMPOM om Ca vs k nes T 3 MUG 26 42 DoclD025486 Rev 1 I UM1691 General description 3 Plug a USB cable which must at least provide a power supply Figure 21 Starting board USB connection LT L9 19 5 S ee TU wi s Lj H d LE LI SA t a gt LE ILI i 3 8 o A 4 The board should switch on automatically DoclD025486 Rev 1 27 42 General description UM1691 5 At this step a Ifa problem is detected the ready LED green and the error LED red will switch on without blinking This means that either the board ID is not recognized by the FW bad FW versions used or there is a problem with the SPI no connection between the MCU and the dSPIN via the SPI orthere is no 5 V 45
23. ation for FLAG signal dSPIN runs at constant speed of 400 steps s forward direction Run DIR SPD Tentative to write to the current motor absolute position register while the motor is running as a consequence the LED_ERROR red is lighted up SetParam PARAM VALUE Get Status to clear FLAG due to non performable command as a consequence the LED ERROR RED is switched off GetStatus dSPIN stops smoothly SoftStop Wait until not busy busy pin test dSPIN pin 22 Busy signal management 13 14 15 16 17 Interrupt configuration for BUSY signal dSPIN moves by 100 000 steps in reverse direction Move DIR N STEP During busy time the LED BUSY orange is switched ON dSPIN Disable the power bridges after a deceleration to zero phase SoftHiZ LED BUSY orange is switched OFF The LED BUSY after the point 7 and the LED ERROR after the point 13 are tied respectively to the BUSY SYNC pin and the FLAG pin So for example they are lighted up when motor accelerates or decelerates This is happening in the remaining part of the demonstration although not mentioned I DoclD025486 Rev 1 37 42 General description UM1691 38 42 Various application command examples 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 dSPIN moves by 60 000 steps forward Move DIR N_STEP Wait until not busy busy pin test dSPIN pin 22 Send dSPIN comm
24. e button Figure 16 DFU file upgrade Available DFU Devices STM Device in DFU Mode Application Mode Nr DFU Mode Vendor ID Vendor ID 0483 Supports Upload C Manifestation tolerant Supports Download C Accelerated Upload ST Procuct ID Procuct ID DF Can Detach Version Version 0200 Enter DFU mode HID detach Leave DFU mode Actions Select Target s Targetld Name Available Sectors Double Click for more DU Internal Flash 128 sectors 01 SPI Flash M25P64 128 sectors Upload Action Upgrade or Verify Action File File fwlibraries_dspin_pecO09v2 dfu Vendor ID 0483 Abi ore l oac m Ec Upload Em Procuct ID 0000 r Transferred data size 1 Version 0000 OKB O Bytes of O KB O Bytes Verify after download Optimize Upgrade duratig m Operation duration 00 00 00 Upgrade File correctly loaded 6 If this dialog box appears click Yes Figure 17 DFU file confirmation Your device was plugged in DFU mode P So it is impossible to make sure this file is correct for this device Continue however DoclD025486 Rev 1 23 42 General description UM1691 7 Once the download is performed you should have Figure 18 DFU file download OK Available DFU Devices STM Dev
25. e inductance and the resistance of the phase are given in the motor datasheet The Ke is rarely given in the specification and must be measured In the help section of the SPIN family software a step by step procedure is explained The same procedure can also be found in the application note AN4144 Voltage mode control operation and parameter optimization on www st com Click on the evaluate button to get the suggested setup for the voltage mode driving Then click on write button to copy the data in the registers of the device Overcurrent and stall detection thresholds The overcurrent protection and the stall detection are implemented measuring the current flowing into each integrated MOSFET The overcurrent protection threshold should be set just above the current rating of the motor locpth e Imax r m s v2 For example if the maximum phase current of the motor is 2 Arms the overcurrent protection should be set to about 3 A Warning Important it is strongly discouraged to disable the overcurrent shutdown It may result in critical failures The stall detection threshold should be just above the operating peak current of the application During the preliminary stages of evaluation it can be set to the maximum value DoclD025486 Rev 1 15 42 General description UM1691 4 2 4 4 3 16 42 Speed profile The max speed parameter is the maximum speed the motor will run By default it is about 10
26. eps s in forward direction for a few seconds while a 2 kHz clock signal from the MCU is applied to the dSPIN STCK pin 25 StepClock DIR The above cited clock is stopped Buttons interrupt example 58 Buttons interrupt configuration a Button A Starts the motor at quarter of max speed if it is stopped Run DIR SPD Doubles the motor speed if it is already running Run DIR SPD b Button B Disables the power bridges after a smooth stop if the motor is running at minimum speed SoftHiZ Halves the motor speed if the motor is running above minimum speed Run DIR SPD DoclD025486 Rev 1 39 42 General description UM1691 4 6 4 40 42 Create a project using the FW library package Using your preferred IDE create a new project In project options properties or settings e Select for the device the ST STM32F105xB e Use the CMSIS library Edit the preprocessor defined symbols and add e STM32F10X CL e USE STDPERIPH DRIVER e ST DSPIN 6470H DISCOVERY Edit the preprocessor include directories and add e PROJ_DIR stm32f10x CMSIS CM3 DeviceSupport ST STM32F 10x e PROJ_DIRS stm32f10x STM32F10x_StdPeriph_Driver inc e PROJ_DIR dspin ince Where PROJ DIR is a variable containing the path to the project directory Add the required library source files e startup stm32f10x cl s e System stm32f10x c e misc c e
27. finitions header e user motion dspin src dspin c dSPIN routines source file e user motion dspin inc dspin config hdSPIN configuration parameters this file can be generated by the GUI e user motion dspin inc main h Main header file e User motion dspin src main c Main program e user motion dspin inc pre include hFirst header file included by the preprocessor e user motion dspin readme txt Information on the files Demonstration sequence description The demonstration sequence description is for one L6470 device without daisy chaining The application commands used are noted after the pipe character The application commands traffic can be seen on the SPI interface pins 18 19 20 and 23 which are respectively SDO CK SDI and CS I DoclD025486 Rev 1 UM1691 General description Initialization and configuration 4 5 Initialize peripherals used by dSPIN LED_READY green is light up other LEDs are switched off LED check sequence a LED_ERROR red is switched ON LED_BUSY orange is switched ON LED_SPARE yellow is switched ON LED_ERROR red LED_BUSY orange and LED_SPARE yellow are switched OFF Resets and puts dSPIN into standby mode The dSPIN STBY_RESET pin goes low for a few hundreds of us and then goes high Program all dSPIN registers SetParam PARAM VALUE ooo Flag signal management o o N 10 11 12 Read status register content GetStatus Interrupt configur
28. ice in DFU Mode lt Application Mode p DFU Mode y E Vendor ID Vendor ID 0483 Supports Upload C Manifestation tolerant Supports Download C Accelerated Upload ST Procuct ID Procuct ID prr Can Detach Version Version 0200 Enter DFU mode HID detach Leave DFU mode Actions Select Targe s Targetld Name Available Sectors Double Click for more DU Internal Flash 128 sectors 01 SPI Flash M25P64 128 sectors m Upload Action m Upgrade or Verify Action File File fwlibraries_dspin_pecO09v2 dfu Vendor ID 0483 Targets in file Choose Upload 00 ST a Procuct ID 0000 m Transferred data size 34 Vasan 0000 11 KB 12148 Bytes of 11 KB 12148 Bytes Verify after download Optimize Upgrade duration Remove some FFs m Operation duration 00 00 05 Choose Verify Target 00 Upgrade successful Abort Quit 8 Dono forget to put the jumper back on the Boot pins in order to restart the discovery board to the normal mode 24 42 I DoclD025486 Rev 1 UM1691 General description 4 5 4 5 1 I Using the EVAL6470H DISC with firmware for the GUI By default the discovery board is loaded with firmware offering the capability to connect the board with the SPINFamily evaluation tool This GUI provides direct access to all SPIN TM registers and allows sending application commands Sanity check of the board with firmw
29. n b BAV99 SOT23 D3 1 LED red 0805 2 mcd 621 nm Red 0805 D4 1 LED green 0805 6 mcd 569 nm Green 0805 D5 1 LED yellow 0805 6 mcd 588 nm Yellow 0805 D6 1 LED orange 0805 2 mcd 602 nm Orange 0805 FIX1 FIX4 4 Hole 3 mn J1 J3 g PES EL poles MRBSN LN BS TERS OE MKDSN 1 5 2 5 08 1 5 2 5 08 J4 1 JTAG CON FLAT 10 x 2 180 M CON FLAT 10 x 2 180 M CON FLAT 10 x 2 180 M J5 1 USB_B_MINI_AMP_1734035 1 CN USB CMS Mini USB J6 J7 2 JUMP254P M 2 OPEN STRIP 2 x 2 54 R 3 OPTICAL TARGET OPTICAL TARGET Diam 1 mn R1 1 Trimmer 200 KO 200 KO Trimm 100 x 50 x 110 R2 1 27 KQ 5 1 10 W 27 KQ 0603 R3 1 Res 7 5 KO 5 1 10 W 0603 SMD 7 5 KQ 0603 R4 R13 2 Res 1 MQ 1 10 W 5 0603 SMD 1MQ 0603 R5 1 Res 1 5 KQ 1 10 W 5 0603 SMD 1 5 KO 0603 10 42 DoclD025486 Rev 1 I UM1691 Schematics layout and bill of material Table 2 Bill of material Item pon Reference Value Package R6 R8 R11 R14 R19 10 Res 10 KO 596 1 10 W 0603 SMD 10 KO 0603 R30 R32 R7 R12 2 Res 100 Q 5 1 10 W 100 Q 0603 R15 R18 4 Res 470 Q 5 1 10 W 0603 470 Q 0603 R20 R33 2 Res 1 KO 596 1 10 W 0603 SMD 1 KO 0603 R21 R23 R34 4 Res NP 0603 NP 0603 R24 R27 4 Res 4 7 KQ 5 1 10 W 0603 SMD 4 7 KO 0603 R28 1 Res 100 KO 5 1 10 W 0603 SMD 100 KO 0603 R29 1 Res NP 0805 NP 0805 S1 S3 3 Switch button SMD EVQQ2D03W CMS 6 5 x 6 x 3 1 TP1 TP2 TP4 TP7 6 Test point red KE
30. omprehensive set of power saving mode allows the design of low power applications The STM32F 105xx offers devices in three different package types from 64 pins to 100 pins Depending on the device chosen different sets of peripherals are included These features make the STM32F 105xx and STM32F 107xx connectivity line microcontroller family suitable for a wide range of applications such as motor drives and application control medical and handheld equipment industrial applications PLCs inverters printers and scanners alarm systems video intercom and HVAC and home audio equipment Please refer to the STM32F105xx datasheet for an overview of the complete range of peripherals proposed in this family Please refer to the STM32F105xx reference manual to get more information on the microcontroller operation The STM32F105RBT6 has a 64 pin LQFP package with a 128 KByte Flash memory and operates in the 40 to 85 C temperature range I DoclD025486 Rev 1 UM1691 General description Figure 10 shows the general block diagram of the STM32F 105xx and STM32F 107xx family Figure 10 STM32F105xx and STM32F107xx block diagram MIL TXD 2 0yRMH TXD 1 0 MIL TX CLK AMIL TX CLK Mil TX EN RMII TX EN Mil RXD 2 OyRMII RXD 1 0 MIL RX ER RMIL RX ER MIL RX CLK AMIL REF CLK MIL RX DV RMII CRS DV MIL CAS BAr 1 8 V to 3 6 V MIL COL RMII COL MDC S OSC32 IN PPR OUT OSC22 OUT E TAMPER RTC VBUS ALARM SECOND OUT ID DM DP
31. out and bill of material LLn 6 4 General description ie e e e ER RE RR RR eee 12 4 1 Power SUDply suk cia RE ER EE EE ET Ka 12 4 2 L6470 stepper motor driver EE EE SE EE SE EE se eee 13 4 2 1 Charge pump as uu dade ED e ens Ra TURO red 14 4 2 2 Voltage mode driving e e x e tee 15 4 2 3 Overcurrent and stall detection thresholds auaa 15 4 2 4 Speed profile ica semana bad rescued eme ese bedded ee vu EE 16 4 3 STM32F105RB microcontroller llle 16 4 4 Firmware loading 523 xx xe ri Re REIR ES AE EE EER Wee 18 4 4 1 DfuSe installation 0 0 ce eae 18 4 4 2 Generate a DFU file from a HEX file Se ee ee ee ee 18 4 4 3 Board Settings sd ues gs DEAR XR xx Verdad eu REX 20 4 4 4 DFU loadirig is sem aa ci od oL ocho nao nes Bor dod eaa 21 4 5 Using the EVAL6470H DISC with firmware for the GUI 25 4 5 1 Sanity check of the board with firmware for the GUI 25 4 5 2 Parameters exportation from the GUI to the FW library 34 4 6 Using the EVAL6470H DISC with the firmware library 35 4 6 1 FW library package contents EE ES SE EG eee 35 4 6 2 FW dSPIN library description EE EE EE ee Ee eee 35 46 3 Demonstration sequence description 2 0000 000 36 4 6 4 Create a project using the FW library package 40 5 Reference S EE cum Me Me nda RE esa Wate ed EER eek eet eee 41 6 Revision his
32. stration when the LED SPARE is blinking for the first time the user shall close the SW MOTOR jumper J8 This triggers a switch turn on event at the dSPIN SW pin For the ReleaseSW feature demonstration when the LED SPARE is blinking again the user shall open the SW MOTOR jumper J8 This triggers a dSPIN SW pin release At the end of the demonstration sequence the GPIO connected to LEFT and RIGHT buttons are configured to trigger interrupts on the microcontroller On a LEFT button press the microcontroller starts the motor at quarter of max speed if it is stopped or doubles the motor speed if it is already running On a LEFT button press the microcontroller disables the power bridges after a smooth stop if the motor is running at minimum speed or halves the motor speed if the motor is running above minimum speed Even if the Daisy Chain mode is supported in the dSPIN FW library the dSPIN Discovery board HW does not allow it Please contact ST support if you want more information on Daisy Chain mode testing or implementation The FW dSPIN library consists of the following files e user motion dspin inc stm32f10x conf h Library configuration file e user motion dspin src stm32f10x it clnterrupt handlers e user motion dspin inc stm32f10x it hHeader for stm32f10x it c user_motion dspin inc clock h System clock setup related header e user motion dspin src clock c System clock source file e user motion dspin inc dspin h dSPIN de
33. tory ass one oh edda sk Oh ek RARR E EE BESONDERE RE 41 2 42 DoclD025486 Rev 1 Ly UM1691 List of figures List of figures Figure 1 Figure 2 Figure 3 Figure 4 Figure 5 Figure 6 Figure 7 Figure 8 Figure 9 Figure 10 Figure 11 Figure 12 Figure 13 Figure 14 Figure 15 Figure 16 Figure 17 Figure 18 Figure 19 Figure 20 Figure 21 Figure 22 Figure 23 Figure 24 Figure 25 Figure 26 Figure 27 Figure 28 Figure 29 d Board image oim gx dp e duae ed geben ace ere Ru p a cr m ske qd es 1 Schematic microcontroller supply parti EE SE EE eee 6 Schematic microcontroller part EE EE eae 7 Schematic motor driver part EE Ee ee eee eae 8 Layout silk screen NG 9 Layout top layer and bottom layer vr eae 9 Microcontroller supply section 0 0 000 cee tee 12 L6470 block diagram EE EE eee ee 13 Charge pump Circuitry A R e R a ninni RR RR eR eee 14 STM32F105xx and STM32F107xx block diagram saasaa EE ee eee 17 DFU file manager action EE arver EE RIA 18 DFU file manager generation EE EE RII 19 Board Settings aaa RE EE EE N den ER EE RE EK 20 DEU loaditig AR EA RR ER e OE HORE N OE OE N 21 DEU le OPEN PETIT 22 DEU Tile Upgrade seres Z E araa raten de ee Ge remm n abuse Re wing Ge se a e ER n 23 DFU Tile confirmation ere ER eee asas T A ee RE RR ee 23 DFU file download OK lt aan EE RRR RRR R rn RRR RR ee a a 24 Starting bo
34. ured or not connected to the PC Figure 14 DFU loading bo E Es cation Mode r DFU Mode dor ID Vendor ID 0483 pports Upload C Manifestation tolera G de Supports De mv efioad ST Procuct ID Procuct Ip DF Can Detach Version Version 0200 Enter DFU mode HID detach Leave DFU mode ba i Actions Select Target s Targetld Name Available Sectors Double Click for more Do Internal Flash 128 sectors 01 SPI Flash M25P64 128 sectors m Upload Action 1 r Upgrade or Verify Action File File TTT Targets in file Eee ue anan e EH m Transferred data size Version OKB O Bytes of 0 KB O Bytes DE Ee iaa I Verify after download Optimize Upgrade duration Remove some FFs para erif L Abort Quit 3 In the Upgrade or Verify Action group click on the Choose button Operation duration 00 00 00 q DoclD025486 Rev 1 21 42 General description UM1691 22 42 4 Select the dfu file of your choice in the open dialog box and click on the Open button Figure 15 DFU file open Look in Ji v1 10 e amp iu By Date modified Type _ fwlibraries_dspin_discoverykit dfu 05 09 2013 12 03 DFU File Name 2 ab Recent Places I DoclD025486 Rev 1 UM1691 General description I 5 Click on the Upgrad
35. used by the dSPIN FW library e IAR workspace files user motion project ewarm6 fwlibraries dspin dspin eww a workspace file A user motion project ewarm6 fwlibraries dspin settings dspin wsdt a workspace settings file user motion project ewarm6 fwlibraries dspin discoverykit a directory containing the dSPIN discovery board project files and subdirectories A user motion project ewarm6 fwlibraries dspin discoverykit Debug Exe a directory containing the HEX and DFU executable files user motion project ewarmO fwlibraries dspin pcc009v2 a directory containing the PCC009V2 board project files and subdirectories 4 6 2 FW dSPIN library description I The FW dSPIN library has the following features e Register read write and check e Register values conversion e Device configuration e Motion commands e FLAG and BUSY interrupts management e Button interrupts management e Step Clock mode management e Initialization routine using GoUntil and ReleaseSW commands e Daisy Chain mode DoclD025486 Rev 1 35 42 General description UM1691 4 6 3 36 42 The FW dSPIN library has been tested on the L6470H DISCOVERY board R1 and the L6472H DISCOVERY R1 The main program contains a commented demonstration sequence which uses all the FW dSPIN library supported features This sequence is interactive and to proceed to the end some user action is necessary For the GoUntil feature demon
Download Pdf Manuals
Related Search
Related Contents
取扱説明書 ご使用前に必ず、ご確認ください Polar Cardio GX Help donkey kong`s moves MODIFICATION HISTORY Sensaphone 2800 Copyright © All rights reserved.
Failed to retrieve file