Recordings
The Recordings tab replays what the robot did, after the fact. It works like Simulate Robot: the field, the subsystems, the motors, the camera and the loop timings, all moved by one timeline, with Play.

What it lists
The list shows the robot project's recordings folder, TeamCode/recordings/, newest first. It holds two kinds of file:
- Sessions the robot recorded (
.jsonl.gz). An autonomous or TeleOp that records writes everything it does from Start until it stops, whether or not a laptop is connected, so a match can be replayed as well as practice. The robot writes them uncompressed, so it spends nothing compressing while it runs, and Sync compresses each as it brings it back. The list shows when each one started, its OpMode, whether it was an autonomous or a TeleOp, and its alliance. - Captures saved from Live Robot (
.jsonl.gz). Save Log… on the Live Robot tab saves to this folder. Older.jsoncaptures and event logs still open with Replay.
The folder has its own .gitignore, so recordings never show up as changes in git: they are your own data, not the robot's code.
A recording made with a prefix, such as practice, shows it in the Prefix column, and its file name starts with it. Show lists one prefix at a time, so practice recordings and a competition's are kept apart: No prefix lists the ones made without one.
The list is read again each time you open the tab, and when you click Refresh. Open Folder shows the folder on your computer. Delete… deletes the chosen recording from this computer.
Replaying one
Click a recording to replay it from its start. Drag the playhead along the timeline, or press Play (the button beside it sets the speed).
The timeline shows the whole session as a thin strip along its top, named after the autonomous routine it ran or else Autonomous or TeleOp; point at it to read the name. Commands are coloured by their subsystems, as in Simulate Robot. A moment the robot code marked with mark("…") shows as a thin bar of its own.
With library 0.21.8 or later on the robot, a script started from Live Robot's Run row shows each of its steps as a bar, with marks where a gamepad command took it over or a condition couldn't read its value, as a capture saved in Live Robot does. A condition problem is recorded even with no laptop connected. Point at a bar to read it.
With library 0.21.10 or later, each command the robot ran is a bar too, as on Live Robot's timeline: each step of the autonomous routine and of what a gamepad button ran, and each script a camera zone started. Point at one to see what started it, such as gamepad1 BACK press.
The line above the field says how many samples the recording holds and over how long. It also says when something went wrong while recording:
- It ends early: the robot was switched off, or the OpMode was killed, before the recording was finished. It holds everything written until then.
- The hub ran out of room for it: the recording reached its share of the Control Hub's storage and stopped recording samples.
- Samples were not written in time: the robot made samples faster than it could save them. Lower
samplesPerSecondif this happens often.
Routines checked in the Overlays list are drawn beside the recording, as on the other field tabs.
Find in the field's corner lists the robot, its devices, what its cameras saw at this moment and the planned paths, to find one and ring it on the field (see Find something on the field).
Loop timing

With library 0.21.21 or later, a recording holds the timing of every loop the robot ran, laptop or none. The Timings tab charts each loop as Live Robot's does (Check loop timing), so a match's slow loops can be found after it. Its Recording a sample part is the loop's own share of recording. The file is written on a thread of its own, and the line above the chart says how long that took in all, its slowest write and how often it saved to storage. An OpMode that doesn't record, with no laptop connected, does no timing at all.
How closely it followed its paths

With library 0.28.47 or later, a recording holds where the drive's plan said the robot should be at every moment. The Tracking tab lists each path and drive-to the robot ran: how far it was from the plan on average, the furthest it was behind and ahead along the path, the furthest to the side and the largest heading error, with the likely cause and the setting to change. Choosing a row moves the replay to that run and charts its error over time, tinted where the plan was speeding up, slowing down or holding still. While the Tracking tab shows, the recordings list collapses to a strip at the left to give the report the width, and opens again when another tab shows. Above the table, the feedforward and PID gains the run used, and how many paths showed each cause.
A cause that says to smooth the path is about how the path is drawn, not the tuning. An older recording has no plan in it, and the tab says so.
Calibrate the simulator from recordings
Recordings of real matches show how each motor really responds to its power, so they can correct the simulator. From the Robot Designer folder, run:
.venv/bin/python -m calibration /path/to/TeamCode --prefix competition1
It fits every motor of the active robot design whose speed the recordings read, and the drive as a whole from how fast the robot moved, then writes the corrections into TeamCode/robot_designs/calibrations.json. The simulator builds those motors and the drive from them (library 0.21.22 or later). Add --dry-run to see the fit without writing it.
- Pick the recordings by prefix: the matches you want to fit together, for example one competition's.
- A motor's speed that follows another motor's power is named in the output: its encoder cable may be in the other motor's port. If it is, fit again with
--encoder MOTOR=READER(eachsubsystem/motor), meaning MOTOR's encoder shows up in READER's report, and swap the cables back on the robot. - Each entry says how well it fits, in its
why, and what it was fitted to. A fit can only average what happened: an intake that drags balls some of the time and runs free the rest follows its recording less closely than a flywheel does. - The drive is fitted in the robot's own frame. Each sample's
poseEstimationsays which frame itsvelocityX/velocityYare in (velocityFrame): a robot-frame velocity is used as it is, and a field-frame one is turned by the heading. A recording that doesn't say, from an older library or an odometry that reportsUNKNOWN, is taken to be in the field's frame; the output says how many, and the drive'swhyand its measurement (velocity_frame_assumed) name them. - The drive is fitted as the simulator replays it: from its wheels' own speeds, not a hub's 50 ms average of them, braking or coasting at no power, whichever matches the robot better (
zero_power). A design that doesn't place the four wheels and give each a speed and a wheel size isn't fitted; the output says what it leaves out. - Each entry records the hardware it was fitted on: a motor's free speed (
free_rpm) and the drive wheels' top speed (free_mps), from the design. Change a motor's gearing or the drive's wheels in the design and the simulator stops applying that correction, builds the motor from its datasheet, and prints that it needs refitting; fit again from recordings of the new hardware. - Fitting again with the same prefix replaces that fit, and keeps everything else in the file.
Calibrate the drive from a test drive


