Skip to content
Work in progress. This library and its docs are new and still changing, and some parts are not yet tested on a real robot. Something wrong or unclear?Tell us with a short GitHub form.

LGT-01: Lights - colour rules and a flash per shot

low prioritySimulator or real robotabout 20 minLights

Why

A light lets the drivers see the robot's state without looking at the Driver Station. The rules must pick the first true one, and the light must never change faster than 5 times a second (game rule R202 J).

Safety

  • Do not point bright lights at people's eyes or onto the field.

Setup

  • lights = add(Lights.gobilda("light")); or Lights.blinkin("blinkin") in Robot.java.
  • Rules in Controls.java, for example the five lines in lesson 9 section 13.
  • Simulator: the light is a dot on the robot.

Steps

  1. INIT: the light shows the alliance, not your rules (solid red or blue once it is chosen; LGT-02 tests that part). START: a 1 s flash of the alliance, then your rules.
  2. Make each rule true in turn (spin up, aim on, ...) and check the colour.
  3. Make two rules true at once: the one written first wins.
  4. Fire 3 pieces (fire(3) or hold RB): 3 white flashes.
  5. Wait for the last 20 s of TeleOp (or use a short match timer): yellow blinking.
  6. Film the blinking with a phone (slow motion): count changes per second.

Pass rule

Every colour matches its rule (all of them), 3 shots give 3 flashes, and the light changes at most 10 times a second (5 on and 5 off).

Record

Write these down while you test. The report form has them as a list to fill in.

  • light type (goBILDA RGB, REV Blinkin)
  • your rules (copy the lines)
  • any colour that was wrong (which rule, what it showed)
  • changes per second from the video

If your robot is different

Use your own rules; any true/false works. If a goBILDA colour looks wrong on your light, say which LightColor and what you saw.

Report your result

Pass, fail, or could not run: every result helps. The form opens on GitHub with this test filled in (a free GitHub account is needed). No student names, please.

Report result

No reports for this test yet: yours would be the first. Every test's reports.

All tests · Next: TUR-04 Slip-ring turret - round and round, always the short way

Something wrong on this page? Tell us with a short GitHub form.