The is a perfect solution for controlling 4 stepper motors simultaneously. It contains an ATmega2560 microcontroller to perform the tasks. The module is compatible with A4988, DRV8825 stepper drivers. You can check movement state with 5 end-stops. The 5th end-stop is for emergency cases.

It is much more effective then the RAMPS and GT2560 3D printer controlling circuits since all 4 motor controlling pins are PWM pins and all 5 end-stop pins are Interrupt pins in the . Interrupt pins are perfect for instantly stopping your motors to prevent accidents. You can precisely set the frequency on the PWM pins for an accurate motor control. We think that temperature controlling must be handled on a different microcontroller. This is why we designed the Ozeki Analog Module. PID calculations for setting the correct temperature consume too much computational power. This is why we do not advise RAMPS and GT2560.

You can program the by using the Arduino IDE environment. A reset button can also be found on this module. The module connects to PC via an USB to serial converter chip (CH340G).

Figure 1 - photos


Specifications:

  • IC: ATmega2560
    • Clock Speed: 16 MHz
    • Flash Memory: 256 KB
    • SRAM: 8 KB
    • EEPROM: 4 KB
  • USB support provided by a CH340G USB to serial chip:
  • Power supply from USB (5V)
  • Compatible with A4988, DRV8825 stepper drivers
  • 4 stepper motors supported (each connected with a 4pin JST connector)
  • 5 end-stops supported (each with software pullup resistor)
  • 35V maximum motor supply voltage
  • 500mA resettable fuse (USB)
  • Status LEDs: power, TX, RX, D13
  • Can be screwed on an Ozeki Matrix Board
  • Product dimensions:
    2.40in.[60.96mm]×2.40in.[60.96mm]

Compatible motor drivers:

motor driver
Figure 2 - A4988 motor driver

motor driver
Figure 3 - DRV8825 motor driver

The pinouts for the motor driver and end-stop connections:

Motor Axis Enable pin MS1 (MicroStep1) MS2 MS3 Step pin Direction pin End-stop pin
X A4 A3 A2 A1 D11 D10 D2
Y A8 A7 A6 A5 D6 D7 D20
Z A12 A11 A10 A9 D5 D3 D21
A D28 D27 D26 D25 D45 D46 D19

Emergency end-stop: D18

Wiring:

steppermotor wiring
Figure 4 -Full wiring which contains 4 stepper motors, 5 end-stops and a power supply connection

Program codes

For moving a maximum of 4 stepper motors

It can control a maximum of 4 stepper motors of any type. The enable, MS1 (microstep1), MS2, MS3, step and direction pins are default pins for all 4 motor drivers (driver X, Y, Z, A). If you are not controlling a motor, the motor should be disabled, so it won't burn down in the case you accidentally give too much power to it.

What does the example code do?
The motors are called by the axis: X, Y, Z, A. First it turns the motors 50 steps clockwise one by one from motor X to A. Then it turns the motors 50 steps counterclockwise one by one from motor A to X.

This code repeats the above mentioned algorithm in a loop.

Downloadable code:
Stepper motor controller example code (.zip)

struct StepperMotor{
  int enPin;
  int MS1;
  int MS2;
  int MS3;
  int stepPin;
  int dirPin;
};

StepperMotor X = {A4, A3, A2, A1, 11, 10};
StepperMotor Y = {A8, A7, A6, A5, 6, 7};
StepperMotor Z = {A12, A11, A10, A9, 5, 3};
StepperMotor A = {28, 27, 26, 25, 45, 46};

StepperMotor myMotors[4] = {X,Y,Z,A};

void setup() { 
  for(int i=0; i<=4; i++){//sets all 4 motor
    pinMode(myMotors[i].enPin,OUTPUT); 
    pinMode(myMotors[i].MS1,OUTPUT); 
    pinMode(myMotors[i].MS2,OUTPUT); 
    pinMode(myMotors[i].MS3,OUTPUT); 
    pinMode(myMotors[i].stepPin,OUTPUT); 
    pinMode(myMotors[i].dirPin,OUTPUT);

    //disables motors and sets them to 1/16 Step:
    digitalWrite(myMotors[i].enPin,HIGH);
    digitalWrite(myMotors[i].MS1,HIGH);
    digitalWrite(myMotors[i].MS1,HIGH);
    digitalWrite(myMotors[i].MS1,HIGH);
  }
}

void loop() {
  for(int i=0; i<=4; i++){ //turns all 4 motors clockwise
    digitalWrite(myMotors[i].enPin,LOW);
    digitalWrite(myMotors[i].dirPin,HIGH); //sets direction clockwise
      for(int x = 0; x < 50; x++) { //makes 50 steps clockwise
        digitalWrite(myMotors[i].stepPin,HIGH);
        delayMicroseconds(500); 
        digitalWrite(myMotors[i].stepPin,LOW);
        delayMicroseconds(500); 
      }
   digitalWrite(myMotors[i].enPin,HIGH);
  }  
  delay(1000); // One second delay

  for(int i=4; i>=0; i--){ //turns all 4 motors counterclockwise
    digitalWrite(myMotors[i].enPin,LOW);
    digitalWrite(myMotors[i].dirPin,LOW); //sets direction counterclockwise
      for(int x = 0; x < 50; x++) { //makes 50 steps counterclockwise
        digitalWrite(myMotors[i].stepPin,HIGH);
        delayMicroseconds(500); 
        digitalWrite(myMotors[i].stepPin,LOW);
        delayMicroseconds(500); 
      }
    digitalWrite(myMotors[i].enPin,HIGH);
  }  
  delay(1000); // One second delay
}
Source Code 1 - Arduino example for moving 4 stepper motors clockwise and then counterclockwise

Other modules

All of the Ozeki Processing Modules have ATmega328P or ATmega2560 microcontrollers integrated. Ozeki Modules can be connected to eachother like pieces of blocks. The connection is provided through USB to each module. They have M2 screw holes to give you an option to screw them on an Ozeki Matrix Board.

AutoConnect Link

If Ozeki 10 is running on your computer (such as on a Raspberry Pi) and you have plugged a microcontroller to it than Ozeki can be set to find serial devices on windows/linux and place them into a connection list so you can interact and control them through the software GUI.

See all Ozeki Processing Modules