Mazin-O3/freecpm

A CP/M-inspired operating system

44

stars

20

commits

C

primary language

Sep 10, 2026

updated

cpm
operating-system
risc-v

README

CP/M Neo logo

CP/M Neo

A CP/M-inspired operating system

Try it Online GitHub Repo stars GitHub forks GitHub contributors License

cpm-neo main

Quick Start

CP/M Neo requires a bare-metal cross-compiler toolchain for your target architecture (arch/<isa>/config.sh supplies the toolchain prefix and flags), make, and sh.

make -C sysgen
./sysgen/build/sysgen new --disk-size=2048K --mem=64K --platform=vemu

Everything outputs directly to sysgen/build/:

FilePurpose
disk.imgFinal disk image
bootloader.binBoot image
core/int/kernel.binkernel binary
core/int/ccp.binConsole Command Processor (CCP) binary
apps/Bundled Apps

To clean up the build environment, run:

make -C sysgen clean

See the User Guide for the full build and execution walkthrough.


The Sysgen Tool

sysgen is the host utility for building and inspecting CP/M Neo disk images. Commands other than new support appending --disk=path to target a specific image; new always writes to sysgen/build/disk.img.

CommandDescription
new --disk-size=KBK --mem=KBK --platform=NAMEBuild the OS and create a disk image (the disk is divided into 1 KB blocks; --disk-size is capped at the useful maximum: 2 MB). NAME is the 8-char max platform id declared by ID= in a platform's config.sh
add <file> [--dst=Vn] [--attr=R/W|R/O|SYS]Add an external file to an image
install <folder> [--dst=Vn] [--attr=...]Compile a source folder and install the binaries
dir [Vn]List files on a volume
type <name> [Vn]Print a file
era <name> [Vn]Delete a file
ren <old> <new> [Vn]Rename a file
statShow volume usage and metadata

Platforms are defined in platform/<name>/: config.sh plus bios.c implementing the console and storage functions from core/kernel/bios.h.

See the Developer Guide to add your own.

Documentation Library

DocumentDescription
User GuideBuild, run, and get started
CCP ReferenceConsole Command Processor guide
Disk FormatCP/M Neo disk image layout
Syscall ReferenceComplete syscall API and ABI specifications
Bundled AppsAuto-installed programs
Developer GuideSDK usage, compiling applications, and adding platforms
ArchitectureMemory layout, boot flow, and build internals

Contributing

Contributions to CP/M Neo are welcome!

If you'd like to contribute, see CONTRIBUTING.md for more info.


License

CP/M Neo is distributed under the terms of the open-source MIT.

Contributors

Mazin-O3

20 commits

Mazin-O3/freecpm

A CP/M-inspired operating system

44

stars

20

commits

C

primary language

Sep 10, 2026

updated

cpm
operating-system
risc-v

README

CP/M Neo logo

CP/M Neo

A CP/M-inspired operating system

Try it Online GitHub Repo stars GitHub forks GitHub contributors License

cpm-neo main

Quick Start

CP/M Neo requires a bare-metal cross-compiler toolchain for your target architecture (arch/<isa>/config.sh supplies the toolchain prefix and flags), make, and sh.

make -C sysgen
./sysgen/build/sysgen new --disk-size=2048K --mem=64K --platform=vemu

Everything outputs directly to sysgen/build/:

FilePurpose
disk.imgFinal disk image
bootloader.binBoot image
core/int/kernel.binkernel binary
core/int/ccp.binConsole Command Processor (CCP) binary
apps/Bundled Apps

To clean up the build environment, run:

make -C sysgen clean

See the User Guide for the full build and execution walkthrough.


The Sysgen Tool

sysgen is the host utility for building and inspecting CP/M Neo disk images. Commands other than new support appending --disk=path to target a specific image; new always writes to sysgen/build/disk.img.

CommandDescription
new --disk-size=KBK --mem=KBK --platform=NAMEBuild the OS and create a disk image (the disk is divided into 1 KB blocks; --disk-size is capped at the useful maximum: 2 MB). NAME is the 8-char max platform id declared by ID= in a platform's config.sh
add <file> [--dst=Vn] [--attr=R/W|R/O|SYS]Add an external file to an image
install <folder> [--dst=Vn] [--attr=...]Compile a source folder and install the binaries
dir [Vn]List files on a volume
type <name> [Vn]Print a file
era <name> [Vn]Delete a file
ren <old> <new> [Vn]Rename a file
statShow volume usage and metadata

Platforms are defined in platform/<name>/: config.sh plus bios.c implementing the console and storage functions from core/kernel/bios.h.

See the Developer Guide to add your own.

Documentation Library

DocumentDescription
User GuideBuild, run, and get started
CCP ReferenceConsole Command Processor guide
Disk FormatCP/M Neo disk image layout
Syscall ReferenceComplete syscall API and ABI specifications
Bundled AppsAuto-installed programs
Developer GuideSDK usage, compiling applications, and adding platforms
ArchitectureMemory layout, boot flow, and build internals

Contributing

Contributions to CP/M Neo are welcome!

If you'd like to contribute, see CONTRIBUTING.md for more info.


License

CP/M Neo is distributed under the terms of the open-source MIT.

Contributors

Mazin-O3

20 commits

Languages

C

92.1%

Shell

4.4%

Assembly

1.6%

Linker Script

1.2%