Ticket #11 (new defect)

Opened 2 years ago

Last modified 2 years ago

Keyboard input sensitivity is incorrect

Reported by: patrick Assigned to:
Priority: major Milestone:
Component: Gadgeteer Version:
Keywords: keyboard event Cc:
Completion:

Description

The way the keyboard processes input leads to key press frequency being tied to frame rate. This causes the keyboard input to be overly sensitive when running applications at very high frame rates and under sensitive when running low frame rate applications.

This could potentially be fixed by using a time/rate update system in keyboard or the corresponding simulator devices, but there is a complexity involving the mouse event source. The problem is that mouse input is already rate based. If you move the mouse 20 pixels in a second, the keyboard device gives the system exactly 20 "key presses" to process. Unfortunately, if the application is running at 200 fps and you move the mouse 20 pixels and also hold key A down for 1 second:

  • The mouse "key" causes 20 events
  • The A key causes 200 events

This is because each frame a key is held down it generates another key "event" to Juggler.