title: Simulate Key Press at hardware level - Windows
body: <p>I'm looking for a language or library to allow me to simulate key strokes at the maximum level possible, without physically pressing the key.  </p>
  
  <p>(My specific measure of the level of the keystroke is whether or not it will produce the same output as a physical Key Press when my computer is already running key listeners (such as MouseKeys and StickyKeys)).</p>
  
  <p>I've tried many methods of keystroke emulation;
  The java AWT library, Java win32api, python win32com sendKeys, python ctypes Key press, and many more libraries for python and Java, but none of them simulate the key stroke at a close enough level to actual hardware.<br>
  (When Windows MouseKeys is active, sending a key stroke of a colon, semi colon or numpad ADD key just produces those characters, where as a physical press performs the MouseKeys click)</p>
  
  <p>I believe such methods must involve sending the strokes straight to an application, rather than passing them just to the OS.</p>
  
  <p>I'm coming to the idea that no library for these high (above OS code) level languages will produce anything adequate. I fear I might have to stoop to some kind of BIOS programming.</p>
  
  <p>Does anybody have any useful information on the matter whatsoever?<br>
  How would I go about emulating key presses in lower level languages?<br>
  Should I be looking for a my-hardware-specific solution (some kind of Fujitsu hardware API)?</p>
  
  <p>I almost feel it would be easier to program a robot to simply sit by the hardware and press the keys.</p>
  
  <p>Thanks!  </p>