Before the robot is used
Safety: Paper and website only. Keep the .blk disabled and do not add motor outputs, call the sensor reference, or enable it as part of this lesson. It cannot protect another OpMode. No physical controls or live deployment are requested. Any later hardware integration needs separate review, verified mapping, synchronized pose/range, measured mounting, sensor health and uncertainty, and an independent raw collision guard.
Required hardware & dependencies
- Paper field drawing, ruler, calculator, and website; no robot required.
- Fictional example_distance reference only; no current Cookie Coders sensor, localization, or port configuration is proven.
Newly authored FieldGeometryBlocks.blk uses FTC SDK 12 native Lists, loops, comparisons, degree sin/cos, telemetry, and a native distance getter. This is not a controller-exported or hardware-tested program. No HashMap block or custom Java helper is claimed. The uncalled getter uses fictional example_distance; selecting even a disabled import may need that placeholder resolved. Generated Java does not inherit the .blk disabled metadata: do not install or enable a Java export. Use the website and paper traces only. Robot deployment is not part of this lesson.
Robot setup checklist
- Open the registered Code Lab lesson, source-linked Blocks, prediction reveals, full-program explorer, and quiz. Check the downloaded source remains disabled.
- Draw center (0,0), +X right, +Y up, headings 0/+90, and the fictional +/-72 edges and +/-12 fixture. Label all positions/ranges in inches and timestamps in milliseconds.
- Explain one-based record columns, unique keys, trusted map assumptions, capture-time pose, and sensor mount (forward 6,left 2,yaw 0). Never borrow an old team's configuration as evidence.
60-minute teaching sequence
- 0-10 min
Draw the centered field and distinguish a surface point from identity.
Look for: Signed axes and heading convention; fictional dimensions.
- 10-25 min
Build named records and paper-trace key lookup.
Look for: Map abstraction versus hash table; missing/duplicate stays unknown.
- 25-40 min
Work default, rotated, yaw, and wall surface projections.
Look for: Mount translation rotation precedes range; degrees and capture-time pose.
- 40-50 min
Trace stale, corner, and near-wall obstacle cases.
Look for: Unknown evidence, imperfect association, raw safety preserved.
- 50-60 min
Quiz, reset, and exit ticket.
Look for: Possible obstacle is not robot identity or center.
Observation notebook
Paper trace: centered surface estimates and candidate evidence| Pose X,Y / h | Range / mount yaw | Sensor face | Surface hit | Classification / raw input |
|---|
| 12,-24 / 0 deg | 30 in / 0 deg | 18,-22 | 48,-22 | Possible robot or obstacle / 30 in retained |
|---|
| -24,12 / 90 deg | 30 in / 0 deg | -26,18 | -26,48 | Possible robot or obstacle / 30 in retained |
|---|
| 30,0 / 0 deg | 36 in / 0 deg | 36,2 | 72,2 | East wall consistent / 36 in retained |
|---|
| 0,0 / 0 deg | 30 in / 90 deg | 6,2 | 6,32 | Possible robot or obstacle / 30 in retained |
|---|
| Valid pose; age 150 ms | 30 in | Not used | UNKNOWN | UNKNOWN / raw 30 in retained |
|---|
Default forward/left mounting is 6/2 inches. Coordinates are surface points, not robot centers. Paper flags and tolerances are not hardware validation or measured accuracy.
Troubleshooting · stop before investigating
- Hit is off by six inches or has the wrong Y sign.
- Start range at the rotated sensor face; positive left adds +Y at heading 0.
- Yaw changes the mounting position.
- Rotate mounting by h only. Rotate the beam by h+yaw.
- A stale or ambiguous hit looks clear.
- Reset labels and coordinates each sample, verify all gates, and retain UNKNOWN when more than one geometry record matches.
- The Blocks editor asks for example_distance.
- It is a fictional uncalled reference, not verified hardware. Stay with the website/paper lesson; do not guess a port or enable the import.
Exit ticket & assessment
- Compute default surface hit and a +90-degree rotated hit.
- Explain map versus hash table and missing/duplicate keys.
- Name what is needed to confirm robot identity, and why known walls still reach raw collision protection.
Assessment: Look for correct centered-frame mounting math, honest list-map terminology, unknown-preserving decisions, and clear separation of surface association, semantic identity, and collision safety.
Extension challenge: On paper, draw a finite-width beam and an obstacle in front of a wall. Explain why a 2D endpoint rectangle match is insufficient and what first-intersection, uncertainty, repeated-observation, and vision evidence would add. Do not implement motion.
Teacher key · discuss after students predict
Default and rotated traces
Default sensor (18,-22), hit (48,-22). Rotated sensor (-26,18), hit (-26,48). Neither identifies a robot or its center.
Wall and corner traces
(72,2) matches east only; (72,72) matches east and north and remains UNKNOWN. Inclusive tolerance includes boundary equality.
Unknown and raw safety
Failed gates erase the old hit. Geometry association never removes raw range; a separate reviewed guard is needed to affect actual motor outputs.