Learning CS and Math with Robotics

CSP Unit 3 Lesson 6.2

Piano MinView
Linkbot Image Mindstorm Image
Grid Lines:
Tics Lines:
Width px
Hash Lines:
Width px
Font px
Trace Lines:
Robot 1:
Width px
Robot 2:
Width px
Robot 3:
Width px
Robot 4:
Width px
Simple View: Grid Size: S M L
CSP Unit 3 Lesson 6.2

Now's your chance to put into practice some of the things you have been learning about coding and functions. Create a program that directs the robot to trace out the blue figure shown. Think about what parts are repetitive and how each might be coded as a function. After the initial setSpeed and traceColor commands (pre-placed), your program should call a function that then calls other functions, as appropriate, to draw the figure. Use descriptive names for the functions. (To turn left or right, or turn around, you may use the built-in "turn" function with the appropriate direction and angle.)

Load Blocks
Workspace Show Ch Save File Console

Rubbish bin