13 #include <HAL/Types.h> 15 #include "DigitalSource.h" 16 #include "LiveWindow/LiveWindowSendable.h" 17 #include "networktables/NetworkTableEntry.h" 34 void Pulse(
double length);
50 void InitTable(std::shared_ptr<nt::NetworkTable> subTable)
override;
54 HAL_DigitalHandle m_handle;
55 HAL_DigitalPWMHandle m_pwmGenerator;
58 NT_EntryListener m_valueListener = 0;
bool IsPulsing() const
Determine if the pulse is still going.
Definition: DigitalOutput.cpp:123
Live Window Sendable is a special type of object sendable to the live window.
Definition: LiveWindowSendable.h:17
void EnablePWM(double initialDutyCycle)
Enable a PWM Output on this line.
Definition: DigitalOutput.cpp:163
void UpdateTable() override
Update the table for this sendable object with the latest values.
Definition: DigitalOutput.cpp:235
DigitalOutput(int channel)
Create an instance of a digital output.
Definition: DigitalOutput.cpp:30
AnalogTriggerType GetAnalogTriggerTypeForRouting() const override
Definition: DigitalOutput.cpp:231
void InitTable(std::shared_ptr< nt::NetworkTable > subTable) override
Initializes a table for this sendable object.
Definition: DigitalOutput.cpp:259
void Set(bool value)
Set the value of a digital output.
Definition: DigitalOutput.cpp:75
bool IsAnalogTrigger() const override
Is source an AnalogTrigger.
Definition: DigitalOutput.cpp:226
int GetChannel() const override
Definition: DigitalOutput.cpp:100
void SetPWMRate(double rate)
Change the PWM frequency of the PWM output on a Digital Output line.
Definition: DigitalOutput.cpp:142
void DisablePWM()
Change this line from a PWM output back to a static Digital Output line.
Definition: DigitalOutput.cpp:186
std::string GetSmartDashboardType() const override
Definition: DigitalOutput.cpp:255
DigitalSource Interface.
Definition: DigitalSource.h:26
void StopLiveWindowMode() override
Stop having this sendable object automatically respond to value changes.
Definition: DigitalOutput.cpp:248
void Pulse(double length)
Output a single pulse on the digital output line.
Definition: DigitalOutput.cpp:110
virtual ~DigitalOutput()
Free the resources associated with a digital output.
Definition: DigitalOutput.cpp:59
Class to write to digital outputs.
Definition: DigitalOutput.h:27
bool Get() const
Gets the value being output from the Digital Output.
Definition: DigitalOutput.cpp:88
void UpdateDutyCycle(double dutyCycle)
Change the duty-cycle that is being generated on the line.
Definition: DigitalOutput.cpp:210
NetworkTables Entry.
Definition: NetworkTableEntry.h:30
void StartLiveWindowMode() override
Start having this sendable object automatically respond to value changes reflect the value on the tab...
Definition: DigitalOutput.cpp:237
HAL_Handle GetPortHandleForRouting() const override
Definition: DigitalOutput.cpp:221