当前位置: 首页>>代码示例>>C++>>正文


C++ SPEAKER函数代码示例

本文整理汇总了C++中SPEAKER函数的典型用法代码示例。如果您正苦于以下问题:C++ SPEAKER函数的具体用法?C++ SPEAKER怎么用?C++ SPEAKER使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了SPEAKER函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: MC6809E

void enmirage_state::mirage(machine_config &config)
{
	MC6809E(config, m_maincpu, 2000000);
	m_maincpu->set_addrmap(AS_PROGRAM, &enmirage_state::mirage_map);

	config.set_default_layout(layout_mirage);

	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();
	es5503_device &es5503(ES5503(config, "es5503", 7000000));
	es5503.set_channels(2);
	es5503.irq_func().set(FUNC(enmirage_state::mirage_doc_irq));
	es5503.adc_func().set(FUNC(enmirage_state::mirage_adc_read));
	es5503.add_route(0, "lspeaker", 1.0);
	es5503.add_route(1, "rspeaker", 1.0);

	VIA6522(config, m_via, 1000000);
	m_via->writepa_handler().set(FUNC(enmirage_state::mirage_via_write_porta));
	m_via->writepb_handler().set(FUNC(enmirage_state::mirage_via_write_portb));
	m_via->irq_handler().set_inputline(m_maincpu, M6809_IRQ_LINE);

	acia6850_device &acia6850(ACIA6850(config, "acia6850", 0));
	acia6850.irq_handler().set_inputline(m_maincpu, M6809_FIRQ_LINE);

	WD1772(config, m_fdc, 8000000);
	m_fdc->intrq_wr_callback().set_inputline(m_maincpu, INPUT_LINE_NMI);
	m_fdc->drq_wr_callback().set_inputline(m_maincpu, M6809_IRQ_LINE);

	FLOPPY_CONNECTOR(config, "wd1772:0", ensoniq_floppies, "35dd", enmirage_state::floppy_formats);
}
开发者ID:MASHinfo,项目名称:mame,代码行数:30,代码来源:enmirage.cpp

示例2: PPC403GCX

void konendev_state::konendev(machine_config &config)
{
	/* basic machine hardware */
	PPC403GCX(config, m_maincpu, 32000000); // Clock unknown
	m_maincpu->set_addrmap(AS_PROGRAM, &konendev_state::konendev_map);
	m_maincpu->set_vblank_int("screen", FUNC(konendev_state::vbl_interrupt));

	/* video hardware */
	PALETTE(config, "palette", palette_device::RGB_555);

	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); // Not accurate
	screen.set_size(640, 480);
	screen.set_visarea(0, 639, 0, 479);
	screen.set_screen_update(FUNC(konendev_state::screen_update));
	screen.set_palette("palette");

	K057714(config, m_gcu, 0);
	m_gcu->irq_callback().set(FUNC(konendev_state::gcu_interrupt));

	NVRAM(config, "nvram0", nvram_device::DEFAULT_ALL_0);
	NVRAM(config, "nvram1", nvram_device::DEFAULT_ALL_0);

	EEPROM_93C56_16BIT(config, "eeprom");

	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	ymz280b_device &ymz(YMZ280B(config, "ymz", 16934400)); // Clock unknown
	ymz.add_route(0, "lspeaker", 1.0);
	ymz.add_route(1, "rspeaker", 1.0);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:34,代码来源:konendev.cpp

示例3: I8052

