Skip to main content

10.2

Major VersionM

by Pete Prodoehl

Introduction

Have you been trying to catch a Leprechaun, but he always gets away? This year try using a distance sensor to instantly sense the presence of a Leprechaun on St. Patrick's Day so that you can trap him and get 3 wishes!

Video Overview

  1. The first thing you'll need is a trap chamber. We used a green top hat, but you could also use a small cardboard box. To entice the Leprechaun, you'll need something that looks like gold. We used some plastic gold coins that look very shiny - they could be real! We put them in a small pot. To make the trap visible from afar, use a rainbow! We all know that gold can be found at the end of a rainbow, so the Leprechaun will surely be lured into your trap. We made ours from paper and cotton balls.
    • The first thing you'll need is a trap chamber. We used a green top hat, but you could also use a small cardboard box.

    • To entice the Leprechaun, you'll need something that looks like gold. We used some plastic gold coins that look very shiny - they could be real! We put them in a small pot.

    • To make the trap visible from afar, use a rainbow! We all know that gold can be found at the end of a rainbow, so the Leprechaun will surely be lured into your trap. We made ours from paper and cotton balls.

  2. Cut a hole in the back of the hat. This will allow the sensor to "see inside" the hat, and for the LEGO Beam motor arm to grab onto. Cut a hole in the back of the hat. This will allow the sensor to "see inside" the hat, and for the LEGO Beam motor arm to grab onto.
    • Cut a hole in the back of the hat. This will allow the sensor to "see inside" the hat, and for the LEGO Beam motor arm to grab onto.

  3. Cut a piece of foam core about 5 inches larger than the size of the hat. Staple the hat's brim to the foam core to make a hinge as shown. (If you're using a cardboard box, cut off all but one of the flaps and staple the remaining flap to the foam core.) Staple the hat's brim to the foam core to make a hinge as shown. (If you're using a cardboard box, cut off all but one of the flaps and staple the remaining flap to the foam core.)
    • Cut a piece of foam core about 5 inches larger than the size of the hat.

    • Staple the hat's brim to the foam core to make a hinge as shown. (If you're using a cardboard box, cut off all but one of the flaps and staple the remaining flap to the foam core.)

  4. Use LEGO Bricks to create a structure that holds the distance sensor up in a way that it points through the hole in the hat. Add LEGO parts to create a spot for the Bit Board. Add LEGO parts to create a spot for the Bit Board.
    • Use LEGO Bricks to create a structure that holds the distance sensor up in a way that it points through the hole in the hat.

    • Add LEGO parts to create a spot for the Bit Board.

  5. On top of the distance sensor, add another layer of LEGO to mount the servo motor. Use the LEGO Brick 2 x 2 with Pins and Axlehole (30000 / 65514)  to mount the motor on its side, as shown. On top of the distance sensor, add another layer of LEGO to mount the servo motor. Use the LEGO Brick 2 x 2 with Pins and Axlehole (30000 / 65514)  to mount the motor on its side, as shown.
    • On top of the distance sensor, add another layer of LEGO to mount the servo motor. Use the LEGO Brick 2 x 2 with Pins and Axlehole (30000 / 65514) to mount the motor on its side, as shown.

  6. Connect the 2AAA battery pack to the screw terminals. Connect:
    • Connect the 2AAA battery pack to the screw terminals.

    • Connect:

    • VCC to +

    • Trig to P14

    • Echo to P13

    • GND to -

    • Servo Motor to P1, + and -

  7. Download the code to the micro:bit https://makecode.microbit.org/_Tx4ap637E...
    • Download the code to the micro:bit https://makecode.microbit.org/_Tx4ap637E...

    • This code sets the servo motor to the "Start Angle" and keeps it there until the distance sensor senses a Leprechaun coming within 3 inches of the sensor. When it does, it moves the servo to the "Capture Angle" to drop the hat over the Leprechaun and trap him inside!

  8. Press Button "A" to move the motor to the Start Angle. Place the LEGO Beam motor arm on the motor shaft in the location where it will hold the hat up. Press Button "B" to test that the LEGO Beam doesn't hit the LEGO Bricks when it moves to the Capture Angle. Press Button "B" to test that the LEGO Beam doesn't hit the LEGO Bricks when it moves to the Capture Angle.
    • Press Button "A" to move the motor to the Start Angle. Place the LEGO Beam motor arm on the motor shaft in the location where it will hold the hat up.

    • Press Button "B" to test that the LEGO Beam doesn't hit the LEGO Bricks when it moves to the Capture Angle.

  9. Place the trap in a location where a Leprechaun could see it easily, preferably on a dresser or nightstand so that the Leprechaun will think you are asleep and  try to sneak in to steal your gold! Press the "A" button to move the motor to the "Start Angle" and place the hat over the motor arm.
    • Place the trap in a location where a Leprechaun could see it easily, preferably on a dresser or nightstand so that the Leprechaun will think you are asleep and try to sneak in to steal your gold!

    • Press the "A" button to move the motor to the "Start Angle" and place the hat over the motor arm.

    • Decorate the area around the trap with gold. Make sure that there is a lot of gold under the hat, but nothing within 3 inches of the sensor.

    • Add rainbow embellishments or a sign that says "FREE GOLD!".

  10. With the tap set the night before St. Patrick's day, go to bed as usual. If you hear the trap go off, wake up! Tell your Leprechaun that you will let him go if he grants you 3 wishes. MAKE 3 WISHES! What will you wish for?
    • With the tap set the night before St. Patrick's day, go to bed as usual.

    • If you hear the trap go off, wake up! Tell your Leprechaun that you will let him go if he grants you 3 wishes.

    • MAKE 3 WISHES! What will you wish for?

Finish Line

Natasha Dzurny

Member since: 08/26/2019

4,201 Reputation

79 Guides authored

0 Comments

Add Comment

View Statistics:

Past 24 Hours: 0

Past 7 Days: 1

Past 30 Days: 5

All Time: 648