Extra stepper motor control

Hi everyone,

I am busy trying to get a ‘modification’ to work on my bot, I basically need to control another stepper motor, effectively a swinging boom arm, but for the life of me I cannot figure out how I can add more stepper motor controls.

I realize there are servo motor controls as well, but they unfortunately will not work for what I am trying to do. If its not possible, thats also fine, will just try something else then.

Thanks for any info in advance

Hi @Dope,

If you have a Genesis 1.4 or 1.5 you’ve probably noticed that there are 5 stepper drivers installed on the PCB . . if you then check the Farmbot OS and Arduino firmware sources you’ll find that there’s no code to support the AUX stepper driver, so it’s up to you to write that code :slight_smile:

Another approach which might work for you ( again needing custom software in the Farmbot OS ) bypassing the Farmduino firmware interface might be to use the I2C or SPI interface on the Raspberry Pi 3 to control your motor (?) . . just a thought and haven’t tried this.

Thanks for the info. I was trying to avoid having to write code, but it would seem this will be the only solution to the problem.

I am running a ramps board, so I have 3 spare stepper drivers, will just have to write the code myself then unfortunately. Maybe I can create a feature for this on the github repo

1 Like

So I had a closer look at Lua, and got it to work using this script:

set_pin_io_mode(34, "output")
set_pin_io_mode(36, "output")
set_pin_io_mode(30, "output")
write_pin(30, "digital", 0)
for i = 200,1,-1 
    write_pin(36, "digital", 1)
    write_pin(36, "digital", 0)
write_pin(30, "digital", 1)

For others who find this thread, how did you hardwire the ( GPIO ) pins to the stepper hardware ?
( :blush: or is that defined by RAMPS ? ) [ never seen any RAMPS board ! ]

So I was slightly wrong on the actual board, its the Makerbase MKS Gen L 2.1 board, I am using the 2 extruder drivers to run the extra motors. Here is the board layout and pinout


Pretty sure that this will apply to any stepper motor driver as you basically just need to control 3 pins, the enable, direction and step pins and then just pulse the step pin for it to move


Would love to see a photo or hear more details about what you’re doing with said boom arm!

Will definitely post some pics once I have it all working nicely, it is mostly mechanically assembled and around 80% electronically done, just waiting for some final parts to arrive so I can finish it off, hopefully by next weekend I should be able to post something on the DIY forum


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.