Any stepper motor is great, but the big ones are amazingly impressive. There are numerous stepper drivers dedicated for use with Arduino, but they are generally limited to Nema 17 and Nema 23. Luckily, using larger steppers (Nema 34 in this instance) with Arduino is still easy. Large steppers give you an amazing combination of precision, control and torque that can be useful for anything from home automation to DIY CNC machines. In these two videos, we walk through the setup of the motor, driver, and Arduino.
Part 1: Test Code, Increase the Load
In this video we test code from three different Arduino programs to drive the large NEMA 34 stepper, then increase the load on the shaft to see how the stepper handles the additional weight.
Part 2: Fabricate a Steel Plate
In the next video, we fabricate a test plate in the machine shop to test the motor speed and responsiveness, experimenting with what works and doesn’t. We machine a 0.75″ hole in a ~7LB, 15″ 1/4 inch steel plate, then turn a bushing which will let us secure the plate to the stepper D-shaft.
Circuit, BOM and Code
How to Wire the Circuit
- microstepping driver ST-M5045
- Pul+ goes to +5V
- Pul- goes to Arduino Pin 9
- Dir+ goes to +5V
- Dir- goes to to Arduino Pin 8
- Enable+ to nothing
- Enable- to nothing
Bill of Materials
- Arduino
- 24V power supply
- ST-M5045 microstepping driver
- breadboard
- jumpers
- Nema 34 motor (but really any stepper that’s correctly sized for the driver)
Code Examples
Download the Arduino Sketches
The Nema34_Arduino code examples include using a potentiometer to control the speed as well as a program to test how quickly the motor can stop. Both programs use the AccelStepper Arduino library.
I’m no expert on this subject matter and am anticipating (hoping!) others may have comments with even better hardware or software tips and tricks — but in the meantime there doesn’t seem to be much content on YouTube on driving large steppers with Arduinos, and I’ve had quite a few email inquiries about it, so here it is!
ADVERTISEMENT