INPUT_PORTS_END void madalien_state::madalien(machine_config &config) { /* main CPU */ M6502(config, m_maincpu, MADALIEN_MAIN_CLOCK / 8); /* 1324kHz */ m_maincpu->set_addrmap(AS_PROGRAM, &madalien_state::main_map); M6502(config, m_audiocpu, SOUND_CLOCK / 8); /* 512kHz */ m_audiocpu->set_addrmap(AS_PROGRAM, &madalien_state::audio_map); /* video hardware */ madalien_video(config); /* audio hardware */ SPEAKER(config, "mono").front_center(); GENERIC_LATCH_8(config, m_soundlatch); m_soundlatch->data_pending_callback().set_inputline(m_audiocpu, 0); // 7400 at 3A used as R/S latch GENERIC_LATCH_8(config, m_soundlatch2); ay8910_device &aysnd(AY8910(config, "aysnd", SOUND_CLOCK / 4)); aysnd.port_a_write_callback().set(FUNC(madalien_state::madalien_portA_w)); aysnd.port_b_write_callback().set(FUNC(madalien_state::madalien_portB_w)); aysnd.add_route(0, "discrete", 1.0, 0); aysnd.add_route(1, "discrete", 1.0, 1); aysnd.add_route(2, "discrete", 1.0, 2); DISCRETE(config, m_discrete, madalien_discrete).add_route(ALL_OUTPUTS, "mono", 1.0); }
GFXDECODE_END /************************************* * * Machine driver * *************************************/ void matmania_state::matmania(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 1500000); /* 1.5 MHz ???? */ m_maincpu->set_addrmap(AS_PROGRAM, &matmania_state::matmania_map); m_maincpu->set_vblank_int("screen", FUNC(matmania_state::irq0_line_hold)); M6502(config, m_audiocpu, 1200000); /* 1.2 MHz ???? */ m_audiocpu->set_addrmap(AS_PROGRAM, &matmania_state::matmania_sound_map); m_audiocpu->set_periodic_int(FUNC(matmania_state::nmi_line_pulse), attotime::from_hz(15*60)); /* ???? */ config.m_minimum_quantum = attotime::from_hz(6000); /* video hardware */ SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_refresh_hz(60); m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */ m_screen->set_size(32*8, 32*8); m_screen->set_visarea(0*8, 32*8-1, 1*8, 31*8-1); m_screen->set_screen_update(FUNC(matmania_state::screen_update_matmania)); m_screen->set_palette(m_palette); GFXDECODE(config, m_gfxdecode, m_palette, gfx_matmania); PALETTE(config, m_palette, FUNC(matmania_state::matmania_palette), 64 + 16); /* sound hardware */ SPEAKER(config, "speaker").front_center(); GENERIC_LATCH_8(config, m_soundlatch); AY8910(config, "ay1", 1500000).add_route(ALL_OUTPUTS, "speaker", 0.3); AY8910(config, "ay2", 1500000).add_route(ALL_OUTPUTS, "speaker", 0.3); DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.4); // unknown DAC voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref", 0)); vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT); }
INPUT_PORTS_END //------------------------------------------------- // device_add_mconfig - add device configuration //------------------------------------------------- void gottlieb_sound_r1_device::device_add_mconfig(machine_config &config) { // audio CPU m6502_device &audiocpu(M6502(config, "audiocpu", SOUND1_CLOCK/4)); // the board can be set to /2 as well audiocpu.set_addrmap(AS_PROGRAM, &gottlieb_sound_r1_device::gottlieb_sound_r1_map); INPUT_MERGER_ANY_HIGH(config, "nmi").output_handler().set_inputline("audiocpu", INPUT_LINE_NMI); // I/O configuration RIOT6532(config, m_riot, SOUND1_CLOCK/4); m_riot->in_pb_callback().set_ioport("SB1"); m_riot->out_pb_callback().set("nmi", FUNC(input_merger_device::in_w<0>)).bit(7).invert(); // unsure if this is ever used, but the NMI is connected to the RIOT's PB7 m_riot->irq_callback().set_inputline("audiocpu", M6502_IRQ_LINE); // sound devices DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, *this, 0.25); // unknown DAC voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref")); vref.set_output(5.0); vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT); }
INPUT_PORTS_END void superga2_state::kuzmich(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &superga2_state::kuzmich_map); APPLE2_VIDEO(config, m_video, XTAL(14'318'181)); APPLE2_COMMON(config, m_a2common, XTAL(14'318'181)); SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_raw(1021800*14, (65*7)*2, 0, (40*7)*2, 262, 0, 192); m_screen->set_screen_update(FUNC(superga2_state::screen_update)); m_screen->set_palette(m_video); /* sound hardware */ SPEAKER(config, "mono").front_center(); SPEAKER_SOUND(config, A2_SPEAKER_TAG).add_route(ALL_OUTPUTS, "mono", 1.00); /* soft switches */ F9334(config, m_softlatch); // F14 (labeled 74LS259 on some boards and in the Apple ][ Reference Manual) m_softlatch->q_out_cb<0>().set(FUNC(superga2_state::txt_w)); m_softlatch->q_out_cb<1>().set(FUNC(superga2_state::mix_w)); m_softlatch->q_out_cb<2>().set(FUNC(superga2_state::scr_w)); m_softlatch->q_out_cb<3>().set(FUNC(superga2_state::res_w)); m_softlatch->q_out_cb<6>().set(FUNC(superga2_state::an2_w)); RAM(config, RAM_TAG).set_default_size("48K").set_default_value(0x00); }
FLOPPY_D81_FORMAT FLOPPY_FORMATS_END //------------------------------------------------- // device_add_mconfig - add device configuration //------------------------------------------------- void c1581_device::device_add_mconfig(machine_config &config) { M6502(config, m_maincpu, 16_MHz_XTAL / 8); m_maincpu->set_addrmap(AS_PROGRAM, &c1581_device::c1581_mem); MOS8520(config, m_cia, 16_MHz_XTAL / 8); m_cia->irq_wr_callback().set_inputline(m_maincpu, INPUT_LINE_IRQ0); m_cia->cnt_wr_callback().set(FUNC(c1581_device::cnt_w)); m_cia->sp_wr_callback().set(FUNC(c1581_device::sp_w)); m_cia->pa_rd_callback().set(FUNC(c1581_device::cia_pa_r)); m_cia->pa_wr_callback().set(FUNC(c1581_device::cia_pa_w)); m_cia->pb_rd_callback().set(FUNC(c1581_device::cia_pb_r)); m_cia->pb_wr_callback().set(FUNC(c1581_device::cia_pb_w)); WD1772(config, m_fdc, 16_MHz_XTAL / 2); FLOPPY_CONNECTOR(config, WD1772_TAG":0", c1581_floppies, "35dd", c1581_device::floppy_formats, true); }
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); }
void venture_sound_device::device_add_mconfig(machine_config &config) { m6502_device &audiocpu(M6502(config, "audiocpu", 3579545/4)); audiocpu.set_addrmap(AS_PROGRAM, &venture_sound_device::venture_audio_map); RIOT6532(config, m_riot, SH6532_CLOCK); m_riot->in_pa_callback().set(FUNC(venture_sound_device::r6532_porta_r)); m_riot->out_pa_callback().set(FUNC(venture_sound_device::r6532_porta_w)); m_riot->in_pb_callback().set(FUNC(venture_sound_device::r6532_portb_r)); m_riot->out_pb_callback().set(FUNC(venture_sound_device::r6532_portb_w)); m_riot->irq_callback().set("audioirq", FUNC(input_merger_device::in_w<0>)); PIA6821(config, m_pia, 0); m_pia->writepa_handler().set(FUNC(venture_sound_device::pia_pa_w)); m_pia->writepb_handler().set(FUNC(venture_sound_device::pia_pb_w)); m_pia->ca2_handler().set(FUNC(venture_sound_device::pia_ca2_w)); m_pia->cb2_handler().set(FUNC(venture_sound_device::pia_cb2_w)); m_pia->irqb_handler().set("audioirq", FUNC(input_merger_device::in_w<1>)); INPUT_MERGER_ANY_HIGH(config, "audioirq").output_handler().set_inputline("audiocpu", m6502_device::IRQ_LINE); // open collector SPEAKER(config, "mono").front_center(); this->add_route(ALL_OUTPUTS, "mono", 0.50); }
/************************************* * * 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)); }
GFXDECODE_END /************************************* * * Machine driver * *************************************/ void ccastles_state::ccastles(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, MASTER_CLOCK/8); m_maincpu->set_addrmap(AS_PROGRAM, &ccastles_state::main_map); LS259(config, m_outlatch[0]); // 8N m_outlatch[0]->q_out_cb<0>().set_output("led0").invert(); m_outlatch[0]->q_out_cb<1>().set_output("led1").invert(); m_outlatch[0]->q_out_cb<2>().set(FUNC(ccastles_state::nvram_store_w)); m_outlatch[0]->q_out_cb<3>().set(FUNC(ccastles_state::nvram_store_w)); m_outlatch[0]->q_out_cb<5>().set([this] (int state) { machine().bookkeeping().coin_counter_w(0, state); }); m_outlatch[0]->q_out_cb<6>().set([this] (int state) { machine().bookkeeping().coin_counter_w(1, state); }); m_outlatch[0]->q_out_cb<7>().set_membank("bank1"); LS259(config, m_outlatch[1]); // 6P WATCHDOG_TIMER(config, "watchdog").set_vblank_count("screen", 8); X2212(config, "nvram_4b").set_auto_save(true); X2212(config, "nvram_4a").set_auto_save(true); /* video hardware */ GFXDECODE(config, m_gfxdecode, m_palette, gfx_ccastles); PALETTE(config, m_palette).set_entries(32); SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_raw(PIXEL_CLOCK, HTOTAL, 0, 256, VTOTAL, 24, 256); // potentially adjusted later m_screen->set_screen_update(FUNC(ccastles_state::screen_update_ccastles)); m_screen->set_palette(m_palette); /* sound hardware */ SPEAKER(config, "mono").front_center(); pokey_device &pokey1(POKEY(config, "pokey1", MASTER_CLOCK/8)); /* NOTE: 1k + 0.2k is not 100% exact, but should not make an audible difference */ pokey1.set_output_opamp(RES_K(1) + RES_K(0.2), CAP_U(0.01), 5.0); pokey1.add_route(ALL_OUTPUTS, "mono", 1.0); pokey_device &pokey2(POKEY(config, "pokey2", MASTER_CLOCK/8)); /* NOTE: 1k + 0.2k is not 100% exact, but should not make an audible difference */ pokey2.set_output_opamp(RES_K(1) + RES_K(0.2), CAP_U(0.01), 5.0); pokey2.allpot_r().set_ioport("IN1"); pokey2.add_route(ALL_OUTPUTS, "mono", 1.0); }
void laser2001_state::lasr2001(machine_config &config) { // basic machine hardware M6502(config, m_maincpu, XTAL(17'734'470)/9); m_maincpu->set_addrmap(AS_PROGRAM, &laser2001_state::lasr2001_map); // devices PIA6821(config, m_pia, 0); m_pia->readpa_handler().set(FUNC(laser2001_state::pia_pa_r)); m_pia->readpb_handler().set(FUNC(laser2001_state::pia_pb_r)); m_pia->readca1_handler().set(FUNC(laser2001_state::pia_ca1_r)); m_pia->writepa_handler().set(FUNC(laser2001_state::pia_pa_w)); m_pia->writepb_handler().set(FUNC(laser2001_state::pia_pb_w)); m_pia->ca2_handler().set(FUNC(laser2001_state::pia_ca2_w)); m_pia->cb2_handler().set(FUNC(laser2001_state::pia_cb2_w)); CASSETTE(config, m_cassette); m_cassette->set_default_state((cassette_state)(CASSETTE_STOPPED | CASSETTE_MOTOR_ENABLED | CASSETTE_SPEAKER_ENABLED)); CENTRONICS(config, m_centronics, centronics_devices, "printer"); m_centronics->busy_handler().set(FUNC(laser2001_state::write_centronics_busy)); OUTPUT_LATCH(config, m_cent_data_out); m_centronics->set_output_latch(*m_cent_data_out); // video hardware tms9929a_device &vdp(TMS9929A(config, TMS9929_TAG, XTAL(10'738'635))); vdp.set_screen("screen"); vdp.set_vram_size(0x4000); vdp.int_callback().set_inputline(M6502_TAG, m6502_device::IRQ_LINE); SCREEN(config, "screen", SCREEN_TYPE_RASTER); // sound hardware SPEAKER(config, "mono").front_center(); SN76489A(config, m_psg, XTAL(17'734'470)/9); m_psg->ready_cb().set(FUNC(laser2001_state::write_psg_ready)); m_psg->add_route(ALL_OUTPUTS, "mono", 1.00); WAVE(config, "wave", m_cassette).add_route(1, "mono", 0.25); // cartridge CRVISION_CART_SLOT(config, m_cart, crvision_cart, nullptr); // internal ram RAM(config, m_ram); m_ram->set_default_size("16K"); m_ram->set_extra_options("32K"); // software list SOFTWARE_LIST(config, "cart_list").set_original("crvision"); SOFTWARE_LIST(config, "cart_list2").set_original("laser2001_cart"); }
void redalert_state::demoneye(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, MAIN_CPU_CLOCK); m_maincpu->set_addrmap(AS_PROGRAM, &redalert_state::demoneye_main_map); m_maincpu->set_vblank_int("screen", FUNC(redalert_state::redalert_vblank_interrupt)); /* video hardware */ demoneye_video(config); /* audio hardware */ demoneye_audio(config); }
void pokechmp_state::pokechmp(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 4_MHz_XTAL/4); m_maincpu->set_addrmap(AS_PROGRAM, &pokechmp_state::pokechmp_map); M6502(config, m_audiocpu, 4_MHz_XTAL/4); m_audiocpu->set_addrmap(AS_PROGRAM, &pokechmp_state::pokechmp_sound_map); /* video hardware */ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); screen.set_refresh_hz(60); screen.set_vblank_time(ATTOSECONDS_IN_USEC(0)); screen.set_size(32*8, 32*8); screen.set_visarea(0*8, 32*8-1, 2*8, 30*8-1); screen.set_screen_update(FUNC(pokechmp_state::screen_update_pokechmp)); screen.set_palette(m_palette); screen.screen_vblank().set_inputline(m_maincpu, INPUT_LINE_NMI); screen.screen_vblank().append(FUNC(pokechmp_state::sound_irq)); GFXDECODE(config, m_gfxdecode, m_palette, gfx_pokechmp); PALETTE(config, m_palette).set_format(palette_device::xBGR_555, 0x400); /* sound hardware */ SPEAKER(config, "mono").front_center(); GENERIC_LATCH_8(config, m_soundlatch); YM2203(config, "ym1", XTAL(4'000'000)/4).add_route(ALL_OUTPUTS, "mono", 0.60); YM3812(config, "ym2", XTAL(24'000'000)/16).add_route(ALL_OUTPUTS, "mono", 1.0); okim6295_device &oki(OKIM6295(config, "oki", XTAL(24'000'000)/16, okim6295_device::PIN7_LOW)); oki.add_route(ALL_OUTPUTS, "mono", 0.50); /* sound fx */ oki.add_route(ALL_OUTPUTS, "mono", 0.50); oki.set_addrmap(0, &pokechmp_state::pokechmp_oki_map); }
GFXDECODE_END /********************************************* * Machine Drivers * *********************************************/ void gluck2_state::gluck2(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, MASTER_CLOCK/16); /* guess */ m_maincpu->set_addrmap(AS_PROGRAM, &gluck2_state::gluck2_map); NVRAM(config, "nvram", nvram_device::DEFAULT_ALL_0); /* video hardware */ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); screen.set_refresh_hz(60); screen.set_vblank_time(ATTOSECONDS_IN_USEC(0)); /* CRTC Register: 00 01 02 03 04 05 06 CRTC Value : 0x27 0x20 0x23 0x03 0x26 0x00 0x20 */ screen.set_size((39+1)*8, (38+1)*8); /* from MC6845 init, registers 00 & 04. (value - 1) */ screen.set_visarea(0*8, 32*8-1, 0*8, 32*8-1); /* from MC6845 init, registers 01 & 06. */ screen.set_screen_update(FUNC(gluck2_state::screen_update)); GFXDECODE(config, m_gfxdecode, "palette", gfx_gluck2); PALETTE(config, "palette", palette_device::RGB_444_PROMS, "proms", 256); mc6845_device &crtc(MC6845(config, "crtc", MASTER_CLOCK/16)); /* guess */ crtc.set_screen("screen"); crtc.set_show_border_area(false); crtc.set_char_width(8); crtc.out_vsync_callback().set_inputline(m_maincpu, INPUT_LINE_NMI); /* sound hardware */ SPEAKER(config, "mono").front_center(); ay8910_device &ay8910(AY8910(config, "ay8910", MASTER_CLOCK/8)); /* guess */ ay8910.port_a_read_callback().set_ioport("SW3"); ay8910.port_b_read_callback().set_ioport("SW2"); /* Output ports have a minimal activity during init. They seems unused (at least for Good Luck II) */ ay8910.add_route(ALL_OUTPUTS, "mono", 1.0); YM2413(config, "ymsnd", SND_CLOCK).add_route(ALL_OUTPUTS, "mono", 1.0); }
GFXDECODE_END void starshp1_state::starshp1(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, STARSHP1_CPU_CLOCK); m_maincpu->set_addrmap(AS_PROGRAM, &starshp1_state::starshp1_map); m_maincpu->set_vblank_int("screen", FUNC(starshp1_state::starshp1_interrupt)); f9334_device &misclatch(F9334(config, "misclatch")); // C8 misclatch.q_out_cb<0>().set(FUNC(starshp1_state::ship_explode_w)); misclatch.q_out_cb<1>().set(FUNC(starshp1_state::circle_mod_w)); misclatch.q_out_cb<2>().set(FUNC(starshp1_state::circle_kill_w)); misclatch.q_out_cb<3>().set(FUNC(starshp1_state::starfield_kill_w)); misclatch.q_out_cb<4>().set(FUNC(starshp1_state::inverse_w)); misclatch.q_out_cb<5>().set_nop(); // BLACK HOLE, not used misclatch.q_out_cb<6>().set(FUNC(starshp1_state::mux_w)); misclatch.q_out_cb<7>().set(FUNC(starshp1_state::led_w)); /* video hardware */ SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_raw(STARSHP1_PIXEL_CLOCK, STARSHP1_HTOTAL, STARSHP1_HBEND, STARSHP1_HBSTART, STARSHP1_VTOTAL, STARSHP1_VBEND, STARSHP1_VBSTART); m_screen->set_screen_update(FUNC(starshp1_state::screen_update_starshp1)); m_screen->screen_vblank().set(FUNC(starshp1_state::screen_vblank_starshp1)); m_screen->set_palette(m_palette); GFXDECODE(config, m_gfxdecode, m_palette, gfx_starshp1); PALETTE(config, m_palette, FUNC(starshp1_state::starshp1_palette), 19, 8); /* sound hardware */ SPEAKER(config, "mono").front_center(); DISCRETE(config, m_discrete, starshp1_discrete).add_route(ALL_OUTPUTS, "mono", 1.0); f9334_device &audiolatch(F9334(config, "audiolatch")); // D9 audiolatch.q_out_cb<0>().set(FUNC(starshp1_state::attract_w)); audiolatch.q_out_cb<1>().set(FUNC(starshp1_state::phasor_w)); audiolatch.q_out_cb<2>().set("discrete", FUNC(discrete_device::write_line<STARSHP1_KICKER>)); audiolatch.q_out_cb<3>().set("discrete", FUNC(discrete_device::write_line<STARSHP1_SL1>)); audiolatch.q_out_cb<4>().set("discrete", FUNC(discrete_device::write_line<STARSHP1_SL2>)); audiolatch.q_out_cb<5>().set("discrete", FUNC(discrete_device::write_line<STARSHP1_MOLVL>)); audiolatch.q_out_cb<6>().set("discrete", FUNC(discrete_device::write_line<STARSHP1_NOISE_FREQ>)); }
void firetrap_state::firetrap(machine_config &config) { /* basic machine hardware */ Z80(config, m_maincpu, FIRETRAP_XTAL/2); // 6 MHz m_maincpu->set_addrmap(AS_PROGRAM, &firetrap_state::firetrap_map); m_maincpu->set_vblank_int("screen", FUNC(firetrap_state::firetrap_irq)); M6502(config, m_audiocpu, FIRETRAP_XTAL/8); // 1.5 MHz m_audiocpu->set_addrmap(AS_PROGRAM, &firetrap_state::sound_map); /* IRQs are caused by the ADPCM chip */ /* NMIs are caused by the main CPU */ I8751(config, "mcu", XTAL(8'000'000)).set_disable(); /* video hardware */ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); // screen.set_refresh_hz(57.4034); // PCB measurement // screen.set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */ // screen.set_size(32*8, 32*8); // screen.set_visarea(0*8, 32*8-1, 1*8, 31*8-1); // DECO video CRTC, unverified screen.set_raw(FIRETRAP_XTAL/2,384,0,256,272,8,248); screen.set_screen_update(FUNC(firetrap_state::screen_update_firetrap)); screen.set_palette(m_palette); GFXDECODE(config, m_gfxdecode, m_palette, gfx_firetrap); PALETTE(config, m_palette, FUNC(firetrap_state::firetrap_palette), 256); /* sound hardware */ SPEAKER(config, "mono").front_center(); GENERIC_LATCH_8(config, m_soundlatch); m_soundlatch->data_pending_callback().set_inputline(m_audiocpu, INPUT_LINE_NMI); ym3526_device &ymsnd(YM3526(config, "ymsnd", FIRETRAP_XTAL/4)); // 3 MHz ymsnd.add_route(ALL_OUTPUTS, "mono", 1.0); LS157(config, m_adpcm_select, 0); m_adpcm_select->out_callback().set("msm", FUNC(msm5205_device::data_w)); MSM5205(config, m_msm, FIRETRAP_XTAL/32); // 375 kHz m_msm->vck_callback().set(FUNC(firetrap_state::firetrap_adpcm_int)); m_msm->set_prescaler_selector(msm5205_device::S48_4B); /* 7.8125kHz */ m_msm->add_route(ALL_OUTPUTS, "mono", 0.30); }
void crvision_state::creativision(machine_config &config) { // basic machine hardware M6502(config, m_maincpu, XTAL(2'000'000)); m_maincpu->set_addrmap(AS_PROGRAM, &crvision_state::crvision_map); // devices PIA6821(config, m_pia, 0); m_pia->readpa_handler().set(FUNC(crvision_state::pia_pa_r)); m_pia->readpb_handler().set(FUNC(crvision_state::pia_pb_r)); m_pia->writepa_handler().set(FUNC(crvision_state::pia_pa_w)); m_pia->writepb_handler().set(SN76489_TAG, FUNC(sn76496_base_device::write)); CASSETTE(config, m_cassette); m_cassette->set_default_state((cassette_state)(CASSETTE_STOPPED | CASSETTE_MOTOR_DISABLED | CASSETTE_SPEAKER_ENABLED)); CENTRONICS(config, m_centronics, centronics_devices, "printer"); m_centronics->busy_handler().set("cent_status_in", FUNC(input_buffer_device::write_bit7)); INPUT_BUFFER(config, "cent_status_in", 0); OUTPUT_LATCH(config, m_cent_data_out); m_centronics->set_output_latch(*m_cent_data_out); OUTPUT_LATCH(config, "cent_ctrl_out").bit_handler<4>().set(m_centronics, FUNC(centronics_device::write_strobe)); // sound hardware SPEAKER(config, "mono").front_center(); SN76489A(config, m_psg, XTAL(2'000'000)); m_psg->ready_cb().set(m_pia, FUNC(pia6821_device::cb1_w)); m_psg->add_route(ALL_OUTPUTS, "mono", 1.00); WAVE(config, "wave", m_cassette).add_route(1, "mono", 0.25); // cartridge CRVISION_CART_SLOT(config, m_cart, crvision_cart, nullptr); // internal ram RAM(config, m_ram); m_ram->set_default_size("1K"); // main RAM m_ram->set_extra_options("15K"); // 16K expansion (lower 14K available only, upper 2K shared with BIOS ROM) // software lists SOFTWARE_LIST(config, "cart_list").set_original("crvision"); }
void gottlieb_sound_r0_device::device_add_mconfig(machine_config &config) { // audio CPU M6502(config, m_audiocpu, SOUND1_CLOCK/4); // M6503 - clock is a gate, a resistor and a capacitor. Freq unknown. m_audiocpu->set_addrmap(AS_PROGRAM, &gottlieb_sound_r0_device::gottlieb_sound_r0_map); // I/O configuration MOS6530(config, m_r6530, SOUND1_CLOCK/4); // unknown - same as cpu m_r6530->out_pa_callback().set("dac", FUNC(dac_byte_interface::data_w)); m_r6530->in_pb_callback().set(FUNC(gottlieb_sound_r0_device::r6530b_r)); // sound devices DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, *this, 0.25); // unknown DAC voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref")); vref.set_output(5.0); vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT); }
void laser3k_state::laser3k(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 1021800); m_maincpu->set_addrmap(AS_PROGRAM, &laser3k_state::laser3k_map); SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_refresh_hz(50); m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */ m_screen->set_size(300*2, 192); m_screen->set_visarea(0, (280*2)-1,0,192-1); m_screen->set_screen_update(FUNC(laser3k_state::screen_update)); m_screen->set_palette("palette"); PALETTE(config, "palette", FUNC(laser3k_state::laser3k_palette), ARRAY_LENGTH(laser3k_pens)); /* memory banking */ ADDRESS_MAP_BANK(config, "bank0").set_map(&laser3k_state::banks_map).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000); ADDRESS_MAP_BANK(config, "bank1").set_map(&laser3k_state::banks_map).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000); ADDRESS_MAP_BANK(config, "bank2").set_map(&laser3k_state::banks_map).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000); ADDRESS_MAP_BANK(config, "bank3").set_map(&laser3k_state::banks_map).set_options(ENDIANNESS_LITTLE, 8, 32, 0x4000); RAM(config, "mainram").set_default_size("192K"); /* the 8048 isn't dumped, so substitute modified real Apple II h/w */ AY3600(config, m_ay3600, 0); m_ay3600->x0().set_ioport("X0"); m_ay3600->x1().set_ioport("X1"); m_ay3600->x2().set_ioport("X2"); m_ay3600->x3().set_ioport("X3"); m_ay3600->x4().set_ioport("X4"); m_ay3600->x5().set_ioport("X5"); m_ay3600->x6().set_ioport("X6"); m_ay3600->x7().set_ioport("X7"); m_ay3600->x8().set_ioport("X8"); m_ay3600->shift().set(FUNC(laser3k_state::ay3600_shift_r)); m_ay3600->control().set(FUNC(laser3k_state::ay3600_control_r)); m_ay3600->data_ready().set(FUNC(laser3k_state::ay3600_data_ready_w)); /* sound hardware */ SPEAKER(config, "mono").front_center(); SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 1.00); SN76489(config, m_sn, 1020484).add_route(ALL_OUTPUTS, "mono", 0.50); }
void gamate_state::gamate(machine_config &config) { M6502(config, m_maincpu, 4433000/2); // NCR 65CX02 m_maincpu->set_addrmap(AS_PROGRAM, &gamate_state::gamate_mem); GAMATE_VIDEO(config, "video", 0); /* sound hardware */ SPEAKER(config, "lspeaker").front_left(); // Stereo headphone output SPEAKER(config, "rspeaker").front_right(); AY8910(config, m_ay, 4433000 / 4); // AY compatible, no actual AY chip present m_ay->add_route(0, "lspeaker", 0.5); m_ay->add_route(1, "rspeaker", 0.5); m_ay->add_route(2, "lspeaker", 0.25); m_ay->add_route(2, "rspeaker", 0.25); GAMATE_CART_SLOT(config, m_cartslot, gamate_cart, nullptr); SOFTWARE_LIST(config, "cart_list").set_original("gamate"); }
void avalnche_state::avalnche_base(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 12.096_MHz_XTAL / 16); /* clock input is the "2H" signal divided by two */ m_maincpu->set_addrmap(AS_PROGRAM, &avalnche_state::main_map); m_maincpu->set_periodic_int(FUNC(avalnche_state::nmi_line_pulse), attotime::from_hz(8*60)); F9334(config, m_latch); // F8 m_latch->q_out_cb<0>().set_output("led0"); // 1 CREDIT LAMP m_latch->q_out_cb<2>().set(FUNC(avalnche_state::video_invert_w)); m_latch->q_out_cb<3>().set_output("led1"); // 2 CREDIT LAMP m_latch->q_out_cb<7>().set_output("led2"); // START LAMP // Q1, Q4, Q5, Q6 are configured in audio/avalnche.cpp WATCHDOG_TIMER(config, "watchdog"); /* video hardware */ screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); screen.set_raw(12.096_MHz_XTAL / 2, 384, 0, 256, 262, 16, 256); screen.set_screen_update(FUNC(avalnche_state::screen_update_avalnche)); }
void matmania_state::maniach(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, 1500000); /* 1.5 MHz ???? */ m_maincpu->set_addrmap(AS_PROGRAM, &matmania_state::maniach_map); m_maincpu->set_vblank_int("screen", FUNC(matmania_state::irq0_line_hold)); MC6809E(config, m_audiocpu, 1500000); /* 1.5 MHz ???? (HD68A09EP) */ m_audiocpu->set_addrmap(AS_PROGRAM, &matmania_state::maniach_sound_map); TAITO68705_MCU(config, m_mcu, 1500000*2); /* (don't know really how fast, but it doesn't need to even be this fast) */ config.m_minimum_quantum = attotime::from_hz(6000); /* 100 CPU slice per frame - high interleaving to sync main and mcu */ /* video hardware */ SCREEN(config, m_screen, SCREEN_TYPE_RASTER); m_screen->set_refresh_hz(60); m_screen->set_vblank_time(ATTOSECONDS_IN_USEC(2500)); /* not accurate */ m_screen->set_size(32*8, 32*8); m_screen->set_visarea(0*8, 32*8-1, 1*8, 31*8-1); m_screen->set_screen_update(FUNC(matmania_state::screen_update_maniach)); m_screen->set_palette(m_palette); GFXDECODE(config, m_gfxdecode, m_palette, gfx_maniach); PALETTE(config, m_palette, FUNC(matmania_state::matmania_palette), 64 + 16); /* sound hardware */ SPEAKER(config, "speaker").front_center(); GENERIC_LATCH_8(config, m_soundlatch); ym3526_device &ymsnd(YM3526(config, "ymsnd", 3600000)); ymsnd.irq_handler().set_inputline(m_audiocpu, M6809_FIRQ_LINE); ymsnd.add_route(ALL_OUTPUTS, "speaker", 1.0); DAC_8BIT_R2R(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.4); // unknown DAC voltage_regulator_device &vref(VOLTAGE_REGULATOR(config, "vref", 0)); vref.add_route(0, "dac", 1.0, DAC_VREF_POS_INPUT); vref.add_route(0, "dac", -1.0, DAC_VREF_NEG_INPUT); }
INPUT_PORTS_END /************************************* * * Machine drivers * *************************************/ void redalert_state::redalert(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, MAIN_CPU_CLOCK); m_maincpu->set_addrmap(AS_PROGRAM, &redalert_state::redalert_main_map); m_maincpu->set_vblank_int("screen", FUNC(redalert_state::redalert_vblank_interrupt)); /* video hardware */ redalert_video(config); /* audio hardware */ redalert_audio(config); }
void cms_state::cms6502(machine_config &config) { M6502(config, m_maincpu, 1_MHz_XTAL); m_maincpu->set_addrmap(AS_PROGRAM, &cms_state::cms6502_mem); INPUT_MERGER_ANY_HIGH(config, m_irqs).output_handler().set_inputline(m_maincpu, M6502_IRQ_LINE); VIA6522(config, m_via, 1_MHz_XTAL); //m_via->cb2_handler().set(FUNC(cms_state::cass_w)); m_via->irq_handler().set("irqs", FUNC(input_merger_device::in_w<0>)); /* 7 Slot Backplane */ ACORN_BUS(config, m_bus, 0); m_bus->set_space(m_maincpu, AS_PROGRAM); m_bus->out_irq_callback().set(m_irqs, FUNC(input_merger_device::in_w<1>)); m_bus->out_nmi_callback().set(FUNC(cms_state::bus_nmi_w)); ACORN_BUS_SLOT(config, "bus1", m_bus, cms_bus_devices, "4080term"); ACORN_BUS_SLOT(config, "bus2", m_bus, cms_bus_devices, nullptr); ACORN_BUS_SLOT(config, "bus3", m_bus, cms_bus_devices, "fdc"); ACORN_BUS_SLOT(config, "bus4", m_bus, cms_bus_devices, "hires"); ACORN_BUS_SLOT(config, "bus5", m_bus, cms_bus_devices, nullptr); ACORN_BUS_SLOT(config, "bus6", m_bus, cms_bus_devices, nullptr); }
void vic1520_device::device_add_mconfig(machine_config &config) { m6502_device &cpu(M6502(config, M6500_1_TAG, XTAL(2'000'000))); // M6500/1 cpu.set_addrmap(AS_PROGRAM, &vic1520_device::vic1520_mem); }
GFXDECODE_END /************************************* * * Machine driver * *************************************/ void carpolo_state::carpolo(machine_config &config) { /* basic machine hardware */ M6502(config, m_maincpu, XTAL(11'289'000)/12); /* 940.75 kHz */ m_maincpu->set_addrmap(AS_PROGRAM, &carpolo_state::main_map); pia6821_device &pia0(PIA6821(config, "pia0", 0)); pia0.readpb_handler().set(FUNC(carpolo_state::pia_0_port_b_r)); pia0.writepa_handler().set(FUNC(carpolo_state::pia_0_port_a_w)); pia0.writepb_handler().set(FUNC(carpolo_state::pia_0_port_b_w)); pia0.ca2_handler().set(FUNC(carpolo_state::coin1_interrupt_clear_w)); pia0.cb2_handler().set(FUNC(carpolo_state::coin2_interrupt_clear_w)); pia6821_device &pia1(PIA6821(config, "pia1", 0)); pia1.readpa_handler().set(FUNC(carpolo_state::pia_1_port_a_r)); pia1.readpb_handler().set(FUNC(carpolo_state::pia_1_port_b_r)); pia1.ca2_handler().set(FUNC(carpolo_state::coin3_interrupt_clear_w)); pia1.cb2_handler().set(FUNC(carpolo_state::coin4_interrupt_clear_w)); TTL7474(config, m_ttl7474_2s_1, 0); m_ttl7474_2s_1->comp_output_cb().set(FUNC(carpolo_state::ttl7474_2s_1_q_cb)); TTL7474(config, m_ttl7474_2s_2, 0); m_ttl7474_2s_2->comp_output_cb().set(FUNC(carpolo_state::ttl7474_2s_2_q_cb)); TTL7474(config, m_ttl7474_2u_1, 0); m_ttl7474_2u_1->comp_output_cb().set(FUNC(carpolo_state::ttl7474_2u_1_q_cb)); TTL7474(config, m_ttl7474_2u_2, 0); m_ttl7474_2u_2->comp_output_cb().set(FUNC(carpolo_state::ttl7474_2u_2_q_cb)); TTL7474(config, m_ttl7474_1f_1, 0); TTL7474(config, m_ttl7474_1f_2, 0); TTL7474(config, m_ttl7474_1d_1, 0); TTL7474(config, m_ttl7474_1d_2, 0); TTL7474(config, m_ttl7474_1c_1, 0); TTL7474(config, m_ttl7474_1c_2, 0); TTL7474(config, m_ttl7474_1a_1, 0); TTL7474(config, m_ttl7474_1a_2, 0); TTL74148(config, m_ttl74148_3s, 0); m_ttl74148_3s->out_cb().set(FUNC(carpolo_state::ttl74148_3s_cb)); TTL153(config, m_ttl74153_1k); m_ttl74153_1k->za_cb().set(FUNC(carpolo_state::ls153_za_w)); // pia1 pb5 m_ttl74153_1k->zb_cb().set(FUNC(carpolo_state::ls153_zb_w)); // pia1 pb4 /* 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(256, 256); screen.set_visarea(0, 239, 0, 255); screen.set_screen_update(FUNC(carpolo_state::screen_update)); screen.screen_vblank().set(FUNC(carpolo_state::screen_vblank)); screen.set_palette(m_palette); GFXDECODE(config, m_gfxdecode, m_palette, gfx_carpolo); PALETTE(config, m_palette, FUNC(carpolo_state::carpolo_palette), 12*2+2*16+4*2); }