Welcome! Log In Create A New Profile

Advanced

X-axis Motor only Moves in One Direction!

Posted by joshuafkon 
X-axis Motor only Moves in One Direction!
June 08, 2015 11:14AM
Hello!

I'm working on getting my machine up and running using Marlin firmware - but I'm having some problems. The X-axis motor only moves to the left. This is slightly complicated by the fact that I'm using Powerlolu stepper motor drivers

I have searched this forum and tried some of the suggestions with no luck so far -

  • I have removed all the endstops and jumped the endstop pins together - sending M119 shows that all the endstops are open
  • I have tried using the RAMPSTestCode.pde (everything lights up but the motor only moves in one direction)
  • I've even switched out my motors and tried a different RAMPs board.

Does anyone have any experience with the powerlolu stepper driver? I suspect I'm wiring that incorrectly?



I'm particularly unclear about the circled GND and Voltage - I interpreted that wiring diagram as saying that if I'm using an external power supply (which I am - 24V) then don't use those lines at all
Thanks!

Edited 3 time(s). Last edit at 06/08/2015 11:32AM by joshuafkon.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 01:19PM
Hello,

First - You are not clear if your stepper is ALWAYS moving to the left regardless of what signal you send, or if it just "ignores" the moves to the right and only executes the left ones.

Try to swap the connecting wires to the stepper. So that, from left to right:

Red - Blue -----------------GAP--------------------------- Green - Black

Doing this should reverse the direction of your stepper.

Then send the same signal as has been working before.

If your stepper now moves in the opposite direction as before, then you know it is not a problem with the actual connection of the stepper and that the stepper it self is OK.

Next thing to look for is the DIR (Direction pin). The direction pin is the blue wire coming from RAMPS and terminating the closest to the red one. So in the right lower corner you have 5 going in. It is nr 3 from left. Put a multimeter on that and see if it changes from +5 to 0 (and opposite) when you ask for the stepper to go the opposite direction.


If the direction pin is doing correctly and if you stepper changed direction as you changed the cabling above then I would say it is software.


If your stepper is always moving to the left regardless of what signal you send and/or the DIR pin is not changing, then the direction signal is being lost:

Try to disconnect it (the DIR) from the ramps and put it to VCC (5V) or GND. That would be the red or the back one of the 5 wires coming into your board in the lower right corner. Doing this should manually control the direction.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 01:51PM
Hello - sorry if I was unclear. It will only move when I select the X-min direction in Pronterface. If I switch the AB wires in either of the phases it will change from only moving clock wise to only moving counter-clockwise.

I will try manually moving the direction pin thanks!
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 02:22PM
Ok, so I tested the DIR pin on the RAMPs board. It is indeed working - switching between 5V and 0V - and the motor moves when the DIR pin is HIGH, when it is LOW there is no movement.

I don't see how this could be a software issue as I'm using the RAMPs test Code
VDX
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 02:58PM
... this is normally connected with an improper defined or set homing or limit switch ...


Viktor
--------
Aufruf zum Projekt "Müll-freie Meere" - [reprap.org] -- Deutsche Facebook-Gruppe - [www.facebook.com]

Call for the project "garbage-free seas" - [reprap.org]
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 03:10PM
Looks like the three control leads are step, direction, and enable. Were direction and enable get reversed, this would be the exact kind of behaviour I would expect.

- Tim
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 03:30PM
Hey Tim,

I tried switching the Direction and enable pins - but it didn't move at all. Interestingly enough, it moves the same (only clockwise) with or without the enable pin.

Thanks though!

Josh
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 03:32PM
I don't think it could be a problem with the limit switches (though I could of course be wrong) because I can't even get the RAMPs test code to work. Also, I've sent M119 to the RAMPs and everything is open.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 03:46PM
Tadawson is correct that if you have swapped the DIR pin and En (Enable) then this would be the exact behavior.

Test this by seing if the stepper is enabled when sending the not working signal the following:


When you are sending the signal that does not work, do the stepper still have holding torque - That is, is it significant harder to turn then it is when the system is not powered?


If you find that it does not have holding torque, investigate by doing the following:


Using you multimeter you should see 0V on the blue most to the right in the lower corner. And you should have continuity (~0 Ohm resistance, the BEEEEEP sound) between it and GND.

That is the 5 going in, in the lower right corner, from left to right:

