Pushrod Garage. Created by John Park. Last updated on :07:30 PM UTC

Similar documents
Slider Crank Mechanism -- from Cardboard and Craft Sticks

Snake Charmer Box. Created by Dano Wall. Last updated on :07:25 PM UTC

Crickit Carnival Bumper Bot

Ping Pong Ball Launcher

Crawling Animatronic Hand

Hammer Time Mini Golf Hazard with Crickit

Crickit Dancing Marionette Kit Created by Dano Wall. Last updated on :03:11 PM UTC

Paper Airplane Launcher

Adabot Operation Game

Crickit Powered Holiday Diorama

Crawling Baby Sea Turtle Robot

Circuit Playground Express Head-Tilt Ears

Bunny Ears with MakeCode

CPX Mystery Dreidel. Created by Kathy Ceceri. Last updated on :51:40 PM UTC

DIY Circuit Playground Shields

Mini Golf Course with Circuit Playground and Crickit

Circuit Playground Express Laser Tag

Trash Panda. Created by Dano Wall. Last updated on :30:46 AM UTC

Stumble-Bot. Created by Dano Wall. Last updated on :04:06 AM UTC

Wind Blowing Emoji Prop

Infinity Mirror Valentine's Candy Box

NeoPixie Dust Bag with Circuit Playground Express

Android GBoard Morse Code Control with Circuit Playground Express

Con Badge with Circuit Playground Express

Secret Hollow Book Intrusion Detector

Neon LED Signs. Created by John Park. Last updated on :11:09 PM UTC

The Scream: Interactive Screaming Painting

Crickit Powered Mini Chair Swing Ride!

Easy Sparkle Pocket T-Shirt

Steven Universe Cosplay Shirt & Gem Created by Erin St Blaine. Last updated on :54:25 PM UTC

Adafruit Capacitive Touch Sensor Breakouts

HalloWing Jump Scare Trap

NeoPixel Ring Bangle Bracelet

Clockwork Goggles. Created by John Park. Last updated on :03:10 PM UTC

Making Adabot: Part 1

Reindeer Mask with Animated Eyes

BLE Light Switch with Feather nrf52840 and Crickit

Prophet 600 GliGli mod

LED Eyes. Created by Ruiz Brothers. Last updated on :50:55 AM UTC

NeoPixel Manicure. Created by Sophy Wong. Last updated on :50:38 PM UTC

Tent Lantern. Created by Timothy Reese. Last updated on :17:25 AM UTC

Sword & Wand Prop Effects with Circuit Playground

Trellis 3D Printed Enclosure

Adafruit Pi Cobbler Kit

FLORA and GEMMA ICSP. Created by Becky Stern. Last updated on :42:16 PM UTC

Interior Purse Light. Created by Becky Stern. Last updated on :41:08 PM UTC

Jewel Hair Stick. Created by Leslie Birch. Last updated on :47:17 PM UTC

Photo Light Box. Created by John Park. Last updated on :28:51 PM UTC

Portable Apple Watch Charger

FLORA TV-B-Gone. Created by Becky Stern. Last updated on :32:57 PM UTC

CircuitPython Snow Globe

Trinket NeoPixel LED Longboard

UFO Flying Saucer with Circuit Playground Express

Sewable NeoPixels. Created by Becky Stern. Last updated on :50:14 PM EDT

Adafruit MCP9808 Precision I2C Temperature Sensor Guide

Glowing Smokey Skull. Created by Ruiz Brothers. Last updated on :03:40 PM UTC

Coffee Detonator: The TNT Plunger Grinder

Interactive Gift Box. Created by codingpro. Last updated on :47:40 AM UTC

Celebration Spectacles

Milk Jug Glow Skull. Created by John Park. Last updated on :28:36 PM UTC

NeoMatrix 8x8 Word Clock

Mad Science Test Tube Rack

Modifying Servos for Continuous Rotation

FLORA and GEMMA ICSP. Created by Becky Stern. Last updated on :30:55 PM EST

Trinket-Powered Conference Room Occupancy Display

PyPortal NeoPixel Color Picker Created by Kattni Rembor. Last updated on :42:41 PM UTC

