WPILibC++ 2024.3.2
frc::sysid::SysIdRoutineLog Class Reference

Utility for logging data from a SysId test routine. More...

#include <frc/sysid/SysIdRoutineLog.h>

Inheritance diagram for frc::sysid::SysIdRoutineLog:
frc2::sysid::SysIdRoutine

Classes

class  MotorLog
 Logs data from a single motor during a SysIdRoutine. More...
 

Public Member Functions

 SysIdRoutineLog (std::string_view logName)
 Create a new logging utility for a SysId test routine. More...
 
void RecordState (State state)
 Records the current state of the SysId test routine. More...
 
MotorLog Motor (std::string_view motorName)
 Log data from a motor during a SysId routine. More...
 

Static Public Member Functions

static std::string StateEnumToString (State state)
 

Detailed Description

Utility for logging data from a SysId test routine.

Each complete routine (quasistatic and dynamic, forward and reverse) should have its own SysIdRoutineLog instance, with a unique log name.

Constructor & Destructor Documentation

◆ SysIdRoutineLog()

frc::sysid::SysIdRoutineLog::SysIdRoutineLog ( std::string_view  logName)
explicit

Create a new logging utility for a SysId test routine.

Parameters
logNameThe name for the test routine in the log. Should be unique between complete test routines (quasistatic and dynamic, forward and reverse). The current state of this test (e.g. "quasistatic-forward") will appear in WPILog under the "sysid-test-state-logName" entry.

Member Function Documentation

◆ Motor()

MotorLog frc::sysid::SysIdRoutineLog::Motor ( std::string_view  motorName)

Log data from a motor during a SysId routine.

Parameters
motorNameThe name of the motor.
Returns
Handle with chainable callbacks to log individual data fields.

◆ RecordState()

void frc::sysid::SysIdRoutineLog::RecordState ( State  state)

Records the current state of the SysId test routine.

Should be called once per iteration during tests with the type of the current test, and once upon test end with state none.

Parameters
stateThe current state of the SysId test routine.

◆ StateEnumToString()

static std::string frc::sysid::SysIdRoutineLog::StateEnumToString ( State  state)
static

The documentation for this class was generated from the following file: