@@ -291,7 +291,7 @@ void LianLiUniHubSLController::SendActivate(size_t channel, unsigned char num_fa
291291 buf[0x00 ] = UNIHUB_SL_REPORT_ID;
292292 buf[0x01 ] = 0x10 ;
293293 buf[0x02 ] = 0x32 ;
294- buf[0x03 ] = 0x10 * channel + num_fans;
294+ buf[0x03 ] = 0x10 * ( unsigned char ) channel + num_fans;
295295
296296 this ->LogBuffer (" SendActivate" , buf, sizeof (buf));
297297
@@ -332,7 +332,7 @@ void LianLiUniHubSLController::SendColor(size_t channel, const unsigned char *co
332332 memset (buf, 0x00 , (2 + num_colors));
333333
334334 buf[0x00 ] = UNIHUB_SL_REPORT_ID;
335- buf[0x01 ] = 0x30 + channel; // Channel 1: 0x30, Channel 2: 0x31, etc.
335+ buf[0x01 ] = 0x30 + ( unsigned char ) channel; // Channel 1: 0x30, Channel 2: 0x31, etc.
336336
337337 memcpy (&buf[0x02 ], colors, num_colors);
338338
@@ -350,7 +350,7 @@ void LianLiUniHubSLController::SendMode(size_t channel, const mode &active)
350350 memset (buf, 0x00 , sizeof (buf));
351351
352352 buf[0x00 ] = UNIHUB_SL_REPORT_ID;
353- buf[0x01 ] = 0x10 + channel; // Channel 1: 0x10, Channel 2: 0x11, etc.
353+ buf[0x01 ] = 0x10 + ( unsigned char ) channel; // Channel 1: 0x10, Channel 2: 0x11, etc.
354354 buf[0x02 ] = active.value ;
355355 buf[0x03 ] = this ->ConvertSpeed (active.speed );
356356 buf[0x04 ] = this ->ConvertDirection (active.direction );
0 commit comments