diff --git a/Cosmos/source/Kernel-X86/10-CPU/Cosmos.CPU.x86/TempDebug.cs b/Cosmos/source/Kernel-X86/10-CPU/Cosmos.CPU.x86/TempDebug.cs index 1967d7a63..38a4404a3 100644 --- a/Cosmos/source/Kernel-X86/10-CPU/Cosmos.CPU.x86/TempDebug.cs +++ b/Cosmos/source/Kernel-X86/10-CPU/Cosmos.CPU.x86/TempDebug.cs @@ -2,17 +2,14 @@ namespace Cosmos.CPU.x86 { static public class TempDebug { - static public void ShowText() { + unsafe static byte* mPtr = (byte*)(0xB8000 - 1); + static public void ShowText(char aChar) { unsafe { - byte* xTest = (byte*)0xB8000; - *xTest = 65; - xTest = (byte*)0xB8001; - *xTest = 0x0A; + mPtr++; + *mPtr = (byte)aChar; - xTest = (byte*)0xB8002; - *xTest = 90; - xTest = (byte*)0xB8003; - *xTest = 0x0A; + mPtr++; + *mPtr = 0x0A; } } } diff --git a/Cosmos/source/Kernel-X86/20-Platform/Cosmos.Platform.PC/Devices/Processor.cs b/Cosmos/source/Kernel-X86/20-Platform/Cosmos.Platform.PC/Devices/Processor.cs index 60afc5cdf..a48109478 100644 --- a/Cosmos/source/Kernel-X86/20-Platform/Cosmos.Platform.PC/Devices/Processor.cs +++ b/Cosmos/source/Kernel-X86/20-Platform/Cosmos.Platform.PC/Devices/Processor.cs @@ -6,7 +6,7 @@ namespace Cosmos.Platform.PC.Devices { public class Processor : HAL.Devices.Processor { public override ulong SetOption(uint aID, ulong aValue = 0) { if (aID == 0) { - CPU.x86.TempDebug.ShowText(); + CPU.x86.TempDebug.ShowText('C'); } return 0; } diff --git a/Cosmos/source/Kernel-X86/30-HAL/Cosmos.HAL/DeviceMgr.cs b/Cosmos/source/Kernel-X86/30-HAL/Cosmos.HAL/DeviceMgr.cs index 2e85562f1..c6fa430ab 100644 --- a/Cosmos/source/Kernel-X86/30-HAL/Cosmos.HAL/DeviceMgr.cs +++ b/Cosmos/source/Kernel-X86/30-HAL/Cosmos.HAL/DeviceMgr.cs @@ -24,7 +24,7 @@ namespace Cosmos.HAL { mAll.Add(aDevice); if (aDevice is Processor) { - + mProcessor = (Processor)aDevice; } } } diff --git a/Cosmos/source/Kernel-X86/50-Application/Boot.cs b/Cosmos/source/Kernel-X86/50-Application/Boot.cs index 6cf9b6587..0c8847562 100644 --- a/Cosmos/source/Kernel-X86/50-Application/Boot.cs +++ b/Cosmos/source/Kernel-X86/50-Application/Boot.cs @@ -6,7 +6,8 @@ namespace KernelGen3 { static public class Boot { [BootEntry] static private void Init() { - Cosmos.CPU.x86.TempDebug.ShowText(); + Cosmos.CPU.x86.TempDebug.ShowText('A'); + Cosmos.CPU.x86.TempDebug.ShowText('c'); //Cosmos.System.Boot.TempDebugTest(); while (true) {