@juj Emscripten's SDL is version 1.3 currently, to see https://github.com/kripken/emscripten/blob/master/system/include/SDL/SDL_version.h#L63 . And, SDL was change keyboard state API behavior from `SDL_GetKeyState`(SDL-1.2) to `SDL_GetKeyboardState`(SDL-1.3 or later). `SDL_GetKeyState` is designed based on SDL-KeyCode, but `SDL_GetKeyboardState` is designed based on SDL-KeyScanCode.  Unfortunately, SDL-1.3 online documentation is not found, because the SDL version is re-based to 2.0 from 1.3 soon. And, we can read `SDL_GetKeyboardState`(SDL-1.3 or later) online documentation to see: https://wiki.libsdl.org/SDL_GetKeyboardState