You are intercepting keyboard keys at a very low level, so you are not getting
characters, but
Scancodes,
defined as :
A scancode (or scan code) is the data that most computer keyboards send to a computer to report which keys have been pressed. A number, or sequence of numbers, is assigned to each key on the keyboard.
You can see for reference the
Table of Keyboard Scan Codes.
Many keys have scancodes, but no ASCII equivalent, for example the CapsLock.
Keys that have both scancodes and ASCII equivalent are translated to their
ASCII values by Windows, before being transmitted to the program
(unless it uses a low-level API call to get the key presses).
Ok, so ASCII is higher level than Scancodes? – Jordan Baron – 2019-04-05T17:44:42.880
Usually an API that is close to the hardware is called lower-level, while an API that uses these calls is called higher-level. – harrymc – 2019-04-05T19:15:16.203