Motorized Swinging Christmas Stockings

by Will Donaldson in Living > Christmas

1527 Views, 7 Favorites, 0 Comments

Motorized Swinging Christmas Stockings

Screen Shot 2021-12-21 at 1.51.43 AM.png
Building Motorized Christmas Decorations
Screen Shot 2021-12-21 at 1.50.53 AM.png

This blog will document how I created a set of motorized Christmas stockings that swing back and forth. To achieve this I designed a laser cut frame for mounting a servo motor that drives the stocking. Though I used some manufacturing methods that may not be accessible to everyone (laser cutting), this build can be replicated by other methods such as cutting the frame out of cardboard instead of acrylic.

Supplies

The materials list is for one stocking (I made 3 in total).

  • 3mm acrylic sheet
  • Servo motor (I used a DS3218 servo, but an MG995 servo is a cheaper option)
  • 8x M4 bolts 12mm and lock nuts
  • Arduino Uno
  • Adafruit 16 Channel Servo Shield: https://www.adafruit.com/product/1411
  • Project box
  • 5V power supply
  • Christmas Stocking
  • Assorted electrical: wire, heatshrink tube, connectors

Laser Cutting

Screen Shot 2021-12-21 at 1.52.03 AM.png

I started by laser cutting a frame to put inside the stocking so it won't collapse when swung. I have attached the file "stocking_frame.svg" below but be sure to check will fit the stocking you are using before cutting. I cut large circular holes in the frame to reduce the weight but in hindsight the DS3218 servo is more than strong enough even with the circles left in.

At the top of the frame there is a slot cut out for the servo body and a 60 degree arc for the wires to pass through. There is a mating file to cut: "outer-stocking-frame.svg" that is attached on the outside, sandwiching the stocking between the two frames (see next step).

I also fabricated "mantel-bracket.svg" out of 1/16" steel to mount the stocking to the mantel. I bent the bracket 20mm from the flat edge. This piece is optional as the mounting options will be highly influenced by your application. Alternatively you can make similar brackets out of wood or using a 3D printer.

Assembly

Screen Shot 2021-12-21 at 1.52.13 AM.png
Screen Shot 2021-12-21 at 1.52.31 AM.png
Screen Shot 2021-12-21 at 1.51.54 AM.png
Screen Shot 2021-12-21 at 1.53.48 AM.png

I started by super gluing the "outer-stocking-frame.svg" to the top of the stocking and then cutting out the fabric where the servo slot is (picture 1). Super gluing it is optional but I found doing so made cutting out the fabric easier. Afterward, insert the "stocking-frame.svg" into the stocking and align the holes to insert the DS3218 servo. The servo should face outwards with the motor shaft at the top of the stocking. The servo can be secured in place with M4 bolts through the acrylic plates. I advise using lock nuts or Loctite to ensure the bolts don't come loose.

The servo wire can be passed through the arc slot and protected from the hard edge of the acrylic with a Bowden cable (picture 2). I stuffed the stocking with butcher paper to give the stocking some volume.

Mounting Brackets

Screen Shot 2021-12-21 at 1.53.18 AM.png
Screen Shot 2021-12-21 at 1.53.12 AM.png
Screen Shot 2021-12-21 at 1.53.37 AM.png

I am using a 4 arm servo arm to mount the servo. Note that while I am using the DS3218 servo, this 4 arm attachment is usually sold with the MG995 servo and not the DS3218 servo (I had both sets available to me). There is quite a bit of flexibility to redesign and build the components in this step to your own specifications.

I 3D printed a bracket that the 4 arm servo attachment can fit in (picture 2) and then bolted this to the "mantel-bracket.svg", as fabricated in step 1. This assembly can then be attached to the servo (picture 3).

Electronics and Code

Screen Shot 2021-12-21 at 1.52.40 AM.png
Screen Shot 2021-12-21 at 1.52.50 AM.png
Screen Shot 2021-12-21 at 1.52.59 AM.png

I assembled the electronics in a project box using an Arduino Uno and Adafruit 16 Channel Servo Shield. I also included user input options (potentiometers) to control the speed and amplitude. Through experimentation, I settled on a relatively slow speed and a swing amplitude of 30 degrees in each direction.

For a thorough tutorial on using the Adafruit 16 Channel Servo Shield, I strongly recommend referring to their thorough tutorial here. Alternatively, if you want to avoid the shield the servo can be run using the Arduino example called "Servo Sweep" as shown in picture 3. Just remember to change the range of angles, as by default the program rotates the servo between 0 and 180 degrees... we wouldn't want the stocking contents to be thrown out by a violent motor!