forked from drath/libratbag
G300: fix profile switching
The profile ID's used are: profile 0: 0x80 profile 1: 0x90 profile 2: 0xA0 These were miscalculated as 0x80, 0x81, and 0x82.
This commit is contained in:
committed by
Peter Hutterer
parent
8d67389042
commit
efe6021e76
@@ -228,7 +228,7 @@ logitech_g300_current_profile(struct ratbag_device *device)
|
||||
static int
|
||||
logitech_g300_set_current_profile(struct ratbag_device *device, unsigned int index)
|
||||
{
|
||||
uint8_t buf[] = {LOGITECH_G300_REPORT_ID_SET_ACTIVE_PROFILE, 0x80 + index, 0x00, 0x00};
|
||||
uint8_t buf[] = {LOGITECH_G300_REPORT_ID_SET_ACTIVE_PROFILE, 0x80 | (index << 4), 0x00, 0x00};
|
||||
int ret;
|
||||
|
||||
if (index > LOGITECH_G300_PROFILE_MAX)
|
||||
|
||||
Reference in New Issue
Block a user