Skip to main content

funnel_align()

Description#

Zumi will try to align to the funnel piece on the competition field (Click here for a PDF version).

Syntax#

funnel_align(speed=20, duration=1.0)
funnel_align(speed=20, duration=1, angle=None, angle_adj=2, l_th=100, r_th=100)

Parameters#

speed: Positive integer value for speed between 0 and 80
duration: Number of seconds Zumi will try to align to the funnel piece
angle: Heading or desired angle (Default to None which is Zumi's current heading)
angle_adj: The number of degrees Zumi will turn if one IR sensor detects white
l_th: threshold of the bottom left IR sensor
r_th: threshold of the bottom right IR sensor

Returns#

None

Example Code#
Python#
#Python code
from zumi.zumi import Zumi
zumi = Zumi()
zumi.funnel_align(speed=10,duration=3,angle_adj=1.1)