From 3d171c222b3db83290d0a5c61a701df4db934ad9 Mon Sep 17 00:00:00 2001 From: Adam Honse Date: Mon, 2 Dec 2024 19:15:16 -0600 Subject: [PATCH] Fix HYTE THICC Q60 --- .../HYTENexusController/HYTENexusController.cpp | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/Controllers/HYTENexusController/HYTENexusController.cpp b/Controllers/HYTENexusController/HYTENexusController.cpp index 003cafa8..52c8ed69 100644 --- a/Controllers/HYTENexusController/HYTENexusController.cpp +++ b/Controllers/HYTENexusController/HYTENexusController.cpp @@ -194,7 +194,20 @@ void HYTENexusController::LEDStreaming(unsigned char channel, unsigned short led command_buf[9 + offset] = RGBGetBValue(colors[led_idx]); } - serialport->serial_write((char *)command_buf, ((led_count * 3) + 7)); + /*-----------------------------------------------------*\ + | The HYTE THICC Q60 requires 90 bytes to be sent for | + | the 4th channel (logo) even though it only has 4 LEDs | + \*-----------------------------------------------------*/ + unsigned char bytes_to_send = ((led_count * 3) + 7); + + if((device_pid == HYTE_THICC_Q60_PID) + && (channel == 3) + && (bytes_to_send < 90)) + { + bytes_to_send = 90; + } + + serialport->serial_write((char *)command_buf, bytes_to_send); serialport->serial_flush_tx(); serialport->serial_flush_rx();