Makey:bit Animatronic Face

About 3 hours

Ages 8+

What Will You Make?

Makey:bit controls this animatronic face. It can open and close its mouth, roll its eyes, and raise and lower its unibrow.

What Will You Learn?

You’ll learn to control servos with micro:bit and MakeCode.

Prepare Your Materials

Step 1

For the face, make or take a box with two flaps that meet at the middle. Turn it so one flap opens and closes from the bottom – this is the mouth. Tape the upper flap closed. This is where the eyes and unibrow will go.

Step 2

For a push rod, straighten a paperclip, leaving the bends at the ends to use as hooks.

Step 3

For the eyes, find or cut a cardboard tube a little shorter than the width of the box.

Step 4

For the arm (which holds up the eyes tube), cut a strip of cardboard just wide enough to fit inside the tube without rubbing. It should be long enough to fit at least halfway into the tube, with enough hanging outside for the arm.

Attach a Servo to the Box to Open the Mouth and Roll the Eyes

Step 1

Mark a spot for a servo on one side of the box, about an inch away from the front and even with the level of the eyes. Trace around the servo at that spot, and cut out a hole to hold it snugly. Insert the servo into the hole from the inside, so the cable is outside the box.

Step 2

Snap a servo horn onto the servo. Mark one arm (or a spot along the edge if you’re using the circle horn) to be your measuring point. It will point up when the mouth is closed.

Step 3

To calibrate the servo so it points the right way:

  1. Turn the horn to the right as far as it will go.

  2. The measuring spot should point directly to the right (the 3 o’clock position). If it doesn’t, take it off and re-attach it so it does.

  3. Remove the servo horn.

  4. If you are leaving out the eyes tube, hook the smaller end of the paperclip through a hole along the servo horn and go directly to Finish the Face from here.

Step 4

Cut out a circle of cardboard about ¼ inch bigger around than the cardboard tube.

Step 5

Tape the servo horn to the middle of the circle.

Step 6

Tape one end of the tube to the circle. Make sure the servo horn is facing out!

Step 7

Hook the smaller end of the paperclip through the cardboard circle. If you need to save space, you can trim it later to an egg shape, leaving an overhang where the paperclip is attached.

Insert the Arm

Step 1

Snap the eyes tube onto the servo with the measuring point facing up.

Step 2

Hold the tube straight across, and mark where the top and bottom of the tube would meet the box if it were long enough. Cut a slot for the cardboard strip between those marks.

Step 3

Insert the arm strip through the slot from the outside and into the eye tube.

Step 4

Bend the outside of the arm forward to hold it in place. If you need to remove or adjust the eye tube, gently pull the arm strip out of the box.

Finish the Face

Step 1

Make sure the measuring point on the servo horn is pointing up.

Step 2

To attach the loose hook on the paper clip to the mouth, poke a hole through it. You can also tape on an extra piece of corrugated cardboard with the channels running sideways and insert the hook into the channel that fits best. Test to make sure you can pull and push the mouth open and closed.

Step 3

Cut the holes for eyes, making sure they are even with the tube inside the box. Draw eyes on the tube with the mouth open and with it shut. Write “back” on the back of the tube so you can re-connect it correctly if you need to.

Add the Unibrow

Step 1

Use a straw or pipe cleaner (or both) to make a brow that bends in the middle. Attach one end to the face so it can pivot. If you’re using a pipe cleaner, you can poke a hole right in the cardboard and insert the end. With a straw, hold it one with a small screw or pin.

Step 2

The servo motor for the brow goes inside the box. The top of the servo motor sticks out the front of the face, above the eye. (Duh.) Trace and cut out a hole so just the top of the servo sticks out. Use plenty of tape to hold the servo motor in place.

Step 3

Tape the loose end of the brow to a servo horn. Wrap some masking tape around them to hold them together.

Step 4

Snap the horn onto the servo with the brow straight.

Connect the Makey:bit

Step 1

Insert the micro:bit into the Makey:bit.

Step 2

Stand the Makey:bit on top of the Animatronic Face box. Secure it on with some kind of attachment, tape, or glue, such as a strip of peel-and-stick Velcro or Legos.

Step 3

Cut a hole in the top of the box near the Makey:bit big enough for the ends of the servo motor cables to pass through.

