title: Find event device for keyboard, mouse
body: <p>What is a <strong>foolproof</strong> method to find the <strong>event device node</strong> for the hardware <strong>keyboard</strong> or <strong>mouse</strong>?</p>
  
  <p>What I have tried is to read <em>/proc/bus/input/devices</em> and search for <em>'Keyboard'</em> or <em>'Mouse'</em> in the device name, but this doesn't work always, as the device names vary a lot.</p>
  
  <p>The other option was to select the ones with <em>Handlers=kbd</em> and <em>Handlers=mouseX</em>, but on a laptop, there are other devices like 'Power button', 'Video bus' with <em>Handlers=kbd</em> too.</p>