0

I am doing an AI project based on Keyboard Analytics. In part 1 of the project, I have to build a python based application which will record keyboard inputs. I have some requirements.

  1. I require a breakdown of input. For eg., 'I is CapsLock + 'i' or Shift + 'i'.
  2. I also want to be able to find the duration of a keypress.
  3. I need to do this globally. Not restricted to an application.

I have considered pyHook + win32 combo. But I don't think it gives keyPress duration I have also considered pyGame. But, it's limited to the application.

Is there any module that will help me do this? Or any way I can combine existing modules to get the job done?

Sriram
  • 1

1 Answers1

0

I believe you can simply use Pygame. Simply check for key events and use pygame.time to tick during the keypress.

Malik Brahimi
  • 16,341
  • 7
  • 39
  • 70