Fixed Main. Moved everything to emulator