'Sup Brows. Created by Kate Hartman. Last updated on :52:04 PM UTC

FLORA Pixel Brooch. Created by Becky Stern. Last updated on :19:07 PM EST

Audio Prank Gift Box. Created by Becky Stern. Last updated on :46:15 PM UTC

3D Printed 20w Amplifier Box

Adafruit PowerBoost 500 Shield

NeoPixel Fairy Crown. Created by Erin St Blaine. Last updated on :22:47 AM UTC

FPV Mini Display. Created by Ruiz Brothers. Last updated on :00:18 PM UTC

LED NeoPixel Corset with Circuit Playground Express and

Adafruit APDS9960 breakout

3D Printed Camera LED Ring

Circuit Playground Yoyo

Magical Mistletoe. Created by Leslie Birch. Last updated on :45:29 PM UTC

3D Printed Google AIY Voice Kit

Zelda Thunder Helm. Created by Ruiz Brothers. Last updated on :46:52 PM UTC

Data Logging with Feather and CircuitPython

Introducing Adafruit Trellis

No-Sew LED Wristband. Created by Kathy Ceceri. Last updated on :23:40 PM UTC

Feather Weather Lamp. Created by Ruiz Brothers. Last updated on :54:26 PM UTC

GPS Logging Dog Harness

Adafruit LED Sequins. Created by Becky Stern. Last updated on :02:00 AM UTC

Boomy The Boombox. Created by Ruiz Brothers. Last updated on :52:13 PM UTC

Adafruit VL53L0X Time of Flight Micro-LIDAR Distance Sensor Breakout

Organza Shadowbox. Project Needs & Notes:

7 Portable Multitouch Raspberry Pi Tablet

Circuit Playground Digital Input

NeoPixel Bike Light. Created by Ruiz Brothers. Last updated on :43:46 PM UTC

Adafruit Prototyping Pi Plate. Created by Ladyada

Circuit Playground Kaleidoscope

7" Portable HDMI Monitor

Naughty or Nice Machine

Adafruit TPL5110 Power Timer Breakout

Fiddy - the FTDI Clip

Adafruit TPL5111 Reset Enable Timer Breakout

CircuitPlayground Minecraft Gesture Controller

Transcription:

Pushrod Garage Created by John Park Last updated on 2018-08-22 04:07:30 PM UTC

Guide Contents Guide Contents Overview Parts & Materials Tools Pushrod Mechanism Code it with MakeCode Functions On Start Variables Servo Write Light it Up Lights Out Buttons Light Sensor Build the Garage Cut Out the Box Floor Make the Door Pivot Servo Mounting Control Horn Pushrod Roof Circuit Playground Express Controll 2 3 3 4 5 7 7 7 8 9 10 10 11 11 13 13 14 17 20 22 29 33 35 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 2 of 40

Overview You can build your own model garage with a functioning automatic garage door powered by a Circuit Playground Express, servo motor, and pushrod mechanism created with a paperclip, cardboard, a dowel, and a straw! You'll code the Circuit Playground Express using MakeCode so that it can open or close your garage door at the press of a button, and even build a light activation mode that will automatically open the door for you! Parts & Materials For materials, you'll need: small, corrugated cardboard box drinking straw wooden dowel or bamboo skewer paper clip. The electronics you'll need are listed below. 1 x Circuit Playground Express Incredibly awesome microcontroller board ADD TO CART 1 x Standard servo TowerPro SG-5010 ADD TO CART 1 x Small Alligator Clip to Male Jumper Wire Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 3 of 40

Bundle - 6 Pieces ADD TO CART Tools Here are the tools you'll use to build the project: Hobby knife Metal ruler Hot melt glue gun and hot melt glue -- either low or high temperature is fine Pencil Small pair of pliers for paper clip bending (optional, you can do it with your fingers too!) Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 4 of 40

Pushrod Mechanism To open the garage door we'll make a mechanism that transfers the rotation of our servo to the rotation of the door. We could try to mount the door directly to the servo's shaft, but this would be a bit tricky, and pretty bulky looking. Instead, we'll transfer the rotation of the servo over a short distance using a pushrod made from a paperclip. Take a look at the diagrams below -- there are a few key things to note: The servo shaft rotates clockwise, and the servo arm rotates along with it The pushrod translates (moves) to the right and slightly down as it is pushed by the servo arm The pushrod pushes the door's control horn to the right The door is on a hinge (made from a drinking straw) which rotates counterclockwise around the door pivot dowel Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 5 of 40

