Coolest Projects 2019 post 3

Coolest Projects 2019 post 3

Lots of work done today!

He started by loading his code from the last session. Here's his code plan. He wanted the robot to go forwards, backwards, left then right at speed 25. The marks on the right are ticks to figure out which motors he needed to move.

and the code itself in MakeCode. He changed his mind and made the speed 50.

The stop was added later!

A talk through from David:

Next he got working on the radio code. The robot will be controlled by a steering wheel. Code plan!

The numbers are what is sent from the steering wheel to the robot.
2 = Left
1 = Right
4 = Forwards (button A)
6 = Backwards (button B)

And again, later he added stop! Button A + B pressed together sends the number 12, which is stop.

Steering Wheel Code:

Robot code amended to include the radio. I was really impressed with David here. I made the first If statement and he duplicated it and changed it to create the rest of the code. He understood how everything worked and really enjoyed coding.


We added the b button press to figure out which motor is motor 1.

Talk through about the steering wheel:

And a demo of the two working together!
At the end he realises he doesn't have a stop

Lot of fun today! He really enjoyed it and was great at the coding. There's not much left to do. Tomorrow, we'll hopefully re-build the robot in acrylic and think about attaching the micro:bit to a steering wheel.

Then onto pedals!

Related Article