Метод | Описание | |
---|---|---|
Initialize ( float frequency, bool clear = true, bool restart = true, bool enable = false ) : |
Creates an initialized instance.
|
|
ReadAll ( ) : void |
Reads all values from the device and updates properties.
|
|
Restart ( NxpPca9685Mode1Bits options ) : void |
Restarts the device with additional options specified, then updates all properties.
|
|
SetLed ( int red, int green, int blue ) : void |
Sets RGB values of the high intensity LED together (in one operation). Automatically inverts the value, providing a natural behaviour where a higher number produces a higher LED intensity. Normally, when written as raw PWM values, the output is inverted due to common anode. |
Метод | Описание | |
---|---|---|
Dispose ( bool disposing ) : void |
Frees resources owned by this instance.
|
Метод | Описание | |
---|---|---|
NavioLedPwmDevice ( Windows.Devices.I2c.I2cDevice device ) : System | ||
OnLedBlueChannelChanged ( object sender, |
Updates the LedBlue property when the related channel changed.
|
|
OnLedGreenChannelChanged ( object sender, |
Updates the LedGreen property when the related channel changed.
|
|
OnLedRedChannelChanged ( object sender, |
Updates the LedRed property when the related channel changed.
|
|
ReadLed ( ) : void |
Reads the LED channels from the device, calculates then updates the related properties.
|
protected Dispose ( bool disposing ) : void | ||
disposing | bool |
/// True when called via |
Результат | void |
public static Initialize ( float frequency, bool clear = true, bool restart = true, bool enable = false ) : |
||
frequency | float |
/// |
clear | bool | Clears all LED/PWM values. |
restart | bool |
/// Set true to restart the device which also enables the osciallator.
/// When false, you have to call |
enable | bool | /// Set true to enable output, or false to continue with further initialization before enabling output. /// When false, you have to set it later before any output can occur. /// Defaults to false to prevent unexpected behaviour from damaging hardware. /// |
Результат |
public Restart ( NxpPca9685Mode1Bits options ) : void | ||
options | NxpPca9685Mode1Bits |
/// Optional mode 1 parameters to add to the final restart sequence. A logical OR is applied to this value and
/// the standard |
Результат | void |
public SetLed ( int red, int green, int blue ) : void | ||
red | int | Red value in the range 0- |
green | int | Green value in the range 0- |
blue | int | Blue value in the range 0- |
Результат | void |