This activity will lead you through the process of setting up the Finch Robots and micro:bits in your own classroom, and allowing students to expand on their coding skills by drawing new shapes! If you do not have Finch Robots, consider becoming a Science World Tech-Up ambassador for access to our loaner kits! Alternatively, try this activity that only requires computers.

### Objectives

• Create code to draw different geometric shapes

• Create and successfully call functions

### Materials

• Finch Robots

• Chart paper

• Crayola paint brush markers

• Micro:bits

• Computer with USB port and micro:USB cord OR tablets with FinchBlox or BirdBlox installed

### Key Questions

• What are the properties of regular polygons?
• What is a function?

### What To Do

#### Set up:

1. Set up the finch robots and microbits:
• Insert the microbit into the rear end of the finch and plug the microbit into the computer.
2. Open classroom.microbit.org and name your classroom. Choose “MakeCode editor”
4. From the editor page, you can share code with your students.

TIP: From the dashboard page, you can “Lock Students Screens” while you are talking to prevent them from getting distracted and missing instructions!

TIP: Follow this link for help on setting up a micro:bit classroom! https://microbit.org/get-started/user-guide/remote-teaching/

#### Recall:

1. Remind your students about how functions work. A function is a list of instructions that your Finch robot can call on when you are telling it to do certain things. In the workshop, you built a function that helped the Finch robot draw a square. The code might have looked something like this:

The blue function box contains all of the instructions that the Finch will follow when you tell it to make a square. The pink box contains the “call square” block, which is the block that triggers the function instructions to begin.

TIP: You need the “Start Finch” block in order for the robot to start moving!

1. See how much students can remember from their Science World workshop (or, if you didn’t do the workshop, see if they can create a function that codes a square and another function that codes a triangle) They probably learned how to draw a square and a triangle. Here is an example of what that code could look like:

#### Taking Inputs

After defining functions to draw the square and triangle, students can use inputs to adjust the size of their shapes. When making a new function, there is an option to add a parameter. Selecting “number” will allow students to input a number as the width of their square, and the code will adjust the robots movement accordingly. An example is provided below. When the function “adjustable_square” is called, the variable “num” can be inputted. Here, it is 1, which would make the width of the square that is drawn 1 cm:

#### New Shapes:

1. See if students can try and build some new shapes. A circle, an octagon, a hexagon, a star! Remind them that the Finch turns along the exterior angle from 180° (so to make an equilateral triangle with 60° angles, we needed to code the finch to turn 120°). Remind them to make all of their new code in specific functions so they can call on them whenever they want.

Finch robot manufacturers have created this worksheet for students to record information about each shape: https://docs.google.com/document/d/1L0ugJLC7UzJWQjoH6P43C3Qrv2Gzeu4zxDk55TjUMIk/edit

• In order to make polygons with multiple sides, students can divide 360° by the number of sides to figure out what angle they need to make their Finch turn (for example a pentagon has five sides, 360/5 = 72°, so to make a pentagon you need to code the Finch to draw a line then rotate 72° five times.)

#### Explore!

1. The range of possibilities for what the finch can do are almost endless! Allow students the time to explore the capabilities of the micro:bit and finch. This activity is about math, but it can be equally artistic.

### Extensions

• Can you draw a pentagon, hexagon, or star?
• Can you draw a rectangle or a trapezoid? What about a diamond?
• Can you use loops to make your code as efficient as possible?
• There are only three buttons on the micro:bit (A, B, logo)! If you make more than three shape functions, how can you use the other inputs of the micro:bit to trigger your finch to draw new shapes?
• How can you create a repeating pattern?
• Can you use the LED display to show what shape the finch is drawing?
• Can you make an irregular or asymmetrical shape?

### Other Resources

Try this activity next!

Survivors

Artist: Jeff Kulak

Jeff is a senior graphic designer at Science World. His illustration work has been published in the Walrus, The National Post, Reader’s Digest and Chickadee Magazine. He loves to make music, ride bikes, and spend time in the forest.

Egg BB

Artist: Jeff Kulak

Jeff is a senior graphic designer at Science World. His illustration work has been published in the Walrus, The National Post, Reader’s Digest and Chickadee Magazine. He loves to make music, ride bikes, and spend time in the forest.

Comet Crisp

Artist: Jeff Kulak

Jeff is a senior graphic designer at Science World. His illustration work has been published in the Walrus, The National Post, Reader’s Digest and Chickadee Magazine. He loves to make music, ride bikes, and spend time in the forest.

T-Rex and Baby

Artist: Michelle Yong

Michelle is a designer with a focus on creating joyful digital experiences! She enjoys exploring the potential forms that an idea can express itself in and helping then take shape.

Buddy the T-Rex

Artist: Michelle Yong

Michelle is a designer with a focus on creating joyful digital experiences! She enjoys exploring the potential forms that an idea can express itself in and helping then take shape.

Geodessy

Artist: Michelle Yong

Michelle is a designer with a focus on creating joyful digital experiences! She enjoys exploring the potential forms that an idea can express itself in and helping then take shape.

Science Buddies

Artist: Ty Dale

From Canada, Ty was born in Vancouver, British Columbia in 1993. From his chaotic workspace he draws in several different illustrative styles with thick outlines, bold colours and quirky-child like drawings. Ty distils the world around him into its basic geometry, prompting us to look at the mundane in a different way.

Western Dinosaur

Artist: Ty Dale

From Canada, Ty was born in Vancouver, British Columbia in 1993. From his chaotic workspace he draws in several different illustrative styles with thick outlines, bold colours and quirky-child like drawings. Ty distils the world around him into its basic geometry, prompting us to look at the mundane in a different way.