<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8">
<meta name="generator" content="pdf2htmlEX">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="stylesheet" href="https://static.pudn.com/base/css/base.min.css">
<link rel="stylesheet" href="https://static.pudn.com/base/css/fancy.min.css">
<link rel="stylesheet" href="https://static.pudn.com/prod/directory_preview_static/622b4e0615da9b288b585b77/raw.css">
<script src="https://static.pudn.com/base/js/compatibility.min.js"></script>
<script src="https://static.pudn.com/base/js/pdf2htmlEX.min.js"></script>
<script>
try{
pdf2htmlEX.defaultViewer = new pdf2htmlEX.Viewer({});
}catch(e){}
</script>
<title></title>
</head>
<body>
<div id="sidebar" style="display: none">
<div id="outline">
</div>
</div>
<div id="pf1" class="pf w0 h0" data-page-no="1"><div class="pc pc1 w0 h0"><img class="bi x0 y0 w1 h1" alt="" src="https://static.pudn.com/prod/directory_preview_static/622b4e0615da9b288b585b77/bg1.jpg"><div class="t m0 x1 h2 y1 ff1 fs0 fc0 sc0 ls0 ws0">Altera Corporation <span class="_ _0"> </span><span class="ls1 ws1">1</span></div><div class="t m0 x1 h2 y2 ff1 fs0 fc0 sc0 ls2 ws1">AN-488-1.0</div><div class="t m0 x2 h2 y3 ff1 fs0 fc1 sc0 ls3 ws2">Application Note 488</div><div class="t m0 x3 h3 y4 ff1 fs1 fc0 sc0 ls4 ws3">Stepper Motor Contr<span class="_ _1"></span>oller</div><div class="t m0 x4 h3 y5 ff1 fs1 fc0 sc0 ls5 ws4">Using MAX II CPLDs</div><div class="t m0 x1 h4 y6 ff2 fs2 fc0 sc0 ls6 ws1">Introduction</div><div class="t m0 x5 h5 y7 ff3 fs3 fc0 sc0 ls7 ws5">This application note details the <span class="_ _1"></span><span class="ls8 ws6">implementation of a stepper motor </span></div><div class="t m0 x5 h5 y8 ff3 fs3 fc0 sc0 ls9 ws7">controlle<span class="_ _1"></span>r using an Altera</div><div class="t m0 x6 h6 y9 ff3 fs4 fc0 sc0 ls1 ws1">®</div><div class="t m0 x7 h5 y8 ff3 fs3 fc0 sc0 lsa ws8"> MAX</div><div class="t m0 x8 h6 y9 ff3 fs4 fc0 sc0 ls1 ws1">®</div><div class="t m0 x9 h5 y8 ff3 fs3 fc0 sc0 lsa ws8"> II CPLD. Y<span class="_ _2"></span>ou can control the motor </div><div class="t m0 x5 h5 ya ff3 fs3 fc0 sc0 lsb ws9">using just a few inputs fr<span class="_ _1"></span><span class="ls8 wsa">om a custom-made keyboar<span class="_ _1"></span>d.</span></div><div class="t m0 x1 h4 yb ff2 fs2 fc0 sc0 lsc wsb">Stepper Motors</div><div class="t m0 x5 h5 yc ff3 fs3 fc0 sc0 lsd wsc">The advantage of precision contr<span class="_ _1"></span>ol, op<span class="ls1 wsd">en-loop contr<span class="_ _1"></span>ol of the motor<span class="_ _2"></span>, self </span></div><div class="t m0 x5 h5 yd ff3 fs3 fc0 sc0 lsd wse">contained braking, and the absence of brushe<span class="_ _1"></span>s, makes the stepper motor </div><div class="t m0 x5 h5 ye ff3 fs3 fc0 sc0 lse wsf">a convenient<span class="_ _1"></span> choice for a variety of <span class="lsf ws10">spe<span class="_ _1"></span>cialized applications. Pri<span class="_ _1"></span>nters and </span></div><div class="t m0 x5 h5 yf ff3 fs3 fc0 sc0 ls10 ws11">plotters, disk drives, r<span class="_ _1"></span>obots, CN<span class="ls11 ws12">C machines, and other precision </span></div><div class="t m0 x5 h5 y10 ff3 fs3 fc0 sc0 ls10 ws13">machines are common examples wh<span class="ls12 ws14">er<span class="_ _1"></span>e the stepper motor is used </span></div><div class="t m0 x5 h5 y11 ff3 fs3 fc0 sc0 ls11 ws1">extensively<span class="_ _3"></span>.</div><div class="t m0 x5 h5 y12 ff3 fs3 fc0 sc0 ls11 ws12">A stepper motor<span class="_ _4"></span>’s operation can be explained by considering a series of </div><div class="t m0 x5 h5 y13 ff3 fs3 fc0 sc0 ls10 ws13">electromagnets arranged in a circle <span class="ls13 ws15">to encapsulate a r<span class="_ _1"></span>otor made up of a </span></div><div class="t m0 x5 h5 y14 ff3 fs3 fc0 sc0 ls14 ws16">magnetic material. When these so<span class="ls15 ws17">lenoids, or electromagnets, ar<span class="_ _1"></span>e </span></div><div class="t m0 x5 h5 y15 ff3 fs3 fc0 sc0 ls16 ws18">energized in sequence, the magneto motive for<span class="_ _1"></span>ce (MMF) developed<span class="_ _1"></span> in </div><div class="t m0 x5 h5 y16 ff3 fs3 fc0 sc0 ls8 ws6">them interacts with the rotor and caus<span class="ls11 ws19">es it to r<span class="_ _1"></span>e-align to the magnetic </span></div><div class="t m0 x5 h5 y17 ff3 fs3 fc0 sc0 ls17 ws1a">field, thereby causing it to r<span class="_ _1"></span>otate <span class="ls7 ws5">in a clockwise or counter<span class="_ _1"></span>clockwise </span></div><div class="t m0 x5 h5 y18 ff3 fs3 fc0 sc0 lsd ws1b">direction. The motor<span class="_ _4"></span>’s angular displace<span class="ls1">me<span class="_ _1"></span>nt can be controlled by simply </span></div><div class="t m0 x5 h5 y19 ff3 fs3 fc0 sc0 lsd ws1c">switching these electromagnets on or <span class="ls11 ws1d">of<span class="_ _1"></span>f in a fixed pattern for the desir<span class="_ _1"></span>ed </span></div><div class="t m0 x5 h5 y1a ff3 fs3 fc0 sc0 ls18 ws1e">motion of the motor<span class="_ _2"></span>.</div><div class="t m0 x1 h4 y1b ff2 fs2 fc0 sc0 lsc wsb">Stepper Motor </div><div class="t m0 x1 h4 y1c ff2 fs2 fc0 sc0 ls19 ws1">Controllers </div><div class="t m0 x1 h4 y1d ff2 fs2 fc0 sc0 ls1a ws1f">Using MAX II </div><div class="t m0 x1 h4 y1e ff2 fs2 fc0 sc0 ls1 ws1">CPLDs</div><div class="t m0 x5 h5 y1f ff3 fs3 fc0 sc0 ls10 ws20">The motor contr<span class="_ _1"></span>oller implemented in th<span class="ls7 ws21">is design uses a MAX II device to </span></div><div class="t m0 x5 h5 y20 ff3 fs3 fc0 sc0 ls9 ws22">govern (as you have pr<span class="_ _1"></span>edetermined) the performance and operation of a </div><div class="t m0 x5 h5 y21 ff3 fs3 fc0 sc0 ls7 ws23">unipolar permanent magnet stepper motor<span class="_ _2"></span>. The design uses a few </div><div class="t m0 x5 h5 y22 ff3 fs3 fc0 sc0 ls7 ws15">switches and buttons on the demo bo<span class="lsf ws24">ard to <span class="_ _1"></span>serve as the user inte<span class="_ _1"></span>rface.</span></div><div class="t m0 x5 h5 y23 ff3 fs3 fc0 sc0 lsa ws25">This motor contro<span class="_ _1"></span>ller design of<span class="_ _1"></span><span class="lsd wsc">fers the following advantages:</span></div><div class="t m0 x5 h5 y24 ff4 fs0 fc2 sc0 ls1 ws1">■<span class="_ _5"> </span><span class="ff3 fs3 fc0 ls15 ws26">T<span class="_ _2"></span>wo types of contr<span class="_ _1"></span>ol for starti<span class="ls18 ws27">ng and stopping the motor and </span></span></div><div class="t m0 xa h5 y25 ff3 fs3 fc0 sc0 lsa ws8">selecting forward or r<span class="_ _1"></span>everse r<span class="_ _1"></span>otation: manual control (thr<span class="_ _1"></span>ough the </div><div class="t m0 xa h5 y26 ff3 fs3 fc0 sc0 ls18 ws27">user interface) or automatic contr<span class="_ _1"></span>ol (through a micr<span class="_ _1"></span>ocontrolle<span class="_ _1"></span>r).</div><div class="t m0 x5 h5 y27 ff4 fs0 fc2 sc0 ls1 ws1">■<span class="_ _5"> </span><span class="ff3 fs3 fc0 ls1b ws28">T<span class="_ _3"></span>wo modes of operation: continuous mode and step mode.</span></div><div class="t m0 x5 h5 y28 ff4 fs0 fc2 sc0 ls1 ws1">■<span class="_ _5"> </span><span class="ff3 fs3 fc0 ls9 ws29">Eliminates the need for an external<span class="ls1c ws2a"> c<span class="_ _1"></span>lock signal as<span class="_ _1"></span> <span class="lse ws2b">all MAX<span class="_ _6"> </span>II devices </span></span></span></div><div class="t m0 xa h5 y29 ff3 fs3 fc0 sc0 ls1d ws2c">have a unique internal oscil<span class="_ _7"></span>lator which is inc<span class="_ _7"></span>orporated in this des<span class="_ _7"></span>ign.</div><div class="t m0 xb h7 y2a ff2 fs5 fc1 sc0 ls1e ws2d">December 2007, versi<span class="_ _7"></span>on 1.0</div></div><div class="pi" data-data='{"ctm":[1.904762,0.000000,0.000000,1.904762,-102.857143,-137.142857]}'></div></div>
</body>
</html>