Thursday, April 3, 2014

Update: Arduino Camera Dolly

This summer I finished the second iteration of my programmable camera dolly. Everything worked relatively predictably and from the process I gained a deeper understanding of what sort of programming, design, and manufacturing processes work for a reasonably small project such as this.

Through testing my C++ menu library, I discovered that there was an increase in unpredictable behavior after adding a large number of menu objects. I'm not sure if this is due to the limitations of the Arduino or simply a lack of an extensive understanding of it's memory usage.

With respect to design and manufacturing, there were a number of simplifications that could have been made. For one, getting current to the servo that panned the camera up and down should have been approached differently. Without going into to much detail, this iteration used a copper contact plate that required CNC milling. Instead of milling such a contact plate, perhaps conductive washers fitted around the vertical axle could have been used instead. Essentially, without needing a CNC mill, the manufacturing process becomes cheaper and faster. Secondly, a number of parts should have been 3D printed instead of laser-cut from acrylic. Time should not have been spent making 3D assemblies by gluing the edges of flat acrylic. Instead, the laser-cut acrylic should have been reserved for completely 2D components. Finally, a digital servo should have been used instead of an analogue servo. In this case I overlooked a very simple and avoidable mistake.

The following test was filmed on my roof.

This next video shows the machining of the contact plate on a Haas Mini Mill.

A pictorial documentation of the manufacturing process can be found >>> here <<<.

There are a few things I'd like to note. Firstly, 400 step steppers was definitely overkill – 200 steps would have sufficed. Secondly, I just want to mention that the process for fixing the bearings was pretty cool. In most applications, the holes for which bearings are meant are heated (so as to expand the fitting space) and usually the placing material is metal. In this case, the same process worked equally effectively using a lighter near each plastic placing hole. Finally, I would like to release a final design. I want to polish the code further, make a Solidworks parts list and a laser cutting AI file, and include full directions for creating such a dolly. Essentially, I want anyone who has an interest in time-lapse photography to be able to produce a programmable camera dolly at low cost and add a new dimension to their work.

Wednesday, April 2, 2014

Arduino Library for Adafruit's 2X16 LCD Shields

In order to make programing my camera dolly's user interface easier, I decided to create my own Arduino library. While there were a couple navigation libraries for Adafruit's 2X16 LCD Shields, I wanted to learn how to write a library, something that I haven't done before. Additionally, I had in mind a simpler interface than what I found online and wanted to make numerical input more efficient by entering numbers by place value.

Here are a few features:

  • Intuitive menu navigation
  • Supports selection of multiple options
  • Numerical input of integer and decimal values
  • Optional delay for static menus
  • Optional menu headings
The .zip file containing the library itself, examples, and documentation can be found here (Last update: Oct. 11, 2014). To get started, go to the "documentation" folder and open "home.html". From here, you can learn how to install the library. Additionally, the page can direct you to several examples and the library's function list.

Many thanks to Prof. Silvan Linn, Grant Paul and Cheng Cheng for their generous help.

Tuesday, April 1, 2014

Arduino Camera Dolly

As a summer project, I decided to design and build a programmable camera dolly in order to take time-lapse footage. An Arduino microcontroller is the "brain" of the dolly and runs a medium servo and two stepper motors through a pair of Big Easy drivers. The steppers are both NEMA 17's and have 400 steps per revolution. The stepper that controls lateral movement moves the dolly at 0.1 mm per step while the stepper dictating rotational movement turns the camera 0.25 degrees per step under half-step mode. The whole system is held together by custom 3D printed parts I designed in Solidworks, two 3/4 in plastic pipes, and a few shafts, bearings, and belts. The LCD screen displays a simple interface that can be used to change the camera's path before it takes the photos that are stitched together to make a time-lapse film.

From this project, I learned a great deal about stepper motors, LCD interfacing, coding, and 3D printing. The entire process allowed me to discover the many caveats that become apparent as things start or stop working for no apparent reason. 

There’s a minor problem with the rig. The servo doesn’t keep the camera in position 100% of the time. I’m not sure if it’s because it’s not receiving enough power through the extensive wiring or it’s just too weak. Either way, it’s a bit of a problem because when it does draw too much energy the Arduino resets.

Here are a few things I learned through the process:

3D printing
  • To avoid bolts and screws. If it’s not a tank, there’s no need to design it like one. 
  • To use epoxy. Better yet, print everything in one piece if you can while still maintaining every parts’ integrity
  • How to take into account printing tolerances along the different axes
  • Making sure every detail is worked out in Solidworks. It prevents things from getting messy later.
  • LCD interfacing
  • The AccelStepper library
For the next iteration:
-No bolts or screws
-Everything down to the wiring will be modeled in Solidworks
-Less wiring
-An infinite degree of rotational freedom around the z-axis

Update: The problem with the servo was simply that I was running it directly off the Arduino so the amperage was too low. This has been fixed with a UBEC that provides enough current and correct voltage. I finished CADding the the structural components of the camera dolly; all that's left is the wiring, which I've never done before, so it should be fun. Here are a couple pictures:

Many thanks to Prof. Silvan Linn at San Francisco State University for his guidance and support.  

The New York Times Crossword Puzzle

Below is a picture of the crossword puzzle that I constructed for The New York Times. Edited by Will Shortz, the puzzle was published on Monday, January 30, 2012.
To do the puzzle, simply download the PDF here. You can also read Wordplay, the NY Times blog that includes readers' comments in response to the puzzle.

Night Sky with Python

After seeing the digital planetarium exhibit at the California Academy of Sciences, I decided that I wanted to paint the night sky on my ceiling and walls using glow-in-the-dark paint. To do this, I wrote a Python program to chart each star's position and magnitude relative to a single point in space. I plan to complete the project in Summer 2013.

The images below are screenshots of the scalable vector graphics (SVG) that were generated by the program.

To see the SVG pages, click the links below:
Night sky
Ursa Major and Ursa Minor
Stargate-like projection (see 2001: A Space Odyssey)

Click here to access all files from the project, including the Python script, a readme file with detailed instructions, and a .zip archive of everything.

Night Sky

Ursa Major and Ursa Minor

Stargate-like Projection

Origami Models

I constructed the origami models shown below between 2009 and 2012. Most are based on existing designs by the origami master Satoshi Kamiya, indicated by the initials SK, and a few are my personal designs. All are constructed from an unbroken sheet of paper. Click on each image to enlarge.

Divine Boar (SK)

Ancient Dragon (SK)

Ancient Dragon detail (SK)

Giraffe (personal design using chewing gum wrapper)

Ring (personal design using one dollar bill)

Unicorn (SK)

 Wizard (SK)

Piano 2012

The three pieces below were recorded on November 30, 2012 at the San Francisco Conservatory of Music. John McCarthy, piano teacher. Click here for my piano resume.
Click on each title to hear the pieces (audio only).
The mp3 files can also be downloaded here.

Bach - Prelude and Fugue in C Major, (WTC II) BWV 870
Length: 4:38

Prokofiev - Sonata No. 4 in C Minor, Op. 29, Movement I
Length: 5:39

Chopin - Nocturne in C Minor, Op. 48, No. 1
Length: 5:53