Garden TOOLS - How-To Coding Guides

Garden vegetables, student notebook, and environmental sensor on a picnic table
Resource Summary
The Garden TOOLS how-to coding guides provide step-by-step instructions on how to program the BBC micro:bit in various ways to gather data in a school garden or other outdoor learning space.
Elementary
Classroom Instruction
After-School Instruction
At-Home Instruction
Technology
Engineering
Systems Thinking
Informed Decision Making
Food
Water
Share to Google Classroom

If you (or youth you work with) are just getting started with the BBC microbit, it can be helpful to allow for exploration time. Don't worry about completing a project or giving detailed instructions about what to do with microbit. Follow the easy steps in the setup guide to get started with the microbit, but then give youth a chance to play and experiment without step-by-step instruction.

You might want to consider beginning with one or more tutorials if you think students need a goal on which to focus.

In each tutorial, a set of basic instructions and simplified menus will be displayed to lead you through a coding activity.

  1. Create a scrolling name tag
  2. Animate a flashing heart
  3. Show different smiley faces

Once you feel comfortable with the coding basics, consider using the following instructions to code your microbit as a technology tool you can use in the garden or other outdoor space.

sun logo

Measure light intensity

How sunny or shady is it in your garden? How does this compare to inside your house or school? Code this sensor to measure brightness.

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)

Short on time? Download the finished code!

Need a video tutorial? Watch one here.

rain logo

Measure soil moisture

How wet or dry is your garden's soil? Code, build, and use this soil moisture sensor to find out. Look for dry and wet areas outside.

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)
  • Two nails (long and skinny work best)
  • Two alligator clips

Short on time? Download the finished code!

Need a video tutorial? Watch one here.

thermometer logo

Measure temperature

Are there areas in your garden that are warmer or cooler? Code this sensor to help measure temperature in the sun, shade, or anywhere in between.

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)

Short on time? Download the finished code!

plus-minus logo

Count wildlife, seeds, etc.

Want to count birds, bees, trees, or just about anything else? Code this counter to help you keep track!

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)

Short on time? Download the finished code!

compass logo

Navigate with a compass

Want to map your garden using a compass? Code the microbit as a compass and create a garden treasure map!

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)

Short on time? Download the finished code!

footsteps logo

Count your steps as you garden

You may not think about it, but gardening is a good workout. Code the step counter and track your fitness!

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)
  • Fabric or other band for attaching your microbit to your ankle

Short on time? Download the finished code!

Need a video tutorial? Watch one here.

orange logo

Create a fruit button

Want to explore how circuits work and eventually add some music to your garden? Code the microbit as a fruit button to help get started!

Materials needed:

  • Microbit
  • Computer with internet access
  • USB cord
  • Battery pack (if you want to take your microbit outside)
  • A piece of fruit (orange, apple, banana, etc.)
  • Two alligator clips

Short on time? Download the finished code!

Need a video tutorial? Watch one here.