{"action":"closed","issue":{"url":"https://api.github.com/repos/ccMSC/ckb/issues/158","labels_url":"https://api.github.com/repos/ccMSC/ckb/issues/158/labels{/name}","comments_url":"https://api.github.com/repos/ccMSC/ckb/issues/158/comments","events_url":"https://api.github.com/repos/ccMSC/ckb/issues/158/events","html_url":"https://github.com/ccMSC/ckb/issues/158","id":116953193,"number":158,"title":"Keymap issue","user":{"login":"OvermindDL1","id":401605,"avatar_url":"https://avatars.githubusercontent.com/u/401605?v=3","gravatar_id":"","url":"https://api.github.com/users/OvermindDL1","html_url":"https://github.com/OvermindDL1","followers_url":"https://api.github.com/users/OvermindDL1/followers","following_url":"https://api.github.com/users/OvermindDL1/following{/other_user}","gists_url":"https://api.github.com/users/OvermindDL1/gists{/gist_id}","starred_url":"https://api.github.com/users/OvermindDL1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OvermindDL1/subscriptions","organizations_url":"https://api.github.com/users/OvermindDL1/orgs","repos_url":"https://api.github.com/users/OvermindDL1/repos","events_url":"https://api.github.com/users/OvermindDL1/events{/privacy}","received_events_url":"https://api.github.com/users/OvermindDL1/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-11-14T21:30:49Z","updated_at":"2016-01-15T08:33:19Z","closed_at":"2016-01-15T08:33:19Z","body":"I have a keyboard-like device, Naga mouse, that I set a custom keymap on via xkbcomp, been working for me for years.\r\n\r\nHowever now that I have hooked up the K95 with ckb randomly within an hour after bootup then its keys break.  Specifically I change the Naga's 1,2,3,4,5,6,7,8,9,10,11,12 keys to be F13 through F24, and this keymap is applied at bootup and it and the K95 keyboard work as expected, however about 5-10 minutes after bootup the K95 keyboard seems to get its keys at the top of the keyboard, not the keypad as the Naga maps to, get remaped to F13 to F24 as well, yet the numpad continues to work fine, so that is a disconnect, and it is especially odd as it happen a while after xkbcomp is ever run.\r\n\r\nSo I started looking, the first thing I notice is that the K95 is not appearing via the xinput list:\r\n```\r\n⎡ Virtual core pointer                          id=2    [master pointer  (3)]\r\n⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]\r\n⎜   ↳ Razer Razer Nostromo                      id=9    [slave  pointer  (2)]\r\n⎜   ↳ Razer Razer Naga 2014                     id=11   [slave  pointer  (2)]\r\n⎜   ↳ ckb1: Corsair K95 RGB Gaming Keyboard     id=13   [slave  pointer  (2)]\r\n⎜   ↳ Razer Razer Naga 2014                     id=10   [slave  pointer  (2)]\r\n⎣ Virtual core keyboard                         id=3    [master keyboard (2)]\r\n    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]\r\n    ↳ Power Button                              id=6    [slave  keyboard (3)]\r\n    ↳ Power Button                              id=7    [slave  keyboard (3)]\r\n    ↳ Razer Razer Nostromo                      id=8    [slave  keyboard (3)]\r\n    ↳ Razer Razer Naga 2014                     id=12   [slave  keyboard (3)]\r\n```\r\nIt is not listed in the Virtual core keyboard whatsoever, only under the Virtual core pointer for the mouse emulation I am guessing, so I cannot even apply an xkbcomp keymap at all to fix it, I have to reboot to fix it, for only a few minutes at that.\r\n\r\nIf I do not have xkbcomp set a keymap on the naga at bootup then the keyboard's mapping never changes.\r\n\r\nThus, how is the mapping ever applied to the K95 whatsoever when it is not appearing in `xinput --list` at all?\r\n\r\nSecond, how is the K95 not appearing in `xinput --list`?\r\n\r\nMy initial hypothesis based on how it is working is that it is using the last-most listed device in Virtual core keyboard as its mapping and sending the key inputs as if it were from that device instead of its own device.  This is further supported by I just tested by forcing a reshuffle of the ID's of the Naga so there is a keyboard higher than it then the keyboard works (I did this by plugging in my old keyboard, which caused it to appear with id=14, and as evidenced by my parenthesis working again).\r\n\r\nIt seems everything comes down to the fact that there is no keyboard device setup for the K95 in the xinput system, so how is it sending events unless via another existing device by mocking it?"}}