Assembler Project

Introduction

Over the summer I took a computer system’s class. In it we learned about low level system’s operations. We learned how instructions get translated from an assembly language to machine code and about logic gates. One of the overarching concepts was how operations are abstracted at different levels, from hardware logic gates all the way up to high level programming languages like C++. We focused on the assembly level of abstraction. The final project was to build a basic assembler. We used an assembly language called Pep9, which was created specifically for this class. Although Pep9 is a fairly basic, fundamental concepts learned using it apply to real life applications. Unfortunately, I am writing this post a few months after completing the project and forget a lot of the details. I will say though the overarching concept is to create a finite state that first parses a plain text file into valid tokens then translates those tokens into valid instructions. Below are two state diagrams for the parser and the translator.

Parser
Translator

If you wish too see more detail feel free to check out the GitHub repo for the project.

GitHub repo: https://github.com/zackthomas1/Pep9Assembler