ev3 programming basics - the ponytail posse · project* x program x lego mindstorms education ev3...

17
EV3 Programming Basics Norton Lam Lego League Co-coordinator Island Lake Elementary

Upload: others

Post on 30-Jul-2020

7 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

EV3 Programming Basics

Norton LamLego League Co-coordinator

Island Lake Elementary

Page 2: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Programming a Parent

• Forward = two wheels• Turn = one wheel• Think in steps• Reusability• Loops• http://www.legoleaguecoaching.org/2010/09/21/programming-a-

parent/

Page 3: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Motor Tips

• Common sense wiring– Forward = Up– Ports B & C for motors

• Rotations vs. Degrees vs. Seconds

Page 4: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Forward

Page 5: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Turn Left

Page 6: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

90 Degrees is not 90 Degrees

Page 7: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Square

Page 8: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Loop

Page 9: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Command Blocking

Page 10: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Command Contingency

Page 11: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Loop with Light Sensor

Page 12: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Wait Until…

Page 13: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Wait Until… Stop

Page 14: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

MyBlocks

Page 15: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Comment

Page 16: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Programming Tips• Common sense wiring

– Forward = Up– Ports B & C for motors– Touch sensor on port 1– Light sensor on port 3

• Use seconds only as a contingency• Use landmarks: lines, walls, mission models• View• Calibrate light sensor

– http://www.nxtprograms.com/line_follower/steps.html - Calibrate 3

• Use Wait Until methodology for smooth transitions

Page 17: EV3 Programming Basics - The Ponytail Posse · Project* x Program x LEGO MINDSTORMS Education EV3 Student Edition Go unti back ine 20 Project* x Program x LEGO MINDSTORMS Education

Programming Tips cont’d

• Watch the power of the motors• Watch battery power• Comment, comment, comment• MyBlocks• For more tips: http://www.legoleaguecoaching.

org/

• Watch out for lockups