|
Treehopper C# API
|
Base class that all LED drivers inherit from. More...
Public Member Functions | |
| LedDriver (int numLeds, bool HasGlobalBrightnessControl, bool HasIndividualBrightnessControl) | |
| Construct an LedDriver More... | |
| async Task | Clear () |
| Clear the display More... | |
| abstract Task | FlushAsync (bool force=false) |
| Write out the current values of the LEDs immediately. More... | |
Protected Attributes | |
| double | brightness |
| The internally-referenced global brightness of the LED driver More... | |
Properties | |
| bool | AutoFlush = true [get, set] |
| Gets or sets whether the display should auto-flush whenever an LED state is changed More... | |
| bool | HasGlobalBrightnessControl [get, protected set] |
| Gets or sets whether this controller supports global brightness control. More... | |
| bool | HasIndividualBrightnessControl [get] |
| Gets or sets whether this controller's LEDs have individual brightness control (through PWM or otherwise). More... | |
| double | Brightness [get, set] |
| The global brightness, from 0.0-1.0, of the LEDs attached to this driver More... | |
| IList< Led > | Leds = new Collection<Led>() [get, set] |
| The collection of LEDs that belong to this driver. More... | |
| IFlushable | Parent [get, protected set] |
| Gets the parent device of this LED driver More... | |
Base class that all LED drivers inherit from.
| LedDriver | ( | int | numLeds, |
| bool | HasGlobalBrightnessControl, | ||
| bool | HasIndividualBrightnessControl | ||
| ) |
Construct an LedDriver
| numLeds | The number of LEDs to construct |
| HasGlobalBrightnessControl | Whether the controller can globally adjust the LED brightness. |
| HasIndividualBrightnessControl | Whether the controller has individual LED brightness control |
| async Task Clear | ( | ) |
Clear the display
Implements ILedDriver.
|
pure virtual |
Write out the current values of the LEDs immediately.
| force | Whether to write out all values, even if they appear unchanged. |
Implements IFlushable.
Implemented in Max7219, Tm1650, Ht16k33, Is31fl3218, GpioLedDriver< TDigitalOutPin >, and PwmLedDriver< TPwm >.
|
protected |
The internally-referenced global brightness of the LED driver
|
getset |
Gets or sets whether the display should auto-flush whenever an LED state is changed
|
getprotected set |
Gets or sets whether this controller supports global brightness control.
|
get |
Gets or sets whether this controller's LEDs have individual brightness control (through PWM or otherwise).
|
getset |
The global brightness, from 0.0-1.0, of the LEDs attached to this driver
|
getprotected set |
Gets the parent device of this LED driver