Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Introductory Workshop for Horizon FLL Program Instructors: Cyrus Johannes With assistance from Coach Erik 2011 Some Slides and Materials courtesy Oregon.

Similar presentations


Presentation on theme: "1 Introductory Workshop for Horizon FLL Program Instructors: Cyrus Johannes With assistance from Coach Erik 2011 Some Slides and Materials courtesy Oregon."— Presentation transcript:

1 1 Introductory Workshop for Horizon FLL Program Instructors: Cyrus Johannes With assistance from Coach Erik 2011 Some Slides and Materials courtesy Oregon Robotics Tournament and Outreach Program

2 2 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

3 3 The Opportunity with FIRST ® Programs from FIRST ® (For Inspiration and Recognition of Science and Technology) Jr.FLL (Junior FIRST ® LEGO ® League) 6-9 year- olds – initial ORTOP pilot in 2006 FLL (FIRST ® LEGO ® League) 9-14 year olds – started by ORTOP in 2001 FTC (FIRST ® Tech Challenge) for high school students – initial ORTOP pilot in 2006 FRC (FIRST ® Robotics Competition) for high school students – not an ORTOP program but active in Oregon "To create a world where science and technology are celebrated.. where young people dream of becoming science and technology heroes"

4 4 The Opportunity -- FLL FIRST ® LEGO ® League (FLL) Targets 9-14 year olds Uses relatively inexpensive LEGO ® robotics kits, retail kit is around $280. Includes scientific research Features hands-on experience and multi- disciplinary teamwork

5 5 What Is an FLL Team? 4-10 youngsters each Ages 9-14 Led by coach and mentor Coach – adult with overall responsibility for the team Mentor – technical expertise Sources of teams Schools Community groups Neighborhoods

6 6 The FLL Team Experience Miniature engineering project team stressing Creativity and teamwork Engineering principles: requirements, alternatives, rapid prototyping, testing, … Hands-on problem solving Context is a real-world situation Illustrates multiple roles: Designers, Builders, Programmers, Sales and Marketing Insights into possible careers The youngsters do the work – FLL Coaches’ Honor Code and FLL Core Values

7 7 Tournament Structure Less focus on competition and more on showcasing the team’s learning and results Qualifying Tournaments Around 15-20 teams each Organized by Qualifying Tournament volunteers with support from ORTOP 21 in 2010: Vancouver, Bend, Roseburg, McMinnville, LaGrande, Corvallis, Hood River, Portland Metro area 11 Championship Tournaments 120 teams at two Championship Tournaments at Liberty High School in Hillsboro in January, 2011

8 8 Tournaments Exhibit Students’ Achievements Three opportunities to demonstrate robot on the Challenge playing field Interaction with Robot Design Judging Panel Presentation to Project Judging Panel General presentation area specified by FLL to enhance learning about the year’s theme Requires research by the team Develops presentation skills (the opportunity for the developing sales and marketing youngsters) Core Values Judging Panel

9 9 Robot Design Judging Panel of “experts” interviews teams Robot design: Creativity and robustness Programming: Creativity and robustness Explain their design of the robot and its program Demonstrate at least one mission on the challenge field Bring a printout of the program

10 10 Tournament Awards Award structure being reworked by FIRST ® Highest level awards (the Champions Awards) require good results in Robot Design, Project, Core Values, and Robot Performance ORTOP Young Team and Rookie Team Participation awards for all teams

11 11 Plans for 2011 Theme: Food Factor 400+ teams with more than 2800 youngsters Around 18-22 Qualifying Tournaments Held first two weekends in December 15 - 20 teams per tournament Expect same locations as last year 2 Championship Tournaments of about 60 teams each in January, 2012 Continued focus on outreach to girls & minorities More sponsors

12 12 FLL Core Values We are a team. We do the work to find the solutions with guidance from our coaches and mentors. We honor the spirit of friendly competition. What we discover is more important than what we win. We share our experiences with others. We display gracious professionalism in everything we do. We have fun.

13 13 FLL Core Values Team Observations Tournament officials observe teams during tournaments Looking for exceptional positive or negative demonstrations of FLL Core Values Observations can impact a team’s score either positively or negatively

