- :-

Topics Covered

  • Wait Block
  • Touch Sensor
    (Wait for Pressed)
  • Lesson Links

    Check Your Understanding:
    1. 1. What does the robot do when the WaitTouch program runs?
    2. Runs continuously until the Touch Sensor is pressed in
      Waits for 1 second, then moves 1 rotation
      Waits for the Touch Sensor to be pressed in, then moves 1 rotation
      Runs for 1 rotation
    3. 2. The program waits BEFORE it moves because...
    4. The Wait Block comes first in the program
      The Wait Block always takes priority over Move Blocks
    Try It!
    Try it! 1

    Already Pressed

    What happens if you’re already holding down the Touch Sensor’s button when you start running the program?
    What happens?

    The robot moves immediately. The Wait Block detects that the sensor is
    “Pressed” and passes control to the Move Block.

    “Pressed” simply means “the button is in the pressed position”; it does not
    matter how or when it was pressed in!

    Try it! 2

    EV3 Buttons

    The 5 buttons on the front of the EV3 (not counting the Cancel button) can be used as Touch Sensors!
    Try changing the Mode of the Wait Block to “Brick Buttons > Compare > Brick Buttons”
    and running your program.

    Once it’s running, press the middle button on the front of the EV3!

    What happens?

    The Wait Block now waits for the middle button on the EV3 to be pressed.
    The robot then moves.

    Did You Know?

    Did you know?

    How the Touch Sensor Works
    When the Touch Sensor is pressed, it closes an electrical circuit, allowing current to flow.
    If the Touch Sensor is released, the circuit is broken and no current flows.

    The flow (or lack) of current is detected by the EV3, allowing it to determine the Touch Sensor is pressed.