The Drive Train page's Tuning tab works from one recording, the test drive, shown in step 1. It is the newest recording whose drive followed paths, unless you press Choose… to pin another; the pin lasts until a newer test drive arrives. Open shows it on the Recordings tab.
Step 2's Calibrate fits the drive's feedforward at once to the test drive and the earlier recordings of the same test (odometry_test1 and odometry_test2 are one test), and shows kS, kV, kA and the strafe efficiency beside what the project has now, and says Calibration settled when every value is within 5% of the current calibration. Under them, Suggested gains lists starting values for the path-following P gains (x/y and heading) beside the drive's own: the loop is modelled from the fit's time constants and the loop period the recordings report, and P is chosen for a 50° phase margin. A run whose turns overshoot more than that predicts, or whose paths wobble, asks for more margin; a run that stops short asks for a small I in a narrow zone. A gain within 10% of the current one says Keep; D stays 0, because odometry noise makes it jumpy. Point at a row for its reason. Change recordings… opens a table of recordings, sortable and filterable by name, OpMode, start, what the drive did (Paths, Driven or —) and whether the current calibration was fitted from them; Find current checks those. Save Calibration writes only the drive entry of calibrations.json, with the recordings, the day they were made and the suggested gains (suggested_gains), and leaves every other entry as it was.
Step 3 Fill has three sources, under Fill from: Calibration (the feedforward), Gains (the suggested PID) and Robot. Each fill is one step to undo.
The five steps are five equal cells, each with its name, one word for its state (Next, Done or a dash while it waits) and its buttons; point at a cell for the details, such as the recording or what the calibration was fitted from. The next step is outlined, and the line under the cells says in full what to do and has the button that does it, for example "Next: Fill from calibration". The order is: choose a test drive; calibrate from this drive; fill the feedforward, then the suggested gains; sync; run the test drive again once the form holds PID or feedforward values it wasn't run with, or the drive's motion settings changed after it was recorded; then compare. What was just done leads the line: "Calibration saved. Next: Fill from calibration", "Filled. Next: Sync", "Synced. Next: run the test drive on the robot with the new values, then Sync".
Step 5 Compare opens the test drive's tracking report. The report marks every move with a tick (on target), a dash (close, within 1.5 times the target) or a cross (off): a path should average 2 cm or less off the plan, never be more than 5 cm behind or ahead, and keep its heading within 3°, and every move should end within the drive's arrival distance; a turn should overshoot by 5° or less and end within 1°. The summary is one line, how many paths and turns were on target and whether the last change has settled, and one bold line of what to do next; point at the first for the causes and the marks. Run history charts the runs of the same test: each run's average and worst distance off the plan and its turn overshoot, a dashed line where the settings changed, and a shaded band where runs with the same settings differ from each other, the run-to-run spread. It starts closed and stays as you leave it. A change that moved the average by less than that spread, or by less than 0.3 cm while the spread is not known yet, is called settled; run a test once more with the same settings to measure the spread.
See how closely the simulator follows the robot
.venv/bin/python -m calibration /path/to/TeamCode --prefix competition1 --compare
This fits nothing. It gives the simulator's motors, built from the corrections already in calibrations.json, the power and battery every sample of the recordings held, and compares their speeds with what the robot read. For each motor and recording it prints:
- rms: how far off it is overall.
- bias: whether it runs fast (+) or slow (−) on the whole.
- worst 2 s: the stretch where it is furthest off, and when.
For the drive it also starts the simulated robot where the real one was and drives it 5 s on the recorded wheel powers: how far apart the two end up, typically and at worst, in metres and degrees. A small error in turning becomes a large one in where the robot ends up, so this is the drive's hardest test.
Each fit also stores how closely its motor followed every sample (replay_rms_rpm, replay_rms_mps). The robot's FittedCalibrationsReplayTest (checkStudentContent) replays the same recordings through the simulator's own motors and fails if they follow less closely than that.
Bringing recordings back from the robot
Click Sync with the robot connected. After copying your files to the robot, Sync brings back every finished recording, deletes it from the robot, and this tab lists it. See Connecting to the robot, "What Sync brings back".
To get the recordings onto more than one computer, turn off Delete from the robot once copied, under the list, on every computer but the last to sync. Each of those copies the recordings and leaves them on the robot; the last one, with it on, copies them too and clears them from the robot. Each computer remembers its own choice, and none copies a recording it already has.
Making the robot record
Recording on the robot, under the list, sets what the active robot records. Each change is saved at once to the robot's recording.json, beside its design, and Sync copies it to the robot. It takes effect the next time an OpMode is initialized.
- Autonomous and TeleOp: Record or Don't record every OpMode of that kind.
- Keep: how many recordings the robot keeps, and how much of its storage they may take. When an OpMode starts recording, the robot deletes its oldest recordings to stay within both. Sync empties the robot's recordings anyway, so these only matter between Syncs.
- Samples a second: how often the robot records what it is doing. Fewer make smaller files.
- Prefix: what each recording's name starts with, such as
practiceorregionals. Set one before a practice and clear it, or set another, before a competition: Show above the list then lists each set of recordings on its own.
A recording starts at Start and ends when the OpMode stops. The Driver Station shows Recording during Init when the OpMode will record. The library's opmodes.md, "Recording sessions", has the details for robot code.