0x726048362412y726048362412
Grid:
Tics Lines:
Width px
Hash Lines:
Width px
Labels:
Font px
Trace Lines:
Robot 1:
Width px
Robot 2:
Width px
Robot 3:
Width px
Robot 4:
Width px
Axes: x-axis y-axis Show Grid
Grid: 24x24 inches 36x36 inches 72x72 inches
96x96 inches 192x192 inches
Quad: 4 quadrants 1 quadrant
Units: US Customary Metric
Background:

Robot 1

Initial Position:
( in, in)
Initial Angle:
deg
Current Position: (36 in, 36 in)
Current Angle: 251.57 deg
Wheel Radius:
Track Width:
in

Robot 2

Initial Position:
( in, in)
Initial Angle:
deg
Current Position: (48 in, 3 in)
Current Angle: 109.43 deg
Wheel Radius:
Track Width:
in

Robot 3

Initial Position:
( in, in)
Initial Angle:
deg
Current Position: (24 in, 0 in)
Current Angle: 90 deg
Wheel Radius:
Track Width:
in

Robot 4

Initial Position:
( in, in)
Initial Angle:
deg
Current Position: (36 in, 0 in)
Current Angle: 90 deg
Wheel Radius:
Track Width:
in

Two Robots Driving in an Intersection
Problem Statement:
The pre-placed blocks draw an intersection with stop signs and move the robots to the stop signs. Robot 1 should turn right and robot 2 should go straight through the intersection.
/* Code generated by RoboBlockly v2.0 */
#include <chplot.h>
#include <linkbot.h>
CPlot plot;
CLinkbotI robot1;
double radius1 = 1.75;
CLinkbotI robot2;
double radius2 = 1.75;
double trackwidth1 = 3.69;

plot.noStrokeColor();
plot.fillColor("#cccccc");
plot.rectangle(0, 12, 72, 10);
plot.strokeColor("#ffff66");
plot.lineStyle("-");
plot.line(0, 17, 8, 17);
plot.lineStyle("-");
plot.line(12, 17, 20, 17);
plot.lineStyle("-");
plot.line(24, 17, 32, 17);
plot.lineStyle("-");
plot.line(36, 17, 44, 17);
plot.lineStyle("-");
plot.line(48, 17, 56, 17);
plot.lineStyle("-");
plot.line(60, 17, 68, 17);
plot.noStrokeColor();
plot.fillColor("#999999");
plot.rectangle(22, 22, 0.5, 9.5);
plot.fillColor("red");
plot.strokeColor("white");
plot.regularPolygon(22, 32, 8, 2, 180);
plot.noStrokeColor();
plot.fillColor("#999999");
plot.rectangle(61, 11.5, 0.5, 9.5);
plot.fillColor("red");
plot.strokeColor("white");
plot.regularPolygon(61.25, 22.5, 8, 2, 180);
robot1.setSpeed(4, radius1);
robot2.setSpeed(4, radius2);
robot2.driveDistanceNB(7, radius2);
robot1.driveDistance(14, radius1);
robot2.driveTimeNB(7);
robot1.delaySeconds(1.5);
robot1.turnRightNB(65, radius1, trackwidth1);
robot1.driveDistance(28, radius1);

plot.label(PLOT_AXIS_XY, "");
plot.grid(PLOT_OFF);
plot.tics(PLOT_AXIS_XY, PLOT_OFF);
plot.axis(PLOT_AXIS_XY, PLOT_OFF);
plot.axisRange(PLOT_AXIS_XY, 0, 72);
plot.ticsRange(PLOT_AXIS_XY, 6);
plot.sizeRatio(1);
plot.plotting();
Blocks Save Blocks Load Blocks Show Ch Save Ch Workspace
Problem Statement:
The pre-placed blocks draw an intersection with stop signs and move the robots to the stop signs. Robot 1 should turn right and robot 2 should go straight through the intersection.

		
Time