14 14 Not a Drop-In Program This is a project oriented program Parents and team members need to understand the commitment required Team members need to be available on a consistent basis to move their parts of the project forward from the first meetings through the season-end tournaments

15 15 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

16 16 Before We Start The NXT Outputs(A,B,C) Inputs (1,2,3,4) Buttons (Enter, Back, Left, Right) USB port Motors Sensors Touch sensor, light sensor, color sensor, ultrasonic sensor, rotation sensor

17 Brick Port/Control Description 17

18 Motors and Sensors Attached Typical connection of motors and sensors 18

19 19 Build the Sample Robot Follow pages 2-10 and 19-23 in the booklet to build your base robot Caster Mount (pages 11- 18) Cowcatcher (pages 32 – 33) Fork Lift (pages 34 – 35) Left light sensor (pages 24-27), touch sensor (pages 28-29), and ultra-sonic sensor (pages 30- 31) may or may not already be assembled.

20 20 Build the Sample Robot (cont.) Add the left light sensor (page 25) Add the touch sensor (page 29) Color of parts need not match what is in the photos. These assembly instructions can be found with all the workshop materials at: www.ortop.org/Workshops

21 21 NXT Programming Let’s get back to our robots and learn how to make them do something!

22 22 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

23 Simple Programs from the Brick 23 NXT Program” display on the screen. “You don’t need a computer to program a robot. Using the NXT Program submenu shown in this figure, you can create many simple, 5-step programs without your computer.” [page 15 of the LEGO NXT User Guide.]

24 24 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

25 Areas of the NXT environment 25

26 The NXT Window 26

27 Common Blocks 27

28 Common Blocks 28

29 Wait for Blocks 29

30 30 NXT Block Summary High Utility Blocks Move Wait Loop Switch Sensor Blocks Stop Data Blocks (variables) My Blocks Low Utility Blocks Record/Play Motor Send Message Lamps Mini Blocks Random Advanced Useful for Debugging Sound Display Number to Text Text

31 31 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

32 Move Block 32

33 Putting Commands in a Program The commands get executed in a row by how far away they are from the beginning of the beam. So, command 1 in this picture happens first, and command 3 happens last. This is the program beam. This is where you put commands for the robot.

34 Using Commands You can pull commands down from the “palette” on the left side of the screen to the program beam. We’ll start with the MOVE command.

35 Move Settings When you put a new command in the program, settings pop up at the bottom that you can change. These are the settings for the MOVE command.

36 Direction 1.Up means forward, down means backward. 2.The “Do Not Enter” sign means “stop.” If you use this setting, nothing will happen to the robot’s movement unless it is already moving when this command is given.

