Make an Arduino Controlled Motorized Camera Slider!




Introduction: Make an Arduino Controlled Motorized Camera Slider!

This project shows you how to convert any ordinary slider to an Arduino controlled motorized slider. The slider can move very fast at 6m/min, but also incredibly slow.

I reccomend you watch the video to get a good introduction.

Things you need:

Step 1: Drill the Mounting Holes for the Stepper Motor.

The stepper motor needs to be mounted underneath the track. The closer to the end, the longer your length of travel. The easiest way to transfer the hole pattern from the motor to the track is by tracing it with painters paint. This is a very useful tip for all kinds of applications.

The pulleys were quite high, so I had to drill large holes to accomondate for some of their height inside the track. That can be easily done with a drillpress and a stepped drill bit.

Make sure you use a center punch to mark the locations of the holes. This makes drilling them easier and more precise.

A 90° chamfer bit cleans up the edges nicely.

Step 2: Mount the Motor on the Track.

Nema 17 motors useually have 3mm threaded holes at the top. I used some washers to reach the perfect hight for the belt. The belt needs to ride quite low in the track to clear the carriage.

The pulleys are fixed to the shaft with a set screw.

On my slider the holes collided a little bit with the round surfaces of the track. I had to do some filing to get the screws in propperly. If you plan ahead and twist the motor a few degrees it should be alright. Two screws are enough anyway though.

Step 3: Making a Little Mount for the Idler Pulley.

The idler pulley, just like the stepper pulley, needs to be mounted slightly below the surface of the track. I used a little piece of metal that I had left from a previous project. You will find something similar in any hardware store.

I used countersunk screws. They look awesome, but only when they are propperly seated inside their holes. To achieve that, I started with one hole, inserted the screw and then drilled the second one. That ensures a perfect fit. A chamfering bit is used to create the counter sink.

For an extra nice look you should paint the metal. Using primer is always a good idea. Mine did not work very well at -10C°.

Step 4: Assembly the Idler Pulley!

The idler pulley needs to be at the same height as the motor pulley. I used washers for that. I strongly reccomend using nylock nuts! They have a little plastic insert that bind with the thread and stop it from becoming loose by the vibrations.

Step 5: Modify the Carriage to Hold the Ends of the Timing Belt.

Your belts will likeley come as a 5m length which you can be cut to size. That means that both ends need to be fixed to the carriage.

I tried a few methods of attaching them to the carriage before I found a very simple solution. I just wedged the belt against a parallel surface using a countersunk M3 screw. I drilled a number of holes to make sure that one would have the right distance to hold the belt tight.

Step 6: Admire Your Hardware!

By now you should have a belt that is connected to the carriage and that loops around the motor and the idler pulley. Next come the electronics!

Step 7: Electronics Overview

I am using an Arduino Micro. This is a great little device with a small form factor and a lot of support material online. The arduino is powered by a 12V battery pack consisting of 8 AA batteries. I find this more convenient than using a LiPo. The battery pack is also directly wired to the Stepper driver since it needs a higher motor controll voltage and current than the Arduino can deliver. The stepper driver gets signals from the Arduino over 2 cables and it controlls the motor. The Arduino starts giving directions to the driver as soon as it gets power. 4 switches are used as some kind of combination lock to set the speed of the motion.

Here is the entire Code and Circuit

Step 8: Wiring the Switches to the Arduino

Wiring Shematic
Its best to use a proto board to create a working circuit. You just need to copy the circuit from the link above for the switches and the power. Once this circuit works, you can transfer it over to a breadboard and solder it on.

The Arduino is usind the 12V battery pack as a voltage source. It produces a 5V voltage itself that can be used to check the state of the 4 switches. They are used to change the speed of the slider. So you kinda have 2 voltages on the board. 12V to power stuff and 5V for the controll circuit.

Wire some thin cables to the 4 switches. I used the cables I found inside an old ethernet cable. I am sure you have plenty of those lying around. Protect the bare terminals with shrink tubing.

Step 9: Wiring the A4988 Stepper Driver

The stepper driver is an A4988. It receives signals from the Arduino and relays them to the Stepper. You need this part.

Instead of explaining the circuit to you, you can rather watch this tutorial as it explains it very well. This is my go to reference whenever I use an A4988. My code uses exactly the same pins. So add this youtubers tutorial to the board with the switches from the previous step and it will work.

Step 10: Add the Code!

Here is the entire code and the circuit for the slider. You can test it online, but only without the stepper driver.
Alternative Link
The code checks for the state of the 4 switches in the loop. After that it goes through some if statements and selects the desired delay between the steps to move through the entire length of the slider in the entered value. All the calculations are included in the code as notes.

You need to enter the length of your slider and the diamter of the pulley to ensure that the motor stops when it reaches the end of travel. Just measure those values yourself. The formulas are included in the code.

The table shows you what switches to press for a desired time period. For instance if you want the slider to move the entire length in 2min you need to activate switch 1 and 2. You can of course change these values to your preferences.

