TB6560 stepper driver with Arduino

Hi Guys, Today I’ll introduce my new stepper motor driver TB6560. By using this driver you can Run high torque stepper motor which required up to 3Amps. In my previous video, I made a 5Amp Stepper motor driver using Tip122 and 127 Mosfets and some other components. You can watch that 5Amp Stepper Driver video also.

Parts List for Stepper Driver Arduino Project

  1. Arduino Mega
  2. TB6560 Driver Module
  3. 22kg Stepper Motor
  4. 12V Power Supply
  5. Some Jumper wires

Video for 3amp TB6560 with Arduino

Arduino code for TB6560 Stepper Driver

Test code 1

 

#include <AccelStepper.h>

// Define a stepper and the pins it will use
AccelStepper stepper(3, 2, 13); // 1 = Driver Mode, Step = pin 2, Direction = pin 3

void setup()
{ 
stepper.setMaxSpeed(5000.0);
stepper.setAcceleration(300.0);
}

void loop()
{ 

stepper.runToNewPosition(5000);


//stepper.move(10000);
}

Test Code 2

const int STEP_PIN = 13;
const int Enable_PIN = 3;
const int DIR_PIN = 2;
void setup()
{
   pinMode(STEP_PIN, OUTPUT);
   pinMode(Enable_PIN, OUTPUT);
   pinMode(DIR_PIN, OUTPUT);
   digitalWrite(STEP_PIN, LOW);
   digitalWrite(Enable_PIN, HIGH); //When device turned on,
                                   //stepper is off
   digitalWrite(DIR_PIN, HIGH);

} 

void loop()
{
         digitalWrite(Enable_PIN, LOW);
         digitalWrite(DIR_PIN, LOW);
         int b=2500;
 int a=10000;
   for (int i=0; i < 60000; i++)
      {
//        a=a-2;
        if (a<=b) a=b;
        else a=a-10;
        digitalWrite(STEP_PIN, HIGH);
         delayMicroseconds(5);
         digitalWrite(STEP_PIN, LOW);
         //delay(a);
         delayMicroseconds(a);
       }
       delay(1000);
}

TB6560 Connection Wiring Diagram – Coming Soon!

0 Comments

Leave a reply

Your email address will not be published. Required fields are marked *

*

or

Log in with your credentials

or    

Forgot your details?

or

Create Account