CPU Emulator

A project log for AYTABTU - Discrete Computer

After the apocalypse we have to build computers from stuff we can make at home, I.E Transistors, diodes and resistors.

matsengmatseng 07/24/2015 at 10:450 Comments

It only took me about four hours to whip up an emulator for the CPU using golang and a library called termbox to handle the output to the screen (it's a lightweight version of curses). Since I'm an old C programmer and this is only my second golang application it probably have a lot of ugly C-mannerisms in the code - but it works and can execute the code I fed to it.

I still need to implement some rather important functions like Load code from file and Edit data in the code- and data RAM spaces.

It could also be nice to have a simulated serial port/uart on a tcp socket that can be telnetted to.

And highlighting of fields that have changed during the last executed opcode as well - that would look very professional :-)

So a couple of hours more tonight to finish off the emulator....