Step 11: Print the Enclosure.

I designed the enclosure using Fusion 360. You can download the files here and print them on a 3D printer. No support is required. I filled the details of the letters with pink nail polish to make it easier to read. You can fill the entire letter and then wipe away the access. This trick can be used for all kinds of indents.

If you want an easier option, you could just make one by hand using a small lunch box.

Step 12: Final Assembly

Its time to put everything together. Place all the components inside the enclosure and mount it to the slider using double sided foam tape. This stuff is pretty strong and nicely adheres to uneven surfaces.

I also added an anti vibration mount with a universal camera mount on top. The vibration mount is fairly cheap and stops vibrations to reach the camera. This is only needed for high speed motion. In my case high speed motion is anything between 10s and 30s for the length of the slider.

I added a table with all the switch combinations on the underside.

Step 13: Admire Your Work and Shoot Some Cool Footage!

Weather its video or timelapse, this slider can do it all! If you build one yourself I would love to find out about it!

Microcontroller Contest 2017

Runner Up in the
Microcontroller Contest 2017

2 People Made This Project!


  • Creative Misuse Contest

    Creative Misuse Contest
  • Water Contest

    Water Contest
  • Tiny Home Contest

    Tiny Home Contest

56 Discussions

Bonjour MAX

my camera + cart + fluid viedo head weigth 2 kilograms . And I would like to lift this ensemble verticaly (70 cm) . Are these tutorial components strong enough? Thank you
PS : picture of my aluminium profile and the new kart.


Well just tried with a4988 and I have the same problem, the motor moves but is stuttering. I tried a simple test code and it works perfectly.... I don't understand why it doesn't work with your code.

Hi ! I just made this and I must say that it's design with the switch is great ! It was a pain to find out the exact wiring though...

Anyways, I have an issue with the code because I didn't have A4988 drivers but only DRV8825, so the movement is choppy and quite noisy, what should I change in the code to make it fit my driver?

Thank you !

In Arduino your code seems to be missing a quotation mark. (It says 'missing " terminating character'). Have I copied and pasted it wrong?

I am a bit confused about how I should make the circuit. The Autodesk Circuits page seems to have an Arduino Uno (I don't know if this will make a difference) and has yellow LCD displays. It also seems a bit hard to copy the placement of the wiring from that pages. I currently am trying to copy the circuit of the photo of your circuit. I'm sure there is a better way. Am I missing something?


1 reply

Hey, the yellow displays are only there for checking the code online. You can see their values changing as you simulate the code. Its a debug tool.

The circuit is correct, but it is missing the parts that run the A4988. You can take that part from the tutorial by the other youtuber and add it to my sketch. Since Autodesk Circuits has no A4988, I could not add it.

You can use either an Arduino UNO, or a Micro. Both have the exact same pins. There are differences of course, but none that concern us for this project. The Micro is just a smaller physical size (plus some technical aspects).

Ill add 2 more pictures of my circuit to the instructable. Hope that helps.


9 months ago

what is the name of the spray paint before the black paint , please

2 replies

I am using cheap off-brand automotive spray primer. Anyone should be fine.


10 months ago

Excuse me, I’m still trying to understand
the formula,

StepDelay = ((TravelTime / Steps) -

StepDelay = ((TravelTime / Steps) - 0.002)
* 1000;

May I say 0.0008 is from the TWO “delayMicroseconds(400);” of MoveStepper()

but what is 0.002 in other time options ?

Sorry for my poor maths.


3 replies

I guess .002 woul be in case you had smaller delays of 100 Microseconds. If it is present in some of the "switch cases" I might just have copied them over wrong or forgot to update them, but they should not matter much for longer time intervals. The significance of the delay decreases over long time periods.

Thank you max.

I will test it when I get all the items a few days later.

I made one. Stepper motors are way worse for this than i thought. Even a time lapse has all sorts of funky artifacts from the stepping. Im probably going to get rid of this controller and just use it as a general purpose stepper controller for experiments. Has anyone found a motor that mounts to a nema 17 stepper mount. Would be really nice if i just mount a motor like that and use a variable speed controller.


The concept is great, but a full schematic (that includes the stepper driver and switch connections) would have been nice for us noobs out there :(

2 replies

You are right. Sorry about that, but I am working on a more simpler solution.

No worries! Would love to see the new version when it's ready. Thanks for all the effort!

Hi there.. can i use this speed remote in Nema 17 Gearbox? if yes how do i do it? i have no idea how to do the wiring's etc.. and is there any chance that when the camera reaches then other end it will automatically go back to the other side without using the remore? just moves back and forth? thank you so much


12 months ago

Hy I wanna do a timelapse so is it possible to use lcd to see interval betwean shots (to make it move every 10sec or every 2 sec) and to make it adjustable on the go? plz help

I was wondering, could you change the switch inputs with a variabele input lile touchpad, variabele encoder etc.?
Also would it be possible to combine the code to make a camera trigger/controller + slider controller