BALTECH Docs |
C API for BALTECH SDK
|
brp_errcode brp_UI_SetRgbLed | ( | brp_protocol | protocol, |
brp_LedBitMask | LedState, | ||
unsigned | RgbColor, | ||
unsigned | TransitionTime | ||
) |
This command changes the RGB color of a single LED or a group of LEDs.
The color may be activated instantly or smoothly by a sine-wave approximated fading transition.
If the addressed LEDs are already active when this command is called, the color first fades to black (off), before the transition to the new color starts.
This command gives you direct control of the reader's LEDs. It competes with the command brp_UI_Enable() , which can be used to switch LEDs via Virtual LED port definitions (VLEDs)._UI.Enable_ operates on a higher abstraction level. Don't mix the 2 commands as this may result in inconsistent behavior.
[in] | protocol | used to execute the command |
[in] | LedState | A bitmask containing the physical LEDs you want to switch. |
[in] | RgbColor | The target RGB color (0x00RRGGBB). |
[in] | TransitionTime | The time for the fading transition to activate the target RGB color in ms. If a color is currently activated, this is also the time for the transition to deactivate this color first. For an immediate color activation, set the value to 0. |