Putting robotics at your service™

Free shipping on orders over $200

ITEAD Studio Dual Stepper (v1.1) Shield: One (Y) Channel Defective?

Print view Share :
Previous topicNext topic

Page 1 of 1 [ 3 posts ]

New ( offline )
Posts: 2
Posted: 2012-12-04 15:43 
I just received the v1.1 shield yesterday. It appears that channel Y simply doesn't work, but I'm very much a newbee so if you folks can suggest a diagnostic or fix, or need more data I'd appreciate it. Thanks in advance!

Ron

I also have an Arduino Motor Shield R3 on which all motors run fine... just one at a time.
____________________________________________________________________________________

The Problem
The X channel works but the Y channel (executing the same code) has the stepper sitting there and vibrating.

Components
A. Arduino UNO R3

B. Shield:ITEAD Dual Stepper Shield v1.1

http://www.robotshop.com/dual-stepper-motor-driver-shield-arduino.html

(Specs at http://imall.iteadstudio.com/im120417015.html )

C. 2 New Stepper Motors from RobotShop

http://www.robotshop.com/rbsoy14-soyo-unipolar-stepper-motor.html

12V 125oz-in Unipolar Stepper Motor
- RoboShop Product code : RB-Soy-14
- Soyo SY57ST76-0686A Unipolar Stepper Motor
- Resolution: 1.8 degrees/step, 200 steps per revolution
- Wired bBpolar (center leads unattached)
- Voltage: 12vdc
- Current: 0.68A
- Resistance 35 Ohms (17.5 Ohms per magnet)
- Torque of 125 oz/inch

D: Power Supply - 12V 1.6A

E: Code (sketch from ITEAD) in an .ino file, slightly modified. This example has the Y stepper commented out.
____________________________________________________
Code:
int dirPin1 = 3;
int stepperPin1 = 2;
//  int dirPin2 = 7;
//  int stepperPin2 = 6;
void setup() {
  pinMode(dirPin1, OUTPUT);
  pinMode(stepperPin1, OUTPUT);
//  pinMode(dirPin2, OUTPUT);
//  pinMode(stepperPin2, OUTPUT);
}

void step(boolean dir,int steps){
  digitalWrite(dirPin1,dir);
//  digitalWrite(dirPin2,dir);
  delay(50);
  for(int i=0;i<steps;i++){
    digitalWrite(stepperPin1, HIGH);
//    digitalWrite(stepperPin2, HIGH);
    delayMicroseconds(300);
    digitalWrite(stepperPin1, LOW);
//    digitalWrite(stepperPin2, LOW);
    delayMicroseconds(300);
  }
}

void loop(){
  step(true,1000);               // Run stepper in one direction
  delay(500);
  step(false,1000);              // Run stepper in reverse direction
  delay(500);
}

________________________________________________

What I've tried:
A. Different power supply

B. Five different stepper motors (The two above and three different Japan Servo Company) all Unipolar with wired as Bipolar . All work on X channel but all on Y channel sit and vibrate.

C. Changed durations of both direction variables

D. Commented out both X and Y channels. Even with Y channel commented out the 3967 on the Y side gets very hot... thought that was odd. Heat-sunk both after that.

E. Changed step jumpers to 1/2, 1/4, and 1/8 step settings. Only the 1/8-step setting works with these motors.

F. The following code (from robotics.org) also runs fine on X but not on Y. Variable-step size in this sketch was implemented via the code rather than jumper settings. I made a few mods to allow all three micro-step routines to run on these Soyo motors.
_____________________________________________________________________________
Code:
// ******************************************************
// Micro Robotics
// Test Procedure to test Y channel
// [url=http://www.robotics.org.za]www.robotics.org.za[/URL]
// written by : Frikkie du Toit
// For Stepper Shield ver 1.0
//
//  To test Y Channel         To test X Channel
//  STEP_PIN 6                STEP_PIN 2
//  DIR_PIN 7                 DIR_PIN 3
//  YMS1 8                    XMS1 4
//  YMS2 9                    XMS2 5
// ******************************************************

#define STEP_PIN 2         
#define DIR_PIN 3         
#define XMS1 4             
#define XMS2 5             

void step_mode(byte xms1, byte xms2)
{
  // Set the pins to select the step mode
 
  digitalWrite(XMS1, xms1); // Set pin YMS1 to the parameter given
  digitalWrite(XMS2, xms2); // Set pin YMS2 to the parameter given
}

void step(int steps, float speed)
{
  // Take the amount of steps specified
  // Negative value for opposite direction
 
  byte dir;
  float micro_sec_delay;
 
  if (steps > 0) // If steps are positive
  {
    dir = HIGH; // Set direction
  }
  else // If steps are negative
  {
   dir = LOW; // Set direction
  }

  steps = abs(steps); // Set steps to absolute value
  digitalWrite(DIR_PIN, dir); // Set the direction pin to dir

  micro_sec_delay = 1 / (speed / 100) * 70; // Calculate delay between  step pin toggles

  for (int i = 0; i < steps; i++)
  {
    // Takes all the steps in the specified direction
   
    digitalWrite(STEP_PIN, HIGH);
    delayMicroseconds(micro_sec_delay);

    digitalWrite(STEP_PIN, LOW);
    delayMicroseconds(micro_sec_delay);
  }
}

void setup()
{
  // Set all the pin modes
 
  pinMode(STEP_PIN, OUTPUT);
  pinMode(DIR_PIN, OUTPUT);
  pinMode(XMS1, OUTPUT);
  pinMode(XMS2, OUTPUT);
}

void loop()
{
  step_mode(HIGH, HIGH); // Set step mode to Eighth Step mode
 
  step(1600, 40); // Take 1600 steps (1 revolution) with speed set to 25
  delay(1000); // Delay one second
 
  step_mode(LOW, HIGH); // Set step mode to Quarter Step mode
 
  step(800, 15); // Take 800 steps (1 revolution) with speed set to 25
  delay(1000); // Delay one second
 
  step_mode(HIGH, LOW); // Set step mode to Half Step mode
 
  step(400, 15); // Take 400 steps (1 revolution) with speed set to 25
  delay(1000); // Delay one second
}


User avatar
Novice ( offline )
Posts: 56
Posted: 2012-12-04 16:34 
A vibrating stepper motor indicate that it is either under too much torque (which you can verify by driving it with another channel) of that it is not wired correctly and thus the steps do not make it move CW or CCW but rather side to side.

Since you connected several motors to the y channel it is unlikely that you did the same mistake several times. So it s possible that the library is nor driving the motor pins in the right sequence. If changing the code and the motor connection does not help, please send us a ticket to our support centre so we can help you exchange the item (don't forget to include your order number)

_________________
Carlos Asmat
Lynxmotion

Imagine it. Build it. Control it.™
http://www.Lynxmotion.com


New ( offline )
Posts: 2
Posted: 2012-12-04 17:14 
Thanks for the quick reply.

Neither sketch calls a library, all five steppers run correctly on the X channel (and with another non-ITEAD controller shield) and I have all motors wired correctly. So by your measures the shield is faulty and I'll get the return process started unless there are more suggestions on techniques I haven't tried yet.


 

All times are UTC - 5 hours [ DST ]. It is currently 2014-10-01 20:20
Feedback Form
Feedback Form