CTRE Phoenix 6 C++ 25.0.0-beta-4
Loading...
Searching...
No Matches
ctre::phoenix6::configs::ToFParamsConfigs Class Reference

Configs that affect the ToF sensor. More...

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

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

Public Member Functions

constexpr ToFParamsConfigs ()=default
 
constexpr ToFParamsConfigsWithUpdateMode (signals::UpdateModeValue newUpdateMode)
 Modifies this configuration's UpdateMode parameter and returns itself for method-chaining and easier to use config API.
 
constexpr ToFParamsConfigsWithUpdateFrequency (units::frequency::hertz_t newUpdateFrequency)
 Modifies this configuration's UpdateFrequency parameter and returns itself for method-chaining and easier to use config API.
 
std::string ToString () const override
 
std::string Serialize () const override
 
ctre::phoenix::StatusCode Deserialize (const std::string &to_deserialize) override
 

Public Attributes

signals::UpdateModeValue UpdateMode = signals::UpdateModeValue::ShortRange100Hz
 Update mode of the CANrange.
 
units::frequency::hertz_t UpdateFrequency = 50_Hz
 Rate at which the CANrange will take measurements.
 

Detailed Description

Configs that affect the ToF sensor.

Includes Update mode and frequency

Constructor & Destructor Documentation

◆ ToFParamsConfigs()

constexpr ctre::phoenix6::configs::ToFParamsConfigs::ToFParamsConfigs ( )
constexprdefault

Member Function Documentation

◆ Deserialize()

ctre::phoenix::StatusCode ctre::phoenix6::configs::ToFParamsConfigs::Deserialize ( const std::string & to_deserialize)
inlineoverridevirtual

◆ Serialize()

std::string ctre::phoenix6::configs::ToFParamsConfigs::Serialize ( ) const
inlineoverridevirtual

◆ ToString()

std::string ctre::phoenix6::configs::ToFParamsConfigs::ToString ( ) const
inlineoverridevirtual

◆ WithUpdateFrequency()

constexpr ToFParamsConfigs & ctre::phoenix6::configs::ToFParamsConfigs::WithUpdateFrequency ( units::frequency::hertz_t newUpdateFrequency)
inlineconstexpr

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

Rate at which the CANrange will take measurements. A lower frequency may provide more stable readings but will reduce the data rate of the sensor.

  • Minimum Value: 5
  • Maximum Value: 50
  • Default Value: 50
  • Units: Hz
Parameters
newUpdateFrequencyParameter to modify
Returns
Itself

◆ WithUpdateMode()

constexpr ToFParamsConfigs & ctre::phoenix6::configs::ToFParamsConfigs::WithUpdateMode ( signals::UpdateModeValue newUpdateMode)
inlineconstexpr

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

Update mode of the CANrange. The CANrange supports short-range and long-range detection at various update frequencies.

Parameters
newUpdateModeParameter to modify
Returns
Itself

Member Data Documentation

◆ UpdateFrequency

units::frequency::hertz_t ctre::phoenix6::configs::ToFParamsConfigs::UpdateFrequency = 50_Hz

Rate at which the CANrange will take measurements.

A lower frequency may provide more stable readings but will reduce the data rate of the sensor.

  • Minimum Value: 5
  • Maximum Value: 50
  • Default Value: 50
  • Units: Hz

◆ UpdateMode

signals::UpdateModeValue ctre::phoenix6::configs::ToFParamsConfigs::UpdateMode = signals::UpdateModeValue::ShortRange100Hz

Update mode of the CANrange.

The CANrange supports short-range and long-range detection at various update frequencies.


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