From b82ccebd3a0cce28177b5fac046139e2de7737fa Mon Sep 17 00:00:00 2001 From: Alexey Gavrilov Date: Sun, 20 Aug 2023 20:12:36 +0700 Subject: Getting started with print on display + some fixes --- arch/x86/io/VGADisplayInfo.h | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 arch/x86/io/VGADisplayInfo.h (limited to 'arch/x86/io/VGADisplayInfo.h') diff --git a/arch/x86/io/VGADisplayInfo.h b/arch/x86/io/VGADisplayInfo.h new file mode 100644 index 0000000..33235cc --- /dev/null +++ b/arch/x86/io/VGADisplayInfo.h @@ -0,0 +1,27 @@ +#ifndef VGAINFOCLASS_H +#define VGAINFOCLASS_H + +#include "../inc/types.h" + +#define TOBG(attr) attr << 4 + +class VGADisplayInfo +{ + public: + const static uint32 videoMemAddr = 0xB8000; + const static uint16 width = 80; + const static uint16 height = 25; + const static uint16 tabSize = 8; + enum class colorAttr { + black = 0, + blue = 1, + green = 2, + cyan = 3, + red = 4, + magenta = 5, + brown = 6, + gray = 7 + }; +}; + +#endif -- cgit v1.2.3