10#include <units/frequency.h>
11#include <units/time.h>
12#include <units/dimensionless.h>
25 ctre::phoenix::StatusCode SendRequest(
const char *network, uint32_t deviceHash, std::shared_ptr<ControlRequest> &req)
const override;
100 constexpr std::string_view
GetName()
const override
102 return "RgbFadeAnimation";
149 Slot = std::move(newSlot);
Common interface implemented by all control requests.
Definition ControlRequest.hpp:27
Animation that fades all the LEDs of a strip simultaneously between Red, Green, and Blue.
Definition RgbFadeAnimation.hpp:24
constexpr RgbFadeAnimation(int LEDStartIndex, int LEDEndIndex)
Animation that fades all the LEDs of a strip simultaneously between Red, Green, and Blue.
Definition RgbFadeAnimation.hpp:88
constexpr ~RgbFadeAnimation() override
Definition RgbFadeAnimation.hpp:93
units::dimensionless::scalar_t Brightness
The brightness of the animation, as a scalar from 0.0 to 1.0.
Definition RgbFadeAnimation.hpp:47
int LEDStartIndex
The index of the first LED this animation controls (inclusive).
Definition RgbFadeAnimation.hpp:33
units::frequency::hertz_t FrameRate
The frame rate of the animation, from [2, 1000] Hz.
Definition RgbFadeAnimation.hpp:58
constexpr RgbFadeAnimation & WithLEDEndIndex(int newLEDEndIndex)
Modifies this Control Request's LEDEndIndex parameter and returns itself for method-chaining and easi...
Definition RgbFadeAnimation.hpp:131
units::frequency::hertz_t UpdateFreqHz
The frequency at which this control will update.
Definition RgbFadeAnimation.hpp:73
int LEDEndIndex
The index of the last LED this animation controls (inclusive).
Definition RgbFadeAnimation.hpp:38
constexpr RgbFadeAnimation & WithSlot(int newSlot)
Modifies this Control Request's Slot parameter and returns itself for method-chaining and easier to u...
Definition RgbFadeAnimation.hpp:147
constexpr RgbFadeAnimation & WithUpdateFreqHz(units::frequency::hertz_t newUpdateFreqHz)
Sets the frequency at which this control will update.
Definition RgbFadeAnimation.hpp:206
constexpr RgbFadeAnimation & WithLEDStartIndex(int newLEDStartIndex)
Modifies this Control Request's LEDStartIndex parameter and returns itself for method-chaining and ea...
Definition RgbFadeAnimation.hpp:115
constexpr RgbFadeAnimation & WithFrameRate(units::frequency::hertz_t newFrameRate)
Modifies this Control Request's FrameRate parameter and returns itself for method-chaining and easier...
Definition RgbFadeAnimation.hpp:184
std::map< std::string, std::string > GetControlInfo() const override
Gets information about this control request.
std::string ToString() const override
Returns a string representation of the object.
constexpr RgbFadeAnimation & WithBrightness(units::dimensionless::scalar_t newBrightness)
Modifies this Control Request's Brightness parameter and returns itself for method-chaining and easie...
Definition RgbFadeAnimation.hpp:162
int Slot
The slot of this animation, within [0, 7].
Definition RgbFadeAnimation.hpp:43
constexpr std::string_view GetName() const override
Gets the name of this control request.
Definition RgbFadeAnimation.hpp:100
Status codes reported by APIs, including OK, warnings, and errors.
Definition StatusCodes.h:28
Definition motor_constants.h:14