-
Notifications
You must be signed in to change notification settings - Fork 1
/
keyboard.h
39 lines (34 loc) · 921 Bytes
/
keyboard.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
/*
* =====================================================================================
*
* Filename: keyboard.h
*
* Description:
*
* Version: 1.0
* Created: 11.01.2012 15:09:58
* Revision: none
* Compiler: gcc
*
* Author: Georg Wassen (gw) (),
* Company:
*
* =====================================================================================
*/
#ifndef KEYBOARD_H
#define KEYBOARD_H
#include "stddef.h"
typedef enum {kbm_poll, kbm_interrupt} kb_mode_t;
#define KEY_ESC 200
#define KEY_UP 201
#define KEY_DOWN 202
#define KEY_PGUP 205
#define KEY_PGDOWN 206
#define KEY_HOME 207
#define KEY_END 208
uint32_t keyboard_get_scancode();
uint8_t scancode_to_keycode(uint32_t scancode);
uint8_t wait_for_key();
int keyboard_mode(kb_mode_t mode);
int keyboard_init(kb_mode_t mode);
#endif // KEYBOARD_H