Added Effects for Clevo Lightbar

This commit is contained in:
Kyle Cascade
2026-01-21 22:55:46 +00:00
committed by Adam Honse
parent e48908573a
commit 4855628d7a
6 changed files with 150 additions and 17 deletions

View File

@@ -17,6 +17,7 @@ ClevoKeyboardController::ClevoKeyboardController(hid_device* dev_handle, const h
{
dev = dev_handle;
location = info.path;
version = info.release_number;
}
ClevoKeyboardController::~ClevoKeyboardController()
@@ -45,6 +46,13 @@ std::string ClevoKeyboardController::GetSerialString()
return(return_string);
}
std::string ClevoKeyboardController::GetFirmwareVersion()
{
char version_string[16];
snprintf(version_string, sizeof(version_string), "%d.%02d", version >> 8, version & 0xFF);
return(version_string);
}
void ClevoKeyboardController::WriteControl(unsigned char* data)
{
hid_send_feature_report(dev, data, CLEVO_KEYBOARD_REPORT_SIZE);