Dragon Frame Motor Only going one way

Hi everyone:) I'm trying to set up an Arduino to use with dragon frames arc moco software. I'm new to Arduino for this project and so far pretty blown away by all the possibilities of Arduino's so have been trying to learn it all myself so I can use it again in the future.

However, I'm having issues and after trying everything I can think of have come to a problem. I managed to modify the default arc moco script to get my motor working, however, it's only going in one direction even when the software tells it to move in the other direction (It keeps moving but in the same direction)

I have been trying to work out what the problem might be and thought it might be something to do with the fact I have no jumpers on the board? (On the step/ direction pins, enable/ ground pin or any of the other pins) Or might it be something in the script, like the direction pin not being set up correctly?

I’m using an Arduino Uno, CNC shield and a Nema 17 Stepper motor.

The link below is the code for Dragonframe that I have modified to get it working with the software any advice and help would be greatly appreciated


Thank you for looking at this post, any advice or pointers in the right direction would be greatly appreciated:)

Folks here don't like to follow links to download code when there is already a means for you to share it here.

Have a look at this page How to use this forum - please read to learn how to use this site. Pay particular attention to number 7. But DO read the entire page.

I'll keep that in mind for the future, but I just worked it out!
For anyone in the future who might find this here's the solution I came up with:

put this above the line // set output pins

motors[0].stepPin = 2;
motors[0].dirPin = 5;
motors[1].stepPin = 3;
motors[1].dirPin = 6;
motors[2].stepPin = 4;
motors[2].dirPin = 7;
motors[3].stepPin = 12;
motors[3].dirPin = 13;

then I just manually worked out which direction pin it was