Turn Motor Off
turn motor off::wedo
Category LEGO WeDo
Type Stack
Introduced in 1.4

The Turn () Off block is a LEGO WeDo block and a Stack block. The block stops a LEGO WeDo motor.

Prior to Scratch 2.0, this block was named Motor Off, and in Scratch 2.0 it was called Turn Motor Off.

Example Uses

Not much can be done with the Lego WeDo robotics kit if the motor cannot be turned off.

Some example uses are:

  • Stopping a vehicle

when green flag clicked
set [gas tank v] to [full]
wait until <(gas tank)=[empty]>
turn motor off::extension
say [Oh no! My car's all out of gas!] for (5) secs

When I receive [Rollercoaster v]
reset timer
repeat until<(timer)>[60]>
wait (3) secs
say (item [random v] of [Rollercoaster sayings v]
change [power v] by (-5)
set motor power (power)::extension
turn motor off::extension
say [That was a fun ride!]
  • Stopping a fan

when I receive [stop fan v]
say [I'm cold. I'm going to turn off the fan.]
glide (1) secs to x:([x position v] of [Fan v]) y:([y position v] of[Fan v]
turn motor off::extension

  • Stopping gears, therefore stopping a machine

when I receive [gear clog v]
set [brightness v] effect to (-30)
turn motor off::extension


Main article: List of Block Workarounds

This block can be replicated with the following code:

turn motor on for (0) secs::extension

Otherwise, this can be used:

set motor power (0)::extension

See Also