stimuli.keyboard.KeyEvent🔗

class stimuli.keyboard.KeyEvent(key, press_time, release_time)[source]🔗

Object representing a keyboard event.

Parameters:
keystr

The string representation of the key.

press_timefloat | None

The time at which the key was pressed in seconds.

release_timefloat | None

The time at which the key was released in seconds.

Notes

The parameters are accessible as attributes of the object.

The time reference is t0, the instantiation time of the Keyboard object or the reset with reset().