old-MTGos-old/kernel/hal/x86/include/keyboard.hpp
Morten Delenk 39b2261758 Keyboard driver now works
!forgot, that the §-sign was not in Codepage 437 (The input is no longer offset while holding the shift button)
+Added modifier key support
2015-10-17 17:03:32 +02:00

23 lines
497 B
C++

#ifndef _KEYBOARD_HPP
#define _KEYBOARD_HPP
#include <stdint.h>
#include <input.hpp>
#include <io.h>
#include <idt.hpp>
namespace MTGosHAL {
class Keyboard: public Input {
private:
//This kernel has a buffer of 16 chars
char buf[16];
int len;
auto getChar() -> char;
auto sendCommand(uint8_t command) -> void;
bool numlock, capslock, scrolllock, response;
public:
auto handleIRQ1(struct cpu_state* cpu) -> void;
Keyboard();
};
}
#endif // -Wno-pmf-conversions