Gnd [BLACK] ( 0V) - VCC [RED] (5V) - DIR [BLUE] (0V or 5V) - Step [BLUE] (need oscilloscope to make sense) - En [BLUE] (0V)

This is what you should see when you try to make your stepper move in either direction.

If your "En" is going to 5V (or floating) then you have a problem.


EDIT: I previously said that En should be 5V to work. I mixed them up. Enable needs to be pulled low.

Edited 1 time(s). Last edit at 06/08/2015 03:59PM by LarsK.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 04:05PM
Hey LarsK,

I just doubled checked everything, and I do NOT have any holding torque when its not moving clockwise.

I tested all the pins from the RAMPs and GND is 0V, VCC is 5V, DIR switches between 0 and 5V, Step showed as roughly constant 4V on my mulitmeter, and En was 5V.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 04:13PM
Quote
joshuafkon
Hey LarsK,

I just doubled checked everything, and I do NOT have any holding torque when its not moving clockwise.

I tested all the pins from the RAMPs and GND is 0V, VCC is 5V, DIR switches between 0 and 5V, Step showed as roughly constant 4V on my mulitmeter, and En was 5V.

Ok, I think this means that EN is floating because it pulls low when going in one direction.

Try to connect En directly to Gnd. Simply instead of connecting it to the Ramps you just connect it to the general Gnd.


If that works then either the used I/O on the Arduino is broken or you have a error in the pins definition in you code or the copper traces between are broken.

Edited 1 time(s). Last edit at 06/08/2015 04:14PM by LarsK.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 04:13PM
Disconnect enable from RAMPS, pull enable on driver to ground, and retest . . . You might also try manually selecting both direction and enable, and just taking the step signal from the RAMPS and see if you get the expected behaviour.

- Tim

Edited 2 time(s). Last edit at 06/08/2015 04:14PM by tadawson.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 04:44PM
I tried disconnecting the Enable pin from the RAMPs board and grounding the pin. No effect sad smiley
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 05:14PM
So, with enable grounded, and direction seen to select correctly, you still only move one direction? To my mind, that pretty much determines that one side of the output bridge on the driver has a failed component. Do you have more than one of these driver cards?

(More detail . . .)

A typical driver output looks like thus (can't use the schemo for your card, since there is no pdf output on github . . . ):

[images.search.yahoo.com]∋=128&no=3&ts=&tab=organic&sigr=120t5diin&sigb=15t6vlg6d&sigi=11lq0tegj&sigt=11qujho8m&sign=11qujho8m&.crumb=vc0niubRTiB&fr=yhs-mozilla-002&fr2=sb-top-images.search.yahoo.com&hsimp=yhs-002&hspart=mozilla

Note the pairs of FETs . . . only one on each side conducts to drive a given direction, or a pair to short the motor to apply brake, such that if one dies, only one direction, and no brake one way . . .

Since this card has discrete driver FETs, if you can test/replace, that might be your solution.

- Tim

Edited 2 time(s). Last edit at 06/08/2015 05:33PM by tadawson.
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 06:17PM
:/ I was really hoping I didn't need to replace/repair the boards themselves (they're out of stock right now). But thank you everyone for all of your help today!

One last question - I'm thinking of using this Stepper Driver as a replacement - Do you think this will be compatible with the RAMPs board?
Re: X-axis Motor only Moves in One Direction!
June 08, 2015 06:29PM
Almost end of the line.

As Tadawson is saying, it looks like your card have some problem.

I would like to return to investigating when your stepper have holding torque.

Do the exact following things and report about the holding torque - Please note in the first two you should not be asking it to move, we only want to see if the circuitry makes holding torque.

1) En= Gnd , DIR = 5V : Does it have holding torque?

2) En= Gnd , DIR = Gnd Does it have holding torque?

3) Then ask it to move in the bad direction (where it will not move and will lose it's holding torque) - Does it return to having holding torque after the failed move or what?


I ask this because it indicates when the error is happening. I have noted that it is only when the DIR is high that it works. I am considering if for some reason that DIR (5V) is supplying the chip rather then the normal VCC - Simply if the normal VCC 5V is failing to reach.

I seriously doubt that the IC or FET circuitry is bad. It would be so weird if it can move in one direction but not the other. It is essentially the same thing it is doing, just in a different sequence. But if both step 1 and 2 turns out with a "yes" it has holding torque, and it loses holding torque on 3 then it does look like a shutdown on the IC...
Sorry, only registered users may post in this forum.

Click here to login