🌐 US-Proxy
class="logged-out env-production page-responsive" style="word-wrap: break-word;" >
Skip to content

Repository files navigation

MicroBot-8bit

GitHub License codecov Docs Ask DeepWiki GitHub top language GitHub code size in bytes

MicroBot-8bit is an 8-bit microcomputer in the vein of the ZX Spectrum/Commodore 64, originally inspired by CHIP-8. It comes with a tiny CP/M-like OS layer, a GPU TTY, keyboard input, and a disk-backed filesystem stub.

sh.bin pong.bin
mb8.mov

Running

Compile assembly

The assembler is implemented in Rust and is part of this workspace. No external assembler is required.

Build the kernel and user-space programs:

make all

To assemble one file directly:

cargo run --quiet -p asm -- build user/sh.asm -o user/sh.bin

Check a source without writing a binary (warnings cause a non-zero exit code):

cargo run --quiet -p asm -- check user/sh.asm

Targets:

  • make kernel — build the kernel image (kernel/main.bin)
  • make user — build user-space programs under user/

Run VM

After building, run the VM with the kernel entrypoint first and then any user programs:

make run

The first path is always the kernel; subsequent arguments are user-space binaries loaded by the OS.

Assembly

User-space programs live under user/. For a minimal shell example, see user/sh.asm; build with make user and run with the kernel:

make run

High-level language compiler

There was an attempt to build a compiler for a high-level programming language targeting this platform, but it did not work out. The latest work on that compiler can be seen in commit 57ce5eba284f069251eb0563cf06fe6a24da53d7.

Architecture

Full documentation can be found in the book.

About

8-bit fantasy computer. Inspired by CHIP-8, ZX Spectrum, Commodore 64. With custom programming language for 8-bit microcomputer

Topics

Resources

Code of conduct

Contributing

Stars

5 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages