186 int GetSourceChannel()
const;
188 std::shared_ptr<AnalogInput> m_analogInput;
189 std::shared_ptr<DutyCycle> m_dutyCycle;
191 bool m_ownsAnalog =
false;
Definition AnalogTrigger.h:22
void SetLimitsVoltage(double lower, double upper)
Set the upper and lower limits of the analog trigger.
void SetLimitsDutyCycle(double lower, double upper)
Set the upper and lower duty cycle limits of the analog trigger.
bool GetTriggerState()
Return the TriggerState output of the analog trigger.
void InitSendable(wpi::SendableBuilder &builder) override
Initializes this Sendable object.
AnalogTrigger(DutyCycle &dutyCycle)
Construct an analog trigger using an existing duty cycle input.
AnalogTrigger(AnalogInput *input)
Construct an analog trigger using an existing analog input.
AnalogTrigger(AnalogInput &input)
Construct an analog trigger using an existing analog input.
void SetFiltered(bool useFilteredValue)
Configure the analog trigger to use a filtered value.
AnalogTrigger(std::shared_ptr< AnalogInput > input)
Construct an analog trigger using an existing analog input.
AnalogTrigger(AnalogTrigger &&)=default
AnalogTrigger(DutyCycle *dutyCycle)
Construct an analog trigger using an existing duty cycle input.
int GetIndex() const
Return the index of the analog trigger.
bool GetInWindow()
Return the InWindow output of the analog trigger.
~AnalogTrigger() override=default
AnalogTrigger(std::shared_ptr< DutyCycle > dutyCycle)
Construct an analog trigger using an existing duty cycle input.
std::shared_ptr< AnalogTriggerOutput > CreateOutput(AnalogTriggerType type) const
Creates an AnalogTriggerOutput object.
AnalogTrigger & operator=(AnalogTrigger &&)=default
void SetLimitsRaw(int lower, int upper)
Set the upper and lower limits of the analog trigger.
void SetAveraged(bool useAveragedValue)
Configure the analog trigger to use the averaged vs.
AnalogTrigger(int channel)
Constructor for an analog trigger given a channel number.
Class to represent a specific output from an analog trigger.
Definition AnalogTriggerOutput.h:49
Class to read a duty cycle PWM input.
Definition DutyCycle.h:32
A move-only C++ wrapper around a HAL handle.
Definition Types.h:96
Helper class for building Sendable dashboard representations.
Definition SendableBuilder.h:21
A helper class for use with objects that add themselves to SendableRegistry.
Definition SendableHelper.h:21
Interface for Sendable objects.
Definition Sendable.h:16
AnalogTriggerType
Defines the state in which the AnalogTrigger triggers.
Definition AnalogTriggerType.h:10