Plug the main board, motors and 1 switch block into your baseboard like the picture. You can click on the picture to zoom in.
Plug in the cables like the picture - the switch block should be plugged into P0, the left motor to M1, and the right motor to M2.
Plug in your micro:bit with the USB Cable, and transfer the program you have just downloaded.
Before we can test the robot, we need to build a maze! Make sure it has straight walls that are around 25cm apart, like the picture. You can use cardboard, wooden blocks, boxes, books - anything really! If you don't have much to hand, you can just make a simple right or left turn to test with for now.
Test your robot in the maze - it should use the switch to detect when it hits a wall, and then turn around to try and find another way. Can you see how the program works? You might need to change the turn_time number at the top to make your robot turn exactly 90 degrees.
Let's add another switch to see if we can get through the maze faster - put another switch block on the back of the robot like the picture, and plug it into P1.
For advanced inventors - can you change the program so that it uses both switches to get through the maze faster?