37 Steering 1.The STEERING setting can be used to tell the robot to turn to the left or to the right. 2.The arrow in the middle will change to give you an idea of how the robot will move. 3.If the slider is moved all the way to the left or right, the robot will spin in place. 4.However, if the slider is moved to just before the extreme left or right, the left or right wheel (respectively), will not rotate during movement. (In other words, the robot will pivot.

38 Power 1.The POWER setting tells the robot how fast to move. 2.Think of it as a percentage, with 0 being no power and 100 being full power. 3.Also keep in mind that this is not necessarily a measure of speed. A heavy robot moving at 100 power can still go slower than a very light robot moving at 50 power.

39 Duration 1.With the DURATION setting, you can tell the robot how long or how far to move. 2.There are four options for the duration: Unlimited: The robot will continue to move with these settings until it is given a new movement command. Rotations: For each rotation, the wheels turn through 360 degrees. So, going forward 2.5 rotations would make the wheels rotate 2.5 x 360 = 900 degrees. Degrees: Same as rotations, but specified in degrees of rotation. Seconds: Amount of time for wheels to rotate at the given speed.

40 Summary of Motor Controls 40

41 Putting the Settings Together The actual movement of the robot is a combination of all of the settings. Some examples: You tell the robot to turn to the left using STEERING and set the DURATION to three rotations. Both wheels can’t do three rotations, because if they did, the robot would move straight. So, the robot’s computer figures out how far to turn each wheel to make the robot drive to the left on a path that is equivalent to three rotations of the wheels. If you set the POWER to 75, then setting different DURATIONS in seconds will make the robot move different distances. When making the robot turn, it usually makes the most sense to pull the STEERING slider all the way to the left or right. When you do this, each wheel will rotate the same amount (which can be set with DURATION in rotations mode), but in opposite directions.

42 Issues for First-Timers “Where did my settings go?” If you hear this, this usually means that the user has clicked away from the command for which they want to change the settings. If you put the mouse cursor over the command you want to change, it will have a blue highlight and the settings will reappear below the programming window. Click

43 Issues for First-Timers When you have finished building the program for the robot, it’s time to download it to the robot’s NXT brain. First, make sure that the USB cable that came with the NXT kit is plugged into the back of the computer and into the top of the NXT robot. Then, turn on the robot with the orange button on the NXT brain. (It doesn’t really matter whether you plug the robot in or turn it on first.)

44 Issues for First-Timers When you plug in the robot for the first time, the computer has to figure out how to talk to the robot before you can put the program on it. (For the computer savvy, the operation system installs the NXT drivers.) You don’t have to do anything for this, but it’s a good idea to wait about one minute after you have turned the robot on and plugged it into the computer. If you don’t, you might get an error message. Once the robot is on and plugged in, you can hit the “download” button (pointed out in the picture below). You should get a “Complete!” message on the computer screen if it downloaded correctly.

45 Issues for First-Timers Once the program is downloaded on the NXT brain, you use the buttons on the front of the brain to run the program. You use the orange button to select items on the screen, and the dark gray button to back up in the menus. (They’re a little like the green and red buttons on a cell phone.) The arrow buttons move left and right in the menus. To run the program you downloaded, you first need to find it. From the main menu, programs you download are located in My Files->Software Files. The program you downloaded should be called by the same title you gave it at the beginning. If you press the orange button when you find your program, you will be given the option to Run or Delete the program. Choose Run to see if the program did what you wanted!

46 Issues for First-Timers If you are finished with the robot, you can turn it off by hitting the dark gray button from the main menu on the NXT brain. You will be asked if you want to turn the robot off. Select the checkmark to say OK. The NXT brain only has a limited amount of space to store programs. It’s not a bad idea to go into the My Files->Software Files folder and delete old programs from time to time so that you won’t run out of space. If you are running the Mindstorms software at a school, you probably have a tech specialist that installs software for you. You will probably need to ask the tech specialist to install the software for the first time. Make sure he or she knows that the students in your class are going to need to be able to run the program. Also for the tech specialist: The LEGO Mindstorms software is not compatible with display resolutions below 1024 by 768 pixels. Make sure before you need to use the software in your class that all of the computers you will use are set to this resolution or higher.

47 47 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Exercises Sensor Blocks Control blocks Development Tips

48 Move Block Exercise 1 Precise moving is key View the rotation sensor in degrees moving the robot 10 inches. Program a move block to move 5 inches Program a move block to move 10 inches Program a move block to move 15 inches 48

49 Viewing Motor Rotations 49 1a. Turn on NXT Turn on your NXT if it is not already on. 1b. Navigate to View Mode Use the left and right arrow buttons to find the View option, and press the Orange button to select it.

50 Move Block Exercise 2 Determine how many degrees of wheel rotation is required to do a 90 degree turn of the robot using view functionality. Program the robot to: Go straight 4 inches Do a 90 degree turn Go straight 6 inches Do a 45 degree turn Go 8 inches 50

51 Place Robot on View Motor B Rotations Place Robot on the pivot point Slowly rotate both wheels in opposite directions without too much pressure Read Degrees of motor rotation Repeat a couple times to average out 51

52 Move Block Exercise 3 The Maze of doom!!!!! Maneuver through the maze of doom starting from base and returning to base. Hints: Turns are 90 and 45 degrees Use tape measure to determine distances Go step at a time 52

53 Some Tips to help debug You can use the Stop block in the middle of a program. You can use the wait block for the NXT button. 53

54 Debug example Insert a button wait block into the program to stop it until you hit the orange button 54

55 55 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks - Touch Control blocks Development Tips

56 Touch Sensor 56

57 Touch Sensor Settings 57

58 Wait Block for Touch Sensor 58

59 Touch Sensor Exercise Change your Maze program to use the touch sensor. Keep your 90 degree turns. Replace the straight line move blocks to unlimited moves. Add a touch wait block Add a move block that stops the robot. 59

60 Use touch sensor in the Maze Change the straight line runs to use touch sensors 60

61 61 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks - Light Control blocks Development Tips

62 Light Sensor 62

63 Light Sensor Cont. 63

64 Viewing Light Sensor Readings 64 1a. Turn on NXT Turn on your NXT if it is not already on. 1b. Navigate to View Mode Use the left and right arrow buttons to find the View option, and press the Orange button to select it. 1c. Select Reflected Light Use the left and right arrow buttons to find the Reflected Light option, and press the Orange button to select it. 1d. Select Port 1 Make sure your Light Sensor is plugged into Port 1 on the NXT. Select Port 1 on screen.

65 Viewing White Light Readings 2. Place robot over light surface Position the robot so that the light sensor shines on a light-colored surface. 65 1. You are now seeing the sensor’s value live, in real time. 3. Record ”light” sensor value On a separate sheet of paper, write down the Light Sensor value for a “light” surface.

66 Viewing Black Light Readings 4. Place robot over dark surface Position the robot so that the light sensor shines on a dark-colored line. 66 5. Record ”dark” sensor value On a separate sheet of paper, write down the Light Sensor value for a “dark” surface. 6. A fair place to set the cutoff line is right in the middle between these two values. That would be the average of these two values. 7. Find the Midpoint to get the cutoff The first step in finding an average is to find the sum of the two values. Since there were two values (light and dark), divide the sum by 2 to find the average. (value 1 + value 2) / 2 = Threshold Value

67 View Light Sensor Readings Class uses the block to read light readings. 67

68 Light Sensor Wait Block 68

69 Light Sensor Exercise Create a version of the maze program to use the light sensor. 69

70 Other Sensors 70

71 Ultrasonic Sensor Used to read distance to an object. Values in centimeters or inches. Works best against a flat object with the robot perpendicular to the object. 71

72 Viewing Ultrasonic Readings Can use the NXT Brick’s View capability to read the ultrasonic sensor. 72

73 Ultrasonic Exercise Create a version of the maze program using the ultrasonic sensor. 73

74 74 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

75 75 Different Forms of Loop Block Look at Loop Blocks in the software Notice the “Data Hub” on the Loop on Logic Value block

76 Loop with Touch Sensor 76

77 77 Use a Switch Block How will we decide if it’s a green or black bar? Look at Switch Blocks in the software

78 Switch Block 78

79 Light Sensor Switch Block 79

80 Cans in Circle Exercise 80

81 81 Data Hubs Look at Data Hubs in the software

82 82 Data Wire Tips Easiest way to connect a data wire: click on the port at the left end and then click on the port on the right end To delete a data wire: click on the right end of the wire

83 83 Data Wire Tips (cont.) You cannot connect a wire from an output port on a data hub unless there is a wire going into the corresponding input port Broken wire Add a new variable block in the read state

84 84 Data Wire Tips (cont.) Don’t run long data wires from a variable block to a data hub. Instead, insert a variable block for the variable you want to use near where you want to use it so that the data wire is short. Not so goodBetter

85 85 Agenda Introductions The ORTOP and FLL Programs Build a LEGO ® robot and try it out Simple programming of your robot brick Using the NXT Software Move Block Sensor Blocks Control blocks Development Tips

86 86 Build a My Block to Display Number Convert number to text Display block If the bounding box you use to select the blocks for the My Block crosses a data wire, then that value becomes an input or output parameter for the My Block.

87 87 Display Number My Block Note the Wait For block to wait for 3 seconds to give time to read the result Note the number as input parameter to the MyBlock

88 88 Other Debugging Ideas I don’t know where the robot is in the program. Use a Sound Block to just play a tone to see if the robot has gotten to a particular point. What value does my variable have? “Print” the value to the NXT screen to see the value. Take a subtask out of a more complex larger program and debug it separately rather than trying to debug it in the full more complex environment.

89 The End 89


Download ppt "1 Introductory Workshop for Horizon FLL Program Instructors: Cyrus Johannes With assistance from Coach Erik 2011 Some Slides and Materials courtesy Oregon."

Similar presentations


Ads by Google