This is an old revision of the document!
Published 2 Apr 2018
I wanted to automate the creation of 360 degree animated GIF photos. The obvious way to do it appeared to be to use an Arduino board to control a stepper motor and synchronize the camera. I had previously created such animations by manually moving the camera and taking many photos, then manually aligning the images and stitching them together to get a more or less smooth animation. But this requires a subject that stays still as it takes a lot of time, and the images inevitably are slightly out of alignment.
Doing it the hard way, the first animation shows the raw frames jerking about, and the second shows the manually aligned frames giving a smoother animation:
Finished result, trimmed manually adjusted frames:
The advantage of automating this by putting the subject on a rotating turntable is that the camera, lighting, distance to the subject, alignment and background all remain static. Additionally the number of images taken to get a smooth animation can be easily adjusted, and frames are in alignment without the necessity of editing or scaling to rectify variations in camera distance etc.
This was to be my first Arduino based project, so I looked for examples that had already implemented the tasks required. I came across shapespeare-scanner, a homemade 3D scanner to create 3D models. I didn't need 3D models, but just the basic automated image capture. So I purchased an Arduino Uno board, plus LCD shield and stepper controller module. I already had a bunch of stepper motors, so set to work.
I had a choice of a number of recycled stepper motors, and settled on using a msaf200b51, a Sankyo Mitsubishi flat motor with 1.8º/step (200 steps per revolution) and runs off a 12V power supply. Its low profile, and lack of any protruding shaft from underneath meant it could just sit on the desk while testing.
The hardware setup consisting of the Arduino UNO with LCD shield, stepper motor controller, stepper motor, and an infrared LED for controlling the shutter on the camera (the green and white wires to the left go to the 12V power supply for the motor, the rest is powered from the USB port)
As mentioned, I started with Shapespear's 3D scanner firmware, which was a great base as I had no experience with Arduinos at this point and his code did most of what I wanted.
As mentioned in the comments to his instructables page, there were a few strange things with delay timings have no effect : this turns out to be a problem of not understanding the order in which expressions are evaluated in the C programming language - easily solved by adding a few brackets around arithmetic expressions!
Below are some initial scans, still a bit of work to do, but promising results:
If any referenced page no longer exists, try looking for its URL on http://archive.org.