The Scribbler Project

Similar documents
Teacher Answer Key: Measured Turns Introduction to Mobile Robotics > Measured Turns Investigation

Problem of the Month: Fair Games

The Basics of Robot Mazes Teacher Notes

understanding sensors

Girl Scout Journey: It's Your World Change It!

STEAM STUDENT SET: INVENTION LOG

Rubber Band Race Car

Chapter 2. Making Shapes

Grade 7/8 Math Circles November 3/4, M.C. Escher and Tessellations

Decomposing Numbers (Operations and Algebraic Thinking)

The Photosynth Photography Guide

Lesson 26: Reflection & Mirror Diagrams

Blender Notes. Introduction to Digital Modelling and Animation in Design Blender Tutorial - week 9 The Game Engine

Your EdVenture into Robotics You re a Controller

Christmas Theme: The Greatest Gift

Mobile Robotics I: Lab 2 Dead Reckoning: Autonomous Locomotion Using Odometry

Rockets: Taking Off! Racing Balloon

itunes Basics Website:

C.I. La chaîne d information LES CAPTEURS. Page 1 sur 5

INTRODUCTION TO COACHING TEACHING SKILLS TEACHING/LEARNING. September 2007 Page 1

Design a Line Maze Solving Robot

The GED math test gives you a page of math formulas that

Programming LEGO NXT Robots using NXC

TEACHER S GUIDE TO RUSH HOUR

Introduction to SketchUp

REWARD System For Even Money Bet in Roulette By Izak Matatya

Phases of the Moon. Preliminaries:

measurement, number & operations, reasoning & proof, and science & technology

Lego Robot Tutorials Touch Sensors

Inclined Plane: Distance vs. Force

Getting to Know God: Who God Is Week 7: God Is Unchanging LEADER PREPARATION

How to Build Your Own CornHole Game

AGES 8+ b e g g i n ʼ f o r t h e b e a t USER S GUIDE

Circumference and Area of a Circle

Tutorial for Programming the LEGO MINDSTORMS NXT

Math Games For Skills and Concepts

Objective: God is all Powerful! Bible Memory Verse: Matthew 19:26b With man this is impossible, but with God all things are THEME OVERVIEW

Determining the Acceleration Due to Gravity

