General cleanup.
Experimenting with running the emulator programatically.