Motor Rotation Sensor - Switch Block Pro Preview

We already know how to use the rotation sensor. Now it’s time to explore more of its functions.

To access the full video please subscribe to FLLCasts.com

Subscribe

  • #1131
  • 24 Feb 2019

The rotation sensor, just like any other sensor, has its own setting in the switch block.


As you can see, the switch block has only one mode – compare. If you drag your mouse over the compare mode, you will see there are three sub-modes there:

  •  Degrees The robot compares the number of degrees the motor has rotated to a value, which is 90 by default. The block checks whether this comparison evaluates to true and depending on the result it performs the corresponding commands.

 

  •  Rotations The robot compares the number of rotations the motor has made to a value, which is 1 by default. The block checks whether this comparison evaluates to true and depending on the result it performs the corresponding commands.

 

  • Current Power  The robot compares the current power at which the motor rotates to a value, which is 50 by default. The block checks whether this comparison evaluates to true and depending on the result it performs the corresponding commands.

 

Unlike the other sensors, the rotation sensor is not connected to ports 1 to 4. As the sensor is located inside motors, the ports where it should connect are from A to D, port A by default. Always check whether the sensor is connected to the correct port.

Courses and lessons with this Tutorial

This Tutorial is used in the following courses and lessons

Image for Level D1. "Animals". Robotics with LEGO
  • 23
  • 0:00
  • 102
Image for Lesson 3 - Scorpion
  • 3
  • 5
  • 13
  • 3d_rotation 1
Image for Robotics with LEGO - Level 4.0 - Kinesthetic and Memory Game (in development)
  • 59
  • 2:58
  • 200
Image for Remember how to work with the rotation sensor
  • 3
  • 0
  • 0
  • 3d_rotation 0
Image for Robotics with LEGO - Level 2.5 - Maritime Journey
  • 42
  • 3:52
  • 133