Electronics & Motors


Contraptor Electronics & Motors are assembled from Controller kit and Axis kits. Controller kit includes Arduino, breadboard, mounting plate, jumper wires (pic 4-5), while Axis kit includes components necessary for a single axis - stepper motor, stepper driver, terminals, limit switches and wires to connect it all together (pic 3). Controller kit has two options - Uno and Mega, which can support 1-3 axes or 1-7 axes respectively.

For example, 4-axis electronics/motors can be built from Controller (Mega) kit and 4 Axis kits (pic 1), and 2-axis electronics/motors can be built from Controller (Uno) kit and 2 Axis kits (pic 2).

Used in



Gather components necessary to solder the protoboard.

Stepper Driver Wiring

The diagram below illustrates the electronics setup to control one axis. For more axes, add drivers and wiring in the same manner. Note that some control lines may be shared - for example, ENABLE line is typically shared among all drivers and therefore uses only one pin on Arduino.

Be sure you get the stepper driver board orientation correctly, otherwise you will blow the driver!


Microstepping Chart

The microstepping mode is controlled by three MS inputs located in the upper right quarter of the driver as seen on the above diagram: MS3, MS2, MS1, ENABLE. Inputs can be set to low (GND) or high (5V) according to the following table:

MS1 MS2 MS3 Resolution
Low Low Low Full step
High Low Low 1/2 step
Low High Low 1/4 step
High High Low 1/8 step
High High High 1/16 step

Remember that changing microstepping mode changes number of steps per unit distance, so corresponding changes need to be made in the firmware. For example, if your mechanism requires 100 full steps to move one inch, it will require 8*100 steps in eighth-stepping mode to move the same distance.


Limit Switch and Frame Wiring

Contraptor limit switch is a screw mounted on a UHMWPE angle so that it's isolated from the frame (GND). The limit switch wire is connected to the screw via spade terminal. Normally, the limit switch is open and corresponding Arduino pin is High. When sliding element, linear bearing, or the frame comes into the contact with the screw, it sets the pin to Low.

Note that this requires electrical connection between isolated subassemblies of the frame - which is typically the case with sliding elements, linear bearings and everything they're connected to. Use black hookup wire and remaining spade terminals to connect isolated subassemblies to GND (pic 1).

Power Supply Wiring

A generic ATX power supply is used to power the stepper drivers. Arduino is typically powered by USB bus, but if it’s not connected to USB, it can be powered by the 5V line (red) from the ATX PSU.
To use the power supply switch to turn it on or off, connect the green wire on the ATX PSU motherboard connector to any black wire (pic 2).

Mounting Electronics

If you choose to mount electronics to the frame of your robot, be sure to use rubber/neoprene washers between the frame and the mounting plate. This reduces vibration and lowers the chances of an occasional loss of electrical contact (pic 3).

Part List

qty part source1
Controller Kit (Uno): 1-3 axes
1 Arduino Uno http://www.adafruit.com/products/50
1 Half Breadboard http://www.adafruit.com/products/64
1 Mounting plate 6"x4" fabricated
1 Flexible jumper wire bundle http://www.adafruit.com/products/153
1 Female header 30 pos Digikey #S7028-ND
1 Protoboard Jameco #2125042
1 Power terminal Mouser #538-22-04-5042
2 Spade terminal Mouser #538-19131-0034
4 Zip ties 4"
2 Zip ties 8"
Controller Kit (Mega): 1-7 axes
0 Arduino Mega http://www.adafruit.com/products/191
1 Full Breadboard http://www.adafruit.com/products/239
1 Mounting plate 9"x4" fabricated
2 Flexible jumper wire bundle http://www.adafruit.com/products/153
2 Female header 30 pos Digikey #S7028-ND
1 Protoboard Jameco #2125042
1 Power terminal Mouser #538-22-04-5042
2 Spade terminal Mouser #538-19131-0034
4 Zip ties 4"
2 Zip ties 8"
Axis Kit
1 NEMA23 stepper motor Ebay/Alltronics #44A501711
1 Pololu stepper driver http://www.pololu.com/catalog/product/1182
1 Heatsink Enzotech MOS-C1
1 Motor terminal 6 pos Mouser #651-1725698
6 Preformed jumper wire 0.3" Mouser #517-923345-03
6 Preformed jumper wire 0.4" Mouser #517-923345-04
4 Spade terminal Mouser #538-19131-0034
3 Hookup wire red, ft Digikey #C2004R-100-ND
3 Hookup wire blue, ft Digikey #C2004L-100-ND
3 Hookup wire black, ft Digikey #C2004B-100-ND
2 Endstop angle fabricated

1 source - retail source for DIY/set extension/part replacement. Some kit parts are sourced in bulk and may differ from parts linked here.


  • 09/18/13: initial release
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License