started migrating cartridge memory to struct