Learning CS and Math with Robotics

CSP Unit 3 Lesson 8.6

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 8.6

Using your newly defined traceTriangle function block (instructions above), add the code to it that turns off the trace, uses the drivexyTo command to move the robot to the point (x,y), turns on the trace, uses another drivexyTo command to draw the bottom side of the triangle, and then uses turnLeft and driveDistance commands to draw the other two sides of the triangle. We have pre-placed in the Workspace the drivexyTo command that draws the bottom side, so you can simply drag it into the function definition when needed. Once the function is defined, add code to the Workspace that calls it twice to draw a triangle of side length 10 and left corner at (8, 8) and a triangle of side 14 and left corner at (18, 15).

Load Blocks
Workspace Show Ch Save File Console

Rubbish bin