예제 #1
0
파일: tutor.cpp 프로젝트: MASHinfo/mame
void tutor_state::machine_start()
{
	std::string region_tag;
	m_cart_rom = memregion(region_tag.assign(m_cart->tag()).append(GENERIC_ROM_REGION_TAG).c_str());

	m_tape_interrupt_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(tutor_state::tape_interrupt_handler),this));

	m_bank1->configure_entry(0, memregion("maincpu")->base() + 0x4000);
	m_bank1->set_entry(0);
	m_bank2->configure_entry(0, memregion("maincpu")->base() + 0x8000);
	m_bank2->set_entry(0);

	if (m_cart_rom)
	{
		if (m_cart_rom->bytes() > 0x4000)
		{
			m_bank1_switching = 1;
			m_bank1->configure_entry(1, m_cart_rom->base());
			m_bank1->set_entry(1);
			m_bank2->configure_entry(1, m_cart_rom->base() + 0x4000);
			m_bank2->set_entry(1);
		}
		else
		{
			m_bank2->configure_entry(1, m_cart_rom->base());
			m_bank2->set_entry(1);
		}
	}
}
예제 #2
0
파일: skimaxx.cpp 프로젝트: rfka01/mame
void skimaxx_state::video_start()
{
	m_bg_buffer = std::make_unique<u32[]>(0x400 * 0x100 * sizeof(u16) / sizeof(u32) * 2); // 2 buffers
	m_bg_buffer_back  = m_bg_buffer.get() + 0x400 * 0x100 * sizeof(u16) / sizeof(u32) * 0;
	m_bg_buffer_front = m_bg_buffer.get() + 0x400 * 0x100 * sizeof(u16) / sizeof(u32) * 1;
	m_bgrambank->configure_entry(0, m_bg_buffer_back);
	m_bgrambank->configure_entry(1, m_bg_buffer_front);

	save_item(NAME(m_blitter_src_x));
	save_item(NAME(m_blitter_src_y));
	save_item(NAME(m_blitter_src_dx));
	save_item(NAME(m_blitter_src_dy));
}
예제 #3
0
파일: iq151.cpp 프로젝트: SailorSat/cabmame
void iq151_state::machine_start()
{
	uint8_t *RAM = memregion("maincpu")->base();
	m_boot_bank->configure_entry(0, RAM + 0xf800);
	m_boot_bank->configure_entry(1, RAM + 0x0000);
}