Example #1
0
rom_load_manager::rom_load_manager(running_machine &machine)
	: m_machine(machine)
{
	/* figure out which BIOS we are using */
	device_iterator deviter(machine.config().root_device());
	for (device_t *device = deviter.first(); device != nullptr; device = deviter.next()) {
		if (device->rom_region()) {
			std::string specbios;
			if (device->owner() == nullptr) {
				specbios.assign(machine.options().bios());
			} else {
				specbios = machine.options().sub_value(std::string(device->owner()->tag()).c_str()+1,"bios");
				if (specbios.empty()) {
					specbios = device->default_bios_tag();
				}
			}
			determine_bios_rom(device, specbios.c_str());
		}
	}

	/* count the total number of ROMs */
	count_roms();

	/* reset the disk list */
	m_chd_list.clear();

	/* process the ROM entries we were passed */
	process_region_list();

	/* display the results and exit */
	display_rom_load_results(FALSE);
}
Example #2
0
void rom_init(running_machine &machine)
{
	rom_load_data *romdata;

	/* allocate private data */
	machine.romload_data = romdata = auto_alloc_clear(machine, romload_private);

	/* make sure we get called back on the way out */
	machine.add_notifier(MACHINE_NOTIFY_EXIT, machine_notify_delegate(FUNC(rom_exit), &machine));

	/* reset the romdata struct */
	romdata->m_machine = &machine;

	/* figure out which BIOS we are using */
	determine_bios_rom(romdata);

	/* count the total number of ROMs */
	count_roms(romdata);

	/* reset the disk list */
	romdata->chd_list.reset();

	/* process the ROM entries we were passed */
	process_region_list(romdata);

	/* display the results and exit */
	display_rom_load_results(romdata);
}
Example #3
0
void rom_init(running_machine &machine)
{
	romload_private *romdata;

	/* allocate private data */
	machine.romload_data = romdata = auto_alloc_clear(machine, romload_private);

	/* make sure we get called back on the way out */
	machine.add_notifier(MACHINE_NOTIFY_EXIT, machine_notify_delegate(FUNC(rom_exit), &machine));

	/* reset the romdata struct */
	romdata->m_machine = &machine;

	/* figure out which BIOS we are using */
	device_iterator deviter(romdata->machine().config().root_device());
	for (device_t *device = deviter.first(); device != NULL; device = deviter.next()) {
		if (device->rom_region()) {
			const char *specbios;
			astring temp;
			if (strcmp(device->tag(),":")==0) {
				specbios = romdata->machine().options().bios();
			} else {
				specbios = romdata->machine().options().sub_value(temp,device->owner()->tag()+1,"bios");
				if (strlen(specbios) == 0) {
					specbios = device->default_bios_tag().cstr();
				}
			}
			determine_bios_rom(romdata, device, specbios);
		}
	}

	/* count the total number of ROMs */
	count_roms(romdata);

	/* reset the disk list */
	romdata->chd_list.reset();

	/* process the ROM entries we were passed */
	process_region_list(romdata);

	/* display the results and exit */
	display_rom_load_results(romdata, FALSE);
}