WPILibC++ 2025.2.1
|
#include <numbers>
#include <type_traits>
#include <gcem.hpp>
#include <wpi/SymbolExports.h>
#include "units/angle.h"
#include "units/base.h"
#include "units/math.h"
Go to the source code of this file.
Namespaces | |
namespace | frc |
Functions | |
template<typename T > requires std::is_arithmetic_v<T> || units::traits::is_unit_t_v<T> | |
constexpr T | frc::ApplyDeadband (T value, T deadband, T maxMagnitude=T{1.0}) |
Returns 0.0 if the given value is within the specified range around zero. | |
template<typename T > | |
constexpr T | frc::InputModulus (T input, T minimumInput, T maximumInput) |
Returns modulus of input. | |
template<typename T > requires std::is_arithmetic_v<T> || units::traits::is_unit_t_v<T> | |
constexpr bool | frc::IsNear (T expected, T actual, T tolerance) |
Checks if the given value matches an expected value within a certain tolerance. | |
template<typename T > requires std::is_arithmetic_v<T> || units::traits::is_unit_t_v<T> | |
constexpr bool | frc::IsNear (T expected, T actual, T tolerance, T min, T max) |
Checks if the given value matches an expected value within a certain tolerance. | |
WPILIB_DLLEXPORT constexpr units::radian_t | frc::AngleModulus (units::radian_t angle) |
Wraps an angle to the range -π to π radians (-180 to 180 degrees). | |
constexpr std::signed_integral auto | frc::FloorDiv (std::signed_integral auto x, std::signed_integral auto y) |
Returns the largest (closest to positive infinity) int value that is less than or equal to the algebraic quotient. | |
constexpr std::signed_integral auto | frc::FloorMod (std::signed_integral auto x, std::signed_integral auto y) |
Returns the floor modulus of the int arguments. | |