class
#include <dual_sense_hid/gamepad.hpp>
Lights Proxy object for calls which mutate state of gamepad's lights.
Public types
- enum class PlayerIndicatorBrightness: uint8_t { MAX = 0, MEDIUM = 1, LOW = 2 }
- Player Indicator Brightness level.
- enum class PlayerIndicator: uint8_t { PLAYER_ONE = 0, PLAYER_TWO = 1, PLAYER_THREE = 2, PLAYER_FOUR = 3, PLAYER_FIVE = 4, DISABLED = 5 }
- Player Indicator state.
- enum class MuteLightMode: uint8_t { OFF, ON, BREATHING }
- Mute light mode.
Public functions
- void set_mute_light_mode(MuteLightMode mute_light_mode)
- Set light mode of mute button.
- void set_player_indicator(PlayerIndicator indicator)
- Set indicator which represents player number.
- void set_player_indicator_brightness(PlayerIndicatorBrightness brightness)
- Set brightness level of player indicator.
- void enable_player_indicator_fade(bool enabled)
- Control player indicator fade (instant changes or smooth fading in)
- void set_touchpad_light_color(uint8_t red, uint8_t green, uint8_t blue)
- Set color of touchpad backlight.
Enum documentation
enum class dual_sense_hid:: Gamepad:: Lights:: PlayerIndicatorBrightness: uint8_t
Player Indicator Brightness level.
Enumerators | |
---|---|
MAX |
Maximum level |
MEDIUM |
Medium level |
LOW |
Low level |
enum class dual_sense_hid:: Gamepad:: Lights:: PlayerIndicator: uint8_t
Player Indicator state.
Enumerators | |
---|---|
PLAYER_ONE |
Player one (1 LED) |
PLAYER_TWO |
Player two (2 LEDs) |
PLAYER_THREE |
Player three (3 LEDs) |
PLAYER_FOUR |
Player four (4 LEDs) |
PLAYER_FIVE |
Player five (5 LEDs) |
DISABLED |
LEDs disabled |
enum class dual_sense_hid:: Gamepad:: Lights:: MuteLightMode: uint8_t
Mute light mode.
Enumerators | |
---|---|
OFF |
Off |
ON |
On |
BREATHING |
Pulsating |
Function documentation
void dual_sense_hid:: Gamepad:: Lights:: set_mute_light_mode(MuteLightMode mute_light_mode)
Set light mode of mute button.
Parameters | |
---|---|
mute_light_mode | mute light mode to be set on gamepad after state push |
void dual_sense_hid:: Gamepad:: Lights:: set_player_indicator(PlayerIndicator indicator)
Set indicator which represents player number.
Parameters | |
---|---|
indicator | player number (1-5) or disabled |
void dual_sense_hid:: Gamepad:: Lights:: set_player_indicator_brightness(PlayerIndicatorBrightness brightness)
Set brightness level of player indicator.
Parameters | |
---|---|
brightness | brightness level |
void dual_sense_hid:: Gamepad:: Lights:: enable_player_indicator_fade(bool enabled)
Control player indicator fade (instant changes or smooth fading in)
Parameters | |
---|---|
enabled | fade enabled |
void dual_sense_hid:: Gamepad:: Lights:: set_touchpad_light_color(uint8_t red,
uint8_t green,
uint8_t blue)
Set color of touchpad backlight.
Parameters | |
---|---|
red | brightness level |
green | brightness level |
blue | brightness level |