loading

ICStation Team introduce you this stepper motor control system based on ICStation UNO compatible with Arduino. It uses ULN2003 chip to drive. The working voltage is DC5V. It is widely used on ATM machine, inkjet printer,cutting plotter, fax machine,spraying equipment, medical instruments and equipments, PC peripheral, and USB Mass Storage ,precise instrument,industrial control system,office automation,robot areas,etc.

Functions

1.When start up, the stepper motor will rotate in the clockwise direction, at the same time the1602 LCD will display the stepping rate and rotating direction.

2.When you press the key1, the stepper motor will rotate in the counter-clockwise direction.

3.When you turn the potentiometer to the left or to the right, you can adjust the stepping rate of the stepper motor. At the same tine the 1602 LCD will display the current speed.

Code for your reference:

http://www.icstation.com/newsletter/eMarketing/Stepper_Motor_Code.txt

Step 2: Schematic Diagram

Working Principle:

To change the rotating speed of the stepper motor by changing the input frequency of pulse signal. And to realize the motor rotating in the clockeise direction and counter-clockwise direction by controlling the transform sequence of the pulse signal.


Step 3: Overall Hardware Connected Diagram

Step 4: Plug Into the Power Supply Wires and Place the Components

Step 5: Connect the LCD1602

Step 6: Connect the Stepper Motor

Step 7: Connect the Signal End and Power Supply End

Connect the signal end of the components and the cathode and anode of the power supply to the ICStation UNO board compatible with Arduino and common port of power supply.

Step 8: The Experimental Effect After Starting Up the Power Supply

<p>Hi, good job man ;-) I wish to ask you if iou can tell me how, adding a<br> third button, to tell the motor to stop, assuming that the motor <br>rotates continuously when the left or right button is pressed.</p><p>Thank you for any help ;-)</p>
<p>1) Can be used stepper motor 12 volts? (Printer)<br> 2) key1 and key2 is the engine rotation direction?<br>Thank you</p>
<p>Doesn't Work, the attachInterrupt not work... The stepper rotate ok, but the button are Useless... Wiring is correct. Something wrong in code. I use ad Arduino Uno Adeept, until now every projects works...this no. I tried to change some way to code, like digitalWrite (pin, HIGH); for the pullup but same result</p>
<p>I am working on a project that uses 4 ldr's, two potentiometers and 2 step motor 28byj-48 to track the movement of the sun. I really need help with the programming</p>
<p>I am working on a project that uses 4 ldr's, two potentiometers and 2 step motor 28byj-48 to track the movement of the sun. I really need help with the programming</p>
<p>How many K is the Trim pot resistor? Thanks</p>
<p>10K</p>
<p>#include &lt;Stepper.h&gt;</p><p>#include &lt;LiquidCrystal.h&gt;</p><p>int Iint1=0;</p><p>int Iint2=1;</p><p>int anjian1=2;</p><p>int anjian2=3;</p><p>int motorSpeed;</p><p>LiquidCrystal lcd(9,8,7,6,5,4);</p><p>const int stepsPerRevolution =200;</p><p>// Here set the stepper motor rotation step how much is a circle</p><p>int dim=stepsPerRevolution;</p><p>// Set the step motor number and pin</p><p>Stepper myStepper(stepsPerRevolution, 10,11,12,13); </p><p>void setup()</p><p>{ </p><p> lcd.begin(16, 2);</p><p> lcd.print(&quot;speed:&quot;);</p><p> lcd.setCursor(10,0);</p><p> lcd.print(&quot;n/min&quot;);</p><p> lcd.setCursor(0, 1);</p><p> lcd.print(&quot;Direction:&quot;);</p><p> // Set the motor speed of 60 steps per minute</p><p> myStepper.setSpeed(60); </p><p>pinMode(anjian1,INPUT_PULLUP);</p><p> pinMode(anjian2,INPUT_PULLUP);</p><p> attachInterrupt(Iint1,counterclockwise,FALLING);</p><p> attachInterrupt(Iint2,clockwise,FALLING);</p><p> Serial.begin(9600);</p><p>}</p><p>void loop() </p><p> { </p><p> myStepper.step(dim);</p><p> void Direction();</p><p> // Read the sensor values:</p><p> int sensorReading = analogRead(A0);</p><p> // Map it to a range of 0-150:</p><p> int motorSpeed = map(sensorReading, 0, 1023, 0, 150);</p><p> // Set the motor speed:</p><p> if (motorSpeed &gt; 0) </p><p> {</p><p> myStepper.setSpeed(motorSpeed);</p><p> lcd.setCursor(6,0);</p><p> lcd.print(float(float(motorSpeed)/float(200)));</p><p> } </p><p> }</p><p> void clockwise()</p><p> { </p><p> // clockwise rotation</p><p> dim=stepsPerRevolution;</p><p> lcd.setCursor(10, 1);</p><p> lcd.print(&quot;&gt;&gt;&gt;&gt;&gt;&gt;&quot;);</p><p> }</p><p> void counterclockwise()</p><p> { </p><p> // anti-clockwise</p><p> dim=-stepsPerRevolution;</p><p> lcd.setCursor(10, 1);</p><p> lcd.print(&quot;&lt;&lt;&lt;&lt;&lt;&lt;&quot;);</p><p> }</p>
<p>Hi, <a href="http://www.icstation.com" rel="nofollow"> www.icstation.com </a> is down !!!</p><p>Could you post the (arduino code) .ino file for this please ?</p><p>This link not work <a href="http://www.icstation.com/newsletter/eMarketing/Stepper_Motor_Code.txt" rel="nofollow">http://www.icstation.com/newsletter/eMarketing/Stepper_Motor_Code.txt</a></p>
<p>If you use a ULN2803, you can run 2 steppers. Put a PCF8574 IC in front of that and you can use I2C, only 2 pins.</p>

About This Instructable

23,291views

45favorites

License:

Bio: www.ICStation.com is a top store of electronic, which specializes in all kinds of IC products, such IC accessories, Module, Robots, Development Board, Transistor ... More »
More by ICStation:Hexapod4 Spider Robot¬†Instruction Manual The NRF24L01 Wireless Motor Speed Control System with Arduino The Wireless Single Point Calling System with Arduino 
Add instructable to: