Skip to content

rhetorica/chasm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CHASM Simulator

This VS Code project implements a simulator of the CHASM computer architecture. It is written in procedural C++ (minimal use of OOP).

About CHASM

CHASM's purpose is to provide a starting platform for the LETHE hobbyist operating system, and more generally to bootstrap microkernel-based systems being developed from scratch without using an off-the-shelf compiler toolchain. Like most real-world CPUs, CHASM is a von Neumann machine with a register-based architecture. In in terms of ISA complexity, CHASM is best described as semi-RISC. It uses 16-bit instruction words and memory addresses with 64-bit registers, and has a feature set a little larger than an early MIPS CPU.

See https://github.com/rhetorica/chas/blob/master/doc/chasm-spec.txt for a description of the CHASM CPU and related hardware, including the assembly language understood by the CHAS assembler.

Usage

CHASM requires SDL3.

On Windows, you will need MSYS64 to compile CHASM. A copy of SDL3.dll is included for Windows users.

To build CHASM, run cmake -S src build; cmake --build build in the project's root directory.

The syntax for running CHASM is:

`chasm [--v|--vv|--vvv] [--rom <filename>]`

`--v`: Enable verbose mode.
`--vv`: Enable very verbose mode.
`--vvv`: Enable very very verbose mode.
`--rom <filename>`: Path to the ROM file. This is a raw binary generated by CHAS with the default base address (0x020000000000).

The CHAS assembly language

See https://github.com/rhetorica/chas for the assembler.

Lethe

This repository is a component of the LETHE project, which aims to build a complete software stack based on the Dhar programming language. Read more at http://lethe.rhetori.ca/

Releases

No releases published

Packages

No packages published

Languages