Kernel that only runs an NES emulator
The Nintendo Entertainment Kernel is a simple kernel designed to run an NES emulator, requiring no additional operating system. This bare-bones kernel lacks paging, userspace, and any form of protection. It is programmed to run only a single program, embedded directly into the kernel's code. The kernel can be built using the make command with the cross-compiler path set, generating a kernel.elf file in the bin folder. Besides the emulador program, three other functional programs can also be compiled using the kernel.
To utilize the kernel, copy the resulting kernel.elf file to the /boot folder and add an entry to the /etc/grub.d/40_custom file, specifying the kernel and initrd.img files. The makefile is configured to run QEMU using the provided disk image disk.img, with a loop device set up in the mount folder. The kernel's base system initialization is handled by kernel_entry() in kernel/arch/x86/init/boot.s, followed by kmain() in kernel/kmain.c, which starts various services.
Finally, the main program is executed within the main() function in program/main.(c|cpp). This Nintendo Entertainment Kernel serves the sole purpose of running NES emulators.
Written by urgent.news from Lobsters's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.