|
Valkyrie 2026
|
#include <valkyrie/drivetrain/swerve/SwerveModule.h>
Public Member Functions | |
| SwerveModule (std::unique_ptr< BaseController > azimuthMotor, std::unique_ptr< BaseController > driveMotor, units::meter_t wheelDiameter, frc::sim::DCMotorSim driveSim, frc::sim::DCMotorSim azimuthSim) | |
| frc::SwerveModuleState | GetState () const |
| frc::SwerveModulePosition | GetPosition () const |
| units::meters_per_second_t | GetMaxSpeed () const |
| void | ApplyRequest (requests::ApplyState) |
| BaseController & | GetDriveMotor () const |
| BaseController & | GetAzimuthMotor () const |
| void | Reset () |
| void | LoggablePeriodic () override |
| Periodic callback for logging updates. | |
| void | SimulationPeriodic () |
| Public Member Functions inherited from valor::Loggable | |
| Loggable (std::string_view name) | |
| Construct a Loggable that registers a top-level table name. | |
| Loggable (std::shared_ptr< nt::NetworkTable > table) | |
| Construct a Loggable that uses an existing NetworkTable. | |
| Loggable () | |
| Default construct an uninitialized Loggable. | |
| void | LogChild (std::string_view name, Loggable *child) |
| Register a child Loggable under a named subtree. | |
| void | LogChild (std::string_view name, wpi::Sendable *child) |
| Register a child Sendable under a named subtree. | |
| void | SetPeriodicLevel (LogLevel level) |
| Set the logging level for LoggablePeriodic. | |
| template<typename T> | |
| T | WriteLog (std::string_view field, const T &data, LogLevel level=LogLevel::Normal) |
| Publish a value to NetworkTables under the given field. | |
| template<typename T> | |
| T | ReadLog (std::string_view field, const T &defaultValue={}) |
| Read a value from NetworkTables for the given field. | |
| template<> | |
| decltype(Loggable::subscribers) ::iterator | addSubscriber (std::string_view field, const std::vector< bool > &defaultValue) |
| template<> | |
| void | WriteLogImpl (nt::Publisher *pub, const std::vector< bool > &data) |
| template<> | |
| std::vector< bool > | ReadLogImpl (nt::Subscriber *sub) |
Additional Inherited Members | |
| Static Public Member Functions inherited from valor::Loggable | |
| static units::millisecond_t | GetLoggingTime () |
| static constexpr Loggable & | GetRoot () |
| Protected Member Functions inherited from valor::Loggable | |
| virtual void | OnLoggingStart () |
| Hook invoked when logging is started for this object. | |
|
overridevirtual |
Periodic callback for logging updates.
If a derived class needs to perform periodic updates to published values, override this method. It is intended to be called by the logging framework; this base class provides an empty implementation.
Reimplemented from valor::Loggable.