Coding Project 5 — Learning to Turn
KIPR · Botball Explorer
Activity Sections

Introductory · SPIKE Coding Project 5

Learning to Turn

Two knobs, three shapes — and your first drive to somewhere that isn't straight ahead.

Project
Coding Project 5
Strand
Coding
Phase
Make It Move
Time
One class period
What You Are Doing
Finding out how a robot turns, learning the three shapes a turn can have, and driving from your starting box to the spilled cubes.
Mission Anchor
Mission 12 — Restack the Freight (approach only — you will finish it in Project 8)
What You Need
Before You Start
Project 4 — you need your straight-driving steering value and your starting position method.
Before you start: type your PIN in the box at the top of the page. Your teacher gave you this number. When you finish, press Download to save a local copy of your answers. This does not turn in your work automatically; give the downloaded file to your teacher.

Try It — Break the Straight Line

In Project 4 you worked hard to make your robot drive straight. Now you are going to ruin it on purpose — and pay close attention while you do.

Start a new project called Turns. Build one single move block — move (steering) for 24 in. — and keep the distance the same for every single run.

Then change only the steering dial. Set it to each value below, run it, and describe the path the robot took.

⚠ Floor, Not Table

These runs go in circles and curves. Do this on an open floor with nothing in the way — not on a table, not on the field.

Steering valueWhat path did the robot take?
0
10
25
40
50
65
85
100

What did your data tell you?

Fill in the blanks from your own runs:

When the steering number is…The robot…
close to 0
getting bigger
exactly 50
all the way at 100

In Project 3 you predicted what the robot would do when both motors got the same arrow. Somewhere in this table, exactly that happened to the wheels. Which steering value was it — and were you right?

Learn It — Two Knobs, Three Shapes

You only have two things to adjust, and they do completely different jobs.

Code / partWhat it means
the steering dialSets the shape of the path. One number decides whether the robot goes straight, curves gently, curves hard, or spins on the spot.
the amountSets how far along that path the robot travels — inches or degrees. It does not change the shape at all, only how much of it you get.

The Two Rules You Just Discovered

The closer the steering is to 0, the straighter the robot goes.

The bigger the number, the sharper the curve.

Everything else in this project is those two sentences applied on purpose.

The three shapes

TurnWhat it meansSteering
Both wheels go the same direction at different speeds. The robot sweeps a wide arc, like a car going around a bend. Sharpness comes from how big the steering number is.steering / 1 to 49
One wheel drives, the other sits still. The robot swings around the stopped wheel — like ring around the rosie. More speed means a faster swing, not a tighter one.steering / exactly 50
The wheels go opposite directions. The robot spins in place without moving forward or backward at all. Also called a pivot or spin turn. This is what you use for precise angles.steering / all the way: 100

Friction Matters More Than You Think

Two moving wheels fight friction better than one moving wheel does. A asks a stopped wheel to skid sideways, so it is the least repeatable of the three. If a turn will not come out the same twice, try the same turn as zero radius instead.

New Number Alert: Degrees on a Move Block

When you set a move block’s unit to degrees, it counts how far the wheels turn — not how far the robot turns. Spin at steering 100 for 90 degrees and the robot turns far less than a right angle, because each wheel only rolled a quarter of the way around.

Nobody can work out the right number from their chair. You find your robot’s 90° the same way you found your distances: test, nudge, test again.

One more dial fact: steering works on both sides. Positive numbers turn right, negative numbers turn left — a spin to the left is steering −100.

Where you are headed

Watch Mission 12 video

Base Mission

11 points Live judged

Two spilled cubes form a scoring stack — one spilled cube is another spilled cube. Both cubes must originate from the spilled cube area. Edge-to-face or corner-to-face contact does not satisfy this definition for Mission 12.

Bonus Mission

5 points Final judged

The scoring stack remains intact and the lower cube of the stack is touching the black line.

Scores

  • One spilled cube is another spilled cube.
  • A robot is supporting one or both cubes while the relationship exists.
  • The scoring stack exists and the lower cube is touching the black line.

Does Not Score

  • Two spilled cubes touching side-by-side.
  • A spilled cube stacked on a cube that did not originate from the spilled cube area.
  • The stack no longer exists at final scoring.
  • The upper cube is touching black line but the lower cube is not.

Do It — Learn to Aim

Step 1 — Drive a big circle

New project called Circles. Put a chair in the middle of an open floor.

Write a program that drives your robot in one big circle all the way around the chair, without it. Use one single move block — no stopping and restarting.

Steering valueDistance (in.)

Step 2 — Drive a tight circle

Swap the chair for something small — a tissue box works. Circle that instead, same rule: one set of commands.

Steering valueDistance (in.)

Compare your two sets of numbers. What did you change to make the circle smaller?

Step 3 — Try all three shapes

Run each one and record what the robot actually does.

Turn typeMy steeringWhat it did
Radius
One-wheel
Zero radius

Which of the three moved the robot the least distance across the floor? Why does that matter on a crowded field?

Step 4 — Build a 90° turn

New project called Right Angle. Use a zero radius turn — steering 100 — and find the degrees value that gives you a true 90° robot turn.

Keep the steering at 100 the whole time. Change only the degrees.

TryDegreesToo far, not far enough, or right?
1
2
3
4
5

Test One Step at a Time

Get the turn right on its own before you attach it to anything else. one command is easy. a whole run to find out which command was wrong is not.

Step 5 — Prove it with a square

Here is the honest test of a 90° turn: do it four times and see if you end up where you started, facing the way you started.

Drive forward, turn 90°. Repeat four times total.

If your robot did not close the square, was each turn too much or too little? How could you tell?

A small error in one turn becomes a big error after four. This is why turning by wheel-count alone is hard — and why Project 11 hands you a sensor that can feel the robot itself turning.

Step 6 — Drive to the spilled cubes

Onto the field. New project called Approach 12.

Start in your starting box, exactly the way you decided in Project 4. Drive out, turn, and stop next to the spilled cube area — close enough and square enough that a claw could pick a cube up.

Write your plan as first:

Code / partWhat it means
1. Drive forwardOut of the starting box.
2. TurnToward the spilled cubes.
3. Drive up to themClose enough to work from.
4. StopSquare to the cubes.
MoveSteeringAmountUnit (in. or deg)
Forward
Turn
Approach

Step 7 — Run it five times

Same rule as Project 4. One good approach is luck.

RunDid it arrive in a position a claw could work from?
1
2
3
4
5
Which part of the run was least reliable — the drive out, the turn, or the final approach?

Score It — Checkpoint

No points yet — Mission 12 does not score until something gets stacked. What you have built is the half of the mission that has to work before the other half matters.

My turning numbers

Every project from here uses these. Write them down properly.

SettingValue
— steering value
Degrees for a 90° turn
Degrees for a 180° turn
Degrees for a 45° turn

You worked out 90° by testing. Did doubling it give you a good 180°? Did halving it give you a good 45°?

Match the turn to the job

The robot needs to…Which turn type?
Face the other way without leaving its spot
Curve around a cone while still moving down the field
Swing its front end around a cube it is already beside
Make a small heading correction while driving straight

Can you do it again?

Think about it

Your square test almost certainly did not close perfectly. Where did the error come from — was the robot doing the wrong thing, or was your program asking for something it cannot deliver?

A teammate’s robot turns 90° perfectly on the carpet but s on the field mat. Nothing in the program changed. What happened?

You now have a robot that gets to the right place and points the right way. What is the next thing it needs before Mission 12 can actually score?

Next

In Project 6 — Bulldoze Run, you put driving and turning together to score four missions at once — and you do it all without a claw, by pushing.

Download saves a local copy of your answers. It does not turn in your work automatically; give the downloaded file to your teacher.

KIPR · Botball Explorer — Introductory Projects · © KISS Institute for Practical Robotics 1997–2026