diff --git a/Config.ini b/Config.ini new file mode 100644 index 0000000..0870286 --- /dev/null +++ b/Config.ini @@ -0,0 +1,2 @@ +defeat_console_textcolor = white +defeat_console_color = black diff --git a/README.md b/README.md new file mode 100644 index 0000000..d5582c1 --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +это изменённая версия операционной системы randomOS добавлены множество новых файлов diff --git a/Service.RL b/Service.RL new file mode 100644 index 0000000..d98f298 --- /dev/null +++ b/Service.RL @@ -0,0 +1,5 @@ +void main(){ +set service +if d2 service send ab0 + send to d2 "Code 07" + diff --git a/Sysinfo.dat b/Sysinfo.dat new file mode 100644 index 0000000..42a78dd --- /dev/null +++ b/Sysinfo.dat @@ -0,0 +1,9 @@ +#include kernel.c + #include filessystem.c +RAM -kernelinfo + sysdisc -filesystem + section .service + move data to void + update + + diff --git a/headers/Sysinfo.h b/headers/Sysinfo.h new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/headers/Sysinfo.h @@ -0,0 +1 @@ + diff --git a/kernel.c b/kernel.c index ffd92a7..bf9ba3b 100644 --- a/kernel.c +++ b/kernel.c @@ -89,7 +89,8 @@ enum Commands { REBOOT, - CLEAR + CLEAR, + SYSINFO } Commands; void EverySecond(void) { @@ -400,7 +401,7 @@ void main(uint32 magic, struct multibootInfo* bootInfoArg) { uint32 (*program) (uint32, uint32) = (void*)(address); // Program definition - UGSMASCIIputString("Random OS --> "); + UGSMASCIIputString("RandomOS --> "); swap(); @@ -508,6 +509,7 @@ void main(uint32 magic, struct multibootInfo* bootInfoArg) { UGSMASCIIputString("\treboot --> Restarts the computer\n"); UGSMASCIIputString("\tclear --> Clears the console\n"); + UGSMASCIIputString("\tPRM --> print sysInfo\n"); } else if (command == ECHO) { @@ -603,8 +605,50 @@ void main(uint32 magic, struct multibootInfo* bootInfoArg) { reboot(); } + else if (command == SYSINFO) + UGSMASCIIputString("0.0.9 global version \n"); + if (RAMSize.gigabytes != 0) { + foregroundColor = 0xffff00; + + putUX16Integer(RAMSize.gigabytes); + + foregroundColor = 0x00ff00; + + UGSMASCIIputString(" gigabytes\n"); + } + + if (RAMSize.megabytes != 0) { + foregroundColor = 0xffff00; + + putUX16Integer(RAMSize.megabytes); + + foregroundColor = 0x00ff00; + + UGSMASCIIputString(" megabytes\n"); + } + + if (RAMSize.kilobytes != 0) { + foregroundColor = 0xffff00; + + putUX16Integer(RAMSize.kilobytes); + + foregroundColor = 0x00ff00; + + UGSMASCIIputString(" kilobytes\n"); + } + + if (RAMSize.bytes != 0) { + foregroundColor = 0xffff00; + + putUX16Integer(RAMSize.bytes); + + foregroundColor = 0x00ff00; - else if (command == CLEAR) { + UGSMASCIIputString(" bytes\n"); + } + + } + else if (command == CLEAR) { clear(backgroundColor); EverySecond(); @@ -699,4 +743,4 @@ void main(uint32 magic, struct multibootInfo* bootInfoArg) { } for (;;); -} \ No newline at end of file +}