Fix HYTE THICC Q60
This commit is contained in:
parent
fe240190b3
commit
3d171c222b
1 changed files with 14 additions and 1 deletions
|
|
@ -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();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue