Odyssey represents robot trajectories as sequences of cubic Bézier curves chained together into aDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/saquer916/odyssey/llms.txt
Use this file to discover all available pages before exploring further.
Path. Each BezierCurve is defined by four Vector2d control points and a heading interpolator. Because the path geometry is stored independently of kinematic limits, you can redesign a trajectory’s speed profile at any time without touching the control points.
FTC field coordinate system
The FTC field is 3657.5 mm × 3657.5 mm. Odyssey works entirely in millimetres — everyVector2d you pass to a BezierCurve should use mm values. The origin is typically at one corner of the field; X increases toward the opposing wall and Y increases toward the far wall. Heading is in radians, measured counter-clockwise from the positive X axis.
Anatomy of a BezierCurve
| Parameter | Role |
|---|---|
p0 | Start point (curve passes through this) |
p1 | First handle (curve is pulled toward this) |
p2 | Second handle (curve is pulled toward this) |
p3 | End point (curve passes through this) |
headingInterpolator | Controls robot heading along the segment |
p0 and p3 exactly. The handles p1 and p2 never lie on the curve — they act as magnets that shape it.
Heading interpolators
Odyssey ships four interpolators that implement theHeadingInterpolator interface:
LinearInterpolator
Sweeps the heading linearly from
startHeading to endHeading as t goes from 0 to 1. Ideal for segments where you want the robot to rotate a known amount.ConstantInterpolator
Holds a fixed heading for the entire segment. Good for backing away while pointing at a target.
TangentInterpolator
Aligns the robot’s heading with the curve’s tangent direction at every point. Produces natural, forward-facing motion along the curve.
FaceTargetInterpolator
Continuously rotates the robot to face a fixed field point throughout the segment. Useful for keeping a camera or intake aimed at a game element.
Building a multi-segment path
A common FTC autonomous routine sweeps from the starting tile into a scoring zone, then backs away. Below, twoBezierCurve segments are chained into a single Path:
Path accepts any number of BezierCurve arguments via varargs and caches each segment’s arc length at construction time, so subsequent queries are fast.
Control point placement tips
Gentle sweeping curve
Place handles far from the endpoints — roughly one-third of the total segment length away. The curve bows out smoothly and the robot has time to accelerate and decelerate.
Tight corner
Place handles close to the endpoints. The curve approaches the corner more steeply and the heading change is concentrated near
p3.S-curve
Place
p1 on the same side as p0 and p2 on the opposite side relative to the chord. The curve inflects in the middle.Heading continuity at segment seams
When chaining segments, the robot’s heading at the end of segment N must equal its heading at the start of segment N+1, otherwise the follower will see a sudden heading discontinuity and issue a large corrective turn command.- If segment N uses
LinearInterpolator(start, end), make segment N+1 start withLinearInterpolator(end, ...)orConstantInterpolator(end). - If segment N uses
TangentInterpolator, computecurve.getTangentAngle(1.0)and use that value as the start heading of the next interpolator.
VelocityProfile is constructed after the Path, not inside it. This means you can swap in a different set of kinematic limits — maxVelocity, maxAcceleration, maxBrake, maxCentripetalAccel — and regenerate the speed profile without re-specifying any control points.