Notifications
Clear all

Confused by the labels on steppers and controllers

9 Posts
3 Users
3 Likes
1,035 Views
Ed
 Ed
(@ed)
Member
Joined: 2 years ago
Posts: 10
Topic starter  

I am trying to make a simple bipolar stepper motor testing setup using an Arduino, an A4988 controller, various small 5V

IMG 4884

bipolar stepper motors, and the code from the DroneBot Workshop video on using Arduino and Steppers, namely

The code compiles without error and loads onto the Arduino. When I try to test out a motor nothing happens. I think the problem is I do not understand the labeling on the A4988 controller for the four wires from the stepper, namely 2B, 2A, 1B, and 1A, and those on the stepper motors, namely A+, A-, B+, B-. According to the wiring diagrams I have seen for bipolar steppers there should be continuity between A+ and A-, and B+ and B-, but the motor I am currently testing shows continuity between A- and B-, and A+ and B+. I've tried every combination I can think of and still nothing works. What is the proper wiring between a stepper motor labeled A+, A-, B+, and B-, and a controller labeled 2B, 2A, 1B, and 1A?

 

Ed


   
Quote
Will
 Will
(@will)
Member
Joined: 3 years ago
Posts: 2531
 

@ed

The A4988 terminals starting with 1 and 2 represent coils. So if your stepper has the coils between A+<->B+ and  A_<->B- you should connect the +s on the stepper to the 1s on the A4988 and the -s on the stepper to the 2s on the A4988.

What stepper class are you using ?

Anything seems possible when you don't know what you're talking about.


   
Ron reacted
ReplyQuote
Ed
 Ed
(@ed)
Member
Joined: 2 years ago
Posts: 10
Topic starter  

@will I will connect the stepper as you suggest: A+ to 1A, B+ to 1B, A- to 2A, and B- to 2B for consistency. I found that I had jumpered the Reset and MS3 pins together instead of the Sleep and Reset pins. I get source voltage when I hook up a voltmeter across GND and VMOT but nothing when I hook up a voltmeter across GND and VDD so it appears the Arduino isn't getting any power from the A4988. The A4988 also takes a minimum of 8-12V to run and I was using 6V. I tried using 9V with no success. I am waiting on some parts to arrive so I can try 12V which will be the standard supply for the setup when I get it working. I have a variety of steppers of different types I want to create test setups for. This one is for small 5V bipolar motors, mainly small stepper sliders with block nuts. I purchased a handful of various types off the Internet to play with.

Ed


   
ReplyQuote
Will
 Will
(@will)
Member
Joined: 3 years ago
Posts: 2531
 

@ed 

I think you still have it wired incorrectly. The high voltage used to drive the Stepper is applied over VMOT (A4988 pin 16) and GND (A4988 pin 15). The Arduino supplies power to the A4988 (not the other way around) so the Arduino connects 5V to the A4988  VDD (to A4988 pin 10) and Arduino GND to A4988 GND (A4988 pin 9).

The voltage needed to drive your stepper will depend on the stepper itself.

What stepper are you using and what stepper library are you using ?

Anything seems possible when you don't know what you're talking about.


   
Ron reacted
ReplyQuote
Ed
 Ed
(@ed)
Member
Joined: 2 years ago
Posts: 10
Topic starter  

@will

A4988 setup

 Above is the CWD I am attempting to wire up between the Arduino and the A4988 as per the Dronebot Workshop video. It shows no separate power supply to the Arduino. I could plug it into my PC and see if that works. I may also have a power plug that will fit it around here somewhere . . .

Ed


   
ReplyQuote
Will
 Will
(@will)
Member
Joined: 3 years ago
Posts: 2531
 

@ed 

You have to power the Arduino.

If it's not powered up and executing the sketch, then it can't possibly send instructions to your stepper motor driver.

Anything seems possible when you don't know what you're talking about.


   
Ron reacted
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 3 years ago
Posts: 6968
 

@ed Did Bill not plug the USB cable into the UNO? That is how the sketch gets transferred AND like ALL USB connections supplies 5VDC to the UNO. Stepper motors require a lot more current than the small amount of milli-amps an UNO can supply.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
Sure you can learn to be a programmer, it will take the same amount of time for me to learn to be a Doctor.


   
ReplyQuote
Ed
 Ed
(@ed)
Member
Joined: 2 years ago
Posts: 10
Topic starter  

@will I plugged the UNO into my PC and it powered right

IMG 4890

  up on 6V for the stepper. I took a video of the stepper working but it is >10MB. I'll try to make a smaller file later and post it. The voltmeters show the voltage from the battery to run the stepper, the VMOT, and VDD. I am intrigued by my progress. I'm having to wipe away 35 years of rust and dust on my electronics skills. I really appreciate all you help.

Ed


   
ReplyQuote
Will
 Will
(@will)
Member
Joined: 3 years ago
Posts: 2531
 

@ed 

There you go, all it needed was a little juice 🙂

Anything seems possible when you don't know what you're talking about.


   
ReplyQuote