Later in the guide, we'll build a similar mechanism for our garage. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 6 of 40

Code it with MakeCode You can code your Circuit Playground Express using MakeCode to open and close with buttons presses and also using the light sensor! If you aren't already familiar with MakeCode, check out this guide (https://adafru.it/wwd) to get started, then return here when you're ready. Functions Here's what we will set up the Circuit Playground Express to do: Open the garage door by turning the servo when the A button is pressed Close the garage when the B button is pressed Watch for a bright light on the light sensor When a bright light is detected, open the door, wait five seconds, and then close the door Those are the basics, but we'll also get fancy and set up some lights and sounds to accompany these functions. On Start First, we'll set up some things that happen as soon as the program starts. Begin by dragging an on start block from the LOOPS category into your program canvas area. Place a set all pixels to block into the on start block, and change the color to orange. This will be the color of the NeoPixel ring on the Circuit Playground Express when the program starts. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 7 of 40

It's also nice to have a startup sound. Pull in a play tone at block. Change the note to High A and the duration to 1/2 beat. Variables Since we'll be setting open and closed values for the servo angles multiple times in the program, it's helpful to set up a couple of variables with these numbers which we can then use over and over again. From the variables category click Make a Variable... and then create one and name it 'closed'. Repeat this a second time for one called 'open'. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 8 of 40

Drag in a block called set closed to into the on start loop. Then duplicate this block and change the drop down menu to the open variable. You may need to adjust these values later but for now use 170 and 70 as shown here. Servo Write We'll have the servo automatically go to the closed position when the program starts. From the pins category, drag in a servo right block. Change the pin from the default A1 to A2. (You can use either of these two pads on the Circuit Playground Express to control a servo.) Then from the variables category drag in closed variable into the servo right pin block. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 9 of 40

Light it Up From the input category drag in the light threshold block. Change the first drop-down item from dark to bright. Then set the value to something pretty high such as 240. This will vary depending on how bright the light source is that you want to use to open the garage door. Lights Out Finally we will turn off all of the NeoPixel LEDs by dragging in a set all pixels block from light category, and then changing the color value to black. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 10 of 40

Buttons Next we will set up the Circuit Playground Express so that pressing the A button will sound a tone and open the garage. We will set up to the B button to close the garage. Create a set of blocks just like the ones shown in the image below. Light Sensor Finally, we will set up a light sensor block so that when a bright light is detected the following actions occur: The LEDs will turn blue A melody will play The servo will open the door. Then an animation will play for five seconds, giving a toy car time to pull into the garage Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 11 of 40

The lights will change to red A different melody will play The door will close The LEDs will turn off Add the blocks needed to do these actions, as shown in the block set below. Your program is complete! There's an interactive embedded version of it below. You can now download your program from your MakeCode session, press the reset button on your Circuit Playground Express, and drag the program onto it. You're ready to test it out! Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 12 of 40

Build the Garage 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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 13 of 40

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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 14 of 40

bottom edge Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 15 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 16 of 40

Pivot 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. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 17 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 18 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 19 of 40

Servo Mounting 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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 20 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 21 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 22 of 40

Control Horn 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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 23 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 24 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 25 of 40

Now, glue the horn mount to the inside of the door as shown. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 26 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 27 of 40

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. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 28 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 29 of 40

Pushrod 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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 30 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 31 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 32 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 33 of 40

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 Roof 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! Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 34 of 40

Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 35 of 40

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. Circuit Playground Express Controll 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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 36 of 40

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 do a couple of things to improve the motion if you're having any problems -- tweak the values of open and close in the MakeCode program, and adjust the pushrod. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 37 of 40

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 Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 38 of 40

about additional automation and lighting you can build for it. A "neon" sign would look rad. Adafruit Industries https://learn.adafruit.com/pushrod-garage Page 39 of 40

Adafruit Industries Last Updated: 2018-08-22 04:07:24 PM UTC Page 40 of 40