#assembly #emulator #processor #advanced #cpu #specification #teaching

app patp

An emulator and assembler for the Pedagogically Advanced Teaching Processor

2 releases

0.1.2 Oct 25, 2021
0.1.1 Aug 26, 2021
0.1.0 Aug 26, 2021

#3 in #teaching

30 downloads per month

MIT license

27KB
664 lines

PATP toolkit

This is an assembler and emulator for the PATP (Pedagogically Advanced Teaching Processor), a simple microprocessor designed for teaching CS132 Computer Organisation and Architecture at The University of Warwick. The processor specification and assembly language documentation is outlined in the specification.

Usage

The program can be installed with cargo install patp . If you don't already have cargo installed, see here for instructions on how to install rust and cargo.

  • patp emulate <file> will execute a binary file and return the final CPU state
  • patp assemble <file> will assemble the .patp file and create a new binary file
  • patp run <file> will assemble and then execute a file

If you'd prefer to download the source and compile yourself, clone the repo and run cargo build. cargo test will also run all the unit test, verifying the correctness of the assembler and emulator.

Dependencies

~0.8–1.3MB
~27K SLoC