Build A Simple Electric Motor (example #1)

Unit 4: Exploring Math Patterns Introduction...5. Unit 1: Visualizing Math Unit 5: Exploring Probability...125

How To Program An Nxt Mindstorms On A Computer Or Tablet Computer

Introduction to learning with Sphero

Lab 11. Simulations. The Concept

Tessellating with Regular Polygons

Julie Rotthoff Brian Ruffles. No Pi Allowed

Custom Linetypes (.LIN)

Lesson #13 Congruence, Symmetry and Transformations: Translations, Reflections, and Rotations

Fun Learning Activities for Mentors and Tutors

Mathematical goals. Starting points. Materials required. Time needed

TO WRITING AND GIVING A GREAT SPEECH. A Reference Guide for Teachers by Elaine C. Shook Leon County 4-H

Village Activity: Beating Bullying

7.S.8 Interpret data to provide the basis for predictions and to establish

Line Tracking Basic Lesson

SCRATCH Lesson Plan What is SCRATCH? Why SCRATCH?

Fry Phrases Set 1. TeacherHelpForParents.com help for all areas of your child s education

Section 1.5 Exponents, Square Roots, and the Order of Operations

Warmups and Energizers

Using sentence fragments

AwanaGames Circle. Official. Diagram 1. Key to diagram: Pin & Striped Bean Bag C Diagonal or Starting Line. B Scoring Pins, or Center.

6th Grade Lesson Plan: Probably Probability

End of Reception Report: July 2013

KNITTING MACHINE Quick Tips for Knitting Success

Your EdVenture into Robotics You re a Programmer

Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 10

Math Girls Rock! Math Club for Young Women Project 2. Geometric Probability and Buffon s Needle Problem

Twist Drill Grinding Attachment By Steven Skiprat Jackson June 2009

PUSD High Frequency Word List

In the situations that we will encounter, we may generally calculate the probability of an event

Lecture 2 Mathcad Basics

Tips For Selecting DC Motors For Your Mobile Robot

Learn How to Revise 1

Banquet with Simon. (Luke 7:36-50) Keep these tips in mind as you welcome kids to the workshop and explore the story together.

Behavior List. Ref. No. Behavior. Grade. Std. Domain/Category. Fine Motor Skills will bring hands to mid line to bang objects together

FREEBIRD THE ORIGINAL D.I.Y. ORNITHOPTER! Tools and Glue. Required Materials

Trigonometric functions and sound

Quick Start Guide to computer control and robotics using LEGO MINDSTORMS for Schools

3 days Lifting the Qualities of Effective Fiction Writing. 3 4 days Stretching Out the Problem and Imagining Creative Solutions to Stories

Agility Training for 4-H Dog Club (Page 1 of 5

Breathe. Relax. Here Are the Most Commonly Asked Questions and Concerns About Setting Up and Programming the SurroundBar 3000.

Introduction to MATLAB IAP 2008

Example Chapter 08-Number 09: This example demonstrates some simple uses of common canned effects found in popular photo editors to stylize photos.

Turtle Power. Introduction: Python. In this project, you ll learn how to use a turtle to draw awesome shapes and patterns. Activity Checklist

Lesson 21. Circles. Objectives

Vectors. Objectives. Assessment. Assessment. Equations. Physics terms 5/15/14. State the definition and give examples of vector and scalar variables.

Analysis of Micromouse Maze Solving Algorithms

Cambridge English: ESOL Skills for Life

Thread Tensions All Machines

Photoillustration: Harold A. Perry; photos: Jupiter Images

GAME SYSTEM MANUAL PITTSBURGH MODULAR SYNTHESIZERS

Lesson 3. Branches of Government. Student Materials OBJECTIVE FOUNDATIONS UNIT

Handwriting. Good handwriting (i.e., legible writing done by hand whether it is. Teaching Printing

Chapter 6: Probability

Coaching and Feedback

Introduction to programming moway

family games Taking the kids swimming is a great way of making sure they re moving around and having fun. And to help you get them into

This, is Blade Stepper, a modern spin on the classic 3-reel mechanical slot machine.

Designing the User Experience

Kristen Kachurek. Circumference, Perimeter, and Area Grades Day lesson plan. Technology and Manipulatives used:

Mathematics (Project Maths Phase 1)

Earth Art: Creating Patterns in Nature

Transcription:

The Scribbler Project By: Eduardo Hernandez (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 1

Table of Contents The Scribbler Project... 1 Table of Contents... 2 Part I: Motion by Dead-reckoning... 3 Experiment 1 Draw a square... 3 Part 1: The Square... 3 Experiment 2 Draw a circle... 4 Part I: The Circle... 4 Experiment 3 Draw a star... 4 Part 1: The Star... 4 Experiment 4 Measure your flicker fusion threshold... 5 Part 1: The Flicker... 5 Part 2: Journal Exercise... 5 Experiment 5 A Scribbler siren... 5 Part 1: The Siren... 5 Experiment 6 Testing the coin toss... 6 Non-determinism and Randomness... 6 Part 1: The Coin Toss... 6 Experiment 7 Random walk... 7 Part 1: The Drunk Walk... 7 Part 2: Journal Exercise... 7 Part2: Open Ended Answers... 8 Experiment 1 Scribbler Art... 8 Part 1: Scribbler Art... 8 Experiment 2 Navigating a Maze... 9 Part 1: The Maze (Extra Credit)... 9 (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 2

Part I: Motion by Dead-reckoning You can move the robot along a pre determined path by specifying the motor speed and duration of each leg of the journey. This kind of navigation is called dead reckoning. The robot s basic movement commands all work this way (except that the Scribbler uses motor power to approximate speed.) One drawback of dead reckoning is that any error in the measurement of speed or direction accumulates over time, causing the robot s position to become less and less accurate. In this section you ll use dead reckoning to make the Scribbler draw some simple figures. You ll also see how to apply basic geometry to plan the robot s course. Experiment 1 Draw a square Instructions required: Forward, Spin Right, Pause, Do for n times Part 1: The Square Program the Scribbler to draw a square with sides approximately 4 inches in length. Use trial and error to get the distances and angles right. 1. First write the code step by step avoiding loops (Save file as P1EX1a_GroupName). 2. Next use a loop to avoid writing the same instructions four times (Save file as P1EX1b_GroupName). Tips for accurate drawing: Tape the paper to your lab table so it doesn t slip. Always test the robot on the paper, since angles and distances may come out differently on other surfaces. Always insert a 0.2 second pause between motor commands to give the robot time to come to a stop. (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 3

Experiment 2 Draw a circle Instructions required: Advanced motor controls Part I: The Circle Program the Scribbler to draw a circle with a radius of approximately 5 inches. Use trial and error to make sure the circle is complete without retracing too much of the line. Your program should use only a single instruction. Save file as P1EX2_GroupName Experiment 3 Draw a star Instructions required: Forward, Spin Right, Pause, Do for n times Part 1: The Star Program the Scribbler to draw a five point pentagram star, as shown that is approximately 5 inches in length. This time use only a loop to avoid writing the same instructions multiple times. Each vertex has an interior angle of 36. Use this fact and the time you ran the motors to make a 90 angle in Experiment 1 to estimate how long to run the motors for the angles of the star. To draw more complicated pictures, you ll need to take advantage of the Scribbler s Advanced Motor Controls. These allow greater control over the speed of each wheel. Save file as P1EX3_GroupName (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 4

Experiment 4 Measure your flicker fusion threshold Instructions required: LED, Pause, Do Forever Part 1: The Flicker Write a Scribbler program that repeatedly blinks the LEDs on and off. Insert equal length pauses after the LEDs turn on and after they turn off. Start with very brief pauses 0.01 seconds. Save file as P1EX4_GroupName Part 2: Journal Exercise 1. Run your program and watch the LEDs. Do they appear to flicker? If not, alter the program to double the pause times, and try again. Repeat this process until you can see the LEDs flicker (Or as close as you can get to getting the lights to flicker). 2. What is the briefest pause time where you can see flicker? What frequency does this correspond to? (Frequency = 1 / time. Here, time is the length of one complete on off cycle.) 3. Movies are displayed at 24 frames per second and TV at 29.97 frames per second, though these are not the rates at which the images flicker. Use Google or Wikipedia to research how these imaging technologies increase the flicker rate to exceed the flicker fusion threshold. Write a few sentences about what you find in your journal. Experiment 5 A Scribbler siren Instructions required: Do forever, Sound Part 1: The Siren Program the Scribbler to sound a siren by repeating two different tones. Experiment with different frequencies and durations to produce a realistic effect. Try frequencies that are close together and ones that are farther apart. Characteristics of the robot s speaker and the resonance of its plastic case cause some frequencies to sound louder than others. Choose loud ones for your siren. (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 5

Save file as P1EX5_GroupName Experiment 6 Testing the coin toss Instructions required: If, Forward, Back Non-determinism and Randomness The robot s sensors detect the condition of the physical world, but there is another condition that can be used in branches and loops: the outcome of a random coin toss. Of course, the robot doesn t toss an actual coin; rather, it uses a mathematical function with random looking outputs to simulate a coin toss. If you toss a fair coin, it will come up heads or tails with about equal likelihood. Is the robot s coin fair? Part 1: The Coin Toss Program the Scribbler to toss a coin. If the coin toss comes up heads, move the robot forward a few inches; otherwise, move it back a few inches. Run this program 10 times. Count how many times the robot moved in each direction. Imagine a staggering drunk on his way home from the bar. He is so inebriated that, with each step, he moves forward with probability p and backwards with probability 1 p. This kind of motion is a simple example of a random walk. Random walks are used as a model in an amazing variety of contexts, including physics (Brownian motion), economics and finance (share prices), and biology (bacterial motion). You can command the Scribbler to follow a very simple random walk and investigate some of the properties of this motion. Save file as P1EX6_GroupName (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 6

Experiment 7 Random walk Instructions required: Do for n times, If, Forward, Back, Pause Part 1: The Drunk Walk Clearly, 10 samples is too little information to judge whether the coin toss is fair. Test 50 times instead. Rather than running the program 50 times by hand, create a new program that adds a loop around the instructions in Experiment 9. Part 2: Journal Exercise 1. If the Scribbler s coin toss is fair, we expect that the average distance from the robot s starting position to its final position will be zero. However, in any individual trial, the robot is unlikely to end up exactly where it started. If the distance traveled after one coin toss is d, how far from the starting position will the robot finish most of the time? 2. Place the robot on the floor and mark its starting point with a piece of tape. Run the program and measure the actual distance. 3. Try this test three more times. How accurate was your prediction? 4. For each trial, use the distance you recorded to determine about how many flips came up heads and how many came up tails. 5. Does the robot s coin toss appear to be fair? Do you have enough information to say with confidence? Briefly respond. (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 7

Part2: Open Ended Answers In part 2 you ll write more code to control the robot. This challenge is more open ended than the last ones. There are many ways to solve them, so try to start brainstorming early! Experiment 1 Scribbler Art Instructions required: Got to use your head for this one! Part 1: Scribbler Art Now it s time to get creative. Working in your team, write pseudocode to show off the Scribbler s artistic side. Here are a few suggestions for inspiration, but the possibilities are nearly endless. Check with your Peer Mentor if you have another project idea. Music: Program a song with the sound commands. This web site lists the frequencies for musical notes: http://www.phy.mtu.edu/~suits/notefreqs.html. Dance: Use motion commands and loops to teach Scribbler a simple step. Here s an amusing example: http://www.youtube.com/watch?v=n6um6l4e2og Drawing: Give Scribbler a pen and let it run wild. Give the robot a fixed drawing path with motion commands, or combine motion with coin tosses for something more abstract. If you want, bring several different color pens and other kinds of paper. Or draw something more creative than the Square from the first experiment. We ll give 50% of the points for entering anything that works. The remaining 50% will be awarded for creativity (but we ll be generous). The best entry wins a prize! (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 8

Experiment 2 Navigating a Maze Instructions required: Got to really use your head for this one! Part 1: The Maze (Extra Credit) Teach the robot to escape from a simple cardboard maze. (Refer to the next page for a diagram of the maze.) We will test your solution by placing Scribbler at a random location within a designated starting zone. This means the robot must use its sensors to navigate. We ll give points for a successful escape and for reliability in repeated tests. The solution to this problem is really open ended and can be a bit difficult to solve. It may also take substantial time to develop the code. Your Peer Mentor will not be able to assist you in this example which is why it is EXTRA CREDIT! (Project ideas borrowed from Princeton University, http://www.cs.princeton.edu) Scribbler Project--Page 9