Step 4

Pull the cable for the servo attached to the mouth and eyes out through the hole. Plug it into the Makey:bit using the pins marked Servo A (SRVA). This servo will be programmed using pin P0.

Step 5

Pull the cable for the brow through the hole the same way. Plug it into the Makey:bit using the pins marked Servo B (SRVB). This servo will be programmed using pin P2.

Troubleshooting

If your face is not moving correctly, try these tips:

  1. Tuck in loose wires.

  2. Bend the paperclip if needed to make the mouth open and close correctly.

  3. Make sure the paperclip doesn’t hit anything as it moves.

  4. Check that the eye tube has not detached from the servo.

Write the MakeCode Program

Sample Code

Sample Code: https://makecode.microbit.org/_U7fdKWMA2WLX 

This program will make the mouth open and close, the eye tube roll, and the unibrow scowl or look happy. To test out the code, it uses Button A to move the mouth and eyes, and Button B to move the unibrow. When it’s working, check out additional ideas to make your Animatronic Face seem more alive!

Remember, you may need to set your servos in the opposite direction of these instructions, depending on how you placed your servos in your model!

Step 1

On start, set both servos – P0 and P2 – to 90 degrees. This makes sure the mouth is closed and in the neutral position for the motors. (If the mouth is open too much, readjust your paperclip and/or your eyes tube.)

Step 2

To open the mouth and make the eyes roll up, make servo P0 turn to the left:

    1. Type in or use the slider to adjust the “set servo angle” block for P0 to about 10 degrees.

    2. Insert a pause of about one second (1000 milliseconds, or ms).

    3. Use another “set servo angle” block to set it back to 90.

    4. Place the blocks inside a repeat block set for as many times as you want the mouth to open and close.

    5. Place the entire stack inside an “on button A pressed” block so you can trigger the action.

Step 3

To make the unibrow point down, go back to the middle, and then point up, swing the servo at P2 in both directions:

    1. Type in or use the slider to adjust the “set servo angle” block for P2 to about 10 degrees.

    2. Insert a pause of about one second.

    3. Use another “set servo angle” block to set it back to 90. Add another pause.

    4. Use a third “set servo angle” block to move the servo to 170 degrees, the opposite direction. Add another pause.

    5. Use the last “set servo angle” block to set it back to 90.

What Is Next?

More Ideas

  1. Program the lights to flash or show images that match your animatronic face’s moods.

  2. Add Music blocks to make the mouth talk. Scroll down to the bottom of the Music block menu to find the “play sound” block. It includes sounds like “giggle” and “yawn.” Or use notes from the Tone section of the Music menu to create your own “tonal” language!

  3. Add “on sound” blocks from the Input menu to make the mouth “answer” with tones when it hears someone talk to it.

About the Makey:bit

The Makey:bit Adventure Board is the perfect way to get started with microcontrollers. With this exclusive Maker Shed kit, you’ll be able to easily launch into the world of electronics and create amazing projects.

This all-in-one board includes everything you need to get started, including a built-in LED, buzzer, and various sensors. Plus, the Makey:bit is compatible with all kinds of additional modules, so you can easily expand your creativity.

So what are you waiting for? Get the Makey:bit Adventure Board today and start supercharging your microcontrollers!

Are you looking for a way to supercharge your microcontrollers? If so, then you need the Makey:bit Adventure Board! This exclusive Maker Shed product is packed with features that will take your microcontrollers to the next level. With the Makey:bit, you’ll be able to launch into the realm of microcontrollers and unleash their full potential. The Makey:bit is loaded with features that make it an essential tool for anyone looking to get the most out of their microcontrollers.

Makey:bit Cereal Box Plotter

1-3 hours

Ages 8+

What Will You Make?

In this project, you will create a programmable drawing robot, also called a plotter. The Makey:bit and the micro:bit control two servos, which make the arms move around. The micro:bit’s accelerometer lets you use the Makey:bit as a tilt controller and tell the plotter to draw back and forth and side to side across the paper!

What Will You Learn?

You’ll learn to use the input from an accelerometer to control servos with MakeCode and a micro:bit.

Prep the Base

Step 1

