feat: Smooth Snake game rendering and expand kernel subsystems

- Implement flicker-free atomic double-buffered frame rendering and sub-tick input polling in userland/lazybox/snake.c
- Add multi-input support (PS/2 keyboard scancodes and serial ANSI arrow escape sequences)
- Add sound effects (food beep, game over chime) and live speed scaling (+/- keys, P to pause)
- Add POSIX /dev/shm shared memory subsystem in ipc/shm_posix.c and include/ipc/shm_posix.h
- Add DNS resolver cache with TTL tracking in net/ipv4/dns_cache.c and include/net/dns_cache.h
- Add audio tone and jingle synthesizer in sound/beep.c and include/sound/beep.h
- Add %o octal formatting support in lib/vsprintf.c
- Add LazyBox applets: 'shm', 'dnscache', and 'beep'
This commit is contained in:
subhobhai943 committed 2026-08-21 01:47:37 +05:30
1 parent 7c510dae24
commit 6f7f60bf53
13 files changed
+495 -56

No files matched your search

+1 -1
View File
@@ -16,7 +16,7 @@ extern "C" {
extern ctor_fn_t __init_array_end[];
void cpp_call_global_constructors(void) {
if (__init_array_end <= __init_array_start) return;
if (+__init_array_end <= +__init_array_start) return;
size_t count = __init_array_end - __init_array_start;
for (size_t i = 0; i < count; i++) {
if (__init_array_start[i]) {
+7 -1
View File
@@ -58,6 +58,9 @@
#include <net/tcp.h>
#include <net/dhcp.h>
#include <net/dns.h>
#include <net/dns_cache.h>
#include <ipc/shm_posix.h>
#include <sound/beep.h>
#include <kernel/rust.h>
#include <kernel/sub_lang.h>
#include <kernel/cpp_kernel.h>
@@ -125,12 +128,14 @@ static void subos_modular_core_boot(void) {
tcp_init();
dhcp_init();
dns_init();
dns_cache_init();
printk(ANSI_BRIGHT_GREEN "Online\n" ANSI_RESET);
} else {
printk(ANSI_YELLOW "No NIC detected\n" ANSI_RESET);
}
#else
virtio_net_init();
dns_cache_init();
printk(ANSI_BRIGHT_GREEN "Online\n" ANSI_RESET);
#endif
@@ -156,8 +161,9 @@ static void subos_modular_core_boot(void) {
printk(ANSI_BRIGHT_GREEN "OK\n" ANSI_RESET);
// Inter-Process Communication
printk(KERN_INFO "[9/14] Initializing IPC Engine (Pipes, MsgQueues, SHM, Semaphores)... ");
printk(KERN_INFO "[9/14] Initializing IPC Engine (Pipes, MsgQueues, POSIX SHM, Semaphores)... ");
ipc_init();
posix_shm_init();
printk(ANSI_BRIGHT_GREEN "OK\n" ANSI_RESET);
// Asynchronous I/O Engine