<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;background-color:#FFFFFF;font-family:Calibri,Arial,Helvetica,sans-serif;">
<p></p>
<div>Following Roman's idea:</div>
<div><br>
</div>
<div>But this is for Unipolar motors (5 wires):</div>
<div><br>
</div>
<div>With 4 audio channels to 2 sets of small USB speakers (2 stereo amps / 4 speakers ) wouldn't it achieve “super smooth micro stepping”?</div>
<div><br>
</div>
<div><a href="https://en.wikipedia.org/wiki/Stepper_motor#Phase_current_waveforms" id="LPlnk130834">https://en.wikipedia.org/wiki/Stepper_motor#Phase_current_waveforms</a></div>
<div><br>
</div>
<div><a href="https://en.wikipedia.org/wiki/Stepper_motor#Microstepping">https://en.wikipedia.org/wiki/Stepper_motor#Microstepping</a></div>
<br>
<p></p>
<p><br>
</p>
<div id="Signature"><font face="Courier New, Courier, Monospace" size="2">Mensaje telepatico asistido por maquinas.</font>
</div>
<br>
<br>
<div style="color: rgb(0, 0, 0);">
<hr style="display:inline-block; width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> Martin Peach <chakekatzil@gmail.com><br>
<b>Sent:</b> Sunday, August 14, 2016 5:52 PM<br>
<b>To:</b> Andy Farnell<br>
<b>Cc:</b> Lucas Cordiviola; pd-list@lists.iem.at; ray Y<br>
<b>Subject:</b> Re: [PD] stepper control</font>
<div> </div>
</div>
<div>
<div dir="ltr">On Sun, Aug 14, 2016 at 1:34 PM, Andy Farnell <span dir="ltr"><<a href="mailto:padawan12@obiwannabe.co.uk" target="_blank">padawan12@obiwannabe.co.uk</a>></span> wrote:<br>
<div class="gmail_extra">
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<span>On Sun, Aug 14, 2016 at 08:16:52AM +0000, Lucas Cordiviola wrote:<br>
<br>
> Also please be careful and be aware that there is risk of<br>
> damaging things.<br>
><br>
</span><span>> Consider this a risk to the amp, do it with a low power one,<br>
> probably with one of those inside little usb speakers.<br>
<br>
</span>Any inductive load will give a back EMF on the negative going edge<br>
of the pulse. Look at stepper motor driver circuits and you will<br>
see that protection diodes are used. Push-pull audio amps aren't<br>
really designed for this kind of punishment, they are linear,<br>
whereas stepper drivers are designed to switch a clean pulse.<br>
That said, for small motors you will get limited success, so its<br>
a useful hack to know.<br>
<span><font color="#888888"><br>
</font></span></blockquote>
<div><br>
And most cheap audio amps won't go bipolar, the 'negative' output is always 0 Volts. You would need 4 channels of sound to do it.<br>
<br>
</div>
<div>But if the OP already has an Arduino and an L298 it just makes sense to program the Arduino to step the motor and use the  serial port to tell it when to step or at what speed to run. If you want better sync, try sending a square wave audio signal from
 the Pd patch to the Arduino and program the Arduino to use that as the stepper clock. (You would need two channels of audio, one for each direction.)<br>
<br>
</div>
<div>Martin<br>
</div>
<div><br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>