2022-Robot
Robot code for 2022 FRC Season by Argos, FRC team #1756
Loading...
Searching...
No Matches
argos_lib::swerve::SwerveHomeStorageInterface Class Referenceabstract

Interface capable of saving and loading module home positions from persistent storage. More...

#include <swerve_utils.h>

Inheritance diagram for argos_lib::swerve::SwerveHomeStorageInterface:
FileSystemHomingStorage argos_lib::swerve::NetworkTablesHomingStorage

Public Member Functions

virtual bool Save (const SwerveModulePositions &homePosition)=0
 Save home position to persistent storage. More...
 
virtual std::optional< SwerveModulePositionsLoad ()=0
 Load home position from persistent storage. More...
 

Detailed Description

Interface capable of saving and loading module home positions from persistent storage.

Member Function Documentation

◆ Load()

virtual std::optional< SwerveModulePositions > argos_lib::swerve::SwerveHomeStorageInterface::Load ( )
pure virtual

Load home position from persistent storage.

Returns
Poisitions from persistent storage or std::nullopt if load failed or no positions were previously stored

Implemented in argos_lib::swerve::NetworkTablesHomingStorage, and FileSystemHomingStorage.

◆ Save()

virtual bool argos_lib::swerve::SwerveHomeStorageInterface::Save ( const SwerveModulePositions homePosition)
pure virtual

Save home position to persistent storage.

Parameters
homePositionPositions to store
Returns
true Save successful
false Error saving

Implemented in argos_lib::swerve::NetworkTablesHomingStorage, and FileSystemHomingStorage.


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