88 void Pulse(units::second_t pulseLength);
Class to write to digital outputs.
Definition DigitalOutput.h:26
DigitalOutput(int channel)
Create an instance of a digital output.
bool IsAnalogTrigger() const override
Is source an AnalogTrigger.
void SetSimDevice(HAL_SimDeviceHandle device)
Indicates this output is used by a simulated device.
void EnablePWM(double initialDutyCycle)
Enable a PWM Output on this line.
DigitalOutput(DigitalOutput &&)=default
bool IsPulsing() const
Determine if the pulse is still going.
AnalogTriggerType GetAnalogTriggerTypeForRouting() const override
void EnablePPS(double dutyCycle)
Enable a PWM PPS (Pulse Per Second) Output on this line.
HAL_Handle GetPortHandleForRouting() const override
void DisablePWM()
Change this line from a PWM output back to a static Digital Output line.
~DigitalOutput() override
void SetPWMRate(double rate)
Change the PWM frequency of the PWM output on a Digital Output line.
bool Get() const
Gets the value being output from the Digital Output.
void Set(bool value)
Set the value of a digital output.
int GetChannel() const override
void UpdateDutyCycle(double dutyCycle)
Change the duty-cycle that is being generated on the line.
void InitSendable(wpi::SendableBuilder &builder) override
Initializes this Sendable object.
DigitalOutput & operator=(DigitalOutput &&)=default
void Pulse(units::second_t pulseLength)
Output a single pulse on the digital output line.
DigitalSource Interface.
Definition DigitalSource.h:22
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
int32_t HAL_Handle
Definition Types.h:17
HAL_Handle HAL_SimDeviceHandle
Definition Types.h:53
AnalogTriggerType
Defines the state in which the AnalogTrigger triggers.
Definition AnalogTriggerType.h:10