void acvirus_state::virus(machine_config &config)
{
	I8052(config, m_maincpu, XTAL(12'000'000));
	m_maincpu->set_addrmap(AS_PROGRAM, &acvirus_state::virus_map);

	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:8,代码来源:acvirus.cpp

示例4: GFXDECODE_START

/*************************************
 *
 *  Graphics definitions
 *
 *************************************/

static const gfx_layout playfield_layout =
{
	8,8,
	256,
	1,
	{ 0 },
	{ 0, 1, 2, 3, 4, 5, 6, 7 },
	{ 0, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
	8*8
};


static const gfx_layout motion_layout =
{
	16,16,
	64,
	1,
	{ 0 },
	{ 3 + 0x400*8, 2 + 0x400*8, 1 + 0x400*8, 0 + 0x400*8,
		7 + 0x400*8, 6 + 0x400*8, 5 + 0x400*8, 4 + 0x400*8,
		3, 2, 1, 0, 7, 6, 5, 4 },
	{ 0, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8,
		8*8, 9*8, 10*8, 11*8, 12*8, 13*8, 14*8, 15*8 },
	16*8
};


static GFXDECODE_START( gfx_subs )
	GFXDECODE_ENTRY( "gfx1", 0, playfield_layout, 0, 2 )    /* playfield graphics */
	GFXDECODE_ENTRY( "gfx2", 0, motion_layout,    0, 2 )    /* motion graphics */
GFXDECODE_END


/*************************************
 *
 *  Machine driver
 *
 *************************************/

void subs_state::subs(machine_config &config)
{
	/* basic machine hardware */
	M6502(config, m_maincpu, 12096000/16);      /* clock input is the "4H" signal */
	m_maincpu->set_addrmap(AS_PROGRAM, &subs_state::main_map);
	m_maincpu->set_periodic_int(FUNC(subs_state::interrupt), attotime::from_hz(4*57));


	/* video hardware */
	GFXDECODE(config, m_gfxdecode, m_palette, gfx_subs);

	PALETTE(config, m_palette, FUNC(subs_state::subs_palette), 4);

	config.set_default_layout(layout_dualhsxs);

	screen_device &lscreen(SCREEN(config, "lscreen", SCREEN_TYPE_RASTER));
	lscreen.set_refresh_hz(57);
	lscreen.set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	lscreen.set_size(32*8, 32*8);
	lscreen.set_visarea(0*8, 32*8-1, 0*8, 28*8-1);
	lscreen.set_screen_update(FUNC(subs_state::screen_update_left));
	lscreen.set_palette(m_palette);

	screen_device &rscreen(SCREEN(config, "rscreen", SCREEN_TYPE_RASTER));
	rscreen.set_refresh_hz(57);
	rscreen.set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	rscreen.set_size(32*8, 32*8);
	rscreen.set_visarea(0*8, 32*8-1, 0*8, 28*8-1);
	rscreen.set_screen_update(FUNC(subs_state::screen_update_right));
	rscreen.set_palette(m_palette);


	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	DISCRETE(config, m_discrete, subs_discrete).add_route(0, "lspeaker", 1.0).add_route(1, "rspeaker", 1.0);

	ls259_device &latch(LS259(config, "latch")); // C9
	latch.q_out_cb<0>().set_output("led0").invert(); // START LAMP 1
	latch.q_out_cb<1>().set_output("led1").invert(); // START LAMP 2
	latch.q_out_cb<2>().set(m_discrete, FUNC(discrete_device::write_line<SUBS_SONAR2_EN>));
	latch.q_out_cb<3>().set(m_discrete, FUNC(discrete_device::write_line<SUBS_SONAR1_EN>));
	// Schematics show crash and explode reversed.  But this is proper.
	latch.q_out_cb<4>().set(m_discrete, FUNC(discrete_device::write_line<SUBS_EXPLODE_EN>));
	latch.q_out_cb<5>().set(m_discrete, FUNC(discrete_device::write_line<SUBS_CRASH_EN>));
	latch.q_out_cb<6>().set(FUNC(subs_state::invert1_w));
	latch.q_out_cb<7>().set(FUNC(subs_state::invert2_w));
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:94,代码来源:subs.cpp

示例5: PPC603

void macpci_state::pippin(machine_config &config)
{
	/* basic machine hardware */
	PPC603(config, m_maincpu, 66000000);
	m_maincpu->set_addrmap(AS_PROGRAM, &macpci_state::pippin_mem);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(60);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
	screen.set_size(640, 480);
	screen.set_visarea(0, 640-1, 0, 480-1);
	screen.set_screen_update(FUNC(macpci_state::screen_update_pippin));
	screen.set_palette("palette");

	palette_device &palette(PALETTE(config, "palette", 2));
	palette.set_init("palette", FUNC(palette_device::palette_init_monochrome));

	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	cdda_device &cdda(CDDA(config, "cdda"));
	cdda.add_route(0, "lspeaker", 1.00);
	cdda.add_route(1, "rspeaker", 1.00);

	cdrom_image_device &cdrom(CDROM(config, "cdrom", 0));
	cdrom.set_interface("pippin_cdrom");
	SOFTWARE_LIST(config, "cd_list").set_type("pippin", SOFTWARE_LIST_ORIGINAL_SYSTEM);

	RAM(config, m_ram);
	m_ram->set_default_size("32M");

	VIA6522(config, m_via1, C7M/10);
	m_via1->readpa_handler().set(FUNC(macpci_state::mac_via_in_a));
	m_via1->readpb_handler().set(FUNC(macpci_state::mac_via_in_b));
	m_via1->writepa_handler().set(FUNC(macpci_state::mac_via_out_a));
	m_via1->writepb_handler().set(FUNC(macpci_state::mac_via_out_b));
	m_via1->cb2_handler().set(FUNC(macpci_state::mac_adb_via_out_cb2));
	m_via1->irq_handler().set(FUNC(macpci_state::mac_via_irq));

	//scc8530_t &scc(SCC8530(config, "scc", C7M));
	//scc.intrq_callback().set(FUNC(macpci_state::set_scc_interrupt));
	CUDA(config, m_cuda, 0);
	m_cuda->set_type(CUDA_341S0060);
	m_cuda->reset_callback().set(FUNC(macpci_state::cuda_reset_w));
	m_cuda->linechange_callback().set(FUNC(macpci_state::cuda_adb_linechange_w));
	m_cuda->via_clock_callback().set(m_via1, FUNC(via6522_device::write_cb1));
	m_cuda->via_data_callback().set(m_via1, FUNC(via6522_device::write_cb2));
	config.m_perfect_cpu_quantum = subtag("maincpu");
}
开发者ID:MASHinfo,项目名称:mame,代码行数:51,代码来源:macpci.cpp

示例6: CXD8530BQ

void konamigq_state::konamigq(machine_config &config)
{
	/* basic machine hardware */
	CXD8530BQ(config, m_maincpu, XTAL(67'737'600));
	m_maincpu->set_addrmap(AS_PROGRAM, &konamigq_state::konamigq_map);
	m_maincpu->subdevice<psxdma_device>("dma")->install_read_handler(5, psxdma_device::read_delegate(&konamigq_state::scsi_dma_read, this));
	m_maincpu->subdevice<psxdma_device>("dma")->install_write_handler(5, psxdma_device::write_delegate(&konamigq_state::scsi_dma_write, this));
	m_maincpu->subdevice<ram_device>("ram")->set_default_size("4M");

	M68000(config, m_soundcpu, XTAL(32'000'000)/4); /* 8MHz - measured */
	m_soundcpu->set_addrmap(AS_PROGRAM, &konamigq_state::konamigq_sound_map);

	TMS57002(config, m_dasp, XTAL(48'000'000)/2); /* 24MHz - measured */
	m_dasp->set_addrmap(AS_DATA, &konamigq_state::konamigq_dasp_map);
	m_dasp->set_periodic_int(FUNC(konamigq_state::tms_sync), attotime::from_hz(48000));

	MB89371(config, "mb89371", 0);

	EEPROM_93C46_16BIT(config, "eeprom").default_data(konamigq_def_eeprom, 128);

	scsi_port_device &scsi(SCSI_PORT(config, "scsi", 0));
	scsi.set_slot_device(1, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_0));

	AM53CF96(config, m_am53cf96, 0);
	m_am53cf96->set_scsi_port("scsi");
	m_am53cf96->irq_handler().set("maincpu:irq", FUNC(psxirq_device::intin10));

	/* video hardware */
	CXD8538Q(config, "gpu", XTAL(53'693'175), 0x200000, subdevice<psxcpu_device>("maincpu")).set_screen("screen");

	SCREEN(config, "screen", SCREEN_TYPE_RASTER);

	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	K056800(config, m_k056800, XTAL(18'432'000));
	m_k056800->int_callback().set_inputline(m_soundcpu, M68K_IRQ_1);

	k054539_device &k054539_1(K054539(config, "k054539_1", XTAL(18'432'000)));
	k054539_1.set_addrmap(0, &konamigq_state::konamigq_k054539_map);
	k054539_1.timer_handler().set(FUNC(konamigq_state::k054539_irq_gen));
	k054539_1.add_route(0, "lspeaker", 1.0);
	k054539_1.add_route(1, "rspeaker", 1.0);

	k054539_device &k054539_2(K054539(config, "k054539_2", XTAL(18'432'000)));
	k054539_2.set_addrmap(0, &konamigq_state::konamigq_k054539_map);
	k054539_2.add_route(0, "lspeaker", 1.0);
	k054539_2.add_route(1, "rspeaker", 1.0);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:50,代码来源:konamigq.cpp

示例7: M68000

void esqkt_state::ts(machine_config &config)
{
	M68000(config, m_maincpu, 16_MHz_XTAL);
	m_maincpu->set_addrmap(AS_PROGRAM, &esqkt_state::ts_map);
	ES5510(config, m_esp, 10_MHz_XTAL);
	m_esp->set_disable();

	auto &panel(ESQPANEL2X40_VFX(config, "sq1panel"));
	panel.write_tx().set(m_duart, FUNC(scn2681_device::rx_b_w));

	SCN2681(config, m_duart, 4000000);
	m_duart->irq_cb().set(FUNC(esqkt_state::duart_irq_handler));
	m_duart->a_tx_cb().set(FUNC(esqkt_state::duart_tx_a));
	m_duart->b_tx_cb().set(FUNC(esqkt_state::duart_tx_b));
	m_duart->outport_cb().set(FUNC(esqkt_state::duart_output));
	m_duart->set_clocks(500000, 500000, 1000000, 1000000);

	auto &mdin(MIDI_PORT(config, "mdin"));
	midiin_slot(mdin);
	mdin.rxd_handler().set(m_duart, FUNC(scn2681_device::rx_a_w)); // route MIDI Tx send directly to 68681 channel A Rx

	midiout_slot(MIDI_PORT(config, "mdout"));

	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	ESQ_5505_5510_PUMP(config, m_pump, 16_MHz_XTAL / (16 * 32));
	m_pump->set_esp(m_esp);
	m_pump->add_route(0, "lspeaker", 1.0);
	m_pump->add_route(1, "rspeaker", 1.0);

	auto &es5506a(ES5506(config, "ensoniq", 16_MHz_XTAL));
	es5506a.sample_rate_changed().set(FUNC(esqkt_state::es5506_clock_changed));
	es5506a.set_region0("waverom");  /* Bank 0 */
	es5506a.set_region1("waverom2"); /* Bank 1 */
	es5506a.set_region2("waverom3"); /* Bank 0 */
	es5506a.set_region3("waverom4"); /* Bank 1 */
	es5506a.set_channels(4);          /* channels */
	es5506a.irq_cb().set(FUNC(esqkt_state::esq5506_otto_irq)); /* irq */
	es5506a.read_port_cb().set(FUNC(esqkt_state::esq5506_read_adc)); /* ADC */
	es5506a.add_route(0, "pump", 1.0, 0);
	es5506a.add_route(1, "pump", 1.0, 1);
	es5506a.add_route(2, "pump", 1.0, 2);
	es5506a.add_route(3, "pump", 1.0, 3);
	es5506a.add_route(4, "pump", 1.0, 4);
	es5506a.add_route(5, "pump", 1.0, 5);
	es5506a.add_route(6, "pump", 1.0, 6);
	es5506a.add_route(7, "pump", 1.0, 7);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:49,代码来源:esqkt.cpp

示例8: RGN_FRAC

/*************************************
 *
 *  Graphics definitions
 *
 *************************************/

static const gfx_layout anlayout =
{
	8,8,
	RGN_FRAC(1,1),
	2,
	{ 0, 4 },
	{ 0, 1, 2, 3, 8, 9, 10, 11 },
	{ 0*16, 1*16, 2*16, 3*16, 4*16, 5*16, 6*16, 7*16 },
	8*16
};


static const gfx_layout pfmolayout =
{
	8,8,
	RGN_FRAC(1,4),
	4,
	{ RGN_FRAC(0,4), RGN_FRAC(1,4), RGN_FRAC(2,4), RGN_FRAC(3,4) },
	{ 0, 1, 2, 3, 4, 5, 6, 7 },
	{ 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 },
	8*8
};


static GFXDECODE_START( gfx_vindictr )
	GFXDECODE_ENTRY( "gfx1", 0, pfmolayout,  256, 32 )      /* sprites & playfield */
	GFXDECODE_ENTRY( "gfx2", 0, anlayout,      0, 64 )      /* characters 8x8 */
GFXDECODE_END



/*************************************
 *
 *  Machine driver
 *
 *************************************/

void vindictr_state::vindictr(machine_config &config)
{
	/* basic machine hardware */
	M68010(config, m_maincpu, ATARI_CLOCK_14MHz/2);
	m_maincpu->set_addrmap(AS_PROGRAM, &vindictr_state::main_map);

	EEPROM_2804(config, "eeprom").lock_after_write(true);

	WATCHDOG_TIMER(config, "watchdog");

	/* video hardware */
	GFXDECODE(config, m_gfxdecode, m_palette, gfx_vindictr);
	PALETTE(config, m_palette).set_entries(2048*8);

	TILEMAP(config, m_playfield_tilemap, m_gfxdecode, 2, 8,8, TILEMAP_SCAN_COLS, 64,64).set_info_callback(FUNC(vindictr_state::get_playfield_tile_info));
	TILEMAP(config, m_alpha_tilemap, m_gfxdecode, 2, 8,8, TILEMAP_SCAN_ROWS, 64,32, 0).set_info_callback(FUNC(vindictr_state::get_alpha_tile_info));

	ATARI_MOTION_OBJECTS(config, m_mob, 0, m_screen, vindictr_state::s_mob_config);
	m_mob->set_gfxdecode(m_gfxdecode);

	SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
	m_screen->set_video_attributes(VIDEO_UPDATE_BEFORE_VBLANK);
	/* note: these parameters are from published specs, not derived */
	/* the board uses a SYNGEN chip to generate video signals */
	m_screen->set_raw(ATARI_CLOCK_14MHz/2, 456, 0, 336, 262, 0, 240);
	m_screen->set_screen_update(FUNC(vindictr_state::screen_update_vindictr));
	m_screen->set_palette(m_palette);

	/* sound hardware */
	SPEAKER(config, "lspeaker").front_left();
	SPEAKER(config, "rspeaker").front_right();

	ATARI_JSA_I(config, m_jsa, 0);
	m_jsa->main_int_cb().set_inputline(m_maincpu, M68K_IRQ_6);
	m_jsa->test_read_cb().set_ioport("260010").bit(12);
	m_jsa->add_route(0, "lspeaker", 1.0);
	m_jsa->add_route(1, "rspeaker", 1.0);
	config.device_remove("jsa:tms");
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:82,代码来源:vindictr.cpp

示例9: SPEAKER

void satansat_sound_device::device_add_mconfig(machine_config &config)
{
	SPEAKER(config, "mono").front_center();

	SNK6502_SOUND(config, m_custom, 0);
	m_custom->add_route(ALL_OUTPUTS, "mono", 0.50);

	samples_device &samples(SAMPLES(config, "samples"));
	samples.set_channels(3);
	samples.set_samples_names(vanguard_sample_names);
	samples.add_route(ALL_OUTPUTS, "mono", 0.25);

	sn76477_device &sn76477_1(SN76477(config, "sn76477.1"));
	// ???      GND: 2,26,27        +5V: 15,25
	sn76477_1.set_noise_params(RES_K(470), RES_M(1.5), CAP_P(220));
	sn76477_1.set_decay_res(0);
	sn76477_1.set_attack_params(0, 0);
	sn76477_1.set_amp_res(RES_K(47));
	sn76477_1.set_feedback_res(RES_K(47));
	sn76477_1.set_vco_params(0, 0, 0);
	sn76477_1.set_pitch_voltage(0);
	sn76477_1.set_slf_params(0, 0);
	sn76477_1.set_oneshot_params(0, 0);
	sn76477_1.set_vco_mode(0);
	sn76477_1.set_mixer_params(0, 1, 0);
	sn76477_1.set_envelope_params(1, 1);
	sn76477_1.set_enable(1);
	sn76477_1.add_route(ALL_OUTPUTS, "mono", 1.0);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:29,代码来源:snk6502.cpp

示例10: S2650

GFXDECODE_END


void subhuntr_state::subhuntr(machine_config &config)
{
	/* basic machine hardware */
	S2650(config, m_maincpu, 14318180/4/2);
	m_maincpu->set_addrmap(AS_PROGRAM, &subhuntr_state::subhuntr_map);
	m_maincpu->set_addrmap(AS_IO, &subhuntr_state::subhuntr_io_map);
	m_maincpu->set_addrmap(AS_DATA, &subhuntr_state::subhuntr_data_map);
	m_maincpu->set_vblank_int("screen", FUNC(subhuntr_state::subhuntr_interrupt));
	m_maincpu->sense_handler().set("screen", FUNC(screen_device::vblank));

	s2636_device &s2636(S2636(config, "s2636", 0));
	s2636.set_offsets(3, -21);
	s2636.add_route(ALL_OUTPUTS, "mono", 0.10);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_video_attributes(VIDEO_ALWAYS_UPDATE);
	screen.set_refresh_hz(50);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
	screen.set_size(256, 256);
	screen.set_visarea(1*8, 29*8-1, 2*8, 32*8-1);
	screen.set_screen_update(FUNC(subhuntr_state::screen_update_subhuntr));
	screen.set_palette("palette");

	GFXDECODE(config, "gfxdecode", "palette", gfx_subhuntr);
	PALETTE(config, "palette", FUNC(subhuntr_state::subhuntr_palette), 26);

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	/* discrete sound */
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:35,代码来源:subhuntr.cpp

示例11: Z8001

GFXDECODE_END

void c900_state::c900(machine_config &config)
{
	/* basic machine hardware */
	Z8001(config, m_maincpu, 12_MHz_XTAL / 2);
	m_maincpu->set_addrmap(AS_PROGRAM, &c900_state::mem_map);
	m_maincpu->set_addrmap(AS_DATA, &c900_state::data_map);
	m_maincpu->set_addrmap(AS_IO, &c900_state::io_map);
	m_maincpu->set_addrmap(z8001_device::AS_SIO, &c900_state::special_io_map);

	M6508(config, m_fdcpu, 12_MHz_XTAL / 8); // PH1/PH2 = 1.5 MHz
	m_fdcpu->set_addrmap(AS_PROGRAM, &c900_state::fdc_map);

	GFXDECODE(config, "gfxdecode", "palette", gfx_c900);
	PALETTE(config, "palette", palette_device::MONOCHROME);

	z8036_device &cio(Z8036(config, "cio", 12_MHz_XTAL / 16)); // SNDCLK = 750kHz
	cio.pb_wr_cb().set(FUNC(c900_state::sound_pb_w));

	scc8030_device &scc(SCC8030(config, "scc", 12_MHz_XTAL / 2)); // 5'850'000 is the ideal figure
	/* Port B */
	scc.out_txdb_callback().set("rs232", FUNC(rs232_port_device::write_txd));
	scc.out_dtrb_callback().set("rs232", FUNC(rs232_port_device::write_dtr));
	scc.out_rtsb_callback().set("rs232", FUNC(rs232_port_device::write_rts));
	//scc.out_int_callback().set("rs232", FUNC(c900_state::scc_int));

	rs232_port_device &rs232(RS232_PORT(config, "rs232", default_rs232_devices, "terminal"));
	rs232.rxd_handler().set("scc", FUNC(scc8030_device::rxb_w));
	rs232.cts_handler().set("scc", FUNC(scc8030_device::ctsb_w));

	SPEAKER(config, "mono").front_center();
	SPEAKER_SOUND(config, m_spkrdev).add_route(ALL_OUTPUTS, "mono", 0.05);
}
开发者ID:fesh0r,项目名称:mame-full,代码行数:34,代码来源:c900.cpp

示例12: ARM

void ertictac_state::ertictac(machine_config &config)
{
	ARM(config, m_maincpu, XTAL(24'000'000)/3); /* guess, 12MHz 8MHz or 6MHz, what's the correct divider 2, 3 or 4? */
	m_maincpu->set_addrmap(AS_PROGRAM, &ertictac_state::ertictac_map);
	m_maincpu->set_periodic_int(FUNC(ertictac_state::ertictac_podule_irq), attotime::from_hz(60)); // FIXME: timing of this

	I2CMEM(config, "i2cmem", 0).set_page_size(NVRAM_PAGE_SIZE).set_data_size(NVRAM_SIZE);

//  AAKART(config, m_kart, XTAL(24'000'000)/3); // TODO: frequency

	SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
	m_screen->set_raw(XTAL(16'000'000), 1024,0,735, 624/2,0,292); // RiscOS 3 default screen settings
	m_screen->set_screen_update(FUNC(archimedes_state::screen_update));

	PALETTE(config, m_palette).set_entries(0x200);

	SPEAKER(config, "speaker").front_center();
	for (int i = 0; i < 8; i++)
	{
		DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac[i], 0).add_route(0, "speaker", 0.05); // unknown DAC
	}
	voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref", 0));
	vref.add_route(0, "dac0", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac0", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac1", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac1", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac2", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac2", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac3", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac3", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac4", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac4", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac5", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac5", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac6", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac6", -1.0, DAC_VREF_NEG_INPUT);
	vref.add_route(0, "dac7", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac7", -1.0, DAC_VREF_NEG_INPUT);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:31,代码来源:ertictac.cpp

示例13: PALETTE

void gmaster_state::gmaster(machine_config &config)
{
	upd7810_device &upd(UPD7810(config, m_maincpu, 12_MHz_XTAL/2/*?*/)); // µPD78C11 in the unit
	upd.set_addrmap(AS_PROGRAM, &gmaster_state::gmaster_mem);
	upd.pa_in_cb().set_ioport("JOY");
	upd.pb_in_cb().set(FUNC(gmaster_state::gmaster_portb_r));
	upd.pc_in_cb().set(FUNC(gmaster_state::gmaster_portc_r));
	upd.pd_in_cb().set(FUNC(gmaster_state::gmaster_portd_r));
	upd.pf_in_cb().set(FUNC(gmaster_state::gmaster_portf_r));
	upd.pa_out_cb().set(FUNC(gmaster_state::gmaster_porta_w));
	upd.pb_out_cb().set(FUNC(gmaster_state::gmaster_portb_w));
	upd.pc_out_cb().set(FUNC(gmaster_state::gmaster_portc_w));
	upd.pd_out_cb().set(FUNC(gmaster_state::gmaster_portd_w));
	upd.pf_out_cb().set(FUNC(gmaster_state::gmaster_portf_w));

	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_LCD));
	screen.set_refresh_hz(60);
	screen.set_size(64, 64);
	screen.set_visarea(0, 64-1-3, 0, 64-1);
	screen.set_screen_update(FUNC(gmaster_state::screen_update_gmaster));
	screen.set_palette("palette");

	PALETTE(config, "palette", FUNC(gmaster_state::gmaster_palette), ARRAY_LENGTH(gmaster_pens));

	SPEAKER(config, "mono").front_center();
	SPEAKER_SOUND(config, m_speaker).add_route(0, "mono", 0.50);

	GENERIC_CARTSLOT(config, m_cart, generic_linear_slot, "gmaster_cart").set_must_be_loaded(true);


	SOFTWARE_LIST(config, "cart_list").set_original("gmaster");
}
开发者ID:k2-git,项目名称:mame,代码行数:32,代码来源:gmaster.cpp

示例14: M68000

void powerbal_state::magicstk(machine_config &config)
{
	/* basic machine hardware */
	M68000(config, m_maincpu, 12000000);   /* 12 MHz */
	m_maincpu->set_addrmap(AS_PROGRAM, &powerbal_state::magicstk_main_map);
	m_maincpu->set_vblank_int("screen", FUNC(powerbal_state::irq2_line_hold));

	EEPROM_93C46_16BIT(config, "eeprom").default_value(0);

	MCFG_MACHINE_START_OVERRIDE(powerbal_state,powerbal)
	MCFG_MACHINE_RESET_OVERRIDE(powerbal_state,powerbal)

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(61);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500) /* not accurate */);
	screen.set_size(128*8, 64*8);
	screen.set_visarea(0*8, 40*8-1, 0*8, 30*8-1);
	screen.set_screen_update(FUNC(powerbal_state::screen_update_powerbal));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_powerbal);
	PALETTE(config, m_palette).set_format(palette_device::RRRRGGGGBBBBRGBx, 512);

	MCFG_VIDEO_START_OVERRIDE(powerbal_state,powerbal)

	/* sound hardware */
	SPEAKER(config, "mono").front_center();

	OKIM6295(config, m_oki, 1000000, okim6295_device::PIN7_HIGH);
	m_oki->add_route(ALL_OUTPUTS, "mono", 1.0);
	m_oki->set_addrmap(0, &powerbal_state::oki_map);
}
开发者ID:SailorSat,项目名称:cabmame,代码行数:33,代码来源:powerbal.cpp

示例15: M6502

INPUT_PORTS_END

/* Machine driver */
void galeb_state::galeb(machine_config &config)
{
	/* basic machine hardware */
	M6502(config, m_maincpu, 1000000);
	m_maincpu->set_addrmap(AS_PROGRAM, &galeb_state::galeb_mem);

	/* video hardware */
	screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER));
	screen.set_refresh_hz(50);
	screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */
	screen.set_size(48*8, 16*8);
	screen.set_visarea(0, 48*8-1, 0, 16*8-1);
	screen.set_screen_update(FUNC(galeb_state::screen_update_galeb));
	screen.set_palette(m_palette);

	GFXDECODE(config, m_gfxdecode, m_palette, gfx_galeb);

	PALETTE(config, m_palette, palette_device::MONOCHROME);


	/* audio hardware */
	SPEAKER(config, "speaker").front_center();
	DAC_1BIT(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.0625); // unknown DAC
	voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref", 0));
	vref.set_output(5.0);
	vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT);
}
开发者ID:k2-git,项目名称:mame,代码行数:30,代码来源:galeb.cpp


注:本文中的SPEAKER函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。