Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/malwarebo/kernel
Tiny kernel built using x86 assembly
https://github.com/malwarebo/kernel
assembly-x86 kernel
Last synced: 5 days ago
JSON representation
Tiny kernel built using x86 assembly
- Host: GitHub
- URL: https://github.com/malwarebo/kernel
- Owner: malwarebo
- License: gpl-3.0
- Created: 2023-09-18T10:51:31.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-07-20T06:23:25.000Z (4 months ago)
- Last Synced: 2024-08-01T10:09:39.138Z (4 months ago)
- Topics: assembly-x86, kernel
- Language: Assembly
- Homepage:
- Size: 23.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Kernel
Minimal starting point for kernel development using x86 assmebly
[Basic kernel implementation of this paper](https://www.cs.vu.nl/~herbertb/misc/basickernel.pdf)## Usage
### Prerequisites
- A development environment for assembling and running x86 assembly code (e.g., NASM and QEMU).
- Basic knowledge of x86 assembly language.
- A virtual machine or computer with x86 architecture.## File Structure
```bash
- kernel/
- boot/
- bootloader.asm
- kernel/
- kernel.asm
- linker.ld```
## Steps to Build and Run
- Assemble the bootloader and kernel using NASM:
```bash
nasm -f bin boot/bootloader.asm -o bootloader.bin
nasm -f elf32 kernel/kernel.asm -o kernel.o
ld -T kernel/linker.ld kernel.o -o kernel.bin
```- Combine the bootloader and kernel into a single image:
```bash
cat bootloader.bin kernel.bin > os-image.bin
```- Run the kernel using QEMU
```bash
qemu-system-i386 -fda os-image.bin
```The QEMU emulator should launch, and you will see the output of your simple kernel, which in this case, clears the screen and prints 'H' in white text on a black background. The kernel will enter an infinite loop to keep it running.