Got the emulator working.
Squashed remaining bugs.