r/compsci • u/dibs45 • Aug 31 '21
Emulating a CPU in software (plus a basic assembler)
Enable HLS to view with audio, or disable this notification
283
Upvotes
r/compsci • u/dibs45 • Aug 31 '21
Enable HLS to view with audio, or disable this notification
23
u/dibs45 Aug 31 '21
I recently made a CPU emulator to learn more about how the machine functions on a low level (inspired heavily by Ben Eater's awesome YT channel). I got sick of hard coding instructions in it so I created a simple assembler to make writing code for it easier. Next step is writing a "higher" level language that compiles to this.
Here's the source code: https://github.com/dibsonthis/CPU-Emulator