Ejemplo n.º 1
0
# Movement

m.forward(100)			# Move forward by 100 mm

m.back(100)

m.left(45)				# Turn left by 45 degrees

m.right(90)

# Pen Control

m.penup()					# Move the pen up

m.pendown()

# Sensors

colliding = m.collideState()		# may be left, right, both or none

# Other functions

m.beep(500)				# Beep for 500 mS (1/2 a second)

m.ping()					# Pings the mirobot for a response

Language

You can use any normal Python statements such as while, try, for, in, if else, return, and others.