Stepper Motor Driver and Computer Interface Boards 1... Ifyou can't find any surplus motor s, investigate a company calledPacific Scientific-they have a variety of steppe r motors and al
Trang 1• Provides step-by-step instructions for building your own CNC mochine
• Greot for use os0 teoching tool in metol/wood shop
or on the industriol floor
GEOFF
www.TechnicalBooksPdf.com
Trang 2CNC Robotics Build Your Own
Workshop Bot
Geoff Williams
McGraw-Hili
New York Chicago San Francisco Lisbon
London Madrid Mexico City Milan
New Delhi San Juan Seoul
S ingapore Sydney Toronto
Trang 3Cataloging-i n-Publication Data is on file with the Library of Congress
Copyright © 2003 by The McGraw-Hili Companies, Inc All rights reserved Printed in the United States of America Except as permitted under the United States Copyright Act of 1976, no part of this publication may be reproduced or distributed in any form or by any means, or stored
in a data base or retrieval system, without the prior written permission
Printed and bound by RR Donnelly.
McGraw-Hili books are available at special quantity discounts to use as premiums and sales promotions, or for use in corporate training pro- grams For more information, please write to the Director of Special Sales, McGraw-Hili Professional, Two Penn Plaza, New York, NY 10121-2298 Or contact your local bookstore.
II\ Thi s book is printed on recycled, acid-free paper containing a
\:CI minimum of 50 percent recycled, de-inked fiber.
Information contained in this book has been obtained by The McGraw-Hili Companies, Inc ("McGraW-Hili") from sources believed to be reliable However, neither McGraw-Hili nor its authors guarantee the accuracy or completeness of any information published herein, and neither McGraw-Hili nor its authors shall be responsible for any errors, om issions, or damages arising out of use of this information This work is published with the under- standing that McGraw-Hili and its authors are supplying information but are not attempting to render engineering or other professional services If such services are required, the assistance of an appropriate professional should
be sought.
www.TechnicalBooksPdf.com
Trang 4For Margaret, whose help and patience made this book possible.
Trang 6Stepper Motor Driver and Computer Interface Boards 1
Trang 7www.TechnicalBooksPdf.com
Trang 8Contents
Trang 9I must tha nk mybrother Karl who inspi red metowrite this book and
my editor JudyBass who se fa ith and assistancemadethe book a rea l
-it I'dalso liketo thank Patric iaWallenburg who asse mbled mywordsand ima ges into book form Judy and Patricia have made this bookproject an extre mely enjoyabl eexperien ce.Finally mythanksgo outto
all the people who have feely shared with me thei r know ledge andassistance whileI was resea rchi ng and.building my CNCmachi ne
Imust thankthefollowing companiesfor allowingmetoinclude some
of their cop yrighted materia l in this book
The NuArc Company,Inc.does n' t promot e,endo rse.orwa rra ntyanymodified product s NuArc le t me reproduce so me ofthe imag es from
the repair ma nua l of the copy came ra I disassembled but they don'tendorse the use ofthei r products for anythingother tha n their origi-
nall intended function You can contact NuArc at M&RSa les andService, Inc I N.372 Main Street ,Glen Elly ,IL 6013 7,USAor on theWeb at http:/ /w ww.nua rc.com
Kellywa re has allowed me to use scree n ca ptures of the progra m
KCa m 4.Ke llywa reca n becontacted at POBox 563 SpiritLake.Iowa
5236 0,USA or on the web at http:/ /www.kellyware.co m
The product data sheet s included with Chapter 2 of this book have
been reprinted withthe perm iss ion of STMicroelectron ics The ments reproduced in th is book and many more useful application
docu-notes can be found at the STMicroelectron ics Web site loca ted at
http:/ /www.st.co m
Scien ce Speciali st s, Inc has give n me permission to include scree ncaptures of the softw a re ACME Profller, Coyot e Version 6.0 Scien ceSpecialists,Inc.ca n be rea ched at 1800 Shec kle r Rd Columbia City,
IN 4675, USA or on the Web at httpt/ zwwwzfw t.co m/ v.klmble/
scispec/scispec.htm
www.TechnicalBooksPdf.com
Trang 10Why Build My Own
I first thought about adding a CNC router to my tool collection
after finis hing a kitch en cab inet renovatio n in my home.I refaced
the cabinets and built 26 new doors during whic h I discovered
that door building can becom e mo noto nou s at best As always
hap pens when you tell or show your friends and famil y whatyou
have don e, som eone wi ll have a similar pro ject and enlist your
help That someone was my friend Geoff S He wanted to do the
same thing to his kitchen-reface and install new cabinet doors I
agreed to help him and he decided on a style of door that can be
made from one piece of material cut to size and routed to create
thelookhe wanted.Ofcourse theprospect ofbuil dinga who leJot
of doo rs and making temp lates to facilitate the routing wasn'ttoo
thrilling That's when Itho ught a small CNCmachine would come
in han dy All the repeti ti ve routing could be asslgned to the CNC
mach ine and the doors wou ld more closely resemble each other
once human erro r had been removed from theequation Now the
project didn't seem too bad at all!
I started to look for an affordable machine to do the job, After
searchingthe Intern et,I was shockedto find how much theasking
pri ce is fo r a CN C machine I did find a couple that were under
Trang 11CNC Robotics
56000 U.S.,but I ca n never co nv ince myse lf to buya toolworthso
much Even ifthe cost of the machin e seems reasonableyou still
h ave ship pingand duties to pay,and in my case the excha nge ra te
betwe en U.S and Ca na dian dollars All things considered, it wasgoing to cost me in excess of 510,000 Canad ian to get a CNC
ma ch ine in my shed.I can't afford that kind of pricetag! I searchedfor plans or a book that described what Iwantedto build.I did findsome plans on the Internet but either the machine was too smalland inaccurate or the plans were expensive and required the use
of expensive components I couldn't find any books in print about
a similar project I won't buy plans that I can't get a good look at
first,so the Inte rnet plans were out of the question I prefer booksbeca use Ican hold them and flip through the pages before I hand
o ve r the cash Books also cost less
I decide d to build my own ma ch ine using some off-t he -she lf
linea l mot ion compo ne nts and some compone nts tha t I s alvaged
or modified to suit the project I thou gh t the most logical thing
would be to docum ent my progress and share the inform a tion
through a book To sum ma rize,Idecided to build my own ma chin e
because Ilo ve a cha llenge and I learn more whe n I have a pra cti
-c lproject; also, Ica n keep the cost low It's that simple
Gantry Style
In my opinion , a gantry styled CNC machine is simplestto imple
-ment Afew years ago, I built a ba nd saw millfram e and gantry,
so the design ofa more accura te system didn't seem too tough a
pro ject Ialso like the idea of moving the tool over the material
ra th er tha n the mat er ial under the tool A mach ine built to move
ma teria l would not h ave as la rge a working area for a g iven print Con s idering my work shed is only 22 X 12 feet, a gantrymachine is most suitable
Trang 12-Chapter1 / Design
first Sure enoug h, they had some step-syn motors (seen in
Fig u res 1.1 and 1.2) They are Nema frame size 34, draw 1.4
amps per cha n nel, and have aratingof 4.6 volts
Trang 13CNC Robotics
These motors we re used in an IBM produ ct -probabl y a printer
They are unipolar, but ifyo u run them as bipolar they prod ucemore torqu e (see Figure 1.3)
1 also disco vered thatthese steppe r motors work better if they are
given 12 vo lts insteadof the 4.6-voltratin gon the motor body.Thestrength of a stepper motor is rated in ounce inches of holdingtorque The ste p-sy n information 1 fo und ind ica te d tha t these
motor s are anywhere from 9 to 220 ounce inch es Isometimes
wo rk backward s,and buying the motors first is ce rta inly just that !
No rma lly,yo u would calculatewha tstrengt h of motoryou need torun the machine and then purc ha se a suita b le motor Here's how
to calculate the st re ngt h of motor you need to run this machine Ifyou can't find any surplus motor s, investigate a company calledPacific Scientific-they have a variety of steppe r motors and alsomake available software for downloa d, which yo u ca n use todetermine the size of motor yo u need Spea king with them, Iwasimpress ed with how well Iwa s treated, co ns ide ring 1wo uld onlyneed three of the ir motors
Remember that although brand new motors are expe ns ive, youknow they will wo rk and yo u ca n match the streng th to themachine New motors could also speed up the mach ine consider-ably When 1 say "speed up," it is important to not e that I amreferring to trav elspeeds, not cutti ng speeds Cutting speeds for
most material s will be slowwith this sty le of machine, rega rdless
of which motor yo u choose; you ca n't run a ro ute r thro ug h wood
at 200 inches per minute and expect the cut to look good Cuttingspeeds of 10 to 30 inches per minute define the ra nge we can
expect from this machine wit hthese motors Afast er machinecan
be expected to travel quickly when not cutti ng and slow downwhen cutti ng through mat erial
Lineal Motion
There are a va riety of off-the-shelf lineal motion prod ucts , but
most of the systems we re too expe nsive for this project Think ing
that it wo uld be useful some day 1acq uired a NuArccopy camera
a few years ago (see Figure 1.4), so 1took it apart and found i4
, - - - -www.TechnicalBooksPdf.com- - -
Trang 14-Chapt er 1 / D esig n
S TEP -SYN 10 3-820-0240 4.5V 1 4 AM P 2 DEG /S TEP
WIR ING DIAGRAM
WH I TE
B L UEN/ HITE - P HAS E D
B OLAR CONN ECTIONS
B LUE - PH ASE C
W H I TE - - PHA S D
B LUEN/HI TE - N OT C O NNEC TED
B IPOLAR FU LL W I N ING ( MOR E lORQ UEJ
<-WHI TE N OT CONNEC TE D Ai\lfo
Trang 15-C NC R o bot ics
Figure 1.4
Ex ploded illu stration o f he NuArc M odel SST 1418 supe rsonic h ori z ontal c ame r a P art 2 1 i s the ca rriage
t hat t ravels o the gu id e rai ls usi ng li neal bearings
6
1 - - - -www.TechnicalBooksPdf.com- - -
Trang 16-Chapte r1 / Design
useslnealbearingsrun ning on guide rais to movethe copy board
as well as the bellows
The slide employed to move the bellows and cop y board wo uld
work well as the y-axis for my CNC machine.And it wascomplete
with beari ngs and holders built into the slide, as pictu red in
Trang 17Fi gure 1 6
C loseup of the sl ide
s howing the bearings
numbered 40and the
location of lead scr ew
nut n umbered 33
CNC Robotics
Of the eight bearings, I found thatonlyfour were still in satisfacto
-ry condition fo r use I decided that the x-a xis could be built in thesame ma nner, employing open linea l bearings running on a ra il
tha t ha d been drilled and tapped to allow the use of support bolts
I also chose toma ke my own bearing holdersfor thex-ax is because
the cost of preb uilt prod uctswas mo re than Icou ld justify.Rail sup port materi al is available as well,but the cost of this product made
-me believe it wasn't required and that the bolts wouldgive the rail
eno ug h support I noticed tha t the copy camera didn't have any
ext rasup portunderthe rails If youwantedextra supportin a proect like this, it could be fashioned fro m two pieces of angle iro n
j-with a spacer, but the surface itwould be mounted on-consideing the rail would be in contact with the support-would have to beperfectly flat As Ihad no intention of using perfect steel to buildthis machine,having the bolts provide the support meant that theycould be adjusted to bring the rail to a flat plane
r-Simi lar bearings andra ilscouldbe used for the z-axls,but Id
ecid-ed instea d to use a swiveling TV tray assembly bought at theHome Depot The glides are ra ted at 100 Ibs to hold a televisio nhorizontall y My pro ject would use the glides vert ica lly, so they
wo uld be plenty stro ng, with la rge ballbea rings and enough tra
v-el for the z-axls The NuArc camera used 3/4 -inc h bearings andsupport rails, so Idecided to use the same bearingand rail size on
the x- axis
8
r - - - - www.TechnicalBooksPdf.com- - -
Trang 18-Chapter 1 / Design
Motor Drivers
At this point in the project 1had alread y purchased motors, so I
looked at simple driver so lut io ns The best solution was found in
the form of the 1297and 1298 integ rated circuitsmanufactured b
ST Microe lec tro nics The ir Web site has all the information
need-ed to build a bipolar steppe r motor driver using these two
inte-grated circuits,which areoften refe rred to as "chips." Adriver built
from these chips can easily provide the vo ltag e and amperage
needed bythe step syn motors
Acme Screw
The question of how to move the gantryand axes slides was also
resolved by cost I had originally co ns ide red using ball screws,but
after co mpar ing the cos t of the ball s crew wit h that of an a cme
screw, it didn't make sense to spe nd three times as much on ba ll
screws The advantage s to using ball screws are that a smaller
motorca n be used to moveagiven load, and with a pre load ed nut,
the re is very little backla sh in the system As mentioned ea rlier in
this cha pte r, this is a machine tha t will not speed thro ug h its
as sign ed jobs so we canco mpe ns a te for backla sh in the softw a re
This means the project ca n be built usin g less expensive acme
screws.
I also had to decide how many turns per inch to put on the acme
screw My experiments with r eady ro dproved that too man y tu rns
made fo r annoy ingly slow movem ent and too few turns redu ce s
the qual ity of resolution that allows the machine to make small ,
precise movem ents 1sett led on a 1/2 -in ch acm e screw witheight
turns per inch, and a 6- foot length with a nut at a cost of $135
Deciding on the Dimensions
of the Machine
Earlier in the cha pte r 1 expla ined that I made the deci sion of
machine footprint size based on the area in my wo rks hop
Trang 19Fig ure 1 7
View from side of
proposed machine.
CNC Robotics
Becau se I on ly have a space 12 X 22 feet and tools and mate
ri-alscu rrently occupy most of tha t space, my machine would only
be about 7 feet lo ng and 4 feet wide The next step in thisprojeciwas to generate concept drawings, since Iwas going to use some
of the components from the NuArc horizontal camera Thedimensions of the frame ended up being longer than the supportrails in order to accommodate the bearing holders and the motormount with a little roo m10spare The width of the frame is a few
inches shorte rthan the balance of a 6-footacme lead screw, after
the length needed for the z-a xis has been cut from it The follow
-ing illustrations are the concept drawings 1 created to guide the
cons tr uctio n of the machine Figure 1.7 is a drawing of the
machine fro m the side
The next illustrati on, Figure 1.8, is the width of the mach ine,
viewe d fromthe front
Software
After figuring out the approximate shape and dimensions and
decid ing on stepper motors and drivers, the next question waswhich software to use to control the machine once finished 1looked at a variety of software solutions and, since my level of
experience withCNC machinery was nonexistent, I wanted a pro
-gra m tha t was easy to use To communicate to the stepper motors
1
r - - - - www.TechnicalBooksPdf.com- - -
Trang 20how to move so the tool being used willfollowthe desired path, a
prog ra m is written in G-code and M-code The G- and M-codes are
used totellthe machine where to go in the xyx-axes areas of t
rav-el and what to do when it gets there Very simple programs
describing things like boxes orcircles are not very complicated to
writeyourself.1wa nted software that wou ldallow me to create my
own designs in a drawing program like CorelDrawand then import
the drawing and auto matica lly crea te the necessary G- and
M-code file 1loo ked at some freeware but was disa ppointed by the
level of difficulty to imple me nt the software and get it doing what
I wanted Furt her research revealed software called KCam that
woulddo exactlywha twas necessary.See the screencapture from
KCam in Figure 1.9
KCam isn't freeware, but it certai nly isn't expensive either at $100
U.S percopy The fact that KCam is not expensive sho uld n't lead
youto believe it is ineffective software It is extremely easy to use
and allows you to customize the use of the printe rport.KCam will
Figure 1 8 Front view of mac hine
a long its width
Trang 21, ~
:-i L ' t ,
- ' 1; l~ ,'"'C, t -·-~I
also import H PGL fil escrea ted in Corel Draw 9 or O X F files created
in CADsoftware lke AutoCa d or in CorelDraw 9
In this cha pter Ishared design choices fo r my CNC machine and
the rea so ns behind them, as wellasthe choices of steppermotors,drivers.and software.At this point in the project we need to start
thinking about the elec tro nics the topic of the next chapter
www.TechnicalBooksPdf.com
Trang 224k 4k 4 k 4 k 4k 4k
Electronics
Stepper Motor Driver and
Computer Interface Boards
This chapter deals wit h the design and construction of the
elec-tronics required for controlling stepper motors using a computer
and Keam software The requirements for the drivers are based on
the step- syn motor purchased in the previous chapter from the
surplus department of Princess Auto (see Fig ur e 2.2)
In addition to these surplus motors, I also bought three new
motors from Pacific Scientific, also mentioned in the previous
chapter (see Figure 2.3)
F igure 2 1 The fin ished boa rds
Trang 24Chapter 2 / Electronics
motors areratedat 4.5volts and the PacificScientific mot or canbe
Scientific motors in this project, if you are unable to find suitable
surplus steppers you may wish to purchasenew ones WARNING:
hor-oughly to gain a greater understa ndingof the strengths and lim
i-tations of the L297 /L298 integrated circ uits (referred to as ICs) in
this applic ation
Stepper Motor Driver Circuit
They receive signa lsfro m the co mp uterthat ind icate whic h d
irec-tion that axis will travel and how far it will move They are the
muscles becau se as they receiv e direct io n and step signa ls from
Figure2.4L297stepper motor
controller IC
Figure 2.5
L298 HBridgeIC
Trang 25CNC Roboti cs
the computer, they translate the information into higher voltageand amperage signa ls to send to the stepper motors The powersent to the stepper motor coils is distributed to the coils in asequence that will move the shaft in the desired direction as manysteps as are needed to traverse the distance required on that axis.For this project we need thr ee driver boards one for each axisoftravel The boards are designed usin g a set of integrated circuits
manu factured by STMicroelect rion ics- t he L297 and L298 Thenice thing about usin g these two chips is that the board design is
quite simple only requiringa minima l number of components Asecond benef it is that when combined, these two chips create avery powerful driver boar d capable of handli ng up to 36 voltsand
2 amperes per channel A lot of bipolar and uniploa r steppermotors currently manufactured or available as surplus.which arestrong enough to be used for this machine are well within the tol-erances of these chips The steppers that I decided to use are
Sanyo Denki step-synand are rated at 4.5 volts and 1.4 amps per
channelwit ha resolution of 2 degrees per step The powerratingsare well within thetolera ncesof thedriverboard You can refer tothe schemat ic (Figure 2.6) to determ ine the componentsrequired
Trang 26en CD
Trang 27Now for a brief explanatio nof thecircuit; note thatI am incl udi ng
in this chapter the data sheets for the L298 and L297 ICs as well
mat eria l at will (see pages 22 through 75) The information con
-tained in these documents is essentially all you need to create the
ral-lel port to pin 17 on the L297 for di rect ion of the stepper motor
volts to function The eight FR304 diodes clamp the stepper motorwindings to motor voltage and ground Diodes used for this pur-
pose must be fast recovery but could be a differentvalue based on
the amperage needed by the stepper motors used This protects
the L298 from the induced high voltages generated by the stepper
moto r when the any of the windingsare turned off
resi stors connected to ground.All drivecurrents used by the st
ep-per 's two field wind ings are passed thro ugh these resi sto rs The
resistor connected to pin I takes the cur rent from one of the two
method of measuring the curre nt being induced within the
18
www.TechnicalBooksPdf.com
Trang 28Chapter 2 / Electronics
motor.The L297 measures the voltage drop across these res istors
to control the PWM chopper circu it used to control the current
within the windings of the ste ppe r motor The 2.2 Kand 10 Kr
esis-tors connect ed to pin 15 (Vref) on the L297 are used to set up a
voltage divider The resu lt ing vo ltage applied to the Vref pin is
used as a set point againstthe measured vo ltage coming from the
field wind ings When the set point is reached , the power drive
stage within the L298 driving tha t winding is turned off, allowing
the FR30 4 diodes to discharge the field winding The field winding
stays off until the internal oscillator within the L297times out and
turns the field winding back on The 22K resistor and the 3.3 nF
capacitor co nnec ted to pin 16 on the L297 set up the timer's cho
p-per rate.C2, C3,and C4filter the power supplyfor the elect roni cs
and motors jP I provides power and gro und for the circuit and the
motors.jP2 is jumped to includethe circuitconnected to pin I with
pin 16 on the L297 on only one board of the th ree used; the other
two have pin 16 on the L29 7 jumped to gro und JP3 pin Iaccepts
step signal s;pin 2 accepts direction sig na ls; pin 3 is use d to
con-nect all drive r boards that need to be sync ed and pin 4 is gro und
jP4 is set to bring pin 19 on the L297 high at pin 1to provide full
step motor drive or lowat pin 3 for half step JPS is set to brin gpin
li on the L297 high at pin I to use pha se driving or low at pin 3
to inhibit drive
Don't wo rry toomuch about under standinghowthiscircuitwor ks;
as long as you follow the direction s closely, the boa rd yo u build
will function properly
The Interface Board
This board is rea lly only a gateway that allows the computer to
send and receive signals to the driver s and limit switches There
isn't much to it as ide from a co nnecto r for the straight-through
parallel port ca ble and some connect io ns for the wires coming
from each of the driver boards and limit switches Ifyo u refer to
the sche ma tic (Fig ure 2.7) yo u willsee why the parts list is short
19
,
Trang 301-17 pin,5-2pin
DB 25 connector4.7K ohm resistorHeader material
Interfa ce Component s
List
The4.7K resi stors limit curren t to protect the circuit and the
par-allel port Better methods of protectingthe parallel port are to use
an optical isolation circuit or install a parallel port card
specifical-ly to be used wit h the interface; the cards are cheap insurance
against damaging a motherboard bought a usedcomputer sole
-ly for use with these boards because if I destroy it I wo n 't lose
years of accumulated files
The pin out of the interfaceboard is straightforward Pins 1-17 on
jP 1 areconnectedto pins 1-17of the parallel port ofyour
comput-er jP2 is connectedto pin 10 on jP I at pin 1and to ground at pin 2
jP3 isconnectedto pin lionjPl at pin 1 and to ground at pin 2.jP4
is connected to pin 12 on [P 1 and to ground at pin 2 jP5 is
con-nected to pin 13on IP I and pin 2 is connected to ground I brought
pins 10, II, 12, and 13 on JP lout to separate connectors to make
hooking them to limitsw itches a little easier At JP6, pin I is to be
connected to 5volts and pin 2 to ground on the pow er supply
Thischapter will have given you an understanding of the circuits
that are needed to connect and control the stepper motors with a
comp ut er You will also ha ve become familiar with the integrated
circuits that the dri vers are built around This understanding will
enable you to bett er troubleshoot your boards when they are com
-plete The next chapter deals with making the printed circ uit
boards using the toner transfer method
I
Trang 31CNC R o botics
L297 L297D
O RDERING N M BER S : L29 7 ( OIP20)
L2 970 (5020 )
-TION
• PR OG RA MM AB LE L OA D CU R REN T
• RE SET I NPUT & HOM E O UT PU T
m-p ute r-conlrolled a pp l ications The m otor ca n be
a nd on - ch ip PWM cho pper cir cuits pe r mit
switch-m ode co ntro l o f th e c urrent in th e wi nd i ngs A
icro-p rocessor a nd the programmer , s g reatly reduced
Mo unte d in D IP20 a nd 8020 packages , he l297
T Itg Ti S torage and junct ion t emp eratu re - 40 to+ 150 "C
Trang 32-Chapter 2 / Electroni cs
Trang 33CNC R oboti cs
L29 7·l297 D
P IN FU NCTIONS - l2971L297D
1 SY NC OUtput of the on-ch ip chopper oscillator
The SYNC con nec tions The SYNC co-oecnco s 0 all l297s to be
sy nchrooi z ed are coonecled toge the r and the oscillator components ar e omitted on all but one If an external c loc k source
is used it is in je c ted at this te rmina l.
3 HOME Ope n co llec to r outpu t that indicates wh en th e l297 is in it initial
s late (AB eD = 0 101)
T e transistor i s open when this gna l is active
4 A Motor pha se A driv e signal for pow er stage
5 IN Hl Active low inh ibit control for dri ver stage of A and B phases.
Whe n a b ipola r bridge is used this signal ca n be used 1 0 ensure fas! decay of load c u rrent when a wi ndi ng i s de-e nergi zed Also used by chopper 1 regulate l oa d current if CONT ROL i nput is low.
6 B Motor pha se 8 d riv e si gna l for power stag e
7 e Motor pha se C d riv e si gna l for power stage
S I NH2 Activ e low inhibi t con trol for drive stages of C a nd 0 phase s.
same functi on s a s INH 1.
9 D Motor pha se 0 driv e si gnal for power stage
I ENABLE Chip ena b le i n ut When low ( inactiv e) INH1 INH2 , A B, C and D
are brought low
11 CONT ROL Control inp ut that del ines action of choppe r.
When low cho pper acts o INHl and I N H2 ; when hig h choppe r
ac ts on phase lines ABC D.
13 SENS 2 Input lor loa d cu rrent se nse vo ltage f rom power stages 0 pha ses
C and D
14 SENS , Input lor loa d curre nt se nse voltage from power stages 0 phases
A and B
1 V Re ferenc e volta ge l or chopp er ci rcui t A vola ge applied t o this p i n
determine s t he p eak loa d current.
An RC network ( A t o Vee C to ground ) comec ted to this termina l
, ose determ ines the chopper ra te This term inal is connecled 1 ground
on all but one d evice i n synch roniz ed mu lti - l29 7 confi g urations I
== 1I0 69RC
1 CW IC CW Clockwi seicou ntef'Clod(wi se direction control inp ul.
Phy sical direction 0 motor rotation a lso dep e nds on con nec tion
of wi ndings
Sy nchroni z ed inte ma lly therefore di r ect i on ca n be c ha nged at any time
18 C LOC K Step cloc k An active low pulse on this input advance s Ihe moto r
one inc reme nt T e step occurs on the ris ing edge 0 th signal.
3/11
2
Trang 34Chapter 2 I Electron ics
12 97· 12970
when low se lects l un s tep ope ration On e-phas e-on ful l step m ode
is ob tained b y sel ecting FU LL wh8f1 the l29 7's translat or is at an
e veo-numoered sla te
Two-pha se-on lull s tep mode is s et b y se lecting F ULL w he n th e transla tor is a t an odd num b ered position (The hom e positi on is
de signate sta te 1 )
20 RES ET Reset in put An active low p ulse on this i np ut restores th e
translat or to th e home posi tion (st ate 1, A BeD = 0 10 1).
max 80
100 oem
T he L Z 97 i s i nte nded f o r u se with a d ual bri dge
d r i ve r , quad darlington array or discrete pow e r
de v i ces in s tep motor d ving app l catio n s It
re-c eives s te p c lock , d irection a d m ode s i gnal s fr om
th e sy s tems co n trolle r ( usua lly a micro comp ut
c hip) an d ge n era te s c o ntro l si g a l s fo r t h po we r
s tage.
T he p r in c i p l fun ct i o s a re a trans l ato r , w h ich ge n
-e ra tes the m oto r ph as e seque nc es , and a d ua l
P WM c hoppe r c i rcuit w hi c h r e gu la tes t he c urrent i n
th e m otor wi n di ngs Th e t ra n s l ato r g enerates t hree
d ifferen t s eq ue n ces , se lec ted b y t he H A L F /FU LL
inp u T h ese a re no r ma l ( t wo phas e s e nergised ),
wave d r ive (one p ase e ne rgis ed) and half -s p
(al t ernately o ne p ase e ne rgised/ t wo p has e s e
n-erg ised) T wo i nh ibit s ig na ls a r e l so ge ne rated b y
t h e l297 in h l f step and w ave d riv e mod es T h ese
si g na l s, wh ich co nnect d irect ly to the L2 9 8 ' s enabl e
i nput s , a re i ntended to spe ed cur ren t d eca y wh e
a wi nd ing i s de-energis ed W hen th e L2 97 is u sed
to d rive a u i po l ar moto r t h e choppe r a cts o n th ese
l ines
An i nput ca lled CO NTROL de term ines w hethe r t he
choppe r will a c t on the p hase l ines A BCD or the
inhibit lines INH1 and I NH2 When th e p hase lines
4111
are cho ppe d t he non- act i ve p hase l i n e of ea ch p a i r
(A B or C ) is a c t ivated(rathe r tha n in te rrupti ng t he line the n ac tive) I n 2 7 + L 298 conf igurati ons t hi s tec h ni q ue r ed u ces d i ssipa tio n i n th e l oad c u r rent
se n se r e s i s t ors
A co m on o n-c hip osc i ll ato r d rives t he d ua l
chop-pe r.lt su pp lie sp u ls es a t th e cho ppe r ra te w hich s et
th e t w o flip -f l o ps FF 1 nd FF2 W hen th e cu rr ent i n
a w ind ing r e ch es th e prog rammed p eak v alue the volt a ge ac ross th e se nse r e si or ( co nn ect ed t o
o ne o f th e s e nse in puts S E NSl o r S N&?) equal s
V ra l and th e co rrespo ndi ng c ompa r ato r r es e t s i t s
f l ip fl op , i nter rupti n g th e r i ve c urren t u nt il th e ext
osci llato r p l se a rr ives The p ea k c u rr en t fo r bo th
wi ndings i s pr og r a mmed by a volt aged ivideron the
V, al i np ut.
G rou nd no ise p r ob l ems i n m ultip le confi guratio ns
can be a voi ded b y s nchronising th e chopp er
os-c i ll ato r s Th is is do ne b y co n nect ing a ll th e SY NC
pi ns together moun t ing t he oscillat or R C n etwork
on one de vice on ly and groundi ng t he OSC pi n o n
all other devi ces
Trang 35CNC Ro botics
L 297·l297D
for norma l drive, w ave dr ive and half s tep modes.
these three modes are shown below In all cases
ansis-tionof~.
-tation the sequences are simply reversed liESET restores the translator to state 1 , w here ABeD =
0101.
o
No rmal drive m ode (also ca lled " two-phase -on" dr ive) is selected by a low level on the HALFJro[[ input
Trang 36-Chapte r2 / Electronic
Wave d r ive mode (a lso ca lled "one- phase-on" drive) i s se lected b a low l evel o n the H AL F/F'O[[ i nput
w hen th e t ranslator is at a e ven n um b redstate (2 , 4 , 6 or 8)
61
Trang 37CNC Robot ic s
ELECTRiCAL C HARACTERISTICS (co n tinu ed)
L297·l297D
Symbol P a ran e t er T est con d Ition s M i n Typ Max: UnIt
V ~ sat uration vol tage ( pin 3) I ",SmA 0 ' V
(pins 1 , 14 1 )
Trang 38Chapte r2 I Elect ronics
L 297-L297D
APP LICATION I NFORMATION
Th is circuit d r i ves b ipola r steppe r moto rs wit h wind i ng c u rr ents u p t o 2A T e d iode s are fast 2A typ es.
Trang 39CNC Robot ics
L297 -1297D D1P20 PA CKAGEMECHANICAL DATA
Trang 40L297 -L297 D
Chapter 2 / Electronics