A small cardboard box will make for the perfect garage for your die cast cars or small robots. We'll make the garage and add the door mechanism next.
Cut Out the Box Floor
- First, cut the flaps off of the bottom of the box. This way your table top or floor will be the garage's floor too
- Save the cutoffs, you'll use some cardboard scraps later to build a door control horn
Make the Door
- To make the door, flatten the box and mark the shape with a ruler and pencil. Then, cut out the door section
- Glue the straw onto the inside of the door (you can cut it to length first) at a point 1-1/2” from the bottom edge
The door and straw will pivot around the dowel.
- Place the dowel through the straw
- Align the door with the opening in the wall and mark the position of the dowel. You'll use this to cut two small holes in the walls for the dowel
- Mark and cut two small holes on either wall that meets the door cutout wall as shown
- Feed the dowel through one wall, then into the straw, and out the other side
Test out the opening and closing action -- if the fit is too tight it may be hard for the servo to push the door open, so you can trim away a bit of the opening if necessary.
- Place the servo on the box in a position where its shaft is level with the door hinge pivot, and mark its location with a pencil
- Carefully cut out the opening so the servo will fit through and then push it through from the inside as shown. A snug fit will help it stay put, but you can also add some more cardboard support later if needed
- Cut two small pieced of cardboard to act as a mounting point for the pushrod we'll be making
- Fold and glue one piece as shown and them mount it to the door below the dowel as shown
- Glue the second piece to the mount -- this is our control horn, when it gets pushed by the pushrod it will cause the door to swing upward on its hinge
We'll poke some holes through the control horn to connect with the pushrod. The different hole positions will allow us to fine tune the pushrod placement later.
- Straighten out a paper clip to create the pushrod
- To connect with the servo arm, you can make a small z-shaped bend as shown and then fit it into the farthest hole of the arm
- Press the arm onto the servo shaft so that the pushrod arm points straight up -- this will be the door's closed position. You should try twisting the horn back and forth to make sure the shaft doesn't hit its limits before you need it to. It should be almost fully counter-clockwise when you fit the arm on pointing straight up
- Now, you can check the length of the pushrod -- note where it will need to bend at a right angle to go through the control arm. Bend the rod and then push it through one of the holes in the control horn
- Test the throw of the pushrod by rotating the servo about 90 degrees as shown here
- Close the roof flaps and tape or glue them down into place
- Flip the garage upside down and take a look at the angle of the pushrod from the servo arm to the control horn -- you can fine tune it for better performance by adding a small angled bend as shown here
- One of the nice things about paperclip pushrods is that you can make small adjustments by hand easily in order to get the door to open just right!
Turn the servo to the clockwise position and make sure the door swings open. If it doesn't, or has difficulty, you can adjust the position of the pushrod in the control horn by poking additional holes as "lower" or "higher" positions until it works smoothly.
Now, connect the Circuit Playground Express to the servo with this wiring:
- CPX VOUT to servo orange power
- CPX GND to servo brown ground
- CPX A2 to servo yellow signal
Plug in the USB cable to power the Circuit Playground Express and test it out -- push the A button and it opens! B and it closes!
You can use some masking tape or double stick foam tape to mount your Circuit Playground Express on the garage wall next to the door.
Grab a flashlight and shine it at the light sensor. I opens automatically!!
Have fun with your brand new garage. You can now cut out some additional windows, decorate it, and maybe think about additional automation and lighting you can build for it. A "neon" sign would look rad.