From 05a221017e390f592aa8ada75754a9a450d962c9 Mon Sep 17 00:00:00 2001 From: niansa Date: Fri, 7 Apr 2023 10:32:23 +0200 Subject: [PATCH] NDS: Display console on top, keyboard on bottom --- Receiver.cpp | 1 + Runtime.hpp | 7 ++++++- Sender.cpp | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Receiver.cpp b/Receiver.cpp index e027016..a8652f2 100644 --- a/Receiver.cpp +++ b/Receiver.cpp @@ -3,6 +3,7 @@ #include #include #ifndef PLATFORM_WINDOWS +# include # include #else # include diff --git a/Runtime.hpp b/Runtime.hpp index b4f4a17..6525342 100644 --- a/Runtime.hpp +++ b/Runtime.hpp @@ -91,6 +91,10 @@ class Runtime { public: Runtime() { + // Configure video + videoSetMode(MODE_0_2D); + lcdMainOnBottom(); + // Initialize console consoleDemoInit(); @@ -101,7 +105,8 @@ public: } // Initialize keyboard - swkbd = keyboardDemoInit(); + swkbd = keyboardGetDefault(); + swkbd = keyboardInit(swkbd, 3, BgType_Text4bpp, BgSize_T_256x512, swkbd->mapBase, swkbd->tileBase, true, true); swkbd->OnKeyPressed = kbCallback; } Runtime(Runtime&) = delete; diff --git a/Sender.cpp b/Sender.cpp index 539ba77..0e9d5cd 100644 --- a/Sender.cpp +++ b/Sender.cpp @@ -4,6 +4,7 @@ #include #ifndef PLATFORM_WINDOWS +# include # include #else # include