SET-03: DEFAULT_FROM_CATALOG, MEASURE and a part not in the catalog
- Your robot needs: any robot.
- Starter bots that fit: goBILDA starter bot, REV DUO starter bot, AndyMark Robits starter bot, Studica starter bot.
- Library version: v0.17.1 or newer.
- The docs it tests: Tunables.java: every number, part by part, Robot module (the robot in five files).
Why
A new robot's Tunables.java can name every setting from day one: DEFAULT_FROM_CATALOG for "use the library's default" and MEASURE for "a number to find on the robot". A motor or servo the catalog does not have can be described in Robot.java (Motors.custom, Parts.customServo). We want to know the INIT messages make clear what was used, where it came from and what to do next.
Safety
- Simulator only: nothing moves on a real robot.
Setup
- Your robot's five files, or
./gradlew :sim:newRobotfrom your configuration (it writes the words). import static com.crossbotics.ftchelper.robot.Starting.*;at the top ofTunables.java.
Steps
- Write
DEFAULT_FROM_CATALOGfor a few numbers (a launcher'skF, a lift'skP, a claw'stravelSec)../gradlew :sim:fromRobot, start the simulator, INIT. Write down each "defaults from ..." note. - Write
MEASUREfor one number (a lift'smax, or a claw position). INIT: write down the message. - Write
DEFAULT_FROM_CATALOGfor a lift'smax. INIT: write down the message. Put your number back. - In Robot.java, give one part a motor of your own:
Motors.custom("my-motor", 28, 5000)(or a servo:Parts.customServo("my-servo", 270, 0.16)).:sim:fromRobotagain: find its numbers in the robot file. INIT: write down its note. - Change it to
Motors.unknown("my-motor")on a lift's.part(...). INIT: write down the note.
Pass rule
Step 1 lists each value and where it came from; steps 2 and 3 stop INIT with a message that names the number and what to do (the tool for MEASURE, "a safety number" for step 3); step 4 shows the custom numbers in the robot file and "(custom)" in the note; step 5 says "general defaults" and how to do better.
Record
Write these down while you test. The report form has them as a list to fill in.
- each message, as shown
- anything in a message that was unclear, and what you did next
If your robot is different
No lift or launcher: use the parts you have (any Claw, Wrist, Hood, servo Turret or Indexer reads a travelSec-like time).
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 resultNo reports for this test yet: yours would be the first. Every test's reports.
Something wrong on this page? Tell us with a short GitHub form.