By default, the motors of the LEGO SPIKE Prime controller connect to ports A and B. What if we want to connect them to other ports? Here's how to change ports in the software.

To access the full video please subscribe to FLLCasts.com
- #2015
- 01 Jul 2022
The block we use to change the ports of the movement motors in the software is in the second-to-last place in the Movement palette. It is called set movement motors to.
The block has one parameter which sets the ports of the two drive motors.
Once we have set the correct ports, our robot will use the new ports as drive motors. Thus, all blocks from the Movement palette will move these two motors.
That block can also be used to reverse the ports, which can be useful if you program the robot to move forward but it still moves backward.
Courses and lessons with this Tutorial
This Tutorial is used in the following courses and lessons

Level A1 - Space Adventure - Robotics with LEGO SPIKE Prime
That is the first level of the LEGO robotics curriculum for second, third, and fourth-grade students.
A "space adventure" but with robots. Different robot structures are built in Level A1. The motors are controlled so that the robots perform precise movements around the "Earth", "Moon" and "Sun". We use the force sensor to overcome various obstacles we bump into. We learn interesting facts about the solar system and space vehicles.
- 64
- 30:30
- 76

Lesson 2 - Tidal waves
Introduction
Today, we will focus on an interesting effect caused by the Moon: tidal waves.
You may know that massive bodies have an attractive force - gravity. The Moon's gravity pulls the water in the oceans, which causes the sea level along the ocean coasts to temporarily rise or fall. The increased level is called high tide, and the decreased level is called low tide.
How much, do you think, can the difference between high and low tide be in the world?
The distance between high tide and low tide sea levels can reach up to 16 meters in the Bay of Fundy in Canada, and the lowest differences are in the Mediterranean, Baltic, and Black Seas, where they are only a few centimeters. We will use 50 cm as an average value as it is convenient for the task.
- 10
- 5
- 12
- 3d_rotation 1