CTRE Phoenix 6 C++ 26.50.0-alpha-1
Loading...
Searching...
No Matches
ctre::phoenix6::configs::GyroTrimConfigs Class Reference

Configs to trim the Pigeon2's gyroscope. More...

#include <ctre/phoenix6/configs/GyroTrimConfigs.hpp>

Inheritance diagram for ctre::phoenix6::configs::GyroTrimConfigs:
ctre::phoenix6::configs::ParentConfiguration ctre::phoenix6::ISerializable

Public Member Functions

constexpr GyroTrimConfigs ()=default
constexpr GyroTrimConfigsWithGyroScalarX (wpi::units::scalar_t newGyroScalarX)
 Modifies this configuration's GyroScalarX parameter and returns itself for method-chaining and easier to use config API.
constexpr GyroTrimConfigsWithGyroScalarY (wpi::units::scalar_t newGyroScalarY)
 Modifies this configuration's GyroScalarY parameter and returns itself for method-chaining and easier to use config API.
constexpr GyroTrimConfigsWithGyroScalarZ (wpi::units::scalar_t newGyroScalarZ)
 Modifies this configuration's GyroScalarZ parameter and returns itself for method-chaining and easier to use config API.
std::string ToString () const override
std::string Serialize () const final
ctre::phoenix::StatusCode Deserialize (std::string const &to_deserialize) final

Public Attributes

wpi::units::scalar_t GyroScalarX = 0
 The gyro scalar component for the X axis.
wpi::units::scalar_t GyroScalarY = 0
 The gyro scalar component for the Y axis.
wpi::units::scalar_t GyroScalarZ = 0
 The gyro scalar component for the Z axis.

Detailed Description

Configs to trim the Pigeon2's gyroscope.

Pigeon2 allows the user to trim the gyroscope's sensitivity. While this isn't necessary for the Pigeon2, as it comes calibrated out-of-the-box, users can make use of this to make the Pigeon2 even more accurate for their application.

Constructor & Destructor Documentation

◆ GyroTrimConfigs()

ctre::phoenix6::configs::GyroTrimConfigs::GyroTrimConfigs ( )
constexprdefault

Member Function Documentation

◆ Deserialize()

ctre::phoenix::StatusCode ctre::phoenix6::configs::GyroTrimConfigs::Deserialize ( std::string const & to_deserialize)
finalvirtual

◆ Serialize()

std::string ctre::phoenix6::configs::GyroTrimConfigs::Serialize ( ) const
finalvirtual

◆ ToString()

std::string ctre::phoenix6::configs::GyroTrimConfigs::ToString ( ) const
overridevirtual

◆ WithGyroScalarX()

GyroTrimConfigs & ctre::phoenix6::configs::GyroTrimConfigs::WithGyroScalarX ( wpi::units::scalar_t newGyroScalarX)
inlineconstexpr

Modifies this configuration's GyroScalarX parameter and returns itself for method-chaining and easier to use config API.

The gyro scalar component for the X axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation
Parameters
newGyroScalarXParameter to modify
Returns
Itself

◆ WithGyroScalarY()

GyroTrimConfigs & ctre::phoenix6::configs::GyroTrimConfigs::WithGyroScalarY ( wpi::units::scalar_t newGyroScalarY)
inlineconstexpr

Modifies this configuration's GyroScalarY parameter and returns itself for method-chaining and easier to use config API.

The gyro scalar component for the Y axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation
Parameters
newGyroScalarYParameter to modify
Returns
Itself

◆ WithGyroScalarZ()

GyroTrimConfigs & ctre::phoenix6::configs::GyroTrimConfigs::WithGyroScalarZ ( wpi::units::scalar_t newGyroScalarZ)
inlineconstexpr

Modifies this configuration's GyroScalarZ parameter and returns itself for method-chaining and easier to use config API.

The gyro scalar component for the Z axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation
Parameters
newGyroScalarZParameter to modify
Returns
Itself

Member Data Documentation

◆ GyroScalarX

wpi::units::scalar_t ctre::phoenix6::configs::GyroTrimConfigs::GyroScalarX = 0

The gyro scalar component for the X axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation

◆ GyroScalarY

wpi::units::scalar_t ctre::phoenix6::configs::GyroTrimConfigs::GyroScalarY = 0

The gyro scalar component for the Y axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation

◆ GyroScalarZ

wpi::units::scalar_t ctre::phoenix6::configs::GyroTrimConfigs::GyroScalarZ = 0

The gyro scalar component for the Z axis.

  • Minimum Value: -180
  • Maximum Value: 180
  • Default Value: 0
  • Units: deg per rotation

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