The function keyboard_event() takes the keyboard controller as
its first argument obj. The key_up argument specifies
whether the event is a key release (1) or a key press (0). The
key argument is the Simics internal keycode, as defined in
the sim_key_t
enum.
If the return value is 1 the keyboard controller accepted the event. If return value is 0 the keyboard controller did not accept the event, and the console should buffer the event until it gets a keyboard_ready() call from the keyboard controller.
SIM_INTERFACE(keyboard) { int (*keyboard_event)(conf_object_t *obj, int key_up, uint8 key); }; #define KEYBOARD_INTERFACE "keyboard"