The base of the plotter is a folded-over ridge of cardboard that holds the servos, and a flat surface that holds the drawing paper. Cereal box cardboard has a coating on the outside that prevents the marker from soaking through. To make it out of a sheet of cardboard, fold the end of a rectangle over twice and tape it as shown.

Step 2

To make the plotter base out of a cereal box, lay the box down on its back. Draw a line across the box about 2 inches up from the bottom. Press hard. Draw another line about 2 inches above the first.

Step 3

Cut one top edge of the box from the opening at the top to the first line. Repeat with the other edge. This will turn the front of the box into a flap you can fold back.

Step 4

Fold the flap up along the second line. Then fold it down along the first line. Press the rest of the flap into the bottom of the box so it lays flat. If you want, trim the other end of the box to fit around the flap. Tape everything in place.

Insert the Servos

Step 1

Place the servos on the stand, trace around them, and cut out the shapes. 

Step 2

Cut a hole in the back of the box. Insert the servos into the hole on top. Pull the servo cables out through the hole in the back.

Step 3

To calibrate the servos so they face front when set at neutral (90 degrees), follow these steps with each one:

  1. Attach a servo horn with an arm facing straight ahead. 
  2. Gently turn the servo horn all the way to the right, as far as it will go. If the arm is not pointing to the right (3 o’clock position), then remove the servo horn and snap it back on in the correct position. 
  3. Turn the servo so the arm points straight ahead again.

Make the Arms

Step 1

Cut four strips of sturdy cardboard, about 1 inch wide by 4 or 5 inches long.

Step 2

Connect the ends of two strips with a brad. Use the sharp pencil to make a starter hole if needed. You now have an arm that bends at the “elbow.” Repeat with the other two strips.

Step 3

Take the end of one arm and overlap it with the end of the other arm. To make a holder for the marker, poke the sharp pencil through both layers of cardboard.

Step 4

Insert the marker through both layers of cardboard. With the cap end of the marker facing down, play around with the ends of the arms. See how you can move them to make the pen go in different directions.

Step 5

Tape the loose ends of the arms securely to the servo horn.

Step 6

Test it with some paper cut down to fit inside the box. See where the marker goes to the right, left, front and back of the box.

Connect the Makey:bit to the Servos

Step 1

Insert the micro:bit into the Makey:bit.

Step 2

Plug the cable wires for one servo over the pins marked SRVA. Write P0 next to the servo.

Step 3

Plug the cable wires for the other servo over the pins marked SRVB. Write P2 next to the servo.

Step 4

Use the data cable to connect the micro:bit to your computer and get ready to code!

Coding Instructions

Sample Code

Sample Plotter Code https://makecode.microbit.org/_XMd1evDoHfMm 

Code the arms to move in the direction you tilt the Makey:bit. 

NOTE: Only move the servo(s) a little way to the right or left. This will help you avoid jerking the plotter arms around too far and damaging the cardboard or the electronics. If needed, increase the movement in small steps until you reach the amount you want.

Coding micro:bit

  1. On start, set the servos to 90 degrees (neutral position).
  2. From Input, grab the “on shake” block.
  3. Open the drop-down menu and choose “tilt left.” 
  4. Add a stack of blocks to make the servos turn left.
  5. Download and test your code. 
  6. When it’s correct, duplicate the stack and  change everything to turn to the right.
  7. Add comments to remember what your code does!

About the Makey:bit

The Makey:bit Adventure Board is the perfect way to get started with microcontrollers. With this exclusive Maker Shed kit, you’ll be able to easily launch into the world of electronics and create amazing projects.

This all-in-one board includes everything you need to get started, including a built-in LED, buzzer, and various sensors. Plus, the Makey:bit is compatible with all kinds of additional modules, so you can easily expand your creativity.

So what are you waiting for? Get the Makey:bit Adventure Board today and start supercharging your microcontrollers!

Are you looking for a way to supercharge your microcontrollers? If so, then you need the Makey:bit Adventure Board! This exclusive Maker Shed product is packed with features that will take your microcontrollers to the next level. With the Makey:bit, you’ll be able to launch into the realm of microcontrollers and unleash their full potential. The Makey:bit is loaded with features that make it an essential tool for anyone looking to get the most out of their microcontrollers.

FEEDBACK