Closed Svenum closed 2 years ago
I'm not sure what Solaar is doing to cause these changes. Does this happen if the GKeys are not diverted?
Please run Solaar as solaar -dd
and attach the output to show what commands Solaar is sending to your keyboard.
Yes, this is happened too if the GKeys are not diverted.
Output of solaar -dd
I think, that solaar is disabling the profile keys (M-Keys) of the keyboard and that is causing the lightning issues.
This is a variant of an issue with Gaming Mice. By default, Solaar wants to be able to control the rate of reports from the device, but to do that for some gaming devices it has to modify the ONBOARD PROFILES, which controls the M Keys.
From https://github.com/pwr-Solaar/Solaar:
Many gaming mice have both the ONBOARD PROFILES feature and the REPORT RATE feature. On these mice changing the Polling Rate setting requires modifying a setting in the ONBOARD PROFILES feature, which can modify how the mouse works. Changing the Polling Rate setting to "Ignore this setting" (see above) prevents Solaar from modifying the ONBOARD PROFILES feature. The mouse has to be reset (e.g., by turning it off and on again) before this fix will take effect.
The fix will be the same for you. Click on the little icon to the right of the Report Rate setting until it gets to the ignore state. (The icon will look like something other than a locked or unlocked lock.)
I'll update the documentation of the known issue to include keyboards.
Thank you for the quick help! The M-Keys still do not work, but the lightning is now turned on automatically, that is a big improvement. Is it possible to get the M-Keys working?
First you need to determine whether Solaar is causing the problem. Make sure that Solaar has the Report Rate setting set to ignore. Then quit out of Solaar using the Quit Solaar button. Then turn the keyboard off and on. Then check whether the M-Keys are working. If they are not working, try to get them working while Solaar is not running.
When the M-Keys are working start up Solaar as solaar -dd
. If they stop working, then Solaar is likely the cause. Post the output from Solaar again.
A second check would be to change all the Solaar settings for the keyboard to ignore and repeat the actions from above to see whether the keyboard M-Keys still do not work under Solaar.
It would be useful to attach a screenshot of the Solaar main window with the keyboard shown.
I have tested Like you said. The problem is the "Divert G Keys" option, if I turn it to ignore the M-Keys work. But i need this, that the keys work, like I wanted.
Again the output:
Do you want to have the G keys diverted (so that they can trigger rules)?
It looks as if diverting the G keys also diverts the M keys. You could check this out by not diverting the G keys and seeing whether the M keys work.
If diverting the G keys also diverts the M keys then you will have to get the M keys to do what you want them to do by writing Solaar rules for them as well. Some code will likely have to be added to Solaar as well.
To verify what is going on, please run Solaar as solaar -dd
and divert the G keys. Then press a couple of G keys and a couple of M keys and post the output produced (just the part related to pressing these keys).
Now I have pressed the M-Keys with "Divert G Key" = on: M1:
08:26:06,657 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 01000000000000000000000000000000]
08:26:06,657 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) <= w[11 01 011A 12000000000000000000000000000000]
08:26:06,668 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 011A 80200000000000000000000000000000]
08:26:06,668 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 01000000000000000000000000000000
08:26:06,833 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 00000000000000000000000000000000]
08:26:06,833 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 00000000000000000000000000000000
M2:
08:26:08,778 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 02000000000000000000000000000000]
08:26:08,778 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 02000000000000000000000000000000
08:26:08,908 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 00000000000000000000000000000000]
08:26:08,908 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 00000000000000000000000000000000
M3:
08:26:09,887 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 04000000000000000000000000000000]
08:26:09,887 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 04000000000000000000000000000000
08:26:10,018 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1200 00000000000000000000000000000000]
08:26:10,018 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MKEYS, report 1, data 00000000000000000000000000000000
MR:
08:26:11,924 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1300 01000000000000000000000000000000]
08:26:11,925 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) <= w[11 01 011A 13000000000000000000000000000000]
08:26:11,935 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 011A 80300000000000000000000000000000]
08:26:11,935 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MR, report 1, data 01000000000000000000000000000000
08:26:12,122 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1300 00000000000000000000000000000000]
08:26:12,123 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature MR, report 1, data 00000000000000000000000000000000
Pressed with "Divert G Keys" = off: Switching from M1 to M2:
08:29:54,436 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1500 00020000000000000000000000000000]
08:29:54,437 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature ONBOARD PROFILES, report 1, data 00020000000000000000000000000000
from M2 to M3:
08:29:57,026 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1500 00030000000000000000000000000000]
08:29:57,027 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature ONBOARD PROFILES, report 1, data 00030000000000000000000000000000
from M3 to M1:
08:30:04,686 DEBUG [ReceiverListener:hidraw9] logitech_receiver.base: (19) => r[11 01 1500 00010000000000000000000000000000]
08:30:04,687 DEBUG [ReceiverListener:hidraw9] logitech_receiver.notifications: <Device(1,407C,G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD,A502B0E1)>: notification for feature ONBOARD PROFILES, report 1, data 00010000000000000000000000000000
MR still do not do anything.
So diverting the G keys also diverts the M keys. But when the G keys are not diverted the M keys are reporting via OnBoard Profiles notifications.
Extending Solaar to handle M keys correctly is going to require information from Logitech, which will take a while to get.
Ok, are you able to get this information? It's not very important, so it has time. Anyway, thank you for your quick help!
I can get some information. There is quite a bit of information available on a public Google folder.
Hey there,
been following along this thread, because I've been key-mapping the G keys to what I want. But sadly due to this I cannot get passed G5 since I cannot hit the M2 and beyond to switch to it. I did some experimenting, such as having the rules to something like G9 > quit Solaar > turn keyboard off > turn it back on > switch to M2 > restart Solaar. But same issue, it reverts back to M1 for G1-G5.
Anyway, any update or anything on this @pfps ? My Keyboard is the G915 as well. Anything I can do to help? Logs or anything. Let me know.
@FormBurden What would help is a clear and concise description of the problem. The G915 has only 5 G keys as far as I can tell. Is the problem that you cannot get rules to be sensitive to M keys?
It appears that the linking of G key and M key behaviour and is a feature of this keyboard that cannot be changed by Solaar.
It looks as if your options are to set ignore on G key diversion and get the standard M key behaviour or set G key diversion on to get notifications from the G, M, and MR keys.
PR #1454 adds the ability to trigger rules on M and MR key presses and releases when G key diversion is on.
Sorry for not getting back recently. As for the first reply you sent me, the issue since the G915 only has 5 keys, you would need to use the M1, M2, M3 keys to get to the G6-15 keys, but when G key diversion is on, it cannot do it. Plus like others have said the light in the "M" keys go out, and you can't change anything. It just defaults to G1-5. That's it.
And your most recent reply. Hmm, that's unfortunate. But all is well. What I'm confused is your "set G key diversion on to get notifications from the G, M, and MR keys", reply. What exactly does "get notifications" from those keys mean? Sorry haha.
Different Logitech keyboards have different numbers of G keys. If there are only 5, then there are only 5. The M keys are different. Solaar has the ability to "divert" keys so that they are not noticed by the Linux input drivers. Instead they produce notifications that can trigger Solaar rules. Before PR #1454 the G keys could trigger rules. PR #1454 adds the ability for M and MR keys to trigger rules. It appears that M and MR keys are diverted when G keys are diverted. So with PR #1454 you can have a rule condition for KeyPress on M2, for example. Some keyboards have the ability to change their behaviour using a feature called onboard profiles. It appears that changing certain other features (such as diverting G keys) changes how the onboard profiles work. I don't have any of these keyboards so I don't know much about how these changes work.
Oh I see. Makes sense. That's why I was using the G key diversion because when that's off, (which you know) it causes the G keys to use I would assume whatever defaults for the onboard profiles? Could be wrong. But the G915 keyboard when 'G key diversion' is off, G1-5 on M1, is the F keys 1-5. While M2 and M3 those keys are the numbers 1-9, then 0 for M3-G5.
Would #1454 cause it so those defaults wouldn't happen? And you could map to whatever? Or is that something sadly you'd need 'G key diversion'?
All that PR #1454 does is let Solaar rules trigger on M and MR keypresses, provided that they are diverted (via divertiing the G keys).
I have got a new keyboard, the Logitech G915 Lightspeed. The key configuration and the Battery-Status is works great without problems! But if I am starting Solaar, the Key lightning is going out and the M1 to M3 Keys do not work anymore. And if the PC is going to sleep I have to reactivate the RGB manually, they do not go on, on its own.
Steps to reproduce the behavior:
Maybe helpfull: If i connect the keyboard via kable and run the command ratbagctl "Logitech G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD" profile 0 button 0 action set macro KEY_1;
# bash > ratbagctl "Logitech G915 WIRELESS RGB MECHANICAL GAMING KEYBOARD" profile 0 button 0 action set macro KEY_1;
I am able to turn the M1-Key back on and load the profile on it. (The other M-Keys dont work anyways)