Previous 199869 Revisions Next

r17997 Tuesday 18th September, 2012 at 14:10:42 UTC by Miodrag Milanović
INTERRUPT_GEN -> INTERRUPT_GEN_MEMBER (no whatsnew)
[src/emu]devcpu.h
[src/mame/audio]aztarac.c cyberbal.c dkong.c redalert.c
[src/mame/drivers]1942.c 1943.c 1945kiii.c 20pacgal.c 2mindril.c 39in1.c 40love.c 4enraya.c 4roses.c 5clown.c 8080bw.c 88games.c acefruit.c actfancr.c adp.c aeroboto.c aerofgt.c airbustr.c ajax.c albazc.c albazg.c aliens.c alpha68k.c amaticmg.c ambush.c ampoker2.c amspdwy.c angelkds.c appoooh.c aquarium.c arabian.c aristmk4.c arkanoid.c armedf.c ashnojoe.c asterix.c asteroid.c astinvad.c astrocorp.c asuka.c atarifb.c atarisy2.c atarisy4.c atronic.c attckufo.c avalnche.c avt.c aztarac.c backfire.c badlands.c bagman.c balsente.c bankp.c baraduke.c battlane.c battlex.c battlnts.c bbusters.c bestleag.c bfcobra.c bfm_sc1.c bfm_sc2.c bfm_sc5.c bfmsys85.c bigevglf.c bigstrkb.c bingoc.c bingor.c bionicc.c bking.c blackt96.c blitz.c blitz68k.c blktiger.c blmbycar.c blockade.c blockhl.c bloodbro.c blueprnt.c bmcbowl.c bmcpokr.c bogeyman.c bombjack.c boogwing.c bottom9.c brkthru.c btoads.c bublbobl.c buggychl.c buster.c bwidow.c bwing.c bzone.c cabal.c cabaret.c calomega.c calorie.c canyon.c capbowl.c cardline.c carjmbre.c carpolo.c carrera.c caswin.c cave.c cb2001.c cbasebal.c cbuster.c cchance.c cclimber.c cesclass.c chaknpop.c champbas.c champbwl.c chance32.c changela.c cheekyms.c chinsan.c chsuper.c circusc.c cischeat.c citycon.c clayshoo.c cloak.c clshroad.c cmmb.c cninja.c cntsteer.c cobra.c coinmstr.c coinmvga.c combatsc.c commando.c compgolf.c contra.c coolridr.c cop01.c corona.c cps1.c cps3.c crbaloon.c crgolf.c crimfght.c crospang.c crshrace.c crystal.c cubeqst.c cultures.c cvs.c cyberbal.c cybertnk.c cyclemb.c d9final.c dacholer.c dai3wksi.c darius.c darkseal.c dassault.c dblewing.c dcheese.c dcon.c ddayjlc.c ddealer.c ddribble.c ddz.c dec0.c dec8.c deco156.c deco32.c deco_ld.c deniam.c deshoros.c destroyr.c dietgo.c discoboy.c diverboy.c djboy.c djmain.c dkong.c dlair.c dmndrby.c docastle.c dogfgt.c dominob.c dooyong.c dorachan.c dotrikun.c dragrace.c dreamwld.c drgnmst.c dribling.c drmicro.c drtomy.c drw80pkr.c dunhuang.c dynax.c dynduke.c egghunt.c enigma2.c epos.c ertictac.c esd16.c esh.c espial.c esripsys.c ettrivia.c exedexes.c exidy.c exidy440.c exprraid.c exzisus.c f-32.c f1gp.c fantland.c fastfred.c fcrash.c feversoc.c firebeat.c firetrap.c firetrk.c fitfight.c flipjack.c flkatck.c flower.c flstory.c flyball.c fortecar.c freekick.c fromanc2.c fromance.c funkybee.c funkyjet.c funworld.c funybubl.c gaelco.c gaelco2.c gaelco3d.c gaiden.c gal3.c galaga.c galastrm.c galaxi.c galaxia.c galaxian.c galaxold.c galgame.c galivan.c galspnbl.c gamtor.c gaplus.c gatron.c gberet.c gbusters.c gcpinbal.c gei.c gijoe.c ginganin.c gladiatr.c glass.c gng.c go2000.c goal92.c goindol.c goldngam.c goldnpkr.c goldstar.c gomoku.c good.c goodejan.c gotcha.c gottlieb.c gotya.c gpworld.c gradius3.c grchamp.c groundfx.c gstream.c gstriker.c gsword.c gticlub.c gumbo.c gunbustr.c gunpey.c gunsmoke.c gyruss.c halleys.c hanaawas.c harddriv.c hcastle.c highvdeo.c himesiki.c hitpoker.c hnayayoi.c holeland.c homedata.c homerun.c hornet.c hotblock.c hotstuff.c hvyunit.c hyperspt.c igs009.c igs011.c igs_m027.c ikki.c imolagp.c intrscti.c inufuku.c invqix.c istellar.c itech32.c itech8.c jack.c jackal.c jackpool.c jailbrek.c jalmah.c jangou.c jantotsu.c jclub2.c jokrwild.c jollyjgr.c jongkyo.c jrpacman.c jubilee.c junofrst.c kangaroo.c karnov.c kchamp.c kickgoal.c kingdrby.c kingobox.c kingpin.c kinst.c kncljoe.c koikoi.c konamigq.c konamigx.c konamim2.c kontest.c kopunch.c ksayakyu.c kungfur.c kyugo.c labyrunr.c ladybug.c ladyfrog.c laserbas.c laserbat.c lasso.c lastbank.c lastduel.c lastfght.c legionna.c leland.c lemmings.c lethal.c lgp.c liberate.c limenko.c lkage.c looping.c lordgun.c lsasquad.c ltcasino.c luckgrln.c lucky74.c lvcards.c lwings.c m10.c m14.c m52.c m57.c m58.c m62.c m63.c m72.c m79amb.c m90.c macrossp.c macs.c madalien.c madmotor.c magic10.c magicard.c magicfly.c magmax.c mainevt.c mainsnk.c majorpkr.c mappy.c marineb.c marinedt.c mario.c markham.c mastboy.c matmania.c maygayv1.c mayumi.c mazerbla.c mcatadv.c mcr68.c meadows.c megasys1.c megazone.c meijinsn.c mermaid.c metro.c mexico86.c micro3d.c midas.c midzeus.c mikie.c mil4000.c miniboy7.c minivadr.c mirage.c mirax.c missb2.c mitchell.c mjkjidai.c mjsister.c mlanding.c model2.c mogura.c mole.c momoko.c monzagp.c moo.c mosaic.c mouser.c mpoker.c mpu4plasma.c mrdo.c mrflea.c mrjong.c msisaac.c mugsmash.c multfish.c munchmo.c murogem.c mustache.c mw18w.c mwarr.c mystwarr.c namconb1.c namcond1.c namcos1.c namcos2.c namcos21.c namcos22.c namcos23.c namcos86.c nbmj9195.c nemesis.c neoprint.c neptunp2.c news.c nightgal.c ninjakd2.c ninjaw.c nitedrvr.c niyanpai.c nmg5.c nmk16.c norautp.c nova2001.c nsmpoker.c nss.c nycaptor.c nyny.c ohmygod.c ojankohs.c olibochu.c omegrace.c oneshot.c onetwo.c opwolf.c orbit.c othello.c othldrby.c othunder.c overdriv.c pachifev.c pacland.c pacman.c pandoras.c paradise.c parodius.c pasha2.c pass.c pastelg.c pbaction.c pcktgal.c pengo.c peyper.c pgm.c photon.c pinkiri8.c pipeline.c pirates.c pitnrun.c pkscram.c pktgaldx.c playch10.c playmark.c plygonet.c pokechmp.c poker72.c policetr.c polyplay.c poo.c poolshrk.c pooyan.c popeye.c popobear.c popper.c portrait.c powerins.c ppmast93.c prehisle.c progolf.c psattack.c psikyo.c psikyo4.c psikyosh.c pturn.c punchout.c pushman.c pzletime.c qdrmfgp.c quantum.c quasar.c quizdna.c quizo.c quizpani.c quizpun2.c r2dx_v33.c rabbit.c raiden.c raiden2.c rainbow.c rallyx.c rastan.c rbmk.c rcorsair.c realbrk.c redalert.c retofinv.c rgum.c rltennis.c rmhaihai.c rockrage.c rocnrope.c rohga.c rollerg.c rollrace.c roul.c route16.c royalmah.c rungun.c sandscrp.c sauro.c sbasketb.c scotrsht.c scramble.c sderby.c segag80r.c segag80v.c segajw.c segald.c segas32.c seibuspi.c seicross.c sengokmj.c senjyo.c seta.c seta2.c sf.c sfbonus.c shangha3.c shanghai.c shangkid.c shisen.c shougi.c sidearms.c sidepckt.c sigmab52.c sigmab98.c silkroad.c silvmil.c simpl156.c simpsons.c skimaxx.c skyarmy.c skydiver.c skyfox.c skykid.c skylncr.c skyraid.c slapfght.c slapshot.c sliver.c snk.c snk6502.c snk68.c snookr10.c snowbros.c solomon.c sonson.c spaceg.c spbactn.c spcforce.c speedatk.c speedbal.c speedspn.c speglsht.c spiders.c splash.c spoker.c spool99.c sprcros2.c sprint2.c spy.c srmp2.c srmp5.c srmp6.c srumbler.c ssfindo.c sshangha.c ssingles.c sslam.c ssozumo.c sspeedr.c ssrj.c sstrangr.c stactics.c stadhero.c starcrus.c starfire.c starshp1.c starwars.c statriv2.c stfight.c stlforce.c strnskil.c sub.c subs.c subsino2.c summit.c suna16.c suna8.c supbtime.c supdrapo.c superchs.c superdq.c superqix.c supertnk.c superwng.c suprgolf.c suprloco.c suprridr.c suprslam.c surpratk.c system1.c system16.c tagteam.c tail2nos.c taito_b.c taito_f2.c taito_f3.c taito_h.c taito_l.c taito_x.c taito_z.c taitoair.c taitojc.c taitosj.c taitotz.c tankbatt.c tankbust.c taotaido.c tapatune.c tasman.c tatsumi.c tattack.c taxidriv.c tbowl.c tceptor.c techno.c tecmo.c tecmo16.c tecmosys.c tehkanwc.c tempest.c terracre.c tetrisp2.c tgtpanic.c thedeep.c thepit.c thief.c thoop2.c thunderx.c tiamc1.c tigeroad.c timelimt.c timeplt.c timetrv.c tmnt.c tmspoker.c tnzs.c toaplan1.c toaplan2.c toki.c tomcat.c topspeed.c toratora.c toypop.c tp84.c trackfld.c travrusa.c triplhnt.c truco.c trucocl.c trvmadns.c trvquest.c tryout.c tsamurai.c ttchamp.c tubep.c tugboat.c tumbleb.c tumblep.c tunhunt.c turbo.c tutankhm.c twin16.c twincobr.c twins.c tx1.c ultraman.c ultrsprt.c umipoker.c undrfire.c unico.c unkhorse.c usgames.c vamphalf.c vaportra.c vastar.c vcombat.c vega.c vendetta.c vertigo.c victory.c videopkr.c vigilant.c viper.c vmetal.c volfied.c vpoker.c vroulet.c vulgus.c wallc.c wardner.c warpsped.c warpwarp.c warriorb.c wc90.c wc90b.c wecleman.c welltris.c wgp.c wheelfir.c whitestar.c wildpkr.c wink.c wiping.c witch.c wiz.c wrally.c xorworld.c xtheball.c xxmissio.c xyonix.c yiear.c yunsun16.c yunsung8.c zaccaria.c zaxxon.c zerozone.c zn.c zodiack.c zr107.c
[src/mame/includes]20pacgal.h 8080bw.h 88games.h aeroboto.h airbustr.h ajax.h aliens.h alpha68k.h appoooh.h asterix.h asteroid.h asuka.h atarisy2.h aztarac.h badlands.h bagman.h balsente.h bankp.h battlane.h battlex.h battlnts.h blockade.h blockhl.h bombjack.h bottom9.h brkthru.h bublbobl.h bwing.h bzone.h capbowl.h carjmbre.h carpolo.h cave.h cclimber.h champbas.h changela.h cheekyms.h circusc.h commando.h contra.h cps1.h cps3.h crbaloon.h crimfght.h cvs.h cyberbal.h dcheese.h ddribble.h dec8.h deco32.h djmain.h dkong.h dribling.h drmicro.h dynax.h dynduke.h espial.h esripsys.h exidy.h exidy440.h exprraid.h fantland.h fastfred.h firetrap.h firetrk.h fitfight.h flkatck.h freekick.h fromanc2.h gaelco3d.h galaga.h galastrm.h galaxia.h galaxian.h galaxold.h gameplan.h gaplus.h gbusters.h gcpinbal.h gijoe.h glass.h goldstar.h gottlieb.h gradius3.h grchamp.h groundfx.h gsword.h gunbustr.h gyruss.h harddriv.h homedata.h hyperspt.h itech32.h itech8.h jack.h jackal.h jailbrek.h karnov.h kchamp.h kickgoal.h kingobox.h kncljoe.h konamigx.h kopunch.h kyugo.h labyrunr.h laserbat.h leland.h lethal.h liberate.h lucky74.h lwings.h m10.h m72.h m90.h mainevt.h mappy.h marineb.h mario.h mcr68.h meadows.h megasys1.h megazone.h mermaid.h metro.h mexico86.h micro3d.h midzeus.h mikie.h mjkjidai.h moo.h mouser.h munchmo.h mustache.h mystwarr.h namconb1.h namcond1.h namcos2.h namcos22.h nbmj9195.h nemesis.h ninjakd2.h niyanpai.h orbit.h othunder.h overdriv.h pacland.h pacman.h pandoras.h paradise.h parodius.h pbaction.h pitnrun.h playch10.h plygonet.h policetr.h polyplay.h pooyan.h popeye.h popper.h psikyo4.h psikyosh.h punchout.h qdrmfgp.h quasar.h raiden.h raiden2.h rallyx.h realbrk.h redalert.h retofinv.h rltennis.h rockrage.h rocnrope.h rollrace.h rungun.h sauro.h sbasketb.h scotrsht.h segag80r.h segas32.h seibuspi.h seicross.h senjyo.h seta.h seta2.h simpl156.h simpsons.h skydiver.h skyfox.h skykid.h slapfght.h slapshot.h snk6502.h solomon.h spcforce.h spiders.h splash.h sprcros2.h sprint2.h spy.h ssozumo.h stactics.h starshp1.h stfight.h subs.h superqix.h suprridr.h surpratk.h system1.h system16.h tagteam.h taito_b.h taito_f2.h taito_f3.h taito_z.h taitojc.h tankbatt.h tankbust.h tatsumi.h tceptor.h thedeep.h thepit.h thief.h thunderx.h timelimt.h timeplt.h tmnt.h tnzs.h toaplan1.h toaplan2.h topspeed.h toypop.h tp84.h trackfld.h truco.h trucocl.h tsamurai.h tumbleb.h tutankhm.h twin16.h twincobr.h tx1.h undrfire.h vastar.h vendetta.h vertigo.h victory.h vulgus.h warpwarp.h wecleman.h wgp.h wiping.h wiz.h xxmissio.h yiear.h zaccaria.h zaxxon.h zodiack.h
[src/mame/machine]ajax.c asteroid.c balsente.c bublbobl.c carpolo.c galaxold.c harddriv.c leland.c mcr68.c mexico86.c namcos2.c slapfght.c stfight.c subs.c tnzs.c toaplan1.c twincobr.c vertigo.c xevious.c
[src/mame/video]esripsys.c exidy.c exidy440.c micro3d.c segag80r.c victory.c

trunk/src/mame/audio/cyberbal.c
r17996r17997
100100}
101101
102102
103INTERRUPT_GEN( cyberbal_sound_68k_irq_gen )
103INTERRUPT_GEN_MEMBER(cyberbal_state::cyberbal_sound_68k_irq_gen)
104104{
105   cyberbal_state *state = device->machine().driver_data<cyberbal_state>();
106   if (!state->m_fast_68k_int)
105   if (!m_fast_68k_int)
107106   {
108      state->m_fast_68k_int = 1;
109      update_sound_68k_interrupts(device->machine());
107      m_fast_68k_int = 1;
108      update_sound_68k_interrupts(machine());
110109   }
111110}
112111
trunk/src/mame/audio/aztarac.c
r17996r17997
4343    m_sound_status &= ~0x10;
4444}
4545
46INTERRUPT_GEN( aztarac_snd_timed_irq )
46INTERRUPT_GEN_MEMBER(aztarac_state::aztarac_snd_timed_irq)
4747{
48   aztarac_state *state = device->machine().driver_data<aztarac_state>();
49    state->m_sound_status ^= 0x10;
48    m_sound_status ^= 0x10;
5049
51    if (state->m_sound_status & 0x10)
52        device->execute().set_input_line(0,HOLD_LINE);
50    if (m_sound_status & 0x10)
51        device.execute().set_input_line(0,HOLD_LINE);
5352}
trunk/src/mame/audio/dkong.c
r17996r17997
14661466
14671467   MCFG_CPU_ADD("n2a03a", N2A03,N2A03_DEFAULTCLOCK)
14681468   MCFG_CPU_PROGRAM_MAP(dkong3_sound1_map)
1469   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1469   MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, nmi_line_pulse)
14701470
14711471   MCFG_CPU_ADD("n2a03b", N2A03,N2A03_DEFAULTCLOCK)
14721472   MCFG_CPU_PROGRAM_MAP(dkong3_sound2_map)
1473   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1473   MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, nmi_line_pulse)
14741474
14751475   /* sound latches */
14761476   MCFG_LATCH8_ADD( "latch1")
trunk/src/mame/audio/redalert.c
r17996r17997
212212
213213   MCFG_CPU_ADD("audiocpu", M6502, REDALERT_AUDIO_CPU_CLOCK)
214214   MCFG_CPU_PROGRAM_MAP(redalert_audio_map)
215   MCFG_CPU_PERIODIC_INT(irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)
215   MCFG_CPU_PERIODIC_INT_DRIVER(redalert_state, irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)
216216
217217   MCFG_SOUND_ADD("aysnd", AY8910, REDALERT_AY8910_CLOCK)
218218   MCFG_SOUND_CONFIG(redalert_ay8910_interface)
r17996r17997
404404
405405   MCFG_CPU_ADD("audiocpu", M6802, DEMONEYE_AUDIO_CPU_CLOCK)
406406   MCFG_CPU_PROGRAM_MAP(demoneye_audio_map)
407   MCFG_CPU_PERIODIC_INT(irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)  /* guess */
407   MCFG_CPU_PERIODIC_INT_DRIVER(redalert_state, irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)  /* guess */
408408
409409   MCFG_PIA6821_ADD("sndpia", demoneye_pia_intf)
410410
trunk/src/mame/machine/xevious.c
r17996r17997
182182}
183183
184184
185INTERRUPT_GEN( battles_interrupt_4 )
185INTERRUPT_GEN_MEMBER(xevious_state::battles_interrupt_4)
186186{
187   device->execute().set_input_line(0, HOLD_LINE);
187   device.execute().set_input_line(0, HOLD_LINE);
188188}
189189
trunk/src/mame/machine/bublbobl.c
r17996r17997
372372   machine.device("mcu")->execute().set_input_line(0, CLEAR_LINE);
373373}
374374
375INTERRUPT_GEN( bublbobl_m68705_interrupt )
375INTERRUPT_GEN_MEMBER(bublbobl_state::bublbobl_m68705_interrupt)
376376{
377   device->execute().set_input_line(0, ASSERT_LINE);
377   device.execute().set_input_line(0, ASSERT_LINE);
378378
379   device->machine().scheduler().timer_set(attotime::from_msec(1000/60), FUNC(bublbobl_m68705_irq_ack)); /* TODO: understand how this is ack'ed */
379   machine().scheduler().timer_set(attotime::from_msec(1000/60), FUNC(bublbobl_m68705_irq_ack)); /* TODO: understand how this is ack'ed */
380380}
381381
382382
trunk/src/mame/machine/tnzs.c
r17996r17997
614614   }
615615}
616616
617INTERRUPT_GEN( arknoid2_interrupt )
617INTERRUPT_GEN_MEMBER(tnzs_state::arknoid2_interrupt)
618618{
619   tnzs_state *state = device->machine().driver_data<tnzs_state>();
620619   int coin;
621620
622   switch (state->m_mcu_type)
621   switch (m_mcu_type)
623622   {
624623      case MCU_ARKANOID:
625624      case MCU_EXTRMATN:
626625      case MCU_DRTOPPEL:
627626      case MCU_PLUMPOP:
628627         coin  = 0;
629         coin |= ((state->ioport("COIN1")->read() & 1) << 0);
630         coin |= ((state->ioport("COIN2")->read() & 1) << 1);
631         coin |= ((state->ioport("IN2")->read() & 3) << 2);
628         coin |= ((ioport("COIN1")->read() & 1) << 0);
629         coin |= ((ioport("COIN2")->read() & 1) << 1);
630         coin |= ((ioport("IN2")->read() & 3) << 2);
632631         coin ^= 0x0c;
633         mcu_handle_coins(device->machine(), coin);
632         mcu_handle_coins(machine(), coin);
634633         break;
635634      default:
636635         break;
637636   }
638637
639   device->execute().set_input_line(0, HOLD_LINE);
638   device.execute().set_input_line(0, HOLD_LINE);
640639}
641640
642641MACHINE_RESET_MEMBER(tnzs_state,tnzs)
trunk/src/mame/machine/asteroid.c
r17996r17997
1313#include "includes/asteroid.h"
1414
1515
16INTERRUPT_GEN( asteroid_interrupt )
16INTERRUPT_GEN_MEMBER(asteroid_state::asteroid_interrupt)
1717{
1818   /* Turn off interrupts if self-test is enabled */
19   if (!(device->machine().root_device().ioport("IN0")->read() & 0x80))
20      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
19   if (!(machine().root_device().ioport("IN0")->read() & 0x80))
20      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
2121}
2222
23INTERRUPT_GEN( asterock_interrupt )
23INTERRUPT_GEN_MEMBER(asteroid_state::asterock_interrupt)
2424{
2525   /* Turn off interrupts if self-test is enabled */
26   if ((device->machine().root_device().ioport("IN0")->read() & 0x80))
27      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
26   if ((machine().root_device().ioport("IN0")->read() & 0x80))
27      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
2828}
2929
30INTERRUPT_GEN( llander_interrupt )
30INTERRUPT_GEN_MEMBER(asteroid_state::llander_interrupt)
3131{
3232   /* Turn off interrupts if self-test is enabled */
33   if (device->machine().root_device().ioport("IN0")->read() & 0x02)
34      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
33   if (machine().root_device().ioport("IN0")->read() & 0x02)
34      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
3535}
3636
3737READ8_MEMBER(asteroid_state::asteroid_IN0_r)
trunk/src/mame/machine/twincobr.c
r17996r17997
1414static const int toaplan_port_type[2] = { 0x7800c, 0x5c };
1515
1616
17INTERRUPT_GEN( twincobr_interrupt )
17INTERRUPT_GEN_MEMBER(twincobr_state::twincobr_interrupt)
1818{
19   twincobr_state *state = device->machine().driver_data<twincobr_state>();
20   if (state->m_intenable) {
21      state->m_intenable = 0;
22      device->execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
19   if (m_intenable) {
20      m_intenable = 0;
21      device.execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
2322   }
2423}
2524
26INTERRUPT_GEN( wardner_interrupt )
25INTERRUPT_GEN_MEMBER(twincobr_state::wardner_interrupt)
2726{
28   twincobr_state *state = device->machine().driver_data<twincobr_state>();
29   if (state->m_intenable) {
30      state->m_intenable = 0;
31      device->execute().set_input_line(0, HOLD_LINE);
27   if (m_intenable) {
28      m_intenable = 0;
29      device.execute().set_input_line(0, HOLD_LINE);
3230   }
3331}
3432
trunk/src/mame/machine/carpolo.c
r17996r17997
202202}
203203
204204
205INTERRUPT_GEN( carpolo_timer_interrupt )
205INTERRUPT_GEN_MEMBER(carpolo_state::carpolo_timer_interrupt)
206206{
207   carpolo_state *state = device->machine().driver_data<carpolo_state>();
208207   UINT8 port_value;
209208   int player;
210209
211210
212211   /* cause the timer interrupt */
213   ttl74148_input_line_w(state->m_ttl74148_3s, PRI0_PRIORTITY_LINE, 0);
214   state->m_priority_0_extension = TIMER_EXTRA_BITS;
212   ttl74148_input_line_w(m_ttl74148_3s, PRI0_PRIORTITY_LINE, 0);
213   m_priority_0_extension = TIMER_EXTRA_BITS;
215214
216   ttl74148_update(state->m_ttl74148_3s);
215   ttl74148_update(m_ttl74148_3s);
217216
218217
219218   /* check the coins here as well - they drive the clock of the flip-flops */
220   port_value = state->ioport("IN0")->read();
219   port_value = ioport("IN0")->read();
221220
222   state->m_ttl7474_2s_1->clock_w((port_value & 0x01) >> 0);
223   state->m_ttl7474_2s_2->clock_w((port_value & 0x02) >> 1);
224   state->m_ttl7474_2u_1->clock_w((port_value & 0x04) >> 2);
225   state->m_ttl7474_2u_2->clock_w((port_value & 0x08) >> 3);
221   m_ttl7474_2s_1->clock_w((port_value & 0x01) >> 0);
222   m_ttl7474_2s_2->clock_w((port_value & 0x02) >> 1);
223   m_ttl7474_2u_1->clock_w((port_value & 0x04) >> 2);
224   m_ttl7474_2u_2->clock_w((port_value & 0x08) >> 3);
226225
227226   /* read the steering controls */
228227   for (player = 0; player < 4; player++)
r17996r17997
234233      switch (player)
235234      {
236235         default:
237         case 0:   movement_flip_flop = state->m_ttl7474_1f_1;   dir_flip_flop = state->m_ttl7474_1f_2;   break;
238         case 1:   movement_flip_flop = state->m_ttl7474_1d_1;   dir_flip_flop = state->m_ttl7474_1d_2;   break;
239         case 2:   movement_flip_flop = state->m_ttl7474_1c_1;   dir_flip_flop = state->m_ttl7474_1c_2;   break;
240         case 3:   movement_flip_flop = state->m_ttl7474_1a_1;   dir_flip_flop = state->m_ttl7474_1a_2;   break;
236         case 0:   movement_flip_flop = m_ttl7474_1f_1;   dir_flip_flop = m_ttl7474_1f_2;   break;
237         case 1:   movement_flip_flop = m_ttl7474_1d_1;   dir_flip_flop = m_ttl7474_1d_2;   break;
238         case 2:   movement_flip_flop = m_ttl7474_1c_1;   dir_flip_flop = m_ttl7474_1c_2;   break;
239         case 3:   movement_flip_flop = m_ttl7474_1a_1;   dir_flip_flop = m_ttl7474_1a_2;   break;
241240      }
242241
243      port_value = device->machine().root_device().ioport(portnames[player])->read();
242      port_value = machine().root_device().ioport(portnames[player])->read();
244243
245      if (port_value != state->m_last_wheel_value[player])
244      if (port_value != m_last_wheel_value[player])
246245      {
247246         /* set the movement direction */
248         dir_flip_flop->d_w(((port_value - state->m_last_wheel_value[player]) & 0x80) ? 1 : 0);
247         dir_flip_flop->d_w(((port_value - m_last_wheel_value[player]) & 0x80) ? 1 : 0);
249248
250         state->m_last_wheel_value[player] = port_value;
249         m_last_wheel_value[player] = port_value;
251250      }
252251
253252      /* as the wheel moves, both flip-flops are clocked */
r17996r17997
258257
259258
260259   /* finally read the accelerator pedals */
261   port_value = device->machine().root_device().ioport("PEDALS")->read();
260   port_value = machine().root_device().ioport("PEDALS")->read();
262261
263262   for (player = 0; player < 4; player++)
264263   {
r17996r17997
266265           how much, resulting in only two different possible levels */
267266      if (port_value & 0x01)
268267      {
269         ttl74153_input_line_w(state->m_ttl74153_1k, 0, player, 1);
270         ttl74153_input_line_w(state->m_ttl74153_1k, 1, player, 0);
268         ttl74153_input_line_w(m_ttl74153_1k, 0, player, 1);
269         ttl74153_input_line_w(m_ttl74153_1k, 1, player, 0);
271270      }
272271      else if (port_value & 0x02)
273272      {
274         ttl74153_input_line_w(state->m_ttl74153_1k, 0, player, 1);
275         ttl74153_input_line_w(state->m_ttl74153_1k, 1, player, 1);
273         ttl74153_input_line_w(m_ttl74153_1k, 0, player, 1);
274         ttl74153_input_line_w(m_ttl74153_1k, 1, player, 1);
276275      }
277276      else
278277      {
279         ttl74153_input_line_w(state->m_ttl74153_1k, 0, player, 0);
278         ttl74153_input_line_w(m_ttl74153_1k, 0, player, 0);
280279         /* the other line is irrelevant */
281280      }
282281
283282      port_value >>= 2;
284283   }
285284
286   ttl74153_update(state->m_ttl74153_1k);
285   ttl74153_update(m_ttl74153_1k);
287286}
288287
289288// FIXME: Remove trampolines
trunk/src/mame/machine/balsente.c
r17996r17997
556556 *
557557 *************************************/
558558
559INTERRUPT_GEN( balsente_update_analog_inputs )
559INTERRUPT_GEN_MEMBER(balsente_state::balsente_update_analog_inputs)
560560{
561   balsente_state *state = device->machine().driver_data<balsente_state>();
562561   int i;
563562   static const char *const analog[] = { "AN0", "AN1", "AN2", "AN3" };
564563
r17996r17997
567566   /* ports are read once a frame, just at varying intervals. To get around this, we */
568567   /* read all the analog inputs at VBLANK time and just return the cached values. */
569568   for (i = 0; i < 4; i++)
570      state->m_analog_input_data[i] = device->machine().root_device().ioport(analog[i])->read();
569      m_analog_input_data[i] = machine().root_device().ioport(analog[i])->read();
571570}
572571
573572
trunk/src/mame/machine/mexico86.c
r17996r17997
150150}
151151
152152
153INTERRUPT_GEN( kikikai_interrupt )
153INTERRUPT_GEN_MEMBER(mexico86_state::kikikai_interrupt)
154154{
155   mexico86_state *state = device->machine().driver_data<mexico86_state>();
156155
157   if (state->m_mcu_running)
158      mcu_simulate(device->machine());
156   if (m_mcu_running)
157      mcu_simulate(machine());
159158
160   device->execute().set_input_line_vector(0, state->m_protection_ram[0]);
161   device->execute().set_input_line(0, HOLD_LINE);
159   device.execute().set_input_line_vector(0, m_protection_ram[0]);
160   device.execute().set_input_line(0, HOLD_LINE);
162161}
163162
164163
r17996r17997
218217
219218***************************************************************************/
220219
221INTERRUPT_GEN( mexico86_m68705_interrupt )
220INTERRUPT_GEN_MEMBER(mexico86_state::mexico86_m68705_interrupt)
222221{
223   device->execute().set_input_line(0, ASSERT_LINE);
222   device.execute().set_input_line(0, ASSERT_LINE);
224223}
225224
226225
trunk/src/mame/machine/vertigo.c
r17996r17997
140140}
141141
142142
143INTERRUPT_GEN( vertigo_interrupt )
143INTERRUPT_GEN_MEMBER(vertigo_state::vertigo_interrupt)
144144{
145145   /* Coin inputs cause IRQ6 */
146   if ((device->machine().root_device().ioport("COIN")->read() & 0x7) < 0x7)
147      update_irq_encoder(device->machine(), INPUT_LINE_IRQ6, ASSERT_LINE);
146   if ((machine().root_device().ioport("COIN")->read() & 0x7) < 0x7)
147      update_irq_encoder(machine(), INPUT_LINE_IRQ6, ASSERT_LINE);
148148}
149149
150150
trunk/src/mame/machine/namcos2.c
r17996r17997
680680   namcos2_posirq_timer->adjust(machine.primary_screen->time_until_pos(scanline, 80), scanline);
681681}
682682
683INTERRUPT_GEN( namcos2_68k_master_vblank )
683INTERRUPT_GEN_MEMBER(namcos2_shared_state::namcos2_68k_master_vblank)
684684{
685   namcos2_shared_state *state = device->machine().driver_data<namcos2_shared_state>();
686   if (!state->is_system21()) namcos2_adjust_posirq_timer(device->machine(), GetPosIRQScanline(device->machine()));
687   device->execute().set_input_line(namcos2_68k_master_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
685   if (!is_system21()) namcos2_adjust_posirq_timer(machine(), GetPosIRQScanline(machine()));
686   device.execute().set_input_line(namcos2_68k_master_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
688687}
689688
690INTERRUPT_GEN( namcos2_68k_slave_vblank )
689INTERRUPT_GEN_MEMBER(namcos2_shared_state::namcos2_68k_slave_vblank)
691690{
692   namcos2_shared_state *state = device->machine().driver_data<namcos2_shared_state>();
693   if (!state->is_system21()) namcos2_adjust_posirq_timer(device->machine(), GetPosIRQScanline(device->machine()));
694   device->execute().set_input_line(namcos2_68k_slave_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
691   if (!is_system21()) namcos2_adjust_posirq_timer(machine(), GetPosIRQScanline(machine()));
692   device.execute().set_input_line(namcos2_68k_slave_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
695693}
696694
697INTERRUPT_GEN( namcos2_68k_gpu_vblank )
695INTERRUPT_GEN_MEMBER(namcos2_shared_state::namcos2_68k_gpu_vblank)
698696{
699697   /* only used by namcos21 */
700   int scanline = GetPosIRQScanline(device->machine());
698   int scanline = GetPosIRQScanline(machine());
701699   scanline = 0x50+0x89; /* HACK for Winning Run */
702700
703701   //printf( "namcos2_68k_gpu_vblank(%d)\n",namcos2_68k_gpu_C148[NAMCOS2_C148_POSIRQ] );
704   namcos2_adjust_posirq_timer(device->machine(), scanline);
705   device->execute().set_input_line(namcos2_68k_gpu_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
702   namcos2_adjust_posirq_timer(machine(), scanline);
703   device.execute().set_input_line(namcos2_68k_gpu_C148[NAMCOS2_C148_VBLANKIRQ], HOLD_LINE);
706704}
707705
708706/**************************************************************/
trunk/src/mame/machine/harddriv.c
r17996r17997
113113}
114114
115115
116INTERRUPT_GEN( hd68k_irq_gen )
116INTERRUPT_GEN_MEMBER(harddriv_state::hd68k_irq_gen)
117117{
118   harddriv_state *state = device->machine().driver_data<harddriv_state>();
119   state->m_irq_state = 1;
120   atarigen_update_interrupts(device->machine());
118   m_irq_state = 1;
119   atarigen_update_interrupts(machine());
121120}
122121
123122
trunk/src/mame/machine/mcr68.c
r17996r17997
212212 *
213213 *************************************/
214214
215INTERRUPT_GEN( mcr68_interrupt )
215INTERRUPT_GEN_MEMBER(mcr68_state::mcr68_interrupt)
216216{
217   mcr68_state *state = device->machine().driver_data<mcr68_state>();
218217   /* update the 6840 VBLANK clock */
219   if (!state->m_m6840_state[0].timer_active)
220      subtract_from_counter(device->machine(), 0, 1);
218   if (!m_m6840_state[0].timer_active)
219      subtract_from_counter(machine(), 0, 1);
221220
222221   logerror("--- VBLANK ---\n");
223222
224223   /* also set a timer to generate the 493 signal at a specific time before the next VBLANK */
225224   /* the timing of this is crucial for Blasted and Tri-Sports, which check the timing of */
226225   /* VBLANK and 493 using counter 2 */
227   device->machine().scheduler().timer_set(attotime::from_hz(30) - state->m_timing_factor, state->m_v493_callback, state->m_v493_callback_name);
226   machine().scheduler().timer_set(attotime::from_hz(30) - m_timing_factor, m_v493_callback, m_v493_callback_name);
228227}
229228
230229
trunk/src/mame/machine/slapfght.c
r17996r17997
761761
762762
763763/* Generate interrups only if they have been enabled */
764INTERRUPT_GEN( getstar_interrupt )
764INTERRUPT_GEN_MEMBER(slapfght_state::getstar_interrupt)
765765{
766   slapfght_state *state = device->machine().driver_data<slapfght_state>();
767   if (state->m_getstar_sh_intenabled)
768      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
766   if (m_getstar_sh_intenabled)
767      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
769768}
770769
771770#ifdef UNUSED_FUNCTION
trunk/src/mame/machine/leland.c
r17996r17997
446446}
447447
448448
449INTERRUPT_GEN( leland_master_interrupt )
449INTERRUPT_GEN_MEMBER(leland_state::leland_master_interrupt)
450450{
451451   /* check for coins here */
452   if ((device->machine().root_device().ioport("IN1")->read() & 0x0e) != 0x0e)
453      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
452   if ((machine().root_device().ioport("IN1")->read() & 0x0e) != 0x0e)
453      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
454454}
455455
456456
trunk/src/mame/machine/toaplan1.c
r17996r17997
3939};
4040
4141
42INTERRUPT_GEN( toaplan1_interrupt )
42INTERRUPT_GEN_MEMBER(toaplan1_state::toaplan1_interrupt)
4343{
44   toaplan1_state *state = device->machine().driver_data<toaplan1_state>();
4544
46   if (state->m_intenable)
47      device->execute().set_input_line(4, HOLD_LINE);
45   if (m_intenable)
46      device.execute().set_input_line(4, HOLD_LINE);
4847}
4948
5049WRITE16_MEMBER(toaplan1_state::toaplan1_intenable_w)
trunk/src/mame/machine/stfight.c
r17996r17997
115115    machine.device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf);
116116}
117117
118INTERRUPT_GEN( stfight_vb_interrupt )
118INTERRUPT_GEN_MEMBER(stfight_state::stfight_vb_interrupt)
119119{
120120    // Do a RST10
121    device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);
122    device->machine().scheduler().timer_set(attotime::from_hz(120), FUNC(stfight_interrupt_1));
121    device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);
122    machine().scheduler().timer_set(attotime::from_hz(120), FUNC(stfight_interrupt_1));
123123}
124124
125125/*
trunk/src/mame/machine/galaxold.c
r17996r17997
413413   state_save_register_global(machine(), m__4in1_bank);
414414}
415415
416INTERRUPT_GEN( hunchbks_vh_interrupt )
416INTERRUPT_GEN_MEMBER(galaxold_state::hunchbks_vh_interrupt)
417417{
418   generic_pulse_irq_line_and_vector(device,0,0x03,1);
418   generic_pulse_irq_line_and_vector(device.execute(),0,0x03,1);
419419}
420420
421421DRIVER_INIT_MEMBER(galaxold_state,ladybugg)
trunk/src/mame/machine/subs.c
r17996r17997
2222/***************************************************************************
2323subs_interrupt
2424***************************************************************************/
25INTERRUPT_GEN( subs_interrupt )
25INTERRUPT_GEN_MEMBER(subs_state::subs_interrupt)
2626{
2727   /* only do NMI interrupt if not in TEST mode */
28   if ((device->machine().root_device().ioport("IN1")->read() & 0x40)==0x40)
29      device->execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
28   if ((machine().root_device().ioport("IN1")->read() & 0x40)==0x40)
29      device.execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
3030}
3131
3232/***************************************************************************
trunk/src/mame/machine/ajax.c
r17996r17997
225225   m_firq_enable = 0;
226226}
227227
228INTERRUPT_GEN( ajax_interrupt )
228INTERRUPT_GEN_MEMBER(ajax_state::ajax_interrupt)
229229{
230   ajax_state *state = device->machine().driver_data<ajax_state>();
231230
232   if (k051960_is_irq_enabled(state->m_k051960))
233      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
231   if (k051960_is_irq_enabled(m_k051960))
232      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
234233}
trunk/src/mame/video/segag80r.c
r17996r17997
3939}
4040
4141
42INTERRUPT_GEN( segag80r_vblank_start )
42INTERRUPT_GEN_MEMBER(segag80r_state::segag80r_vblank_start)
4343{
44   segag80r_state *state = device->machine().driver_data<segag80r_state>();
45   vblank_latch_set(device->machine());
44   vblank_latch_set(machine());
4645
4746   /* if interrupts are enabled, clock one */
48   if (state->m_video_control & 0x04)
47   if (m_video_control & 0x04)
4948      irq0_line_hold(device);
5049}
5150
5251
53INTERRUPT_GEN( sindbadm_vblank_start )
52INTERRUPT_GEN_MEMBER(segag80r_state::sindbadm_vblank_start)
5453{
55   vblank_latch_set(device->machine());
54   vblank_latch_set(machine());
5655
5756   /* interrupts appear to always be enabled, but they have a manual */
5857   /* acknowledge rather than an automatic ack; they are also not masked */
trunk/src/mame/video/victory.c
r17996r17997
8080}
8181
8282
83INTERRUPT_GEN( victory_vblank_interrupt )
83INTERRUPT_GEN_MEMBER(victory_state::victory_vblank_interrupt)
8484{
85   victory_state *state = device->machine().driver_data<victory_state>();
86   state->m_vblank_irq = 1;
85   m_vblank_irq = 1;
8786
88   victory_update_irq(device->machine());
87   victory_update_irq(machine());
8988}
9089
9190
trunk/src/mame/video/esripsys.c
r17996r17997
99#include "includes/esripsys.h"
1010
1111
12INTERRUPT_GEN( esripsys_vblank_irq )
12INTERRUPT_GEN_MEMBER(esripsys_state::esripsys_vblank_irq)
1313{
14   esripsys_state *state = device->machine().driver_data<esripsys_state>();
15   device->machine().device("game_cpu")->execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
16   state->m_frame_vbl = 0;
14   machine().device("game_cpu")->execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
15   m_frame_vbl = 0;
1716}
1817
1918static TIMER_CALLBACK( hblank_start_callback )
trunk/src/mame/video/exidy440.c
r17996r17997
233233}
234234
235235
236INTERRUPT_GEN( exidy440_vblank_interrupt )
236INTERRUPT_GEN_MEMBER(exidy440_state::exidy440_vblank_interrupt)
237237{
238   exidy440_state *state = device->machine().driver_data<exidy440_state>();
239238   /* set the FIRQ line on a VBLANK */
240   state->m_firq_vblank = 1;
241   exidy440_update_firq(device->machine());
239   m_firq_vblank = 1;
240   exidy440_update_firq(machine());
242241}
243242
244243
trunk/src/mame/video/micro3d.c
r17996r17997
752752   return m_pipe_data;
753753}
754754
755INTERRUPT_GEN( micro3d_vblank )
755INTERRUPT_GEN_MEMBER(micro3d_state::micro3d_vblank)
756756{
757//  mc68901_int_gen(device->machine(), GPIP7);
758   micro3d_state *state = device->machine().driver_data<micro3d_state>();
757//  mc68901_int_gen(machine(), GPIP7);
759758
760   state->m_display_buffer = state->m_drawing_buffer ^ 1;
759   m_display_buffer = m_drawing_buffer ^ 1;
761760}
trunk/src/mame/video/exidy.c
r17996r17997
6565}
6666
6767
68INTERRUPT_GEN( exidy_vblank_interrupt )
68INTERRUPT_GEN_MEMBER(exidy_state::exidy_vblank_interrupt)
6969{
70   exidy_state *state = device->machine().driver_data<exidy_state>();
7170   /* latch the current condition */
72   latch_condition(device->machine(), 0);
73   state->m_int_condition &= ~0x80;
71   latch_condition(machine(), 0);
72   m_int_condition &= ~0x80;
7473
7574   /* set the IRQ line */
76   device->execute().set_input_line(0, ASSERT_LINE);
75   device.execute().set_input_line(0, ASSERT_LINE);
7776}
7877
7978
trunk/src/mame/includes/tutankhm.h
r17996r17997
3232   DECLARE_MACHINE_START(tutankhm);
3333   DECLARE_MACHINE_RESET(tutankhm);
3434   UINT32 screen_update_tutankhm(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
35   INTERRUPT_GEN_MEMBER(tutankhm_interrupt);
3536};
trunk/src/mame/includes/m10.h
r17996r17997
8888   DECLARE_VIDEO_START(m15);
8989   UINT32 screen_update_m10(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
9090   UINT32 screen_update_m15(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
91   INTERRUPT_GEN_MEMBER(m11_interrupt);
92   INTERRUPT_GEN_MEMBER(m10_interrupt);
93   INTERRUPT_GEN_MEMBER(m15_interrupt);
9194};
9295
trunk/src/mame/includes/dynduke.h
r17996r17997
4141   TILE_GET_INFO_MEMBER(get_tx_tile_info);
4242   virtual void video_start();
4343   UINT32 screen_update_dynduke(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(dynduke_interrupt);
4445};
trunk/src/mame/includes/rungun.h
r17996r17997
5353   virtual void machine_reset();
5454   virtual void video_start();
5555   UINT32 screen_update_rng(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
56   INTERRUPT_GEN_MEMBER(rng_interrupt);
57   INTERRUPT_GEN_MEMBER(audio_interrupt);
5658};
5759/*----------- defined in video/rungun.c -----------*/
5860
trunk/src/mame/includes/skyfox.h
r17996r17997
3232   virtual void machine_reset();
3333   virtual void palette_init();
3434   UINT32 screen_update_skyfox(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
35   INTERRUPT_GEN_MEMBER(skyfox_interrupt);
3536};
trunk/src/mame/includes/bublbobl.h
r17996r17997
109109   DECLARE_MACHINE_START(common);
110110   DECLARE_MACHINE_RESET(common);
111111   UINT32 screen_update_bublbobl(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
112   INTERRUPT_GEN_MEMBER(bublbobl_m68705_interrupt);
112113};
113
114/*----------- defined in machine/bublbobl.c -----------*/
115// for 68705 bootleg
116INTERRUPT_GEN( bublbobl_m68705_interrupt );
trunk/src/mame/includes/rocnrope.h
r17996r17997
2929   virtual void video_start();
3030   virtual void palette_init();
3131   UINT32 screen_update_rocnrope(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(vblank_irq);
3233};
trunk/src/mame/includes/senjyo.h
r17996r17997
8282   virtual void machine_reset();
8383   virtual void video_start();
8484   UINT32 screen_update_senjyo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
85   INTERRUPT_GEN_MEMBER(senjyo_interrupt);
8586};
8687
8788/*----------- defined in audio/senjyo.c -----------*/
trunk/src/mame/includes/yiear.h
r17996r17997
3636   virtual void video_start();
3737   virtual void palette_init();
3838   UINT32 screen_update_yiear(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(yiear_vblank_interrupt);
40   INTERRUPT_GEN_MEMBER(yiear_nmi_interrupt);
3941};
trunk/src/mame/includes/bzone.h
r17996r17997
2626   DECLARE_DRIVER_INIT(bradley);
2727   virtual void machine_start();
2828   DECLARE_MACHINE_START(redbaron);
29   INTERRUPT_GEN_MEMBER(bzone_interrupt);
2930};
3031
3132
trunk/src/mame/includes/nbmj9195.h
r17996r17997
111111   DECLARE_VIDEO_START(nbmj9195_1layer);
112112   DECLARE_VIDEO_START(nbmj9195_nb22090);
113113   UINT32 screen_update_nbmj9195(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
114   INTERRUPT_GEN_MEMBER(ctc0_trg1);
114115};
115116
116117/*----------- defined in video/nbmj9195.c -----------*/
trunk/src/mame/includes/simpl156.h
r17996r17997
5959   DECLARE_DRIVER_INIT(chainrec);
6060   virtual void video_start();
6161   UINT32 screen_update_simpl156(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(simpl156_vbl_interrupt);
6263};
trunk/src/mame/includes/twincobr.h
r17996r17997
105105   DECLARE_VIDEO_START(toaplan0);
106106   DECLARE_MACHINE_RESET(wardner);
107107   UINT32 screen_update_toaplan0(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
108   INTERRUPT_GEN_MEMBER(twincobr_interrupt);
109   INTERRUPT_GEN_MEMBER(wardner_interrupt);
108110};
109111
110112
111113/*----------- defined in machine/twincobr.c -----------*/
112
113INTERRUPT_GEN( twincobr_interrupt );
114INTERRUPT_GEN( wardner_interrupt );
115114extern void twincobr_driver_savestate(running_machine &machine);
116115
117116/*----------- defined in video/twincobr.c -----------*/
trunk/src/mame/includes/battlnts.h
r17996r17997
2929   virtual void machine_start();
3030   virtual void machine_reset();
3131   UINT32 screen_update_battlnts(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(battlnts_interrupt);
3233};
3334
3435/*----------- defined in video/battlnts.c -----------*/
trunk/src/mame/includes/labyrunr.h
r17996r17997
4242   virtual void video_start();
4343   virtual void palette_init();
4444   UINT32 screen_update_labyrunr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
45   INTERRUPT_GEN_MEMBER(labyrunr_vblank_interrupt);
46   INTERRUPT_GEN_MEMBER(labyrunr_timer_interrupt);
4547};
trunk/src/mame/includes/thief.h
r17996r17997
3434   DECLARE_DRIVER_INIT(thief);
3535   virtual void video_start();
3636   UINT32 screen_update_thief(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
37   INTERRUPT_GEN_MEMBER(thief_interrupt);
3738};
trunk/src/mame/includes/sprint2.h
r17996r17997
6666   virtual void palette_init();
6767   UINT32 screen_update_sprint2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6868   void screen_eof_sprint2(screen_device &screen, bool state);
69   INTERRUPT_GEN_MEMBER(sprint2);
6970};
7071
7172/*----------- defined in audio/sprint2.c -----------*/
trunk/src/mame/includes/orbit.h
r17996r17997
4444   virtual void machine_reset();
4545   virtual void video_start();
4646   UINT32 screen_update_orbit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
47   INTERRUPT_GEN_MEMBER(orbit_interrupt);
4748};
4849/*----------- defined in audio/orbit.c -----------*/
4950DECLARE_WRITE8_DEVICE_HANDLER( orbit_note_w );
trunk/src/mame/includes/policetr.h
r17996r17997
4747   DECLARE_DRIVER_INIT(plctr13b);
4848   virtual void video_start();
4949   UINT32 screen_update_policetr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(irq4_gen);
5051};
trunk/src/mame/includes/seibuspi.h
r17996r17997
115115   DECLARE_MACHINE_RESET(sxx2f);
116116   UINT32 screen_update_spi(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
117117   UINT32 screen_update_sys386f2(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
118   INTERRUPT_GEN_MEMBER(spi_interrupt);
118119};
119120/*----------- defined in machine/spisprit.c -----------*/
120121void seibuspi_sprite_decrypt(UINT8 *src, int romsize);
trunk/src/mame/includes/sauro.h
r17996r17997
3838   DECLARE_VIDEO_START(sauro);
3939   UINT32 screen_update_trckydoc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4040   UINT32 screen_update_sauro(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
41   INTERRUPT_GEN_MEMBER(sauro_interrupt);
4142};
trunk/src/mame/includes/gaplus.h
r17996r17997
4747   virtual void palette_init();
4848   UINT32 screen_update_gaplus(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4949   void screen_eof_gaplus(screen_device &screen, bool state);
50   INTERRUPT_GEN_MEMBER(gaplus_vblank_main_irq);
51   INTERRUPT_GEN_MEMBER(gaplus_vblank_sub_irq);
52   INTERRUPT_GEN_MEMBER(gaplus_vblank_sub2_irq);
5053};
trunk/src/mame/includes/drmicro.h
r17996r17997
3535   virtual void video_start();
3636   virtual void palette_init();
3737   UINT32 screen_update_drmicro(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
38   INTERRUPT_GEN_MEMBER(drmicro_interrupt);
3839};
trunk/src/mame/includes/carpolo.h
r17996r17997
6868   virtual void palette_init();
6969   UINT32 screen_update_carpolo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7070   void screen_eof_carpolo(screen_device &screen, bool state);
71   INTERRUPT_GEN_MEMBER(carpolo_timer_interrupt);
7172};
7273
7374
r17996r17997
8384WRITE_LINE_DEVICE_HANDLER( carpolo_7474_2u_1_q_cb );
8485WRITE_LINE_DEVICE_HANDLER( carpolo_7474_2u_2_q_cb );
8586
86INTERRUPT_GEN( carpolo_timer_interrupt );
87
8887void carpolo_generate_car_car_interrupt(running_machine &machine, int car1, int car2);
8988void carpolo_generate_ball_screen_interrupt(running_machine &machine, UINT8 cause);
9089void carpolo_generate_car_goal_interrupt(running_machine &machine, int car, int right_goal);
trunk/src/mame/includes/system1.h
r17996r17997
107107   UINT32 screen_update_system1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
108108   UINT32 screen_update_system2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
109109   UINT32 screen_update_system2_rowscroll(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
110   INTERRUPT_GEN_MEMBER(mcu_irq_assert);
110111};
111112
112113
trunk/src/mame/includes/niyanpai.h
r17996r17997
8080   virtual void machine_reset();
8181   virtual void video_start();
8282   UINT32 screen_update_niyanpai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
83   INTERRUPT_GEN_MEMBER(niyanpai_interrupt);
8384};
trunk/src/mame/includes/seta2.h
r17996r17997
7171   DECLARE_VIDEO_START(seta2_xoffset);
7272   UINT32 screen_update_seta2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7373   void screen_eof_seta2(screen_device &screen, bool state);
74   INTERRUPT_GEN_MEMBER(seta2_interrupt);
75   INTERRUPT_GEN_MEMBER(samshoot_interrupt);
76   INTERRUPT_GEN_MEMBER(funcube_sub_timer_irq);
7477};
trunk/src/mame/includes/flkatck.h
r17996r17997
3939   virtual void machine_reset();
4040   virtual void video_start();
4141   UINT32 screen_update_flkatck(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(flkatck_interrupt);
4243};
trunk/src/mame/includes/dynax.h
r17996r17997
471471   UINT32 screen_update_jantouki_top(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
472472   UINT32 screen_update_jantouki_bottom(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
473473   UINT32 screen_update_htengoku(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
474   INTERRUPT_GEN_MEMBER(sprtmtch_vblank_interrupt);
475   INTERRUPT_GEN_MEMBER(jantouki_vblank_interrupt);
476   INTERRUPT_GEN_MEMBER(jantouki_sound_vblank_interrupt);
477   INTERRUPT_GEN_MEMBER(yarunara_clock_interrupt);
478   INTERRUPT_GEN_MEMBER(mjelctrn_vblank_interrupt);
474479};
475480
476481//----------- defined in drivers/dynax.c -----------
trunk/src/mame/includes/contra.h
r17996r17997
6161   virtual void video_start();
6262   virtual void palette_init();
6363   UINT32 screen_update_contra(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
64   INTERRUPT_GEN_MEMBER(contra_interrupt);
6465};
trunk/src/mame/includes/paradise.h
r17996r17997
5454   UINT32 screen_update_paradise(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5555   UINT32 screen_update_torus(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5656   UINT32 screen_update_madball(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(paradise_irq);
5758};
trunk/src/mame/includes/dribling.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void palette_init();
4949   UINT32 screen_update_dribling(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(dribling_irq_gen);
5051};
trunk/src/mame/includes/balsente.h
r17996r17997
193193   virtual void machine_reset();
194194   virtual void video_start();
195195   UINT32 screen_update_balsente(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
196   INTERRUPT_GEN_MEMBER(balsente_update_analog_inputs);
196197};
197198
198199
r17996r17997
202203
203204void balsente_noise_gen(device_t *device, int count, short *buffer);
204205
205INTERRUPT_GEN( balsente_update_analog_inputs );
206
207206TIMER_DEVICE_CALLBACK( balsente_counter_callback );
208207
209208TIMER_DEVICE_CALLBACK( balsente_clock_counter_0_ff );
trunk/src/mame/includes/itech32.h
r17996r17997
158158   virtual void video_start();
159159   DECLARE_MACHINE_RESET(drivedge);
160160   UINT32 screen_update_itech32(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
161   INTERRUPT_GEN_MEMBER(generate_int1);
161162};
162163
163164/*----------- defined in drivers/itech32.c -----------*/
trunk/src/mame/includes/mexico86.h
r17996r17997
5555   virtual void machine_reset();
5656   UINT32 screen_update_mexico86(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5757   UINT32 screen_update_kikikai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
58   INTERRUPT_GEN_MEMBER(kikikai_interrupt);
59   INTERRUPT_GEN_MEMBER(mexico86_m68705_interrupt);
5860};
59
60/*----------- defined in machine/mexico86.c -----------*/
61INTERRUPT_GEN( kikikai_interrupt );
62INTERRUPT_GEN( mexico86_m68705_interrupt );
trunk/src/mame/includes/fitfight.h
r17996r17997
6262   virtual void machine_reset();
6363   virtual void video_start();
6464   UINT32 screen_update_fitfight(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
65   INTERRUPT_GEN_MEMBER(snd_irq);
6566};
trunk/src/mame/includes/ddribble.h
r17996r17997
6060   virtual void video_start();
6161   virtual void palette_init();
6262   UINT32 screen_update_ddribble(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
63   INTERRUPT_GEN_MEMBER(ddribble_interrupt_0);
64   INTERRUPT_GEN_MEMBER(ddribble_interrupt_1);
6365};
trunk/src/mame/includes/mouser.h
r17996r17997
3636   virtual void machine_reset();
3737   virtual void palette_init();
3838   UINT32 screen_update_mouser(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(mouser_nmi_interrupt);
40   INTERRUPT_GEN_MEMBER(mouser_sound_nmi_assert);
3941};
trunk/src/mame/includes/undrfire.h
r17996r17997
4545   virtual void video_start();
4646   UINT32 screen_update_undrfire(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4747   UINT32 screen_update_cbombers(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   INTERRUPT_GEN_MEMBER(undrfire_interrupt);
4849};
trunk/src/mame/includes/deco32.h
r17996r17997
109109   UINT32 screen_update_fghthist(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
110110   UINT32 screen_update_nslasher(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);   
111111   void screen_eof_captaven(screen_device &screen, bool state);
112   INTERRUPT_GEN_MEMBER(deco32_vbl_interrupt);
112113};
113114
114115class dragngun_state : public deco32_state
trunk/src/mame/includes/vertigo.h
r17996r17997
110110   DECLARE_WRITE16_MEMBER(vertigo_pit8254_lsb_w);
111111   virtual void machine_start();
112112   virtual void machine_reset();
113   INTERRUPT_GEN_MEMBER(vertigo_interrupt);
113114};
114115
115116/*----------- defined in machine/vertigo.c -----------*/
r17996r17997
118119
119120extern const struct pit8253_config vertigo_pit8254_config;
120121
121INTERRUPT_GEN( vertigo_interrupt );
122
123122/*----------- defined in video/vertigo.c -----------*/
124123
125124void vertigo_vproc_init(running_machine &machine);
trunk/src/mame/includes/midzeus.h
r17996r17997
5858   DECLARE_VIDEO_START(midzeus2);
5959   UINT32 screen_update_midzeus(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6060   UINT32 screen_update_midzeus2(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
61   INTERRUPT_GEN_MEMBER(display_irq);
6162};
6263
6364/*----------- defined in video/midzeus2.c -----------*/
trunk/src/mame/includes/grchamp.h
r17996r17997
7272   virtual void video_start();
7373   virtual void palette_init();
7474   UINT32 screen_update_grchamp(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
75   INTERRUPT_GEN_MEMBER(grchamp_cpu0_interrupt);
76   INTERRUPT_GEN_MEMBER(grchamp_cpu1_interrupt);
7577};
7678
7779/* Discrete Sound Input Nodes */
trunk/src/mame/includes/zaxxon.h
r17996r17997
7272   UINT32 screen_update_futspy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7373   UINT32 screen_update_razmataz(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7474   UINT32 screen_update_congo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
75   INTERRUPT_GEN_MEMBER(vblank_int);
7576};
7677
7778
trunk/src/mame/includes/trackfld.h
r17996r17997
6666   DECLARE_PALETTE_INIT(trackfld);
6767   DECLARE_VIDEO_START(atlantol);
6868   UINT32 screen_update_trackfld(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
69   INTERRUPT_GEN_MEMBER(vblank_irq);
70   INTERRUPT_GEN_MEMBER(vblank_nmi);
71   INTERRUPT_GEN_MEMBER(yieartf_timer_irq);
6972};
trunk/src/mame/includes/fastfred.h
r17996r17997
6363   DECLARE_VIDEO_START(imago);
6464   UINT32 screen_update_fastfred(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6565   UINT32 screen_update_imago(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
66   INTERRUPT_GEN_MEMBER(vblank_irq);
67   INTERRUPT_GEN_MEMBER(sound_timer_irq);
6668};
6769
6870/*----------- defined in video/fastfred.c -----------*/
trunk/src/mame/includes/karnov.h
r17996r17997
5858   DECLARE_VIDEO_START(karnov);
5959   DECLARE_VIDEO_START(wndrplnt);
6060   UINT32 screen_update_karnov(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
61   INTERRUPT_GEN_MEMBER(karnov_interrupt);
6162};
6263
6364enum {
trunk/src/mame/includes/lwings.h
r17996r17997
6060   DECLARE_VIDEO_START(avengers);
6161   UINT32 screen_update_lwings(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6262   UINT32 screen_update_trojan(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
63   INTERRUPT_GEN_MEMBER(lwings_interrupt);
64   INTERRUPT_GEN_MEMBER(avengers_interrupt);
6365};
trunk/src/mame/includes/punchout.h
r17996r17997
6767   UINT32 screen_update_punchout_bottom(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6868   UINT32 screen_update_armwrest_top(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6969   UINT32 screen_update_armwrest_bottom(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
70   INTERRUPT_GEN_MEMBER(vblank_irq);
7071};
trunk/src/mame/includes/kopunch.h
r17996r17997
4343   virtual void video_start();
4444   virtual void palette_init();
4545   UINT32 screen_update_kopunch(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(kopunch_interrupt);
4647};
trunk/src/mame/includes/cclimber.h
r17996r17997
7070   UINT32 screen_update_swimmer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7171   UINT32 screen_update_yamato(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7272   UINT32 screen_update_toprollr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
73   INTERRUPT_GEN_MEMBER(vblank_irq);
7374};
trunk/src/mame/includes/dkong.h
r17996r17997
256256   UINT32 screen_update_dkong(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
257257   UINT32 screen_update_pestplce(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
258258   UINT32 screen_update_spclforc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
259   INTERRUPT_GEN_MEMBER(s2650_interrupt);
260   INTERRUPT_GEN_MEMBER(vblank_irq);
259261};
260262
261263/*----------- defined in audio/dkong.c -----------*/
trunk/src/mame/includes/appoooh.h
r17996r17997
5252   DECLARE_PALETTE_INIT(robowres);
5353   UINT32 screen_update_appoooh(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5454   UINT32 screen_update_robowres(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(vblank_irq);
5556};
5657
5758#define CHR1_OFST   0x00  /* palette page of char set #1 */
trunk/src/mame/includes/aliens.h
r17996r17997
3939   virtual void machine_reset();
4040   virtual void video_start();
4141   UINT32 screen_update_aliens(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(aliens_interrupt);
4243};
4344
4445/*----------- defined in video/aliens.c -----------*/
trunk/src/mame/includes/88games.h
r17996r17997
4747   virtual void machine_start();
4848   virtual void machine_reset();
4949   UINT32 screen_update_88games(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(k88games_interrupt);
5051};
5152
5253/*----------- defined in video/88games.c -----------*/
trunk/src/mame/includes/goldstar.h
r17996r17997
147147   UINT32 screen_update_magical(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
148148   UINT32 screen_update_amcoe1a(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
149149   UINT32 screen_update_unkch(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
150   INTERRUPT_GEN_MEMBER(lucky8_irq);
150151};
trunk/src/mame/includes/20pacgal.h
r17996r17997
5555   virtual void machine_start();
5656   virtual void machine_reset();
5757   UINT32 screen_update_20pacgal(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
58   INTERRUPT_GEN_MEMBER(vblank_irq);
5859};
5960
6061
trunk/src/mame/includes/seicross.h
r17996r17997
3030   virtual void video_start();
3131   virtual void palette_init();
3232   UINT32 screen_update_seicross(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
33   INTERRUPT_GEN_MEMBER(vblank_irq);
3334};
trunk/src/mame/includes/system16.h
r17996r17997
193193   UINT32 screen_update_system18old(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
194194   UINT32 screen_update_s16a_bootleg(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
195195   UINT32 screen_update_s16a_bootleg_passht4b(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
196   INTERRUPT_GEN_MEMBER(sys16_interrupt);
196197};
trunk/src/mame/includes/redalert.h
r17996r17997
4040   UINT32 screen_update_redalert(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
4141   UINT32 screen_update_demoneye(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
4242   UINT32 screen_update_panther(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(redalert_vblank_interrupt);
4344};
4445/*----------- defined in audio/redalert.c -----------*/
4546
trunk/src/mame/includes/simpsons.h
r17996r17997
4040   virtual void machine_start();
4141   virtual void machine_reset();
4242   UINT32 screen_update_simpsons(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(simpsons_irq);
4344};
4445
4546/*----------- defined in machine/simpsons.c -----------*/
trunk/src/mame/includes/taito_b.h
r17996r17997
7373   UINT32 screen_update_taitob(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7474   UINT32 screen_update_realpunc(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
7575   void screen_eof_taitob(screen_device &screen, bool state);
76   INTERRUPT_GEN_MEMBER(rastansaga2_interrupt);
77   INTERRUPT_GEN_MEMBER(crimec_interrupt);
78   INTERRUPT_GEN_MEMBER(hitice_interrupt);
79   INTERRUPT_GEN_MEMBER(rambo3_interrupt);
80   INTERRUPT_GEN_MEMBER(pbobble_interrupt);
81   INTERRUPT_GEN_MEMBER(viofight_interrupt);
82   INTERRUPT_GEN_MEMBER(masterw_interrupt);
83   INTERRUPT_GEN_MEMBER(silentd_interrupt);
84   INTERRUPT_GEN_MEMBER(selfeena_interrupt);
85   INTERRUPT_GEN_MEMBER(sbm_interrupt);
86   INTERRUPT_GEN_MEMBER(realpunc_interrupt);
7687};
trunk/src/mame/includes/jackal.h
r17996r17997
4343   virtual void video_start();
4444   virtual void palette_init();
4545   UINT32 screen_update_jackal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(jackal_interrupt);
4647};
4748
4849/*----------- defined in video/jackal.c -----------*/
trunk/src/mame/includes/qdrmfgp.h
r17996r17997
3939   DECLARE_MACHINE_START(qdrmfgp2);
4040   DECLARE_VIDEO_START(qdrmfgp2);
4141   UINT32 screen_update_qdrmfgp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(qdrmfgp2_interrupt);
4243};
4344
4445/*----------- defined in video/qdrmfgp.c -----------*/
trunk/src/mame/includes/cps1.h
r17996r17997
213213   UINT32 screen_update_fcrash(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
214214   UINT32 screen_update_kodb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
215215   void screen_eof_cps1(screen_device &screen, bool state);
216   INTERRUPT_GEN_MEMBER(cps1_interrupt);
217   INTERRUPT_GEN_MEMBER(cps1_qsound_interrupt);
216218};
217219
218220/*----------- defined in drivers/cps1.c -----------*/
219221
220222ADDRESS_MAP_EXTERN( qsound_sub_map, 8 );
221223
222INTERRUPT_GEN( cps1_interrupt );
223
224224GFXDECODE_EXTERN( cps1 );
225225
226226
trunk/src/mame/includes/wiz.h
r17996r17997
5151   UINT32 screen_update_wiz(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5252   UINT32 screen_update_stinger(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5353   UINT32 screen_update_kungfut(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(wiz_vblank_interrupt);
55   INTERRUPT_GEN_MEMBER(wiz_sound_interrupt);
5456};
trunk/src/mame/includes/stactics.h
r17996r17997
6060   DECLARE_VIDEO_START(stactics);
6161   DECLARE_PALETTE_INIT(stactics);
6262   UINT32 screen_update_stactics(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
63   INTERRUPT_GEN_MEMBER(stactics_interrupt);
6364};
6465/*----------- defined in video/stactics.c -----------*/
6566MACHINE_CONFIG_EXTERN( stactics_video );
trunk/src/mame/includes/mermaid.h
r17996r17997
7979   DECLARE_PALETTE_INIT(rougien);
8080   UINT32 screen_update_mermaid(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8181   void screen_eof_mermaid(screen_device &screen, bool state);
82   INTERRUPT_GEN_MEMBER(vblank_irq);
8283};
trunk/src/mame/includes/gaelco3d.h
r17996r17997
116116   DECLARE_MACHINE_RESET(gaelco3d2);
117117   DECLARE_MACHINE_RESET(common);
118118   UINT32 screen_update_gaelco3d(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
119   INTERRUPT_GEN_MEMBER(vblank_gen);
119120};
120121
121122/*----------- defined in video/gaelco3d.c -----------*/
trunk/src/mame/includes/kickgoal.h
r17996r17997
7575   DECLARE_VIDEO_START(kickgoal);
7676   DECLARE_VIDEO_START(actionhw);
7777   UINT32 screen_update_kickgoal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
78   INTERRUPT_GEN_MEMBER(kickgoal_interrupt);
7879};
trunk/src/mame/includes/galaxian.h
r17996r17997
224224   DECLARE_PALETTE_INIT(moonwar);
225225   void tenspot_set_game_bank(running_machine& machine, int bank, int from_game);
226226   UINT32 screen_update_galaxian(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
227   INTERRUPT_GEN_MEMBER(interrupt_gen);
228   INTERRUPT_GEN_MEMBER(fakechange_interrupt_gen);
227229};
228230
229231
trunk/src/mame/includes/itech8.h
r17996r17997
9494   UINT32 screen_update_slikshot(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
9595   UINT32 screen_update_itech8_2page(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
9696   UINT32 screen_update_itech8_2page_large(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
97   INTERRUPT_GEN_MEMBER(generate_nmi);
9798};
9899
99100
trunk/src/mame/includes/namconb1.h
r17996r17997
7777   DECLARE_VIDEO_START(namconb2);
7878   UINT32 screen_update_namconb1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7979   UINT32 screen_update_namconb2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
80   INTERRUPT_GEN_MEMBER(namconb1_interrupt);
81   INTERRUPT_GEN_MEMBER(namconb2_interrupt);
8082};
trunk/src/mame/includes/wiping.h
r17996r17997
2222   DECLARE_WRITE8_MEMBER(wiping_flipscreen_w);
2323   virtual void palette_init();
2424   UINT32 screen_update_wiping(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
25   INTERRUPT_GEN_MEMBER(vblank_irq);
26   INTERRUPT_GEN_MEMBER(sound_timer_irq);
2527};
trunk/src/mame/includes/kyugo.h
r17996r17997
5959   virtual void machine_reset();
6060   virtual void video_start();
6161   UINT32 screen_update_kyugo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(vblank_irq);
6263};
6364
trunk/src/mame/includes/leland.h
r17996r17997
142142   DECLARE_VIDEO_START(ataxx);
143143   UINT32 screen_update_leland(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
144144   UINT32 screen_update_ataxx(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
145   INTERRUPT_GEN_MEMBER(leland_master_interrupt);
145146};
146147
147148
r17996r17997
153154#define SERIAL_TYPE_ENCRYPT      3
154155#define SERIAL_TYPE_ENCRYPT_XOR   4
155156
156
157
158
159
160
161
162
163
164
165
166
167
168INTERRUPT_GEN( leland_master_interrupt );
169
170157void cerberus_bankswitch(running_machine &machine);
171158void mayhem_bankswitch(running_machine &machine);
172159void dangerz_bankswitch(running_machine &machine);
trunk/src/mame/includes/popeye.h
r17996r17997
4141   DECLARE_VIDEO_START(popeye);
4242   DECLARE_PALETTE_INIT(popeyebl);
4343   UINT32 screen_update_popeye(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(popeye_interrupt);
4445};
trunk/src/mame/includes/blockade.h
r17996r17997
2727   virtual void video_start();
2828   virtual void palette_init();
2929   UINT32 screen_update_blockade(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
30   INTERRUPT_GEN_MEMBER(blockade_interrupt);
3031};
3132
3233/*----------- defined in audio/blockade.c -----------*/
trunk/src/mame/includes/espial.h
r17996r17997
5252   virtual void palette_init();
5353   DECLARE_VIDEO_START(netwars);
5454   UINT32 screen_update_espial(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(espial_sound_nmi_gen);
5556};
trunk/src/mame/includes/hyperspt.h
r17996r17997
4343   virtual void palette_init();
4444   DECLARE_VIDEO_START(roadf);
4545   UINT32 screen_update_hyperspt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(vblank_irq);
4647};
trunk/src/mame/includes/toaplan1.h
r17996r17997
143143   void screen_eof_rallybik(screen_device &screen, bool state);
144144   void screen_eof_toaplan1(screen_device &screen, bool state);
145145   void screen_eof_samesame(screen_device &screen, bool state);
146   INTERRUPT_GEN_MEMBER(toaplan1_interrupt);
146147};
147148
148149
149150/*----------- defined in machine/toaplan1.c -----------*/
150
151INTERRUPT_GEN( toaplan1_interrupt );
152151void toaplan1_driver_savestate(running_machine &machine);
153152void demonwld_driver_savestate(running_machine &machine);
154153void vimana_driver_savestate(running_machine &machine);
trunk/src/mame/includes/segag80r.h
r17996r17997
9999   virtual void machine_start();
100100   virtual void video_start();
101101   UINT32 screen_update_segag80r(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
102   INTERRUPT_GEN_MEMBER(segag80r_vblank_start);
103   INTERRUPT_GEN_MEMBER(sindbadm_vblank_start);
102104};
103105
104106
r17996r17997
116118#define G80_BACKGROUND_MONSTERB      2
117119#define G80_BACKGROUND_PIGNEWT      3
118120#define G80_BACKGROUND_SINDBADM      4
119
120INTERRUPT_GEN( segag80r_vblank_start );
121INTERRUPT_GEN( sindbadm_vblank_start );
trunk/src/mame/includes/tmnt.h
r17996r17997
140140   UINT32 screen_update_tmnt2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
141141   UINT32 screen_update_thndrx2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
142142   void screen_eof_blswhstl(screen_device &screen, bool state);
143   INTERRUPT_GEN_MEMBER(cuebrick_interrupt);
144   INTERRUPT_GEN_MEMBER(punkshot_interrupt);
145   INTERRUPT_GEN_MEMBER(lgtnfght_interrupt);
146   INTERRUPT_GEN_MEMBER(tmnt_vblank_irq);
143147};
144148
145149
trunk/src/mame/includes/raiden2.h
r17996r17997
149149   DECLARE_MACHINE_RESET(xsedae);
150150   DECLARE_MACHINE_RESET(raidendx);
151151   UINT32 screen_update_raiden2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
152   INTERRUPT_GEN_MEMBER(raiden2_interrupt);
152153};
153154
154155/*----------- defined in machine/r2crypt.c -----------*/
trunk/src/mame/includes/zodiack.h
r17996r17997
6767   TILE_GET_INFO_MEMBER(get_bg_tile_info);
6868   TILE_GET_INFO_MEMBER(get_fg_tile_info);
6969   DECLARE_PALETTE_INIT(zodiack);
70   INTERRUPT_GEN_MEMBER(zodiack_sound_nmi_gen);
7071};
7172
7273class percuss_state : public zodiack_state
trunk/src/mame/includes/taitojc.h
r17996r17997
161161   virtual void video_start();
162162   UINT32 screen_update_taitojc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
163163   UINT32 screen_update_dendego(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
164   INTERRUPT_GEN_MEMBER(taitojc_vblank);
164165};
165166
166167
trunk/src/mame/includes/pitnrun.h
r17996r17997
5252   virtual void video_start();
5353   virtual void palette_init();
5454   UINT32 screen_update_pitnrun(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(pitnrun_nmi_source);
5556};
trunk/src/mame/includes/suprridr.h
r17996r17997
4141   virtual void video_start();
4242   virtual void palette_init();
4343   UINT32 screen_update_suprridr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(main_nmi_gen);
4445};
4546
4647/*----------- defined in video/suprridr.c -----------*/
trunk/src/mame/includes/spy.h
r17996r17997
4545   virtual void machine_reset();
4646   virtual void video_start();
4747   UINT32 screen_update_spy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   INTERRUPT_GEN_MEMBER(spy_interrupt);
4849};
4950
5051/*----------- defined in video/spy.c -----------*/
trunk/src/mame/includes/gameplan.h
r17996r17997
7070   DECLARE_VIDEO_START(common);
7171   UINT32 screen_update_gameplan(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
7272   UINT32 screen_update_leprechn(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
73   INTERRUPT_GEN_MEMBER(trvquest_interrupt);
7374};
7475
7576/*----------- defined in video/gameplan.c -----------*/
trunk/src/mame/includes/capbowl.h
r17996r17997
4141   virtual void machine_reset();
4242   virtual void video_start();
4343   UINT32 screen_update_capbowl(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(capbowl_interrupt);
4445};
trunk/src/mame/includes/sbasketb.h
r17996r17997
4343   virtual void video_start();
4444   virtual void palette_init();
4545   UINT32 screen_update_sbasketb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(vblank_irq);
4647};
trunk/src/mame/includes/battlex.h
r17996r17997
3636   virtual void machine_reset();
3737   virtual void video_start();
3838   UINT32 screen_update_battlex(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(battlex_interrupt);
3940};
trunk/src/mame/includes/cps3.h
r17996r17997
106106   virtual void machine_reset();
107107   virtual void video_start();
108108   UINT32 screen_update_cps3(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
109   INTERRUPT_GEN_MEMBER(cps3_vbl_interrupt);
110   INTERRUPT_GEN_MEMBER(cps3_other_interrupt);
109111};
110112
111113
trunk/src/mame/includes/glass.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void video_start();
4949   UINT32 screen_update_glass(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(glass_interrupt);
5051};
trunk/src/mame/includes/spiders.h
r17996r17997
2929   DECLARE_WRITE8_MEMBER(gfx_rom_intf_w);
3030   DECLARE_READ8_MEMBER(gfx_rom_r);
3131   virtual void machine_start();
32   INTERRUPT_GEN_MEMBER(update_pia_1);
3233};
3334
3435/*----------- defined in audio/spiders.c -----------*/
trunk/src/mame/includes/toaplan2.h
r17996r17997
127127   UINT32 screen_update_toaplan2_dual(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
128128   UINT32 screen_update_toaplan2_mixed(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
129129   void screen_eof_toaplan2(screen_device &screen, bool state);
130   INTERRUPT_GEN_MEMBER(toaplan2_vblank_irq1);
131   INTERRUPT_GEN_MEMBER(toaplan2_vblank_irq2);
132   INTERRUPT_GEN_MEMBER(toaplan2_vblank_irq4);
133   INTERRUPT_GEN_MEMBER(bbakraid_snd_interrupt);
130134};
trunk/src/mame/includes/mjkjidai.h
r17996r17997
2929   TILE_GET_INFO_MEMBER(get_tile_info);
3030   virtual void video_start();
3131   UINT32 screen_update_mjkjidai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(vblank_irq);
3233};
trunk/src/mame/includes/jailbrek.h
r17996r17997
4343   virtual void video_start();
4444   virtual void palette_init();
4545   UINT32 screen_update_jailbrek(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(jb_interrupt);
47   INTERRUPT_GEN_MEMBER(jb_interrupt_nmi);
4648};
4749
trunk/src/mame/includes/wecleman.h
r17996r17997
7878   DECLARE_VIDEO_START(hotchase);
7979   UINT32 screen_update_wecleman(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
8080   UINT32 screen_update_hotchase(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
81   INTERRUPT_GEN_MEMBER(hotchase_sound_timer);
8182};
8283
8384/*----------- defined in video/wecleman.c -----------*/
trunk/src/mame/includes/tankbust.h
r17996r17997
4343   virtual void video_start();
4444   virtual void palette_init();
4545   UINT32 screen_update_tankbust(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(vblank_irq);
4647};
trunk/src/mame/includes/bankp.h
r17996r17997
3939   virtual void video_start();
4040   virtual void palette_init();
4141   UINT32 screen_update_bankp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(vblank_irq);
4243};
trunk/src/mame/includes/crbaloon.h
r17996r17997
3737   virtual void video_start();
3838   virtual void palette_init();
3939   UINT32 screen_update_crbaloon(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
40   INTERRUPT_GEN_MEMBER(vblank_irq);
4041};
4142
4243
trunk/src/mame/includes/munchmo.h
r17996r17997
4747   virtual void video_start();
4848   virtual void palette_init();
4949   UINT32 screen_update_mnchmobl(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(mnchmobl_vblank_irq);
51   INTERRUPT_GEN_MEMBER(mnchmobl_sound_irq);
5052};
trunk/src/mame/includes/galastrm.h
r17996r17997
4848   DECLARE_CUSTOM_INPUT_MEMBER(coin_word_r);
4949   virtual void video_start();
5050   UINT32 screen_update_galastrm(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
51   INTERRUPT_GEN_MEMBER(galastrm_interrupt);
5152};
trunk/src/mame/includes/alpha68k.h
r17996r17997
104104   UINT32 screen_update_alpha68k_II(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
105105   UINT32 screen_update_alpha68k_V(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
106106   UINT32 screen_update_alpha68k_V_sb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
107   INTERRUPT_GEN_MEMBER(alpha68k_sound_nmi);
107108};
108109
109110/* game_id - used to deal with a few game specific situations */
trunk/src/mame/includes/freekick.h
r17996r17997
5151   UINT32 screen_update_pbillrd(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5252   UINT32 screen_update_freekick(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5353   UINT32 screen_update_gigas(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(freekick_irqgen);
5455};
trunk/src/mame/includes/namcos22.h
r17996r17997
256256   DECLARE_VIDEO_START(common);
257257   UINT32 screen_update_namcos22s(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
258258   UINT32 screen_update_namcos22(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
259   INTERRUPT_GEN_MEMBER(namcos22s_interrupt);
260   INTERRUPT_GEN_MEMBER(namcos22_interrupt);
259261};
260262
261263/*----------- defined in video/namcos22.c -----------*/
trunk/src/mame/includes/galaxold.h
r17996r17997
178178   DECLARE_VIDEO_START(dambustr);
179179   UINT32 screen_update_galaxold(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
180180   UINT32 screen_update_dambustr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
181   INTERRUPT_GEN_MEMBER(vblank_irq);
182   INTERRUPT_GEN_MEMBER(hunchbks_vh_interrupt);
181183};
182184
183185/*----------- defined in video/galaxold.c -----------*/
r17996r17997
193195
194196#define galaxold_coin_counter_0_w galaxold_coin_counter_w
195197
196INTERRUPT_GEN( hunchbks_vh_interrupt );
197
198198#endif
trunk/src/mame/includes/wgp.h
r17996r17997
6969   virtual void video_start();
7070   DECLARE_VIDEO_START(wgp2);
7171   UINT32 screen_update_wgp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
72   INTERRUPT_GEN_MEMBER(wgp_cpub_interrupt);
7273};
trunk/src/mame/includes/tceptor.h
r17996r17997
6464   UINT32 screen_update_tceptor_3d_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6565   UINT32 screen_update_tceptor_3d_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6666   void screen_eof_tceptor(screen_device &screen, bool state);
67   INTERRUPT_GEN_MEMBER(m6809_vb_interrupt);
68   INTERRUPT_GEN_MEMBER(m68k_vb_interrupt);
69   INTERRUPT_GEN_MEMBER(mcu_vb_interrupt);
6770};
trunk/src/mame/includes/metro.h
r17996r17997
162162   DECLARE_VIDEO_START(blzntrnd);
163163   DECLARE_VIDEO_START(gstrik2);
164164   UINT32 screen_update_metro(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
165   INTERRUPT_GEN_MEMBER(metro_vblank_interrupt);
166   INTERRUPT_GEN_MEMBER(metro_periodic_interrupt);
167   INTERRUPT_GEN_MEMBER(karatour_interrupt);
168   INTERRUPT_GEN_MEMBER(puzzlet_interrupt);
165169};
166170
167171
trunk/src/mame/includes/circusc.h
r17996r17997
5858   virtual void video_start();
5959   virtual void palette_init();
6060   UINT32 screen_update_circusc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
61   INTERRUPT_GEN_MEMBER(vblank_irq);
6162};
trunk/src/mame/includes/mikie.h
r17996r17997
4444   virtual void video_start();
4545   virtual void palette_init();
4646   UINT32 screen_update_mikie(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
47   INTERRUPT_GEN_MEMBER(vblank_irq);
4748};
trunk/src/mame/includes/namcond1.h
r17996r17997
2727   DECLARE_WRITE16_MEMBER(namcond1_cuskey_w);
2828   virtual void machine_start();
2929   virtual void machine_reset();
30   INTERRUPT_GEN_MEMBER(mcu_interrupt);
3031};
trunk/src/mame/includes/surpratk.h
r17996r17997
3535   virtual void machine_start();
3636   virtual void machine_reset();
3737   UINT32 screen_update_surpratk(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
38   INTERRUPT_GEN_MEMBER(surpratk_interrupt);
3839};
3940
4041/*----------- defined in video/surpratk.c -----------*/
trunk/src/mame/includes/zaccaria.h
r17996r17997
4545   virtual void video_start();
4646   virtual void palette_init();
4747   UINT32 screen_update_zaccaria(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   INTERRUPT_GEN_MEMBER(zaccaria_cb1_toggle);
49   INTERRUPT_GEN_MEMBER(vblank_irq);
4850};
trunk/src/mame/includes/tagteam.h
r17996r17997
2828   virtual void video_start();
2929   virtual void palette_init();
3030   UINT32 screen_update_tagteam(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
31   INTERRUPT_GEN_MEMBER(sound_timer_irq);
3132};
trunk/src/mame/includes/bagman.h
r17996r17997
4848   DECLARE_VIDEO_START(bagman);
4949   DECLARE_PALETTE_INIT(bagman);
5050   UINT32 screen_update_bagman(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
51   INTERRUPT_GEN_MEMBER(vblank_irq);
5152};
5253
5354/*----------- timings -----------*/
trunk/src/mame/includes/commando.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void video_start();
4949   UINT32 screen_update_commando(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(commando_interrupt);
5051};
trunk/src/mame/includes/atarisy2.h
r17996r17997
7979   DECLARE_MACHINE_RESET(atarisy2);
8080   DECLARE_VIDEO_START(atarisy2);
8181   UINT32 screen_update_atarisy2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
82   INTERRUPT_GEN_MEMBER(vblank_int);
8283};
8384
8485
trunk/src/mame/includes/ninjakd2.h
r17996r17997
7676   UINT32 screen_update_robokid(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7777   UINT32 screen_update_omegaf(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7878   void screen_eof_ninjakd2(screen_device &screen, bool state);
79   INTERRUPT_GEN_MEMBER(ninjakd2_interrupt);
7980};
trunk/src/mame/includes/skydiver.h
r17996r17997
5151   virtual void video_start();
5252   virtual void palette_init();
5353   UINT32 screen_update_skydiver(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(skydiver_interrupt);
5455};
5556
5657/*----------- defined in audio/skydiver.c -----------*/
trunk/src/mame/includes/warpwarp.h
r17996r17997
4747   DECLARE_VIDEO_START(navarone);
4848   DECLARE_PALETTE_INIT(navarone);
4949   UINT32 screen_update_geebee(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(vblank_irq);
5051};
5152
5253
trunk/src/mame/includes/kncljoe.h
r17996r17997
4646   virtual void video_start();
4747   virtual void palette_init();
4848   UINT32 screen_update_kncljoe(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(sound_nmi);
4950};
trunk/src/mame/includes/liberate.h
r17996r17997
6767   UINT32 screen_update_prosport(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6868   UINT32 screen_update_boomrang(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6969   UINT32 screen_update_prosoccr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
70   INTERRUPT_GEN_MEMBER(deco16_interrupt);
71   INTERRUPT_GEN_MEMBER(prosport_interrupt);
7072};
trunk/src/mame/includes/cvs.h
r17996r17997
105105   DECLARE_VIDEO_START(cvs);
106106   DECLARE_PALETTE_INIT(cvs);
107107   UINT32 screen_update_cvs(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
108   INTERRUPT_GEN_MEMBER(cvs_main_cpu_interrupt);
108109};
109110
110111/*----------- defined in video/cvs.c -----------*/
trunk/src/mame/includes/truco.h
r17996r17997
1717   virtual void machine_reset();
1818   virtual void palette_init();
1919   UINT32 screen_update_truco(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
20   INTERRUPT_GEN_MEMBER(truco_interrupt);
2021};
trunk/src/mame/includes/seta.h
r17996r17997
198198   UINT32 screen_update_seta_layers(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
199199   void screen_eof_seta_buffer_sprites(screen_device &screen, bool state);
200200   void screen_eof_setaroul(screen_device &screen, bool state);
201   INTERRUPT_GEN_MEMBER(wrofaero_interrupt);
201202};
202203
203204/*----------- defined in video/seta.c -----------*/
trunk/src/mame/includes/laserbat.h
r17996r17997
8282   virtual void machine_reset();
8383   virtual void video_start();
8484   UINT32 screen_update_laserbat(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
85   INTERRUPT_GEN_MEMBER(laserbat_interrupt);
86   INTERRUPT_GEN_MEMBER(zaccaria_cb1_toggle);
8587};
trunk/src/mame/includes/tnzs.h
r17996r17997
9898   DECLARE_MACHINE_RESET(jpopnics);
9999   UINT32 screen_update_tnzs(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
100100   void screen_eof_tnzs(screen_device &screen, bool state);
101   INTERRUPT_GEN_MEMBER(arknoid2_interrupt);
101102};
102
103
104/*----------- defined in machine/tnzs.c -----------*/
105INTERRUPT_GEN( arknoid2_interrupt );
trunk/src/mame/includes/tp84.h
r17996r17997
4141   virtual void video_start();
4242   virtual void palette_init();
4343   UINT32 screen_update_tp84(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(sub_vblank_irq);
4445};
trunk/src/mame/includes/plygonet.h
r17996r17997
7373   virtual void machine_start();
7474   virtual void video_start();
7575   UINT32 screen_update_polygonet(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
76   INTERRUPT_GEN_MEMBER(polygonet_interrupt);
77   INTERRUPT_GEN_MEMBER(audio_interrupt);
7678};
trunk/src/mame/includes/nemesis.h
r17996r17997
8585   virtual void machine_reset();
8686   virtual void video_start();
8787   UINT32 screen_update_nemesis(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
88   INTERRUPT_GEN_MEMBER(nemesis_interrupt);
89   INTERRUPT_GEN_MEMBER(blkpnthr_interrupt);
8890};
trunk/src/mame/includes/cheekyms.h
r17996r17997
3636   virtual void video_start();
3737   virtual void palette_init();
3838   UINT32 screen_update_cheekyms(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(vblank_irq);
3940};
trunk/src/mame/includes/asteroid.h
r17996r17997
2929   DECLARE_DRIVER_INIT(asterock);
3030   DECLARE_DRIVER_INIT(asteroidb);
3131   virtual void machine_reset();
32   INTERRUPT_GEN_MEMBER(asteroid_interrupt);
33   INTERRUPT_GEN_MEMBER(asterock_interrupt);
34   INTERRUPT_GEN_MEMBER(llander_interrupt);
3235};
3336
34
35/*----------- defined in machine/asteroid.c -----------*/
36
37INTERRUPT_GEN( asteroid_interrupt );
38INTERRUPT_GEN( asterock_interrupt );
39INTERRUPT_GEN( llander_interrupt );
40
41
4237/*----------- defined in audio/asteroid.c -----------*/
4338
4439DISCRETE_SOUND_EXTERN( asteroid );
trunk/src/mame/includes/timelimt.h
r17996r17997
2929   virtual void video_start();
3030   virtual void palette_init();
3131   UINT32 screen_update_timelimt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(timelimt_irq);
3233};
trunk/src/mame/includes/raiden.h
r17996r17997
4040   virtual void video_start();
4141   DECLARE_VIDEO_START(raidena);
4242   UINT32 screen_update_raiden(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(raiden_interrupt);
4344};
trunk/src/mame/includes/galaxia.h
r17996r17997
2828   DECLARE_PALETTE_INIT(astrowar);
2929   UINT32 screen_update_galaxia(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
3030   UINT32 screen_update_astrowar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
31   INTERRUPT_GEN_MEMBER(galaxia_interrupt);
3132};
trunk/src/mame/includes/fromanc2.h
r17996r17997
105105   DECLARE_VIDEO_START(fromanc4);
106106   UINT32 screen_update_fromanc2_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
107107   UINT32 screen_update_fromanc2_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
108   INTERRUPT_GEN_MEMBER(fromanc2_interrupt);
108109};
109110
110111/*----------- defined in video/fromanc2.c -----------*/
trunk/src/mame/includes/bombjack.h
r17996r17997
4040   virtual void machine_reset();
4141   virtual void video_start();
4242   UINT32 screen_update_bombjack(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(vblank_irq);
4344};
trunk/src/mame/includes/rallyx.h
r17996r17997
6464   UINT32 screen_update_rallyx(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6565   UINT32 screen_update_jungler(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6666   UINT32 screen_update_locomotn(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
67   INTERRUPT_GEN_MEMBER(rallyx_vblank_irq);
68   INTERRUPT_GEN_MEMBER(jungler_vblank_irq);
6769};
trunk/src/mame/includes/trucocl.h
r17996r17997
2222   virtual void video_start();
2323   virtual void palette_init();
2424   UINT32 screen_update_trucocl(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
25   INTERRUPT_GEN_MEMBER(trucocl_interrupt);
2526};
trunk/src/mame/includes/blockhl.h
r17996r17997
3737   virtual void machine_reset();
3838   virtual void video_start();
3939   UINT32 screen_update_blockhl(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
40   INTERRUPT_GEN_MEMBER(blockhl_interrupt);
4041};
4142
4243/*----------- defined in video/blockhl.c -----------*/
trunk/src/mame/includes/gcpinbal.h
r17996r17997
5959   virtual void machine_reset();
6060   virtual void video_start();
6161   UINT32 screen_update_gcpinbal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(gcpinbal_interrupt);
6263};
trunk/src/mame/includes/realbrk.h
r17996r17997
4646   virtual void video_start();
4747   UINT32 screen_update_realbrk(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4848   UINT32 screen_update_dai2kaku(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(realbrk_interrupt);
4950};
trunk/src/mame/includes/carjmbre.h
r17996r17997
3232   virtual void video_start();
3333   virtual void palette_init();
3434   UINT32 screen_update_carjmbre(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
35   INTERRUPT_GEN_MEMBER(vblank_irq);
3536};
trunk/src/mame/includes/bottom9.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void video_start();
4949   UINT32 screen_update_bottom9(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(bottom9_interrupt);
51   INTERRUPT_GEN_MEMBER(bottom9_sound_interrupt);
5052};
5153
5254/*----------- defined in video/bottom9.c -----------*/
trunk/src/mame/includes/mainevt.h
r17996r17997
4545   DECLARE_VIDEO_START(dv);
4646   UINT32 screen_update_mainevt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4747   UINT32 screen_update_dv(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   INTERRUPT_GEN_MEMBER(mainevt_interrupt);
49   INTERRUPT_GEN_MEMBER(dv_interrupt);
50   INTERRUPT_GEN_MEMBER(mainevt_sound_timer_irq);
51   INTERRUPT_GEN_MEMBER(devstors_sound_timer_irq);
4852};
4953
5054/*----------- defined in video/mainevt.c -----------*/
trunk/src/mame/includes/megazone.h
r17996r17997
5252   virtual void video_start();
5353   virtual void palette_init();
5454   UINT32 screen_update_megazone(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(vblank_irq);
5556};
trunk/src/mame/includes/galaga.h
r17996r17997
5858   DECLARE_PALETTE_INIT(galaga);
5959   UINT32 screen_update_galaga(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6060   void screen_eof_galaga(screen_device &screen, bool state);
61   INTERRUPT_GEN_MEMBER(main_vblank_irq);
62   INTERRUPT_GEN_MEMBER(sub_vblank_irq);
6163};
6264
6365class xevious_state : public galaga_state
r17996r17997
9395   DECLARE_PALETTE_INIT(battles);
9496   DECLARE_MACHINE_RESET(battles);
9597   UINT32 screen_update_xevious(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
98   INTERRUPT_GEN_MEMBER(battles_interrupt_4);
9699};
97100
98101
r17996r17997
203206DECLARE_WRITE8_HANDLER( battles_CPU4_coin_w );
204207DECLARE_WRITE8_HANDLER( battles_noise_sound_w );
205208
206INTERRUPT_GEN( battles_interrupt_4 );
207
208209/*----------- defined in video/digdug.c -----------*/
209210
210211DECLARE_WRITE8_HANDLER( digdug_videoram_w );
trunk/src/mame/includes/8080bw.h
r17996r17997
8585   UINT32 screen_update_polaris(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
8686   UINT32 screen_update_ballbomb(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
8787   UINT32 screen_update_shuttlei(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
88   INTERRUPT_GEN_MEMBER(polaris_interrupt);
8889};
8990
9091
trunk/src/mame/includes/othunder.h
r17996r17997
6363   virtual void machine_reset();
6464   virtual void video_start();
6565   UINT32 screen_update_othunder(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
66   INTERRUPT_GEN_MEMBER(vblank_interrupt);
6667};
trunk/src/mame/includes/quasar.h
r17996r17997
2929   DECLARE_VIDEO_START(quasar);
3030   DECLARE_PALETTE_INIT(quasar);
3131   UINT32 screen_update_quasar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(quasar_interrupt);
3233};
trunk/src/mame/includes/slapshot.h
r17996r17997
6666   virtual void video_start();
6767   UINT32 screen_update_slapshot(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6868   void screen_eof_taito_no_buffer(screen_device &screen, bool state);
69   INTERRUPT_GEN_MEMBER(slapshot_interrupt);
6970};
7071
trunk/src/mame/includes/victory.h
r17996r17997
6262   DECLARE_WRITE8_MEMBER(victory_video_control_w);
6363   virtual void video_start();
6464   UINT32 screen_update_victory(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
65   INTERRUPT_GEN_MEMBER(victory_vblank_interrupt);
6566};
66
67
68/*----------- defined in video/victory.c -----------*/
69INTERRUPT_GEN( victory_vblank_interrupt );
trunk/src/mame/includes/psikyo4.h
r17996r17997
5252   virtual void video_start();
5353   UINT32 screen_update_psikyo4_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5454   UINT32 screen_update_psikyo4_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(psikyosh_interrupt);
5556};
trunk/src/mame/includes/lucky74.h
r17996r17997
4040   virtual void video_start();
4141   virtual void palette_init();
4242   UINT32 screen_update_lucky74(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(nmi_interrupt);
4344};
trunk/src/mame/includes/pacland.h
r17996r17997
3838   virtual void video_start();
3939   virtual void palette_init();
4040   UINT32 screen_update_pacland(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
41   INTERRUPT_GEN_MEMBER(main_vblank_irq);
42   INTERRUPT_GEN_MEMBER(mcu_vblank_irq);
4143};
trunk/src/mame/includes/rollrace.h
r17996r17997
3535   DECLARE_WRITE8_MEMBER(rollrace_flipx_w);
3636   virtual void palette_init();
3737   UINT32 screen_update_rollrace(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
38   INTERRUPT_GEN_MEMBER(vblank_irq);
39   INTERRUPT_GEN_MEMBER(sound_timer_irq);
3840};
trunk/src/mame/includes/popper.h
r17996r17997
5555   virtual void video_start();
5656   virtual void palette_init();
5757   UINT32 screen_update_popper(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
58   INTERRUPT_GEN_MEMBER(vblank_irq);
5859};
trunk/src/mame/includes/jack.h
r17996r17997
5757   DECLARE_PALETTE_INIT(joinem);
5858   UINT32 screen_update_jack(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5959   UINT32 screen_update_joinem(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
60   INTERRUPT_GEN_MEMBER(joinem_vblank_irq);
6061};
trunk/src/mame/includes/kingobox.h
r17996r17997
5858   DECLARE_PALETTE_INIT(ringking);
5959   UINT32 screen_update_kingofb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6060   UINT32 screen_update_ringking(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
61   INTERRUPT_GEN_MEMBER(kingofb_interrupt);
6162};
trunk/src/mame/includes/esripsys.h
r17996r17997
9393   DECLARE_DRIVER_INIT(esripsys);
9494   virtual void video_start();
9595   UINT32 screen_update_esripsys(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
96   INTERRUPT_GEN_MEMBER(esripsys_vblank_irq);
9697};
9798
9899
99100/*----------- defined in video/esripsys.c -----------*/
100INTERRUPT_GEN( esripsys_vblank_irq );
101101int esripsys_draw(running_machine &machine, int l, int r, int fig, int attr, int addr, int col, int x_scale, int bank);
trunk/src/mame/includes/tsamurai.h
r17996r17997
5959   DECLARE_VIDEO_START(vsgongf);
6060   UINT32 screen_update_tsamurai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6161   UINT32 screen_update_vsgongf(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(samurai_interrupt);
63   INTERRUPT_GEN_MEMBER(vsgongf_sound_interrupt);
6264};
trunk/src/mame/includes/splash.h
r17996r17997
6464   DECLARE_MACHINE_RESET(funystrp);
6565   UINT32 screen_update_splash(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6666   UINT32 screen_update_funystrp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
67   INTERRUPT_GEN_MEMBER(roldfrog_interrupt);
6768};
trunk/src/mame/includes/namcos2.h
r17996r17997
178178   // general
179179   void zdrawgfxzoom(bitmap_ind16 &dest_bmp, const rectangle &clip, gfx_element *gfx, UINT32 code, UINT32 color, int flipx, int flipy, int sx, int sy, int scalex, int scaley, int zpos);
180180   void zdrawgfxzoom(bitmap_rgb32 &dest_bmp, const rectangle &clip, gfx_element *gfx, UINT32 code, UINT32 color, int flipx, int flipy, int sx, int sy, int scalex, int scaley, int zpos);
181   INTERRUPT_GEN_MEMBER(namcos2_68k_master_vblank);
182   INTERRUPT_GEN_MEMBER(namcos2_68k_slave_vblank);
183   INTERRUPT_GEN_MEMBER(namcos2_68k_gpu_vblank);
181184};
182185
183186class namcos2_state : public namcos2_shared_state
r17996r17997
333336
334337DECLARE_WRITE16_HANDLER( namcos2_68k_master_C148_w );
335338DECLARE_READ16_HANDLER( namcos2_68k_master_C148_r );
336INTERRUPT_GEN( namcos2_68k_master_vblank );
337339
338340DECLARE_WRITE16_HANDLER( namcos2_68k_slave_C148_w );
339341DECLARE_READ16_HANDLER( namcos2_68k_slave_C148_r );
340INTERRUPT_GEN( namcos2_68k_slave_vblank );
341342
342343DECLARE_WRITE16_HANDLER( namcos2_68k_gpu_C148_w );
343344DECLARE_READ16_HANDLER( namcos2_68k_gpu_C148_r );
344INTERRUPT_GEN( namcos2_68k_gpu_vblank );
345345
346346void namcos2_adjust_posirq_timer( running_machine &machine, int scanline );
347347
trunk/src/mame/includes/snk6502.h
r17996r17997
6161   DECLARE_MACHINE_RESET(pballoon);
6262   DECLARE_VIDEO_START(pballoon);
6363   UINT32 screen_update_snk6502(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
64   INTERRUPT_GEN_MEMBER(satansat_interrupt);
65   INTERRUPT_GEN_MEMBER(snk6502_interrupt);
6466};
6567
6668
trunk/src/mame/includes/polyplay.h
r17996r17997
3333   virtual void video_start();
3434   virtual void palette_init();
3535   UINT32 screen_update_polyplay(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
36   INTERRUPT_GEN_MEMBER(periodic_interrupt);
37   INTERRUPT_GEN_MEMBER(coin_interrupt);
3638};
3739
3840
trunk/src/mame/includes/exidy440.h
r17996r17997
6969   DECLARE_VIDEO_START(topsecex);
7070   UINT32 screen_update_exidy440(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7171   UINT32 screen_update_topsecex(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
72   INTERRUPT_GEN_MEMBER(exidy440_vblank_interrupt);
7273};
7374
7475
r17996r17997
7879
7980/*----------- defined in video/exidy440.c -----------*/
8081
81INTERRUPT_GEN( exidy440_vblank_interrupt );
82
8382MACHINE_CONFIG_EXTERN( exidy440_video );
8483MACHINE_CONFIG_EXTERN( topsecex_video );
trunk/src/mame/includes/tx1.h
r17996r17997
177177   UINT32 screen_update_buggybjr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
178178   void screen_eof_tx1(screen_device &screen, bool state);
179179   void screen_eof_buggyboy(screen_device &screen, bool state);
180   INTERRUPT_GEN_MEMBER(z80_irq);
180181};
181182
182183/*----------- defined in audio/tx1.c -----------*/
trunk/src/mame/includes/aztarac.h
r17996r17997
2727   DECLARE_WRITE8_MEMBER(aztarac_snd_status_w);
2828   virtual void machine_reset();
2929   virtual void video_start();
30   INTERRUPT_GEN_MEMBER(aztarac_snd_timed_irq);
3031};
31
32/*----------- defined in audio/aztarac.c -----------*/
33INTERRUPT_GEN( aztarac_snd_timed_irq );
trunk/src/mame/includes/tatsumi.h
r17996r17997
124124   UINT32 screen_update_roundup5(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
125125   UINT32 screen_update_cyclwarr(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
126126   UINT32 screen_update_bigfight(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
127   INTERRUPT_GEN_MEMBER(roundup5_interrupt);
127128};
128129
129130/*----------- defined in machine/tatsumi.c -----------*/
trunk/src/mame/includes/retofinv.h
r17996r17997
6262   virtual void video_start();
6363   virtual void palette_init();
6464   UINT32 screen_update_retofinv(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
65   INTERRUPT_GEN_MEMBER(main_vblank_irq);
66   INTERRUPT_GEN_MEMBER(sub_vblank_irq);
6567};
trunk/src/mame/includes/gbusters.h
r17996r17997
4141   virtual void machine_reset();
4242   virtual void video_start();
4343   UINT32 screen_update_gbusters(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(gbusters_interrupt);
4445};
4546
4647/*----------- defined in video/gbusters.c -----------*/
trunk/src/mame/includes/meadows.h
r17996r17997
4646   virtual void video_start();
4747   virtual void palette_init();
4848   UINT32 screen_update_meadows(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(meadows_interrupt);
50   INTERRUPT_GEN_MEMBER(minferno_interrupt);
51   INTERRUPT_GEN_MEMBER(audio_interrupt);
4952};
5053
5154
trunk/src/mame/includes/harddriv.h
r17996r17997
217217   DECLARE_MACHINE_START(harddriv);
218218   DECLARE_MACHINE_RESET(harddriv);
219219   DECLARE_VIDEO_START(harddriv);
220   INTERRUPT_GEN_MEMBER(hd68k_irq_gen);
220221};
221222
222223
r17996r17997
224225
225226/* Driver/Multisync board */
226227
227
228
229INTERRUPT_GEN( hd68k_irq_gen );
230228DECLARE_WRITE16_HANDLER( hd68k_irq_ack_w );
231229void hdgsp_irq_gen(device_t *device, int state);
232230void hdmsp_irq_gen(device_t *device, int state);
trunk/src/mame/includes/m72.h
r17996r17997
117117   DECLARE_MACHINE_RESET(kengo);
118118   UINT32 screen_update_m72(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
119119   UINT32 screen_update_majtitle(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
120   INTERRUPT_GEN_MEMBER(m72_mcu_int);
121   INTERRUPT_GEN_MEMBER(fake_nmi);
120122};
trunk/src/mame/includes/aeroboto.h
r17996r17997
5959   virtual void machine_reset();
6060   virtual void video_start();
6161   UINT32 screen_update_aeroboto(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(aeroboto_interrupt);
6263};
trunk/src/mame/includes/firetrap.h
r17996r17997
7171   virtual void video_start();
7272   virtual void palette_init();
7373   UINT32 screen_update_firetrap(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
74   INTERRUPT_GEN_MEMBER(firetrap_irq);
7475};
trunk/src/mame/includes/thedeep.h
r17996r17997
5050   virtual void video_start();
5151   virtual void palette_init();
5252   UINT32 screen_update_thedeep(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
53   INTERRUPT_GEN_MEMBER(thedeep_mcu_irq);
5354};
trunk/src/mame/includes/topspeed.h
r17996r17997
5555   virtual void machine_start();
5656   virtual void machine_reset();
5757   UINT32 screen_update_topspeed(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
58   INTERRUPT_GEN_MEMBER(topspeed_interrupt);
59   INTERRUPT_GEN_MEMBER(topspeed_cpub_interrupt);
5860};
trunk/src/mame/includes/fantland.h
r17996r17997
4848   DECLARE_MACHINE_START(borntofi);
4949   DECLARE_MACHINE_RESET(borntofi);
5050   UINT32 screen_update_fantland(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
51   INTERRUPT_GEN_MEMBER(fantland_irq);
52   INTERRUPT_GEN_MEMBER(fantland_sound_irq);
5153};
trunk/src/mame/includes/mcr68.h
r17996r17997
9898   DECLARE_VIDEO_START(mcr68);
9999   UINT32 screen_update_zwackery(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
100100   UINT32 screen_update_mcr68(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
101   INTERRUPT_GEN_MEMBER(mcr68_interrupt);
101102};
102103
103104/*----------- defined in machine/mcr68.c -----------*/
r17996r17997
105106extern const pia6821_interface zwackery_pia0_intf;
106107extern const pia6821_interface zwackery_pia1_intf;
107108extern const pia6821_interface zwackery_pia2_intf;
108
109INTERRUPT_GEN( mcr68_interrupt );
trunk/src/mame/includes/pbaction.h
r17996r17997
5252   virtual void machine_reset();
5353   virtual void video_start();
5454   UINT32 screen_update_pbaction(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(pbaction_interrupt);
56   INTERRUPT_GEN_MEMBER(vblank_irq);
5557};
trunk/src/mame/includes/overdriv.h
r17996r17997
4343   virtual void machine_start();
4444   virtual void machine_reset();
4545   UINT32 screen_update_overdriv(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(cpuB_interrupt);
4647};
4748
4849/*----------- defined in video/overdriv.c -----------*/
trunk/src/mame/includes/thunderx.h
r17996r17997
5151   DECLARE_MACHINE_START(thunderx);
5252   DECLARE_MACHINE_RESET(thunderx);
5353   UINT32 screen_update_scontra(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(scontra_interrupt);
5455};
5556
5657
trunk/src/mame/includes/spcforce.h
r17996r17997
3434   DECLARE_WRITE8_MEMBER(spcforce_flip_screen_w);
3535   virtual void palette_init();
3636   UINT32 screen_update_spcforce(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
37   INTERRUPT_GEN_MEMBER(vblank_irq);
3738};
trunk/src/mame/includes/gsword.h
r17996r17997
4646   DECLARE_MACHINE_RESET(josvolly);
4747   DECLARE_PALETTE_INIT(josvolly);
4848   UINT32 screen_update_gsword(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(gsword_snd_interrupt);
4950};
trunk/src/mame/includes/mario.h
r17996r17997
8282   virtual void video_start();
8383   virtual void palette_init();
8484   UINT32 screen_update_mario(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
85   INTERRUPT_GEN_MEMBER(vblank_irq);
8586};
8687
8788/*----------- defined in audio/mario.c -----------*/
trunk/src/mame/includes/lethal.h
r17996r17997
4040   virtual void machine_reset();
4141   virtual void video_start();
4242   UINT32 screen_update_lethalen(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(lethalen_interrupt);
4344};
4445
4546/*----------- defined in video/lethal.c -----------*/
trunk/src/mame/includes/exprraid.h
r17996r17997
5454   virtual void machine_reset();
5555   virtual void video_start();
5656   UINT32 screen_update_exprraid(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(exprraid_interrupt);
5758};
trunk/src/mame/includes/toypop.h
r17996r17997
5050   virtual void video_start();
5151   virtual void palette_init();
5252   UINT32 screen_update_toypop(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
53   INTERRUPT_GEN_MEMBER(toypop_main_vblank_irq);
54   INTERRUPT_GEN_MEMBER(toypop_sound_timer_irq);
55   INTERRUPT_GEN_MEMBER(toypop_m68000_interrupt);
5356};
trunk/src/mame/includes/tumbleb.h
r17996r17997
101101   UINT32 screen_update_bcstory(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
102102   UINT32 screen_update_semibase(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
103103   UINT32 screen_update_sdfight(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
104   INTERRUPT_GEN_MEMBER(tumbleb2_interrupt);
104105};
trunk/src/mame/includes/micro3d.h
r17996r17997
114114   virtual void machine_reset();
115115   virtual void video_start();
116116   virtual void video_reset();
117   INTERRUPT_GEN_MEMBER(micro3d_vblank);
117118};
118119
119120struct micro3d_vtx
r17996r17997
162163/*----------- defined in video/micro3d.c -----------*/
163164void micro3d_tms_interrupt(device_t *device, int state);
164165void micro3d_scanline_update(screen_device &screen, bitmap_ind16 &bitmap, int scanline, const tms34010_display_params *params);
165
166INTERRUPT_GEN( micro3d_vblank );
trunk/src/mame/includes/kchamp.h
r17996r17997
5050   DECLARE_MACHINE_START(kchamp);
5151   UINT32 screen_update_kchampvs(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5252   UINT32 screen_update_kchamp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
53   INTERRUPT_GEN_MEMBER(kc_interrupt);
54   INTERRUPT_GEN_MEMBER(sound_int);
5355};
trunk/src/mame/includes/m90.h
r17996r17997
4343   UINT32 screen_update_m90(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4444   UINT32 screen_update_bomblord(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4545   UINT32 screen_update_dynablsb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(fake_nmi);
47   INTERRUPT_GEN_MEMBER(bomblord_fake_nmi);
48   INTERRUPT_GEN_MEMBER(m90_interrupt);
49   INTERRUPT_GEN_MEMBER(dynablsb_interrupt);
50   INTERRUPT_GEN_MEMBER(bomblord_interrupt);
4651};
trunk/src/mame/includes/taito_z.h
r17996r17997
8585   UINT32 screen_update_spacegun(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8686   UINT32 screen_update_dblaxle(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8787   UINT32 screen_update_racingb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
88   INTERRUPT_GEN_MEMBER(sci_interrupt);
8889};
trunk/src/mame/includes/scotrsht.h
r17996r17997
2626   virtual void video_start();
2727   virtual void palette_init();
2828   UINT32 screen_update_scotrsht(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
29   INTERRUPT_GEN_MEMBER(scotrsht_interrupt);
2930};
trunk/src/mame/includes/gunbustr.h
r17996r17997
4040   DECLARE_DRIVER_INIT(gunbustr);
4141   virtual void video_start();
4242   UINT32 screen_update_gunbustr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(gunbustr_interrupt);
4344};
trunk/src/mame/includes/superqix.h
r17996r17997
7878   DECLARE_VIDEO_START(superqix);
7979   UINT32 screen_update_pbillian(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8080   UINT32 screen_update_superqix(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
81   INTERRUPT_GEN_MEMBER(vblank_irq);
82   INTERRUPT_GEN_MEMBER(sqix_timer_irq);
8183};
trunk/src/mame/includes/playch10.h
r17996r17997
117117   UINT32 screen_update_playch10_top(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
118118   UINT32 screen_update_playch10_bottom(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
119119   UINT32 screen_update_playch10_single(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
120   INTERRUPT_GEN_MEMBER(playch10_interrupt);
120121};
121122
122123/*----------- defined in video/playch10.c -----------*/
trunk/src/mame/includes/cyberbal.h
r17996r17997
5656   UINT32 screen_update_cyberbal_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5757   UINT32 screen_update_cyberbal_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5858   UINT32 screen_update_cyberbal2p(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
59   INTERRUPT_GEN_MEMBER(cyberbal_sound_68k_irq_gen);
5960};
6061
6162/*----------- defined in audio/cyberbal.c -----------*/
6263
6364void cyberbal_sound_reset(running_machine &machine);
64INTERRUPT_GEN( cyberbal_sound_68k_irq_gen );
6565
6666/*----------- defined in video/cyberbal.c -----------*/
6767
trunk/src/mame/includes/mappy.h
r17996r17997
5252   UINT32 screen_update_superpac(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5353   UINT32 screen_update_phozon(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5454   UINT32 screen_update_mappy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(superpac_main_vblank_irq);
56   INTERRUPT_GEN_MEMBER(pacnpal_main_vblank_irq);
57   INTERRUPT_GEN_MEMBER(phozon_main_vblank_irq);
58   INTERRUPT_GEN_MEMBER(mappy_main_vblank_irq);
59   INTERRUPT_GEN_MEMBER(sub_vblank_irq);
60   INTERRUPT_GEN_MEMBER(sub2_vblank_irq);
5561};
trunk/src/mame/includes/gijoe.h
r17996r17997
4545   virtual void machine_reset();
4646   virtual void video_start();
4747   UINT32 screen_update_gijoe(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
48   INTERRUPT_GEN_MEMBER(gijoe_interrupt);
4849};
4950
5051/*----------- defined in video/gijoe.c -----------*/
trunk/src/mame/includes/rltennis.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void video_start();
4949   UINT32 screen_update_rltennis(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(rltennis_interrupt);
5051};
trunk/src/mame/includes/segas32.h
r17996r17997
177177   UINT32 screen_update_system32(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
178178   UINT32 screen_update_multi32_left(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
179179   UINT32 screen_update_multi32_right(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
180   INTERRUPT_GEN_MEMBER(start_of_vblank_int);
180181};
181182
182183/*----------- defined in machine/segas32.c -----------*/
trunk/src/mame/includes/slapfght.h
r17996r17997
125125   DECLARE_VIDEO_START(slapfight);
126126   UINT32 screen_update_perfrman(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
127127   UINT32 screen_update_slapfight(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
128   INTERRUPT_GEN_MEMBER(vblank_irq);
129   INTERRUPT_GEN_MEMBER(getstar_interrupt);
128130};
129131
130132
r17996r17997
141143                      m_gs_d = 0; \
142144                      m_gs_e = 0;
143145
144
145/*----------- defined in machine/slapfght.c -----------*/
146INTERRUPT_GEN( getstar_interrupt );
trunk/src/mame/includes/badlands.h
r17996r17997
3131   DECLARE_VIDEO_START(badlands);
3232   DECLARE_MACHINE_RESET(badlandsb);
3333   UINT32 screen_update_badlands(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
34   INTERRUPT_GEN_MEMBER(vblank_int);
3435};
3536
3637/*----------- defined in video/badlands.c -----------*/
trunk/src/mame/includes/psikyosh.h
r17996r17997
6666   virtual void machine_start();
6767   virtual void video_start();
6868   UINT32 screen_update_psikyosh(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
69   INTERRUPT_GEN_MEMBER(psikyosh_interrupt);
6970};
trunk/src/mame/includes/gradius3.h
r17996r17997
4949   virtual void machine_reset();
5050   virtual void video_start();
5151   UINT32 screen_update_gradius3(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
52   INTERRUPT_GEN_MEMBER(cpuA_interrupt);
5253};
5354
5455/*----------- defined in video/gradius3.c -----------*/
trunk/src/mame/includes/mystwarr.h
r17996r17997
7171   UINT32 screen_update_metamrph(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
7272   UINT32 screen_update_dadandrn(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
7373   UINT32 screen_update_martchmp(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
74   INTERRUPT_GEN_MEMBER(ddd_interrupt);
7475};
trunk/src/mame/includes/skykid.h
r17996r17997
4141   virtual void video_start();
4242   virtual void palette_init();
4343   UINT32 screen_update_skykid(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
44   INTERRUPT_GEN_MEMBER(main_vblank_irq);
45   INTERRUPT_GEN_MEMBER(mcu_vblank_irq);
4446};
trunk/src/mame/includes/djmain.h
r17996r17997
5454   virtual void machine_reset();
5555   virtual void video_start();
5656   UINT32 screen_update_djmain(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(vb_interrupt);
5758};
5859
5960/*----------- defined in video/djmain.c -----------*/
trunk/src/mame/includes/firetrk.h
r17996r17997
104104   UINT32 screen_update_firetrk(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
105105   UINT32 screen_update_superbug(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
106106   UINT32 screen_update_montecar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
107   INTERRUPT_GEN_MEMBER(firetrk_interrupt);
107108};
108109
109110
trunk/src/mame/includes/mustache.h
r17996r17997
2020   virtual void video_start();
2121   virtual void palette_init();
2222   UINT32 screen_update_mustache(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
23   INTERRUPT_GEN_MEMBER(assert_irq);
2324};
trunk/src/mame/includes/konamigx.h
r17996r17997
7878   UINT32 screen_update_konamigx(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
7979   UINT32 screen_update_konamigx_left(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
8080   UINT32 screen_update_konamigx_right(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
81   INTERRUPT_GEN_MEMBER(konamigx_vbinterrupt);
82   INTERRUPT_GEN_MEMBER(tms_sync);
8183};
8284
8385
trunk/src/mame/includes/sprcros2.h
r17996r17997
3131   virtual void video_start();
3232   virtual void palette_init();
3333   UINT32 screen_update_sprcros2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
34   INTERRUPT_GEN_MEMBER(sprcros2_s_interrupt);
3435};
trunk/src/mame/includes/parodius.h
r17996r17997
4343   virtual void machine_start();
4444   virtual void machine_reset();
4545   UINT32 screen_update_parodius(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(parodius_interrupt);
4647};
4748
4849/*----------- defined in video/parodius.c -----------*/
trunk/src/mame/includes/rockrage.h
r17996r17997
3131   virtual void machine_reset();
3232   virtual void palette_init();
3333   UINT32 screen_update_rockrage(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
34   INTERRUPT_GEN_MEMBER(rockrage_interrupt);
3435};
3536
3637/*----------- defined in video/rockrage.c -----------*/
trunk/src/mame/includes/starshp1.h
r17996r17997
8080   virtual void palette_init();
8181   UINT32 screen_update_starshp1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8282   void screen_eof_starshp1(screen_device &screen, bool state);
83   INTERRUPT_GEN_MEMBER(starshp1_interrupt);
8384};
8485
8586/*----------- defined in audio/starshp1.c -----------*/
trunk/src/mame/includes/taito_f2.h
r17996r17997
142142   void screen_eof_taitof2_partial_buffer_delayed_thundfox(screen_device &screen, bool state);
143143   void screen_eof_taitof2_full_buffer_delayed(screen_device &screen, bool state);
144144   void screen_eof_taitof2_partial_buffer_delayed_qzchikyu(screen_device &screen, bool state);
145   INTERRUPT_GEN_MEMBER(taitof2_interrupt);
145146};
trunk/src/mame/includes/pandoras.h
r17996r17997
5151   virtual void video_start();
5252   virtual void palette_init();
5353   UINT32 screen_update_pandoras(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(pandoras_master_interrupt);
55   INTERRUPT_GEN_MEMBER(pandoras_slave_interrupt);
5456};
trunk/src/mame/includes/stfight.h
r17996r17997
4646   virtual void video_start();
4747   virtual void palette_init();
4848   UINT32 screen_update_stfight(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(stfight_vb_interrupt);
4950};
5051
5152/*----------- defined in machine/stfight.c -----------*/
52INTERRUPT_GEN( stfight_vb_interrupt );
5353void stfight_adpcm_int(device_t *device);
5454DECLARE_WRITE8_DEVICE_HANDLER( stfight_adpcm_control_w );
5555
trunk/src/mame/includes/gottlieb.h
r17996r17997
302302   virtual void video_start();
303303   DECLARE_VIDEO_START(screwloo);
304304   UINT32 screen_update_gottlieb(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
305   INTERRUPT_GEN_MEMBER(gottlieb_interrupt);
305306};
306307
307308/*----------- defined in video/gottlieb.c -----------*/
trunk/src/mame/includes/asterix.h
r17996r17997
4343   virtual void machine_start();
4444   virtual void machine_reset();
4545   UINT32 screen_update_asterix(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(asterix_interrupt);
4647};
4748
4849/*----------- defined in video/asterix.c -----------*/
trunk/src/mame/includes/homedata.h
r17996r17997
125125   UINT32 screen_update_pteacher(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
126126   UINT32 screen_update_mirderby(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
127127   void screen_eof_homedata(screen_device &screen, bool state);
128   INTERRUPT_GEN_MEMBER(homedata_irq);
129   INTERRUPT_GEN_MEMBER(upd7807_irq);
128130};
trunk/src/mame/includes/exidy.h
r17996r17997
6868   virtual void video_start();
6969   DECLARE_MACHINE_START(teetert);
7070   UINT32 screen_update_exidy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
71   INTERRUPT_GEN_MEMBER(exidy_vblank_interrupt);
7172};
7273
7374/*----------- defined in video/exidy.c -----------*/
7475
7576void exidy_video_config(running_machine &machine, UINT8 _collision_mask, UINT8 _collision_invert, int _is_2bpp);
76INTERRUPT_GEN( exidy_vblank_interrupt );
trunk/src/mame/includes/xxmissio.h
r17996r17997
2929   virtual void machine_start();
3030   virtual void video_start();
3131   UINT32 screen_update_xxmissio(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
32   INTERRUPT_GEN_MEMBER(xxmissio_interrupt_m);
33   INTERRUPT_GEN_MEMBER(xxmissio_interrupt_s);
3234};
3335
3436DECLARE_WRITE8_DEVICE_HANDLER( xxmissio_scroll_x_w );
trunk/src/mame/includes/solomon.h
r17996r17997
3131   TILE_GET_INFO_MEMBER(get_fg_tile_info);
3232   virtual void video_start();
3333   UINT32 screen_update_solomon(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
34   INTERRUPT_GEN_MEMBER(vblank_irq);
3435};
trunk/src/mame/includes/moo.h
r17996r17997
5454   DECLARE_MACHINE_RESET(moo);
5555   DECLARE_VIDEO_START(moo);
5656   UINT32 screen_update_moo(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(moo_interrupt);
58   INTERRUPT_GEN_MEMBER(moobl_interrupt);
5759};
5860
5961/*----------- defined in video/moo.c -----------*/
trunk/src/mame/includes/gyruss.h
r17996r17997
5454   virtual void video_start();
5555   virtual void palette_init();
5656   UINT32 screen_update_gyruss(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(master_vblank_irq);
58   INTERRUPT_GEN_MEMBER(slave_vblank_irq);
5759};
trunk/src/mame/includes/groundfx.h
r17996r17997
3838   DECLARE_DRIVER_INIT(groundfx);
3939   virtual void video_start();
4040   UINT32 screen_update_groundfx(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
41   INTERRUPT_GEN_MEMBER(groundfx_interrupt);
4142};
trunk/src/mame/includes/vendetta.h
r17996r17997
4444   virtual void machine_start();
4545   virtual void machine_reset();
4646   UINT32 screen_update_vendetta(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
47   INTERRUPT_GEN_MEMBER(vendetta_irq);
4748};
4849
4950/*----------- defined in video/vendetta.c -----------*/
trunk/src/mame/includes/marineb.h
r17996r17997
4444   UINT32 screen_update_springer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4545   UINT32 screen_update_hoccer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4646   UINT32 screen_update_hopprobo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
47   INTERRUPT_GEN_MEMBER(marineb_vblank_irq);
48   INTERRUPT_GEN_MEMBER(wanted_vblank_irq);
4749};
trunk/src/mame/includes/timeplt.h
r17996r17997
5151   virtual void palette_init();
5252   DECLARE_VIDEO_START(chkun);
5353   UINT32 screen_update_timeplt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
54   INTERRUPT_GEN_MEMBER(timeplt_interrupt);
5455};
trunk/src/mame/includes/vulgus.h
r17996r17997
2626   virtual void video_start();
2727   virtual void palette_init();
2828   UINT32 screen_update_vulgus(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
29   INTERRUPT_GEN_MEMBER(vulgus_vblank_irq);
2930};
trunk/src/mame/includes/vastar.h
r17996r17997
4747   virtual void machine_reset();
4848   virtual void video_start();
4949   UINT32 screen_update_vastar(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(vblank_irq);
5051};
trunk/src/mame/includes/taito_f3.h
r17996r17997
272272   DECLARE_VIDEO_START(f3);
273273   UINT32 screen_update_f3(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
274274   void screen_eof_f3(screen_device &screen, bool state);
275   INTERRUPT_GEN_MEMBER(f3_interrupt2);
275276};
trunk/src/mame/includes/champbas.h
r17996r17997
6363   UINT32 screen_update_champbas(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6464   UINT32 screen_update_exctsccr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6565   void screen_eof_champbas(screen_device &screen, bool state);
66   INTERRUPT_GEN_MEMBER(vblank_irq);
6667};
trunk/src/mame/includes/ssozumo.h
r17996r17997
3636   virtual void video_start();
3737   virtual void palette_init();
3838   UINT32 screen_update_ssozumo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(sound_timer_irq);
3940};
trunk/src/mame/includes/twin16.h
r17996r17997
6363   DECLARE_VIDEO_START(twin16);
6464   UINT32 screen_update_twin16(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
6565   void screen_eof_twin16(screen_device &screen, bool state);
66   INTERRUPT_GEN_MEMBER(CPUA_interrupt);
67   INTERRUPT_GEN_MEMBER(CPUB_interrupt);
6668};
6769
6870/*----------- defined in drivers/twin16.c -----------*/
trunk/src/mame/includes/megasys1.h
r17996r17997
112112   DECLARE_MACHINE_RESET(megasys1_hachoo);
113113   UINT32 screen_update_megasys1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
114114   void screen_eof_megasys1(screen_device &screen, bool state);
115   INTERRUPT_GEN_MEMBER(megasys1D_irq);
115116};
trunk/src/mame/includes/airbustr.h
r17996r17997
6868   virtual void video_start();
6969   UINT32 screen_update_airbustr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
7070   void screen_eof_airbustr(screen_device &screen, bool state);
71   INTERRUPT_GEN_MEMBER(slave_interrupt);
7172};
trunk/src/mame/includes/pacman.h
r17996r17997
136136   DECLARE_VIDEO_START(jrpacman);
137137   UINT32 screen_update_pacman(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
138138   UINT32 screen_update_s2650games(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
139   INTERRUPT_GEN_MEMBER(vblank_irq);
140   INTERRUPT_GEN_MEMBER(vblank_nmi);
141   INTERRUPT_GEN_MEMBER(s2650_interrupt);
139142};
140143
141144/*----------- defined in machine/pacplus.c -----------*/
trunk/src/mame/includes/dcheese.h
r17996r17997
4747   virtual void video_start();
4848   virtual void palette_init();
4949   UINT32 screen_update_dcheese(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
50   INTERRUPT_GEN_MEMBER(dcheese_vblank);
5051};
5152
5253/*----------- defined in drivers/dcheese.c -----------*/
trunk/src/mame/includes/bwing.h
r17996r17997
7575   virtual void machine_reset();
7676   virtual void video_start();
7777   UINT32 screen_update_bwing(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
78   INTERRUPT_GEN_MEMBER(bwp3_interrupt);
7879};
7980
8081/*----------- defined in video/bwing.c -----------*/
trunk/src/mame/includes/cave.h
r17996r17997
201201   DECLARE_VIDEO_START(sailormn_3_layers);
202202   DECLARE_PALETTE_INIT(sailormn);
203203   UINT32 screen_update_cave(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
204   INTERRUPT_GEN_MEMBER(cave_interrupt);
204205};
205206
206207/*----------- defined in video/cave.c -----------*/
trunk/src/mame/includes/brkthru.h
r17996r17997
4646   virtual void video_start();
4747   virtual void palette_init();
4848   UINT32 screen_update_brkthru(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(vblank_irq);
4950};
trunk/src/mame/includes/dec8.h
r17996r17997
130130   UINT32 screen_update_srdarwin(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
131131   UINT32 screen_update_cobracom(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
132132   void screen_eof_dec8(screen_device &screen, bool state);
133   INTERRUPT_GEN_MEMBER(gondo_interrupt);
134   INTERRUPT_GEN_MEMBER(oscar_interrupt);
133135};
134136
135137/*----------- defined in video/dec8.c -----------*/
trunk/src/mame/includes/battlane.h
r17996r17997
3939   virtual void machine_reset();
4040   virtual void video_start();
4141   UINT32 screen_update_battlane(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(battlane_cpu1_interrupt);
4243};
trunk/src/mame/includes/thepit.h
r17996r17997
3939   virtual void palette_init();
4040   DECLARE_PALETTE_INIT(suprmous);
4141   UINT32 screen_update_thepit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(vblank_irq);
4243};
trunk/src/mame/includes/changela.h
r17996r17997
8989   virtual void machine_reset();
9090   virtual void video_start();
9191   UINT32 screen_update_changela(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
92   INTERRUPT_GEN_MEMBER(chl_mcu_irq);
9293};
trunk/src/mame/includes/crimfght.h
r17996r17997
3232   virtual void machine_reset();
3333   virtual void video_start();
3434   UINT32 screen_update_crimfght(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
35   INTERRUPT_GEN_MEMBER(crimfght_interrupt);
3536};
3637
3738/*----------- defined in video/crimfght.c -----------*/
trunk/src/mame/includes/asuka.h
r17996r17997
5050   UINT32 screen_update_bonzeadv(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5151   UINT32 screen_update_asuka(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
5252   void screen_eof_asuka(screen_device &screen, bool state);
53   INTERRUPT_GEN_MEMBER(cadash_interrupt);
5354};
5455
5556/*----------- defined in machine/bonzeadv.c -----------*/
trunk/src/mame/includes/pooyan.h
r17996r17997
3333   virtual void video_start();
3434   virtual void palette_init();
3535   UINT32 screen_update_pooyan(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
36   INTERRUPT_GEN_MEMBER(pooyan_interrupt);
3637};
trunk/src/mame/includes/tankbatt.h
r17996r17997
3030   virtual void video_start();
3131   virtual void palette_init();
3232   UINT32 screen_update_tankbatt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
33   INTERRUPT_GEN_MEMBER(tankbatt_interrupt);
3334};
trunk/src/mame/includes/subs.h
r17996r17997
4444   virtual void palette_init();
4545   UINT32 screen_update_subs_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
4646   UINT32 screen_update_subs_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
47   INTERRUPT_GEN_MEMBER(subs_interrupt);
4748};
4849
49
50/*----------- defined in machine/subs.c -----------*/
51INTERRUPT_GEN( subs_interrupt );
52
5350/*----------- defined in audio/subs.c -----------*/
5451
5552DECLARE_WRITE8_DEVICE_HANDLER( subs_noise_reset_w );
trunk/src/mame/includes/ajax.h
r17996r17997
3737   virtual void machine_reset();
3838   virtual void video_start();
3939   UINT32 screen_update_ajax(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
40   INTERRUPT_GEN_MEMBER(ajax_interrupt);
4041};
4142
42/*----------- defined in machine/ajax.c -----------*/
43INTERRUPT_GEN( ajax_interrupt );
44
4543/*----------- defined in video/ajax.c -----------*/
46
4744extern void ajax_tile_callback(running_machine &machine, int layer,int bank,int *code,int *color,int *flags,int *priority);
4845extern void ajax_sprite_callback(running_machine &machine, int *code,int *color,int *priority,int *shadow);
4946extern void ajax_zoom_callback(running_machine &machine, int *code,int *color,int *flags);
trunk/src/mame/drivers/bfcobra.c
r17996r17997
300300   virtual void machine_reset();
301301   virtual void video_start();
302302   UINT32 screen_update_bfcobra(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
303   INTERRUPT_GEN_MEMBER(timer_irq);
304   INTERRUPT_GEN_MEMBER(vblank_gen);
303305};
304306
305307
r17996r17997
17621764}
17631765
17641766/* TODO */
1765static INTERRUPT_GEN( timer_irq )
1767INTERRUPT_GEN_MEMBER(bfcobra_state::timer_irq)
17661768{
1767   generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
1769   generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
17681770}
17691771
17701772/* TODO */
1771static INTERRUPT_GEN( vblank_gen )
1773INTERRUPT_GEN_MEMBER(bfcobra_state::vblank_gen)
17721774{
1773   bfcobra_state *state = device->machine().driver_data<bfcobra_state>();
1774   state->m_vblank_irq = 1;
1775   update_irqs(device->machine());
1775   m_vblank_irq = 1;
1776   update_irqs(machine());
17761777}
17771778
17781779static MACHINE_CONFIG_START( bfcobra, bfcobra_state )
17791780   MCFG_CPU_ADD("maincpu", Z80, Z80_XTAL)
17801781   MCFG_CPU_PROGRAM_MAP(z80_prog_map)
17811782   MCFG_CPU_IO_MAP(z80_io_map)
1782   MCFG_CPU_VBLANK_INT("screen", vblank_gen)
1783   MCFG_CPU_VBLANK_INT_DRIVER("screen", bfcobra_state, vblank_gen)
17831784
17841785   MCFG_CPU_ADD("audiocpu", M6809, M6809_XTAL)
17851786   MCFG_CPU_PROGRAM_MAP(m6809_prog_map)
1786   MCFG_CPU_PERIODIC_INT(timer_irq, 1000)
1787   MCFG_CPU_PERIODIC_INT_DRIVER(bfcobra_state, timer_irq, 1000)
17871788
17881789   MCFG_NVRAM_ADD_0FILL("nvram")
17891790
trunk/src/mame/drivers/nycaptor.c
r17996r17997
832832   /* basic machine hardware */
833833   MCFG_CPU_ADD("maincpu", Z80,8000000/2)      /* ??? */
834834   MCFG_CPU_PROGRAM_MAP(nycaptor_master_map)
835   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
835   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)
836836
837837   MCFG_CPU_ADD("sub", Z80,8000000/2)
838838   MCFG_CPU_PROGRAM_MAP(nycaptor_slave_map)
839   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ generated by ??? */
839   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)   /* IRQ generated by ??? */
840840
841841   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)
842842   MCFG_CPU_PROGRAM_MAP(nycaptor_sound_map)
843   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ??? */
843   MCFG_CPU_PERIODIC_INT_DRIVER(nycaptor_state, irq0_line_hold, 2*60)   /* IRQ generated by ??? */
844844
845845   MCFG_CPU_ADD("mcu", M68705,2000000)
846846   MCFG_CPU_PROGRAM_MAP(nycaptor_m68705_map)
r17996r17997
890890
891891   MCFG_CPU_ADD("maincpu", Z80,8000000/2)
892892   MCFG_CPU_PROGRAM_MAP(cyclshtg_master_map)
893   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
893   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)
894894
895895   MCFG_CPU_ADD("sub", Z80,8000000/2)
896896   MCFG_CPU_PROGRAM_MAP(cyclshtg_slave_map)
897   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
897   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)
898898
899899   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)
900900   MCFG_CPU_PROGRAM_MAP(nycaptor_sound_map)
901   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
901   MCFG_CPU_PERIODIC_INT_DRIVER(nycaptor_state, irq0_line_hold, 2*60)
902902
903903#ifdef USE_MCU
904904   MCFG_CPU_ADD("mcu", M68705,2000000)
r17996r17997
948948
949949   MCFG_CPU_ADD("maincpu", Z80,8000000/2)
950950   MCFG_CPU_PROGRAM_MAP(bronx_master_map)
951   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
951   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)
952952
953953   MCFG_CPU_ADD("sub", Z80,8000000/2)
954954   MCFG_CPU_PROGRAM_MAP(bronx_slave_map)
955955   MCFG_CPU_IO_MAP(bronx_slave_io_map)
956   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
956   MCFG_CPU_VBLANK_INT_DRIVER("screen", nycaptor_state, irq0_line_hold)
957957
958958   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)
959959   MCFG_CPU_PROGRAM_MAP(nycaptor_sound_map)
960   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
960   MCFG_CPU_PERIODIC_INT_DRIVER(nycaptor_state, irq0_line_hold, 2*60)
961961
962962   MCFG_QUANTUM_TIME(attotime::from_hz(120))
963963
trunk/src/mame/drivers/mitchell.c
r17996r17997
12251225   MCFG_CPU_MODIFY("maincpu")
12261226   MCFG_CPU_PROGRAM_MAP(spangbl_map)
12271227   MCFG_CPU_IO_MAP(spangbl_io_map)
1228   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1228   MCFG_CPU_VBLANK_INT_DRIVER("screen", mitchell_state, irq0_line_hold)
12291229
12301230   MCFG_DEVICE_REMOVE("scantimer")
12311231
12321232   MCFG_CPU_ADD("audiocpu", Z80, 8000000)
12331233   MCFG_CPU_PROGRAM_MAP(spangbl_sound_map)
12341234   MCFG_CPU_IO_MAP(spangbl_sound_io_map)
1235   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1236//  MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1235   MCFG_CPU_VBLANK_INT_DRIVER("screen", mitchell_state,  irq0_line_hold)
1236   MCFG_CPU_VBLANK_INT_DRIVER("screen", mitchell_state,  nmi_line_pulse)
12371237
12381238   MCFG_GFXDECODE(spangbl)
12391239
r17996r17997
12521252   MCFG_CPU_ADD("maincpu", Z80, 6000000*4)
12531253   MCFG_CPU_PROGRAM_MAP(mitchell_map)
12541254   MCFG_CPU_IO_MAP(mstworld_io_map)
1255   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1255   MCFG_CPU_VBLANK_INT_DRIVER("screen", mitchell_state, irq0_line_hold)
12561256
12571257   MCFG_CPU_ADD("audiocpu", Z80,6000000)       /* 6 MHz? */
12581258   MCFG_CPU_PROGRAM_MAP(mstworld_sound_map)
trunk/src/mame/drivers/blktiger.c
r17996r17997
317317   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4)   /* verified on pcb */
318318   MCFG_CPU_PROGRAM_MAP(blktiger_map)
319319   MCFG_CPU_IO_MAP(blktiger_io_map)
320   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
320   MCFG_CPU_VBLANK_INT_DRIVER("screen", blktiger_state, irq0_line_hold)
321321
322322   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
323323   MCFG_CPU_PROGRAM_MAP(blktiger_sound_map)
r17996r17997
325325   MCFG_CPU_ADD("mcu", I8751, XTAL_24MHz/4) /* ??? */
326326   MCFG_CPU_PROGRAM_MAP(blktiger_mcu_map)
327327   MCFG_CPU_IO_MAP(blktiger_mcu_io_map)
328   //MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
328   //MCFG_CPU_VBLANK_INT_DRIVER("screen", blktiger_state, irq0_line_hold)
329329
330330
331331   /* video hardware */
trunk/src/mame/drivers/dynduke.c
r17996r17997
263263
264264/* Interrupt Generator */
265265
266static INTERRUPT_GEN( dynduke_interrupt )
266INTERRUPT_GEN_MEMBER(dynduke_state::dynduke_interrupt)
267267{
268   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   // VBL
268   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   // VBL
269269}
270270
271271/* Machine Driver */
r17996r17997
274274   // basic machine hardware
275275   MCFG_CPU_ADD("maincpu", V30, 16000000/2) // NEC V30-8 CPU
276276   MCFG_CPU_PROGRAM_MAP(master_map)
277   MCFG_CPU_VBLANK_INT("screen", dynduke_interrupt)
277   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynduke_state, dynduke_interrupt)
278278
279279   MCFG_CPU_ADD("slave", V30, 16000000/2) // NEC V30-8 CPU
280280   MCFG_CPU_PROGRAM_MAP(slave_map)
281   MCFG_CPU_VBLANK_INT("screen", dynduke_interrupt)
281   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynduke_state, dynduke_interrupt)
282282
283283   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
284284
trunk/src/mame/drivers/pasha2.c
r17996r17997
418418   MCFG_CPU_ADD("maincpu", E116XT, 20000000*4)      /* 4x internal multiplier */
419419   MCFG_CPU_PROGRAM_MAP(pasha2_map)
420420   MCFG_CPU_IO_MAP(pasha2_io)
421   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
421   MCFG_CPU_VBLANK_INT_DRIVER("screen", pasha2_state, irq0_line_hold)
422422
423423   MCFG_EEPROM_93C46_ADD("eeprom")
424424
trunk/src/mame/drivers/skyfox.c
r17996r17997
211211
212212/* Scroll the background on every vblank (guess). */
213213
214static INTERRUPT_GEN( skyfox_interrupt )
214INTERRUPT_GEN_MEMBER(skyfox_state::skyfox_interrupt)
215215{
216   skyfox_state *state = device->machine().driver_data<skyfox_state>();
217216
218217   /* Scroll the bg */
219   state->m_bg_pos += (state->m_bg_ctrl >> 1) & 0x7;   // maybe..
218   m_bg_pos += (m_bg_ctrl >> 1) & 0x7;   // maybe..
220219}
221220
222221void skyfox_state::machine_start()
r17996r17997
240239   /* basic machine hardware */
241240   MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz/2) /* Verified at 4MHz */
242241   MCFG_CPU_PROGRAM_MAP(skyfox_map)
243   MCFG_CPU_VBLANK_INT("screen", skyfox_interrupt)      /* NMI caused by coin insertion */
242   MCFG_CPU_VBLANK_INT_DRIVER("screen", skyfox_state, skyfox_interrupt)      /* NMI caused by coin insertion */
244243
245244   MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz/8) /* Verified at 1.789772MHz */
246245   MCFG_CPU_PROGRAM_MAP(skyfox_sound_map)
trunk/src/mame/drivers/bublbobl.c
r17996r17997
764764   /* basic machine hardware */
765765   MCFG_CPU_ADD("maincpu", Z80, MAIN_XTAL/4)   // 6 MHz
766766   MCFG_CPU_PROGRAM_MAP(tokio_map)
767   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
767   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
768768
769769   MCFG_CPU_ADD("slave", Z80, MAIN_XTAL/4)   // 6 MHz
770770   MCFG_CPU_PROGRAM_MAP(tokio_slave_map)
771   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
771   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
772772
773773   MCFG_CPU_ADD("audiocpu", Z80, MAIN_XTAL/8)   // 3 MHz
774774   MCFG_CPU_PROGRAM_MAP(tokio_sound_map) // NMIs are triggered by the main CPU, IRQs are triggered by the YM2203
r17996r17997
845845
846846   MCFG_CPU_ADD("slave", Z80, MAIN_XTAL/4)   // 6 MHz
847847   MCFG_CPU_PROGRAM_MAP(slave_map)
848   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
848   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
849849
850850   MCFG_CPU_ADD("audiocpu", Z80, MAIN_XTAL/8)   // 3 MHz
851851   MCFG_CPU_PROGRAM_MAP(sound_map) // IRQs are triggered by the YM2203
852852
853853   MCFG_CPU_ADD("mcu", M6801, 4000000)   // actually 6801U4  // xtal is 4MHz, divided by 4 internally
854854   MCFG_CPU_PROGRAM_MAP(mcu_map)
855   MCFG_CPU_VBLANK_INT("screen", irq0_line_pulse) // comes from the same clock that latches the INT pin on the second Z80
855   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_pulse) // comes from the same clock that latches the INT pin on the second Z80
856856
857857   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // 100 CPU slices per frame - a high value to ensure proper synchronization of the CPUs
858858
r17996r17997
901901
902902   MCFG_CPU_MODIFY("maincpu")
903903   MCFG_CPU_PROGRAM_MAP(bootleg_map)
904   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   // interrupt mode 1, unlike Bubble Bobble
904   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)   // interrupt mode 1, unlike Bubble Bobble
905905
906906   MCFG_MACHINE_START_OVERRIDE(bublbobl_state,boblbobl)
907907   MCFG_MACHINE_RESET_OVERRIDE(bublbobl_state,boblbobl)
r17996r17997
945945
946946   MCFG_CPU_ADD("mcu", M68705, 4000000)   // xtal is 4MHz, divided by 4 internally
947947   MCFG_CPU_PROGRAM_MAP(bootlegmcu_map)
948   MCFG_CPU_VBLANK_INT("screen",bublbobl_m68705_interrupt) // ??? should come from the same clock which latches the INT pin on the second Z80
948   MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, bublbobl_m68705_interrupt) // ??? should come from the same clock which latches the INT pin on the second Z80
949949
950950   MCFG_MACHINE_START_OVERRIDE(bublbobl_state,bub68705)
951951   MCFG_MACHINE_RESET_OVERRIDE(bublbobl_state,bub68705)
trunk/src/mame/drivers/coinmstr.c
r17996r17997
10101010static MACHINE_CONFIG_START( coinmstr, coinmstr_state )
10111011   MCFG_CPU_ADD("maincpu",Z80,8000000) // ?
10121012   MCFG_CPU_PROGRAM_MAP(coinmstr_map)
1013   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1013   MCFG_CPU_VBLANK_INT_DRIVER("screen", coinmstr_state, irq0_line_hold)
10141014
10151015   MCFG_PIA6821_ADD("pia0", pia_0_intf)
10161016   MCFG_PIA6821_ADD("pia1", pia_1_intf)
trunk/src/mame/drivers/docastle.c
r17996r17997
604604   MCFG_CPU_ADD("maincpu", Z80, XTAL_4MHz)
605605   MCFG_CPU_PROGRAM_MAP(docastle_map)
606606   MCFG_CPU_IO_MAP(docastle_io_map)
607   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
607   MCFG_CPU_VBLANK_INT_DRIVER("screen", docastle_state, irq0_line_hold)
608608
609609   MCFG_CPU_ADD("slave", Z80, XTAL_4MHz)
610610   MCFG_CPU_PROGRAM_MAP(docastle_map2)
611   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 8*60)
611   MCFG_CPU_PERIODIC_INT_DRIVER(docastle_state, irq0_line_hold, 8*60)
612612
613613   MCFG_CPU_ADD("cpu3", Z80, XTAL_4MHz)
614614   MCFG_CPU_PROGRAM_MAP(docastle_map3)
615   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
615   MCFG_CPU_VBLANK_INT_DRIVER("screen", docastle_state, nmi_line_pulse)
616616
617617   /* video hardware */
618618   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mainsnk.c
r17996r17997
390390
391391   MCFG_CPU_ADD("maincpu", Z80, 3360000)
392392   MCFG_CPU_PROGRAM_MAP(main_map)
393   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
393   MCFG_CPU_VBLANK_INT_DRIVER("screen", mainsnk_state, irq0_line_hold)
394394
395395   MCFG_CPU_ADD("audiocpu", Z80,4000000)
396396   MCFG_CPU_PROGRAM_MAP(sound_map)
397397   MCFG_CPU_IO_MAP(sound_portmap)
398   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 244)
398   MCFG_CPU_PERIODIC_INT_DRIVER(mainsnk_state, irq0_line_hold, 244)
399399
400400   /* video hardware */
401401   MCFG_VIDEO_ATTRIBUTES(VIDEO_HAS_SHADOWS)
trunk/src/mame/drivers/magicard.c
r17996r17997
218218   virtual void machine_reset();
219219   virtual void video_start();
220220   UINT32 screen_update_magicard(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
221   INTERRUPT_GEN_MEMBER(magicard_irq);
221222};
222223
223224
r17996r17997
708709*************************/
709710
710711/*Probably there's a mask somewhere if it REALLY uses irqs at all...irq vectors dynamically changes after some time.*/
711static INTERRUPT_GEN( magicard_irq )
712INTERRUPT_GEN_MEMBER(magicard_state::magicard_irq)
712713{
713   if(device->machine().input().code_pressed(KEYCODE_Z)) //vblank?
714      device->execute().set_input_line_and_vector(1, HOLD_LINE,0xe4/4);
715   if(device->machine().input().code_pressed(KEYCODE_X)) //uart irq
716      device->execute().set_input_line_and_vector(1, HOLD_LINE,0xf0/4);
714   if(machine().input().code_pressed(KEYCODE_Z)) //vblank?
715      device.execute().set_input_line_and_vector(1, HOLD_LINE,0xe4/4);
716   if(machine().input().code_pressed(KEYCODE_X)) //uart irq
717      device.execute().set_input_line_and_vector(1, HOLD_LINE,0xf0/4);
717718}
718719
719720static MACHINE_CONFIG_START( magicard, magicard_state )
720721   MCFG_CPU_ADD("maincpu", SCC68070, CLOCK_A/2)   /* SCC-68070 CCA84 datasheet */
721722   MCFG_CPU_PROGRAM_MAP(magicard_mem)
722   MCFG_CPU_VBLANK_INT("screen", magicard_irq) /* no interrupts? (it erases the vectors..) */
723   MCFG_CPU_VBLANK_INT_DRIVER("screen", magicard_state, magicard_irq) /* no interrupts? (it erases the vectors..) */
723724
724725   MCFG_SCREEN_ADD("screen", RASTER)
725726   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/yiear.c
r17996r17997
121121   vlm5030_rst(device, (data >> 2) & 1);
122122}
123123
124static INTERRUPT_GEN( yiear_vblank_interrupt )
124INTERRUPT_GEN_MEMBER(yiear_state::yiear_vblank_interrupt)
125125{
126   yiear_state *state = device->machine().driver_data<yiear_state>();
127126
128   if (state->m_yiear_irq_enable)
129      device->execute().set_input_line(0, HOLD_LINE);
127   if (m_yiear_irq_enable)
128      device.execute().set_input_line(0, HOLD_LINE);
130129}
131130
132131
133static INTERRUPT_GEN( yiear_nmi_interrupt )
132INTERRUPT_GEN_MEMBER(yiear_state::yiear_nmi_interrupt)
134133{
135   yiear_state *state = device->machine().driver_data<yiear_state>();
136134
137   if (state->m_yiear_nmi_enable)
138      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
135   if (m_yiear_nmi_enable)
136      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
139137}
140138
141139
r17996r17997
289287   /* basic machine hardware */
290288   MCFG_CPU_ADD("maincpu", M6809,XTAL_18_432MHz/12)   /* verified on pcb */
291289   MCFG_CPU_PROGRAM_MAP(main_map)
292   MCFG_CPU_VBLANK_INT("screen", yiear_vblank_interrupt)
293   MCFG_CPU_PERIODIC_INT(yiear_nmi_interrupt,480)   /* music tempo (correct frequency unknown) */
290   MCFG_CPU_VBLANK_INT_DRIVER("screen", yiear_state,  yiear_vblank_interrupt)
291   MCFG_CPU_PERIODIC_INT_DRIVER(yiear_state, yiear_nmi_interrupt, 480)   /* music tempo (correct frequency unknown) */
294292
295293
296294   /* video hardware */
trunk/src/mame/drivers/bfm_sc1.c
r17996r17997
175175   DECLARE_DRIVER_INIT(rou029);
176176   DECLARE_DRIVER_INIT(nocrypt);
177177   virtual void machine_reset();
178   INTERRUPT_GEN_MEMBER(timer_irq);
178179};
179180
180181#define VFD_RESET  0x20
r17996r17997
213214
214215///////////////////////////////////////////////////////////////////////////
215216
216static INTERRUPT_GEN( timer_irq )
217INTERRUPT_GEN_MEMBER(bfm_sc1_state::timer_irq)
217218{
218   bfm_sc1_state *state = device->machine().driver_data<bfm_sc1_state>();
219219
220   if ( state->m_is_timer_enabled )
220   if ( m_is_timer_enabled )
221221   {
222      state->m_irq_status = 0x01 |0x02; //0xff;
222      m_irq_status = 0x01 |0x02; //0xff;
223223
224       state->m_sc1_Inputs[2] = state->ioport("STROBE0")->read();
224       m_sc1_Inputs[2] = ioport("STROBE0")->read();
225225
226      generic_pulse_irq_line(device->machine().device("maincpu"), M6809_IRQ_LINE, 1);
226      generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
227227   }
228228}
229229
r17996r17997
10951095static MACHINE_CONFIG_START( scorpion1, bfm_sc1_state )
10961096   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4)         // 6809 CPU at 1 Mhz
10971097   MCFG_CPU_PROGRAM_MAP(sc1_base)                  // setup read and write memorymap
1098   MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )            // generate 1000 IRQ's per second
1098   MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc1_state, timer_irq, 1000)            // generate 1000 IRQ's per second
10991099   MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
11001100
11011101   MCFG_BFMBD1_ADD("vfd0",0)
trunk/src/mame/drivers/murogem.c
r17996r17997
247247   /* basic machine hardware */
248248   MCFG_CPU_ADD("maincpu", M6802, 8000000)       /* ? MHz */
249249   MCFG_CPU_PROGRAM_MAP(murogem_map)
250   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
250   MCFG_CPU_VBLANK_INT_DRIVER("screen", murogem_state, irq0_line_hold)
251251
252252   /* video hardware */
253253   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/snowbros.c
r17996r17997
16951695   MCFG_CPU_ADD("soundcpu", Z80, 4000000)
16961696   MCFG_CPU_PROGRAM_MAP(sound_map)
16971697   MCFG_CPU_IO_MAP(twinadv_sound_io_map)
1698   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1698   MCFG_CPU_VBLANK_INT_DRIVER("screen", snowbros_state, irq0_line_hold)
16991699
17001700   /* video hardware */
17011701   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/nbmj9195.c
r17996r17997
611611}
612612
613613/* CTC of main cpu, ch0 trigger is vblank */
614static INTERRUPT_GEN( ctc0_trg1 )
614INTERRUPT_GEN_MEMBER(nbmj9195_state::ctc0_trg1)
615615{
616   z80ctc_device *ctc = device->machine().device<z80ctc_device>("main_ctc");
616   z80ctc_device *ctc = machine().device<z80ctc_device>("main_ctc");
617617   ctc->trg1(1);
618618   ctc->trg1(0);
619619}
r17996r17997
31653165   MCFG_CPU_CONFIG(daisy_chain_main)
31663166   MCFG_CPU_PROGRAM_MAP(sailorws_map)
31673167   MCFG_CPU_IO_MAP(sailorws_io_map)
3168   MCFG_CPU_VBLANK_INT("screen", ctc0_trg1)            /* vblank is connect to ctc triggfer */
3168   MCFG_CPU_VBLANK_INT_DRIVER("screen", nbmj9195_state, ctc0_trg1)            /* vblank is connect to ctc triggfer */
31693169
31703170   MCFG_CPU_ADD("audiocpu", Z80, 8000000)               /* TMPZ84C011, 8.00 MHz */
31713171   MCFG_CPU_CONFIG(daisy_chain_sound)
trunk/src/mame/drivers/sonson.c
r17996r17997
244244   /* basic machine hardware */
245245   MCFG_CPU_ADD("maincpu", M6809,12000000/6)   /* 2 MHz ??? */
246246   MCFG_CPU_PROGRAM_MAP(main_map)
247   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
247   MCFG_CPU_VBLANK_INT_DRIVER("screen", sonson_state, irq0_line_hold)
248248
249249   MCFG_CPU_ADD("audiocpu", M6809,12000000/6)   /* 2 MHz ??? */
250250   MCFG_CPU_PROGRAM_MAP(sound_map)
251   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* FIRQs are triggered by the main CPU */
251   MCFG_CPU_PERIODIC_INT_DRIVER(sonson_state, irq0_line_hold, 4*60)   /* FIRQs are triggered by the main CPU */
252252
253253
254254   /* video hardware */
trunk/src/mame/drivers/sslam.c
r17996r17997
707707   /* basic machine hardware */
708708   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
709709   MCFG_CPU_PROGRAM_MAP(sslam_program_map)
710   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
710   MCFG_CPU_VBLANK_INT_DRIVER("screen", sslam_state, irq2_line_hold)
711711
712712   MCFG_CPU_ADD("audiocpu", I8051, 12000000)
713713   MCFG_DEVICE_DISABLE()      /* Internal code is not dumped - 2 boards were protected */
r17996r17997
737737   /* basic machine hardware */
738738   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
739739   MCFG_CPU_PROGRAM_MAP(powerbls_map)
740   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
740   MCFG_CPU_VBLANK_INT_DRIVER("screen", sslam_state, irq2_line_hold)
741741
742742   MCFG_CPU_ADD("audiocpu", I80C51, 12000000)      /* 83C751 */
743743   MCFG_CPU_IO_MAP(sound_io_map)
trunk/src/mame/drivers/hcastle.c
r17996r17997
209209   /* basic machine hardware */
210210   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)   /* Derived from 24 MHz clock */
211211   MCFG_CPU_PROGRAM_MAP(hcastle_map)
212   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
212   MCFG_CPU_VBLANK_INT_DRIVER("screen", hcastle_state, irq0_line_hold)
213213
214214   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
215215   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/cntsteer.c
r17996r17997
9292   DECLARE_PALETTE_INIT(zerotrgt);
9393   UINT32 screen_update_cntsteer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
9494   UINT32 screen_update_zerotrgt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
95   INTERRUPT_GEN_MEMBER(sound_interrupt);
9596};
9697
9798
r17996r17997
595596   m_nmimask = data & 0x80;
596597}
597598
598static INTERRUPT_GEN ( sound_interrupt )
599INTERRUPT_GEN_MEMBER(cntsteer_state::sound_interrupt)
599600{
600   cntsteer_state *state = device->machine().driver_data<cntsteer_state>();
601   if (!state->m_nmimask)
602      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
601   if (!m_nmimask)
602      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
603603}
604604
605605static ADDRESS_MAP_START( sound_map, AS_PROGRAM, 8, cntsteer_state )
r17996r17997
883883   /* basic machine hardware */
884884   MCFG_CPU_ADD("maincpu", M6809, 2000000)       /* ? */
885885   MCFG_CPU_PROGRAM_MAP(cntsteer_cpu1_map)
886   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
886   MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
887887
888888   MCFG_CPU_ADD("subcpu", M6809, 2000000)       /* ? */
889889   MCFG_CPU_PROGRAM_MAP(cntsteer_cpu2_map)
890//  MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
890   MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
891891
892892   MCFG_CPU_ADD("audiocpu", M6502, 1500000)        /* ? */
893893   MCFG_CPU_PROGRAM_MAP(sound_map)
894   MCFG_CPU_PERIODIC_INT(sound_interrupt, 480)
894   MCFG_CPU_PERIODIC_INT_DRIVER(cntsteer_state, sound_interrupt, 480)
895895
896896   MCFG_MACHINE_START_OVERRIDE(cntsteer_state,cntsteer)
897897   MCFG_MACHINE_RESET_OVERRIDE(cntsteer_state,cntsteer)
r17996r17997
930930   /* basic machine hardware */
931931   MCFG_CPU_ADD("maincpu", M6809, 2000000)       /* ? */
932932   MCFG_CPU_PROGRAM_MAP(gekitsui_cpu1_map)
933   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
933   MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
934934
935935   MCFG_CPU_ADD("subcpu", M6809, 2000000)       /* ? */
936936   MCFG_CPU_PROGRAM_MAP(gekitsui_cpu2_map)
937//  MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
937   MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
938938
939939   MCFG_CPU_ADD("audiocpu", M6502, 1500000)      /* ? */
940940   MCFG_CPU_PROGRAM_MAP(sound_map)
941   MCFG_CPU_PERIODIC_INT(sound_interrupt, 480)
941   MCFG_CPU_PERIODIC_INT_DRIVER(cntsteer_state, sound_interrupt, 480)
942942
943943   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
944944
trunk/src/mame/drivers/bking.c
r17996r17997
468468   MCFG_CPU_ADD("main_cpu", Z80, XTAL_12MHz/4)   /* 3 MHz */
469469   MCFG_CPU_PROGRAM_MAP(bking_map)
470470   MCFG_CPU_IO_MAP(bking_io_map)
471   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
471   MCFG_CPU_VBLANK_INT_DRIVER("screen", bking_state, irq0_line_hold)
472472
473473   MCFG_CPU_ADD("audiocpu", Z80, XTAL_6MHz/2)   /* 3 MHz */
474474   MCFG_CPU_PROGRAM_MAP(bking_audio_map)
r17996r17997
476476   /* - no interrupts synced with vblank */
477477   /* - NMI triggered by the main CPU */
478478   /* - periodic IRQ, with frequency 6000000/(4*16*16*10*16) = 36.621 Hz, */
479   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)6000000/(4*16*16*10*16))
479   MCFG_CPU_PERIODIC_INT_DRIVER(bking_state, irq0_line_hold, (double)6000000/(4*16*16*10*16))
480480
481481
482482   /* video hardware */
trunk/src/mame/drivers/dblewing.c
r17996r17997
641641   /* basic machine hardware */
642642   MCFG_CPU_ADD("maincpu", M68000, 14000000)   /* DE102 */
643643   MCFG_CPU_PROGRAM_MAP(dblewing_map)
644   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
644   MCFG_CPU_VBLANK_INT_DRIVER("screen", dblewing_state, irq6_line_hold)
645645
646646   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
647647   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/arabian.c
r17996r17997
360360   MCFG_CPU_ADD("maincpu", Z80, MAIN_OSC/4)
361361   MCFG_CPU_PROGRAM_MAP(main_map)
362362   MCFG_CPU_IO_MAP(main_io_map)
363   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
363   MCFG_CPU_VBLANK_INT_DRIVER("screen", arabian_state, irq0_line_hold)
364364
365365   MCFG_CPU_ADD("mcu", MB8841, MAIN_OSC/3/2)
366366   MCFG_CPU_IO_MAP(mcu_io_map)
trunk/src/mame/drivers/labyrunr.c
r17996r17997
1616#include "includes/labyrunr.h"
1717
1818
19static INTERRUPT_GEN( labyrunr_vblank_interrupt )
19INTERRUPT_GEN_MEMBER(labyrunr_state::labyrunr_vblank_interrupt)
2020{
21   labyrunr_state *state = device->machine().driver_data<labyrunr_state>();
22   address_space &space = state->generic_space();
23   if (k007121_ctrlram_r(state->m_k007121, space, 7) & 0x02)
24      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
21   address_space &space = generic_space();
22   if (k007121_ctrlram_r(m_k007121, space, 7) & 0x02)
23      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
2524}
2625
27static INTERRUPT_GEN( labyrunr_timer_interrupt )
26INTERRUPT_GEN_MEMBER(labyrunr_state::labyrunr_timer_interrupt)
2827{
29   labyrunr_state *state = device->machine().driver_data<labyrunr_state>();
30   address_space &space = state->generic_space();
31   if (k007121_ctrlram_r(state->m_k007121, space, 7) & 0x01)
32      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
28   address_space &space = generic_space();
29   if (k007121_ctrlram_r(m_k007121, space, 7) & 0x01)
30      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
3331}
3432
3533
r17996r17997
197195   /* basic machine hardware */
198196   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)      /* 24MHz/8? */
199197   MCFG_CPU_PROGRAM_MAP(labyrunr_map)
200   MCFG_CPU_VBLANK_INT("screen", labyrunr_vblank_interrupt)
201   MCFG_CPU_PERIODIC_INT(labyrunr_timer_interrupt, 4*60)
198   MCFG_CPU_VBLANK_INT_DRIVER("screen", labyrunr_state,  labyrunr_vblank_interrupt)
199   MCFG_CPU_PERIODIC_INT_DRIVER(labyrunr_state, labyrunr_timer_interrupt,  4*60)
202200
203201
204202   /* video hardware */
trunk/src/mame/drivers/shougi.c
r17996r17997
112112   DECLARE_READ8_MEMBER(dummy_r);
113113   virtual void palette_init();
114114   UINT32 screen_update_shougi(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
115   INTERRUPT_GEN_MEMBER(shougi_vblank_nmi);
115116};
116117
117118
r17996r17997
273274   m_nmi_enabled = 1; /* enable NMIs */
274275}
275276
276static INTERRUPT_GEN( shougi_vblank_nmi )
277INTERRUPT_GEN_MEMBER(shougi_state::shougi_vblank_nmi)
277278{
278   shougi_state *state = device->machine().driver_data<shougi_state>();
279279
280   if ( state->m_nmi_enabled == 1 )
280   if ( m_nmi_enabled == 1 )
281281   {
282282      /* NMI lines are tied together on both CPUs and connected to the LS74 /Q output */
283      device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
284      device->machine().device("sub")->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
283      machine().device("maincpu")->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
284      machine().device("sub")->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
285285   }
286286}
287287
r17996r17997
405405
406406   MCFG_CPU_ADD("maincpu", Z80,10000000/4)
407407   MCFG_CPU_PROGRAM_MAP(main_map)
408   MCFG_CPU_VBLANK_INT("screen", shougi_vblank_nmi)
408   MCFG_CPU_VBLANK_INT_DRIVER("screen", shougi_state, shougi_vblank_nmi)
409409
410410   MCFG_CPU_ADD("sub", Z80,10000000/4)
411411   MCFG_CPU_PROGRAM_MAP(sub_map)
trunk/src/mame/drivers/thief.c
r17996r17997
3333
3434
3535
36static INTERRUPT_GEN( thief_interrupt )
36INTERRUPT_GEN_MEMBER(thief_state::thief_interrupt)
3737{
3838   /* SLAM switch causes an NMI if it's pressed */
39   if( (device->machine().root_device().ioport("P2")->read() & 0x10) == 0 )
40      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
39   if( (machine().root_device().ioport("P2")->read() & 0x10) == 0 )
40      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
4141   else
42      device->execute().set_input_line(0, HOLD_LINE);
42      device.execute().set_input_line(0, HOLD_LINE);
4343}
4444
4545/**********************************************************/
r17996r17997
439439   MCFG_CPU_ADD("maincpu", Z80, 4000000)        /* 4 MHz? */
440440   MCFG_CPU_PROGRAM_MAP(sharkatt_main_map)
441441   MCFG_CPU_IO_MAP(io_map)
442   MCFG_CPU_VBLANK_INT("screen", thief_interrupt)
442   MCFG_CPU_VBLANK_INT_DRIVER("screen", thief_state, thief_interrupt)
443443
444444   /* video hardware */
445445   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
474474   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz? */
475475   MCFG_CPU_PROGRAM_MAP(thief_main_map)
476476   MCFG_CPU_IO_MAP(io_map)
477   MCFG_CPU_VBLANK_INT("screen", thief_interrupt)
477   MCFG_CPU_VBLANK_INT_DRIVER("screen", thief_state, thief_interrupt)
478478
479479   /* video hardware */
480480   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
509509   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz? */
510510   MCFG_CPU_PROGRAM_MAP(thief_main_map)
511511   MCFG_CPU_IO_MAP(io_map)
512   MCFG_CPU_VBLANK_INT("screen", thief_interrupt)
512   MCFG_CPU_VBLANK_INT_DRIVER("screen", thief_state, thief_interrupt)
513513
514514   /* video hardware */
515515   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/hornet.c
r17996r17997
993993   /* basic machine hardware */
994994   MCFG_CPU_ADD("maincpu", PPC403GA, 64000000/2)   /* PowerPC 403GA 32MHz */
995995   MCFG_CPU_PROGRAM_MAP(hornet_map)
996   MCFG_CPU_PERIODIC_INT(irq1_line_assert, 1000)
996   MCFG_CPU_PERIODIC_INT_DRIVER(hornet_state, irq1_line_assert, 1000)
997997
998998   MCFG_CPU_ADD("audiocpu", M68000, 64000000/4)   /* 16MHz */
999999   MCFG_CPU_PROGRAM_MAP(sound_memmap)
trunk/src/mame/drivers/hotstuff.c
r17996r17997
126126
127127   MCFG_CPU_ADD("maincpu", M68000, 16000000)
128128   MCFG_CPU_PROGRAM_MAP(hotstuff_map)
129   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
129   MCFG_CPU_VBLANK_INT_DRIVER("screen", hotstuff_state, irq1_line_hold)
130130
131131   MCFG_SCREEN_ADD("screen", RASTER)
132132   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/discoboy.c
r17996r17997
498498   MCFG_CPU_ADD("maincpu", Z80,12000000/2)       /* 6 MHz? */
499499   MCFG_CPU_PROGRAM_MAP(discoboy_map)
500500   MCFG_CPU_IO_MAP(io_map)
501   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
501   MCFG_CPU_VBLANK_INT_DRIVER("screen", discoboy_state, irq0_line_hold)
502502
503503   MCFG_CPU_ADD("audiocpu", Z80,10000000/2)       /* 5 MHz? */
504504   MCFG_CPU_PROGRAM_MAP(sound_map)
505   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,32*60)
505   MCFG_CPU_PERIODIC_INT_DRIVER(discoboy_state, nmi_line_pulse, 32*60)
506506
507507
508508   /* video hardware */
trunk/src/mame/drivers/wildpkr.c
r17996r17997
276276   /* basic machine hardware */
277277   MCFG_CPU_ADD("maincpu", M68000, MAIN_CLOCK)
278278   MCFG_CPU_PROGRAM_MAP(wildpkr_map)
279//  MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)   //guess
279   MCFG_CPU_VBLANK_INT_DRIVER("screen", wildpkr_state, irq1_line_hold)   //guess
280280
281281
282282   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/summit.c
r17996r17997
300300   /* basic machine hardware */
301301   MCFG_CPU_ADD("maincpu", Z80,4000000)
302302   MCFG_CPU_PROGRAM_MAP(mainmap)
303   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
303   MCFG_CPU_VBLANK_INT_DRIVER("screen", summit_state, irq0_line_hold)
304304
305305   /* video hardware */
306306   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ambush.c
r17996r17997
232232   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)      /* XTAL confirmed, divisor guessed */
233233   MCFG_CPU_PROGRAM_MAP(main_map)
234234   MCFG_CPU_IO_MAP(main_portmap)
235   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
235   MCFG_CPU_VBLANK_INT_DRIVER("screen", ambush_state, irq0_line_hold)
236236
237237   /* video hardware */
238238   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/orbit.c
r17996r17997
4747}
4848
4949
50static INTERRUPT_GEN( orbit_interrupt )
50INTERRUPT_GEN_MEMBER(orbit_state::orbit_interrupt)
5151{
52   device->execute().set_input_line(0, ASSERT_LINE);
53   device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_vblank_end(), FUNC(irq_off));
52   device.execute().set_input_line(0, ASSERT_LINE);
53   machine().scheduler().timer_set(machine().primary_screen->time_until_vblank_end(), FUNC(irq_off));
5454}
5555
5656
r17996r17997
299299   /* basic machine hardware */
300300   MCFG_CPU_ADD("maincpu", M6800, MASTER_CLOCK / 16)
301301   MCFG_CPU_PROGRAM_MAP(orbit_map)
302   MCFG_CPU_VBLANK_INT("screen", orbit_interrupt)
302   MCFG_CPU_VBLANK_INT_DRIVER("screen", orbit_state, orbit_interrupt)
303303
304304   MCFG_TIMER_ADD_SCANLINE("32v", nmi_32v, "screen", 0, 32)
305305
trunk/src/mame/drivers/policetr.c
r17996r17997
107107}
108108
109109
110static INTERRUPT_GEN( irq4_gen )
110INTERRUPT_GEN_MEMBER(policetr_state::irq4_gen)
111111{
112   device->execute().set_input_line(R3000_IRQ4, ASSERT_LINE);
113   device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_pos(0), FUNC(irq5_gen));
112   device.execute().set_input_line(R3000_IRQ4, ASSERT_LINE);
113   machine().scheduler().timer_set(machine().primary_screen->time_until_pos(0), FUNC(irq5_gen));
114114}
115115
116116
r17996r17997
416416   MCFG_CPU_ADD("maincpu", R3000BE, MASTER_CLOCK/2)
417417   MCFG_CPU_CONFIG(r3000_config)
418418   MCFG_CPU_PROGRAM_MAP(policetr_map)
419   MCFG_CPU_VBLANK_INT("screen", irq4_gen)
419   MCFG_CPU_VBLANK_INT_DRIVER("screen", policetr_state, irq4_gen)
420420
421421   MCFG_EEPROM_ADD("eeprom", eeprom_interface_policetr)
422422
trunk/src/mame/drivers/skimaxx.c
r17996r17997
525525static MACHINE_CONFIG_START( skimaxx, skimaxx_state )
526526   MCFG_CPU_ADD("maincpu", M68EC030, XTAL_40MHz)
527527   MCFG_CPU_PROGRAM_MAP(68030_1_map)
528   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)   // 1,3,7 are identical, rest is RTE
528   MCFG_CPU_VBLANK_INT_DRIVER("screen", skimaxx_state, irq3_line_hold)   // 1,3,7 are identical, rest is RTE
529529
530530   MCFG_CPU_ADD("subcpu", M68EC030, XTAL_40MHz)
531531   MCFG_CPU_PROGRAM_MAP(68030_2_map)
trunk/src/mame/drivers/mwarr.c
r17996r17997
558558   /* basic machine hardware */
559559   MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK)
560560   MCFG_CPU_PROGRAM_MAP(mwarr_map)
561   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
561   MCFG_CPU_VBLANK_INT_DRIVER("screen", mwarr_state, irq4_line_hold)
562562
563563
564564   /* video hardware */
trunk/src/mame/drivers/gaplus.c
r17996r17997
250250   }
251251}
252252
253static INTERRUPT_GEN( gaplus_vblank_main_irq )
253INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_main_irq)
254254{
255   gaplus_state *state = device->machine().driver_data<gaplus_state>();
256255
257   device_t *io58xx = device->machine().device("58xx");
258   device_t *io56xx = device->machine().device("56xx");
256   device_t *io58xx = machine().device("58xx");
257   device_t *io56xx = machine().device("56xx");
259258
260   if(state->m_main_irq_mask)
261      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
259   if(m_main_irq_mask)
260      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
262261
263262   if (!namcoio_read_reset_line(io58xx))      /* give the cpu a tiny bit of time to write the command before processing it */
264      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
263      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
265264
266265   if (!namcoio_read_reset_line(io56xx))      /* give the cpu a tiny bit of time to write the command before processing it */
267      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
266      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
268267}
269268
270static INTERRUPT_GEN( gaplus_vblank_sub_irq )
269INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_sub_irq)
271270{
272   gaplus_state *state = device->machine().driver_data<gaplus_state>();
273271
274   if(state->m_sub_irq_mask)
275      device->machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
272   if(m_sub_irq_mask)
273      machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
276274}
277275
278static INTERRUPT_GEN( gaplus_vblank_sub2_irq )
276INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_sub2_irq)
279277{
280   gaplus_state *state = device->machine().driver_data<gaplus_state>();
281278
282   if(state->m_sub2_irq_mask)
283      device->machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
279   if(m_sub2_irq_mask)
280      machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
284281}
285282
286283
r17996r17997
560557   /* basic machine hardware */
561558   MCFG_CPU_ADD("maincpu", M6809,   24576000/16)   /* 1.536 MHz */
562559   MCFG_CPU_PROGRAM_MAP(cpu1_map)
563   MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_main_irq)
560   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_main_irq)
564561
565562   MCFG_CPU_ADD("sub", M6809,   24576000/16)   /* 1.536 MHz */
566563   MCFG_CPU_PROGRAM_MAP(cpu2_map)
567   MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_sub_irq)
564   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_sub_irq)
568565
569566   MCFG_CPU_ADD("sub2", M6809, 24576000/16)   /* 1.536 MHz */
570567   MCFG_CPU_PROGRAM_MAP(cpu3_map)
571   MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_sub2_irq)
568   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_sub2_irq)
572569
573570   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* a high value to ensure proper synchronization of the CPUs */
574571
trunk/src/mame/drivers/carpolo.c
r17996r17997
244244   /* basic machine hardware */
245245   MCFG_CPU_ADD("maincpu", M6502, XTAL_11_289MHz/12)      /* 940.75 kHz */
246246   MCFG_CPU_PROGRAM_MAP(main_map)
247   MCFG_CPU_VBLANK_INT("screen", carpolo_timer_interrupt)   /* this not strictly VBLANK,
247   MCFG_CPU_VBLANK_INT_DRIVER("screen", carpolo_state, carpolo_timer_interrupt)   /* this not strictly VBLANK,
248248                                                       but it's supposed to happen 60
249249                                                       times a sec, so it's a good place */
250250
trunk/src/mame/drivers/vroulet.c
r17996r17997
288288   MCFG_CPU_ADD("maincpu", Z80, 4000000)   //???
289289   MCFG_CPU_PROGRAM_MAP(vroulet_map)
290290   MCFG_CPU_IO_MAP(vroulet_io_map)
291   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
291   MCFG_CPU_VBLANK_INT_DRIVER("screen", vroulet_state, irq0_line_hold)
292292
293293   MCFG_NVRAM_ADD_1FILL("nvram")
294294
trunk/src/mame/drivers/speedatk.c
r17996r17997
325325   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/2) //divider is unknown
326326   MCFG_CPU_PROGRAM_MAP(speedatk_mem)
327327   MCFG_CPU_IO_MAP(speedatk_io)
328   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
328   MCFG_CPU_VBLANK_INT_DRIVER("screen", speedatk_state, irq0_line_hold)
329329
330330   MCFG_WATCHDOG_VBLANK_INIT(8) // timing is unknown
331331
trunk/src/mame/drivers/coinmvga.c
r17996r17997
237237   virtual void video_start();
238238   virtual void palette_init();
239239   UINT32 screen_update_coinmvga(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
240   INTERRUPT_GEN_MEMBER(vblank_irq);
240241};
241242
242243
r17996r17997
656657   0   // irq ?
657658};
658659
659static INTERRUPT_GEN( vblank_irq )
660INTERRUPT_GEN_MEMBER(coinmvga_state::vblank_irq)
660661{
661662   //printf("1\n");
662   device->execute().set_input_line(2, HOLD_LINE);
663   device.execute().set_input_line(2, HOLD_LINE);
663664}
664665
665666
r17996r17997
673674   MCFG_CPU_ADD("maincpu", H83007, CPU_CLOCK)   /* xtal */
674675   MCFG_CPU_PROGRAM_MAP(coinmvga_map)
675676   MCFG_CPU_IO_MAP(coinmvga_io_map)
676   MCFG_CPU_VBLANK_INT("screen", vblank_irq)   /* wrong, fix me */
677   MCFG_CPU_VBLANK_INT_DRIVER("screen", coinmvga_state, vblank_irq)   /* wrong, fix me */
677678
678679//  MCFG_NVRAM_ADD_0FILL("nvram")
679680
trunk/src/mame/drivers/twins.c
r17996r17997
193193   MCFG_CPU_ADD("maincpu", V30, 8000000)
194194   MCFG_CPU_PROGRAM_MAP(twins_map)
195195   MCFG_CPU_IO_MAP(twins_io)
196   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
196   MCFG_CPU_VBLANK_INT_DRIVER("screen", twins_state, nmi_line_pulse)
197197
198198   /* video hardware */
199199   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
281281   MCFG_CPU_ADD("maincpu", V30, XTAL_16MHz/2) /* verified on pcb */
282282   MCFG_CPU_PROGRAM_MAP(twins_map)
283283   MCFG_CPU_IO_MAP(twinsa_io)
284   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
284   MCFG_CPU_VBLANK_INT_DRIVER("screen", twins_state, nmi_line_pulse)
285285
286286   /* video hardware */
287287   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/powerins.c
r17996r17997
343343   /* basic machine hardware */
344344   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12MHz */
345345   MCFG_CPU_PROGRAM_MAP(powerins_map)
346   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
346   MCFG_CPU_VBLANK_INT_DRIVER("screen", powerins_state, irq4_line_hold)
347347
348348   MCFG_CPU_ADD("soundcpu", Z80, 6000000) /* 6 MHz */
349349   MCFG_CPU_PROGRAM_MAP(powerins_sound_map)
r17996r17997
407407
408408   MCFG_CPU_MODIFY("soundcpu") /* 6 MHz */
409409   MCFG_CPU_IO_MAP(powerinb_sound_io_map)
410   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 120)   // YM2203 rate is at 150??
410   MCFG_CPU_PERIODIC_INT_DRIVER(powerins_state, irq0_line_hold, 120)   // YM2203 rate is at 150??
411411
412412   MCFG_DEVICE_REMOVE("ym2203")   // Sound code talks to one, but it's not fitted on the board
413413MACHINE_CONFIG_END
trunk/src/mame/drivers/cultures.c
r17996r17997
5757   virtual void machine_reset();
5858   virtual void video_start();
5959   UINT32 screen_update_cultures(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
60   INTERRUPT_GEN_MEMBER(cultures_interrupt);
6061};
6162
6263
r17996r17997
362363   GFXDECODE_ENTRY("gfx3", 0, gfxlayout, 0x1000, 0x10 )
363364GFXDECODE_END
364365
365static INTERRUPT_GEN( cultures_interrupt )
366INTERRUPT_GEN_MEMBER(cultures_state::cultures_interrupt)
366367{
367   cultures_state *state = device->machine().driver_data<cultures_state>();
368   if (state->m_irq_enable)
369      device->execute().set_input_line(0, HOLD_LINE);
368   if (m_irq_enable)
369      device.execute().set_input_line(0, HOLD_LINE);
370370}
371371
372372void cultures_state::machine_start()
r17996r17997
398398   MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 8.000 MHz */
399399   MCFG_CPU_PROGRAM_MAP(cultures_map)
400400   MCFG_CPU_IO_MAP(cultures_io_map)
401   MCFG_CPU_VBLANK_INT("screen", cultures_interrupt)
401   MCFG_CPU_VBLANK_INT_DRIVER("screen", cultures_state, cultures_interrupt)
402402
403403
404404   /* video hardware */
trunk/src/mame/drivers/5clown.c
r17996r17997
10651065   /* basic machine hardware */
10661066   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/8)   /* guess, seems ok */
10671067   MCFG_CPU_PROGRAM_MAP(fclown_map)
1068   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1068   MCFG_CPU_VBLANK_INT_DRIVER("screen", _5clown_state, nmi_line_pulse)
10691069
10701070   MCFG_CPU_ADD("audiocpu", M6502, MASTER_CLOCK/8)   /* guess, seems ok */
10711071   MCFG_CPU_PROGRAM_MAP(fcaudio_map)
trunk/src/mame/drivers/tgtpanic.c
r17996r17997
134134   MCFG_CPU_ADD("maincpu", Z80, XTAL_4MHz)
135135   MCFG_CPU_PROGRAM_MAP(prg_map)
136136   MCFG_CPU_IO_MAP(io_map)
137   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 20) /* Unverified */
137   MCFG_CPU_PERIODIC_INT_DRIVER(tgtpanic_state, irq0_line_hold, 20) /* Unverified */
138138
139139   /* video hardware */
140140   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/exedexes.c
r17996r17997
232232
233233   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   /* 3 MHz ??? */
234234   MCFG_CPU_PROGRAM_MAP(sound_map)
235   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
235   MCFG_CPU_PERIODIC_INT_DRIVER(exedexes_state, irq0_line_hold, 4*60)
236236
237237
238238   /* video hardware */
trunk/src/mame/drivers/seta2.c
r17996r17997
20062006
20072007***************************************************************************/
20082008
2009static INTERRUPT_GEN( seta2_interrupt )
2009INTERRUPT_GEN_MEMBER(seta2_state::seta2_interrupt)
20102010{
20112011   /* VBlank is connected to INT0 (external interrupts pin 0) */
2012   tmp68301_external_interrupt_0(device->machine());
2012   tmp68301_external_interrupt_0(machine());
20132013}
20142014
2015static INTERRUPT_GEN( samshoot_interrupt )
2015INTERRUPT_GEN_MEMBER(seta2_state::samshoot_interrupt)
20162016{
2017   tmp68301_external_interrupt_2(device->machine());   // to do: hook up x1-10 interrupts
2017   tmp68301_external_interrupt_2(machine());   // to do: hook up x1-10 interrupts
20182018}
20192019
20202020static const x1_010_interface x1_010_sound_intf =
r17996r17997
20252025static MACHINE_CONFIG_START( seta2, seta2_state )
20262026   MCFG_CPU_ADD("maincpu", M68301, XTAL_50MHz/3)   // !! TMP68301 !!
20272027   MCFG_CPU_PROGRAM_MAP(mj4simai_map)
2028   MCFG_CPU_VBLANK_INT("screen", seta2_interrupt)
2028   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta2_state, seta2_interrupt)
20292029
20302030   MCFG_MACHINE_START( tmp68301 )
20312031   MCFG_MACHINE_RESET( tmp68301 )
r17996r17997
21482148static MACHINE_CONFIG_DERIVED( samshoot, seta2 )
21492149   MCFG_CPU_MODIFY("maincpu")
21502150   MCFG_CPU_PROGRAM_MAP(samshoot_map)
2151   MCFG_CPU_PERIODIC_INT(samshoot_interrupt,60)
2151   MCFG_CPU_PERIODIC_INT_DRIVER(seta2_state, samshoot_interrupt, 60)
21522152
21532153   MCFG_NVRAM_ADD_0FILL("nvram")
21542154
r17996r17997
21742174      state->m_maincpu->set_input_line(2, HOLD_LINE);
21752175}
21762176
2177static INTERRUPT_GEN( funcube_sub_timer_irq )
2177INTERRUPT_GEN_MEMBER(seta2_state::funcube_sub_timer_irq)
21782178{
2179   seta2_state *state = device->machine().driver_data<seta2_state>();
21802179
2181   if ( state->m_funcube_serial_count )
2180   if ( m_funcube_serial_count )
21822181   {
2183      device->execute().set_input_line(H8_SCI_1_RX, HOLD_LINE);
2182      device.execute().set_input_line(H8_SCI_1_RX, HOLD_LINE);
21842183   }
21852184   else
21862185   {
2187      UINT8 press   = device->machine().root_device().ioport("TOUCH_PRESS")->read();
2188      UINT8 release = state->m_funcube_press && !press;
2186      UINT8 press   = machine().root_device().ioport("TOUCH_PRESS")->read();
2187      UINT8 release = m_funcube_press && !press;
21892188
21902189      if ( press || release )
21912190      {
2192         state->m_funcube_serial_fifo[0] = press ? 0xfe : 0xfd;
2193         state->m_funcube_serial_fifo[1] = device->machine().root_device().ioport("TOUCH_X")->read();
2194         state->m_funcube_serial_fifo[2] = device->machine().root_device().ioport("TOUCH_Y")->read();
2195         state->m_funcube_serial_fifo[3] = 0xff;
2196         state->m_funcube_serial_count = 4;
2191         m_funcube_serial_fifo[0] = press ? 0xfe : 0xfd;
2192         m_funcube_serial_fifo[1] = machine().root_device().ioport("TOUCH_X")->read();
2193         m_funcube_serial_fifo[2] = machine().root_device().ioport("TOUCH_Y")->read();
2194         m_funcube_serial_fifo[3] = 0xff;
2195         m_funcube_serial_count = 4;
21972196      }
21982197
2199      state->m_funcube_press = press;
2198      m_funcube_press = press;
22002199   }
22012200
2202   device->execute().set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
2201   device.execute().set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
22032202}
22042203
22052204MACHINE_RESET_MEMBER(seta2_state,funcube)
r17996r17997
22192218   MCFG_CPU_ADD("sub", H83007, FUNCUBE_SUB_CPU_CLOCK)
22202219   MCFG_CPU_PROGRAM_MAP(funcube_sub_map)
22212220   MCFG_CPU_IO_MAP(funcube_sub_io)
2222   MCFG_CPU_PERIODIC_INT(funcube_sub_timer_irq, 60*10 )
2221   MCFG_CPU_PERIODIC_INT_DRIVER(seta2_state, funcube_sub_timer_irq, 60*10)
22232222
22242223   MCFG_NVRAM_ADD_0FILL("nvram")
22252224
r17996r17997
22712270static MACHINE_CONFIG_START( namcostr, seta2_state )
22722271   MCFG_CPU_ADD("maincpu", M68301, XTAL_50MHz/3)   // !! TMP68301 !!
22732272   MCFG_CPU_PROGRAM_MAP(namcostr_map)
2274   MCFG_CPU_VBLANK_INT("screen", seta2_interrupt)
2273   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta2_state, seta2_interrupt)
22752274
22762275   MCFG_MACHINE_START( tmp68301 )
22772276   MCFG_MACHINE_RESET( tmp68301 )
trunk/src/mame/drivers/flkatck.c
r17996r17997
2020#include "includes/flkatck.h"
2121
2222
23static INTERRUPT_GEN( flkatck_interrupt )
23INTERRUPT_GEN_MEMBER(flkatck_state::flkatck_interrupt)
2424{
25   flkatck_state *state = device->machine().driver_data<flkatck_state>();
2625
27   if (state->m_irq_enabled)
28      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
26   if (m_irq_enabled)
27      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
2928}
3029
3130WRITE8_MEMBER(flkatck_state::flkatck_bankswitch_w)
r17996r17997
222221   /* basic machine hardware */
223222   MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP, 24/8 MHz */
224223   MCFG_CPU_PROGRAM_MAP(flkatck_map)
225   MCFG_CPU_VBLANK_INT("screen", flkatck_interrupt)
224   MCFG_CPU_VBLANK_INT_DRIVER("screen", flkatck_state, flkatck_interrupt)
226225
227226   MCFG_CPU_ADD("audiocpu", Z80,3579545)   /* NEC D780C-1, 3.579545 MHz */
228227   MCFG_CPU_PROGRAM_MAP(flkatck_sound_map)
trunk/src/mame/drivers/contra.c
r17996r17997
2525#include "includes/contra.h"
2626
2727
28static INTERRUPT_GEN( contra_interrupt )
28INTERRUPT_GEN_MEMBER(contra_state::contra_interrupt)
2929{
30   contra_state *state = device->machine().driver_data<contra_state>();
31   address_space &space = state->generic_space();
32   if (k007121_ctrlram_r(state->m_k007121_1, space, 7) & 0x02)
33      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
30   address_space &space = generic_space();
31   if (k007121_ctrlram_r(m_k007121_1, space, 7) & 0x02)
32      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
3433}
3534
3635WRITE8_MEMBER(contra_state::contra_bankswitch_w)
r17996r17997
192191   /* basic machine hardware */
193192   MCFG_CPU_ADD("maincpu", HD6309, XTAL_24MHz / 2 /* 3000000*4? */)
194193   MCFG_CPU_PROGRAM_MAP(contra_map)
195   MCFG_CPU_VBLANK_INT("screen", contra_interrupt)
194   MCFG_CPU_VBLANK_INT_DRIVER("screen", contra_state, contra_interrupt)
196195
197196   MCFG_CPU_ADD("audiocpu", M6809, XTAL_24MHz/8) /* 3000000? */
198197   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/zn.c
r17996r17997
117117   DECLARE_MACHINE_RESET(coh1001l);
118118   DECLARE_MACHINE_RESET(coh1002v);
119119   DECLARE_MACHINE_RESET(coh1002m);
120   INTERRUPT_GEN_MEMBER(qsound_interrupt);
120121};
121122
122123INLINE void ATTR_PRINTF(3,4) verboselog( running_machine &machine, int n_level, const char *s_fmt, ... )
r17996r17997
719720   membank( "bank10" )->set_base( memregion( "audiocpu" )->base() + 0x10000 + ( ( data & 0x0f ) * 0x4000 ) );
720721}
721722
722static INTERRUPT_GEN( qsound_interrupt )
723INTERRUPT_GEN_MEMBER(zn_state::qsound_interrupt)
723724{
724   device->execute().set_input_line(0, HOLD_LINE);
725   device.execute().set_input_line(0, HOLD_LINE);
725726}
726727
727728WRITE32_MEMBER(zn_state::zn_qsound_w)
r17996r17997
779780   MCFG_CPU_ADD( "audiocpu", Z80, 8000000 )  /* 8MHz ?? */
780781   MCFG_CPU_PROGRAM_MAP( qsound_map)
781782   MCFG_CPU_IO_MAP( qsound_portmap)
782   MCFG_CPU_PERIODIC_INT( qsound_interrupt, 60*4 ) /* 4 interrupts per frame ?? */
783   MCFG_CPU_PERIODIC_INT_DRIVER(zn_state, qsound_interrupt, 60*4) /* 4 interrupts per frame ?? */
783784
784785   MCFG_MACHINE_RESET_OVERRIDE(zn_state, coh1000c )
785786
r17996r17997
793794   MCFG_CPU_ADD( "audiocpu", Z80, 8000000 )  /* 8MHz ?? */
794795   MCFG_CPU_PROGRAM_MAP( qsound_map)
795796   MCFG_CPU_IO_MAP( qsound_portmap)
796   MCFG_CPU_PERIODIC_INT( qsound_interrupt, 60*4 ) /* 4 interrupts per frame ?? */
797   MCFG_CPU_PERIODIC_INT_DRIVER(zn_state, qsound_interrupt, 60*4) /* 4 interrupts per frame ?? */
797798
798799   MCFG_MACHINE_RESET_OVERRIDE(zn_state, coh1000c )
799800
r17996r17997
973974   MCFG_CPU_ADD("audiocpu", Z80, 8000000 )   /* 8MHz ?? */
974975   MCFG_CPU_PROGRAM_MAP( qsound_map)
975976   MCFG_CPU_IO_MAP( qsound_portmap)
976   MCFG_CPU_PERIODIC_INT( qsound_interrupt, 60*4 ) /* 4 interrupts per frame ?? */
977   MCFG_CPU_PERIODIC_INT_DRIVER(zn_state, qsound_interrupt, 60*4) /* 4 interrupts per frame ?? */
977978
978979   MCFG_MACHINE_RESET_OVERRIDE(zn_state, coh3002c )
979980
trunk/src/mame/drivers/paradise.c
r17996r17997
692692
693693}
694694
695static INTERRUPT_GEN(paradise_irq)
695INTERRUPT_GEN_MEMBER(paradise_state::paradise_irq)
696696{
697   paradise_state *state = device->machine().driver_data<paradise_state>();
698697
699   if (state->irq_count<300)
700      state->irq_count++;
698   if (irq_count<300)
699      irq_count++;
701700   else
702      device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_IRQ0, HOLD_LINE);
701      machine().device("maincpu")->execute().set_input_line(INPUT_LINE_IRQ0, HOLD_LINE);
703702}
704703
705704static MACHINE_CONFIG_START( paradise, paradise_state )
r17996r17997
708707   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)         /* Z8400B - 6mhz Verified */
709708   MCFG_CPU_PROGRAM_MAP(paradise_map)
710709   MCFG_CPU_IO_MAP(paradise_io_map)
711   MCFG_CPU_PERIODIC_INT(paradise_irq,4*54)   /* No nmi routine, timing is confirmed (i.e. three timing irqs for each vblank irq */
710   MCFG_CPU_PERIODIC_INT_DRIVER(paradise_state, paradise_irq, 4*54)   /* No nmi routine, timing is confirmed (i.e. three timing irqs for each vblank irq */
712711
713712
714713   /* video hardware */
trunk/src/mame/drivers/balsente.c
r17996r17997
12021202   /* basic machine hardware */
12031203   MCFG_CPU_ADD("maincpu", M6809, XTAL_20MHz/16) /* xtal verified but not speed */
12041204   MCFG_CPU_PROGRAM_MAP(cpu1_map)
1205   MCFG_CPU_VBLANK_INT("screen", balsente_update_analog_inputs)
1205   MCFG_CPU_VBLANK_INT_DRIVER("screen", balsente_state, balsente_update_analog_inputs)
12061206
12071207   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* xtal verified but not speed */
12081208   MCFG_CPU_PROGRAM_MAP(cpu2_map)
trunk/src/mame/drivers/fitfight.c
r17996r17997
257257      AM_RANGE(UPD7810_PORTC, UPD7810_PORTC) AM_READ(snd_portc_r) AM_WRITE(snd_portc_w)
258258ADDRESS_MAP_END
259259
260static INTERRUPT_GEN( snd_irq )
260INTERRUPT_GEN_MEMBER(fitfight_state::snd_irq)
261261{
262   device->execute().set_input_line(UPD7810_INTF2, HOLD_LINE);
262   device.execute().set_input_line(UPD7810_INTF2, HOLD_LINE);
263263}
264264
265265static const UPD7810_CONFIG sound_cpu_config =
r17996r17997
735735
736736   MCFG_CPU_ADD("maincpu",M68000, 12000000)
737737   MCFG_CPU_PROGRAM_MAP(fitfight_main_map)
738   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
738   MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, irq2_line_hold)
739739
740740   MCFG_CPU_ADD("audiocpu", UPD7810, 12000000)
741741   MCFG_CPU_CONFIG(sound_cpu_config)
742742   MCFG_CPU_PROGRAM_MAP(snd_mem)
743743   MCFG_CPU_IO_MAP(snd_io)
744   MCFG_CPU_VBLANK_INT("screen", snd_irq)
744   MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, snd_irq)
745745
746746
747747   MCFG_GFXDECODE(fitfight)
r17996r17997
766766
767767   MCFG_CPU_ADD("maincpu",M68000, 12000000)
768768   MCFG_CPU_PROGRAM_MAP(bbprot_main_map)
769   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
769   MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, irq2_line_hold)
770770
771771
772772   MCFG_GFXDECODE(prot)
trunk/src/mame/drivers/terracre.c
r17996r17997
528528static MACHINE_CONFIG_START( amazon, terracre_state )
529529   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz
530530   MCFG_CPU_PROGRAM_MAP(amazon_map)
531   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
531   MCFG_CPU_VBLANK_INT_DRIVER("screen", terracre_state, irq1_line_hold)
532532
533533   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)      // 4mhz? should be derived from XTAL_22MHz? how?
534534   MCFG_CPU_PROGRAM_MAP(sound_map)
535535   MCFG_CPU_IO_MAP(sound_3526_io_map)
536   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_16MHz/4/512)   // ?
536   MCFG_CPU_PERIODIC_INT_DRIVER(terracre_state, irq0_line_hold, XTAL_16MHz/4/512)   // ?
537537
538538   MCFG_MACHINE_START_OVERRIDE(terracre_state,amazon)
539539
r17996r17997
563563static MACHINE_CONFIG_START( ym3526, terracre_state )
564564   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz
565565   MCFG_CPU_PROGRAM_MAP(terracre_map)
566   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
566   MCFG_CPU_VBLANK_INT_DRIVER("screen", terracre_state, irq1_line_hold)
567567
568568   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)      // 4.0mhz when compared to sound recordings, should be derived from XTAL_22MHz? how?
569569   MCFG_CPU_PROGRAM_MAP(sound_map)
570570   MCFG_CPU_IO_MAP(sound_3526_io_map)
571   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_16MHz/4/512)   // ?
571   MCFG_CPU_PERIODIC_INT_DRIVER(terracre_state, irq0_line_hold, XTAL_16MHz/4/512)   // ?
572572
573573   MCFG_SCREEN_ADD("screen", RASTER)
574574   MCFG_SCREEN_REFRESH_RATE( 60 )
r17996r17997
596596static MACHINE_CONFIG_START( ym2203, terracre_state )
597597   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz
598598   MCFG_CPU_PROGRAM_MAP(terracre_map)
599   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
599   MCFG_CPU_VBLANK_INT_DRIVER("screen", terracre_state, irq1_line_hold)
600600
601601   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)      // 4.0mhz when compared to sound recordings, should be derived from XTAL_22MHz? how?
602602   MCFG_CPU_PROGRAM_MAP(sound_map)
603603   MCFG_CPU_IO_MAP(sound_2203_io_map)
604   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_16MHz/4/512)   // ?
604   MCFG_CPU_PERIODIC_INT_DRIVER(terracre_state, irq0_line_hold, XTAL_16MHz/4/512)   // ?
605605
606606   MCFG_SCREEN_ADD("screen", RASTER)
607607   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/ddribble.c
r17996r17997
1818#include "includes/ddribble.h"
1919
2020
21static INTERRUPT_GEN( ddribble_interrupt_0 )
21INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_0)
2222{
23   ddribble_state *state = device->machine().driver_data<ddribble_state>();
24   if (state->m_int_enable_0)
25      device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
23   if (m_int_enable_0)
24      device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
2625}
2726
28static INTERRUPT_GEN( ddribble_interrupt_1 )
27INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_1)
2928{
30   ddribble_state *state = device->machine().driver_data<ddribble_state>();
31   if (state->m_int_enable_1)
32      device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
29   if (m_int_enable_1)
30      device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
3331}
3432
3533
r17996r17997
282280   /* basic machine hardware */
283281   MCFG_CPU_ADD("maincpu", M6809,   XTAL_18_432MHz/12)   /* verified on pcb */
284282   MCFG_CPU_PROGRAM_MAP(cpu0_map)
285   MCFG_CPU_VBLANK_INT("screen", ddribble_interrupt_0)
283   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_0)
286284
287285   MCFG_CPU_ADD("cpu1", M6809,   XTAL_18_432MHz/12)   /* verified on pcb */
288286   MCFG_CPU_PROGRAM_MAP(cpu1_map)
289   MCFG_CPU_VBLANK_INT("screen", ddribble_interrupt_1)
287   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_1)
290288
291289   MCFG_CPU_ADD("cpu2", M6809,   XTAL_18_432MHz/12)   /* verified on pcb */
292290   MCFG_CPU_PROGRAM_MAP(cpu2_map)
trunk/src/mame/drivers/deco32.c
r17996r17997
16711671   decoprot_reset(machine());
16721672}
16731673
1674static INTERRUPT_GEN( deco32_vbl_interrupt )
1674INTERRUPT_GEN_MEMBER(deco32_state::deco32_vbl_interrupt)
16751675{
1676   device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
1676   device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
16771677}
16781678
16791679UINT16 captaven_pri_callback(UINT16 x)
r17996r17997
17351735   /* basic machine hardware */
17361736   MCFG_CPU_ADD("maincpu", ARM, XTAL_28MHz/4) /* verified on pcb (Data East 101 custom)*/
17371737   MCFG_CPU_PROGRAM_MAP(captaven_map)
1738   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
1738   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
17391739
17401740   MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/4/3)  /* pin 10 is 32mhz/4, pin 14 is High so internal divisor is 3 (verified on pcb) */
17411741   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
17871787   /* basic machine hardware */
17881788   MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
17891789   MCFG_CPU_PROGRAM_MAP(fghthist_map)
1790   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
1790   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
17911791
17921792   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
17931793   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
18341834   /* basic machine hardware */
18351835   MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
18361836   MCFG_CPU_PROGRAM_MAP(fghthsta_memmap)
1837   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
1837   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
18381838
18391839   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
18401840   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
19431943   /* basic machine hardware */
19441944   MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
19451945   MCFG_CPU_PROGRAM_MAP(dragngun_map)
1946   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
1946   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
19471947
19481948   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
19491949   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
21102110   /* basic machine hardware */
21112111   MCFG_CPU_ADD("maincpu", ARM, 28000000/*/4*/) /* Unconfirmed - the divider makes it far too slow, due to inaccurate core timings? */
21122112   MCFG_CPU_PROGRAM_MAP(tattass_map)
2113   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
2113   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
21142114
21152115   MCFG_EEPROM_ADD("eeprom", eeprom_interface_tattass)
21162116
r17996r17997
21442144   /* basic machine hardware */
21452145   MCFG_CPU_ADD("maincpu", ARM, 28322000/4)
21462146   MCFG_CPU_PROGRAM_MAP(nslasher_map)
2147   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
2147   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
21482148
21492149   MCFG_CPU_ADD("audiocpu", Z80, 32220000/9)
21502150   MCFG_CPU_PROGRAM_MAP(nslasher_sound)
trunk/src/mame/drivers/vertigo.c
r17996r17997
125125   /* basic machine hardware */
126126   MCFG_CPU_ADD("maincpu", M68000, 8000000)
127127   MCFG_CPU_PROGRAM_MAP(vertigo_map)
128   MCFG_CPU_PERIODIC_INT(vertigo_interrupt,60)
128   MCFG_CPU_PERIODIC_INT_DRIVER(vertigo_state, vertigo_interrupt, 60)
129129
130130   MCFG_FRAGMENT_ADD(exidy440_audio)
131131
trunk/src/mame/drivers/midzeus.c
r17996r17997
111111   machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
112112}
113113
114static INTERRUPT_GEN( display_irq )
114INTERRUPT_GEN_MEMBER(midzeus_state::display_irq)
115115{
116   device->execute().set_input_line(0, ASSERT_LINE);
117   device->machine().scheduler().timer_set(attotime::from_hz(30000000), FUNC(display_irq_off));
116   device.execute().set_input_line(0, ASSERT_LINE);
117   machine().scheduler().timer_set(attotime::from_hz(30000000), FUNC(display_irq_off));
118118}
119119
120120
r17996r17997
10911091   /* basic machine hardware */
10921092   MCFG_CPU_ADD("maincpu", TMS32032, CPU_CLOCK)
10931093   MCFG_CPU_PROGRAM_MAP(zeus_map)
1094   MCFG_CPU_VBLANK_INT("screen", display_irq)
1094   MCFG_CPU_VBLANK_INT_DRIVER("screen", midzeus_state, display_irq)
10951095
10961096   MCFG_MACHINE_START_OVERRIDE(midzeus_state,midzeus)
10971097   MCFG_MACHINE_RESET_OVERRIDE(midzeus_state,midzeus)
r17996r17997
11311131   /* basic machine hardware */
11321132   MCFG_CPU_ADD("maincpu", TMS32032, CPU_CLOCK)
11331133   MCFG_CPU_PROGRAM_MAP(zeus2_map)
1134   MCFG_CPU_VBLANK_INT("screen", display_irq)
1134   MCFG_CPU_VBLANK_INT_DRIVER("screen", midzeus_state, display_irq)
11351135
11361136   MCFG_MACHINE_START_OVERRIDE(midzeus_state,midzeus)
11371137   MCFG_MACHINE_RESET_OVERRIDE(midzeus_state,midzeus)
trunk/src/mame/drivers/drw80pkr.c
r17996r17997
467467   MCFG_CPU_ADD("maincpu", I8039, CPU_CLOCK)
468468   MCFG_CPU_PROGRAM_MAP(drw80pkr_map)
469469    MCFG_CPU_IO_MAP(drw80pkr_io_map)
470   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
470   MCFG_CPU_VBLANK_INT_DRIVER("screen", drw80pkr_state, irq0_line_hold)
471471
472472
473473   // video hardware
trunk/src/mame/drivers/superdq.c
r17996r17997
5252   virtual void video_start();
5353   virtual void palette_init();
5454   UINT32 screen_update_superdq(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
55   INTERRUPT_GEN_MEMBER(superdq_vblank);
5556};
5657
5758TILE_GET_INFO_MEMBER(superdq_state::get_tile_info)
r17996r17997
131132   m_color_bank = 0;
132133}
133134
134static INTERRUPT_GEN( superdq_vblank )
135INTERRUPT_GEN_MEMBER(superdq_state::superdq_vblank)
135136{
136   superdq_state *state = device->machine().driver_data<superdq_state>();
137137
138138   /* status is read when the STATUS line from the laserdisc
139139       toggles (600usec after the vblank). We could set up a
140140       timer to do that, but this works as well */
141   state->m_ld_in_latch = state->m_laserdisc->status_r();
141   m_ld_in_latch = m_laserdisc->status_r();
142142
143143   /* command is written when the COMMAND line from the laserdisc
144144       toggles (680usec after the vblank). We could set up a
145145       timer to do that, but this works as well */
146   state->m_laserdisc->data_w(state->m_ld_out_latch);
147   device->execute().set_input_line(0, ASSERT_LINE);
146   m_laserdisc->data_w(m_ld_out_latch);
147   device.execute().set_input_line(0, ASSERT_LINE);
148148}
149149
150150WRITE8_MEMBER(superdq_state::superdq_videoram_w)
r17996r17997
345345   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/8)
346346   MCFG_CPU_PROGRAM_MAP(superdq_map)
347347   MCFG_CPU_IO_MAP(superdq_io)
348   MCFG_CPU_VBLANK_INT("screen", superdq_vblank)
348   MCFG_CPU_VBLANK_INT_DRIVER("screen", superdq_state, superdq_vblank)
349349
350350
351351   MCFG_LASERDISC_LDV1000_ADD("laserdisc")
trunk/src/mame/drivers/bestleag.c
r17996r17997
365365static MACHINE_CONFIG_START( bestleag, bestleag_state )
366366   MCFG_CPU_ADD("maincpu", M68000, 12000000)
367367   MCFG_CPU_PROGRAM_MAP(bestleag_map)
368   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
368   MCFG_CPU_VBLANK_INT_DRIVER("screen", bestleag_state, irq6_line_hold)
369369
370370   MCFG_SCREEN_ADD("screen", RASTER)
371371   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/tomcat.c
r17996r17997
397397static MACHINE_CONFIG_START( tomcat, tomcat_state )
398398   MCFG_CPU_ADD("maincpu", M68010, XTAL_12MHz / 2)
399399   MCFG_CPU_PROGRAM_MAP(tomcat_map)
400   MCFG_CPU_PERIODIC_INT(irq1_line_assert, 5*60)
401   //MCFG_CPU_PERIODIC_INT(irq1_line_assert, (double)XTAL_12MHz / 16 / 16 / 16 / 12)
400   MCFG_CPU_PERIODIC_INT_DRIVER(tomcat_state, irq1_line_assert,  5*60)
401   //MCFG_CPU_PERIODIC_INT_DRIVER(tomcat_state, irq1_line_assert,  (double)XTAL_12MHz / 16 / 16 / 16 / 12)
402402
403403   MCFG_CPU_ADD("dsp", TMS32010, XTAL_16MHz)
404404   MCFG_CPU_PROGRAM_MAP( dsp_map)
trunk/src/mame/drivers/zaxxon.c
r17996r17997
297297}
298298
299299
300static INTERRUPT_GEN( vblank_int )
300INTERRUPT_GEN_MEMBER(zaxxon_state::vblank_int)
301301{
302   zaxxon_state *state = device->machine().driver_data<zaxxon_state>();
303302
304   if (state->m_int_enabled)
305      device->execute().set_input_line(0, ASSERT_LINE);
303   if (m_int_enabled)
304      device.execute().set_input_line(0, ASSERT_LINE);
306305}
307306
308307
r17996r17997
962961   /* basic machine hardware */
963962   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/16)
964963   MCFG_CPU_PROGRAM_MAP(zaxxon_map)
965   MCFG_CPU_VBLANK_INT("screen", vblank_int)
964   MCFG_CPU_VBLANK_INT_DRIVER("screen", zaxxon_state, vblank_int)
966965
967966
968967   MCFG_I8255A_ADD( "ppi8255", zaxxon_ppi_intf )
r17996r17997
10261025
10271026   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK)
10281027   MCFG_CPU_PROGRAM_MAP(congo_sound_map)
1029   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)SOUND_CLOCK/16/16/16/4)
1028   MCFG_CPU_PERIODIC_INT_DRIVER(zaxxon_state, irq0_line_hold, (double)SOUND_CLOCK/16/16/16/4)
10301029
10311030   /* video hardware */
10321031   MCFG_PALETTE_LENGTH(512)
trunk/src/mame/drivers/norautp.c
r17996r17997
12821282
12831283   /* basic machine hardware */
12841284   MCFG_CPU_MODIFY("maincpu")
1285   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1285   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
12861286MACHINE_CONFIG_END
12871287
12881288
r17996r17997
12901290
12911291   /* basic machine hardware */
12921292   MCFG_CPU_MODIFY("maincpu")
1293   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1293   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
12941294
12951295   /* sound hardware */
12961296   MCFG_SOUND_MODIFY("discrete")
r17996r17997
13031303   /* basic machine hardware */
13041304   MCFG_CPU_MODIFY("maincpu")
13051305   MCFG_CPU_PROGRAM_MAP(norautxp_map)
1306   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1306   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13071307MACHINE_CONFIG_END
13081308
13091309
r17996r17997
13121312   /* basic machine hardware */
13131313   MCFG_CPU_MODIFY("maincpu")
13141314   MCFG_CPU_PROGRAM_MAP(nortest1_map)
1315   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1315   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13161316MACHINE_CONFIG_END
13171317
13181318
r17996r17997
13211321   /* basic machine hardware */
13221322   MCFG_CPU_MODIFY("maincpu")
13231323   MCFG_CPU_PROGRAM_MAP(norautx4_map)
1324   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1324   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13251325MACHINE_CONFIG_END
13261326
13271327
r17996r17997
13311331   /* basic machine hardware */
13321332   MCFG_CPU_MODIFY("maincpu")
13331333   MCFG_CPU_PROGRAM_MAP(norautx8_map)
1334   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1334   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13351335MACHINE_CONFIG_END
13361336#endif
13371337
r17996r17997
13411341   /* basic machine hardware */
13421342   MCFG_CPU_MODIFY("maincpu")
13431343   MCFG_CPU_PROGRAM_MAP(kimble_map)
1344   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1344   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13451345
13461346   /* sound hardware */
13471347   MCFG_SOUND_MODIFY("discrete")
r17996r17997
13541354   MCFG_CPU_MODIFY("maincpu")
13551355   MCFG_CPU_PROGRAM_MAP(newhilop_map)
13561356//  MCFG_CPU_IO_MAP(newhilop_portmap)
1357   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1357   MCFG_CPU_VBLANK_INT_DRIVER("screen", norautp_state, irq0_line_hold)
13581358MACHINE_CONFIG_END
13591359
13601360/********** 8080 based **********/
trunk/src/mame/drivers/shangkid.c
r17996r17997
363363   /* basic machine hardware */
364364   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6) /* verified on pcb */
365365   MCFG_CPU_PROGRAM_MAP(chinhero_main_map)
366   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
366   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangkid_state, irq0_line_hold)
367367
368368   MCFG_CPU_ADD("bbx", Z80, XTAL_18_432MHz/6) /* verified on pcb */
369369   MCFG_CPU_PROGRAM_MAP(chinhero_bbx_map)
370370   MCFG_CPU_IO_MAP(chinhero_bbx_portmap)
371   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
371   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangkid_state, irq0_line_hold)
372372
373373   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6) /* verified on pcb */
374374   MCFG_CPU_PROGRAM_MAP(chinhero_sound_map)
r17996r17997
455455   MCFG_CPU_ADD("maincpu", Z80, 3000000) /* ? */
456456   MCFG_CPU_PROGRAM_MAP(dynamski_map)
457457   MCFG_CPU_IO_MAP(dynamski_portmap)
458   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
458   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangkid_state, irq0_line_hold)
459459
460460   /* video hardware */
461461   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/fastfred.c
r17996r17997
626626
627627#define CLOCK 18432000  /* The crystal is 18.432MHz */
628628
629static INTERRUPT_GEN( vblank_irq )
629INTERRUPT_GEN_MEMBER(fastfred_state::vblank_irq)
630630{
631   fastfred_state *state = device->machine().driver_data<fastfred_state>();
632631
633   if(state->m_nmi_mask)
634      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
632   if(m_nmi_mask)
633      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
635634}
636635
637static INTERRUPT_GEN( sound_timer_irq )
636INTERRUPT_GEN_MEMBER(fastfred_state::sound_timer_irq)
638637{
639   fastfred_state *state = device->machine().driver_data<fastfred_state>();
640638
641   if(state->m_sound_nmi_mask)
642      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
639   if(m_sound_nmi_mask)
640      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
643641}
644642
645643static MACHINE_CONFIG_START( fastfred, fastfred_state )
r17996r17997
647645   /* basic machine hardware */
648646   MCFG_CPU_ADD("maincpu", Z80, CLOCK/6)     /* 3.072 MHz */
649647   MCFG_CPU_PROGRAM_MAP(fastfred_map)
650   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
648   MCFG_CPU_VBLANK_INT_DRIVER("screen", fastfred_state, vblank_irq)
651649
652650   MCFG_CPU_ADD("audiocpu", Z80, CLOCK/12)    /* 1.536 MHz */
653651   MCFG_CPU_PROGRAM_MAP(sound_map)
654   MCFG_CPU_PERIODIC_INT(sound_timer_irq,4*60)
652   MCFG_CPU_PERIODIC_INT_DRIVER(fastfred_state, sound_timer_irq, 4*60)
655653
656654   /* video hardware */
657655   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/karnov.c
r17996r17997
725725 *
726726 *************************************/
727727
728static INTERRUPT_GEN( karnov_interrupt )
728INTERRUPT_GEN_MEMBER(karnov_state::karnov_interrupt)
729729{
730   karnov_state *state = device->machine().driver_data<karnov_state>();
731   UINT8 port = state->ioport("FAKE")->read();
730   UINT8 port = ioport("FAKE")->read();
732731
733732   /* Coin input to the i8751 generates an interrupt to the main cpu */
734   if (port == state->m_coin_mask)
735      state->m_latch = 1;
733   if (port == m_coin_mask)
734      m_latch = 1;
736735
737   if (port != state->m_coin_mask && state->m_latch)
736   if (port != m_coin_mask && m_latch)
738737   {
739      if (state->m_i8751_needs_ack)
738      if (m_i8751_needs_ack)
740739      {
741740         /* i8751 is busy - queue the command */
742         state->m_i8751_coin_pending = port | 0x8000;
741         m_i8751_coin_pending = port | 0x8000;
743742      }
744743      else
745744      {
746         state->m_i8751_return = port | 0x8000;
747         device->execute().set_input_line(6, HOLD_LINE);
748         state->m_i8751_needs_ack = 1;
745         m_i8751_return = port | 0x8000;
746         device.execute().set_input_line(6, HOLD_LINE);
747         m_i8751_needs_ack = 1;
749748      }
750749
751      state->m_latch = 0;
750      m_latch = 0;
752751   }
753752
754   device->execute().set_input_line(7, HOLD_LINE);   /* VBL */
753   device.execute().set_input_line(7, HOLD_LINE);   /* VBL */
755754}
756755
757756static const ym3526_interface ym3526_config =
r17996r17997
806805   /* basic machine hardware */
807806   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10 MHz */
808807   MCFG_CPU_PROGRAM_MAP(karnov_map)
809   MCFG_CPU_VBLANK_INT("screen", karnov_interrupt)
808   MCFG_CPU_VBLANK_INT_DRIVER("screen", karnov_state, karnov_interrupt)
810809
811810   MCFG_CPU_ADD("audiocpu", M6502, 1500000)   /* Accurate */
812811   MCFG_CPU_PROGRAM_MAP(karnov_sound_map)
r17996r17997
847846   /* basic machine hardware */
848847   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10 MHz */
849848   MCFG_CPU_PROGRAM_MAP(karnov_map)
850   MCFG_CPU_VBLANK_INT("screen", karnov_interrupt)
849   MCFG_CPU_VBLANK_INT_DRIVER("screen", karnov_state, karnov_interrupt)
851850
852851   MCFG_CPU_ADD("audiocpu", M6502, 1500000)   /* Accurate */
853852   MCFG_CPU_PROGRAM_MAP(karnov_sound_map)
trunk/src/mame/drivers/xtheball.c
r17996r17997
338338   MCFG_CPU_ADD("maincpu", TMS34010, 40000000)
339339   MCFG_CPU_CONFIG(tms_config)
340340   MCFG_CPU_PROGRAM_MAP(main_map)
341   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 15000)
341   MCFG_CPU_PERIODIC_INT_DRIVER(xtheball_state, irq1_line_hold, 15000)
342342
343343   MCFG_NVRAM_ADD_1FILL("nvram")
344344
trunk/src/mame/drivers/lwings.c
r17996r17997
8787   coin_counter_w(machine(), 0, data & 0x80);
8888}
8989
90static INTERRUPT_GEN( lwings_interrupt )
90INTERRUPT_GEN_MEMBER(lwings_state::lwings_interrupt)
9191{
92   lwings_state *state = device->machine().driver_data<lwings_state>();
9392
94   if(state->m_nmi_mask)
95      device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
93   if(m_nmi_mask)
94      device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
9695}
9796
98static INTERRUPT_GEN( avengers_interrupt )
97INTERRUPT_GEN_MEMBER(lwings_state::avengers_interrupt)
9998{
100   lwings_state *state = device->machine().driver_data<lwings_state>();
10199
102   if(state->m_nmi_mask)
103      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
100   if(m_nmi_mask)
101      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
104102}
105103
106104
r17996r17997
783781   /* basic machine hardware */
784782   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)   /* verified on PCB */
785783   MCFG_CPU_PROGRAM_MAP(lwings_map)
786   MCFG_CPU_VBLANK_INT("screen", lwings_interrupt)
784   MCFG_CPU_VBLANK_INT_DRIVER("screen", lwings_state, lwings_interrupt)
787785
788786   MCFG_CPU_ADD("soundcpu", Z80, XTAL_12MHz/4)   /* verified on PCB */
789787   MCFG_CPU_PROGRAM_MAP(lwings_sound_map)
790   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* ??? */
788   MCFG_CPU_PERIODIC_INT_DRIVER(lwings_state, irq0_line_hold, 4*60)   /* ??? */
791789
792790
793791   /* video hardware */
r17996r17997
834832   MCFG_CPU_ADD("adpcm", Z80, XTAL_12MHz/4)   /* verified on PCB */
835833   MCFG_CPU_PROGRAM_MAP(trojan_adpcm_map)
836834   MCFG_CPU_IO_MAP(trojan_adpcm_io_map)
837   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4000)
835   MCFG_CPU_PERIODIC_INT_DRIVER(lwings_state, irq0_line_hold, 4000)
838836
839837   /* video hardware */
840838   MCFG_GFXDECODE(trojan)
r17996r17997
853851
854852   MCFG_CPU_MODIFY("maincpu") //AT: (avengers37b16gre)
855853   MCFG_CPU_PROGRAM_MAP(avengers_map)
856   MCFG_CPU_VBLANK_INT("screen", avengers_interrupt) // RST 38h triggered by software
854   MCFG_CPU_VBLANK_INT_DRIVER("screen", lwings_state, avengers_interrupt) // RST 38h triggered by software
857855
858856   MCFG_CPU_MODIFY("adpcm")
859857   MCFG_CPU_IO_MAP(avengers_adpcm_io_map)
trunk/src/mame/drivers/punchout.c
r17996r17997
928928   memset(m_rp5c01_mem, 0, sizeof(m_rp5c01_mem));
929929}
930930
931static INTERRUPT_GEN( vblank_irq )
931INTERRUPT_GEN_MEMBER(punchout_state::vblank_irq)
932932{
933   punchout_state *state = device->machine().driver_data<punchout_state>();
934933
935   if(state->m_nmi_mask)
936      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
934   if(m_nmi_mask)
935      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
937936}
938937
939938
r17996r17997
944943   MCFG_CPU_ADD("maincpu", Z80, 8000000/2)   /* 4 MHz */
945944   MCFG_CPU_PROGRAM_MAP(punchout_map)
946945   MCFG_CPU_IO_MAP(punchout_io_map)
947   MCFG_CPU_VBLANK_INT("top", vblank_irq)
946   MCFG_CPU_VBLANK_INT_DRIVER("top", punchout_state, vblank_irq)
948947
949948   MCFG_CPU_ADD("audiocpu", N2A03, N2A03_DEFAULTCLOCK)
950949   MCFG_CPU_PROGRAM_MAP(punchout_sound_map)
951   MCFG_CPU_VBLANK_INT("top", nmi_line_pulse)
950   MCFG_CPU_VBLANK_INT_DRIVER("top", punchout_state, nmi_line_pulse)
952951
953952   MCFG_NVRAM_ADD_0FILL("nvram")
954953
trunk/src/mame/drivers/kopunch.c
r17996r17997
88#include "cpu/i8085/i8085.h"
99#include "includes/kopunch.h"
1010
11static INTERRUPT_GEN( kopunch_interrupt )
11INTERRUPT_GEN_MEMBER(kopunch_state::kopunch_interrupt)
1212{
13   device->execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
14   device->execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
13   device.execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
14   device.execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
1515}
1616
1717READ8_MEMBER(kopunch_state::kopunch_in_r)
r17996r17997
189189   MCFG_CPU_ADD("maincpu", I8085A, 4000000)   /* 4 MHz ???? Uses SIM, must be 8085 */
190190   MCFG_CPU_PROGRAM_MAP(kopunch_map)
191191   MCFG_CPU_IO_MAP(kopunch_io_map)
192   MCFG_CPU_VBLANK_INT("screen",kopunch_interrupt)
192   MCFG_CPU_VBLANK_INT_DRIVER("screen", kopunch_state, kopunch_interrupt)
193193
194194
195195   /* video hardware */
trunk/src/mame/drivers/news.c
r17996r17997
130130   /* basic machine hardware */
131131   MCFG_CPU_ADD("maincpu", Z80,8000000)       /* ? MHz */
132132   MCFG_CPU_PROGRAM_MAP(news_map)
133   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
133   MCFG_CPU_VBLANK_INT_DRIVER("screen", news_state, irq0_line_hold)
134134
135135
136136   /* video hardware */
trunk/src/mame/drivers/cclimber.c
r17996r17997
973973   GFXDECODE_ENTRY( "gfx3", 0x0000, cclimber_charlayout,   24*4, 16 )
974974GFXDECODE_END
975975
976static INTERRUPT_GEN( vblank_irq )
976INTERRUPT_GEN_MEMBER(cclimber_state::vblank_irq)
977977{
978   cclimber_state *state = device->machine().driver_data<cclimber_state>();
979978
980   if(state->m_nmi_mask)
981      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
979   if(m_nmi_mask)
980      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
982981}
983982
984983static MACHINE_CONFIG_START( root, cclimber_state )
r17996r17997
987986   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/3/2)   /* 3.072 MHz */
988987   MCFG_CPU_PROGRAM_MAP(cclimber_map)
989988   MCFG_CPU_IO_MAP(cclimber_portmap)
990   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
989   MCFG_CPU_VBLANK_INT_DRIVER("screen", cclimber_state, vblank_irq)
991990
992991   MCFG_MACHINE_RESET_OVERRIDE(cclimber_state,cclimber)
993992
r17996r17997
10821081   /* basic machine hardware */
10831082    MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)    /* verified on pcb */
10841083   MCFG_CPU_PROGRAM_MAP(swimmer_map)
1085   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1084   MCFG_CPU_VBLANK_INT_DRIVER("screen", cclimber_state, vblank_irq)
10861085
10871086    MCFG_CPU_ADD("audiocpu", Z80,XTAL_4MHz/2)  /* verified on pcb */
10881087   MCFG_CPU_PROGRAM_MAP(swimmer_audio_map)
10891088   MCFG_CPU_IO_MAP(swimmer_audio_portmap)
1090   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, (double)4000000/16384) /* IRQs are triggered by the main CPU */
1089   MCFG_CPU_PERIODIC_INT_DRIVER(cclimber_state, nmi_line_pulse, (double)4000000/16384) /* IRQs are triggered by the main CPU */
10911090
10921091   /* video hardware */
10931092   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/xorworld.c
r17996r17997
175175   // basic machine hardware
176176   MCFG_CPU_ADD("maincpu", M68000, 10000000)   // 10 MHz
177177   MCFG_CPU_PROGRAM_MAP(xorworld_map)
178   MCFG_CPU_VBLANK_INT("screen",irq6_line_assert) // irq 4 or 6
179   MCFG_CPU_PERIODIC_INT(irq2_line_assert,3*60) //timed irq, unknown timing
178   MCFG_CPU_VBLANK_INT_DRIVER("screen", xorworld_state, irq6_line_assert) // irq 4 or 6
179   MCFG_CPU_PERIODIC_INT_DRIVER(xorworld_state, irq2_line_assert, 3*60) //timed irq, unknown timing
180180
181181   MCFG_QUANTUM_TIME(attotime::from_hz(60))
182182
trunk/src/mame/drivers/cloak.c
r17996r17997
333333   /* basic machine hardware */
334334   MCFG_CPU_ADD("maincpu", M6502, 1000000)      /* 1 MHz ???? */
335335   MCFG_CPU_PROGRAM_MAP(master_map)
336   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
336   MCFG_CPU_PERIODIC_INT_DRIVER(cloak_state, irq0_line_hold, 4*60)
337337
338338   MCFG_CPU_ADD("slave", M6502, 1250000)      /* 1.25 MHz ???? */
339339   MCFG_CPU_PROGRAM_MAP(slave_map)
340   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
340   MCFG_CPU_PERIODIC_INT_DRIVER(cloak_state, irq0_line_hold, 2*60)
341341
342342   MCFG_QUANTUM_TIME(attotime::from_hz(1000))
343343
trunk/src/mame/drivers/cesclass.c
r17996r17997
245245
246246   MCFG_CPU_ADD("maincpu", M68000, 24000000/2 )
247247   MCFG_CPU_PROGRAM_MAP(cesclassic_map)
248   MCFG_CPU_VBLANK_INT("l_lcd", irq2_line_assert)  // TODO: unknown sources
249   MCFG_CPU_PERIODIC_INT(irq3_line_assert,60*8)
248   MCFG_CPU_VBLANK_INT_DRIVER("l_lcd", cesclassic_state,  irq2_line_assert)  // TODO: unknown sources
249   MCFG_CPU_PERIODIC_INT_DRIVER(cesclassic_state, irq3_line_assert, 60*8)
250250
251251   MCFG_NVRAM_ADD_0FILL("nvram")
252252
trunk/src/mame/drivers/skyraid.c
r17996r17997
220220   /* basic machine hardware */
221221   MCFG_CPU_ADD("maincpu", M6502, 12096000 / 12)
222222   MCFG_CPU_PROGRAM_MAP(skyraid_map)
223   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
223   MCFG_CPU_VBLANK_INT_DRIVER("screen", skyraid_state, irq0_line_hold)
224224   MCFG_WATCHDOG_VBLANK_INIT(4)
225225
226226   /* video hardware */
trunk/src/mame/drivers/aliens.c
r17996r17997
1919/* prototypes */
2020static KONAMI_SETLINES_CALLBACK( aliens_banking );
2121
22static INTERRUPT_GEN( aliens_interrupt )
22INTERRUPT_GEN_MEMBER(aliens_state::aliens_interrupt)
2323{
24   aliens_state *state = device->machine().driver_data<aliens_state>();
2524
26   if (k051960_is_irq_enabled(state->m_k051960))
27      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
25   if (k051960_is_irq_enabled(m_k051960))
26      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
2827}
2928
3029READ8_MEMBER(aliens_state::bankedram_r)
r17996r17997
256255
257256   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)      /* 052001 (verified on pcb) */
258257   MCFG_CPU_PROGRAM_MAP(aliens_map)
259   MCFG_CPU_VBLANK_INT("screen", aliens_interrupt)
258   MCFG_CPU_VBLANK_INT_DRIVER("screen", aliens_state, aliens_interrupt)
260259
261260   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)    /* verified on pcb */
262261   MCFG_CPU_PROGRAM_MAP(aliens_sound_map)
trunk/src/mame/drivers/88games.c
r17996r17997
2222 *
2323 *************************************/
2424
25static INTERRUPT_GEN( k88games_interrupt )
25INTERRUPT_GEN_MEMBER(_88games_state::k88games_interrupt)
2626{
27   _88games_state *state = device->machine().driver_data<_88games_state>();
2827
29   if (k052109_is_irq_enabled(state->m_k052109))
28   if (k052109_is_irq_enabled(m_k052109))
3029      irq0_line_hold(device);
3130}
3231
r17996r17997
370369   /* basic machine hardware */
371370   MCFG_CPU_ADD("maincpu", KONAMI, 3000000) /* ? */
372371   MCFG_CPU_PROGRAM_MAP(main_map)
373   MCFG_CPU_VBLANK_INT("screen", k88games_interrupt)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", _88games_state, k88games_interrupt)
374373
375374   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
376375   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/cybertnk.c
r17996r17997
834834static MACHINE_CONFIG_START( cybertnk, cybertnk_state )
835835   MCFG_CPU_ADD("maincpu", M68000,XTAL_20MHz/2)
836836   MCFG_CPU_PROGRAM_MAP(master_mem)
837   MCFG_CPU_VBLANK_INT("lscreen", irq1_line_assert)
837   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", cybertnk_state, irq1_line_assert)
838838
839839   MCFG_CPU_ADD("slave", M68000,XTAL_20MHz/2)
840840   MCFG_CPU_PROGRAM_MAP(slave_mem)
841   MCFG_CPU_VBLANK_INT("lscreen", irq3_line_hold)
841   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", cybertnk_state, irq3_line_hold)
842842
843843   MCFG_CPU_ADD("audiocpu", Z80,XTAL_3_579545MHz)
844844   MCFG_CPU_PROGRAM_MAP(sound_mem)
trunk/src/mame/drivers/wc90.c
r17996r17997
310310   /* basic machine hardware */
311311   MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz)      /* verified on pcb */
312312   MCFG_CPU_PROGRAM_MAP(wc90_map_1)
313   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
313   MCFG_CPU_VBLANK_INT_DRIVER("screen", wc90_state, irq0_line_hold)
314314
315315   MCFG_CPU_ADD("sub", Z80, XTAL_8MHz)      /* verified on pcb */
316316   MCFG_CPU_PROGRAM_MAP(wc90_map_2)
317   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
317   MCFG_CPU_VBLANK_INT_DRIVER("screen", wc90_state, irq0_line_hold)
318318
319319   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)   /* verified on pcb */
320320   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/darkseal.c
r17996r17997
263263   /* basic machine hardware */
264264   MCFG_CPU_ADD("maincpu", M68000,12000000) /* Custom chip 59 */
265265   MCFG_CPU_PROGRAM_MAP(darkseal_map)
266   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
266   MCFG_CPU_VBLANK_INT_DRIVER("screen", darkseal_state, irq6_line_hold)/* VBL */
267267
268268   MCFG_CPU_ADD("audiocpu", H6280, 32220000/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
269269   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/deniam.c
r17996r17997
272272   /* basic machine hardware */
273273   MCFG_CPU_ADD("maincpu", M68000,XTAL_25MHz/2)   /* 12.5Mhz verified */
274274   MCFG_CPU_PROGRAM_MAP(deniam16b_map)
275   MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
275   MCFG_CPU_VBLANK_INT_DRIVER("screen", deniam_state, irq4_line_assert)
276276
277277   MCFG_CPU_ADD("audiocpu", Z80,XTAL_25MHz/4)   /* 6.25Mhz verified */
278278   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
308308   /* basic machine hardware */
309309   MCFG_CPU_ADD("maincpu", M68000,XTAL_25MHz/2)   /* 12.5Mhz verified */
310310   MCFG_CPU_PROGRAM_MAP(deniam16c_map)
311   MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
311   MCFG_CPU_VBLANK_INT_DRIVER("screen", deniam_state, irq4_line_assert)
312312
313313
314314   /* video hardware */
trunk/src/mame/drivers/redalert.c
r17996r17997
107107 *
108108 *************************************/
109109
110static INTERRUPT_GEN( redalert_vblank_interrupt )
110INTERRUPT_GEN_MEMBER(redalert_state::redalert_vblank_interrupt)
111111{
112   if( device->machine().root_device().ioport("COIN")->read() )
112   if( machine().root_device().ioport("COIN")->read() )
113113      /* the service coin as conntected to the CPU's RDY pin as well */
114      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
114      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
115115
116   device->execute().set_input_line(M6502_IRQ_LINE, ASSERT_LINE);
116   device.execute().set_input_line(M6502_IRQ_LINE, ASSERT_LINE);
117117}
118118
119119
r17996r17997
390390   /* basic machine hardware */
391391   MCFG_CPU_ADD("maincpu", M6502, MAIN_CPU_CLOCK)
392392   MCFG_CPU_PROGRAM_MAP(redalert_main_map)
393   MCFG_CPU_VBLANK_INT("screen", redalert_vblank_interrupt)
393   MCFG_CPU_VBLANK_INT_DRIVER("screen", redalert_state, redalert_vblank_interrupt)
394394
395395   /* video hardware */
396396   MCFG_FRAGMENT_ADD(redalert_video)
r17996r17997
404404   /* basic machine hardware */
405405   MCFG_CPU_ADD("maincpu", M6502, MAIN_CPU_CLOCK)
406406   MCFG_CPU_PROGRAM_MAP(ww3_main_map)
407   MCFG_CPU_VBLANK_INT("screen", redalert_vblank_interrupt)
407   MCFG_CPU_VBLANK_INT_DRIVER("screen", redalert_state, redalert_vblank_interrupt)
408408
409409   /* video hardware */
410410   MCFG_FRAGMENT_ADD(ww3_video)
r17996r17997
418418   /* basic machine hardware */
419419   MCFG_CPU_ADD("maincpu", M6502, MAIN_CPU_CLOCK)
420420   MCFG_CPU_PROGRAM_MAP(panther_main_map)
421   MCFG_CPU_VBLANK_INT("screen", redalert_vblank_interrupt)
421   MCFG_CPU_VBLANK_INT_DRIVER("screen", redalert_state, redalert_vblank_interrupt)
422422
423423   /* video hardware */
424424   MCFG_FRAGMENT_ADD(panther_video)
r17996r17997
432432   /* basic machine hardware */
433433   MCFG_CPU_ADD("maincpu", M6502, MAIN_CPU_CLOCK)
434434   MCFG_CPU_PROGRAM_MAP(demoneye_main_map)
435   MCFG_CPU_VBLANK_INT("screen", redalert_vblank_interrupt)
435   MCFG_CPU_VBLANK_INT_DRIVER("screen", redalert_state, redalert_vblank_interrupt)
436436
437437   /* video hardware */
438438   MCFG_FRAGMENT_ADD(demoneye_video)
trunk/src/mame/drivers/pipeline.c
r17996r17997
391391
392392   MCFG_CPU_ADD("maincpu", Z80, 7372800/2)
393393   MCFG_CPU_PROGRAM_MAP(cpu0_mem)
394   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
394   MCFG_CPU_VBLANK_INT_DRIVER("screen", pipeline_state, nmi_line_pulse)
395395
396396   MCFG_CPU_ADD("audiocpu", Z80, 7372800/2)
397397   MCFG_CPU_CONFIG(daisy_chain_sound)
trunk/src/mame/drivers/stadhero.c
r17996r17997
229229   /* basic machine hardware */
230230   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2)
231231   MCFG_CPU_PROGRAM_MAP(main_map)
232   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
232   MCFG_CPU_VBLANK_INT_DRIVER("screen", stadhero_state, irq5_line_hold)
233233
234234   MCFG_CPU_ADD("audiocpu", M6502, XTAL_24MHz/16)
235235   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/techno.c
r17996r17997
4949private:
5050   bool m_digwait;
5151   UINT8 m_keyrow;
52public:   
53   INTERRUPT_GEN_MEMBER(techno_intgen);
5254};
5355
5456
r17996r17997
230232   PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_OTHER ) PORT_NAME("Fix top left target middle") PORT_CODE(KEYCODE_EQUALS)
231233INPUT_PORTS_END
232234
233static INTERRUPT_GEN( techno_intgen )
235INTERRUPT_GEN_MEMBER(techno_state::techno_intgen)
234236{
235   techno_state *state = device->machine().driver_data<techno_state>();
236237   // vectors change per int: 88-8F, 98-9F)
237   if ((state->m_vector & 7) == 7)
238      state->m_vector = (state->m_vector ^ 0x10) & 0x97;
239   state->m_vector++;
238   if ((m_vector & 7) == 7)
239      m_vector = (m_vector ^ 0x10) & 0x97;
240   m_vector++;
240241   // core doesn't support clearing of irq via hardware
241   generic_pulse_irq_line_and_vector(device, 1, state->m_vector, 1);
242   generic_pulse_irq_line_and_vector(device.execute(), 1, m_vector, 1);
242243}
243244
244245void techno_state::machine_reset()
r17996r17997
251252   /* basic machine hardware */
252253   MCFG_CPU_ADD("maincpu", M68000, TECHNO_MAINCLK)
253254   MCFG_CPU_PROGRAM_MAP(techno_map)
254   MCFG_CPU_PERIODIC_INT(techno_intgen, TECHNO_MAINCLK/256) // 31250Hz
255   MCFG_CPU_PERIODIC_INT_DRIVER(techno_state, techno_intgen, TECHNO_MAINCLK/256) // 31250Hz
255256   //MCFG_CPU_ADD("cpu2", TMS7000, 4000000)
256257   //MCFG_CPU_PROGRAM_MAP(techno_sub_map)
257258
trunk/src/mame/drivers/taito_b.c
r17996r17997
202202   state->m_maincpu->set_input_line(2, HOLD_LINE);
203203}
204204
205static INTERRUPT_GEN( rastansaga2_interrupt )
205INTERRUPT_GEN_MEMBER(taitob_state::rastansaga2_interrupt)
206206{
207   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(rsaga2_interrupt2));
208   device->execute().set_input_line(4, HOLD_LINE);
207   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(rsaga2_interrupt2));
208   device.execute().set_input_line(4, HOLD_LINE);
209209}
210210
211211
r17996r17997
215215   state->m_maincpu->set_input_line(3, HOLD_LINE);
216216}
217217
218static INTERRUPT_GEN( crimec_interrupt )
218INTERRUPT_GEN_MEMBER(taitob_state::crimec_interrupt)
219219{
220   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(crimec_interrupt3));
221   device->execute().set_input_line(5, HOLD_LINE);
220   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(crimec_interrupt3));
221   device.execute().set_input_line(5, HOLD_LINE);
222222}
223223
224224
r17996r17997
228228   state->m_maincpu->set_input_line(6, HOLD_LINE);
229229}
230230
231static INTERRUPT_GEN( hitice_interrupt )
231INTERRUPT_GEN_MEMBER(taitob_state::hitice_interrupt)
232232{
233   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(hitice_interrupt6));
234   device->execute().set_input_line(4, HOLD_LINE);
233   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(hitice_interrupt6));
234   device.execute().set_input_line(4, HOLD_LINE);
235235}
236236
237237
r17996r17997
241241   state->m_maincpu->set_input_line(1, HOLD_LINE);
242242}
243243
244static INTERRUPT_GEN( rambo3_interrupt )
244INTERRUPT_GEN_MEMBER(taitob_state::rambo3_interrupt)
245245{
246   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(rambo3_interrupt1));
247   device->execute().set_input_line(6, HOLD_LINE);
246   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(rambo3_interrupt1));
247   device.execute().set_input_line(6, HOLD_LINE);
248248}
249249
250250
r17996r17997
254254   state->m_maincpu->set_input_line(5, HOLD_LINE);
255255}
256256
257static INTERRUPT_GEN( pbobble_interrupt )
257INTERRUPT_GEN_MEMBER(taitob_state::pbobble_interrupt)
258258{
259   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(pbobble_interrupt5));
260   device->execute().set_input_line(3, HOLD_LINE);
259   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(pbobble_interrupt5));
260   device.execute().set_input_line(3, HOLD_LINE);
261261}
262262
263263static TIMER_CALLBACK( viofight_interrupt1 )
r17996r17997
266266   state->m_maincpu->set_input_line(1, HOLD_LINE);
267267}
268268
269static INTERRUPT_GEN( viofight_interrupt )
269INTERRUPT_GEN_MEMBER(taitob_state::viofight_interrupt)
270270{
271   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(viofight_interrupt1));
272   device->execute().set_input_line(4, HOLD_LINE);
271   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(viofight_interrupt1));
272   device.execute().set_input_line(4, HOLD_LINE);
273273}
274274
275275static TIMER_CALLBACK( masterw_interrupt4 )
r17996r17997
278278   state->m_maincpu->set_input_line(4, HOLD_LINE);
279279}
280280
281static INTERRUPT_GEN( masterw_interrupt )
281INTERRUPT_GEN_MEMBER(taitob_state::masterw_interrupt)
282282{
283   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(masterw_interrupt4));
284   device->execute().set_input_line(5, HOLD_LINE);
283   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(masterw_interrupt4));
284   device.execute().set_input_line(5, HOLD_LINE);
285285}
286286
287287static TIMER_CALLBACK( silentd_interrupt4 )
r17996r17997
290290   state->m_maincpu->set_input_line(4, HOLD_LINE);
291291}
292292
293static INTERRUPT_GEN( silentd_interrupt )
293INTERRUPT_GEN_MEMBER(taitob_state::silentd_interrupt)
294294{
295   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(silentd_interrupt4));
296   device->execute().set_input_line(6, HOLD_LINE);
295   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(silentd_interrupt4));
296   device.execute().set_input_line(6, HOLD_LINE);
297297}
298298
299299static TIMER_CALLBACK( selfeena_interrupt4 )
r17996r17997
302302   state->m_maincpu->set_input_line(4, HOLD_LINE);
303303}
304304
305static INTERRUPT_GEN( selfeena_interrupt )
305INTERRUPT_GEN_MEMBER(taitob_state::selfeena_interrupt)
306306{
307   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(5000), FUNC(selfeena_interrupt4));
308   device->execute().set_input_line(6, HOLD_LINE);
307   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(5000), FUNC(selfeena_interrupt4));
308   device.execute().set_input_line(6, HOLD_LINE);
309309}
310310
311311static TIMER_CALLBACK( sbm_interrupt5 )//4
r17996r17997
314314   state->m_maincpu->set_input_line(5, HOLD_LINE);
315315}
316316
317static INTERRUPT_GEN( sbm_interrupt )//5
317INTERRUPT_GEN_MEMBER(taitob_state::sbm_interrupt)//5
318318{
319   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(10000), FUNC(sbm_interrupt5));
320   device->execute().set_input_line(4, HOLD_LINE);
319   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(10000), FUNC(sbm_interrupt5));
320   device.execute().set_input_line(4, HOLD_LINE);
321321}
322322
323323static TIMER_CALLBACK( realpunc_interrupt3 )//3
r17996r17997
326326   state->m_maincpu->set_input_line(3, HOLD_LINE);
327327}
328328
329static INTERRUPT_GEN( realpunc_interrupt )//2
329INTERRUPT_GEN_MEMBER(taitob_state::realpunc_interrupt)//2
330330{
331   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(10000), FUNC(realpunc_interrupt3));
332   device->execute().set_input_line(2, HOLD_LINE);
331   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(10000), FUNC(realpunc_interrupt3));
332   device.execute().set_input_line(2, HOLD_LINE);
333333}
334334
335335
r17996r17997
20402040   /* basic machine hardware */
20412041   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
20422042   MCFG_CPU_PROGRAM_MAP(rastsag2_map)
2043   MCFG_CPU_VBLANK_INT("screen", rastansaga2_interrupt)
2043   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, rastansaga2_interrupt)
20442044
20452045   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
20462046   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
20842084   /* basic machine hardware */
20852085   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
20862086   MCFG_CPU_PROGRAM_MAP(rastsag2_map)
2087   MCFG_CPU_VBLANK_INT("screen", rastansaga2_interrupt)
2087   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, rastansaga2_interrupt)
20882088
20892089   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
20902090   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
21282128   /* basic machine hardware */
21292129   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
21302130   MCFG_CPU_PROGRAM_MAP(crimec_map)
2131   MCFG_CPU_VBLANK_INT("screen", crimec_interrupt)
2131   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, crimec_interrupt)
21322132
21332133   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
21342134   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
21722172   /* basic machine hardware */
21732173   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ???*/
21742174   MCFG_CPU_PROGRAM_MAP(tetrist_map)
2175   MCFG_CPU_VBLANK_INT("screen", rastansaga2_interrupt)
2175   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, rastansaga2_interrupt)
21762176
21772177   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
21782178   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
22152215   /* basic machine hardware */
22162216   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
22172217   MCFG_CPU_PROGRAM_MAP(tetrista_map)
2218   MCFG_CPU_VBLANK_INT("screen", masterw_interrupt)
2218   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, masterw_interrupt)
22192219
22202220   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
22212221   MCFG_CPU_PROGRAM_MAP(masterw_sound_map)
r17996r17997
22592259   /* basic machine hardware */
22602260   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
22612261   MCFG_CPU_PROGRAM_MAP(hitice_map)
2262   MCFG_CPU_VBLANK_INT("screen", hitice_interrupt)
2262   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, hitice_interrupt)
22632263
22642264   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
22652265   MCFG_CPU_PROGRAM_MAP(viofight_sound_map)
r17996r17997
23082308   /* basic machine hardware */
23092309   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)   /* verified on pcb */
23102310   MCFG_CPU_PROGRAM_MAP(rambo3_map)
2311   MCFG_CPU_VBLANK_INT("screen", rambo3_interrupt)
2311   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, rambo3_interrupt)
23122312
23132313   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/6)   /* verified on pcb */
23142314   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
23522352   /* basic machine hardware */
23532353   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)   /* verified on pcb */
23542354   MCFG_CPU_PROGRAM_MAP(rambo3_map)
2355   MCFG_CPU_VBLANK_INT("screen", rambo3_interrupt)
2355   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, rambo3_interrupt)
23562356
23572357   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/6)   /* verified on pcb */
23582358   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
23952395   /* basic machine hardware */
23962396   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
23972397   MCFG_CPU_PROGRAM_MAP(pbobble_map)
2398   MCFG_CPU_VBLANK_INT("screen", pbobble_interrupt)
2398   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, pbobble_interrupt)
23992399
24002400   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
24012401   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
24432443   /* basic machine hardware */
24442444   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
24452445   MCFG_CPU_PROGRAM_MAP(spacedx_map)
2446   MCFG_CPU_VBLANK_INT("screen", pbobble_interrupt)
2446   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, pbobble_interrupt)
24472447
24482448   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
24492449   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
24912491   /* basic machine hardware */
24922492   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
24932493   MCFG_CPU_PROGRAM_MAP(spacedxo_map)
2494   MCFG_CPU_VBLANK_INT("screen", selfeena_interrupt)
2494   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, selfeena_interrupt)
24952495
24962496   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
24972497   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
25352535   /* basic machine hardware */
25362536   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz according to the readme*/
25372537   MCFG_CPU_PROGRAM_MAP(qzshowby_map)
2538   MCFG_CPU_VBLANK_INT("screen", pbobble_interrupt)
2538   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, pbobble_interrupt)
25392539
25402540   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
25412541   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
25832583   /* basic machine hardware */
25842584   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
25852585   MCFG_CPU_PROGRAM_MAP(viofight_map)
2586   MCFG_CPU_VBLANK_INT("screen", viofight_interrupt)
2586   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, viofight_interrupt)
25872587
25882588   MCFG_CPU_ADD("audiocpu", Z80, 6000000)   /* 6 MHz verified */
25892589   MCFG_CPU_PROGRAM_MAP(viofight_sound_map)
r17996r17997
26302630   /* basic machine hardware */
26312631   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
26322632   MCFG_CPU_PROGRAM_MAP(masterw_map)
2633   MCFG_CPU_VBLANK_INT("screen", masterw_interrupt)
2633   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, masterw_interrupt)
26342634
26352635   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
26362636   MCFG_CPU_PROGRAM_MAP(masterw_sound_map)
r17996r17997
26752675   /* basic machine hardware */
26762676   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz ??? */
26772677   MCFG_CPU_PROGRAM_MAP(silentd_map)
2678   MCFG_CPU_VBLANK_INT("screen", silentd_interrupt)
2678   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, silentd_interrupt)
26792679
26802680   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
26812681   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
27192719   /* basic machine hardware */
27202720   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
27212721   MCFG_CPU_PROGRAM_MAP(selfeena_map)
2722   MCFG_CPU_VBLANK_INT("screen", selfeena_interrupt)
2722   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, selfeena_interrupt)
27232723
27242724   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
27252725   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
27722772   /* basic machine hardware */
27732773   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
27742774   MCFG_CPU_PROGRAM_MAP(selfeena_map)
2775   MCFG_CPU_VBLANK_INT("screen", selfeena_interrupt)
2775   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, selfeena_interrupt)
27762776
27772777   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
27782778   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
28232823   /* basic machine hardware */
28242824   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
28252825   MCFG_CPU_PROGRAM_MAP(sbm_map)
2826   MCFG_CPU_VBLANK_INT("screen", sbm_interrupt)
2826   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, sbm_interrupt)
28272827
28282828   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
28292829   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
28722872   /* basic machine hardware */
28732873   MCFG_CPU_ADD("maincpu", M68000, 12000000)
28742874   MCFG_CPU_PROGRAM_MAP(realpunc_map)
2875   MCFG_CPU_VBLANK_INT("screen", realpunc_interrupt)
2875   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitob_state, realpunc_interrupt)
28762876
28772877   MCFG_CPU_ADD("audiocpu", Z80, 6000000)
28782878   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/kungfur.c
r17996r17997
8383   DECLARE_WRITE8_MEMBER(kungfur_adpcm2_w);
8484   virtual void machine_start();
8585   virtual void machine_reset();
86   INTERRUPT_GEN_MEMBER(kungfur_irq);
8687};
8788
8889
89static INTERRUPT_GEN( kungfur_irq )
90INTERRUPT_GEN_MEMBER(kungfur_state::kungfur_irq)
9091{
91   kungfur_state *state = device->machine().driver_data<kungfur_state>();
92   if (state->m_control & 0x10)
93      device->execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
92   if (m_control & 0x10)
93      device.execute().set_input_line(M6809_IRQ_LINE, ASSERT_LINE);
9494}
9595
9696
r17996r17997
317317   /* basic machine hardware */
318318   MCFG_CPU_ADD("maincpu", M6809, 8000000/2)   // 4MHz?
319319   MCFG_CPU_PROGRAM_MAP(kungfur_map)
320   MCFG_CPU_PERIODIC_INT(kungfur_irq, 975)      // close approximation
320   MCFG_CPU_PERIODIC_INT_DRIVER(kungfur_state, kungfur_irq, 975)      // close approximation
321321
322322   MCFG_I8255A_ADD( "ppi8255_0", ppi8255_0_intf )
323323   MCFG_I8255A_ADD( "ppi8255_1", ppi8255_1_intf )
trunk/src/mame/drivers/jackal.c
r17996r17997
307307 *
308308 *************************************/
309309
310static INTERRUPT_GEN( jackal_interrupt )
310INTERRUPT_GEN_MEMBER(jackal_state::jackal_interrupt)
311311{
312   jackal_state *state = device->machine().driver_data<jackal_state>();
313312
314   if (state->m_irq_enable)
313   if (m_irq_enable)
315314   {
316      device->execute().set_input_line(0, HOLD_LINE);
317      state->m_slavecpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
315      device.execute().set_input_line(0, HOLD_LINE);
316      m_slavecpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
318317   }
319318}
320319
r17996r17997
358357   /* basic machine hardware */
359358   MCFG_CPU_ADD("master", M6809, MASTER_CLOCK/12) // verified on pcb
360359   MCFG_CPU_PROGRAM_MAP(master_map)
361   MCFG_CPU_VBLANK_INT("screen", jackal_interrupt)
360   MCFG_CPU_VBLANK_INT_DRIVER("screen", jackal_state, jackal_interrupt)
362361
363362   MCFG_CPU_ADD("slave", M6809, MASTER_CLOCK/12) // verified on pcb
364363   MCFG_CPU_PROGRAM_MAP(slave_map)
trunk/src/mame/drivers/viper.c
r17996r17997
347347   virtual void machine_start();
348348   virtual void machine_reset();
349349   UINT32 screen_update_viper(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
350   INTERRUPT_GEN_MEMBER(viper_vblank);
350351};
351352
352353UINT32 viper_state::screen_update_viper(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect)
r17996r17997
19251926   NULL
19261927};
19271928
1928static INTERRUPT_GEN(viper_vblank)
1929INTERRUPT_GEN_MEMBER(viper_state::viper_vblank)
19291930{
1930   mpc8240_interrupt(device->machine(), MPC8240_IRQ0);
1931   //mpc8240_interrupt(device->machine, MPC8240_IRQ3);
1931   mpc8240_interrupt(machine(), MPC8240_IRQ0);
1932   //mpc8240_interrupt(device.machine, MPC8240_IRQ3);
19321933}
19331934
19341935static void voodoo_vblank(device_t *device, int state)
r17996r17997
19931994   MCFG_CPU_ADD("maincpu", MPC8240, 200000000)
19941995   MCFG_CPU_CONFIG(viper_ppc_cfg)
19951996   MCFG_CPU_PROGRAM_MAP(viper_map)
1996   MCFG_CPU_VBLANK_INT("screen", viper_vblank)
1997   MCFG_CPU_VBLANK_INT_DRIVER("screen", viper_state, viper_vblank)
19971998
19981999
19992000   MCFG_PCI_BUS_LEGACY_ADD("pcibus", 0)
trunk/src/mame/drivers/pinkiri8.c
r17996r17997
11321132   MCFG_CPU_ADD("maincpu",Z180,16000000)
11331133   MCFG_CPU_PROGRAM_MAP(pinkiri8_map)
11341134   MCFG_CPU_IO_MAP(pinkiri8_io)
1135   MCFG_CPU_VBLANK_INT("screen",nmi_line_assert)
1135   MCFG_CPU_VBLANK_INT_DRIVER("screen", pinkiri8_state, nmi_line_assert)
11361136
11371137   MCFG_SCREEN_ADD("screen", RASTER)
11381138   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/suna8.c
r17996r17997
16241624   MCFG_CPU_ADD("maincpu", Z80, SUNA8_MASTER_CLOCK / 4)   /* verified on pcb */
16251625   MCFG_CPU_PROGRAM_MAP(hardhead_map)
16261626   MCFG_CPU_IO_MAP(hardhead_io_map)
1627   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)      /* No NMI */
1627   MCFG_CPU_VBLANK_INT_DRIVER("screen", suna8_state, irq0_line_hold)      /* No NMI */
16281628
16291629   MCFG_CPU_ADD("audiocpu", Z80, SUNA8_MASTER_CLOCK / 8)   /* verified on pcb */
16301630   MCFG_CPU_PROGRAM_MAP(hardhead_sound_map)
16311631   MCFG_CPU_IO_MAP(hardhead_sound_io_map)
1632   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)      /* No NMI */
1632   MCFG_CPU_PERIODIC_INT_DRIVER(suna8_state, irq0_line_hold, 4*60)      /* No NMI */
16331633
16341634   /* video hardware */
16351635   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
16891689   MCFG_CPU_ADD("maincpu", Z80, SUNA8_MASTER_CLOCK / 4)               /* ? */
16901690   MCFG_CPU_PROGRAM_MAP(rranger_map)
16911691   MCFG_CPU_IO_MAP(rranger_io_map)
1692   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ & NMI ! */
1692   MCFG_CPU_VBLANK_INT_DRIVER("screen", suna8_state, irq0_line_hold)   /* IRQ & NMI ! */
16931693
16941694   MCFG_CPU_ADD("audiocpu", Z80, SUNA8_MASTER_CLOCK / 4)               /* ? */
16951695   MCFG_CPU_PROGRAM_MAP(rranger_sound_map)
1696   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* NMI = retn */
1696   MCFG_CPU_PERIODIC_INT_DRIVER(suna8_state, irq0_line_hold, 4*60)   /* NMI = retn */
16971697
16981698   /* video hardware */
16991699   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
17631763   MCFG_CPU_ADD("maincpu", Z80, SUNA8_MASTER_CLOCK / 4)      /* SUNA PROTECTION BLOCK */
17641764   MCFG_CPU_PROGRAM_MAP(brickzn_map)
17651765   MCFG_CPU_IO_MAP(brickzn_io_map)
1766   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   // nmi breaks ramtest but is needed!
1766   MCFG_CPU_VBLANK_INT_DRIVER("screen", suna8_state, irq0_line_hold)   // nmi breaks ramtest but is needed!
17671767
17681768   MCFG_CPU_ADD("audiocpu", Z80, SUNA8_MASTER_CLOCK / 4)   /* Z0840006PSC */
17691769   MCFG_CPU_PROGRAM_MAP(brickzn_sound_map)
r17996r17997
18731873   MCFG_CPU_ADD("audiocpu", Z80, SUNA8_MASTER_CLOCK / 4)               /* ? */
18741874   MCFG_CPU_PROGRAM_MAP(hardhead_sound_map)
18751875   MCFG_CPU_IO_MAP(hardhead_sound_io_map)
1876   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* No NMI */
1876   MCFG_CPU_PERIODIC_INT_DRIVER(suna8_state, irq0_line_hold, 4*60)   /* No NMI */
18771877
18781878   /* video hardware */
18791879   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
19201920   MCFG_CPU_ADD("audiocpu", Z80, SUNA8_MASTER_CLOCK / 4)            /* ? */
19211921   MCFG_CPU_PROGRAM_MAP(hardhead_sound_map)
19221922   MCFG_CPU_IO_MAP(hardhead_sound_io_map)
1923   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* No NMI */
1923   MCFG_CPU_PERIODIC_INT_DRIVER(suna8_state, irq0_line_hold, 4*60)   /* No NMI */
19241924
19251925   /* video hardware */
19261926   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/namcos86.c
r17996r17997
992992   /* basic machine hardware */
993993   MCFG_CPU_ADD("cpu1", M6809, 49152000/32)
994994   MCFG_CPU_PROGRAM_MAP(cpu1_map)
995   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
995   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos86_state, irq0_line_assert)
996996
997997   MCFG_CPU_ADD("cpu2", M6809, 49152000/32)
998998   MCFG_CPU_PROGRAM_MAP(hopmappy_cpu2_map)
999   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
999   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos86_state, irq0_line_assert)
10001000
10011001   MCFG_CPU_ADD("mcu", HD63701, 49152000/8)   /* or compatible 6808 with extra instructions */
10021002   MCFG_CPU_PROGRAM_MAP(hopmappy_mcu_map)
10031003   MCFG_CPU_IO_MAP(mcu_port_map)
1004   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* ??? */
1004   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos86_state, irq0_line_hold)   /* ??? */
10051005
10061006   MCFG_QUANTUM_TIME(attotime::from_hz(48000))   /* heavy interleaving needed to avoid hangs in rthunder */
10071007
trunk/src/mame/drivers/vaportra.c
r17996r17997
264264   /* basic machine hardware */
265265   MCFG_CPU_ADD("maincpu", M68000,12000000) /* Custom chip 59 */
266266   MCFG_CPU_PROGRAM_MAP(main_map)
267   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
267   MCFG_CPU_VBLANK_INT_DRIVER("screen", vaportra_state, irq6_line_hold)
268268
269269   MCFG_CPU_ADD("audiocpu", H6280, 32220000/4) /* Custom chip 45; Audio section crystal is 32.220 MHz */
270270   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/m14.c
r17996r17997
8686   virtual void video_start();
8787   virtual void palette_init();
8888   UINT32 screen_update_m14(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
89   INTERRUPT_GEN_MEMBER(m14_irq);
8990};
9091
9192
r17996r17997
313314   GFXDECODE_ENTRY( "gfx1", 0, charlayout,     0, 0x10 )
314315GFXDECODE_END
315316
316static INTERRUPT_GEN( m14_irq )
317INTERRUPT_GEN_MEMBER(m14_state::m14_irq)
317318{
318   device->execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
319   device->execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
319   device.execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
320   device.execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
320321}
321322
322323void m14_state::machine_start()
r17996r17997
340341   MCFG_CPU_ADD("maincpu",I8085A,6000000/2) //guess: 6 Mhz internally divided by 2
341342   MCFG_CPU_PROGRAM_MAP(m14_map)
342343   MCFG_CPU_IO_MAP(m14_io_map)
343   MCFG_CPU_VBLANK_INT("screen",m14_irq)
344   MCFG_CPU_VBLANK_INT_DRIVER("screen", m14_state, m14_irq)
344345
345346
346347   /* video hardware */
trunk/src/mame/drivers/nova2001.c
r17996r17997
683683   /* basic machine hardware */
684684   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK/4)   // 3 MHz verified on schematics
685685   MCFG_CPU_PROGRAM_MAP(nova2001_map)
686   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
686   MCFG_CPU_VBLANK_INT_DRIVER("screen", nova2001_state, irq0_line_hold)
687687
688688   /* video hardware */
689689   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
715715   /* basic machine hardware */
716716   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK/4)   // 3 MHz
717717   MCFG_CPU_PROGRAM_MAP(ninjakun_cpu1_map)
718   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
718   MCFG_CPU_VBLANK_INT_DRIVER("screen", nova2001_state, irq0_line_hold)
719719
720720   MCFG_CPU_ADD("sub", Z80, MAIN_CLOCK/4)   // 3 MHz
721721   MCFG_CPU_PROGRAM_MAP(ninjakun_cpu2_map)
722   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60) /* ? */
722   MCFG_CPU_PERIODIC_INT_DRIVER(nova2001_state, irq0_line_hold, 4*60) /* ? */
723723
724724   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* 100 CPU slices per frame */
725725
r17996r17997
756756   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK/4)   // 3 MHz
757757   MCFG_CPU_PROGRAM_MAP(pkunwar_map)
758758   MCFG_CPU_IO_MAP(pkunwar_io)
759   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
759   MCFG_CPU_VBLANK_INT_DRIVER("screen", nova2001_state, irq0_line_hold)
760760
761761   /* video hardware */
762762   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
789789   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK/4)   // 3 MHz
790790   MCFG_CPU_PROGRAM_MAP(raiders5_cpu1_map)
791791   MCFG_CPU_IO_MAP(raiders5_io)
792   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
792   MCFG_CPU_VBLANK_INT_DRIVER("screen", nova2001_state, irq0_line_hold)
793793
794794   MCFG_CPU_ADD("sub", Z80, MAIN_CLOCK/4)   // 3 MHz
795795   MCFG_CPU_PROGRAM_MAP(raiders5_cpu2_map)
796   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* ? */
796   MCFG_CPU_PERIODIC_INT_DRIVER(nova2001_state, irq0_line_hold, 4*60)   /* ? */
797797
798798   MCFG_QUANTUM_TIME(attotime::from_hz(24000))
799799
trunk/src/mame/drivers/jantotsu.c
r17996r17997
519519   MCFG_CPU_ADD("maincpu", Z80,MAIN_CLOCK/4)
520520   MCFG_CPU_PROGRAM_MAP(jantotsu_map)
521521   MCFG_CPU_IO_MAP(jantotsu_io)
522   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
522   MCFG_CPU_VBLANK_INT_DRIVER("screen", jantotsu_state, nmi_line_pulse)
523523
524524
525525   /* video hardware */
trunk/src/mame/drivers/chsuper.c
r17996r17997
203203   MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2)   /* HD64180RP8, 8 MHz? */
204204   MCFG_CPU_PROGRAM_MAP(chsuper_prg_map)
205205   MCFG_CPU_IO_MAP(chsuper_portmap)
206   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
206   MCFG_CPU_VBLANK_INT_DRIVER("screen", chsuper_state, irq0_line_hold)
207207
208208   /* video hardware */
209209   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mermaid.c
r17996r17997
439439};
440440
441441
442static INTERRUPT_GEN( vblank_irq )
442INTERRUPT_GEN_MEMBER(mermaid_state::vblank_irq)
443443{
444   mermaid_state *state = device->machine().driver_data<mermaid_state>();
445444
446   if(state->m_nmi_mask)
447      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
445   if(m_nmi_mask)
446      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
448447}
449448
450449static MACHINE_CONFIG_START( mermaid, mermaid_state )
r17996r17997
452451   /* basic machine hardware */
453452   MCFG_CPU_ADD("maincpu", Z80, 4000000)   // ???
454453   MCFG_CPU_PROGRAM_MAP(mermaid_map)
455   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
454   MCFG_CPU_VBLANK_INT_DRIVER("screen", mermaid_state, vblank_irq)
456455
457456
458457   /* video hardware */
trunk/src/mame/drivers/avalnche.c
r17996r17997
248248   /* basic machine hardware */
249249   MCFG_CPU_ADD("maincpu", M6502,MASTER_CLOCK/16)      /* clock input is the "2H" signal divided by two */
250250   MCFG_CPU_PROGRAM_MAP(main_map)
251   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,8*60)
251   MCFG_CPU_PERIODIC_INT_DRIVER(avalnche_state, nmi_line_pulse, 8*60)
252252
253253
254254   /* video hardware */
trunk/src/mame/drivers/gaelco3d.c
r17996r17997
250250 *
251251 *************************************/
252252
253static INTERRUPT_GEN( vblank_gen )
253INTERRUPT_GEN_MEMBER(gaelco3d_state::vblank_gen)
254254{
255   gaelco3d_render(*device->machine().primary_screen);
256   device->execute().set_input_line(2, ASSERT_LINE);
255   gaelco3d_render(*machine().primary_screen);
256   device.execute().set_input_line(2, ASSERT_LINE);
257257}
258258
259259
r17996r17997
994994   /* basic machine hardware */
995995   MCFG_CPU_ADD("maincpu", M68000, 15000000)
996996   MCFG_CPU_PROGRAM_MAP(main_map)
997   MCFG_CPU_VBLANK_INT("screen", vblank_gen)
997   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco3d_state, vblank_gen)
998998
999999   MCFG_CPU_ADD("tms", TMS32031, 60000000)
10001000   MCFG_TMS3203X_CONFIG(tms_config)
r17996r17997
10471047   /* basic machine hardware */
10481048   MCFG_CPU_REPLACE("maincpu", M68EC020, 25000000)
10491049   MCFG_CPU_PROGRAM_MAP(main020_map)
1050   MCFG_CPU_VBLANK_INT("screen", vblank_gen)
1050   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco3d_state, vblank_gen)
10511051
10521052   MCFG_CPU_MODIFY("tms")
10531053   MCFG_CPU_CLOCK(50000000)
trunk/src/mame/drivers/dcon.c
r17996r17997
251251   /* basic machine hardware */
252252   MCFG_CPU_ADD("maincpu", M68000, 10000000)
253253   MCFG_CPU_PROGRAM_MAP(dcon_map)
254   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
254   MCFG_CPU_VBLANK_INT_DRIVER("screen", dcon_state, irq4_line_hold)
255255
256256   SEIBU_SOUND_SYSTEM_CPU(4000000) /* Perhaps 14318180/4? */
257257
r17996r17997
278278   /* basic machine hardware */
279279   MCFG_CPU_ADD("maincpu", M68000, 10000000)
280280   MCFG_CPU_PROGRAM_MAP(dcon_map)
281   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
281   MCFG_CPU_VBLANK_INT_DRIVER("screen", dcon_state, irq4_line_hold)
282282
283283   SEIBU2_SOUND_SYSTEM_CPU(14318180/4)
284284
trunk/src/mame/drivers/gstriker.c
r17996r17997
542542static MACHINE_CONFIG_START( gstriker, gstriker_state )
543543   MCFG_CPU_ADD("maincpu", M68000, 10000000)
544544   MCFG_CPU_PROGRAM_MAP(gstriker_map)
545   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
545   MCFG_CPU_VBLANK_INT_DRIVER("screen", gstriker_state, irq1_line_hold)
546546
547547   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)   /* 4 MHz ??? */
548548   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
580580static MACHINE_CONFIG_START( vgoal, gstriker_state )
581581   MCFG_CPU_ADD("maincpu", M68000, 16000000)
582582   MCFG_CPU_PROGRAM_MAP(vgoal_map)
583   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
583   MCFG_CPU_VBLANK_INT_DRIVER("screen", gstriker_state, irq1_line_hold)
584584
585585   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)   /* 4 MHz ??? */
586586   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/snk.c
r17996r17997
36253625   /* basic machine hardware */
36263626   MCFG_CPU_ADD("maincpu", Z80, 3360000)   /* 3.36 MHz */
36273627   MCFG_CPU_PROGRAM_MAP(marvins_cpuA_map)
3628   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3628   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
36293629
36303630   MCFG_CPU_ADD("sub", Z80, 3360000)   /* 3.36 MHz */
36313631   MCFG_CPU_PROGRAM_MAP(marvins_cpuB_map)
3632   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3632   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
36333633
36343634   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* verified on schematics */
36353635   MCFG_CPU_PROGRAM_MAP(marvins_sound_map)
36363636   MCFG_CPU_IO_MAP(marvins_sound_portmap)
3637   MCFG_CPU_PERIODIC_INT(nmi_line_assert, 244)   // schematics show a separate 244Hz timer
3637   MCFG_CPU_PERIODIC_INT_DRIVER(snk_state, nmi_line_assert, 244)   // schematics show a separate 244Hz timer
36383638
36393639   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
36403640
r17996r17997
36943694   /* basic machine hardware */
36953695   MCFG_CPU_ADD("maincpu", Z80, 3350000) /* NOT verified */
36963696   MCFG_CPU_PROGRAM_MAP(jcross_cpuA_map)
3697   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3697   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
36983698
36993699   MCFG_CPU_ADD("sub", Z80, 3350000) /* NOT verified */
37003700   MCFG_CPU_PROGRAM_MAP(jcross_cpuB_map)
3701   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3701   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
37023702
37033703   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* NOT verified */
37043704   MCFG_CPU_PROGRAM_MAP(jcross_sound_map)
37053705   MCFG_CPU_IO_MAP(jcross_sound_portmap)
3706   MCFG_CPU_PERIODIC_INT(irq0_line_assert, 244)   // Marvin's frequency, sounds ok
3706   MCFG_CPU_PERIODIC_INT_DRIVER(snk_state, irq0_line_assert, 244)   // Marvin's frequency, sounds ok
37073707
37083708   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
37093709
r17996r17997
37623762   MCFG_CPU_MODIFY("audiocpu")
37633763   MCFG_CPU_PROGRAM_MAP(hal21_sound_map)
37643764   MCFG_CPU_IO_MAP(hal21_sound_portmap)
3765   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 220) // music tempo, hand tuned
3765   MCFG_CPU_PERIODIC_INT_DRIVER(snk_state, irq0_line_hold, 220) // music tempo, hand tuned
37663766
37673767   /* video hardware */
37683768   MCFG_VIDEO_START_OVERRIDE(snk_state,hal21)
r17996r17997
37743774   /* basic machine hardware */
37753775   MCFG_CPU_ADD("maincpu", Z80, XTAL_13_4MHz/4) /* verified on pcb */
37763776   MCFG_CPU_PROGRAM_MAP(tnk3_cpuA_map)
3777   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3777   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
37783778
37793779   MCFG_CPU_ADD("sub", Z80, XTAL_13_4MHz/4) /* verified on pcb */
37803780   MCFG_CPU_PROGRAM_MAP(tnk3_cpuB_map)
3781   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3781   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
37823782
37833783   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* verified on pcb */
37843784   MCFG_CPU_PROGRAM_MAP(tnk3_YM3526_sound_map)
r17996r17997
38583858   /* basic machine hardware */
38593859   MCFG_CPU_ADD("maincpu", Z80, XTAL_13_4MHz/4) /* verified on pcb */
38603860   MCFG_CPU_PROGRAM_MAP(ikari_cpuA_map)
3861   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3861   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
38623862
38633863   MCFG_CPU_ADD("sub", Z80, XTAL_13_4MHz/4) /* verified on pcb */
38643864   MCFG_CPU_PROGRAM_MAP(ikari_cpuB_map)
3865   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3865   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
38663866
38673867   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* verified on pcb */
38683868   MCFG_CPU_PROGRAM_MAP(YM3526_YM3526_sound_map)
r17996r17997
39153915   /* basic machine hardware */
39163916   MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz/2) /* verified on pcb */
39173917   MCFG_CPU_PROGRAM_MAP(bermudat_cpuA_map)
3918   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3918   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
39193919
39203920   MCFG_CPU_ADD("sub", Z80, XTAL_8MHz/2) /* verified on pcb */
39213921   MCFG_CPU_PROGRAM_MAP(bermudat_cpuB_map)
3922   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3922   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
39233923
39243924   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* verified on pcb */
39253925   MCFG_CPU_PROGRAM_MAP(YM3526_Y8950_sound_map)
r17996r17997
40184018   /* basic machine hardware */
40194019   MCFG_CPU_ADD("maincpu", Z80, 4000000)
40204020   MCFG_CPU_PROGRAM_MAP(tdfever_cpuA_map)
4021   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
4021   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
40224022
40234023   MCFG_CPU_ADD("sub", Z80, 4000000)
40244024   MCFG_CPU_PROGRAM_MAP(tdfever_cpuB_map)
4025   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
4025   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk_state, irq0_line_hold)
40264026
40274027   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
40284028   MCFG_CPU_PROGRAM_MAP(YM3526_Y8950_sound_map)
trunk/src/mame/drivers/highvdeo.c
r17996r17997
127127   DECLARE_VIDEO_START(tourvisn);
128128   UINT32 screen_update_tourvisn(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
129129   UINT32 screen_update_brasil(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
130   INTERRUPT_GEN_MEMBER(vblank_irq);
130131};
131132
132133
r17996r17997
920921   PORT_DIPSETTING(      0x0000, DEF_STR( On ) )
921922INPUT_PORTS_END
922923
923static INTERRUPT_GEN( vblank_irq )
924INTERRUPT_GEN_MEMBER(highvdeo_state::vblank_irq)
924925{
925   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4);
926   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4);
926927}
927928
928929static MACHINE_CONFIG_START( tv_vcf, highvdeo_state )
929930   MCFG_CPU_ADD("maincpu", V30, XTAL_12MHz/2 )   // ?
930931   MCFG_CPU_PROGRAM_MAP(tv_vcf_map)
931932   MCFG_CPU_IO_MAP(tv_vcf_io)
932   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
933   MCFG_CPU_VBLANK_INT_DRIVER("screen", highvdeo_state, vblank_irq)
933934
934935   MCFG_NVRAM_ADD_0FILL("nvram")
935936
r17996r17997
988989   MCFG_CPU_ADD("maincpu", I80186, 20000000/2 )   // ?
989990   MCFG_CPU_PROGRAM_MAP(tv_tcf_map)
990991   MCFG_CPU_IO_MAP(tv_tcf_io)
991   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
992   MCFG_CPU_VBLANK_INT_DRIVER("screen", highvdeo_state, vblank_irq)
992993MACHINE_CONFIG_END
993994
994995static MACHINE_CONFIG_START( brasil, highvdeo_state )
995996   MCFG_CPU_ADD("maincpu", I80186, 20000000 )   // fashion doesn't like 20/2 Mhz
996997   MCFG_CPU_PROGRAM_MAP(brasil_map)
997998   MCFG_CPU_IO_MAP(brasil_io)
998   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
999   MCFG_CPU_VBLANK_INT_DRIVER("screen", highvdeo_state, vblank_irq)
9991000
10001001   MCFG_NVRAM_ADD_0FILL("nvram")
10011002
trunk/src/mame/drivers/nsmpoker.c
r17996r17997
8383   virtual void video_start();
8484   virtual void palette_init();
8585   UINT32 screen_update_nsmpoker(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
86   INTERRUPT_GEN_MEMBER(nsmpoker_interrupt);
8687};
8788
8889
r17996r17997
145146*  Read / Write Handlers  *
146147**************************/
147148
148static INTERRUPT_GEN( nsmpoker_interrupt )
149INTERRUPT_GEN_MEMBER(nsmpoker_state::nsmpoker_interrupt)
149150{
150   device->execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
151   device.execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
151152}
152153
153154//WRITE8_MEMBER(nsmpoker_state::debug_w)
r17996r17997
398399   MCFG_CPU_ADD("maincpu", TMS9995L, MASTER_CLOCK/2)   /* guess */
399400   MCFG_CPU_PROGRAM_MAP(nsmpoker_map)
400401   MCFG_CPU_IO_MAP(nsmpoker_portmap)
401   MCFG_CPU_VBLANK_INT("screen", nsmpoker_interrupt)
402   MCFG_CPU_VBLANK_INT_DRIVER("screen", nsmpoker_state, nsmpoker_interrupt)
402403
403404   /* video hardware */
404405   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/namconb1.c
r17996r17997
307307   machine.device("maincpu")->execute().set_input_line(state->m_namconb_cpureg[0x02] & 0xf, ASSERT_LINE);
308308}
309309
310static INTERRUPT_GEN( namconb1_interrupt )
310INTERRUPT_GEN_MEMBER(namconb1_state::namconb1_interrupt)
311311{
312   namconb1_state *state = device->machine().driver_data<namconb1_state>();
313312   /**
314313     * 400000 0x00
315314     * 400001 0x00
r17996r17997
344343     * 40001e 0x00
345344     * 40001f 0x00
346345     */
347   int scanline = (state->m_generic_paletteram_32[0x1808/4]&0xffff)-32;
346   int scanline = (m_generic_paletteram_32[0x1808/4]&0xffff)-32;
348347
349   if((!state->m_vblank_irq_active) && (state->m_namconb_cpureg[0x04] & 0xf0)) {
350      device->execute().set_input_line(state->m_namconb_cpureg[0x04] & 0xf, ASSERT_LINE);
351      state->m_vblank_irq_active = 1;
348   if((!m_vblank_irq_active) && (m_namconb_cpureg[0x04] & 0xf0)) {
349      device.execute().set_input_line(m_namconb_cpureg[0x04] & 0xf, ASSERT_LINE);
350      m_vblank_irq_active = 1;
352351   }
353352
354353   if( scanline<0 )
r17996r17997
357356   }
358357   if( scanline < NAMCONB1_VBSTART )
359358   {
360      device->machine().scheduler().timer_set( device->machine().primary_screen->time_until_pos(scanline), FUNC(namconb1_TriggerPOSIRQ ), scanline);
359      machine().scheduler().timer_set( machine().primary_screen->time_until_pos(scanline), FUNC(namconb1_TriggerPOSIRQ ), scanline);
361360   }
362361} /* namconb1_interrupt */
363362
r17996r17997
370369   machine.device("maincpu")->execute().set_input_line(state->m_namconb_cpureg[0x02], ASSERT_LINE);
371370}
372371
373static INTERRUPT_GEN( namconb2_interrupt )
372INTERRUPT_GEN_MEMBER(namconb1_state::namconb2_interrupt)
374373{
375   namconb1_state *state = device->machine().driver_data<namconb1_state>();
376374   /**
377375     * f00000 0x01 // VBLANK irq level
378376     * f00001 0x00
r17996r17997
402400     * f0001e 0x00
403401     * f0001f 0x01
404402     */
405   int scanline = (state->m_generic_paletteram_32[0x1808/4]&0xffff)-32;
403   int scanline = (m_generic_paletteram_32[0x1808/4]&0xffff)-32;
406404
407   if((!state->m_vblank_irq_active) && state->m_namconb_cpureg[0x00]) {
408      device->execute().set_input_line(state->m_namconb_cpureg[0x00], ASSERT_LINE);
409      state->m_vblank_irq_active = 1;
405   if((!m_vblank_irq_active) && m_namconb_cpureg[0x00]) {
406      device.execute().set_input_line(m_namconb_cpureg[0x00], ASSERT_LINE);
407      m_vblank_irq_active = 1;
410408   }
411409
412410   if( scanline<0 )
413411      scanline = 0;
414412
415413   if( scanline < NAMCONB1_VBSTART )
416      device->machine().scheduler().timer_set( device->machine().primary_screen->time_until_pos(scanline), FUNC(namconb2_TriggerPOSIRQ ), scanline);
414      machine().scheduler().timer_set( machine().primary_screen->time_until_pos(scanline), FUNC(namconb2_TriggerPOSIRQ ), scanline);
417415} /* namconb2_interrupt */
418416
419417static void namconb1_cpureg8_w(running_machine &machine, int reg, UINT8 data)
r17996r17997
10091007static MACHINE_CONFIG_START( namconb1, namconb1_state )
10101008   MCFG_CPU_ADD("maincpu", M68EC020,MASTER_CLOCK_HZ/2)
10111009   MCFG_CPU_PROGRAM_MAP(namconb1_am)
1012   MCFG_CPU_VBLANK_INT("screen", namconb1_interrupt)
1010   MCFG_CPU_VBLANK_INT_DRIVER("screen", namconb1_state, namconb1_interrupt)
10131011
10141012   MCFG_CPU_ADD("mcu", M37702, MASTER_CLOCK_HZ/3)
10151013   MCFG_CPU_PROGRAM_MAP(namcoc75_am)
r17996r17997
10411039static MACHINE_CONFIG_START( namconb2, namconb1_state )
10421040   MCFG_CPU_ADD("maincpu", M68EC020,MASTER_CLOCK_HZ/2)
10431041   MCFG_CPU_PROGRAM_MAP(namconb2_am)
1044   MCFG_CPU_VBLANK_INT("screen", namconb2_interrupt)
1042   MCFG_CPU_VBLANK_INT_DRIVER("screen", namconb1_state, namconb2_interrupt)
10451043
10461044   MCFG_CPU_ADD("mcu", M37702, MASTER_CLOCK_HZ/3)
10471045   MCFG_CPU_PROGRAM_MAP(namcoc75_am)
trunk/src/mame/drivers/fcrash.c
r17996r17997
726726   /* basic machine hardware */
727727   MCFG_CPU_ADD("maincpu", M68000, 10000000)
728728   MCFG_CPU_PROGRAM_MAP(fcrash_map)
729   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
729   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
730730
731731   MCFG_CPU_ADD("soundcpu", Z80, 24000000/6) /* ? */
732732   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
777777   /* basic machine hardware */
778778   MCFG_CPU_ADD("maincpu", M68000, 10000000)
779779   MCFG_CPU_PROGRAM_MAP(kodb_map)
780   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
780   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
781781
782782//  MCFG_CPU_ADD("soundcpu", Z80, 3579545)
783783//  MCFG_CPU_PROGRAM_MAP(sub_map)
r17996r17997
933933   /* basic machine hardware */
934934   MCFG_CPU_ADD("maincpu", M68000, 12000000)
935935   MCFG_CPU_PROGRAM_MAP(kodb_map)
936   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
936   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
937937
938938//  MCFG_CPU_ADD("soundcpu", Z80, 3579545)
939939//  MCFG_CPU_PROGRAM_MAP(sub_map)
trunk/src/mame/drivers/othello.c
r17996r17997
417417   MCFG_CPU_ADD("maincpu",Z80,XTAL_8MHz/2)
418418   MCFG_CPU_PROGRAM_MAP(main_map)
419419   MCFG_CPU_IO_MAP(main_portmap)
420   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
420   MCFG_CPU_VBLANK_INT_DRIVER("screen", othello_state, irq0_line_hold)
421421
422422   MCFG_CPU_ADD("audiocpu",Z80,XTAL_3_579545MHz)
423423   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/f-32.c
r17996r17997
137137   MCFG_CPU_ADD("maincpu", E132XN, 20000000*4)   /* 4x internal multiplier */
138138   MCFG_CPU_PROGRAM_MAP(common_map)
139139   MCFG_CPU_IO_MAP(mosaicf2_io)
140   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
140   MCFG_CPU_VBLANK_INT_DRIVER("screen", mosaicf2_state, irq0_line_hold)
141141
142142   MCFG_EEPROM_93C46_ADD("eeprom")
143143
trunk/src/mame/drivers/strnskil.c
r17996r17997
356356
357357   MCFG_CPU_ADD("sub", Z80,8000000/2) /* 4.000MHz */
358358   MCFG_CPU_PROGRAM_MAP(strnskil_map2)
359   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
359   MCFG_CPU_PERIODIC_INT_DRIVER(strnskil_state, irq0_line_hold, 2*60)
360360
361361//  MCFG_QUANTUM_PERFECT_CPU("maincpu")
362362   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
trunk/src/mame/drivers/bfm_sc5.c
r17996r17997
3333   required_device<cpu_device> m_maincpu;
3434public:
3535   DECLARE_DRIVER_INIT(sc5);
36   INTERRUPT_GEN_MEMBER(sc5_fake_timer_int);
3637};
3738
3839
r17996r17997
4546static INPUT_PORTS_START(  sc5 )
4647INPUT_PORTS_END
4748
48static INTERRUPT_GEN( sc5_fake_timer_int )
49INTERRUPT_GEN_MEMBER(sc5_state::sc5_fake_timer_int)
4950{
5051   // this should be coming from the Timer / SIM modules of the Coldfire
51   device->machine().device("maincpu")->execute().set_input_line_and_vector(5, HOLD_LINE, 0x8c);
52   machine().device("maincpu")->execute().set_input_line_and_vector(5, HOLD_LINE, 0x8c);
5253}
5354
5455static MACHINE_CONFIG_START( sc5, sc5_state )
5556   MCFG_CPU_ADD("maincpu", MCF5206E, 40000000) /* MCF5206eFT */
5657   MCFG_CPU_PROGRAM_MAP(sc5_map)
57   MCFG_CPU_PERIODIC_INT(sc5_fake_timer_int,1000)
58   MCFG_CPU_PERIODIC_INT_DRIVER(sc5_state, sc5_fake_timer_int, 1000)
5859
5960   MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
6061   /* unknown sound */
trunk/src/mame/drivers/model2.c
r17996r17997
21112111   MCFG_CPU_ADD("drivecpu", Z80, 16000000/4) //???
21122112   MCFG_CPU_PROGRAM_MAP(drive_map)
21132113   MCFG_CPU_IO_MAP(drive_io_map)
2114//  MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
2114   MCFG_CPU_VBLANK_INT_DRIVER("screen", model2_state, irq0_line_hold)
21152115MACHINE_CONFIG_END
21162116
21172117static const sharc_config sharc_cfg =
trunk/src/mame/drivers/majorpkr.c
r17996r17997
10321032   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)   /* 6 MHz */
10331033   MCFG_CPU_PROGRAM_MAP(map)
10341034   MCFG_CPU_IO_MAP(portmap)
1035   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1035   MCFG_CPU_VBLANK_INT_DRIVER("screen", majorpkr_state, irq0_line_hold)
10361036
10371037   MCFG_NVRAM_ADD_0FILL("nvram")
10381038
trunk/src/mame/drivers/sshangha.c
r17996r17997
395395   /* basic machine hardware */
396396   MCFG_CPU_ADD("maincpu", M68000, 28000000/2)
397397   MCFG_CPU_PROGRAM_MAP(sshangha_map)
398   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
398   MCFG_CPU_VBLANK_INT_DRIVER("screen", sshangha_state, irq6_line_hold)
399399
400400   MCFG_CPU_ADD("audiocpu", Z80, 16000000/4)
401401   MCFG_CPU_PROGRAM_MAP(sshangha_sound_map)
trunk/src/mame/drivers/wiping.c
r17996r17997
262262   GFXDECODE_ENTRY( "gfx2", 0, spritelayout, 64*4, 64 )
263263GFXDECODE_END
264264
265static INTERRUPT_GEN( vblank_irq )
265INTERRUPT_GEN_MEMBER(wiping_state::vblank_irq)
266266{
267   wiping_state *state = device->machine().driver_data<wiping_state>();
268267
269   if(state->m_main_irq_mask)
270      device->execute().set_input_line(0, HOLD_LINE);
268   if(m_main_irq_mask)
269      device.execute().set_input_line(0, HOLD_LINE);
271270}
272271
273static INTERRUPT_GEN( sound_timer_irq )
272INTERRUPT_GEN_MEMBER(wiping_state::sound_timer_irq)
274273{
275   wiping_state *state = device->machine().driver_data<wiping_state>();
276274
277   if(state->m_sound_irq_mask)
278      device->execute().set_input_line(0, HOLD_LINE);
275   if(m_sound_irq_mask)
276      device.execute().set_input_line(0, HOLD_LINE);
279277}
280278
281279
r17996r17997
285283   /* basic machine hardware */
286284   MCFG_CPU_ADD("maincpu", Z80,18432000/6)   /* 3.072 MHz */
287285   MCFG_CPU_PROGRAM_MAP(main_map)
288   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
286   MCFG_CPU_VBLANK_INT_DRIVER("screen", wiping_state, vblank_irq)
289287
290288   MCFG_CPU_ADD("audiocpu", Z80,18432000/6)   /* 3.072 MHz */
291289   MCFG_CPU_PROGRAM_MAP(sound_map)
292   MCFG_CPU_PERIODIC_INT(sound_timer_irq,120)   /* periodic interrupt, don't know about the frequency */
290   MCFG_CPU_PERIODIC_INT_DRIVER(wiping_state, sound_timer_irq, 120)   /* periodic interrupt, don't know about the frequency */
293291
294292   /* video hardware */
295293   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/popeye.c
r17996r17997
2121#include "sound/ay8910.h"
2222#include "includes/popeye.h"
2323
24static INTERRUPT_GEN( popeye_interrupt )
24INTERRUPT_GEN_MEMBER(popeye_state::popeye_interrupt)
2525{
2626   /* NMIs are enabled by the I register?? How can that be? */
27   if (device->state().state_int(Z80_I) & 1)   /* skyskipr: 0/1, popeye: 2/3 but also 0/1 */
28      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
27   if (device.state().state_int(Z80_I) & 1)   /* skyskipr: 0/1, popeye: 2/3 but also 0/1 */
28      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
2929}
3030
3131
r17996r17997
428428   MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz/2)   /* 4 MHz */
429429   MCFG_CPU_PROGRAM_MAP(skyskipr_map)
430430   MCFG_CPU_IO_MAP(popeye_io_map)
431   MCFG_CPU_VBLANK_INT("screen", popeye_interrupt)
431   MCFG_CPU_VBLANK_INT_DRIVER("screen", popeye_state, popeye_interrupt)
432432
433433   /* video hardware */
434434   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gstream.c
r17996r17997
565565   MCFG_CPU_ADD("maincpu", E132XT, 16000000*4)   /* 4x internal multiplier */
566566   MCFG_CPU_PROGRAM_MAP(gstream_32bit_map)
567567   MCFG_CPU_IO_MAP(gstream_io)
568   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
568   MCFG_CPU_VBLANK_INT_DRIVER("screen", gstream_state, irq0_line_hold)
569569
570570
571571   MCFG_NVRAM_ADD_1FILL("nvram")
trunk/src/mame/drivers/4enraya.c
r17996r17997
321321   MCFG_CPU_ADD("maincpu",Z80,MAIN_CLOCK/2)
322322   MCFG_CPU_PROGRAM_MAP(main_map)
323323   MCFG_CPU_IO_MAP(main_portmap)
324   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60) // unknown timing
324   MCFG_CPU_PERIODIC_INT_DRIVER(_4enraya_state, irq0_line_hold, 4*60) // unknown timing
325325
326326
327327   /* video hardware */
trunk/src/mame/drivers/compgolf.c
r17996r17997
248248   /* basic machine hardware */
249249   MCFG_CPU_ADD("maincpu", M6809, 2000000)
250250   MCFG_CPU_PROGRAM_MAP(compgolf_map)
251   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
251   MCFG_CPU_VBLANK_INT_DRIVER("screen", compgolf_state, nmi_line_pulse)
252252
253253
254254   /* video hardware */
trunk/src/mame/drivers/pushman.c
r17996r17997
429429   /* basic machine hardware */
430430   MCFG_CPU_ADD("maincpu", M68000, 8000000)
431431   MCFG_CPU_PROGRAM_MAP(pushman_map)
432   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
432   MCFG_CPU_VBLANK_INT_DRIVER("screen", pushman_state, irq2_line_hold)
433433
434434   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
435435   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
479479   /* basic machine hardware */
480480   MCFG_CPU_ADD("maincpu", M68000, 8000000)
481481   MCFG_CPU_PROGRAM_MAP(bballs_map)
482   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
482   MCFG_CPU_VBLANK_INT_DRIVER("screen", pushman_state, irq2_line_hold)
483483
484484   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
485485   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/monzagp.c
r17996r17997
259259   MCFG_CPU_ADD("maincpu", I8035, 12000000/32)   /* 400KHz ??? - Main board Crystal is 12MHz */
260260   MCFG_CPU_PROGRAM_MAP(monzagp_map)
261261   MCFG_CPU_IO_MAP(monzagp_io)
262   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
262   MCFG_CPU_VBLANK_INT_DRIVER("screen", monzagp_state, irq0_line_hold)
263263
264264   /* video hardware */
265265   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/hyperspt.c
r17996r17997
272272   GFXDECODE_ENTRY( "gfx2", 0, roadf_charlayout,    16*16, 16 )
273273GFXDECODE_END
274274
275static INTERRUPT_GEN( vblank_irq )
275INTERRUPT_GEN_MEMBER(hyperspt_state::vblank_irq)
276276{
277   hyperspt_state *state = device->machine().driver_data<hyperspt_state>();
278277
279   if(state->m_irq_mask)
280      device->execute().set_input_line(0, HOLD_LINE);
278   if(m_irq_mask)
279      device.execute().set_input_line(0, HOLD_LINE);
281280}
282281
283282//-------------------------------------------------
r17996r17997
294293   /* basic machine hardware */
295294   MCFG_CPU_ADD("maincpu", M6809, XTAL_18_432MHz/12)   /* verified on pcb */
296295   MCFG_CPU_PROGRAM_MAP(hyperspt_map)
297   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
296   MCFG_CPU_VBLANK_INT_DRIVER("screen", hyperspt_state, vblank_irq)
298297
299298   MCFG_CPU_ADD("audiocpu", Z80,XTAL_14_31818MHz/4) /* verified on pcb */
300299   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/hnayayoi.c
r17996r17997
560560   MCFG_CPU_ADD("maincpu", Z80, 20000000/4 )        /* 5 MHz ???? */
561561   MCFG_CPU_PROGRAM_MAP(hnayayoi_map)
562562   MCFG_CPU_IO_MAP(hnayayoi_io_map)
563   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
564   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 8000)
563   MCFG_CPU_VBLANK_INT_DRIVER("screen", hnayayoi_state,  irq0_line_hold)
564   MCFG_CPU_PERIODIC_INT_DRIVER(hnayayoi_state, nmi_line_pulse,  8000)
565565
566566
567567   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/shanghai.c
r17996r17997
3939   virtual void video_start();
4040   DECLARE_PALETTE_INIT(shanghai);
4141   UINT32 screen_update_shanghai(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(shanghai_interrupt);
4243};
4344
4445
r17996r17997
124125   return 0;
125126}
126127
127static INTERRUPT_GEN( shanghai_interrupt )
128INTERRUPT_GEN_MEMBER(shanghai_state::shanghai_interrupt)
128129{
129   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x80);
130   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x80);
130131}
131132
132133WRITE16_MEMBER(shanghai_state::shanghai_coin_w)
r17996r17997
446447   MCFG_CPU_ADD("maincpu", V30,16000000/2)   /* ? */
447448   MCFG_CPU_PROGRAM_MAP(shanghai_map)
448449   MCFG_CPU_IO_MAP(shanghai_portmap)
449   MCFG_CPU_VBLANK_INT("screen", shanghai_interrupt)
450   MCFG_CPU_VBLANK_INT_DRIVER("screen", shanghai_state, shanghai_interrupt)
450451
451452   /* video hardware */
452453   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
479480   MCFG_CPU_ADD("maincpu", V30,16000000/2)   /* ? */
480481   MCFG_CPU_PROGRAM_MAP(shangha2_map)
481482   MCFG_CPU_IO_MAP(shangha2_portmap)
482   MCFG_CPU_VBLANK_INT("screen", shanghai_interrupt)
483   MCFG_CPU_VBLANK_INT_DRIVER("screen", shanghai_state, shanghai_interrupt)
483484
484485   /* video hardware */
485486   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
510511   /* basic machine hardware */
511512   MCFG_CPU_ADD("maincpu", V30,16000000/2)   /* ? */
512513   MCFG_CPU_PROGRAM_MAP(kothello_map)
513   MCFG_CPU_VBLANK_INT("screen", shanghai_interrupt)
514   MCFG_CPU_VBLANK_INT_DRIVER("screen", shanghai_state, shanghai_interrupt)
514515
515516   SEIBU3A_SOUND_SYSTEM_CPU(14318180/4)
516517
trunk/src/mame/drivers/amaticmg.c
r17996r17997
454454   DECLARE_PALETTE_INIT(amaticmg2);
455455   UINT32 screen_update_amaticmg(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
456456   UINT32 screen_update_amaticmg2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
457   INTERRUPT_GEN_MEMBER(amaticmg2_irq);
457458};
458459
459460
r17996r17997
866867   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)      /* WRONG! */
867868   MCFG_CPU_PROGRAM_MAP(amaticmg_map)
868869   MCFG_CPU_IO_MAP(amaticmg_portmap)
869   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) // no NMI mask?
870   MCFG_CPU_VBLANK_INT_DRIVER("screen", amaticmg_state, nmi_line_pulse) // no NMI mask?
870871
871872//  MCFG_NVRAM_ADD_0FILL("nvram")
872873
r17996r17997
903904MACHINE_CONFIG_END
904905
905906
906static INTERRUPT_GEN( amaticmg2_irq )
907INTERRUPT_GEN_MEMBER(amaticmg_state::amaticmg2_irq)
907908{
908   amaticmg_state *state = device->machine().driver_data<amaticmg_state>();
909909
910   if(state->m_nmi_mask)
911      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
910   if(m_nmi_mask)
911      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
912912}
913913
914914
r17996r17997
916916
917917   MCFG_CPU_MODIFY("maincpu")
918918   MCFG_CPU_IO_MAP(amaticmg2_portmap)
919   MCFG_CPU_VBLANK_INT("screen", amaticmg2_irq)
919   MCFG_CPU_VBLANK_INT_DRIVER("screen", amaticmg_state, amaticmg2_irq)
920920
921921   MCFG_SCREEN_MODIFY("screen")
922922   MCFG_SCREEN_UPDATE_DRIVER(amaticmg_state, screen_update_amaticmg2)
trunk/src/mame/drivers/scramble.c
r17996r17997
15331533   MCFG_CPU_REPLACE("maincpu", S2650, 18432000/6)
15341534   MCFG_CPU_PROGRAM_MAP(hunchbks_map)
15351535   MCFG_CPU_IO_MAP(hunchbks_readport)
1536   MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
1536   MCFG_CPU_VBLANK_INT_DRIVER("screen", scramble_state, hunchbks_vh_interrupt)
15371537
15381538   MCFG_SCREEN_MODIFY("screen")
15391539   MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500))
trunk/src/mame/drivers/taxidriv.c
r17996r17997
369369   /* basic machine hardware */
370370   MCFG_CPU_ADD("maincpu", Z80,4000000)   /* 4 MHz ??? */
371371   MCFG_CPU_PROGRAM_MAP(main_map)
372   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", taxidriv_state, irq0_line_hold)
373373
374374   MCFG_CPU_ADD("sub", Z80,4000000)   /* 4 MHz ??? */
375375   MCFG_CPU_PROGRAM_MAP(cpu2_map)
376   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* ??? */
376   MCFG_CPU_VBLANK_INT_DRIVER("screen", taxidriv_state, irq0_line_hold)   /* ??? */
377377
378378   MCFG_CPU_ADD("audiocpu", Z80,4000000)   /* 4 MHz ??? */
379379   MCFG_CPU_PROGRAM_MAP(cpu3_map)
380380   MCFG_CPU_IO_MAP(cpu3_port_map)
381   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* ??? */
381   MCFG_CPU_VBLANK_INT_DRIVER("screen", taxidriv_state, irq0_line_hold)   /* ??? */
382382
383383   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* 100 CPU slices per frame - an high value to ensure proper */
384384                     /* synchronization of the CPUs */
trunk/src/mame/drivers/avt.c
r17996r17997
445445   virtual void video_start();
446446   virtual void palette_init();
447447   UINT32 screen_update_avt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
448   INTERRUPT_GEN_MEMBER(avt_vblank_irq);
448449};
449450
450451#define mc6845_h_char_total    (state->m_crtc_vreg[0])
r17996r17997
881882*********************************************/
882883
883884/* IM 2 */
884static INTERRUPT_GEN( avt_vblank_irq )
885INTERRUPT_GEN_MEMBER(avt_state::avt_vblank_irq)
885886{
886   avt_state *state = device->machine().driver_data<avt_state>();
887887
888   state->m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0x06);
888   m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0x06);
889889}
890890
891891static MACHINE_CONFIG_START( avt, avt_state )
r17996r17997
894894   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)   /* guess */
895895   MCFG_CPU_PROGRAM_MAP(avt_map)
896896   MCFG_CPU_IO_MAP(avt_portmap)
897   MCFG_CPU_VBLANK_INT("screen", avt_vblank_irq)
897   MCFG_CPU_VBLANK_INT_DRIVER("screen", avt_state, avt_vblank_irq)
898898
899899   /* video hardware */
900900   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mole.c
r17996r17997
316316   /* basic machine hardware */
317317   MCFG_CPU_ADD("maincpu", M6502, 4000000) // ???
318318   MCFG_CPU_PROGRAM_MAP(mole_map)
319   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
319   MCFG_CPU_VBLANK_INT_DRIVER("screen", mole_state, irq0_line_hold)
320320
321321
322322   /* video hardware */
trunk/src/mame/drivers/pitnrun.c
r17996r17997
7070#include "includes/pitnrun.h"
7171
7272
73static INTERRUPT_GEN( pitnrun_nmi_source )
73INTERRUPT_GEN_MEMBER(pitnrun_state::pitnrun_nmi_source)
7474{
75   pitnrun_state *state = device->machine().driver_data<pitnrun_state>();
76   if(state->m_nmi) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
75   if(m_nmi) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
7776}
7877
7978WRITE8_MEMBER(pitnrun_state::nmi_enable_w)
r17996r17997
231230static MACHINE_CONFIG_START( pitnrun, pitnrun_state )
232231   MCFG_CPU_ADD("maincpu", Z80,XTAL_18_432MHz/6)      /* verified on pcb */
233232   MCFG_CPU_PROGRAM_MAP(pitnrun_map)
234   MCFG_CPU_VBLANK_INT("screen", pitnrun_nmi_source)
233   MCFG_CPU_VBLANK_INT_DRIVER("screen", pitnrun_state, pitnrun_nmi_source)
235234
236235   MCFG_CPU_ADD("audiocpu", Z80, XTAL_5MHz/2)         /* verified on pcb */
237236   MCFG_CPU_PROGRAM_MAP(pitnrun_sound_map)
238237   MCFG_CPU_IO_MAP(pitnrun_sound_io_map)
239   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
238   MCFG_CPU_VBLANK_INT_DRIVER("screen", pitnrun_state, irq0_line_hold)
240239
241240   MCFG_CPU_ADD("mcu", M68705,XTAL_18_432MHz/6)      /* verified on pcb */
242241   MCFG_CPU_PROGRAM_MAP(pitnrun_mcu_map)
trunk/src/mame/drivers/missb2.c
r17996r17997
3939   DECLARE_MACHINE_START(missb2);
4040   DECLARE_MACHINE_RESET(missb2);
4141   UINT32 screen_update_missb2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
42   INTERRUPT_GEN_MEMBER(missb2_interrupt);
4243};
4344
4445
r17996r17997
428429
429430/* Interrupt Generator */
430431
431static INTERRUPT_GEN( missb2_interrupt )
432INTERRUPT_GEN_MEMBER(missb2_state::missb2_interrupt)
432433{
433   device->execute().set_input_line(0, HOLD_LINE);
434   device.execute().set_input_line(0, HOLD_LINE);
434435}
435436
436437/* Machine Driver */
r17996r17997
462463   /* basic machine hardware */
463464   MCFG_CPU_ADD("maincpu", Z80, MAIN_XTAL/4)   // 6 MHz
464465   MCFG_CPU_PROGRAM_MAP(master_map)
465   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
466   MCFG_CPU_VBLANK_INT_DRIVER("screen", missb2_state, irq0_line_hold)
466467
467468   MCFG_CPU_ADD("slave", Z80, MAIN_XTAL/4)   // 6 MHz
468469   MCFG_CPU_PROGRAM_MAP(slave_map)
469   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
470   MCFG_CPU_VBLANK_INT_DRIVER("screen", missb2_state, irq0_line_hold)
470471
471472   MCFG_CPU_ADD("audiocpu", Z80, MAIN_XTAL/8)   // 3 MHz
472473   MCFG_CPU_PROGRAM_MAP(sound_map)
473//  MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
474   MCFG_CPU_VBLANK_INT("screen", missb2_interrupt)
474   MCFG_CPU_VBLANK_INT_DRIVER("screen", missb2_state,  irq0_line_hold)
475   MCFG_CPU_VBLANK_INT_DRIVER("screen", missb2_state,  missb2_interrupt)
475476
476477   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // 100 CPU slices per frame - a high value to ensure proper synchronization of the CPUs
477478
trunk/src/mame/drivers/tehkanwc.c
r17996r17997
642642   /* basic machine hardware */
643643   MCFG_CPU_ADD("maincpu", Z80, 18432000/4)   /* 18.432000 / 4 */
644644   MCFG_CPU_PROGRAM_MAP(main_mem)
645   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
645   MCFG_CPU_VBLANK_INT_DRIVER("screen", tehkanwc_state, irq0_line_hold)
646646
647647   MCFG_CPU_ADD("sub", Z80, 18432000/4)
648648   MCFG_CPU_PROGRAM_MAP(sub_mem)
649   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
649   MCFG_CPU_VBLANK_INT_DRIVER("screen", tehkanwc_state, irq0_line_hold)
650650
651651   MCFG_CPU_ADD("audiocpu", Z80, 18432000/4)
652652   MCFG_CPU_PROGRAM_MAP(sound_mem)
653653   MCFG_CPU_IO_MAP(sound_port)
654   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
654   MCFG_CPU_VBLANK_INT_DRIVER("screen", tehkanwc_state, irq0_line_hold)
655655
656656   MCFG_QUANTUM_TIME(attotime::from_hz(600))   /* 10 CPU slices per frame - seems enough to keep the CPUs in sync */
657657
trunk/src/mame/drivers/bionicc.c
r17996r17997
362362     * schematics indicate that nmi_line is set on  M680000 access with AB1=1
363363     * and IOCS=0 (active low), see pages A-1/10, A-4/10 in schematics
364364     */
365   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,4*60)
365   MCFG_CPU_PERIODIC_INT_DRIVER(bionicc_state, nmi_line_pulse, 4*60)
366366
367367
368368   /* video hardware */
trunk/src/mame/drivers/photon.c
r17996r17997
3737   virtual void machine_reset();
3838   virtual void video_start();
3939   UINT32 screen_update_photon(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
40   INTERRUPT_GEN_MEMBER(pk8000_interrupt);
4041};
4142
4243
r17996r17997
185186   PORT_BIT(0xff, IP_ACTIVE_HIGH, IPT_UNUSED)
186187INPUT_PORTS_END
187188
188static INTERRUPT_GEN( pk8000_interrupt )
189INTERRUPT_GEN_MEMBER(photon_state::pk8000_interrupt)
189190{
190   device->execute().set_input_line(0, HOLD_LINE);
191   device.execute().set_input_line(0, HOLD_LINE);
191192}
192193
193194static IRQ_CALLBACK(pk8000_irq_callback)
r17996r17997
217218    MCFG_CPU_ADD("maincpu",I8080, 1780000)
218219    MCFG_CPU_PROGRAM_MAP(pk8000_mem)
219220    MCFG_CPU_IO_MAP(pk8000_io)
220    MCFG_CPU_VBLANK_INT("screen", pk8000_interrupt)
221   MCFG_CPU_VBLANK_INT_DRIVER("screen", photon_state, pk8000_interrupt)
221222
222223
223224    /* video hardware */
trunk/src/mame/drivers/citycon.c
r17996r17997
206206   /* basic machine hardware */
207207   MCFG_CPU_ADD("maincpu", M6809, 2048000)        /* 2.048 MHz ??? */
208208   MCFG_CPU_PROGRAM_MAP(citycon_map)
209   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
209   MCFG_CPU_VBLANK_INT_DRIVER("screen", citycon_state, irq0_line_assert)
210210
211211   MCFG_CPU_ADD("audiocpu", M6809, 640000)       /* 0.640 MHz ??? */
212212   MCFG_CPU_PROGRAM_MAP(sound_map)
213//  MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) //actually unused, probably it was during development
213   MCFG_CPU_VBLANK_INT_DRIVER("screen", citycon_state, irq0_line_hold) //actually unused, probably it was during development
214214
215215
216216   /* video hardware */
trunk/src/mame/drivers/sigmab52.c
r17996r17997
150150   virtual void video_start();
151151   virtual void palette_init();
152152   UINT32 screen_update_jwildb52(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
153   INTERRUPT_GEN_MEMBER(timer_irq);
153154};
154155
155156
r17996r17997
536537*   Interrupts Gen (to fix)   *
537538******************************/
538539
539static INTERRUPT_GEN( timer_irq )
540INTERRUPT_GEN_MEMBER(sigmab52_state::timer_irq)
540541{
541   generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
542   generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
542543}
543544
544545
r17996r17997
591592   /* basic machine hardware */
592593   MCFG_CPU_ADD("maincpu", M6809, MAIN_CLOCK/9)   /* 2 MHz */
593594   MCFG_CPU_PROGRAM_MAP(jwildb52_map)
594   MCFG_CPU_VBLANK_INT("screen", timer_irq)   /* Fix me */
595   MCFG_CPU_VBLANK_INT_DRIVER("screen", sigmab52_state, timer_irq)   /* Fix me */
595596
596597#if 0
597598   MCFG_CPU_ADD("audiocpu", M6809, MAIN_CLOCK/9)   /* 2 MHz */
598599   MCFG_CPU_PROGRAM_MAP(sound_prog_map)
599600   //temporary teh same int as for main cpu
600   MCFG_CPU_PERIODIC_INT(timer_irq, 1000)         /* Fix me */
601   MCFG_CPU_PERIODIC_INT_DRIVER(sigmab52_state, timer_irq, 1000)         /* Fix me */
601602#endif
602603
603604
trunk/src/mame/drivers/playmark.c
r17996r17997
10691069   /* basic machine hardware */
10701070   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
10711071   MCFG_CPU_PROGRAM_MAP(bigtwin_main_map)
1072   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1072   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq2_line_hold)
10731073
10741074   MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)   /* 3MHz */
10751075   /* Program and Data Maps are internal to the MCU */
r17996r17997
11031103   /* basic machine hardware */
11041104   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
11051105   MCFG_CPU_PROGRAM_MAP(bigtwinb_main_map)
1106   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1106   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq2_line_hold)
11071107
11081108   MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)   /* 3MHz */
11091109   /* Program and Data Maps are internal to the MCU */
r17996r17997
11371137   /* basic machine hardware */
11381138   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
11391139   MCFG_CPU_PROGRAM_MAP(wbeachvl_main_map)
1140   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1140   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq2_line_hold)
11411141
11421142//  MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)   /* 3MHz */
11431143   /* Program and Data Maps are internal to the MCU */
r17996r17997
11741174   /* basic machine hardware */
11751175   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
11761176   MCFG_CPU_PROGRAM_MAP(excelsr_main_map)
1177   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1177   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq2_line_hold)
11781178
11791179   MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)   /* 3MHz */
11801180   /* Program and Data Maps are internal to the MCU */
r17996r17997
12081208   /* basic machine hardware */
12091209   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)   /* verified on pcb */
12101210   MCFG_CPU_PROGRAM_MAP(hotmind_main_map)
1211   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1211   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq2_line_hold)
12121212
12131213   MCFG_CPU_ADD("audiocpu", PIC16C57, XTAL_24MHz/2)   /* verified on pcb */
12141214   /* Program and Data Maps are internal to the MCU */
r17996r17997
12451245   /* basic machine hardware */
12461246   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)   /* verified on pcb */
12471247   MCFG_CPU_PROGRAM_MAP(hrdtimes_main_map)
1248   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
1248   MCFG_CPU_VBLANK_INT_DRIVER("screen", playmark_state, irq6_line_hold)
12491249
12501250//  MCFG_CPU_ADD("audiocpu", PIC16C57, XTAL_24MHz/2)    /* verified on pcb */
12511251   /* Program and Data Maps are internal to the MCU */
trunk/src/mame/drivers/ampoker2.c
r17996r17997
11691169   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/2)      /* 3 MHz */
11701170   MCFG_CPU_PROGRAM_MAP(ampoker2_map)
11711171   MCFG_CPU_IO_MAP(ampoker2_io_map)
1172   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 1536)
1172   MCFG_CPU_PERIODIC_INT_DRIVER(ampoker2_state, nmi_line_pulse, 1536)
11731173   MCFG_WATCHDOG_TIME_INIT(attotime::from_msec(200))   /* 200 ms, measured */
11741174
11751175   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/pgm.c
r17996r17997
520520   /* basic machine hardware */
521521   MCFG_CPU_ADD("maincpu", M68000, 20000000) /* 20 mhz! verified on real board */
522522   MCFG_CPU_PROGRAM_MAP(pgm_basic_mem)
523   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
523   MCFG_CPU_VBLANK_INT_DRIVER("screen", pgm_state, irq6_line_hold)
524524   MCFG_TIMER_ADD_SCANLINE("scantimer", pgm_interrupt, "screen", 0, 1)
525525
526526   MCFG_CPU_ADD("soundcpu", Z80, 33868800/4)
trunk/src/mame/drivers/namcos21.c
r17996r17997
14891489static MACHINE_CONFIG_START( namcos21, namcos21_state )
14901490   MCFG_CPU_ADD("maincpu", M68000,12288000) /* Master */
14911491   MCFG_CPU_PROGRAM_MAP(namcos21_68k_master)
1492   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1492   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_master_vblank)
14931493
14941494   MCFG_CPU_ADD("slave", M68000,12288000) /* Slave */
14951495   MCFG_CPU_PROGRAM_MAP(namcos21_68k_slave)
1496   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1496   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_slave_vblank)
14971497
14981498   MCFG_CPU_ADD("audiocpu", M6809,3072000) /* Sound */
14991499   MCFG_CPU_PROGRAM_MAP(am_sound_winrun)
1500   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1501   MCFG_CPU_PERIODIC_INT(irq1_line_hold,120)
1500   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq0_line_hold, 2*60)
1501   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq1_line_hold, 120)
15021502
15031503   MCFG_CPU_ADD("mcu", HD63705,2048000) /* IO */
15041504   MCFG_CPU_PROGRAM_MAP(am_mcu_winrun)
1505   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1505   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, irq0_line_hold)
15061506
15071507   MCFG_CPU_ADD("dspmaster", TMS32025,24000000) /* 24 MHz? overclocked */
15081508   MCFG_CPU_PROGRAM_MAP(master_dsp_program)
r17996r17997
15491549static MACHINE_CONFIG_START( driveyes, namcos21_state )
15501550   MCFG_CPU_ADD("maincpu", M68000,12288000) /* Master */
15511551   MCFG_CPU_PROGRAM_MAP(driveyes_68k_master)
1552   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1552   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_master_vblank)
15531553
15541554   MCFG_CPU_ADD("slave", M68000,12288000) /* Slave */
15551555   MCFG_CPU_PROGRAM_MAP(driveyes_68k_slave)
1556   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1556   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_slave_vblank)
15571557
15581558   MCFG_CPU_ADD("audiocpu", M6809,3072000) /* Sound */
15591559   MCFG_CPU_PROGRAM_MAP(am_sound_winrun)
1560   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1561   MCFG_CPU_PERIODIC_INT(irq1_line_hold,120)
1560   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq0_line_hold, 2*60)
1561   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq1_line_hold, 120)
15621562
15631563   MCFG_CPU_ADD("mcu", HD63705,2048000) /* IO */
15641564   MCFG_CPU_PROGRAM_MAP(am_mcu_winrun)
1565   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1565   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, irq0_line_hold)
15661566
15671567   MCFG_CPU_ADD("dsp", TMS32025,24000000*2) /* 24 MHz? overclocked */
15681568   MCFG_CPU_PROGRAM_MAP(winrun_dsp_program)
r17996r17997
16041604static MACHINE_CONFIG_START( winrun, namcos21_state )
16051605   MCFG_CPU_ADD("maincpu", M68000,12288000) /* Master */
16061606   MCFG_CPU_PROGRAM_MAP(am_master_winrun)
1607   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1607   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_master_vblank)
16081608
16091609   MCFG_CPU_ADD("slave", M68000,12288000) /* Slave */
16101610   MCFG_CPU_PROGRAM_MAP(am_slave_winrun)
1611   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1611   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_slave_vblank)
16121612
16131613   MCFG_CPU_ADD("audiocpu", M6809,3072000) /* Sound */
16141614   MCFG_CPU_PROGRAM_MAP(am_sound_winrun)
1615   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1616   MCFG_CPU_PERIODIC_INT(irq1_line_hold,120)
1615   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq0_line_hold, 2*60)
1616   MCFG_CPU_PERIODIC_INT_DRIVER(namcos21_state, irq1_line_hold, 120)
16171617
16181618   MCFG_CPU_ADD("mcu", HD63705,2048000) /* IO */
16191619   MCFG_CPU_PROGRAM_MAP(am_mcu_winrun)
1620   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1620   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, irq0_line_hold)
16211621
16221622   MCFG_CPU_ADD("dsp", TMS32025,24000000) /* 24 MHz? overclocked */
16231623   MCFG_CPU_PROGRAM_MAP(winrun_dsp_program)
r17996r17997
16261626
16271627   MCFG_CPU_ADD("gpu", M68000,12288000) /* graphics coprocessor */
16281628   MCFG_CPU_PROGRAM_MAP(am_gpu_winrun)
1629   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_gpu_vblank)
1629   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos21_state, namcos2_68k_gpu_vblank)
16301630
16311631   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* 100 CPU slices per frame */
16321632
trunk/src/mame/drivers/jangou.c
r17996r17997
991991   MCFG_CPU_ADD("cpu0", Z80, MASTER_CLOCK / 8)
992992   MCFG_CPU_PROGRAM_MAP(cpu0_map)
993993   MCFG_CPU_IO_MAP(cpu0_io)
994   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
994   MCFG_CPU_VBLANK_INT_DRIVER("screen", jangou_state, irq0_line_hold)
995995
996996   MCFG_CPU_ADD("cpu1", Z80, MASTER_CLOCK / 8)
997997   MCFG_CPU_PROGRAM_MAP(cpu1_map)
trunk/src/mame/drivers/darius.c
r17996r17997
918918   /* basic machine hardware */
919919   MCFG_CPU_ADD("maincpu", M68000,16000000/2)   /* 8 MHz ? */
920920   MCFG_CPU_PROGRAM_MAP(darius_map)
921   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
921   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", darius_state, irq4_line_hold)
922922
923923   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)   /* 4 MHz ? */
924924   MCFG_CPU_PROGRAM_MAP(darius_sound_map)
925925
926926   MCFG_CPU_ADD("cpub", M68000,16000000/2)   /* 8 MHz ? */
927927   MCFG_CPU_PROGRAM_MAP(darius_cpub_map)
928   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
928   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", darius_state, irq4_line_hold)
929929
930930   MCFG_CPU_ADD("adpcm", Z80,8000000/2) /* 4 MHz ? */   /* ADPCM player using MSM5205 */
931931   MCFG_CPU_PROGRAM_MAP(darius_sound2_map)
trunk/src/mame/drivers/capbowl.c
r17996r17997
105105 *
106106 *************************************/
107107
108static INTERRUPT_GEN( capbowl_interrupt )
108INTERRUPT_GEN_MEMBER(capbowl_state::capbowl_interrupt)
109109{
110   if (device->machine().root_device().ioport("SERVICE")->read() & 1)                  /* get status of the F2 key */
111      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);   /* trigger self test */
110   if (machine().root_device().ioport("SERVICE")->read() & 1)                  /* get status of the F2 key */
111      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);   /* trigger self test */
112112}
113113
114114
r17996r17997
361361   /* basic machine hardware */
362362   MCFG_CPU_ADD("maincpu", M6809E, MASTER_CLOCK)
363363   MCFG_CPU_PROGRAM_MAP(capbowl_map)
364   MCFG_CPU_VBLANK_INT("screen", capbowl_interrupt)
364   MCFG_CPU_VBLANK_INT_DRIVER("screen", capbowl_state, capbowl_interrupt)
365365
366366   MCFG_CPU_ADD("audiocpu", M6809E, MASTER_CLOCK)
367367   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/ssingles.c
r17996r17997
173173   DECLARE_CUSTOM_INPUT_MEMBER(controls_r);
174174   DECLARE_DRIVER_INIT(ssingles);
175175   virtual void video_start();
176   INTERRUPT_GEN_MEMBER(atamanot_irq);
176177};
177178
178179//fake palette
r17996r17997
568569   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* ? MHz */
569570   MCFG_CPU_PROGRAM_MAP(ssingles_map)
570571   MCFG_CPU_IO_MAP(ssingles_io_map)
571   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
572   MCFG_CPU_VBLANK_INT_DRIVER("screen", ssingles_state, nmi_line_pulse)
572573
573574   MCFG_SCREEN_ADD("screen", RASTER)
574575   MCFG_SCREEN_RAW_PARAMS(4000000, 256, 0, 256, 256, 0, 256)   /* temporary, CRTC will configure screen */
r17996r17997
592593
593594MACHINE_CONFIG_END
594595
595static INTERRUPT_GEN( atamanot_irq )
596INTERRUPT_GEN_MEMBER(ssingles_state::atamanot_irq)
596597{
597598   // ...
598599}
r17996r17997
601602   MCFG_CPU_MODIFY("maincpu")
602603   MCFG_CPU_PROGRAM_MAP(atamanot_map)
603604   MCFG_CPU_IO_MAP(atamanot_io_map)
604   MCFG_CPU_VBLANK_INT("screen", atamanot_irq)
605   MCFG_CPU_VBLANK_INT_DRIVER("screen", ssingles_state, atamanot_irq)
605606
606607   MCFG_DEVICE_REMOVE("crtc")
607608
trunk/src/mame/drivers/ikki.c
r17996r17997
264264
265265   MCFG_CPU_ADD("sub", Z80,8000000/2) /* 4.000MHz */
266266   MCFG_CPU_PROGRAM_MAP(ikki_cpu2)
267   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
267   MCFG_CPU_PERIODIC_INT_DRIVER(ikki_state, irq0_line_hold, 2*60)
268268
269269   MCFG_QUANTUM_PERFECT_CPU("maincpu")
270270
trunk/src/mame/drivers/kinst.c
r17996r17997
163163   virtual void machine_start();
164164   virtual void machine_reset();
165165   UINT32 screen_update_kinst(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
166   INTERRUPT_GEN_MEMBER(irq0_start);
166167};
167168
168169
r17996r17997
281282}
282283
283284
284static INTERRUPT_GEN( irq0_start )
285INTERRUPT_GEN_MEMBER(kinst_state::irq0_start)
285286{
286   device->execute().set_input_line(0, ASSERT_LINE);
287   device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq0_stop));
287   device.execute().set_input_line(0, ASSERT_LINE);
288   machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq0_stop));
288289}
289290
290291
r17996r17997
675676   MCFG_CPU_ADD("maincpu", R4600LE, MASTER_CLOCK*2)
676677   MCFG_CPU_CONFIG(r4600_config)
677678   MCFG_CPU_PROGRAM_MAP(main_map)
678   MCFG_CPU_VBLANK_INT("screen", irq0_start)
679   MCFG_CPU_VBLANK_INT_DRIVER("screen", kinst_state, irq0_start)
679680
680681
681682   MCFG_IDE_CONTROLLER_ADD("ide", ide_intf, ide_devices, "hdd", NULL, true)
trunk/src/mame/drivers/sub.c
r17996r17997
134134   virtual void video_start();
135135   virtual void palette_init();
136136   UINT32 screen_update_sub(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
137   INTERRUPT_GEN_MEMBER(subm_sound_irq);
137138};
138139
139140void sub_state::video_start()
r17996r17997
418419}
419420
420421
421static INTERRUPT_GEN( subm_sound_irq )
422INTERRUPT_GEN_MEMBER(sub_state::subm_sound_irq)
422423{
423   sub_state *state = device->machine().driver_data<sub_state>();
424424
425   if(state->m_nmi_en)
426      device->machine().device("soundcpu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
425   if(m_nmi_en)
426      machine().device("soundcpu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
427427}
428428
429429static MACHINE_CONFIG_START( sub, sub_state )
r17996r17997
432432   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/6)       /* ? MHz */
433433   MCFG_CPU_PROGRAM_MAP(subm_map)
434434   MCFG_CPU_IO_MAP(subm_io)
435   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
435   MCFG_CPU_VBLANK_INT_DRIVER("screen", sub_state, irq0_line_hold)
436436
437437   MCFG_CPU_ADD("soundcpu", Z80,MASTER_CLOCK/6)       /* ? MHz */
438438   MCFG_CPU_PROGRAM_MAP(subm_sound_map)
439439   MCFG_CPU_IO_MAP(subm_sound_io)
440   MCFG_CPU_PERIODIC_INT(subm_sound_irq, 120) //???
440   MCFG_CPU_PERIODIC_INT_DRIVER(sub_state, subm_sound_irq, 120) //???
441441
442442
443443   /* video hardware */
trunk/src/mame/drivers/cbasebal.c
r17996r17997
277277   MCFG_CPU_ADD("maincpu", Z80, 6000000)   /* ??? */
278278   MCFG_CPU_PROGRAM_MAP(cbasebal_map)
279279   MCFG_CPU_IO_MAP(cbasebal_portmap)
280   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* ??? */
280   MCFG_CPU_VBLANK_INT_DRIVER("screen", cbasebal_state, irq0_line_hold)   /* ??? */
281281
282282
283283   MCFG_EEPROM_ADD("eeprom", cbasebal_eeprom_intf)
trunk/src/mame/drivers/mpoker.c
r17996r17997
586586   /* basic machine hardware */
587587   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/6)       /* 3 MHz? */
588588   MCFG_CPU_PROGRAM_MAP(main_map)
589   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
589   MCFG_CPU_VBLANK_INT_DRIVER("screen", mpoker_state, irq0_line_hold)
590590
591591   MCFG_NVRAM_ADD_0FILL("nvram")
592592
trunk/src/mame/drivers/sbasketb.c
r17996r17997
176176   GFXDECODE_ENTRY( "gfx2", 0, spritelayout, 16*16, 16*16 )
177177GFXDECODE_END
178178
179static INTERRUPT_GEN( vblank_irq )
179INTERRUPT_GEN_MEMBER(sbasketb_state::vblank_irq)
180180{
181   sbasketb_state *state = device->machine().driver_data<sbasketb_state>();
182181
183   if(state->m_irq_mask)
184      device->execute().set_input_line(0, HOLD_LINE);
182   if(m_irq_mask)
183      device.execute().set_input_line(0, HOLD_LINE);
185184}
186185
187186//-------------------------------------------------
r17996r17997
199198   /* basic machine hardware */
200199   MCFG_CPU_ADD("maincpu", M6809, 1400000)        /* 1.400 MHz ??? */
201200   MCFG_CPU_PROGRAM_MAP(sbasketb_map)
202   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
201   MCFG_CPU_VBLANK_INT_DRIVER("screen", sbasketb_state, vblank_irq)
203202
204203   MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz / 4)   /* 3.5795 MHz */
205204   MCFG_CPU_PROGRAM_MAP(sbasketb_sound_map)
trunk/src/mame/drivers/lastbank.c
r17996r17997
459459   MCFG_CPU_ADD("audiocpu",Z80,MASTER_CLOCK/4)
460460   MCFG_CPU_PROGRAM_MAP(lastbank_audio_map)
461461   MCFG_CPU_IO_MAP(lastbank_audio_io)
462//  MCFG_CPU_PERIODIC_INT(nmi_line_pulse,60)
462   MCFG_CPU_PERIODIC_INT_DRIVER(lastbank_state, nmi_line_pulse, 60)
463463
464464   MCFG_QUANTUM_PERFECT_CPU("maincpu")
465465
trunk/src/mame/drivers/skyarmy.c
r17996r17997
5454   virtual void video_start();
5555   virtual void palette_init();
5656   UINT32 screen_update_skyarmy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(skyarmy_nmi_source);
5758};
5859
5960WRITE8_MEMBER(skyarmy_state::skyarmy_flip_screen_x_w)
r17996r17997
155156   return 0;
156157}
157158
158static INTERRUPT_GEN( skyarmy_nmi_source )
159INTERRUPT_GEN_MEMBER(skyarmy_state::skyarmy_nmi_source)
159160{
160   skyarmy_state *state = device->machine().driver_data<skyarmy_state>();
161161
162   if(state->m_nmi) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
162   if(m_nmi) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
163163}
164164
165165
r17996r17997
284284   MCFG_CPU_ADD("maincpu", Z80,4000000)
285285   MCFG_CPU_PROGRAM_MAP(skyarmy_map)
286286   MCFG_CPU_IO_MAP(skyarmy_io_map)
287   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
288   MCFG_CPU_PERIODIC_INT(skyarmy_nmi_source,650)   /* Hz */
287   MCFG_CPU_VBLANK_INT_DRIVER("screen", skyarmy_state,  irq0_line_hold)
288   MCFG_CPU_PERIODIC_INT_DRIVER(skyarmy_state, skyarmy_nmi_source, 650)   /* Hz */
289289
290290   /* video hardware */
291291   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ksayakyu.c
r17996r17997
271271   /* basic machine hardware */
272272   MCFG_CPU_ADD("maincpu", Z80,MAIN_CLOCK/8) //divider is guessed
273273   MCFG_CPU_PROGRAM_MAP(maincpu_map)
274   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
274   MCFG_CPU_VBLANK_INT_DRIVER("screen", ksayakyu_state, irq0_line_hold)
275275
276276   MCFG_CPU_ADD("audiocpu", Z80, MAIN_CLOCK/8) //divider is guessed, controls DAC tempo
277277   MCFG_CPU_PROGRAM_MAP(soundcpu_map)
278   MCFG_CPU_PERIODIC_INT(irq0_line_hold,60) //guess, controls music tempo
278   MCFG_CPU_PERIODIC_INT_DRIVER(ksayakyu_state, irq0_line_hold, 60) //guess, controls music tempo
279279
280280   MCFG_QUANTUM_TIME(attotime::from_hz(60000))
281281
trunk/src/mame/drivers/suprgolf.c
r17996r17997
515515   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/2) /* guess */
516516   MCFG_CPU_PROGRAM_MAP(suprgolf_map)
517517   MCFG_CPU_IO_MAP(io_map)
518   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
518   MCFG_CPU_VBLANK_INT_DRIVER("screen", suprgolf_state, irq0_line_hold)
519519
520520
521521
trunk/src/mame/drivers/himesiki.c
r17996r17997
292292   MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 6.000 MHz */
293293   MCFG_CPU_PROGRAM_MAP(himesiki_prm0)
294294   MCFG_CPU_IO_MAP(himesiki_iom0)
295   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
295   MCFG_CPU_VBLANK_INT_DRIVER("screen", himesiki_state, irq0_line_hold)
296296
297297   MCFG_CPU_ADD("sub", Z80, MCLK/3) /* 4.000 MHz */
298298   MCFG_CPU_PROGRAM_MAP(himesiki_prm1)
trunk/src/mame/drivers/battlex.c
r17996r17997
4848#include "includes/battlex.h"
4949
5050
51static INTERRUPT_GEN( battlex_interrupt )
51INTERRUPT_GEN_MEMBER(battlex_state::battlex_interrupt)
5252{
53   battlex_state *state = device->machine().driver_data<battlex_state>();
54   state->m_in0_b4 = 1;
55   device->execute().set_input_line(0, ASSERT_LINE);
53   m_in0_b4 = 1;
54   device.execute().set_input_line(0, ASSERT_LINE);
5655}
5756
5857CUSTOM_INPUT_MEMBER(battlex_state::battlex_in0_b4_r)
r17996r17997
250249   MCFG_CPU_ADD("maincpu", Z80,XTAL_10MHz/4 )      // ?
251250   MCFG_CPU_PROGRAM_MAP(battlex_map)
252251   MCFG_CPU_IO_MAP(io_map)
253   MCFG_CPU_PERIODIC_INT(battlex_interrupt,400)   /* controls game speed? */
252   MCFG_CPU_PERIODIC_INT_DRIVER(battlex_state, battlex_interrupt, 400)   /* controls game speed? */
254253
255254
256255   /* video hardware */
trunk/src/mame/drivers/adp.c
r17996r17997
184184   DECLARE_MACHINE_RESET(skattv);
185185   DECLARE_PALETTE_INIT(adp);
186186   UINT32 screen_update_adp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
187   //INTERRUPT_GEN_MEMBER(adp_int);
187188};
188189
189190
r17996r17997
621622INPUT_PORTS_END
622623
623624/*
624static INTERRUPT_GEN( adp_int )
625INTERRUPT_GEN_MEMBER(adp_state::adp_int)
625626{
626    device->execute().set_input_line(1, HOLD_LINE); // ??? All irqs have the same vector, and the mask used is 0 or 7
627    device.execute().set_input_line(1, HOLD_LINE); // ??? All irqs have the same vector, and the mask used is 0 or 7
627628}
628629*/
629630static const ay8910_interface ay8910_config =
r17996r17997
663664
664665   MCFG_CPU_ADD("maincpu", M68000, 8000000)
665666   MCFG_CPU_PROGRAM_MAP(quickjac_mem)
666//  MCFG_CPU_VBLANK_INT("screen", adp_int)
667   //MCFG_CPU_VBLANK_INT_DRIVER("screen", adp_state, adp_int)
667668
668669   MCFG_MACHINE_START_OVERRIDE(adp_state,skattv)
669670   MCFG_MACHINE_RESET_OVERRIDE(adp_state,skattv)
r17996r17997
695696
696697   MCFG_CPU_ADD("maincpu", M68000, 8000000)
697698   MCFG_CPU_PROGRAM_MAP(skattv_mem)
698//  MCFG_CPU_VBLANK_INT("screen", adp_int)
699   //MCFG_CPU_VBLANK_INT_DRIVER("screen", adp_state, adp_int)
699700
700701   MCFG_MACHINE_START_OVERRIDE(adp_state,skattv)
701702   MCFG_MACHINE_RESET_OVERRIDE(adp_state,skattv)
trunk/src/mame/drivers/konamigq.c
r17996r17997
344344
345345   MCFG_CPU_ADD( "soundcpu", M68000, 8000000 )
346346   MCFG_CPU_PROGRAM_MAP( konamigq_sound_map)
347   MCFG_CPU_PERIODIC_INT( irq2_line_hold, 480 )
347   MCFG_CPU_PERIODIC_INT_DRIVER(konamigq_state, irq2_line_hold, 480)
348348
349349   MCFG_MACHINE_START_OVERRIDE(konamigq_state, konamigq )
350350   MCFG_MACHINE_RESET_OVERRIDE(konamigq_state, konamigq )
trunk/src/mame/drivers/mcatadv.c
r17996r17997
444444   /* basic machine hardware */
445445   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz) /* verified on pcb */
446446   MCFG_CPU_PROGRAM_MAP(mcatadv_map)
447   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
447   MCFG_CPU_VBLANK_INT_DRIVER("screen", mcatadv_state, irq1_line_hold)
448448
449449   MCFG_CPU_ADD("soundcpu", Z80, XTAL_16MHz/4) /* verified on pcb */
450450   MCFG_CPU_PROGRAM_MAP(mcatadv_sound_map)
trunk/src/mame/drivers/toaplan2.c
r17996r17997
497497   machine.scheduler().timer_set(machine.primary_screen->time_until_pos(0xe6), FUNC(toaplan2_raise_irq), irq_line);
498498}
499499
500static INTERRUPT_GEN( toaplan2_vblank_irq1 ) { toaplan2_vblank_irq(device->machine(), 1); }
501static INTERRUPT_GEN( toaplan2_vblank_irq2 ) { toaplan2_vblank_irq(device->machine(), 2); }
502static INTERRUPT_GEN( toaplan2_vblank_irq4 ) { toaplan2_vblank_irq(device->machine(), 4); }
500INTERRUPT_GEN_MEMBER(toaplan2_state::toaplan2_vblank_irq1){ toaplan2_vblank_irq(machine(), 1); }
501INTERRUPT_GEN_MEMBER(toaplan2_state::toaplan2_vblank_irq2){ toaplan2_vblank_irq(machine(), 2); }
502INTERRUPT_GEN_MEMBER(toaplan2_state::toaplan2_vblank_irq4){ toaplan2_vblank_irq(machine(), 4); }
503503
504504
505505READ16_MEMBER(toaplan2_state::video_count_r)
r17996r17997
10181018}
10191019
10201020
1021static INTERRUPT_GEN( bbakraid_snd_interrupt )
1021INTERRUPT_GEN_MEMBER(toaplan2_state::bbakraid_snd_interrupt)
10221022{
1023   device->execute().set_input_line(0, HOLD_LINE);
1023   device.execute().set_input_line(0, HOLD_LINE);
10241024}
10251025
10261026
r17996r17997
30283028   /* basic machine hardware */
30293029   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)         /* 10MHz Oscillator */
30303030   MCFG_CPU_PROGRAM_MAP(tekipaki_68k_mem)
3031   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3031   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
30323032
30333033#ifdef USE_HD64x180
30343034   MCFG_CPU_ADD("audiocpu", Z180, XTAL_10MHz)         /* HD647180 CPU actually */
r17996r17997
30693069   /* basic machine hardware */
30703070   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)         /* verified on pcb */
30713071   MCFG_CPU_PROGRAM_MAP(ghox_68k_mem)
3072   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3072   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
30733073
30743074#ifdef USE_HD64x180
30753075   MCFG_CPU_ADD("audiocpu", Z180, XTAL_10MHz)         /* HD647180 CPU actually */
r17996r17997
31603160   /* basic machine hardware */
31613161   MCFG_CPU_ADD("maincpu", M68000, XTAL_25MHz/2)         /* verified on pcb */
31623162   MCFG_CPU_PROGRAM_MAP(dogyuun_68k_mem)
3163   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3163   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
31643164
31653165   MCFG_CPU_ADD("audiocpu", V25, XTAL_25MHz/2)         /* NEC V25 type Toaplan marked CPU ??? */
31663166   MCFG_CPU_PROGRAM_MAP(v25_mem)
r17996r17997
32033203   /* basic machine hardware */
32043204   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)         /* 16MHz Oscillator */
32053205   MCFG_CPU_PROGRAM_MAP(kbash_68k_mem)
3206   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3206   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
32073207
32083208   /* ROM based v25 */
32093209   MCFG_CPU_ADD("audiocpu", V25, XTAL_16MHz)         /* NEC V25 type Toaplan marked CPU ??? */
r17996r17997
32463246   /* basic machine hardware */
32473247   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)         /* 16MHz Oscillator */
32483248   MCFG_CPU_PROGRAM_MAP(kbash2_68k_mem)
3249   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3249   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
32503250
32513251   MCFG_MACHINE_START_OVERRIDE(toaplan2_state,toaplan2)
32523252
r17996r17997
32833283   /* basic machine hardware */
32843284   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)         /* verified on pcb */
32853285   MCFG_CPU_PROGRAM_MAP(truxton2_68k_mem)
3286   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq2)
3286   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq2)
32873287
32883288   MCFG_MACHINE_START_OVERRIDE(toaplan2_state,toaplan2)
32893289
r17996r17997
33323332   /* basic machine hardware */
33333333   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)         /* verified on pcb */
33343334   MCFG_CPU_PROGRAM_MAP(pipibibs_68k_mem)
3335   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3335   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
33363336
33373337   MCFG_CPU_ADD("audiocpu", Z80, XTAL_27MHz/8)         /* verified on pcb */
33383338   MCFG_CPU_PROGRAM_MAP(pipibibs_sound_z80_mem)
r17996r17997
33733373   /* basic machine hardware */
33743374   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)         /* 10MHz Oscillator */
33753375   MCFG_CPU_PROGRAM_MAP(pipibibi_bootleg_68k_mem)
3376   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3376   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
33773377
33783378   MCFG_CPU_ADD("audiocpu", Z80, XTAL_27MHz/8)         /* ??? 3.37MHz */
33793379   MCFG_CPU_PROGRAM_MAP(pipibibs_sound_z80_mem)
r17996r17997
34533453   /* basic machine hardware */
34543454   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)         /* verified on pcb */
34553455   MCFG_CPU_PROGRAM_MAP(fixeight_68k_mem)
3456   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3456   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
34573457
34583458   MCFG_CPU_ADD("audiocpu", V25, XTAL_16MHz)         /* NEC V25 type Toaplan marked CPU ??? */
34593459   MCFG_CPU_PROGRAM_MAP(fixeight_v25_mem)
r17996r17997
34973497   /* basic machine hardware */
34983498   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)         /* 10MHz Oscillator */
34993499   MCFG_CPU_PROGRAM_MAP(fixeightbl_68k_mem)
3500   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq2)
3500   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq2)
35013501
35023502   MCFG_MACHINE_START_OVERRIDE(toaplan2_state,toaplan2)
35033503
r17996r17997
35323532   /* basic machine hardware */
35333533   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2)   /* verified on pcb */
35343534   MCFG_CPU_PROGRAM_MAP(vfive_68k_mem)
3535   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3535   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
35363536
35373537   MCFG_CPU_ADD("audiocpu", V25, XTAL_20MHz/2)   /* Verified on pcb, NEC V25 type Toaplan mark scratched out */
35383538   MCFG_CPU_PROGRAM_MAP(vfive_v25_mem)
r17996r17997
35713571   /* basic machine hardware */
35723572   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)         /* 16MHz , 32MHz Oscillator */
35733573   MCFG_CPU_PROGRAM_MAP(batsugun_68k_mem)
3574   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3574   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
35753575
35763576   MCFG_CPU_ADD("audiocpu", V25, XTAL_32MHz/2)         /* NEC V25 type Toaplan marked CPU ??? */
35773577   MCFG_CPU_PROGRAM_MAP(v25_mem)
r17996r17997
36133613   /* basic machine hardware */
36143614   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
36153615   MCFG_CPU_PROGRAM_MAP(snowbro2_68k_mem)
3616   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3616   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
36173617
36183618   MCFG_MACHINE_START_OVERRIDE(toaplan2_state,toaplan2)
36193619
r17996r17997
36503650   /* basic machine hardware */
36513651   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* 16MHz , 32MHz Oscillator */
36523652   MCFG_CPU_PROGRAM_MAP(mahoudai_68k_mem)
3653   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3653   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
36543654
36553655   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)      /* 4MHz , 32MHz Oscillator */
36563656   MCFG_CPU_PROGRAM_MAP(raizing_sound_z80_mem)
r17996r17997
36933693   /* basic machine hardware */
36943694   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* 16MHz , 32MHz Oscillator */
36953695   MCFG_CPU_PROGRAM_MAP(shippumd_68k_mem)
3696   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3696   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
36973697
36983698   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)      /* 4MHz , 32MHz Oscillator */
36993699   MCFG_CPU_PROGRAM_MAP(raizing_sound_z80_mem)
r17996r17997
37473747   /* basic machine hardware */
37483748   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* 16MHz , 32MHz Oscillator */
37493749   MCFG_CPU_PROGRAM_MAP(bgaregga_68k_mem)
3750   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq4)
3750   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq4)
37513751
37523752   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)      /* 4MHz , 32MHz Oscillator */
37533753   MCFG_CPU_PROGRAM_MAP(bgaregga_sound_z80_mem)
r17996r17997
37963796   /* basic machine hardware */
37973797   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* 16MHz , 32MHz Oscillator */
37983798   MCFG_CPU_PROGRAM_MAP(batrider_68k_mem)
3799   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq2)
3799   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq2)
38003800
38013801   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)      /* 4MHz , 32MHz Oscillator */
38023802   MCFG_CPU_PROGRAM_MAP(batrider_sound_z80_mem)
r17996r17997
38443844   /* basic machine hardware */
38453845   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* 16MHz , 32MHz Oscillator */
38463846   MCFG_CPU_PROGRAM_MAP(bbakraid_68k_mem)
3847   MCFG_CPU_VBLANK_INT("screen", toaplan2_vblank_irq1)
3847   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan2_state, toaplan2_vblank_irq1)
38483848
38493849   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/6)      /* 5.3333MHz , 32MHz Oscillator */
38503850   MCFG_CPU_PROGRAM_MAP(bbakraid_sound_z80_mem)
38513851   MCFG_CPU_IO_MAP(bbakraid_sound_z80_port)
3852   MCFG_CPU_PERIODIC_INT(bbakraid_snd_interrupt, 448)
3852   MCFG_CPU_PERIODIC_INT_DRIVER(toaplan2_state, bbakraid_snd_interrupt, 448)
38533853
38543854   MCFG_QUANTUM_TIME(attotime::from_hz(600))
38553855
trunk/src/mame/drivers/mjkjidai.c
r17996r17997
414414   GFXDECODE_ENTRY( "gfx1", 0, spritelayout, 0, 16 )
415415GFXDECODE_END
416416
417static INTERRUPT_GEN( vblank_irq )
417INTERRUPT_GEN_MEMBER(mjkjidai_state::vblank_irq)
418418{
419   mjkjidai_state *state = device->machine().driver_data<mjkjidai_state>();
420419
421   if(state->m_nmi_mask)
422      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
420   if(m_nmi_mask)
421      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
423422}
424423
425424
r17996r17997
446445   MCFG_CPU_ADD("maincpu", Z80,10000000/2)   /* 5 MHz ??? */
447446   MCFG_CPU_PROGRAM_MAP(mjkjidai_map)
448447   MCFG_CPU_IO_MAP(mjkjidai_io_map)
449   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
448   MCFG_CPU_VBLANK_INT_DRIVER("screen", mjkjidai_state, vblank_irq)
450449
451450   MCFG_NVRAM_HANDLER(mjkjidai)
452451
trunk/src/mame/drivers/jailbrek.c
r17996r17997
100100   flip_screen_set(data & 0x08);
101101}
102102
103static INTERRUPT_GEN( jb_interrupt )
103INTERRUPT_GEN_MEMBER(jailbrek_state::jb_interrupt)
104104{
105   jailbrek_state *state = device->machine().driver_data<jailbrek_state>();
106105
107   if (state->m_irq_enable)
108      device->execute().set_input_line(0, HOLD_LINE);
106   if (m_irq_enable)
107      device.execute().set_input_line(0, HOLD_LINE);
109108}
110109
111static INTERRUPT_GEN( jb_interrupt_nmi )
110INTERRUPT_GEN_MEMBER(jailbrek_state::jb_interrupt_nmi)
112111{
113   jailbrek_state *state = device->machine().driver_data<jailbrek_state>();
114112
115   if (state->m_nmi_enable)
116      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
113   if (m_nmi_enable)
114      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
117115}
118116
119117
r17996r17997
271269   /* basic machine hardware */
272270   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/12)
273271   MCFG_CPU_PROGRAM_MAP(jailbrek_map)
274   MCFG_CPU_VBLANK_INT("screen", jb_interrupt)
275   MCFG_CPU_PERIODIC_INT(jb_interrupt_nmi, 500) /* ? */
272   MCFG_CPU_VBLANK_INT_DRIVER("screen", jailbrek_state,  jb_interrupt)
273   MCFG_CPU_PERIODIC_INT_DRIVER(jailbrek_state, jb_interrupt_nmi,  500) /* ? */
276274
277275
278276   /* video hardware */
trunk/src/mame/drivers/gaelco.c
r17996r17997
506506   /* basic machine hardware */
507507   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* MC68000P10, 10 MHz */
508508   MCFG_CPU_PROGRAM_MAP(bigkarnk_map)
509   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
509   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
510510
511511   MCFG_CPU_ADD("audiocpu", M6809, 8867000/4)   /* 68B09, 2.21675 MHz? */
512512   MCFG_CPU_PROGRAM_MAP(bigkarnk_snd_map)
r17996r17997
542542   /* basic machine hardware */
543543   MCFG_CPU_ADD("maincpu", M68000,24000000/2)         /* 12 MHz */
544544   MCFG_CPU_PROGRAM_MAP(maniacsq_map)
545   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
545   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
546546
547547
548548   /* video hardware */
r17996r17997
570570   /* basic machine hardware */
571571   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* MC68000P12, 12 MHz */
572572   MCFG_CPU_PROGRAM_MAP(squash_map)
573   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
573   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
574574
575575   MCFG_QUANTUM_TIME(attotime::from_hz(600))
576576
r17996r17997
600600   /* basic machine hardware */
601601   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* MC68000P12, 12 MHz */
602602   MCFG_CPU_PROGRAM_MAP(thoop_map)
603   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
603   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
604604
605605   MCFG_QUANTUM_TIME(attotime::from_hz(600))
606606
trunk/src/mame/drivers/wecleman.c
r17996r17997
10991099                        Hot Chase Hardware Definitions
11001100***************************************************************************/
11011101
1102static INTERRUPT_GEN( hotchase_sound_timer )
1102INTERRUPT_GEN_MEMBER(wecleman_state::hotchase_sound_timer)
11031103{
1104   generic_pulse_irq_line(device, M6809_FIRQ_LINE, 1);
1104   generic_pulse_irq_line(device.execute(), M6809_FIRQ_LINE, 1);
11051105}
11061106
11071107static const k051316_interface hotchase_k051316_intf_0 =
r17996r17997
11461146
11471147   MCFG_CPU_ADD("audiocpu", M6809, 3579545 / 2)   /* 3.579/2 MHz - PCB is drawn in one set's readme */
11481148   MCFG_CPU_PROGRAM_MAP(hotchase_sound_map)
1149   MCFG_CPU_PERIODIC_INT( hotchase_sound_timer, 496 )
1149   MCFG_CPU_PERIODIC_INT_DRIVER(wecleman_state, hotchase_sound_timer, 496)
11501150
11511151   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
11521152
trunk/src/mame/drivers/dmndrby.c
r17996r17997
8181   virtual void video_start();
8282   virtual void palette_init();
8383   UINT32 screen_update_dderby(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
84   INTERRUPT_GEN_MEMBER(dderby_irq);
85   INTERRUPT_GEN_MEMBER(dderby_timer_irq);
8486};
8587
8688
r17996r17997
498500}
499501
500502/*Main Z80 is IM 0,HW-latched irqs. */
501static INTERRUPT_GEN( dderby_irq )
503INTERRUPT_GEN_MEMBER(dmndrby_state::dderby_irq)
502504{
503   device->machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
505   machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
504506}
505507
506static INTERRUPT_GEN( dderby_timer_irq )
508INTERRUPT_GEN_MEMBER(dmndrby_state::dderby_timer_irq)
507509{
508   device->machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf); /* RST 08h */
510   machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf); /* RST 08h */
509511}
510512
511513static MACHINE_CONFIG_START( dderby, dmndrby_state )
512514   /* basic machine hardware */
513515   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* ? MHz */
514516   MCFG_CPU_PROGRAM_MAP(memmap)
515   MCFG_CPU_VBLANK_INT("screen", dderby_irq)
516   MCFG_CPU_PERIODIC_INT(dderby_timer_irq, 244/2)
517   MCFG_CPU_VBLANK_INT_DRIVER("screen", dmndrby_state,  dderby_irq)
518   MCFG_CPU_PERIODIC_INT_DRIVER(dmndrby_state, dderby_timer_irq,  244/2)
517519
518520   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* verified on schematics */
519521   MCFG_CPU_PROGRAM_MAP(dderby_sound_map)
trunk/src/mame/drivers/crbaloon.c
r17996r17997
355355 *
356356 *************************************/
357357
358static INTERRUPT_GEN( vblank_irq )
358INTERRUPT_GEN_MEMBER(crbaloon_state::vblank_irq)
359359{
360   crbaloon_state *state = device->machine().driver_data<crbaloon_state>();
361360
362   if(state->m_irq_mask)
363      device->execute().set_input_line(0, HOLD_LINE);
361   if(m_irq_mask)
362      device.execute().set_input_line(0, HOLD_LINE);
364363}
365364
366365
r17996r17997
370369   MCFG_CPU_ADD("maincpu", Z80, CRBALOON_MASTER_XTAL / 3)
371370   MCFG_CPU_PROGRAM_MAP(main_map)
372371   MCFG_CPU_IO_MAP(main_io_map)
373   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", crbaloon_state, vblank_irq)
374373
375374
376375   /* video hardware */
trunk/src/mame/drivers/portrait.c
r17996r17997
243243static MACHINE_CONFIG_START( portrait, portrait_state )
244244   MCFG_CPU_ADD("maincpu", Z80, 4000000)     /* 4 MHz ? */
245245   MCFG_CPU_PROGRAM_MAP(portrait_map)
246   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
246   MCFG_CPU_VBLANK_INT_DRIVER("screen", portrait_state, irq0_line_hold)
247247
248248   MCFG_CPU_ADD("audiocpu", I8039, 3120000)  /* ? */
249249   MCFG_CPU_PROGRAM_MAP(portrait_sound_map)
trunk/src/mame/drivers/munchmo.c
r17996r17997
4141}
4242
4343/* trusted thru schematics, NMI and IRQ triggers at vblank, at the same time (!) */
44static INTERRUPT_GEN( mnchmobl_vblank_irq )
44INTERRUPT_GEN_MEMBER(munchmo_state::mnchmobl_vblank_irq)
4545{
46   munchmo_state *state = device->machine().driver_data<munchmo_state>();
4746
48   if (state->m_nmi_enable)
49      state->m_maincpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
47   if (m_nmi_enable)
48      m_maincpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
5049
51   state->m_maincpu->set_input_line(0, HOLD_LINE);
50   m_maincpu->set_input_line(0, HOLD_LINE);
5251}
5352
54static INTERRUPT_GEN( mnchmobl_sound_irq )
53INTERRUPT_GEN_MEMBER(munchmo_state::mnchmobl_sound_irq)
5554{
56   //munchmo_state *state = device->machine().driver_data<munchmo_state>();
5755
58   device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
56   device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
5957}
6058
6159WRITE8_MEMBER(munchmo_state::mnchmobl_soundlatch_w)
r17996r17997
330328   /* basic machine hardware */
331329   MCFG_CPU_ADD("maincpu", Z80, XTAL_15MHz/4) /* ? */
332330   MCFG_CPU_PROGRAM_MAP(mnchmobl_map)
333   MCFG_CPU_VBLANK_INT("screen", mnchmobl_vblank_irq)
331   MCFG_CPU_VBLANK_INT_DRIVER("screen", munchmo_state, mnchmobl_vblank_irq)
334332
335333   MCFG_CPU_ADD("audiocpu", Z80, XTAL_15MHz/4) /* ? */
336334   MCFG_CPU_PROGRAM_MAP(sound_map)
337   MCFG_CPU_VBLANK_INT("screen", mnchmobl_sound_irq)
335   MCFG_CPU_VBLANK_INT_DRIVER("screen", munchmo_state, mnchmobl_sound_irq)
338336
339337
340338   /* video hardware */
trunk/src/mame/drivers/funkybee.c
r17996r17997
296296   MCFG_CPU_ADD("maincpu", Z80, 3072000)   /* 3.072 MHz */
297297   MCFG_CPU_PROGRAM_MAP(funkybee_map)
298298   MCFG_CPU_IO_MAP(io_map)
299   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
299   MCFG_CPU_VBLANK_INT_DRIVER("screen", funkybee_state, irq0_line_hold)
300300
301301
302302   /* video hardware */
trunk/src/mame/drivers/btoads.c
r17996r17997
327327   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)
328328   MCFG_CPU_PROGRAM_MAP(sound_map)
329329   MCFG_CPU_IO_MAP(sound_io_map)
330   MCFG_CPU_PERIODIC_INT(irq0_line_assert, 183)
330   MCFG_CPU_PERIODIC_INT_DRIVER(btoads_state, irq0_line_assert, 183)
331331
332332   MCFG_NVRAM_ADD_1FILL("nvram")
333333
trunk/src/mame/drivers/lastduel.c
r17996r17997
500500   /* basic machine hardware */
501501   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* Could be 8 MHz */
502502   MCFG_CPU_PROGRAM_MAP(lastduel_map)
503   MCFG_CPU_VBLANK_INT("screen",irq2_line_hold)
503   MCFG_CPU_VBLANK_INT_DRIVER("screen", lastduel_state, irq2_line_hold)
504504   MCFG_TIMER_ADD_PERIODIC("timer_irq", lastduel_timer_cb, attotime::from_hz(120)) /* control reads?? */
505505
506506   MCFG_CPU_ADD("audiocpu", Z80, 3579545) /* Accurate */
r17996r17997
543543   /* basic machine hardware */
544544   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* Accurate */
545545   MCFG_CPU_PROGRAM_MAP(madgear_map)
546   MCFG_CPU_VBLANK_INT("screen",irq5_line_hold)
546   MCFG_CPU_VBLANK_INT_DRIVER("screen", lastduel_state, irq5_line_hold)
547547   MCFG_TIMER_ADD_PERIODIC("timer_irq", madgear_timer_cb, attotime::from_hz(120)) /* control reads?? */
548548
549549   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
trunk/src/mame/drivers/drgnmst.c
r17996r17997
397397
398398   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* Confirmed */
399399   MCFG_CPU_PROGRAM_MAP(drgnmst_main_map)
400   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
400   MCFG_CPU_VBLANK_INT_DRIVER("screen", drgnmst_state, irq2_line_hold)
401401
402402   MCFG_CPU_ADD("audiocpu", PIC16C55, 32000000/8)   /* Confirmed */
403403   /* Program and Data Maps are internal to the MCU */
trunk/src/mame/drivers/cmmb.c
r17996r17997
6767   virtual void machine_reset();
6868   virtual void video_start();
6969   UINT32 screen_update_cmmb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
70   INTERRUPT_GEN_MEMBER(cmmb_irq);
7071};
7172
7273
r17996r17997
301302   GFXDECODE_ENTRY( "gfx", 0, spritelayout,   0x10, 4 )
302303GFXDECODE_END
303304
304static INTERRUPT_GEN( cmmb_irq )
305INTERRUPT_GEN_MEMBER(cmmb_state::cmmb_irq)
305306{
306   //if(device->machine().input().code_pressed_once(KEYCODE_Z))
307   //if(device->machine().input().code_pressed(KEYCODE_Z))
308//      device->execute().set_input_line(0, HOLD_LINE);
307   //if(machine().input().code_pressed_once(KEYCODE_Z))
308   //if(machine().input().code_pressed(KEYCODE_Z))
309//      device.execute().set_input_line(0, HOLD_LINE);
309310}
310311
311312void cmmb_state::machine_reset()
r17996r17997
317318   /* basic machine hardware */
318319   MCFG_CPU_ADD("maincpu", M65SC02, XTAL_72_576MHz/5) // Unknown clock, but chip rated for 14MHz
319320   MCFG_CPU_PROGRAM_MAP(cmmb_map)
320   MCFG_CPU_VBLANK_INT("screen",cmmb_irq)
321   MCFG_CPU_VBLANK_INT_DRIVER("screen", cmmb_state, cmmb_irq)
321322
322323   /* video hardware */
323324   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/starfire.c
r17996r17997
263263   /* basic machine hardware */
264264   MCFG_CPU_ADD("maincpu", Z80, STARFIRE_CPU_CLOCK)
265265   MCFG_CPU_PROGRAM_MAP(main_map)
266   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
266   MCFG_CPU_VBLANK_INT_DRIVER("screen", starfire_state, nmi_line_pulse)
267267
268268   /* video hardware */
269269   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/roul.c
r17996r17997
279279   MCFG_CPU_ADD("maincpu", Z80, 4000000)
280280   MCFG_CPU_PROGRAM_MAP(roul_map)
281281   MCFG_CPU_IO_MAP(roul_cpu_io_map)
282   MCFG_CPU_VBLANK_INT("screen",nmi_line_pulse)
282   MCFG_CPU_VBLANK_INT_DRIVER("screen", roul_state, nmi_line_pulse)
283283
284284   MCFG_CPU_ADD("soundcpu", Z80, 4000000)
285285   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/freekick.c
r17996r17997
7676   m_nmi_en = data & 1;
7777}
7878
79static INTERRUPT_GEN( freekick_irqgen )
79INTERRUPT_GEN_MEMBER(freekick_state::freekick_irqgen)
8080{
81   freekick_state *state = device->machine().driver_data<freekick_state>();
82   if (state->m_nmi_en)
83      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
81   if (m_nmi_en)
82      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
8483}
8584
8685WRITE8_MEMBER(freekick_state::oigas_5_w)
r17996r17997
632631
633632   MCFG_CPU_ADD("maincpu",Z80, 18432000/6)   //confirmed
634633   MCFG_CPU_PROGRAM_MAP(pbillrd_map)
635   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 50*3) //??
636   MCFG_CPU_VBLANK_INT("screen", freekick_irqgen)
634   MCFG_CPU_PERIODIC_INT_DRIVER(freekick_state, irq0_line_hold,  50*3) //??
635   MCFG_CPU_VBLANK_INT_DRIVER("screen", freekick_state,  freekick_irqgen)
637636
638637   MCFG_GFXDECODE(freekick)
639638
trunk/src/mame/drivers/cischeat.c
r17996r17997
15641564
15651565   MCFG_CPU_ADD("cpu2", M68000, 10000000)
15661566   MCFG_CPU_PROGRAM_MAP(bigrun_map2)
1567   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
1567   MCFG_CPU_VBLANK_INT_DRIVER("screen", cischeat_state, irq4_line_hold)
15681568
15691569   MCFG_CPU_ADD("cpu3", M68000, 10000000)
15701570   MCFG_CPU_PROGRAM_MAP(bigrun_map3)
1571   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
1571   MCFG_CPU_VBLANK_INT_DRIVER("screen", cischeat_state, irq4_line_hold)
15721572
15731573   MCFG_CPU_ADD("soundcpu", M68000, 6000000)
15741574   MCFG_CPU_PROGRAM_MAP(bigrun_sound_map)
1575   MCFG_CPU_PERIODIC_INT(irq4_line_hold,16*30)
1575   MCFG_CPU_PERIODIC_INT_DRIVER(cischeat_state, irq4_line_hold, 16*30)
15761576
15771577   MCFG_QUANTUM_TIME(attotime::from_hz(1200))
15781578
trunk/src/mame/drivers/speglsht.c
r17996r17997
391391   MCFG_CPU_PROGRAM_MAP(st0016_mem)
392392   MCFG_CPU_IO_MAP(st0016_io)
393393
394   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
394   MCFG_CPU_VBLANK_INT_DRIVER("screen", speglsht_state, irq0_line_hold)
395395
396396   MCFG_CPU_ADD("sub", R3000LE, 25000000)
397397   MCFG_CPU_CONFIG(r3000_config)
398398   MCFG_CPU_PROGRAM_MAP(speglsht_mem)
399   MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
399   MCFG_CPU_VBLANK_INT_DRIVER("screen", speglsht_state, irq4_line_assert)
400400
401401   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
402402   MCFG_MACHINE_RESET_OVERRIDE(speglsht_state,speglsht)
trunk/src/mame/drivers/magicfly.c
r17996r17997
804804   /* basic machine hardware */
805805   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/16)   /* guess */
806806   MCFG_CPU_PROGRAM_MAP(magicfly_map)
807   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
807   MCFG_CPU_VBLANK_INT_DRIVER("screen", magicfly_state, nmi_line_pulse)
808808
809809   MCFG_NVRAM_ADD_0FILL("nvram")
810810
trunk/src/mame/drivers/wgp.c
r17996r17997
472472/* FWIW offset of 10000,10500 on ints can get CPUB obeying the
473473   first CPUA command the same frame; probably not necessary */
474474
475static INTERRUPT_GEN( wgp_cpub_interrupt )
475INTERRUPT_GEN_MEMBER(wgp_state::wgp_cpub_interrupt)
476476{
477   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000-500), FUNC(wgp_cpub_interrupt6));
478   device->execute().set_input_line(4, HOLD_LINE);
477   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000-500), FUNC(wgp_cpub_interrupt6));
478   device.execute().set_input_line(4, HOLD_LINE);
479479}
480480
481481
r17996r17997
994994   /* basic machine hardware */
995995   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
996996   MCFG_CPU_PROGRAM_MAP(main_map)
997   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
997   MCFG_CPU_VBLANK_INT_DRIVER("screen", wgp_state, irq4_line_hold)
998998
999999   MCFG_CPU_ADD("audiocpu", Z80, 16000000/4)   /* 4 MHz ??? */
10001000   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
10011001
10021002   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
10031003   MCFG_CPU_PROGRAM_MAP(cpu2_map)
1004   MCFG_CPU_VBLANK_INT("screen", wgp_cpub_interrupt)
1004   MCFG_CPU_VBLANK_INT_DRIVER("screen", wgp_state, wgp_cpub_interrupt)
10051005
10061006
10071007   MCFG_QUANTUM_TIME(attotime::from_hz(30000))
trunk/src/mame/drivers/atronic.c
r17996r17997
6060   MCFG_CPU_ADD("maincpu", Z180, 6000000)
6161   MCFG_CPU_PROGRAM_MAP(atronic_map)
6262   MCFG_CPU_IO_MAP(atronic_portmap)
63   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
63   MCFG_CPU_VBLANK_INT_DRIVER("screen", atronic_state, irq0_line_hold)
6464
6565   MCFG_SCREEN_ADD("screen", RASTER)
6666   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/welltris.c
r17996r17997
707707   /* basic machine hardware */
708708   MCFG_CPU_ADD("maincpu", M68000,20000000/2)   /* 10 MHz */
709709   MCFG_CPU_PROGRAM_MAP(main_map)
710   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
710   MCFG_CPU_VBLANK_INT_DRIVER("screen", welltris_state, irq1_line_hold)
711711
712712   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)      /* 4 MHz ??? */
713713   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/taitoair.c
r17996r17997
709709   /* basic machine hardware */
710710   MCFG_CPU_ADD("maincpu", M68000,24000000 / 2)      /* 12 MHz ??? */
711711   MCFG_CPU_PROGRAM_MAP(airsys_map)
712   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
712   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoair_state, irq5_line_hold)
713713
714714   MCFG_CPU_ADD("audiocpu", Z80,8000000 / 2)         /* 4 MHz ??? */
715715   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tceptor.c
r17996r17997
3737
3838/*******************************************************************/
3939
40static INTERRUPT_GEN( m6809_vb_interrupt )
40INTERRUPT_GEN_MEMBER(tceptor_state::m6809_vb_interrupt)
4141{
42   tceptor_state *state = device->machine().driver_data<tceptor_state>();
43   if (state->m_m6809_irq_enable)
44      device->execute().set_input_line(0, HOLD_LINE);
42   if (m_m6809_irq_enable)
43      device.execute().set_input_line(0, HOLD_LINE);
4544   else
46      state->m_m6809_irq_enable = 1;
45      m_m6809_irq_enable = 1;
4746}
4847
4948WRITE8_MEMBER(tceptor_state::m6809_irq_enable_w)
r17996r17997
5756}
5857
5958
60static INTERRUPT_GEN( m68k_vb_interrupt )
59INTERRUPT_GEN_MEMBER(tceptor_state::m68k_vb_interrupt)
6160{
62   tceptor_state *state = device->machine().driver_data<tceptor_state>();
63   if (state->m_m68k_irq_enable)
64      device->execute().set_input_line(M68K_IRQ_1, HOLD_LINE);
61   if (m_m68k_irq_enable)
62      device.execute().set_input_line(M68K_IRQ_1, HOLD_LINE);
6563}
6664
6765WRITE16_MEMBER(tceptor_state::m68k_irq_enable_w)
r17996r17997
7068}
7169
7270
73static INTERRUPT_GEN( mcu_vb_interrupt )
71INTERRUPT_GEN_MEMBER(tceptor_state::mcu_vb_interrupt)
7472{
75   tceptor_state *state = device->machine().driver_data<tceptor_state>();
76   if (state->m_mcu_irq_enable)
77      device->execute().set_input_line(0, HOLD_LINE);
73   if (m_mcu_irq_enable)
74      device.execute().set_input_line(0, HOLD_LINE);
7875   else
79      state->m_mcu_irq_enable = 1;
76      m_mcu_irq_enable = 1;
8077}
8178
8279WRITE8_MEMBER(tceptor_state::mcu_irq_enable_w)
r17996r17997
364361   /* basic machine hardware */
365362   MCFG_CPU_ADD("maincpu", M6809, 49152000/32)
366363   MCFG_CPU_PROGRAM_MAP(m6809_map)
367   MCFG_CPU_VBLANK_INT("2dscreen", m6809_vb_interrupt)
364   MCFG_CPU_VBLANK_INT_DRIVER("2dscreen", tceptor_state, m6809_vb_interrupt)
368365
369366   MCFG_CPU_ADD("audiocpu", M65C02, 49152000/24)
370367   MCFG_CPU_PROGRAM_MAP(m6502_a_map)
r17996r17997
374371
375372   MCFG_CPU_ADD("sub", M68000, 49152000/4)
376373   MCFG_CPU_PROGRAM_MAP(m68k_map)
377   MCFG_CPU_VBLANK_INT("2dscreen", m68k_vb_interrupt)
374   MCFG_CPU_VBLANK_INT_DRIVER("2dscreen", tceptor_state, m68k_vb_interrupt)
378375
379376   MCFG_CPU_ADD("mcu", HD63701, 49152000/8)   /* or compatible 6808 with extra instructions */
380377   MCFG_CPU_PROGRAM_MAP(mcu_map)
381378   MCFG_CPU_IO_MAP(mcu_io_map)
382   MCFG_CPU_VBLANK_INT("2dscreen", mcu_vb_interrupt)
379   MCFG_CPU_VBLANK_INT_DRIVER("2dscreen", tceptor_state, mcu_vb_interrupt)
383380
384381   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
385382
trunk/src/mame/drivers/aquarium.c
r17996r17997
318318   /* basic machine hardware */
319319   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2) // clock not verified on pcb
320320   MCFG_CPU_PROGRAM_MAP(main_map)
321   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
321   MCFG_CPU_VBLANK_INT_DRIVER("screen", aquarium_state, irq1_line_hold)
322322
323323   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/6) // clock not verified on pcb
324324   MCFG_CPU_PROGRAM_MAP(snd_map)
trunk/src/mame/drivers/gal3.c
r17996r17997
627627static MACHINE_CONFIG_START( gal3, gal3_state )
628628   MCFG_CPU_ADD("cpumst", M68020, 49152000/2)
629629   MCFG_CPU_PROGRAM_MAP(cpu_mst_map)
630   MCFG_CPU_VBLANK_INT("lscreen", irq1_line_hold)
630   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq1_line_hold)
631631
632632   MCFG_CPU_ADD("cpuslv", M68020, 49152000/2)
633633   MCFG_CPU_PROGRAM_MAP(cpu_slv_map)
634   MCFG_CPU_VBLANK_INT("lscreen", irq1_line_hold)
634   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq1_line_hold)
635635
636636   MCFG_CPU_ADD("rs_cpu", M68000, 49152000/4)
637637   MCFG_CPU_PROGRAM_MAP(rs_cpu_map)
638   MCFG_CPU_VBLANK_INT("lscreen", irq5_line_hold)   /// programmable via 148 IC
638   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq5_line_hold)   /// programmable via 148 IC
639639
640640   MCFG_CPU_ADD("sound_cpu", M68000, 12000000) // ??
641641   MCFG_CPU_PROGRAM_MAP(sound_cpu_map)
trunk/src/mame/drivers/metro.c
r17996r17997
187187   update_irq_state(machine());
188188}
189189
190static INTERRUPT_GEN( metro_vblank_interrupt )
190INTERRUPT_GEN_MEMBER(metro_state::metro_vblank_interrupt)
191191{
192   metro_state *state = device->machine().driver_data<metro_state>();
193192
194   state->m_requested_int[state->m_vblank_bit] = 1;
195   update_irq_state(device->machine());
193   m_requested_int[m_vblank_bit] = 1;
194   update_irq_state(machine());
196195}
197196
198static INTERRUPT_GEN( metro_periodic_interrupt )
197INTERRUPT_GEN_MEMBER(metro_state::metro_periodic_interrupt)
199198{
200   metro_state *state = device->machine().driver_data<metro_state>();
201199
202   state->m_requested_int[4] = 1;
203   update_irq_state(device->machine());
200   m_requested_int[4] = 1;
201   update_irq_state(machine());
204202}
205203
206204static TIMER_CALLBACK( karatour_irq_callback )
r17996r17997
210208}
211209
212210/* lev 2-7 (lev 1 seems sound related) */
213static INTERRUPT_GEN( karatour_interrupt )
211INTERRUPT_GEN_MEMBER(metro_state::karatour_interrupt)
214212{
215   metro_state *state = device->machine().driver_data<metro_state>();
216213
217   state->m_requested_int[state->m_vblank_bit] = 1;
214   m_requested_int[m_vblank_bit] = 1;
218215
219216   /* write to scroll registers, the duration is a guess */
220   device->machine().scheduler().timer_set(attotime::from_usec(2500), FUNC(karatour_irq_callback));
221   state->m_requested_int[5] = 1;
217   machine().scheduler().timer_set(attotime::from_usec(2500), FUNC(karatour_irq_callback));
218   m_requested_int[5] = 1;
222219
223   update_irq_state(device->machine());
220   update_irq_state(machine());
224221}
225222
226223static TIMER_CALLBACK( mouja_irq_callback )
r17996r17997
238235   m_mouja_irq_timer->adjust(attotime::zero, 0, attotime::from_hz(freq));
239236}
240237
241static INTERRUPT_GEN( puzzlet_interrupt )
238INTERRUPT_GEN_MEMBER(metro_state::puzzlet_interrupt)
242239{
243   metro_state *state = device->machine().driver_data<metro_state>();
244240
245   state->m_requested_int[state->m_vblank_bit] = 1;
246   update_irq_state(device->machine());
241   m_requested_int[m_vblank_bit] = 1;
242   update_irq_state(machine());
247243
248   state->m_maincpu->set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
244   m_maincpu->set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
249245}
250246
251247static void ymf278b_interrupt( device_t *device, int active )
r17996r17997
34213417   /* basic machine hardware */
34223418   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
34233419   MCFG_CPU_PROGRAM_MAP(balcube_map)
3424   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3425   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3420   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3421   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
34263422
34273423   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
34283424   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
34553451   /* basic machine hardware */
34563452   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
34573453   MCFG_CPU_PROGRAM_MAP(daitoa_map)
3458   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3459   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3454   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3455   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
34603456
34613457   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
34623458   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
34893485   /* basic machine hardware */
34903486   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
34913487   MCFG_CPU_PROGRAM_MAP(msgogo_map)
3492   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt) // timing is off, shaking sprites in intro
3493   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 60) // ?
3488   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt) // timing is off, shaking sprites in intro
3489   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  60) // ?
34943490
34953491   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
34963492   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
35233519   /* basic machine hardware */
35243520   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
35253521   MCFG_CPU_PROGRAM_MAP(bangball_map)
3526   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3527   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 60) // ?
3522   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3523   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  60) // ?
35283524
35293525   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
35303526   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
35573553   /* basic machine hardware */
35583554   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
35593555   MCFG_CPU_PROGRAM_MAP(batlbubl_map)
3560   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3561   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 60) // ?
3556   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3557   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  60) // ?
35623558
35633559   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
35643560   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
35903586   /* basic machine hardware */
35913587   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
35923588   MCFG_CPU_PROGRAM_MAP(daitorid_map)
3593   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3594   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3589   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3590   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
35953591
35963592   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_12MHz)
35973593   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
36333629   /* basic machine hardware */
36343630   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
36353631   MCFG_CPU_PROGRAM_MAP(dharma_map)
3636   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3637   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3632   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3633   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
36383634
36393635   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
36403636   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
36753671   /* basic machine hardware */
36763672   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
36773673   MCFG_CPU_PROGRAM_MAP(karatour_map)
3678   MCFG_CPU_VBLANK_INT("screen", karatour_interrupt)
3679   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3674   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  karatour_interrupt)
3675   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
36803676
36813677   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
36823678   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
37173713   /* basic machine hardware */
37183714   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
37193715   MCFG_CPU_PROGRAM_MAP(kokushi_map)
3720   MCFG_CPU_VBLANK_INT("screen", karatour_interrupt)
3721   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3716   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  karatour_interrupt)
3717   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
37223718
37233719   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
37243720   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
37593755   /* basic machine hardware */
37603756   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
37613757   MCFG_CPU_PROGRAM_MAP(lastfort_map)
3762   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3763   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3758   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3759   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
37643760
37653761   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
37663762   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
38003796   /* basic machine hardware */
38013797   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
38023798   MCFG_CPU_PROGRAM_MAP(lastforg_map)
3803   MCFG_CPU_VBLANK_INT("screen", karatour_interrupt)
3804   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3799   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  karatour_interrupt)
3800   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
38053801
38063802   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
38073803   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
38413837   /* basic machine hardware */
38423838   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
38433839   MCFG_CPU_PROGRAM_MAP(dokyusei_map)
3844   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3840   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, metro_vblank_interrupt)
38453841
38463842   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
38473843   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
38763872   /* basic machine hardware */
38773873   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
38783874   MCFG_CPU_PROGRAM_MAP(dokyusp_map)
3879   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3875   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, metro_vblank_interrupt)
38803876
38813877   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
38823878   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
39133909   /* basic machine hardware */
39143910   MCFG_CPU_ADD("maincpu", M68000, 16000000) /* 26.6660MHz/2?, OSCs listed are 26.6660MHz & 3.579545MHz */
39153911   MCFG_CPU_PROGRAM_MAP(gakusai_map)
3916   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3912   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, metro_vblank_interrupt)
39173913
39183914   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
39193915   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
39503946   /* basic machine hardware */
39513947   MCFG_CPU_ADD("maincpu", M68000, 16000000) /* 26.6660MHz/2?, OSCs listed are 26.6660MHz & 3.579545MHz */
39523948   MCFG_CPU_PROGRAM_MAP(gakusai2_map)
3953   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3949   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, metro_vblank_interrupt)
39543950
39553951   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
39563952   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
39873983   /* basic machine hardware */
39883984   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
39893985   MCFG_CPU_PROGRAM_MAP(pangpoms_map)
3990   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
3991   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
3986   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
3987   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
39923988
39933989   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
39943990   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
40294025   /* basic machine hardware */
40304026   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
40314027   MCFG_CPU_PROGRAM_MAP(poitto_map)
4032   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
4033   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4028   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
4029   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
40344030
40354031   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
40364032   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
40714067   /* basic machine hardware */
40724068   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)      /* Not confirmed */
40734069   MCFG_CPU_PROGRAM_MAP(pururun_map)
4074   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
4075   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4070   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
4071   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
40764072
40774073   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)      /* Not confiremd */
40784074   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
41144110   /* basic machine hardware */
41154111   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
41164112   MCFG_CPU_PROGRAM_MAP(skyalert_map)
4117   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
4118   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4113   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
4114   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
41194115
41204116   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
41214117   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
41564152   /* basic machine hardware */
41574153   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
41584154   MCFG_CPU_PROGRAM_MAP(toride2g_map)
4159   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
4160   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4155   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  metro_vblank_interrupt)
4156   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
41614157
41624158   MCFG_CPU_ADD("audiocpu", UPD7810, XTAL_24MHz/2)
41634159   MCFG_CPU_CONFIG(metro_cpu_config)
r17996r17997
41984194   /* basic machine hardware */
41994195   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
42004196   MCFG_CPU_PROGRAM_MAP(mouja_map)
4201   MCFG_CPU_VBLANK_INT("screen", metro_vblank_interrupt)
4197   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, metro_vblank_interrupt)
42024198
42034199   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
42044200   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
r17996r17997
42384234   /* basic machine hardware */
42394235   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
42404236   MCFG_CPU_PROGRAM_MAP(blzntrnd_map)
4241   MCFG_CPU_VBLANK_INT("screen", karatour_interrupt)
4242   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4237   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  karatour_interrupt)
4238   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
42434239
42444240   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/2)
42454241   MCFG_CPU_PROGRAM_MAP(blzntrnd_sound_map)
r17996r17997
42864282   /* basic machine hardware */
42874283   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
42884284   MCFG_CPU_PROGRAM_MAP(blzntrnd_map)
4289   MCFG_CPU_VBLANK_INT("screen", karatour_interrupt)
4290   MCFG_CPU_PERIODIC_INT(metro_periodic_interrupt, 8*60) // ?
4285   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state,  karatour_interrupt)
4286   MCFG_CPU_PERIODIC_INT_DRIVER(metro_state, metro_periodic_interrupt,  8*60) // ?
42914287
42924288   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/2)
42934289   MCFG_CPU_PROGRAM_MAP(blzntrnd_sound_map)
r17996r17997
43294325   MCFG_CPU_ADD("maincpu", H83007, XTAL_20MHz)   // H8/3007 - Hitachi HD6413007F20 CPU. Clock 20MHz
43304326   MCFG_CPU_PROGRAM_MAP(puzzlet_map)
43314327   MCFG_CPU_IO_MAP(puzzlet_io_map)
4332   MCFG_CPU_VBLANK_INT("screen", puzzlet_interrupt)
4328   MCFG_CPU_VBLANK_INT_DRIVER("screen", metro_state, puzzlet_interrupt)
43334329
43344330   MCFG_MACHINE_START_OVERRIDE(metro_state,metro)
43354331   MCFG_MACHINE_RESET_OVERRIDE(metro_state,metro)
trunk/src/mame/drivers/angelkds.c
r17996r17997
602602   MCFG_CPU_ADD("maincpu", Z80, XTAL_6MHz)
603603   MCFG_CPU_PROGRAM_MAP(main_map)
604604   MCFG_CPU_IO_MAP(main_portmap)
605   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
605   MCFG_CPU_VBLANK_INT_DRIVER("screen", angelkds_state, irq0_line_hold)
606606
607607   MCFG_CPU_ADD("sub", Z80, XTAL_4MHz)
608608   MCFG_CPU_PROGRAM_MAP(sub_map)
trunk/src/mame/drivers/jrpacman.c
r17996r17997
112112   DECLARE_WRITE8_MEMBER(jrpacman_interrupt_vector_w);
113113   DECLARE_WRITE8_MEMBER(irq_mask_w);
114114   DECLARE_DRIVER_INIT(jrpacman);
115   INTERRUPT_GEN_MEMBER(vblank_irq);
115116};
116117
117118
r17996r17997
280281 *
281282 *************************************/
282283
283static INTERRUPT_GEN( vblank_irq )
284INTERRUPT_GEN_MEMBER(jrpacman_state::vblank_irq)
284285{
285   jrpacman_state *state = device->machine().driver_data<jrpacman_state>();
286286
287   if(state->m_irq_mask)
288      device->execute().set_input_line(0, HOLD_LINE);
287   if(m_irq_mask)
288      device.execute().set_input_line(0, HOLD_LINE);
289289}
290290
291291static MACHINE_CONFIG_START( jrpacman, jrpacman_state )
r17996r17997
294294   MCFG_CPU_ADD("maincpu", Z80, 18432000/6)   /* 3.072 MHz */
295295   MCFG_CPU_PROGRAM_MAP(main_map)
296296   MCFG_CPU_IO_MAP(port_map)
297   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
297   MCFG_CPU_VBLANK_INT_DRIVER("screen", jrpacman_state, vblank_irq)
298298
299299   /* video hardware */
300300   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/nightgal.c
r17996r17997
868868   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK / 8)       /* ? MHz */
869869   MCFG_CPU_PROGRAM_MAP(royalqn_map)
870870   MCFG_CPU_IO_MAP(royalqn_io)
871   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
871   MCFG_CPU_VBLANK_INT_DRIVER("screen", nightgal_state, irq0_line_hold)
872872
873873   MCFG_CPU_ADD("sub", NSC8105, MASTER_CLOCK / 8)
874874   MCFG_CPU_PROGRAM_MAP(royalqn_nsc_map)
r17996r17997
902902   MCFG_CPU_MODIFY("maincpu")
903903   MCFG_CPU_PROGRAM_MAP(sexygal_map)
904904   MCFG_CPU_IO_MAP(sexygal_io)
905   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,244)//???
905   MCFG_CPU_PERIODIC_INT_DRIVER(nightgal_state, nmi_line_pulse, 244)//???
906906
907907   MCFG_CPU_MODIFY("sub")
908908   MCFG_CPU_PROGRAM_MAP(sexygal_nsc_map)
909   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
909   MCFG_CPU_VBLANK_INT_DRIVER("screen", nightgal_state, irq0_line_hold)
910910
911911   MCFG_DEVICE_REMOVE("aysnd")
912912
r17996r17997
919919   MCFG_CPU_MODIFY("maincpu")
920920   MCFG_CPU_PROGRAM_MAP(royalqn_map)
921921   MCFG_CPU_IO_MAP(royalqn_io)
922   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,244)//???
922   MCFG_CPU_PERIODIC_INT_DRIVER(nightgal_state, nmi_line_pulse, 244)//???
923923MACHINE_CONFIG_END
924924
925925/*
trunk/src/mame/drivers/maygayv1.c
r17996r17997
243243   virtual void video_start();
244244   UINT32 screen_update_maygayv1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
245245   void screen_eof_maygayv1(screen_device &screen, bool state);
246   INTERRUPT_GEN_MEMBER(vsync_interrupt);
246247};
247248
248249
r17996r17997
10251026}
10261027
10271028
1028static INTERRUPT_GEN( vsync_interrupt )
1029INTERRUPT_GEN_MEMBER(maygayv1_state::vsync_interrupt)
10291030{
1030   maygayv1_state *state = device->machine().driver_data<maygayv1_state>();
1031   if (state->m_vsync_latch_preset)
1032      device->machine().device("maincpu")->execute().set_input_line(3, ASSERT_LINE);
1031   if (m_vsync_latch_preset)
1032      machine().device("maincpu")->execute().set_input_line(3, ASSERT_LINE);
10331033}
10341034
10351035
10361036static MACHINE_CONFIG_START( maygayv1, maygayv1_state )
10371037   MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK / 2)
10381038   MCFG_CPU_PROGRAM_MAP(main_map)
1039   MCFG_CPU_VBLANK_INT("screen", vsync_interrupt)
1039   MCFG_CPU_VBLANK_INT_DRIVER("screen", maygayv1_state, vsync_interrupt)
10401040
10411041   MCFG_CPU_ADD("soundcpu", I8052, SOUND_CLOCK)
10421042   MCFG_CPU_PROGRAM_MAP(sound_prg)
trunk/src/mame/drivers/namcond1.c
r17996r17997
265265   AM_RANGE(H8_ADC_0_L, H8_ADC_3_H) AM_NOP // MCU reads these, but the games have no analog controls
266266ADDRESS_MAP_END
267267
268static INTERRUPT_GEN( mcu_interrupt )
268INTERRUPT_GEN_MEMBER(namcond1_state::mcu_interrupt)
269269{
270   namcond1_state *state = device->machine().driver_data<namcond1_state>();
271   if( state->m_h8_irq5_enabled )
270   if( m_h8_irq5_enabled )
272271   {
273      generic_pulse_irq_line(device, H8_IRQ5, 1);
272      generic_pulse_irq_line(device.execute(), H8_IRQ5, 1);
274273   }
275274}
276275
r17996r17997
286285   /* basic machine hardware */
287286   MCFG_CPU_ADD("maincpu", M68000, XTAL_49_152MHz/4)
288287   MCFG_CPU_PROGRAM_MAP(namcond1_map)
289   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
288   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcond1_state, irq1_line_hold)
290289
291290   // I've disabled this for now, I don't think it's correct, it breaks ncv2 'game options' in test
292291   // mode (and could also be responsible for the random resets?)
r17996r17997
298297   MCFG_CPU_ADD("mcu", H83002, XTAL_49_152MHz/3 )
299298   MCFG_CPU_PROGRAM_MAP( nd1h8rwmap)
300299   MCFG_CPU_IO_MAP( nd1h8iomap)
301   MCFG_CPU_VBLANK_INT("screen", mcu_interrupt)
300   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcond1_state, mcu_interrupt)
302301
303302   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
304303
trunk/src/mame/drivers/rgum.c
r17996r17997
268268   /* basic machine hardware */
269269   MCFG_CPU_ADD("maincpu", M65C02,24000000/16)       /* ? MHz */
270270   MCFG_CPU_PROGRAM_MAP(rgum_map)
271//  MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
271   MCFG_CPU_VBLANK_INT_DRIVER("screen", rgum_state, nmi_line_pulse)
272272
273273   /* video hardware */
274274   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/surpratk.c
r17996r17997
1818/* prototypes */
1919static KONAMI_SETLINES_CALLBACK( surpratk_banking );
2020
21static INTERRUPT_GEN( surpratk_interrupt )
21INTERRUPT_GEN_MEMBER(surpratk_state::surpratk_interrupt)
2222{
23   surpratk_state *state = device->machine().driver_data<surpratk_state>();
24   if (k052109_is_irq_enabled(state->m_k052109))
25      device->execute().set_input_line(0, HOLD_LINE);
23   if (k052109_is_irq_enabled(m_k052109))
24      device.execute().set_input_line(0, HOLD_LINE);
2625}
2726
2827READ8_MEMBER(surpratk_state::bankedram_r)
r17996r17997
230229   /* basic machine hardware */
231230   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)   /* 053248 */
232231   MCFG_CPU_PROGRAM_MAP(surpratk_map)
233   MCFG_CPU_VBLANK_INT("screen", surpratk_interrupt)
232   MCFG_CPU_VBLANK_INT_DRIVER("screen", surpratk_state, surpratk_interrupt)
234233
235234
236235   /* video hardware */
trunk/src/mame/drivers/neptunp2.c
r17996r17997
9595   MCFG_CPU_ADD("maincpu",I80188,20000000) // N80C188-20 AMD
9696   MCFG_CPU_PROGRAM_MAP(neptunp2_map)
9797   MCFG_CPU_IO_MAP(neptunp2_io)
98//  MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
98   MCFG_CPU_VBLANK_INT_DRIVER("screen", neptunp2_state, irq0_line_hold)
9999
100100   /* video hardware */
101101   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/zaccaria.c
r17996r17997
151151   m_last_port0b = data;
152152}
153153
154static INTERRUPT_GEN( zaccaria_cb1_toggle )
154INTERRUPT_GEN_MEMBER(zaccaria_state::zaccaria_cb1_toggle)
155155{
156   zaccaria_state *state = device->machine().driver_data<zaccaria_state>();
157   pia6821_device *pia0 = device->machine().device<pia6821_device>("pia0");
156   pia6821_device *pia0 = machine().device<pia6821_device>("pia0");
158157
159   pia0->cb1_w(state->m_toggle & 1);
160   state->m_toggle ^= 1;
158   pia0->cb1_w(m_toggle & 1);
159   m_toggle ^= 1;
161160}
162161
163162WRITE8_MEMBER(zaccaria_state::zaccaria_port1b_w)
r17996r17997
570569   DEVCB_DEVICE_LINE_MEMBER("pia1", pia6821_device, ca2_w)      /* READYQ handler */
571570};
572571
573static INTERRUPT_GEN( vblank_irq )
572INTERRUPT_GEN_MEMBER(zaccaria_state::vblank_irq)
574573{
575   zaccaria_state *state = device->machine().driver_data<zaccaria_state>();
576574
577   if(state->m_nmi_mask)
578      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
575   if(m_nmi_mask)
576      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
579577}
580578
581579
r17996r17997
584582   /* basic machine hardware */
585583   MCFG_CPU_ADD("maincpu", Z80,XTAL_18_432MHz/6)   /* verified on pcb */
586584   MCFG_CPU_PROGRAM_MAP(main_map)
587   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
585   MCFG_CPU_VBLANK_INT_DRIVER("screen", zaccaria_state, vblank_irq)
588586   MCFG_QUANTUM_TIME(attotime::from_hz(1000000))
589587
590588   MCFG_CPU_ADD("audiocpu", M6802,XTAL_3_579545MHz) /* verified on pcb */
591589   MCFG_CPU_PROGRAM_MAP(sound_map_1)
592   MCFG_CPU_PERIODIC_INT(zaccaria_cb1_toggle,(double)XTAL_3_579545MHz/4096)
590   MCFG_CPU_PERIODIC_INT_DRIVER(zaccaria_state, zaccaria_cb1_toggle, (double)XTAL_3_579545MHz/4096)
593591   MCFG_QUANTUM_TIME(attotime::from_hz(1000000))
594592
595593   MCFG_CPU_ADD("audio2", M6802,XTAL_3_579545MHz) /* verified on pcb */
trunk/src/mame/drivers/speedbal.c
r17996r17997
223223   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz ??? */
224224   MCFG_CPU_PROGRAM_MAP(main_cpu_map)
225225   MCFG_CPU_IO_MAP(main_cpu_io_map)
226   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
226   MCFG_CPU_VBLANK_INT_DRIVER("screen", speedbal_state, irq0_line_hold)
227227
228228   MCFG_CPU_ADD("audiocpu", Z80, 2660000)   /* 2.66 MHz ???  Maybe yes */
229229   MCFG_CPU_PROGRAM_MAP(sound_cpu_map)
230230   MCFG_CPU_IO_MAP(sound_cpu_io_map)
231   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*60)
231   MCFG_CPU_PERIODIC_INT_DRIVER(speedbal_state, irq0_line_hold, 8*60)
232232
233233   MCFG_NVRAM_ADD_1FILL("nvram")
234234
trunk/src/mame/drivers/attckufo.c
r17996r17997
6969
7070   DECLARE_READ8_MEMBER( vic_videoram_r );
7171   DECLARE_READ8_MEMBER( vic_colorram_r );
72   INTERRUPT_GEN_MEMBER(attckufo_raster_interrupt);
7273};
7374
7475READ8_MEMBER(attckufo_state::attckufo_io_r)
r17996r17997
148149INPUT_PORTS_END
149150
150151
151static INTERRUPT_GEN( attckufo_raster_interrupt )
152INTERRUPT_GEN_MEMBER(attckufo_state::attckufo_raster_interrupt)
152153{
153   attckufo_state *state = device->machine().driver_data<attckufo_state>();
154   state->m_mos6560->raster_interrupt_gen();
154   m_mos6560->raster_interrupt_gen();
155155}
156156
157157static MOS6560_INTERFACE( vic_intf )
r17996r17997
166166   /* basic machine hardware */
167167   MCFG_CPU_ADD("maincpu", M6502, 14318181/14)
168168   MCFG_CPU_PROGRAM_MAP(cpu_map)
169   MCFG_CPU_PERIODIC_INT(attckufo_raster_interrupt, MOS656X_HRETRACERATE)
169   MCFG_CPU_PERIODIC_INT_DRIVER(attckufo_state, attckufo_raster_interrupt, MOS656X_HRETRACERATE)
170170
171171   /* video hardware */
172172   MCFG_MOS656X_ATTACK_UFO_ADD("mos6560", "screen", 14318181/14, vic_intf, vic_videoram_map, vic_colorram_map)
trunk/src/mame/drivers/jongkyo.c
r17996r17997
494494   MCFG_CPU_ADD("maincpu", Z80,JONGKYO_CLOCK/4)
495495   MCFG_CPU_PROGRAM_MAP(jongkyo_memmap)
496496   MCFG_CPU_IO_MAP(jongkyo_portmap)
497   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
497   MCFG_CPU_VBLANK_INT_DRIVER("screen", jongkyo_state, irq0_line_hold)
498498
499499
500500   /* video hardware */
trunk/src/mame/drivers/tagteam.c
r17996r17997
195195GFXDECODE_END
196196
197197
198static INTERRUPT_GEN( sound_timer_irq )
198INTERRUPT_GEN_MEMBER(tagteam_state::sound_timer_irq)
199199{
200   tagteam_state *state = device->machine().driver_data<tagteam_state>();
201200
202   if(state->m_sound_nmi_mask)
203      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
201   if(m_sound_nmi_mask)
202      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
204203}
205204
206205
r17996r17997
209208   /* basic machine hardware */
210209   MCFG_CPU_ADD("maincpu", M6502, XTAL_12MHz/8)
211210   MCFG_CPU_PROGRAM_MAP(main_map)
212   MCFG_CPU_PERIODIC_INT(irq0_line_assert,272/16*57) // connected to bit 4 of vcount (basically once every 16 scanlines)
211   MCFG_CPU_PERIODIC_INT_DRIVER(tagteam_state, irq0_line_assert, 272/16*57) // connected to bit 4 of vcount (basically once every 16 scanlines)
213212
214213   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz/2/6) // daughterboard gets 12mhz/2 from mainboard, but how it's divided further is a guess
215214   MCFG_CPU_PROGRAM_MAP(sound_map)
216   MCFG_CPU_PERIODIC_INT(sound_timer_irq,272/16*57) // same source as maincpu irq
215   MCFG_CPU_PERIODIC_INT_DRIVER(tagteam_state, sound_timer_irq, 272/16*57) // same source as maincpu irq
217216
218217   /* video hardware */
219218   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/namcos23.c
r17996r17997
14351435   DECLARE_VIDEO_START(ss23);
14361436   DECLARE_MACHINE_RESET(gmen);
14371437   UINT32 screen_update_ss23(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
1438   INTERRUPT_GEN_MEMBER(s23_interrupt);
14381439};
14391440
14401441
r17996r17997
24322433   return 0;
24332434}
24342435
2435static INTERRUPT_GEN(s23_interrupt)
2436INTERRUPT_GEN_MEMBER(namcos23_state::s23_interrupt)
24362437{
2437   namcos23_state *state = device->machine().driver_data<namcos23_state>();
2438   render_t &render = state->m_render;
2438   render_t &render = m_render;
24392439
2440   if(!state->m_ctl_vbl_active) {
2441      state->m_ctl_vbl_active = true;
2442      device->execute().set_input_line(MIPS3_IRQ0, ASSERT_LINE);
2440   if(!m_ctl_vbl_active) {
2441      m_ctl_vbl_active = true;
2442      device.execute().set_input_line(MIPS3_IRQ0, ASSERT_LINE);
24432443   }
24442444
24452445   render.cur = !render.cur;
r17996r17997
31483148   MCFG_CPU_ADD("maincpu", R4650BE, S23_BUSCLOCK*4)
31493149   MCFG_CPU_CONFIG(r4650_config)
31503150   MCFG_CPU_PROGRAM_MAP(gorgon_map)
3151   MCFG_CPU_VBLANK_INT("screen", s23_interrupt)
3151   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, s23_interrupt)
31523152
31533153   MCFG_CPU_ADD("audiocpu", H83002, S23_H8CLOCK )
31543154   MCFG_CPU_PROGRAM_MAP( s23h8rwmap )
31553155   MCFG_CPU_IO_MAP( s23h8iomap )
3156   MCFG_CPU_VBLANK_INT("screen", irq1_line_pulse)
3156   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, irq1_line_pulse)
31573157
31583158   MCFG_CPU_ADD("ioboard", H83334, S23_H8CLOCK )
31593159   MCFG_CPU_PROGRAM_MAP( gorgoniobrdmap )
r17996r17997
31933193   MCFG_CPU_ADD("maincpu", R4650BE, S23_BUSCLOCK*4)
31943194   MCFG_CPU_CONFIG(r4650_config)
31953195   MCFG_CPU_PROGRAM_MAP(ss23_map)
3196   MCFG_CPU_VBLANK_INT("screen", s23_interrupt)
3196   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, s23_interrupt)
31973197
31983198   MCFG_CPU_ADD("audiocpu", H83002, S23_H8CLOCK )
31993199   MCFG_CPU_PROGRAM_MAP( s23h8rwmap )
32003200   MCFG_CPU_IO_MAP( s23h8iomap )
3201   MCFG_CPU_VBLANK_INT("screen", irq1_line_pulse)
3201   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, irq1_line_pulse)
32023202
32033203   MCFG_CPU_ADD("ioboard", H83334, S23_H8CLOCK )
32043204   MCFG_CPU_PROGRAM_MAP( s23iobrdmap )
r17996r17997
32383238   MCFG_CPU_ADD("maincpu", R4650BE, S23_BUSCLOCK*5)
32393239   MCFG_CPU_CONFIG(r4650_config)
32403240   MCFG_CPU_PROGRAM_MAP(ss23_map)
3241   MCFG_CPU_VBLANK_INT("screen", s23_interrupt)
3241   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, s23_interrupt)
32423242
32433243   MCFG_CPU_ADD("audiocpu", H83002, S23_H8CLOCK )
32443244   MCFG_CPU_PROGRAM_MAP( s23h8rwmap )
32453245   MCFG_CPU_IO_MAP( s23h8noiobmap )
3246   MCFG_CPU_VBLANK_INT("screen", irq1_line_pulse)
3246   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos23_state, irq1_line_pulse)
32473247
32483248   MCFG_QUANTUM_TIME(attotime::from_hz(60000))
32493249
trunk/src/mame/drivers/commando.c
r17996r17997
216216
217217/* Interrupt Generator */
218218
219static INTERRUPT_GEN( commando_interrupt )
219INTERRUPT_GEN_MEMBER(commando_state::commando_interrupt)
220220{
221   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   // RST 10h - VBLANK
221   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   // RST 10h - VBLANK
222222}
223223
224224/* Machine Driver */
r17996r17997
247247   /* basic machine hardware */
248248   MCFG_CPU_ADD("maincpu", Z80, PHI_MAIN)   // ???
249249   MCFG_CPU_PROGRAM_MAP(commando_map)
250   MCFG_CPU_VBLANK_INT("screen", commando_interrupt)
250   MCFG_CPU_VBLANK_INT_DRIVER("screen", commando_state, commando_interrupt)
251251
252252   MCFG_CPU_ADD("audiocpu", Z80, PHI_B)   // 3 MHz
253253   MCFG_CPU_PROGRAM_MAP(sound_map)
254   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
254   MCFG_CPU_PERIODIC_INT_DRIVER(commando_state, irq0_line_hold, 4*60)
255255
256256
257257   /* video hardware */
trunk/src/mame/drivers/atarisy2.c
r17996r17997
259259 *
260260 *************************************/
261261
262static INTERRUPT_GEN( vblank_int )
262INTERRUPT_GEN_MEMBER(atarisy2_state::vblank_int)
263263{
264   atarisy2_state *state = device->machine().driver_data<atarisy2_state>();
265264
266265   /* clock the VBLANK through */
267   if (state->m_interrupt_enable & 8)
268      atarigen_video_int_gen(device);
266   if (m_interrupt_enable & 8)
267      atarigen_video_int_gen(&device);
269268}
270269
271270
r17996r17997
12621261   MCFG_CPU_ADD("maincpu", T11, MASTER_CLOCK/2)
12631262   MCFG_CPU_CONFIG(t11_data)
12641263   MCFG_CPU_PROGRAM_MAP(main_map)
1265   MCFG_CPU_VBLANK_INT("screen", vblank_int)
1264   MCFG_CPU_VBLANK_INT_DRIVER("screen", atarisy2_state, vblank_int)
12661265
12671266   MCFG_CPU_ADD("soundcpu", M6502, SOUND_CLOCK/8)
12681267   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/skydiver.c
r17996r17997
143143}
144144
145145
146static INTERRUPT_GEN( skydiver_interrupt )
146INTERRUPT_GEN_MEMBER(skydiver_state::skydiver_interrupt)
147147{
148   skydiver_state *state = device->machine().driver_data<skydiver_state>();
149   device_t *discrete = device->machine().device("discrete");
148   device_t *discrete = machine().device("discrete");
150149
151150   /* Convert range data to divide value and write to sound */
152   address_space &space = *device->machine().firstcpu->space(AS_PROGRAM);
153   discrete_sound_w(discrete, space, SKYDIVER_RANGE_DATA, (0x01 << (~state->m_videoram[0x394] & 0x07)) & 0xff);   // Range 0-2
151   address_space &space = *machine().firstcpu->space(AS_PROGRAM);
152   discrete_sound_w(discrete, space, SKYDIVER_RANGE_DATA, (0x01 << (~m_videoram[0x394] & 0x07)) & 0xff);   // Range 0-2
154153
155   discrete_sound_w(discrete, space, SKYDIVER_RANGE3_EN,  state->m_videoram[0x394] & 0x08);      // Range 3 - note disable
156   discrete_sound_w(discrete, space, SKYDIVER_NOTE_DATA, ~state->m_videoram[0x395] & 0xff);      // Note - freq
157   discrete_sound_w(discrete, space, SKYDIVER_NOISE_DATA,  state->m_videoram[0x396] & 0x0f);   // NAM - Noise Amplitude
154   discrete_sound_w(discrete, space, SKYDIVER_RANGE3_EN,  m_videoram[0x394] & 0x08);      // Range 3 - note disable
155   discrete_sound_w(discrete, space, SKYDIVER_NOTE_DATA, ~m_videoram[0x395] & 0xff);      // Note - freq
156   discrete_sound_w(discrete, space, SKYDIVER_NOISE_DATA,  m_videoram[0x396] & 0x0f);   // NAM - Noise Amplitude
158157
159   if (state->m_nmion)
160      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
158   if (m_nmion)
159      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
161160}
162161
163162
r17996r17997
378377   /* basic machine hardware */
379378   MCFG_CPU_ADD("maincpu", M6800,MASTER_CLOCK/16)      /* ???? */
380379   MCFG_CPU_PROGRAM_MAP(skydiver_map)
381   MCFG_CPU_PERIODIC_INT(skydiver_interrupt, 5*60)
380   MCFG_CPU_PERIODIC_INT_DRIVER(skydiver_state, skydiver_interrupt, 5*60)
382381   MCFG_WATCHDOG_VBLANK_INIT(8)   // 128V clocks the same as VBLANK
383382
384383
trunk/src/mame/drivers/ninjakd2.c
r17996r17997
166166static void omegaf_io_protection_reset(running_machine &machine);
167167
168168
169static INTERRUPT_GEN( ninjakd2_interrupt )
169INTERRUPT_GEN_MEMBER(ninjakd2_state::ninjakd2_interrupt)
170170{
171   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   /* RST 10h */
171   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   /* RST 10h */
172172}
173173
174174
r17996r17997
939939   /* basic machine hardware */
940940   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK_12/2)      /* verified */
941941   MCFG_CPU_PROGRAM_MAP(ninjakd2_main_cpu)
942   MCFG_CPU_VBLANK_INT("screen", ninjakd2_interrupt)
942   MCFG_CPU_VBLANK_INT_DRIVER("screen", ninjakd2_state, ninjakd2_interrupt)
943943
944944   MCFG_CPU_ADD("soundcpu", Z80, MAIN_CLOCK_5)      /* verified */
945945   MCFG_CPU_PROGRAM_MAP(ninjakd2_sound_cpu)
trunk/src/mame/drivers/mjsister.c
r17996r17997
499499   MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 6.000 MHz */
500500   MCFG_CPU_PROGRAM_MAP(mjsister_map)
501501   MCFG_CPU_IO_MAP(mjsister_io_map)
502   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
502   MCFG_CPU_PERIODIC_INT_DRIVER(mjsister_state, irq0_line_hold, 2*60)
503503
504504
505505   /* video hardware */
trunk/src/mame/drivers/yunsung8.c
r17996r17997
502502   MCFG_CPU_ADD("maincpu", Z80, 8000000)         /* Z80B */
503503   MCFG_CPU_PROGRAM_MAP(main_map)
504504   MCFG_CPU_IO_MAP(port_map)
505   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* No nmi routine */
505   MCFG_CPU_VBLANK_INT_DRIVER("screen", yunsung8_state, irq0_line_hold)   /* No nmi routine */
506506
507507   MCFG_CPU_ADD("audiocpu", Z80, 4000000)         /* ? */
508508   MCFG_CPU_PROGRAM_MAP(sound_map)
509   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* NMI caused by the MSM5205? */
509   MCFG_CPU_VBLANK_INT_DRIVER("screen", yunsung8_state, irq0_line_hold)   /* NMI caused by the MSM5205? */
510510
511511
512512   /* video hardware */
trunk/src/mame/drivers/warpwarp.c
r17996r17997
139139
140140
141141/* Interrupt Gen */
142static INTERRUPT_GEN( vblank_irq )
142INTERRUPT_GEN_MEMBER(warpwarp_state::vblank_irq)
143143{
144   warpwarp_state *state = device->machine().driver_data<warpwarp_state>();
145144
146   if(state->m_ball_on)
147      device->execute().set_input_line(0, ASSERT_LINE);
145   if(m_ball_on)
146      device.execute().set_input_line(0, ASSERT_LINE);
148147}
149148
150149
r17996r17997
732731   MCFG_CPU_ADD("maincpu", I8080, MASTER_CLOCK/9) /* verified on pcb */
733732   MCFG_CPU_PROGRAM_MAP(geebee_map)
734733   MCFG_CPU_IO_MAP(geebee_port_map)
735   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
734   MCFG_CPU_VBLANK_INT_DRIVER("screen", warpwarp_state, vblank_irq)
736735
737736   /* video hardware */
738737   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
767766   /* basic machine hardware */
768767   MCFG_CPU_ADD("maincpu", I8080, MASTER_CLOCK/9)      /* 18.432 MHz / 9 */
769768   MCFG_CPU_PROGRAM_MAP(bombbee_map)
770   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
769   MCFG_CPU_VBLANK_INT_DRIVER("screen", warpwarp_state, vblank_irq)
771770
772771   /* video hardware */
773772   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/m52.c
r17996r17997
396396   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)
397397   MCFG_CPU_PROGRAM_MAP(main_map)
398398   MCFG_CPU_IO_MAP(main_portmap)
399   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
399   MCFG_CPU_VBLANK_INT_DRIVER("screen", m52_state, irq0_line_hold)
400400
401401
402402   /* video hardware */
trunk/src/mame/drivers/wheelfir.c
r17996r17997
817817
818818   MCFG_CPU_ADD("subcpu", M68000, 32000000/2)
819819   MCFG_CPU_PROGRAM_MAP(wheelfir_sub)
820   //MCFG_CPU_PERIODIC_INT(irq1_line_hold,256*60)
820   //MCFG_CPU_PERIODIC_INT_DRIVER(wheelfir_state, irq1_line_hold, 256*60)
821821
822822   MCFG_QUANTUM_TIME(attotime::from_hz(12000))
823823
trunk/src/mame/drivers/onetwo.c
r17996r17997
362362   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK)   /* 4 MHz */
363363   MCFG_CPU_PROGRAM_MAP(main_cpu)
364364   MCFG_CPU_IO_MAP(main_cpu_io)
365   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
365   MCFG_CPU_VBLANK_INT_DRIVER("screen", onetwo_state, irq0_line_hold)
366366
367367   MCFG_CPU_ADD("audiocpu", Z80,MASTER_CLOCK)   /* 4 MHz */
368368   MCFG_CPU_PROGRAM_MAP(sound_cpu)
trunk/src/mame/drivers/gng.c
r17996r17997
343343   /* basic machine hardware */
344344   MCFG_CPU_ADD("maincpu", M6809, XTAL_12MHz/8)      /* verified on pcb */
345345   MCFG_CPU_PROGRAM_MAP(gng_map)
346   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
346   MCFG_CPU_VBLANK_INT_DRIVER("screen", gng_state, irq0_line_hold)
347347
348348   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4)      /* verified on pcb */
349349   MCFG_CPU_PROGRAM_MAP(sound_map)
350   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
350   MCFG_CPU_PERIODIC_INT_DRIVER(gng_state, irq0_line_hold, 4*60)
351351
352352
353353   /* video hardware */
trunk/src/mame/drivers/mpu4plasma.c
r17996r17997
8787MACHINE_CONFIG_DERIVED_CLASS( mpu4plasma    , mod2, mpu4plasma_state )
8888   MCFG_CPU_ADD("plasmacpu", M68000, 10000000)
8989   MCFG_CPU_PROGRAM_MAP(mpu4plasma_map)
90   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
90   MCFG_CPU_VBLANK_INT_DRIVER("screen", mpu4plasma_state, irq4_line_hold)
9191
9292   MCFG_SCREEN_ADD("screen", RASTER)
9393   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/wc90b.c
r17996r17997
365365   /* basic machine hardware */
366366   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK)
367367   MCFG_CPU_PROGRAM_MAP(wc90b_map1)
368   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
368   MCFG_CPU_VBLANK_INT_DRIVER("screen", wc90b_state, irq0_line_hold)
369369
370370   MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK)
371371   MCFG_CPU_PROGRAM_MAP(wc90b_map2)
372   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", wc90b_state, irq0_line_hold)
373373
374374   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK)
375375   MCFG_CPU_PROGRAM_MAP(sound_cpu)
trunk/src/mame/drivers/holeland.c
r17996r17997
280280   MCFG_CPU_ADD("maincpu", Z80, 4000000)        /* 4 MHz ? */
281281   MCFG_CPU_PROGRAM_MAP(holeland_map)
282282   MCFG_CPU_IO_MAP(io_map)
283   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
283   MCFG_CPU_VBLANK_INT_DRIVER("screen", holeland_state, irq0_line_hold)
284284
285285   /* video hardware */
286286   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
348348   MCFG_CPU_ADD("maincpu", Z80, 20000000/4)        /* 5 MHz */
349349   MCFG_CPU_PROGRAM_MAP(crzrally_map)
350350   MCFG_CPU_IO_MAP(io_map)
351   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
351   MCFG_CPU_VBLANK_INT_DRIVER("screen", holeland_state, irq0_line_hold)
352352
353353   MCFG_NVRAM_ADD_1FILL("nvram")
354354
trunk/src/mame/drivers/liberate.c
r17996r17997
760760 *
761761 *************************************/
762762
763static INTERRUPT_GEN( deco16_interrupt )
763INTERRUPT_GEN_MEMBER(liberate_state::deco16_interrupt)
764764{
765   liberate_state *state = device->machine().driver_data<liberate_state>();
766   int p = ~state->ioport("IN3")->read();
767   if ((p & 0x43) && !state->m_latch)
765   int p = ~ioport("IN3")->read();
766   if ((p & 0x43) && !m_latch)
768767   {
769      device->execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
770      state->m_latch = 1;
768      device.execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
769      m_latch = 1;
771770   }
772771   else
773772   {
774773      if (!(p & 0x43))
775         state->m_latch = 0;
774         m_latch = 0;
776775   }
777776}
778777
779778#if 0
780static INTERRUPT_GEN( prosport_interrupt )
779INTERRUPT_GEN_MEMBER(liberate_state::prosport_interrupt)
781780{
782781   /* ??? */
783   device->execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
782   device.execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
784783}
785784#endif
786785
r17996r17997
823822   MCFG_CPU_ADD("maincpu",DECO16, 2000000)
824823   MCFG_CPU_PROGRAM_MAP(liberate_map)
825824   MCFG_CPU_IO_MAP(deco16_io_map)
826   MCFG_CPU_VBLANK_INT("screen", deco16_interrupt)
825   MCFG_CPU_VBLANK_INT_DRIVER("screen", liberate_state, deco16_interrupt)
827826
828827   MCFG_CPU_ADD("audiocpu",M6502, 1500000)
829828   MCFG_CPU_PROGRAM_MAP(liberate_sound_map)
830   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,16*60) /* ??? */
829   MCFG_CPU_PERIODIC_INT_DRIVER(liberate_state, nmi_line_pulse, 16*60) /* ??? */
831830
832831   MCFG_QUANTUM_TIME(attotime::from_hz(12000))
833832
r17996r17997
863862   /* basic machine hardware */
864863   MCFG_CPU_REPLACE("maincpu", M6502, 2000000)
865864   MCFG_CPU_PROGRAM_MAP(liberatb_map)
866   MCFG_CPU_VBLANK_INT("screen", deco16_interrupt)
865   MCFG_CPU_VBLANK_INT_DRIVER("screen", liberate_state, deco16_interrupt)
867866MACHINE_CONFIG_END
868867
869868static MACHINE_CONFIG_DERIVED( boomrang, liberate )
r17996r17997
902901   MCFG_CPU_ADD("maincpu", DECO16, 2000000)
903902   MCFG_CPU_PROGRAM_MAP(prosport_map)
904903   MCFG_CPU_IO_MAP(deco16_io_map)
905   MCFG_CPU_VBLANK_INT("screen", deco16_interrupt)
904   MCFG_CPU_VBLANK_INT_DRIVER("screen", liberate_state, deco16_interrupt)
906905
907906   MCFG_CPU_ADD("audiocpu", M6502, 1500000/2)
908907   MCFG_CPU_PROGRAM_MAP(liberate_sound_map)
909   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,16*60) /* ??? */
908   MCFG_CPU_PERIODIC_INT_DRIVER(liberate_state, nmi_line_pulse, 16*60) /* ??? */
910909
911910//  MCFG_QUANTUM_TIME(attotime::from_hz(12000))
912911
trunk/src/mame/drivers/gunsmoke.c
r17996r17997
297297   /* basic machine hardware */
298298   MCFG_CPU_ADD("maincpu", Z80, 4000000)   // 4 MHz
299299   MCFG_CPU_PROGRAM_MAP(gunsmoke_map)
300   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
300   MCFG_CPU_VBLANK_INT_DRIVER("screen", gunsmoke_state, irq0_line_hold)
301301
302302   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   // 3 MHz
303303   MCFG_CPU_PROGRAM_MAP(sound_map)
304   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
304   MCFG_CPU_PERIODIC_INT_DRIVER(gunsmoke_state, irq0_line_hold, 4*60)
305305
306306
307307   /* video hardware */
trunk/src/mame/drivers/truco.c
r17996r17997
389389   m_battery_ram[0x020] = m_battery_ram[0x011];
390390}
391391
392static INTERRUPT_GEN( truco_interrupt )
392INTERRUPT_GEN_MEMBER(truco_state::truco_interrupt)
393393{
394   truco_state *state = device->machine().driver_data<truco_state>();
395394   /* coinup */
396395
397   if ( state->ioport("COIN")->read() & 1 )
396   if ( ioport("COIN")->read() & 1 )
398397   {
399      if ( state->m_trigger == 0 )
398      if ( m_trigger == 0 )
400399      {
401         generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
402         state->m_trigger++;
400         generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
401         m_trigger++;
403402      }
404403   } else
405      state->m_trigger = 0;
404      m_trigger = 0;
406405}
407406
408407
r17996r17997
457456   /* basic machine hardware */
458457   MCFG_CPU_ADD("maincpu", M6809, CPU_CLOCK)
459458   MCFG_CPU_PROGRAM_MAP(main_map)
460   MCFG_CPU_VBLANK_INT("screen", truco_interrupt)
459   MCFG_CPU_VBLANK_INT_DRIVER("screen", truco_state, truco_interrupt)
461460    MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(1.6))   /* 1.6 seconds */
462461
463462   MCFG_PIA6821_ADD("pia0", pia0_intf)
trunk/src/mame/drivers/seta.c
r17996r17997
74847484   /* basic machine hardware */
74857485   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
74867486   MCFG_CPU_PROGRAM_MAP(tndrcade_map)
7487   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
7487   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq2_line_hold)
74887488
74897489   MCFG_CPU_ADD("sub", M65C02, 16000000/8)   /* 2 MHz */
74907490   MCFG_CPU_PROGRAM_MAP(tndrcade_sub_map)
r17996r17997
75347534   /* basic machine hardware */
75357535   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
75367536   MCFG_CPU_PROGRAM_MAP(downtown_map)
7537   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
7537   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
75387538
75397539   MCFG_CPU_ADD("sub", M65C02, 16000000/8)   /* 2 MHz */
75407540   MCFG_CPU_PROGRAM_MAP(twineagl_sub_map)
r17996r17997
76377637
76387638   MCFG_CPU_ADD("sub", M65C02, 16000000/8)   /* 2 MHz */
76397639   MCFG_CPU_PROGRAM_MAP(calibr50_sub_map)
7640   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* NMI caused by main cpu when writing to the sound latch */
7640   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq0_line_hold)   /* NMI caused by main cpu when writing to the sound latch */
76417641
76427642   MCFG_MACHINE_RESET_OVERRIDE(seta_state,calibr50)
76437643
r17996r17997
76857685
76867686   MCFG_CPU_ADD("sub", M65C02, XTAL_16MHz/8) /* verified on pcb */
76877687   MCFG_CPU_PROGRAM_MAP(calibr50_sub_map)
7688   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* IRQ: 4/frame
7688   MCFG_CPU_PERIODIC_INT_DRIVER(seta_state, irq0_line_hold, 4*60)   /* IRQ: 4/frame
76897689                               NMI: when the 68k writes the sound latch */
76907690
76917691   MCFG_MACHINE_RESET_OVERRIDE(seta_state,calibr50)
r17996r17997
77247724   /* basic machine hardware */
77257725   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
77267726   MCFG_CPU_PROGRAM_MAP(downtown_map)
7727   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
7727   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
77287728
77297729   MCFG_CPU_ADD("sub", M65C02, 16000000/8)   /* 2 MHz */
77307730   MCFG_CPU_PROGRAM_MAP(metafox_sub_map)
r17996r17997
78777877   /* basic machine hardware */
78787878   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
78797879   MCFG_CPU_PROGRAM_MAP(blockcar_map)
7880   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
7880   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
78817881
78827882   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
78837883
r17996r17997
81518151                                Gundhara
81528152***************************************************************************/
81538153#if __uPD71054_TIMER
8154static INTERRUPT_GEN( wrofaero_interrupt )
8154INTERRUPT_GEN_MEMBER(seta_state::wrofaero_interrupt)
81558155{
8156   device->execute().set_input_line(2, HOLD_LINE );
8156   device.execute().set_input_line(2, HOLD_LINE );
81578157}
81588158
81598159MACHINE_START_MEMBER(seta_state,wrofaero){ uPD71054_timer_init(machine()); }
r17996r17997
82908290   /* basic machine hardware */
82918291   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
82928292   MCFG_CPU_PROGRAM_MAP(kamenrid_map)
8293   MCFG_CPU_VBLANK_INT("screen", wrofaero_interrupt)
8293   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, wrofaero_interrupt)
82948294
82958295#if   __uPD71054_TIMER
82968296   MCFG_MACHINE_START_OVERRIDE(seta_state, wrofaero )
r17996r17997
84428442   /* basic machine hardware */
84438443   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
84448444   MCFG_CPU_PROGRAM_MAP(madshark_map)
8445   MCFG_CPU_VBLANK_INT("screen", wrofaero_interrupt)
8445   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, wrofaero_interrupt)
84468446
84478447#if   __uPD71054_TIMER
84488448   MCFG_MACHINE_START_OVERRIDE(seta_state, wrofaero )
r17996r17997
84848484   /* basic machine hardware */
84858485   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
84868486   MCFG_CPU_PROGRAM_MAP(magspeed_map)
8487   MCFG_CPU_VBLANK_INT("screen", wrofaero_interrupt)
8487   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, wrofaero_interrupt)
84888488
84898489#if   __uPD71054_TIMER
84908490   MCFG_MACHINE_START_OVERRIDE(seta_state, wrofaero )
r17996r17997
85278527   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
85288528   MCFG_CPU_PROGRAM_MAP(msgundam_map)
85298529#if   __uPD71054_TIMER
8530   MCFG_CPU_VBLANK_INT("screen", wrofaero_interrupt)
8530   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, wrofaero_interrupt)
85318531#else
85328532   MCFG_TIMER_ADD_SCANLINE("scantimer", seta_interrupt_2_and_4, "screen", 0, 1)
85338533#endif   // __uPD71054_TIMER
r17996r17997
86098609   /* basic machine hardware */
86108610   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
86118611   MCFG_CPU_PROGRAM_MAP(triplfun_map)
8612   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
8612   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
86138613
86148614   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
86158615
r17996r17997
86438643   /* basic machine hardware */
86448644   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
86458645   MCFG_CPU_PROGRAM_MAP(kiwame_map)
8646   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* lev 1-7 are the same. WARNING:
8646   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq1_line_hold)/* lev 1-7 are the same. WARNING:
86478647                                   the interrupt table is written to. */
86488648
86498649   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
r17996r17997
87228722   /* basic machine hardware */
87238723   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
87248724   MCFG_CPU_PROGRAM_MAP(thunderl_map)
8725   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
8725   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq2_line_hold)
87268726
87278727   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
87288728
r17996r17997
87728772   /* basic machine hardware */
87738773   MCFG_CPU_MODIFY("maincpu")
87748774   MCFG_CPU_PROGRAM_MAP(thunderlbl_map)
8775   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
8775   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq2_line_hold)
87768776
87778777   MCFG_CPU_ADD("audiocpu", Z80, 10000000/2)
87788778   MCFG_CPU_PROGRAM_MAP(thunderlbl_sound_map)
r17996r17997
87908790   /* basic machine hardware */
87918791   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
87928792   MCFG_CPU_PROGRAM_MAP(wiggie_map)
8793   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
8793   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq2_line_hold)
87948794
87958795   MCFG_CPU_ADD("audiocpu", Z80, 16000000/4)   /* 4 MHz */
87968796   MCFG_CPU_PROGRAM_MAP(wiggie_sound_map)
r17996r17997
88278827   /* basic machine hardware */
88288828   MCFG_CPU_ADD("maincpu", M68000, 16000000/2)   /* 8 MHz */
88298829   MCFG_CPU_PROGRAM_MAP(thunderl_map)
8830   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
8830   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq2_line_hold)
88318831
88328832   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
88338833
r17996r17997
88638863   /* basic machine hardware */
88648864   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
88658865   MCFG_CPU_PROGRAM_MAP(umanclub_map)
8866   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
8866   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
88678867
88688868   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
88698869
r17996r17997
89458945   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
89468946   MCFG_CPU_PROGRAM_MAP(wrofaero_map)
89478947#if   __uPD71054_TIMER
8948   MCFG_CPU_VBLANK_INT("screen", wrofaero_interrupt)
8948   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, wrofaero_interrupt)
89498949#else
89508950   MCFG_TIMER_ADD_SCANLINE("scantimer", seta_interrupt_2_and_4, "screen", 0, 1)
89518951#endif   // __uPD71054_TIMER
r17996r17997
89958995   /* basic machine hardware */
89968996   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
89978997   MCFG_CPU_PROGRAM_MAP(wrofaero_map)
8998   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
8998   MCFG_CPU_VBLANK_INT_DRIVER("screen", seta_state, irq3_line_hold)
89998999
90009000   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
90019001
trunk/src/mame/drivers/laserbat.c
r17996r17997
646646};
647647
648648
649static INTERRUPT_GEN( laserbat_interrupt )
649INTERRUPT_GEN_MEMBER(laserbat_state::laserbat_interrupt)
650650{
651   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x0a);
651   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x0a);
652652}
653653
654static INTERRUPT_GEN( zaccaria_cb1_toggle )
654INTERRUPT_GEN_MEMBER(laserbat_state::zaccaria_cb1_toggle)
655655{
656   laserbat_state *state = device->machine().driver_data<laserbat_state>();
657656
658   state->m_pia->cb1_w(state->m_cb1_toggle & 1);
659   state->m_cb1_toggle ^= 1;
657   m_pia->cb1_w(m_cb1_toggle & 1);
658   m_cb1_toggle ^= 1;
660659}
661660
662661
r17996r17997
750749   MCFG_CPU_ADD("maincpu", S2650, 14318180/4) // ???
751750   MCFG_CPU_PROGRAM_MAP(laserbat_map)
752751   MCFG_CPU_IO_MAP(laserbat_io_map)
753   MCFG_CPU_VBLANK_INT("screen", laserbat_interrupt)
752   MCFG_CPU_VBLANK_INT_DRIVER("screen", laserbat_state, laserbat_interrupt)
754753
755754
756755   /* video hardware */
r17996r17997
788787   MCFG_CPU_ADD("maincpu", S2650, 14318000/4)   /* ? */
789788   MCFG_CPU_PROGRAM_MAP(laserbat_map)
790789   MCFG_CPU_IO_MAP(catnmous_io_map)
791   MCFG_CPU_VBLANK_INT("screen", laserbat_interrupt)
790   MCFG_CPU_VBLANK_INT_DRIVER("screen", laserbat_state, laserbat_interrupt)
792791
793792   MCFG_CPU_ADD("audiocpu", M6802,3580000) /* ? */
794793   MCFG_CPU_PROGRAM_MAP(catnmous_sound_map)
795   MCFG_CPU_PERIODIC_INT(zaccaria_cb1_toggle, (double)3580000/4096)
794   MCFG_CPU_PERIODIC_INT_DRIVER(laserbat_state, zaccaria_cb1_toggle, (double)3580000/4096)
796795
797796   MCFG_PIA6821_ADD("pia", pia_intf)
798797
trunk/src/mame/drivers/tp84.c
r17996r17997
278278   GFXDECODE_ENTRY( "gfx2", 0, spritelayout, 64*4*8, 16*8 )
279279GFXDECODE_END
280280
281static INTERRUPT_GEN( sub_vblank_irq )
281INTERRUPT_GEN_MEMBER(tp84_state::sub_vblank_irq)
282282{
283   tp84_state *state = device->machine().driver_data<tp84_state>();
284283
285   if(state->m_sub_irq_mask)
286      device->execute().set_input_line(0, HOLD_LINE);
284   if(m_sub_irq_mask)
285      device.execute().set_input_line(0, HOLD_LINE);
287286}
288287
289288
r17996r17997
309308   /* basic machine hardware */
310309   MCFG_CPU_ADD("cpu1",M6809, XTAL_18_432MHz/12) /* verified on pcb */
311310   MCFG_CPU_PROGRAM_MAP(tp84_cpu1_map)
312   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
311   MCFG_CPU_VBLANK_INT_DRIVER("screen", tp84_state, irq0_line_hold)
313312
314313   MCFG_CPU_ADD("sub", M6809, XTAL_18_432MHz/12)   /* verified on pcb */
315314   MCFG_CPU_PROGRAM_MAP(cpu2_map)
316   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
315   MCFG_CPU_VBLANK_INT_DRIVER("screen", tp84_state, sub_vblank_irq)
317316
318317   MCFG_CPU_ADD("audiocpu", Z80,XTAL_14_31818MHz/4) /* verified on pcb */
319318   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/cheekyms.c
r17996r17997
115115   m_dac = machine().device<dac_device>("dac");
116116}
117117
118static INTERRUPT_GEN( vblank_irq )
118INTERRUPT_GEN_MEMBER(cheekyms_state::vblank_irq)
119119{
120   cheekyms_state *state = device->machine().driver_data<cheekyms_state>();
121120
122   if(state->m_irq_mask)
123      device->execute().set_input_line(0, HOLD_LINE);
121   if(m_irq_mask)
122      device.execute().set_input_line(0, HOLD_LINE);
124123}
125124
126125
r17996r17997
130129   MCFG_CPU_ADD("maincpu", Z80,5000000/2)  /* 2.5 MHz */
131130   MCFG_CPU_PROGRAM_MAP(main_map)
132131   MCFG_CPU_IO_MAP(io_map)
133   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
132   MCFG_CPU_VBLANK_INT_DRIVER("screen", cheekyms_state, vblank_irq)
134133
135134
136135   /* video hardware */
trunk/src/mame/drivers/asteroid.c
r17996r17997
615615   /* basic machine hardware */
616616   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/8)
617617   MCFG_CPU_PROGRAM_MAP(asteroid_map)
618   MCFG_CPU_PERIODIC_INT(asteroid_interrupt, (double)MASTER_CLOCK/4096/12)
618   MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, asteroid_interrupt, (double)MASTER_CLOCK/4096/12)
619619
620620
621621   /* video hardware */
r17996r17997
639639
640640   /* basic machine hardware */
641641   MCFG_CPU_MODIFY("maincpu")
642   MCFG_CPU_PERIODIC_INT(asterock_interrupt, (double)MASTER_CLOCK/4096/12)
642   MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, asterock_interrupt, (double)MASTER_CLOCK/4096/12)
643643MACHINE_CONFIG_END
644644
645645
r17996r17997
668668   /* basic machine hardware */
669669   MCFG_CPU_MODIFY("maincpu")
670670   MCFG_CPU_PROGRAM_MAP(llander_map)
671   MCFG_CPU_PERIODIC_INT(llander_interrupt, (double)MASTER_CLOCK/4096/12)
671   MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, llander_interrupt, (double)MASTER_CLOCK/4096/12)
672672
673673   MCFG_MACHINE_RESET(avgdvg)
674674
trunk/src/mame/drivers/timelimt.c
r17996r17997
214214   DEVCB_NULL
215215};
216216
217static INTERRUPT_GEN( timelimt_irq )
217INTERRUPT_GEN_MEMBER(timelimt_state::timelimt_irq)
218218{
219   timelimt_state *state = device->machine().driver_data<timelimt_state>();
220   if ( state->m_nmi_enabled )
221      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
219   if ( m_nmi_enabled )
220      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
222221}
223222
224223/***************************************************************************/
r17996r17997
229228   MCFG_CPU_ADD("maincpu", Z80, 5000000)   /* 5.000 MHz */
230229   MCFG_CPU_PROGRAM_MAP(main_map)
231230   MCFG_CPU_IO_MAP(main_io_map)
232   MCFG_CPU_VBLANK_INT("screen", timelimt_irq)
231   MCFG_CPU_VBLANK_INT_DRIVER("screen", timelimt_state, timelimt_irq)
233232
234233   MCFG_CPU_ADD("audiocpu", Z80,18432000/6)   /* 3.072 MHz */
235234   MCFG_CPU_PROGRAM_MAP(sound_map)
236235   MCFG_CPU_IO_MAP(sound_io_map)
237   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* ? */
236   MCFG_CPU_VBLANK_INT_DRIVER("screen", timelimt_state, irq0_line_hold) /* ? */
238237
239238   MCFG_QUANTUM_TIME(attotime::from_hz(3000))
240239
trunk/src/mame/drivers/champbwl.c
r17996r17997
480480   /* basic machine hardware */
481481   MCFG_CPU_ADD("maincpu", Z80, 16000000/4) /* 4MHz */
482482   MCFG_CPU_PROGRAM_MAP(champbwl_map)
483   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
483   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbwl_state, irq0_line_hold)
484484
485485   MCFG_NVRAM_ADD_0FILL("nvram")
486486
r17996r17997
544544   /* basic machine hardware */
545545   MCFG_CPU_ADD("maincpu", Z80, XTAL_14_31818MHz/4)
546546   MCFG_CPU_PROGRAM_MAP(doraemon)
547   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
547   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbwl_state, irq0_line_hold)
548548
549549   MCFG_NVRAM_ADD_0FILL("nvram")
550550   MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
trunk/src/mame/drivers/vamphalf.c
r17996r17997
985985static MACHINE_CONFIG_START( common, vamphalf_state )
986986   MCFG_CPU_ADD("maincpu", E116T, 50000000)   /* 50 MHz */
987987   MCFG_CPU_PROGRAM_MAP(common_map)
988   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
988   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
989989
990990   MCFG_EEPROM_93C46_ADD("eeprom")
991991
r17996r17997
10451045   MCFG_CPU_REPLACE("maincpu", GMS30C2116, 50000000)   /* 50 MHz */
10461046   MCFG_CPU_PROGRAM_MAP(common_map)
10471047   MCFG_CPU_IO_MAP(misncrft_io)
1048   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1048   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
10491049
10501050   MCFG_FRAGMENT_ADD(sound_qs1000)
10511051MACHINE_CONFIG_END
r17996r17997
10761076   MCFG_CPU_PROGRAM_MAP(common_map)
10771077   MCFG_CPU_MODIFY("maincpu")
10781078   MCFG_CPU_IO_MAP(mrdig_io)
1079   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1079   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
10801080
10811081   MCFG_FRAGMENT_ADD(sound_ym_oki)
10821082MACHINE_CONFIG_END
r17996r17997
10851085   MCFG_CPU_REPLACE("maincpu", E132T, 50000000)   /* 50 MHz */
10861086   MCFG_CPU_PROGRAM_MAP(common_32bit_map)
10871087   MCFG_CPU_IO_MAP(wyvernwg_io)
1088   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1088   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
10891089
10901090   MCFG_FRAGMENT_ADD(sound_qs1000)
10911091MACHINE_CONFIG_END
r17996r17997
10941094   MCFG_CPU_REPLACE("maincpu", E132T, 50000000)   /* 50 MHz */
10951095   MCFG_CPU_PROGRAM_MAP(common_32bit_map)
10961096   MCFG_CPU_IO_MAP(finalgdr_io)
1097   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1097   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
10981098
10991099   MCFG_NVRAM_ADD_0FILL("nvram")
11001100
r17996r17997
11051105   MCFG_CPU_REPLACE("maincpu", E132T, 50000000)   /* 50 MHz */
11061106   MCFG_CPU_PROGRAM_MAP(common_32bit_map)
11071107   MCFG_CPU_IO_MAP(mrkicker_io)
1108   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1108   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
11091109
11101110   MCFG_NVRAM_ADD_0FILL("nvram")
11111111
r17996r17997
11161116   MCFG_CPU_ADD("maincpu", E132XN, 20000000*4)   /* 4x internal multiplier */
11171117   MCFG_CPU_PROGRAM_MAP(aoh_map)
11181118   MCFG_CPU_IO_MAP(aoh_io)
1119   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1119   MCFG_CPU_VBLANK_INT_DRIVER("screen", vamphalf_state, irq1_line_hold)
11201120
11211121   MCFG_EEPROM_93C46_ADD("eeprom")
11221122
trunk/src/mame/drivers/1942.c
r17996r17997
262262
263263   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK)   /* 3 MHz ??? */
264264   MCFG_CPU_PROGRAM_MAP(sound_map)
265   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
265   MCFG_CPU_PERIODIC_INT_DRIVER(_1942_state, irq0_line_hold, 4*60)
266266
267267
268268   /* video hardware */
trunk/src/mame/drivers/poolshrk.c
r17996r17997
216216   /* basic machine hardware */
217217   MCFG_CPU_ADD("maincpu", M6800, 11055000 / 8) /* ? */
218218   MCFG_CPU_PROGRAM_MAP(poolshrk_cpu_map)
219   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
219   MCFG_CPU_VBLANK_INT_DRIVER("screen", poolshrk_state, irq0_line_assert)
220220
221221   /* video hardware */
222222   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mayumi.c
r17996r17997
4646   virtual void machine_reset();
4747   virtual void video_start();
4848   UINT32 screen_update_mayumi(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
49   INTERRUPT_GEN_MEMBER(mayumi_interrupt);
4950};
5051
5152
r17996r17997
8687 *
8788 *************************************/
8889
89static INTERRUPT_GEN( mayumi_interrupt )
90INTERRUPT_GEN_MEMBER(mayumi_state::mayumi_interrupt)
9091{
91   mayumi_state *state = device->machine().driver_data<mayumi_state>();
9292
93   if (state->m_int_enable)
94       device->execute().set_input_line(0, HOLD_LINE);
93   if (m_int_enable)
94       device.execute().set_input_line(0, HOLD_LINE);
9595}
9696
9797/*************************************
r17996r17997
399399   MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 5.000 MHz ? */
400400   MCFG_CPU_PROGRAM_MAP(mayumi_map)
401401   MCFG_CPU_IO_MAP(mayumi_io_map)
402   MCFG_CPU_VBLANK_INT("screen", mayumi_interrupt)
402   MCFG_CPU_VBLANK_INT_DRIVER("screen", mayumi_state, mayumi_interrupt)
403403
404404
405405   MCFG_I8255_ADD( "i8255", mayumi_i8255_intf )
trunk/src/mame/drivers/raiden.c
r17996r17997
237237
238238/******************************************************************************/
239239
240static INTERRUPT_GEN( raiden_interrupt )
240INTERRUPT_GEN_MEMBER(raiden_state::raiden_interrupt)
241241{
242   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   /* VBL */
242   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   /* VBL */
243243}
244244
245245static MACHINE_CONFIG_START( raiden, raiden_state )
r17996r17997
247247   /* basic machine hardware */
248248   MCFG_CPU_ADD("maincpu", V30,XTAL_20MHz/2) /* NEC V30 CPU, 20MHz verified on pcb */
249249   MCFG_CPU_PROGRAM_MAP(main_map)
250   MCFG_CPU_VBLANK_INT("screen", raiden_interrupt)
250   MCFG_CPU_VBLANK_INT_DRIVER("screen", raiden_state, raiden_interrupt)
251251
252252   MCFG_CPU_ADD("sub", V30,XTAL_20MHz/2) /* NEC V30 CPU, 20MHz verified on pcb */
253253   MCFG_CPU_PROGRAM_MAP(sub_map)
254   MCFG_CPU_VBLANK_INT("screen", raiden_interrupt)
254   MCFG_CPU_VBLANK_INT_DRIVER("screen", raiden_state, raiden_interrupt)
255255
256256   SEIBU_SOUND_SYSTEM_CPU(XTAL_14_31818MHz/4) /* verified on pcb */
257257
trunk/src/mame/drivers/bloodbro.c
r17996r17997
436436   // basic machine hardware
437437   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
438438   MCFG_CPU_PROGRAM_MAP(bloodbro_map)
439   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
439   MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq4_line_hold)
440440
441441   SEIBU_SOUND_SYSTEM_CPU(XTAL_7_15909MHz/2) /* verified on pcb */
442442
r17996r17997
463463
464464   MCFG_CPU_MODIFY("maincpu")
465465   MCFG_CPU_PROGRAM_MAP(weststry_map)
466   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
466   MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq6_line_hold)
467467
468468   MCFG_GFXDECODE(weststry)
469469   MCFG_PALETTE_LENGTH(1024)
r17996r17997
475475static MACHINE_CONFIG_DERIVED( skysmash, bloodbro )
476476
477477   MCFG_CPU_MODIFY("maincpu")
478   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
478   MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq2_line_hold)
479479
480480   MCFG_SCREEN_MODIFY("screen")
481481   MCFG_SCREEN_UPDATE_DRIVER(bloodbro_state, screen_update_skysmash)
trunk/src/mame/drivers/galaxia.c
r17996r17997
6767#include "includes/galaxia.h"
6868
6969
70static INTERRUPT_GEN( galaxia_interrupt )
70INTERRUPT_GEN_MEMBER(galaxia_state::galaxia_interrupt)
7171{
72   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
73   cvs_scroll_stars(device->machine());
72   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
73   cvs_scroll_stars(machine());
7474}
7575
7676
r17996r17997
296296   MCFG_CPU_ADD("maincpu", S2650, 2000000)       /* ? MHz */
297297   MCFG_CPU_PROGRAM_MAP(galaxia_mem_map)
298298   MCFG_CPU_IO_MAP(galaxia_io_map)
299   MCFG_CPU_VBLANK_INT("screen", galaxia_interrupt)
299   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxia_state, galaxia_interrupt)
300300
301301   /* video hardware */
302302   MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
r17996r17997
336336   MCFG_CPU_ADD("maincpu", S2650, 2000000)       /* ? MHz */
337337   MCFG_CPU_PROGRAM_MAP(astrowar_mem_map)
338338   MCFG_CPU_IO_MAP(galaxia_io_map)
339   MCFG_CPU_VBLANK_INT("screen", galaxia_interrupt)
339   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxia_state, galaxia_interrupt)
340340
341341   /* video hardware */
342342   MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
trunk/src/mame/drivers/fromanc2.c
r17996r17997
3131 *
3232 *************************************/
3333
34static INTERRUPT_GEN( fromanc2_interrupt )
34INTERRUPT_GEN_MEMBER(fromanc2_state::fromanc2_interrupt)
3535{
36   device->execute().set_input_line(1, HOLD_LINE);
36   device.execute().set_input_line(1, HOLD_LINE);
3737}
3838
3939
r17996r17997
546546   /* basic machine hardware */
547547   MCFG_CPU_ADD("maincpu", M68000,32000000/2)      /* 16.00 MHz */
548548   MCFG_CPU_PROGRAM_MAP(fromanc2_main_map)
549   MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
549   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
550550
551551   MCFG_CPU_ADD("audiocpu", Z80,32000000/4)      /* 8.00 MHz */
552552   MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
r17996r17997
596596   /* basic machine hardware */
597597   MCFG_CPU_ADD("maincpu", M68000,32000000/2)      /* 16.00 MHz */
598598   MCFG_CPU_PROGRAM_MAP(fromancr_main_map)
599   MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
599   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
600600
601601   MCFG_CPU_ADD("audiocpu", Z80,32000000/4)      /* 8.00 MHz */
602602   MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
r17996r17997
646646   /* basic machine hardware */
647647   MCFG_CPU_ADD("maincpu", M68000,32000000/2)      /* 16.00 MHz */
648648   MCFG_CPU_PROGRAM_MAP(fromanc4_main_map)
649   MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
649   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
650650
651651   MCFG_CPU_ADD("audiocpu", Z80,32000000/4)      /* 8.00 MHz */
652652   MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
trunk/src/mame/drivers/rallyx.c
r17996r17997
888888   m_stars_enable = 0;
889889}
890890
891static INTERRUPT_GEN( rallyx_vblank_irq )
891INTERRUPT_GEN_MEMBER(rallyx_state::rallyx_vblank_irq)
892892{
893   rallyx_state *state = device->machine().driver_data<rallyx_state>();
894893
895   if(state->m_main_irq_mask)
896      device->execute().set_input_line(0, ASSERT_LINE);
894   if(m_main_irq_mask)
895      device.execute().set_input_line(0, ASSERT_LINE);
897896}
898897
899static INTERRUPT_GEN( jungler_vblank_irq )
898INTERRUPT_GEN_MEMBER(rallyx_state::jungler_vblank_irq)
900899{
901   rallyx_state *state = device->machine().driver_data<rallyx_state>();
902900
903   if(state->m_main_irq_mask)
904      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
901   if(m_main_irq_mask)
902      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
905903}
906904
907905static MACHINE_CONFIG_START( rallyx, rallyx_state )
r17996r17997
910908   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
911909   MCFG_CPU_PROGRAM_MAP(rallyx_map)
912910   MCFG_CPU_IO_MAP(io_map)
913   MCFG_CPU_VBLANK_INT("screen", rallyx_vblank_irq)
911   MCFG_CPU_VBLANK_INT_DRIVER("screen", rallyx_state, rallyx_vblank_irq)
914912
915913   MCFG_MACHINE_START_OVERRIDE(rallyx_state,rallyx)
916914   MCFG_MACHINE_RESET_OVERRIDE(rallyx_state,rallyx)
r17996r17997
948946   /* basic machine hardware */
949947   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
950948   MCFG_CPU_PROGRAM_MAP(jungler_map)
951   MCFG_CPU_VBLANK_INT("screen", jungler_vblank_irq)
949   MCFG_CPU_VBLANK_INT_DRIVER("screen", rallyx_state, jungler_vblank_irq)
952950
953951   MCFG_MACHINE_START_OVERRIDE(rallyx_state,rallyx)
954952   MCFG_MACHINE_RESET_OVERRIDE(rallyx_state,rallyx)
trunk/src/mame/drivers/dai3wksi.c
r17996r17997
591591   /* basic machine hardware */
592592   MCFG_CPU_ADD("maincpu", Z80, XTAL_10MHz/4)
593593   MCFG_CPU_PROGRAM_MAP(main_map)
594   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
594   MCFG_CPU_VBLANK_INT_DRIVER("screen", dai3wksi_state, irq0_line_hold)
595595
596596
597597   /* video hardware */
trunk/src/mame/drivers/realbrk.c
r17996r17997
746746                        Billiard Academy Real Break
747747***************************************************************************/
748748
749static INTERRUPT_GEN( realbrk_interrupt )
749INTERRUPT_GEN_MEMBER(realbrk_state::realbrk_interrupt)
750750{
751751   /* VBlank is connected to INT1 (external interrupts pin 1) */
752   tmp68301_external_interrupt_1(device->machine());
752   tmp68301_external_interrupt_1(machine());
753753}
754754
755755static MACHINE_CONFIG_START( realbrk, realbrk_state )
r17996r17997
757757   /* basic machine hardware */
758758   MCFG_CPU_ADD("maincpu",M68000, XTAL_32MHz / 2)         /* !! TMP68301 !! */
759759   MCFG_CPU_PROGRAM_MAP(realbrk_mem)
760   MCFG_CPU_VBLANK_INT("screen", realbrk_interrupt)
760   MCFG_CPU_VBLANK_INT_DRIVER("screen", realbrk_state, realbrk_interrupt)
761761
762762   MCFG_MACHINE_START( tmp68301 )
763763   MCFG_MACHINE_RESET( tmp68301 )
trunk/src/mame/drivers/diverboy.c
r17996r17997
257257
258258   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* guess */
259259   MCFG_CPU_PROGRAM_MAP(diverboy_map)
260   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
260   MCFG_CPU_VBLANK_INT_DRIVER("screen", diverboy_state, irq6_line_hold)
261261
262262   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
263263   MCFG_CPU_PROGRAM_MAP(snd_map)
trunk/src/mame/drivers/carjmbre.c
r17996r17997
190190   m_bgcolor = 0;
191191}
192192
193static INTERRUPT_GEN( vblank_irq )
193INTERRUPT_GEN_MEMBER(carjmbre_state::vblank_irq)
194194{
195   carjmbre_state *state = device->machine().driver_data<carjmbre_state>();
196195
197   if(state->m_nmi_mask)
198      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
196   if(m_nmi_mask)
197      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
199198}
200199
201200static MACHINE_CONFIG_START( carjmbre, carjmbre_state )
r17996r17997
203202   /* basic machine hardware */
204203   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
205204   MCFG_CPU_PROGRAM_MAP(carjmbre_map)
206   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
205   MCFG_CPU_VBLANK_INT_DRIVER("screen", carjmbre_state, vblank_irq)
207206
208207
209208   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6/2)
210209   MCFG_CPU_PROGRAM_MAP(carjmbre_sound_map)
211210   MCFG_CPU_IO_MAP(carjmbre_sound_io_map)
212   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
211   MCFG_CPU_VBLANK_INT_DRIVER("screen", carjmbre_state, irq0_line_hold)
213212
214213   /* video hardware */
215214   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/vmetal.c
r17996r17997
484484   /* basic machine hardware */
485485   MCFG_CPU_ADD("maincpu", M68000, 16000000)
486486   MCFG_CPU_PROGRAM_MAP(varia_program_map)
487   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) // also level 3
487   MCFG_CPU_VBLANK_INT_DRIVER("screen", vmetal_state, irq1_line_hold) // also level 3
488488
489489   /* video hardware */
490490   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/superchs.c
r17996r17997
328328   /* basic machine hardware */
329329   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_32MHz/2)
330330   MCFG_CPU_PROGRAM_MAP(superchs_map)
331   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
331   MCFG_CPU_VBLANK_INT_DRIVER("screen", superchs_state, irq2_line_hold)
332332
333333   MCFG_CPU_ADD("sub", M68000, XTAL_32MHz/2)
334334   MCFG_CPU_PROGRAM_MAP(superchs_cpub_map)
335   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
335   MCFG_CPU_VBLANK_INT_DRIVER("screen", superchs_state, irq4_line_hold)
336336
337337   MCFG_QUANTUM_TIME(attotime::from_hz(480)) /* Need to interleave CPU 1 & 3 */
338338
trunk/src/mame/drivers/flower.c
r17996r17997
250250   // cpus are Z80 "A" type, official maximum speed of 4 MHz, but 4.6 MHz has been proven to work in practice
251251   MCFG_CPU_ADD("maincpu", Z80,XTAL_18_432MHz/4)
252252   MCFG_CPU_PROGRAM_MAP(flower_cpu1_2)
253   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
253   MCFG_CPU_VBLANK_INT_DRIVER("screen", flower_state, irq0_line_hold)
254254
255255   MCFG_CPU_ADD("subcpu", Z80,XTAL_18_432MHz/4)
256256   MCFG_CPU_PROGRAM_MAP(flower_cpu1_2)
257   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 120)   // controls game speed? irqsource and frequency unknown
257   MCFG_CPU_PERIODIC_INT_DRIVER(flower_state, irq0_line_hold, 120)   // controls game speed? irqsource and frequency unknown
258258
259259   MCFG_CPU_ADD("audiocpu", Z80,XTAL_18_432MHz/4)
260260   MCFG_CPU_PROGRAM_MAP(flower_sound_cpu)
261   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 90)   // controls music speed. irqsource and frequency unknown, same as subcpu perhaps?
261   MCFG_CPU_PERIODIC_INT_DRIVER(flower_state, irq0_line_hold, 90)   // controls music speed. irqsource and frequency unknown, same as subcpu perhaps?
262262
263263   // tight sync, slowdowns otherwise
264264//  MCFG_QUANTUM_PERFECT_CPU("maincpu")
trunk/src/mame/drivers/namcos1.c
r17996r17997
10831083   /* basic machine hardware */
10841084   MCFG_CPU_ADD("maincpu", M6809,49152000/32)
10851085   MCFG_CPU_PROGRAM_MAP(main_map)
1086   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1086   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos1_state, irq0_line_assert)
10871087
10881088   MCFG_CPU_ADD("sub", M6809,49152000/32)
10891089   MCFG_CPU_PROGRAM_MAP(sub_map)
1090   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1090   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos1_state, irq0_line_assert)
10911091
10921092   MCFG_CPU_ADD("audiocpu", M6809,49152000/32)
10931093   MCFG_CPU_PROGRAM_MAP(sound_map)
1094   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1094   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos1_state, irq0_line_assert)
10951095
10961096   MCFG_CPU_ADD("mcu",HD63701,49152000/8)
10971097   MCFG_CPU_PROGRAM_MAP(mcu_map)
10981098   MCFG_CPU_IO_MAP(mcu_port_map)
1099   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1099   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos1_state, irq0_line_assert)
11001100
11011101   // heavy sync required to prevent CPUs from fighting for video RAM access and going into deadlocks
11021102   MCFG_QUANTUM_TIME(attotime::from_hz(38400))
trunk/src/mame/drivers/mrdo.c
r17996r17997
186186   /* basic machine hardware */
187187   MCFG_CPU_ADD("maincpu", Z80, MAIN_CLOCK/2)   /* Verified */
188188   MCFG_CPU_PROGRAM_MAP(main_map)
189   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
189   MCFG_CPU_VBLANK_INT_DRIVER("screen", mrdo_state, irq0_line_hold)
190190
191191   /* video hardware */
192192   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mainevt.c
r17996r17997
3131#include "includes/konamipt.h"
3232#include "includes/mainevt.h"
3333
34static INTERRUPT_GEN( mainevt_interrupt )
34INTERRUPT_GEN_MEMBER(mainevt_state::mainevt_interrupt)
3535{
36   mainevt_state *state = device->machine().driver_data<mainevt_state>();
3736
38   if (k052109_is_irq_enabled(state->m_k052109))
37   if (k052109_is_irq_enabled(m_k052109))
3938      irq0_line_hold(device);
4039}
4140
r17996r17997
4443   m_nmi_enable = data;
4544}
4645
47static INTERRUPT_GEN( dv_interrupt )
46INTERRUPT_GEN_MEMBER(mainevt_state::dv_interrupt)
4847{
49   mainevt_state *state = device->machine().driver_data<mainevt_state>();
5048
51   if (state->m_nmi_enable)
49   if (m_nmi_enable)
5250      nmi_line_pulse(device);
5351}
5452
r17996r17997
433431   m_nmi_enable = 0;
434432}
435433
436static INTERRUPT_GEN( mainevt_sound_timer_irq )
434INTERRUPT_GEN_MEMBER(mainevt_state::mainevt_sound_timer_irq)
437435{
438   mainevt_state *state = device->machine().driver_data<mainevt_state>();
439436
440   if(state->m_sound_irq_mask)
441      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
437   if(m_sound_irq_mask)
438      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
442439}
443440
444static INTERRUPT_GEN( devstors_sound_timer_irq )
441INTERRUPT_GEN_MEMBER(mainevt_state::devstors_sound_timer_irq)
445442{
446   mainevt_state *state = device->machine().driver_data<mainevt_state>();
447443
448   if(state->m_sound_irq_mask)
449      device->execute().set_input_line(0, HOLD_LINE);
444   if(m_sound_irq_mask)
445      device.execute().set_input_line(0, HOLD_LINE);
450446}
451447
452448static MACHINE_CONFIG_START( mainevt, mainevt_state )
r17996r17997
454450   /* basic machine hardware */
455451   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)   /* ?? */
456452   MCFG_CPU_PROGRAM_MAP(mainevt_map)
457   MCFG_CPU_VBLANK_INT("screen", mainevt_interrupt)
453   MCFG_CPU_VBLANK_INT_DRIVER("screen", mainevt_state, mainevt_interrupt)
458454
459455   MCFG_CPU_ADD("audiocpu", Z80, 3579545)   /* 3.579545 MHz */
460456   MCFG_CPU_PROGRAM_MAP(mainevt_sound_map)
461   MCFG_CPU_PERIODIC_INT(mainevt_sound_timer_irq,8*60)   /* ??? */
457   MCFG_CPU_PERIODIC_INT_DRIVER(mainevt_state, mainevt_sound_timer_irq, 8*60)   /* ??? */
462458
463459
464460   /* video hardware */
r17996r17997
512508   /* basic machine hardware */
513509   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)   /* ?? */
514510   MCFG_CPU_PROGRAM_MAP(devstors_map)
515   MCFG_CPU_VBLANK_INT("screen", dv_interrupt)
511   MCFG_CPU_VBLANK_INT_DRIVER("screen", mainevt_state, dv_interrupt)
516512
517513   MCFG_CPU_ADD("audiocpu", Z80, 3579545)   /* 3.579545 MHz */
518514   MCFG_CPU_PROGRAM_MAP(devstors_sound_map)
519   MCFG_CPU_PERIODIC_INT(devstors_sound_timer_irq,4*60) /* ??? */
515   MCFG_CPU_PERIODIC_INT_DRIVER(mainevt_state, devstors_sound_timer_irq, 4*60) /* ??? */
520516
521517
522518   /* video hardware */
trunk/src/mame/drivers/toki.c
r17996r17997
418418   /* basic machine hardware */
419419   MCFG_CPU_ADD("maincpu", M68000,XTAL_20MHz /2)   /* verified on pcb */
420420   MCFG_CPU_PROGRAM_MAP(toki_map)
421   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* VBL */
421   MCFG_CPU_VBLANK_INT_DRIVER("screen", toki_state, irq1_line_hold)/* VBL */
422422
423423   SEIBU_SOUND_SYSTEM_CPU(XTAL_14_31818MHz/4)   /* verifed on pcb */
424424
r17996r17997
448448   /* basic machine hardware */
449449   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10MHz causes bad slowdowns with monkey machine rd1, but is correct, 20Mhz XTAL */
450450   MCFG_CPU_PROGRAM_MAP(tokib_map)
451   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL (could be level1, same vector) */
451   MCFG_CPU_VBLANK_INT_DRIVER("screen", toki_state, irq6_line_hold)/* VBL (could be level1, same vector) */
452452
453453   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* verified with PCB */
454454   MCFG_CPU_PROGRAM_MAP(tokib_audio_map)
trunk/src/mame/drivers/deco156.c
r17996r17997
5555   DECLARE_DRIVER_INIT(wcvol95);
5656   virtual void video_start();
5757   UINT32 screen_update_wcvol95(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
58   INTERRUPT_GEN_MEMBER(deco32_vbl_interrupt);
5859};
5960
6061
r17996r17997
313314   sound_irq_gen
314315};
315316
316static INTERRUPT_GEN( deco32_vbl_interrupt )
317INTERRUPT_GEN_MEMBER(deco156_state::deco32_vbl_interrupt)
317318{
318   device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
319   device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
319320}
320321
321322static int deco156_bank_callback(const int bank)
r17996r17997
354355   /* basic machine hardware */
355356   MCFG_CPU_ADD("maincpu", ARM, 28000000) /* Unconfirmed */
356357   MCFG_CPU_PROGRAM_MAP(hvysmsh_map)
357   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
358   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco156_state, deco32_vbl_interrupt)
358359
359360   MCFG_EEPROM_93C46_ADD("eeprom")
360361
r17996r17997
391392   /* basic machine hardware */
392393   MCFG_CPU_ADD("maincpu", ARM, 28000000) /* Unconfirmed */
393394   MCFG_CPU_PROGRAM_MAP(wcvol95_map)
394   MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
395   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco156_state, deco32_vbl_interrupt)
395396
396397   MCFG_EEPROM_93C46_ADD("eeprom")
397398
trunk/src/mame/drivers/junofrst.c
r17996r17997
118118   DECLARE_DRIVER_INIT(junofrst);
119119   DECLARE_MACHINE_START(junofrst);
120120   DECLARE_MACHINE_RESET(junofrst);
121   INTERRUPT_GEN_MEMBER(junofrst_30hz_irq);
121122};
122123
123124
r17996r17997
418419   m_blitterdata[3] = 0;
419420}
420421
421static INTERRUPT_GEN( junofrst_30hz_irq )
422INTERRUPT_GEN_MEMBER(junofrst_state::junofrst_30hz_irq)
422423{
423   junofrst_state *state = device->machine().driver_data<junofrst_state>();
424424
425425   /* flip flops cause the interrupt to be signalled every other frame */
426   state->m_irq_toggle ^= 1;
427   if (state->m_irq_toggle && state->m_irq_enable)
428      device->execute().set_input_line(0, ASSERT_LINE);
426   m_irq_toggle ^= 1;
427   if (m_irq_toggle && m_irq_enable)
428      device.execute().set_input_line(0, ASSERT_LINE);
429429}
430430
431431static MACHINE_CONFIG_START( junofrst, junofrst_state )
r17996r17997
433433   /* basic machine hardware */
434434   MCFG_CPU_ADD("maincpu", M6809, 1500000)         /* 1.5 MHz ??? */
435435   MCFG_CPU_PROGRAM_MAP(main_map)
436   MCFG_CPU_VBLANK_INT("screen", junofrst_30hz_irq)
436   MCFG_CPU_VBLANK_INT_DRIVER("screen", junofrst_state, junofrst_30hz_irq)
437437
438438   MCFG_CPU_ADD("audiocpu", Z80,14318000/8)   /* 1.78975 MHz */
439439   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/caswin.c
r17996r17997
305305   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* ? MHz */
306306   MCFG_CPU_PROGRAM_MAP(vvillage_mem)
307307   MCFG_CPU_IO_MAP(vvillage_io)
308   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold )
308   MCFG_CPU_VBLANK_INT_DRIVER("screen", caswin_state,  irq0_line_hold)
309309
310310   /* video hardware */
311311   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/hitpoker.c
r17996r17997
8282   DECLARE_DRIVER_INIT(hitpoker);
8383   virtual void video_start();
8484   UINT32 screen_update_hitpoker(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
85   INTERRUPT_GEN_MEMBER(hitpoker_irq);
8586};
8687
8788
r17996r17997
485486   0x01   //INIT defaults to 0x01
486487};
487488
488static INTERRUPT_GEN( hitpoker_irq )
489INTERRUPT_GEN_MEMBER(hitpoker_state::hitpoker_irq)
489490{
490   device->execute().set_input_line(MC68HC11_IRQ_LINE, HOLD_LINE);
491   device.execute().set_input_line(MC68HC11_IRQ_LINE, HOLD_LINE);
491492}
492493
493494static MACHINE_CONFIG_START( hitpoker, hitpoker_state )
r17996r17997
495496   MCFG_CPU_PROGRAM_MAP(hitpoker_map)
496497   MCFG_CPU_IO_MAP(hitpoker_io)
497498   MCFG_CPU_CONFIG(hitpoker_config)
498   MCFG_CPU_VBLANK_INT("screen", hitpoker_irq)
499   MCFG_CPU_VBLANK_INT_DRIVER("screen", hitpoker_state, hitpoker_irq)
499500
500501   MCFG_NVRAM_ADD_0FILL("nvram")
501502
trunk/src/mame/drivers/taito_h.c
r17996r17997
566566   /* basic machine hardware */
567567   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz / 2)      /* 12 MHz */
568568   MCFG_CPU_PROGRAM_MAP(syvalion_map)
569   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
569   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoh_state, irq2_line_hold)
570570
571571   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz / 2)      /* 4 MHz ??? */
572572   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
607607   /* basic machine hardware */
608608   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz / 2)      /* 12 MHz */
609609   MCFG_CPU_PROGRAM_MAP(recordbr_map)
610   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
610   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoh_state, irq2_line_hold)
611611
612612   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz / 2)      /* 4 MHz ??? */
613613   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
648648   /* basic machine hardware */
649649   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz / 2)      /* 12 MHz */
650650   MCFG_CPU_PROGRAM_MAP(dleague_map)
651   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
651   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoh_state, irq1_line_hold)
652652
653653   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz / 2)      /* 4 MHz ??? */
654654   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/ginganin.c
r17996r17997
261261   /* basic machine hardware */
262262   MCFG_CPU_ADD("maincpu", M68000, MAIN_CLOCK)
263263   MCFG_CPU_PROGRAM_MAP(ginganin_map)
264   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) /* ? (vectors 1-7 cointain the same address) */
264   MCFG_CPU_VBLANK_INT_DRIVER("screen", ginganin_state, irq1_line_hold) /* ? (vectors 1-7 cointain the same address) */
265265
266266   MCFG_CPU_ADD("audiocpu", M6809, SOUND_CLOCK)
267267   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tail2nos.c
r17996r17997
238238   /* basic machine hardware */
239239   MCFG_CPU_ADD("maincpu", M68000,XTAL_20MHz/2)   /* verified on pcb */
240240   MCFG_CPU_PROGRAM_MAP(main_map)
241   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
241   MCFG_CPU_VBLANK_INT_DRIVER("screen", tail2nos_state, irq6_line_hold)
242242
243243   MCFG_CPU_ADD("audiocpu", Z80,XTAL_20MHz/4)   /* verified on pcb */
244244   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/m79amb.c
r17996r17997
7979   DECLARE_WRITE8_MEMBER(m79amb_8002_w);
8080   DECLARE_DRIVER_INIT(m79amb);
8181   UINT32 screen_update_ramtek(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
82   INTERRUPT_GEN_MEMBER(m79amb_interrupt);
8283};
8384
8485
r17996r17997
202203INPUT_PORTS_END
203204
204205
205static INTERRUPT_GEN( m79amb_interrupt )
206INTERRUPT_GEN_MEMBER(m79amb_state::m79amb_interrupt)
206207{
207   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf);  /* RST 08h */
208   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf);  /* RST 08h */
208209}
209210
210211static MACHINE_CONFIG_START( m79amb, m79amb_state )
r17996r17997
212213   /* basic machine hardware */
213214   MCFG_CPU_ADD("maincpu", I8080, XTAL_19_6608MHz / 10)
214215   MCFG_CPU_PROGRAM_MAP(main_map)
215   MCFG_CPU_VBLANK_INT("screen", m79amb_interrupt)
216   MCFG_CPU_VBLANK_INT_DRIVER("screen", m79amb_state, m79amb_interrupt)
216217
217218   /* video hardware */
218219   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mrjong.c
r17996r17997
201201   MCFG_CPU_ADD("maincpu", Z80,15468000/6)   /* 2.578 MHz?? */
202202   MCFG_CPU_PROGRAM_MAP(mrjong_map)
203203   MCFG_CPU_IO_MAP(mrjong_io_map)
204   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
204   MCFG_CPU_VBLANK_INT_DRIVER("screen", mrjong_state, nmi_line_pulse)
205205
206206   /* video hardware */
207207   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/slapshot.c
r17996r17997
178178}
179179
180180
181static INTERRUPT_GEN( slapshot_interrupt )
181INTERRUPT_GEN_MEMBER(slapshot_state::slapshot_interrupt)
182182{
183   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000 - 500), FUNC(slapshot_interrupt6));
184   device->execute().set_input_line(5, HOLD_LINE);
183   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000 - 500), FUNC(slapshot_interrupt6));
184   device.execute().set_input_line(5, HOLD_LINE);
185185}
186186
187187
r17996r17997
543543   /* basic machine hardware */
544544   MCFG_CPU_ADD("maincpu", M68000, 14346000)   /* 28.6860 MHz / 2 ??? */
545545   MCFG_CPU_PROGRAM_MAP(slapshot_map)
546   MCFG_CPU_VBLANK_INT("screen", slapshot_interrupt)
546   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapshot_state, slapshot_interrupt)
547547
548548   MCFG_CPU_ADD("audiocpu", Z80,32000000/8)   /* 4 MHz */
549549   MCFG_CPU_PROGRAM_MAP(opwolf3_z80_sound_map)
r17996r17997
589589   /* basic machine hardware */
590590   MCFG_CPU_ADD("maincpu", M68000, 14346000)   /* 28.6860 MHz / 2 ??? */
591591   MCFG_CPU_PROGRAM_MAP(opwolf3_map)
592   MCFG_CPU_VBLANK_INT("screen", slapshot_interrupt)
592   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapshot_state, slapshot_interrupt)
593593
594594   MCFG_CPU_ADD("audiocpu", Z80,32000000/8)   /* 4 MHz */
595595   MCFG_CPU_PROGRAM_MAP(opwolf3_z80_sound_map)
trunk/src/mame/drivers/ertictac.c
r17996r17997
3838   DECLARE_DRIVER_INIT(ertictac);
3939   virtual void machine_start();
4040   virtual void machine_reset();
41   INTERRUPT_GEN_MEMBER(ertictac_podule_irq);
4142};
4243
4344
r17996r17997
208209   archimedes_reset(machine());
209210}
210211
211static INTERRUPT_GEN( ertictac_podule_irq )
212INTERRUPT_GEN_MEMBER(ertictac_state::ertictac_podule_irq)
212213{
213   archimedes_request_irq_b(device->machine(), ARCHIMEDES_IRQB_PODULE_IRQ);
214   archimedes_request_irq_b(machine(), ARCHIMEDES_IRQB_PODULE_IRQ);
214215}
215216
216217/* TODO: Are we sure that this HW have I2C device? */
r17996r17997
226227
227228   MCFG_CPU_ADD("maincpu", ARM, XTAL_24MHz/3) /* guess, 12MHz 8MHz or 6MHz, what's the correct divider 2, 3 or 4? */
228229   MCFG_CPU_PROGRAM_MAP(ertictac_map)
229   MCFG_CPU_PERIODIC_INT(ertictac_podule_irq,60) // FIXME: timing of this
230   MCFG_CPU_PERIODIC_INT_DRIVER(ertictac_state, ertictac_podule_irq, 60) // FIXME: timing of this
230231
231232
232233   MCFG_I2CMEM_ADD("i2cmem",i2cmem_interface)
trunk/src/mame/drivers/victory.c
r17996r17997
214214   MCFG_CPU_ADD("maincpu", Z80, VICTORY_MAIN_CPU_CLOCK)
215215   MCFG_CPU_PROGRAM_MAP(main_map)
216216   MCFG_CPU_IO_MAP(main_io_map)
217   MCFG_CPU_VBLANK_INT("screen", victory_vblank_interrupt)
217   MCFG_CPU_VBLANK_INT_DRIVER("screen", victory_state, victory_vblank_interrupt)
218218
219219   MCFG_NVRAM_ADD_0FILL("nvram")
220220
trunk/src/mame/drivers/atarisy4.c
r17996r17997
5959   virtual void video_reset();
6060   DECLARE_MACHINE_RESET(airrace);
6161   UINT32 screen_update_atarisy4(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(vblank_int);
6263};
6364
6465
r17996r17997
516517   return res;
517518}
518519
519static INTERRUPT_GEN( vblank_int )
520INTERRUPT_GEN_MEMBER(atarisy4_state::vblank_int)
520521{
521522   if (gpu.mcr & 0x08)
522      device->machine().device("maincpu")->execute().set_input_line(6, ASSERT_LINE);
523      machine().device("maincpu")->execute().set_input_line(6, ASSERT_LINE);
523524}
524525
525526
r17996r17997
730731static MACHINE_CONFIG_START( atarisy4, atarisy4_state )
731732   MCFG_CPU_ADD("maincpu", M68000, 8000000)
732733   MCFG_CPU_PROGRAM_MAP(main_map)
733   MCFG_CPU_VBLANK_INT("screen", vblank_int)
734   MCFG_CPU_VBLANK_INT_DRIVER("screen", atarisy4_state, vblank_int)
734735
735736   MCFG_CPU_ADD("dsp0", TMS32010, 16000000)
736737   MCFG_CPU_PROGRAM_MAP(dsp0_map)
trunk/src/mame/drivers/lucky74.c
r17996r17997
901901*    Interrupts Gen     *
902902************************/
903903
904static INTERRUPT_GEN( nmi_interrupt )
904INTERRUPT_GEN_MEMBER(lucky74_state::nmi_interrupt)
905905{
906   lucky74_state *state = device->machine().driver_data<lucky74_state>();
907   if ((state->m_ym2149_portb & 0x10) == 0)   /* ym2149 portB bit 4 trigger the NMI */
906   if ((m_ym2149_portb & 0x10) == 0)   /* ym2149 portB bit 4 trigger the NMI */
908907   {
909      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
908      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
910909   }
911910}
912911
r17996r17997
13611360   MCFG_CPU_ADD("maincpu", Z80, C_06B49P_CLKOUT_03)   /* 3 MHz. */
13621361   MCFG_CPU_PROGRAM_MAP(lucky74_map)
13631362   MCFG_CPU_IO_MAP(lucky74_portmap)
1364   MCFG_CPU_VBLANK_INT("screen", nmi_interrupt)   /* 60 Hz. measured */
1363   MCFG_CPU_VBLANK_INT_DRIVER("screen", lucky74_state, nmi_interrupt)   /* 60 Hz. measured */
13651364
13661365   MCFG_NVRAM_ADD_0FILL("nvram")
13671366
trunk/src/mame/drivers/wardner.c
r17996r17997
391391   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4)      /* 6MHz */
392392   MCFG_CPU_PROGRAM_MAP(main_program_map)
393393   MCFG_CPU_IO_MAP(main_io_map)
394   MCFG_CPU_VBLANK_INT("screen", wardner_interrupt)
394   MCFG_CPU_VBLANK_INT_DRIVER("screen", wardner_state, wardner_interrupt)
395395
396396   MCFG_CPU_ADD("audiocpu", Z80, XTAL_14MHz/4)      /* 3.5MHz */
397397   MCFG_CPU_PROGRAM_MAP(sound_program_map)
trunk/src/mame/drivers/cninja.c
r17996r17997
906906   /* basic machine hardware */
907907   MCFG_CPU_ADD("maincpu", M68000, 12000000)
908908   MCFG_CPU_PROGRAM_MAP(cninja_map)
909   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
909   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
910910
911911   MCFG_CPU_ADD("audiocpu", H6280,32220000/8)   /* Accurate */
912912   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
958958   /* basic machine hardware */
959959   MCFG_CPU_ADD("maincpu", M68000, 12000000)
960960   MCFG_CPU_PROGRAM_MAP(cninja_map)
961   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
961   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
962962
963963   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
964964   MCFG_CPU_PROGRAM_MAP(stoneage_s_map)
r17996r17997
10101010   /* basic machine hardware */
10111011   MCFG_CPU_ADD("maincpu", M68000, 12000000)
10121012   MCFG_CPU_PROGRAM_MAP(cninjabl_map)
1013   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1013   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
10141014
10151015   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
10161016   MCFG_CPU_PROGRAM_MAP(stoneage_s_map)
r17996r17997
10531053   /* basic machine hardware */
10541054   MCFG_CPU_ADD("maincpu", M68000, 12000000)
10551055   MCFG_CPU_PROGRAM_MAP(edrandy_map)
1056   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1056   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
10571057
10581058   MCFG_CPU_ADD("audiocpu", H6280,32220000/8)   /* Accurate */
10591059   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
11051105   /* basic machine hardware */
11061106   MCFG_CPU_ADD("maincpu", M68000, 14000000)
11071107   MCFG_CPU_PROGRAM_MAP(robocop2_map)
1108   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1108   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
11091109
11101110   MCFG_CPU_ADD("audiocpu", H6280,32220000/8)   /* Accurate */
11111111   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
11601160   /* basic machine hardware */
11611161   MCFG_CPU_ADD("maincpu", M68000, 14000000)
11621162   MCFG_CPU_PROGRAM_MAP(mutantf_map)
1163   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
1163   MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq6_line_hold)
11641164
11651165   MCFG_CPU_ADD("audiocpu", H6280,32220000/8)
11661166   MCFG_CPU_PROGRAM_MAP(sound_map_mutantf)
trunk/src/mame/drivers/go2000.c
r17996r17997
326326
327327   MCFG_CPU_ADD("maincpu", M68000, 10000000)
328328   MCFG_CPU_PROGRAM_MAP(go2000_map)
329   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
329   MCFG_CPU_VBLANK_INT_DRIVER("screen", go2000_state, irq1_line_hold)
330330
331331   MCFG_CPU_ADD("soundcpu", Z80, 4000000)
332332   MCFG_CPU_PROGRAM_MAP(go2000_sound_map)
trunk/src/mame/drivers/jack.c
r17996r17997
813813   /* basic machine hardware */
814814   MCFG_CPU_ADD("maincpu", Z80, 18000000/6)   /* 3 MHz */
815815   MCFG_CPU_PROGRAM_MAP(jack_map)
816   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* jack needs 1 or its too fast */
816   MCFG_CPU_VBLANK_INT_DRIVER("screen", jack_state, irq0_line_hold) /* jack needs 1 or its too fast */
817817
818818   MCFG_CPU_ADD("audiocpu", Z80,18000000/12)   /* 1.5 MHz */
819819   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
844844
845845   /* basic machine hardware */
846846   MCFG_CPU_MODIFY("maincpu")
847   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* tripool needs 2 or the palette is broken */
847   MCFG_CPU_PERIODIC_INT_DRIVER(jack_state, irq0_line_hold, 2*60) /* tripool needs 2 or the palette is broken */
848848MACHINE_CONFIG_END
849849
850static INTERRUPT_GEN( joinem_vblank_irq )
850INTERRUPT_GEN_MEMBER(jack_state::joinem_vblank_irq)
851851{
852852    /* TODO: looks hackish to me ... */
853   if (!(device->machine().root_device().ioport("IN2")->read() & 0x80))
854      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
853   if (!(machine().root_device().ioport("IN2")->read() & 0x80))
854      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
855855}
856856
857857static MACHINE_CONFIG_DERIVED( joinem, jack )
r17996r17997
859859   /* basic machine hardware */
860860   MCFG_CPU_MODIFY("maincpu")
861861   MCFG_CPU_PROGRAM_MAP(joinem_map)
862   MCFG_CPU_VBLANK_INT("screen",joinem_vblank_irq)
863   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
862   MCFG_CPU_VBLANK_INT_DRIVER("screen", jack_state, joinem_vblank_irq)
863   MCFG_CPU_PERIODIC_INT_DRIVER(jack_state, irq0_line_hold, 2*60)
864864
865865   MCFG_GFXDECODE(joinem)
866866   MCFG_PALETTE_LENGTH(0x100)
r17996r17997
879879   /* basic machine hardware */
880880   MCFG_CPU_MODIFY("maincpu")
881881   MCFG_CPU_PROGRAM_MAP(joinem_map)
882   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
882   MCFG_CPU_VBLANK_INT_DRIVER("screen", jack_state, nmi_line_pulse)
883883
884884   MCFG_GFXDECODE(joinem)
885885   MCFG_PALETTE_LENGTH(0x100)
trunk/src/mame/drivers/dogfgt.c
r17996r17997
242242   /* basic machine hardware */
243243   MCFG_CPU_ADD("maincpu", M6502, 1500000)   /* 1.5 MHz ???? */
244244   MCFG_CPU_PROGRAM_MAP(main_map)
245   MCFG_CPU_PERIODIC_INT(irq0_line_hold,16*60)   /* ? controls music tempo */
245   MCFG_CPU_PERIODIC_INT_DRIVER(dogfgt_state, irq0_line_hold, 16*60)   /* ? controls music tempo */
246246
247247   MCFG_CPU_ADD("sub", M6502, 1500000)   /* 1.5 MHz ???? */
248248   MCFG_CPU_PROGRAM_MAP(sub_map)
trunk/src/mame/drivers/vigilant.c
r17996r17997
483483   MCFG_CPU_ADD("maincpu", Z80, 3579645)         /* 3.579645 MHz */
484484   MCFG_CPU_PROGRAM_MAP(vigilant_map)
485485   MCFG_CPU_IO_MAP(vigilant_io_map)
486   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
486   MCFG_CPU_VBLANK_INT_DRIVER("screen", vigilant_state, irq0_line_hold)
487487
488488   MCFG_CPU_ADD("soundcpu", Z80, 3579645)         /* 3.579645 MHz */
489489   MCFG_CPU_PROGRAM_MAP(sound_map)
490490   MCFG_CPU_IO_MAP(sound_io_map)
491   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1 */
491   MCFG_CPU_PERIODIC_INT_DRIVER(vigilant_state, nmi_line_pulse, 128*55)   /* clocked by V1 */
492492                        /* IRQs are generated by main Z80 and YM2151 */
493493   /* video hardware */
494494   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
523523   MCFG_CPU_ADD("maincpu", Z80, 5688800)         /* 5.688800 MHz */
524524   MCFG_CPU_PROGRAM_MAP(vigilant_map)
525525   MCFG_CPU_IO_MAP(vigilant_io_map)
526   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
526   MCFG_CPU_VBLANK_INT_DRIVER("screen", vigilant_state, irq0_line_hold)
527527
528528   MCFG_CPU_ADD("soundcpu", Z80, 18432000/6)         /* 3.072000 MHz */
529529   MCFG_CPU_PROGRAM_MAP(sound_map)
530530   MCFG_CPU_IO_MAP(buccanrs_sound_io_map)
531   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1 */
531   MCFG_CPU_PERIODIC_INT_DRIVER(vigilant_state, nmi_line_pulse, 128*55)   /* clocked by V1 */
532532                        /* IRQs are generated by main Z80 and YM2151 */
533533   /* video hardware */
534534   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
579579   MCFG_CPU_ADD("maincpu", Z80, 3579645)         /* 3.579645 MHz */
580580   MCFG_CPU_PROGRAM_MAP(kikcubic_map)
581581   MCFG_CPU_IO_MAP(kikcubic_io_map)
582   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
582   MCFG_CPU_VBLANK_INT_DRIVER("screen", vigilant_state, irq0_line_hold)
583583
584584   MCFG_CPU_ADD("soundcpu", Z80, 3579645)         /* 3.579645 MHz */
585585   MCFG_CPU_PROGRAM_MAP(sound_map)
586586   MCFG_CPU_IO_MAP(sound_io_map)
587   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1 */
587   MCFG_CPU_PERIODIC_INT_DRIVER(vigilant_state, nmi_line_pulse, 128*55)   /* clocked by V1 */
588588                        /* IRQs are generated by main Z80 and YM2151 */
589589   /* video hardware */
590590   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/taitosj.c
r17996r17997
17911791   /* basic machine hardware */
17921792   MCFG_CPU_ADD("maincpu",Z80,8000000/2)      /* 4 MHz */
17931793   MCFG_CPU_PROGRAM_MAP(taitosj_main_nomcu_map)
1794   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1794   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitosj_state, irq0_line_hold)
17951795
17961796   MCFG_CPU_ADD("audiocpu", Z80,6000000/2)    /* 3 MHz */
17971797   MCFG_CPU_PROGRAM_MAP(taitosj_audio_map)
r17996r17997
17991799         /* - no interrupts synced with vblank */
18001800         /* - NMI triggered by the main CPU */
18011801         /* - periodic IRQ, with frequency 6000000/(4*16*16*10*16) = 36.621 Hz, */
1802   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)6000000/(4*16*16*10*16))
1802   MCFG_CPU_PERIODIC_INT_DRIVER(taitosj_state, irq0_line_hold, (double)6000000/(4*16*16*10*16))
18031803
18041804
18051805   /* video hardware */
trunk/src/mame/drivers/galivan.c
r17996r17997
436436   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)      /* 6 MHz? */
437437   MCFG_CPU_PROGRAM_MAP(galivan_map)
438438   MCFG_CPU_IO_MAP(io_map)
439   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
439   MCFG_CPU_VBLANK_INT_DRIVER("screen", galivan_state, irq0_line_hold)
440440
441441   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      /* 4 MHz? */
442442   MCFG_CPU_PROGRAM_MAP(sound_map)
443443   MCFG_CPU_IO_MAP(sound_io_map)
444   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
444   MCFG_CPU_PERIODIC_INT_DRIVER(galivan_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
445445
446446   MCFG_MACHINE_START_OVERRIDE(galivan_state,galivan)
447447   MCFG_MACHINE_RESET_OVERRIDE(galivan_state,galivan)
r17996r17997
478478   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)      /* 6 MHz? */
479479   MCFG_CPU_PROGRAM_MAP(ninjemak_map)
480480   MCFG_CPU_IO_MAP(ninjemak_io_map)
481   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
481   MCFG_CPU_VBLANK_INT_DRIVER("screen", galivan_state, irq0_line_hold)
482482
483483   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      /* 4 MHz? */
484484   MCFG_CPU_PROGRAM_MAP(sound_map)
485485   MCFG_CPU_IO_MAP(sound_io_map)
486   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
486   MCFG_CPU_PERIODIC_INT_DRIVER(galivan_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
487487
488488   MCFG_MACHINE_START_OVERRIDE(galivan_state,ninjemak)
489489   MCFG_MACHINE_RESET_OVERRIDE(galivan_state,ninjemak)
trunk/src/mame/drivers/deshoros.c
r17996r17997
261261   /* basic machine hardware */
262262   MCFG_CPU_ADD("maincpu", M6809, XTAL_4MHz/2)
263263   MCFG_CPU_PROGRAM_MAP(main_map)
264   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 60) // timer irq controls update speed, frequency needs to be determined yet (2MHz through three 74LS390)
264   MCFG_CPU_PERIODIC_INT_DRIVER(destiny_state, irq0_line_hold, 60) // timer irq controls update speed, frequency needs to be determined yet (2MHz through three 74LS390)
265265
266266   /* video hardware (dummy) */
267267   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/canyon.c
r17996r17997
239239   /* basic machine hardware */
240240   MCFG_CPU_ADD("maincpu", M6502, XTAL_12_096MHz / 16)
241241   MCFG_CPU_PROGRAM_MAP(main_map)
242   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
242   MCFG_CPU_VBLANK_INT_DRIVER("screen", canyon_state, nmi_line_pulse)
243243   MCFG_WATCHDOG_VBLANK_INIT(8)
244244
245245   /* video hardware */
trunk/src/mame/drivers/igs_m027.c
r17996r17997
5959   TILE_GET_INFO_MEMBER(get_bg_tilemap_tile_info);
6060   virtual void video_start();
6161   UINT32 screen_update_igs_majhong(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(igs_majhong_interrupt);
6263};
6364
6465
r17996r17997
357358GFXDECODE_END
358359
359360
360static INTERRUPT_GEN( igs_majhong_interrupt )
361INTERRUPT_GEN_MEMBER(igs_m027_state::igs_majhong_interrupt)
361362{
362   generic_pulse_irq_line(device, ARM7_FIRQ_LINE, 1);
363   generic_pulse_irq_line(device.execute(), ARM7_FIRQ_LINE, 1);
363364}
364365
365366
r17996r17997
368369
369370   MCFG_CPU_PROGRAM_MAP(igs_majhong_map)
370371
371   MCFG_CPU_VBLANK_INT("screen", igs_majhong_interrupt)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs_m027_state, igs_majhong_interrupt)
372373   //MCFG_NVRAM_ADD_0FILL("nvram")
373374
374375   MCFG_GFXDECODE(igs_m027)
trunk/src/mame/drivers/splash.c
r17996r17997
496496   /* basic machine hardware */
497497   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)      /* 12MHz (24/2) */
498498   MCFG_CPU_PROGRAM_MAP(splash_map)
499   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
499   MCFG_CPU_VBLANK_INT_DRIVER("screen", splash_state, irq6_line_hold)
500500
501501   MCFG_CPU_ADD("audiocpu", Z80, XTAL_30MHz/8)      /* 3.75MHz (30/8) */
502502   MCFG_CPU_PROGRAM_MAP(splash_sound_map)
503   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,60*64)   /* needed for the msm5205 to play the samples */
503   MCFG_CPU_PERIODIC_INT_DRIVER(splash_state, nmi_line_pulse, 60*64)   /* needed for the msm5205 to play the samples */
504504
505505   /* video hardware */
506506   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
539539   DEVCB_LINE(ym_irq)
540540};
541541
542static INTERRUPT_GEN(  roldfrog_interrupt )
542INTERRUPT_GEN_MEMBER(splash_state::roldfrog_interrupt)
543543{
544   splash_state *state = device->machine().driver_data<splash_state>();
545   state->m_vblank_irq = 1;
546   roldfrog_update_irq(device->machine());
544   m_vblank_irq = 1;
545   roldfrog_update_irq(machine());
547546}
548547
549548static MACHINE_CONFIG_START( roldfrog, splash_state )
r17996r17997
551550   /* basic machine hardware */
552551   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)      /* 12 MHz - verified */
553552   MCFG_CPU_PROGRAM_MAP(roldfrog_map)
554   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
553   MCFG_CPU_VBLANK_INT_DRIVER("screen", splash_state, irq6_line_hold)
555554
556555   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8)      /* 3 MHz - verified */
557556   MCFG_CPU_PROGRAM_MAP(roldfrog_sound_map)
558557   MCFG_CPU_IO_MAP(roldfrog_sound_io_map)
559   MCFG_CPU_VBLANK_INT("screen", roldfrog_interrupt)
558   MCFG_CPU_VBLANK_INT_DRIVER("screen", splash_state, roldfrog_interrupt)
560559
561560   /* video hardware */
562561   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
632631   /* basic machine hardware */
633632   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)      /* 12 MHz (24/2) */
634633   MCFG_CPU_PROGRAM_MAP(funystrp_map)
635   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
634   MCFG_CPU_VBLANK_INT_DRIVER("screen", splash_state, irq6_line_hold)
636635
637636   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/4)      /* 6MHz (24/4) */
638637   MCFG_CPU_PROGRAM_MAP(funystrp_sound_map)
trunk/src/mame/drivers/buster.c
r17996r17997
333333   /* basic machine hardware */
334334   MCFG_CPU_ADD("maincpu", Z80,XTAL_3_579545MHz)       /* ? MHz */
335335   MCFG_CPU_PROGRAM_MAP(mainmap)
336   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
336   MCFG_CPU_VBLANK_INT_DRIVER("screen", buster_state, irq0_line_hold)
337337
338338   /* video hardware */
339339   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/subsino2.c
r17996r17997
166166   DECLARE_MACHINE_RESET(am188em);
167167   DECLARE_VIDEO_START(xtrain);
168168   UINT32 screen_update_subsino2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
169   INTERRUPT_GEN_MEMBER(am188em_int0_irq);
169170};
170171
171172
r17996r17997
862863   m_am188em_regs[AM188EM_I0CON+1] = 0x00;
863864}
864865
865static INTERRUPT_GEN( am188em_int0_irq )
866INTERRUPT_GEN_MEMBER(subsino2_state::am188em_int0_irq)
866867{
867   subsino2_state *state = device->machine().driver_data<subsino2_state>();
868   if ( ((state->m_am188em_regs[AM188EM_IMASK+0] & 0x10) == 0) ||   // IMASK.I0 mask
869       ((state->m_am188em_regs[AM188EM_I0CON+0] & 0x08) == 0) )   // I0CON.MSK mask
870      device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x0c);   // INT0 (background scrolling in xplan)
868   if ( ((m_am188em_regs[AM188EM_IMASK+0] & 0x10) == 0) ||   // IMASK.I0 mask
869       ((m_am188em_regs[AM188EM_I0CON+0] & 0x08) == 0) )   // I0CON.MSK mask
870      device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x0c);   // INT0 (background scrolling in xplan)
871871}
872872
873873static TIMER_DEVICE_CALLBACK( am188em_timer2_irq )
r17996r17997
21772177static MACHINE_CONFIG_START( bishjan, subsino2_state )
21782178   MCFG_CPU_ADD("maincpu", H83044, XTAL_44_1MHz / 3)
21792179   MCFG_CPU_PROGRAM_MAP( bishjan_map )
2180   MCFG_CPU_VBLANK_INT( "screen", irq0_line_hold )
2180   MCFG_CPU_VBLANK_INT_DRIVER("screen", subsino2_state,  irq0_line_hold)
21812181   MCFG_TIMER_ADD_PERIODIC("timer", h8_timer_irq, attotime::from_hz(60)) // timer, ?? Hz
21822182
21832183   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
22742274   MCFG_CPU_ADD("maincpu", I80188, XTAL_20MHz )   // !! AMD AM188-EM !!
22752275   MCFG_CPU_PROGRAM_MAP( xplan_map )
22762276   MCFG_CPU_IO_MAP( xplan_io )
2277   MCFG_CPU_VBLANK_INT( "screen", am188em_int0_irq )
2277   MCFG_CPU_VBLANK_INT_DRIVER("screen", subsino2_state,  am188em_int0_irq)
22782278   MCFG_TIMER_ADD_PERIODIC("timer2", am188em_timer2_irq, attotime::from_hz(60)) // timer 2, ?? Hz
22792279
22802280   MCFG_MACHINE_RESET_OVERRIDE(subsino2_state,am188em)
trunk/src/mame/drivers/m63.c
r17996r17997
184184   DECLARE_VIDEO_START(m63);
185185   DECLARE_PALETTE_INIT(m63);
186186   UINT32 screen_update_m63(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
187   INTERRUPT_GEN_MEMBER(snd_irq);
188   INTERRUPT_GEN_MEMBER(vblank_irq);
187189};
188190
189191
r17996r17997
718720   fghtbskt_sh_start
719721};
720722
721static INTERRUPT_GEN( snd_irq )
723INTERRUPT_GEN_MEMBER(m63_state::snd_irq)
722724{
723   m63_state *state = device->machine().driver_data<m63_state>();
724   state->m_sound_irq = 1;
725   m_sound_irq = 1;
725726}
726727
727728MACHINE_START_MEMBER(m63_state,m63)
r17996r17997
755756}
756757
757758
758static INTERRUPT_GEN( vblank_irq )
759INTERRUPT_GEN_MEMBER(m63_state::vblank_irq)
759760{
760   m63_state *state = device->machine().driver_data<m63_state>();
761761
762   if(state->m_nmi_mask)
763      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
762   if(m_nmi_mask)
763      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
764764}
765765
766766static MACHINE_CONFIG_START( m63, m63_state )
r17996r17997
768768   /* basic machine hardware */
769769   MCFG_CPU_ADD("maincpu",Z80,XTAL_12MHz/4)     /* 3 MHz */
770770   MCFG_CPU_PROGRAM_MAP(m63_map)
771   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
771   MCFG_CPU_VBLANK_INT_DRIVER("screen", m63_state, vblank_irq)
772772
773773   MCFG_CPU_ADD("soundcpu",I8039,XTAL_12MHz/4)   /* ????? */
774774   MCFG_CPU_PROGRAM_MAP(i8039_map)
775775   MCFG_CPU_IO_MAP(i8039_port_map)
776   MCFG_CPU_PERIODIC_INT(snd_irq, 60)
776   MCFG_CPU_PERIODIC_INT_DRIVER(m63_state, snd_irq, 60)
777777
778778   MCFG_MACHINE_START_OVERRIDE(m63_state,m63)
779779   MCFG_MACHINE_RESET_OVERRIDE(m63_state,m63)
r17996r17997
804804
805805static MACHINE_CONFIG_DERIVED( atomboy, m63 )
806806   MCFG_CPU_MODIFY("soundcpu")
807   MCFG_CPU_PERIODIC_INT(snd_irq, 60/2)
807   MCFG_CPU_PERIODIC_INT_DRIVER(m63_state, snd_irq, 60/2)
808808MACHINE_CONFIG_END
809809
810810static MACHINE_CONFIG_START( fghtbskt, m63_state )
r17996r17997
812812   /* basic machine hardware */
813813   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/4)     /* 3 MHz */
814814   MCFG_CPU_PROGRAM_MAP(fghtbskt_map)
815   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
815   MCFG_CPU_VBLANK_INT_DRIVER("screen", m63_state, vblank_irq)
816816
817817   MCFG_CPU_ADD("soundcpu", I8039,XTAL_12MHz/4)   /* ????? */
818818   MCFG_CPU_PROGRAM_MAP(i8039_map)
819819   MCFG_CPU_IO_MAP(i8039_port_map)
820   MCFG_CPU_PERIODIC_INT(snd_irq, 60/2)
820   MCFG_CPU_PERIODIC_INT_DRIVER(m63_state, snd_irq, 60/2)
821821
822822   MCFG_MACHINE_START_OVERRIDE(m63_state,m63)
823823   MCFG_MACHINE_RESET_OVERRIDE(m63_state,m63)
trunk/src/mame/drivers/route16.c
r17996r17997
601601   MCFG_CPU_ADD("cpu1", Z80, 2500000)   /* 10MHz / 4 = 2.5MHz */
602602   MCFG_CPU_PROGRAM_MAP(route16_cpu1_map)
603603   MCFG_CPU_IO_MAP(cpu1_io_map)
604   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
604   MCFG_CPU_VBLANK_INT_DRIVER("screen", route16_state, irq0_line_hold)
605605
606606   MCFG_CPU_ADD("cpu2", Z80, 2500000)   /* 10MHz / 4 = 2.5MHz */
607607   MCFG_CPU_PROGRAM_MAP(route16_cpu2_map)
r17996r17997
667667
668668   /* basic machine hardware */
669669   MCFG_CPU_MODIFY("cpu2")
670   MCFG_CPU_PERIODIC_INT(irq0_line_hold,48*60)
670   MCFG_CPU_PERIODIC_INT_DRIVER(route16_state, irq0_line_hold, 48*60)
671671MACHINE_CONFIG_END
672672
673673
trunk/src/mame/drivers/tecmosys.c
r17996r17997
455455static MACHINE_CONFIG_START( deroon, tecmosys_state )
456456   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
457457   MCFG_CPU_PROGRAM_MAP(main_map)
458   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
458   MCFG_CPU_VBLANK_INT_DRIVER("screen", tecmosys_state, irq1_line_hold)
459459   MCFG_WATCHDOG_VBLANK_INIT(400) // guess
460460
461461   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/2 )
trunk/src/mame/drivers/snk6502.c
r17996r17997
740740 *
741741 *************************************/
742742
743static INTERRUPT_GEN( satansat_interrupt )
743INTERRUPT_GEN_MEMBER(snk6502_state::satansat_interrupt)
744744{
745   snk6502_state *state = device->machine().driver_data<snk6502_state>();
746745
747   if(state->m_irq_mask)
748      device->execute().set_input_line(M6502_IRQ_LINE, HOLD_LINE);   /* one IRQ per frame */
746   if(m_irq_mask)
747      device.execute().set_input_line(M6502_IRQ_LINE, HOLD_LINE);   /* one IRQ per frame */
749748}
750749
751static INTERRUPT_GEN( snk6502_interrupt )
750INTERRUPT_GEN_MEMBER(snk6502_state::snk6502_interrupt)
752751{
753   device->execute().set_input_line(M6502_IRQ_LINE, HOLD_LINE);   /* one IRQ per frame */
752   device.execute().set_input_line(M6502_IRQ_LINE, HOLD_LINE);   /* one IRQ per frame */
754753}
755754
756755
r17996r17997
824823   // basic machine hardware
825824   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK / 16) // 700 kHz
826825   MCFG_CPU_PROGRAM_MAP(sasuke_map)
827   MCFG_CPU_VBLANK_INT("screen",satansat_interrupt)
826   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk6502_state, satansat_interrupt)
828827
829828   MCFG_MACHINE_RESET_OVERRIDE(snk6502_state,sasuke)
830829
r17996r17997
897896   //MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK / 8)   // 1.4 MHz
898897   MCFG_CPU_ADD("maincpu", M6502, 930000)      // adjusted
899898   MCFG_CPU_PROGRAM_MAP(vanguard_map)
900   MCFG_CPU_VBLANK_INT("screen",snk6502_interrupt)
899   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk6502_state, snk6502_interrupt)
901900
902901   MCFG_MACHINE_RESET_OVERRIDE(snk6502_state,vanguard)
903902
trunk/src/mame/drivers/polyplay.c
r17996r17997
118118}
119119
120120
121static INTERRUPT_GEN( periodic_interrupt )
121INTERRUPT_GEN_MEMBER(polyplay_state::periodic_interrupt)
122122{
123   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x4e);
123   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x4e);
124124}
125125
126126
127static INTERRUPT_GEN( coin_interrupt )
127INTERRUPT_GEN_MEMBER(polyplay_state::coin_interrupt)
128128{
129   polyplay_state *state = device->machine().driver_data<polyplay_state>();
130129
131   if (state->ioport("INPUT")->read() & 0x80)
132      state->m_last = 0;
130   if (ioport("INPUT")->read() & 0x80)
131      m_last = 0;
133132   else
134133   {
135      if (state->m_last == 0)    /* coin inserted */
136         device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x50);
134      if (m_last == 0)    /* coin inserted */
135         device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x50);
137136
138      state->m_last = 1;
137      m_last = 1;
139138   }
140139}
141140
r17996r17997
273272   MCFG_CPU_ADD("maincpu", Z80, 9830400/4)
274273   MCFG_CPU_PROGRAM_MAP(polyplay_map)
275274   MCFG_CPU_IO_MAP(polyplay_io_map)
276   MCFG_CPU_PERIODIC_INT(periodic_interrupt,75)
277   MCFG_CPU_VBLANK_INT("screen", coin_interrupt)
275   MCFG_CPU_PERIODIC_INT_DRIVER(polyplay_state, periodic_interrupt, 75)
276   MCFG_CPU_VBLANK_INT_DRIVER("screen", polyplay_state,  coin_interrupt)
278277
279278
280279   MCFG_TIMER_ADD("timer", polyplay_timer_callback)
trunk/src/mame/drivers/exidy440.c
r17996r17997
999999   /* basic machine hardware */
10001000   MCFG_CPU_ADD("maincpu", M6809, MAIN_CPU_CLOCK)
10011001   MCFG_CPU_PROGRAM_MAP(exidy440_map)
1002   MCFG_CPU_VBLANK_INT("screen", exidy440_vblank_interrupt)
1002   MCFG_CPU_VBLANK_INT_DRIVER("screen", exidy440_state, exidy440_vblank_interrupt)
10031003
10041004   MCFG_NVRAM_ADD_0FILL("nvram")
10051005
trunk/src/mame/drivers/dassault.c
r17996r17997
506506   /* basic machine hardware */
507507   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2)   /* 14MHz - Accurate */
508508   MCFG_CPU_PROGRAM_MAP(dassault_map)
509   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
509   MCFG_CPU_VBLANK_INT_DRIVER("screen", dassault_state, irq4_line_hold)
510510
511511   MCFG_CPU_ADD("sub", M68000, XTAL_28MHz/2)   /* 14MHz - Accurate */
512512   MCFG_CPU_PROGRAM_MAP(dassault_sub_map)
513   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
513   MCFG_CPU_VBLANK_INT_DRIVER("screen", dassault_state, irq5_line_hold)
514514
515515   MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/8)   /* Accurate */
516516   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tatsumi.c
r17996r17997
849849   DEVCB_LINE(sound_irq)
850850};
851851
852static INTERRUPT_GEN( roundup5_interrupt )
852INTERRUPT_GEN_MEMBER(tatsumi_state::roundup5_interrupt)
853853{
854   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   /* VBL */
854   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4);   /* VBL */
855855}
856856
857857static void apache3_68000_reset(device_t *device)
r17996r17997
873873   /* basic machine hardware */
874874   MCFG_CPU_ADD("maincpu", V30, CLOCK_1 / 2)
875875   MCFG_CPU_PROGRAM_MAP(apache3_v30_map)
876   MCFG_CPU_VBLANK_INT("screen", roundup5_interrupt)
876   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, roundup5_interrupt)
877877
878878   MCFG_CPU_ADD("sub", M68000, CLOCK_2 / 4)
879879   MCFG_CPU_PROGRAM_MAP(apache3_68000_map)
880   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
880   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq4_line_hold)
881881
882882   MCFG_CPU_ADD("audiocpu", V20, CLOCK_1 / 2)
883883   MCFG_CPU_PROGRAM_MAP(apache3_v20_map)
884884
885885   MCFG_CPU_ADD("sub2", Z80, CLOCK_2 / 8)
886886   MCFG_CPU_PROGRAM_MAP(apache3_z80_map)
887   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
887   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq0_line_hold)
888888
889889   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
890890   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
918918   /* basic machine hardware */
919919   MCFG_CPU_ADD("maincpu", V30, CLOCK_1 / 2)
920920   MCFG_CPU_PROGRAM_MAP(roundup5_v30_map)
921   MCFG_CPU_VBLANK_INT("screen", roundup5_interrupt)
921   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, roundup5_interrupt)
922922
923923   MCFG_CPU_ADD("sub", M68000, CLOCK_2 / 4)
924924   MCFG_CPU_PROGRAM_MAP(roundup5_68000_map)
r17996r17997
959959   /* basic machine hardware */
960960   MCFG_CPU_ADD("maincpu", M68000, CLOCK_2 / 4)
961961   MCFG_CPU_PROGRAM_MAP(cyclwarr_68000a_map)
962   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
962   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq5_line_hold)
963963
964964   MCFG_CPU_ADD("sub", M68000, CLOCK_2 / 4)
965965   MCFG_CPU_PROGRAM_MAP(cyclwarr_68000b_map)
966   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
966   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq5_line_hold)
967967
968968   MCFG_CPU_ADD("audiocpu", Z80, CLOCK_1 / 4)
969969   MCFG_CPU_PROGRAM_MAP(cyclwarr_z80_map)
r17996r17997
10011001   /* basic machine hardware */
10021002   MCFG_CPU_ADD("maincpu", M68000, CLOCK_2 / 4)
10031003   MCFG_CPU_PROGRAM_MAP(bigfight_68000a_map)
1004   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1004   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq5_line_hold)
10051005
10061006   MCFG_CPU_ADD("sub", M68000, CLOCK_2 / 4)
10071007   MCFG_CPU_PROGRAM_MAP(bigfight_68000b_map)
1008   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1008   MCFG_CPU_VBLANK_INT_DRIVER("screen", tatsumi_state, irq5_line_hold)
10091009
10101010   MCFG_CPU_ADD("audiocpu", Z80, CLOCK_1 / 4)
10111011   MCFG_CPU_PROGRAM_MAP(cyclwarr_z80_map)
trunk/src/mame/drivers/supbtime.c
r17996r17997
343343   /* basic machine hardware */
344344   MCFG_CPU_ADD("maincpu", M68000, 14000000)
345345   MCFG_CPU_PROGRAM_MAP(supbtime_map)
346   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
346   MCFG_CPU_VBLANK_INT_DRIVER("screen", supbtime_state, irq6_line_hold)
347347
348348   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)   /* Custom chip 45, audio section crystal is 32.220 MHz */
349349   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
384384   /* basic machine hardware */
385385   MCFG_CPU_ADD("maincpu", M68000, 14000000)
386386   MCFG_CPU_PROGRAM_MAP(chinatwn_map)
387   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
387   MCFG_CPU_VBLANK_INT_DRIVER("screen", supbtime_state, irq6_line_hold)
388388
389389   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8) /* Custom chip 45, audio section crystal is 32.220 MHz */
390390   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/toratora.c
r17996r17997
5858   virtual void machine_start();
5959   virtual void machine_reset();
6060   UINT32 screen_update_toratora(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
61   INTERRUPT_GEN_MEMBER(toratora_timer);
6162};
6263
6364
r17996r17997
150151}
151152
152153
153static INTERRUPT_GEN( toratora_timer )
154INTERRUPT_GEN_MEMBER(toratora_state::toratora_timer)
154155{
155   toratora_state *state = device->machine().driver_data<toratora_state>();
156   state->m_timer++;   /* timer counting at 16 Hz */
156   m_timer++;   /* timer counting at 16 Hz */
157157
158158   /* also, when the timer overflows (16 seconds) watchdog would kick in */
159   if (state->m_timer & 0x100)
159   if (m_timer & 0x100)
160160      popmessage("watchdog!");
161161
162   if (state->m_last != (state->ioport("INPUT")->read() & 0x0f))
162   if (m_last != (ioport("INPUT")->read() & 0x0f))
163163   {
164      state->m_last = state->ioport("INPUT")->read() & 0x0f;
165      generic_pulse_irq_line(device, 0, 1);
164      m_last = ioport("INPUT")->read() & 0x0f;
165      generic_pulse_irq_line(device.execute(), 0, 1);
166166   }
167   state->m_pia_u1->set_a_input(device->machine().root_device().ioport("INPUT")->read() & 0x0f, 0);
168   state->m_pia_u1->ca1_w(device->machine().root_device().ioport("INPUT")->read() & 0x10);
169   state->m_pia_u1->ca2_w(device->machine().root_device().ioport("INPUT")->read() & 0x20);
167   m_pia_u1->set_a_input(machine().root_device().ioport("INPUT")->read() & 0x0f, 0);
168   m_pia_u1->ca1_w(machine().root_device().ioport("INPUT")->read() & 0x10);
169   m_pia_u1->ca2_w(machine().root_device().ioport("INPUT")->read() & 0x20);
170170}
171171
172172READ8_MEMBER(toratora_state::timer_r)
r17996r17997
449449   /* basic machine hardware */
450450   MCFG_CPU_ADD("maincpu", M6800,500000)   /* ?????? game speed is entirely controlled by this */
451451   MCFG_CPU_PROGRAM_MAP(main_map)
452   MCFG_CPU_PERIODIC_INT(toratora_timer,16)   /* timer counting at 16 Hz */
452   MCFG_CPU_PERIODIC_INT_DRIVER(toratora_state, toratora_timer, 16)   /* timer counting at 16 Hz */
453453
454454   MCFG_PIA6821_ADD("pia_u1", pia_u1_intf)
455455   MCFG_PIA6821_ADD("pia_u2", pia_u2_intf)
trunk/src/mame/drivers/blmbycar.c
r17996r17997
355355   /* basic machine hardware */
356356   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* ? */
357357   MCFG_CPU_PROGRAM_MAP(blmbycar_map)
358   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
358   MCFG_CPU_VBLANK_INT_DRIVER("screen", blmbycar_state, irq1_line_hold)
359359
360360   MCFG_MACHINE_START_OVERRIDE(blmbycar_state,blmbycar)
361361   MCFG_MACHINE_RESET_OVERRIDE(blmbycar_state,blmbycar)
r17996r17997
398398   /* basic machine hardware */
399399   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* ? */
400400   MCFG_CPU_PROGRAM_MAP(watrball_map)
401   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
401   MCFG_CPU_VBLANK_INT_DRIVER("screen", blmbycar_state, irq1_line_hold)
402402
403403   MCFG_MACHINE_START_OVERRIDE(blmbycar_state,watrball)
404404   MCFG_MACHINE_RESET_OVERRIDE(blmbycar_state,watrball)
trunk/src/mame/drivers/gbusters.c
r17996r17997
1919/* prototypes */
2020static KONAMI_SETLINES_CALLBACK( gbusters_banking );
2121
22static INTERRUPT_GEN( gbusters_interrupt )
22INTERRUPT_GEN_MEMBER(gbusters_state::gbusters_interrupt)
2323{
24   gbusters_state *state = device->machine().driver_data<gbusters_state>();
2524
26   if (k052109_is_irq_enabled(state->m_k052109))
27      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
25   if (k052109_is_irq_enabled(m_k052109))
26      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
2827}
2928
3029READ8_MEMBER(gbusters_state::bankedram_r)
r17996r17997
303302   /* basic machine hardware */
304303   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)   /* Konami custom 052526 */
305304   MCFG_CPU_PROGRAM_MAP(gbusters_map)
306   MCFG_CPU_VBLANK_INT("screen", gbusters_interrupt)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", gbusters_state, gbusters_interrupt)
307306
308307   MCFG_CPU_ADD("audiocpu", Z80, 3579545)      /* ? */
309308   MCFG_CPU_PROGRAM_MAP(gbusters_sound_map)
trunk/src/mame/drivers/bogeyman.c
r17996r17997
241241   // basic machine hardware
242242   MCFG_CPU_ADD("maincpu", M6502, 1500000)   /* Verified */
243243   MCFG_CPU_PROGRAM_MAP(bogeyman_map)
244   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 16*60) // Controls sound
244   MCFG_CPU_PERIODIC_INT_DRIVER(bogeyman_state, irq0_line_hold, 16*60) // Controls sound
245245
246246
247247   // video hardware
trunk/src/mame/drivers/m72.c
r17996r17997
283283   return ret;
284284}
285285
286static INTERRUPT_GEN( m72_mcu_int )
286INTERRUPT_GEN_MEMBER(m72_state::m72_mcu_int)
287287{
288   m72_state *state = device->machine().driver_data<m72_state>();
289   //state->m_mcu_snd_cmd_latch |= 0x11; /* 0x10 is special as well - FIXME */
290   state->m_mcu_snd_cmd_latch = 0x11;// | (machine.rand() & 1); /* 0x10 is special as well - FIXME */
291   device->execute().set_input_line(1, ASSERT_LINE);
288   //m_mcu_snd_cmd_latch |= 0x11; /* 0x10 is special as well - FIXME */
289   m_mcu_snd_cmd_latch = 0x11;// | (machine.rand() & 1); /* 0x10 is special as well - FIXME */
290   device.execute().set_input_line(1, ASSERT_LINE);
292291}
293292
294293READ8_MEMBER(m72_state::m72_mcu_sample_r)
r17996r17997
434433}
435434#endif
436435
437static INTERRUPT_GEN(fake_nmi)
436INTERRUPT_GEN_MEMBER(m72_state::fake_nmi)
438437{
439   m72_state *state = device->machine().driver_data<m72_state>();
440   address_space &space = state->generic_space();
441   int sample = m72_sample_r(state->m_audio,space,0);
438   address_space &space = generic_space();
439   int sample = m72_sample_r(m_audio,space,0);
442440   if (sample)
443      m72_sample_w(state->m_audio,space,0,sample);
441      m72_sample_w(m_audio,space,0,sample);
444442}
445443
446444
r17996r17997
18431841
18441842static MACHINE_CONFIG_DERIVED( m72, m72_base )
18451843   MCFG_CPU_MODIFY("maincpu")
1846   MCFG_CPU_PERIODIC_INT(fake_nmi,128*55)   /* clocked by V1? (Vigilante) */
1844   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, fake_nmi, 128*55)   /* clocked by V1? (Vigilante) */
18471845                     /* IRQs are generated by main Z80 and YM2151 */
18481846MACHINE_CONFIG_END
18491847
r17996r17997
18511849
18521850   MCFG_CPU_ADD("mcu",I8751, MASTER_CLOCK/4)
18531851   MCFG_CPU_IO_MAP(mcu_io_map)
1854   MCFG_CPU_VBLANK_INT("screen", m72_mcu_int)
1852   MCFG_CPU_VBLANK_INT_DRIVER("screen", m72_state, m72_mcu_int)
18551853
18561854MACHINE_CONFIG_END
18571855
r17996r17997
19021900   MCFG_CPU_ADD("soundcpu",Z80, SOUND_CLOCK)
19031901   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
19041902   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
1905   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
1903   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
19061904                        /* IRQs are generated by main Z80 and YM2151 */
19071905
19081906   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
19431941   MCFG_CPU_ADD("soundcpu",Z80, SOUND_CLOCK)
19441942   MCFG_CPU_PROGRAM_MAP(sound_ram_map)
19451943   MCFG_CPU_IO_MAP(sound_portmap)
1946   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
1944   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
19471945                        /* IRQs are generated by main Z80 and YM2151 */
19481946
19491947   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
19841982   MCFG_CPU_ADD("soundcpu",Z80, SOUND_CLOCK)
19851983   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
19861984   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
1987   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
1985   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
19881986                        /* IRQs are generated by main Z80 and YM2151 */
19891987
19901988   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
20252023   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
20262024   MCFG_CPU_PROGRAM_MAP(sound_ram_map)
20272025   MCFG_CPU_IO_MAP(sound_portmap)
2028   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2026   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
20292027                        /* IRQs are generated by main Z80 and YM2151 */
20302028
20312029   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
20662064   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
20672065   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
20682066   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
2069   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2067   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
20702068                        /* IRQs are generated by main Z80 and YM2151 */
20712069
20722070   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
21072105   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
21082106   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
21092107   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
2110   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2108   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
21112109                        /* IRQs are generated by main Z80 and YM2151 */
21122110
21132111   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
21482146   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
21492147   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
21502148   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
2151   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2149   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
21522150                        /* IRQs are generated by main Z80 and YM2151 */
21532151
21542152   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
21892187   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
21902188   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
21912189   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
2192   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2190   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
21932191                        /* IRQs are generated by main Z80 and YM2151 */
21942192
21952193   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
22302228   MCFG_CPU_ADD("soundcpu",Z80, SOUND_CLOCK)
22312229   MCFG_CPU_PROGRAM_MAP(sound_ram_map)
22322230   MCFG_CPU_IO_MAP(sound_portmap)
2233   MCFG_CPU_PERIODIC_INT(fake_nmi,128*55)   /* clocked by V1? (Vigilante) */
2231   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, fake_nmi, 128*55)   /* clocked by V1? (Vigilante) */
22342232                        /* IRQs are generated by main Z80 and YM2151 */
22352233
22362234   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
22712269   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
22722270   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
22732271   MCFG_CPU_IO_MAP(poundfor_sound_portmap)
2274   MCFG_CPU_PERIODIC_INT(fake_nmi,128*55)   /* clocked by V1? (Vigilante) */
2272   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, fake_nmi, 128*55)   /* clocked by V1? (Vigilante) */
22752273                        /* IRQs are generated by main Z80 and YM2151 */
22762274
22772275   MCFG_MACHINE_START_OVERRIDE(m72_state,m72)
r17996r17997
23122310   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK)
23132311   MCFG_CPU_PROGRAM_MAP(sound_rom_map)
23142312   MCFG_CPU_IO_MAP(rtype2_sound_portmap)
2315   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
2313   MCFG_CPU_PERIODIC_INT_DRIVER(m72_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
23162314                        /* IRQs are generated by main Z80 and YM2151 */
23172315
23182316   MCFG_MACHINE_START_OVERRIDE(m72_state,kengo)
trunk/src/mame/drivers/pokechmp.c
r17996r17997
206206   /* basic machine hardware */
207207   MCFG_CPU_ADD("maincpu", M6502, 4000000)
208208   MCFG_CPU_PROGRAM_MAP(pokechmp_map)
209   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
209   MCFG_CPU_VBLANK_INT_DRIVER("screen", pokechmp_state, nmi_line_pulse)
210210
211211   MCFG_CPU_ADD("audiocpu", M6502, 4000000)
212212   MCFG_CPU_PROGRAM_MAP(pokechmp_sound_map)
213   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
213   MCFG_CPU_VBLANK_INT_DRIVER("screen", pokechmp_state, irq0_line_hold)
214214
215215   /* video hardware */
216216   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/crgolf.c
r17996r17997
404404   /* basic machine hardware */
405405   MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/3/2)
406406   MCFG_CPU_PROGRAM_MAP(main_map)
407   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
407   MCFG_CPU_VBLANK_INT_DRIVER("screen", crgolf_state, irq0_line_hold)
408408
409409   MCFG_CPU_ADD("audiocpu", Z80,MASTER_CLOCK/3/2)
410410   MCFG_CPU_PROGRAM_MAP(sound_map)
411   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
411   MCFG_CPU_VBLANK_INT_DRIVER("screen", crgolf_state, irq0_line_hold)
412412
413413   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
414414
trunk/src/mame/drivers/mastboy.c
r17996r17997
479479   virtual void machine_reset();
480480   virtual void video_start();
481481   UINT32 screen_update_mastboy(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
482   INTERRUPT_GEN_MEMBER(mastboy_interrupt);
482483};
483484
484485
r17996r17997
693694      machine().device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
694695}
695696
696static INTERRUPT_GEN( mastboy_interrupt )
697INTERRUPT_GEN_MEMBER(mastboy_state::mastboy_interrupt)
697698{
698   mastboy_state *state = device->machine().driver_data<mastboy_state>();
699   if ((state->m_irq0_ack & 1) == 1)
699   if ((m_irq0_ack & 1) == 1)
700700   {
701      device->execute().set_input_line(0, ASSERT_LINE);
701      device.execute().set_input_line(0, ASSERT_LINE);
702702   }
703703}
704704
r17996r17997
888888   MCFG_CPU_ADD("maincpu", Z180, 12000000/2)   /* HD647180X0CP6-1M1R */
889889   MCFG_CPU_PROGRAM_MAP(mastboy_map)
890890   MCFG_CPU_IO_MAP(mastboy_io_map)
891   MCFG_CPU_VBLANK_INT("screen", mastboy_interrupt)
891   MCFG_CPU_VBLANK_INT_DRIVER("screen", mastboy_state, mastboy_interrupt)
892892
893893   MCFG_NVRAM_ADD_1FILL("nvram")
894894
trunk/src/mame/drivers/jclub2.c
r17996r17997
800800   MCFG_CPU_ADD("st0016",Z80,8000000)
801801   MCFG_CPU_PROGRAM_MAP(st0016_mem)
802802   MCFG_CPU_IO_MAP(st0016_io)
803   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
803   MCFG_CPU_VBLANK_INT_DRIVER("screen", darkhors_state, irq0_line_hold)
804804
805805   MCFG_EEPROM_ADD("eeprom", eeprom_interface_93C46_8bit)
806806
trunk/src/mame/drivers/rmhaihai.c
r17996r17997
469469   MCFG_CPU_ADD("maincpu",Z80,20000000/4)   /* 5 MHz ??? */
470470   MCFG_CPU_PROGRAM_MAP(rmhaihai_map)
471471   MCFG_CPU_IO_MAP(rmhaihai_io_map)
472   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
472   MCFG_CPU_VBLANK_INT_DRIVER("screen", rmhaihai_state, irq0_line_hold)
473473
474474   /* video hardware */
475475   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/topspeed.c
r17996r17997
337337}
338338
339339
340static INTERRUPT_GEN( topspeed_interrupt )
340INTERRUPT_GEN_MEMBER(topspeed_state::topspeed_interrupt)
341341{
342342   /* Unsure how many int6's per frame */
343   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000 - 500), FUNC(topspeed_interrupt6));
344   device->execute().set_input_line(5, HOLD_LINE);
343   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000 - 500), FUNC(topspeed_interrupt6));
344   device.execute().set_input_line(5, HOLD_LINE);
345345}
346346
347static INTERRUPT_GEN( topspeed_cpub_interrupt )
347INTERRUPT_GEN_MEMBER(topspeed_state::topspeed_cpub_interrupt)
348348{
349349   /* Unsure how many int6's per frame */
350   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000 - 500), FUNC(topspeed_cpub_interrupt6));
351   device->execute().set_input_line(5, HOLD_LINE);
350   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000 - 500), FUNC(topspeed_cpub_interrupt6));
351   device.execute().set_input_line(5, HOLD_LINE);
352352}
353353
354354
r17996r17997
751751   /* basic machine hardware */
752752   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
753753   MCFG_CPU_PROGRAM_MAP(topspeed_map)
754   MCFG_CPU_VBLANK_INT("screen", topspeed_interrupt)
754   MCFG_CPU_VBLANK_INT_DRIVER("screen", topspeed_state, topspeed_interrupt)
755755
756756   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz / 4)
757757   MCFG_CPU_PROGRAM_MAP(z80_map)
758758
759759   MCFG_CPU_ADD("subcpu", M68000, 12000000)   /* 12 MHz ??? */
760760   MCFG_CPU_PROGRAM_MAP(topspeed_cpub_map)
761   MCFG_CPU_VBLANK_INT("screen", topspeed_cpub_interrupt)
761   MCFG_CPU_VBLANK_INT_DRIVER("screen", topspeed_state, topspeed_cpub_interrupt)
762762
763763
764764   MCFG_TC0220IOC_ADD("tc0220ioc", topspeed_io_intf)
trunk/src/mame/drivers/amspdwy.c
r17996r17997
275275   MCFG_CPU_ADD("maincpu", Z80,3000000)
276276   MCFG_CPU_PROGRAM_MAP(amspdwy_map)
277277   MCFG_CPU_IO_MAP(amspdwy_portmap)
278   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ: 60Hz, NMI: retn */
278   MCFG_CPU_VBLANK_INT_DRIVER("screen", amspdwy_state, irq0_line_hold)   /* IRQ: 60Hz, NMI: retn */
279279
280280   MCFG_CPU_ADD("audiocpu", Z80,3000000)   /* Can't be disabled: the YM2151 timers must work */
281281   MCFG_CPU_PROGRAM_MAP(amspdwy_sound_map)
trunk/src/mame/drivers/fantland.c
r17996r17997
829829   m_nmi_enable = 0;
830830}
831831
832static INTERRUPT_GEN( fantland_irq )
832INTERRUPT_GEN_MEMBER(fantland_state::fantland_irq)
833833{
834   fantland_state *state = device->machine().driver_data<fantland_state>();
835   if (state->m_nmi_enable & 8)
836      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
834   if (m_nmi_enable & 8)
835      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
837836}
838837
839static INTERRUPT_GEN( fantland_sound_irq )
838INTERRUPT_GEN_MEMBER(fantland_state::fantland_sound_irq)
840839{
841   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x80 / 4);
840   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x80 / 4);
842841}
843842
844843static MACHINE_CONFIG_START( fantland, fantland_state )
r17996r17997
846845   /* basic machine hardware */
847846   MCFG_CPU_ADD("maincpu", I8086, 8000000)        // ?
848847   MCFG_CPU_PROGRAM_MAP(fantland_map)
849   MCFG_CPU_VBLANK_INT("screen", fantland_irq)
848   MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
850849
851850   MCFG_CPU_ADD("audiocpu", I8088, 8000000)        // ?
852851   MCFG_CPU_PROGRAM_MAP(fantland_sound_map)
853852   MCFG_CPU_IO_MAP(fantland_sound_iomap)
854   MCFG_CPU_PERIODIC_INT(fantland_sound_irq, 8000)
853   MCFG_CPU_PERIODIC_INT_DRIVER(fantland_state, fantland_sound_irq, 8000)
855854   // NMI when soundlatch is written
856855
857856   MCFG_MACHINE_START_OVERRIDE(fantland_state,fantland)
r17996r17997
899898   /* basic machine hardware */
900899   MCFG_CPU_ADD("maincpu", I8088, 8000000)        // ?
901900   MCFG_CPU_PROGRAM_MAP(galaxygn_map)
902   MCFG_CPU_VBLANK_INT("screen", fantland_irq)
901   MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
903902
904903   MCFG_CPU_ADD("audiocpu", I8088, 8000000)        // ?
905904   MCFG_CPU_PROGRAM_MAP(fantland_sound_map)
r17996r17997
10051004   /* basic machine hardware */
10061005   MCFG_CPU_ADD("maincpu", V20, 16000000/2)        // D701080C-8 - NEC D70108C-8 V20 CPU, running at 8.000MHz [16/2]
10071006   MCFG_CPU_PROGRAM_MAP(borntofi_map)
1008   MCFG_CPU_VBLANK_INT("screen", fantland_irq)
1007   MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
10091008
10101009   MCFG_CPU_ADD("audiocpu", I8088, 18432000/3)        // 8088 - AMD P8088-2 CPU, running at 6.144MHz [18.432/3]
10111010   MCFG_CPU_PROGRAM_MAP(borntofi_sound_map)
r17996r17997
10441043   /* basic machine hardware */
10451044   MCFG_CPU_ADD("maincpu", V20, XTAL_18MHz/2)      // D701080C-8 (V20)
10461045   MCFG_CPU_PROGRAM_MAP(wheelrun_map)
1047   MCFG_CPU_VBLANK_INT("screen", fantland_irq)
1046   MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
10481047
10491048   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/2)      // Z8400BB1 (Z80B)
10501049   MCFG_CPU_PROGRAM_MAP(wheelrun_sound_map)
trunk/src/mame/drivers/albazc.c
r17996r17997
271271
272272   MCFG_CPU_ADD("maincpu", Z80,6000000)       /* ? MHz */
273273   MCFG_CPU_PROGRAM_MAP(hanaroku_map)
274   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
274   MCFG_CPU_VBLANK_INT_DRIVER("screen", albazc_state, irq0_line_hold)
275275
276276   /* video hardware */
277277   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/legionna.c
r17996r17997
10521052   /* basic machine hardware */
10531053   MCFG_CPU_ADD("maincpu", M68000,20000000/2)   /* ??? */
10541054   MCFG_CPU_PROGRAM_MAP(legionna_map)
1055   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)/* VBL */
1055   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)/* VBL */
10561056
10571057   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
10581058
r17996r17997
10821082   /* basic machine hardware */
10831083   MCFG_CPU_ADD("maincpu", M68000,20000000/2)   /* ??? */
10841084   MCFG_CPU_PROGRAM_MAP(heatbrl_map)
1085   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)/* VBL */
1085   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)/* VBL */
10861086
10871087   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
10881088
r17996r17997
11111111   /* basic machine hardware */
11121112   MCFG_CPU_ADD("maincpu", M68000, 20000000/2)
11131113   MCFG_CPU_PROGRAM_MAP(godzilla_map)
1114   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
1114   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)
11151115
11161116   SEIBU2_SOUND_SYSTEM_CPU(14318180/4)
11171117
r17996r17997
11401140   /* basic machine hardware */
11411141   MCFG_CPU_ADD("maincpu", M68000, 20000000/2)
11421142   MCFG_CPU_PROGRAM_MAP(denjinmk_map)
1143   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
1143   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)
11441144
11451145   SEIBU2_SOUND_SYSTEM_CPU(14318180/4)
11461146
r17996r17997
11691169   /* basic machine hardware */
11701170   MCFG_CPU_ADD("maincpu", M68000, 20000000/2)
11711171   MCFG_CPU_PROGRAM_MAP(grainbow_map)
1172   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
1172   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)
11731173
11741174   SEIBU2_SOUND_SYSTEM_CPU(14318180/4)
11751175
r17996r17997
11991199   /* basic machine hardware */
12001200   MCFG_CPU_ADD("maincpu", M68000,20000000/2)
12011201   MCFG_CPU_PROGRAM_MAP(cupsoc_mem)
1202   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)/* VBL */
1202   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold)/* VBL */
12031203
12041204   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
12051205
r17996r17997
12331233   /* basic machine hardware */
12341234   MCFG_CPU_ADD("maincpu", M68000,12000000)
12351235   MCFG_CPU_PROGRAM_MAP(cupsocbl_mem)
1236   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold) /* VBL */
1236   MCFG_CPU_VBLANK_INT_DRIVER("screen", legionna_state, irq4_line_hold) /* VBL */
12371237
12381238   /*Different Sound hardware*/
12391239   //SEIBU_SOUND_SYSTEM_CPU(14318180/4)
trunk/src/mame/drivers/midas.c
r17996r17997
701701   /* basic machine hardware */
702702   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz / 2)
703703   MCFG_CPU_PROGRAM_MAP(livequiz_map)
704   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
704   MCFG_CPU_VBLANK_INT_DRIVER("screen", midas_state, irq1_line_hold)
705705
706706   MCFG_EEPROM_93C46_ADD("eeprom")
707707
r17996r17997
730730   /* basic machine hardware */
731731   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz / 2)
732732   MCFG_CPU_PROGRAM_MAP(hammer_map)
733   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
733   MCFG_CPU_VBLANK_INT_DRIVER("screen", midas_state, irq1_line_hold)
734734
735735   MCFG_EEPROM_93C46_ADD("eeprom")
736736
trunk/src/mame/drivers/aristmk4.c
r17996r17997
16841684   /* basic machine hardware */
16851685   MCFG_CPU_ADD("maincpu", M6809, MAIN_CLOCK/8) // 1.5mhz
16861686   MCFG_CPU_PROGRAM_MAP(aristmk4_map)
1687   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1687   MCFG_CPU_VBLANK_INT_DRIVER("screen", aristmk4_state, irq0_line_hold)
16881688
16891689   MCFG_NVRAM_ADD_0FILL("nvram")
16901690   MCFG_TIMER_ADD_PERIODIC("power_fail", aristmk4_pf,attotime::from_hz(1)) // not real but required to simulate power failure to access robot test. How else can we do this ?
r17996r17997
17271727   /* basic machine hardware */
17281728   MCFG_CPU_MODIFY("maincpu")
17291729   MCFG_CPU_PROGRAM_MAP(aristmk4_poker_map)
1730   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1730   MCFG_CPU_VBLANK_INT_DRIVER("screen", aristmk4_state, irq0_line_hold)
17311731MACHINE_CONFIG_END
17321732
17331733/* same as Aristocrat Mark-IV HW color offset 7 */
trunk/src/mame/drivers/thunderx.c
r17996r17997
2121
2222/***************************************************************************/
2323
24static INTERRUPT_GEN( scontra_interrupt )
24INTERRUPT_GEN_MEMBER(thunderx_state::scontra_interrupt)
2525{
26   thunderx_state *state = device->machine().driver_data<thunderx_state>();
2726
28   if (k052109_is_irq_enabled(state->m_k052109))
29      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
27   if (k052109_is_irq_enabled(m_k052109))
28      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
3029}
3130
3231static TIMER_CALLBACK( thunderx_firq_callback )
r17996r17997
658657   /* basic machine hardware */
659658   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)      /* Verified on pcb, CPU is 052001 */
660659   MCFG_CPU_PROGRAM_MAP(scontra_map)
661   MCFG_CPU_VBLANK_INT("screen", scontra_interrupt)
660   MCFG_CPU_VBLANK_INT_DRIVER("screen", thunderx_state, scontra_interrupt)
662661
663662   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)      /* verified on pcb */
664663   MCFG_CPU_PROGRAM_MAP(scontra_sound_map)
r17996r17997
701700   /* basic machine hardware */
702701   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)      /* ? */
703702   MCFG_CPU_PROGRAM_MAP(thunderx_map)
704   MCFG_CPU_VBLANK_INT("screen", scontra_interrupt)
703   MCFG_CPU_VBLANK_INT_DRIVER("screen", thunderx_state, scontra_interrupt)
705704
706705   MCFG_CPU_ADD("audiocpu", Z80, 3579545)      /* ? */
707706   MCFG_CPU_PROGRAM_MAP(thunderx_sound_map)
trunk/src/mame/drivers/galaxi.c
r17996r17997
406406   /* basic machine hardware */
407407   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)   // ?
408408   MCFG_CPU_PROGRAM_MAP(galaxi_map)
409   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
409   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxi_state, irq4_line_hold)
410410
411411   MCFG_NVRAM_ADD_0FILL("nvram")
412412
trunk/src/mame/drivers/toypop.c
r17996r17997
9999   }
100100}
101101
102static INTERRUPT_GEN( toypop_main_vblank_irq )
102INTERRUPT_GEN_MEMBER(toypop_state::toypop_main_vblank_irq)
103103{
104   toypop_state *state = device->machine().driver_data<toypop_state>();
105   device_t *namcoio_0 = device->machine().device("58xx");
106   device_t *namcoio_1 = device->machine().device("56xx_1");
107   device_t *namcoio_2 = device->machine().device("56xx_2");
104   device_t *namcoio_0 = machine().device("58xx");
105   device_t *namcoio_1 = machine().device("56xx_1");
106   device_t *namcoio_2 = machine().device("56xx_2");
108107
109   if(state->m_main_irq_mask)
110      device->execute().set_input_line(0, HOLD_LINE);
108   if(m_main_irq_mask)
109      device.execute().set_input_line(0, HOLD_LINE);
111110
112111   if (!namcoio_read_reset_line(namcoio_0))      /* give the cpu a tiny bit of time to write the command before processing it */
113      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
112      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
114113
115114   if (!namcoio_read_reset_line(namcoio_1))      /* give the cpu a tiny bit of time to write the command before processing it */
116      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
115      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
117116
118117   if (!namcoio_read_reset_line(namcoio_2))      /* give the cpu a tiny bit of time to write the command before processing it */
119      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 2);
118      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 2);
120119
121120}
122121
123static INTERRUPT_GEN( toypop_sound_timer_irq )
122INTERRUPT_GEN_MEMBER(toypop_state::toypop_sound_timer_irq)
124123{
125   toypop_state *state = device->machine().driver_data<toypop_state>();
126124
127   if(state->m_sound_irq_mask)
128      device->execute().set_input_line(0, HOLD_LINE);
125   if(m_sound_irq_mask)
126      device.execute().set_input_line(0, HOLD_LINE);
129127}
130128
131129WRITE8_MEMBER(toypop_state::toypop_sound_clear_w)
r17996r17997
160158   m_interrupt_enable_68k = 0;
161159}
162160
163static INTERRUPT_GEN( toypop_m68000_interrupt )
161INTERRUPT_GEN_MEMBER(toypop_state::toypop_m68000_interrupt)
164162{
165   toypop_state *state = device->machine().driver_data<toypop_state>();
166   if (state->m_interrupt_enable_68k)
167      device->execute().set_input_line(6, HOLD_LINE);
163   if (m_interrupt_enable_68k)
164      device.execute().set_input_line(6, HOLD_LINE);
168165}
169166
170167WRITE16_MEMBER(toypop_state::toypop_m68000_interrupt_enable_w)
r17996r17997
549546   /* basic machine hardware */
550547   MCFG_CPU_ADD("maincpu", M6809, 1536000)   /* 1.536 MHz (measured on Libble Rabble board) */
551548   MCFG_CPU_PROGRAM_MAP(liblrabl_map)
552   MCFG_CPU_VBLANK_INT("screen", toypop_main_vblank_irq)
549   MCFG_CPU_VBLANK_INT_DRIVER("screen", toypop_state, toypop_main_vblank_irq)
553550
554551   MCFG_CPU_ADD("audiocpu", M6809, 1536000)
555552   MCFG_CPU_PROGRAM_MAP(sound_map)
556   MCFG_CPU_VBLANK_INT("screen", toypop_sound_timer_irq)
553   MCFG_CPU_VBLANK_INT_DRIVER("screen", toypop_state, toypop_sound_timer_irq)
557554
558555   MCFG_CPU_ADD("sub", M68000, 6144000)   /* 6.144 MHz (measured on Libble Rabble board) */
559556   MCFG_CPU_PROGRAM_MAP(m68k_map)
560   MCFG_CPU_VBLANK_INT("screen", toypop_m68000_interrupt)
557   MCFG_CPU_VBLANK_INT_DRIVER("screen", toypop_state, toypop_m68000_interrupt)
561558
562559   MCFG_QUANTUM_TIME(attotime::from_hz(6000))    /* 100 CPU slices per frame - an high value to ensure proper */
563560                     /* synchronization of the CPUs */
trunk/src/mame/drivers/tumbleb.c
r17996r17997
439439}
440440
441441
442static INTERRUPT_GEN( tumbleb2_interrupt )
442INTERRUPT_GEN_MEMBER(tumbleb_state::tumbleb2_interrupt)
443443{
444   tumbleb_state *state = device->machine().driver_data<tumbleb_state>();
445   device->execute().set_input_line(6, HOLD_LINE);
446   tumbleb2_playmusic(state->m_oki);
444   device.execute().set_input_line(6, HOLD_LINE);
445   tumbleb2_playmusic(m_oki);
447446}
448447
449448static const int tumbleb_sound_lookup[256] = {
r17996r17997
19771976   /* basic machine hardware */
19781977   MCFG_CPU_ADD("maincpu", M68000, 14000000)
19791978   MCFG_CPU_PROGRAM_MAP(tumblepopb_main_map)
1980   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
1979   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, irq6_line_hold)
19811980
19821981   MCFG_MACHINE_START_OVERRIDE(tumbleb_state,tumbleb)
19831982   MCFG_MACHINE_RESET_OVERRIDE(tumbleb_state,tumbleb)
r17996r17997
20122011   /* basic machine hardware */
20132012   MCFG_CPU_ADD("maincpu", M68000, 14000000)
20142013   MCFG_CPU_PROGRAM_MAP(tumblepopb_main_map)
2015   MCFG_CPU_VBLANK_INT("screen", tumbleb2_interrupt)
2014   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, tumbleb2_interrupt)
20162015
20172016   MCFG_MACHINE_START_OVERRIDE(tumbleb_state,tumbleb)
20182017   MCFG_MACHINE_RESET_OVERRIDE(tumbleb_state,tumbleb)
r17996r17997
20462045   /* basic machine hardware */
20472046   MCFG_CPU_ADD("maincpu", M68000, 12000000)
20482047   MCFG_CPU_PROGRAM_MAP(jumpkids_main_map)
2049   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
2048   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, irq6_line_hold)
20502049
20512050   /* z80? */
20522051   MCFG_CPU_ADD("audiocpu", Z80, 8000000/2)
r17996r17997
20842083   /* basic machine hardware */
20852084   MCFG_CPU_ADD("maincpu", M68000, 12000000)
20862085   MCFG_CPU_PROGRAM_MAP(fncywld_main_map)
2087   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
2086   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, irq6_line_hold)
20882087
20892088   MCFG_MACHINE_START_OVERRIDE(tumbleb_state,tumbleb)
20902089   MCFG_MACHINE_RESET_OVERRIDE(tumbleb_state,tumbleb)
r17996r17997
21512150   /* basic machine hardware */
21522151   MCFG_CPU_ADD("maincpu", M68000, 15000000) /* verified */
21532152   MCFG_CPU_PROGRAM_MAP(htchctch_main_map)
2154   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
2153   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, irq6_line_hold)
21552154
21562155   MCFG_CPU_ADD("audiocpu", Z80, 15000000/4) /* verified on dquizgo */
21572156   MCFG_CPU_PROGRAM_MAP(semicom_sound_map)
r17996r17997
22442243   /* basic machine hardware */
22452244   MCFG_CPU_ADD("maincpu", M68000, 14000000) /* 14mhz should be correct, but lots of sprite flicker later in game */
22462245   MCFG_CPU_PROGRAM_MAP(suprtrio_main_map)
2247   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
2246   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, irq6_line_hold)
22482247
22492248   MCFG_CPU_ADD("audiocpu", Z80, 8000000)
22502249   MCFG_CPU_PROGRAM_MAP(suprtrio_sound_map)
r17996r17997
22822281   /* basic machine hardware */
22832282   MCFG_CPU_ADD("maincpu", M68000, 14000000)
22842283   MCFG_CPU_PROGRAM_MAP(pangpang_main_map)
2285   MCFG_CPU_VBLANK_INT("screen", tumbleb2_interrupt)
2284   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumbleb_state, tumbleb2_interrupt)
22862285
22872286   MCFG_MACHINE_START_OVERRIDE(tumbleb_state,tumbleb)
22882287   MCFG_MACHINE_RESET_OVERRIDE(tumbleb_state,tumbleb)
trunk/src/mame/drivers/bmcpokr.c
r17996r17997
230230static MACHINE_CONFIG_START( bmcpokr, bmcpokr_state )
231231   MCFG_CPU_ADD("maincpu", M68000, XTAL_42MHz/4)
232232   MCFG_CPU_PROGRAM_MAP(bmcpokr_mem)
233   MCFG_CPU_VBLANK_INT("screen",irq3_line_hold)
233   MCFG_CPU_VBLANK_INT_DRIVER("screen", bmcpokr_state, irq3_line_hold)
234234
235235   MCFG_SCREEN_ADD("screen", RASTER)
236236   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/taitotz.c
r17996r17997
525525   virtual void machine_reset();
526526   virtual void video_start();
527527   UINT32 screen_update_taitotz(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
528   INTERRUPT_GEN_MEMBER(taitotz_vbi);
528529};
529530
530531
r17996r17997
24452446}
24462447
24472448
2448static INTERRUPT_GEN( taitotz_vbi )
2449INTERRUPT_GEN_MEMBER(taitotz_state::taitotz_vbi)
24492450{
2450   device->machine().device("iocpu")->execute().set_input_line(TLCS900_INT3, ASSERT_LINE);
2451   machine().device("iocpu")->execute().set_input_line(TLCS900_INT3, ASSERT_LINE);
24512452}
24522453
24532454static void ide_interrupt(device_t *device, int state)
r17996r17997
24872488   MCFG_CPU_ADD("iocpu", TMP95C063, 25000000)
24882489   MCFG_CPU_CONFIG(taitotz_tlcs900_interface)
24892490   MCFG_CPU_PROGRAM_MAP(tlcs900h_mem)
2490   MCFG_CPU_VBLANK_INT("screen", taitotz_vbi)
2491   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitotz_state, taitotz_vbi)
24912492
24922493   /* MN1020819DA sound CPU */
24932494
trunk/src/mame/drivers/micro3d.c
r17996r17997
335335
336336   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz / 2)
337337   MCFG_CPU_PROGRAM_MAP(hostmem)
338   MCFG_CPU_VBLANK_INT("screen", micro3d_vblank)
338   MCFG_CPU_VBLANK_INT_DRIVER("screen", micro3d_state, micro3d_vblank)
339339
340340   MCFG_CPU_ADD("vgb", TMS34010, XTAL_40MHz)
341341   MCFG_CPU_CONFIG(vgb_config)
trunk/src/mame/drivers/cabaret.c
r17996r17997
5656   virtual void machine_reset();
5757   virtual void video_start();
5858   UINT32 screen_update_cabaret(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
59   INTERRUPT_GEN_MEMBER(cabaret_interrupt);
5960};
6061
6162
r17996r17997
324325   m_nmi_enable      =   0;
325326}
326327
327static INTERRUPT_GEN( cabaret_interrupt )
328INTERRUPT_GEN_MEMBER(cabaret_state::cabaret_interrupt)
328329{
329   cabaret_state *state = device->machine().driver_data<cabaret_state>();
330    if (state->m_nmi_enable & 0x80)
331      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
330    if (m_nmi_enable & 0x80)
331      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
332332}
333333
334334static MACHINE_CONFIG_START( cabaret, cabaret_state )
r17996r17997
336336   MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2)
337337   MCFG_CPU_PROGRAM_MAP(cabaret_map)
338338   MCFG_CPU_IO_MAP(cabaret_portmap)
339   MCFG_CPU_VBLANK_INT("screen",cabaret_interrupt)
339   MCFG_CPU_VBLANK_INT_DRIVER("screen", cabaret_state, cabaret_interrupt)
340340
341341
342342   /* video hardware */
trunk/src/mame/drivers/momoko.c
r17996r17997
263263   /* basic machine hardware */
264264   MCFG_CPU_ADD("maincpu", Z80, 5000000)   /* 5.0MHz */
265265   MCFG_CPU_PROGRAM_MAP(momoko_map)
266   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
266   MCFG_CPU_VBLANK_INT_DRIVER("screen", momoko_state, irq0_line_hold)
267267
268268   MCFG_CPU_ADD("audiocpu", Z80, 2500000)   /* 2.5MHz */
269269   MCFG_CPU_PROGRAM_MAP(momoko_sound_map)
trunk/src/mame/drivers/kchamp.c
r17996r17997
340340
341341
342342
343static INTERRUPT_GEN( kc_interrupt )
343INTERRUPT_GEN_MEMBER(kchamp_state::kc_interrupt)
344344{
345   kchamp_state *state = device->machine().driver_data<kchamp_state>();
346   if (state->m_nmi_enable)
347      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
345   if (m_nmi_enable)
346      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
348347}
349348
350349static void msmint( device_t *device )
r17996r17997
375374* 1 Player Version  *
376375********************/
377376
378static INTERRUPT_GEN( sound_int )
377INTERRUPT_GEN_MEMBER(kchamp_state::sound_int)
379378{
380   kchamp_state *state = device->machine().driver_data<kchamp_state>();
381   if (state->m_sound_nmi_enable)
382      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
379   if (m_sound_nmi_enable)
380      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
383381}
384382
385383
r17996r17997
415413   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/4)    /* verified on pcb */
416414   MCFG_CPU_PROGRAM_MAP(kchampvs_map)
417415   MCFG_CPU_IO_MAP(kchampvs_io_map)
418   MCFG_CPU_VBLANK_INT("screen", kc_interrupt)
416   MCFG_CPU_VBLANK_INT_DRIVER("screen", kchamp_state, kc_interrupt)
419417
420418   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4)    /* verified on pcb */
421419   MCFG_CPU_PROGRAM_MAP(kchampvs_sound_map)
r17996r17997
460458   MCFG_CPU_ADD("maincpu", Z80, 3000000)   /* 12MHz / 4 = 3.0 MHz */
461459   MCFG_CPU_PROGRAM_MAP(kchamp_map)
462460   MCFG_CPU_IO_MAP(kchamp_io_map)
463   MCFG_CPU_VBLANK_INT("screen", kc_interrupt)
461   MCFG_CPU_VBLANK_INT_DRIVER("screen", kchamp_state, kc_interrupt)
464462
465463   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   /* 12MHz / 4 = 3.0 MHz */
466464   MCFG_CPU_PROGRAM_MAP(kchamp_sound_map)
467465   MCFG_CPU_IO_MAP(kchamp_sound_io_map)
468   MCFG_CPU_PERIODIC_INT(sound_int, 125)   /* Hz */
466   MCFG_CPU_PERIODIC_INT_DRIVER(kchamp_state, sound_int, 125)   /* Hz */
469467                                 /* irq's triggered from main cpu */
470468                                 /* nmi's from 125 Hz clock */
471469
trunk/src/mame/drivers/olibochu.c
r17996r17997
452452
453453   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ?? */
454454   MCFG_CPU_PROGRAM_MAP(olibochu_sound_map)
455   MCFG_CPU_PERIODIC_INT(irq0_line_hold,60) //???
455   MCFG_CPU_PERIODIC_INT_DRIVER(olibochu_state, irq0_line_hold, 60) //???
456456
457457//  MCFG_QUANTUM_PERFECT_CPU("maincpu")
458458
trunk/src/mame/drivers/m90.c
r17996r17997
677677   DEVCB_NULL
678678};
679679
680static INTERRUPT_GEN( fake_nmi )
680INTERRUPT_GEN_MEMBER(m90_state::fake_nmi)
681681{
682   m90_state *state = device->machine().driver_data<m90_state>();
683   address_space &space = *device->machine().firstcpu->space(AS_PROGRAM);
684   int sample = m72_sample_r(state->m_audio,space,0);
682   address_space &space = *machine().firstcpu->space(AS_PROGRAM);
683   int sample = m72_sample_r(m_audio,space,0);
685684   if (sample)
686      m72_sample_w(state->m_audio,space,0,sample);
685      m72_sample_w(m_audio,space,0,sample);
687686}
688687
689static INTERRUPT_GEN( bomblord_fake_nmi )
688INTERRUPT_GEN_MEMBER(m90_state::bomblord_fake_nmi)
690689{
691   m90_state *state = device->machine().driver_data<m90_state>();
692   address_space &space = *device->machine().firstcpu->space(AS_PROGRAM);
693   int sample = m72_sample_r(state->m_audio,space,0);
690   address_space &space = *machine().firstcpu->space(AS_PROGRAM);
691   int sample = m72_sample_r(m_audio,space,0);
694692   if (sample != 0x80)
695      m72_sample_w(state->m_audio,space,0,sample);
693      m72_sample_w(m_audio,space,0,sample);
696694}
697695
698static INTERRUPT_GEN( m90_interrupt )
696INTERRUPT_GEN_MEMBER(m90_state::m90_interrupt)
699697{
700   generic_pulse_irq_line(device, NEC_INPUT_LINE_INTP0, 1);
698   generic_pulse_irq_line(device.execute(), NEC_INPUT_LINE_INTP0, 1);
701699}
702700
703static INTERRUPT_GEN( dynablsb_interrupt )
701INTERRUPT_GEN_MEMBER(m90_state::dynablsb_interrupt)
704702{
705   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x60/4);
703   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x60/4);
706704}
707705
708static INTERRUPT_GEN( bomblord_interrupt )
706INTERRUPT_GEN_MEMBER(m90_state::bomblord_interrupt)
709707{
710   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x50/4);
708   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x50/4);
711709}
712710
713711
r17996r17997
717715   MCFG_CPU_ADD("maincpu", V35, XTAL_32MHz/2)
718716   MCFG_CPU_PROGRAM_MAP(m90_main_cpu_map)
719717   MCFG_CPU_IO_MAP(m90_main_cpu_io_map)
720   MCFG_CPU_VBLANK_INT("screen", m90_interrupt)
718   MCFG_CPU_VBLANK_INT_DRIVER("screen", m90_state, m90_interrupt)
721719
722720   MCFG_CPU_ADD("soundcpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
723721   MCFG_CPU_PROGRAM_MAP(m90_sound_cpu_map)
724722   MCFG_CPU_IO_MAP(m90_sound_cpu_io_map)
725   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 128*60)   /* clocked by V1? (Vigilante) */
723   MCFG_CPU_PERIODIC_INT_DRIVER(m90_state, nmi_line_pulse, 128*60)   /* clocked by V1? (Vigilante) */
726724                        /* IRQs are generated by main Z80 and YM2151 */
727725
728726
r17996r17997
802800static MACHINE_CONFIG_DERIVED( bbmanw, bbmanwj )
803801   MCFG_CPU_MODIFY("soundcpu")
804802   MCFG_CPU_IO_MAP(m99_sound_cpu_io_map)
805   MCFG_CPU_PERIODIC_INT(fake_nmi, 128*60)
803   MCFG_CPU_PERIODIC_INT_DRIVER(m90_state, fake_nmi, 128*60)
806804MACHINE_CONFIG_END
807805
808806
r17996r17997
810808   MCFG_CPU_REPLACE("maincpu", V30, 32000000/4)
811809   MCFG_CPU_PROGRAM_MAP(bomblord_main_cpu_map)
812810   MCFG_CPU_IO_MAP(m90_main_cpu_io_map)
813   MCFG_CPU_VBLANK_INT("screen", bomblord_interrupt)
811   MCFG_CPU_VBLANK_INT_DRIVER("screen", m90_state, bomblord_interrupt)
814812
815813   MCFG_CPU_MODIFY("soundcpu")
816814   MCFG_CPU_IO_MAP(m99_sound_cpu_io_map)
817   MCFG_CPU_PERIODIC_INT(bomblord_fake_nmi, 128*60)
815   MCFG_CPU_PERIODIC_INT_DRIVER(m90_state, bomblord_fake_nmi, 128*60)
818816
819817   MCFG_SCREEN_MODIFY("screen")
820818   MCFG_SCREEN_VISIBLE_AREA(10*8, 50*8-1, 17*8, 47*8-1)
r17996r17997
828826   MCFG_CPU_REPLACE("maincpu", V30, 32000000/4)
829827   MCFG_CPU_PROGRAM_MAP(dynablsb_main_cpu_map)
830828   MCFG_CPU_IO_MAP(dynablsb_main_cpu_io_map)
831   MCFG_CPU_VBLANK_INT("screen", dynablsb_interrupt)
829   MCFG_CPU_VBLANK_INT_DRIVER("screen", m90_state, dynablsb_interrupt)
832830
833831   MCFG_CPU_MODIFY("soundcpu")
834832   MCFG_CPU_IO_MAP(dynablsb_sound_cpu_io_map)
835   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 64*60)   /* half the sample rate of the original */
833   MCFG_CPU_PERIODIC_INT_DRIVER(m90_state, irq0_line_hold, 64*60)   /* half the sample rate of the original */
836834
837835   MCFG_SCREEN_MODIFY("screen")
838836   MCFG_SCREEN_SIZE(320, 240)
trunk/src/mame/drivers/tugboat.c
r17996r17997
333333static MACHINE_CONFIG_START( tugboat, tugboat_state )
334334   MCFG_CPU_ADD("maincpu", M6502, 2000000)   /* 2 MHz ???? */
335335   MCFG_CPU_PROGRAM_MAP(main_map)
336   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
336   MCFG_CPU_VBLANK_INT_DRIVER("screen", tugboat_state, nmi_line_pulse)
337337
338338
339339   MCFG_PIA6821_ADD("pia0", pia0_intf)
trunk/src/mame/drivers/kingdrby.c
r17996r17997
10171017   MCFG_CPU_ADD("master", Z80, CLK_2)
10181018   MCFG_CPU_PROGRAM_MAP(master_map)
10191019   MCFG_CPU_IO_MAP(master_io_map)
1020   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1020   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingdrby_state, irq0_line_hold)
10211021
10221022   MCFG_CPU_ADD("slave", Z80, CLK_2)
10231023   MCFG_CPU_PROGRAM_MAP(slave_map)
10241024   MCFG_CPU_IO_MAP(slave_io_map)
1025   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1025   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingdrby_state, irq0_line_hold)
10261026
10271027   MCFG_CPU_ADD("soundcpu", Z80, CLK_2)
10281028   MCFG_CPU_PROGRAM_MAP(sound_map)
10291029   MCFG_CPU_IO_MAP(sound_io_map)
1030   MCFG_CPU_PERIODIC_INT(irq0_line_hold,1000) /* guess, controls ay8910 tempo.*/
1030   MCFG_CPU_PERIODIC_INT_DRIVER(kingdrby_state, irq0_line_hold, 1000) /* guess, controls ay8910 tempo.*/
10311031
10321032   MCFG_QUANTUM_PERFECT_CPU("master")
10331033
trunk/src/mame/drivers/r2dx_v33.c
r17996r17997
7171   tilemap_t *m_tx_tilemap;
7272   virtual void video_start();
7373   UINT32 screen_update_rdx_v33(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
74   INTERRUPT_GEN_MEMBER(rdx_v33_interrupt);
7475};
7576
7677
r17996r17997
509510   AM_RANGE(0x40000, 0xfffff) AM_ROM AM_REGION("mainprg", 0x40000 )
510511ADDRESS_MAP_END
511512
512static INTERRUPT_GEN( rdx_v33_interrupt )
513INTERRUPT_GEN_MEMBER(r2dx_v33_state::rdx_v33_interrupt)
513514{
514   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc0/4);   /* VBL */
515   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc0/4);   /* VBL */
515516}
516517
517518static const gfx_layout rdx_v33_charlayout =
r17996r17997
692693   /* basic machine hardware */
693694   MCFG_CPU_ADD("maincpu", V33, 32000000/2 ) // ?
694695   MCFG_CPU_PROGRAM_MAP(rdx_v33_map)
695   MCFG_CPU_VBLANK_INT("screen", rdx_v33_interrupt)
696   MCFG_CPU_VBLANK_INT_DRIVER("screen", r2dx_v33_state, rdx_v33_interrupt)
696697
697698   //MCFG_MACHINE_RESET_OVERRIDE(r2dx_v33_state,rdx_v33)
698699
r17996r17997
722723   /* basic machine hardware */
723724   MCFG_CPU_ADD("maincpu", V33,XTAL_32MHz/2) /* verified on pcb */
724725   MCFG_CPU_PROGRAM_MAP(nzerotea_map)
725   MCFG_CPU_VBLANK_INT("screen", rdx_v33_interrupt)
726   MCFG_CPU_VBLANK_INT_DRIVER("screen", r2dx_v33_state, rdx_v33_interrupt)
726727
727728   MCFG_MACHINE_RESET(seibu_sound)
728729
trunk/src/mame/drivers/lastfght.c
r17996r17997
125125   virtual void machine_reset();
126126   virtual void video_start();
127127   UINT32 screen_update_lastfght(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
128   INTERRUPT_GEN_MEMBER(unknown_interrupt);
128129};
129130
130131
r17996r17997
527528                                Machine Drivers
528529***************************************************************************/
529530
530static INTERRUPT_GEN( unknown_interrupt )
531INTERRUPT_GEN_MEMBER(lastfght_state::unknown_interrupt)
531532{
532   lastfght_state *state = device->machine().driver_data<lastfght_state>();
533533
534   state->m_maincpu->set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
534   m_maincpu->set_input_line(H8_METRO_TIMER_HACK, HOLD_LINE);
535535}
536536
537537void lastfght_state::machine_start()
r17996r17997
581581   /* basic machine hardware */
582582   MCFG_CPU_ADD("maincpu", H83044, 32000000/2)
583583   MCFG_CPU_PROGRAM_MAP( lastfght_map)
584   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
585   MCFG_CPU_PERIODIC_INT(unknown_interrupt,60)
584   MCFG_CPU_VBLANK_INT_DRIVER("screen", lastfght_state, irq0_line_hold)
585   MCFG_CPU_PERIODIC_INT_DRIVER(lastfght_state, unknown_interrupt, 60)
586586
587587   MCFG_NVRAM_ADD_0FILL("nvram")
588588
trunk/src/mame/drivers/superqix.c
r17996r17997
982982   DEVCB_NULL
983983};
984984
985static INTERRUPT_GEN( vblank_irq )
985INTERRUPT_GEN_MEMBER(superqix_state::vblank_irq)
986986{
987   superqix_state *state = device->machine().driver_data<superqix_state>();
988987
989   if(state->m_nmi_mask)
990      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
988   if(m_nmi_mask)
989      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
991990}
992991
993static INTERRUPT_GEN( sqix_timer_irq )
992INTERRUPT_GEN_MEMBER(superqix_state::sqix_timer_irq)
994993{
995   superqix_state *state = device->machine().driver_data<superqix_state>();
996994
997   if (state->m_nmi_mask)
998      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
995   if (m_nmi_mask)
996      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
999997}
1000998
1001999
r17996r17997
10041002   MCFG_CPU_ADD("maincpu", Z80,12000000/2)       /* 6 MHz */
10051003   MCFG_CPU_PROGRAM_MAP(main_map)
10061004   MCFG_CPU_IO_MAP(pbillian_port_map)
1007   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1005   MCFG_CPU_VBLANK_INT_DRIVER("screen", superqix_state, vblank_irq)
10081006
10091007   MCFG_MACHINE_START_OVERRIDE(superqix_state,pbillian)
10101008
r17996r17997
10351033   MCFG_CPU_ADD("maincpu", Z80,12000000/2)       /* 6 MHz */
10361034   MCFG_CPU_PROGRAM_MAP(main_map)
10371035   MCFG_CPU_IO_MAP(hotsmash_port_map)
1038   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1036   MCFG_CPU_VBLANK_INT_DRIVER("screen", superqix_state, vblank_irq)
10391037
10401038   MCFG_CPU_ADD("mcu", M68705, 4000000) /* ???? */
10411039   MCFG_CPU_PROGRAM_MAP(m68705_map)
r17996r17997
10711069   MCFG_CPU_ADD("maincpu", Z80, 12000000/2)   /* 6 MHz */
10721070   MCFG_CPU_PROGRAM_MAP(main_map)
10731071   MCFG_CPU_IO_MAP(sqix_port_map)
1074   MCFG_CPU_PERIODIC_INT(sqix_timer_irq, 4*60) /* ??? */
1072   MCFG_CPU_PERIODIC_INT_DRIVER(superqix_state, sqix_timer_irq, 4*60) /* ??? */
10751073
10761074   MCFG_CPU_ADD("mcu", I8751, 12000000/3)   /* ??? */
10771075   MCFG_CPU_IO_MAP(bootleg_mcu_io_map)
r17996r17997
11191117   MCFG_CPU_ADD("maincpu", Z80, 12000000/2)   /* 6 MHz */
11201118   MCFG_CPU_PROGRAM_MAP(main_map)
11211119   MCFG_CPU_IO_MAP(sqix_port_map)
1122   MCFG_CPU_PERIODIC_INT(sqix_timer_irq, 4*60) /* ??? */
1120   MCFG_CPU_PERIODIC_INT_DRIVER(superqix_state, sqix_timer_irq, 4*60) /* ??? */
11231121
11241122   MCFG_MACHINE_START_OVERRIDE(superqix_state,superqix)
11251123
trunk/src/mame/drivers/markham.c
r17996r17997
194194   /* basic machine hardware */
195195   MCFG_CPU_ADD("maincpu", Z80,8000000/2) /* 4.000MHz */
196196   MCFG_CPU_PROGRAM_MAP(markham_master_map)
197   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
197   MCFG_CPU_VBLANK_INT_DRIVER("screen", markham_state, irq0_line_hold)
198198
199199   MCFG_CPU_ADD("sub", Z80,8000000/2) /* 4.000MHz */
200200   MCFG_CPU_PROGRAM_MAP(markham_slave_map)
201   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
201   MCFG_CPU_VBLANK_INT_DRIVER("screen", markham_state, irq0_line_hold)
202202
203203   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
204204
trunk/src/mame/drivers/vega.c
r17996r17997
842842   MCFG_CPU_ADD("maincpu", I8035, 4000000)
843843   MCFG_CPU_PROGRAM_MAP(vega_map)
844844   MCFG_CPU_IO_MAP(vega_io_map)
845   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
845   MCFG_CPU_VBLANK_INT_DRIVER("screen", vega_state, irq0_line_hold)
846846
847847
848848
trunk/src/mame/drivers/cyberbal.c
r17996r17997
440440
441441   MCFG_CPU_ADD("dac", M68000, ATARI_CLOCK_14MHz/2)
442442   MCFG_CPU_PROGRAM_MAP(sound_68k_map)
443   MCFG_CPU_PERIODIC_INT(cyberbal_sound_68k_irq_gen, 10000)
443   MCFG_CPU_PERIODIC_INT_DRIVER(cyberbal_state, cyberbal_sound_68k_irq_gen, 10000)
444444
445445   MCFG_QUANTUM_TIME(attotime::from_hz(600))
446446
trunk/src/mame/drivers/warpsped.c
r17996r17997
308308   MCFG_CPU_ADD("maincpu", Z80, XTAL_5MHz/2)
309309   MCFG_CPU_PROGRAM_MAP(warpspeed_map)
310310   MCFG_CPU_IO_MAP(warpspeed_io_map)
311   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
311   MCFG_CPU_VBLANK_INT_DRIVER("screen", warpspeed_state, irq0_line_hold)
312312
313313   /* video hardware */
314314
trunk/src/mame/drivers/kontest.c
r17996r17997
5353
5454   virtual void video_start();
5555   virtual void palette_init();
56public:   
57   INTERRUPT_GEN_MEMBER(kontest_interrupt);
5658};
5759
5860
r17996r17997
240242
241243***************************************************************************/
242244
243static INTERRUPT_GEN( kontest_interrupt )
245INTERRUPT_GEN_MEMBER(kontest_state::kontest_interrupt)
244246{
245   kontest_state *state = device->machine().driver_data<kontest_state>();
246   if (state->m_control & 8)
247      device->execute().set_input_line(0, ASSERT_LINE);
247   if (m_control & 8)
248      device.execute().set_input_line(0, ASSERT_LINE);
248249}
249250
250251void kontest_state::machine_start()
r17996r17997
264265   MCFG_CPU_ADD("maincpu", Z80,MAIN_CLOCK/8)
265266   MCFG_CPU_PROGRAM_MAP(kontest_map)
266267   MCFG_CPU_IO_MAP(kontest_io)
267   MCFG_CPU_VBLANK_INT("screen", kontest_interrupt)
268   MCFG_CPU_VBLANK_INT_DRIVER("screen", kontest_state, kontest_interrupt)
268269
269270   /* video hardware */
270271   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gijoe.c
r17996r17997
116116      state->m_maincpu->set_input_line(6, HOLD_LINE);
117117}
118118
119static INTERRUPT_GEN( gijoe_interrupt )
119INTERRUPT_GEN_MEMBER(gijoe_state::gijoe_interrupt)
120120{
121   gijoe_state *state = device->machine().driver_data<gijoe_state>();
122121
123122   // global interrupt masking (*this game only)
124   if (!k056832_is_irq_enabled(state->m_k056832, 0))
123   if (!k056832_is_irq_enabled(m_k056832, 0))
125124      return;
126125
127   if (k053246_is_irq_enabled(state->m_k053246))
126   if (k053246_is_irq_enabled(m_k053246))
128127   {
129      gijoe_objdma(device->machine());
128      gijoe_objdma(machine());
130129
131130      // 42.7us(clr) + 341.3us(xfer) delay at 6Mhz dotclock
132      state->m_dmadelay_timer->adjust(JOE_DMADELAY);
131      m_dmadelay_timer->adjust(JOE_DMADELAY);
133132   }
134133
135134   // trigger V-blank interrupt
136   if (state->m_cur_control2 & 0x0080)
137      device->execute().set_input_line(5, HOLD_LINE);
135   if (m_cur_control2 & 0x0080)
136      device.execute().set_input_line(5, HOLD_LINE);
138137}
139138
140139WRITE16_MEMBER(gijoe_state::sound_cmd_w)
r17996r17997
296295   /* basic machine hardware */
297296   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* Confirmed */
298297   MCFG_CPU_PROGRAM_MAP(gijoe_map)
299   MCFG_CPU_VBLANK_INT("screen", gijoe_interrupt)
298   MCFG_CPU_VBLANK_INT_DRIVER("screen", gijoe_state, gijoe_interrupt)
300299
301300   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* Amuse & confirmed. z80e */
302301   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tigeroad.c
r17996r17997
520520   /* basic machine hardware */
521521   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz) /* verified on pcb */
522522   MCFG_CPU_PROGRAM_MAP(main_map)
523   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
523   MCFG_CPU_VBLANK_INT_DRIVER("screen", tigeroad_state, irq2_line_hold)
524524
525525   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
526526   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
563563   MCFG_CPU_ADD("sample", Z80, 3579545) /* ? */
564564   MCFG_CPU_PROGRAM_MAP(sample_map)
565565   MCFG_CPU_IO_MAP(sample_port_map)
566   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4000)   /* ? */
566   MCFG_CPU_PERIODIC_INT_DRIVER(tigeroad_state, irq0_line_hold, 4000)   /* ? */
567567
568568   /* sound hardware */
569569   MCFG_SOUND_ADD("msm", MSM5205, 384000)
trunk/src/mame/drivers/rltennis.c
r17996r17997
147147   state->m_timer->adjust(attotime::from_hz( RLT_TIMER_FREQ ));
148148}
149149
150static INTERRUPT_GEN(  rltennis_interrupt )
150INTERRUPT_GEN_MEMBER(rltennis_state::rltennis_interrupt)
151151{
152   rltennis_state *state = device->machine().driver_data<rltennis_state>();
153   ++state->m_unk_counter; /* frame counter? verify */
154   device->execute().set_input_line(4, HOLD_LINE);
155   device->execute().set_input_line(1, HOLD_LINE); /* hack, to avoid dead loop */
152   ++m_unk_counter; /* frame counter? verify */
153   device.execute().set_input_line(4, HOLD_LINE);
154   device.execute().set_input_line(1, HOLD_LINE); /* hack, to avoid dead loop */
156155}
157156
158157void rltennis_state::machine_start()
r17996r17997
185184
186185   MCFG_CPU_ADD("maincpu", M68000, RLT_XTAL/2) /* 68000P8  ??? */
187186   MCFG_CPU_PROGRAM_MAP(rltennis_main)
188   MCFG_CPU_VBLANK_INT("screen", rltennis_interrupt)
187   MCFG_CPU_VBLANK_INT_DRIVER("screen", rltennis_state, rltennis_interrupt)
189188
190189   MCFG_SCREEN_ADD("screen", RASTER)
191190   MCFG_SCREEN_REFRESH_RATE( RLT_REFRESH_RATE )
trunk/src/mame/drivers/spaceg.c
r17996r17997
428428   /* basic machine hardware */
429429   MCFG_CPU_ADD("maincpu", Z80,2500000)       /* 2.5 MHz */
430430   MCFG_CPU_PROGRAM_MAP(spaceg_map)
431   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)   /* 60 Hz NMIs (verified) */
431   MCFG_CPU_VBLANK_INT_DRIVER("screen", spaceg_state, nmi_line_pulse)   /* 60 Hz NMIs (verified) */
432432
433433   /* video hardware */
434434   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gei.c
r17996r17997
134134   DECLARE_DRIVER_INIT(setbank);
135135   virtual void palette_init();
136136   DECLARE_PALETTE_INIT(quizvid);
137   INTERRUPT_GEN_MEMBER(vblank_irq);
137138};
138139
139140
r17996r17997
11051106};
11061107
11071108
1108static INTERRUPT_GEN( vblank_irq )
1109INTERRUPT_GEN_MEMBER(gei_state::vblank_irq)
11091110{
1110   gei_state *state = device->machine().driver_data<gei_state>();
11111111
1112   if(state->m_nmi_mask)
1113      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
1112   if(m_nmi_mask)
1113      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
11141114}
11151115
11161116
11171117static MACHINE_CONFIG_START( getrivia, gei_state )
11181118   MCFG_CPU_ADD("maincpu",Z80,4000000) /* 4 MHz */
11191119   MCFG_CPU_PROGRAM_MAP(getrivia_map)
1120   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1120   MCFG_CPU_VBLANK_INT_DRIVER("screen", gei_state, vblank_irq)
11211121
11221122   /* video hardware */
11231123   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/segas32.c
r17996r17997
569569}
570570
571571
572static INTERRUPT_GEN( start_of_vblank_int )
572INTERRUPT_GEN_MEMBER(segas32_state::start_of_vblank_int)
573573{
574   segas32_state *state = device->machine().driver_data<segas32_state>();
575   signal_v60_irq(device->machine(), MAIN_IRQ_VBSTART);
576   system32_set_vblank(device->machine(), 1);
577   device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_pos(0), FUNC(end_of_vblank_int));
578   if (state->m_system32_prot_vblank)
579      (*state->m_system32_prot_vblank)(device);
574   signal_v60_irq(machine(), MAIN_IRQ_VBSTART);
575   system32_set_vblank(machine(), 1);
576   machine().scheduler().timer_set(machine().primary_screen->time_until_pos(0), FUNC(end_of_vblank_int));
577   if (m_system32_prot_vblank)
578      (*m_system32_prot_vblank)(&device);
580579}
581580
582581
r17996r17997
21932192   /* basic machine hardware */
21942193   MCFG_CPU_ADD("maincpu", V60, MASTER_CLOCK/2)
21952194   MCFG_CPU_PROGRAM_MAP(system32_map)
2196   MCFG_CPU_VBLANK_INT("screen", start_of_vblank_int)
2195   MCFG_CPU_VBLANK_INT_DRIVER("screen", segas32_state, start_of_vblank_int)
21972196
21982197   MCFG_CPU_ADD("soundcpu", Z80, MASTER_CLOCK/4)
21992198   MCFG_CPU_PROGRAM_MAP(system32_sound_map)
r17996r17997
22522251   /* basic machine hardware */
22532252   MCFG_CPU_ADD("maincpu", V70, MULTI32_CLOCK/2)
22542253   MCFG_CPU_PROGRAM_MAP(multi32_map)
2255   MCFG_CPU_VBLANK_INT("lscreen", start_of_vblank_int)
2254   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", segas32_state, start_of_vblank_int)
22562255
22572256   MCFG_CPU_ADD("soundcpu", Z80, MASTER_CLOCK/4)
22582257   MCFG_CPU_PROGRAM_MAP(multi32_sound_map)
trunk/src/mame/drivers/looping.c
r17996r17997
143143   virtual void video_start();
144144   virtual void palette_init();
145145   UINT32 screen_update_looping(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
146   INTERRUPT_GEN_MEMBER(looping_interrupt);
146147};
147148
148149
r17996r17997
333334 *
334335 *************************************/
335336
336static INTERRUPT_GEN( looping_interrupt )
337INTERRUPT_GEN_MEMBER(looping_state::looping_interrupt)
337338{
338   device->execute().set_input_line_and_vector(0, ASSERT_LINE, 4);
339   device.execute().set_input_line_and_vector(0, ASSERT_LINE, 4);
339340}
340341
341342
r17996r17997
642643   MCFG_CPU_ADD("maincpu", TMS9995L, MAIN_CPU_CLOCK)
643644   MCFG_CPU_PROGRAM_MAP(looping_map)
644645   MCFG_CPU_IO_MAP(looping_io_map)
645   MCFG_CPU_VBLANK_INT("screen", looping_interrupt)
646   MCFG_CPU_VBLANK_INT_DRIVER("screen", looping_state, looping_interrupt)
646647
647648   MCFG_CPU_ADD("audiocpu", TMS9980L, SOUND_CLOCK/4)
648649   MCFG_CPU_PROGRAM_MAP(looping_sound_map)
trunk/src/mame/drivers/1945kiii.c
r17996r17997
257257
258258   MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK)
259259   MCFG_CPU_PROGRAM_MAP(k3_map)
260   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
260   MCFG_CPU_VBLANK_INT_DRIVER("screen", k3_state, irq4_line_hold)
261261
262262
263263   MCFG_GFXDECODE(1945kiii)
trunk/src/mame/drivers/badlands.c
r17996r17997
227227 *
228228 *************************************/
229229
230static INTERRUPT_GEN( vblank_int )
230INTERRUPT_GEN_MEMBER(badlands_state::vblank_int)
231231{
232   badlands_state *state = device->machine().driver_data<badlands_state>();
233   int pedal_state = state->ioport("PEDALS")->read();
232   int pedal_state = ioport("PEDALS")->read();
234233   int i;
235234
236235   /* update the pedals once per frame */
237236   for (i = 0; i < 2; i++)
238237   {
239      state->m_pedal_value[i]--;
238      m_pedal_value[i]--;
240239      if (pedal_state & (1 << i))
241         state->m_pedal_value[i]++;
240         m_pedal_value[i]++;
242241   }
243242
244   atarigen_video_int_gen(device);
243   atarigen_video_int_gen(&device);
245244}
246245
247246
r17996r17997
502501   /* basic machine hardware */
503502   MCFG_CPU_ADD("maincpu", M68000, ATARI_CLOCK_14MHz/2)
504503   MCFG_CPU_PROGRAM_MAP(main_map)
505   MCFG_CPU_VBLANK_INT("screen", vblank_int)
504   MCFG_CPU_VBLANK_INT_DRIVER("screen", badlands_state, vblank_int)
506505
507506   MCFG_CPU_ADD("audiocpu", M6502, ATARI_CLOCK_14MHz/8)
508507   MCFG_CPU_PROGRAM_MAP(audio_map)
r17996r17997
708707   /* basic machine hardware */
709708   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/4)   /* Divisor estimated */
710709   MCFG_CPU_PROGRAM_MAP(bootleg_map)
711   MCFG_CPU_VBLANK_INT("screen", vblank_int)
710   MCFG_CPU_VBLANK_INT_DRIVER("screen", badlands_state, vblank_int)
712711
713712//  MCFG_CPU_ADD("audiocpu", Z80, XTAL_20MHz/12)    /* Divisor estimated */
714713//  MCFG_CPU_PROGRAM_MAP(bootleg_soundmap)
trunk/src/mame/drivers/slapfght.c
r17996r17997
734734   DEVCB_NULL
735735};
736736
737static INTERRUPT_GEN( vblank_irq )
737INTERRUPT_GEN_MEMBER(slapfght_state::vblank_irq)
738738{
739   slapfght_state *state = device->machine().driver_data<slapfght_state>();
740739
741   if(state->m_irq_mask)
742      device->execute().set_input_line(0, HOLD_LINE);
740   if(m_irq_mask)
741      device.execute().set_input_line(0, HOLD_LINE);
743742}
744743
745744
r17996r17997
749748   MCFG_CPU_ADD("maincpu", Z80,16000000/4)         /* 4MHz ???, 16MHz Oscillator */
750749   MCFG_CPU_PROGRAM_MAP(perfrman_map)
751750   MCFG_CPU_IO_MAP(slapfght_io_map)
752   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
751   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapfght_state, vblank_irq)
753752
754753   MCFG_CPU_ADD("audiocpu", Z80,16000000/8)         /* 2MHz ???, 16MHz Oscillator */
755754   MCFG_CPU_PROGRAM_MAP(perfrman_sound_map)
756   MCFG_CPU_PERIODIC_INT(getstar_interrupt,4*60)   /* music speed, verified */
755   MCFG_CPU_PERIODIC_INT_DRIVER(slapfght_state, getstar_interrupt, 4*60)   /* music speed, verified */
757756
758757   MCFG_QUANTUM_TIME(attotime::from_hz(600))      /* 10 CPU slices per frame - enough for the sound CPU to read all commands */
759758
r17996r17997
795794   MCFG_CPU_ADD("maincpu", Z80, 6000000)
796795   MCFG_CPU_PROGRAM_MAP(tigerh_map)
797796   MCFG_CPU_IO_MAP(tigerhb_io_map)
798   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
797   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapfght_state, vblank_irq)
799798
800799   MCFG_CPU_ADD("audiocpu", Z80, 6000000)
801800   MCFG_CPU_PROGRAM_MAP(slapfght_sound_map)
802   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,6*60)    /* ??? */
801   MCFG_CPU_PERIODIC_INT_DRIVER(slapfght_state, nmi_line_pulse, 6*60)    /* ??? */
803802
804803   MCFG_QUANTUM_TIME(attotime::from_hz(600))   /* 10 CPU slices per frame - enough for the sound CPU to read all commands */
805804
r17996r17997
840839   MCFG_CPU_ADD("maincpu", Z80, XTAL_36MHz/6) /* verified on pcb */
841840   MCFG_CPU_PROGRAM_MAP(tigerh_map)
842841   MCFG_CPU_IO_MAP(tigerh_io_map)
843   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
842   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapfght_state, vblank_irq)
844843
845844   MCFG_CPU_ADD("audiocpu", Z80, XTAL_36MHz/12) /* verified on pcb */
846845   MCFG_CPU_PROGRAM_MAP(slapfght_sound_map)
847   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,6*60)    /* ??? */
846   MCFG_CPU_PERIODIC_INT_DRIVER(slapfght_state, nmi_line_pulse, 6*60)    /* ??? */
848847
849848   MCFG_CPU_ADD("mcu", M68705,XTAL_36MHz/12) /* verified on pcb */
850849   MCFG_CPU_PROGRAM_MAP(tigerh_m68705_map)
r17996r17997
889888   MCFG_CPU_ADD("maincpu",Z80, XTAL_36MHz/6) /* verified on pcb */
890889   MCFG_CPU_PROGRAM_MAP(slapfght_map)
891890   MCFG_CPU_IO_MAP(slapfght_io_map)
892   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
891   MCFG_CPU_VBLANK_INT_DRIVER("screen", slapfght_state, vblank_irq)
893892
894893   MCFG_CPU_ADD("audiocpu", Z80, XTAL_36MHz/12) /* verified on pcb */
895894   MCFG_CPU_PROGRAM_MAP(slapfght_sound_map)
896   MCFG_CPU_PERIODIC_INT(getstar_interrupt, 3*60)
895   MCFG_CPU_PERIODIC_INT_DRIVER(slapfght_state, getstar_interrupt, 3*60)
897896
898897   MCFG_CPU_ADD("mcu", M68705, XTAL_36MHz/12) /* verified on pcb */
899898   MCFG_CPU_PROGRAM_MAP(slapfight_m68705_map)
trunk/src/mame/drivers/psikyosh.c
r17996r17997
347347   return 0;
348348}
349349
350static INTERRUPT_GEN(psikyosh_interrupt)
350INTERRUPT_GEN_MEMBER(psikyosh_state::psikyosh_interrupt)
351351{
352   device->execute().set_input_line(4, ASSERT_LINE);
352   device.execute().set_input_line(4, ASSERT_LINE);
353353}
354354
355355// VBL handler writes 0x00 on entry, 0xc0 on exit
r17996r17997
808808   /* basic machine hardware */
809809   MCFG_CPU_ADD("maincpu", SH2, MASTER_CLOCK/2)
810810   MCFG_CPU_PROGRAM_MAP(ps3v1_map)
811   MCFG_CPU_VBLANK_INT("screen", psikyosh_interrupt)
811   MCFG_CPU_VBLANK_INT_DRIVER("screen", psikyosh_state, psikyosh_interrupt)
812812
813813
814814   MCFG_EEPROM_ADD("eeprom", eeprom_interface_93C56)
trunk/src/mame/drivers/astinvad.c
r17996r17997
625625   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK)        /* a guess */
626626   MCFG_CPU_PROGRAM_MAP(spaceint_map)
627627   MCFG_CPU_IO_MAP(spaceint_portmap)
628   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
628   MCFG_CPU_VBLANK_INT_DRIVER("screen", astinvad_state, irq0_line_hold)
629629
630630   MCFG_MACHINE_START_OVERRIDE(astinvad_state,spaceint)
631631   MCFG_MACHINE_RESET_OVERRIDE(astinvad_state,spaceint)
trunk/src/mame/drivers/supertnk.c
r17996r17997
126126   virtual void machine_reset();
127127   virtual void video_start();
128128   UINT32 screen_update_supertnk(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
129   INTERRUPT_GEN_MEMBER(supertnk_interrupt);
129130};
130131
131132
r17996r17997
167168 *
168169 *************************************/
169170
170static INTERRUPT_GEN( supertnk_interrupt )
171INTERRUPT_GEN_MEMBER(supertnk_state::supertnk_interrupt)
171172{
172173   /* On a TMS9980, a 6 on the interrupt bus means a level 4 interrupt */
173   device->execute().set_input_line_and_vector(0, ASSERT_LINE, 6);
174   device.execute().set_input_line_and_vector(0, ASSERT_LINE, 6);
174175}
175176
176177
r17996r17997
429430   MCFG_CPU_ADD("maincpu", TMS9980L, 2598750) /* ? to which frequency is the 20.79 Mhz crystal mapped down? */
430431   MCFG_CPU_PROGRAM_MAP(supertnk_map)
431432   MCFG_CPU_IO_MAP(supertnk_io_map)
432   MCFG_CPU_VBLANK_INT("screen", supertnk_interrupt)
433   MCFG_CPU_VBLANK_INT_DRIVER("screen", supertnk_state, supertnk_interrupt)
433434
434435
435436   /* video hardware */
trunk/src/mame/drivers/quizdna.c
r17996r17997
447447   MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 8.000 MHz */
448448   MCFG_CPU_PROGRAM_MAP(quizdna_map)
449449   MCFG_CPU_IO_MAP(quizdna_io_map)
450   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
450   MCFG_CPU_VBLANK_INT_DRIVER("screen", quizdna_state, irq0_line_hold)
451451
452452   /* video hardware */
453453   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/boogwing.c
r17996r17997
343343   /* basic machine hardware */
344344   MCFG_CPU_ADD("maincpu", M68000, 14000000)   /* DE102 */
345345   MCFG_CPU_PROGRAM_MAP(boogwing_map)
346   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
346   MCFG_CPU_VBLANK_INT_DRIVER("screen", boogwing_state, irq6_line_hold)
347347
348348   MCFG_CPU_ADD("audiocpu", H6280,32220000/4)
349349   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/esh.c
r17996r17997
5050   virtual void machine_start();
5151   virtual void palette_init();
5252   UINT32 screen_update_esh(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
53   INTERRUPT_GEN_MEMBER(vblank_callback_esh);
5354};
5455
5556
r17996r17997
283284   machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
284285}
285286
286static INTERRUPT_GEN( vblank_callback_esh )
287INTERRUPT_GEN_MEMBER(esh_state::vblank_callback_esh)
287288{
288289   // IRQ
289   device->execute().set_input_line(0, ASSERT_LINE);
290   device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq_stop));
290   device.execute().set_input_line(0, ASSERT_LINE);
291   machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq_stop));
291292}
292293
293294void esh_state::machine_start()
r17996r17997
302303   MCFG_CPU_ADD("maincpu", Z80, PCB_CLOCK/6)                  /* The denominator is a Daphne guess based on PacMan's hardware */
303304   MCFG_CPU_PROGRAM_MAP(z80_0_mem)
304305   MCFG_CPU_IO_MAP(z80_0_io)
305   MCFG_CPU_VBLANK_INT("screen", vblank_callback_esh)
306   MCFG_CPU_VBLANK_INT_DRIVER("screen", esh_state, vblank_callback_esh)
306307
307308   MCFG_NVRAM_ADD_0FILL("nvram")
308309
trunk/src/mame/drivers/fromance.c
r17996r17997
10041004   /* basic machine hardware */
10051005   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 Mhz ? */
10061006   MCFG_CPU_PROGRAM_MAP(nekkyoku_main_map)
1007   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1007   MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
10081008
10091009   MCFG_CPU_ADD("sub", Z80,12000000/2)      /* 6.00 Mhz ? */
10101010   MCFG_CPU_PROGRAM_MAP(nekkyoku_sub_map)
r17996r17997
10421042   /* basic machine hardware */
10431043   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 Mhz ? */
10441044   MCFG_CPU_PROGRAM_MAP(fromance_main_map)
1045   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1045   MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
10461046
10471047   MCFG_CPU_ADD("sub", Z80,12000000/2)      /* 6.00 Mhz ? */
10481048   MCFG_CPU_PROGRAM_MAP(fromance_sub_map)
r17996r17997
10801080   /* basic machine hardware */
10811081   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 Mhz ? */
10821082   MCFG_CPU_PROGRAM_MAP(fromance_main_map)
1083   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1083   MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
10841084
10851085   MCFG_CPU_ADD("sub", Z80,12000000/2)      /* 6.00 Mhz ? */
10861086   MCFG_CPU_PROGRAM_MAP(fromance_sub_map)
trunk/src/mame/drivers/skykid.c
r17996r17997
422422   0               /* stereo */
423423};
424424
425static INTERRUPT_GEN( main_vblank_irq )
425INTERRUPT_GEN_MEMBER(skykid_state::main_vblank_irq)
426426{
427   skykid_state *state = device->machine().driver_data<skykid_state>();
428427
429   if(state->m_main_irq_mask)
430      device->execute().set_input_line(0, ASSERT_LINE);
428   if(m_main_irq_mask)
429      device.execute().set_input_line(0, ASSERT_LINE);
431430}
432431
433432
434static INTERRUPT_GEN( mcu_vblank_irq )
433INTERRUPT_GEN_MEMBER(skykid_state::mcu_vblank_irq)
435434{
436   skykid_state *state = device->machine().driver_data<skykid_state>();
437435
438   if(state->m_mcu_irq_mask)
439      device->execute().set_input_line(0, ASSERT_LINE);
436   if(m_mcu_irq_mask)
437      device.execute().set_input_line(0, ASSERT_LINE);
440438}
441439
442440
r17996r17997
445443   /* basic machine hardware */
446444   MCFG_CPU_ADD("maincpu", M6809,49152000/32)
447445   MCFG_CPU_PROGRAM_MAP(skykid_map)
448   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
446   MCFG_CPU_VBLANK_INT_DRIVER("screen", skykid_state, main_vblank_irq)
449447
450448   MCFG_CPU_ADD("mcu", HD63701,49152000/8)   /* or compatible 6808 with extra instructions */
451449   MCFG_CPU_PROGRAM_MAP(mcu_map)
452450   MCFG_CPU_IO_MAP(mcu_port_map)
453   MCFG_CPU_VBLANK_INT("screen", mcu_vblank_irq)
451   MCFG_CPU_VBLANK_INT_DRIVER("screen", skykid_state, mcu_vblank_irq)
454452
455453   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* we need heavy synch */
456454
trunk/src/mame/drivers/halleys.c
r17996r17997
19631963
19641964   MCFG_CPU_ADD("audiocpu", Z80, XTAL_6MHz/2) /* verified on pcb */
19651965   MCFG_CPU_PROGRAM_MAP(sound_map)
1966   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)6000000/(4*16*16*10*16))
1966   MCFG_CPU_PERIODIC_INT_DRIVER(halleys_state, irq0_line_hold, (double)6000000/(4*16*16*10*16))
19671967
19681968
19691969   // video hardware
trunk/src/mame/drivers/djmain.c
r17996r17997
7474
7575
7676
77#define DISABLE_VB_INT   (!(state->m_v_ctrl & 0x8000))
77#define DISABLE_VB_INT   (!(m_v_ctrl & 0x8000))
7878
7979
8080
r17996r17997
396396 *
397397 *************************************/
398398
399static INTERRUPT_GEN( vb_interrupt )
399INTERRUPT_GEN_MEMBER(djmain_state::vb_interrupt)
400400{
401   djmain_state *state = device->machine().driver_data<djmain_state>();
402   state->m_pending_vb_int = 0;
401   m_pending_vb_int = 0;
403402
404403   if (DISABLE_VB_INT)
405404   {
406      state->m_pending_vb_int = 1;
405      m_pending_vb_int = 1;
407406      return;
408407   }
409408
410409   //logerror("V-Blank interrupt\n");
411   device->execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
410   device.execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
412411}
413412
414413
r17996r17997
14601459   //MCFG_CPU_ADD("maincpu", M68EC020, 18432000/2)    /*  9.216 MHz!? */
14611460   MCFG_CPU_ADD("maincpu", M68EC020, 32000000/4)   /*  8.000 MHz!? */
14621461   MCFG_CPU_PROGRAM_MAP(memory_map)
1463   MCFG_CPU_VBLANK_INT("screen", vb_interrupt)
1462   MCFG_CPU_VBLANK_INT_DRIVER("screen", djmain_state, vb_interrupt)
14641463
14651464
14661465   MCFG_IDE_CONTROLLER_ADD("ide", ide_intf, ide_devices, "hdd", NULL, true)
trunk/src/mame/drivers/mustache.c
r17996r17997
162162   machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
163163}
164164
165static INTERRUPT_GEN( assert_irq )
165INTERRUPT_GEN_MEMBER(mustache_state::assert_irq)
166166{
167   mustache_state *state = device->machine().driver_data<mustache_state>();
168   device->execute().set_input_line(0, ASSERT_LINE);
169    state->m_clear_irq_timer->adjust(downcast<cpu_device *>(device)->cycles_to_attotime(14288));
167   device.execute().set_input_line(0, ASSERT_LINE);
168    m_clear_irq_timer->adjust(downcast<cpu_device *>(&device)->cycles_to_attotime(14288));
170169       /* Timing here is an educated GUESS, Z80 /INT must stay high so the irq
171170          fires no less than TWICE per frame, else game doesn't work right.
172171      6000000 / 56.747 = 105732.4616 cycles per frame, we'll call it A
r17996r17997
188187   /* basic machine hardware */
189188   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
190189   MCFG_CPU_PROGRAM_MAP(memmap)
191   MCFG_CPU_VBLANK_INT("screen", assert_irq)
190   MCFG_CPU_VBLANK_INT_DRIVER("screen", mustache_state, assert_irq)
192191
193192   MCFG_CPU_ADD(CPUTAG_T5182,Z80, T5182_CLOCK)
194193   MCFG_CPU_PROGRAM_MAP(t5182_map)
trunk/src/mame/drivers/snookr10.c
r17996r17997
690690    /* basic machine hardware */
691691   MCFG_CPU_ADD("maincpu", M65SC02, MASTER_CLOCK/8)   /* 2 MHz (1.999 MHz measured) */
692692   MCFG_CPU_PROGRAM_MAP(snookr10_map)
693   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
693   MCFG_CPU_VBLANK_INT_DRIVER("screen", snookr10_state, nmi_line_pulse)
694694
695695   MCFG_NVRAM_ADD_0FILL("nvram")
696696
trunk/src/mame/drivers/statriv2.c
r17996r17997
110110   virtual void palette_init();
111111   DECLARE_VIDEO_START(vertical);
112112   UINT32 screen_update_statriv2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
113   INTERRUPT_GEN_MEMBER(statriv2_interrupt);
113114};
114115
115116
r17996r17997
209210 *
210211 *************************************/
211212
212static INTERRUPT_GEN( statriv2_interrupt )
213INTERRUPT_GEN_MEMBER(statriv2_state::statriv2_interrupt)
213214{
214   statriv2_state *state = device->machine().driver_data<statriv2_state>();
215   UINT8 new_coin = state->ioport("COIN")->read();
215   UINT8 new_coin = ioport("COIN")->read();
216216
217217   /* check the coin inputs once per frame */
218   state->m_latched_coin |= new_coin & (new_coin ^ state->m_last_coin);
219   state->m_last_coin = new_coin;
218   m_latched_coin |= new_coin & (new_coin ^ m_last_coin);
219   m_last_coin = new_coin;
220220
221   device->execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
222   device->execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
221   device.execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
222   device.execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
223223}
224224
225225
r17996r17997
602602    MCFG_CPU_ADD("maincpu", I8085A, MASTER_CLOCK)
603603   MCFG_CPU_PROGRAM_MAP(statriv2_map)
604604   MCFG_CPU_IO_MAP(statriv2_io_map)
605   MCFG_CPU_VBLANK_INT("screen", statriv2_interrupt)
605   MCFG_CPU_VBLANK_INT_DRIVER("screen", statriv2_state, statriv2_interrupt)
606606
607607   MCFG_NVRAM_ADD_0FILL("nvram")
608608
trunk/src/mame/drivers/carrera.c
r17996r17997
330330   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK / 6)
331331   MCFG_CPU_PROGRAM_MAP(carrera_map)
332332   MCFG_CPU_IO_MAP(io_map)
333   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
333   MCFG_CPU_VBLANK_INT_DRIVER("screen", carrera_state, nmi_line_pulse)
334334
335335   /* video hardware */
336336   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ultraman.c
r17996r17997
218218   /* basic machine hardware */
219219   MCFG_CPU_ADD("maincpu", M68000,24000000/2)      /* 12 MHz? */
220220   MCFG_CPU_PROGRAM_MAP(main_map)
221   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
221   MCFG_CPU_VBLANK_INT_DRIVER("screen", ultraman_state, irq4_line_hold)
222222
223223   MCFG_CPU_ADD("audiocpu", Z80,24000000/6)   /* 4 MHz? */
224224   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/d9final.c
r17996r17997
284284   MCFG_CPU_ADD("maincpu", Z80, 24000000/4)/* ? MHz */
285285   MCFG_CPU_PROGRAM_MAP(d9final_map)
286286   MCFG_CPU_IO_MAP(d9final_io)
287   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
287   MCFG_CPU_VBLANK_INT_DRIVER("screen", d9final_state, irq0_line_hold)
288288
289289
290290   /* video hardware */
trunk/src/mame/drivers/ladybug.c
r17996r17997
814814   /* basic machine hardware */
815815   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz */
816816   MCFG_CPU_PROGRAM_MAP(sraider_cpu1_map)
817   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
817   MCFG_CPU_VBLANK_INT_DRIVER("screen", ladybug_state, irq0_line_hold)
818818
819819   MCFG_CPU_ADD("sub", Z80, 4000000)   /* 4 MHz */
820820   MCFG_CPU_PROGRAM_MAP(sraider_cpu2_map)
821821   MCFG_CPU_IO_MAP(sraider_cpu2_io_map)
822   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
822   MCFG_CPU_VBLANK_INT_DRIVER("screen", ladybug_state, irq0_line_hold)
823823
824824   MCFG_MACHINE_START_OVERRIDE(ladybug_state,sraider)
825825   MCFG_MACHINE_RESET_OVERRIDE(ladybug_state,sraider)
trunk/src/mame/drivers/blueprnt.c
r17996r17997
296296   /* basic machine hardware */
297297   MCFG_CPU_ADD("maincpu", Z80, 7000000/2)   // 3.5 MHz
298298   MCFG_CPU_PROGRAM_MAP(blueprnt_map)
299   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
299   MCFG_CPU_VBLANK_INT_DRIVER("screen", blueprnt_state, irq0_line_hold)
300300
301301   MCFG_CPU_ADD("audiocpu", Z80, 10000000/2/2/2)   // 1.25 MHz (2H)
302302   MCFG_CPU_PROGRAM_MAP(sound_map)
303   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)   // IRQs connected to 32V
303   MCFG_CPU_PERIODIC_INT_DRIVER(blueprnt_state, irq0_line_hold, 4*60)   // IRQs connected to 32V
304304                           // NMIs are caused by the main CPU
305305
306306
trunk/src/mame/drivers/ttchamp.c
r17996r17997
8585
8686   virtual void video_start();
8787   UINT32 screen_update_ttchamp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
88   INTERRUPT_GEN_MEMBER(ttchamp_irq);
8889};
8990
9091
r17996r17997
269270INPUT_PORTS_END
270271
271272
272static INTERRUPT_GEN( ttchamp_irq ) /* right? */
273INTERRUPT_GEN_MEMBER(ttchamp_state::ttchamp_irq)/* right? */
273274{
274   device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
275   device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
275276}
276277
277278static MACHINE_CONFIG_START( ttchamp, ttchamp_state )
r17996r17997
279280   MCFG_CPU_ADD("maincpu", V30, 8000000)
280281   MCFG_CPU_PROGRAM_MAP(ttchamp_map)
281282   MCFG_CPU_IO_MAP(ttchamp_io)
282   MCFG_CPU_VBLANK_INT("screen", ttchamp_irq)
283   MCFG_CPU_VBLANK_INT_DRIVER("screen", ttchamp_state, ttchamp_irq)
283284
284285   /* video hardware */
285286   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/buggychl.c
r17996r17997
394394   /* basic machine hardware */
395395   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz??? */
396396   MCFG_CPU_PROGRAM_MAP(buggychl_map)
397   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
397   MCFG_CPU_VBLANK_INT_DRIVER("screen", buggychl_state, irq0_line_hold)
398398
399399   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz??? */
400400   MCFG_CPU_PROGRAM_MAP(sound_map)
401   MCFG_CPU_PERIODIC_INT(irq0_line_hold,60*60)   /* irq is timed, tied to the cpu clock and not to vblank */
401   MCFG_CPU_PERIODIC_INT_DRIVER(buggychl_state, irq0_line_hold, 60*60)   /* irq is timed, tied to the cpu clock and not to vblank */
402402                     /* nmi is caused by the main cpu */
403403
404404   MCFG_CPU_ADD("mcu", M68705,8000000/2)  /* 4 MHz */
trunk/src/mame/drivers/starshp1.c
r17996r17997
1414
1515
1616
17static INTERRUPT_GEN( starshp1_interrupt )
17INTERRUPT_GEN_MEMBER(starshp1_state::starshp1_interrupt)
1818{
19   if ((device->machine().root_device().ioport("SYSTEM")->read() & 0x90) != 0x90)
20      generic_pulse_irq_line(device, 0, 1);
19   if ((machine().root_device().ioport("SYSTEM")->read() & 0x90) != 0x90)
20      generic_pulse_irq_line(device.execute(), 0, 1);
2121}
2222
2323
r17996r17997
299299
300300   MCFG_CPU_ADD("maincpu", M6502, STARSHP1_CPU_CLOCK)
301301   MCFG_CPU_PROGRAM_MAP(starshp1_map)
302   MCFG_CPU_VBLANK_INT("screen", starshp1_interrupt)
302   MCFG_CPU_VBLANK_INT_DRIVER("screen", starshp1_state, starshp1_interrupt)
303303
304304   /* video hardware */
305305
trunk/src/mame/drivers/gotcha.c
r17996r17997
278278   /* basic machine hardware */
279279   MCFG_CPU_ADD("maincpu", M68000,14318180)   /* 14.31818 MHz */
280280   MCFG_CPU_PROGRAM_MAP(gotcha_map)
281   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
281   MCFG_CPU_VBLANK_INT_DRIVER("screen", gotcha_state, irq6_line_hold)
282282
283283   MCFG_CPU_ADD("audiocpu", Z80,6000000)   /* 6 MHz */
284284   MCFG_CPU_PROGRAM_MAP(sound_map)
285//  MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
285   MCFG_CPU_VBLANK_INT_DRIVER("screen", gotcha_state, nmi_line_pulse)
286286
287287
288288   /* video hardware */
trunk/src/mame/drivers/taito_f2.c
r17996r17997
578578   state->m_maincpu->set_input_line(6, HOLD_LINE);
579579}
580580
581static INTERRUPT_GEN( taitof2_interrupt )
581INTERRUPT_GEN_MEMBER(taitof2_state::taitof2_interrupt)
582582{
583   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(500), FUNC(taitof2_interrupt6));
584   device->execute().set_input_line(5, HOLD_LINE);
583   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(500), FUNC(taitof2_interrupt6));
584   device.execute().set_input_line(5, HOLD_LINE);
585585}
586586
587587
r17996r17997
30403040
30413041   /* basic machine hardware */
30423042   MCFG_CPU_ADD("maincpu", M68000, 24000000/2)   /* 12 MHz */
3043   MCFG_CPU_VBLANK_INT("screen", taitof2_interrupt)
3043   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitof2_state, taitof2_interrupt)
30443044
30453045   MCFG_CPU_ADD("audiocpu", Z80, 24000000/6)   /* 4 MHz */
30463046   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
35983598   /* basic machine hardware */
35993599   MCFG_CPU_ADD("maincpu", M68000,24000000/2)   /* verified on pcb  */
36003600   MCFG_CPU_PROGRAM_MAP(cameltry_map)
3601   MCFG_CPU_VBLANK_INT("screen", taitof2_interrupt)
3601   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitof2_state, taitof2_interrupt)
36023602
36033603   MCFG_CPU_ADD("audiocpu", Z80,24000000/4)   /* verifed on pcb */
36043604   MCFG_CPU_PROGRAM_MAP(cameltrya_sound_map)
r17996r17997
36473647   /* basic machine hardware */
36483648   MCFG_CPU_ADD("maincpu", M68000,24000000/2)   /* 12 MHz */
36493649   MCFG_CPU_PROGRAM_MAP(driveout_map)
3650   MCFG_CPU_VBLANK_INT("screen", taitof2_interrupt)
3650   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitof2_state, taitof2_interrupt)
36513651
36523652   MCFG_CPU_ADD("audiocpu", Z80,24000000/6)   /* 4 MHz */
36533653   MCFG_CPU_PROGRAM_MAP(driveout_sound_map)
trunk/src/mame/drivers/pandoras.c
r17996r17997
3535#define SOUND_CLOCK         XTAL_14_31818MHz
3636
3737
38static INTERRUPT_GEN( pandoras_master_interrupt )
38INTERRUPT_GEN_MEMBER(pandoras_state::pandoras_master_interrupt)
3939{
40   pandoras_state *state = device->machine().driver_data<pandoras_state>();
4140
42   if (state->m_irq_enable_a)
43      device->execute().set_input_line(M6809_IRQ_LINE, HOLD_LINE);
41   if (m_irq_enable_a)
42      device.execute().set_input_line(M6809_IRQ_LINE, HOLD_LINE);
4443}
4544
46static INTERRUPT_GEN( pandoras_slave_interrupt )
45INTERRUPT_GEN_MEMBER(pandoras_state::pandoras_slave_interrupt)
4746{
48   pandoras_state *state = device->machine().driver_data<pandoras_state>();
4947
50   if (state->m_irq_enable_b)
51      device->execute().set_input_line(M6809_IRQ_LINE, HOLD_LINE);
48   if (m_irq_enable_b)
49      device.execute().set_input_line(M6809_IRQ_LINE, HOLD_LINE);
5250}
5351
5452WRITE8_MEMBER(pandoras_state::pandoras_int_control_w)
r17996r17997
344342   /* basic machine hardware */
345343   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/6)   /* CPU A */
346344   MCFG_CPU_PROGRAM_MAP(pandoras_master_map)
347   MCFG_CPU_VBLANK_INT("screen", pandoras_master_interrupt)
345   MCFG_CPU_VBLANK_INT_DRIVER("screen", pandoras_state, pandoras_master_interrupt)
348346
349347   MCFG_CPU_ADD("sub", M6809, MASTER_CLOCK/6)      /* CPU B */
350348   MCFG_CPU_PROGRAM_MAP(pandoras_slave_map)
351   MCFG_CPU_VBLANK_INT("screen", pandoras_slave_interrupt)
349   MCFG_CPU_VBLANK_INT_DRIVER("screen", pandoras_state, pandoras_slave_interrupt)
352350
353351   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/8)
354352   MCFG_CPU_PROGRAM_MAP(pandoras_sound_map)
trunk/src/mame/drivers/gottlieb.c
r17996r17997
657657}
658658
659659
660static INTERRUPT_GEN( gottlieb_interrupt )
660INTERRUPT_GEN_MEMBER(gottlieb_state::gottlieb_interrupt)
661661{
662   gottlieb_state *state = device->machine().driver_data<gottlieb_state>();
663662   /* assert the NMI and set a timer to clear it at the first visible line */
664   device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
665   device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_pos(0), FUNC(nmi_clear));
663   device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
664   machine().scheduler().timer_set(machine().primary_screen->time_until_pos(0), FUNC(nmi_clear));
666665
667666   /* if we have a laserdisc, update it */
668   if (state->m_laserdisc != NULL)
667   if (m_laserdisc != NULL)
669668   {
670669      /* set the "disc ready" bit, which basically indicates whether or not we have a proper video frame */
671      if (!state->m_laserdisc->video_active())
672         state->m_laserdisc_status &= ~0x20;
670      if (!m_laserdisc->video_active())
671         m_laserdisc_status &= ~0x20;
673672      else
674         state->m_laserdisc_status |= 0x20;
673         m_laserdisc_status |= 0x20;
675674   }
676675}
677676
r17996r17997
17111710   /* basic machine hardware */
17121711   MCFG_CPU_ADD("maincpu", I8088, CPU_CLOCK/3)
17131712   MCFG_CPU_PROGRAM_MAP(gottlieb_map)
1714   MCFG_CPU_VBLANK_INT("screen", gottlieb_interrupt)
1713   MCFG_CPU_VBLANK_INT_DRIVER("screen", gottlieb_state, gottlieb_interrupt)
17151714
17161715   MCFG_NVRAM_ADD_1FILL("nvram")
17171716   MCFG_WATCHDOG_VBLANK_INIT(16)
trunk/src/mame/drivers/psattack.c
r17996r17997
9292   virtual void video_start();
9393   UINT32 screen_update_psattack(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
9494   void screen_eof_psattack(screen_device &screen, bool state);
95   INTERRUPT_GEN_MEMBER(psattack_interrupt);
9596};
9697
9798
r17996r17997
136137
137138}
138139
139static INTERRUPT_GEN(psattack_interrupt)
140INTERRUPT_GEN_MEMBER(psattack_state::psattack_interrupt)
140141{
141142
142143}
r17996r17997
178179static MACHINE_CONFIG_START( psattack, psattack_state )
179180   MCFG_CPU_ADD("maincpu", SE3208, 43000000)
180181   MCFG_CPU_PROGRAM_MAP(psattack_mem)
181   MCFG_CPU_VBLANK_INT("screen", psattack_interrupt)
182   MCFG_CPU_VBLANK_INT_DRIVER("screen", psattack_state, psattack_interrupt)
182183
183184
184185   //MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/asterix.c
r17996r17997
5353   }
5454}
5555
56static INTERRUPT_GEN( asterix_interrupt )
56INTERRUPT_GEN_MEMBER(asterix_state::asterix_interrupt)
5757{
58   asterix_state *state = device->machine().driver_data<asterix_state>();
5958
6059   // global interrupt masking
61   if (!k056832_is_irq_enabled(state->m_k056832, 0))
60   if (!k056832_is_irq_enabled(m_k056832, 0))
6261      return;
6362
64   device->execute().set_input_line(5, HOLD_LINE); /* ??? All irqs have the same vector, and the mask used is 0 or 7 */
63   device.execute().set_input_line(5, HOLD_LINE); /* ??? All irqs have the same vector, and the mask used is 0 or 7 */
6564}
6665
6766READ8_MEMBER(asterix_state::asterix_sound_r)
r17996r17997
291290   /* basic machine hardware */
292291   MCFG_CPU_ADD("maincpu", M68000, 12000000)
293292   MCFG_CPU_PROGRAM_MAP(main_map)
294   MCFG_CPU_VBLANK_INT("screen", asterix_interrupt)
293   MCFG_CPU_VBLANK_INT_DRIVER("screen", asterix_state, asterix_interrupt)
295294
296295   MCFG_CPU_ADD("audiocpu", Z80, 8000000)
297296   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/ppmast93.c
r17996r17997
366366   MCFG_CPU_ADD("maincpu", Z80,5000000)       /* 5 MHz */
367367   MCFG_CPU_PROGRAM_MAP(ppmast93_cpu1_map)
368368   MCFG_CPU_IO_MAP(ppmast93_cpu1_io)
369   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
369   MCFG_CPU_VBLANK_INT_DRIVER("screen", ppmast93_state, irq0_line_hold)
370370
371371   MCFG_CPU_ADD("sub", Z80,5000000)       /* 5 MHz */
372372   MCFG_CPU_PROGRAM_MAP(ppmast93_cpu2_map)
373373   MCFG_CPU_IO_MAP(ppmast93_cpu2_io)
374   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
374   MCFG_CPU_PERIODIC_INT_DRIVER(ppmast93_state, irq0_line_hold, 8000)
375375
376376   /* video hardware */
377377   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/goldnpkr.c
r17996r17997
35743574   /* basic machine hardware */
35753575   MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK)
35763576   MCFG_CPU_PROGRAM_MAP(goldnpkr_map)
3577   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
3577   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldnpkr_state, nmi_line_pulse)
35783578
35793579   MCFG_NVRAM_ADD_0FILL("nvram")
35803580
trunk/src/mame/drivers/xxmissio.c
r17996r17997
6363   }
6464}
6565
66static INTERRUPT_GEN( xxmissio_interrupt_m )
66INTERRUPT_GEN_MEMBER(xxmissio_state::xxmissio_interrupt_m)
6767{
68   xxmissio_state *state = device->machine().driver_data<xxmissio_state>();
69   state->m_status &= ~0x20;
70   device->execute().set_input_line(0, HOLD_LINE);
68   m_status &= ~0x20;
69   device.execute().set_input_line(0, HOLD_LINE);
7170}
7271
73static INTERRUPT_GEN( xxmissio_interrupt_s )
72INTERRUPT_GEN_MEMBER(xxmissio_state::xxmissio_interrupt_s)
7473{
75   xxmissio_state *state = device->machine().driver_data<xxmissio_state>();
76   state->m_status &= ~0x10;
77   device->execute().set_input_line(0, HOLD_LINE);
74   m_status &= ~0x10;
75   device.execute().set_input_line(0, HOLD_LINE);
7876}
7977
8078void xxmissio_state::machine_start()
r17996r17997
286284   /* basic machine hardware */
287285   MCFG_CPU_ADD("maincpu", Z80,12000000/4)   /* 3.0MHz */
288286   MCFG_CPU_PROGRAM_MAP(map1)
289   MCFG_CPU_VBLANK_INT("screen", xxmissio_interrupt_m)
287   MCFG_CPU_VBLANK_INT_DRIVER("screen", xxmissio_state, xxmissio_interrupt_m)
290288
291289   MCFG_CPU_ADD("sub", Z80,12000000/4)   /* 3.0MHz */
292290   MCFG_CPU_PROGRAM_MAP(map2)
293   MCFG_CPU_PERIODIC_INT(xxmissio_interrupt_s,2*60)
291   MCFG_CPU_PERIODIC_INT_DRIVER(xxmissio_state, xxmissio_interrupt_s, 2*60)
294292
295293   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
296294
trunk/src/mame/drivers/moo.c
r17996r17997
125125      state->m_maincpu->set_input_line(4, HOLD_LINE);
126126}
127127
128static INTERRUPT_GEN( moo_interrupt )
128INTERRUPT_GEN_MEMBER(moo_state::moo_interrupt)
129129{
130   moo_state *state = device->machine().driver_data<moo_state>();
131   if (k053246_is_irq_enabled(state->m_k053246))
130   if (k053246_is_irq_enabled(m_k053246))
132131   {
133      moo_objdma(device->machine(), state->m_game_type);
132      moo_objdma(machine(), m_game_type);
134133
135134      // schedule DMA end interrupt (delay shortened to catch up with V-blank)
136        state->m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
135        m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
137136   }
138137
139138   // trigger V-blank interrupt
140   if (state->m_cur_control2 & 0x20)
141      device->execute().set_input_line(5, HOLD_LINE);
139   if (m_cur_control2 & 0x20)
140      device.execute().set_input_line(5, HOLD_LINE);
142141}
143142
144static INTERRUPT_GEN( moobl_interrupt )
143INTERRUPT_GEN_MEMBER(moo_state::moobl_interrupt)
145144{
146   moo_state *state = device->machine().driver_data<moo_state>();
147   moo_objdma(device->machine(), state->m_game_type);
145   moo_objdma(machine(), m_game_type);
148146
149147   // schedule DMA end interrupt (delay shortened to catch up with V-blank)
150    state->m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
148    m_dmaend_timer->adjust(attotime::from_usec(MOO_DMADELAY));
151149
152150   // trigger V-blank interrupt
153   device->execute().set_input_line(5, HOLD_LINE);
151   device.execute().set_input_line(5, HOLD_LINE);
154152}
155153
156154WRITE16_MEMBER(moo_state::sound_cmd1_w)
r17996r17997
515513   /* basic machine hardware */
516514   MCFG_CPU_ADD("maincpu", M68000, 16000000)
517515   MCFG_CPU_PROGRAM_MAP(moo_map)
518   MCFG_CPU_VBLANK_INT("screen", moo_interrupt)
516   MCFG_CPU_VBLANK_INT_DRIVER("screen", moo_state, moo_interrupt)
519517
520518   MCFG_CPU_ADD("soundcpu", Z80, 8000000)
521519   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
563561   /* basic machine hardware */
564562   MCFG_CPU_ADD("maincpu", M68000, 16100000)
565563   MCFG_CPU_PROGRAM_MAP(moobl_map)
566   MCFG_CPU_VBLANK_INT("screen", moobl_interrupt)
564   MCFG_CPU_VBLANK_INT_DRIVER("screen", moo_state, moobl_interrupt)
567565
568566   MCFG_MACHINE_START_OVERRIDE(moo_state,moo)
569567   MCFG_MACHINE_RESET_OVERRIDE(moo_state,moo)
trunk/src/mame/drivers/taito_l.c
r17996r17997
18511851
18521852   MCFG_CPU_ADD("slave", Z80, XTAL_12MHz/3)      /* verified on pcb */
18531853   MCFG_CPU_PROGRAM_MAP(fhawk_2_map)
1854   MCFG_CPU_PERIODIC_INT(irq0_line_hold,3*60) /* fixes slow down problems */
1854   MCFG_CPU_PERIODIC_INT_DRIVER(taitol_state, irq0_line_hold, 3*60) /* fixes slow down problems */
18551855
18561856   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
18571857
r17996r17997
19431943
19441944   MCFG_CPU_ADD("audiocpu",  Z80, XTAL_12MHz/3)      /* verified on pcb */
19451945   MCFG_CPU_PROGRAM_MAP(kurikint_2_map)
1946   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1946   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitol_state, irq0_line_hold)
19471947
19481948   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
19491949
r17996r17997
20812081
20822082   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/3)      /* not verified */
20832083   MCFG_CPU_PROGRAM_MAP(evilston_2_map)
2084   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
2085   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,60)
2084   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitol_state,  irq0_line_hold)
2085   MCFG_CPU_PERIODIC_INT_DRIVER(taitol_state, nmi_line_pulse, 60)
20862086
20872087   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
20882088
trunk/src/mame/drivers/groundfx.c
r17996r17997
354354   0      /* col_base */
355355};
356356
357static INTERRUPT_GEN( groundfx_interrupt )
357INTERRUPT_GEN_MEMBER(groundfx_state::groundfx_interrupt)
358358{
359   groundfx_state *state = device->machine().driver_data<groundfx_state>();
360   state->m_frame_counter^=1;
361   device->execute().set_input_line(4, HOLD_LINE);
359   m_frame_counter^=1;
360   device.execute().set_input_line(4, HOLD_LINE);
362361}
363362
364363static MACHINE_CONFIG_START( groundfx, groundfx_state )
r17996r17997
366365   /* basic machine hardware */
367366   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)   /* 16 MHz */
368367   MCFG_CPU_PROGRAM_MAP(groundfx_map)
369   MCFG_CPU_VBLANK_INT("screen", groundfx_interrupt)
368   MCFG_CPU_VBLANK_INT_DRIVER("screen", groundfx_state, groundfx_interrupt)
370369
371370   MCFG_EEPROM_ADD("eeprom", groundfx_eeprom_interface)
372371
trunk/src/mame/drivers/segald.c
r17996r17997
373373   MCFG_CPU_ADD("maincpu", Z80, SCHEMATIC_CLOCK/4)
374374   MCFG_CPU_PROGRAM_MAP(mainmem)
375375   MCFG_CPU_IO_MAP(mainport)
376   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 1000.0/59.94)
376   MCFG_CPU_PERIODIC_INT_DRIVER(segald_state, nmi_line_pulse, 1000.0/59.94)
377377
378378
379379   MCFG_LASERDISC_LDV1000_ADD("laserdisc")
trunk/src/mame/drivers/srmp5.c
r17996r17997
559559   MCFG_CPU_ADD("maincpu",Z80,8000000)
560560   MCFG_CPU_PROGRAM_MAP(st0016_mem)
561561   MCFG_CPU_IO_MAP(st0016_io)
562   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
562   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp5_state, irq0_line_hold)
563563
564564   MCFG_CPU_ADD("sub", R3000LE, 25000000)
565565   MCFG_CPU_CONFIG(r3000_config)
566566   MCFG_CPU_PROGRAM_MAP(srmp5_mem)
567   MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
567   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp5_state, irq4_line_assert)
568568
569569   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
570570
trunk/src/mame/drivers/suprloco.c
r17996r17997
171171   /* basic machine hardware */
172172   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz (?) */
173173   MCFG_CPU_PROGRAM_MAP(main_map)
174   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
174   MCFG_CPU_VBLANK_INT_DRIVER("screen", suprloco_state, irq0_line_hold)
175175
176176   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
177177   MCFG_CPU_PROGRAM_MAP(sound_map)
178   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)         /* NMIs are caused by the main CPU */
178   MCFG_CPU_PERIODIC_INT_DRIVER(suprloco_state, irq0_line_hold, 4*60)         /* NMIs are caused by the main CPU */
179179
180180   /* video hardware */
181181   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/m58.c
r17996r17997
193193   /* basic machine hardware */
194194   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/3/2)
195195   MCFG_CPU_PROGRAM_MAP(yard_map)
196   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
196   MCFG_CPU_VBLANK_INT_DRIVER("screen", m58_state, irq0_line_hold)
197197
198198   /* video hardware */
199199   MCFG_GFXDECODE(yard)
trunk/src/mame/drivers/destroyr.c
r17996r17997
452452   /* basic machine hardware */
453453   MCFG_CPU_ADD("maincpu", M6800, XTAL_12_096MHz / 16)
454454   MCFG_CPU_PROGRAM_MAP(destroyr_map)
455   MCFG_CPU_PERIODIC_INT(irq0_line_assert, 4*60)
455   MCFG_CPU_PERIODIC_INT_DRIVER(destroyr_state, irq0_line_assert, 4*60)
456456
457457
458458   /* video hardware */
trunk/src/mame/drivers/feversoc.c
r17996r17997
7979   DECLARE_DRIVER_INIT(feversoc);
8080   virtual void video_start();
8181   UINT32 screen_update_feversoc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
82   INTERRUPT_GEN_MEMBER(feversoc_irq);
8283};
8384
8485
r17996r17997
246247   PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED )
247248INPUT_PORTS_END
248249
249static INTERRUPT_GEN( feversoc_irq )
250INTERRUPT_GEN_MEMBER(feversoc_state::feversoc_irq)
250251{
251   device->machine().device("maincpu")->execute().set_input_line(8, HOLD_LINE );
252   machine().device("maincpu")->execute().set_input_line(8, HOLD_LINE );
252253}
253254
254255static MACHINE_CONFIG_START( feversoc, feversoc_state )
r17996r17997
256257   /* basic machine hardware */
257258   MCFG_CPU_ADD("maincpu",SH2,MASTER_CLOCK)
258259   MCFG_CPU_PROGRAM_MAP(feversoc_map)
259   MCFG_CPU_VBLANK_INT("screen",feversoc_irq)
260   MCFG_CPU_VBLANK_INT_DRIVER("screen", feversoc_state, feversoc_irq)
260261
261262   /* video hardware */
262263   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/segajw.c
r17996r17997
9191   /* basic machine hardware */
9292   MCFG_CPU_ADD("maincpu",M68000,8000000) // unknown clock
9393   MCFG_CPU_PROGRAM_MAP(segajw_map)
94   MCFG_CPU_VBLANK_INT("screen",irq4_line_hold)
94   MCFG_CPU_VBLANK_INT_DRIVER("screen", segajw_state, irq4_line_hold)
9595
9696   /* video hardware */
9797   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/vulgus.c
r17996r17997
4747#include "includes/vulgus.h"
4848
4949
50static INTERRUPT_GEN( vulgus_vblank_irq )
50INTERRUPT_GEN_MEMBER(vulgus_state::vulgus_vblank_irq)
5151{
52   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   /* RST 10h - vblank */
52   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7);   /* RST 10h - vblank */
5353}
5454
5555static ADDRESS_MAP_START( main_map, AS_PROGRAM, 8, vulgus_state )
r17996r17997
213213   /* basic machine hardware */
214214   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/4)   /* 3 MHz */
215215   MCFG_CPU_PROGRAM_MAP(main_map)
216   MCFG_CPU_VBLANK_INT("screen",vulgus_vblank_irq)
216   MCFG_CPU_VBLANK_INT_DRIVER("screen", vulgus_state, vulgus_vblank_irq)
217217
218218   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4)   /* 3 MHz */
219219   MCFG_CPU_PROGRAM_MAP(sound_map)
220   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*60)
220   MCFG_CPU_PERIODIC_INT_DRIVER(vulgus_state, irq0_line_hold, 8*60)
221221
222222   /* video hardware */
223223   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/sderby.c
r17996r17997
497497
498498   MCFG_CPU_ADD("maincpu", M68000, 12000000)
499499   MCFG_CPU_PROGRAM_MAP(sderby_map)
500   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
500   MCFG_CPU_VBLANK_INT_DRIVER("screen", sderby_state, irq2_line_hold)
501501
502502   MCFG_NVRAM_ADD_0FILL("nvram")
503503
r17996r17997
520520
521521   MCFG_CPU_ADD("maincpu", M68000, 12000000)
522522   MCFG_CPU_PROGRAM_MAP(luckboom_map)
523   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
523   MCFG_CPU_VBLANK_INT_DRIVER("screen", sderby_state, irq4_line_hold)
524524
525525   MCFG_NVRAM_ADD_0FILL("nvram")
526526
r17996r17997
543543
544544   MCFG_CPU_ADD("maincpu", M68000, 12000000)
545545   MCFG_CPU_PROGRAM_MAP(spacewin_map)
546   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
546   MCFG_CPU_VBLANK_INT_DRIVER("screen", sderby_state, irq2_line_hold)
547547
548548   MCFG_NVRAM_ADD_0FILL("nvram")
549549
r17996r17997
566566
567567   MCFG_CPU_ADD("maincpu", M68000, 12000000)
568568   MCFG_CPU_PROGRAM_MAP(roulette_map)
569   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
569   MCFG_CPU_VBLANK_INT_DRIVER("screen", sderby_state, irq2_line_hold)
570570
571571   MCFG_NVRAM_ADD_0FILL("nvram")
572572
trunk/src/mame/drivers/vcombat.c
r17996r17997
582582static MACHINE_CONFIG_START( vcombat, vcombat_state )
583583   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)
584584   MCFG_CPU_PROGRAM_MAP(main_map)
585   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
585   MCFG_CPU_VBLANK_INT_DRIVER("screen", vcombat_state, irq1_line_assert)
586586
587587   /* The middle board i860 */
588588   MCFG_CPU_ADD("vid_0", I860, XTAL_20MHz)
r17996r17997
595595   /* Sound CPU */
596596   MCFG_CPU_ADD("soundcpu", M68000, XTAL_12MHz)
597597   MCFG_CPU_PROGRAM_MAP(sound_map)
598   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 15000)   /* Remove this if MC6845 is enabled */
598   MCFG_CPU_PERIODIC_INT_DRIVER(vcombat_state, irq1_line_hold, 15000)   /* Remove this if MC6845 is enabled */
599599
600600   MCFG_NVRAM_ADD_0FILL("nvram")
601601   MCFG_MACHINE_RESET_OVERRIDE(vcombat_state,vcombat)
r17996r17997
630630static MACHINE_CONFIG_START( shadfgtr, vcombat_state )
631631   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)
632632   MCFG_CPU_PROGRAM_MAP(main_map)
633   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
633   MCFG_CPU_VBLANK_INT_DRIVER("screen", vcombat_state, irq1_line_assert)
634634
635635   /* The middle board i860 */
636636   MCFG_CPU_ADD("vid_0", I860, XTAL_20MHz)
trunk/src/mame/drivers/shangha3.c
r17996r17997
471471   /* basic machine hardware */
472472   MCFG_CPU_ADD("maincpu", M68000, 8000000)
473473   MCFG_CPU_PROGRAM_MAP(shangha3_map)
474   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
474   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangha3_state, irq4_line_hold)
475475
476476   /* video hardware */
477477   MCFG_VIDEO_ATTRIBUTES(VIDEO_HAS_SHADOWS)
r17996r17997
504504   /* basic machine hardware */
505505   MCFG_CPU_ADD("maincpu", M68000, 8000000)
506506   MCFG_CPU_PROGRAM_MAP(heberpop_map)
507   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
507   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangha3_state, irq4_line_hold)
508508
509509   MCFG_CPU_ADD("audiocpu", Z80, 6000000)   /* 6 MHz ??? */
510510   MCFG_CPU_PROGRAM_MAP(heberpop_sound_map)
r17996r17997
542542   /* basic machine hardware */
543543   MCFG_CPU_ADD("maincpu", M68000, 8000000)
544544   MCFG_CPU_PROGRAM_MAP(blocken_map)
545   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
545   MCFG_CPU_VBLANK_INT_DRIVER("screen", shangha3_state, irq4_line_hold)
546546
547547   MCFG_CPU_ADD("audiocpu", Z80, 6000000)   /* 6 MHz ??? */
548548   MCFG_CPU_PROGRAM_MAP(heberpop_sound_map)
trunk/src/mame/drivers/pkscram.c
r17996r17997
303303   /* basic machine hardware */
304304   MCFG_CPU_ADD("maincpu", M68000, 8000000 )
305305   MCFG_CPU_PROGRAM_MAP(pkscramble_map)
306   //MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) /* only valid irq */
306   //MCFG_CPU_VBLANK_INT_DRIVER("screen", pkscram_state, irq1_line_hold) /* only valid irq */
307307
308308   MCFG_NVRAM_ADD_0FILL("nvram")
309309
trunk/src/mame/drivers/vastar.c
r17996r17997
289289   DEVCB_NULL
290290};
291291
292static INTERRUPT_GEN( vblank_irq )
292INTERRUPT_GEN_MEMBER(vastar_state::vblank_irq)
293293{
294   vastar_state *state = device->machine().driver_data<vastar_state>();
295294
296   if(state->m_nmi_mask)
297      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
295   if(m_nmi_mask)
296      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
298297}
299298
300299static MACHINE_CONFIG_START( vastar, vastar_state )
r17996r17997
303302   MCFG_CPU_ADD("maincpu", Z80, 3072000)   /* 3.072 MHz ???? */
304303   MCFG_CPU_PROGRAM_MAP(main_map)
305304   MCFG_CPU_IO_MAP(main_port_map)
306   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", vastar_state, vblank_irq)
307306
308307   MCFG_CPU_ADD("sub", Z80, 3072000)   /* 3.072 MHz ???? */
309308   MCFG_CPU_PROGRAM_MAP(cpu2_map)
310309   MCFG_CPU_IO_MAP(cpu2_port_map)
311   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)   /* ??? */
310   MCFG_CPU_PERIODIC_INT_DRIVER(vastar_state, irq0_line_hold, 4*60)   /* ??? */
312311
313312   MCFG_QUANTUM_TIME(attotime::from_hz(600))   /* 10 CPU slices per frame - seems enough to ensure proper */
314313                  /* synchronization of the CPUs */
trunk/src/mame/drivers/39in1.c
r17996r17997
7575   DECLARE_DRIVER_INIT(39in1);
7676   virtual void machine_start();
7777   UINT32 screen_update_39in1(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
78   INTERRUPT_GEN_MEMBER(pxa255_vblank_start);
7879};
7980
8081
r17996r17997
13531354   }
13541355}
13551356
1356static INTERRUPT_GEN( pxa255_vblank_start )
1357INTERRUPT_GEN_MEMBER(_39in1_state::pxa255_vblank_start)
13571358{
13581359}
13591360
r17996r17997
15911592
15921593   MCFG_CPU_ADD("maincpu", PXA255, 200000000)
15931594   MCFG_CPU_PROGRAM_MAP(39in1_map)
1594   MCFG_CPU_VBLANK_INT("screen", pxa255_vblank_start)
1595   MCFG_CPU_VBLANK_INT_DRIVER("screen", _39in1_state, pxa255_vblank_start)
15951596
15961597   MCFG_PALETTE_LENGTH(32768)
15971598
trunk/src/mame/drivers/fortecar.c
r17996r17997
690690   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)       /* 3 MHz, measured */
691691   MCFG_CPU_PROGRAM_MAP(fortecar_map)
692692   MCFG_CPU_IO_MAP(fortecar_ports)
693   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
693   MCFG_CPU_VBLANK_INT_DRIVER("screen", fortecar_state, nmi_line_pulse)
694694   MCFG_WATCHDOG_TIME_INIT(attotime::from_msec(200))   /* guess */
695695
696696   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/gunpey.c
r17996r17997
9595   virtual void video_start();
9696   virtual void palette_init();
9797   UINT32 screen_update_gunpey(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
98   INTERRUPT_GEN_MEMBER(gunpey_interrupt);
9899};
99100
100101
r17996r17997
355356
356357}
357358
358static INTERRUPT_GEN( gunpey_interrupt )
359INTERRUPT_GEN_MEMBER(gunpey_state::gunpey_interrupt)
359360{
360   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x200/4);
361   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x200/4);
361362}
362363
363364/***************************************************************************************/
r17996r17997
367368   MCFG_CPU_ADD("maincpu", V30, 57242400 / 4)
368369   MCFG_CPU_PROGRAM_MAP(mem_map)
369370   MCFG_CPU_IO_MAP(io_map)
370   MCFG_CPU_VBLANK_INT("screen", gunpey_interrupt)
371   MCFG_CPU_VBLANK_INT_DRIVER("screen", gunpey_state, gunpey_interrupt)
371372
372373   /* video hardware */
373374   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/superwng.c
r17996r17997
7474   virtual void video_start();
7575   virtual void palette_init();
7676   UINT32 screen_update_superwng(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
77   INTERRUPT_GEN_MEMBER(superwng_nmi_interrupt);
78   INTERRUPT_GEN_MEMBER(superwng_sound_nmi_assert);
7779};
7880
7981TILE_GET_INFO_MEMBER(superwng_state::get_bg_tile_info)
r17996r17997
204206   m_nmi_enable = data;
205207}
206208
207static INTERRUPT_GEN( superwng_nmi_interrupt )
209INTERRUPT_GEN_MEMBER(superwng_state::superwng_nmi_interrupt)
208210{
209   superwng_state *state = device->machine().driver_data<superwng_state>();
210211
211   if (BIT(state->m_nmi_enable, 0))
212   if (BIT(m_nmi_enable, 0))
212213      nmi_line_pulse(device);
213214}
214215
r17996r17997
229230   m_audiocpu->set_input_line(INPUT_LINE_NMI, CLEAR_LINE);
230231}
231232
232static INTERRUPT_GEN( superwng_sound_nmi_assert )
233INTERRUPT_GEN_MEMBER(superwng_state::superwng_sound_nmi_assert)
233234{
234   superwng_state *state = device->machine().driver_data<superwng_state>();
235   if (BIT(state->m_nmi_enable, 0))
236      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
235   if (BIT(m_nmi_enable, 0))
236      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
237237}
238238
239239WRITE8_MEMBER(superwng_state::superwng_bg_vram_w)
r17996r17997
466466   /* basic machine hardware */
467467   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
468468   MCFG_CPU_PROGRAM_MAP(superwng_map)
469   MCFG_CPU_VBLANK_INT("screen", superwng_nmi_interrupt)
469   MCFG_CPU_VBLANK_INT_DRIVER("screen", superwng_state, superwng_nmi_interrupt)
470470
471471   MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK/4)
472472   MCFG_CPU_PROGRAM_MAP(superwng_sound_map)
473   MCFG_CPU_PERIODIC_INT(superwng_sound_nmi_assert, 4*60)
473   MCFG_CPU_PERIODIC_INT_DRIVER(superwng_state, superwng_sound_nmi_assert, 4*60)
474474
475475
476476   /* video hardware */
trunk/src/mame/drivers/cyclemb.c
r17996r17997
907907   MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz/3) // Z8400BPS
908908   MCFG_CPU_PROGRAM_MAP(cyclemb_map)
909909   MCFG_CPU_IO_MAP(cyclemb_io)
910   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
910   MCFG_CPU_VBLANK_INT_DRIVER("screen", cyclemb_state, irq0_line_hold)
911911
912912   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/6)
913913   MCFG_CPU_PROGRAM_MAP(cyclemb_sound_map)
trunk/src/mame/drivers/baraduke.c
r17996r17997
379379   /* basic machine hardware */
380380   MCFG_CPU_ADD("maincpu", M6809,49152000/32)
381381   MCFG_CPU_PROGRAM_MAP(baraduke_map)
382   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
382   MCFG_CPU_VBLANK_INT_DRIVER("screen", baraduke_state, irq0_line_assert)
383383
384384   MCFG_CPU_ADD("mcu", HD63701,49152000/8)
385385   MCFG_CPU_PROGRAM_MAP(mcu_map)
386386   MCFG_CPU_IO_MAP(mcu_port_map)
387   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
387   MCFG_CPU_VBLANK_INT_DRIVER("screen", baraduke_state, irq0_line_hold)
388388
389389   MCFG_QUANTUM_TIME(attotime::from_hz(6000))      /* we need heavy synch */
390390
trunk/src/mame/drivers/bingor.c
r17996r17997
455455   DECLARE_READ8_MEMBER(test8_r);
456456   virtual void video_start();
457457   UINT32 screen_update_bingor(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
458   INTERRUPT_GEN_MEMBER(vblank_irq);
459   INTERRUPT_GEN_MEMBER(unk_irq);
458460};
459461
460462
r17996r17997
587589   PORT_DIPSETTING(      0x0000, DEF_STR( On ) )
588590INPUT_PORTS_END
589591
590static INTERRUPT_GEN( vblank_irq )
592INTERRUPT_GEN_MEMBER(bingor_state::vblank_irq)
591593{
592//  device->execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4); // reads i/o 0x200 and puts the result in ram, pic irq?
593   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x4c/4); // ?
594//  device.execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4); // reads i/o 0x200 and puts the result in ram, pic irq?
595   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x4c/4); // ?
594596}
595597
596static INTERRUPT_GEN( unk_irq )
598INTERRUPT_GEN_MEMBER(bingor_state::unk_irq)
597599{
598   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); // ?
600   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); // ?
599601}
600602
601603
r17996r17997
619621   MCFG_CPU_ADD("maincpu", I80186, 14000000 ) //?? Mhz
620622   MCFG_CPU_PROGRAM_MAP(bingor_map)
621623   MCFG_CPU_IO_MAP(bingor_io)
622   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
623   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 30)
624   MCFG_CPU_PERIODIC_INT(unk_irq, 30)
624   MCFG_CPU_VBLANK_INT_DRIVER("screen", bingor_state,  vblank_irq)
625   MCFG_CPU_PERIODIC_INT_DRIVER(bingor_state, nmi_line_pulse,  30)
626   MCFG_CPU_PERIODIC_INT_DRIVER(bingor_state, unk_irq,  30)
625627
626628   MCFG_CPU_ADD("pic", PIC16C57, 12000000) //?? Mhz
627629   MCFG_CPU_IO_MAP(pic_io_map)
trunk/src/mame/drivers/matmania.c
r17996r17997
309309   /* basic machine hardware */
310310   MCFG_CPU_ADD("maincpu", M6502, 1500000)   /* 1.5 MHz ???? */
311311   MCFG_CPU_PROGRAM_MAP(matmania_map)
312   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
312   MCFG_CPU_VBLANK_INT_DRIVER("screen", matmania_state, irq0_line_hold)
313313
314314   MCFG_CPU_ADD("audiocpu", M6502, 1200000)   /* 1.2 MHz ???? */
315315   MCFG_CPU_PROGRAM_MAP(matmania_sound_map)
316   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,15*60)   /* ???? */
316   MCFG_CPU_PERIODIC_INT_DRIVER(matmania_state, nmi_line_pulse, 15*60)   /* ???? */
317317                        /* IRQs are caused by the main CPU */
318318   MCFG_QUANTUM_TIME(attotime::from_hz(600))
319319
r17996r17997
394394   /* basic machine hardware */
395395   MCFG_CPU_ADD("maincpu", M6502, 1500000)   /* 1.5 MHz ???? */
396396   MCFG_CPU_PROGRAM_MAP(maniach_map)
397   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
397   MCFG_CPU_VBLANK_INT_DRIVER("screen", matmania_state, irq0_line_hold)
398398
399399   MCFG_CPU_ADD("audiocpu", M6809, 1500000)   /* 1.5 MHz ???? */
400400   MCFG_CPU_PROGRAM_MAP(maniach_sound_map)
trunk/src/mame/drivers/clshroad.c
r17996r17997
231231   /* basic machine hardware */
232232   MCFG_CPU_ADD("maincpu", Z80, 3000000)   /* ? */
233233   MCFG_CPU_PROGRAM_MAP(clshroad_map)
234   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ, no NMI */
234   MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold)   /* IRQ, no NMI */
235235
236236   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   /* ? */
237237   MCFG_CPU_PROGRAM_MAP(clshroad_sound_map)
238   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ, no NMI */
238   MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold)   /* IRQ, no NMI */
239239
240240
241241   /* video hardware */
r17996r17997
264264   /* basic machine hardware */
265265   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/4)   /* ? real speed unknown. 3MHz is too low and causes problems */
266266   MCFG_CPU_PROGRAM_MAP(clshroad_map)
267   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ, no NMI */
267   MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold)   /* IRQ, no NMI */
268268
269269   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6)   /* ? */
270270   MCFG_CPU_PROGRAM_MAP(clshroad_sound_map)
271   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* IRQ, no NMI */
271   MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold)   /* IRQ, no NMI */
272272
273273
274274   /* video hardware */
trunk/src/mame/drivers/dcheese.c
r17996r17997
7979}
8080
8181
82static INTERRUPT_GEN( dcheese_vblank )
82INTERRUPT_GEN_MEMBER(dcheese_state::dcheese_vblank)
8383{
8484   logerror("---- VBLANK ----\n");
85   dcheese_signal_irq(device->machine(), 4);
85   dcheese_signal_irq(machine(), 4);
8686}
8787
8888
r17996r17997
409409   /* basic machine hardware */
410410   MCFG_CPU_ADD("maincpu", M68000, MAIN_OSC)
411411   MCFG_CPU_PROGRAM_MAP(main_cpu_map)
412   MCFG_CPU_VBLANK_INT("screen", dcheese_vblank)
412   MCFG_CPU_VBLANK_INT_DRIVER("screen", dcheese_state, dcheese_vblank)
413413
414414   MCFG_CPU_ADD("audiocpu", M6809, SOUND_OSC/16)
415415   MCFG_CPU_PROGRAM_MAP(sound_cpu_map)
416   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 480)   /* accurate for fredmem */
416   MCFG_CPU_PERIODIC_INT_DRIVER(dcheese_state, irq1_line_hold, 480)   /* accurate for fredmem */
417417
418418
419419   MCFG_EEPROM_93C46_ADD("eeprom")
trunk/src/mame/drivers/lsasquad.c
r17996r17997
619619   /* basic machine hardware */
620620   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK / 4)
621621   MCFG_CPU_PROGRAM_MAP(lsasquad_map)
622   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
622   MCFG_CPU_VBLANK_INT_DRIVER("screen", lsasquad_state, irq0_line_hold)
623623
624624   MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK / 8)
625625   MCFG_CPU_PROGRAM_MAP(lsasquad_sound_map)
r17996r17997
674674   /* basic machine hardware */
675675   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK / 4)
676676   MCFG_CPU_PROGRAM_MAP(daikaiju_map)
677   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
677   MCFG_CPU_VBLANK_INT_DRIVER("screen", lsasquad_state, irq0_line_hold)
678678
679679   MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK / 8)
680680   MCFG_CPU_PROGRAM_MAP(daikaiju_sound_map)
trunk/src/mame/drivers/sengokmj.c
r17996r17997
7171   DECLARE_WRITE16_MEMBER(mahjong_panel_w);
7272   DECLARE_WRITE16_MEMBER(sengokmj_out_w);
7373   DECLARE_READ16_MEMBER(sengokmj_system_r);
74   INTERRUPT_GEN_MEMBER(sengokmj_interrupt);
7475};
7576
7677
r17996r17997
288289   GFXDECODE_ENTRY( "tx_gfx", 0, charlayout, 0x700, 0x10 ) /* Text */
289290GFXDECODE_END
290291
291static INTERRUPT_GEN( sengokmj_interrupt )
292INTERRUPT_GEN_MEMBER(sengokmj_state::sengokmj_interrupt)
292293{
293   device->execute().set_input_line_and_vector(0,HOLD_LINE,0xc8/4);
294   device.execute().set_input_line_and_vector(0,HOLD_LINE,0xc8/4);
294295}
295296
296297static MACHINE_CONFIG_START( sengokmj, sengokmj_state )
r17996r17997
299300   MCFG_CPU_ADD("maincpu", V30, 16000000/2) /* V30-8 */
300301   MCFG_CPU_PROGRAM_MAP(sengokmj_map)
301302   MCFG_CPU_IO_MAP(sengokmj_io_map)
302   MCFG_CPU_VBLANK_INT("screen", sengokmj_interrupt)
303   MCFG_CPU_VBLANK_INT_DRIVER("screen", sengokmj_state, sengokmj_interrupt)
303304
304305   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
305306
trunk/src/mame/drivers/dooyong.c
r17996r17997
865865   /* basic machine hardware */
866866   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
867867   MCFG_CPU_PROGRAM_MAP(lastday_map)
868   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
868   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
869869
870870   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* ??? */
871871   MCFG_CPU_PROGRAM_MAP(lastday_sound_map)
r17996r17997
908908   /* basic machine hardware */
909909   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
910910   MCFG_CPU_PROGRAM_MAP(gulfstrm_map)
911   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
911   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
912912
913913   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* ??? */
914914   MCFG_CPU_PROGRAM_MAP(lastday_sound_map)
r17996r17997
941941   /* basic machine hardware */
942942   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
943943   MCFG_CPU_PROGRAM_MAP(pollux_map)
944   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
944   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
945945
946946   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* ??? */
947947   MCFG_CPU_PROGRAM_MAP(pollux_sound_map)
r17996r17997
974974   /* basic machine hardware */
975975   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
976976   MCFG_CPU_PROGRAM_MAP(bluehawk_map)
977   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
977   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
978978
979979   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ??? */
980980   MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
r17996r17997
10061006   /* basic machine hardware */
10071007   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
10081008   MCFG_CPU_PROGRAM_MAP(flytiger_map)
1009   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1009   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
10101010
10111011   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ??? */
10121012   MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
r17996r17997
10381038   /* basic machine hardware */
10391039   MCFG_CPU_ADD("maincpu", Z80, 8000000)   /* ??? */
10401040   MCFG_CPU_PROGRAM_MAP(primella_map)
1041   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1041   MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
10421042
10431043   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ??? */
10441044   MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
trunk/src/mame/drivers/silvmil.c
r17996r17997
318318   /* basic machine hardware */
319319   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)
320320   MCFG_CPU_PROGRAM_MAP(silvmil_map)
321   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
321   MCFG_CPU_VBLANK_INT_DRIVER("screen", silvmil_state, irq6_line_hold)
322322
323323   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4_096MHz) // 4.096MHz or 3.579545MHz - Need to verify
324324   MCFG_CPU_PROGRAM_MAP(silvmil_sound_map)
trunk/src/mame/drivers/brkthru.c
r17996r17997
381381   m_flipscreen = 0;
382382}
383383
384static INTERRUPT_GEN( vblank_irq )
384INTERRUPT_GEN_MEMBER(brkthru_state::vblank_irq)
385385{
386   brkthru_state *state = device->machine().driver_data<brkthru_state>();
387386
388   if(state->m_nmi_mask)
389      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
387   if(m_nmi_mask)
388      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
390389}
391390
392391static MACHINE_CONFIG_START( brkthru, brkthru_state )
r17996r17997
394393   /* basic machine hardware */
395394   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/8)        /* 1.5 MHz ? */
396395   MCFG_CPU_PROGRAM_MAP(brkthru_map)
397   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
396   MCFG_CPU_VBLANK_INT_DRIVER("screen", brkthru_state, vblank_irq)
398397
399398   MCFG_CPU_ADD("audiocpu", M6809, MASTER_CLOCK/8)      /* 1.5 MHz ? */
400399   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
430429   /* basic machine hardware */
431430   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/8)        /* 1.5 MHz ? */
432431   MCFG_CPU_PROGRAM_MAP(darwin_map)
433   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
432   MCFG_CPU_VBLANK_INT_DRIVER("screen", brkthru_state, vblank_irq)
434433
435434   MCFG_CPU_ADD("audiocpu", M6809, MASTER_CLOCK/8)      /* 1.5 MHz ? */
436435   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/rbmk.c
r17996r17997
7979   DECLARE_WRITE16_MEMBER(eeprom_w);
8080   virtual void video_start();
8181   UINT32 screen_update_rbmk(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
82   INTERRUPT_GEN_MEMBER(mcu_irq);
8283};
8384
8485
r17996r17997
527528   return 0;
528529}
529530
530static INTERRUPT_GEN( mcu_irq )
531INTERRUPT_GEN_MEMBER(rbmk_state::mcu_irq)
531532{
532   device->machine().device("mcu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
533   machine().device("mcu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
533534}
534535
535536static MACHINE_CONFIG_START( rbmk, rbmk_state )
536537   MCFG_CPU_ADD("maincpu", M68000, 22000000 /2)
537538   MCFG_CPU_PROGRAM_MAP(rbmk_mem)
538   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
539   MCFG_CPU_VBLANK_INT_DRIVER("screen", rbmk_state, irq1_line_hold)
539540
540541   MCFG_CPU_ADD("mcu", AT89C4051, 22000000 / 4) // frequency isn't right
541542   MCFG_CPU_PROGRAM_MAP(rbmk_mcu_mem)
542543   MCFG_CPU_IO_MAP(rbmk_mcu_io)
543   MCFG_CPU_VBLANK_INT("screen", mcu_irq)
544   MCFG_CPU_VBLANK_INT_DRIVER("screen", rbmk_state, mcu_irq)
544545
545546   MCFG_GFXDECODE(rbmk)
546547
trunk/src/mame/drivers/thepit.c
r17996r17997
635635   DEVCB_NULL
636636};
637637
638static INTERRUPT_GEN( vblank_irq )
638INTERRUPT_GEN_MEMBER(thepit_state::vblank_irq)
639639{
640   thepit_state *state = device->machine().driver_data<thepit_state>();
641640
642   if(state->m_nmi_mask)
643      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
641   if(m_nmi_mask)
642      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
644643}
645644
646645static MACHINE_CONFIG_START( thepit, thepit_state )
r17996r17997
648647   /* basic machine hardware */
649648   MCFG_CPU_ADD("maincpu", Z80, PIXEL_CLOCK/2)     /* 3.072 MHz */
650649   MCFG_CPU_PROGRAM_MAP(thepit_main_map)
651   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
650   MCFG_CPU_VBLANK_INT_DRIVER("screen", thepit_state, vblank_irq)
652651
653652   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)     /* 2.5 MHz */
654653   MCFG_CPU_PROGRAM_MAP(audio_map)
655654   MCFG_CPU_IO_MAP(audio_io_map)
656   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
655   MCFG_CPU_VBLANK_INT_DRIVER("screen", thepit_state, irq0_line_hold)
657656
658657   /* video hardware */
659658   MCFG_GFXDECODE(thepit)
trunk/src/mame/drivers/trvmadns.c
r17996r17997
347347   MCFG_CPU_ADD("maincpu", Z80,10000000/2) // ?
348348   MCFG_CPU_PROGRAM_MAP(cpu_map)
349349   MCFG_CPU_IO_MAP(io_map)
350   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
350   MCFG_CPU_VBLANK_INT_DRIVER("screen", trvmadns_state, nmi_line_pulse)
351351
352352
353353   /* video hardware */
trunk/src/mame/drivers/albazg.c
r17996r17997
380380   MCFG_CPU_ADD("maincpu", Z80 , MASTER_CLOCK/2) /* xtal is 12 Mhz, unknown divider*/
381381   MCFG_CPU_PROGRAM_MAP(main_map)
382382   MCFG_CPU_IO_MAP(port_map)
383   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
383   MCFG_CPU_VBLANK_INT_DRIVER("screen", albazg_state, irq0_line_hold)
384384
385385
386386   MCFG_EEPROM_93C46_ADD("eeprom")
trunk/src/mame/drivers/bingoc.c
r17996r17997
146146
147147   MCFG_CPU_ADD("maincpu", M68000,8000000)       /* ? MHz */
148148   MCFG_CPU_PROGRAM_MAP(main_map)
149   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
149   MCFG_CPU_VBLANK_INT_DRIVER("screen", bingoc_state, irq2_line_hold)
150150
151151   MCFG_CPU_ADD("soundcpu", Z80,4000000)       /* ? MHz */
152152   MCFG_CPU_PROGRAM_MAP(sound_map)
153153   MCFG_CPU_IO_MAP(sound_io)
154154#if SOUND_TEST
155   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
155   MCFG_CPU_VBLANK_INT_DRIVER("screen", bingoc_state, nmi_line_pulse)
156156#endif
157157
158158   /* video hardware */
trunk/src/mame/drivers/changela.c
r17996r17997
412412      timer.machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE,0xcf);
413413}
414414
415static INTERRUPT_GEN( chl_mcu_irq )
415INTERRUPT_GEN_MEMBER(changela_state::chl_mcu_irq)
416416{
417   changela_state *state = device->machine().driver_data<changela_state>();
418417
419   generic_pulse_irq_line(state->m_mcu, 0, 1);
418   generic_pulse_irq_line(m_mcu->execute(), 0, 1);
420419}
421420
422421void changela_state::machine_start()
r17996r17997
508507
509508   MCFG_CPU_ADD("mcu", M68705,2500000)
510509   MCFG_CPU_PROGRAM_MAP(mcu_map)
511   MCFG_CPU_VBLANK_INT("screen",chl_mcu_irq)
510   MCFG_CPU_VBLANK_INT_DRIVER("screen", changela_state, chl_mcu_irq)
512511
513512
514513   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/sstrangr.c
r17996r17997
197197   MCFG_CPU_ADD("maincpu",I8080,1996800)   /* clock is a guess, taken from mw8080bw */
198198   MCFG_CPU_PROGRAM_MAP(sstrangr_map)
199199   MCFG_CPU_IO_MAP(sstrangr_io_map)
200   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
200   MCFG_CPU_PERIODIC_INT_DRIVER(sstrangr_state, irq0_line_hold, 2*60)
201201
202202   /* video hardware */
203203   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/backfire.c
r17996r17997
8181   virtual void video_start();
8282   UINT32 screen_update_backfire_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
8383   UINT32 screen_update_backfire_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
84   INTERRUPT_GEN_MEMBER(deco32_vbl_interrupt);
8485};
8586
8687//UINT32 *backfire_180010, *backfire_188010;
r17996r17997
432433   sound_irq_gen
433434};
434435
435static INTERRUPT_GEN( deco32_vbl_interrupt )
436INTERRUPT_GEN_MEMBER(backfire_state::deco32_vbl_interrupt)
436437{
437   device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
438   device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
438439}
439440
440441
r17996r17997
500501   /* basic machine hardware */
501502   MCFG_CPU_ADD("maincpu", ARM, 28000000/4) /* Unconfirmed */
502503   MCFG_CPU_PROGRAM_MAP(backfire_map)
503   MCFG_CPU_VBLANK_INT("lscreen", deco32_vbl_interrupt)   /* or is it "rscreen?" */
504   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", backfire_state, deco32_vbl_interrupt)   /* or is it "rscreen?" */
504505
505506   MCFG_EEPROM_93C46_ADD("eeprom")
506507
trunk/src/mame/drivers/sidepckt.c
r17996r17997
390390   /* basic machine hardware */
391391   MCFG_CPU_ADD("maincpu", M6809, 2000000)        /* 2 MHz */
392392   MCFG_CPU_PROGRAM_MAP(sidepckt_map)
393   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
393   MCFG_CPU_VBLANK_INT_DRIVER("screen", sidepckt_state, nmi_line_pulse)
394394
395395   MCFG_CPU_ADD("audiocpu", M6502, 1500000)        /* 1.5 MHz */
396396   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/starwars.c
r17996r17997
318318   /* basic machine hardware */
319319   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK / 8)
320320   MCFG_CPU_PROGRAM_MAP(main_map)
321   MCFG_CPU_PERIODIC_INT(irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
321   MCFG_CPU_PERIODIC_INT_DRIVER(starwars_state, irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
322322   MCFG_WATCHDOG_TIME_INIT(attotime::from_hz(CLOCK_3KHZ / 128))
323323
324324   MCFG_CPU_ADD("audiocpu", M6809, MASTER_CLOCK / 8)
trunk/src/mame/drivers/cubeqst.c
r17996r17997
5757   virtual void video_start();
5858   virtual void palette_init();
5959   UINT32 screen_update_cubeqst(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
60   INTERRUPT_GEN_MEMBER(vblank);
6061};
6162
6263
r17996r17997
192193   return machine().primary_screen->vpos();
193194}
194195
195static INTERRUPT_GEN( vblank )
196INTERRUPT_GEN_MEMBER(cubeqst_state::vblank)
196197{
197   cubeqst_state *state = device->machine().driver_data<cubeqst_state>();
198   int int_level = state->m_video_field == 0 ? 5 : 6;
198   int int_level = m_video_field == 0 ? 5 : 6;
199199
200   device->execute().set_input_line(int_level, HOLD_LINE);
200   device.execute().set_input_line(int_level, HOLD_LINE);
201201
202202   /* Update the laserdisc */
203   state->m_video_field ^= 1;
203   m_video_field ^= 1;
204204}
205205
206206
r17996r17997
513513static MACHINE_CONFIG_START( cubeqst, cubeqst_state )
514514   MCFG_CPU_ADD("main_cpu", M68000, XTAL_16MHz / 2)
515515   MCFG_CPU_PROGRAM_MAP(m68k_program_map)
516   MCFG_CPU_VBLANK_INT("screen", vblank)
516   MCFG_CPU_VBLANK_INT_DRIVER("screen", cubeqst_state, vblank)
517517
518518   MCFG_CPU_ADD("rotate_cpu", CQUESTROT, XTAL_10MHz / 2)
519519   MCFG_CPU_PROGRAM_MAP(rotate_map)
trunk/src/mame/drivers/mosaic.c
r17996r17997
267267   MCFG_CPU_ADD("maincpu", Z180, 7000000)   /* ??? */
268268   MCFG_CPU_PROGRAM_MAP(mosaic_map)
269269   MCFG_CPU_IO_MAP(mosaic_io_map)
270   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
270   MCFG_CPU_VBLANK_INT_DRIVER("screen", mosaic_state, irq0_line_hold)
271271
272272
273273   /* video hardware */
trunk/src/mame/drivers/meijinsn.c
r17996r17997
362362   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
363363   MCFG_CPU_PROGRAM_MAP(meijinsn_sound_map)
364364   MCFG_CPU_IO_MAP(meijinsn_sound_io_map)
365   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 160*60)
365   MCFG_CPU_PERIODIC_INT_DRIVER(meijinsn_state, irq0_line_hold, 160*60)
366366
367367
368368   /* video hardware */
trunk/src/mame/drivers/ltcasino.c
r17996r17997
647647   /* basic machine hardware */
648648   MCFG_CPU_ADD("maincpu", M6502,2000000)       /* ? MHz */
649649   MCFG_CPU_PROGRAM_MAP(ltcasino_map)
650   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
650   MCFG_CPU_VBLANK_INT_DRIVER("screen", ltcasino_state, irq0_line_hold)
651651
652652   /* video hardware */
653653   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/astrocorp.c
r17996r17997
475475   /* basic machine hardware */
476476   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
477477   MCFG_CPU_PROGRAM_MAP(showhand_map)
478   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
478   MCFG_CPU_VBLANK_INT_DRIVER("screen", astrocorp_state, irq4_line_hold)
479479
480480   MCFG_NVRAM_ADD_0FILL("nvram")
481481   MCFG_EEPROM_93C46_ADD("eeprom")
trunk/src/mame/drivers/coolridr.c
r17996r17997
320320   virtual void machine_reset();
321321   virtual void video_start();
322322   UINT32 screen_update_coolridr(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
323   INTERRUPT_GEN_MEMBER(system_h1);
323324};
324325
325326
r17996r17997
11371138
11381139
11391140// IRQs 4, 6 (& 8?) are valid on SH-2
1140static INTERRUPT_GEN( system_h1 )
1141INTERRUPT_GEN_MEMBER(coolridr_state::system_h1)
11411142{
1142   device->execute().set_input_line(4, HOLD_LINE);
1143   device.execute().set_input_line(4, HOLD_LINE);
11431144}
11441145
11451146//IRQs 10,12 and 14 are valid on SH-1 instead
r17996r17997
11651166static MACHINE_CONFIG_START( coolridr, coolridr_state )
11661167   MCFG_CPU_ADD("maincpu", SH2, 28000000)   // 28 mhz
11671168   MCFG_CPU_PROGRAM_MAP(system_h1_map)
1168   MCFG_CPU_VBLANK_INT("screen",system_h1)
1169   MCFG_CPU_VBLANK_INT_DRIVER("screen", coolridr_state, system_h1)
11691170
11701171   MCFG_CPU_ADD("soundcpu", M68000, 11289600) //256 x 44100 Hz = 11.2896 MHz
11711172   MCFG_CPU_PROGRAM_MAP(system_h1_sound_map)
trunk/src/mame/drivers/blitz.c
r17996r17997
794794   /* basic machine hardware */
795795   MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK)
796796   MCFG_CPU_PROGRAM_MAP(megadpkr_map)
797   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
797   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz_state, nmi_line_pulse)
798798
799799//  MCFG_CPU_ADD("mcu", M68705, CPU_CLOCK) /* unknown */
800800//  MCFG_CPU_PROGRAM_MAP(mcu_map)
trunk/src/mame/drivers/cobra.c
r17996r17997
721721   virtual void machine_reset();
722722   virtual void video_start();
723723   UINT32 screen_update_cobra(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
724   INTERRUPT_GEN_MEMBER(cobra_vblank);
724725};
725726
726727void cobra_renderer::render_color_scan(INT32 scanline, const extent_t &extent, const cobra_polydata &extradata, int threadid)
r17996r17997
31873188}
31883189
31893190
3190static INTERRUPT_GEN( cobra_vblank )
3191INTERRUPT_GEN_MEMBER(cobra_state::cobra_vblank)
31913192{
3192   cobra_state *cobra = device->machine().driver_data<cobra_state>();
31933193
3194   if (cobra->m_vblank_enable & 0x80)
3194   if (m_vblank_enable & 0x80)
31953195   {
3196      device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
3197      cobra->m_gfx_unk_flag = 0x80;
3196      device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
3197      m_gfx_unk_flag = 0x80;
31983198   }
31993199}
32003200
r17996r17997
32363236   MCFG_CPU_ADD("maincpu", PPC603, 100000000)      /* 603EV, 100? MHz */
32373237   MCFG_CPU_CONFIG(main_ppc_cfg)
32383238   MCFG_CPU_PROGRAM_MAP(cobra_main_map)
3239   MCFG_CPU_VBLANK_INT("screen", cobra_vblank)
3239   MCFG_CPU_VBLANK_INT_DRIVER("screen", cobra_state, cobra_vblank)
32403240
32413241   MCFG_CPU_ADD("subcpu", PPC403GA, 32000000)      /* 403GA, 33? MHz */
32423242   MCFG_CPU_PROGRAM_MAP(cobra_sub_map)
trunk/src/mame/drivers/gamtor.c
r17996r17997
7070static MACHINE_CONFIG_START( gaminator, gaminator_state )
7171   MCFG_CPU_ADD("maincpu", MCF5206E, 40000000) /* definitely Coldfire, model / clock uncertain */
7272   MCFG_CPU_PROGRAM_MAP(gaminator_map)
73   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) // irq6 seems to be needed to get past the ROM checking
73   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaminator_state, irq6_line_hold) // irq6 seems to be needed to get past the ROM checking
7474
7575   MCFG_FRAGMENT_ADD( pcvideo_vga )
7676
trunk/src/mame/drivers/tutankhm.c
r17996r17997
6161 *
6262 *************************************/
6363
64static INTERRUPT_GEN( tutankhm_interrupt )
64INTERRUPT_GEN_MEMBER(tutankhm_state::tutankhm_interrupt)
6565{
66   tutankhm_state *state = device->machine().driver_data<tutankhm_state>();
6766
6867   /* flip flops cause the interrupt to be signalled every other frame */
69   state->m_irq_toggle ^= 1;
70   if (state->m_irq_toggle && state->m_irq_enable)
71      device->execute().set_input_line(0, ASSERT_LINE);
68   m_irq_toggle ^= 1;
69   if (m_irq_toggle && m_irq_enable)
70      device.execute().set_input_line(0, ASSERT_LINE);
7271}
7372
7473
r17996r17997
221220   /* basic machine hardware */
222221   MCFG_CPU_ADD("maincpu", M6809, XTAL_18_432MHz/12)   /* 1.5 MHz ??? */
223222   MCFG_CPU_PROGRAM_MAP(main_map)
224   MCFG_CPU_VBLANK_INT("screen", tutankhm_interrupt)
223   MCFG_CPU_VBLANK_INT_DRIVER("screen", tutankhm_state, tutankhm_interrupt)
225224
226225   MCFG_MACHINE_START_OVERRIDE(tutankhm_state,tutankhm)
227226   MCFG_MACHINE_RESET_OVERRIDE(tutankhm_state,tutankhm)
trunk/src/mame/drivers/nitedrvr.c
r17996r17997
139139   /* basic machine hardware */
140140   MCFG_CPU_ADD("maincpu", M6502, XTAL_12_096MHz/12) // 1 MHz
141141   MCFG_CPU_PROGRAM_MAP(nitedrvr_map)
142   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
142   MCFG_CPU_VBLANK_INT_DRIVER("screen", nitedrvr_state, irq0_line_hold)
143143   MCFG_WATCHDOG_VBLANK_INIT(3)
144144
145145
trunk/src/mame/drivers/intrscti.c
r17996r17997
163163   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* ? MHz */
164164   MCFG_CPU_PROGRAM_MAP(intrscti_map)
165165   MCFG_CPU_IO_MAP(readport)
166   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
166   MCFG_CPU_VBLANK_INT_DRIVER("screen", intrscti_state, irq0_line_hold)
167167
168168   /* video hardware */
169169   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/rainbow.c
r17996r17997
676676   /* basic machine hardware */
677677   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) /* verified on pcb */
678678   MCFG_CPU_PROGRAM_MAP(rbisland_map)
679   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
679   MCFG_CPU_VBLANK_INT_DRIVER("screen", rbisland_state, irq4_line_hold)
680680
681681   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4) /* verified on pcb */
682682   MCFG_CPU_PROGRAM_MAP(rbisland_sound_map)
r17996r17997
716716   /* basic machine hardware */
717717   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/3)   /* not verified but matches original */
718718   MCFG_CPU_PROGRAM_MAP(jumping_map)
719   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
719   MCFG_CPU_VBLANK_INT_DRIVER("screen", rbisland_state, irq4_line_hold)
720720
721721   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6)   /* not verified but music tempo matches original */
722722   MCFG_CPU_PROGRAM_MAP(jumping_sound_map)
trunk/src/mame/drivers/galspnbl.c
r17996r17997
229229   /* basic machine hardware */
230230   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)   /* 12 MHz ??? - Use value from Temco's Super Pinball Action - NEEDS VERIFICATION!! */
231231   MCFG_CPU_PROGRAM_MAP(main_map)
232   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* also has vector for 6, but it does nothing */
232   MCFG_CPU_VBLANK_INT_DRIVER("screen", galspnbl_state, irq3_line_hold)/* also has vector for 6, but it does nothing */
233233
234234   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz)   /* 4 MHz ??? - Use value from Temco's Super Pinball Action - NEEDS VERIFICATION!! */
235235   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/tunhunt.c
r17996r17997
297297   /* basic machine hardware */
298298   MCFG_CPU_ADD("maincpu", M6502, XTAL_12_096MHz/6)      /* ??? */
299299   MCFG_CPU_PROGRAM_MAP(main_map)
300   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)   /* 48V, 112V, 176V, 240V */
300   MCFG_CPU_PERIODIC_INT_DRIVER(tunhunt_state, irq0_line_hold, 4*60)   /* 48V, 112V, 176V, 240V */
301301
302302   /* video hardware */
303303   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/tryout.c
r17996r17997
192192
193193   MCFG_CPU_ADD("audiocpu", M6502, 1500000)   /* ? */
194194   MCFG_CPU_PROGRAM_MAP(sound_cpu)
195   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,1000) /* controls BGM tempo, 1000 is an hand-tuned value to match a side-by-side video */
195   MCFG_CPU_PERIODIC_INT_DRIVER(tryout_state, nmi_line_pulse, 1000) /* controls BGM tempo, 1000 is an hand-tuned value to match a side-by-side video */
196196
197197   /* video hardware */
198198   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/rungun.c
r17996r17997
171171   return 0;
172172}
173173
174static INTERRUPT_GEN(rng_interrupt)
174INTERRUPT_GEN_MEMBER(rungun_state::rng_interrupt)
175175{
176   rungun_state *state = device->machine().driver_data<rungun_state>();
177176
178   if (state->m_sysreg[0x0c / 2] & 0x09)
179      device->execute().set_input_line(M68K_IRQ_5, ASSERT_LINE);
177   if (m_sysreg[0x0c / 2] & 0x09)
178      device.execute().set_input_line(M68K_IRQ_5, ASSERT_LINE);
180179}
181180
182181static ADDRESS_MAP_START( rungun_map, AS_PROGRAM, 16, rungun_state )
r17996r17997
226225      m_audiocpu->set_input_line(INPUT_LINE_NMI, CLEAR_LINE);
227226}
228227
229static INTERRUPT_GEN(audio_interrupt)
228INTERRUPT_GEN_MEMBER(rungun_state::audio_interrupt)
230229{
231   rungun_state *state = device->machine().driver_data<rungun_state>();
232230
233   if (state->m_z80_control & 0x80)
231   if (m_z80_control & 0x80)
234232      return;
235233
236   device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
234   device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
237235}
238236
239237/* sound (this should be split into audio/xexex.c or pregx.c or so someday) */
r17996r17997
399397   /* basic machine hardware */
400398   MCFG_CPU_ADD("maincpu", M68000, 16000000)
401399   MCFG_CPU_PROGRAM_MAP(rungun_map)
402   MCFG_CPU_VBLANK_INT("screen", rng_interrupt)
400   MCFG_CPU_VBLANK_INT_DRIVER("screen", rungun_state, rng_interrupt)
403401
404402   MCFG_CPU_ADD("soundcpu", Z80, 10000000) // 8Mhz (10Mhz is much safer in self-test due to heavy sync)
405403   MCFG_CPU_PROGRAM_MAP(rungun_sound_map)
406   MCFG_CPU_PERIODIC_INT(audio_interrupt, 480)
404   MCFG_CPU_PERIODIC_INT_DRIVER(rungun_state, audio_interrupt, 480)
407405
408406   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // higher if sound stutters
409407
trunk/src/mame/drivers/sfbonus.c
r17996r17997
13591359   MCFG_CPU_ADD("maincpu", Z80, 6000000) // custom packaged z80 CPU ?? Mhz
13601360   MCFG_CPU_PROGRAM_MAP(sfbonus_map)
13611361   MCFG_CPU_IO_MAP(sfbonus_io)
1362   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
1363   //MCFG_CPU_PERIODIC_INT(nmi_line_pulse,100)
1362   MCFG_CPU_VBLANK_INT_DRIVER("screen", sfbonus_state, irq0_line_hold)
1363   //MCFG_CPU_PERIODIC_INT_DRIVER(sfbonus_state, nmi_line_pulse, 100)
13641364
13651365
13661366   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/crystal.c
r17996r17997
192192   virtual void machine_reset();
193193   UINT32 screen_update_crystal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
194194   void screen_eof_crystal(screen_device &screen, bool state);
195   INTERRUPT_GEN_MEMBER(crystal_interrupt);
195196};
196197
197198static void IntReq( running_machine &machine, int num )
r17996r17997
742743   }
743744}
744745
745static INTERRUPT_GEN(crystal_interrupt)
746INTERRUPT_GEN_MEMBER(crystal_state::crystal_interrupt)
746747{
747   IntReq(device->machine(), 24);      //VRender0 VBlank
748   IntReq(machine(), 24);      //VRender0 VBlank
748749}
749750
750751static INPUT_PORTS_START(crystal)
r17996r17997
841842
842843   MCFG_CPU_ADD("maincpu", SE3208, 43000000)
843844   MCFG_CPU_PROGRAM_MAP(crystal_mem)
844   MCFG_CPU_VBLANK_INT("screen", crystal_interrupt)
845   MCFG_CPU_VBLANK_INT_DRIVER("screen", crystal_state, crystal_interrupt)
845846
846847
847848   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/tempest.c
r17996r17997
588588   /* basic machine hardware */
589589   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK / 8)
590590   MCFG_CPU_PROGRAM_MAP(main_map)
591   MCFG_CPU_PERIODIC_INT(irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
591   MCFG_CPU_PERIODIC_INT_DRIVER(tempest_state, irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
592592   MCFG_WATCHDOG_TIME_INIT(attotime::from_hz(CLOCK_3KHZ / 256))
593593
594594   MCFG_ATARIVGEAROM_ADD("earom")
trunk/src/mame/drivers/madmotor.c
r17996r17997
250250   /* basic machine hardware */
251251   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* Custom chip 59, 24 MHz crystal */
252252   MCFG_CPU_PROGRAM_MAP(madmotor_map)
253   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
253   MCFG_CPU_VBLANK_INT_DRIVER("screen", madmotor_state, irq6_line_hold)/* VBL */
254254
255255   MCFG_CPU_ADD("audiocpu", H6280, 8053000/2) /* Custom chip 45, Crystal near CPU is 8.053 MHz */
256256   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/chinsan.c
r17996r17997
605605   MCFG_CPU_ADD("maincpu", Z80,10000000/2)       /* ? MHz */
606606   MCFG_CPU_PROGRAM_MAP(chinsan_map)
607607   MCFG_CPU_IO_MAP(chinsan_io)
608   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
608   MCFG_CPU_VBLANK_INT_DRIVER("screen", chinsan_state, irq0_line_hold)
609609
610610
611611   /* video hardware */
trunk/src/mame/drivers/rocnrope.c
r17996r17997
186186 *
187187 *************************************/
188188
189static INTERRUPT_GEN( vblank_irq )
189INTERRUPT_GEN_MEMBER(rocnrope_state::vblank_irq)
190190{
191   rocnrope_state *state = device->machine().driver_data<rocnrope_state>();
192191
193   if(state->m_irq_mask)
194      device->execute().set_input_line(0, HOLD_LINE);
192   if(m_irq_mask)
193      device.execute().set_input_line(0, HOLD_LINE);
195194}
196195
197196
r17996r17997
200199   /* basic machine hardware */
201200   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK / 3 / 4)        /* Verified in schematics */
202201   MCFG_CPU_PROGRAM_MAP(rocnrope_map)
203   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
202   MCFG_CPU_VBLANK_INT_DRIVER("screen", rocnrope_state, vblank_irq)
204203
205204   /* video hardware */
206205   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/aerofgt.c
r17996r17997
13271327   /* basic machine hardware */
13281328   MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2)    /* verified on pcb */
13291329   MCFG_CPU_PROGRAM_MAP(pspikes_map)
1330   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1330   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
13311331
13321332   MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4) /* verified on pcb */
13331333   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
13661366   /* basic machine hardware */
13671367   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
13681368   MCFG_CPU_PROGRAM_MAP(spikes91_map)
1369   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1369   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
13701370
13711371   /* + Z80 for sound */
13721372
r17996r17997
14001400   /* basic machine hardware */
14011401   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
14021402   MCFG_CPU_PROGRAM_MAP(pspikesb_map)
1403   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1403   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
14041404
14051405   MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
14061406   MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
r17996r17997
14301430   /* basic machine hardware */
14311431   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
14321432   MCFG_CPU_PROGRAM_MAP(pspikesc_map)
1433   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1433   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
14341434
14351435   MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
14361436   MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
r17996r17997
14601460   /* basic machine hardware */
14611461   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
14621462   MCFG_CPU_PROGRAM_MAP(karatblz_map)
1463   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1463   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)
14641464
14651465   MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
14661466   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
14991499   /* basic machine hardware */
15001500   MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2)   /* verified on pcb */
15011501   MCFG_CPU_PROGRAM_MAP(spinlbrk_map)
1502   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* there are vectors for 3 and 4 too */
1502   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* there are vectors for 3 and 4 too */
15031503
15041504   MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4)   /* 5mhz verified on pcb */
15051505   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
15381538   /* basic machine hardware */
15391539   MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2)   /* verified on pcb */
15401540   MCFG_CPU_PROGRAM_MAP(turbofrc_map)
1541   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1541   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
15421542
15431543   MCFG_CPU_ADD("audiocpu",Z80,XTAL_5MHz)   /* verified on pcb */
15441544   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
15771577   /* basic machine hardware */
15781578   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
15791579   MCFG_CPU_PROGRAM_MAP(aerofgtb_map)
1580   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1580   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
15811581
15821582   MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
15831583   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
16171617   /* basic machine hardware */
16181618   MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2)   /* verified on pcb */
16191619   MCFG_CPU_PROGRAM_MAP(aerofgt_map)
1620   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1620   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
16211621
16221622   MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4) /* 5 MHz verified on pcb */
16231623   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
16571657   /* basic machine hardware */
16581658   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
16591659   MCFG_CPU_PROGRAM_MAP(aerfboot_map)
1660   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1660   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)
16611661
16621662   MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
16631663   MCFG_CPU_PROGRAM_MAP(aerfboot_sound_map)
r17996r17997
16911691   /* basic machine hardware */
16921692   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
16931693   MCFG_CPU_PROGRAM_MAP(aerfboo2_map)
1694   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1694   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq2_line_hold)
16951695
16961696   MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
16971697   MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
r17996r17997
17221722   /* basic machine hardware */
17231723   MCFG_CPU_ADD("maincpu",M68000,20000000/2)   /* 10 MHz (?) */
17241724   MCFG_CPU_PROGRAM_MAP(wbbc97_map)
1725   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
1725   MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
17261726
17271727   MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
17281728   MCFG_CPU_PROGRAM_MAP(wbbc97_sound_map)
trunk/src/mame/drivers/ultrsprt.c
r17996r17997
3636   DECLARE_CUSTOM_INPUT_MEMBER(analog_ctrl_r);
3737   virtual void machine_start();
3838   UINT32 screen_update_ultrsprt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
39   INTERRUPT_GEN_MEMBER(ultrsprt_vblank);
3940};
4041
4142
r17996r17997
203204INPUT_PORTS_END
204205
205206
206static INTERRUPT_GEN( ultrsprt_vblank )
207INTERRUPT_GEN_MEMBER(ultrsprt_state::ultrsprt_vblank)
207208{
208   device->execute().set_input_line(INPUT_LINE_IRQ1, ASSERT_LINE);
209   device.execute().set_input_line(INPUT_LINE_IRQ1, ASSERT_LINE);
209210}
210211
211212static void sound_irq_callback(running_machine &machine, int irq)
r17996r17997
227228   /* basic machine hardware */
228229   MCFG_CPU_ADD("maincpu", PPC403GA, 25000000)      /* PowerPC 403GA 25MHz */
229230   MCFG_CPU_PROGRAM_MAP(ultrsprt_map)
230   MCFG_CPU_VBLANK_INT("screen", ultrsprt_vblank)
231   MCFG_CPU_VBLANK_INT_DRIVER("screen", ultrsprt_state, ultrsprt_vblank)
231232
232233   MCFG_CPU_ADD("audiocpu", M68000, 8000000)      /* Not sure about the frequency */
233234   MCFG_CPU_PROGRAM_MAP(sound_map)
234   MCFG_CPU_PERIODIC_INT(irq5_line_hold, 1)   // ???
235   MCFG_CPU_PERIODIC_INT_DRIVER(ultrsprt_state, irq5_line_hold, 1)   // ???
235236
236237   MCFG_QUANTUM_TIME(attotime::from_hz(12000))
237238
trunk/src/mame/drivers/senjyo.c
r17996r17997
8888   m_int_delay_kludge = 10;
8989}
9090
91static INTERRUPT_GEN( senjyo_interrupt )
91INTERRUPT_GEN_MEMBER(senjyo_state::senjyo_interrupt)
9292{
93   senjyo_state *state = device->machine().driver_data<senjyo_state>();
9493
95   if (state->m_int_delay_kludge == 0) device->execute().set_input_line(0, HOLD_LINE);
96   else state->m_int_delay_kludge--;
94   if (m_int_delay_kludge == 0) device.execute().set_input_line(0, HOLD_LINE);
95   else m_int_delay_kludge--;
9796}
9897
9998WRITE8_MEMBER(senjyo_state::flip_screen_w)
r17996r17997
572571   /* basic machine hardware */
573572   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz? */
574573   MCFG_CPU_PROGRAM_MAP(senjyo_map)
575   MCFG_CPU_VBLANK_INT("screen", senjyo_interrupt)
574   MCFG_CPU_VBLANK_INT_DRIVER("screen", senjyo_state, senjyo_interrupt)
576575
577576   MCFG_CPU_ADD("sub", Z80, 2000000)   /* 2 MHz? */
578577   MCFG_CPU_CONFIG(senjyo_daisy_chain)
trunk/src/mame/drivers/bzone.c
r17996r17997
244244 *
245245 *************************************/
246246
247static INTERRUPT_GEN( bzone_interrupt )
247INTERRUPT_GEN_MEMBER(bzone_state::bzone_interrupt)
248248{
249   if (device->machine().root_device().ioport("IN0")->read() & 0x10)
250      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
249   if (machine().root_device().ioport("IN0")->read() & 0x10)
250      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
251251}
252252
253253
r17996r17997
553553   /* basic machine hardware */
554554   MCFG_CPU_ADD("maincpu", M6502, BZONE_MASTER_CLOCK / 8)
555555   MCFG_CPU_PROGRAM_MAP(bzone_map)
556   MCFG_CPU_PERIODIC_INT(bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
556   MCFG_CPU_PERIODIC_INT_DRIVER(bzone_state, bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
557557
558558
559559   /* video hardware */
r17996r17997
584584   /* basic machine hardware */
585585   MCFG_CPU_MODIFY("maincpu")
586586   MCFG_CPU_PROGRAM_MAP(redbaron_map)
587   MCFG_CPU_PERIODIC_INT(bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
587   MCFG_CPU_PERIODIC_INT_DRIVER(bzone_state, bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
588588
589589   MCFG_MACHINE_START_OVERRIDE(bzone_state,redbaron)
590590
trunk/src/mame/drivers/spool99.c
r17996r17997
352352
353353   MCFG_CPU_ADD("maincpu", Z80, 24000000/8)
354354   MCFG_CPU_PROGRAM_MAP(spool99_map)
355   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
355   MCFG_CPU_VBLANK_INT_DRIVER("screen", spool99_state, irq0_line_hold)
356356
357357   MCFG_GFXDECODE(spool99)
358358
trunk/src/mame/drivers/simpl156.c
r17996r17997
383383
384384GFXDECODE_END
385385
386static INTERRUPT_GEN( simpl156_vbl_interrupt )
386INTERRUPT_GEN_MEMBER(simpl156_state::simpl156_vbl_interrupt)
387387{
388   device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
388   device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
389389}
390390
391391
r17996r17997
425425   /* basic machine hardware */
426426   MCFG_CPU_ADD("maincpu", ARM, 28000000 /* /4 */)   /*DE156*/ /* 7.000 MHz */ /* measured at 7.. seems to need 28? */
427427   MCFG_CPU_PROGRAM_MAP(chainrec_map)
428   MCFG_CPU_VBLANK_INT("screen", simpl156_vbl_interrupt)
428   MCFG_CPU_VBLANK_INT_DRIVER("screen", simpl156_state, simpl156_vbl_interrupt)
429429
430430   MCFG_EEPROM_93C46_ADD("eeprom")  // 93C45
431431
trunk/src/mame/drivers/lgp.c
r17996r17997
8787   DECLARE_DRIVER_INIT(lgp);
8888   virtual void machine_start();
8989   UINT32 screen_update_lgp(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
90   INTERRUPT_GEN_MEMBER(vblank_callback_lgp);
9091};
9192
9293
r17996r17997
336337   machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
337338}
338339
339static INTERRUPT_GEN( vblank_callback_lgp )
340INTERRUPT_GEN_MEMBER(lgp_state::vblank_callback_lgp)
340341{
341   lgp_state *state = device->machine().driver_data<lgp_state>();
342342   // NMI
343   //device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
343   //device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
344344
345345   // IRQ
346   device->execute().set_input_line(0, ASSERT_LINE);
347   state->m_irq_timer->adjust(attotime::from_usec(50));
346   device.execute().set_input_line(0, ASSERT_LINE);
347   m_irq_timer->adjust(attotime::from_usec(50));
348348}
349349
350350
r17996r17997
360360   MCFG_CPU_ADD("maincpu", Z80, CPU_PCB_CLOCK)
361361   MCFG_CPU_PROGRAM_MAP(main_program_map)
362362   MCFG_CPU_IO_MAP(main_io_map)
363   MCFG_CPU_VBLANK_INT("screen", vblank_callback_lgp)
363   MCFG_CPU_VBLANK_INT_DRIVER("screen", lgp_state, vblank_callback_lgp)
364364
365365   /* sound cpu */
366366   MCFG_CPU_ADD("audiocpu", Z80, SOUND_PCB_CLOCK)
trunk/src/mame/drivers/twincobr.c
r17996r17997
564564   /* basic machine hardware */
565565   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/4)      /* 7MHz - Main board Crystal is 28MHz */
566566   MCFG_CPU_PROGRAM_MAP(main_program_map)
567   MCFG_CPU_VBLANK_INT("screen", twincobr_interrupt)
567   MCFG_CPU_VBLANK_INT_DRIVER("screen", twincobr_state, twincobr_interrupt)
568568
569569   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)         /* 3.5MHz */
570570   MCFG_CPU_PROGRAM_MAP(sound_program_map)
trunk/src/mame/drivers/battlnts.c
r17996r17997
2525 *
2626 *************************************/
2727
28static INTERRUPT_GEN( battlnts_interrupt )
28INTERRUPT_GEN_MEMBER(battlnts_state::battlnts_interrupt)
2929{
30   battlnts_state *state = device->machine().driver_data<battlnts_state>();
31   if (k007342_is_int_enabled(state->m_k007342))
32      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
30   if (k007342_is_int_enabled(m_k007342))
31      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
3332}
3433
3534WRITE8_MEMBER(battlnts_state::battlnts_sh_irqtrigger_w)
r17996r17997
248247   /* basic machine hardware */
249248   MCFG_CPU_ADD("maincpu", HD6309, XTAL_24MHz / 2 /* 3000000*4? */)
250249   MCFG_CPU_PROGRAM_MAP(battlnts_map)
251   MCFG_CPU_VBLANK_INT("screen", battlnts_interrupt)
250   MCFG_CPU_VBLANK_INT_DRIVER("screen", battlnts_state, battlnts_interrupt)
252251
253252   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz / 6 /* 3579545? */)
254253   MCFG_CPU_PROGRAM_MAP(battlnts_sound_map)
trunk/src/mame/drivers/multfish.c
r17996r17997
10991099   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4)
11001100   MCFG_CPU_PROGRAM_MAP(multfish_map)
11011101   MCFG_CPU_IO_MAP(multfish_portmap)
1102   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
1102   MCFG_CPU_VBLANK_INT_DRIVER("screen", multfish_state, irq0_line_hold)
11031103
11041104
11051105   /* video hardware */
trunk/src/mame/drivers/sprint2.c
r17996r17997
6666}
6767
6868
69static INTERRUPT_GEN( sprint2 )
69INTERRUPT_GEN_MEMBER(sprint2_state::sprint2)
7070{
71   sprint2_state *state = device->machine().driver_data<sprint2_state>();
72   device_t *discrete = device->machine().device("discrete");
71   sprint2_state *state = machine().driver_data<sprint2_state>();
72   device_t *discrete = machine().device("discrete");
7373
7474   /* handle steering wheels */
7575
r17996r17997
7979
8080      for (i = 0; i < 2; i++)
8181      {
82         signed char delta = state->ioport(i ? "DIAL_P2" : "DIAL_P1")->read() - state->m_dial[i];
82         signed char delta = ioport(i ? "DIAL_P2" : "DIAL_P1")->read() - m_dial[i];
8383
8484         if (delta < 0)
8585         {
86            state->m_steering[i] = 0x00;
86            m_steering[i] = 0x00;
8787         }
8888         if (delta > 0)
8989         {
90            state->m_steering[i] = 0x40;
90            m_steering[i] = 0x40;
9191         }
9292
93         state->m_dial[i] += delta;
93         m_dial[i] += delta;
9494
95         switch (device->machine().root_device().ioport(i ? "GEAR_P2" : "GEAR_P1")->read() & 15)
95         switch (machine().root_device().ioport(i ? "GEAR_P2" : "GEAR_P1")->read() & 15)
9696         {
97         case 1: state->m_gear[i] = 1; break;
98         case 2: state->m_gear[i] = 2; break;
99         case 4: state->m_gear[i] = 3; break;
100         case 8: state->m_gear[i] = 4; break;
97         case 1: m_gear[i] = 1; break;
98         case 2: m_gear[i] = 2; break;
99         case 4: m_gear[i] = 3; break;
100         case 8: m_gear[i] = 4; break;
101101         }
102102      }
103103   }
104104
105   address_space &space = *device->machine().firstcpu->space(AS_PROGRAM);
106   discrete_sound_w(discrete, space, SPRINT2_MOTORSND1_DATA, state->m_video_ram[0x394] & 15);   // also DOMINOS_FREQ_DATA
107   discrete_sound_w(discrete, space, SPRINT2_MOTORSND2_DATA, state->m_video_ram[0x395] & 15);
108   discrete_sound_w(discrete, space, SPRINT2_CRASHSND_DATA, state->m_video_ram[0x396] & 15);   // also DOMINOS_AMP_DATA
105   address_space &space = *machine().firstcpu->space(AS_PROGRAM);
106   discrete_sound_w(discrete, space, SPRINT2_MOTORSND1_DATA, m_video_ram[0x394] & 15);   // also DOMINOS_FREQ_DATA
107   discrete_sound_w(discrete, space, SPRINT2_MOTORSND2_DATA, m_video_ram[0x395] & 15);
108   discrete_sound_w(discrete, space, SPRINT2_CRASHSND_DATA, m_video_ram[0x396] & 15);   // also DOMINOS_AMP_DATA
109109
110110   /* interrupts and watchdog are disabled during service mode */
111111
112   device->machine().watchdog_enable(!service_mode(device->machine()));
112   machine().watchdog_enable(!service_mode(machine()));
113113
114   if (!service_mode(device->machine()))
115      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
114   if (!service_mode(machine()))
115      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
116116}
117117
118118
r17996r17997
499499   /* basic machine hardware */
500500   MCFG_CPU_ADD("maincpu", M6502, XTAL_12_096MHz / 16)
501501   MCFG_CPU_PROGRAM_MAP(sprint2_map)
502   MCFG_CPU_VBLANK_INT("screen", sprint2)
502   MCFG_CPU_VBLANK_INT_DRIVER("screen", sprint2_state, sprint2)
503503   MCFG_WATCHDOG_VBLANK_INIT(8)
504504
505505   /* video hardware */
trunk/src/mame/drivers/dragrace.c
r17996r17997
332332   /* basic machine hardware */
333333   MCFG_CPU_ADD("maincpu", M6800, XTAL_12_096MHz / 12)
334334   MCFG_CPU_PROGRAM_MAP(dragrace_map)
335   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
335   MCFG_CPU_PERIODIC_INT_DRIVER(dragrace_state, irq0_line_hold, 4*60)
336336   MCFG_WATCHDOG_VBLANK_INIT(8)
337337
338338
trunk/src/mame/drivers/seibuspi.c
r17996r17997
17891789   1            /* reset_delay */
17901790};
17911791
1792static INTERRUPT_GEN( spi_interrupt )
1792INTERRUPT_GEN_MEMBER(seibuspi_state::spi_interrupt)
17931793{
1794   device->execute().set_input_line(0, ASSERT_LINE );
1794   device.execute().set_input_line(0, ASSERT_LINE );
17951795}
17961796
17971797static IRQ_CALLBACK(spi_irq_callback)
r17996r17997
18471847   /* basic machine hardware */
18481848   MCFG_CPU_ADD("maincpu", I386, 50000000/2)   /* Intel 386DX, 25MHz */
18491849   MCFG_CPU_PROGRAM_MAP(spi_map)
1850   MCFG_CPU_VBLANK_INT("screen", spi_interrupt)
1850   MCFG_CPU_VBLANK_INT_DRIVER("screen", seibuspi_state, spi_interrupt)
18511851
18521852   MCFG_CPU_ADD("soundcpu", Z80, 28636360/4)
18531853   MCFG_CPU_PROGRAM_MAP(spisound_map)
r17996r17997
21932193   /* basic machine hardware */
21942194   MCFG_CPU_ADD("maincpu", I386, 40000000)   /* AMD 386DX, 40MHz */
21952195   MCFG_CPU_PROGRAM_MAP(seibu386_map)
2196   MCFG_CPU_VBLANK_INT("screen", spi_interrupt)
2196   MCFG_CPU_VBLANK_INT_DRIVER("screen", seibuspi_state, spi_interrupt)
21972197
21982198   MCFG_MACHINE_RESET_OVERRIDE(seibuspi_state,seibu386)
21992199
r17996r17997
22462246   /* basic machine hardware */
22472247   MCFG_CPU_ADD("maincpu", I386, 25000000)   /* 25mhz */
22482248   MCFG_CPU_PROGRAM_MAP(sys386f2_map)
2249   MCFG_CPU_VBLANK_INT("screen", spi_interrupt)
2249   MCFG_CPU_VBLANK_INT_DRIVER("screen", seibuspi_state, spi_interrupt)
22502250
22512251   /* no z80? */
22522252
trunk/src/mame/drivers/sauro.c
r17996r17997
367367   GFXDECODE_ENTRY( "gfx2", 0, trckydoc_spritelayout, 0, 64 )
368368GFXDECODE_END
369369
370static INTERRUPT_GEN( sauro_interrupt )
370INTERRUPT_GEN_MEMBER(sauro_state::sauro_interrupt)
371371{
372   device->execute().set_input_line(0, HOLD_LINE);
372   device.execute().set_input_line(0, HOLD_LINE);
373373}
374374
375375static MACHINE_CONFIG_START( tecfri, sauro_state )
376376
377377   /* basic machine hardware */
378378   MCFG_CPU_ADD("maincpu", Z80, XTAL_20MHz/4)       /* verified on pcb */
379   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
379   MCFG_CPU_VBLANK_INT_DRIVER("screen", sauro_state, irq0_line_hold)
380380
381381   MCFG_NVRAM_ADD_1FILL("nvram")
382382
r17996r17997
419419
420420   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   // 4 MHz?
421421   MCFG_CPU_PROGRAM_MAP(sauro_sound_map)
422   MCFG_CPU_PERIODIC_INT(sauro_interrupt, 8*60) // ?
422   MCFG_CPU_PERIODIC_INT_DRIVER(sauro_state, sauro_interrupt, 8*60) // ?
423423
424424   MCFG_GFXDECODE(sauro)
425425
trunk/src/mame/drivers/timetrv.c
r17996r17997
4343   DECLARE_READ8_MEMBER(ld_r);
4444   virtual void video_start();
4545   UINT32 screen_update_timetrv(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(vblank_irq);
47   INTERRUPT_GEN_MEMBER(ld_irq);
4648};
4749
4850
r17996r17997
134136   // 0x80 eeprom read bit
135137INPUT_PORTS_END
136138
137static INTERRUPT_GEN( vblank_irq )
139INTERRUPT_GEN_MEMBER(timetrv_state::vblank_irq)
138140{
139   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x20/4); //vblank bit flag clear
141   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x20/4); //vblank bit flag clear
140142}
141143
142static INTERRUPT_GEN( ld_irq )
144INTERRUPT_GEN_MEMBER(timetrv_state::ld_irq)
143145{
144   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); //ld irq
146   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); //ld irq
145147}
146148
147149static MACHINE_CONFIG_START( timetrv, timetrv_state )
r17996r17997
150152   MCFG_CPU_ADD("maincpu",I80188,20000000) //???
151153   MCFG_CPU_PROGRAM_MAP(timetrv_map)
152154   MCFG_CPU_IO_MAP(timetrv_io)
153   MCFG_CPU_VBLANK_INT("screen",vblank_irq)
154   MCFG_CPU_PERIODIC_INT(ld_irq,60) //remove from here
155   MCFG_CPU_VBLANK_INT_DRIVER("screen", timetrv_state, vblank_irq)
156   MCFG_CPU_PERIODIC_INT_DRIVER(timetrv_state, ld_irq, 60) //remove from here
155157
156158   /* video hardware */
157159   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/drmicro.c
r17996r17997
2323 *
2424 *************************************/
2525
26static INTERRUPT_GEN( drmicro_interrupt )
26INTERRUPT_GEN_MEMBER(drmicro_state::drmicro_interrupt)
2727{
28   drmicro_state *state = device->machine().driver_data<drmicro_state>();
2928
30   if (state->m_nmi_enable)
31       device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
29   if (m_nmi_enable)
30       device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
3231}
3332
3433WRITE8_MEMBER(drmicro_state::nmi_enable_w)
r17996r17997
263262   MCFG_CPU_ADD("maincpu", Z80,MCLK/6)   /* 3.072MHz? */
264263   MCFG_CPU_PROGRAM_MAP(drmicro_map)
265264   MCFG_CPU_IO_MAP(io_map)
266   MCFG_CPU_VBLANK_INT("screen", drmicro_interrupt)
265   MCFG_CPU_VBLANK_INT_DRIVER("screen", drmicro_state, drmicro_interrupt)
267266
268267   MCFG_QUANTUM_TIME(attotime::from_hz(60))
269268
trunk/src/mame/drivers/system1.c
r17996r17997
591591}
592592
593593
594static INTERRUPT_GEN( mcu_irq_assert )
594INTERRUPT_GEN_MEMBER(system1_state::mcu_irq_assert)
595595{
596596   /* toggle the INT0 line on the MCU */
597   device->execute().set_input_line(MCS51_INT0_LINE, ASSERT_LINE);
598   device->execute().set_input_line(MCS51_INT0_LINE, CLEAR_LINE);
597   device.execute().set_input_line(MCS51_INT0_LINE, ASSERT_LINE);
598   device.execute().set_input_line(MCS51_INT0_LINE, CLEAR_LINE);
599599
600600   /* boost interleave to ensure that the MCU can break the Z80 out of a HALT */
601   device->machine().scheduler().boost_interleave(attotime::zero, attotime::from_usec(10));
601   machine().scheduler().boost_interleave(attotime::zero, attotime::from_usec(10));
602602}
603603
604604
r17996r17997
21472147   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK)   /* not really, see notes above */
21482148   MCFG_CPU_PROGRAM_MAP(system1_map)
21492149   MCFG_CPU_IO_MAP(system1_ppi_io_map)
2150   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
2150   MCFG_CPU_VBLANK_INT_DRIVER("screen", system1_state, irq0_line_hold)
21512151
21522152   MCFG_CPU_ADD("soundcpu", Z80, SOUND_CLOCK/2)
21532153   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
22202220
22212221   MCFG_CPU_ADD("mcu", I8751, SOUND_CLOCK)
22222222   MCFG_CPU_IO_MAP(mcu_io_map)
2223   MCFG_CPU_VBLANK_INT("screen", mcu_irq_assert)
2223   MCFG_CPU_VBLANK_INT_DRIVER("screen", system1_state, mcu_irq_assert)
22242224
22252225   MCFG_TIMER_ADD_PERIODIC("mcu_t0", mcu_t0_callback, attotime::from_usec(2500))   /* ??? actual clock unknown */
22262226MACHINE_CONFIG_END
trunk/src/mame/drivers/quizo.c
r17996r17997
208208   MCFG_CPU_PROGRAM_MAP(memmap)
209209   MCFG_CPU_IO_MAP(portmap)
210210
211   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
211   MCFG_CPU_VBLANK_INT_DRIVER("screen", quizo_state, irq0_line_hold)
212212
213213   /* video hardware */
214214   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/niyanpai.c
r17996r17997
926926INPUT_PORTS_END
927927
928928
929static INTERRUPT_GEN( niyanpai_interrupt )
929INTERRUPT_GEN_MEMBER(niyanpai_state::niyanpai_interrupt)
930930{
931   device->execute().set_input_line_and_vector(1, HOLD_LINE,0x100/4);
931   device.execute().set_input_line_and_vector(1, HOLD_LINE,0x100/4);
932932}
933933
934934static const z80_daisy_config daisy_chain_sound[] =
r17996r17997
943943   /* basic machine hardware */
944944   MCFG_CPU_ADD("maincpu", M68000, 12288000/2)   /* TMP68301, 6.144 MHz */
945945   MCFG_CPU_PROGRAM_MAP(niyanpai_map)
946   MCFG_CPU_VBLANK_INT("screen", niyanpai_interrupt)
946   MCFG_CPU_VBLANK_INT_DRIVER("screen", niyanpai_state, niyanpai_interrupt)
947947
948948   MCFG_CPU_ADD("audiocpu", Z80, 8000000)               /* TMPZ84C011, 8.00 MHz */
949949   MCFG_CPU_CONFIG(daisy_chain_sound)
trunk/src/mame/drivers/bfm_sc2.c
r17996r17997
302302   DECLARE_MACHINE_RESET(awp_init);
303303   DECLARE_MACHINE_START(sc2dmd);
304304   DECLARE_MACHINE_RESET(dm01_init);
305   INTERRUPT_GEN_MEMBER(timer_irq);
305306};
306307
307308
r17996r17997
503504
504505///////////////////////////////////////////////////////////////////////////
505506
506static INTERRUPT_GEN( timer_irq )
507INTERRUPT_GEN_MEMBER(bfm_sc2_state::timer_irq)
507508{
508   bfm_sc2_state *state = device->machine().driver_data<bfm_sc2_state>();
509   state->m_timercnt++;
509   m_timercnt++;
510510
511   if ( state->m_is_timer_enabled )
511   if ( m_is_timer_enabled )
512512   {
513      state->m_irq_timer_stat = 0x01;
514      state->m_irq_status     = 0x02;
513      m_irq_timer_stat = 0x01;
514      m_irq_status     = 0x02;
515515
516      generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
516      generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
517517   }
518518}
519519
r17996r17997
21572157   MCFG_QUANTUM_TIME(attotime::from_hz(960))                           // needed for serial communication !!
21582158   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 )   // 6809 CPU at 2 Mhz
21592159   MCFG_CPU_PROGRAM_MAP(memmap_vid)               // setup scorpion2 board memorymap
2160   MCFG_CPU_PERIODIC_INT(timer_irq, 1000)            // generate 1000 IRQ's per second
2160   MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000)            // generate 1000 IRQ's per second
21612161   MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
21622162
21632163   MCFG_BFMBD1_ADD("vfd0",0)
r17996r17997
37053705   MCFG_MACHINE_RESET_OVERRIDE(bfm_sc2_state,awp_init)
37063706   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 )
37073707   MCFG_CPU_PROGRAM_MAP(sc2_basemap)
3708   MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )
3708   MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000)
37093709   MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
37103710
37113711   MCFG_BFMBD1_ADD("vfd0",0)
r17996r17997
37393739   MCFG_QUANTUM_TIME(attotime::from_hz(960))                           // needed for serial communication !!
37403740   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 )
37413741   MCFG_CPU_PROGRAM_MAP(sc2_basemap)
3742   MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )
3742   MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000)
37433743   MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
37443744
37453745   MCFG_SPEAKER_STANDARD_MONO("mono")
trunk/src/mame/drivers/witch.c
r17996r17997
239239   TILE_GET_INFO_MEMBER(get_gfx1_tile_info);
240240   virtual void video_start();
241241   UINT32 screen_update_witch(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
242   INTERRUPT_GEN_MEMBER(witch_main_interrupt);
243   INTERRUPT_GEN_MEMBER(witch_sub_interrupt);
242244};
243245
244246
r17996r17997
779781   return 0;
780782}
781783
782static INTERRUPT_GEN( witch_main_interrupt )
784INTERRUPT_GEN_MEMBER(witch_state::witch_main_interrupt)
783785{
784   device->execute().set_input_line(0,ASSERT_LINE);
786   device.execute().set_input_line(0,ASSERT_LINE);
785787}
786788
787static INTERRUPT_GEN( witch_sub_interrupt )
789INTERRUPT_GEN_MEMBER(witch_state::witch_sub_interrupt)
788790{
789   device->execute().set_input_line(0,ASSERT_LINE);
791   device.execute().set_input_line(0,ASSERT_LINE);
790792}
791793
792794static MACHINE_CONFIG_START( witch, witch_state )
793795   /* basic machine hardware */
794796   MCFG_CPU_ADD("maincpu", Z80,8000000)       /* ? MHz */
795797   MCFG_CPU_PROGRAM_MAP(map_main)
796   MCFG_CPU_VBLANK_INT("screen", witch_main_interrupt)
798   MCFG_CPU_VBLANK_INT_DRIVER("screen", witch_state, witch_main_interrupt)
797799
798800   /* 2nd z80 */
799801   MCFG_CPU_ADD("sub", Z80,8000000)       /* ? MHz */
800802   MCFG_CPU_PROGRAM_MAP(map_sub)
801   MCFG_CPU_VBLANK_INT("screen", witch_sub_interrupt)
803   MCFG_CPU_VBLANK_INT_DRIVER("screen", witch_state, witch_sub_interrupt)
802804
803805   MCFG_NVRAM_ADD_0FILL("nvram")
804806
trunk/src/mame/drivers/luckgrln.c
r17996r17997
151151   TILE_GET_INFO_MEMBER(get_luckgrln_reel4_tile_info);
152152   virtual void video_start();
153153   UINT32 screen_update_luckgrln(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
154   INTERRUPT_GEN_MEMBER(luckgrln_irq);
154155};
155156
156157
r17996r17997
986987   NULL      /* update address callback */
987988};
988989
989static INTERRUPT_GEN( luckgrln_irq )
990INTERRUPT_GEN_MEMBER(luckgrln_state::luckgrln_irq)
990991{
991   luckgrln_state *state = device->machine().driver_data<luckgrln_state>();
992   if(state->m_nmi_enable)
993      device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
992   if(m_nmi_enable)
993      machine().device("maincpu")->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
994994}
995995
996996static MACHINE_CONFIG_START( luckgrln, luckgrln_state )
997997   MCFG_CPU_ADD("maincpu", Z180,8000000)
998998   MCFG_CPU_PROGRAM_MAP(mainmap)
999999   MCFG_CPU_IO_MAP(portmap)
1000   MCFG_CPU_VBLANK_INT("screen", luckgrln_irq)
1000   MCFG_CPU_VBLANK_INT_DRIVER("screen", luckgrln_state, luckgrln_irq)
10011001
10021002   MCFG_MC6845_ADD("crtc", H46505, 6000000/4, mc6845_intf)   /* unknown clock, hand tuned to get ~60 fps */
10031003
trunk/src/mame/drivers/sigmab98.c
r17996r17997
177177   DECLARE_MACHINE_RESET(sammymdl);
178178   UINT32 screen_update_sigmab98(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
179179   void screen_eof_sammymdl(screen_device &screen, bool state);
180   INTERRUPT_GEN_MEMBER(gegege_vblank_interrupt);
180181};
181182
182183
r17996r17997
16901691   7            // reset_delay (otherwise gegege will hang when saving settings)
16911692};
16921693
1693static INTERRUPT_GEN( gegege_vblank_interrupt )
1694INTERRUPT_GEN_MEMBER(sigmab98_state::gegege_vblank_interrupt)
16941695{
1695   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x5a);
1696   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x5a);
16961697}
16971698
16981699static MACHINE_CONFIG_START( gegege, sigmab98_state )
16991700   MCFG_CPU_ADD("maincpu", Z80, 10000000)   // !! TAXAN KY-80, clock @X1? !!
17001701   MCFG_CPU_PROGRAM_MAP(gegege_mem_map)
17011702   MCFG_CPU_IO_MAP(gegege_io_map)
1702   MCFG_CPU_VBLANK_INT("screen", gegege_vblank_interrupt)
1703   MCFG_CPU_VBLANK_INT_DRIVER("screen", sigmab98_state, gegege_vblank_interrupt)
17031704
17041705   MCFG_NVRAM_ADD_0FILL("nvram")
17051706   MCFG_EEPROM_ADD("eeprom", eeprom_intf)
trunk/src/mame/drivers/dynax.c
r17996r17997
117117   sprtmtch_update_irq(machine());
118118}
119119
120static INTERRUPT_GEN( sprtmtch_vblank_interrupt )
120INTERRUPT_GEN_MEMBER(dynax_state::sprtmtch_vblank_interrupt)
121121{
122   dynax_state *state = device->machine().driver_data<dynax_state>();
123   state->m_vblank_irq = 1;
124   sprtmtch_update_irq(device->machine());
122   m_vblank_irq = 1;
123   sprtmtch_update_irq(machine());
125124}
126125
127126static void sprtmtch_sound_callback( device_t *device, int state )
r17996r17997
162161   jantouki_update_irq(machine());
163162}
164163
165static INTERRUPT_GEN( jantouki_vblank_interrupt )
164INTERRUPT_GEN_MEMBER(dynax_state::jantouki_vblank_interrupt)
166165{
167   dynax_state *state = device->machine().driver_data<dynax_state>();
168   state->m_vblank_irq = 1;
169   jantouki_update_irq(device->machine());
166   m_vblank_irq = 1;
167   jantouki_update_irq(machine());
170168}
171169
172170
r17996r17997
181179   state->m_soundcpu->set_input_line_and_vector(0, irq ? ASSERT_LINE : CLEAR_LINE, 0xc7 | irq); /* rst $xx */
182180}
183181
184static INTERRUPT_GEN( jantouki_sound_vblank_interrupt )
182INTERRUPT_GEN_MEMBER(dynax_state::jantouki_sound_vblank_interrupt)
185183{
186   dynax_state *state = device->machine().driver_data<dynax_state>();
187   state->m_sound_vblank_irq = 1;
188   jantouki_sound_update_irq(device->machine());
184   m_sound_vblank_irq = 1;
185   jantouki_sound_update_irq(machine());
189186}
190187
191188WRITE8_MEMBER(dynax_state::jantouki_sound_vblank_ack_w)
r17996r17997
42884285   MCFG_CPU_ADD("maincpu",Z80,22000000 / 4)   /* 5.5MHz */
42894286   MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
42904287   MCFG_CPU_IO_MAP(hanamai_io_map)
4291   MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4288   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
42924289
42934290   MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
42944291   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
43454342   MCFG_CPU_ADD("maincpu",Z80,22000000 / 4)   /* 5.5MHz */
43464343   MCFG_CPU_PROGRAM_MAP(hnoridur_mem_map)
43474344   MCFG_CPU_IO_MAP(hnoridur_io_map)
4348   MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4345   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
43494346
43504347   MCFG_MACHINE_START_OVERRIDE(dynax_state,hnoridur)
43514348   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
43904387   MCFG_CPU_ADD("maincpu",Z80, XTAL_22MHz / 4)
43914388   MCFG_CPU_PROGRAM_MAP(hjingi_mem_map)
43924389   MCFG_CPU_IO_MAP(hjingi_io_map)
4393   MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4390   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
43944391
43954392   MCFG_MACHINE_START_OVERRIDE(dynax_state,hnoridur)
43964393   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
44484445   MCFG_CPU_ADD("maincpu", Z80,22000000 / 4)   /* 5.5MHz */
44494446   MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
44504447   MCFG_CPU_IO_MAP(sprtmtch_io_map)
4451   MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4448   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
44524449
44534450   MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
44544451   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
44904487   MCFG_CPU_ADD("maincpu",Z80,24000000/4)   /* 6 MHz? */
44914488   MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
44924489   MCFG_CPU_IO_MAP(mjfriday_io_map)
4493   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
4490   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, irq0_line_hold)
44944491
44954492   MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
44964493   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
45384535  what was it trying to do?
45394536  set an irq and clear it before its even taken? */
45404537
4541static INTERRUPT_GEN( yarunara_clock_interrupt )
4538INTERRUPT_GEN_MEMBER(dynax_state::yarunara_clock_interrupt)
45424539{
4543   dynax_state *state = device->machine().driver_data<dynax_state>();
4544   state->m_yarunara_clk_toggle ^= 1;
4540   m_yarunara_clk_toggle ^= 1;
45454541
4546   if (state->m_yarunara_clk_toggle == 1)
4547      state->m_sound_irq = 0;
4542   if (m_yarunara_clk_toggle == 1)
4543      m_sound_irq = 0;
45484544   else
4549      state->m_sound_irq = 1;
4545      m_sound_irq = 1;
45504546
4551   sprtmtch_update_irq(device->machine());
4547   sprtmtch_update_irq(machine());
45524548}
45534549
45544550static MSM6242_INTERFACE( yarunara_rtc_intf )
r17996r17997
45624558   MCFG_CPU_MODIFY("maincpu")
45634559   MCFG_CPU_PROGRAM_MAP(yarunara_mem_map)
45644560   MCFG_CPU_IO_MAP(yarunara_io_map)
4565   MCFG_CPU_PERIODIC_INT(yarunara_clock_interrupt, 60)   // RTC
4561   MCFG_CPU_PERIODIC_INT_DRIVER(dynax_state, yarunara_clock_interrupt, 60)   // RTC
45664562
45674563   MCFG_NVRAM_REPLACE_0FILL("nvram")
45684564
r17996r17997
46464642   MCFG_CPU_ADD("maincpu",Z80,22000000 / 4)   /* 5.5MHz */
46474643   MCFG_CPU_PROGRAM_MAP(jantouki_mem_map)
46484644   MCFG_CPU_IO_MAP(jantouki_io_map)
4649   MCFG_CPU_VBLANK_INT("top", jantouki_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4645   MCFG_CPU_VBLANK_INT_DRIVER("top", dynax_state, jantouki_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
46504646
46514647   MCFG_CPU_ADD("soundcpu",Z80,22000000 / 4)   /* 5.5MHz */
46524648   MCFG_CPU_PROGRAM_MAP(jantouki_sound_mem_map)
46534649   MCFG_CPU_IO_MAP(jantouki_sound_io_map)
4654   MCFG_CPU_VBLANK_INT("top", jantouki_sound_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4650   MCFG_CPU_VBLANK_INT_DRIVER("top", dynax_state, jantouki_sound_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
46554651
46564652   MCFG_MACHINE_START_OVERRIDE(dynax_state,jantouki)
46574653   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
47154711   state->m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0xfa);
47164712}
47174713
4718static INTERRUPT_GEN( mjelctrn_vblank_interrupt )
4714INTERRUPT_GEN_MEMBER(dynax_state::mjelctrn_vblank_interrupt)
47194715{
4720   dynax_state *state = device->machine().driver_data<dynax_state>();
47214716
47224717   // This is a kludge to avoid losing blitter interrupts
47234718   // there should be a vblank ack mechanism
4724   if (!state->m_blitter_irq)
4725      device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xf8);
4719   if (!m_blitter_irq)
4720      device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xf8);
47264721}
47274722
47284723static MACHINE_CONFIG_DERIVED( mjelctrn, hnoridur )
47294724   MCFG_CPU_MODIFY("maincpu")
47304725   MCFG_CPU_PROGRAM_MAP(nanajign_mem_map)
47314726   MCFG_CPU_IO_MAP(mjelctrn_io_map)
4732   MCFG_CPU_VBLANK_INT("screen", mjelctrn_vblank_interrupt)   /* IM 2 needs a vector on the data bus */
4727   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, mjelctrn_vblank_interrupt)   /* IM 2 needs a vector on the data bus */
47334728
47344729   MCFG_VIDEO_START_OVERRIDE(dynax_state,mjelctrn)
47354730MACHINE_CONFIG_END
r17996r17997
48264821   MCFG_CPU_ADD("maincpu",Z80,20000000 / 4)
48274822   MCFG_CPU_PROGRAM_MAP(yarunara_mem_map)
48284823   MCFG_CPU_IO_MAP(htengoku_io_map)
4829   MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4830   MCFG_CPU_PERIODIC_INT(yarunara_clock_interrupt, 60)   // RTC
4824   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state,  sprtmtch_vblank_interrupt)   /* IM 0 needs an opcode on the data bus */
4825   MCFG_CPU_PERIODIC_INT_DRIVER(dynax_state, yarunara_clock_interrupt,  60)   // RTC
48314826
48324827   MCFG_MACHINE_START_OVERRIDE(dynax_state,htengoku)
48334828   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
r17996r17997
49794974   MCFG_CPU_ADD("maincpu",TMP90841, XTAL_10MHz )   // ?
49804975   MCFG_CPU_PROGRAM_MAP(gekisha_map)
49814976   MCFG_CPU_IO_MAP(gekisha_io_map)
4982   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
4977   MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, irq0_line_hold)
49834978
49844979   MCFG_MACHINE_START_OVERRIDE(dynax_state,gekisha)
49854980   MCFG_MACHINE_RESET_OVERRIDE(dynax_state,gekisha)
trunk/src/mame/drivers/volfied.c
r17996r17997
261261   /* basic machine hardware */
262262   MCFG_CPU_ADD("maincpu", M68000, CPU_CLOCK)   /* 8MHz */
263263   MCFG_CPU_PROGRAM_MAP(main_map)
264   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
264   MCFG_CPU_VBLANK_INT_DRIVER("screen", volfied_state, irq4_line_hold)
265265
266266   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK)   /* 4MHz sound CPU, required to run the game */
267267   MCFG_CPU_PROGRAM_MAP(z80_map)
trunk/src/mame/drivers/dribling.c
r17996r17997
3838 *
3939 *************************************/
4040
41static INTERRUPT_GEN( dribling_irq_gen )
41INTERRUPT_GEN_MEMBER(dribling_state::dribling_irq_gen)
4242{
43   dribling_state *state = device->machine().driver_data<dribling_state>();
44   if (state->m_di)
45      device->execute().set_input_line(0, ASSERT_LINE);
43   if (m_di)
44      device.execute().set_input_line(0, ASSERT_LINE);
4645}
4746
4847
r17996r17997
305304   MCFG_CPU_ADD("maincpu", Z80, 5000000)
306305   MCFG_CPU_PROGRAM_MAP(dribling_map)
307306   MCFG_CPU_IO_MAP(io_map)
308   MCFG_CPU_VBLANK_INT("screen", dribling_irq_gen)
307   MCFG_CPU_VBLANK_INT_DRIVER("screen", dribling_state, dribling_irq_gen)
309308
310309   MCFG_I8255A_ADD( "ppi8255_0", ppi8255_0_intf )
311310   MCFG_I8255A_ADD( "ppi8255_1", ppi8255_1_intf )
trunk/src/mame/drivers/itech32.c
r17996r17997
414414}
415415
416416
417static INTERRUPT_GEN( generate_int1 )
417INTERRUPT_GEN_MEMBER(itech32_state::generate_int1)
418418{
419419   /* signal the NMI */
420   itech32_update_interrupts(device->machine(), 1, -1, -1);
421   if (FULL_LOGGING) logerror("------------ VBLANK (%d) --------------\n", device->machine().primary_screen->vpos());
420   itech32_update_interrupts(machine(), 1, -1, -1);
421   if (FULL_LOGGING) logerror("------------ VBLANK (%d) --------------\n", machine().primary_screen->vpos());
422422}
423423
424424
r17996r17997
16711671   /* basic machine hardware */
16721672   MCFG_CPU_ADD("maincpu", M68000, CPU_CLOCK)
16731673   MCFG_CPU_PROGRAM_MAP(timekill_map)
1674   MCFG_CPU_VBLANK_INT("screen", generate_int1)
1674   MCFG_CPU_VBLANK_INT_DRIVER("screen", itech32_state, generate_int1)
16751675
16761676   MCFG_CPU_ADD("soundcpu", M6809, SOUND_CLOCK/8)
16771677   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
17391739
17401740   MCFG_CPU_REPLACE("maincpu", M68EC020, CPU020_CLOCK)
17411741   MCFG_CPU_PROGRAM_MAP(itech020_map)
1742   MCFG_CPU_VBLANK_INT("screen", generate_int1)
1742   MCFG_CPU_VBLANK_INT_DRIVER("screen", itech32_state, generate_int1)
17431743
17441744   MCFG_CPU_MODIFY("soundcpu")
17451745   MCFG_CPU_PROGRAM_MAP(sound_020_map)
1746   MCFG_CPU_PERIODIC_INT(irq1_line_assert,4*60)
1746   MCFG_CPU_PERIODIC_INT_DRIVER(itech32_state, irq1_line_assert, 4*60)
17471747
17481748   /* via */
17491749   MCFG_DEVICE_REMOVE("via6522_0")
trunk/src/mame/drivers/mexico86.c
r17996r17997
477477
478478   MCFG_CPU_ADD("audiocpu", Z80, 24000000/4)      /* 6 MHz, Uses clock divided 24MHz OSC */
479479   MCFG_CPU_PROGRAM_MAP(mexico86_sound_map)
480   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
480   MCFG_CPU_VBLANK_INT_DRIVER("screen", mexico86_state, irq0_line_hold)
481481
482482   MCFG_CPU_ADD("mcu", M68705, 4000000) /* xtal is 4MHz, divided by 4 internally */
483483   MCFG_CPU_PROGRAM_MAP(mexico86_m68705_map)
484   MCFG_CPU_VBLANK_INT("screen",mexico86_m68705_interrupt)
484   MCFG_CPU_VBLANK_INT_DRIVER("screen", mexico86_state, mexico86_m68705_interrupt)
485485
486486   MCFG_CPU_ADD("sub", Z80, 8000000/2)      /* 4 MHz, Uses 8Mhz OSC */
487487   MCFG_CPU_PROGRAM_MAP(mexico86_sub_cpu_map)
488   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
488   MCFG_CPU_VBLANK_INT_DRIVER("screen", mexico86_state, irq0_line_hold)
489489
490490   MCFG_QUANTUM_TIME(attotime::from_hz(6000))    /* 100 CPU slices per frame - an high value to ensure proper synchronization of the CPUs */
491491
r17996r17997
532532   /* basic machine hardware */
533533
534534   MCFG_CPU_MODIFY("maincpu")
535   MCFG_CPU_VBLANK_INT("screen", kikikai_interrupt) // IRQs should be triggered by the MCU, but we don't have it
535   MCFG_CPU_VBLANK_INT_DRIVER("screen", mexico86_state, kikikai_interrupt) // IRQs should be triggered by the MCU, but we don't have it
536536
537537   MCFG_DEVICE_REMOVE("mcu")   // we don't have code for the MC6801U4
538538
trunk/src/mame/drivers/chaknpop.c
r17996r17997
375375   /* basic machine hardware */
376376   MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz / 6)   /* Verified on PCB */
377377   MCFG_CPU_PROGRAM_MAP(chaknpop_map)
378   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
378   MCFG_CPU_VBLANK_INT_DRIVER("screen", chaknpop_state, irq0_line_hold)
379379
380380
381381   /* video hardware */
trunk/src/mame/drivers/sspeedr.c
r17996r17997
190190   MCFG_CPU_ADD("maincpu", Z80, XTAL_19_968MHz/8)
191191   MCFG_CPU_PROGRAM_MAP(sspeedr_map)
192192   MCFG_CPU_IO_MAP(sspeedr_io_map)
193   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
193   MCFG_CPU_VBLANK_INT_DRIVER("screen", sspeedr_state, irq0_line_assert)
194194
195195   /* video hardware */
196196   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ashnojoe.c
r17996r17997
351351   /* basic machine hardware */
352352   MCFG_CPU_ADD("maincpu", M68000, 8000000)
353353   MCFG_CPU_PROGRAM_MAP(ashnojoe_map)
354   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
354   MCFG_CPU_VBLANK_INT_DRIVER("screen", ashnojoe_state, irq1_line_hold)
355355
356356   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
357357   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/popobear.c
r17996r17997
458458   MCFG_CPU_ADD("maincpu", M68000, XTAL_42MHz/4)  // XTAL CORRECT, DIVISOR GUESSED
459459   MCFG_CPU_PROGRAM_MAP(popobear_mem)
460460   // levels 2,3,5 look interesting
461   //MCFG_CPU_VBLANK_INT("screen",irq5_line_assert)
462   //MCFG_CPU_PERIODIC_INT(irq2_line_assert,120)
461   //MCFG_CPU_VBLANK_INT_DRIVER("screen", popobear_state, irq5_line_assert)
462   //MCFG_CPU_PERIODIC_INT_DRIVER(popobear_state, irq2_line_assert, 120)
463463   MCFG_TIMER_ADD_SCANLINE("scantimer", popobear_irq, "screen", 0, 1)
464464
465465   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/minivadr.c
r17996r17997
8383   /* basic machine hardware */
8484   MCFG_CPU_ADD("maincpu", Z80,24000000 / 6)       /* 4 MHz ? */
8585   MCFG_CPU_PROGRAM_MAP(minivadr_map)
86   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
86   MCFG_CPU_VBLANK_INT_DRIVER("screen", minivadr_state, irq0_line_hold)
8787
8888   /* video hardware */
8989   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mouser.c
r17996r17997
2525   m_nmi_enable = data;
2626}
2727
28static INTERRUPT_GEN( mouser_nmi_interrupt )
28INTERRUPT_GEN_MEMBER(mouser_state::mouser_nmi_interrupt)
2929{
30   mouser_state *state = device->machine().driver_data<mouser_state>();
3130
32   if (BIT(state->m_nmi_enable, 0))
31   if (BIT(m_nmi_enable, 0))
3332      nmi_line_pulse(device);
3433}
3534
r17996r17997
5453   m_audiocpu->set_input_line(INPUT_LINE_NMI, CLEAR_LINE);
5554}
5655
57static INTERRUPT_GEN( mouser_sound_nmi_assert )
56INTERRUPT_GEN_MEMBER(mouser_state::mouser_sound_nmi_assert)
5857{
59   mouser_state *state = device->machine().driver_data<mouser_state>();
60   if (BIT(state->m_nmi_enable, 0))
61      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
58   if (BIT(m_nmi_enable, 0))
59      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
6260}
6361
6462static ADDRESS_MAP_START( mouser_map, AS_PROGRAM, 8, mouser_state )
r17996r17997
205203   /* basic machine hardware */
206204   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz ? */
207205   MCFG_CPU_PROGRAM_MAP(mouser_map)
208   MCFG_CPU_VBLANK_INT("screen", mouser_nmi_interrupt) /* NMI is masked externally */
206   MCFG_CPU_VBLANK_INT_DRIVER("screen", mouser_state, mouser_nmi_interrupt) /* NMI is masked externally */
209207
210208   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ??? */
211209   MCFG_CPU_PROGRAM_MAP(mouser_sound_map)
212210   MCFG_CPU_IO_MAP(mouser_sound_io_map)
213   MCFG_CPU_PERIODIC_INT(mouser_sound_nmi_assert, 4*60) /* ??? This controls the sound tempo */
211   MCFG_CPU_PERIODIC_INT_DRIVER(mouser_state, mouser_sound_nmi_assert, 4*60) /* ??? This controls the sound tempo */
214212
215213
216214   /* video hardware */
trunk/src/mame/drivers/undrfire.c
r17996r17997
697697                 MACHINE DRIVERS
698698***********************************************************/
699699
700static INTERRUPT_GEN( undrfire_interrupt )
700INTERRUPT_GEN_MEMBER(undrfire_state::undrfire_interrupt)
701701{
702   undrfire_state *state = device->machine().driver_data<undrfire_state>();
703   state->m_frame_counter ^= 1;
704   device->execute().set_input_line(4, HOLD_LINE);
702   m_frame_counter ^= 1;
703   device.execute().set_input_line(4, HOLD_LINE);
705704}
706705
707706static const tc0100scn_interface undrfire_tc0100scn_intf =
r17996r17997
729728   /* basic machine hardware */
730729   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)   /* 16 MHz */
731730   MCFG_CPU_PROGRAM_MAP(undrfire_map)
732   MCFG_CPU_VBLANK_INT("screen", undrfire_interrupt)
731   MCFG_CPU_VBLANK_INT_DRIVER("screen", undrfire_state, undrfire_interrupt)
733732
734733   MCFG_EEPROM_ADD("eeprom", undrfire_eeprom_interface)
735734
r17996r17997
758757   /* basic machine hardware */
759758   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)   /* 16 MHz */
760759   MCFG_CPU_PROGRAM_MAP(cbombers_cpua_map)
761   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
760   MCFG_CPU_VBLANK_INT_DRIVER("screen", undrfire_state, irq4_line_hold)
762761
763762   MCFG_CPU_ADD("sub", M68000, 16000000)   /* 16 MHz */
764763   MCFG_CPU_PROGRAM_MAP(cbombers_cpub_map)
765   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
764   MCFG_CPU_VBLANK_INT_DRIVER("screen", undrfire_state, irq4_line_hold)
766765
767766   MCFG_QUANTUM_TIME(attotime::from_hz(480))   /* CPU slices - Need to interleave Cpu's 1 & 3 */
768767
trunk/src/mame/drivers/grchamp.c
r17996r17997
9090 *
9191 *************************************/
9292
93static INTERRUPT_GEN( grchamp_cpu0_interrupt )
93INTERRUPT_GEN_MEMBER(grchamp_state::grchamp_cpu0_interrupt)
9494{
95   grchamp_state *state = device->machine().driver_data<grchamp_state>();
9695
97   if (state->m_cpu0_out[0] & 0x01)
98      device->execute().set_input_line(0, ASSERT_LINE);
96   if (m_cpu0_out[0] & 0x01)
97      device.execute().set_input_line(0, ASSERT_LINE);
9998}
10099
101100
102static INTERRUPT_GEN( grchamp_cpu1_interrupt )
101INTERRUPT_GEN_MEMBER(grchamp_state::grchamp_cpu1_interrupt)
103102{
104   grchamp_state *state = device->machine().driver_data<grchamp_state>();
105103
106   if (state->m_cpu1_out[4] & 0x01)
107      device->execute().set_input_line(0, ASSERT_LINE);
104   if (m_cpu1_out[4] & 0x01)
105      device.execute().set_input_line(0, ASSERT_LINE);
108106}
109107
110108
r17996r17997
671669   MCFG_CPU_ADD("maincpu", Z80, PIXEL_CLOCK/2)
672670   MCFG_CPU_PROGRAM_MAP(main_map)
673671   MCFG_CPU_IO_MAP(main_portmap)
674   MCFG_CPU_VBLANK_INT("screen", grchamp_cpu0_interrupt)
672   MCFG_CPU_VBLANK_INT_DRIVER("screen", grchamp_state, grchamp_cpu0_interrupt)
675673
676674   /* GAME BOARD */
677675   MCFG_CPU_ADD("sub", Z80, PIXEL_CLOCK/2)
678676   MCFG_CPU_PROGRAM_MAP(sub_map)
679677   MCFG_CPU_IO_MAP(sub_portmap)
680   MCFG_CPU_VBLANK_INT("screen", grchamp_cpu1_interrupt)
678   MCFG_CPU_VBLANK_INT_DRIVER("screen", grchamp_state, grchamp_cpu1_interrupt)
681679
682680   /* SOUND BOARD */
683681   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/2)
684682   MCFG_CPU_PROGRAM_MAP(sound_map)
685   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)SOUND_CLOCK/4/16/16/10/16)
683   MCFG_CPU_PERIODIC_INT_DRIVER(grchamp_state, irq0_line_hold, (double)SOUND_CLOCK/4/16/16/10/16)
686684
687685   MCFG_WATCHDOG_VBLANK_INIT(8)
688686   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
trunk/src/mame/drivers/lkage.c
r17996r17997
556556   MCFG_CPU_ADD("maincpu", Z80, MAIN_CPU_CLOCK)
557557   MCFG_CPU_PROGRAM_MAP(lkage_map)
558558   MCFG_CPU_IO_MAP(lkage_io_map)
559   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
559   MCFG_CPU_VBLANK_INT_DRIVER("screen", lkage_state, irq0_line_hold)
560560
561561   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK)
562562   MCFG_CPU_PROGRAM_MAP(lkage_sound_map)
r17996r17997
602602   MCFG_CPU_ADD("maincpu", Z80,MAIN_CPU_CLOCK)
603603   MCFG_CPU_PROGRAM_MAP(lkage_map)
604604   MCFG_CPU_IO_MAP(lkage_io_map)
605   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
605   MCFG_CPU_VBLANK_INT_DRIVER("screen", lkage_state, irq0_line_hold)
606606
607607   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK)
608608   MCFG_CPU_PROGRAM_MAP(lkage_sound_map)
trunk/src/mame/drivers/goodejan.c
r17996r17997
6767   DECLARE_WRITE16_MEMBER(goodejan_gfxbank_w);
6868   DECLARE_READ16_MEMBER(mahjong_panel_r);
6969   DECLARE_WRITE16_MEMBER(mahjong_panel_w);
70   INTERRUPT_GEN_MEMBER(goodejan_irq);
7071};
7172
7273
r17996r17997
329330   GFXDECODE_ENTRY( "tx_gfx", 0, charlayout, 0x100, 0x10 ) /* Text */
330331GFXDECODE_END
331332
332static INTERRUPT_GEN( goodejan_irq )
333INTERRUPT_GEN_MEMBER(goodejan_state::goodejan_irq)
333334{
334   device->execute().set_input_line_and_vector(0,HOLD_LINE,0x208/4);
335   device.execute().set_input_line_and_vector(0,HOLD_LINE,0x208/4);
335336/* vector 0x00c is just a reti */
336337}
337338
r17996r17997
341342   MCFG_CPU_ADD("maincpu", V30, GOODEJAN_MHZ2/2)
342343   MCFG_CPU_PROGRAM_MAP(goodejan_map)
343344   MCFG_CPU_IO_MAP(goodejan_io_map)
344   MCFG_CPU_VBLANK_INT("screen",goodejan_irq)
345   MCFG_CPU_VBLANK_INT_DRIVER("screen", goodejan_state, goodejan_irq)
345346
346347   SEIBU_SOUND_SYSTEM_CPU(GOODEJAN_MHZ1/2)
347348
trunk/src/mame/drivers/gaiden.c
r17996r17997
764764   /* basic machine hardware */
765765   MCFG_CPU_ADD("maincpu", M68000, 18432000/2)   /* 9.216 MHz */
766766   MCFG_CPU_PROGRAM_MAP(gaiden_map)
767   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
767   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
768768
769769   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz */
770770   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
820820   /* basic machine hardware */
821821   MCFG_CPU_ADD("maincpu", M68000, 20000000/2)   /* 10 MHz */
822822   MCFG_CPU_PROGRAM_MAP(drgnbowl_map)
823   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
823   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
824824
825825   MCFG_CPU_ADD("audiocpu", Z80, 12000000/2)   /* 6 MHz */
826826   MCFG_CPU_PROGRAM_MAP(drgnbowl_sound_map)
r17996r17997
936936   /* basic machine hardware */
937937   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10 MHz? */
938938   MCFG_CPU_PROGRAM_MAP(mastninj_map)
939   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
939   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
940940
941941   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ?? MHz */
942942   MCFG_CPU_PROGRAM_MAP(mastninj_sound_map)
trunk/src/mame/drivers/trackfld.c
r17996r17997
883883   m_old_gfx_bank = 0;
884884}
885885
886static INTERRUPT_GEN( vblank_irq )
886INTERRUPT_GEN_MEMBER(trackfld_state::vblank_irq)
887887{
888   trackfld_state *state = device->machine().driver_data<trackfld_state>();
889888
890   if(state->m_irq_mask)
891      device->execute().set_input_line(0, HOLD_LINE);
889   if(m_irq_mask)
890      device.execute().set_input_line(0, HOLD_LINE);
892891}
893892
894static INTERRUPT_GEN( vblank_nmi )
893INTERRUPT_GEN_MEMBER(trackfld_state::vblank_nmi)
895894{
896   trackfld_state *state = device->machine().driver_data<trackfld_state>();
897895
898   if(state->m_irq_mask)
899      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
896   if(m_irq_mask)
897      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
900898}
901899
902900//-------------------------------------------------
r17996r17997
913911   /* basic machine hardware */
914912   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/6/2)   /* a guess for now */
915913   MCFG_CPU_PROGRAM_MAP(main_map)
916   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
914   MCFG_CPU_VBLANK_INT_DRIVER("screen", trackfld_state, vblank_irq)
917915
918916   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)
919917   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
953951MACHINE_CONFIG_END
954952
955953
956static INTERRUPT_GEN( yieartf_timer_irq )
954INTERRUPT_GEN_MEMBER(trackfld_state::yieartf_timer_irq)
957955{
958   trackfld_state *state = device->machine().driver_data<trackfld_state>();
959956
960   if (state->m_yieartf_nmi_mask)
961      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
957   if (m_yieartf_nmi_mask)
958      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
962959}
963960
964961static MACHINE_CONFIG_START( yieartf, trackfld_state )
r17996r17997
966963   /* basic machine hardware */
967964   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/6/2)   /* a guess for now */
968965   MCFG_CPU_PROGRAM_MAP(yieartf_map)
969   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
970   MCFG_CPU_PERIODIC_INT(yieartf_timer_irq,480)
966   MCFG_CPU_VBLANK_INT_DRIVER("screen", trackfld_state,  vblank_irq)
967   MCFG_CPU_PERIODIC_INT_DRIVER(trackfld_state, yieartf_timer_irq, 480)
971968
972969//  z80 isn't used
973970//  MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)
r17996r17997
10411038   // right cpu?
10421039   MCFG_CPU_REPLACE("maincpu",M6800,2048000)      /* 1.400 MHz ??? */
10431040   MCFG_CPU_PROGRAM_MAP(wizzquiz_map)
1044   MCFG_CPU_VBLANK_INT("screen", vblank_nmi)
1041   MCFG_CPU_VBLANK_INT_DRIVER("screen", trackfld_state, vblank_nmi)
10451042MACHINE_CONFIG_END
10461043
10471044static MACHINE_CONFIG_DERIVED( reaktor, trackfld )
r17996r17997
10501047   MCFG_CPU_REPLACE("maincpu",Z80,MASTER_CLOCK/6)
10511048   MCFG_CPU_PROGRAM_MAP(reaktor_map)
10521049   MCFG_CPU_IO_MAP(reaktor_io_map)
1053   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1050   MCFG_CPU_VBLANK_INT_DRIVER("screen", trackfld_state, vblank_irq)
10541051MACHINE_CONFIG_END
10551052
10561053
trunk/src/mame/drivers/peyper.c
r17996r17997
537537   MCFG_CPU_ADD("maincpu", Z80, 2500000)
538538   MCFG_CPU_PROGRAM_MAP(peyper_map)
539539   MCFG_CPU_IO_MAP(peyper_io)
540    MCFG_CPU_PERIODIC_INT(irq0_line_hold, 1250 * 2)
540   MCFG_CPU_PERIODIC_INT_DRIVER(peyper_state, irq0_line_hold, 1250 * 2)
541541
542542
543543    /* video hardware */
trunk/src/mame/drivers/tecmo.c
r17996r17997
633633   /* basic machine hardware */
634634   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4) /* verified on pcb */
635635   MCFG_CPU_PROGRAM_MAP(rygar_map)
636   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
636   MCFG_CPU_VBLANK_INT_DRIVER("screen", tecmo_state, irq0_line_hold)
637637
638638   MCFG_CPU_ADD("soundcpu", Z80, XTAL_4MHz) /* verified on pcb */
639639   MCFG_CPU_PROGRAM_MAP(rygar_sound_map)
r17996r17997
692692   /* basic machine hardware */
693693   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4)
694694   MCFG_CPU_PROGRAM_MAP(rygar_map)
695   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
695   MCFG_CPU_VBLANK_INT_DRIVER("screen", tecmo_state, irq0_line_hold)
696696
697697   MCFG_CPU_ADD("soundcpu", Z80, XTAL_8MHz/2)
698698   MCFG_CPU_PROGRAM_MAP(rygar_sound_map)
trunk/src/mame/drivers/speedspn.c
r17996r17997
273273   MCFG_CPU_ADD("maincpu",Z80,6000000)       /* 6 MHz */
274274   MCFG_CPU_PROGRAM_MAP(speedspn_map)
275275   MCFG_CPU_IO_MAP(speedspn_io_map)
276   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
276   MCFG_CPU_VBLANK_INT_DRIVER("screen", speedspn_state, irq0_line_hold)
277277
278278   MCFG_CPU_ADD("audiocpu", Z80,6000000)       /* 6 MHz */
279279   MCFG_CPU_PROGRAM_MAP(speedspn_sound_map)
trunk/src/mame/drivers/enigma2.c
r17996r17997
611611
612612   MCFG_CPU_ADD("audiocpu", Z80, 2500000)
613613   MCFG_CPU_PROGRAM_MAP(engima2_audio_cpu_map)
614   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*52)
614   MCFG_CPU_PERIODIC_INT_DRIVER(enigma2_state, irq0_line_hold, 8*52)
615615
616616
617617   /* video hardware */
r17996r17997
637637
638638   MCFG_CPU_ADD("audiocpu", Z80, 2500000)
639639   MCFG_CPU_PROGRAM_MAP(engima2_audio_cpu_map)
640   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*52)
640   MCFG_CPU_PERIODIC_INT_DRIVER(enigma2_state, irq0_line_hold, 8*52)
641641
642642
643643   /* video hardware */
trunk/src/mame/drivers/videopkr.c
r17996r17997
12371237   MCFG_CPU_PROGRAM_MAP(i8039_map)
12381238   MCFG_CPU_IO_MAP(i8039_io_port)
12391239
1240   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1240   MCFG_CPU_VBLANK_INT_DRIVER("screen", videopkr_state, irq0_line_assert)
12411241
12421242   MCFG_CPU_ADD("soundcpu", I8039, SOUND_CLOCK)
12431243   MCFG_CPU_PROGRAM_MAP(i8039_sound_mem)
trunk/src/mame/drivers/mil4000.c
r17996r17997
372372   MCFG_CPU_ADD("maincpu", M68000, 12000000 )   // ?
373373   MCFG_CPU_PROGRAM_MAP(mil4000_map)
374374   // irq 2/4/5 point to the same place, others invalid
375   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
375   MCFG_CPU_VBLANK_INT_DRIVER("screen", mil4000_state, irq5_line_hold)
376376
377377   MCFG_NVRAM_ADD_0FILL("nvram")
378378
trunk/src/mame/drivers/koikoi.c
r17996r17997
365365   MCFG_CPU_ADD("maincpu", Z80,KOIKOI_CRYSTAL/4)   /* ?? */
366366   MCFG_CPU_PROGRAM_MAP(koikoi_map)
367367   MCFG_CPU_IO_MAP(koikoi_io_map)
368   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
368   MCFG_CPU_VBLANK_INT_DRIVER("screen", koikoi_state, nmi_line_pulse)
369369
370370
371371   /* video hardware */
trunk/src/mame/drivers/gticlub.c
r17996r17997
263263   DECLARE_MACHINE_START(gticlub);
264264   DECLARE_MACHINE_RESET(gticlub);
265265   DECLARE_MACHINE_RESET(hangplt);
266   INTERRUPT_GEN_MEMBER(gticlub_vblank);
266267};
267268
268269
r17996r17997
694695    DMA0
695696
696697*/
697static INTERRUPT_GEN( gticlub_vblank )
698INTERRUPT_GEN_MEMBER(gticlub_state::gticlub_vblank)
698699{
699   device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
700   device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
700701}
701702
702703
r17996r17997
806807   /* basic machine hardware */
807808   MCFG_CPU_ADD("maincpu", PPC403GA, 64000000/2)   /* PowerPC 403GA 32MHz */
808809   MCFG_CPU_PROGRAM_MAP(gticlub_map)
809   MCFG_CPU_VBLANK_INT("screen", gticlub_vblank)
810   MCFG_CPU_VBLANK_INT_DRIVER("screen", gticlub_state, gticlub_vblank)
810811
811812   MCFG_CPU_ADD("audiocpu", M68000, 64000000/4)   /* 16MHz */
812813   MCFG_CPU_PROGRAM_MAP(sound_memmap)
trunk/src/mame/drivers/mazerbla.c
r17996r17997
145145   virtual void palette_init();
146146   UINT32 screen_update_mazerbla(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
147147   UINT32 screen_update_test_vcu(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
148   INTERRUPT_GEN_MEMBER(sound_interrupt);
148149};
149150
150151
r17996r17997
14211422}
14221423
14231424/* frequency is 14.318 MHz/16/16/16/16 */
1424static INTERRUPT_GEN( sound_interrupt )
1425INTERRUPT_GEN_MEMBER(mazerbla_state::sound_interrupt)
14251426{
1426   device->execute().set_input_line(0, ASSERT_LINE);
1427   device.execute().set_input_line(0, ASSERT_LINE);
14271428}
14281429
14291430
r17996r17997
15161517   MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK)   /* 4 MHz, NMI, IM1 INT */
15171518   MCFG_CPU_PROGRAM_MAP(mazerbla_cpu2_map)
15181519   MCFG_CPU_IO_MAP(mazerbla_cpu2_io_map)
1519//  MCFG_CPU_PERIODIC_INT(irq0_line_hold, 400 ) /* frequency in Hz */
1520   MCFG_CPU_PERIODIC_INT_DRIVER(mazerbla_state, irq0_line_hold, 400) /* frequency in Hz */
15201521
15211522   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK)   /* 4 MHz, no  NMI, IM1 INT */
15221523   MCFG_CPU_PROGRAM_MAP(mazerbla_cpu3_map)
r17996r17997
15251526    and cleared on ANY port access.
15261527    but handled differently for now
15271528    */
1528   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1529   MCFG_CPU_VBLANK_INT_DRIVER("screen", mazerbla_state, irq0_line_hold)
15291530
15301531   /* synchronization forced on the fly */
15311532
r17996r17997
15531554
15541555   MCFG_CPU_ADD("sub", Z80, SOUND_CLOCK / 4)   /* 3.579500 MHz, NMI - caused by sound command write, periodic INT */
15551556   MCFG_CPU_PROGRAM_MAP(greatgun_sound_map)
1556   MCFG_CPU_PERIODIC_INT(sound_interrupt, (double)14318180/16/16/16/16 )
1557   MCFG_CPU_PERIODIC_INT_DRIVER(mazerbla_state, sound_interrupt, (double)14318180/16/16/16/16 )
15571558
15581559   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK)   /* 4 MHz, no  NMI, IM1 INT */
15591560   MCFG_CPU_PROGRAM_MAP(mazerbla_cpu3_map)
r17996r17997
15621563    and cleared on ANY port access.
15631564    but handled differently for now
15641565    */
1565   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1566   MCFG_CPU_VBLANK_INT_DRIVER("screen", mazerbla_state, irq0_line_hold)
15661567
15671568
15681569   /* video hardware */
trunk/src/mame/drivers/armedf.c
r17996r17997
11791179   /* basic machine hardware */
11801180   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
11811181   MCFG_CPU_PROGRAM_MAP(terraf_map)
1182   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
1182   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
11831183
11841184   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
11851185   MCFG_CPU_PROGRAM_MAP(sound_map)
11861186   MCFG_CPU_IO_MAP(sound_portmap)
1187   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1187   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
11881188
11891189   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
11901190   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
12241224   /* basic machine hardware */
12251225   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
12261226   MCFG_CPU_PROGRAM_MAP(terraf_map)
1227   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
1227   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
12281228
12291229   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
12301230   MCFG_CPU_PROGRAM_MAP(sound_map)
12311231   MCFG_CPU_IO_MAP(sound_portmap)
1232   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1232   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
12331233
12341234   MCFG_CPU_ADD("extra", Z80, XTAL_8MHz/2)         // 4mhz?
12351235   MCFG_CPU_PROGRAM_MAP(terrafb_extraz80_map)
r17996r17997
12721272   /* basic machine hardware */
12731273   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
12741274   MCFG_CPU_PROGRAM_MAP(kozure_map)
1275   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
1275   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
12761276
12771277   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
12781278   MCFG_CPU_PROGRAM_MAP(sound_map)
12791279   MCFG_CPU_IO_MAP(sound_portmap)
1280   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1280   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
12811281
12821282   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
12831283   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
13161316   /* basic machine hardware */
13171317   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
13181318   MCFG_CPU_PROGRAM_MAP(armedf_map)
1319   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
1319   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
13201320
13211321   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
13221322   MCFG_CPU_PROGRAM_MAP(sound_map)
13231323   MCFG_CPU_IO_MAP(sound_portmap)
1324   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1324   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
13251325
13261326   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
13271327   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
13601360   /* basic machine hardware */
13611361   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
13621362   MCFG_CPU_PROGRAM_MAP(cclimbr2_map)
1363   MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
1363   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
13641364
13651365   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
13661366   MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
13671367   MCFG_CPU_IO_MAP(sound_portmap)
1368   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1368   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
13691369
13701370   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
13711371   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
14041404   /* basic machine hardware */
14051405   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
14061406   MCFG_CPU_PROGRAM_MAP(legion_map)
1407   MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
1407   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
14081408
14091409   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
14101410   MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
14111411   MCFG_CPU_IO_MAP(sound_portmap)
1412   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1412   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
14131413
14141414   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
14151415   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
14481448   /* basic machine hardware */
14491449   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // 8mhz?
14501450   MCFG_CPU_PROGRAM_MAP(legiono_map)
1451   MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
1451   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
14521452
14531453   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
14541454   MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
14551455   MCFG_CPU_IO_MAP(sound_portmap)
1456   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1456   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
14571457
14581458   MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
14591459   MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
r17996r17997
15051505
15061506   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   // verified
15071507   MCFG_CPU_PROGRAM_MAP(bigfghtr_map)
1508   MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
1508   MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
15091509
15101510   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)      // 4mhz?
15111511   MCFG_CPU_PROGRAM_MAP(sound_map)
15121512   MCFG_CPU_IO_MAP(sound_portmap)
1513   MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512)   // ?
1513   MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512)   // ?
15141514
15151515   MCFG_MACHINE_START_OVERRIDE(bigfghtr_state,bigfghtr)
15161516   MCFG_MACHINE_RESET_OVERRIDE(bigfghtr_state,bigfghtr)
trunk/src/mame/drivers/dkong.c
r17996r17997
389389 *
390390 *************************************/
391391
392static INTERRUPT_GEN( s2650_interrupt )
392INTERRUPT_GEN_MEMBER(dkong_state::s2650_interrupt)
393393{
394    device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
394    device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
395395}
396396
397397/*************************************
r17996r17997
16381638 *
16391639 *************************************/
16401640
1641static INTERRUPT_GEN( vblank_irq )
1641INTERRUPT_GEN_MEMBER(dkong_state::vblank_irq)
16421642{
1643   dkong_state *state = device->machine().driver_data<dkong_state>();
16441643
1645   if(state->m_nmi_mask)
1646      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
1644   if(m_nmi_mask)
1645      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
16471646}
16481647
16491648static MACHINE_CONFIG_START( dkong_base, dkong_state )
r17996r17997
16511650    /* basic machine hardware */
16521651    MCFG_CPU_ADD("maincpu", Z80, CLOCK_1H)
16531652    MCFG_CPU_PROGRAM_MAP(dkong_map)
1654    MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1653   MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, vblank_irq)
16551654
16561655    MCFG_MACHINE_START_OVERRIDE(dkong_state,dkong2b)
16571656    MCFG_MACHINE_RESET_OVERRIDE(dkong_state,dkong)
r17996r17997
17151714    MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz / 2) /* verified in schematics */
17161715    MCFG_CPU_PROGRAM_MAP(dkong3_map)
17171716    MCFG_CPU_IO_MAP(dkong3_io_map)
1718    MCFG_CPU_VBLANK_INT("screen", vblank_irq)
1717   MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, vblank_irq)
17191718
17201719    MCFG_MACHINE_START_OVERRIDE(dkong_state,dkong3)
17211720
r17996r17997
17741773    MCFG_CPU_REPLACE("maincpu", S2650, CLOCK_1H / 2)    /* ??? */
17751774    MCFG_CPU_PROGRAM_MAP(s2650_map)
17761775    MCFG_CPU_IO_MAP(s2650_io_map)
1777    MCFG_CPU_VBLANK_INT("screen", s2650_interrupt)
1776   MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, s2650_interrupt)
17781777
17791778    MCFG_DEVICE_MODIFY("dma8257")
17801779    MCFG_DEVICE_CONFIG(hb_dma)
trunk/src/mame/drivers/acefruit.c
r17996r17997
4040   virtual void video_start();
4141   virtual void palette_init();
4242   UINT32 screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(acefruit_vblank);
4344};
4445
4546
r17996r17997
8384   m_refresh_timer = machine().scheduler().timer_alloc(FUNC(acefruit_refresh));
8485}
8586
86static INTERRUPT_GEN( acefruit_vblank )
87INTERRUPT_GEN_MEMBER(acefruit_state::acefruit_vblank)
8788{
88   acefruit_state *state = device->machine().driver_data<acefruit_state>();
89   device->execute().set_input_line(0, HOLD_LINE );
90   state->m_refresh_timer->adjust( attotime::zero );
89   device.execute().set_input_line(0, HOLD_LINE );
90   m_refresh_timer->adjust( attotime::zero );
9191}
9292
9393UINT32 acefruit_state::screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
r17996r17997
584584   MCFG_CPU_PROGRAM_MAP(acefruit_map)
585585   MCFG_CPU_IO_MAP(acefruit_io)
586586   MCFG_GFXDECODE(acefruit)
587   MCFG_CPU_VBLANK_INT("screen", acefruit_vblank)
587   MCFG_CPU_VBLANK_INT_DRIVER("screen", acefruit_state, acefruit_vblank)
588588
589589   /* video hardware */
590590   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/appoooh.c
r17996r17997
429429   m_priority = 0;
430430}
431431
432static INTERRUPT_GEN( vblank_irq )
432INTERRUPT_GEN_MEMBER(appoooh_state::vblank_irq)
433433{
434   appoooh_state *state = device->machine().driver_data<appoooh_state>();
435434
436   if(state->m_nmi_mask)
437      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
435   if(m_nmi_mask)
436      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
438437}
439438
440439static MACHINE_CONFIG_START( appoooh_common, appoooh_state )
r17996r17997
443442   MCFG_CPU_ADD("maincpu", Z80,18432000/6)   /* ??? the main xtal is 18.432 MHz */
444443   MCFG_CPU_PROGRAM_MAP(main_map)
445444   MCFG_CPU_IO_MAP(main_portmap)
446   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
445   MCFG_CPU_VBLANK_INT_DRIVER("screen", appoooh_state, vblank_irq)
447446
448447
449448   /* sound hardware */
trunk/src/mame/drivers/travrusa.c
r17996r17997
301301   /* basic machine hardware */
302302   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz (?) */
303303   MCFG_CPU_PROGRAM_MAP(main_map)
304   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
304   MCFG_CPU_VBLANK_INT_DRIVER("screen", travrusa_state, irq0_line_hold)
305305
306306
307307   /* video hardware */
trunk/src/mame/drivers/goldstar.c
r17996r17997
58575857   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
58585858   MCFG_CPU_PROGRAM_MAP(goldstar_map)
58595859   MCFG_CPU_IO_MAP(goldstar_readport)
5860   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
5860   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
58615861
58625862   /* video hardware */
58635863   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
58915891   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
58925892   MCFG_CPU_PROGRAM_MAP(goldstar_map)
58935893   MCFG_CPU_IO_MAP(goldstar_readport)
5894   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
5894   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
58955895
58965896   /* video hardware */
58975897   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
59245924   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
59255925   MCFG_CPU_PROGRAM_MAP(goldstar_map)
59265926   MCFG_CPU_IO_MAP(goldstar_readport)
5927   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
5927   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
59285928
59295929   /* video hardware */
59305930   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
60186018   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
60196019   MCFG_CPU_PROGRAM_MAP(ncb3_map)
60206020   MCFG_CPU_IO_MAP(ncb3_readwriteport)
6021   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6021   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
60226022
60236023   /* 3x 8255 */
60246024   MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
r17996r17997
60606060   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
60616061   MCFG_CPU_PROGRAM_MAP(ncb3_map)
60626062   MCFG_CPU_IO_MAP(ncb3_readwriteport)
6063   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6063   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
60646064
60656065   /* 3x 8255 */
60666066   MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
r17996r17997
61016101   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
61026102   MCFG_CPU_PROGRAM_MAP(ncb3_map)
61036103   MCFG_CPU_IO_MAP(ncb3_readwriteport)
6104   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6104   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
61056105
61066106   /* 3x 8255 */
61076107   MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
r17996r17997
61436143   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
61446144   MCFG_CPU_PROGRAM_MAP(cm_map)
61456145   MCFG_CPU_IO_MAP(cm_portmap)
6146   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6146   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
61476147
61486148   /* 2x 8255 */
61496149   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
61836183   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
61846184   MCFG_CPU_PROGRAM_MAP(cm_map)
61856185   MCFG_CPU_IO_MAP(cm_portmap)
6186   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6186   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
61876187
61886188   /* 2x 8255 */
61896189   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
62186218   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
62196219   MCFG_CPU_PROGRAM_MAP(cm_map)
62206220   MCFG_CPU_IO_MAP(cmast91_portmap)
6221   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6221   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
62226222
62236223   /* 2x 8255 */
62246224   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
62466246   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
62476247MACHINE_CONFIG_END
62486248
6249static INTERRUPT_GEN( lucky8_irq )
6249INTERRUPT_GEN_MEMBER(goldstar_state::lucky8_irq)
62506250{
6251   goldstar_state *state = device->machine().driver_data<goldstar_state>();
62526251
6253   if(state->m_lucky8_nmi_enable)
6254      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
6252   if(m_lucky8_nmi_enable)
6253      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
62556254}
62566255
62576256static MACHINE_CONFIG_START( lucky8, goldstar_state )
r17996r17997
62606259   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
62616260   MCFG_CPU_PROGRAM_MAP(lucky8_map)
62626261   //MCFG_CPU_IO_MAP(goldstar_readport)
6263   MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
6262   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
62646263
62656264   /* 3x 8255 */
62666265   MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
r17996r17997
63006299   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
63016300   MCFG_CPU_PROGRAM_MAP(lucky8_map)
63026301   //MCFG_CPU_IO_MAP(goldstar_readport)
6303   MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
6302   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
63046303
63056304   /* 3x 8255 */
63066305   MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
r17996r17997
63406339   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
63416340   MCFG_CPU_PROGRAM_MAP(lucky8_map)
63426341   //MCFG_CPU_IO_MAP(goldstar_readport)
6343   MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
6342   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
63446343
63456344   /* 3x 8255 */
63466345   MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
r17996r17997
63976396   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
63986397   MCFG_CPU_PROGRAM_MAP(magodds_map)
63996398   //MCFG_CPU_IO_MAP(goldstar_readport)
6400   MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
6399   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
64016400
64026401   /* 3x 8255 */
64036402   MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
r17996r17997
64386437   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
64396438   MCFG_CPU_PROGRAM_MAP(kkotnoli_map)
64406439   //MCFG_CPU_IO_MAP(goldstar_readport)
6441   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
6440   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
64426441
64436442
64446443   /* 3x 8255 */
r17996r17997
64766475   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
64776476   MCFG_CPU_PROGRAM_MAP(ladylinr_map)
64786477   //MCFG_CPU_IO_MAP(goldstar_readport)
6479   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
6478   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
64806479
64816480   /* 2x 8255 */
64826481   MCFG_I8255A_ADD( "ppi8255_0", ladylinr_ppi8255_0_intf )
r17996r17997
65166515   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
65176516   MCFG_CPU_PROGRAM_MAP(wcat3_map)
65186517   //MCFG_CPU_IO_MAP(goldstar_readport)
6519   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
6518   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
65206519
65216520   /* 3x 8255 */
65226521   MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
r17996r17997
65596558   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
65606559   MCFG_CPU_PROGRAM_MAP(cm_map)
65616560   MCFG_CPU_IO_MAP(amcoe1_portmap)
6562   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6561   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
65636562
65646563   /* 2x 8255 */
65656564   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
65986597   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
65996598   MCFG_CPU_PROGRAM_MAP(cm_map)
66006599   MCFG_CPU_IO_MAP(amcoe1_portmap)
6601   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6600   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
66026601
66036602   /* 2x 8255 */
66046603   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
66376636   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
66386637   MCFG_CPU_PROGRAM_MAP(cm_map)
66396638   MCFG_CPU_IO_MAP(amcoe2_portmap)
6640   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6639   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
66416640
66426641   /* 2x 8255 */
66436642   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
66716670   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
66726671   MCFG_CPU_PROGRAM_MAP(nfm_map)
66736672   MCFG_CPU_IO_MAP(amcoe2_portmap)
6674   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6673   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
66756674
66766675   /* 2x 8255 */
66776676   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
r17996r17997
67056704   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
67066705   MCFG_CPU_PROGRAM_MAP(unkch_map)
67076706   MCFG_CPU_IO_MAP(unkch_portmap)
6708   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
6709   //MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6707   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state,  nmi_line_pulse)
6708   //MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state,  irq0_line_hold)
67106709
67116710   /* video hardware */
67126711   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
67506749   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
67516750   MCFG_CPU_PROGRAM_MAP(cm_map)
67526751   MCFG_CPU_IO_MAP(cm_portmap)
6753   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
6752   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
67546753
67556754   /* 2x 8255 */
67566755   MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
trunk/src/mame/drivers/skylncr.c
r17996r17997
109109   TILE_GET_INFO_MEMBER(get_reel_4_tile_info);
110110   virtual void video_start();
111111   UINT32 screen_update_skylncr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
112   INTERRUPT_GEN_MEMBER(skylncr_vblank_interrupt);
112113};
113114
114115
r17996r17997
695696
696697
697698// It runs in IM 0, thus needs an opcode on the data bus
698static INTERRUPT_GEN( skylncr_vblank_interrupt )
699INTERRUPT_GEN_MEMBER(skylncr_state::skylncr_vblank_interrupt)
699700{
700   skylncr_state *state = device->machine().driver_data<skylncr_state>();
701   if (state->m_nmi_enable) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
701   if (m_nmi_enable) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
702702}
703703
704704
r17996r17997
712712   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
713713   MCFG_CPU_PROGRAM_MAP(mem_map_skylncr)
714714   MCFG_CPU_IO_MAP(io_map_skylncr)
715   MCFG_CPU_VBLANK_INT("screen", skylncr_vblank_interrupt)
715   MCFG_CPU_VBLANK_INT_DRIVER("screen", skylncr_state, skylncr_vblank_interrupt)
716716
717717   MCFG_NVRAM_ADD_0FILL("nvram")
718718
trunk/src/mame/drivers/20pacgal.c
r17996r17997
360360   m_game_selected = 0;
361361}
362362
363static INTERRUPT_GEN( vblank_irq )
363INTERRUPT_GEN_MEMBER(_20pacgal_state::vblank_irq)
364364{
365   _20pacgal_state *state = device->machine().driver_data<_20pacgal_state>();
366365
367   if(state->m_irq_mask)
368      device->execute().set_input_line(0, HOLD_LINE); // TODO: assert breaks the inputs in 25pacman test mode
366   if(m_irq_mask)
367      device.execute().set_input_line(0, HOLD_LINE); // TODO: assert breaks the inputs in 25pacman test mode
369368}
370369
371370static MACHINE_CONFIG_START( 20pacgal, _20pacgal_state )
r17996r17997
374373   MCFG_CPU_ADD("maincpu", Z180, MAIN_CPU_CLOCK)
375374   MCFG_CPU_PROGRAM_MAP(20pacgal_map)
376375   MCFG_CPU_IO_MAP(20pacgal_io_map)
377   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
376   MCFG_CPU_VBLANK_INT_DRIVER("screen", _20pacgal_state, vblank_irq)
378377
379378
380379   MCFG_EEPROM_ADD("eeprom", _20pacgal_eeprom_intf)
trunk/src/mame/drivers/seicross.c
r17996r17997
388388   DEVCB_DRIVER_MEMBER(seicross_state,friskyt_portB_w)
389389};
390390
391static INTERRUPT_GEN( vblank_irq )
391INTERRUPT_GEN_MEMBER(seicross_state::vblank_irq)
392392{
393   seicross_state *state = device->machine().driver_data<seicross_state>();
394393
395   if(state->m_irq_mask)
396      device->execute().set_input_line(0, HOLD_LINE);
394   if(m_irq_mask)
395      device.execute().set_input_line(0, HOLD_LINE);
397396
398397}
399398
r17996r17997
404403   MCFG_CPU_ADD("maincpu", Z80, 3072000)   /* 3.072 MHz? */
405404   MCFG_CPU_PROGRAM_MAP(main_map)
406405   MCFG_CPU_IO_MAP(main_portmap)
407   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
406   MCFG_CPU_VBLANK_INT_DRIVER("screen", seicross_state, vblank_irq)
408407
409408   MCFG_CPU_ADD("mcu", NSC8105, 3072000)   /* ??? */
410409   MCFG_CPU_PROGRAM_MAP(mcu_nvram_map)
trunk/src/mame/drivers/spbactn.c
r17996r17997
349349   /* basic machine hardware */
350350   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)
351351   MCFG_CPU_PROGRAM_MAP(spbactn_map)
352   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)
352   MCFG_CPU_VBLANK_INT_DRIVER("screen", spbactn_state, irq3_line_hold)
353353
354354   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz)
355355   MCFG_CPU_PROGRAM_MAP(spbactn_sound_map)
trunk/src/mame/drivers/system16.c
r17996r17997
100100#define SHADOW_COLORS_MULTIPLIER 2
101101
102102
103static INTERRUPT_GEN( sys16_interrupt )
103INTERRUPT_GEN_MEMBER(segas1x_bootleg_state::sys16_interrupt)
104104{
105   device->execute().set_input_line(4, HOLD_LINE); /* Interrupt vector 4, used by VBlank */
105   device.execute().set_input_line(4, HOLD_LINE); /* Interrupt vector 4, used by VBlank */
106106}
107107
108108
r17996r17997
20152015
20162016   /* basic machine hardware */
20172017   MCFG_CPU_ADD("maincpu", M68000, 10000000)
2018   MCFG_CPU_VBLANK_INT("screen", sys16_interrupt)
2018   MCFG_CPU_VBLANK_INT_DRIVER("screen", segas1x_bootleg_state, sys16_interrupt)
20192019
20202020   MCFG_CPU_ADD("soundcpu", Z80, 4000000)
20212021   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
21652165   /* basic machine hardware */
21662166   MCFG_CPU_ADD("maincpu", M68000, 10000000)
21672167   MCFG_CPU_PROGRAM_MAP(goldnaxeb1_map)
2168   MCFG_CPU_VBLANK_INT("screen", sys16_interrupt)
2168   MCFG_CPU_VBLANK_INT_DRIVER("screen", segas1x_bootleg_state, sys16_interrupt)
21692169
21702170
21712171   /* video hardware */
r17996r17997
22952295
22962296   /* basic machine hardware */
22972297   MCFG_CPU_ADD("maincpu", M68000, 10000000)
2298   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
2298   MCFG_CPU_VBLANK_INT_DRIVER("screen", segas1x_bootleg_state, irq4_line_hold)
22992299
23002300   MCFG_CPU_ADD("soundcpu", Z80, 8000000)
23012301   MCFG_CPU_PROGRAM_MAP(sound_18_map)
trunk/src/mame/drivers/nyny.c
r17996r17997
129129   DECLARE_WRITE8_MEMBER(nyny_ay8910_37_port_a_w);
130130   virtual void machine_start();
131131   virtual void machine_reset();
132   INTERRUPT_GEN_MEMBER(update_pia_1);
132133};
133134
134135
r17996r17997
169170 *
170171 *************************************/
171172
172static INTERRUPT_GEN( update_pia_1 )
173INTERRUPT_GEN_MEMBER(nyny_state::update_pia_1)
173174{
174   nyny_state *state = device->machine().driver_data<nyny_state>();
175175
176176   /* update the different PIA pins from the input ports */
177177
178178   /* CA1 - copy of PA0 (COIN1) */
179   state->m_pia1->ca1_w(state->ioport("IN0")->read() & 0x01);
179   m_pia1->ca1_w(ioport("IN0")->read() & 0x01);
180180
181181   /* CA2 - copy of PA1 (SERVICE1) */
182   state->m_pia1->ca2_w(state->ioport("IN0")->read() & 0x02);
182   m_pia1->ca2_w(ioport("IN0")->read() & 0x02);
183183
184184   /* CB1 - (crosshatch) */
185   state->m_pia1->cb1_w(state->ioport("CROSS")->read());
185   m_pia1->cb1_w(ioport("CROSS")->read());
186186
187187   /* CB2 - NOT CONNECTED */
188188}
r17996r17997
713713   /* basic machine hardware */
714714   MCFG_CPU_ADD("maincpu", M6809, 1400000)   /* 1.40 MHz? The clock signal is generated by analog chips */
715715   MCFG_CPU_PROGRAM_MAP(nyny_main_map)
716   MCFG_CPU_PERIODIC_INT(update_pia_1, 25)
716   MCFG_CPU_PERIODIC_INT_DRIVER(nyny_state, update_pia_1, 25)
717717
718718   MCFG_CPU_ADD("audiocpu", M6802, AUDIO_CPU_1_CLOCK)
719719   MCFG_CPU_PROGRAM_MAP(nyny_audio_1_map)
trunk/src/mame/drivers/limenko.c
r17996r17997
752752   MCFG_CPU_ADD("maincpu", E132XN, 20000000*4)   /* 4x internal multiplier */
753753   MCFG_CPU_PROGRAM_MAP(limenko_map)
754754   MCFG_CPU_IO_MAP(limenko_io_map)
755   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
755   MCFG_CPU_VBLANK_INT_DRIVER("screen", limenko_state, irq0_line_hold)
756756
757757   MCFG_EEPROM_93C46_ADD("eeprom")
758758
r17996r17997
780780   MCFG_CPU_ADD("maincpu", GMS30C2232, 20000000)   /* 20 MHz, no internal multiplier */
781781   MCFG_CPU_PROGRAM_MAP(spotty_map)
782782   MCFG_CPU_IO_MAP(spotty_io_map)
783   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
783   MCFG_CPU_VBLANK_INT_DRIVER("screen", limenko_state, irq0_line_hold)
784784
785785   MCFG_CPU_ADD("audiocpu", AT89C4051, 4000000)   /* 4 MHz */
786786   MCFG_CPU_IO_MAP(spotty_sound_io_map)
trunk/src/mame/drivers/pengo.c
r17996r17997
7777   DECLARE_WRITE8_MEMBER(irq_mask_w);
7878   DECLARE_DRIVER_INIT(penta);
7979   DECLARE_DRIVER_INIT(pengo);
80   INTERRUPT_GEN_MEMBER(vblank_irq);
8081};
8182
8283
r17996r17997
369370 *
370371 *************************************/
371372
372static INTERRUPT_GEN( vblank_irq )
373INTERRUPT_GEN_MEMBER(pengo_state::vblank_irq)
373374{
374   pengo_state *state = device->machine().driver_data<pengo_state>();
375375
376   if(state->m_irq_mask)
377      device->execute().set_input_line(0, HOLD_LINE);
376   if(m_irq_mask)
377      device.execute().set_input_line(0, HOLD_LINE);
378378}
379379
380380
r17996r17997
383383   /* basic machine hardware */
384384   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)
385385   MCFG_CPU_PROGRAM_MAP(pengo_map)
386   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
386   MCFG_CPU_VBLANK_INT_DRIVER("screen", pengo_state, vblank_irq)
387387
388388   /* video hardware */
389389   MCFG_GFXDECODE(pengo)
trunk/src/mame/drivers/whitestar.c
r17996r17997
4949   DECLARE_DRIVER_INIT(whitestar);
5050   virtual void machine_reset();
5151   virtual void palette_init();
52   INTERRUPT_GEN_MEMBER(whitestar_firq_interrupt);
5253};
5354
5455static INPUT_PORTS_START( whitestar )
r17996r17997
182183}
183184
184185// the appropriate device is passed in, so we can share this routine
185static INTERRUPT_GEN( whitestar_firq_interrupt )
186INTERRUPT_GEN_MEMBER(whitestar_state::whitestar_firq_interrupt)
186187{
187   device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
188   device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
188189}
189190
190191#define DMD_CHUNK_SIZE 10
r17996r17997
271272   /* basic machine hardware */
272273   MCFG_CPU_ADD("maincpu", M6809, 2000000)
273274   MCFG_CPU_PROGRAM_MAP(whitestar_map)
274   MCFG_CPU_PERIODIC_INT(whitestar_firq_interrupt, 976) // value taken from PinMAME
275   MCFG_CPU_PERIODIC_INT_DRIVER(whitestar_state, whitestar_firq_interrupt, 976) // value taken from PinMAME
275276
276277    MCFG_CPU_ADD("dmdcpu", M6809, (8000000/4))
277278   MCFG_CPU_PROGRAM_MAP(whitestar_dmd_map)
278   MCFG_CPU_PERIODIC_INT(whitestar_firq_interrupt, 80) // value taken from PinMAME
279   MCFG_CPU_PERIODIC_INT_DRIVER(whitestar_state, whitestar_firq_interrupt, 80) // value taken from PinMAME
279280
280281
281282   /* sound hardware */
trunk/src/mame/drivers/prehisle.c
r17996r17997
210210   /* basic machine hardware */
211211   MCFG_CPU_ADD("maincpu", M68000, XTAL_18MHz/2)   /* verified on pcb */
212212   MCFG_CPU_PROGRAM_MAP(prehisle_map)
213   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
213   MCFG_CPU_VBLANK_INT_DRIVER("screen", prehisle_state, irq4_line_hold)
214214
215215   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz)   /* verified on pcb */
216216   MCFG_CPU_PROGRAM_MAP(prehisle_sound_map)
trunk/src/mame/drivers/simpsons.c
r17996r17997
260260}
261261
262262
263static INTERRUPT_GEN( simpsons_irq )
263INTERRUPT_GEN_MEMBER(simpsons_state::simpsons_irq)
264264{
265   simpsons_state *state = device->machine().driver_data<simpsons_state>();
266265
267   if (k053246_is_irq_enabled(state->m_k053246))
266   if (k053246_is_irq_enabled(m_k053246))
268267   {
269      simpsons_objdma(device->machine());
268      simpsons_objdma(machine());
270269      // 32+256us delay at 8MHz dotclock; artificially shortened since actual V-blank length is unknown
271      device->machine().scheduler().timer_set(attotime::from_usec(30), FUNC(dmaend_callback));
270      machine().scheduler().timer_set(attotime::from_usec(30), FUNC(dmaend_callback));
272271   }
273272
274   if (k052109_is_irq_enabled(state->m_k052109))
275      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
273   if (k052109_is_irq_enabled(m_k052109))
274      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
276275}
277276
278277static const k052109_interface simpsons_k052109_intf =
r17996r17997
309308   /* basic machine hardware */
310309   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8) /* 052001 (verified on pcb) */
311310   MCFG_CPU_PROGRAM_MAP(main_map)
312   MCFG_CPU_VBLANK_INT("screen", simpsons_irq)   /* IRQ triggered by the 052109, FIRQ by the sprite hardware */
311   MCFG_CPU_VBLANK_INT_DRIVER("screen", simpsons_state, simpsons_irq)   /* IRQ triggered by the 052109, FIRQ by the sprite hardware */
313312
314313   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)   /* verified on pcb */
315314   MCFG_CPU_PROGRAM_MAP(z80_map)
trunk/src/mame/drivers/actfancr.c
r17996r17997
323323   /* basic machine hardware */
324324   MCFG_CPU_ADD("maincpu",H6280,21477200/3) /* Should be accurate */
325325   MCFG_CPU_PROGRAM_MAP(actfan_map)
326   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* VBL */
326   MCFG_CPU_VBLANK_INT_DRIVER("screen", actfancr_state, irq0_line_hold) /* VBL */
327327
328328   MCFG_CPU_ADD("audiocpu",M6502, 1500000) /* Should be accurate */
329329   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
373373   /* basic machine hardware */
374374   MCFG_CPU_ADD("maincpu",H6280,XTAL_21_4772MHz/3) /* XIN=21.4772Mhz, verified on pcb */
375375   MCFG_CPU_PROGRAM_MAP(triothep_map)
376   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* VBL */
376   MCFG_CPU_VBLANK_INT_DRIVER("screen", actfancr_state, irq0_line_hold) /* VBL */
377377
378378   MCFG_CPU_ADD("audiocpu",M6502, XTAL_12MHz/8) /* verified on pcb */
379379   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
trunk/src/mame/drivers/poo.c
r17996r17997
339339   MCFG_CPU_ADD("maincpu", Z80,18000000/6)       /* ? MHz */
340340   MCFG_CPU_PROGRAM_MAP(unclepoo_main_map)
341341   MCFG_CPU_IO_MAP(unclepoo_main_portmap)
342   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
343   MCFG_CPU_PERIODIC_INT(irq0_line_hold,256) // ??? controls game speed
342   MCFG_CPU_VBLANK_INT_DRIVER("screen", poo_state,  nmi_line_pulse)
343   MCFG_CPU_PERIODIC_INT_DRIVER(poo_state, irq0_line_hold, 256) // ??? controls game speed
344344
345345   MCFG_CPU_ADD("subcpu", Z80,18000000/12)       /* ? MHz */
346346   MCFG_CPU_PROGRAM_MAP(unclepoo_sub_map)
347347   MCFG_CPU_IO_MAP(unclepoo_sub_portmap)
348//  MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
348   MCFG_CPU_VBLANK_INT_DRIVER("screen", poo_state, irq0_line_hold)
349349
350350   /* video hardware */
351351   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/galgame.c
r17996r17997
4848   virtual void machine_reset();
4949   virtual void palette_init();
5050   UINT32 screen_update_galaxygame(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
51   INTERRUPT_GEN_MEMBER(galaxygame_irq);
5152};
5253
5354/*************************************
r17996r17997
301302   return 0x40;
302303}
303304
304static INTERRUPT_GEN(galaxygame_irq)
305INTERRUPT_GEN_MEMBER(galaxygame_state::galaxygame_irq)
305306{
306   galaxygame_state *state = device->machine().driver_data<galaxygame_state>();
307   if ( state->m_clk & 0x40 )
307   if ( m_clk & 0x40 )
308308   {
309      device->execute().set_input_line(0, ASSERT_LINE);
310      state->m_interrupt = 1;
309      device.execute().set_input_line(0, ASSERT_LINE);
310      m_interrupt = 1;
311311   }
312312}
313313
r17996r17997
331331   MCFG_CPU_ADD("maincpu", T11, 3000000 )
332332   MCFG_CPU_PROGRAM_MAP(galaxygame_map)
333333   MCFG_CPU_CONFIG(t11_data)
334   MCFG_CPU_PERIODIC_INT(galaxygame_irq,60)
334   MCFG_CPU_PERIODIC_INT_DRIVER(galaxygame_state, galaxygame_irq, 60)
335335
336336   /* video hardware */
337337   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/qdrmfgp.c
r17996r17997
300300      machine.device("maincpu")->execute().set_input_line(3, HOLD_LINE);
301301}
302302
303static INTERRUPT_GEN(qdrmfgp2_interrupt)
303INTERRUPT_GEN_MEMBER(qdrmfgp_state::qdrmfgp2_interrupt)
304304{
305   qdrmfgp_state *state = device->machine().driver_data<qdrmfgp_state>();
306305   /* trigger V-blank interrupt */
307   if (state->m_control & 0x0008)
308      device->execute().set_input_line(4, HOLD_LINE);
306   if (m_control & 0x0008)
307      device.execute().set_input_line(4, HOLD_LINE);
309308}
310309
311310static void gp2_ide_interrupt(device_t *device, int state)
r17996r17997
718717   /* basic machine hardware */
719718   MCFG_CPU_ADD("maincpu", M68000, 32000000/2)   /*  16.000 MHz */
720719   MCFG_CPU_PROGRAM_MAP(qdrmfgp2_map)
721   MCFG_CPU_VBLANK_INT("screen", qdrmfgp2_interrupt)
720   MCFG_CPU_VBLANK_INT_DRIVER("screen", qdrmfgp_state, qdrmfgp2_interrupt)
722721
723722   MCFG_MACHINE_START_OVERRIDE(qdrmfgp_state,qdrmfgp2)
724723   MCFG_NVRAM_ADD_1FILL("nvram")
trunk/src/mame/drivers/starcrus.c
r17996r17997
140140   MCFG_CPU_ADD("maincpu", I8080,9750000/9)  /* 8224 chip is a divide by 9 */
141141   MCFG_CPU_PROGRAM_MAP(starcrus_map)
142142   MCFG_CPU_IO_MAP(starcrus_io_map)
143   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
143   MCFG_CPU_VBLANK_INT_DRIVER("screen", starcrus_state, irq0_line_hold)
144144
145145   /* video hardware */
146146   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/cps1.c
r17996r17997
326326    }
327327}
328328
329INTERRUPT_GEN( cps1_interrupt )
329INTERRUPT_GEN_MEMBER(cps_state::cps1_interrupt)
330330{
331331   /* Strider also has a IRQ4 handler. It is input port related, but the game */
332332   /* works without it. It is the *only* CPS1 game to have that. */
333   device->execute().set_input_line(2, HOLD_LINE);
333   device.execute().set_input_line(2, HOLD_LINE);
334334}
335335
336336/********************************************************************
r17996r17997
341341********************************************************************/
342342
343343
344static INTERRUPT_GEN( cps1_qsound_interrupt )
344INTERRUPT_GEN_MEMBER(cps_state::cps1_qsound_interrupt)
345345{
346   device->execute().set_input_line(2, HOLD_LINE);
346   device.execute().set_input_line(2, HOLD_LINE);
347347}
348348
349349
r17996r17997
30543054   /* basic machine hardware */
30553055   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz )   /* verified on pcb */
30563056   MCFG_CPU_PROGRAM_MAP(main_map)
3057   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
3057   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
30583058
30593059   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)  /* verified on pcb */
30603060   MCFG_CPU_PROGRAM_MAP(sub_map)
r17996r17997
31093109
31103110   MCFG_CPU_REPLACE("maincpu", M68000, XTAL_12MHz )   /* verified on pcb */
31113111   MCFG_CPU_PROGRAM_MAP(qsound_main_map)
3112   MCFG_CPU_VBLANK_INT("screen", cps1_qsound_interrupt)  /* ??? interrupts per frame */
3112   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_qsound_interrupt)  /* ??? interrupts per frame */
31133113
31143114   MCFG_CPU_REPLACE("audiocpu", Z80, XTAL_8MHz)  /* verified on pcb */
31153115   MCFG_CPU_PROGRAM_MAP(qsound_sub_map)
3116   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 250)   /* ?? */
3116   MCFG_CPU_PERIODIC_INT_DRIVER(cps_state, irq0_line_hold, 250)   /* ?? */
31173117
31183118   MCFG_MACHINE_START_OVERRIDE(cps_state,qsound)
31193119
r17996r17997
31383138   /* basic machine hardware */
31393139   MCFG_CPU_ADD("maincpu", M68000, 12000000)
31403140   MCFG_CPU_PROGRAM_MAP(main_map)
3141   MCFG_CPU_VBLANK_INT("screen", cps1_qsound_interrupt)
3141   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_qsound_interrupt)
31423142
31433143   MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)
31443144   MCFG_DEVICE_DISABLE() /* no valid dumps .. */
r17996r17997
32123212   /* basic machine hardware */
32133213   MCFG_CPU_ADD("maincpu", M68000, 12000000)
32143214   MCFG_CPU_PROGRAM_MAP(main_map)
3215   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
3215   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
32163216
32173217   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
32183218   MCFG_CPU_PROGRAM_MAP(sf2mdt_z80map)
r17996r17997
32963296   /* basic machine hardware */
32973297   MCFG_CPU_ADD("maincpu", M68000, 24000000 / 2)
32983298   MCFG_CPU_PROGRAM_MAP(main_map)
3299   MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
3299   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
33003300
33013301   MCFG_CPU_ADD("audiocpu", Z80, 29821000 / 8)
33023302   MCFG_CPU_PROGRAM_MAP(sf2mdt_z80map)
trunk/src/mame/drivers/yunsun16.c
r17996r17997
590590   /* basic machine hardware */
591591   MCFG_CPU_ADD("maincpu", M68000, 16000000)
592592   MCFG_CPU_PROGRAM_MAP(main_map)
593   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
593   MCFG_CPU_VBLANK_INT_DRIVER("screen", yunsun16_state, irq2_line_hold)
594594
595595   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   /* ? */
596596   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
632632   /* basic machine hardware */
633633   MCFG_CPU_ADD("maincpu", M68000, 16000000)
634634   MCFG_CPU_PROGRAM_MAP(main_map)
635   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
635   MCFG_CPU_VBLANK_INT_DRIVER("screen", yunsun16_state, irq2_line_hold)
636636
637637
638638   /* video hardware */
trunk/src/mame/drivers/wiz.c
r17996r17997
700700   m_dsc0 = m_dsc1 = 1;
701701}
702702
703static INTERRUPT_GEN( wiz_vblank_interrupt )
703INTERRUPT_GEN_MEMBER(wiz_state::wiz_vblank_interrupt)
704704{
705   wiz_state *state = device->machine().driver_data<wiz_state>();
706705
707   if(state->m_main_nmi_mask & 1)
708      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
706   if(m_main_nmi_mask & 1)
707      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
709708}
710709
711static INTERRUPT_GEN( wiz_sound_interrupt )
710INTERRUPT_GEN_MEMBER(wiz_state::wiz_sound_interrupt)
712711{
713   wiz_state *state = device->machine().driver_data<wiz_state>();
714712
715   if(state->m_sound_nmi_mask & 1)
716      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
713   if(m_sound_nmi_mask & 1)
714      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
717715}
718716
719717
r17996r17997
722720   /* basic machine hardware */
723721   MCFG_CPU_ADD("maincpu", Z80, 18432000/6)   /* 3.072 MHz ??? */
724722   MCFG_CPU_PROGRAM_MAP(main_map)
725   MCFG_CPU_VBLANK_INT("screen", wiz_vblank_interrupt)
723   MCFG_CPU_VBLANK_INT_DRIVER("screen", wiz_state, wiz_vblank_interrupt)
726724
727725   MCFG_CPU_ADD("audiocpu", Z80, 14318000/8)   /* ? */
728726   MCFG_CPU_PROGRAM_MAP(sound_map)
729   MCFG_CPU_PERIODIC_INT(wiz_sound_interrupt,4*60)   /* ??? */
727   MCFG_CPU_PERIODIC_INT_DRIVER(wiz_state, wiz_sound_interrupt, 4*60)   /* ??? */
730728
731729
732730   /* video hardware */
trunk/src/mame/drivers/stactics.c
r17996r17997
151151 *
152152 *************************************/
153153
154static INTERRUPT_GEN( stactics_interrupt )
154INTERRUPT_GEN_MEMBER(stactics_state::stactics_interrupt)
155155{
156   stactics_state *state = device->machine().driver_data<stactics_state>();
157156
158   move_motor(device->machine(), state);
157   move_motor(machine(), this);
159158
160    device->execute().set_input_line(0, HOLD_LINE);
159    device.execute().set_input_line(0, HOLD_LINE);
161160}
162161
163162
r17996r17997
303302   /* basic machine hardware */
304303   MCFG_CPU_ADD("maincpu", I8080, 1933560)
305304   MCFG_CPU_PROGRAM_MAP(main_map)
306   MCFG_CPU_VBLANK_INT("screen", stactics_interrupt)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", stactics_state, stactics_interrupt)
307306
308307
309308   /* video hardware */
trunk/src/mame/drivers/drtomy.c
r17996r17997
300300   /* basic machine hardware */
301301   MCFG_CPU_ADD("maincpu", M68000,24000000/2)         /* ? MHz */
302302   MCFG_CPU_PROGRAM_MAP(drtomy_map)
303   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
303   MCFG_CPU_VBLANK_INT_DRIVER("screen", drtomy_state, irq6_line_hold)
304304
305305
306306   /* video hardware */
trunk/src/mame/drivers/calorie.c
r17996r17997
442442   /* basic machine hardware */
443443   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* 4 MHz */
444444   MCFG_CPU_PROGRAM_MAP(calorie_map)
445   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
445   MCFG_CPU_VBLANK_INT_DRIVER("screen", calorie_state, irq0_line_hold)
446446
447447   MCFG_CPU_ADD("audiocpu", Z80,3000000)       /* 3 MHz */
448448   MCFG_CPU_PROGRAM_MAP(calorie_sound_map)
449449   MCFG_CPU_IO_MAP(calorie_sound_io_map)
450   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 64)
450   MCFG_CPU_PERIODIC_INT_DRIVER(calorie_state, irq0_line_hold, 64)
451451
452452
453453   /* video hardware */
trunk/src/mame/drivers/galaxian.c
r17996r17997
438438 *
439439 *************************************/
440440
441static INTERRUPT_GEN( interrupt_gen )
441INTERRUPT_GEN_MEMBER(galaxian_state::interrupt_gen)
442442{
443   galaxian_state *state = device->machine().driver_data<galaxian_state>();
444443   /* interrupt line is clocked at VBLANK */
445444   /* a flip-flop at 6F is held in the preset state based on the NMI ON signal */
446   if (state->m_irq_enabled)
447      device->execute().set_input_line(state->m_irq_line, ASSERT_LINE);
445   if (m_irq_enabled)
446      device.execute().set_input_line(m_irq_line, ASSERT_LINE);
448447}
449448
450static INTERRUPT_GEN( fakechange_interrupt_gen )
449INTERRUPT_GEN_MEMBER(galaxian_state::fakechange_interrupt_gen)
451450{
452   galaxian_state *state = device->machine().driver_data<galaxian_state>();
453451   interrupt_gen(device);
454452
455   if (state->ioport("FAKE_SELECT")->read_safe(0x00))
453   if (ioport("FAKE_SELECT")->read_safe(0x00))
456454   {
457      state->m_tenspot_current_game++;
458      state->m_tenspot_current_game%=10;
459      state->tenspot_set_game_bank(device->machine(), state->m_tenspot_current_game, 1);
460      device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
455      m_tenspot_current_game++;
456      m_tenspot_current_game%=10;
457      tenspot_set_game_bank(machine(), m_tenspot_current_game, 1);
458      machine().device("maincpu")->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
461459   }
462460}
463461
r17996r17997
20842082   /* basic machine hardware */
20852083   MCFG_CPU_ADD("maincpu", Z80, GALAXIAN_PIXEL_CLOCK/3/2)
20862084   MCFG_CPU_PROGRAM_MAP(galaxian_map)
2087   MCFG_CPU_VBLANK_INT("screen", interrupt_gen)
2085   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, interrupt_gen)
20882086
20892087   MCFG_WATCHDOG_VBLANK_INIT(8)
20902088
r17996r17997
21802178static MACHINE_CONFIG_DERIVED( tenspot, galaxian )
21812179
21822180   MCFG_CPU_MODIFY("maincpu")
2183   MCFG_CPU_VBLANK_INT("screen", fakechange_interrupt_gen)
2181   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, fakechange_interrupt_gen)
21842182
21852183   /* basic machine hardware */
21862184   MCFG_CPU_ADD("selectcpu", Z80, GALAXIAN_PIXEL_CLOCK/3/2) // ?? mhz
r17996r17997
22602258   MCFG_CPU_ADD("audiocpu", Z80, 1620000)   /* 1.62 MHz */
22612259   MCFG_CPU_PROGRAM_MAP(checkman_sound_map)
22622260   MCFG_CPU_IO_MAP(checkman_sound_portmap)
2263   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* NMIs are triggered by the main CPU */
2261   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, irq0_line_hold)   /* NMIs are triggered by the main CPU */
22642262
22652263   /* sound hardware */
22662264   MCFG_SOUND_ADD("aysnd", AY8910, 1789750)
trunk/src/mame/drivers/itech8.c
r17996r17997
610610}
611611
612612
613static INTERRUPT_GEN( generate_nmi )
613INTERRUPT_GEN_MEMBER(itech8_state::generate_nmi)
614614{
615615   /* signal the NMI */
616   itech8_update_interrupts(device->machine(), 1, -1, -1);
617   device->machine().scheduler().timer_set(attotime::from_usec(1), FUNC(irq_off));
616   itech8_update_interrupts(machine(), 1, -1, -1);
617   machine().scheduler().timer_set(attotime::from_usec(1), FUNC(irq_off));
618618
619   if (FULL_LOGGING) logerror("------------ VBLANK (%d) --------------\n", device->machine().primary_screen->vpos());
619   if (FULL_LOGGING) logerror("------------ VBLANK (%d) --------------\n", machine().primary_screen->vpos());
620620}
621621
622622
r17996r17997
16851685   /* basic machine hardware */
16861686   MCFG_CPU_ADD("maincpu", M6809, CLOCK_8MHz/4)
16871687   MCFG_CPU_PROGRAM_MAP(tmslo_map)
1688   MCFG_CPU_VBLANK_INT("screen", generate_nmi)
1688   MCFG_CPU_VBLANK_INT_DRIVER("screen", itech8_state, generate_nmi)
16891689
16901690   MCFG_NVRAM_ADD_RANDOM_FILL("nvram")
16911691
r17996r17997
19201920
19211921   MCFG_CPU_REPLACE("maincpu", HD6309, CLOCK_12MHz)
19221922   MCFG_CPU_PROGRAM_MAP(tmshi_map)
1923   MCFG_CPU_VBLANK_INT("screen", generate_nmi)
1923   MCFG_CPU_VBLANK_INT_DRIVER("screen", itech8_state, generate_nmi)
19241924
19251925   /* video hardware */
19261926   MCFG_SCREEN_MODIFY("screen")
r17996r17997
19361936
19371937   MCFG_CPU_REPLACE("maincpu", M68000, CLOCK_12MHz)
19381938   MCFG_CPU_PROGRAM_MAP(ninclown_map)
1939   MCFG_CPU_VBLANK_INT("screen", generate_nmi)
1939   MCFG_CPU_VBLANK_INT_DRIVER("screen", itech8_state, generate_nmi)
19401940
19411941   /* video hardware */
19421942   MCFG_SCREEN_MODIFY("screen")
trunk/src/mame/drivers/kickgoal.c
r17996r17997
293293}
294294
295295
296static INTERRUPT_GEN( kickgoal_interrupt )
296INTERRUPT_GEN_MEMBER(kickgoal_state::kickgoal_interrupt)
297297{
298   kickgoal_state *state = device->machine().driver_data<kickgoal_state>();
299298
300   if ((state->m_adpcm->read_status() & 0x08) == 0)
299   if ((m_adpcm->read_status() & 0x08) == 0)
301300   {
302      switch(state->m_melody_loop)
301      switch(m_melody_loop)
303302      {
304         case 0x060:   state->m_melody_loop = 0x061; break;
305         case 0x061:   state->m_melody_loop = 0x062; break;
306         case 0x062:   state->m_melody_loop = 0x060; break;
303         case 0x060:   m_melody_loop = 0x061; break;
304         case 0x061:   m_melody_loop = 0x062; break;
305         case 0x062:   m_melody_loop = 0x060; break;
307306
308         case 0x065:   state->m_melody_loop = 0x165; break;
309         case 0x165:   state->m_melody_loop = 0x265; break;
310         case 0x265:   state->m_melody_loop = 0x365; break;
311         case 0x365:   state->m_melody_loop = 0x066; break;
312         case 0x066:   state->m_melody_loop = 0x067; break;
313         case 0x067:   state->m_melody_loop = 0x068; break;
314         case 0x068:   state->m_melody_loop = 0x065; break;
307         case 0x065:   m_melody_loop = 0x165; break;
308         case 0x165:   m_melody_loop = 0x265; break;
309         case 0x265:   m_melody_loop = 0x365; break;
310         case 0x365:   m_melody_loop = 0x066; break;
311         case 0x066:   m_melody_loop = 0x067; break;
312         case 0x067:   m_melody_loop = 0x068; break;
313         case 0x068:   m_melody_loop = 0x065; break;
315314
316         case 0x063:   state->m_melody_loop = 0x063; break;
317         case 0x064:   state->m_melody_loop = 0x064; break;
318         case 0x069:   state->m_melody_loop = 0x069; break;
319         case 0x06a:   state->m_melody_loop = 0x06a; break;
320         case 0x06b:   state->m_melody_loop = 0x06b; break;
321         case 0x06c:   state->m_melody_loop = 0x06c; break;
315         case 0x063:   m_melody_loop = 0x063; break;
316         case 0x064:   m_melody_loop = 0x064; break;
317         case 0x069:   m_melody_loop = 0x069; break;
318         case 0x06a:   m_melody_loop = 0x06a; break;
319         case 0x06b:   m_melody_loop = 0x06b; break;
320         case 0x06c:   m_melody_loop = 0x06c; break;
322321
323         default:   state->m_melody_loop = 0x00; break;
322         default:   m_melody_loop = 0x00; break;
324323      }
325324
326      if (state->m_melody_loop)
325      if (m_melody_loop)
327326      {
328//          logerror("Changing to sample %02x\n", state->m_melody_loop);
329         state->m_adpcm->write_command((0x80 | state->m_melody_loop) & 0xff);
330         state->m_adpcm->write_command(0x81);
327//          logerror("Changing to sample %02x\n", m_melody_loop);
328         m_adpcm->write_command((0x80 | m_melody_loop) & 0xff);
329         m_adpcm->write_command(0x81);
331330      }
332331   }
333   if (device->machine().input().code_pressed_once(KEYCODE_PGUP))
332   if (machine().input().code_pressed_once(KEYCODE_PGUP))
334333   {
335      if (state->m_m6295_key_delay >= (0x60 * oki_time_base))
334      if (m_m6295_key_delay >= (0x60 * oki_time_base))
336335      {
337         state->m_m6295_bank += 0x01;
338         state->m_m6295_bank &= 0x03;
339         if (state->m_m6295_bank == 0x03)
340            state->m_m6295_bank = 0x00;
341         popmessage("Changing Bank to %02x", state->m_m6295_bank);
342         state->m_adpcm->set_bank_base(((state->m_m6295_bank) * 0x40000));
336         m_m6295_bank += 0x01;
337         m_m6295_bank &= 0x03;
338         if (m_m6295_bank == 0x03)
339            m_m6295_bank = 0x00;
340         popmessage("Changing Bank to %02x", m_m6295_bank);
341         m_adpcm->set_bank_base(((m_m6295_bank) * 0x40000));
343342
344         if (state->m_m6295_key_delay == 0xffff)
345            state->m_m6295_key_delay = 0x00;
343         if (m_m6295_key_delay == 0xffff)
344            m_m6295_key_delay = 0x00;
346345         else
347            state->m_m6295_key_delay = (0x30 * oki_time_base);
346            m_m6295_key_delay = (0x30 * oki_time_base);
348347      }
349348      else
350         state->m_m6295_key_delay += (0x01 * oki_time_base);
349         m_m6295_key_delay += (0x01 * oki_time_base);
351350   }
352   else if (device->machine().input().code_pressed_once(KEYCODE_PGDN))
351   else if (machine().input().code_pressed_once(KEYCODE_PGDN))
353352   {
354      if (state->m_m6295_key_delay >= (0x60 * oki_time_base))
353      if (m_m6295_key_delay >= (0x60 * oki_time_base))
355354      {
356         state->m_m6295_bank -= 0x01;
357         state->m_m6295_bank &= 0x03;
358         if (state->m_m6295_bank == 0x03)
359            state->m_m6295_bank = 0x02;
360         popmessage("Changing Bank to %02x", state->m_m6295_bank);
361         state->m_adpcm->set_bank_base(((state->m_m6295_bank) * 0x40000));
355         m_m6295_bank -= 0x01;
356         m_m6295_bank &= 0x03;
357         if (m_m6295_bank == 0x03)
358            m_m6295_bank = 0x02;
359         popmessage("Changing Bank to %02x", m_m6295_bank);
360         m_adpcm->set_bank_base(((m_m6295_bank) * 0x40000));
362361
363         if (state->m_m6295_key_delay == 0xffff)
364            state->m_m6295_key_delay = 0x00;
362         if (m_m6295_key_delay == 0xffff)
363            m_m6295_key_delay = 0x00;
365364         else
366            state->m_m6295_key_delay = (0x30 * oki_time_base);
365            m_m6295_key_delay = (0x30 * oki_time_base);
367366      }
368367      else
369         state->m_m6295_key_delay += (0x01 * oki_time_base);
368         m_m6295_key_delay += (0x01 * oki_time_base);
370369   }
371   else if (device->machine().input().code_pressed_once(KEYCODE_INSERT))
370   else if (machine().input().code_pressed_once(KEYCODE_INSERT))
372371   {
373      if (state->m_m6295_key_delay >= (0x60 * oki_time_base))
372      if (m_m6295_key_delay >= (0x60 * oki_time_base))
374373      {
375         state->m_m6295_comm += 1;
376         state->m_m6295_comm &= 0x7f;
377         if (state->m_m6295_comm == 0x00) { state->m_adpcm->set_bank_base((0 * 0x40000)); state->m_m6295_bank = 0; }
378         if (state->m_m6295_comm == 0x60) { state->m_adpcm->set_bank_base((0 * 0x40000)); state->m_m6295_bank = 0; }
379         if (state->m_m6295_comm == 0x65) { state->m_adpcm->set_bank_base((1 * 0x40000)); state->m_m6295_bank = 1; }
380         if (state->m_m6295_comm == 0x69) { state->m_adpcm->set_bank_base((2 * 0x40000)); state->m_m6295_bank = 2; }
381         if (state->m_m6295_comm == 0x70) { state->m_adpcm->set_bank_base((1 * 0x40000)); state->m_m6295_bank = 1; }
382         popmessage("Sound test command %02x on Bank %02x", state->m_m6295_comm, state->m_m6295_bank);
374         m_m6295_comm += 1;
375         m_m6295_comm &= 0x7f;
376         if (m_m6295_comm == 0x00) { m_adpcm->set_bank_base((0 * 0x40000)); m_m6295_bank = 0; }
377         if (m_m6295_comm == 0x60) { m_adpcm->set_bank_base((0 * 0x40000)); m_m6295_bank = 0; }
378         if (m_m6295_comm == 0x65) { m_adpcm->set_bank_base((1 * 0x40000)); m_m6295_bank = 1; }
379         if (m_m6295_comm == 0x69) { m_adpcm->set_bank_base((2 * 0x40000)); m_m6295_bank = 2; }
380         if (m_m6295_comm == 0x70) { m_adpcm->set_bank_base((1 * 0x40000)); m_m6295_bank = 1; }
381         popmessage("Sound test command %02x on Bank %02x", m_m6295_comm, m_m6295_bank);
383382
384         if (state->m_m6295_key_delay == 0xffff)
385            state->m_m6295_key_delay = 0x00;
383         if (m_m6295_key_delay == 0xffff)
384            m_m6295_key_delay = 0x00;
386385         else
387            state->m_m6295_key_delay = (0x5d * oki_time_base);
386            m_m6295_key_delay = (0x5d * oki_time_base);
388387      }
389388      else
390         state->m_m6295_key_delay += (0x01 * oki_time_base);
389         m_m6295_key_delay += (0x01 * oki_time_base);
391390   }
392   else if (device->machine().input().code_pressed_once(KEYCODE_DEL))
391   else if (machine().input().code_pressed_once(KEYCODE_DEL))
393392   {
394      if (state->m_m6295_key_delay >= (0x60 * oki_time_base))
393      if (m_m6295_key_delay >= (0x60 * oki_time_base))
395394      {
396         state->m_m6295_comm -= 1;
397         state->m_m6295_comm &= 0x7f;
398         if (state->m_m6295_comm == 0x2b) { state->m_adpcm->set_bank_base((0 * 0x40000)); state->m_m6295_bank = 0; }
399         if (state->m_m6295_comm == 0x64) { state->m_adpcm->set_bank_base((0 * 0x40000)); state->m_m6295_bank = 0; }
400         if (state->m_m6295_comm == 0x68) { state->m_adpcm->set_bank_base((1 * 0x40000)); state->m_m6295_bank = 1; }
401         if (state->m_m6295_comm == 0x6c) { state->m_adpcm->set_bank_base((2 * 0x40000)); state->m_m6295_bank = 2; }
402         if (state->m_m6295_comm == 0x76) { state->m_adpcm->set_bank_base((1 * 0x40000)); state->m_m6295_bank = 1; }
403         popmessage("Sound test command %02x on Bank %02x", state->m_m6295_comm, state->m_m6295_bank);
395         m_m6295_comm -= 1;
396         m_m6295_comm &= 0x7f;
397         if (m_m6295_comm == 0x2b) { m_adpcm->set_bank_base((0 * 0x40000)); m_m6295_bank = 0; }
398         if (m_m6295_comm == 0x64) { m_adpcm->set_bank_base((0 * 0x40000)); m_m6295_bank = 0; }
399         if (m_m6295_comm == 0x68) { m_adpcm->set_bank_base((1 * 0x40000)); m_m6295_bank = 1; }
400         if (m_m6295_comm == 0x6c) { m_adpcm->set_bank_base((2 * 0x40000)); m_m6295_bank = 2; }
401         if (m_m6295_comm == 0x76) { m_adpcm->set_bank_base((1 * 0x40000)); m_m6295_bank = 1; }
402         popmessage("Sound test command %02x on Bank %02x", m_m6295_comm, m_m6295_bank);
404403
405         if (state->m_m6295_key_delay == 0xffff)
406            state->m_m6295_key_delay = 0x00;
404         if (m_m6295_key_delay == 0xffff)
405            m_m6295_key_delay = 0x00;
407406         else
408            state->m_m6295_key_delay = (0x5d * oki_time_base);
407            m_m6295_key_delay = (0x5d * oki_time_base);
409408      }
410409      else
411         state->m_m6295_key_delay += (0x01 * oki_time_base);
410         m_m6295_key_delay += (0x01 * oki_time_base);
412411   }
413   else if (device->machine().input().code_pressed_once(KEYCODE_Z))
412   else if (machine().input().code_pressed_once(KEYCODE_Z))
414413   {
415      if (state->m_m6295_key_delay >= (0x80 * oki_time_base))
414      if (m_m6295_key_delay >= (0x80 * oki_time_base))
416415      {
417         state->m_adpcm->write_command(0x78);
418         state->m_adpcm->write_command(0x80 | state->m_m6295_comm);
419         state->m_adpcm->write_command(0x11);
416         m_adpcm->write_command(0x78);
417         m_adpcm->write_command(0x80 | m_m6295_comm);
418         m_adpcm->write_command(0x11);
420419
421         popmessage("Playing sound %02x on Bank %02x", state->m_m6295_comm, state->m_m6295_bank);
420         popmessage("Playing sound %02x on Bank %02x", m_m6295_comm, m_m6295_bank);
422421
423         if (state->m_m6295_key_delay == 0xffff)
424            state->m_m6295_key_delay = 0x00;
422         if (m_m6295_key_delay == 0xffff)
423            m_m6295_key_delay = 0x00;
425424         else
426            state->m_m6295_key_delay = (0x60 * oki_time_base);
425            m_m6295_key_delay = (0x60 * oki_time_base);
427426      }
428427      else
429         state->m_m6295_key_delay += (0x01 * oki_time_base);
430//      logerror("Sending %02x to the sound CPU\n", state->m_m6295_comm);
428         m_m6295_key_delay += (0x01 * oki_time_base);
429//      logerror("Sending %02x to the sound CPU\n", m_m6295_comm);
431430   }
432431   else
433      state->m_m6295_key_delay = 0xffff;
432      m_m6295_key_delay = 0xffff;
434433}
435434
436435
r17996r17997
648647   /* basic machine hardware */
649648   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
650649   MCFG_CPU_PROGRAM_MAP(kickgoal_program_map)
651   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
652   MCFG_CPU_PERIODIC_INT(kickgoal_interrupt, 240)
650   MCFG_CPU_VBLANK_INT_DRIVER("screen", kickgoal_state,  irq6_line_hold)
651   MCFG_CPU_PERIODIC_INT_DRIVER(kickgoal_state, kickgoal_interrupt,  240)
653652
654653   MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000/4)   /* 3MHz ? */
655654   MCFG_DEVICE_DISABLE()   /* Disables since the internal rom isn't dumped */
r17996r17997
684683   /* basic machine hardware */
685684   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)   /* verified on pcb */
686685   MCFG_CPU_PROGRAM_MAP(kickgoal_program_map)
687   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
686   MCFG_CPU_VBLANK_INT_DRIVER("screen", kickgoal_state, irq6_line_hold)
688687
689688   MCFG_CPU_ADD("audiocpu", PIC16C57, XTAL_12MHz/3)   /* verified on pcb */
690689   MCFG_DEVICE_DISABLE() /* Disables since the internal rom isn't dumped */
trunk/src/mame/drivers/othldrby.c
r17996r17997
242242   /* basic machine hardware */
243243   MCFG_CPU_ADD("maincpu", M68000, 16000000)
244244   MCFG_CPU_PROGRAM_MAP(othldrby_map)
245   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
245   MCFG_CPU_VBLANK_INT_DRIVER("screen", othldrby_state, irq4_line_hold)
246246
247247
248248   /* video hardware */
trunk/src/mame/drivers/bbusters.c
r17996r17997
670670   /* basic machine hardware */
671671   MCFG_CPU_ADD("maincpu", M68000, 12000000)
672672   MCFG_CPU_PROGRAM_MAP(bbusters_map)
673   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
673   MCFG_CPU_VBLANK_INT_DRIVER("screen", bbusters_state, irq6_line_hold)
674674
675675   MCFG_CPU_ADD("audiocpu", Z80,4000000) /* Accurate */
676676   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
710710   /* basic machine hardware */
711711   MCFG_CPU_ADD("maincpu", M68000, 12000000)
712712   MCFG_CPU_PROGRAM_MAP(mechatt_map)
713   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
713   MCFG_CPU_VBLANK_INT_DRIVER("screen", bbusters_state, irq4_line_hold)
714714
715715   MCFG_CPU_ADD("audiocpu", Z80,4000000) /* Accurate */
716716   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/flstory.c
r17996r17997
10821082   /* basic machine hardware */
10831083   MCFG_CPU_ADD("maincpu", Z80,XTAL_10_733MHz/2) /* verified on pcb */
10841084   MCFG_CPU_PROGRAM_MAP(flstory_map)
1085   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1085   MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
10861086
10871087   MCFG_CPU_ADD("audiocpu", Z80,XTAL_8MHz/2) /* verified on pcb */
10881088   MCFG_CPU_PROGRAM_MAP(sound_map)
1089   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ??? */
1089   MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60)   /* IRQ generated by ??? */
10901090                  /* NMI generated by the main CPU */
10911091
10921092   MCFG_CPU_ADD("mcu", M68705,XTAL_18_432MHz/6)   /* verified on pcb */
r17996r17997
11391139   /* basic machine hardware */
11401140   MCFG_CPU_ADD("maincpu", Z80,10733000/2)      /* ??? */
11411141   MCFG_CPU_PROGRAM_MAP(onna34ro_map)
1142   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1142   MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
11431143
11441144   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)      /* 4 MHz */
11451145   MCFG_CPU_PROGRAM_MAP(sound_map)
1146   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ??? */
1146   MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60)   /* IRQ generated by ??? */
11471147                  /* NMI generated by the main CPU */
11481148
11491149//  MCFG_CPU_ADD("mcu", M68705,4000000)  /* ??? */
r17996r17997
11961196   /* basic machine hardware */
11971197   MCFG_CPU_ADD("maincpu", Z80,8000000/2)      /* 4 MHz */
11981198   MCFG_CPU_PROGRAM_MAP(victnine_map)
1199   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1199   MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
12001200
12011201   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)      /* 4 MHz */
12021202   MCFG_CPU_PROGRAM_MAP(sound_map)
1203   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ??? */
1203   MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60)   /* IRQ generated by ??? */
12041204                  /* NMI generated by the main CPU */
12051205
12061206//  MCFG_CPU_ADD("mcu", M68705,4000000)  /* ??? */
r17996r17997
12591259   /* basic machine hardware */
12601260   MCFG_CPU_ADD("maincpu", Z80,8000000/2)      /* 4 MHz */
12611261   MCFG_CPU_PROGRAM_MAP(rumba_map)
1262   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1262   MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
12631263
12641264   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)      /* 4 MHz */
12651265   MCFG_CPU_PROGRAM_MAP(sound_map)
1266   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ??? */
1266   MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60)   /* IRQ generated by ??? */
12671267                  /* NMI generated by the main CPU */
12681268
12691269//  MCFG_CPU_ADD("mcu", M68705,18432000/6)  /* ??? */
trunk/src/mame/drivers/suprslam.c
r17996r17997
316316
317317   MCFG_CPU_ADD("maincpu", M68000, 16000000)
318318   MCFG_CPU_PROGRAM_MAP(suprslam_map)
319   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
319   MCFG_CPU_VBLANK_INT_DRIVER("screen", suprslam_state, irq1_line_hold)
320320
321321   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)   /* 4 MHz ??? */
322322   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/calomega.c
r17996r17997
27362736   /* basic machine hardware */
27372737   MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK)   /* confirmed */
27382738   MCFG_CPU_PROGRAM_MAP(sys903_map)
2739   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
2739   MCFG_CPU_VBLANK_INT_DRIVER("screen", calomega_state, irq0_line_hold)
27402740
27412741   MCFG_NVRAM_ADD_0FILL("nvram")
27422742
trunk/src/mame/drivers/4roses.c
r17996r17997
385385   /* basic machine hardware */
386386   MCFG_CPU_ADD("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz, guess */
387387   MCFG_CPU_PROGRAM_MAP(4roses_map)
388   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
388   MCFG_CPU_VBLANK_INT_DRIVER("screen", _4roses_state, nmi_line_pulse)
389389
390390//  MCFG_NVRAM_ADD_0FILL("nvram")
391391
trunk/src/mame/drivers/bmcbowl.c
r17996r17997
503503static MACHINE_CONFIG_START( bmcbowl, bmcbowl_state )
504504   MCFG_CPU_ADD("maincpu", M68000, 21477270/2 )
505505   MCFG_CPU_PROGRAM_MAP(bmcbowl_mem)
506   MCFG_CPU_VBLANK_INT("screen",irq2_line_hold)
506   MCFG_CPU_VBLANK_INT_DRIVER("screen", bmcbowl_state, irq2_line_hold)
507507
508508   MCFG_SCREEN_ADD("screen", RASTER)
509509   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/pachifev.c
r17996r17997
107107   DECLARE_READ8_MEMBER(controls_r);
108108   virtual void machine_start();
109109   virtual void machine_reset();
110   INTERRUPT_GEN_MEMBER(pachifev_vblank_irq);
110111};
111112
112113WRITE8_MEMBER(pachifev_state::controls_w)
r17996r17997
317318}
318319
319320
320static INTERRUPT_GEN( pachifev_vblank_irq )
321INTERRUPT_GEN_MEMBER(pachifev_state::pachifev_vblank_irq)
321322{
322323    {
323324      static const char *const inname[2] = { "PLUNGER_P1", "PLUNGER_P2" };
324        pachifev_state *state = device->machine().driver_data<pachifev_state>();
325325
326326      /* I wish I had found a better way to handle cocktail inputs, but I can't find a way to access internal RAM */
327327      /* (bit 5 of 0xf0aa : 0 = player 1 and 1 = player 2 - bit 6 of 0xf0aa : 0 = upright and 1 = cocktail). */
328328      /* All I found is that in main RAM, 0xe00f.b determines the player : 0x00 = player 1 and 0x01 = player 2. */
329      address_space *ramspace = device->memory().space(AS_PROGRAM);
329      address_space *ramspace = device.memory().space(AS_PROGRAM);
330330      UINT8 player = 0;
331331
332      if ((ramspace->read_byte(0xe00f) == 0x01) && ((state->ioport("DSW1")->read() & 0x08) == 0x00))
332      if ((ramspace->read_byte(0xe00f) == 0x01) && ((ioport("DSW1")->read() & 0x08) == 0x00))
333333         player = 1;
334334
335        int current_power=state->ioport(inname[player])->read() & 0x3f;
336        if(current_power != state->m_previous_power)
335        int current_power=ioport(inname[player])->read() & 0x3f;
336        if(current_power != m_previous_power)
337337        {
338338            popmessage    ("%d%%", (current_power * 100) / 0x3f);
339339        }
340340
341        if( (!current_power) && (state->m_previous_power) )
341        if( (!current_power) && (m_previous_power) )
342342        {
343            state->m_input_power=state->m_previous_power;
344            state->m_cnt=NUM_PLUNGER_REPEATS;
343            m_input_power=m_previous_power;
344            m_cnt=NUM_PLUNGER_REPEATS;
345345        }
346346
347        state->m_previous_power=current_power;
347        m_previous_power=current_power;
348348    }
349349
350350}
r17996r17997
378378    MCFG_CPU_CONFIG(pachifev_processor_config)
379379    MCFG_CPU_PROGRAM_MAP(pachifev_map)
380380    MCFG_CPU_IO_MAP(pachifev_cru)
381    MCFG_CPU_VBLANK_INT("screen",pachifev_vblank_irq)
381   MCFG_CPU_VBLANK_INT_DRIVER("screen", pachifev_state, pachifev_vblank_irq)
382382
383383
384384    /* video hardware */
trunk/src/mame/drivers/kyugo.c
r17996r17997
523523   m_flipscreen = 0;
524524}
525525
526static INTERRUPT_GEN( vblank_irq )
526INTERRUPT_GEN_MEMBER(kyugo_state::vblank_irq)
527527{
528   kyugo_state *state = device->machine().driver_data<kyugo_state>();
529528
530   if(state->m_nmi_mask)
531      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
529   if(m_nmi_mask)
530      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
532531}
533532
534533
r17996r17997
538537   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)   /* verified on pcb */
539538   MCFG_CPU_PROGRAM_MAP(kyugo_main_map)
540539   MCFG_CPU_IO_MAP(kyugo_main_portmap)
541   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
540   MCFG_CPU_VBLANK_INT_DRIVER("screen", kyugo_state, vblank_irq)
542541
543542   MCFG_CPU_ADD("sub", Z80, XTAL_18_432MHz/6)   /* verified on pcb */
544543   MCFG_CPU_PROGRAM_MAP(gyrodine_sub_map)
545544   MCFG_CPU_IO_MAP(gyrodine_sub_portmap)
546   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
545   MCFG_CPU_PERIODIC_INT_DRIVER(kyugo_state, irq0_line_hold, 4*60)
547546
548547   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
549548
trunk/src/mame/drivers/leland.c
r17996r17997
737737   MCFG_CPU_ADD("master", Z80, MASTER_CLOCK/2)
738738   MCFG_CPU_PROGRAM_MAP(master_map_program)
739739   MCFG_CPU_IO_MAP(master_map_io)
740   MCFG_CPU_VBLANK_INT("screen", leland_master_interrupt)
740   MCFG_CPU_VBLANK_INT_DRIVER("screen", leland_state, leland_master_interrupt)
741741
742742   MCFG_CPU_ADD("slave", Z80, MASTER_CLOCK/2)
743743   MCFG_CPU_PROGRAM_MAP(slave_small_map_program)
trunk/src/mame/drivers/blockade.c
r17996r17997
5858/* Need to check for a coin on the interrupt, */
5959/* This will reset the cpu                    */
6060
61static INTERRUPT_GEN( blockade_interrupt )
61INTERRUPT_GEN_MEMBER(blockade_state::blockade_interrupt)
6262{
63   blockade_state *state = device->machine().driver_data<blockade_state>();
64   device->execute().resume(SUSPEND_ANY_REASON);
63   device.execute().resume(SUSPEND_ANY_REASON);
6564
66   if ((state->ioport("IN0")->read() & 0x80) == 0)
65   if ((ioport("IN0")->read() & 0x80) == 0)
6766   {
68      state->m_just_been_reset = 1;
69      device->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
67      m_just_been_reset = 1;
68      device.execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
7069   }
7170}
7271
r17996r17997
472471   MCFG_CPU_ADD("maincpu", I8080, MASTER_CLOCK/10)
473472   MCFG_CPU_PROGRAM_MAP(main_map)
474473   MCFG_CPU_IO_MAP(main_io_map)
475   MCFG_CPU_VBLANK_INT("screen", blockade_interrupt)
474   MCFG_CPU_VBLANK_INT_DRIVER("screen", blockade_state, blockade_interrupt)
476475
477476
478477   /* video hardware */
trunk/src/mame/drivers/lordgun.c
r17996r17997
657657static MACHINE_CONFIG_START( lordgun, lordgun_state )
658658   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
659659   MCFG_CPU_PROGRAM_MAP(lordgun_map)
660   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
660   MCFG_CPU_VBLANK_INT_DRIVER("screen", lordgun_state, irq4_line_hold)
661661
662662   MCFG_CPU_ADD("soundcpu", Z80, XTAL_20MHz / 4)
663663   MCFG_CPU_PROGRAM_MAP(lordgun_soundmem_map)
r17996r17997
699699static MACHINE_CONFIG_START( aliencha, lordgun_state )
700700   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
701701   MCFG_CPU_PROGRAM_MAP(aliencha_map)
702   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
702   MCFG_CPU_VBLANK_INT_DRIVER("screen", lordgun_state, irq4_line_hold)
703703
704704   MCFG_CPU_ADD("soundcpu", Z80, XTAL_20MHz / 4)
705705   MCFG_CPU_PROGRAM_MAP(lordgun_soundmem_map)
trunk/src/mame/drivers/lemmings.c
r17996r17997
263263   /* basic machine hardware */
264264   MCFG_CPU_ADD("maincpu", M68000, 14000000)
265265   MCFG_CPU_PROGRAM_MAP(lemmings_map)
266   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
266   MCFG_CPU_VBLANK_INT_DRIVER("screen", lemmings_state, irq6_line_hold)
267267
268268   MCFG_CPU_ADD("audiocpu", M6809,32220000/8)
269269   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/zerozone.c
r17996r17997
169169   /* basic machine hardware */
170170   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10 MHz */
171171   MCFG_CPU_PROGRAM_MAP(main_map)
172   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
172   MCFG_CPU_VBLANK_INT_DRIVER("screen", zerozone_state, irq1_line_hold)
173173
174174   MCFG_CPU_ADD("audiocpu", Z80, 1000000)   /* 1 MHz ??? */
175175   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/espial.c
r17996r17997
8888}
8989
9090
91INTERRUPT_GEN( espial_sound_nmi_gen )
91INTERRUPT_GEN_MEMBER(espial_state::espial_sound_nmi_gen)
9292{
93   espial_state *state = device->machine().driver_data<espial_state>();
9493
95   if (state->m_sound_nmi_enabled)
94   if (m_sound_nmi_enabled)
9695      nmi_line_pulse(device);
9796}
9897
r17996r17997
328327   MCFG_CPU_ADD("audiocpu", Z80, 3072000)   /* 2 MHz?????? */
329328   MCFG_CPU_PROGRAM_MAP(espial_sound_map)
330329   MCFG_CPU_IO_MAP(espial_sound_io_map)
331   MCFG_CPU_PERIODIC_INT(espial_sound_nmi_gen,4*60)
330   MCFG_CPU_PERIODIC_INT_DRIVER(espial_state, espial_sound_nmi_gen, 4*60)
332331
333332
334333   /* video hardware */
trunk/src/mame/drivers/tiamc1.c
r17996r17997
224224   MCFG_CPU_PROGRAM_MAP(tiamc1_map)
225225   MCFG_CPU_IO_MAP(tiamc1_io_map)
226226
227   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
227   MCFG_CPU_VBLANK_INT_DRIVER("screen", tiamc1_state, irq1_line_hold)
228228
229229
230230   /* video hardware */
trunk/src/mame/drivers/toaplan1.c
r17996r17997
15321532   /* basic machine hardware */
15331533   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
15341534   MCFG_CPU_PROGRAM_MAP(rallybik_main_map)
1535   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1535   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
15361536
15371537   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
15381538   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
15691569   /* basic machine hardware */
15701570   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
15711571   MCFG_CPU_PROGRAM_MAP(truxton_main_map)
1572   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1572   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
15731573
15741574   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
15751575   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
16061606   /* basic machine hardware */
16071607   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
16081608   MCFG_CPU_PROGRAM_MAP(hellfire_main_map)
1609   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1609   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
16101610
16111611   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
16121612   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
16431643   /* basic machine hardware */
16441644   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
16451645   MCFG_CPU_PROGRAM_MAP(zerowing_main_map)
1646   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1646   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
16471647
16481648   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
16491649   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
16801680   /* basic machine hardware */
16811681   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
16821682   MCFG_CPU_PROGRAM_MAP(demonwld_main_map)
1683   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1683   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
16841684
16851685   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
16861686   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
17211721   /* basic machine hardware */
17221722   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
17231723   MCFG_CPU_PROGRAM_MAP(samesame_main_map)
1724   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1724   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
17251725
17261726   MCFG_CPU_ADD("audiocpu", Z180, XTAL_28MHz/8)   /* HD647180XOFS6 CPU */
17271727   MCFG_CPU_PROGRAM_MAP(hd647180_mem_map)
r17996r17997
17561756   /* basic machine hardware */
17571757   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)
17581758   MCFG_CPU_PROGRAM_MAP(outzone_main_map)
1759   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1759   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
17601760
17611761   MCFG_CPU_ADD("audiocpu", Z80, XTAL_28MHz/8)
17621762   MCFG_CPU_PROGRAM_MAP(toaplan1_sound_map)
r17996r17997
17931793   /* basic machine hardware */
17941794   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz)   /* verified on pcb */
17951795   MCFG_CPU_PROGRAM_MAP(vimana_main_map)
1796   MCFG_CPU_VBLANK_INT("screen", toaplan1_interrupt)
1796   MCFG_CPU_VBLANK_INT_DRIVER("screen", toaplan1_state, toaplan1_interrupt)
17971797
17981798   MCFG_CPU_ADD("audiocpu", Z180, XTAL_28MHz/8)   /* HD647180XOFS6 CPU */
17991799   MCFG_CPU_PROGRAM_MAP(hd647180_mem_map)
trunk/src/mame/drivers/segag80r.c
r17996r17997
843843   MCFG_CPU_ADD("maincpu", Z80, VIDEO_CLOCK/4)
844844   MCFG_CPU_PROGRAM_MAP(main_map)
845845   MCFG_CPU_IO_MAP(main_portmap)
846   MCFG_CPU_VBLANK_INT("screen", segag80r_vblank_start)
846   MCFG_CPU_VBLANK_INT_DRIVER("screen", segag80r_state, segag80r_vblank_start)
847847
848848
849849   /* video hardware */
r17996r17997
931931   /* basic machine hardware */
932932   MCFG_CPU_MODIFY("maincpu")
933933   MCFG_CPU_IO_MAP(sindbadm_portmap)
934   MCFG_CPU_VBLANK_INT("screen", sindbadm_vblank_start)
934   MCFG_CPU_VBLANK_INT_DRIVER("screen", segag80r_state, sindbadm_vblank_start)
935935
936936   MCFG_I8255A_ADD( "ppi8255", sindbadm_ppi_intf )
937937
r17996r17997
943943
944944   MCFG_CPU_ADD("audiocpu", Z80, SINDBADM_SOUND_CLOCK/2)
945945   MCFG_CPU_PROGRAM_MAP(sindbadm_sound_map)
946   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
946   MCFG_CPU_PERIODIC_INT_DRIVER(segag80r_state, irq0_line_hold, 4*60)
947947
948948   /* sound hardware */
949949   MCFG_SOUND_ADD("sn1", SN76496_NEW, SINDBADM_SOUND_CLOCK/4)
trunk/src/mame/drivers/magic10.c
r17996r17997
730730   /* basic machine hardware */
731731   MCFG_CPU_ADD("maincpu", M68000, 10000000) // ?
732732   MCFG_CPU_PROGRAM_MAP(magic10_map)
733   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
733   MCFG_CPU_VBLANK_INT_DRIVER("screen", magic10_state, irq1_line_hold)
734734
735735   MCFG_NVRAM_ADD_0FILL("nvram")
736736
r17996r17997
787787   /* basic machine hardware */
788788   MCFG_CPU_MODIFY("maincpu")
789789   MCFG_CPU_PROGRAM_MAP(sgsafari_map)
790   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)   /* L1 interrupts */
790   MCFG_CPU_VBLANK_INT_DRIVER("screen", magic10_state, irq2_line_hold)   /* L1 interrupts */
791791
792792   MCFG_SCREEN_MODIFY("screen")
793793   MCFG_SCREEN_VISIBLE_AREA(0*8, 44*8-1, 0*8, 30*8-1)
trunk/src/mame/drivers/tmnt.c
r17996r17997
164164      k053244_w(m_k053245, space, offset + 1, data & 0xff);
165165}
166166
167static INTERRUPT_GEN(cuebrick_interrupt)
167INTERRUPT_GEN_MEMBER(tmnt_state::cuebrick_interrupt)
168168{
169   tmnt_state *state = device->machine().driver_data<tmnt_state>();
170169
171   if (state->m_irq5_mask)
172      device->execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
170   if (m_irq5_mask)
171      device.execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
173172}
174173
175static INTERRUPT_GEN( punkshot_interrupt )
174INTERRUPT_GEN_MEMBER(tmnt_state::punkshot_interrupt)
176175{
177   tmnt_state *state = device->machine().driver_data<tmnt_state>();
178176
179   if (k052109_is_irq_enabled(state->m_k052109))
177   if (k052109_is_irq_enabled(m_k052109))
180178      irq4_line_hold(device);
181179}
182180
183static INTERRUPT_GEN( lgtnfght_interrupt )
181INTERRUPT_GEN_MEMBER(tmnt_state::lgtnfght_interrupt)
184182{
185   tmnt_state *state = device->machine().driver_data<tmnt_state>();
186183
187   if (k052109_is_irq_enabled(state->m_k052109))
184   if (k052109_is_irq_enabled(m_k052109))
188185      irq5_line_hold(device);
189186}
190187
r17996r17997
22422239}
22432240
22442241/* cuebrick, mia and tmnt */
2245static INTERRUPT_GEN( tmnt_vblank_irq )
2242INTERRUPT_GEN_MEMBER(tmnt_state::tmnt_vblank_irq)
22462243{
2247   tmnt_state *state = device->machine().driver_data<tmnt_state>();
22482244
2249   if(state->m_irq5_mask)
2250      device->execute().set_input_line(5, HOLD_LINE);
2245   if(m_irq5_mask)
2246      device.execute().set_input_line(5, HOLD_LINE);
22512247}
22522248
22532249
r17996r17997
22562252   /* basic machine hardware */
22572253   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz */
22582254   MCFG_CPU_PROGRAM_MAP(cuebrick_main_map)
2259   MCFG_CPU_VBLANK_INT("screen",cuebrick_interrupt)
2255   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, cuebrick_interrupt)
22602256
22612257   MCFG_MACHINE_START_OVERRIDE(tmnt_state,common)
22622258   MCFG_MACHINE_RESET_OVERRIDE(tmnt_state,common)
r17996r17997
22942290   /* basic machine hardware */
22952291   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/3)
22962292   MCFG_CPU_PROGRAM_MAP(mia_main_map)
2297   MCFG_CPU_VBLANK_INT("screen", tmnt_vblank_irq)
2293   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, tmnt_vblank_irq)
22982294
22992295   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
23002296   MCFG_CPU_PROGRAM_MAP(mia_audio_map)
r17996r17997
23462342   /* basic machine hardware */
23472343   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/3)
23482344   MCFG_CPU_PROGRAM_MAP(tmnt_main_map)
2349   MCFG_CPU_VBLANK_INT("screen", tmnt_vblank_irq)
2345   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, tmnt_vblank_irq)
23502346
23512347   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
23522348   MCFG_CPU_PROGRAM_MAP(tmnt_audio_map)
r17996r17997
23982394   /* basic machine hardware */
23992395   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
24002396   MCFG_CPU_PROGRAM_MAP(punkshot_main_map)
2401   MCFG_CPU_VBLANK_INT("screen", punkshot_interrupt)
2397   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, punkshot_interrupt)
24022398
24032399   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
24042400   MCFG_CPU_PROGRAM_MAP(punkshot_audio_map)
r17996r17997
24402436   /* basic machine hardware */
24412437   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/2)
24422438   MCFG_CPU_PROGRAM_MAP(lgtnfght_main_map)
2443   MCFG_CPU_VBLANK_INT("screen", lgtnfght_interrupt)
2439   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, lgtnfght_interrupt)
24442440
24452441   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
24462442   MCFG_CPU_PROGRAM_MAP(lgtnfght_audio_map)
r17996r17997
24842480   /* basic machine hardware */
24852481   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
24862482   MCFG_CPU_PROGRAM_MAP(blswhstl_main_map)
2487   MCFG_CPU_VBLANK_INT("screen", punkshot_interrupt)
2483   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, punkshot_interrupt)
24882484
24892485   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
24902486   MCFG_CPU_PROGRAM_MAP(ssriders_audio_map)
r17996r17997
25502546   /* basic machine hardware */
25512547   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* Confirmed */
25522548   MCFG_CPU_PROGRAM_MAP(glfgreat_main_map)
2553   MCFG_CPU_VBLANK_INT("screen", lgtnfght_interrupt)
2549   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, lgtnfght_interrupt)
25542550
25552551   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
25562552   MCFG_CPU_PROGRAM_MAP(glfgreat_audio_map)
r17996r17997
26132609   /* basic machine hardware */
26142610   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)      /* Confirmed */
26152611   MCFG_CPU_PROGRAM_MAP(prmrsocr_main_map)
2616   MCFG_CPU_VBLANK_INT("screen", lgtnfght_interrupt)
2612   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, lgtnfght_interrupt)
26172613
26182614   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* ? */
26192615   MCFG_CPU_PROGRAM_MAP(prmrsocr_audio_map)
r17996r17997
26582654   /* basic machine hardware */
26592655   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
26602656   MCFG_CPU_PROGRAM_MAP(tmnt2_main_map)
2661   MCFG_CPU_VBLANK_INT("screen", punkshot_interrupt)
2657   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, punkshot_interrupt)
26622658
26632659   MCFG_CPU_ADD("audiocpu", Z80, 8000000)   /* 8 MHz; clock is correct, but there's 1 cycle wait for ROM/RAM */
26642660                  /* access. Access speed of ROM/RAM used on the machine is 150ns, */
r17996r17997
27092705   /* basic machine hardware */
27102706   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
27112707   MCFG_CPU_PROGRAM_MAP(ssriders_main_map)
2712   MCFG_CPU_VBLANK_INT("screen", punkshot_interrupt)
2708   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, punkshot_interrupt)
27132709
27142710   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ????? makes the ROM test sync */
27152711   MCFG_CPU_PROGRAM_MAP(ssriders_audio_map)
r17996r17997
27562752   /* basic machine hardware */
27572753   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
27582754   MCFG_CPU_PROGRAM_MAP(sunsetbl_main_map)
2759   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
2755   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, irq4_line_hold)
27602756
27612757   MCFG_MACHINE_START_OVERRIDE(tmnt_state,common)
27622758   MCFG_MACHINE_RESET_OVERRIDE(tmnt_state,common)
r17996r17997
27922788   /* basic machine hardware */
27932789   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz */
27942790   MCFG_CPU_PROGRAM_MAP(thndrx2_main_map)
2795   MCFG_CPU_VBLANK_INT("screen", punkshot_interrupt)
2791   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmnt_state, punkshot_interrupt)
27962792
27972793   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
27982794   MCFG_CPU_PROGRAM_MAP(thndrx2_audio_map)
trunk/src/mame/drivers/tasman.c
r17996r17997
598598
599599   MCFG_CPU_ADD("sndcpu", M68000, 16000000)
600600   MCFG_CPU_PROGRAM_MAP(kongamaud_map)
601   MCFG_CPU_PERIODIC_INT(irq2_line_hold, 480)
601   MCFG_CPU_PERIODIC_INT_DRIVER(kongambl_state, irq2_line_hold, 480)
602602
603603   MCFG_EEPROM_93C46_ADD("eeprom")
604604
trunk/src/mame/drivers/raiden2.c
r17996r17997
10061006 *
10071007 *************************************/
10081008
1009static INTERRUPT_GEN( raiden2_interrupt )
1009INTERRUPT_GEN_MEMBER(raiden2_state::raiden2_interrupt)
10101010{
1011   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc0/4);   /* VBL */
1011   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc0/4);   /* VBL */
10121012}
10131013
10141014
r17996r17997
18251825   /* basic machine hardware */
18261826   MCFG_CPU_ADD("maincpu", V30,XTAL_32MHz/2) /* verified on pcb */
18271827   MCFG_CPU_PROGRAM_MAP(raiden2_mem)
1828   MCFG_CPU_VBLANK_INT("screen", raiden2_interrupt)
1828   MCFG_CPU_VBLANK_INT_DRIVER("screen", raiden2_state, raiden2_interrupt)
18291829
18301830   MCFG_MACHINE_RESET_OVERRIDE(raiden2_state,raiden2)
18311831
r17996r17997
18811881   /* basic machine hardware */
18821882   MCFG_CPU_ADD("maincpu", V30,XTAL_32MHz/2) /* verified on pcb */
18831883   MCFG_CPU_PROGRAM_MAP(zeroteam_mem)
1884   MCFG_CPU_VBLANK_INT("screen", raiden2_interrupt)
1884   MCFG_CPU_VBLANK_INT_DRIVER("screen", raiden2_state, raiden2_interrupt)
18851885
18861886   MCFG_MACHINE_RESET_OVERRIDE(raiden2_state,zeroteam)
18871887
trunk/src/mame/drivers/zodiack.c
r17996r17997
115115      timer.machine().device("maincpu")->execute().set_input_line(0, HOLD_LINE);
116116}
117117
118static INTERRUPT_GEN( zodiack_sound_nmi_gen )
118INTERRUPT_GEN_MEMBER(zodiack_state::zodiack_sound_nmi_gen)
119119{
120   zodiack_state *state = device->machine().driver_data<zodiack_state>();
121120
122   if (state->m_sound_nmi_enabled)
121   if (m_sound_nmi_enabled)
123122      nmi_line_pulse(device);
124123}
125124
r17996r17997
565564   MCFG_CPU_ADD("audiocpu", Z80, 14318000/8)   /* 1.78975 MHz??? */
566565   MCFG_CPU_PROGRAM_MAP(sound_map)
567566   MCFG_CPU_IO_MAP(io_map)
568   MCFG_CPU_PERIODIC_INT(zodiack_sound_nmi_gen,8*60)   /* IRQs are triggered by the main CPU */
567   MCFG_CPU_PERIODIC_INT_DRIVER(zodiack_state, zodiack_sound_nmi_gen, 8*60)   /* IRQs are triggered by the main CPU */
569568
570569   /* video hardware */
571570   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mogura.c
r17996r17997
204204   MCFG_CPU_ADD("maincpu", Z80,3000000)       /* 3 MHz */
205205   MCFG_CPU_PROGRAM_MAP(mogura_map)
206206   MCFG_CPU_IO_MAP(mogura_io_map)
207   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
207   MCFG_CPU_VBLANK_INT_DRIVER("screen", mogura_state, irq0_line_hold)
208208
209209
210210   MCFG_GFXDECODE(mogura)
trunk/src/mame/drivers/taitojc.c
r17996r17997
12171217   m_dsp->set_input_line(INPUT_LINE_RESET, ASSERT_LINE);
12181218}
12191219
1220static INTERRUPT_GEN( taitojc_vblank )
1220INTERRUPT_GEN_MEMBER(taitojc_state::taitojc_vblank)
12211221{
1222   device->execute().set_input_line_and_vector(2, HOLD_LINE, 130);
1222   device.execute().set_input_line_and_vector(2, HOLD_LINE, 130);
12231223}
12241224
12251225static const tc0640fio_interface taitojc_io_intf =
r17996r17997
12391239   /* basic machine hardware */
12401240   MCFG_CPU_ADD("maincpu", M68040, 25000000)
12411241   MCFG_CPU_PROGRAM_MAP(taitojc_map)
1242   MCFG_CPU_VBLANK_INT("screen", taitojc_vblank)
1242   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitojc_state, taitojc_vblank)
12431243
12441244   MCFG_CPU_ADD("sub", MC68HC11, 4000000) // MC68HC11M0
12451245   MCFG_CPU_PROGRAM_MAP(hc11_pgm_map)
trunk/src/mame/drivers/ddealer.c
r17996r17997
157157   virtual void machine_reset();
158158   virtual void video_start();
159159   UINT32 screen_update_ddealer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
160   INTERRUPT_GEN_MEMBER(ddealer_interrupt);
160161};
161162
162163
r17996r17997
618619   m_coin_input = 0;
619620}
620621
621static INTERRUPT_GEN( ddealer_interrupt )
622INTERRUPT_GEN_MEMBER(ddealer_state::ddealer_interrupt)
622623{
623   device->execute().set_input_line(4, HOLD_LINE);
624   device.execute().set_input_line(4, HOLD_LINE);
624625}
625626
626627static MACHINE_CONFIG_START( ddealer, ddealer_state )
627628
628629   MCFG_CPU_ADD("maincpu" , M68000, 10000000)
629630   MCFG_CPU_PROGRAM_MAP(ddealer)
630   MCFG_CPU_VBLANK_INT("screen", ddealer_interrupt)
631   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 90)//guess,controls music tempo,112 is way too fast
631   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddealer_state,  ddealer_interrupt)
632   MCFG_CPU_PERIODIC_INT_DRIVER(ddealer_state, irq1_line_hold,  90)//guess,controls music tempo,112 is way too fast
632633
633634   // M50747 or NMK-110 8131 MCU
634635
trunk/src/mame/drivers/vpoker.c
r17996r17997
656656   /* basic machine hardware */
657657   MCFG_CPU_ADD("maincpu",M6809,XTAL_4MHz)
658658   MCFG_CPU_PROGRAM_MAP(main_map)
659//  MCFG_CPU_VBLANK_INT("screen",irq0_line_hold) //irq0 valid too
659   MCFG_CPU_VBLANK_INT_DRIVER("screen", vpoker_state, irq0_line_hold) //irq0 valid too
660660
661661   /* video hardware */
662662   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/suprridr.c
r17996r17997
9999}
100100
101101
102static INTERRUPT_GEN( main_nmi_gen )
102INTERRUPT_GEN_MEMBER(suprridr_state::main_nmi_gen)
103103{
104   suprridr_state *state = device->machine().driver_data<suprridr_state>();
105   if (state->m_nmi_enable)
106      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
104   if (m_nmi_enable)
105      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
107106}
108107
109108
r17996r17997
360359   MCFG_CPU_ADD("maincpu", Z80, XTAL_49_152MHz/16)      /* 3 MHz */
361360   MCFG_CPU_PROGRAM_MAP(main_map)
362361   MCFG_CPU_IO_MAP(main_portmap)
363   MCFG_CPU_VBLANK_INT("screen", main_nmi_gen)
362   MCFG_CPU_VBLANK_INT_DRIVER("screen", suprridr_state, main_nmi_gen)
364363
365364   MCFG_CPU_ADD("audiocpu", Z80, 10000000/4)      /* 2.5 MHz */
366365   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/spy.c
r17996r17997
2626#include "includes/konamipt.h"
2727#include "includes/spy.h"
2828
29static INTERRUPT_GEN( spy_interrupt )
29INTERRUPT_GEN_MEMBER(spy_state::spy_interrupt)
3030{
31   spy_state *state = device->machine().driver_data<spy_state>();
3231
33   if (k052109_is_irq_enabled(state->m_k052109))
34      device->execute().set_input_line(0, HOLD_LINE);
32   if (k052109_is_irq_enabled(m_k052109))
33      device.execute().set_input_line(0, HOLD_LINE);
3534}
3635
3736READ8_MEMBER(spy_state::spy_bankedram1_r)
r17996r17997
532531   /* basic machine hardware */
533532   MCFG_CPU_ADD("maincpu", M6809, 3000000) /* ? */
534533   MCFG_CPU_PROGRAM_MAP(spy_map)
535   MCFG_CPU_VBLANK_INT("screen", spy_interrupt)
534   MCFG_CPU_VBLANK_INT_DRIVER("screen", spy_state, spy_interrupt)
536535
537536   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
538537   MCFG_CPU_PROGRAM_MAP(spy_sound_map)
trunk/src/mame/drivers/igs009.c
r17996r17997
9090   virtual void video_start();
9191   DECLARE_VIDEO_START(gp98);
9292   UINT32 screen_update_jingbell(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
93   INTERRUPT_GEN_MEMBER(jingbell_interrupt);
9394};
9495
9596
r17996r17997
733734   m_video_enable   =   1;
734735}
735736
736static INTERRUPT_GEN( jingbell_interrupt )
737INTERRUPT_GEN_MEMBER(igs009_state::jingbell_interrupt)
737738{
738   igs009_state *state = device->machine().driver_data<igs009_state>();
739    if (state->m_nmi_enable & 0x80)
740      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
739    if (m_nmi_enable & 0x80)
740      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
741741}
742742
743743static MACHINE_CONFIG_START( jingbell, igs009_state )
r17996r17997
745745   MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2)   /* HD64180RP8, 8 MHz? */
746746   MCFG_CPU_PROGRAM_MAP(jingbell_map)
747747   MCFG_CPU_IO_MAP(jingbell_portmap)
748   MCFG_CPU_VBLANK_INT("screen",jingbell_interrupt)
748   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs009_state, jingbell_interrupt)
749749
750750
751751   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/blitz68k.c
r17996r17997
17151715static MACHINE_CONFIG_START( ilpag, blitz68k_state )
17161716   MCFG_CPU_ADD("maincpu", M68000, 11059200 )   // ?
17171717   MCFG_CPU_PROGRAM_MAP(ilpag_map)
1718   MCFG_CPU_VBLANK_INT("screen",irq4_line_hold) //3 & 6 used, mcu comms?
1718   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq4_line_hold) //3 & 6 used, mcu comms?
17191719
17201720   MCFG_SCREEN_ADD("screen", RASTER)
17211721   MCFG_SCREEN_REFRESH_RATE(60)
r17996r17997
17791779static MACHINE_CONFIG_DERIVED( steaser, ilpag )
17801780   MCFG_CPU_MODIFY("maincpu")
17811781   MCFG_CPU_PROGRAM_MAP(steaser_map)
1782   MCFG_CPU_VBLANK_INT("screen",irq5_line_hold) //3, 4 & 6 used, mcu comms?
1782   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq5_line_hold) //3, 4 & 6 used, mcu comms?
17831783
17841784   MCFG_TIMER_ADD_PERIODIC("coinsim", steaser_mcu_sim, attotime::from_hz(10000)) // not real, but for simulating the MCU
17851785MACHINE_CONFIG_END
r17996r17997
18151815static MACHINE_CONFIG_START( bankrob, blitz68k_state )
18161816   MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz)
18171817   MCFG_CPU_PROGRAM_MAP(bankrob_map)
1818   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)   // protection prevents correct irq frequency by crtc
1818   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold)   // protection prevents correct irq frequency by crtc
18191819   // irq 2 reads from MCUs
18201820
18211821   // MC68HC705C8P (MCU1)
r17996r17997
18471847static MACHINE_CONFIG_START( bankroba, blitz68k_state )
18481848   MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz )
18491849   MCFG_CPU_PROGRAM_MAP(bankroba_map)
1850   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)   // protection prevents correct irq frequency by crtc
1850   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq5_line_hold)   // protection prevents correct irq frequency by crtc
18511851   // irq 3,4 read from MCUs
18521852
18531853   // MC68HC705C8P (MCU)
r17996r17997
19061906static MACHINE_CONFIG_START( dualgame, blitz68k_state )
19071907   MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz )
19081908   MCFG_CPU_PROGRAM_MAP(dualgame_map)
1909   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold) // lev 2 = MCUs, lev 3 = vblank
1909   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq2_line_hold) // lev 2 = MCUs, lev 3 = vblank
19101910
19111911   // MC68HC705C8P (MCU1)
19121912
r17996r17997
19371937static MACHINE_CONFIG_START( hermit, blitz68k_state )
19381938   MCFG_CPU_ADD("maincpu", M68000, XTAL_22_1184MHz/2 )
19391939   MCFG_CPU_PROGRAM_MAP(hermit_map)
1940   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)   // protection prevents correct irq frequency by crtc
1940   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq1_line_hold)   // protection prevents correct irq frequency by crtc
19411941
19421942   // MC68HC705C8P (MCU)
19431943
r17996r17997
19661966static MACHINE_CONFIG_START( maxidbl, blitz68k_state )
19671967   MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz)
19681968   MCFG_CPU_PROGRAM_MAP(maxidbl_map)
1969   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)   // protection prevents correct irq frequency by crtc
1969   MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold)   // protection prevents correct irq frequency by crtc
19701970   // irq 2 reads from MCUs
19711971
19721972   // MC68HC705C8P (MCU1)
trunk/src/mame/drivers/psikyo.c
r17996r17997
10491049   /* basic machine hardware */
10501050   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_32MHz/2) /* verified on pcb */
10511051   MCFG_CPU_PROGRAM_MAP(psikyo_map)
1052   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1052   MCFG_CPU_VBLANK_INT_DRIVER("screen", psikyo_state, irq1_line_hold)
10531053
10541054   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8) /* verified on pcb */
10551055   MCFG_CPU_PROGRAM_MAP(sngkace_sound_map)
r17996r17997
10981098   /* basic machine hardware */
10991099   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)
11001100   MCFG_CPU_PROGRAM_MAP(psikyo_map)
1101   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1101   MCFG_CPU_VBLANK_INT_DRIVER("screen", psikyo_state, irq1_line_hold)
11021102
11031103   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ! LZ8420M (Z80 core) ! */
11041104   MCFG_CPU_PROGRAM_MAP(gunbird_sound_map)
r17996r17997
11351135   /* basic machine hardware */
11361136   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)
11371137   MCFG_CPU_PROGRAM_MAP(psikyo_bootleg_map)
1138   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1138   MCFG_CPU_VBLANK_INT_DRIVER("screen", psikyo_state, irq1_line_hold)
11391139
11401140
11411141   /* video hardware */
r17996r17997
11831183   /* basic machine hardware */
11841184   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)
11851185   MCFG_CPU_PROGRAM_MAP(psikyo_map)
1186   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
1186   MCFG_CPU_VBLANK_INT_DRIVER("screen", psikyo_state, irq1_line_hold)
11871187
11881188   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* ! LZ8420M (Z80 core) ! */
11891189   MCFG_CPU_PROGRAM_MAP(gunbird_sound_map)
trunk/src/mame/drivers/dacholer.c
r17996r17997
9090   virtual void video_start();
9191   virtual void palette_init();
9292   UINT32 screen_update_dacholer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
93   INTERRUPT_GEN_MEMBER(sound_irq);
9394};
9495
9596TILE_GET_INFO_MEMBER(dacholer_state::get_bg_tile_info)
r17996r17997
549550GFXDECODE_END
550551
551552
552static INTERRUPT_GEN( sound_irq )
553INTERRUPT_GEN_MEMBER(dacholer_state::sound_irq)
553554{
554   dacholer_state *state = device->machine().driver_data<dacholer_state>();
555   if (state->m_music_interrupt_enable == 1)
555   if (m_music_interrupt_enable == 1)
556556   {
557      device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x30);
557      device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x30);
558558   }
559559}
560560
r17996r17997
652652   MCFG_CPU_ADD("maincpu", Z80, XTAL_16MHz/4)   /* ? */
653653   MCFG_CPU_PROGRAM_MAP(main_map)
654654   MCFG_CPU_IO_MAP(main_io_map)
655   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
655   MCFG_CPU_VBLANK_INT_DRIVER("screen", dacholer_state, irq0_line_assert)
656656
657657   MCFG_CPU_ADD("audiocpu", Z80, XTAL_19_968MHz/8)   /* ? */
658658   MCFG_CPU_PROGRAM_MAP(snd_map)
659659   MCFG_CPU_IO_MAP(snd_io_map)
660   MCFG_CPU_VBLANK_INT("screen",sound_irq)
660   MCFG_CPU_VBLANK_INT_DRIVER("screen", dacholer_state, sound_irq)
661661
662662
663663   /* video hardware */
trunk/src/mame/drivers/tapatune.c
r17996r17997
385385   MCFG_CPU_ADD("soundcpu", Z80, 24000000/6 )
386386   MCFG_CPU_PROGRAM_MAP(sound_map)
387387   MCFG_CPU_IO_MAP(sound_io_map)
388   MCFG_CPU_PERIODIC_INT(irq0_line_assert, 183)
388   MCFG_CPU_PERIODIC_INT_DRIVER(tapatune_state, irq0_line_assert, 183)
389389
390390   /* video hardware */
391391   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/esd16.c
r17996r17997
616616   /* basic machine hardware */
617617   MCFG_CPU_ADD("maincpu",M68000, XTAL_16MHz)   /* 16MHz */
618618   MCFG_CPU_PROGRAM_MAP(multchmp_map)
619   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
619   MCFG_CPU_VBLANK_INT_DRIVER("screen", esd16_state, irq6_line_hold)
620620
621621   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)   /* 4MHz */
622622   MCFG_CPU_PROGRAM_MAP(multchmp_sound_map)
623623   MCFG_CPU_IO_MAP(multchmp_sound_io_map)
624   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,32*60)   /* IRQ By Main CPU */
624   MCFG_CPU_PERIODIC_INT_DRIVER(esd16_state, nmi_line_pulse, 32*60)   /* IRQ By Main CPU */
625625
626626
627627   /* video hardware */
trunk/src/mame/drivers/cb2001.c
r17996r17997
7272   virtual void video_start();
7373   virtual void palette_init();
7474   UINT32 screen_update_cb2001(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
75   INTERRUPT_GEN_MEMBER(vblank_irq);
7576};
7677
7778
r17996r17997
737738
738739INPUT_PORTS_END
739740
740static INTERRUPT_GEN( vblank_irq )
741INTERRUPT_GEN_MEMBER(cb2001_state::vblank_irq)
741742{
742   generic_pulse_irq_line(device, NEC_INPUT_LINE_INTP0, 1);
743   generic_pulse_irq_line(device.execute(), NEC_INPUT_LINE_INTP0, 1);
743744}
744745
745746static const gfx_layout cb2001_layout =
r17996r17997
836837   MCFG_CPU_CONFIG(cb2001_config)
837838   MCFG_CPU_PROGRAM_MAP(cb2001_map)
838839   MCFG_CPU_IO_MAP(cb2001_io)
839   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
840   MCFG_CPU_VBLANK_INT_DRIVER("screen", cb2001_state, vblank_irq)
840841
841842   MCFG_I8255A_ADD( "ppi8255_0", ppi8255_0_intf )
842843   MCFG_I8255A_ADD( "ppi8255_1", ppi8255_1_intf )
trunk/src/mame/drivers/funkyjet.c
r17996r17997
312312   /* basic machine hardware */
313313   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2) /* 28 MHz crystal */
314314   MCFG_CPU_PROGRAM_MAP(funkyjet_map)
315   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
315   MCFG_CPU_VBLANK_INT_DRIVER("screen", funkyjet_state, irq6_line_hold)
316316
317317   MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
318318   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/wallc.c
r17996r17997
302302   /* basic machine hardware */
303303   MCFG_CPU_ADD("maincpu", Z80, 12288000 / 4)   /* 3.072 MHz ? */
304304   MCFG_CPU_PROGRAM_MAP(wallc_map)
305   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", wallc_state, irq0_line_hold)
306306
307307   /* video hardware */
308308   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/marinedt.c
r17996r17997
673673   MCFG_CPU_ADD("maincpu", Z80,10000000/4)
674674   MCFG_CPU_PROGRAM_MAP(marinedt_map)
675675   MCFG_CPU_IO_MAP(marinedt_io_map)
676   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
676   MCFG_CPU_VBLANK_INT_DRIVER("screen", marinedt_state, irq0_line_hold)
677677
678678
679679   /* video hardware */
trunk/src/mame/drivers/sliver.c
r17996r17997
473473static MACHINE_CONFIG_START( sliver, sliver_state )
474474   MCFG_CPU_ADD("maincpu", M68000, 12000000)
475475   MCFG_CPU_PROGRAM_MAP(sliver_map)
476   MCFG_CPU_VBLANK_INT("screen",irq4_line_hold)
476   MCFG_CPU_VBLANK_INT_DRIVER("screen", sliver_state, irq4_line_hold)
477477   MCFG_TIMER_ADD_PERIODIC("obj_actel", obj_irq_cb, attotime::from_hz(60)) /* unknown clock, causes "obj actel ready error" without this */
478478   // irq 2 valid but not used?
479479
trunk/src/mame/drivers/epos.c
r17996r17997
398398   MCFG_CPU_ADD("maincpu", Z80, 11000000/4)   /* 2.75 MHz (see notes) */
399399   MCFG_CPU_PROGRAM_MAP(epos_map)
400400   MCFG_CPU_IO_MAP(io_map)
401   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
401   MCFG_CPU_VBLANK_INT_DRIVER("screen", epos_state, irq0_line_hold)
402402
403403
404404   /* video hardware */
r17996r17997
422422   MCFG_CPU_ADD("maincpu", Z80, 11000000/4)   /* 2.75 MHz (see notes) */
423423   MCFG_CPU_PROGRAM_MAP(dealer_map)
424424   MCFG_CPU_IO_MAP(dealer_io_map)
425   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
425   MCFG_CPU_VBLANK_INT_DRIVER("screen", epos_state, irq0_line_hold)
426426
427427   MCFG_I8255A_ADD( "ppi8255", ppi8255_intf )
428428
trunk/src/mame/drivers/mrflea.c
r17996r17997
357357   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz? */
358358   MCFG_CPU_PROGRAM_MAP(mrflea_master_map)
359359   MCFG_CPU_IO_MAP(mrflea_master_io_map)
360   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* NMI resets the game */
360   MCFG_CPU_VBLANK_INT_DRIVER("screen", mrflea_state, irq0_line_hold) /* NMI resets the game */
361361
362362   MCFG_CPU_ADD("sub", Z80, 6000000)
363363   MCFG_CPU_PROGRAM_MAP(mrflea_slave_map)
trunk/src/mame/drivers/cps3.c
r17996r17997
22432243   PORT_BIT( 0x00200000, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_PLAYER(2)
22442244INPUT_PORTS_END
22452245
2246static INTERRUPT_GEN(cps3_vbl_interrupt)
2246INTERRUPT_GEN_MEMBER(cps3_state::cps3_vbl_interrupt)
22472247{
2248   device->execute().set_input_line(12, ASSERT_LINE);
2248   device.execute().set_input_line(12, ASSERT_LINE);
22492249}
22502250
2251static INTERRUPT_GEN(cps3_other_interrupt)
2251INTERRUPT_GEN_MEMBER(cps3_state::cps3_other_interrupt)
22522252{
22532253   // this seems to need to be periodic (see the life bar portraits in sfiii2
22542254   // but also triggered on certain dma events (or warzard locks up in attract)
22552255   // what is the REAL source of IRQ10??
2256   device->execute().set_input_line(10, ASSERT_LINE);
2256   device.execute().set_input_line(10, ASSERT_LINE);
22572257}
22582258
22592259
r17996r17997
24942494   /* basic machine hardware */
24952495   MCFG_CPU_ADD("maincpu", SH2, 6250000*4) // external clock is 6.25 Mhz, it sets the intenral multiplier to 4x (this should probably be handled in the core..)
24962496   MCFG_CPU_PROGRAM_MAP(cps3_map)
2497   MCFG_CPU_VBLANK_INT("screen", cps3_vbl_interrupt)
2498   MCFG_CPU_PERIODIC_INT(cps3_other_interrupt,80) /* ?source? */
2497   MCFG_CPU_VBLANK_INT_DRIVER("screen", cps3_state,  cps3_vbl_interrupt)
2498   MCFG_CPU_PERIODIC_INT_DRIVER(cps3_state, cps3_other_interrupt, 80) /* ?source? */
24992499   MCFG_CPU_CONFIG(sh2_conf_cps3)
25002500
25012501   MCFG_SCSIBUS_ADD("scsi")
trunk/src/mame/drivers/glass.c
r17996r17997
1818   m_cause_interrupt = 1;
1919}
2020
21static INTERRUPT_GEN( glass_interrupt )
21INTERRUPT_GEN_MEMBER(glass_state::glass_interrupt)
2222{
23   glass_state *state = device->machine().driver_data<glass_state>();
2423
25   if (state->m_cause_interrupt)
24   if (m_cause_interrupt)
2625   {
27      device->execute().set_input_line(6, HOLD_LINE);
28      state->m_cause_interrupt = 0;
26      device.execute().set_input_line(6, HOLD_LINE);
27      m_cause_interrupt = 0;
2928   }
3029}
3130
r17996r17997
196195   /* basic machine hardware */
197196   MCFG_CPU_ADD("maincpu", M68000,24000000/2)      /* 12 MHz (M680000 P12) */
198197   MCFG_CPU_PROGRAM_MAP(glass_map)
199   MCFG_CPU_VBLANK_INT("screen", glass_interrupt)
198   MCFG_CPU_VBLANK_INT_DRIVER("screen", glass_state, glass_interrupt)
200199
201200
202201   /* video hardware */
trunk/src/mame/drivers/spiders.c
r17996r17997
269269   DEVCB_DRIVER_LINE_MEMBER(spiders_state,main_cpu_irq)      /* IRQB */
270270};
271271
272static INTERRUPT_GEN( update_pia_1 )
272INTERRUPT_GEN_MEMBER(spiders_state::update_pia_1)
273273{
274   pia6821_device *pia1 = device->machine().device<pia6821_device>("pia1");
274   pia6821_device *pia1 = machine().device<pia6821_device>("pia1");
275275   /* update the different PIA pins from the input ports */
276276
277277   /* CA1 - copy of PA1 (COIN1) */
278   pia1->ca1_w(device->machine().root_device().ioport("IN0")->read() & 0x02);
278   pia1->ca1_w(machine().root_device().ioport("IN0")->read() & 0x02);
279279
280280   /* CA2 - copy of PA0 (SERVICE1) */
281   pia1->ca2_w(device->machine().root_device().ioport("IN0")->read() & 0x01);
281   pia1->ca2_w(machine().root_device().ioport("IN0")->read() & 0x01);
282282
283283   /* CB1 - (crosshatch) */
284   pia1->cb1_w(device->machine().root_device().ioport("XHATCH")->read());
284   pia1->cb1_w(machine().root_device().ioport("XHATCH")->read());
285285
286286   /* CB2 - NOT CONNECTED */
287287}
r17996r17997
693693   /* basic machine hardware */
694694   MCFG_CPU_ADD("maincpu", M6809, 2800000)
695695   MCFG_CPU_PROGRAM_MAP(spiders_main_map)
696   MCFG_CPU_PERIODIC_INT(update_pia_1, 25)
696   MCFG_CPU_PERIODIC_INT_DRIVER(spiders_state, update_pia_1, 25)
697697
698698   MCFG_CPU_ADD("audiocpu", M6802, 3000000)
699699   MCFG_CPU_PROGRAM_MAP(spiders_audio_map)
trunk/src/mame/drivers/ddz.c
r17996r17997
2525   virtual void video_start();
2626   UINT32 screen_update_ddz(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
2727   void screen_eof_ddz(screen_device &screen, bool state);
28   INTERRUPT_GEN_MEMBER(ddz_interrupt);
2829};
2930
3031
r17996r17997
4748
4849}
4950
50static INTERRUPT_GEN(ddz_interrupt)
51INTERRUPT_GEN_MEMBER(ddz_state::ddz_interrupt)
5152{
5253//  IntReq(24);     //VRender0 VBlank
5354}
r17996r17997
6667static MACHINE_CONFIG_START( ddz, ddz_state )
6768   MCFG_CPU_ADD("maincpu", SE3208, 43000000)
6869   MCFG_CPU_PROGRAM_MAP(ddz_mem)
69   MCFG_CPU_VBLANK_INT("screen", ddz_interrupt)
70   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddz_state, ddz_interrupt)
7071
7172   //MCFG_MACHINE_RESET_OVERRIDE(ddz_state,ddz)
7273
trunk/src/mame/drivers/mlanding.c
r17996r17997
768768   /* basic machine hardware */
769769   MCFG_CPU_ADD("maincpu", M68000, 12000000 )      /* 12 MHz ??? (guess) */
770770   MCFG_CPU_PROGRAM_MAP(mlanding_mem)
771   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
771   MCFG_CPU_VBLANK_INT_DRIVER("screen", mlanding_state, irq6_line_hold)
772772
773773   MCFG_CPU_ADD("sub", M68000, 12000000 )      /* 12 MHz ??? (guess) */
774774   MCFG_CPU_PROGRAM_MAP(mlanding_sub_mem)
775   MCFG_CPU_PERIODIC_INT(irq6_line_hold,7*60) /* ??? */
775   MCFG_CPU_PERIODIC_INT_DRIVER(mlanding_state, irq6_line_hold, 7*60) /* ??? */
776776
777777   MCFG_CPU_ADD("audiocpu", Z80, 4000000 )      /* 4 MHz ??? (guess) */
778778   MCFG_CPU_PROGRAM_MAP(mlanding_z80_mem)
779779
780780   MCFG_CPU_ADD("z80sub", Z80, 4000000 )      /* 4 MHz ??? (guess) */
781781   MCFG_CPU_PROGRAM_MAP(mlanding_z80_sub_mem)
782   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
782   MCFG_CPU_VBLANK_INT_DRIVER("screen", mlanding_state, irq0_line_hold)
783783
784784   MCFG_CPU_ADD("dsp", TMS32025,12000000)         /* 12 MHz ??? */
785785   MCFG_CPU_PROGRAM_MAP(DSP_map_program)
trunk/src/mame/drivers/tankbust.c
r17996r17997
317317   m_variable_data = 0x11;
318318}
319319
320static INTERRUPT_GEN( vblank_irq )
320INTERRUPT_GEN_MEMBER(tankbust_state::vblank_irq)
321321{
322   tankbust_state *state = device->machine().driver_data<tankbust_state>();
323322
324   if(state->m_irq_mask)
325      device->execute().set_input_line(0, HOLD_LINE);
323   if(m_irq_mask)
324      device.execute().set_input_line(0, HOLD_LINE);
326325}
327326
328327static MACHINE_CONFIG_START( tankbust, tankbust_state )
r17996r17997
330329   /* basic machine hardware */
331330   MCFG_CPU_ADD("maincpu", Z80, XTAL_14_31818MHz/2)   /* Verified on PCB */
332331   MCFG_CPU_PROGRAM_MAP(main_map)
333   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
332   MCFG_CPU_VBLANK_INT_DRIVER("screen", tankbust_state, vblank_irq)
334333
335334   MCFG_CPU_ADD("sub", Z80, XTAL_14_31818MHz/4)      /* Verified on PCB */
336335//  MCFG_CPU_ADD("sub", Z80, XTAL_14_31818MHz/3)        /* Accurate to audio recording, but apparently incorrect clock */
trunk/src/mame/drivers/bankp.c
r17996r17997
289289   m_priority = 0;
290290}
291291
292static INTERRUPT_GEN( vblank_irq )
292INTERRUPT_GEN_MEMBER(bankp_state::vblank_irq)
293293{
294   bankp_state *state = device->machine().driver_data<bankp_state>();
295294
296   if(state->m_nmi_mask)
297      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
295   if(m_nmi_mask)
296      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
298297}
299298
300299static MACHINE_CONFIG_START( bankp, bankp_state )
r17996r17997
303302   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)
304303   MCFG_CPU_PROGRAM_MAP(bankp_map)
305304   MCFG_CPU_IO_MAP(bankp_io_map)
306   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", bankp_state, vblank_irq)
307306
308307
309308   /* video hardware */
trunk/src/mame/drivers/neoprint.c
r17996r17997
464464static MACHINE_CONFIG_START( neoprint, neoprint_state )
465465   MCFG_CPU_ADD("maincpu", M68000, 12000000)
466466   MCFG_CPU_PROGRAM_MAP(neoprint_map)
467//  MCFG_CPU_PERIODIC_INT(irq3_line_hold,45) /* camera / printer irq, unknown timing */
468   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold) // lv1,2,3 valid?
467   MCFG_CPU_PERIODIC_INT_DRIVER(neoprint_state, irq3_line_hold, 45) /* camera / printer irq, unknown timing */
468   MCFG_CPU_VBLANK_INT_DRIVER("screen", neoprint_state,  irq2_line_hold) // lv1,2,3 valid?
469469
470470   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
471471   MCFG_CPU_PROGRAM_MAP(neoprint_audio_map)
r17996r17997
504504static MACHINE_CONFIG_START( nprsp, neoprint_state )
505505   MCFG_CPU_ADD("maincpu", M68000, 12000000)
506506   MCFG_CPU_PROGRAM_MAP(nprsp_map)
507//  MCFG_CPU_PERIODIC_INT(irq3_line_hold,45) /* camera / printer irq, unknown timing */
508   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold) // lv1,2,3 valid?
507   MCFG_CPU_PERIODIC_INT_DRIVER(neoprint_state, irq3_line_hold, 45) /* camera / printer irq, unknown timing */
508   MCFG_CPU_VBLANK_INT_DRIVER("screen", neoprint_state,  irq2_line_hold) // lv1,2,3 valid?
509509
510510   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
511511   MCFG_CPU_PROGRAM_MAP(neoprint_audio_map)
trunk/src/mame/drivers/pastelg.c
r17996r17997
410410   MCFG_CPU_ADD("maincpu", Z80, 19968000/4)   /* unknown divider, galds definitely relies on this for correct voice pitch */
411411   MCFG_CPU_PROGRAM_MAP(pastelg_map)
412412   MCFG_CPU_IO_MAP(pastelg_io_map)
413   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert) // nmiclock not written, chip is 1411M1 instead of 1413M3
413   MCFG_CPU_VBLANK_INT_DRIVER("screen", pastelg_state, irq0_line_assert) // nmiclock not written, chip is 1411M1 instead of 1413M3
414414
415415   MCFG_MACHINE_RESET(nb1413m3)
416416   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
466466   MCFG_CPU_ADD("maincpu", Z80, 19968000/4)   /* unknown divider, galds definitely relies on this for correct voice pitch */
467467   MCFG_CPU_PROGRAM_MAP(pastelg_map)
468468   MCFG_CPU_IO_MAP(threeds_io_map)
469   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
469   MCFG_CPU_VBLANK_INT_DRIVER("screen", pastelg_state, irq0_line_assert)
470470
471471   MCFG_MACHINE_RESET(nb1413m3)
472472   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/galastrm.c
r17996r17997
4848
4949/*********************************************************************/
5050
51static INTERRUPT_GEN( galastrm_interrupt )
51INTERRUPT_GEN_MEMBER(galastrm_state::galastrm_interrupt)
5252{
53   galastrm_state *state = device->machine().driver_data<galastrm_state>();
54   state->m_frame_counter ^= 1;
55   device->execute().set_input_line(5, HOLD_LINE);
53   m_frame_counter ^= 1;
54   device.execute().set_input_line(5, HOLD_LINE);
5655}
5756
5857static TIMER_CALLBACK( galastrm_interrupt6 )
r17996r17997
310309   /* basic machine hardware */
311310   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)   /* 16 MHz */
312311   MCFG_CPU_PROGRAM_MAP(galastrm_map)
313   MCFG_CPU_VBLANK_INT("screen", galastrm_interrupt) /* VBL */
312   MCFG_CPU_VBLANK_INT_DRIVER("screen", galastrm_state, galastrm_interrupt) /* VBL */
314313
315314   MCFG_EEPROM_ADD("eeprom", galastrm_eeprom_interface)
316315
trunk/src/mame/drivers/tetrisp2.c
r17996r17997
13291329   /* basic machine hardware */
13301330   MCFG_CPU_ADD("maincpu", M68000, 12000000)
13311331   MCFG_CPU_PROGRAM_MAP(tetrisp2_map)
1332   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1332   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq2_line_hold)
13331333
13341334   MCFG_NVRAM_ADD_0FILL("nvram")
13351335   MCFG_WATCHDOG_VBLANK_INIT(8)   /* guess */
r17996r17997
13611361   /* basic machine hardware */
13621362   MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz)
13631363   MCFG_CPU_PROGRAM_MAP(nndmseal_map)
1364   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1364   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq2_line_hold)
13651365
13661366   MCFG_NVRAM_ADD_0FILL("nvram")
13671367
r17996r17997
13911391   /* basic machine hardware */
13921392   MCFG_CPU_ADD("maincpu", M68000, 12000000)
13931393   MCFG_CPU_PROGRAM_MAP(rockn1_map)
1394   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1394   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq2_line_hold)
13951395
13961396   MCFG_NVRAM_ADD_0FILL("nvram")
13971397
r17996r17997
14221422   /* basic machine hardware */
14231423   MCFG_CPU_ADD("maincpu", M68000, 12000000)
14241424   MCFG_CPU_PROGRAM_MAP(rockn2_map)
1425   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1425   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq2_line_hold)
14261426
14271427   MCFG_NVRAM_ADD_0FILL("nvram")
14281428
r17996r17997
14531453   /* basic machine hardware */
14541454   MCFG_CPU_ADD("maincpu", M68000, 12000000)
14551455   MCFG_CPU_PROGRAM_MAP(rocknms_main_map)
1456   MCFG_CPU_VBLANK_INT("lscreen", irq2_line_hold)
1456   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", tetrisp2_state, irq2_line_hold)
14571457
14581458   MCFG_CPU_ADD("sub", M68000, 12000000)
14591459   MCFG_CPU_PROGRAM_MAP(rocknms_sub_map)
1460   MCFG_CPU_VBLANK_INT("lscreen", irq2_line_hold)
1460   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", tetrisp2_state, irq2_line_hold)
14611461
14621462   MCFG_NVRAM_ADD_0FILL("nvram")
14631463
r17996r17997
14951495static MACHINE_CONFIG_START( stepstag, stepstag_state )
14961496   MCFG_CPU_ADD("maincpu", M68000, 16000000 ) //??
14971497   MCFG_CPU_PROGRAM_MAP(stepstag_map)
1498   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold) // lev 4 triggered by system timer
1498   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq2_line_hold) // lev 4 triggered by system timer
14991499
15001500   MCFG_CPU_ADD("sub", M68000, 16000000 ) //??
15011501   MCFG_CPU_PROGRAM_MAP(stepstag_sub_map)
1502   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold) // lev 6 triggered by main CPU
1502   MCFG_CPU_VBLANK_INT_DRIVER("screen", tetrisp2_state, irq4_line_hold) // lev 6 triggered by main CPU
15031503
15041504   MCFG_NVRAM_ADD_0FILL("nvram")
15051505
trunk/src/mame/drivers/alpha68k.c
r17996r17997
19551955   /* basic machine hardware */
19561956   MCFG_CPU_ADD("maincpu", M68000, 6000000) /* 24MHz/4? */
19571957   MCFG_CPU_PROGRAM_MAP(kyros_map)
1958   MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
1959   MCFG_CPU_PERIODIC_INT(irq2_line_hold,60) // MCU irq
1958   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
1959   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60) // MCU irq
19601960
19611961   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
19621962   MCFG_CPU_PROGRAM_MAP(sstingry_sound_map)
19631963   MCFG_CPU_IO_MAP(kyros_sound_portmap)
1964   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
1965   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000)
1964   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold,  2*60)
1965   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, nmi_line_pulse,  4000)
19661966
19671967   MCFG_CPU_ADD("mcu", I8748, 9263750)      /* 9.263750 MHz oscillator, divided by 3*5 internally */
19681968//  MCFG_CPU_PROGRAM_MAP(i8748_map)
r17996r17997
20052005   /* basic machine hardware */
20062006   MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/4)   /* Verified on bootleg PCB */
20072007   MCFG_CPU_PROGRAM_MAP(kyros_map)
2008   MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
2009   MCFG_CPU_PERIODIC_INT(irq2_line_hold,60) // MCU irq
2008   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
2009   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60) // MCU irq
20102010
20112011   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/6)   /* Verified on bootleg PCB */
20122012   MCFG_CPU_PROGRAM_MAP(kyros_sound_map)
20132013   MCFG_CPU_IO_MAP(kyros_sound_portmap)
2014   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
2015   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000)
2014   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold,  2*60)
2015   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, nmi_line_pulse,  4000)
20162016
20172017   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,common)
20182018   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,common)
r17996r17997
20512051   /* basic machine hardware */
20522052   MCFG_CPU_ADD("maincpu", M68000, 8000000)
20532053   MCFG_CPU_PROGRAM_MAP(kyros_map)
2054   MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
2055   MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*16) // MCU irq
2054   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
2055   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*16) // MCU irq
20562056
20572057   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
20582058   MCFG_CPU_PROGRAM_MAP(jongbou_sound_map)
20592059   MCFG_CPU_IO_MAP(jongbou_sound_portmap)
2060   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 160*60)
2060   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold, 160*60)
20612061
20622062   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,common)
20632063   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,common)
r17996r17997
20882088   /* basic machine hardware */
20892089   MCFG_CPU_ADD("maincpu", M68000, 6000000) /* 24MHz/4? */
20902090   MCFG_CPU_PROGRAM_MAP(alpha68k_I_map)
2091   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* VBL */
2091   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)/* VBL */
20922092
20932093   MCFG_CPU_ADD("audiocpu", Z80, 4000000) // 4Mhz seems to yield the correct tone
20942094   MCFG_CPU_PROGRAM_MAP(alpha68k_I_s_map)
r17996r17997
21172117   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
21182118MACHINE_CONFIG_END
21192119
2120static INTERRUPT_GEN( alpha68k_sound_nmi )
2120INTERRUPT_GEN_MEMBER(alpha68k_state::alpha68k_sound_nmi)
21212121{
2122   alpha68k_state *state = device->machine().driver_data<alpha68k_state>();
21232122
2124   if(state->m_sound_nmi_mask)
2125      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
2123   if(m_sound_nmi_mask)
2124      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
21262125}
21272126
21282127static MACHINE_CONFIG_START( alpha68k_II, alpha68k_state )
r17996r17997
21302129   /* basic machine hardware */
21312130   MCFG_CPU_ADD("maincpu", M68000, 8000000) /* Correct */
21322131   MCFG_CPU_PROGRAM_MAP(alpha68k_II_map)
2133   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
2132   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
21342133
21352134   MCFG_CPU_ADD("audiocpu", Z80, 3579545*2) /* Unlikely but needed to stop nested NMI's */
21362135   MCFG_CPU_PROGRAM_MAP(sound_map)
21372136   MCFG_CPU_IO_MAP(sound_portmap)
2138   MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 7500)
2137   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 7500)
21392138
21402139   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_II)
21412140   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_II)
r17996r17997
21692168
21702169static MACHINE_CONFIG_DERIVED( btlfieldb, alpha68k_II )
21712170   MCFG_CPU_MODIFY("maincpu")
2172   MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
2173   MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*4) // MCU irq
2171   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
2172   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*4) // MCU irq
21742173MACHINE_CONFIG_END
21752174
21762175static MACHINE_CONFIG_START( alpha68k_II_gm, alpha68k_state )
r17996r17997
21782177   /* basic machine hardware */
21792178   MCFG_CPU_ADD("maincpu", M68000, 8000000)
21802179   MCFG_CPU_PROGRAM_MAP(alpha68k_II_map)
2181   MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
2182   MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*3) // MCU irq
2180   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
2181   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*3) // MCU irq
21832182
21842183   MCFG_CPU_ADD("audiocpu", Z80, 4000000*2) // TODO: fix this
21852184   MCFG_CPU_PROGRAM_MAP(sound_map)
21862185   MCFG_CPU_IO_MAP(sound_portmap)
2187   MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 7500)
2186   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 7500)
21882187
21892188   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_II)
21902189   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_II)
r17996r17997
22222221   /* basic machine hardware */
22232222   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
22242223   MCFG_CPU_PROGRAM_MAP(alpha68k_V_map)
2225   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
2224   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
22262225
22272226   MCFG_CPU_ADD("audiocpu", Z80, /*3579545*/3579545*2) /* Unlikely but needed to stop nested NMI's */
22282227   MCFG_CPU_PROGRAM_MAP(sound_map)
22292228   MCFG_CPU_IO_MAP(sound_portmap)
2230   MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 8500)
2229   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 8500)
22312230
22322231   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_V)
22332232   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_V)
r17996r17997
22642263   /* basic machine hardware */
22652264   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
22662265   MCFG_CPU_PROGRAM_MAP(alpha68k_V_map)
2267   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
2266   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
22682267
22692268   MCFG_CPU_ADD("audiocpu", Z80, /*3579545*/3579545*2) /* Unlikely but needed to stop nested NMI's */
22702269   MCFG_CPU_PROGRAM_MAP(sound_map)
22712270   MCFG_CPU_IO_MAP(sound_portmap)
2272   MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 8500)
2271   MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 8500)
22732272
22742273   MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_V)
22752274   MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_V)
r17996r17997
23062305   /* basic machine hardware */
23072306   MCFG_CPU_ADD("maincpu", M68000, 9000000) /* Confirmed 18 MHz/2 */
23082307   MCFG_CPU_PROGRAM_MAP(tnextspc_map)
2309   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* VBL */
2308   MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)/* VBL */
23102309
23112310   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
23122311   MCFG_CPU_PROGRAM_MAP(tnextspc_sound_map)
trunk/src/mame/drivers/namcos22.c
r17996r17997
2181218100008bf0: sys[0x00] := 0x04 // vblank
2182218200008bf8: sys[0x08] := 0xff // ?
21832183*/
2184static INTERRUPT_GEN( namcos22s_interrupt )
2184INTERRUPT_GEN_MEMBER(namcos22_state::namcos22s_interrupt)
21852185{
2186   namcos22_state *state = device->machine().driver_data<namcos22_state>();
21872186
2188   if (nthbyte(state->m_system_controller, 0x00) & 7)
2187   if (nthbyte(m_system_controller, 0x00) & 7)
21892188   {
21902189      // vblank irq
2191      state->m_irq_state |= 1;
2192      device->execute().set_input_line(nthbyte(state->m_system_controller, 0x00) & 7, ASSERT_LINE);
2190      m_irq_state |= 1;
2191      device.execute().set_input_line(nthbyte(m_system_controller, 0x00) & 7, ASSERT_LINE);
21932192   }
21942193}
21952194
r17996r17997
23432342
23442343    move.b  #$34, $40000004.l
23452344*/
2346static INTERRUPT_GEN( namcos22_interrupt )
2345INTERRUPT_GEN_MEMBER(namcos22_state::namcos22_interrupt)
23472346{
2348   namcos22_state *state = device->machine().driver_data<namcos22_state>();
23492347
2350   switch( state->m_gametype )
2348   switch( m_gametype )
23512349   {
23522350      case NAMCOS22_RIDGE_RACER:
23532351      case NAMCOS22_RIDGE_RACER2:
23542352      case NAMCOS22_RAVE_RACER:
23552353      case NAMCOS22_ACE_DRIVER:
23562354      case NAMCOS22_VICTORY_LAP:
2357         HandleDrivingIO(device->machine());
2355         HandleDrivingIO(machine());
23582356         break;
23592357
23602358      case NAMCOS22_CYBER_COMMANDO:
2361         HandleCyberCommandoIO(device->machine());
2359         HandleCyberCommandoIO(machine());
23622360         break;
23632361
23642362      default:
23652363         break;
23662364   }
23672365
2368   if (nthbyte(state->m_system_controller, 0x04) & 7)
2366   if (nthbyte(m_system_controller, 0x04) & 7)
23692367   {
23702368      // vblank irq
2371      state->m_irq_state |= 1;
2372      device->execute().set_input_line(nthbyte(state->m_system_controller, 0x04) & 7, ASSERT_LINE);
2369      m_irq_state |= 1;
2370      device.execute().set_input_line(nthbyte(m_system_controller, 0x04) & 7, ASSERT_LINE);
23732371   }
23742372}
23752373
r17996r17997
29452943static MACHINE_CONFIG_START( namcos22s, namcos22_state )
29462944   MCFG_CPU_ADD("maincpu", M68EC020,SS22_MASTER_CLOCK/2)
29472945   MCFG_CPU_PROGRAM_MAP(namcos22s_am)
2948   MCFG_CPU_VBLANK_INT("screen", namcos22s_interrupt)
2946   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos22_state, namcos22s_interrupt)
29492947
29502948   MCFG_CPU_ADD("master", TMS32025,SS22_MASTER_CLOCK)
29512949   MCFG_CPU_PROGRAM_MAP(master_dsp_program)
r17996r17997
31963194static MACHINE_CONFIG_START( namcos22, namcos22_state )
31973195   MCFG_CPU_ADD("maincpu", M68020,SS22_MASTER_CLOCK/2) /* 25 MHz? */
31983196   MCFG_CPU_PROGRAM_MAP(namcos22_am)
3199   MCFG_CPU_VBLANK_INT("screen", namcos22_interrupt)
3197   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos22_state, namcos22_interrupt)
32003198
32013199   MCFG_CPU_ADD("master", TMS32025,SS22_MASTER_CLOCK) /* ? */
32023200   MCFG_CPU_PROGRAM_MAP(master_dsp_program)
trunk/src/mame/drivers/flyball.c
r17996r17997
415415   /* basic machine hardware */
416416   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/16)
417417   MCFG_CPU_PROGRAM_MAP(flyball_map)
418   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
418   MCFG_CPU_VBLANK_INT_DRIVER("screen", flyball_state, nmi_line_pulse)
419419
420420
421421   /* video hardware */
trunk/src/mame/drivers/galaxold.c
r17996r17997
23142314   MCFG_CPU_MODIFY("maincpu")
23152315   MCFG_CPU_PROGRAM_MAP(ozon1_map)
23162316   MCFG_CPU_IO_MAP(ozon1_io_map)
2317   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2317   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, nmi_line_pulse)
23182318
23192319   MCFG_MACHINE_RESET(0)
23202320
r17996r17997
23322332   MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/6)
23332333   MCFG_CPU_PROGRAM_MAP(drivfrcg)
23342334   MCFG_CPU_IO_MAP(drivfrcg_io)
2335   MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
2335   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
23362336
23372337
23382338   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
23842384   MCFG_FRAGMENT_ADD(galaxian_audio)
23852385MACHINE_CONFIG_END
23862386
2387static INTERRUPT_GEN( vblank_irq )
2387INTERRUPT_GEN_MEMBER(galaxold_state::vblank_irq)
23882388{
2389   galaxold_state *state = device->machine().driver_data<galaxold_state>();
23902389
2391   if(state->m_nmi_mask)
2392      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
2390   if(m_nmi_mask)
2391      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
23932392}
23942393
23952394static MACHINE_CONFIG_DERIVED( harem, galaxold_base )
r17996r17997
23972396   /* basic machine hardware */
23982397   MCFG_CPU_MODIFY("maincpu")
23992398   MCFG_CPU_PROGRAM_MAP(harem_cpu1)
2400   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
2399   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, vblank_irq)
24012400
24022401   MCFG_CPU_ADD("audiocpu", Z80, 1620000) //?
24032402   MCFG_CPU_PROGRAM_MAP(harem_cpu2)
r17996r17997
24332432   MCFG_CPU_ADD("maincpu", S2650, PIXEL_CLOCK/2)
24342433   MCFG_CPU_PROGRAM_MAP(racknrol)
24352434   MCFG_CPU_IO_MAP(racknrol_io)
2436   MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
2435   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
24372436
24382437   MCFG_GFXDECODE(galaxian)
24392438   MCFG_PALETTE_LENGTH(32)
r17996r17997
24912490   MCFG_CPU_ADD("maincpu", S2650, PIXEL_CLOCK/2)
24922491   MCFG_CPU_PROGRAM_MAP(racknrol)
24932492   MCFG_CPU_IO_MAP(hexpoola_io)
2494   MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
2493   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
24952494
24962495   MCFG_GFXDECODE(galaxian)
24972496   MCFG_PALETTE_LENGTH(32)
trunk/src/mame/drivers/unkhorse.c
r17996r17997
4040   DECLARE_WRITE_LINE_MEMBER(horse_timer_out);
4141   virtual void palette_init();
4242   UINT32 screen_update_horse(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
43   INTERRUPT_GEN_MEMBER(horse_interrupt);
4344};
4445
4546
r17996r17997
191192
192193***************************************************************************/
193194
194static INTERRUPT_GEN( horse_interrupt )
195INTERRUPT_GEN_MEMBER(horse_state::horse_interrupt)
195196{
196   device->execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
197   device->execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
197   device.execute().set_input_line(I8085_RST75_LINE, ASSERT_LINE);
198   device.execute().set_input_line(I8085_RST75_LINE, CLEAR_LINE);
198199}
199200
200201static MACHINE_CONFIG_START( horse, horse_state )
r17996r17997
202203   MCFG_CPU_ADD("maincpu", I8085A, XTAL_12MHz / 2)
203204   MCFG_CPU_PROGRAM_MAP(horse_map)
204205   MCFG_CPU_IO_MAP(horse_io_map)
205   MCFG_CPU_VBLANK_INT("screen", horse_interrupt)
206   MCFG_CPU_VBLANK_INT_DRIVER("screen", horse_state, horse_interrupt)
206207
207208   MCFG_I8155_ADD("i8155", XTAL_12MHz / 2, i8155_intf)
208209
trunk/src/mame/drivers/pturn.c
r17996r17997
118118   virtual void machine_reset();
119119   virtual void video_start();
120120   UINT32 screen_update_pturn(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
121   INTERRUPT_GEN_MEMBER(pturn_sub_intgen);
122   INTERRUPT_GEN_MEMBER(pturn_main_intgen);
121123};
122124
123125
r17996r17997
459461   PORT_DIPSETTING(    0x80, DEF_STR( Japanese ) )
460462INPUT_PORTS_END
461463
462static INTERRUPT_GEN( pturn_sub_intgen )
464INTERRUPT_GEN_MEMBER(pturn_state::pturn_sub_intgen)
463465{
464   pturn_state *state = device->machine().driver_data<pturn_state>();
465   if(state->m_nmi_sub)
466   if(m_nmi_sub)
466467   {
467      device->execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
468      device.execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
468469   }
469470}
470471
471static INTERRUPT_GEN( pturn_main_intgen )
472INTERRUPT_GEN_MEMBER(pturn_state::pturn_main_intgen)
472473{
473   pturn_state *state = device->machine().driver_data<pturn_state>();
474   if (state->m_nmi_main)
474   if (m_nmi_main)
475475   {
476      device->execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
476      device.execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
477477   }
478478}
479479
r17996r17997
486486static MACHINE_CONFIG_START( pturn, pturn_state )
487487   MCFG_CPU_ADD("maincpu", Z80, 12000000/3)
488488   MCFG_CPU_PROGRAM_MAP(main_map)
489   MCFG_CPU_VBLANK_INT("screen", pturn_main_intgen)
489   MCFG_CPU_VBLANK_INT_DRIVER("screen", pturn_state, pturn_main_intgen)
490490
491491   MCFG_CPU_ADD("audiocpu", Z80, 12000000/3)
492492   MCFG_CPU_PROGRAM_MAP(sub_map)
493   MCFG_CPU_PERIODIC_INT(pturn_sub_intgen,3*60)
493   MCFG_CPU_PERIODIC_INT_DRIVER(pturn_state, pturn_sub_intgen, 3*60)
494494
495495
496496   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gumbo.c
r17996r17997
231231
232232   MCFG_CPU_ADD("maincpu", M68000, 14318180 /2)    // or 10mhz? ?
233233   MCFG_CPU_PROGRAM_MAP(gumbo_map)
234   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) // all the same
234   MCFG_CPU_VBLANK_INT_DRIVER("screen", gumbo_state, irq1_line_hold) // all the same
235235
236236   MCFG_GFXDECODE(gumbo)
237237
trunk/src/mame/drivers/dec0.c
r17996r17997
14031403   /* basic machine hardware */
14041404   MCFG_CPU_ADD("maincpu", M68000, 10000000)
14051405   MCFG_CPU_PROGRAM_MAP(automat_map)
1406   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
1406   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
14071407
14081408   MCFG_CPU_ADD("audiocpu", Z80, 3000000)// ?
14091409   MCFG_CPU_PROGRAM_MAP(automat_s_map)
r17996r17997
14561456   /* basic machine hardware */
14571457   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
14581458   MCFG_CPU_PROGRAM_MAP(secretab_map)
1459   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
1459   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
14601460
14611461   MCFG_CPU_ADD("audiocpu", Z80, 3000000)// ?
14621462   MCFG_CPU_PROGRAM_MAP(automat_s_map)
r17996r17997
15101510   /* basic machine hardware */
15111511   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
15121512   MCFG_CPU_PROGRAM_MAP(dec0_map)
1513   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
1513   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
15141514
15151515   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
15161516   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
15331533   /* basic machine hardware */
15341534   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
15351535   MCFG_CPU_PROGRAM_MAP(dec0_map)
1536   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
1536   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
15371537
15381538   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
15391539   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
15531553   /* basic machine hardware */
15541554   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
15551555   MCFG_CPU_PROGRAM_MAP(dec0_map)
1556   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
1556   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
15571557
15581558   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
15591559   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
15731573   /* basic machine hardware */
15741574   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
15751575   MCFG_CPU_PROGRAM_MAP(dec0_map)
1576   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
1576   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
15771577
15781578   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
15791579   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
15981598   /* basic machine hardware */
15991599   MCFG_CPU_ADD("maincpu", M68000, 10000000)
16001600   MCFG_CPU_PROGRAM_MAP(dec0_map)
1601   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
1601   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
16021602
16031603   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
16041604   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
16181618   /* basic machine hardware */
16191619   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
16201620   MCFG_CPU_PROGRAM_MAP(dec0_map)
1621   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
1621   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
16221622
16231623   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
16241624   MCFG_CPU_PROGRAM_MAP(dec0_s_map)
r17996r17997
16491649   /* basic machine hardware */
16501650   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
16511651   MCFG_CPU_PROGRAM_MAP(slyspy_map)
1652   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) /* VBL, apparently it auto-acks */
1652   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold) /* VBL, apparently it auto-acks */
16531653
16541654   MCFG_CPU_ADD("audiocpu", H6280, XTAL_12MHz/2/3) /* verified on pcb (6Mhz is XIN on pin 10 of H6280, verified on pcb */
16551655   MCFG_CPU_PROGRAM_MAP(slyspy_s_map)
r17996r17997
16761676   /* basic machine hardware */
16771677   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
16781678   MCFG_CPU_PROGRAM_MAP(midres_map)
1679   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
1679   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
16801680
16811681   MCFG_CPU_ADD("audiocpu", H6280, XTAL_24MHz/4/3) /* verified on pcb (6Mhz is XIN on pin 10 of H6280, verified on pcb */
16821682   MCFG_CPU_PROGRAM_MAP(midres_s_map)
trunk/src/mame/drivers/jubilee.c
r17996r17997
105105   virtual void video_start();
106106   virtual void palette_init();
107107   UINT32 screen_update_jubileep(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
108   INTERRUPT_GEN_MEMBER(jubileep_interrupt);
108109};
109110
110111
r17996r17997
152153*  Read / Write Handlers  *
153154**************************/
154155
155static INTERRUPT_GEN( jubileep_interrupt )
156INTERRUPT_GEN_MEMBER(jubilee_state::jubileep_interrupt)
156157{
157158   /* doesn't seems to work properly. need to set level1 interrupts */
158   device->execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
159   device.execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
159160}
160161
161162
r17996r17997
417418   MCFG_CPU_ADD("maincpu", TMS9980L, MASTER_CLOCK/2)   /* guess */
418419   MCFG_CPU_PROGRAM_MAP(jubileep_map)
419420   MCFG_CPU_IO_MAP(jubileep_cru_map)
420   MCFG_CPU_VBLANK_INT("screen", jubileep_interrupt)
421   MCFG_CPU_VBLANK_INT_DRIVER("screen", jubilee_state, jubileep_interrupt)
421422
422423   /* video hardware */
423424   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/cop01.c
r17996r17997
454454   MCFG_CPU_ADD("maincpu", Z80, MAINCPU_CLOCK/2)   /* unknown clock / divider */
455455   MCFG_CPU_PROGRAM_MAP(cop01_map)
456456   MCFG_CPU_IO_MAP(io_map)
457   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
457   MCFG_CPU_VBLANK_INT_DRIVER("screen", cop01_state, irq0_line_assert)
458458
459459   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3MHz)   /* unknown clock / divider, hand-tuned to match audio reference */
460460   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
492492   MCFG_CPU_ADD("maincpu", Z80, MAINCPU_CLOCK/2)   /* unknown divider */
493493   MCFG_CPU_PROGRAM_MAP(cop01_map)
494494   MCFG_CPU_IO_MAP(mightguy_io_map)
495   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
495   MCFG_CPU_VBLANK_INT_DRIVER("screen", cop01_state, irq0_line_assert)
496496
497497   MCFG_CPU_ADD("audiocpu", Z80, AUDIOCPU_CLOCK/2)   /* unknown divider */
498498   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/hanaawas.c
r17996r17997
200200   MCFG_CPU_ADD("maincpu", Z80,18432000/6)   /* 3.072 MHz ??? */
201201   MCFG_CPU_PROGRAM_MAP(hanaawas_map)
202202   MCFG_CPU_IO_MAP(io_map)
203   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
203   MCFG_CPU_VBLANK_INT_DRIVER("screen", hanaawas_state, irq0_line_hold)
204204
205205
206206   /* video hardware */
trunk/src/mame/drivers/goldngam.c
r17996r17997
560560   /* basic machine hardware */
561561   MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK)
562562   MCFG_CPU_PROGRAM_MAP(swisspkr_map)
563   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
563   MCFG_CPU_VBLANK_INT_DRIVER("screen", goldngam_state, irq2_line_hold)
564564
565565   /* video hardware */
566566   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/circusc.c
r17996r17997
345345
346346DISCRETE_SOUND_END
347347
348static INTERRUPT_GEN( vblank_irq )
348INTERRUPT_GEN_MEMBER(circusc_state::vblank_irq)
349349{
350   circusc_state *state = device->machine().driver_data<circusc_state>();
351350
352   if(state->m_irq_mask)
353      device->execute().set_input_line(0, HOLD_LINE);
351   if(m_irq_mask)
352      device.execute().set_input_line(0, HOLD_LINE);
354353}
355354
356355static MACHINE_CONFIG_START( circusc, circusc_state )
r17996r17997
358357   /* basic machine hardware */
359358   MCFG_CPU_ADD("maincpu", M6809, 2048000)        /* 2 MHz? */
360359   MCFG_CPU_PROGRAM_MAP(circusc_map)
361   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
360   MCFG_CPU_VBLANK_INT_DRIVER("screen", circusc_state, vblank_irq)
362361   MCFG_WATCHDOG_VBLANK_INIT(8)
363362
364363   MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz/4)
trunk/src/mame/drivers/laserbas.c
r17996r17997
308308   MCFG_CPU_ADD("maincpu", Z80, 4000000)
309309   MCFG_CPU_PROGRAM_MAP(laserbas_memory)
310310   MCFG_CPU_IO_MAP(laserbas_io)
311   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
311   MCFG_CPU_VBLANK_INT_DRIVER("screen", laserbas_state, irq0_line_hold)
312312
313313   MCFG_PIT8253_ADD("pit0", laserbas_pit8253_intf_0)
314314   MCFG_PIT8253_ADD("pit1", laserbas_pit8253_intf_1)
trunk/src/mame/drivers/mikie.c
r17996r17997
264264   m_last_irq = 0;
265265}
266266
267static INTERRUPT_GEN( vblank_irq )
267INTERRUPT_GEN_MEMBER(mikie_state::vblank_irq)
268268{
269   mikie_state *state = device->machine().driver_data<mikie_state>();
270269
271   if(state->m_irq_mask)
272      device->execute().set_input_line(0, HOLD_LINE);
270   if(m_irq_mask)
271      device.execute().set_input_line(0, HOLD_LINE);
273272}
274273
275274static MACHINE_CONFIG_START( mikie, mikie_state )
r17996r17997
277276   /* basic machine hardware */
278277   MCFG_CPU_ADD("maincpu", M6809, OSC/12)
279278   MCFG_CPU_PROGRAM_MAP(mikie_map)
280   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
279   MCFG_CPU_VBLANK_INT_DRIVER("screen", mikie_state, vblank_irq)
281280
282281   MCFG_CPU_ADD("audiocpu", Z80, CLK)
283282   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/kingpin.c
r17996r17997
178178
179179   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)
180180   MCFG_CPU_PROGRAM_MAP(kingpin_sound_map)
181   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 1000) // unknown freq
181   MCFG_CPU_PERIODIC_INT_DRIVER(kingpin_state, irq0_line_hold, 1000) // unknown freq
182182
183183   /* video hardware */
184184   MCFG_TMS9928A_ADD( "tms9928a", TMS9928A, kingpin_tms9928a_interface )
trunk/src/mame/drivers/usgames.c
r17996r17997
234234   /* basic machine hardware */
235235   MCFG_CPU_ADD("maincpu", M6809, 2000000) /* ?? */
236236   MCFG_CPU_PROGRAM_MAP(usgames_map)
237   MCFG_CPU_PERIODIC_INT(irq0_line_hold,5*60) /* ?? */
237   MCFG_CPU_PERIODIC_INT_DRIVER(usgames_state, irq0_line_hold, 5*60) /* ?? */
238238
239239   MCFG_NVRAM_ADD_0FILL("nvram")
240240
trunk/src/mame/drivers/opwolf.c
r17996r17997
735735   /* basic machine hardware */
736736   MCFG_CPU_ADD("maincpu", M68000, CPU_CLOCK )   /* 8 MHz */
737737   MCFG_CPU_PROGRAM_MAP(opwolf_map)
738   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
738   MCFG_CPU_VBLANK_INT_DRIVER("screen", opwolf_state, irq5_line_hold)
739739
740740   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK )   /* 4 MHz */
741741   MCFG_CPU_PROGRAM_MAP(opwolf_sound_z80_map)
r17996r17997
785785   /* basic machine hardware */
786786   MCFG_CPU_ADD("maincpu", M68000, CPU_CLOCK )   /* 8 MHz ??? */
787787   MCFG_CPU_PROGRAM_MAP(opwolfb_map)
788   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
788   MCFG_CPU_VBLANK_INT_DRIVER("screen", opwolf_state, irq5_line_hold)
789789
790790   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK )   /* 4 MHz ??? */
791791   MCFG_CPU_PROGRAM_MAP(opwolf_sound_z80_map)
792792
793793   MCFG_CPU_ADD("sub", Z80, SOUND_CPU_CLOCK )   /* 4 MHz ??? */
794794   MCFG_CPU_PROGRAM_MAP(opwolfb_sub_z80_map)
795   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
795   MCFG_CPU_VBLANK_INT_DRIVER("screen", opwolf_state, irq0_line_hold)
796796
797797   MCFG_QUANTUM_TIME(attotime::from_hz(600))   /* 10 CPU slices per frame - enough for the sound CPU to read all commands */
798798
trunk/src/mame/drivers/suna16.c
r17996r17997
828828   /* basic machine hardware */
829829   MCFG_CPU_ADD("maincpu", M68000, 8000000)
830830   MCFG_CPU_PROGRAM_MAP(uballoon_map)
831   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
831   MCFG_CPU_VBLANK_INT_DRIVER("screen", suna16_state, irq1_line_hold)
832832
833833   MCFG_CPU_ADD("audiocpu", Z80, 3579545)   /* ? */
834834   MCFG_CPU_PROGRAM_MAP(uballoon_sound_map)
r17996r17997
878878   /* basic machine hardware */
879879   MCFG_CPU_ADD("maincpu", M68000, 24000000/4)
880880   MCFG_CPU_PROGRAM_MAP(sunaq_map)
881   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
881   MCFG_CPU_VBLANK_INT_DRIVER("screen", suna16_state, irq1_line_hold)
882882
883883   MCFG_CPU_ADD("audiocpu", Z80, 14318000/4)
884884   MCFG_CPU_PROGRAM_MAP(sunaq_sound_map)
trunk/src/mame/drivers/firebeat.c
r17996r17997
185185   DECLARE_VIDEO_START(firebeat);
186186   UINT32 screen_update_firebeat_0(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
187187   UINT32 screen_update_firebeat_1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
188   INTERRUPT_GEN_MEMBER(firebeat_interrupt);
188189};
189190
190191
r17996r17997
19361937
19371938INPUT_PORTS_END
19381939
1939static INTERRUPT_GEN(firebeat_interrupt)
1940INTERRUPT_GEN_MEMBER(firebeat_state::firebeat_interrupt)
19401941{
19411942   // IRQs
19421943   // IRQ 0: VBlank
r17996r17997
19441945   // IRQ 2: Main board UART
19451946   // IRQ 4: ATAPI
19461947
1947   device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
1948   device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
19481949}
19491950
19501951MACHINE_RESET_MEMBER(firebeat_state,firebeat)
r17996r17997
19731974   /* basic machine hardware */
19741975   MCFG_CPU_ADD("maincpu", PPC403GCX, 66000000)
19751976   MCFG_CPU_PROGRAM_MAP(firebeat_map)
1976   MCFG_CPU_VBLANK_INT("screen", firebeat_interrupt)
1977   MCFG_CPU_VBLANK_INT_DRIVER("screen", firebeat_state, firebeat_interrupt)
19771978
19781979   MCFG_MACHINE_START_OVERRIDE(firebeat_state,firebeat)
19791980   MCFG_MACHINE_RESET_OVERRIDE(firebeat_state,firebeat)
r17996r17997
20192020   /* basic machine hardware */
20202021   MCFG_CPU_ADD("maincpu", PPC403GCX, 66000000)
20212022   MCFG_CPU_PROGRAM_MAP(firebeat_map)
2022   MCFG_CPU_VBLANK_INT("lscreen", firebeat_interrupt)
2023   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", firebeat_state, firebeat_interrupt)
20232024
20242025   MCFG_MACHINE_START_OVERRIDE(firebeat_state,firebeat)
20252026   MCFG_MACHINE_RESET_OVERRIDE(firebeat_state,firebeat)
trunk/src/mame/drivers/clayshoo.c
r17996r17997
331331   MCFG_CPU_ADD("maincpu", Z80,5068000/4)      /* 5.068/4 Mhz (divider is a guess) */
332332   MCFG_CPU_PROGRAM_MAP(main_map)
333333   MCFG_CPU_IO_MAP(main_io_map)
334   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
334   MCFG_CPU_VBLANK_INT_DRIVER("screen", clayshoo_state, irq0_line_hold)
335335
336336
337337   /* video hardware */
trunk/src/mame/drivers/bagman.c
r17996r17997
462462   DEVCB_NULL                              /* rom clock - Only used to drive the data lines */
463463};
464464
465static INTERRUPT_GEN( vblank_irq )
465INTERRUPT_GEN_MEMBER(bagman_state::vblank_irq)
466466{
467   bagman_state *state = device->machine().driver_data<bagman_state>();
468467
469   if(state->m_irq_mask)
470      device->execute().set_input_line(0, HOLD_LINE);
468   if(m_irq_mask)
469      device.execute().set_input_line(0, HOLD_LINE);
471470}
472471
473472
r17996r17997
477476   MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
478477   MCFG_CPU_PROGRAM_MAP(main_map)
479478   MCFG_CPU_IO_MAP(main_portmap)
480   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
479   MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
481480
482481   MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
483482
r17996r17997
513512   MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
514513   MCFG_CPU_PROGRAM_MAP(pickin_map)
515514   MCFG_CPU_IO_MAP(main_portmap)
516   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
515   MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
517516
518517   MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
519518
r17996r17997
565564   MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
566565   MCFG_CPU_PROGRAM_MAP(pickin_map)
567566   MCFG_CPU_IO_MAP(main_portmap)
568   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
567   MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
569568
570569   MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
571570
trunk/src/mame/drivers/bigevglf.c
r17996r17997
494494   MCFG_CPU_ADD("maincpu", Z80,10000000/2)      /* 5 MHz ? */
495495   MCFG_CPU_PROGRAM_MAP(main_map)
496496   MCFG_CPU_IO_MAP(bigevglf_portmap)
497   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* vblank */
497   MCFG_CPU_VBLANK_INT_DRIVER("screen", bigevglf_state, irq0_line_hold)   /* vblank */
498498
499499   MCFG_CPU_ADD("sub", Z80,10000000/2)      /* 5 MHz ? */
500500   MCFG_CPU_PROGRAM_MAP(sub_map)
501501   MCFG_CPU_IO_MAP(bigevglf_sub_portmap)
502   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* vblank */
502   MCFG_CPU_VBLANK_INT_DRIVER("screen", bigevglf_state, irq0_line_hold)   /* vblank */
503503
504504   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)   /* 4 MHz ? */
505505   MCFG_CPU_PROGRAM_MAP(sound_map)
506   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* IRQ generated by ???;
506   MCFG_CPU_PERIODIC_INT_DRIVER(bigevglf_state, irq0_line_hold, 2*60)   /* IRQ generated by ???;
507507        2 irqs/frame give good music tempo but also SOUND ERROR in test mode,
508508        4 irqs/frame give SOUND OK in test mode but music seems to be running too fast */
509509
trunk/src/mame/drivers/inufuku.c
r17996r17997
348348   /* basic machine hardware */
349349   MCFG_CPU_ADD("maincpu", M68000, 32000000/2)   /* 16.00 MHz */
350350   MCFG_CPU_PROGRAM_MAP(inufuku_map)
351   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
351   MCFG_CPU_VBLANK_INT_DRIVER("screen", inufuku_state, irq1_line_hold)
352352
353353   MCFG_CPU_ADD("audiocpu", Z80, 32000000/4)      /* 8.00 MHz */
354354   MCFG_CPU_PROGRAM_MAP(inufuku_sound_map)
trunk/src/mame/drivers/tattack.c
r17996r17997
201201   /* basic machine hardware */
202202   MCFG_CPU_ADD("maincpu", Z80, 8000000 / 2)   /* 4 MHz ? */
203203   MCFG_CPU_PROGRAM_MAP(mem)
204   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
204   MCFG_CPU_VBLANK_INT_DRIVER("screen", tattack_state, irq0_line_hold)
205205
206206   /* video hardware */
207207   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/cbuster.c
r17996r17997
326326   /* basic machine hardware */
327327   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* Custom chip 59 */
328328   MCFG_CPU_PROGRAM_MAP(twocrude_map)
329   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)/* VBL */
329   MCFG_CPU_VBLANK_INT_DRIVER("screen", cbuster_state, irq4_line_hold)/* VBL */
330330
331331   MCFG_CPU_ADD("audiocpu", H6280,32220000/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
332332   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/dunhuang.c
r17996r17997
819819   MCFG_CPU_ADD("maincpu", Z80,12000000/2)
820820   MCFG_CPU_PROGRAM_MAP(dunhuang_map)
821821   MCFG_CPU_IO_MAP(dunhuang_io_map)
822   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
822   MCFG_CPU_VBLANK_INT_DRIVER("screen", dunhuang_state, irq0_line_hold)
823823
824824
825825   MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(5))
trunk/src/mame/drivers/ojankohs.c
r17996r17997
857857   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 MHz ? */
858858   MCFG_CPU_PROGRAM_MAP(ojankohs_map)
859859   MCFG_CPU_IO_MAP(ojankohs_io_map)
860   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
860   MCFG_CPU_VBLANK_INT_DRIVER("screen", ojankohs_state, irq0_line_hold)
861861
862862   MCFG_MACHINE_START_OVERRIDE(ojankohs_state,ojankohs)
863863   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
893893   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 MHz ? */
894894   MCFG_CPU_PROGRAM_MAP(ojankoy_map)
895895   MCFG_CPU_IO_MAP(ojankoy_io_map)
896   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
896   MCFG_CPU_VBLANK_INT_DRIVER("screen", ojankohs_state, irq0_line_hold)
897897
898898   MCFG_MACHINE_START_OVERRIDE(ojankohs_state,ojankoy)
899899   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
930930   MCFG_CPU_ADD("maincpu", Z80,12000000/2)      /* 6.00 MHz ? */
931931   MCFG_CPU_PROGRAM_MAP(ojankoy_map)
932932   MCFG_CPU_IO_MAP(ccasino_io_map)
933   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
933   MCFG_CPU_VBLANK_INT_DRIVER("screen", ojankohs_state, irq0_line_hold)
934934
935935   MCFG_MACHINE_START_OVERRIDE(ojankohs_state,ojankohs)
936936   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
966966   MCFG_CPU_ADD("maincpu", Z80,8000000/2)         /* 4.00 MHz */
967967   MCFG_CPU_PROGRAM_MAP(ojankoc_map)
968968   MCFG_CPU_IO_MAP(ojankoc_io_map)
969   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
969   MCFG_CPU_VBLANK_INT_DRIVER("screen", ojankohs_state, irq0_line_hold)
970970
971971   MCFG_MACHINE_START_OVERRIDE(ojankohs_state,ojankoc)
972972   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/kncljoe.c
r17996r17997
257257   DEVCB_DRIVER_MEMBER(kncljoe_state,unused_w)
258258};
259259
260static INTERRUPT_GEN (sound_nmi)
260INTERRUPT_GEN_MEMBER(kncljoe_state::sound_nmi)
261261{
262   device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
262   device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
263263}
264264
265265void kncljoe_state::machine_start()
r17996r17997
289289   /* basic machine hardware */
290290   MCFG_CPU_ADD("maincpu", Z80, XTAL_6MHz)  /* verified on pcb */
291291   MCFG_CPU_PROGRAM_MAP(main_map)
292   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
292   MCFG_CPU_VBLANK_INT_DRIVER("screen", kncljoe_state, irq0_line_hold)
293293
294294   MCFG_CPU_ADD("soundcpu", M6803, XTAL_3_579545MHz) /* verified on pcb */
295295   MCFG_CPU_PROGRAM_MAP(sound_map)
296296   MCFG_CPU_IO_MAP(sound_portmap)
297   MCFG_CPU_PERIODIC_INT(sound_nmi, (double)3970) //measured 3.970 kHz
297   MCFG_CPU_PERIODIC_INT_DRIVER(kncljoe_state, sound_nmi, (double)3970) //measured 3.970 kHz
298298
299299
300300   /* video hardware */
trunk/src/mame/drivers/deco_ld.c
r17996r17997
147147   DECLARE_INPUT_CHANGED_MEMBER(coin_inserted);
148148   virtual void machine_start();
149149   UINT32 screen_update_rblaster(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
150   INTERRUPT_GEN_MEMBER(sound_interrupt);
150151};
151152
152153static void draw_sprites(running_machine &machine, bitmap_rgb32 &bitmap, const rectangle &cliprect, UINT8 *spriteram, UINT16 tile_bank )
r17996r17997
295296}
296297#endif
297298
298static INTERRUPT_GEN ( sound_interrupt )
299INTERRUPT_GEN_MEMBER(deco_ld_state::sound_interrupt)
299300{
300   deco_ld_state *state = device->machine().driver_data<deco_ld_state>();
301   if (!state->m_nmimask) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
301   if (!m_nmimask) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
302302}
303303
304304
r17996r17997
459459   /* basic machine hardware */
460460   MCFG_CPU_ADD("maincpu",M6502,8000000/2)
461461   MCFG_CPU_PROGRAM_MAP(rblaster_map)
462   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
462   MCFG_CPU_VBLANK_INT_DRIVER("screen", deco_ld_state, irq0_line_hold)
463463
464464   MCFG_CPU_ADD("audiocpu",M6502,8000000/2)
465465   MCFG_CPU_PROGRAM_MAP(rblaster_sound_map)
466   MCFG_CPU_PERIODIC_INT(sound_interrupt, 640)
466   MCFG_CPU_PERIODIC_INT_DRIVER(deco_ld_state, sound_interrupt, 640)
467467
468468//  MCFG_QUANTUM_TIME(attotime::from_hz(6000))
469469
trunk/src/mame/drivers/cvs.c
r17996r17997
226226 *
227227 *************************************/
228228
229static INTERRUPT_GEN( cvs_main_cpu_interrupt )
229INTERRUPT_GEN_MEMBER(cvs_state::cvs_main_cpu_interrupt)
230230{
231   device->execute().set_input_line_vector(0, 0x03);
232   generic_pulse_irq_line(device, 0, 1);
231   device.execute().set_input_line_vector(0, 0x03);
232   generic_pulse_irq_line(device.execute(), 0, 1);
233233
234   cvs_scroll_stars(device->machine());
234   cvs_scroll_stars(machine());
235235}
236236
237237
r17996r17997
10421042   MCFG_CPU_ADD("maincpu", S2650, 894886.25)
10431043   MCFG_CPU_PROGRAM_MAP(cvs_main_cpu_map)
10441044   MCFG_CPU_IO_MAP(cvs_main_cpu_io_map)
1045   MCFG_CPU_VBLANK_INT("screen", cvs_main_cpu_interrupt)
1045   MCFG_CPU_VBLANK_INT_DRIVER("screen", cvs_state, cvs_main_cpu_interrupt)
10461046
10471047   MCFG_CPU_ADD("audiocpu", S2650, 894886.25)
10481048   MCFG_CPU_PROGRAM_MAP(cvs_dac_cpu_map)
trunk/src/mame/drivers/turbo.c
r17996r17997
930930   /* basic machine hardware */
931931   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
932932   MCFG_CPU_PROGRAM_MAP(turbo_map)
933   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
933   MCFG_CPU_VBLANK_INT_DRIVER("screen", turbo_state, irq0_line_hold)
934934
935935   MCFG_I8255_ADD( "i8255_0", turbo_8255_intf_0 )
936936   MCFG_I8255_ADD( "i8255_1", turbo_8255_intf_1 )
r17996r17997
961961   /* basic machine hardware */
962962   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
963963   MCFG_CPU_PROGRAM_MAP(subroc3d_map)
964   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
964   MCFG_CPU_VBLANK_INT_DRIVER("screen", turbo_state, irq0_line_hold)
965965
966966   MCFG_I8255_ADD( "i8255_0", subroc3d_8255_intf_0 )
967967   MCFG_I8255_ADD( "i8255_1", subroc3d_8255_intf_1 )
r17996r17997
990990   /* basic machine hardware */
991991   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
992992   MCFG_CPU_PROGRAM_MAP(buckrog_map)
993   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
993   MCFG_CPU_VBLANK_INT_DRIVER("screen", turbo_state, irq0_line_hold)
994994
995995   MCFG_CPU_ADD("subcpu", Z80, MASTER_CLOCK/4)
996996   MCFG_CPU_PROGRAM_MAP(buckrog_cpu2_map)
trunk/src/mame/drivers/trvquest.c
r17996r17997
204204   m_video_data = 0;
205205}
206206
207static INTERRUPT_GEN( trvquest_interrupt )
207INTERRUPT_GEN_MEMBER(gameplan_state::trvquest_interrupt)
208208{
209   gameplan_state *state = device->machine().driver_data<gameplan_state>();
210   state->m_via_2->write_ca1(1);
211   state->m_via_2->write_ca1(0);
209   m_via_2->write_ca1(1);
210   m_via_2->write_ca1(0);
212211}
213212
214213static MACHINE_CONFIG_START( trvquest, gameplan_state )
215214
216215   MCFG_CPU_ADD("maincpu", M6809,XTAL_6MHz/4)
217216   MCFG_CPU_PROGRAM_MAP(cpu_map)
218   MCFG_CPU_VBLANK_INT("screen", trvquest_interrupt)
217   MCFG_CPU_VBLANK_INT_DRIVER("screen", gameplan_state, trvquest_interrupt)
219218
220219   MCFG_NVRAM_ADD_1FILL("nvram")
221220   MCFG_MACHINE_START_OVERRIDE(gameplan_state,trvquest)
trunk/src/mame/drivers/tnzs.c
r17996r17997
16201620   /* basic machine hardware */
16211621   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)   /* verified on pcb */
16221622   MCFG_CPU_PROGRAM_MAP(main_map)
1623   MCFG_CPU_VBLANK_INT("screen", arknoid2_interrupt)
1623   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, arknoid2_interrupt)
16241624
16251625   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/2)   /* verified on pcb */
16261626   MCFG_CPU_PROGRAM_MAP(sub_map)
1627   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1627   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
16281628
16291629   MCFG_QUANTUM_PERFECT_CPU("maincpu")
16301630
r17996r17997
16611661   /* basic machine hardware */
16621662   MCFG_CPU_ADD("maincpu", Z80,XTAL_12MHz/2)      /* 6.0 MHz ??? - Main board Crystal is 12MHz */
16631663   MCFG_CPU_PROGRAM_MAP(main_map)
1664   MCFG_CPU_VBLANK_INT("screen", arknoid2_interrupt)
1664   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, arknoid2_interrupt)
16651665
16661666   MCFG_CPU_ADD("sub", Z80,XTAL_12MHz/2)      /* 6.0 MHz ??? - Main board Crystal is 12MHz */
16671667   MCFG_CPU_PROGRAM_MAP(sub_map)
1668   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1668   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
16691669
16701670   MCFG_QUANTUM_PERFECT_CPU("maincpu")
16711671
r17996r17997
17021702   /* basic machine hardware */
17031703   MCFG_CPU_ADD("maincpu", Z80,XTAL_12MHz/2)      /* 6.0 MHz ??? - Main board Crystal is 12MHz */
17041704   MCFG_CPU_PROGRAM_MAP(main_map)
1705   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1705   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17061706
17071707   MCFG_CPU_ADD("sub", Z80,XTAL_12MHz/2)      /* 6.0 MHz ??? - Main board Crystal is 12MHz */
17081708   MCFG_CPU_PROGRAM_MAP(sub_map)
1709   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1709   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17101710
17111711   MCFG_CPU_ADD("mcu", I8742, 12000000/2)   /* 400KHz ??? - Main board Crystal is 12MHz */
17121712   MCFG_CPU_IO_MAP(i8742_io_map)
r17996r17997
17451745   /* basic machine hardware */
17461746   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)   /* verified on pcb */
17471747   MCFG_CPU_PROGRAM_MAP(main_map)
1748   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1748   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17491749
17501750   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/2)   /* verified on pcb */
17511751   MCFG_CPU_PROGRAM_MAP(sub_map)
1752   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1752   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17531753
17541754   MCFG_QUANTUM_PERFECT_CPU("maincpu")
17551755
r17996r17997
17841784   /* basic machine hardware */
17851785   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
17861786   MCFG_CPU_PROGRAM_MAP(main_map)
1787   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1787   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17881788
17891789   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/2) /* verified on pcb */
17901790   MCFG_CPU_PROGRAM_MAP(kageki_sub_map)
1791   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1791   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
17921792
17931793   MCFG_QUANTUM_PERFECT_CPU("maincpu")
17941794
r17996r17997
18291829   /* basic machine hardware */
18301830   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
18311831   MCFG_CPU_PROGRAM_MAP(cpu0_type2)
1832   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1832   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
18331833
18341834   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/2) /* verified on pcb */
18351835   MCFG_CPU_PROGRAM_MAP(tnzsb_cpu1_map)
1836   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1836   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
18371837
18381838   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/2) /* verified on pcb */
18391839   MCFG_CPU_PROGRAM_MAP(tnzsb_cpu2_map)
r17996r17997
18921892   /* basic machine hardware */
18931893   MCFG_CPU_ADD("maincpu", Z80,XTAL_12MHz/2) /* Not verified - Main board Crystal is 12MHz */
18941894   MCFG_CPU_PROGRAM_MAP(jpopnics_main_map)
1895   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1895   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
18961896
18971897   MCFG_CPU_ADD("sub", Z80,XTAL_12MHz/2)   /* Not verified - Main board Crystal is 12MHz */
18981898   MCFG_CPU_PROGRAM_MAP(jpopnics_sub_map)
1899   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1899   MCFG_CPU_VBLANK_INT_DRIVER("screen", tnzs_state, irq0_line_hold)
19001900
19011901   MCFG_QUANTUM_PERFECT_CPU("maincpu")
19021902
trunk/src/mame/drivers/rohga.c
r17996r17997
800800   /* basic machine hardware */
801801   MCFG_CPU_ADD("maincpu", M68000, 14000000)
802802   MCFG_CPU_PROGRAM_MAP(rohga_map)
803   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)
803   MCFG_CPU_VBLANK_INT_DRIVER("screen", rohga_state, irq6_line_assert)
804804
805805   MCFG_CPU_ADD("audiocpu", H6280,32220000/4/3) /* verified on pcb (8.050Mhz is XIN on pin 10 of H6280 */
806806   MCFG_CPU_PROGRAM_MAP(rohga_sound_map)
r17996r17997
850850   /* basic machine hardware */
851851   MCFG_CPU_ADD("maincpu", M68000, 14000000)
852852   MCFG_CPU_PROGRAM_MAP(wizdfire_map)
853   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)
853   MCFG_CPU_VBLANK_INT_DRIVER("screen", rohga_state, irq6_line_assert)
854854
855855   MCFG_CPU_ADD("audiocpu", H6280,32220000/4/3) /* verified on pcb (8.050Mhz is XIN on pin 10 of H6280 */
856856   MCFG_CPU_PROGRAM_MAP(rohga_sound_map)
r17996r17997
904904   /* basic machine hardware */
905905   MCFG_CPU_ADD("maincpu", M68000, 14000000)
906906   MCFG_CPU_PROGRAM_MAP(nitrobal_map)
907   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)
907   MCFG_CPU_VBLANK_INT_DRIVER("screen", rohga_state, irq6_line_assert)
908908
909909   MCFG_CPU_ADD("audiocpu", H6280,32220000/4/3) /* verified on pcb (8.050Mhz is XIN on pin 10 of H6280 */
910910   MCFG_CPU_PROGRAM_MAP(rohga_sound_map)
r17996r17997
958958   /* basic machine hardware */
959959   MCFG_CPU_ADD("maincpu", M68000, 14000000)
960960   MCFG_CPU_PROGRAM_MAP(schmeisr_map)
961   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)
961   MCFG_CPU_VBLANK_INT_DRIVER("screen", rohga_state, irq6_line_assert)
962962
963963   MCFG_CPU_ADD("audiocpu", H6280,32220000/4/3) /* verified on pcb (8.050Mhz is XIN on pin 10 of H6280 */
964964   MCFG_CPU_PROGRAM_MAP(rohga_sound_map)
trunk/src/mame/drivers/plygonet.c
r17996r17997
154154/* irq 3 is network.  don't generate if you don't emulate the network h/w! */
155155/* irq 5 is vblank */
156156/* irq 7 does nothing (it jsrs to a rts and then rte) */
157static INTERRUPT_GEN(polygonet_interrupt)
157INTERRUPT_GEN_MEMBER(polygonet_state::polygonet_interrupt)
158158{
159   device->execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
159   device.execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
160160}
161161
162162/* sound CPU communications */
r17996r17997
555555   reset_sound_region(machine());
556556}
557557
558static INTERRUPT_GEN(audio_interrupt)
558INTERRUPT_GEN_MEMBER(polygonet_state::audio_interrupt)
559559{
560   device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
560   device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
561561}
562562
563563static ADDRESS_MAP_START( sound_map, AS_PROGRAM, 8, polygonet_state )
r17996r17997
622622
623623   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)   /* 16 MHz (xtal is 32.0 MHz) */
624624   MCFG_CPU_PROGRAM_MAP(main_map)
625   MCFG_CPU_VBLANK_INT("screen", polygonet_interrupt)
625   MCFG_CPU_VBLANK_INT_DRIVER("screen", polygonet_state, polygonet_interrupt)
626626
627627   MCFG_CPU_ADD("dsp", DSP56156, 40000000)      /* xtal is 40.0 MHz, DSP has an internal divide-by-2 */
628628   MCFG_CPU_PROGRAM_MAP(dsp_program_map)
r17996r17997
630630
631631   MCFG_CPU_ADD("soundcpu", Z80, 8000000)
632632   MCFG_CPU_PROGRAM_MAP(sound_map)
633   MCFG_CPU_PERIODIC_INT(audio_interrupt, 480)
633   MCFG_CPU_PERIODIC_INT_DRIVER(polygonet_state, audio_interrupt, 480)
634634
635635
636636   MCFG_GFXDECODE(plygonet)
trunk/src/mame/drivers/nemesis.c
r17996r17997
5656#include "includes/konamipt.h"
5757
5858
59static INTERRUPT_GEN( nemesis_interrupt )
59INTERRUPT_GEN_MEMBER(nemesis_state::nemesis_interrupt)
6060{
61   nemesis_state *state = device->machine().driver_data<nemesis_state>();
6261
63   if (state->m_irq_on)
64      device->execute().set_input_line(1, HOLD_LINE);
62   if (m_irq_on)
63      device.execute().set_input_line(1, HOLD_LINE);
6564}
6665
67static INTERRUPT_GEN( blkpnthr_interrupt )
66INTERRUPT_GEN_MEMBER(nemesis_state::blkpnthr_interrupt)
6867{
69   nemesis_state *state = device->machine().driver_data<nemesis_state>();
7068
71   if (state->m_irq_on)
72      device->execute().set_input_line(2, HOLD_LINE);
69   if (m_irq_on)
70      device.execute().set_input_line(2, HOLD_LINE);
7371}
7472
7573static TIMER_DEVICE_CALLBACK( konamigt_interrupt )
r17996r17997
15581556   MCFG_CPU_ADD("maincpu", M68000,18432000/2)         /* 9.216 MHz? */
15591557//          14318180/2, /* From schematics, should be accurate */
15601558   MCFG_CPU_PROGRAM_MAP(nemesis_map)
1561   MCFG_CPU_VBLANK_INT("screen", nemesis_interrupt)
1559   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nemesis_interrupt)
15621560
15631561   MCFG_CPU_ADD("audiocpu", Z80,14318180/4) /* From schematics, should be accurate */
15641562   MCFG_CPU_PROGRAM_MAP(sound_map)   /* fixed */
r17996r17997
16041602
16051603   MCFG_CPU_ADD("audiocpu", Z80,14318180/4)        /* 3.579545 MHz */
16061604   MCFG_CPU_PROGRAM_MAP(gx400_sound_map)
1607   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)   /* interrupts are triggered by the main CPU */
1605   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nmi_line_pulse)   /* interrupts are triggered by the main CPU */
16081606
16091607
16101608   /* video hardware */
r17996r17997
16861684
16871685   MCFG_CPU_ADD("audiocpu", Z80,14318180/4)        /* 3.579545 MHz */
16881686   MCFG_CPU_PROGRAM_MAP(gx400_sound_map)
1689   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)   /* interrupts are triggered by the main CPU */
1687   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nmi_line_pulse)   /* interrupts are triggered by the main CPU */
16901688
16911689
16921690   /* video hardware */
r17996r17997
17251723   /* basic machine hardware */
17261724   MCFG_CPU_ADD("maincpu", M68000,18432000/2)       /* 9.216MHz */
17271725   MCFG_CPU_PROGRAM_MAP(salamand_map)
1728   MCFG_CPU_VBLANK_INT("screen", nemesis_interrupt)
1726   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nemesis_interrupt)
17291727
17301728   MCFG_CPU_ADD("audiocpu", Z80, 3579545)         /* 3.579545 MHz */
17311729   MCFG_CPU_PROGRAM_MAP(sal_sound_map)
r17996r17997
17711769   /* basic machine hardware */
17721770   MCFG_CPU_ADD("maincpu", M68000,18432000/2)         /* 9.216 MHz? */
17731771   MCFG_CPU_PROGRAM_MAP(blkpnthr_map)
1774   MCFG_CPU_VBLANK_INT("screen", blkpnthr_interrupt)
1772   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, blkpnthr_interrupt)
17751773
17761774   MCFG_CPU_ADD("audiocpu", Z80, 3579545)        /* 3.579545 MHz */
17771775   MCFG_CPU_PROGRAM_MAP(blkpnthr_sound_map)
r17996r17997
18131811   /* basic machine hardware */
18141812   MCFG_CPU_ADD("maincpu", M68000,18432000/2)         /* 9.216 MHz? */
18151813   MCFG_CPU_PROGRAM_MAP(citybomb_map)
1816   MCFG_CPU_VBLANK_INT("screen", nemesis_interrupt)
1814   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nemesis_interrupt)
18171815
18181816   MCFG_CPU_ADD("audiocpu", Z80, 3579545)        /* 3.579545 MHz */
18191817   MCFG_CPU_PROGRAM_MAP(city_sound_map)
r17996r17997
18591857   /* basic machine hardware */
18601858   MCFG_CPU_ADD("maincpu", M68000,18432000/2)         /* 9.216 MHz? */
18611859   MCFG_CPU_PROGRAM_MAP(nyanpani_map)
1862   MCFG_CPU_VBLANK_INT("screen", nemesis_interrupt)
1860   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nemesis_interrupt)
18631861
18641862   MCFG_CPU_ADD("audiocpu", Z80, 3579545)        /* 3.579545 MHz */
18651863   MCFG_CPU_PROGRAM_MAP(city_sound_map)
r17996r17997
26552653
26562654   MCFG_CPU_ADD("audiocpu", Z80,14318180/4)        /* 3.579545 MHz */
26572655   MCFG_CPU_PROGRAM_MAP(gx400_sound_map)
2658   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)   /* interrupts are triggered by the main CPU */
2656   MCFG_CPU_VBLANK_INT_DRIVER("screen", nemesis_state, nmi_line_pulse)   /* interrupts are triggered by the main CPU */
26592657
26602658
26612659   /* video hardware */
trunk/src/mame/drivers/progolf.c
r17996r17997
8787   virtual void video_start();
8888   virtual void palette_init();
8989   UINT32 screen_update_progolf(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
90   INTERRUPT_GEN_MEMBER(progolf_interrupt);
9091};
9192
9293
r17996r17997
370371
371372
372373//#ifdef UNUSED_FUNCTION
373static INTERRUPT_GEN( progolf_interrupt )
374INTERRUPT_GEN_MEMBER(progolf_state::progolf_interrupt)
374375{
375376}
376377//#endif
r17996r17997
423424   /* basic machine hardware */
424425   MCFG_CPU_ADD("maincpu", M6502, 3000000/2) /* guess, 3 Mhz makes the game to behave worse? */
425426   MCFG_CPU_PROGRAM_MAP(main_cpu)
426   MCFG_CPU_VBLANK_INT("screen", progolf_interrupt)
427   MCFG_CPU_VBLANK_INT_DRIVER("screen", progolf_state, progolf_interrupt)
427428
428429   MCFG_CPU_ADD("audiocpu", M6502, 500000)
429430   MCFG_CPU_PROGRAM_MAP(sound_cpu)
trunk/src/mame/drivers/magmax.c
r17996r17997
347347   /* basic machine hardware */
348348   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   /* verified on pcb */
349349   MCFG_CPU_PROGRAM_MAP(magmax_map)
350   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
350   MCFG_CPU_VBLANK_INT_DRIVER("screen", magmax_state, irq1_line_hold)
351351
352352   MCFG_CPU_ADD("audiocpu", Z80,XTAL_20MHz/8) /* verified on pcb */
353353   MCFG_CPU_PROGRAM_MAP(magmax_sound_map)
trunk/src/mame/drivers/warriorb.c
r17996r17997
546546   /* basic machine hardware */
547547   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? (Might well be 16!) */
548548   MCFG_CPU_PROGRAM_MAP(darius2d_map)
549   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
549   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", warriorb_state, irq4_line_hold)
550550
551551   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ? */
552552   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
r17996r17997
609609   /* basic machine hardware */
610610   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz ? */
611611   MCFG_CPU_PROGRAM_MAP(warriorb_map)
612   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
612   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", warriorb_state, irq4_line_hold)
613613
614614   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ? */
615615   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
trunk/src/mame/drivers/goal92.c
r17996r17997
315315   /* basic machine hardware */
316316   MCFG_CPU_ADD("maincpu", M68000,12000000)
317317   MCFG_CPU_PROGRAM_MAP(goal92_map)
318   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) /* VBL */
318   MCFG_CPU_VBLANK_INT_DRIVER("screen", goal92_state, irq6_line_hold) /* VBL */
319319
320320   MCFG_CPU_ADD("audiocpu", Z80, 2500000)
321321   MCFG_CPU_PROGRAM_MAP(sound_cpu)
trunk/src/mame/drivers/bombjack.c
r17996r17997
347347}
348348
349349
350static INTERRUPT_GEN( vblank_irq )
350INTERRUPT_GEN_MEMBER(bombjack_state::vblank_irq)
351351{
352   bombjack_state *state = device->machine().driver_data<bombjack_state>();
353352
354   if(state->m_nmi_mask)
355      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
353   if(m_nmi_mask)
354      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
356355}
357356
358357static MACHINE_CONFIG_START( bombjack, bombjack_state )
r17996r17997
360359   /* basic machine hardware */
361360   MCFG_CPU_ADD("maincpu", Z80, XTAL_4MHz)      /* Confirmed from PCB */
362361   MCFG_CPU_PROGRAM_MAP(main_map)
363   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
362   MCFG_CPU_VBLANK_INT_DRIVER("screen", bombjack_state, vblank_irq)
364363
365364   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4)   /* Confirmed from PCB */
366365   MCFG_CPU_PROGRAM_MAP(audio_map)
367366   MCFG_CPU_IO_MAP(audio_io_map)
368   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
367   MCFG_CPU_VBLANK_INT_DRIVER("screen", bombjack_state, nmi_line_pulse)
369368
370369
371370   /* video hardware */
trunk/src/mame/drivers/trucocl.c
r17996r17997
122122   GFXDECODE_ENTRY( "gfx1", 0x10000, tilelayout,      0, 2 )
123123GFXDECODE_END
124124
125static INTERRUPT_GEN( trucocl_interrupt )
125INTERRUPT_GEN_MEMBER(trucocl_state::trucocl_interrupt)
126126{
127   trucocl_state *state = device->machine().driver_data<trucocl_state>();
128127
129   if(state->m_irq_mask)
130      device->execute().set_input_line(0, HOLD_LINE);
128   if(m_irq_mask)
129      device.execute().set_input_line(0, HOLD_LINE);
131130
132131}
133132
r17996r17997
135134   /* basic machine hardware */
136135   MCFG_CPU_ADD("maincpu", Z80, 18432000/6)
137136   MCFG_CPU_PROGRAM_MAP(main_map)
138   MCFG_CPU_VBLANK_INT("screen", trucocl_interrupt)
137   MCFG_CPU_VBLANK_INT_DRIVER("screen", trucocl_state, trucocl_interrupt)
139138
140139   /* video hardware */
141140   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/unico.c
r17996r17997
593593   /* basic machine hardware */
594594   MCFG_CPU_ADD("maincpu", M68000, 16000000)
595595   MCFG_CPU_PROGRAM_MAP(burglarx_map)
596   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
596   MCFG_CPU_VBLANK_INT_DRIVER("screen", unico_state, irq2_line_hold)
597597
598598   MCFG_MACHINE_RESET_OVERRIDE(unico_state,unico)
599599
r17996r17997
638638   /* basic machine hardware */
639639   MCFG_CPU_ADD("maincpu", M68000, 16000000)
640640   MCFG_CPU_PROGRAM_MAP(zeropnt_map)
641   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
641   MCFG_CPU_VBLANK_INT_DRIVER("screen", unico_state, irq2_line_hold)
642642
643643   MCFG_MACHINE_RESET_OVERRIDE(unico_state,zeropt)
644644
r17996r17997
678678   /* basic machine hardware */
679679   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)
680680   MCFG_CPU_PROGRAM_MAP(zeropnt2_map)
681   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
681   MCFG_CPU_VBLANK_INT_DRIVER("screen", unico_state, irq2_line_hold)
682682
683683   MCFG_MACHINE_RESET_OVERRIDE(unico_state,zeropt)
684684
trunk/src/mame/drivers/blockhl.c
r17996r17997
3030/* prototypes */
3131static KONAMI_SETLINES_CALLBACK( blockhl_banking );
3232
33static INTERRUPT_GEN( blockhl_interrupt )
33INTERRUPT_GEN_MEMBER(blockhl_state::blockhl_interrupt)
3434{
35   blockhl_state *state = device->machine().driver_data<blockhl_state>();
3635
37   if (k052109_is_irq_enabled(state->m_k052109) && state->m_rombank == 0)   /* kludge to prevent crashes */
38      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
36   if (k052109_is_irq_enabled(m_k052109) && m_rombank == 0)   /* kludge to prevent crashes */
37      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
3938}
4039
4140READ8_MEMBER(blockhl_state::bankedram_r)
r17996r17997
215214   /* basic machine hardware */
216215   MCFG_CPU_ADD("maincpu", KONAMI,3000000)      /* Konami custom 052526 */
217216   MCFG_CPU_PROGRAM_MAP(main_map)
218   MCFG_CPU_VBLANK_INT("screen", blockhl_interrupt)
217   MCFG_CPU_VBLANK_INT_DRIVER("screen", blockhl_state, blockhl_interrupt)
219218
220219   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
221220   MCFG_CPU_PROGRAM_MAP(audio_map)
trunk/src/mame/drivers/gcpinbal.c
r17996r17997
6565}
6666#endif
6767
68static INTERRUPT_GEN( gcpinbal_interrupt )
68INTERRUPT_GEN_MEMBER(gcpinbal_state::gcpinbal_interrupt)
6969{
7070   /* Unsure of actual sequence */
7171
72   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(500), FUNC(gcpinbal_interrupt1));
73//  device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(1000), FUNC(gcpinbal_interrupt3));
74   device->execute().set_input_line(4, HOLD_LINE);
72   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(500), FUNC(gcpinbal_interrupt1));
73//  machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(1000), FUNC(gcpinbal_interrupt3));
74   device.execute().set_input_line(4, HOLD_LINE);
7575}
7676
7777
r17996r17997
439439   /* basic machine hardware */
440440   MCFG_CPU_ADD("maincpu", M68000, 32000000/2)   /* 16 MHz ? */
441441   MCFG_CPU_PROGRAM_MAP(gcpinbal_map)
442   MCFG_CPU_VBLANK_INT("screen", gcpinbal_interrupt)
442   MCFG_CPU_VBLANK_INT_DRIVER("screen", gcpinbal_state, gcpinbal_interrupt)
443443
444444   /* video hardware */
445445   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/blackt96.c
r17996r17997
608608static MACHINE_CONFIG_START( blackt96, blackt96_state )
609609   MCFG_CPU_ADD("maincpu", M68000, 18000000 /2)
610610   MCFG_CPU_PROGRAM_MAP(blackt96_map)
611   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
611   MCFG_CPU_VBLANK_INT_DRIVER("screen", blackt96_state, irq1_line_hold)
612612
613613   MCFG_CPU_ADD("audiocpu", PIC16C57, 8000000)   /* ? */
614614   MCFG_CPU_IO_MAP(sound_io_map)
trunk/src/mame/drivers/segag80v.c
r17996r17997
898898   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK/2)
899899   MCFG_CPU_PROGRAM_MAP(main_map)
900900   MCFG_CPU_IO_MAP(main_portmap)
901   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
901   MCFG_CPU_VBLANK_INT_DRIVER("screen", segag80v_state, irq0_line_hold)
902902
903903
904904   /* video hardware */
trunk/src/mame/drivers/gatron.c
r17996r17997
448448   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/24)   /* 666.66 kHz, guess */
449449   MCFG_CPU_PROGRAM_MAP(gat_map)
450450   MCFG_CPU_IO_MAP(gat_portmap)
451   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
451   MCFG_CPU_VBLANK_INT_DRIVER("screen", gatron_state, nmi_line_pulse)
452452
453453   MCFG_NVRAM_ADD_0FILL("nvram")
454454
trunk/src/mame/drivers/bottom9.c
r17996r17997
2020#include "includes/konamipt.h"
2121#include "includes/bottom9.h"
2222
23static INTERRUPT_GEN( bottom9_interrupt )
23INTERRUPT_GEN_MEMBER(bottom9_state::bottom9_interrupt)
2424{
25   bottom9_state *state = device->machine().driver_data<bottom9_state>();
2625
27   if (k052109_is_irq_enabled(state->m_k052109))
28      device->execute().set_input_line(0, HOLD_LINE);
26   if (k052109_is_irq_enabled(m_k052109))
27      device.execute().set_input_line(0, HOLD_LINE);
2928}
3029
3130READ8_MEMBER(bottom9_state::k052109_051960_r)
r17996r17997
138137   m_audiocpu->set_input_line_and_vector(0, HOLD_LINE, 0xff);
139138}
140139
141static INTERRUPT_GEN( bottom9_sound_interrupt )
140INTERRUPT_GEN_MEMBER(bottom9_state::bottom9_sound_interrupt)
142141{
143   bottom9_state *state = device->machine().driver_data<bottom9_state>();
144   if (state->m_nmienable)
145      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
142   if (m_nmienable)
143      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
146144}
147145
148146WRITE8_MEMBER(bottom9_state::nmi_enable_w)
r17996r17997
353351   /* basic machine hardware */
354352   MCFG_CPU_ADD("maincpu", M6809, 2000000) /* ? */
355353   MCFG_CPU_PROGRAM_MAP(main_map)
356   MCFG_CPU_VBLANK_INT("screen", bottom9_interrupt)
354   MCFG_CPU_VBLANK_INT_DRIVER("screen", bottom9_state, bottom9_interrupt)
357355
358356   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
359357   MCFG_CPU_PROGRAM_MAP(audio_map)
360   MCFG_CPU_PERIODIC_INT(bottom9_sound_interrupt,8*60)   /* irq is triggered by the main CPU */
358   MCFG_CPU_PERIODIC_INT_DRIVER(bottom9_state, bottom9_sound_interrupt, 8*60)   /* irq is triggered by the main CPU */
361359
362360
363361   /* video hardware */
trunk/src/mame/drivers/dreamwld.c
r17996r17997
589589   /* basic machine hardware */
590590   MCFG_CPU_ADD("maincpu", M68EC020, MASTER_CLOCK/2)
591591   MCFG_CPU_PROGRAM_MAP(baryon_map)
592   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold )
592   MCFG_CPU_VBLANK_INT_DRIVER("screen", dreamwld_state,  irq4_line_hold)
593593
594594
595595   /* video hardware */
r17996r17997
617617   /* basic machine hardware */
618618   MCFG_CPU_MODIFY("maincpu")
619619   MCFG_CPU_PROGRAM_MAP(dreamwld_map)
620   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
620   MCFG_CPU_VBLANK_INT_DRIVER("screen", dreamwld_state, irq4_line_hold)
621621
622622   MCFG_OKIM6295_ADD("oki2", MASTER_CLOCK/32, OKIM6295_PIN7_LOW)
623623   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.50)
trunk/src/mame/drivers/m62.c
r17996r17997
957957   MCFG_CPU_ADD("maincpu", Z80, 24000000/6)
958958   MCFG_CPU_PROGRAM_MAP(ldrun_map)
959959   MCFG_CPU_IO_MAP(kungfum_io_map)
960   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
960   MCFG_CPU_VBLANK_INT_DRIVER("screen", m62_state, irq0_line_hold)
961961
962962
963963   /* video hardware */
trunk/src/mame/drivers/megazone.c
r17996r17997
244244   m_i8039_status = 0;
245245}
246246
247static INTERRUPT_GEN( vblank_irq )
247INTERRUPT_GEN_MEMBER(megazone_state::vblank_irq)
248248{
249   megazone_state *state = device->machine().driver_data<megazone_state>();
250249
251   if(state->m_irq_mask)
252      device->execute().set_input_line(0, HOLD_LINE);
250   if(m_irq_mask)
251      device.execute().set_input_line(0, HOLD_LINE);
253252}
254253
255254
r17996r17997
258257   /* basic machine hardware */
259258   MCFG_CPU_ADD("maincpu", M6809, 18432000/9)        /* 2 MHz */
260259   MCFG_CPU_PROGRAM_MAP(megazone_map)
261   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
260   MCFG_CPU_VBLANK_INT_DRIVER("screen", megazone_state, vblank_irq)
262261
263262   MCFG_CPU_ADD("audiocpu", Z80,18432000/6)     /* Z80 Clock is derived from the H1 signal */
264263   MCFG_CPU_PROGRAM_MAP(megazone_sound_map)
265264   MCFG_CPU_IO_MAP(megazone_sound_io_map)
266   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
265   MCFG_CPU_VBLANK_INT_DRIVER("screen", megazone_state, irq0_line_hold)
267266
268267   MCFG_CPU_ADD("daccpu", I8039,14318000/2)   /* 1/2 14MHz crystal */
269268   MCFG_CPU_PROGRAM_MAP(megazone_i8039_map)
trunk/src/mame/drivers/pass.c
r17996r17997
236236   /* basic machine hardware */
237237   MCFG_CPU_ADD("maincpu", M68000, 14318180/2 )
238238   MCFG_CPU_PROGRAM_MAP(pass_map)
239   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) /* all the same */
239   MCFG_CPU_VBLANK_INT_DRIVER("screen", pass_state, irq1_line_hold) /* all the same */
240240
241241   MCFG_CPU_ADD("audiocpu", Z80, 14318180/4 )
242242   MCFG_CPU_PROGRAM_MAP(pass_sound_map)
243243   MCFG_CPU_IO_MAP(pass_sound_io_map)
244   MCFG_CPU_PERIODIC_INT(irq0_line_hold,60) /* probably not accurate, unknown timing and generation (ym2203 sound chip?). */
244   MCFG_CPU_PERIODIC_INT_DRIVER(pass_state, irq0_line_hold, 60) /* probably not accurate, unknown timing and generation (ym2203 sound chip?). */
245245
246246   /* video hardware */
247247   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/40love.c
r17996r17997
10601060   /* basic machine hardware */
10611061   MCFG_CPU_ADD("maincpu",Z80,8000000/2) /* OK */
10621062   MCFG_CPU_PROGRAM_MAP(40love_map)
1063   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1063   MCFG_CPU_VBLANK_INT_DRIVER("screen", fortyl_state, irq0_line_hold)
10641064
10651065   MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* OK */
10661066   MCFG_CPU_PROGRAM_MAP(sound_map)
1067   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* source/number of IRQs is unknown */
1067   MCFG_CPU_PERIODIC_INT_DRIVER(fortyl_state, irq0_line_hold, 2*60)   /* source/number of IRQs is unknown */
10681068
10691069   MCFG_CPU_ADD("mcu",M68705,18432000/6) /* OK */
10701070   MCFG_CPU_PROGRAM_MAP(buggychl_mcu_map)
r17996r17997
11161116   /* basic machine hardware */
11171117   MCFG_CPU_ADD("maincpu",Z80,8000000/2)
11181118   MCFG_CPU_PROGRAM_MAP(undoukai_map)
1119   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1119   MCFG_CPU_VBLANK_INT_DRIVER("screen", fortyl_state, irq0_line_hold)
11201120
11211121   MCFG_CPU_ADD("audiocpu",Z80,8000000/2)
11221122   MCFG_CPU_PROGRAM_MAP(sound_map)
1123   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* source/number of IRQs is unknown */
1123   MCFG_CPU_PERIODIC_INT_DRIVER(fortyl_state, irq0_line_hold, 2*60)   /* source/number of IRQs is unknown */
11241124
11251125//  MCFG_CPU_ADD("mcu",M68705,18432000/6)
11261126//  MCFG_CPU_PROGRAM_MAP(buggychl_mcu_map)
trunk/src/mame/drivers/galaga.c
r17996r17997
16371637};
16381638
16391639
1640static INTERRUPT_GEN( main_vblank_irq )
1640INTERRUPT_GEN_MEMBER(galaga_state::main_vblank_irq)
16411641{
1642   galaga_state *state = device->machine().driver_data<galaga_state>();
16431642
1644   if(state->m_main_irq_mask)
1645      device->execute().set_input_line(0, ASSERT_LINE);
1643   if(m_main_irq_mask)
1644      device.execute().set_input_line(0, ASSERT_LINE);
16461645}
16471646
1648static INTERRUPT_GEN( sub_vblank_irq )
1647INTERRUPT_GEN_MEMBER(galaga_state::sub_vblank_irq)
16491648{
1650   galaga_state *state = device->machine().driver_data<galaga_state>();
16511649
1652   if(state->m_sub_irq_mask)
1653      device->execute().set_input_line(0, ASSERT_LINE);
1650   if(m_sub_irq_mask)
1651      device.execute().set_input_line(0, ASSERT_LINE);
16541652}
16551653
16561654const namco_06xx_config bosco_namco_06xx_0_intf =
r17996r17997
16731671   /* basic machine hardware */
16741672   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
16751673   MCFG_CPU_PROGRAM_MAP(bosco_map)
1676   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
1674   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
16771675
16781676   MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
16791677   MCFG_CPU_PROGRAM_MAP(bosco_map)
1680   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1678   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
16811679
16821680   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
16831681   MCFG_CPU_PROGRAM_MAP(bosco_map)
r17996r17997
17331731   /* basic machine hardware */
17341732   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
17351733   MCFG_CPU_PROGRAM_MAP(galaga_map)
1736   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
1734   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
17371735
17381736   MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
17391737   MCFG_CPU_PROGRAM_MAP(galaga_map)
1740   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1738   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
17411739
17421740   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
17431741   MCFG_CPU_PROGRAM_MAP(galaga_map)
r17996r17997
18101808   /* basic machine hardware */
18111809   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
18121810   MCFG_CPU_PROGRAM_MAP(xevious_map)
1813   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
1811   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
18141812
18151813   MCFG_CPU_ADD("sub", Z80,MASTER_CLOCK/6)   /* 3.072 MHz */
18161814   MCFG_CPU_PROGRAM_MAP(xevious_map)
1817   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1815   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
18181816
18191817   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
18201818   MCFG_CPU_PROGRAM_MAP(xevious_map)
r17996r17997
18731871
18741872   MCFG_CPU_ADD("sub3", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
18751873   MCFG_CPU_PROGRAM_MAP(battles_mem4)
1876   MCFG_CPU_VBLANK_INT("screen", battles_interrupt_4)
1874   MCFG_CPU_VBLANK_INT_DRIVER("screen", xevious_state, battles_interrupt_4)
18771875
18781876   MCFG_TIMER_ADD("battles_nmi", battles_nmi_generate)
18791877
r17996r17997
18991897   /* basic machine hardware */
19001898   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
19011899   MCFG_CPU_PROGRAM_MAP(digdug_map)
1902   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
1900   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
19031901
19041902   MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
19051903   MCFG_CPU_PROGRAM_MAP(digdug_map)
1906   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1904   MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
19071905
19081906   MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
19091907   MCFG_CPU_PROGRAM_MAP(digdug_map)
trunk/src/mame/drivers/istellar.c
r17996r17997
5454   virtual void machine_start();
5555   virtual void palette_init();
5656   UINT32 screen_update_istellar(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
57   INTERRUPT_GEN_MEMBER(vblank_callback_istellar);
5758};
5859
5960
r17996r17997
316317   GFXDECODE_ENTRY( "gfx1", 0, istellar_gfx_layout, 0x0, 0x20 )
317318GFXDECODE_END
318319
319static INTERRUPT_GEN( vblank_callback_istellar )
320INTERRUPT_GEN_MEMBER(istellar_state::vblank_callback_istellar)
320321{
321322   /* Interrupt presumably comes from VBlank */
322   device->execute().set_input_line(0, HOLD_LINE);
323   device.execute().set_input_line(0, HOLD_LINE);
323324
324325   /* Interrupt presumably comes from the LDP's status strobe */
325   device->machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
326   machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
326327}
327328
328329
r17996r17997
332333   MCFG_CPU_ADD("maincpu", Z80, GUESSED_CLOCK)
333334   MCFG_CPU_PROGRAM_MAP(z80_0_mem)
334335   MCFG_CPU_IO_MAP(z80_0_io)
335   MCFG_CPU_VBLANK_INT("screen", vblank_callback_istellar)
336   MCFG_CPU_VBLANK_INT_DRIVER("screen", istellar_state, vblank_callback_istellar)
336337
337338   /* sound cpu */
338339   MCFG_CPU_ADD("audiocpu", Z80, GUESSED_CLOCK)
trunk/src/mame/drivers/lasso.c
r17996r17997
511511   /* basic machine hardware */
512512   MCFG_CPU_ADD("maincpu", M6502, 11289000/16)   /* guess */
513513   MCFG_CPU_PROGRAM_MAP(lasso_main_map)
514   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
514   MCFG_CPU_VBLANK_INT_DRIVER("screen", lasso_state, irq0_line_hold)
515515
516516   MCFG_CPU_ADD("audiocpu", M6502, 600000)
517517   MCFG_CPU_PROGRAM_MAP(lasso_audio_map)
r17996r17997
597597   /* basic machine hardware */
598598   MCFG_CPU_REPLACE("maincpu", M6502, XTAL_18MHz/24)
599599   MCFG_CPU_PROGRAM_MAP(pinbo_main_map)
600   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
600   MCFG_CPU_VBLANK_INT_DRIVER("screen", lasso_state, irq0_line_hold)
601601
602602   MCFG_CPU_REPLACE("audiocpu", Z80, XTAL_18MHz/6)
603603   MCFG_CPU_PROGRAM_MAP(pinbo_audio_map)
trunk/src/mame/drivers/macs.c
r17996r17997
481481   MCFG_CPU_PROGRAM_MAP(macs_mem)
482482   MCFG_CPU_IO_MAP(macs_io)
483483
484   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
484   MCFG_CPU_VBLANK_INT_DRIVER("screen", macs_state, irq0_line_hold)
485485
486486   MCFG_MACHINE_RESET_OVERRIDE(macs_state,macs)
487487
trunk/src/mame/drivers/othunder.c
r17996r17997
273273   update_irq(machine());
274274}
275275
276static INTERRUPT_GEN( vblank_interrupt )
276INTERRUPT_GEN_MEMBER(othunder_state::vblank_interrupt)
277277{
278   othunder_state *state = device->machine().driver_data<othunder_state>();
279278
280   state->m_vblank_irq = 1;
281   update_irq(device->machine());
279   m_vblank_irq = 1;
280   update_irq(machine());
282281}
283282
284283static TIMER_CALLBACK( ad_interrupt )
r17996r17997
710709//  MCFG_CPU_ADD("maincpu", M68000, 24000000/2 )   /* 12 MHz */
711710   MCFG_CPU_ADD("maincpu", M68000, 13000000 )   /* fixes garbage graphics on startup */
712711   MCFG_CPU_PROGRAM_MAP(othunder_map)
713   MCFG_CPU_VBLANK_INT("screen", vblank_interrupt)
712   MCFG_CPU_VBLANK_INT_DRIVER("screen", othunder_state, vblank_interrupt)
714713
715714   MCFG_CPU_ADD("audiocpu", Z80,16000000/4 )   /* 4 MHz */
716715   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
trunk/src/mame/drivers/8080bw.c
r17996r17997
12141214   /* basic machine hardware */
12151215   MCFG_CPU_REPLACE("maincpu",M6800,1500000) // ?
12161216   MCFG_CPU_PROGRAM_MAP(sflush_map)
1217   MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
1217   MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, irq0_line_hold)
12181218   MCFG_MACHINE_START_OVERRIDE(_8080bw_state,mw8080bw)
12191219
12201220   /* add shifter */
r17996r17997
13631363/*                                                     */
13641364/*******************************************************/
13651365
1366static INTERRUPT_GEN( polaris_interrupt )
1366INTERRUPT_GEN_MEMBER(_8080bw_state::polaris_interrupt)
13671367{
1368   _8080bw_state *state = device->machine().driver_data<_8080bw_state>();
1369   state->m_polaris_cloud_speed++;
1368   m_polaris_cloud_speed++;
13701369
1371   if (state->m_polaris_cloud_speed >= 4)   /* every 4 frames - this was verified against real machine */
1370   if (m_polaris_cloud_speed >= 4)   /* every 4 frames - this was verified against real machine */
13721371   {
1373      state->m_polaris_cloud_speed = 0;
1374      state->m_polaris_cloud_pos++;
1372      m_polaris_cloud_speed = 0;
1373      m_polaris_cloud_pos++;
13751374   }
13761375}
13771376
r17996r17997
14611460   MCFG_CPU_PROGRAM_MAP(schaser_map)
14621461   MCFG_CPU_IO_MAP(polaris_io_map)
14631462   MCFG_WATCHDOG_VBLANK_INIT(255)
1464   MCFG_CPU_VBLANK_INT("screen", polaris_interrupt)
1463   MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, polaris_interrupt)
14651464   MCFG_MACHINE_START_OVERRIDE(_8080bw_state,polaris)
14661465
14671466   /* add shifter */
r17996r17997
20742073   MCFG_CPU_MODIFY("maincpu")
20752074   MCFG_CPU_PROGRAM_MAP(darthvdr_map)
20762075   MCFG_CPU_IO_MAP(darthvdr_io_map)
2077   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
2076   MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, irq0_line_hold)
20782077
20792078   MCFG_MACHINE_START_OVERRIDE(_8080bw_state,darthvdr)
20802079   MCFG_MACHINE_RESET_OVERRIDE(_8080bw_state,darthvdr)
trunk/src/mame/drivers/good.c
r17996r17997
279279
280280   MCFG_CPU_ADD("maincpu", M68000, 16000000 /2)
281281   MCFG_CPU_PROGRAM_MAP(good_map)
282   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
282   MCFG_CPU_VBLANK_INT_DRIVER("screen", good_state, irq2_line_hold)
283283
284284   MCFG_GFXDECODE(good)
285285
trunk/src/mame/drivers/quasar.c
r17996r17997
268268   GFXDECODE_ENTRY( "gfx1", 0x0000, charlayout, 0, 64+1 )   /* ROM chars */
269269GFXDECODE_END
270270
271static INTERRUPT_GEN( quasar_interrupt )
271INTERRUPT_GEN_MEMBER(quasar_state::quasar_interrupt)
272272{
273   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
273   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
274274}
275275
276276static const s2636_interface s2636_0_config =
r17996r17997
328328   MCFG_CPU_ADD("maincpu", S2650, 14318000/4)   /* 14 mhz crystal divide by 4 on board */
329329   MCFG_CPU_PROGRAM_MAP(quasar)
330330   MCFG_CPU_IO_MAP(quasar_io)
331   MCFG_CPU_VBLANK_INT("screen", quasar_interrupt)
331   MCFG_CPU_VBLANK_INT_DRIVER("screen", quasar_state, quasar_interrupt)
332332
333333   MCFG_CPU_ADD("soundcpu",I8035,6000000)         /* 6MHz crystal divide by 15 in CPU */
334334   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/xyonix.c
r17996r17997
235235   MCFG_CPU_ADD("maincpu", Z80,16000000 / 4)       /* 4 MHz ? */
236236   MCFG_CPU_PROGRAM_MAP(main_map)
237237   MCFG_CPU_IO_MAP(port_map)
238   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
239   MCFG_CPU_PERIODIC_INT(irq0_line_assert,4*60)   /* ?? controls music tempo */
238   MCFG_CPU_VBLANK_INT_DRIVER("screen", xyonix_state,  nmi_line_pulse)
239   MCFG_CPU_PERIODIC_INT_DRIVER(xyonix_state, irq0_line_assert, 4*60)   /* ?? controls music tempo */
240240
241241   /* video hardware */
242242   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/1943.c
r17996r17997
257257   // basic machine hardware
258258   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4)   /* verified on pcb */
259259   MCFG_CPU_PROGRAM_MAP(c1943_map)
260   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
260   MCFG_CPU_VBLANK_INT_DRIVER("screen", _1943_state, irq0_line_hold)
261261
262262   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8)   /* verified on pcb */
263263   MCFG_CPU_PROGRAM_MAP(sound_map)
264   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
264   MCFG_CPU_PERIODIC_INT_DRIVER(_1943_state, irq0_line_hold, 4*60)
265265
266266
267267   // video hardware
trunk/src/mame/drivers/psikyo4.c
r17996r17997
191191   return 0x00;
192192}
193193
194static INTERRUPT_GEN(psikyosh_interrupt)
194INTERRUPT_GEN_MEMBER(psikyo4_state::psikyosh_interrupt)
195195{
196   device->execute().set_input_line(4, HOLD_LINE);
196   device.execute().set_input_line(4, HOLD_LINE);
197197}
198198
199199CUSTOM_INPUT_MEMBER(psikyo4_state::system_port_r)
r17996r17997
681681   /* basic machine hardware */
682682   MCFG_CPU_ADD("maincpu", SH2, MASTER_CLOCK/2)
683683   MCFG_CPU_PROGRAM_MAP(ps4_map)
684   MCFG_CPU_VBLANK_INT("lscreen", psikyosh_interrupt)
684   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", psikyo4_state, psikyosh_interrupt)
685685
686686
687687   MCFG_EEPROM_ADD("eeprom", eeprom_interface_93C56)
trunk/src/mame/drivers/pacland.c
r17996r17997
396396   0      /* stereo */
397397};
398398
399static INTERRUPT_GEN( main_vblank_irq )
399INTERRUPT_GEN_MEMBER(pacland_state::main_vblank_irq)
400400{
401   pacland_state *state = device->machine().driver_data<pacland_state>();
402401
403   if(state->m_main_irq_mask)
404      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
402   if(m_main_irq_mask)
403      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
405404}
406405
407static INTERRUPT_GEN( mcu_vblank_irq )
406INTERRUPT_GEN_MEMBER(pacland_state::mcu_vblank_irq)
408407{
409   pacland_state *state = device->machine().driver_data<pacland_state>();
410408
411   if(state->m_mcu_irq_mask)
412      device->machine().device("mcu")->execute().set_input_line(0, ASSERT_LINE);
409   if(m_mcu_irq_mask)
410      machine().device("mcu")->execute().set_input_line(0, ASSERT_LINE);
413411}
414412
415413static MACHINE_CONFIG_START( pacland, pacland_state )
r17996r17997
417415   /* basic machine hardware */
418416   MCFG_CPU_ADD("maincpu", M6809, 49152000/32)   /* 1.536 MHz */
419417   MCFG_CPU_PROGRAM_MAP(main_map)
420   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
418   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacland_state, main_vblank_irq)
421419
422420   MCFG_CPU_ADD("mcu", HD63701, 49152000/8)   /* 1.536 MHz? */
423421   MCFG_CPU_PROGRAM_MAP(mcu_map)
424422   MCFG_CPU_IO_MAP(mcu_port_map)
425   MCFG_CPU_VBLANK_INT("screen", mcu_vblank_irq)
423   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacland_state, mcu_vblank_irq)
426424
427425   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* we need heavy synching between the MCU and the CPU */
428426
trunk/src/mame/drivers/nss.c
r17996r17997
329329   DECLARE_CUSTOM_INPUT_MEMBER(game_over_flag_r);
330330   virtual void machine_start();
331331   virtual void machine_reset();
332   INTERRUPT_GEN_MEMBER(nss_vblank_irq);
332333};
333334
334335
r17996r17997
814815   MCFG_SOUND_ROUTE(1, "rspeaker", 1.00)
815816MACHINE_CONFIG_END
816817
817static INTERRUPT_GEN ( nss_vblank_irq )
818INTERRUPT_GEN_MEMBER(nss_state::nss_vblank_irq)
818819{
819   nss_state *state = device->machine().driver_data<nss_state>();
820
821   if(state->m_nmi_enable)
822      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
820   if(m_nmi_enable)
821      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
823822}
824823
825824void nss_state::machine_reset()
r17996r17997
845844   MCFG_CPU_ADD("bios", Z80, 4000000)
846845   MCFG_CPU_PROGRAM_MAP(bios_map)
847846   MCFG_CPU_IO_MAP(bios_io_map)
848   MCFG_CPU_VBLANK_INT("screen", nss_vblank_irq)
847   MCFG_CPU_VBLANK_INT_DRIVER("screen", nss_state, nss_vblank_irq)
849848
850849   MCFG_M50458_ADD("m50458",m50458_intf,4000000) /* TODO: correct clock */
851850   MCFG_S3520CF_ADD("s3520cf") /* RTC */
trunk/src/mame/drivers/rollrace.c
r17996r17997
208208   GFXDECODE_ENTRY( "gfx5", 0x0000, spritelayout,   0,   32 )
209209GFXDECODE_END
210210
211static INTERRUPT_GEN( vblank_irq )
211INTERRUPT_GEN_MEMBER(rollrace_state::vblank_irq)
212212{
213   rollrace_state *state = device->machine().driver_data<rollrace_state>();
214213
215   if(state->m_nmi_mask)
216      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
214   if(m_nmi_mask)
215      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
217216}
218217
219static INTERRUPT_GEN( sound_timer_irq )
218INTERRUPT_GEN_MEMBER(rollrace_state::sound_timer_irq)
220219{
221   rollrace_state *state = device->machine().driver_data<rollrace_state>();
222220
223   if(state->m_sound_nmi_mask)
224      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
221   if(m_sound_nmi_mask)
222      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
225223}
226224
227225static MACHINE_CONFIG_START( rollrace, rollrace_state )
r17996r17997
229227   /* basic machine hardware */
230228   MCFG_CPU_ADD("maincpu", Z80,XTAL_24MHz/8) /* verified on pcb */
231229   MCFG_CPU_PROGRAM_MAP(rollrace_map)
232   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
230   MCFG_CPU_VBLANK_INT_DRIVER("screen", rollrace_state, vblank_irq)
233231
234232   MCFG_CPU_ADD("audiocpu", Z80,XTAL_24MHz/16) /* verified on pcb */
235233   MCFG_CPU_PROGRAM_MAP(rollrace_sound_map)
236   MCFG_CPU_PERIODIC_INT(sound_timer_irq,4*60)
234   MCFG_CPU_PERIODIC_INT_DRIVER(rollrace_state, sound_timer_irq, 4*60)
237235
238236   /* video hardware */
239237   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/mirage.c
r17996r17997
320320   /* basic machine hardware */
321321   MCFG_CPU_ADD("maincpu", M68000, 28000000/2)
322322   MCFG_CPU_PROGRAM_MAP(mirage_map)
323   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
323   MCFG_CPU_VBLANK_INT_DRIVER("screen", miragemi_state, irq6_line_hold)
324324
325325
326326   /* video hardware */
trunk/src/mame/drivers/popper.c
r17996r17997
328328   m_gfx_bank = 0;
329329}
330330
331static INTERRUPT_GEN( vblank_irq )
331INTERRUPT_GEN_MEMBER(popper_state::vblank_irq)
332332{
333   popper_state *state = device->machine().driver_data<popper_state>();
334333
335   if(state->m_nmi_mask)
336      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
334   if(m_nmi_mask)
335      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
337336}
338337
339338
r17996r17997
342341   /* basic machine hardware */
343342   MCFG_CPU_ADD("maincpu", Z80,18432000/6)
344343   MCFG_CPU_PROGRAM_MAP(popper_map)
345   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
344   MCFG_CPU_VBLANK_INT_DRIVER("screen", popper_state, vblank_irq)
346345
347346   MCFG_CPU_ADD("audiocpu", Z80,18432000/12)
348347   MCFG_CPU_PROGRAM_MAP(popper_sound_map)
349   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)      //NMIs caused by the main CPU
348   MCFG_CPU_PERIODIC_INT_DRIVER(popper_state, irq0_line_hold, 4*60)      //NMIs caused by the main CPU
350349
351350   MCFG_QUANTUM_TIME(attotime::from_hz(1800))
352351
trunk/src/mame/drivers/ladyfrog.c
r17996r17997
306306   /* basic machine hardware */
307307   MCFG_CPU_ADD("maincpu", Z80,8000000/2)
308308   MCFG_CPU_PROGRAM_MAP(ladyfrog_map)
309   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
309   MCFG_CPU_VBLANK_INT_DRIVER("screen", ladyfrog_state, irq0_line_hold)
310310
311311   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)
312312   MCFG_CPU_PROGRAM_MAP(ladyfrog_sound_map)
313   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
313   MCFG_CPU_PERIODIC_INT_DRIVER(ladyfrog_state, irq0_line_hold, 2*60)
314314
315315
316316   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
trunk/src/mame/drivers/djboy.c
r17996r17997
577577   MCFG_CPU_ADD("cpu1", Z80, 6000000)
578578   MCFG_CPU_PROGRAM_MAP(cpu1_am)
579579   MCFG_CPU_IO_MAP(cpu1_port_am)
580   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
580   MCFG_CPU_VBLANK_INT_DRIVER("screen", djboy_state, irq0_line_hold)
581581
582582   MCFG_CPU_ADD("cpu2", Z80, 6000000)
583583   MCFG_CPU_PROGRAM_MAP(cpu2_am)
584584   MCFG_CPU_IO_MAP(cpu2_port_am)
585   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
585   MCFG_CPU_VBLANK_INT_DRIVER("screen", djboy_state, irq0_line_hold)
586586
587587   MCFG_CPU_ADD("beast", I80C51, 6000000)
588588   MCFG_CPU_IO_MAP(djboy_mcu_io_map)
trunk/src/mame/drivers/sidearms.c
r17996r17997
657657   /* basic machine hardware */
658658   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz (?) */
659659   MCFG_CPU_PROGRAM_MAP(sidearms_map)
660   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
660   MCFG_CPU_VBLANK_INT_DRIVER("screen", sidearms_state, irq0_line_hold)
661661
662662   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz (?) */
663663   MCFG_CPU_PROGRAM_MAP(sidearms_sound_map)
r17996r17997
700700   /* basic machine hardware */
701701   MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz (?) */
702702   MCFG_CPU_PROGRAM_MAP(turtship_map)
703   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
703   MCFG_CPU_VBLANK_INT_DRIVER("screen", sidearms_state, irq0_line_hold)
704704
705705   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz (?) */
706706   MCFG_CPU_PROGRAM_MAP(sidearms_sound_map)
r17996r17997
742742   /* basic machine hardware */
743743   MCFG_CPU_ADD("maincpu", Z80, 4000000)        /* 4 MHz (?) */
744744   MCFG_CPU_PROGRAM_MAP(whizz_map)
745   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
745   MCFG_CPU_VBLANK_INT_DRIVER("screen", sidearms_state, irq0_line_hold)
746746
747747   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
748748   MCFG_CPU_PROGRAM_MAP(whizz_sound_map)
749749   MCFG_CPU_IO_MAP(whizz_io_map)
750   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
750   MCFG_CPU_VBLANK_INT_DRIVER("screen", sidearms_state, irq0_line_hold)
751751
752752   MCFG_QUANTUM_TIME(attotime::from_hz(60000))
753753
trunk/src/mame/drivers/taito_x.c
r17996r17997
829829   /* basic machine hardware */
830830   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   /* verified on pcb */
831831   MCFG_CPU_PROGRAM_MAP(superman_map)
832   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
832   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitox_state, irq6_line_hold)
833833
834834   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)   /* verified on pcb */
835835   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
872872   /* basic machine hardware */
873873   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   /* verified on pcb */
874874   MCFG_CPU_PROGRAM_MAP(daisenpu_map)
875   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
875   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitox_state, irq2_line_hold)
876876
877877   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)   /* verified on pcb */
878878   MCFG_CPU_PROGRAM_MAP(daisenpu_sound_map)
r17996r17997
912912   /* basic machine hardware */
913913   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz? */
914914   MCFG_CPU_PROGRAM_MAP(gigandes_map)
915   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
915   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitox_state, irq2_line_hold)
916916
917917   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ??? */
918918   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
954954   /* basic machine hardware */
955955   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz? */
956956   MCFG_CPU_PROGRAM_MAP(ballbros_map)
957   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
957   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitox_state, irq2_line_hold)
958958
959959   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ??? */
960960   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tumblep.c
r17996r17997
307307   /* basic machine hardware */
308308   MCFG_CPU_ADD("maincpu", M68000, 14000000)
309309   MCFG_CPU_PROGRAM_MAP(main_map)
310   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
310   MCFG_CPU_VBLANK_INT_DRIVER("screen", tumblep_state, irq6_line_hold)
311311
312312   MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)   /* Custom chip 45; Audio section crystal is 32.220 MHz */
313313   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/dietgo.c
r17996r17997
208208   /* basic machine hardware */
209209   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2) /* DE102 (verified on pcb) */
210210   MCFG_CPU_PROGRAM_MAP(dietgo_map)
211   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
211   MCFG_CPU_VBLANK_INT_DRIVER("screen", dietgo_state, irq6_line_hold)
212212
213213   MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/4/3)   /* Custom chip 45; XIN is 32.220MHZ/4, verified on pcb */
214214   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/kingobox.c
r17996r17997
442442   DEVCB_DRIVER_MEMBER(driver_device, soundlatch_byte_r)
443443};
444444
445static INTERRUPT_GEN( kingofb_interrupt )
445INTERRUPT_GEN_MEMBER(kingofb_state::kingofb_interrupt)
446446{
447   kingofb_state *state = device->machine().driver_data<kingofb_state>();
448447
449   if (state->m_nmi_enable)
450      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
448   if (m_nmi_enable)
449      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
451450}
452451
453452void kingofb_state::machine_start()
r17996r17997
473472   /* basic machine hardware */
474473   MCFG_CPU_ADD("maincpu", Z80, 4000000)        /* 4.0 MHz */
475474   MCFG_CPU_PROGRAM_MAP(kingobox_map)
476   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
475   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
477476
478477   MCFG_CPU_ADD("video", Z80, 4000000)        /* 4.0 MHz */
479478   MCFG_CPU_PROGRAM_MAP(kingobox_video_map)
480   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
479   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
481480
482481   MCFG_CPU_ADD("sprite", Z80, 4000000)        /* 4.0 MHz */
483482   MCFG_CPU_PROGRAM_MAP(kingobox_sprite_map)
484   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
483   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
485484
486485   MCFG_CPU_ADD("audiocpu", Z80, 4000000)        /* 4.0 MHz */
487486   MCFG_CPU_PROGRAM_MAP(kingobox_sound_map)
488487   MCFG_CPU_IO_MAP(kingobox_sound_io_map)
489   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 6000)   /* Hz */
488   MCFG_CPU_PERIODIC_INT_DRIVER(kingofb_state, nmi_line_pulse, 6000)   /* Hz */
490489
491490   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* We really need heavy synching among the processors */
492491
r17996r17997
523522   /* basic machine hardware */
524523   MCFG_CPU_ADD("maincpu", Z80, 4000000)        /* 4.0 MHz */
525524   MCFG_CPU_PROGRAM_MAP(ringking_map)
526   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
525   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
527526
528527   MCFG_CPU_ADD("video", Z80, 4000000)        /* 4.0 MHz */
529528   MCFG_CPU_PROGRAM_MAP(ringking_video_map)
530   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
529   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
531530
532531   MCFG_CPU_ADD("sprite", Z80, 4000000)        /* 4.0 MHz */
533532   MCFG_CPU_PROGRAM_MAP(ringking_sprite_map)
534   MCFG_CPU_VBLANK_INT("screen", kingofb_interrupt)
533   MCFG_CPU_VBLANK_INT_DRIVER("screen", kingofb_state, kingofb_interrupt)
535534
536535   MCFG_CPU_ADD("audiocpu", Z80, 4000000)        /* 4.0 MHz */
537536   MCFG_CPU_PROGRAM_MAP(kingobox_sound_map)
538537   MCFG_CPU_IO_MAP(ringking_sound_io_map)
539   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 6000)   /* Hz */
538   MCFG_CPU_PERIODIC_INT_DRIVER(kingofb_state, nmi_line_pulse, 6000)   /* Hz */
540539
541540   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* We really need heavy synching among the processors */
542541
trunk/src/mame/drivers/bfmsys85.c
r17996r17997
112112   DECLARE_DRIVER_INIT(decode);
113113   virtual void machine_start();
114114   virtual void machine_reset();
115   INTERRUPT_GEN_MEMBER(timer_irq);
115116};
116117
117118
r17996r17997
185186
186187///////////////////////////////////////////////////////////////////////////
187188
188static INTERRUPT_GEN( timer_irq )
189INTERRUPT_GEN_MEMBER(bfmsys85_state::timer_irq)
189190{
190   bfmsys85_state *state = device->machine().driver_data<bfmsys85_state>();
191   if ( state->m_is_timer_enabled )
191   if ( m_is_timer_enabled )
192192   {
193      state->m_irq_status = 0x01 |0x02; //0xff;
194      generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
193      m_irq_status = 0x01 |0x02; //0xff;
194      generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
195195   }
196196}
197197
r17996r17997
418418static MACHINE_CONFIG_START( bfmsys85, bfmsys85_state )
419419   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4)         // 6809 CPU at 1 Mhz
420420   MCFG_CPU_PROGRAM_MAP(memmap)                  // setup read and write memorymap
421   MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )            // generate 1000 IRQ's per second
421   MCFG_CPU_PERIODIC_INT_DRIVER(bfmsys85_state, timer_irq, 1000)            // generate 1000 IRQ's per second
422422   MCFG_MSC1937_ADD("vfd",0,RIGHT_TO_LEFT)
423423
424424   MCFG_ACIA6850_ADD("acia6850_0", m6809_acia_if)
trunk/src/mame/drivers/esripsys.c
r17996r17997
699699static MACHINE_CONFIG_START( esripsys, esripsys_state )
700700   MCFG_CPU_ADD("game_cpu", M6809E, XTAL_8MHz)
701701   MCFG_CPU_PROGRAM_MAP(game_cpu_map)
702   MCFG_CPU_VBLANK_INT("screen", esripsys_vblank_irq)
702   MCFG_CPU_VBLANK_INT_DRIVER("screen", esripsys_state, esripsys_vblank_irq)
703703
704704   MCFG_CPU_ADD("frame_cpu", M6809E, XTAL_8MHz)
705705   MCFG_CPU_PROGRAM_MAP(frame_cpu_map)
trunk/src/mame/drivers/tsamurai.c
r17996r17997
4646   m_nmi_enabled = data;
4747}
4848
49static INTERRUPT_GEN( samurai_interrupt )
49INTERRUPT_GEN_MEMBER(tsamurai_state::samurai_interrupt)
5050{
51   tsamurai_state *state = device->machine().driver_data<tsamurai_state>();
52   if (state->m_nmi_enabled) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
51   if (m_nmi_enabled) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
5352}
5453
5554READ8_MEMBER(tsamurai_state::unknown_d803_r)
r17996r17997
267266   m_vsgongf_sound_nmi_enabled = data;
268267}
269268
270static INTERRUPT_GEN( vsgongf_sound_interrupt )
269INTERRUPT_GEN_MEMBER(tsamurai_state::vsgongf_sound_interrupt)
271270{
272   tsamurai_state *state = device->machine().driver_data<tsamurai_state>();
273   if (state->m_vsgongf_sound_nmi_enabled) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
271   if (m_vsgongf_sound_nmi_enabled) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
274272}
275273
276274/* what are these, protection of some kind? */
r17996r17997
682680   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/8)
683681   MCFG_CPU_PROGRAM_MAP(main_map)
684682   MCFG_CPU_IO_MAP(z80_io_map)
685   MCFG_CPU_VBLANK_INT("screen", samurai_interrupt)
683   MCFG_CPU_VBLANK_INT_DRIVER("screen", tsamurai_state, samurai_interrupt)
686684
687685   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8)
688686   MCFG_CPU_PROGRAM_MAP(sound1_map)
r17996r17997
723721   /* basic machine hardware */
724722   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/8)
725723   MCFG_CPU_PROGRAM_MAP(vsgongf_map)
726   MCFG_CPU_VBLANK_INT("screen", samurai_interrupt)
724   MCFG_CPU_VBLANK_INT_DRIVER("screen", tsamurai_state, samurai_interrupt)
727725
728726   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8)
729727   MCFG_CPU_PROGRAM_MAP(sound_vsgongf_map)
730728   MCFG_CPU_IO_MAP(vsgongf_audio_io_map)
731   MCFG_CPU_PERIODIC_INT(vsgongf_sound_interrupt,3*60)
729   MCFG_CPU_PERIODIC_INT_DRIVER(tsamurai_state, vsgongf_sound_interrupt, 3*60)
732730
733731   /* video hardware */
734732   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
761759   MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/8)
762760   MCFG_CPU_PROGRAM_MAP(m660_map)
763761   MCFG_CPU_IO_MAP(z80_m660_io_map)
764   MCFG_CPU_VBLANK_INT("screen", samurai_interrupt)
762   MCFG_CPU_VBLANK_INT_DRIVER("screen", tsamurai_state, samurai_interrupt)
765763
766764   MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8)
767765   MCFG_CPU_PROGRAM_MAP(sound1_m660_map)
r17996r17997
772770   MCFG_CPU_ADD("audio3", Z80, XTAL_24MHz/8)
773771   MCFG_CPU_PROGRAM_MAP(sound3_m660_map)
774772   MCFG_CPU_IO_MAP(sound3_m660_io_map)
775   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
773   MCFG_CPU_VBLANK_INT_DRIVER("screen", tsamurai_state, nmi_line_pulse)
776774
777775   /* video hardware */
778776   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ettrivia.c
r17996r17997
6161   virtual void video_start();
6262   virtual void palette_init();
6363   UINT32 screen_update_ettrivia(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
64   INTERRUPT_GEN_MEMBER(ettrivia_interrupt);
6465};
6566
6667
r17996r17997
289290};
290291
291292
292static INTERRUPT_GEN( ettrivia_interrupt )
293INTERRUPT_GEN_MEMBER(ettrivia_state::ettrivia_interrupt)
293294{
294   if( device->machine().root_device().ioport("COIN")->read() & 0x01 )
295      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
295   if( machine().root_device().ioport("COIN")->read() & 0x01 )
296      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
296297   else
297      device->execute().set_input_line(0, HOLD_LINE);
298      device.execute().set_input_line(0, HOLD_LINE);
298299}
299300
300301static MACHINE_CONFIG_START( ettrivia, ettrivia_state )
301302   MCFG_CPU_ADD("maincpu", Z80,12000000/4-48000) //should be ok, it gives the 300 interrupts expected
302303   MCFG_CPU_PROGRAM_MAP(cpu_map)
303304   MCFG_CPU_IO_MAP(io_map)
304   MCFG_CPU_VBLANK_INT("screen", ettrivia_interrupt)
305   MCFG_CPU_VBLANK_INT_DRIVER("screen", ettrivia_state, ettrivia_interrupt)
305306
306307   MCFG_NVRAM_ADD_0FILL("nvram")
307308
trunk/src/mame/drivers/jalmah.c
r17996r17997
14061406static MACHINE_CONFIG_START( jalmah, jalmah_state )
14071407   MCFG_CPU_ADD("maincpu" , M68000, 12000000) /* 68000-8 */
14081408   MCFG_CPU_PROGRAM_MAP(jalmah)
1409   MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
1409   MCFG_CPU_VBLANK_INT_DRIVER("screen", jalmah_state, irq2_line_hold)
14101410
14111411   //M50747 MCU
14121412
trunk/src/mame/drivers/f1gp.c
r17996r17997
451451   /* basic machine hardware */
452452   MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2)   /* verified on pcb */
453453   MCFG_CPU_PROGRAM_MAP(f1gp_cpu1_map)
454   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
454   MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
455455
456456   MCFG_CPU_ADD("sub", M68000,XTAL_20MHz/2)   /* verified on pcb */
457457   MCFG_CPU_PROGRAM_MAP(f1gp_cpu2_map)
458   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
458   MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
459459
460460   MCFG_CPU_ADD("audiocpu", Z80,XTAL_20MHz/4)   /* verified on pcb */
461461   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
497497   /* basic machine hardware */
498498   MCFG_CPU_ADD("maincpu",M68000,10000000)   /* 10 MHz ??? */
499499   MCFG_CPU_PROGRAM_MAP(f1gpb_cpu1_map)
500   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
500   MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
501501
502502   MCFG_CPU_ADD("sub", M68000,10000000)   /* 10 MHz ??? */
503503   MCFG_CPU_PROGRAM_MAP(f1gpb_cpu2_map)
504   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
504   MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
505505
506506   /* NO sound CPU */
507507   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* 100 CPU slices per frame */
trunk/src/mame/drivers/supdrapo.c
r17996r17997
445445
446446   MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)   /* guess */
447447   MCFG_CPU_PROGRAM_MAP(sdpoker_mem)
448   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
448   MCFG_CPU_VBLANK_INT_DRIVER("screen", supdrapo_state, irq0_line_hold)
449449
450450
451451   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/lvcards.c
r17996r17997
465465
466466   MCFG_CPU_PROGRAM_MAP(lvcards_map)
467467   MCFG_CPU_IO_MAP(lvcards_io_map)
468   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
468   MCFG_CPU_VBLANK_INT_DRIVER("screen", lvcards_state, irq0_line_hold)
469469
470470   // video hardware
471471
trunk/src/mame/drivers/namcos2.c
r17996r17997
16061606static MACHINE_CONFIG_START( default, namcos2_state )
16071607   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
16081608   MCFG_CPU_PROGRAM_MAP(master_default_am)
1609   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1609   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
16101610
16111611   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /*  12.288MHz (49.152MHz OSC/4) */
16121612   MCFG_CPU_PROGRAM_MAP(slave_default_am)
1613   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1613   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
16141614
16151615   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
16161616   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1617   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1618   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 120)
1617   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold, 2*60)
1618   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold,  120)
16191619
16201620   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
16211621   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1622   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1622   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
16231623
16241624   MCFG_QUANTUM_TIME(attotime::from_hz(12000)) /* CPU slices per frame */
16251625
r17996r17997
16801680static MACHINE_CONFIG_START( gollygho, namcos2_state )
16811681   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
16821682   MCFG_CPU_PROGRAM_MAP(master_default_am)
1683   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1683   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
16841684
16851685   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
16861686   MCFG_CPU_PROGRAM_MAP(slave_default_am)
1687   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1687   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
16881688
16891689   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
16901690   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1691   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
1692   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 120)
1691   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold,  2*60)
1692   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold,  120)
16931693
16941694   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
16951695   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1696   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1696   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
16971697
16981698   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices per frame */
16991699
r17996r17997
17271727static MACHINE_CONFIG_START( finallap, namcos2_state )
17281728   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
17291729   MCFG_CPU_PROGRAM_MAP(master_finallap_am)
1730   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1730   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
17311731
17321732   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
17331733   MCFG_CPU_PROGRAM_MAP(slave_finallap_am)
1734   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1734   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
17351735
17361736   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
17371737   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1738   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
1739   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 120)
1738   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold,  2*60)
1739   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold,  120)
17401740
17411741   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
17421742   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1743   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1743   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
17441744
17451745   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices per frame */
17461746
r17996r17997
17781778static MACHINE_CONFIG_START( sgunner, namcos2_state )
17791779   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
17801780   MCFG_CPU_PROGRAM_MAP(master_sgunner_am)
1781   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1781   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
17821782
17831783   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
17841784   MCFG_CPU_PROGRAM_MAP(slave_sgunner_am)
1785   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1785   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
17861786
17871787   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
17881788   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1789   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
1790   MCFG_CPU_PERIODIC_INT(irq1_line_hold, 120)
1789   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold,  2*60)
1790   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold,  120)
17911791
17921792   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
17931793   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1794   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1794   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
17951795
17961796   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices per frame */
17971797
r17996r17997
18271827static MACHINE_CONFIG_START( luckywld, namcos2_state )
18281828   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
18291829   MCFG_CPU_PROGRAM_MAP(master_luckywld_am)
1830   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1830   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
18311831
18321832   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
18331833   MCFG_CPU_PROGRAM_MAP(slave_luckywld_am)
1834   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1834   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
18351835
18361836   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
18371837   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1838   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1839   MCFG_CPU_PERIODIC_INT(irq1_line_hold,120)
1838   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold, 2*60)
1839   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold, 120)
18401840
18411841   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
18421842   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1843   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1843   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
18441844
18451845   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices per frame */
18461846
r17996r17997
18781878static MACHINE_CONFIG_START( metlhawk, namcos2_state )
18791879   MCFG_CPU_ADD("maincpu", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
18801880   MCFG_CPU_PROGRAM_MAP(master_metlhawk_am)
1881   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_master_vblank)
1881   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_master_vblank)
18821882
18831883   MCFG_CPU_ADD("slave", M68000, M68K_CPU_CLOCK) /* 12.288MHz (49.152MHz OSC/4) */
18841884   MCFG_CPU_PROGRAM_MAP(slave_metlhawk_am)
1885   MCFG_CPU_VBLANK_INT("screen", namcos2_68k_slave_vblank)
1885   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, namcos2_68k_slave_vblank)
18861886
18871887   MCFG_CPU_ADD("audiocpu", M6809, M68B09_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - Sound handling */
18881888   MCFG_CPU_PROGRAM_MAP(sound_default_am)
1889   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
1890   MCFG_CPU_PERIODIC_INT(irq1_line_hold,120)
1889   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq0_line_hold, 2*60)
1890   MCFG_CPU_PERIODIC_INT_DRIVER(namcos2_shared_state, irq1_line_hold, 120)
18911891
18921892   MCFG_CPU_ADD("mcu", HD63705, C65_CPU_CLOCK) /* 2.048MHz (49.152MHz OSC/24) - I/O handling */
18931893   MCFG_CPU_PROGRAM_MAP(mcu_default_am)
1894   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1894   MCFG_CPU_VBLANK_INT_DRIVER("screen", namcos2_shared_state, irq0_line_hold)
18951895
18961896   MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* CPU slices per frame */
18971897
trunk/src/mame/drivers/exzisus.c
r17996r17997
274274   /* basic machine hardware */
275275   MCFG_CPU_ADD("cpua", Z80, 6000000)
276276   MCFG_CPU_PROGRAM_MAP(cpua_map)
277   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
277   MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
278278
279279   MCFG_CPU_ADD("cpub", Z80, 6000000)
280280   MCFG_CPU_PROGRAM_MAP(cpub_map)
281   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
281   MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
282282
283283   MCFG_CPU_ADD("cpuc", Z80, 6000000)
284284   MCFG_CPU_PROGRAM_MAP(cpuc_map)
285   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
285   MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
286286
287287   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
288288   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/tx1.c
r17996r17997
8181}
8282
8383/* Periodic Z80 interrupt */
84static INTERRUPT_GEN( z80_irq )
84INTERRUPT_GEN_MEMBER(tx1_state::z80_irq)
8585{
86   device->execute().set_input_line(0, HOLD_LINE);
86   device.execute().set_input_line(0, HOLD_LINE);
8787}
8888
8989READ16_MEMBER(tx1_state::z80_shared_r)
r17996r17997
701701   MCFG_CPU_ADD("audio_cpu", Z80, TX1_PIXEL_CLOCK / 2)
702702   MCFG_CPU_PROGRAM_MAP(tx1_sound_prg)
703703   MCFG_CPU_IO_MAP(tx1_sound_io)
704   MCFG_CPU_PERIODIC_INT(irq0_line_hold, TX1_PIXEL_CLOCK / 4 / 2048 / 2)
704   MCFG_CPU_PERIODIC_INT_DRIVER(tx1_state, irq0_line_hold, TX1_PIXEL_CLOCK / 4 / 2048 / 2)
705705
706706   MCFG_MACHINE_RESET_OVERRIDE(tx1_state,tx1)
707707   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
753753
754754   MCFG_CPU_ADD("audio_cpu", Z80, BUGGYBOY_ZCLK / 2)
755755   MCFG_CPU_PROGRAM_MAP(buggyboy_sound_prg)
756   MCFG_CPU_PERIODIC_INT(z80_irq, BUGGYBOY_ZCLK / 2 / 4 / 2048)
756   MCFG_CPU_PERIODIC_INT_DRIVER(tx1_state, z80_irq, BUGGYBOY_ZCLK / 2 / 4 / 2048)
757757   MCFG_CPU_IO_MAP(buggyboy_sound_io)
758758
759759   MCFG_MACHINE_RESET_OVERRIDE(tx1_state,buggyboy)
r17996r17997
808808   MCFG_CPU_ADD("audio_cpu", Z80, BUGGYBOY_ZCLK / 2)
809809   MCFG_CPU_PROGRAM_MAP(buggybjr_sound_prg)
810810   MCFG_CPU_IO_MAP(buggyboy_sound_io)
811   MCFG_CPU_PERIODIC_INT(z80_irq, BUGGYBOY_ZCLK / 2 / 4 / 2048)
811   MCFG_CPU_PERIODIC_INT_DRIVER(tx1_state, z80_irq, BUGGYBOY_ZCLK / 2 / 4 / 2048)
812812
813813   MCFG_MACHINE_RESET_OVERRIDE(tx1_state,buggyboy)
814814   MCFG_NVRAM_ADD_0FILL("nvram")
trunk/src/mame/drivers/ssrj.c
r17996r17997
144144   /* basic machine hardware */
145145   MCFG_CPU_ADD("maincpu", Z80,8000000/2)
146146   MCFG_CPU_PROGRAM_MAP(ssrj_map)
147   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
147   MCFG_CPU_VBLANK_INT_DRIVER("screen", ssrj_state, irq0_line_hold)
148148
149149   /* video hardware */
150150   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gotya.c
r17996r17997
195195   /* basic machine hardware */
196196   MCFG_CPU_ADD("maincpu", Z80,18432000/6)   /* 3.072 MHz ??? */
197197   MCFG_CPU_PROGRAM_MAP(gotya_map)
198   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
198   MCFG_CPU_VBLANK_INT_DRIVER("screen", gotya_state, irq0_line_hold)
199199
200200
201201   /* video hardware */
trunk/src/mame/drivers/cchance.c
r17996r17997
221221
222222   MCFG_CPU_ADD("maincpu", Z80,4000000)       /* ? MHz */
223223   MCFG_CPU_PROGRAM_MAP(main_map)
224   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
224   MCFG_CPU_VBLANK_INT_DRIVER("screen", cchance_state, irq0_line_hold)
225225
226226   MCFG_MACHINE_START_OVERRIDE(cchance_state,cchance)
227227   MCFG_MACHINE_RESET_OVERRIDE(cchance_state,cchance)
trunk/src/mame/drivers/aztarac.c
r17996r17997
149149   /* basic machine hardware */
150150   MCFG_CPU_ADD("maincpu", M68000, 8000000)
151151   MCFG_CPU_PROGRAM_MAP(main_map)
152   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
152   MCFG_CPU_VBLANK_INT_DRIVER("screen", aztarac_state, irq4_line_hold)
153153
154154   MCFG_CPU_ADD("audiocpu", Z80, 2000000)
155155   MCFG_CPU_PROGRAM_MAP(sound_map)
156   MCFG_CPU_PERIODIC_INT(aztarac_snd_timed_irq, 100)
156   MCFG_CPU_PERIODIC_INT_DRIVER(aztarac_state, aztarac_snd_timed_irq, 100)
157157
158158   MCFG_NVRAM_ADD_1FILL("nvram")
159159
trunk/src/mame/drivers/retofinv.c
r17996r17997
328328   GFXDECODE_ENTRY( "gfx3", 0, bglayout,     64*16+256*2,  64 )
329329GFXDECODE_END
330330
331static INTERRUPT_GEN( main_vblank_irq )
331INTERRUPT_GEN_MEMBER(retofinv_state::main_vblank_irq)
332332{
333   retofinv_state *state = device->machine().driver_data<retofinv_state>();
334333
335   if(state->m_main_irq_mask)
336      device->execute().set_input_line(0, ASSERT_LINE);
334   if(m_main_irq_mask)
335      device.execute().set_input_line(0, ASSERT_LINE);
337336}
338337
339static INTERRUPT_GEN( sub_vblank_irq )
338INTERRUPT_GEN_MEMBER(retofinv_state::sub_vblank_irq)
340339{
341   retofinv_state *state = device->machine().driver_data<retofinv_state>();
342340
343   if(state->m_sub_irq_mask)
344      device->execute().set_input_line(0, ASSERT_LINE);
341   if(m_sub_irq_mask)
342      device.execute().set_input_line(0, ASSERT_LINE);
345343}
346344
347345
r17996r17997
367365   /* basic machine hardware */
368366   MCFG_CPU_ADD("maincpu", Z80, 18432000/6)   /* 3.072 MHz? */
369367   MCFG_CPU_PROGRAM_MAP(main_map)
370   MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
368   MCFG_CPU_VBLANK_INT_DRIVER("screen", retofinv_state, main_vblank_irq)
371369
372370   MCFG_CPU_ADD("sub", Z80, 18432000/6)   /* 3.072 MHz? */
373371   MCFG_CPU_PROGRAM_MAP(sub_map)
374   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
372   MCFG_CPU_VBLANK_INT_DRIVER("screen", retofinv_state, sub_vblank_irq)
375373
376374   MCFG_CPU_ADD("audiocpu", Z80, 18432000/6)   /* 3.072 MHz? */
377375   MCFG_CPU_PROGRAM_MAP(sound_map)
378   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,2*60)
376   MCFG_CPU_PERIODIC_INT_DRIVER(retofinv_state, nmi_line_pulse, 2*60)
379377
380378   MCFG_CPU_ADD("68705", M68705,18432000/6)   /* 3.072 MHz? */
381379   MCFG_CPU_PROGRAM_MAP(mcu_map)
trunk/src/mame/drivers/dotrikun.c
r17996r17997
155155   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK)       /* 4 MHz */
156156   MCFG_CPU_PROGRAM_MAP(dotrikun_map)
157157   MCFG_CPU_IO_MAP(io_map)
158   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
158   MCFG_CPU_VBLANK_INT_DRIVER("screen", dotrikun_state, irq0_line_hold)
159159
160160
161161   /* video hardware */
trunk/src/mame/drivers/meadows.c
r17996r17997
209209 *
210210 *************************************/
211211
212static INTERRUPT_GEN( meadows_interrupt )
212INTERRUPT_GEN_MEMBER(meadows_state::meadows_interrupt)
213213{
214   meadows_state *state = device->machine().driver_data<meadows_state>();
215214    /* fake something toggling the sense input line of the S2650 */
216   state->m_main_sense_state ^= 1;
217   device->execute().set_input_line(1, state->m_main_sense_state ? ASSERT_LINE : CLEAR_LINE);
215   m_main_sense_state ^= 1;
216   device.execute().set_input_line(1, m_main_sense_state ? ASSERT_LINE : CLEAR_LINE);
218217}
219218
220219
r17996r17997
225224 *
226225 *************************************/
227226
228static INTERRUPT_GEN( minferno_interrupt )
227INTERRUPT_GEN_MEMBER(meadows_state::minferno_interrupt)
229228{
230   meadows_state *state = device->machine().driver_data<meadows_state>();
231   state->m_main_sense_state++;
232   device->execute().set_input_line(1, (state->m_main_sense_state & 0x40) ? ASSERT_LINE : CLEAR_LINE );
229   m_main_sense_state++;
230   device.execute().set_input_line(1, (m_main_sense_state & 0x40) ? ASSERT_LINE : CLEAR_LINE );
233231}
234232
235233
r17996r17997
307305 *
308306 *************************************/
309307
310static INTERRUPT_GEN( audio_interrupt )
308INTERRUPT_GEN_MEMBER(meadows_state::audio_interrupt)
311309{
312   meadows_state *state = device->machine().driver_data<meadows_state>();
313310    /* fake something toggling the sense input line of the S2650 */
314   state->m_audio_sense_state ^= 1;
315   device->execute().set_input_line(1, state->m_audio_sense_state ? ASSERT_LINE : CLEAR_LINE);
311   m_audio_sense_state ^= 1;
312   device.execute().set_input_line(1, m_audio_sense_state ? ASSERT_LINE : CLEAR_LINE);
316313}
317314
318315
r17996r17997
645642   /* basic machine hardware */
646643   MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/8)   /* 5MHz / 8 = 625 kHz */
647644   MCFG_CPU_PROGRAM_MAP(meadows_main_map)
648   MCFG_CPU_VBLANK_INT("screen", meadows_interrupt)   /* one interrupt per frame!? */
645   MCFG_CPU_VBLANK_INT_DRIVER("screen", meadows_state, meadows_interrupt)   /* one interrupt per frame!? */
649646
650647   MCFG_CPU_ADD("audiocpu", S2650, MASTER_CLOCK/8)    /* 5MHz / 8 = 625 kHz */
651648   MCFG_CPU_PROGRAM_MAP(audio_map)
652   MCFG_CPU_PERIODIC_INT(audio_interrupt, (double)5000000/131072)
649   MCFG_CPU_PERIODIC_INT_DRIVER(meadows_state, audio_interrupt, (double)5000000/131072)
653650
654651   MCFG_QUANTUM_TIME(attotime::from_hz(600))
655652
r17996r17997
681678   MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/24)    /* 5MHz / 8 / 3 = 208.33 kHz */
682679   MCFG_CPU_PROGRAM_MAP(minferno_main_map)
683680   MCFG_CPU_IO_MAP(minferno_io_map)
684   MCFG_CPU_VBLANK_INT("screen", minferno_interrupt)
681   MCFG_CPU_VBLANK_INT_DRIVER("screen", meadows_state, minferno_interrupt)
685682
686683   /* video hardware */
687684   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
702699   /* basic machine hardware */
703700   MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/8)   /* 5MHz / 8 = 625 kHz */
704701   MCFG_CPU_PROGRAM_MAP(bowl3d_main_map)
705   MCFG_CPU_VBLANK_INT("screen", meadows_interrupt)   /* one interrupt per frame!? */
702   MCFG_CPU_VBLANK_INT_DRIVER("screen", meadows_state, meadows_interrupt)   /* one interrupt per frame!? */
706703
707704   MCFG_CPU_ADD("audiocpu", S2650, MASTER_CLOCK/8)    /* 5MHz / 8 = 625 kHz */
708705   MCFG_CPU_PROGRAM_MAP(audio_map)
709   MCFG_CPU_PERIODIC_INT(audio_interrupt, (double)5000000/131072)
706   MCFG_CPU_PERIODIC_INT_DRIVER(meadows_state, audio_interrupt, (double)5000000/131072)
710707
711708   MCFG_QUANTUM_TIME(attotime::from_hz(600))
712709
trunk/src/mame/drivers/spoker.c
r17996r17997
5959   virtual void machine_reset();
6060   virtual void video_start();
6161   UINT32 screen_update_spoker(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
62   INTERRUPT_GEN_MEMBER(spoker_interrupt);
6263};
6364
6465WRITE8_MEMBER(spoker_state::bg_tile_w)
r17996r17997
519520   m_video_enable   =   1;
520521}
521522
522static INTERRUPT_GEN( spoker_interrupt )
523INTERRUPT_GEN_MEMBER(spoker_state::spoker_interrupt)
523524{
524//  spoker_state *state = device->machine().driver_data<spoker_state>();
525525
526   device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
526   device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
527527}
528528
529529static MACHINE_CONFIG_START( spoker, spoker_state )
r17996r17997
532532   MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2)   /* HD64180RP8, 8 MHz? */
533533   MCFG_CPU_PROGRAM_MAP(spoker_map)
534534   MCFG_CPU_IO_MAP(spoker_portmap)
535   MCFG_CPU_VBLANK_INT("screen",spoker_interrupt)
535   MCFG_CPU_VBLANK_INT_DRIVER("screen", spoker_state, spoker_interrupt)
536536
537537
538538   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
564564   MCFG_CPU_MODIFY("maincpu")
565565   MCFG_CPU_PROGRAM_MAP(spoker_map)
566566   MCFG_CPU_IO_MAP(3super8_portmap)
567   MCFG_CPU_VBLANK_INT("screen",spoker_interrupt)
568   MCFG_CPU_PERIODIC_INT(irq0_line_hold,120) // this signal comes from the PIC
567   MCFG_CPU_VBLANK_INT_DRIVER("screen", spoker_state, spoker_interrupt)
568   MCFG_CPU_PERIODIC_INT_DRIVER(spoker_state, irq0_line_hold, 120) // this signal comes from the PIC
569569
570570   MCFG_GFXDECODE(3super8)
571571
trunk/src/mame/drivers/harddriv.c
r17996r17997
13261326   MCFG_CPU_ADD("maincpu", M68010, HARDDRIV_MASTER_CLOCK/4)
13271327   MCFG_CPU_PROGRAM_MAP(driver_68k_map)
13281328   MCFG_CPU_VBLANK_INT("screen", atarigen_video_int_gen)
1329   MCFG_CPU_PERIODIC_INT(hd68k_irq_gen, (double)HARDDRIV_MASTER_CLOCK/16/16/16/16/2)
1329   MCFG_CPU_PERIODIC_INT_DRIVER(harddriv_state, hd68k_irq_gen, (double)HARDDRIV_MASTER_CLOCK/16/16/16/16/2)
13301330
13311331   MCFG_CPU_ADD("gsp", TMS34010, HARDDRIV_GSP_CLOCK)
13321332   MCFG_CPU_PROGRAM_MAP(driver_gsp_map)
trunk/src/mame/drivers/srmp2.c
r17996r17997
11651165   /* basic machine hardware */
11661166   MCFG_CPU_ADD("maincpu", M68000,16000000/2)            /* 8.00 MHz */
11671167   MCFG_CPU_PROGRAM_MAP(srmp2_map)
1168   MCFG_CPU_VBLANK_INT("screen",irq4_line_assert)
1169   MCFG_CPU_PERIODIC_INT(irq2_line_assert,15*60)      /* Interrupt times is not understood */
1168   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp2_state, irq4_line_assert)
1169   MCFG_CPU_PERIODIC_INT_DRIVER(srmp2_state, irq2_line_assert, 15*60)      /* Interrupt times is not understood */
11701170
11711171   MCFG_MACHINE_START_OVERRIDE(srmp2_state,srmp2)
11721172   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
12071207   //      4000000,                /* 4.00 MHz ? */
12081208   MCFG_CPU_PROGRAM_MAP(srmp3_map)
12091209   MCFG_CPU_IO_MAP(srmp3_io_map)
1210   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
1210   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp2_state, irq0_line_assert)
12111211
12121212   MCFG_MACHINE_START_OVERRIDE(srmp2_state,srmp3)
12131213   MCFG_NVRAM_ADD_0FILL("nvram")
r17996r17997
12551255   /* basic machine hardware */
12561256   MCFG_CPU_ADD("maincpu", M68000,16000000/2)            /* 8.00 MHz */
12571257   MCFG_CPU_PROGRAM_MAP(mjyuugi_map)
1258   MCFG_CPU_VBLANK_INT("screen",irq4_line_assert)
1259   MCFG_CPU_PERIODIC_INT(irq2_line_assert,15*60)      /* Interrupt times is not understood */
1258   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp2_state, irq4_line_assert)
1259   MCFG_CPU_PERIODIC_INT_DRIVER(srmp2_state, irq2_line_assert, 15*60)      /* Interrupt times is not understood */
12601260
12611261   MCFG_MACHINE_START_OVERRIDE(srmp2_state,srmp2)
12621262
trunk/src/mame/drivers/ohmygod.c
r17996r17997
319319   /* basic machine hardware */
320320   MCFG_CPU_ADD("maincpu", M68000, 12000000)
321321   MCFG_CPU_PROGRAM_MAP(ohmygod_map)
322   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
322   MCFG_CPU_VBLANK_INT_DRIVER("screen", ohmygod_state, irq1_line_hold)
323323
324324   MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(3))   /* a guess, and certainly wrong */
325325
trunk/src/mame/drivers/snk68.c
r17996r17997
593593   /* basic machine hardware */
594594   MCFG_CPU_ADD("maincpu", M68000, XTAL_18MHz/2) /* verified on pcb */
595595   MCFG_CPU_PROGRAM_MAP(pow_map)
596   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
596   MCFG_CPU_VBLANK_INT_DRIVER("screen", snk68_state, irq1_line_hold)
597597
598598   MCFG_CPU_ADD("soundcpu", Z80, XTAL_8MHz/2) /* verified on pcb */
599599   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/aeroboto.c
r17996r17997
3939}
4040
4141
42static INTERRUPT_GEN( aeroboto_interrupt )
42INTERRUPT_GEN_MEMBER(aeroboto_state::aeroboto_interrupt)
4343{
44   aeroboto_state *state = device->machine().driver_data<aeroboto_state>();
4544
46   if (!state->m_disable_irq)
47      device->execute().set_input_line(0, ASSERT_LINE);
45   if (!m_disable_irq)
46      device.execute().set_input_line(0, ASSERT_LINE);
4847   else
49      state->m_disable_irq--;
48      m_disable_irq--;
5049}
5150
5251READ8_MEMBER(aeroboto_state::aeroboto_irq_ack_r)
r17996r17997
252251   /* basic machine hardware */
253252   MCFG_CPU_ADD("maincpu", M6809, XTAL_10MHz/8) /* verified on pcb */
254253   MCFG_CPU_PROGRAM_MAP(main_map)
255   MCFG_CPU_VBLANK_INT("screen", aeroboto_interrupt)
254   MCFG_CPU_VBLANK_INT_DRIVER("screen", aeroboto_state, aeroboto_interrupt)
256255
257256   MCFG_CPU_ADD("audiocpu", M6809, XTAL_10MHz/16) /* verified on pcb */
258257   MCFG_CPU_PROGRAM_MAP(sound_map)
259   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
258   MCFG_CPU_VBLANK_INT_DRIVER("screen", aeroboto_state, irq0_line_hold)
260259
261260
262261   /* video hardware */
trunk/src/mame/drivers/madalien.c
r17996r17997
178178
179179   MCFG_CPU_ADD("audiocpu", M6502, SOUND_CLOCK / 8)      /* 512kHz */
180180   MCFG_CPU_PROGRAM_MAP(audio_map)
181   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
181   MCFG_CPU_VBLANK_INT_DRIVER("screen", madalien_state, nmi_line_pulse)
182182
183183   /* video hardware */
184184   MCFG_FRAGMENT_ADD(madalien_video)
trunk/src/mame/drivers/firetrap.c
r17996r17997
581581   MSM5205_S48_4B      /* 7.8125kHz          */
582582};
583583
584static INTERRUPT_GEN( firetrap_irq )
584INTERRUPT_GEN_MEMBER(firetrap_state::firetrap_irq)
585585{
586   firetrap_state *state = device->machine().driver_data<firetrap_state>();
587586
588   if (state->m_nmi_enable)
589      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
587   if (m_nmi_enable)
588      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
590589}
591590
592591
r17996r17997
643642   /* basic machine hardware */
644643   MCFG_CPU_ADD("maincpu", Z80, FIRETRAP_XTAL/2)      // 6 MHz
645644   MCFG_CPU_PROGRAM_MAP(firetrap_map)
646   MCFG_CPU_VBLANK_INT("screen",firetrap_irq)
645   MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrap_state, firetrap_irq)
647646
648647   MCFG_CPU_ADD("audiocpu", M6502, FIRETRAP_XTAL/8)   // 1.5 MHz
649648   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
679678   /* basic machine hardware */
680679   MCFG_CPU_ADD("maincpu", Z80, FIRETRAP_XTAL/2)      // 6 MHz
681680   MCFG_CPU_PROGRAM_MAP(firetrap_bootleg_map)
682   MCFG_CPU_VBLANK_INT("screen", firetrap_irq)
681   MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrap_state, firetrap_irq)
683682
684683   MCFG_CPU_ADD("audiocpu", M6502, FIRETRAP_XTAL/8)   // 1.5 MHz
685684   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/thedeep.c
r17996r17997
437437   }
438438}
439439
440static INTERRUPT_GEN( thedeep_mcu_irq )
440INTERRUPT_GEN_MEMBER(thedeep_state::thedeep_mcu_irq)
441441{
442   thedeep_state *state = device->machine().driver_data<thedeep_state>();
443442
444   state->m_mcu->set_input_line(MCS51_INT1_LINE, ASSERT_LINE);
443   m_mcu->set_input_line(MCS51_INT1_LINE, ASSERT_LINE);
445444}
446445
447446static MACHINE_CONFIG_START( thedeep, thedeep_state )
r17996r17997
458457   /* MCU is a i8751 running at 8Mhz (8mhz xtal)*/
459458   MCFG_CPU_ADD("mcu", I8751, XTAL_8MHz)
460459   MCFG_CPU_IO_MAP(mcu_io_map)
461   MCFG_CPU_VBLANK_INT("screen",thedeep_mcu_irq ) // unknown source, but presumably vblank
460   MCFG_CPU_VBLANK_INT_DRIVER("screen", thedeep_state, thedeep_mcu_irq) // unknown source, but presumably vblank
462461   MCFG_DEVICE_DISABLE()
463462
464463
trunk/src/mame/drivers/oneshot.c
r17996r17997
372372   /* basic machine hardware */
373373   MCFG_CPU_ADD("maincpu", M68000, 12000000)
374374   MCFG_CPU_PROGRAM_MAP(oneshot_map)
375   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
375   MCFG_CPU_VBLANK_INT_DRIVER("screen", oneshot_state, irq4_line_hold)
376376
377377   MCFG_CPU_ADD("audiocpu", Z80, 5000000)
378378   MCFG_CPU_PROGRAM_MAP(oneshot_sound_map)
trunk/src/mame/drivers/stlforce.c
r17996r17997
191191   /* basic machine hardware */
192192   MCFG_CPU_ADD("maincpu", M68000, 15000000)
193193   MCFG_CPU_PROGRAM_MAP(stlforce_map)
194   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
194   MCFG_CPU_VBLANK_INT_DRIVER("screen", stlforce_state, irq4_line_hold)
195195
196196   MCFG_EEPROM_93C46_ADD("eeprom")
197197
trunk/src/mame/drivers/zr107.c
r17996r17997
207207   DECLARE_VIDEO_START(jetwave);
208208   UINT32 screen_update_zr107(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
209209   UINT32 screen_update_jetwave(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
210   INTERRUPT_GEN_MEMBER(zr107_vblank);
210211};
211212
212213
r17996r17997
716717    DMA0
717718
718719*/
719static INTERRUPT_GEN( zr107_vblank )
720INTERRUPT_GEN_MEMBER(zr107_state::zr107_vblank)
720721{
721   device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
722   device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
722723}
723724
724725void zr107_state::machine_reset()
r17996r17997
731732   /* basic machine hardware */
732733   MCFG_CPU_ADD("maincpu", PPC403GA, 64000000/2)   /* PowerPC 403GA 32MHz */
733734   MCFG_CPU_PROGRAM_MAP(zr107_map)
734   MCFG_CPU_VBLANK_INT("screen", zr107_vblank)
735   MCFG_CPU_VBLANK_INT_DRIVER("screen", zr107_state, zr107_vblank)
735736
736737   MCFG_CPU_ADD("audiocpu", M68000, 64000000/8)   /* 8MHz */
737738   MCFG_CPU_PROGRAM_MAP(sound_memmap)
r17996r17997
787788   /* basic machine hardware */
788789   MCFG_CPU_ADD("maincpu", PPC403GA, 64000000/2)   /* PowerPC 403GA 32MHz */
789790   MCFG_CPU_PROGRAM_MAP(jetwave_map)
790   MCFG_CPU_VBLANK_INT("screen", zr107_vblank)
791   MCFG_CPU_VBLANK_INT_DRIVER("screen", zr107_state, zr107_vblank)
791792
792793   MCFG_CPU_ADD("audiocpu", M68000, 64000000/8)   /* 8MHz */
793794   MCFG_CPU_PROGRAM_MAP(sound_memmap)
trunk/src/mame/drivers/flipjack.c
r17996r17997
478478   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
479479   MCFG_CPU_PROGRAM_MAP(flipjack_main_map)
480480   MCFG_CPU_IO_MAP(flipjack_main_io_map)
481   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
481   MCFG_CPU_VBLANK_INT_DRIVER("screen", flipjack_state, irq0_line_hold)
482482
483483   MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK/4)
484484   MCFG_CPU_PROGRAM_MAP(flipjack_sound_map)
485485   MCFG_CPU_IO_MAP(flipjack_sound_io_map)
486   MCFG_CPU_VBLANK_INT("screen", nmi_line_assert)
486   MCFG_CPU_VBLANK_INT_DRIVER("screen", flipjack_state, nmi_line_assert)
487487
488488   MCFG_I8255A_ADD( "ppi8255", ppi8255_intf )
489489
trunk/src/mame/drivers/dominob.c
r17996r17997
299299   MCFG_CPU_ADD("maincpu", Z80,XTAL_12MHz/2)
300300   MCFG_CPU_PROGRAM_MAP(memmap)
301301   MCFG_CPU_IO_MAP(portmap)
302   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
302   MCFG_CPU_VBLANK_INT_DRIVER("screen", dominob_state, irq0_line_hold)
303303
304304   /* video hardware */
305305   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/srumbler.c
r17996r17997
243243
244244   MCFG_CPU_ADD("audiocpu", Z80, 3000000)        /* 3 MHz ??? */
245245   MCFG_CPU_PROGRAM_MAP(srumbler_sound_map)
246   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
246   MCFG_CPU_PERIODIC_INT_DRIVER(srumbler_state, irq0_line_hold, 4*60)
247247
248248
249249   /* video hardware */
trunk/src/mame/drivers/bwidow.c
r17996r17997
696696   /* basic machine hardware */
697697   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK / 8)
698698   MCFG_CPU_PROGRAM_MAP(bwidow_map)
699   MCFG_CPU_PERIODIC_INT(irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
699   MCFG_CPU_PERIODIC_INT_DRIVER(bwidow_state, irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
700700
701701   MCFG_ATARIVGEAROM_ADD("earom")
702702
trunk/src/mame/drivers/mcr68.c
r17996r17997
965965   /* basic machine hardware */
966966   MCFG_CPU_ADD("maincpu", M68000, 7652400)   /* should be XTAL_16MHz/2 */
967967   MCFG_CPU_PROGRAM_MAP(zwackery_map)
968   MCFG_CPU_VBLANK_INT("screen", mcr68_interrupt)
968   MCFG_CPU_VBLANK_INT_DRIVER("screen", mcr68_state, mcr68_interrupt)
969969
970970//  MCFG_WATCHDOG_VBLANK_INIT(8)
971971   MCFG_MACHINE_START_OVERRIDE(mcr68_state,zwackery)
r17996r17997
10001000   /* basic machine hardware */
10011001   MCFG_CPU_ADD("maincpu", M68000, 7723800)
10021002   MCFG_CPU_PROGRAM_MAP(mcr68_map)
1003   MCFG_CPU_VBLANK_INT("screen", mcr68_interrupt)
1003   MCFG_CPU_VBLANK_INT_DRIVER("screen", mcr68_state, mcr68_interrupt)
10041004
10051005   MCFG_WATCHDOG_VBLANK_INIT(8)
10061006   MCFG_MACHINE_START_OVERRIDE(mcr68_state,mcr68)
trunk/src/mame/drivers/pbaction.c
r17996r17997
249249GFXDECODE_END
250250
251251
252static INTERRUPT_GEN( pbaction_interrupt )
252INTERRUPT_GEN_MEMBER(pbaction_state::pbaction_interrupt)
253253{
254   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x02);   /* the CPU is in Interrupt Mode 2 */
254   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x02);   /* the CPU is in Interrupt Mode 2 */
255255}
256256
257257
r17996r17997
270270   m_scroll = 0;
271271}
272272
273static INTERRUPT_GEN( vblank_irq )
273INTERRUPT_GEN_MEMBER(pbaction_state::vblank_irq)
274274{
275   pbaction_state *state = device->machine().driver_data<pbaction_state>();
276275
277   if(state->m_nmi_mask)
278      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
276   if(m_nmi_mask)
277      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
279278}
280279
281280static MACHINE_CONFIG_START( pbaction, pbaction_state )
r17996r17997
283282   /* basic machine hardware */
284283   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4 MHz? */
285284   MCFG_CPU_PROGRAM_MAP(pbaction_map)
286   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
285   MCFG_CPU_VBLANK_INT_DRIVER("screen", pbaction_state, vblank_irq)
287286
288287   MCFG_CPU_ADD("audiocpu", Z80, 3072000)
289288   MCFG_CPU_PROGRAM_MAP(pbaction_sound_map)
290289   MCFG_CPU_IO_MAP(pbaction_sound_io_map)
291   MCFG_CPU_PERIODIC_INT(pbaction_interrupt,2*60)   /* ??? */
290   MCFG_CPU_PERIODIC_INT_DRIVER(pbaction_state, pbaction_interrupt, 2*60)   /* ??? */
292291                           /* IRQs are caused by the main CPU */
293292
294293
trunk/src/mame/drivers/funworld.c
r17996r17997
23522352    /* basic machine hardware */
23532353   MCFG_CPU_ADD("maincpu", M65SC02, MASTER_CLOCK/8)   /* 2MHz */
23542354   MCFG_CPU_PROGRAM_MAP(funworld_map)
2355   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2355   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
23562356
23572357   MCFG_NVRAM_ADD_0FILL("nvram")
23582358
r17996r17997
23882388
23892389   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
23902390   MCFG_CPU_PROGRAM_MAP(funworld_map)
2391   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2391   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
23922392
23932393   MCFG_GFXDECODE(fw2ndpal)
23942394MACHINE_CONFIG_END
r17996r17997
24002400
24012401   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24022402   MCFG_CPU_PROGRAM_MAP(funquiz_map)
2403   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2403   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24042404
24052405   MCFG_SOUND_REPLACE("ay8910", AY8910, MASTER_CLOCK/8)   /* 2MHz */
24062406   MCFG_SOUND_CONFIG(funquiz_ay8910_intf)
r17996r17997
24122412
24132413   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24142414   MCFG_CPU_PROGRAM_MAP(magicrd2_map)
2415   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2415   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24162416
24172417   MCFG_VIDEO_START_OVERRIDE(funworld_state,magicrd2)
24182418
r17996r17997
24252425
24262426   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* (G65SC02P in pro version) 2MHz */
24272427   MCFG_CPU_PROGRAM_MAP(magicrd2_map)
2428   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2428   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24292429MACHINE_CONFIG_END
24302430
24312431static MACHINE_CONFIG_DERIVED( royalcd2, fw2ndpal )
24322432
24332433   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24342434   MCFG_CPU_PROGRAM_MAP(magicrd2_map)
2435   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2435   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24362436MACHINE_CONFIG_END
24372437
24382438static MACHINE_CONFIG_DERIVED( cuoreuno, fw1stpal )
24392439
24402440   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24412441   MCFG_CPU_PROGRAM_MAP(cuoreuno_map)
2442   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2442   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24432443MACHINE_CONFIG_END
24442444
24452445static MACHINE_CONFIG_DERIVED( saloon, fw1stpal )
24462446
24472447   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24482448   MCFG_CPU_PROGRAM_MAP(saloon_map)
2449   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2449   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24502450MACHINE_CONFIG_END
24512451
24522452static MACHINE_CONFIG_DERIVED( witchryl, fw1stpal )
24532453
24542454   MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8)   /* 2MHz */
24552455   MCFG_CPU_PROGRAM_MAP(witchryl_map)
2456   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2456   MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
24572457MACHINE_CONFIG_END
24582458
24592459
trunk/src/mame/drivers/overdriv.c
r17996r17997
8686      timer.machine().device("maincpu")->execute().set_input_line(5, HOLD_LINE);
8787}
8888
89static INTERRUPT_GEN( cpuB_interrupt )
89INTERRUPT_GEN_MEMBER(overdriv_state::cpuB_interrupt)
9090{
91   overdriv_state *state = device->machine().driver_data<overdriv_state>();
9291
93   if (k053246_is_irq_enabled(state->m_k053246))
94      device->execute().set_input_line(4, HOLD_LINE);
92   if (k053246_is_irq_enabled(m_k053246))
93      device.execute().set_input_line(4, HOLD_LINE);
9594}
9695
9796
r17996r17997
333332
334333   MCFG_CPU_ADD("sub", M68000,24000000/2)   /* 12 MHz */
335334   MCFG_CPU_PROGRAM_MAP(overdriv_slave_map)
336   MCFG_CPU_VBLANK_INT("screen", cpuB_interrupt)   /* IRQ 5 and 6 are generated by the main CPU. */
335   MCFG_CPU_VBLANK_INT_DRIVER("screen", overdriv_state, cpuB_interrupt)   /* IRQ 5 and 6 are generated by the main CPU. */
337336                                       /* IRQ 5 is used only in test mode, to request the checksums of the gfx ROMs. */
338337
339338   MCFG_CPU_ADD("audiocpu", M6809,3579545)      /* 1.789 MHz?? This might be the right speed, but ROM testing */
trunk/src/mame/drivers/jackpool.c
r17996r17997
3838   DECLARE_DRIVER_INIT(jackpool);
3939   virtual void video_start();
4040   UINT32 screen_update_jackpool(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
41   INTERRUPT_GEN_MEMBER(jackpool_interrupt);
4142};
4243
4344
r17996r17997
248249
249250
250251/*irq 2 used for communication stuff.3 is just a rte*/
251static INTERRUPT_GEN( jackpool_interrupt )
252INTERRUPT_GEN_MEMBER(jackpool_state::jackpool_interrupt)
252253{
253   device->execute().set_input_line(1, HOLD_LINE);
254   device.execute().set_input_line(1, HOLD_LINE);
254255}
255256
256257
257258static MACHINE_CONFIG_START( jackpool, jackpool_state )
258259   MCFG_CPU_ADD("maincpu", M68000, 12000000) // ?
259260   MCFG_CPU_PROGRAM_MAP(jackpool_mem)
260   MCFG_CPU_VBLANK_INT("screen",jackpool_interrupt)  // ?
261   MCFG_CPU_VBLANK_INT_DRIVER("screen", jackpool_state, jackpool_interrupt)  // ?
261262
262263   MCFG_GFXDECODE(jackpool)
263264
trunk/src/mame/drivers/spcforce.c
r17996r17997
253253};
254254
255255
256static INTERRUPT_GEN( vblank_irq )
256INTERRUPT_GEN_MEMBER(spcforce_state::vblank_irq)
257257{
258   spcforce_state *state = device->machine().driver_data<spcforce_state>();
259258
260   if(state->m_irq_mask)
261      device->execute().set_input_line(3, HOLD_LINE);
259   if(m_irq_mask)
260      device.execute().set_input_line(3, HOLD_LINE);
262261}
263262
264263static MACHINE_CONFIG_START( spcforce, spcforce_state )
r17996r17997
267266   /* FIXME: The 8085A had a max clock of 6MHz, internally divided by 2! */
268267   MCFG_CPU_ADD("maincpu", I8085A, 8000000 * 2)        /* 4.00 MHz??? */
269268   MCFG_CPU_PROGRAM_MAP(spcforce_map)
270   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
269   MCFG_CPU_VBLANK_INT_DRIVER("screen", spcforce_state, vblank_irq)
271270
272271   MCFG_CPU_ADD("audiocpu", I8035, 6144000)      /* divisor ??? */
273272   MCFG_CPU_PROGRAM_MAP(spcforce_sound_map)
trunk/src/mame/drivers/gsword.c
r17996r17997
247247   josvolly_8741_reset();
248248}
249249
250static INTERRUPT_GEN( gsword_snd_interrupt )
250INTERRUPT_GEN_MEMBER(gsword_state::gsword_snd_interrupt)
251251{
252   gsword_state *state = device->machine().driver_data<gsword_state>();
253252
254   if(state->m_nmi_enable)
255      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
253   if(m_nmi_enable)
254      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
256255}
257256
258257WRITE8_MEMBER(gsword_state::gsword_nmi_set_w)
r17996r17997
661660   MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz/6) /* verified on pcb */
662661   MCFG_CPU_PROGRAM_MAP(cpu1_map)
663662   MCFG_CPU_IO_MAP(cpu1_io_map)
664   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
663   MCFG_CPU_VBLANK_INT_DRIVER("screen", gsword_state, irq0_line_hold)
665664
666665   MCFG_CPU_ADD("sub", Z80, XTAL_18MHz/6) /* verified on pcb */
667666   MCFG_CPU_PROGRAM_MAP(cpu2_map)
668667   MCFG_CPU_IO_MAP(cpu2_io_map)
669   MCFG_CPU_PERIODIC_INT(gsword_snd_interrupt,4*60)
668   MCFG_CPU_PERIODIC_INT_DRIVER(gsword_state, gsword_snd_interrupt, 4*60)
670669
671670   MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/6) /* verified on pcb */
672671   MCFG_CPU_PROGRAM_MAP(cpu3_map)
r17996r17997
714713   MCFG_CPU_ADD("maincpu", Z80, 18000000/6) /* ? */
715714   MCFG_CPU_PROGRAM_MAP(cpu1_map)
716715   MCFG_CPU_IO_MAP(josvolly_cpu1_io_map)
717   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
716   MCFG_CPU_PERIODIC_INT_DRIVER(gsword_state, irq0_line_hold, 2*60)
718717
719718   MCFG_CPU_ADD("audiocpu", Z80, 12000000/4) /* ? */
720719   MCFG_CPU_PROGRAM_MAP(josvolly_cpu2_map)
721720   MCFG_CPU_IO_MAP(josvolly_cpu2_io_map)
722   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
721   MCFG_CPU_VBLANK_INT_DRIVER("screen", gsword_state, irq0_line_hold)
723722
724723   MCFG_MACHINE_RESET_OVERRIDE(gsword_state,josvolly)
725724
trunk/src/mame/drivers/nmg5.c
r17996r17997
10101010   /* basic machine hardware */
10111011   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz */
10121012   MCFG_CPU_PROGRAM_MAP(nmg5_map)
1013   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
1013   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmg5_state, irq6_line_hold)
10141014
10151015   MCFG_CPU_ADD("soundcpu", Z80, 4000000)      /* 4 MHz */
10161016   MCFG_CPU_PROGRAM_MAP(nmg5_sound_map)
trunk/src/mame/drivers/mario.c
r17996r17997
323323 *
324324 *************************************/
325325
326static INTERRUPT_GEN( vblank_irq )
326INTERRUPT_GEN_MEMBER(mario_state::vblank_irq)
327327{
328   mario_state *state = device->machine().driver_data<mario_state>();
329328
330   if(state->m_nmi_mask)
331      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
329   if(m_nmi_mask)
330      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
332331}
333332
334333static MACHINE_CONFIG_START( mario_base, mario_state )
r17996r17997
337336   MCFG_CPU_ADD("maincpu", Z80, Z80_CLOCK)   /* verified on pcb */
338337   MCFG_CPU_PROGRAM_MAP(mario_map)
339338   MCFG_CPU_IO_MAP(mario_io_map)
340   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
339   MCFG_CPU_VBLANK_INT_DRIVER("screen", mario_state, vblank_irq)
341340
342341   /* devices */
343342   MCFG_Z80DMA_ADD("z80dma", Z80_CLOCK, mario_dma)
trunk/src/mame/drivers/wink.c
r17996r17997
4343   virtual void machine_reset();
4444   virtual void video_start();
4545   UINT32 screen_update_wink(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
46   INTERRUPT_GEN_MEMBER(wink_sound);
4647};
4748
4849
r17996r17997
329330};
330331
331332//AY portA is fed by an input clock at 15625 Hz
332static INTERRUPT_GEN( wink_sound )
333INTERRUPT_GEN_MEMBER(wink_state::wink_sound)
333334{
334   wink_state *state = device->machine().driver_data<wink_state>();
335   state->m_sound_flag ^= 0x80;
335   m_sound_flag ^= 0x80;
336336}
337337
338338void wink_state::machine_reset()
r17996r17997
345345   MCFG_CPU_ADD("maincpu", Z80, 12000000 / 4)
346346   MCFG_CPU_PROGRAM_MAP(wink_map)
347347   MCFG_CPU_IO_MAP(wink_io)
348   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
348   MCFG_CPU_VBLANK_INT_DRIVER("screen", wink_state, nmi_line_pulse)
349349
350350   MCFG_CPU_ADD("audiocpu", Z80, 12000000 / 8)
351351   MCFG_CPU_PROGRAM_MAP(wink_sound_map)
352352   MCFG_CPU_IO_MAP(wink_sound_io)
353   MCFG_CPU_PERIODIC_INT(wink_sound, 15625)
353   MCFG_CPU_PERIODIC_INT_DRIVER(wink_state, wink_sound, 15625)
354354
355355   MCFG_NVRAM_ADD_1FILL("nvram")
356356
trunk/src/mame/drivers/atarifb.c
r17996r17997
555555   /* basic machine hardware */
556556   MCFG_CPU_ADD("maincpu", M6502, 750000)
557557   MCFG_CPU_PROGRAM_MAP(atarifb_map)
558   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
558   MCFG_CPU_PERIODIC_INT_DRIVER(atarifb_state, irq0_line_hold, 4*60)
559559
560560
561561   /* video hardware */
trunk/src/mame/drivers/silkroad.c
r17996r17997
283283   /* basic machine hardware */
284284   MCFG_CPU_ADD("maincpu", M68EC020, 16000000)
285285   MCFG_CPU_PROGRAM_MAP(cpu_map)
286   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
286   MCFG_CPU_VBLANK_INT_DRIVER("screen", silkroad_state, irq4_line_hold)
287287
288288   /* video hardware */
289289   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/lethal.c
r17996r17997
203203   ioport("EEPROMOUT")->write(m_cur_control2, 0xff);
204204}
205205
206static INTERRUPT_GEN(lethalen_interrupt)
206INTERRUPT_GEN_MEMBER(lethal_state::lethalen_interrupt)
207207{
208   lethal_state *state = device->machine().driver_data<lethal_state>();
209208
210   if (k056832_is_irq_enabled(state->m_k056832, 0))
211      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
209   if (k056832_is_irq_enabled(m_k056832, 0))
210      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
212211}
213212
214213WRITE8_MEMBER(lethal_state::sound_cmd_w)
r17996r17997
645644   /* basic machine hardware */
646645   MCFG_CPU_ADD("maincpu", HD6309, MAIN_CLOCK/2)    /* verified on pcb */
647646   MCFG_CPU_PROGRAM_MAP(le_main)
648   MCFG_CPU_VBLANK_INT("screen", lethalen_interrupt)
647   MCFG_CPU_VBLANK_INT_DRIVER("screen", lethal_state, lethalen_interrupt)
649648
650649   MCFG_CPU_ADD("soundcpu", Z80, MAIN_CLOCK/4)  /* verified on pcb */
651650   MCFG_CPU_PROGRAM_MAP(le_sound)
trunk/src/mame/drivers/exprraid.c
r17996r17997
446446};
447447
448448#if 0
449static INTERRUPT_GEN( exprraid_interrupt )
449INTERRUPT_GEN_MEMBER(exprraid_state::exprraid_interrupt)
450450{
451   exprraid_state *state = device->machine().driver_data<exprraid_state>();
452451
453   if ((~state->ioport("IN2")->read()) & 0xc0)
452   if ((~ioport("IN2")->read()) & 0xc0)
454453   {
455      if (state->m_coin == 0)
454      if (m_coin == 0)
456455      {
457         state->m_coin = 1;
458         //device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
459         device->execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
456         m_coin = 1;
457         //device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
458         device.execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
460459      }
461460   }
462461   else
463462   {
464      device->execute().set_input_line(DECO16_IRQ_LINE, CLEAR_LINE);
465      state->m_coin = 0;
463      device.execute().set_input_line(DECO16_IRQ_LINE, CLEAR_LINE);
464      m_coin = 0;
466465   }
467466}
468467#endif
trunk/src/mame/drivers/tecmo16.c
r17996r17997
378378   /* basic machine hardware */
379379   MCFG_CPU_ADD("maincpu", M68000,24000000/2)         /* 12MHz */
380380   MCFG_CPU_PROGRAM_MAP(fstarfrc_map)
381   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
381   MCFG_CPU_VBLANK_INT_DRIVER("screen", tecmo16_state, irq5_line_hold)
382382
383383   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)         /* 4MHz */
384384   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/invqix.c
r17996r17997
315315   MCFG_CPU_ADD("maincpu", H8S2394, XTAL_20MHz)
316316   MCFG_CPU_PROGRAM_MAP(invqix_prg_map)
317317   MCFG_CPU_IO_MAP(invqix_io_map)
318   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
319   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 60)
318   MCFG_CPU_VBLANK_INT_DRIVER("screen", invqix_state,  irq1_line_hold)
319   MCFG_CPU_PERIODIC_INT_DRIVER(invqix_state, irq0_line_hold,  60)
320320
321321   /* video hardware */
322322   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/2mindril.c
r17996r17997
6363   DECLARE_DRIVER_INIT(drill);
6464   DECLARE_MACHINE_START(drill);
6565   DECLARE_MACHINE_RESET(drill);
66   INTERRUPT_GEN_MEMBER(drill_vblank_irq);
67   //INTERRUPT_GEN_MEMBER(drill_device_irq);
6668};
6769
6870
r17996r17997
399401GFXDECODE_END
400402
401403
402static INTERRUPT_GEN( drill_vblank_irq )
404INTERRUPT_GEN_MEMBER(_2mindril_state::drill_vblank_irq)
403405{
404   device->execute().set_input_line(4, ASSERT_LINE);
406   device.execute().set_input_line(4, ASSERT_LINE);
405407}
406408
407409#if 0
408static INTERRUPT_GEN( drill_device_irq )
410INTERRUPT_GEN_MEMBER(_2mindril_state::drill_device_irq)
409411{
410   device->execute().set_input_line(5, ASSERT_LINE);
412   device.execute().set_input_line(5, ASSERT_LINE);
411413}
412414#endif
413415
r17996r17997
445447
446448   MCFG_CPU_ADD("maincpu", M68000, 16000000 )
447449   MCFG_CPU_PROGRAM_MAP(drill_map)
448   MCFG_CPU_VBLANK_INT("screen", drill_vblank_irq)
449   //MCFG_CPU_PERIODIC_INT(drill_device_irq,60)
450   MCFG_CPU_VBLANK_INT_DRIVER("screen", _2mindril_state,  drill_vblank_irq)
451   //MCFG_CPU_PERIODIC_INT_DRIVER(_2mindril_state, drill_device_irq, 60)
450452   MCFG_GFXDECODE(2mindril)
451453
452454   MCFG_MACHINE_START_OVERRIDE(_2mindril_state,drill)
trunk/src/mame/drivers/corona.c
r17996r17997
13581358   MCFG_CPU_ADD("maincpu", Z80, WC81_MAIN_XTAL/8)   /* measured */
13591359   MCFG_CPU_PROGRAM_MAP(winner81_map)
13601360   MCFG_CPU_IO_MAP(winner81_cpu_io_map)
1361   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1361   MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
13621362
13631363   MCFG_CPU_ADD("soundcpu", Z80, WC81_MAIN_XTAL/10)   /* measured */
13641364   MCFG_CPU_PROGRAM_MAP(winner81_sound_map)
13651365   MCFG_CPU_IO_MAP(winner81_sound_cpu_io_map)
1366   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
1366   MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
13671367
13681368   MCFG_NVRAM_ADD_0FILL("nvram")
13691369
r17996r17997
13901390   MCFG_CPU_ADD("maincpu", Z80, WC82_MAIN_XTAL/8)   /* measured */
13911391   MCFG_CPU_PROGRAM_MAP(winner82_map)
13921392   MCFG_CPU_IO_MAP(winner82_cpu_io_map)
1393   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1393   MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
13941394
13951395   MCFG_CPU_ADD("soundcpu", Z80, WC82_MAIN_XTAL/8)   /* measured */
13961396   MCFG_CPU_PROGRAM_MAP(winner82_sound_map)      /* IM1 instead of NMI */
r17996r17997
14201420   MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14211421   MCFG_CPU_PROGRAM_MAP(re800_map)
14221422   MCFG_CPU_IO_MAP(re800_cpu_io_map)
1423   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1423   MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
14241424
14251425   MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14261426   MCFG_CPU_PROGRAM_MAP(re800_sound_map)
14271427   MCFG_CPU_IO_MAP(re800_sound_cpu_io_map)
1428   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
1428   MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
14291429
14301430   MCFG_NVRAM_ADD_0FILL("nvram")
14311431
r17996r17997
14511451   MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14521452   MCFG_CPU_PROGRAM_MAP(re800_map)
14531453   MCFG_CPU_IO_MAP(re800_cpu_io_map)
1454   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1454   MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
14551455
14561456   MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14571457   MCFG_CPU_PROGRAM_MAP(winner82_sound_map)      /* IM1 instead of NMI */
r17996r17997
14811481   MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14821482   MCFG_CPU_PROGRAM_MAP(luckyrlt_map)
14831483   MCFG_CPU_IO_MAP(luckyrlt_cpu_io_map)
1484   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
1484   MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
14851485
14861486   MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8)   /* measured 2MHz */
14871487   MCFG_CPU_PROGRAM_MAP(luckyrlt_sound_map)
14881488   MCFG_CPU_IO_MAP(luckyrlt_sound_cpu_io_map)
1489   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
1489   MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244)   /* 244 Hz (1MHz/16/16/16) */
14901490
14911491   MCFG_NVRAM_ADD_0FILL("nvram")
14921492
trunk/src/mame/drivers/taito_z.c
r17996r17997
10361036
10371037/***** Routines for particular games *****/
10381038
1039static INTERRUPT_GEN( sci_interrupt )
1039INTERRUPT_GEN_MEMBER(taitoz_state::sci_interrupt)
10401040{
10411041   /* Need 2 int4's per int6 else (-$6b63,A5) never set to 1 which
10421042       causes all sprites to vanish! Spriteram has areas for 2 frames
10431043       so in theory only needs updating every other frame. */
10441044
1045   taitoz_state *state = device->machine().driver_data<taitoz_state>();
1046   state->m_sci_int6 = !state->m_sci_int6;
1045   m_sci_int6 = !m_sci_int6;
10471046
1048   if (state->m_sci_int6)
1049      device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000 - 500), FUNC(taitoz_interrupt6));
1047   if (m_sci_int6)
1048      machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000 - 500), FUNC(taitoz_interrupt6));
10501049
1051   device->execute().set_input_line(4, HOLD_LINE);
1050   device.execute().set_input_line(4, HOLD_LINE);
10521051}
10531052
10541053
r17996r17997
30763075   /* basic machine hardware */
30773076   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
30783077   MCFG_CPU_PROGRAM_MAP(contcirc_map)
3079   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
3078   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq6_line_hold)
30803079
30813080   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
30823081   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
30833082
30843083   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
30853084   MCFG_CPU_PROGRAM_MAP(contcirc_cpub_map)
3086   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
3085   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq6_line_hold)
30873086
30883087   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
30893088   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
31383137   /* basic machine hardware */
31393138   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
31403139   MCFG_CPU_PROGRAM_MAP(chasehq_map)
3141   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3140   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
31423141
31433142   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
31443143   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
31453144
31463145   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
31473146   MCFG_CPU_PROGRAM_MAP(chq_cpub_map)
3148   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3147   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
31493148
31503149   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
31513150   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
32003199   /* basic machine hardware */
32013200   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
32023201   MCFG_CPU_PROGRAM_MAP(enforce_map)
3203   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
3202   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq6_line_hold)
32043203
32053204   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
32063205   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
32073206
32083207   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
32093208   MCFG_CPU_PROGRAM_MAP(enforce_cpub_map)
3210   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
3209   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq6_line_hold)
32113210
32123211   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
32133212   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
32633262   /* basic machine hardware */
32643263   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
32653264   MCFG_CPU_PROGRAM_MAP(bshark_map)
3266   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3265   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
32673266
32683267   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
32693268   MCFG_CPU_PROGRAM_MAP(bshark_cpub_map)
3270   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3269   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
32713270
32723271   MCFG_MACHINE_START_OVERRIDE(taitoz_state,bshark)
32733272   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
33313330   /* basic machine hardware */
33323331   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
33333332   MCFG_CPU_PROGRAM_MAP(sci_map)
3334   MCFG_CPU_VBLANK_INT("screen", sci_interrupt)
3333   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, sci_interrupt)
33353334
33363335   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
33373336   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
33383337
33393338   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
33403339   MCFG_CPU_PROGRAM_MAP(sci_cpub_map)
3341   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3340   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
33423341
33433342   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
33443343   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
33933392   /* basic machine hardware */
33943393   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
33953394   MCFG_CPU_PROGRAM_MAP(nightstr_map)
3396   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3395   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
33973396
33983397   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
33993398   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
34003399
34013400   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
34023401   MCFG_CPU_PROGRAM_MAP(nightstr_cpub_map)
3403   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3402   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
34043403
34053404   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
34063405   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
34573456   /* basic machine hardware */
34583457   MCFG_CPU_ADD("maincpu", M68000, 12000000)   /* 12 MHz ??? */
34593458   MCFG_CPU_PROGRAM_MAP(aquajack_map)
3460   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3459   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
34613460
34623461   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ??? */
34633462   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
34643463
34653464   MCFG_CPU_ADD("sub", M68000, 12000000)   /* 12 MHz ??? */
34663465   MCFG_CPU_PROGRAM_MAP(aquajack_cpub_map)
3467   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3466   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
34683467
34693468   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
34703469   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
35203519   /* basic machine hardware */
35213520   MCFG_CPU_ADD("maincpu", M68000, 16000000)   /* 16 MHz ??? */
35223521   MCFG_CPU_PROGRAM_MAP(spacegun_map)
3523   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3522   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
35243523
35253524   MCFG_CPU_ADD("sub", M68000, 16000000)   /* 16 MHz ??? */
35263525   MCFG_CPU_PROGRAM_MAP(spacegun_cpub_map)
3527   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3526   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
35283527
35293528   MCFG_MACHINE_START_OVERRIDE(taitoz_state,bshark)
35303529   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
35793578   /* basic machine hardware */
35803579   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
35813580   MCFG_CPU_PROGRAM_MAP(dblaxle_map)
3582   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3581   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
35833582
35843583   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)
35853584   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
35863585
35873586   MCFG_CPU_ADD("sub", M68000, XTAL_32MHz/2)
35883587   MCFG_CPU_PROGRAM_MAP(dblaxle_cpub_map)
3589   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3588   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
35903589
35913590   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
35923591   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
r17996r17997
36413640   /* basic machine hardware */
36423641   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)
36433642   MCFG_CPU_PROGRAM_MAP(racingb_map)
3644   MCFG_CPU_VBLANK_INT("screen", sci_interrupt)
3643   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, sci_interrupt)
36453644
36463645   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/8)
36473646   MCFG_CPU_PROGRAM_MAP(z80_sound_map)
36483647
36493648   MCFG_CPU_ADD("sub", M68000, XTAL_32MHz/2)
36503649   MCFG_CPU_PROGRAM_MAP(racingb_cpub_map)
3651   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3650   MCFG_CPU_VBLANK_INT_DRIVER("screen", taitoz_state, irq4_line_hold)
36523651
36533652   MCFG_MACHINE_START_OVERRIDE(taitoz_state,taitoz)
36543653   MCFG_MACHINE_RESET_OVERRIDE(taitoz_state,taitoz)
trunk/src/mame/drivers/scotrsht.c
r17996r17997
4646   flip_screen_set(data & 0x08);
4747}
4848
49static INTERRUPT_GEN( scotrsht_interrupt )
49INTERRUPT_GEN_MEMBER(scotrsht_state::scotrsht_interrupt)
5050{
51   scotrsht_state *state = device->machine().driver_data<scotrsht_state>();
5251
53   if (state->m_irq_enable)
54      device->execute().set_input_line(0, HOLD_LINE);
52   if (m_irq_enable)
53      device.execute().set_input_line(0, HOLD_LINE);
5554}
5655
5756WRITE8_MEMBER(scotrsht_state::scotrsht_soundlatch_w)
r17996r17997
185184   /* basic machine hardware */
186185   MCFG_CPU_ADD("maincpu", M6809, 18432000/6)        /* 3.072 MHz */
187186   MCFG_CPU_PROGRAM_MAP(scotrsht_map)
188   MCFG_CPU_VBLANK_INT("screen", scotrsht_interrupt)
187   MCFG_CPU_VBLANK_INT_DRIVER("screen", scotrsht_state, scotrsht_interrupt)
189188
190189   MCFG_CPU_ADD("audiocpu", Z80, 18432000/6)        /* 3.072 MHz */
191190   MCFG_CPU_PROGRAM_MAP(scotrsht_sound_map)
trunk/src/mame/drivers/gunbustr.c
r17996r17997
5757   machine.device("maincpu")->execute().set_input_line(5, HOLD_LINE);
5858}
5959
60static INTERRUPT_GEN( gunbustr_interrupt )
60INTERRUPT_GEN_MEMBER(gunbustr_state::gunbustr_interrupt)
6161{
62   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(200000-500), FUNC(gunbustr_interrupt5));
63   device->execute().set_input_line(4, HOLD_LINE);
62   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(200000-500), FUNC(gunbustr_interrupt5));
63   device.execute().set_input_line(4, HOLD_LINE);
6464}
6565
6666WRITE32_MEMBER(gunbustr_state::gunbustr_palette_w)
r17996r17997
305305   /* basic machine hardware */
306306   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_16MHz)
307307   MCFG_CPU_PROGRAM_MAP(gunbustr_map)
308   MCFG_CPU_VBLANK_INT("screen", gunbustr_interrupt) /* VBL */
308   MCFG_CPU_VBLANK_INT_DRIVER("screen", gunbustr_state, gunbustr_interrupt) /* VBL */
309309
310310   MCFG_EEPROM_ADD("eeprom", gunbustr_eeprom_interface)
311311
trunk/src/mame/drivers/msisaac.c
r17996r17997
478478   /* basic machine hardware */
479479   MCFG_CPU_ADD("maincpu", Z80, 4000000)
480480   MCFG_CPU_PROGRAM_MAP(msisaac_map)
481   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
481   MCFG_CPU_VBLANK_INT_DRIVER("screen", msisaac_state, irq0_line_hold)
482482
483483   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
484484   MCFG_CPU_PROGRAM_MAP(msisaac_sound_map)
485   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)   /* source of IRQs is unknown */
485   MCFG_CPU_VBLANK_INT_DRIVER("screen", msisaac_state, irq0_line_hold)   /* source of IRQs is unknown */
486486
487487#ifdef USE_MCU
488488   MCFG_CPU_ADD("mcu", M68705,8000000/2)  /* 4 MHz */
trunk/src/mame/drivers/playch10.c
r17996r17997
656656   GFXDECODE_ENTRY( "gfx1", 0, bios_charlayout,   0,  32 )
657657GFXDECODE_END
658658
659static INTERRUPT_GEN( playch10_interrupt ) {
660   playch10_state *state = device->machine().driver_data<playch10_state>();
659INTERRUPT_GEN_MEMBER(playch10_state::playch10_interrupt){
661660
662661   /* LS161A, Sheet 1 - bottom left of Z80 */
663   if ( !state->m_pc10_dog_di && !state->m_pc10_nmi_enable ) {
664      device->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE );
662   if ( !m_pc10_dog_di && !m_pc10_nmi_enable ) {
663      device.execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE );
665664   }
666665
667   else if ( state->m_pc10_nmi_enable )
668      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
666   else if ( m_pc10_nmi_enable )
667      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
669668}
670669
671670static const nes_interface nes_config =
r17996r17997
679678   MCFG_CPU_ADD("maincpu", Z80, 8000000/2)   // 4 MHz
680679   MCFG_CPU_PROGRAM_MAP(bios_map)
681680   MCFG_CPU_IO_MAP(bios_io_map)
682   MCFG_CPU_VBLANK_INT("top", playch10_interrupt)
681   MCFG_CPU_VBLANK_INT_DRIVER("top", playch10_state, playch10_interrupt)
683682
684683   MCFG_CPU_ADD("cart", N2A03, N2A03_DEFAULTCLOCK)
685684   MCFG_CPU_PROGRAM_MAP(cart_map)
trunk/src/mame/drivers/mappy.c
r17996r17997
763763   }
764764}
765765
766static INTERRUPT_GEN( superpac_main_vblank_irq )
766INTERRUPT_GEN_MEMBER(mappy_state::superpac_main_vblank_irq)
767767{
768   mappy_state *state = device->machine().driver_data<mappy_state>();
769   device_t *namcoio_1 = device->machine().device("namcoio_1");
770   device_t *namcoio_2 = device->machine().device("namcoio_2");
768   device_t *namcoio_1 = machine().device("namcoio_1");
769   device_t *namcoio_2 = machine().device("namcoio_2");
771770
772   if (state->m_main_irq_mask)
773      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
771   if (m_main_irq_mask)
772      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
774773
775774   if (!namcoio_read_reset_line(namcoio_1))      /* give the cpu a tiny bit of time to write the command before processing it */
776      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(superpac_io_run));
775      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(superpac_io_run));
777776
778777   if (!namcoio_read_reset_line(namcoio_2))      /* give the cpu a tiny bit of time to write the command before processing it */
779      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(superpac_io_run), 1);
778      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(superpac_io_run), 1);
780779}
781780
782781static TIMER_CALLBACK( pacnpal_io_run )
r17996r17997
795794   }
796795}
797796
798static INTERRUPT_GEN( pacnpal_main_vblank_irq )
797INTERRUPT_GEN_MEMBER(mappy_state::pacnpal_main_vblank_irq)
799798{
800   mappy_state *state = device->machine().driver_data<mappy_state>();
801   device_t *namcoio_1 = device->machine().device("namcoio_1");
802   device_t *namcoio_2 = device->machine().device("namcoio_2");
799   device_t *namcoio_1 = machine().device("namcoio_1");
800   device_t *namcoio_2 = machine().device("namcoio_2");
803801
804   if (state->m_main_irq_mask)
805      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
802   if (m_main_irq_mask)
803      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
806804
807805   if (!namcoio_read_reset_line(namcoio_1))      /* give the cpu a tiny bit of time to write the command before processing it */
808      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(pacnpal_io_run));
806      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(pacnpal_io_run));
809807
810808   if (!namcoio_read_reset_line(namcoio_2))      /* give the cpu a tiny bit of time to write the command before processing it */
811      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(pacnpal_io_run), 1);
809      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(pacnpal_io_run), 1);
812810}
813811
814812static TIMER_CALLBACK( phozon_io_run )
r17996r17997
827825   }
828826}
829827
830static INTERRUPT_GEN( phozon_main_vblank_irq )
828INTERRUPT_GEN_MEMBER(mappy_state::phozon_main_vblank_irq)
831829{
832   mappy_state *state = device->machine().driver_data<mappy_state>();
833   device_t *namcoio_1 = device->machine().device("namcoio_1");
834   device_t *namcoio_2 = device->machine().device("namcoio_2");
830   device_t *namcoio_1 = machine().device("namcoio_1");
831   device_t *namcoio_2 = machine().device("namcoio_2");
835832
836   if (state->m_main_irq_mask)
837      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
833   if (m_main_irq_mask)
834      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
838835
839836   if (!namcoio_read_reset_line(namcoio_1))      /* give the cpu a tiny bit of time to write the command before processing it */
840      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(phozon_io_run));
837      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(phozon_io_run));
841838
842839   if (!namcoio_read_reset_line(namcoio_2))      /* give the cpu a tiny bit of time to write the command before processing it */
843      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(phozon_io_run), 1);
840      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(phozon_io_run), 1);
844841}
845842
846843static TIMER_CALLBACK( mappy_io_run )
r17996r17997
859856   }
860857}
861858
862static INTERRUPT_GEN( mappy_main_vblank_irq )
859INTERRUPT_GEN_MEMBER(mappy_state::mappy_main_vblank_irq)
863860{
864   mappy_state *state = device->machine().driver_data<mappy_state>();
865   device_t *namcoio_1 = device->machine().device("namcoio_1");
866   device_t *namcoio_2 = device->machine().device("namcoio_2");
861   device_t *namcoio_1 = machine().device("namcoio_1");
862   device_t *namcoio_2 = machine().device("namcoio_2");
867863
868   if(state->m_main_irq_mask)
869      device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
864   if(m_main_irq_mask)
865      machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
870866
871867   if (!namcoio_read_reset_line(namcoio_1))      /* give the cpu a tiny bit of time to write the command before processing it */
872      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(mappy_io_run));
868      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(mappy_io_run));
873869
874870   if (!namcoio_read_reset_line(namcoio_2))      /* give the cpu a tiny bit of time to write the command before processing it */
875      device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(mappy_io_run), 1);
871      machine().scheduler().timer_set(attotime::from_usec(50), FUNC(mappy_io_run), 1);
876872}
877873
878static INTERRUPT_GEN( sub_vblank_irq )
874INTERRUPT_GEN_MEMBER(mappy_state::sub_vblank_irq)
879875{
880   mappy_state *state = device->machine().driver_data<mappy_state>();
881876
882   if(state->m_sub_irq_mask)
883      device->machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
877   if(m_sub_irq_mask)
878      machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
884879}
885880
886static INTERRUPT_GEN( sub2_vblank_irq )
881INTERRUPT_GEN_MEMBER(mappy_state::sub2_vblank_irq)
887882{
888   mappy_state *state = device->machine().driver_data<mappy_state>();
889883
890   if(state->m_sub2_irq_mask)
891      device->machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
884   if(m_sub2_irq_mask)
885      machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
892886}
893887
894888static ADDRESS_MAP_START( superpac_cpu1_map, AS_PROGRAM, 8, mappy_state )
r17996r17997
16311625   /* basic machine hardware */
16321626   MCFG_CPU_ADD("maincpu", M6809, PIXEL_CLOCK/4)   /* 1.536 MHz */
16331627   MCFG_CPU_PROGRAM_MAP(superpac_cpu1_map)
1634   MCFG_CPU_VBLANK_INT("screen", superpac_main_vblank_irq)   // also update the custom I/O chips
1628   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, superpac_main_vblank_irq)   // also update the custom I/O chips
16351629
16361630   MCFG_CPU_ADD("sub", M6809, PIXEL_CLOCK/4)   /* 1.536 MHz */
16371631   MCFG_CPU_PROGRAM_MAP(superpac_cpu2_map)
1638   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1632   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, sub_vblank_irq)
16391633
16401634   MCFG_WATCHDOG_VBLANK_INIT(8)
16411635   MCFG_QUANTUM_TIME(attotime::from_hz(6000))    /* 100 CPU slices per frame - an high value to ensure proper */
r17996r17997
16691663
16701664   /* basic machine hardware */
16711665   MCFG_CPU_MODIFY("maincpu")
1672   MCFG_CPU_VBLANK_INT("screen", pacnpal_main_vblank_irq)   // also update the custom I/O chips
1666   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, pacnpal_main_vblank_irq)   // also update the custom I/O chips
16731667
16741668   MCFG_DEVICE_REMOVE("namcoio_1")
16751669   MCFG_DEVICE_REMOVE("namcoio_2")
r17996r17997
16821676
16831677   /* basic machine hardware */
16841678   MCFG_CPU_MODIFY("maincpu")
1685   MCFG_CPU_VBLANK_INT("screen", phozon_main_vblank_irq)   // also update the custom I/O chips
1679   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, phozon_main_vblank_irq)   // also update the custom I/O chips
16861680
16871681   MCFG_DEVICE_REMOVE("namcoio_1")
16881682   MCFG_DEVICE_REMOVE("namcoio_2")
r17996r17997
17001694   /* basic machine hardware */
17011695   MCFG_CPU_ADD("maincpu", M6809,   PIXEL_CLOCK/4)   /* MAIN CPU */
17021696   MCFG_CPU_PROGRAM_MAP(phozon_cpu1_map)
1703   MCFG_CPU_VBLANK_INT("screen", phozon_main_vblank_irq)   // also update the custom I/O chips
1697   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, phozon_main_vblank_irq)   // also update the custom I/O chips
17041698
17051699   MCFG_CPU_ADD("sub", M6809,   PIXEL_CLOCK/4)   /* SOUND CPU */
17061700   MCFG_CPU_PROGRAM_MAP(phozon_cpu2_map)
1707   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1701   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, sub_vblank_irq)
17081702
17091703   MCFG_CPU_ADD("sub2", M6809,   PIXEL_CLOCK/4)   /* SUB CPU */
17101704   MCFG_CPU_PROGRAM_MAP(phozon_cpu3_map)
1711   MCFG_CPU_VBLANK_INT("screen", sub2_vblank_irq)
1705   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, sub2_vblank_irq)
17121706
17131707   MCFG_WATCHDOG_VBLANK_INIT(8)
17141708   MCFG_QUANTUM_TIME(attotime::from_hz(6000))    /* 100 CPU slices per frame - an high value to ensure proper */
r17996r17997
17441738   /* basic machine hardware */
17451739   MCFG_CPU_ADD("maincpu", M6809, PIXEL_CLOCK/4)   /* 1.536 MHz */
17461740   MCFG_CPU_PROGRAM_MAP(mappy_cpu1_map)
1747   MCFG_CPU_VBLANK_INT("screen", mappy_main_vblank_irq)   // also update the custom I/O chips
1741   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, mappy_main_vblank_irq)   // also update the custom I/O chips
17481742
17491743   MCFG_CPU_ADD("sub", M6809, PIXEL_CLOCK/4)   /* 1.536 MHz */
17501744   MCFG_CPU_PROGRAM_MAP(mappy_cpu2_map)
1751   MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
1745   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, sub_vblank_irq)
17521746
17531747   MCFG_WATCHDOG_VBLANK_INIT(8)
17541748   MCFG_QUANTUM_TIME(attotime::from_hz(6000))    /* 100 CPU slices per frame - an high value to ensure proper */
r17996r17997
17821776
17831777   /* basic machine hardware */
17841778   MCFG_CPU_MODIFY("maincpu")
1785   MCFG_CPU_VBLANK_INT("screen", phozon_main_vblank_irq)   // also update the custom I/O chips
1779   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, phozon_main_vblank_irq)   // also update the custom I/O chips
17861780
17871781   MCFG_WATCHDOG_VBLANK_INIT(0)
17881782
r17996r17997
17961790
17971791   /* basic machine hardware */
17981792   MCFG_CPU_MODIFY("maincpu")
1799   MCFG_CPU_VBLANK_INT("screen", phozon_main_vblank_irq)   // also update the custom I/O chips
1793   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, phozon_main_vblank_irq)   // also update the custom I/O chips
18001794
18011795   MCFG_DEVICE_REMOVE("namcoio_1")
18021796   MCFG_DEVICE_REMOVE("namcoio_2")
r17996r17997
18121806
18131807   /* basic machine hardware */
18141808   MCFG_CPU_MODIFY("maincpu")
1815   MCFG_CPU_VBLANK_INT("screen", superpac_main_vblank_irq)   // also update the custom I/O chips
1809   MCFG_CPU_VBLANK_INT_DRIVER("screen", mappy_state, superpac_main_vblank_irq)   // also update the custom I/O chips
18161810
18171811   MCFG_DEVICE_REMOVE("namcoio_1")
18181812   MCFG_DEVICE_REMOVE("namcoio_2")
trunk/src/mame/drivers/rastan.c
r17996r17997
407407   /* basic machine hardware */
408408   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   /* verified on pcb */
409409   MCFG_CPU_PROGRAM_MAP(rastan_map)
410   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
410   MCFG_CPU_VBLANK_INT_DRIVER("screen", rastan_state, irq5_line_hold)
411411
412412   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)   /* verified on pcb */
413413   MCFG_CPU_PROGRAM_MAP(rastan_s_map)
trunk/src/mame/drivers/pzletime.c
r17996r17997
324324   /* basic machine hardware */
325325   MCFG_CPU_ADD("maincpu",M68000,10000000)
326326   MCFG_CPU_PROGRAM_MAP(pzletime_map)
327   MCFG_CPU_VBLANK_INT("screen",irq4_line_hold)
327   MCFG_CPU_VBLANK_INT_DRIVER("screen", pzletime_state, irq4_line_hold)
328328
329329
330330   /* video hardware */
trunk/src/mame/drivers/tmspoker.c
r17996r17997
233233   virtual void video_start();
234234   virtual void palette_init();
235235   UINT32 screen_update_tmspoker(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
236   INTERRUPT_GEN_MEMBER(tmspoker_interrupt);
236237};
237238
238239
r17996r17997
285286//  popmessage("written : %02X", data);
286287//}
287288
288static INTERRUPT_GEN( tmspoker_interrupt )
289INTERRUPT_GEN_MEMBER(tmspoker_state::tmspoker_interrupt)
289290{
290   device->execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
291   device.execute().set_input_line_and_vector(0, ASSERT_LINE, 3);//2=nmi  3,4,5,6
291292}
292293
293294
r17996r17997
568569   MCFG_CPU_ADD("maincpu", TMS9980L, MASTER_CLOCK/4)   /* guess */
569570   MCFG_CPU_PROGRAM_MAP(tmspoker_map)
570571   MCFG_CPU_IO_MAP(tmspoker_cru_map)
571   MCFG_CPU_VBLANK_INT("screen", tmspoker_interrupt)
572   MCFG_CPU_VBLANK_INT_DRIVER("screen", tmspoker_state, tmspoker_interrupt)
572573
573574//  MCFG_NVRAM_HANDLER(generic_0fill)
574575
trunk/src/mame/drivers/mirax.c
r17996r17997
130130   DECLARE_DRIVER_INIT(mirax);
131131   virtual void palette_init();
132132   UINT32 screen_update_mirax(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
133   INTERRUPT_GEN_MEMBER(mirax_vblank_irq);
133134};
134135
135136
r17996r17997
444445GFXDECODE_END
445446
446447
447static INTERRUPT_GEN( mirax_vblank_irq )
448INTERRUPT_GEN_MEMBER(mirax_state::mirax_vblank_irq)
448449{
449   mirax_state *state = device->machine().driver_data<mirax_state>();
450   if(state->m_nmi_mask)
451      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
450   if(m_nmi_mask)
451      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
452452}
453453
454454static MACHINE_CONFIG_START( mirax, mirax_state )
455455   MCFG_CPU_ADD("maincpu", Z80, 12000000/4) // ceramic potted module, encrypted z80
456456   MCFG_CPU_PROGRAM_MAP(mirax_main_map)
457   MCFG_CPU_VBLANK_INT("screen",mirax_vblank_irq)
457   MCFG_CPU_VBLANK_INT_DRIVER("screen", mirax_state, mirax_vblank_irq)
458458
459459   MCFG_CPU_ADD("audiocpu", Z80, 12000000/4)
460460   MCFG_CPU_PROGRAM_MAP(mirax_sound_map)
461   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
461   MCFG_CPU_PERIODIC_INT_DRIVER(mirax_state, irq0_line_hold, 4*60)
462462
463463   /* video hardware */
464464   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/gradius3.c
r17996r17997
9999      m_irqBmask = (data >> 8) & 0x07;
100100}
101101
102static INTERRUPT_GEN( cpuA_interrupt )
102INTERRUPT_GEN_MEMBER(gradius3_state::cpuA_interrupt)
103103{
104   gradius3_state *state = device->machine().driver_data<gradius3_state>();
105   if (state->m_irqAen)
106      device->execute().set_input_line(2, HOLD_LINE);
104   if (m_irqAen)
105      device.execute().set_input_line(2, HOLD_LINE);
107106}
108107
109108
r17996r17997
317316   /* basic machine hardware */
318317   MCFG_CPU_ADD("maincpu", M68000, 10000000)   /* 10 MHz */
319318   MCFG_CPU_PROGRAM_MAP(gradius3_map)
320   MCFG_CPU_VBLANK_INT("screen", cpuA_interrupt)
319   MCFG_CPU_VBLANK_INT_DRIVER("screen", gradius3_state, cpuA_interrupt)
321320
322321   MCFG_CPU_ADD("sub", M68000, 10000000)   /* 10 MHz */
323322   MCFG_CPU_PROGRAM_MAP(gradius3_map2)
trunk/src/mame/drivers/cardline.c
r17996r17997
218218   MCFG_CPU_ADD("maincpu", I80C32,12000000)
219219   MCFG_CPU_PROGRAM_MAP(mem_prg)
220220   MCFG_CPU_IO_MAP(mem_io)
221   //MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
221   //MCFG_CPU_VBLANK_INT_DRIVER("screen", cardline_state, irq1_line_hold)
222222
223223   /* video hardware */
224224   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/omegrace.c
r17996r17997
491491   MCFG_CPU_ADD("maincpu", Z80,12000000/4)
492492   MCFG_CPU_PROGRAM_MAP(main_map)
493493   MCFG_CPU_IO_MAP(port_map)
494   MCFG_CPU_PERIODIC_INT(irq0_line_hold,250)
494   MCFG_CPU_PERIODIC_INT_DRIVER(omegrace_state, irq0_line_hold, 250)
495495
496496   /* audio CPU */
497497   /* XTAL101 Crystal @ 12mhz */
r17996r17997
500500   MCFG_CPU_ADD("audiocpu", Z80,12000000/8)
501501   MCFG_CPU_PROGRAM_MAP(sound_map)
502502   MCFG_CPU_IO_MAP(sound_port)
503   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,250)
503   MCFG_CPU_PERIODIC_INT_DRIVER(omegrace_state, nmi_line_pulse, 250)
504504
505505   MCFG_NVRAM_ADD_0FILL("nvram")
506506
trunk/src/mame/drivers/mystwarr.c
r17996r17997
152152      state->m_maincpu->set_input_line(M68K_IRQ_2, HOLD_LINE);
153153}
154154
155static INTERRUPT_GEN(ddd_interrupt)
155INTERRUPT_GEN_MEMBER(mystwarr_state::ddd_interrupt)
156156{
157   device->execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
157   device.execute().set_input_line(M68K_IRQ_5, HOLD_LINE);
158158}
159159
160160
r17996r17997
990990
991991   MCFG_CPU_ADD("soundcpu", Z80, 8000000)
992992   MCFG_CPU_PROGRAM_MAP(mystwarr_sound_map)
993   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 480)
993   MCFG_CPU_PERIODIC_INT_DRIVER(mystwarr_state, nmi_line_pulse, 480)
994994
995995   MCFG_QUANTUM_TIME(attotime::from_hz(1920))
996996
r17996r17997
10831083   /* basic machine hardware */
10841084   MCFG_CPU_MODIFY("maincpu")
10851085   MCFG_CPU_PROGRAM_MAP(dadandrn_map)
1086   MCFG_CPU_VBLANK_INT("screen", ddd_interrupt)
1086   MCFG_CPU_VBLANK_INT_DRIVER("screen", mystwarr_state, ddd_interrupt)
10871087   MCFG_DEVICE_REMOVE("scantimer")
10881088
10891089   MCFG_DEVICE_REMOVE("k053252")
r17996r17997
11091109   /* basic machine hardware */
11101110   MCFG_CPU_MODIFY("maincpu")
11111111   MCFG_CPU_PROGRAM_MAP(gaiapols_map)
1112   MCFG_CPU_VBLANK_INT("screen", ddd_interrupt)
1112   MCFG_CPU_VBLANK_INT_DRIVER("screen", mystwarr_state, ddd_interrupt)
11131113   MCFG_DEVICE_REMOVE("scantimer")
11141114
11151115   MCFG_DEVICE_REMOVE("k053252")
trunk/src/mame/drivers/dlair.c
r17996r17997
114114   DECLARE_MACHINE_RESET(dlair);
115115   DECLARE_PALETTE_INIT(dleuro);
116116   UINT32 screen_update_dleuro(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
117   INTERRUPT_GEN_MEMBER(vblank_callback);
117118};
118119
119120
r17996r17997
277278 *
278279 *************************************/
279280
280static INTERRUPT_GEN( vblank_callback )
281INTERRUPT_GEN_MEMBER(dlair_state::vblank_callback)
281282{
282283   /* also update the speaker on the European version */
283   beep_device *beep = device->machine().device<beep_device>("beep");
284   beep_device *beep = machine().device<beep_device>("beep");
284285   if (beep != NULL)
285286   {
286      z80ctc_device *ctc = device->machine().device<z80ctc_device>("ctc");
287      z80ctc_device *ctc = machine().device<z80ctc_device>("ctc");
287288      beep_set_state(beep, 1);
288289      beep_set_frequency(beep, ATTOSECONDS_TO_HZ(ctc->period(0).attoseconds));
289290   }
r17996r17997
723724   /* basic machine hardware */
724725   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK_US/4)
725726   MCFG_CPU_PROGRAM_MAP(dlus_map)
726   MCFG_CPU_VBLANK_INT("screen", vblank_callback)
727   MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)MASTER_CLOCK_US/8/16/16/16/16)
727   MCFG_CPU_VBLANK_INT_DRIVER("screen", dlair_state,  vblank_callback)
728   MCFG_CPU_PERIODIC_INT_DRIVER(dlair_state, irq0_line_hold,  (double)MASTER_CLOCK_US/8/16/16/16/16)
728729
729730   MCFG_MACHINE_START_OVERRIDE(dlair_state,dlair)
730731   MCFG_MACHINE_RESET_OVERRIDE(dlair_state,dlair)
r17996r17997
761762   MCFG_CPU_CONFIG(dleuro_daisy_chain)
762763   MCFG_CPU_PROGRAM_MAP(dleuro_map)
763764   MCFG_CPU_IO_MAP(dleuro_io_map)
764   MCFG_CPU_VBLANK_INT("screen", vblank_callback)
765   MCFG_CPU_VBLANK_INT_DRIVER("screen", dlair_state, vblank_callback)
765766
766767   MCFG_Z80CTC_ADD("ctc", MASTER_CLOCK_EURO/4 /* same as "maincpu" */, ctc_intf)
767768   MCFG_Z80SIO_ADD("sio", MASTER_CLOCK_EURO/4 /* same as "maincpu" */, sio_intf)
trunk/src/mame/drivers/jollyjgr.c
r17996r17997
141141   virtual void palette_init();
142142   UINT32 screen_update_jollyjgr(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
143143   UINT32 screen_update_fspider(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
144   INTERRUPT_GEN_MEMBER(jollyjgr_interrupt);
144145};
145146
146147
r17996r17997
621622 *
622623 *************************************/
623624
624static INTERRUPT_GEN( jollyjgr_interrupt )
625INTERRUPT_GEN_MEMBER(jollyjgr_state::jollyjgr_interrupt)
625626{
626   jollyjgr_state *state = device->machine().driver_data<jollyjgr_state>();
627   if(state->m_nmi_enable)
628      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
627   if(m_nmi_enable)
628      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
629629}
630630
631631
r17996r17997
654654   /* basic machine hardware */
655655   MCFG_CPU_ADD("maincpu", Z80, 3579545)       /* 3,579545 MHz */
656656   MCFG_CPU_PROGRAM_MAP(jollyjgr_map)
657   MCFG_CPU_VBLANK_INT("screen", jollyjgr_interrupt)
657   MCFG_CPU_VBLANK_INT_DRIVER("screen", jollyjgr_state, jollyjgr_interrupt)
658658
659659
660660   /* video hardware */
trunk/src/mame/drivers/quizpani.c
r17996r17997
197197static MACHINE_CONFIG_START( quizpani, quizpani_state )
198198   MCFG_CPU_ADD("maincpu", M68000, 10000000)
199199   MCFG_CPU_PROGRAM_MAP(quizpani_map)
200   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
201   MCFG_CPU_PERIODIC_INT(irq1_line_hold,164) // music tempo
200   MCFG_CPU_VBLANK_INT_DRIVER("screen", quizpani_state,  irq4_line_hold)
201   MCFG_CPU_PERIODIC_INT_DRIVER(quizpani_state, irq1_line_hold, 164) // music tempo
202202
203203   MCFG_GFXDECODE(quizpani)
204204   MCFG_PALETTE_LENGTH(0x200)
trunk/src/mame/drivers/gomoku.c
r17996r17997
121121   /* basic machine hardware */
122122   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/12)       /* 1.536 MHz ? */
123123   MCFG_CPU_PROGRAM_MAP(gomoku_map)
124   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
124   MCFG_CPU_VBLANK_INT_DRIVER("screen", gomoku_state, irq0_line_hold)
125125
126126   /* video hardware */
127127   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ssfindo.c
r17996r17997
247247   DECLARE_DRIVER_INIT(tetfight);
248248   virtual void machine_reset();
249249   UINT32 screen_update_ssfindo(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
250   INTERRUPT_GEN_MEMBER(ssfindo_interrupt);
250251};
251252
252253
r17996r17997
330331      state->m_PS7500timer1->adjust(attotime::from_usec(val ), 0, attotime::from_usec(val ));
331332}
332333
333static INTERRUPT_GEN( ssfindo_interrupt )
334INTERRUPT_GEN_MEMBER(ssfindo_state::ssfindo_interrupt)
334335{
335   ssfindo_state *state = device->machine().driver_data<ssfindo_state>();
336   state->m_PS7500_IO[IRQSTA]|=0x08;
337      if(state->m_PS7500_IO[IRQMSKA]&0x08)
336   m_PS7500_IO[IRQSTA]|=0x08;
337      if(m_PS7500_IO[IRQMSKA]&0x08)
338338      {
339         generic_pulse_irq_line(device, ARM7_IRQ_LINE, 1);
339         generic_pulse_irq_line(device.execute(), ARM7_IRQ_LINE, 1);
340340      }
341341}
342342
r17996r17997
757757   MCFG_CPU_ADD("maincpu", ARM7, 54000000) // guess...
758758   MCFG_CPU_PROGRAM_MAP(ssfindo_map)
759759
760   MCFG_CPU_VBLANK_INT("screen", ssfindo_interrupt)
760   MCFG_CPU_VBLANK_INT_DRIVER("screen", ssfindo_state, ssfindo_interrupt)
761761
762762
763763   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/firetrk.c
r17996r17997
4747}
4848
4949
50static INTERRUPT_GEN( firetrk_interrupt )
50INTERRUPT_GEN_MEMBER(firetrk_state::firetrk_interrupt)
5151{
52   firetrk_state *state = device->machine().driver_data<firetrk_state>();
5352
5453   /* NMI interrupts are disabled during service mode in firetrk and montecar */
55   if (!state->m_in_service_mode)
56      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
54   if (!m_in_service_mode)
55      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
5756}
5857
5958
r17996r17997
876875   /* basic machine hardware */
877876   MCFG_CPU_ADD("maincpu", M6800, MASTER_CLOCK/12)   /* 750Khz during service mode */
878877   MCFG_CPU_PROGRAM_MAP(firetrk_map)
879   MCFG_CPU_VBLANK_INT("screen", firetrk_interrupt)
878   MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrk_state, firetrk_interrupt)
880879   MCFG_WATCHDOG_VBLANK_INIT(5)
881880
882881
trunk/src/mame/drivers/m57.c
r17996r17997
228228   /* basic machine hardware */
229229   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)   /* verified on pcb */
230230   MCFG_CPU_PROGRAM_MAP(main_map)
231   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
231   MCFG_CPU_VBLANK_INT_DRIVER("screen", m57_state, irq0_line_hold)
232232
233233   /* video hardware */
234234   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ddayjlc.c
r17996r17997
106106   virtual void video_start();
107107   virtual void palette_init();
108108   UINT32 screen_update_ddayjlc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
109   INTERRUPT_GEN_MEMBER(ddayjlc_interrupt);
110   INTERRUPT_GEN_MEMBER(ddayjlc_snd_interrupt);
109111};
110112
111113
r17996r17997
435437   DEVCB_NULL
436438};
437439
438static INTERRUPT_GEN( ddayjlc_interrupt )
440INTERRUPT_GEN_MEMBER(ddayjlc_state::ddayjlc_interrupt)
439441{
440   ddayjlc_state *state = device->machine().driver_data<ddayjlc_state>();
441   if(state->m_main_nmi_enable)
442      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
442   if(m_main_nmi_enable)
443      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
443444}
444445
445static INTERRUPT_GEN( ddayjlc_snd_interrupt )
446INTERRUPT_GEN_MEMBER(ddayjlc_state::ddayjlc_snd_interrupt)
446447{
447   ddayjlc_state *state = device->machine().driver_data<ddayjlc_state>();
448   if(state->m_sound_nmi_enable)
449      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
448   if(m_sound_nmi_enable)
449      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
450450}
451451
452452
r17996r17997
518518   /* basic machine hardware */
519519   MCFG_CPU_ADD("maincpu", Z80,12000000/3)
520520   MCFG_CPU_PROGRAM_MAP(main_cpu)
521   MCFG_CPU_VBLANK_INT("screen", ddayjlc_interrupt)
521   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddayjlc_state, ddayjlc_interrupt)
522522
523523   MCFG_CPU_ADD("audiocpu", Z80, 12000000/4)
524524   MCFG_CPU_PROGRAM_MAP(sound_cpu)
525   MCFG_CPU_VBLANK_INT("screen", ddayjlc_snd_interrupt)
525   MCFG_CPU_VBLANK_INT_DRIVER("screen", ddayjlc_state, ddayjlc_snd_interrupt)
526526
527527   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
528528
trunk/src/mame/drivers/konamigx.c
r17996r17997
633633}
634634
635635
636static INTERRUPT_GEN(konamigx_vbinterrupt)
636INTERRUPT_GEN_MEMBER(konamigx_state::konamigx_vbinterrupt)
637637{
638638   // lift idle suspension
639   if (resume_trigger && suspension_active) { suspension_active = 0; device->machine().scheduler().trigger(resume_trigger); }
639   if (resume_trigger && suspension_active) { suspension_active = 0; machine().scheduler().trigger(resume_trigger); }
640640
641641   // IRQ 1 is the main 60hz vblank interrupt
642642   if (gx_syncen & 0x20)
r17996r17997
646646      if ((konamigx_wrport1_1 & 0x81) == 0x81 || (gx_syncen & 1))
647647      {
648648         gx_syncen &= ~1;
649         device->execute().set_input_line(1, HOLD_LINE);
649         device.execute().set_input_line(1, HOLD_LINE);
650650      }
651651   }
652652
r17996r17997
12511251   sndto020[offset] = data;
12521252}
12531253
1254static INTERRUPT_GEN(tms_sync)
1254INTERRUPT_GEN_MEMBER(konamigx_state::tms_sync)
12551255{
1256   downcast<tms57002_device *>(device)->sync();
1256   downcast<tms57002_device *>(&device)->sync();
12571257}
12581258
12591259READ16_MEMBER(konamigx_state::tms57002_data_word_r)
r17996r17997
17611761   /* basic machine hardware */
17621762   MCFG_CPU_ADD("maincpu", M68EC020, 24000000)
17631763   MCFG_CPU_PROGRAM_MAP(gx_type2_map)
1764   MCFG_CPU_VBLANK_INT("screen", konamigx_vbinterrupt)
1764   MCFG_CPU_VBLANK_INT_DRIVER("screen", konamigx_state, konamigx_vbinterrupt)
17651765
17661766   MCFG_CPU_ADD("soundcpu", M68000, 8000000)
17671767   MCFG_CPU_PROGRAM_MAP(gxsndmap)
1768   MCFG_CPU_PERIODIC_INT(irq2_line_hold, 480)
1768   MCFG_CPU_PERIODIC_INT_DRIVER(konamigx_state, irq2_line_hold, 480)
17691769
17701770   MCFG_CPU_ADD("dasp", TMS57002, 12500000)
17711771   MCFG_CPU_DATA_MAP(gxtmsmap)
1772   MCFG_CPU_PERIODIC_INT(tms_sync, 48000)
1772   MCFG_CPU_PERIODIC_INT_DRIVER(konamigx_state, tms_sync, 48000)
17731773
17741774   MCFG_QUANTUM_TIME(attotime::from_hz(1920))
17751775
trunk/src/mame/drivers/sprcros2.c
r17996r17997
262262   }
263263}
264264
265static INTERRUPT_GEN( sprcros2_s_interrupt )
265INTERRUPT_GEN_MEMBER(sprcros2_state::sprcros2_s_interrupt)
266266{
267   sprcros2_state *state = device->machine().driver_data<sprcros2_state>();
268267
269   if(state->m_s_port3&0x01)
270      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
268   if(m_s_port3&0x01)
269      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
271270}
272271
273272void sprcros2_state::machine_start()
r17996r17997
288287   MCFG_CPU_ADD("slave", Z80,10000000/2)
289288   MCFG_CPU_PROGRAM_MAP(sprcros2_slave_map)
290289   MCFG_CPU_IO_MAP(sprcros2_slave_io_map)
291   MCFG_CPU_PERIODIC_INT(sprcros2_s_interrupt,2*60)   //2 nmis
290   MCFG_CPU_PERIODIC_INT_DRIVER(sprcros2_state, sprcros2_s_interrupt, 2*60)   //2 nmis
292291
293292
294293   /* video hardware */
trunk/src/mame/drivers/dorachan.c
r17996r17997
243243   MCFG_CPU_ADD("maincpu", Z80, 2000000)
244244   MCFG_CPU_PROGRAM_MAP(dorachan_map)
245245   MCFG_CPU_IO_MAP(dorachan_io_map)
246   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
246   MCFG_CPU_PERIODIC_INT_DRIVER(dorachan_state, irq0_line_hold, 2*60)
247247
248248
249249   /* video hardware */
trunk/src/mame/drivers/parodius.c
r17996r17997
1919static KONAMI_SETLINES_CALLBACK( parodius_banking );
2020
2121
22static INTERRUPT_GEN( parodius_interrupt )
22INTERRUPT_GEN_MEMBER(parodius_state::parodius_interrupt)
2323{
24   parodius_state *state = device->machine().driver_data<parodius_state>();
25   if (k052109_is_irq_enabled(state->m_k052109))
26      device->execute().set_input_line(0, HOLD_LINE);
24   if (k052109_is_irq_enabled(m_k052109))
25      device.execute().set_input_line(0, HOLD_LINE);
2726}
2827
2928READ8_MEMBER(parodius_state::bankedram_r)
r17996r17997
290289   /* basic machine hardware */
291290   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)      /* 053248 */
292291   MCFG_CPU_PROGRAM_MAP(parodius_map)
293   MCFG_CPU_VBLANK_INT("screen", parodius_interrupt)
292   MCFG_CPU_VBLANK_INT_DRIVER("screen", parodius_state, parodius_interrupt)
294293
295294   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
296295   MCFG_CPU_PROGRAM_MAP(parodius_sound_map)
trunk/src/mame/drivers/quantum.c
r17996r17997
292292   /* basic machine hardware */
293293   MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK / 2)
294294   MCFG_CPU_PROGRAM_MAP(main_map)
295   MCFG_CPU_PERIODIC_INT(irq1_line_hold, (double)MASTER_CLOCK / 4096 / 12)
295   MCFG_CPU_PERIODIC_INT_DRIVER(quantum_state, irq1_line_hold, (double)MASTER_CLOCK / 4096 / 12)
296296
297297   MCFG_NVRAM_ADD_1FILL("nvram")
298298
trunk/src/mame/drivers/combatsc.c
r17996r17997
735735   /* basic machine hardware */
736736   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)   /* 3 MHz? */
737737   MCFG_CPU_PROGRAM_MAP(combatsc_map)
738   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
738   MCFG_CPU_VBLANK_INT_DRIVER("screen", combatsc_state, irq0_line_hold)
739739
740740   MCFG_CPU_ADD("audiocpu", Z80,3579545)   /* 3.579545 MHz */
741741   MCFG_CPU_PROGRAM_MAP(combatsc_sound_map)
r17996r17997
785785   /* basic machine hardware */
786786   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)   /* 3 MHz? */
787787   MCFG_CPU_PROGRAM_MAP(combatscb_map)
788   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
788   MCFG_CPU_VBLANK_INT_DRIVER("screen", combatsc_state, irq0_line_hold)
789789
790790   MCFG_CPU_ADD("audiocpu", Z80,3579545)   /* 3.579545 MHz */
791791   MCFG_CPU_PROGRAM_MAP(combatscb_sound_map)
792   MCFG_CPU_PERIODIC_INT(irq0_line_hold,3800) // controls BGM tempo
792   MCFG_CPU_PERIODIC_INT_DRIVER(combatsc_state, irq0_line_hold, 3800) // controls BGM tempo
793793
794794   MCFG_QUANTUM_TIME(attotime::from_hz(1200))
795795
trunk/src/mame/drivers/rockrage.c
r17996r17997
5757#include "includes/konamipt.h"
5858
5959
60static INTERRUPT_GEN( rockrage_interrupt )
60INTERRUPT_GEN_MEMBER(rockrage_state::rockrage_interrupt)
6161{
62   rockrage_state *state = device->machine().driver_data<rockrage_state>();
63   if (k007342_is_int_enabled(state->m_k007342))
64      device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
62   if (k007342_is_int_enabled(m_k007342))
63      device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
6564}
6665
6766WRITE8_MEMBER(rockrage_state::rockrage_bankswitch_w)
r17996r17997
263262   /* basic machine hardware */
264263   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)      /* 24MHz/8 */
265264   MCFG_CPU_PROGRAM_MAP(rockrage_map)
266   MCFG_CPU_VBLANK_INT("screen", rockrage_interrupt)
265   MCFG_CPU_VBLANK_INT_DRIVER("screen", rockrage_state, rockrage_interrupt)
267266
268267   MCFG_CPU_ADD("audiocpu", M6809, 1500000)      /* 24MHz/16 */
269268   MCFG_CPU_PROGRAM_MAP(rockrage_sound_map)
trunk/src/mame/drivers/quizpun2.c
r17996r17997
488488   MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz / 2)   // 4 MHz?
489489   MCFG_CPU_PROGRAM_MAP(quizpun2_map)
490490   MCFG_CPU_IO_MAP(quizpun2_io_map)
491   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
491   MCFG_CPU_VBLANK_INT_DRIVER("screen", quizpun2_state, irq0_line_hold)
492492
493493   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz / 2)   // 4 MHz?
494494   MCFG_CPU_PROGRAM_MAP(quizpun2_sound_map)
495495   MCFG_CPU_IO_MAP(quizpun2_sound_io_map)
496   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
496   MCFG_CPU_VBLANK_INT_DRIVER("screen", quizpun2_state, irq0_line_hold)
497497   // NMI generated by main CPU
498498
499499
trunk/src/mame/drivers/egghunt.c
r17996r17997
412412   MCFG_CPU_ADD("maincpu", Z80,12000000/2)       /* 6 MHz ?*/
413413   MCFG_CPU_PROGRAM_MAP(egghunt_map)
414414   MCFG_CPU_IO_MAP(io_map)
415   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) // or 2 like mitchell.c?
415   MCFG_CPU_VBLANK_INT_DRIVER("screen", egghunt_state, irq0_line_hold) // or 2 like mitchell.c?
416416
417417   MCFG_CPU_ADD("audiocpu", Z80,12000000/2)       /* 6 MHz ?*/
418418   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/bigstrkb.c
r17996r17997
198198
199199   MCFG_CPU_ADD("maincpu", M68000, 12000000)
200200   MCFG_CPU_PROGRAM_MAP(bigstrkb_map)
201   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
201   MCFG_CPU_VBLANK_INT_DRIVER("screen", bigstrkb_state, irq6_line_hold)
202202
203203   MCFG_GFXDECODE(bigstrkb)
204204
trunk/src/mame/drivers/stfight.c
r17996r17997
436436   /* basic machine hardware */
437437   MCFG_CPU_ADD("maincpu", Z80, 3000000)   /* 3 MHz */
438438   MCFG_CPU_PROGRAM_MAP(cpu1_map)
439   MCFG_CPU_VBLANK_INT("screen", stfight_vb_interrupt)
439   MCFG_CPU_VBLANK_INT_DRIVER("screen", stfight_state, stfight_vb_interrupt)
440440
441441   MCFG_CPU_ADD("audiocpu", Z80, 3000000)   /* 3 MHz */
442442   MCFG_CPU_PROGRAM_MAP(cpu2_map)
443   MCFG_CPU_PERIODIC_INT(irq0_line_hold,120)
443   MCFG_CPU_PERIODIC_INT_DRIVER(stfight_state, irq0_line_hold, 120)
444444
445445   MCFG_QUANTUM_TIME(attotime::from_hz(600))
446446
trunk/src/mame/drivers/gberet.c
r17996r17997
462462   /* basic machine hardware */
463463   MCFG_CPU_ADD("maincpu", Z80, XTAL_20MHz/4) // divider guessed
464464   MCFG_CPU_PROGRAM_MAP(gberetb_map)
465   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
466   MCFG_CPU_PERIODIC_INT(nmi_line_assert, XTAL_20MHz/0x8000) // divider guessed
465   MCFG_CPU_VBLANK_INT_DRIVER("screen", gberet_state,  irq0_line_assert)
466   MCFG_CPU_PERIODIC_INT_DRIVER(gberet_state, nmi_line_assert,  XTAL_20MHz/0x8000) // divider guessed
467467
468468   MCFG_MACHINE_START_OVERRIDE(gberet_state,gberet)
469469   MCFG_MACHINE_RESET_OVERRIDE(gberet_state,gberet)
trunk/src/mame/drivers/sandscrp.c
r17996r17997
111111   virtual void machine_reset();
112112   UINT32 screen_update_sandscrp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
113113   void screen_eof_sandscrp(screen_device &screen, bool state);
114   INTERRUPT_GEN_MEMBER(sandscrp_interrupt);
114115};
115116
116117
r17996r17997
160161
161162
162163/* Called once/frame to generate the VBLANK interrupt */
163static INTERRUPT_GEN( sandscrp_interrupt )
164INTERRUPT_GEN_MEMBER(sandscrp_state::sandscrp_interrupt)
164165{
165   sandscrp_state *state = device->machine().driver_data<sandscrp_state>();
166   state->m_vblank_irq = 1;
167   update_irq_state(device->machine());
166   m_vblank_irq = 1;
167   update_irq_state(machine());
168168}
169169
170170
r17996r17997
500500   /* basic machine hardware */
501501   MCFG_CPU_ADD("maincpu", M68000,12000000)   /* TMP68HC000N-12 */
502502   MCFG_CPU_PROGRAM_MAP(sandscrp)
503   MCFG_CPU_VBLANK_INT("screen", sandscrp_interrupt)
503   MCFG_CPU_VBLANK_INT_DRIVER("screen", sandscrp_state, sandscrp_interrupt)
504504
505505   MCFG_CPU_ADD("audiocpu", Z80,4000000)   /* Z8400AB1, Reads the DSWs: it can't be disabled */
506506   MCFG_CPU_PROGRAM_MAP(sandscrp_soundmem)
trunk/src/mame/drivers/gpworld.c
r17996r17997
7272   DECLARE_DRIVER_INIT(gpworld);
7373   virtual void machine_start();
7474   UINT32 screen_update_gpworld(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
75   INTERRUPT_GEN_MEMBER(vblank_callback_gpworld);
7576};
7677
7778
r17996r17997
429430   machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
430431}
431432
432static INTERRUPT_GEN( vblank_callback_gpworld )
433INTERRUPT_GEN_MEMBER(gpworld_state::vblank_callback_gpworld)
433434{
434   gpworld_state *state = device->machine().driver_data<gpworld_state>();
435435   /* Do an NMI if the enabled bit is set */
436   if (state->m_nmi_enable)
436   if (m_nmi_enable)
437437   {
438      state->m_laserdisc->data_w(state->m_ldp_write_latch);
439      state->m_ldp_read_latch = state->m_laserdisc->status_r();
440      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
438      m_laserdisc->data_w(m_ldp_write_latch);
439      m_ldp_read_latch = m_laserdisc->status_r();
440      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
441441   }
442442
443443   /* The time the IRQ line stays high is set just long enough to happen after the NMI - hacky? */
444   device->execute().set_input_line(0, ASSERT_LINE);
445   device->machine().scheduler().timer_set(attotime::from_usec(100), FUNC(irq_stop));
444   device.execute().set_input_line(0, ASSERT_LINE);
445   machine().scheduler().timer_set(attotime::from_usec(100), FUNC(irq_stop));
446446}
447447
448448static const gfx_layout gpworld_tile_layout =
r17996r17997
467467   MCFG_CPU_ADD("maincpu", Z80, GUESSED_CLOCK)
468468   MCFG_CPU_PROGRAM_MAP(mainmem)
469469   MCFG_CPU_IO_MAP(mainport)
470   MCFG_CPU_VBLANK_INT("screen", vblank_callback_gpworld)
470   MCFG_CPU_VBLANK_INT_DRIVER("screen", gpworld_state, vblank_callback_gpworld)
471471
472472
473473   MCFG_LASERDISC_LDV1000_ADD("laserdisc")
trunk/src/mame/drivers/tubep.c
r17996r17997
942942
943943   MCFG_CPU_REPLACE("mcu", M6802,6000000) /* ? MHz Xtal */
944944   MCFG_CPU_PROGRAM_MAP(nsc_map)
945   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
945   MCFG_CPU_VBLANK_INT_DRIVER("screen", tubep_state, nmi_line_pulse)
946946MACHINE_CONFIG_END
947947
948948
trunk/src/mame/drivers/exidy.c
r17996r17997
806806
807807   /* basic machine hardware */
808808   MCFG_CPU_ADD("maincpu", M6502, EXIDY_CPU_CLOCK)
809   MCFG_CPU_VBLANK_INT("screen", exidy_vblank_interrupt)
809   MCFG_CPU_VBLANK_INT_DRIVER("screen", exidy_state, exidy_vblank_interrupt)
810810
811811   /* video hardware */
812812   MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
r17996r17997
878878
879879   /* basic machine hardware */
880880   MCFG_CPU_MODIFY("maincpu")
881   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,10*60)
881   MCFG_CPU_PERIODIC_INT_DRIVER(exidy_state, nmi_line_pulse, 10*60)
882882
883883   MCFG_MACHINE_START_OVERRIDE(exidy_state, teetert )
884884
trunk/src/mame/drivers/homedata.c
r17996r17997
223223#include "sound/dac.h"
224224#include "sound/2203intf.h"
225225
226static INTERRUPT_GEN( homedata_irq )
226INTERRUPT_GEN_MEMBER(homedata_state::homedata_irq)
227227{
228   homedata_state *state = device->machine().driver_data<homedata_state>();
229   state->m_vblank = 1;
230   device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
228   m_vblank = 1;
229   device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
231230}
232231
233static INTERRUPT_GEN( upd7807_irq )
232INTERRUPT_GEN_MEMBER(homedata_state::upd7807_irq)
234233{
235   device->execute().set_input_line(UPD7810_INTF1, HOLD_LINE);
234   device.execute().set_input_line(UPD7810_INTF1, HOLD_LINE);
236235}
237236
238237
r17996r17997
12461245   /* basic machine hardware */
12471246   MCFG_CPU_ADD("maincpu", M6809, 16000000/4)   /* 4MHz ? */
12481247   MCFG_CPU_PROGRAM_MAP(mrokumei_map)
1249   MCFG_CPU_VBLANK_INT("screen", homedata_irq)   /* also triggered by the blitter */
1248   MCFG_CPU_VBLANK_INT_DRIVER("screen", homedata_state, homedata_irq)   /* also triggered by the blitter */
12501249
12511250   MCFG_CPU_ADD("audiocpu", Z80, 16000000/4)   /* 4MHz ? */
12521251   MCFG_CPU_PROGRAM_MAP(mrokumei_sound_map)
r17996r17997
13121311   /* basic machine hardware */
13131312   MCFG_CPU_ADD("maincpu", M6809, 16000000/4)   /* 4MHz ? */
13141313   MCFG_CPU_PROGRAM_MAP(reikaids_map)
1315   MCFG_CPU_VBLANK_INT("screen", homedata_irq)   /* also triggered by the blitter */
1314   MCFG_CPU_VBLANK_INT_DRIVER("screen", homedata_state, homedata_irq)   /* also triggered by the blitter */
13161315
13171316   MCFG_CPU_ADD("audiocpu", UPD7807, 8000000)   /* ??? MHz (max speed for the 7807 is 12MHz) */
13181317   MCFG_CPU_CONFIG(upd_config)
13191318   MCFG_CPU_PROGRAM_MAP(reikaids_upd7807_map)
13201319   MCFG_CPU_IO_MAP(reikaids_upd7807_io_map)
1321   MCFG_CPU_VBLANK_INT("screen", upd7807_irq)
1320   MCFG_CPU_VBLANK_INT_DRIVER("screen", homedata_state, upd7807_irq)
13221321
13231322   MCFG_QUANTUM_TIME(attotime::from_hz(30000))   // very high interleave required to sync for startup tests
13241323
r17996r17997
13621361   /* basic machine hardware */
13631362   MCFG_CPU_ADD("maincpu", M6809, 16000000/4)   /* 4MHz ? */
13641363   MCFG_CPU_PROGRAM_MAP(pteacher_map)
1365   MCFG_CPU_VBLANK_INT("screen", homedata_irq)   /* also triggered by the blitter */
1364   MCFG_CPU_VBLANK_INT_DRIVER("screen", homedata_state, homedata_irq)   /* also triggered by the blitter */
13661365
13671366   MCFG_CPU_ADD("audiocpu", UPD7807, 9000000)   /* 9MHz ? */
13681367   MCFG_CPU_CONFIG(upd_config)
13691368   MCFG_CPU_PROGRAM_MAP(pteacher_upd7807_map)
13701369   MCFG_CPU_IO_MAP(pteacher_upd7807_io_map)
1371   MCFG_CPU_VBLANK_INT("screen", upd7807_irq)
1370   MCFG_CPU_VBLANK_INT_DRIVER("screen", homedata_state, upd7807_irq)
13721371
13731372   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   // should be enough
13741373
trunk/src/mame/drivers/mw18w.c
r17996r17997
177177static MACHINE_CONFIG_START( mw18w, mw18w_state )
178178   /* basic machine hardware */
179179   MCFG_CPU_ADD("maincpu", Z80, XTAL_19_968MHz/8)
180   MCFG_CPU_PERIODIC_INT(irq0_line_assert,960.516)   // 555 IC
180   MCFG_CPU_PERIODIC_INT_DRIVER(mw18w_state, irq0_line_assert, 960.516)   // 555 IC
181181   MCFG_CPU_PROGRAM_MAP(mw18w_map)
182182   MCFG_CPU_IO_MAP(mw18w_portmap)
183183
trunk/src/mame/drivers/mugsmash.c
r17996r17997
410410
411411   MCFG_CPU_ADD("maincpu", M68000, 12000000)
412412   MCFG_CPU_PROGRAM_MAP(mugsmash_map)
413   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
413   MCFG_CPU_VBLANK_INT_DRIVER("screen", mugsmash_state, irq6_line_hold)
414414
415415   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* Guess */
416416   MCFG_CPU_PROGRAM_MAP(mugsmash_sound_map)
trunk/src/mame/drivers/pcktgal.c
r17996r17997
222222   /* basic machine hardware */
223223   MCFG_CPU_ADD("maincpu", M6502, 2000000)
224224   MCFG_CPU_PROGRAM_MAP(pcktgal_map)
225   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
225   MCFG_CPU_VBLANK_INT_DRIVER("screen", pcktgal_state, nmi_line_pulse)
226226
227227   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
228228   MCFG_CPU_PROGRAM_MAP(pcktgal_sound_map)
trunk/src/mame/drivers/jokrwild.c
r17996r17997
480480   /* basic machine hardware */
481481   MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/2)   /* guess */
482482   MCFG_CPU_PROGRAM_MAP(jokrwild_map)
483   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
483   MCFG_CPU_VBLANK_INT_DRIVER("screen", jokrwild_state, nmi_line_pulse)
484484
485485//  MCFG_NVRAM_ADD_0FILL("nvram")
486486
trunk/src/mame/drivers/solomon.c
r17996r17997
193193   GFXDECODE_ENTRY( "gfx3", 0, spritelayout,   0, 8 )   /* colors   0-127 */
194194GFXDECODE_END
195195
196static INTERRUPT_GEN( vblank_irq )
196INTERRUPT_GEN_MEMBER(solomon_state::vblank_irq)
197197{
198   solomon_state *state = device->machine().driver_data<solomon_state>();
199198
200   if(state->m_nmi_mask)
201      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
199   if(m_nmi_mask)
200      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
202201}
203202
204203
r17996r17997
208207   /* basic machine hardware */
209208   MCFG_CPU_ADD("maincpu", Z80, 4000000)   /* 4.0 MHz (?????) */
210209   MCFG_CPU_PROGRAM_MAP(main_map)
211   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
210   MCFG_CPU_VBLANK_INT_DRIVER("screen", solomon_state, vblank_irq)
212211
213212   MCFG_CPU_ADD("audiocpu", Z80, 3072000)
214213   MCFG_CPU_PROGRAM_MAP(sound_map)
215214   MCFG_CPU_IO_MAP(sound_portmap)
216   MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)   /* ??? */
215   MCFG_CPU_PERIODIC_INT_DRIVER(solomon_state, irq0_line_hold, 2*60)   /* ??? */
217216                  /* NMIs are caused by the main CPU */
218217
219218   /* video hardware */
trunk/src/mame/drivers/gladiatr.c
r17996r17997
666666   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
667667   MCFG_CPU_PROGRAM_MAP(ppking_cpu1_map)
668668   MCFG_CPU_IO_MAP(ppking_cpu1_io)
669   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
669   MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
670670
671671   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/4) /* verified on pcb */
672672   MCFG_CPU_PROGRAM_MAP(cpu2_map)
673673   MCFG_CPU_IO_MAP(ppking_cpu2_io)
674   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
674   MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
675675
676676   MCFG_CPU_ADD("audiocpu", M6809, XTAL_12MHz/16) /* verified on pcb */
677677   MCFG_CPU_PROGRAM_MAP(ppking_cpu3_map)
r17996r17997
715715   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
716716   MCFG_CPU_PROGRAM_MAP(gladiatr_cpu1_map)
717717   MCFG_CPU_IO_MAP(gladiatr_cpu1_io)
718   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
718   MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
719719
720720   MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/4) /* verified on pcb */
721721   MCFG_CPU_PROGRAM_MAP(cpu2_map)
trunk/src/mame/drivers/macrossp.c
r17996r17997
623623   /* basic machine hardware */
624624   MCFG_CPU_ADD("maincpu", M68EC020, 50000000/2)   /* 25 MHz */
625625   MCFG_CPU_PROGRAM_MAP(macrossp_map)
626   MCFG_CPU_VBLANK_INT("screen", irq3_line_hold) // there are others ...
626   MCFG_CPU_VBLANK_INT_DRIVER("screen", macrossp_state, irq3_line_hold) // there are others ...
627627
628628   MCFG_CPU_ADD("audiocpu", M68000, 32000000/2)   /* 16 MHz */
629629   MCFG_CPU_PROGRAM_MAP(macrossp_sound_map)
trunk/src/mame/drivers/imolagp.c
r17996r17997
129129   virtual void machine_reset();
130130   virtual void video_start();
131131   UINT32 screen_update_imolagp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
132   INTERRUPT_GEN_MEMBER(vblank_irq);
132133};
133134
134135
r17996r17997
493494   }
494495}
495496
496static INTERRUPT_GEN( vblank_irq )
497INTERRUPT_GEN_MEMBER(imolagp_state::vblank_irq)
497498{
498   imolagp_state *state = device->machine().driver_data<imolagp_state>();
499499
500500#ifdef HLE_COM
501   memcpy(&state->m_slave_workram[0x80], state->m_mComData, state->m_mComCount);
502   state->m_mComCount = 0;
501   memcpy(&m_slave_workram[0x80], m_mComData, m_mComCount);
502   m_mComCount = 0;
503503#endif
504   device->execute().set_input_line(0, HOLD_LINE);
504   device.execute().set_input_line(0, HOLD_LINE);
505505} /* master_interrupt */
506506
507507
r17996r17997
556556   MCFG_CPU_ADD("maincpu", Z80,8000000) /* ? */
557557   MCFG_CPU_PROGRAM_MAP(imolagp_master)
558558   MCFG_CPU_IO_MAP(readport_master)
559   MCFG_CPU_VBLANK_INT("screen",vblank_irq)
559   MCFG_CPU_VBLANK_INT_DRIVER("screen", imolagp_state, vblank_irq)
560560   MCFG_TIMER_ADD_PERIODIC("pot_irq", imolagp_nmi_cb, attotime::from_hz(60*3))
561561
562562   MCFG_CPU_ADD("slave", Z80,8000000) /* ? */
563563   MCFG_CPU_PROGRAM_MAP(imolagp_slave)
564564   MCFG_CPU_IO_MAP(readport_slave)
565   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
565   MCFG_CPU_VBLANK_INT_DRIVER("screen", imolagp_state, irq0_line_hold)
566566
567567   MCFG_QUANTUM_TIME(attotime::from_hz(6000))
568568
trunk/src/mame/drivers/poker72.c
r17996r17997
354354   /* basic machine hardware */
355355   MCFG_CPU_ADD("maincpu", Z80,8000000)       /* ? MHz */
356356   MCFG_CPU_PROGRAM_MAP(poker72_map)
357   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
357   MCFG_CPU_VBLANK_INT_DRIVER("screen", poker72_state, irq0_line_hold)
358358
359359
360360   /* video hardware */
trunk/src/mame/drivers/umipoker.c
r17996r17997
662662   /* basic machine hardware */
663663   MCFG_CPU_ADD("maincpu",M68000,16000000) // TMP68HC000-16
664664   MCFG_CPU_PROGRAM_MAP(umipoker_map)
665   MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)
665   MCFG_CPU_VBLANK_INT_DRIVER("screen", umipoker_state, irq6_line_assert)
666666
667667   MCFG_CPU_ADD("audiocpu",Z80,4000000)
668668   MCFG_CPU_PROGRAM_MAP(umipoker_audio_map)
669669   MCFG_CPU_IO_MAP(umipoker_audio_io_map)
670   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 120)   // ? controls ym3812 music tempo
670   MCFG_CPU_PERIODIC_INT_DRIVER(umipoker_state, irq0_line_hold, 120)   // ? controls ym3812 music tempo
671671
672672   MCFG_NVRAM_ADD_1FILL("nvram")
673673
trunk/src/mame/drivers/goindol.c
r17996r17997
239239   /* basic machine hardware */
240240   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)   /* XTAL confirmed, divisor is not */
241241   MCFG_CPU_PROGRAM_MAP(goindol_map)
242   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
242   MCFG_CPU_VBLANK_INT_DRIVER("screen", goindol_state, irq0_line_hold)
243243
244244   MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/2)   /* XTAL confirmed, divisor is not */
245245   MCFG_CPU_PROGRAM_MAP(sound_map)
246   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
246   MCFG_CPU_PERIODIC_INT_DRIVER(goindol_state, irq0_line_hold, 4*60)
247247
248248
249249   /* video hardware */
trunk/src/mame/drivers/gyruss.c
r17996r17997
496496   save_item(NAME(m_slave_irq_mask));
497497}
498498
499static INTERRUPT_GEN( master_vblank_irq )
499INTERRUPT_GEN_MEMBER(gyruss_state::master_vblank_irq)
500500{
501   gyruss_state *state = device->machine().driver_data<gyruss_state>();
502501
503   if (state->m_master_nmi_mask)
504      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
502   if (m_master_nmi_mask)
503      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
505504}
506505
507static INTERRUPT_GEN( slave_vblank_irq )
506INTERRUPT_GEN_MEMBER(gyruss_state::slave_vblank_irq)
508507{
509   gyruss_state *state = device->machine().driver_data<gyruss_state>();
510508
511   if (state->m_slave_irq_mask)
512      device->execute().set_input_line(0, HOLD_LINE);
509   if (m_slave_irq_mask)
510      device.execute().set_input_line(0, HOLD_LINE);
513511}
514512
515513static MACHINE_CONFIG_START( gyruss, gyruss_state )
r17996r17997
517515   /* basic machine hardware */
518516   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)   /* 3.072 MHz */
519517   MCFG_CPU_PROGRAM_MAP(main_cpu1_map)
520   MCFG_CPU_VBLANK_INT("screen", master_vblank_irq)
518   MCFG_CPU_VBLANK_INT_DRIVER("screen", gyruss_state, master_vblank_irq)
521519
522520   MCFG_CPU_ADD("sub", M6809, MASTER_CLOCK/12)      /* 1.536 MHz */
523521   MCFG_CPU_PROGRAM_MAP(main_cpu2_map)
524   MCFG_CPU_VBLANK_INT("screen", slave_vblank_irq)
522   MCFG_CPU_VBLANK_INT_DRIVER("screen", gyruss_state, slave_vblank_irq)
525523
526524   MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)   /* 3.579545 MHz */
527525   MCFG_CPU_PROGRAM_MAP(audio_cpu1_map)
trunk/src/mame/drivers/kangaroo.c
r17996r17997
428428   /* basic machine hardware */
429429   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
430430   MCFG_CPU_PROGRAM_MAP(main_map)
431   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
431   MCFG_CPU_VBLANK_INT_DRIVER("screen", kangaroo_state, irq0_line_hold)
432432
433433   MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK/8)
434434   MCFG_CPU_PROGRAM_MAP(sound_map)
435435   MCFG_CPU_IO_MAP(sound_portmap)
436   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
436   MCFG_CPU_VBLANK_INT_DRIVER("screen", kangaroo_state, irq0_line_hold)
437437
438438
439439   /* video hardware */
trunk/src/mame/drivers/cabal.c
r17996r17997
492492   /* basic machine hardware */
493493   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
494494   MCFG_CPU_PROGRAM_MAP(main_map)
495   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
495   MCFG_CPU_VBLANK_INT_DRIVER("screen", cabal_state, irq1_line_hold)
496496
497497   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
498498   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
534534   /* basic machine hardware */
535535   MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
536536   MCFG_CPU_PROGRAM_MAP(cabalbl_main_map)
537   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
537   MCFG_CPU_VBLANK_INT_DRIVER("screen", cabal_state, irq1_line_hold)
538538
539539   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
540540   MCFG_CPU_PROGRAM_MAP(cabalbl_sound_map)
r17996r17997
543543   MCFG_CPU_ADD("adpcm1", Z80, XTAL_3_579545MHz) /* verified on pcb */
544544   MCFG_CPU_PROGRAM_MAP(cabalbl_talk1_map)
545545   MCFG_CPU_IO_MAP(cabalbl_talk1_portmap)
546   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
546   MCFG_CPU_PERIODIC_INT_DRIVER(cabal_state, irq0_line_hold, 8000)
547547
548548   MCFG_CPU_ADD("adpcm2", Z80, XTAL_3_579545MHz) /* verified on pcb */
549549   MCFG_CPU_PROGRAM_MAP(cabalbl_talk2_map)
550550   MCFG_CPU_IO_MAP(cabalbl_talk2_portmap)
551   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
551   MCFG_CPU_PERIODIC_INT_DRIVER(cabal_state, irq0_line_hold, 8000)
552552
553553   MCFG_QUANTUM_TIME(attotime::from_hz(600))
554554
trunk/src/mame/drivers/hotblock.c
r17996r17997
6868   DECLARE_WRITE8_MEMBER(hotblock_video_write);
6969   virtual void video_start();
7070   UINT32 screen_update_hotblock(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
71   INTERRUPT_GEN_MEMBER(hotblocks_irq);
7172};
7273
7374
r17996r17997
195196INPUT_PORTS_END
196197
197198
198static INTERRUPT_GEN( hotblocks_irq ) /* right? */
199INTERRUPT_GEN_MEMBER(hotblock_state::hotblocks_irq)/* right? */
199200{
200   device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
201   device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
201202}
202203
203204static const ay8910_interface ay8910_config =
r17996r17997
217218   MCFG_CPU_ADD("maincpu", I8088, 10000000)
218219   MCFG_CPU_PROGRAM_MAP(hotblock_map)
219220   MCFG_CPU_IO_MAP(hotblock_io)
220   MCFG_CPU_VBLANK_INT("screen", hotblocks_irq)
221   MCFG_CPU_VBLANK_INT_DRIVER("screen", hotblock_state, hotblocks_irq)
221222
222223   /* video hardware */
223224   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/vendetta.c
r17996r17997
404404
405405***************************************************************************/
406406
407static INTERRUPT_GEN( vendetta_irq )
407INTERRUPT_GEN_MEMBER(vendetta_state::vendetta_irq)
408408{
409   vendetta_state *state = device->machine().driver_data<vendetta_state>();
410   if (state->m_irq_enabled)
411      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
409   if (m_irq_enabled)
410      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
412411}
413412
414413static const k052109_interface vendetta_k052109_intf =
r17996r17997
504503   /* basic machine hardware */
505504   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)   /* 052001 (verified on pcb) */
506505   MCFG_CPU_PROGRAM_MAP(main_map)
507   MCFG_CPU_VBLANK_INT("screen", vendetta_irq)
506   MCFG_CPU_VBLANK_INT_DRIVER("screen", vendetta_state, vendetta_irq)
508507
509508   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)   /* verified with PCB */
510509   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/thoop2.c
r17996r17997
191191   /* basic machine hardware */
192192   MCFG_CPU_ADD("maincpu", M68000,24000000/2)         /* 12 MHz */
193193   MCFG_CPU_PROGRAM_MAP(thoop2_map)
194   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
194   MCFG_CPU_VBLANK_INT_DRIVER("screen", thoop2_state, irq6_line_hold)
195195
196196   /* video hardware */
197197   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/marineb.c
r17996r17997
523523   GFXDECODE_ENTRY( "gfx2", 0x0000, marineb_big_spritelayout,    0, 64 )
524524GFXDECODE_END
525525
526static INTERRUPT_GEN( marineb_vblank_irq )
526INTERRUPT_GEN_MEMBER(marineb_state::marineb_vblank_irq)
527527{
528   marineb_state *state = device->machine().driver_data<marineb_state>();
529528
530   if(state->m_irq_mask)
531      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
529   if(m_irq_mask)
530      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
532531}
533532
534static INTERRUPT_GEN( wanted_vblank_irq )
533INTERRUPT_GEN_MEMBER(marineb_state::wanted_vblank_irq)
535534{
536   marineb_state *state = device->machine().driver_data<marineb_state>();
537535
538   if(state->m_irq_mask)
539      device->execute().set_input_line(0, HOLD_LINE);
536   if(m_irq_mask)
537      device.execute().set_input_line(0, HOLD_LINE);
540538}
541539
542540
r17996r17997
546544   MCFG_CPU_ADD("maincpu", Z80, 3072000)   /* 3.072 MHz */
547545   MCFG_CPU_PROGRAM_MAP(marineb_map)
548546   MCFG_CPU_IO_MAP(marineb_io_map)
549   MCFG_CPU_VBLANK_INT("screen", marineb_vblank_irq)
547   MCFG_CPU_VBLANK_INT_DRIVER("screen", marineb_state, marineb_vblank_irq)
550548
551549
552550   /* video hardware */
r17996r17997
606604   /* basic machine hardware */
607605   MCFG_CPU_MODIFY("maincpu")
608606   MCFG_CPU_IO_MAP(wanted_io_map)
609   MCFG_CPU_VBLANK_INT("screen", wanted_vblank_irq)
607   MCFG_CPU_VBLANK_INT_DRIVER("screen", marineb_state, wanted_vblank_irq)
610608
611609   /* video hardware */
612610   MCFG_GFXDECODE(wanted)
trunk/src/mame/drivers/timeplt.c
r17996r17997
5959 *
6060 *************************************/
6161
62static INTERRUPT_GEN( timeplt_interrupt )
62INTERRUPT_GEN_MEMBER(timeplt_state::timeplt_interrupt)
6363{
64   timeplt_state *state = device->machine().driver_data<timeplt_state>();
6564
66   if (state->m_nmi_enable)
67      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
65   if (m_nmi_enable)
66      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
6867}
6968
7069
r17996r17997
470469   /* basic machine hardware */
471470   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/3/2)   /* not confirmed, but common for Konami games of the era */
472471   MCFG_CPU_PROGRAM_MAP(timeplt_main_map)
473   MCFG_CPU_VBLANK_INT("screen", timeplt_interrupt)
472   MCFG_CPU_VBLANK_INT_DRIVER("screen", timeplt_state, timeplt_interrupt)
474473
475474
476475   /* video hardware */
r17996r17997
496495   /* basic machine hardware */
497496   MCFG_CPU_MODIFY("maincpu")
498497   MCFG_CPU_PROGRAM_MAP(psurge_main_map)
499   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
498   MCFG_CPU_VBLANK_INT_DRIVER("screen", timeplt_state, nmi_line_pulse)
500499MACHINE_CONFIG_END
501500
502501static MACHINE_CONFIG_DERIVED( bikkuric, timeplt )
trunk/src/mame/drivers/pktgaldx.c
r17996r17997
328328   /* basic machine hardware */
329329   MCFG_CPU_ADD("maincpu", M68000, 14000000)
330330   MCFG_CPU_PROGRAM_MAP(pktgaldx_map)
331   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
331   MCFG_CPU_VBLANK_INT_DRIVER("screen", pktgaldx_state, irq6_line_hold)
332332
333333
334334   /* video hardware */
r17996r17997
367367   /* basic machine hardware */
368368   MCFG_CPU_ADD("maincpu", M68000, 16000000)
369369   MCFG_CPU_PROGRAM_MAP(pktgaldb_map)
370   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
370   MCFG_CPU_VBLANK_INT_DRIVER("screen", pktgaldx_state, irq6_line_hold)
371371
372372
373373   /* video hardware */
trunk/src/mame/drivers/taotaido.c
r17996r17997
332332static MACHINE_CONFIG_START( taotaido, taotaido_state )
333333   MCFG_CPU_ADD("maincpu", M68000, 32000000/2)
334334   MCFG_CPU_PROGRAM_MAP(main_map)
335   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
335   MCFG_CPU_VBLANK_INT_DRIVER("screen", taotaido_state, irq1_line_hold)
336336
337337   MCFG_CPU_ADD("audiocpu", Z80,20000000/4) // ??
338338   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/taito_f3.c
r17996r17997
395395   machine.device("maincpu")->execute().set_input_line(3, HOLD_LINE);   // some signal from video hardware?
396396}
397397
398static INTERRUPT_GEN( f3_interrupt2 )
398INTERRUPT_GEN_MEMBER(taito_f3_state::f3_interrupt2)
399399{
400   device->execute().set_input_line(2, HOLD_LINE);   // vblank
401   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(10000), FUNC(f3_interrupt3));
400   device.execute().set_input_line(2, HOLD_LINE);   // vblank
401   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(10000), FUNC(f3_interrupt3));
402402}
403403
404404static SOUND_RESET( f3 )
r17996r17997
429429   /* basic machine hardware */
430430   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_16MHz)
431431   MCFG_CPU_PROGRAM_MAP(f3_map)
432   MCFG_CPU_VBLANK_INT("screen", f3_interrupt2)
432   MCFG_CPU_VBLANK_INT_DRIVER("screen", taito_f3_state, f3_interrupt2)
433433
434434   MCFG_MACHINE_START_OVERRIDE(taito_f3_state,f3)
435435
r17996r17997
523523   /* basic machine hardware */
524524   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_16MHz)
525525   MCFG_CPU_PROGRAM_MAP(f3_map)
526   MCFG_CPU_VBLANK_INT("screen", f3_interrupt2)
526   MCFG_CPU_VBLANK_INT_DRIVER("screen", taito_f3_state, f3_interrupt2)
527527
528528   MCFG_MACHINE_START_OVERRIDE(taito_f3_state,f3)
529529
trunk/src/mame/drivers/gaelco2.c
r17996r17997
157157   /* basic machine hardware */
158158   MCFG_CPU_ADD("maincpu", M68000, 26000000/2)      /* 13 MHz? */
159159   MCFG_CPU_PROGRAM_MAP(maniacsq_map)
160   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
160   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
161161
162162   /* video hardware */
163163   MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
r17996r17997
531531   /* basic machine hardware */
532532   MCFG_CPU_ADD("maincpu", M68000, 24000000/2)         /* 12 MHz */
533533   MCFG_CPU_PROGRAM_MAP(alighunt_map)
534   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
534   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
535535
536536   /* video hardware */
537537   MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
r17996r17997
773773   /* basic machine hardware */
774774   MCFG_CPU_ADD("maincpu", M68000, 32000000/2)         /* 16 MHz */
775775   MCFG_CPU_PROGRAM_MAP(touchgo_map)
776   MCFG_CPU_VBLANK_INT("lscreen", irq6_line_hold)
776   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gaelco2_state, irq6_line_hold)
777777
778778   /* video hardware */
779779   MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
r17996r17997
965965   /* basic machine hardware */
966966   MCFG_CPU_ADD("maincpu", M68000, 30000000/2)         /* 15 MHz */
967967   MCFG_CPU_PROGRAM_MAP(snowboar_map)
968   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
968   MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
969969
970970   MCFG_EEPROM_ADD("eeprom", gaelco2_eeprom_interface)
971971
r17996r17997
12061206   /* basic machine hardware */
12071207   MCFG_CPU_ADD("maincpu", M68000, 26000000/2)         /* 13 MHz */
12081208   MCFG_CPU_PROGRAM_MAP(wrally2_map)
1209   MCFG_CPU_VBLANK_INT("lscreen", irq6_line_hold)
1209   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gaelco2_state, irq6_line_hold)
12101210
12111211   MCFG_EEPROM_ADD("eeprom", gaelco2_eeprom_interface)
12121212
trunk/src/mame/drivers/homerun.c
r17996r17997
387387   MCFG_CPU_ADD("maincpu", Z80, XTAL_20MHz/4)
388388   MCFG_CPU_PROGRAM_MAP(homerun_memmap)
389389   MCFG_CPU_IO_MAP(homerun_iomap)
390   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
390   MCFG_CPU_VBLANK_INT_DRIVER("screen", homerun_state, irq0_line_hold)
391391
392392
393393   MCFG_I8255A_ADD( "ppi8255", ppi8255_intf )
r17996r17997
424424
425425   /* basic machine hardware */
426426   MCFG_CPU_MODIFY("maincpu")
427   MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60) // ?
427   MCFG_CPU_PERIODIC_INT_DRIVER(homerun_state, irq0_line_hold, 4*60) // ?
428428
429429   /* sound hardware */
430430   MCFG_SOUND_ADD("d7756", UPD7756, UPD7759_STANDARD_CLOCK)
trunk/src/mame/drivers/champbas.c
r17996r17997
604604   m_gfx_bank = 0;   // talbot has only 1 bank
605605}
606606
607static INTERRUPT_GEN( vblank_irq )
607INTERRUPT_GEN_MEMBER(champbas_state::vblank_irq)
608608{
609   champbas_state *state = device->machine().driver_data<champbas_state>();
610609
611   if(state->m_irq_mask)
612      device->execute().set_input_line(0, ASSERT_LINE);
610   if(m_irq_mask)
611      device.execute().set_input_line(0, ASSERT_LINE);
613612}
614613
615614
r17996r17997
618617   /* basic machine hardware */
619618   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
620619   MCFG_CPU_PROGRAM_MAP(talbot_map)
621   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
620   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
622621
623622   /* MCU */
624623   MCFG_CPU_ADD(CPUTAG_MCU, ALPHA8201, XTAL_18_432MHz/6/8)
r17996r17997
654653   /* main cpu */
655654   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
656655   MCFG_CPU_PROGRAM_MAP(champbas_main_map)
657   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
656   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
658657
659658   MCFG_CPU_ADD("sub", Z80, XTAL_18_432MHz/6)
660659   MCFG_CPU_PROGRAM_MAP(champbas_sub_map)
r17996r17997
705704   /* basic machine hardware */
706705   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6 )
707706   MCFG_CPU_PROGRAM_MAP(exctsccr_main_map)
708   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
707   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
709708
710709   MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz/4 )
711710   MCFG_CPU_PROGRAM_MAP(exctsccr_sub_map)
712711   MCFG_CPU_IO_MAP(exctsccr_sound_io_map)
713   MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000) /* 4 kHz, updates the dac */
712   MCFG_CPU_PERIODIC_INT_DRIVER(champbas_state, nmi_line_pulse, 4000) /* 4 kHz, updates the dac */
714713
715714   /* MCU */
716715   MCFG_CPU_ADD(CPUTAG_MCU, ALPHA8301, XTAL_18_432MHz/6/8)      /* Actually 8302 */
r17996r17997
762761   /* basic machine hardware */
763762   MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
764763   MCFG_CPU_PROGRAM_MAP(exctsccrb_main_map)
765   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
764   MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
766765
767766   MCFG_CPU_ADD("sub", Z80, XTAL_18_432MHz/6)
768767   MCFG_CPU_PROGRAM_MAP(champbas_sub_map)
trunk/src/mame/drivers/ssozumo.c
r17996r17997
180180   GFXDECODE_ENTRY( "gfx3", 0, spritelayout, 8*8, 2 )
181181GFXDECODE_END
182182
183static INTERRUPT_GEN( sound_timer_irq )
183INTERRUPT_GEN_MEMBER(ssozumo_state::sound_timer_irq)
184184{
185   ssozumo_state *state = device->machine().driver_data<ssozumo_state>();
186185
187   if(state->m_sound_nmi_mask)
188      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
186   if(m_sound_nmi_mask)
187      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
189188}
190189
191190static MACHINE_CONFIG_START( ssozumo, ssozumo_state )
r17996r17997
193192   /* basic machine hardware */
194193   MCFG_CPU_ADD("maincpu", M6502, 1200000)   /* 1.2 MHz ???? */
195194   MCFG_CPU_PROGRAM_MAP(ssozumo_map)
196   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
195   MCFG_CPU_VBLANK_INT_DRIVER("screen", ssozumo_state, irq0_line_hold)
197196
198197   MCFG_CPU_ADD("audiocpu", M6502, 975000)       /* 975 kHz ?? */
199198   MCFG_CPU_PROGRAM_MAP(ssozumo_sound_map)
200   MCFG_CPU_PERIODIC_INT(sound_timer_irq,272/16*57) // guess, assume to be the same as tagteam
199   MCFG_CPU_PERIODIC_INT_DRIVER(ssozumo_state, sound_timer_irq, 272/16*57) // guess, assume to be the same as tagteam
201200
202201   /* video hardware */
203202   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/ninjaw.c
r17996r17997
843843   /* basic machine hardware */
844844   MCFG_CPU_ADD("maincpu", M68000,16000000/2)   /* 8 MHz ? */
845845   MCFG_CPU_PROGRAM_MAP(ninjaw_master_map)
846   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
846   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
847847
848848   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 16/4 MHz ? */
849849   MCFG_CPU_PROGRAM_MAP(ninjaw_sound_map)
850850
851851   MCFG_CPU_ADD("sub", M68000,16000000/2)   /* 8 MHz ? */
852852   MCFG_CPU_PROGRAM_MAP(ninjaw_slave_map)
853   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
853   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
854854
855855   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* CPU slices */
856856
r17996r17997
923923   /* basic machine hardware */
924924   MCFG_CPU_ADD("maincpu", M68000,16000000/2)   /* 8 MHz ? */
925925   MCFG_CPU_PROGRAM_MAP(darius2_master_map)
926   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
926   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
927927
928928   MCFG_CPU_ADD("audiocpu", Z80,16000000/4)   /* 4 MHz ? */
929929   MCFG_CPU_PROGRAM_MAP(ninjaw_sound_map)
930930
931931   MCFG_CPU_ADD("sub", M68000,16000000/2)   /* 8 MHz ? */
932932   MCFG_CPU_PROGRAM_MAP(darius2_slave_map)
933   MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
933   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", ninjaw_state, irq4_line_hold)
934934
935935   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   /* CPU slices */
936936
trunk/src/mame/drivers/twin16.c
r17996r17997
5555
5656
5757
58#define CPUA_IRQ_ENABLE (state->m_CPUA_register & 0x20)
59#define CPUB_IRQ_ENABLE (state->m_CPUB_register & 0x02)
58#define CPUA_IRQ_ENABLE (m_CPUA_register & 0x20)
59#define CPUB_IRQ_ENABLE (m_CPUB_register & 0x02)
6060
6161
6262
r17996r17997
685685
686686/* Interrupt Generators */
687687
688static INTERRUPT_GEN( CPUA_interrupt )
688INTERRUPT_GEN_MEMBER(twin16_state::CPUA_interrupt)
689689{
690   twin16_state *state = device->machine().driver_data<twin16_state>();
691   if (CPUA_IRQ_ENABLE) device->execute().set_input_line(5, HOLD_LINE);
690   if (CPUA_IRQ_ENABLE) device.execute().set_input_line(5, HOLD_LINE);
692691}
693692
694static INTERRUPT_GEN( CPUB_interrupt )
693INTERRUPT_GEN_MEMBER(twin16_state::CPUB_interrupt)
695694{
696   twin16_state *state = device->machine().driver_data<twin16_state>();
697   if (CPUB_IRQ_ENABLE) device->execute().set_input_line(5, HOLD_LINE);
695   if (CPUB_IRQ_ENABLE) device.execute().set_input_line(5, HOLD_LINE);
698696}
699697
700698/* Machine Drivers */
r17996r17997
722720   // basic machine hardware
723721   MCFG_CPU_ADD("maincpu", M68000, XTAL_18_432MHz/2)
724722   MCFG_CPU_PROGRAM_MAP(main_map)
725   MCFG_CPU_VBLANK_INT("screen", CPUA_interrupt)
723   MCFG_CPU_VBLANK_INT_DRIVER("screen", twin16_state, CPUA_interrupt)
726724
727725   MCFG_CPU_ADD("sub", M68000, XTAL_18_432MHz/2)
728726   MCFG_CPU_PROGRAM_MAP(sub_map)
729   MCFG_CPU_VBLANK_INT("screen", CPUB_interrupt)
727   MCFG_CPU_VBLANK_INT_DRIVER("screen", twin16_state, CPUB_interrupt)
730728
731729   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
732730   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
780778   /* basic machine hardware */
781779   MCFG_CPU_ADD("maincpu", M68000, 10000000)
782780   MCFG_CPU_PROGRAM_MAP(fround_map)
783   MCFG_CPU_VBLANK_INT("screen", CPUA_interrupt)
781   MCFG_CPU_VBLANK_INT_DRIVER("screen", twin16_state, CPUA_interrupt)
784782
785783   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
786784   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/arkanoid.c
r17996r17997
10201020   /* basic machine hardware */
10211021   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
10221022   MCFG_CPU_PROGRAM_MAP(arkanoid_map)
1023   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1023   MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
10241024
10251025   MCFG_CPU_ADD("mcu", M68705, XTAL_12MHz/4) /* verified on pcb */
10261026   MCFG_CPU_PROGRAM_MAP(mcu_map)
r17996r17997
10581058   /* basic machine hardware */
10591059   MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2)   /* Imported from arkanoid - correct? */
10601060   MCFG_CPU_PROGRAM_MAP(hexa_map)
1061   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1061   MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
10621062
10631063   MCFG_MACHINE_START_OVERRIDE(arkanoid_state,arkanoid)
10641064   MCFG_MACHINE_RESET_OVERRIDE(arkanoid_state,arkanoid)
r17996r17997
11001100   /* basic machine hardware */
11011101   MCFG_CPU_MODIFY("maincpu")
11021102   MCFG_CPU_PROGRAM_MAP(brixian_map)
1103   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
1103   MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
11041104
11051105   MCFG_DEVICE_REMOVE("mcu")
11061106MACHINE_CONFIG_END
trunk/src/mame/drivers/megasys1.c
r17996r17997
292292                            [ Main CPU - System D ]
293293***************************************************************************/
294294
295static INTERRUPT_GEN( megasys1D_irq )
295INTERRUPT_GEN_MEMBER(megasys1_state::megasys1D_irq)
296296{
297   device->execute().set_input_line(2, HOLD_LINE);
297   device.execute().set_input_line(2, HOLD_LINE);
298298}
299299
300300static ADDRESS_MAP_START( megasys1D_map, AS_PROGRAM, 16, megasys1_state )
r17996r17997
16031603   /* basic machine hardware */
16041604   MCFG_CPU_ADD("maincpu", M68000, SYS_D_CPU_CLOCK)   /* 8MHz */
16051605   MCFG_CPU_PROGRAM_MAP(megasys1D_map)
1606   MCFG_CPU_VBLANK_INT("screen", megasys1D_irq)
1606   MCFG_CPU_VBLANK_INT_DRIVER("screen", megasys1_state, megasys1D_irq)
16071607
16081608   MCFG_MACHINE_RESET_OVERRIDE(megasys1_state,megasys1)
16091609
trunk/src/mame/drivers/crshrace.c
r17996r17997
463463   /* basic machine hardware */
464464   MCFG_CPU_ADD("maincpu", M68000,16000000)   /* 16 MHz ??? */
465465   MCFG_CPU_PROGRAM_MAP(crshrace_map)
466   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
466   MCFG_CPU_VBLANK_INT_DRIVER("screen", crshrace_state, irq1_line_hold)
467467
468468   MCFG_CPU_ADD("audiocpu", Z80,4000000)   /* 4 MHz ??? */
469469   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/airbustr.c
r17996r17997
561561}
562562
563563/* Sub Z80 uses IM2 too, but 0xff irq routine just contains an irq ack in it */
564static INTERRUPT_GEN( slave_interrupt )
564INTERRUPT_GEN_MEMBER(airbustr_state::slave_interrupt)
565565{
566   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xfd);
566   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xfd);
567567}
568568
569569/* Machine Initialization */
r17996r17997
630630   MCFG_CPU_ADD("slave", Z80, 6000000)   // ???
631631   MCFG_CPU_PROGRAM_MAP(slave_map)
632632   MCFG_CPU_IO_MAP(slave_io_map)
633   MCFG_CPU_VBLANK_INT("screen", slave_interrupt) /* nmi signal from master cpu */
633   MCFG_CPU_VBLANK_INT_DRIVER("screen", airbustr_state, slave_interrupt) /* nmi signal from master cpu */
634634
635635   MCFG_CPU_ADD("audiocpu", Z80, 6000000)   // ???
636636   MCFG_CPU_PROGRAM_MAP(sound_map)
637637   MCFG_CPU_IO_MAP(sound_io_map)
638   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)      // nmi are caused by sub cpu writing a sound command
638   MCFG_CPU_VBLANK_INT_DRIVER("screen", airbustr_state, irq0_line_hold)      // nmi are caused by sub cpu writing a sound command
639639
640640   MCFG_QUANTUM_TIME(attotime::from_hz(6000))   // Palette RAM is filled by sub cpu with data supplied by main cpu
641641                     // Maybe a high value is safer in order to avoid glitches
trunk/src/mame/drivers/pacman.c
r17996r17997
399399 *
400400 *************************************/
401401
402static INTERRUPT_GEN( vblank_irq )
402INTERRUPT_GEN_MEMBER(pacman_state::vblank_irq)
403403{
404   pacman_state *state = device->machine().driver_data<pacman_state>();
405404
406   if(state->m_irq_mask)
407      device->execute().set_input_line(0, HOLD_LINE);
405   if(m_irq_mask)
406      device.execute().set_input_line(0, HOLD_LINE);
408407}
409408
410static INTERRUPT_GEN( vblank_nmi )
409INTERRUPT_GEN_MEMBER(pacman_state::vblank_nmi)
411410{
412   pacman_state *state = device->machine().driver_data<pacman_state>();
413411
414   if(state->m_irq_mask)
415      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
412   if(m_irq_mask)
413      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
416414}
417415
418416WRITE8_MEMBER(pacman_state::irq_mask_w)
r17996r17997
694692 *
695693 ************************************/
696694
697static INTERRUPT_GEN( s2650_interrupt )
695INTERRUPT_GEN_MEMBER(pacman_state::s2650_interrupt)
698696{
699   device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
697   device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
700698}
701699
702700WRITE8_MEMBER(pacman_state::porky_banking_w)
r17996r17997
32943292   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)
32953293   MCFG_CPU_PROGRAM_MAP(pacman_map)
32963294   MCFG_CPU_IO_MAP(writeport)
3297   MCFG_CPU_VBLANK_INT("screen",vblank_irq)
3295   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, vblank_irq)
32983296   MCFG_WATCHDOG_VBLANK_INIT(16)
32993297
33003298   /* video hardware */
r17996r17997
33753373   MCFG_CPU_MODIFY("maincpu")
33763374   MCFG_CPU_PROGRAM_MAP(dremshpr_map)
33773375   MCFG_CPU_IO_MAP(dremshpr_portmap)
3378   MCFG_CPU_VBLANK_INT("screen", vblank_nmi)
3376   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, vblank_nmi)
33793377
33803378   /* sound hardware */
33813379   MCFG_SOUND_REPLACE("namco", AY8910, 14318000/8)
r17996r17997
34133411   MCFG_CPU_MODIFY("maincpu")
34143412   MCFG_CPU_PROGRAM_MAP(dremshpr_map)
34153413   MCFG_CPU_IO_MAP(vanvan_portmap)
3416   MCFG_CPU_VBLANK_INT("screen", vblank_nmi)
3414   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, vblank_nmi)
34173415
34183416   /* video hardware */
34193417   MCFG_SCREEN_MODIFY("screen")
r17996r17997
34353433   MCFG_CPU_MODIFY("maincpu")
34363434   MCFG_CPU_PROGRAM_MAP(bigbucks_map)
34373435   MCFG_CPU_IO_MAP(bigbucks_portmap)
3438   MCFG_CPU_PERIODIC_INT(vblank_irq,20*60)
3436   MCFG_CPU_PERIODIC_INT_DRIVER(pacman_state, vblank_irq, 20*60)
34393437
34403438   MCFG_SCREEN_MODIFY("screen")
34413439   MCFG_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 0*8, 28*8-1)
r17996r17997
34483446   MCFG_DEVICE_REMOVE("maincpu")
34493447   MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/6/2)   /* 2H */
34503448   MCFG_CPU_PROGRAM_MAP(s2650games_map)
3451   MCFG_CPU_VBLANK_INT("screen", s2650_interrupt)
3449   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, s2650_interrupt)
34523450
34533451   MCFG_GFXDECODE(s2650games)
34543452
r17996r17997
34963494   /* basic machine hardware */
34973495   MCFG_CPU_MODIFY("maincpu")
34983496   MCFG_CPU_PROGRAM_MAP(rocktrv2_map)
3499   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3497   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, irq0_line_hold)
35003498
35013499   MCFG_SCREEN_MODIFY("screen")
35023500   MCFG_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 0*8, 28*8-1)
r17996r17997
35093507   MCFG_CPU_MODIFY("maincpu")
35103508   MCFG_CPU_PROGRAM_MAP(mschamp_map)
35113509   MCFG_CPU_IO_MAP(mschamp_portmap)
3512   MCFG_CPU_VBLANK_INT("screen", vblank_irq)
3510   MCFG_CPU_VBLANK_INT_DRIVER("screen", pacman_state, vblank_irq)
35133511
35143512   MCFG_MACHINE_RESET_OVERRIDE(pacman_state,mschamp)
35153513MACHINE_CONFIG_END
trunk/src/mame/drivers/igs011.c
r17996r17997
198198   virtual void video_start();
199199   UINT32 screen_update_igs011(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
200200   void screen_eof_vbowl(screen_device &screen, bool state);
201   INTERRUPT_GEN_MEMBER(lhb_vblank_irq);
201202};
202203
203204
r17996r17997
38323833static MACHINE_CONFIG_DERIVED( drgnwrld, igs011_base )
38333834   MCFG_CPU_MODIFY("maincpu")
38343835   MCFG_CPU_PROGRAM_MAP(drgnwrld)
3835   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3836   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
38363837   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev5_timer_irq_cb, attotime::from_hz(240)) // lev5 frequency drives the music tempo
38373838
38383839   MCFG_SOUND_ADD("ymsnd", YM3812, XTAL_3_579545MHz)
r17996r17997
38463847
38473848
38483849
3849static INTERRUPT_GEN( lhb_vblank_irq )
3850INTERRUPT_GEN_MEMBER(igs011_state::lhb_vblank_irq)
38503851{
3851   igs011_state *state = device->machine().driver_data<igs011_state>();
3852   if (!state->m_lhb_irq_enable)
3852   if (!m_lhb_irq_enable)
38533853      return;
38543854
3855   state->m_maincpu->set_input_line(6, HOLD_LINE);
3855   m_maincpu->set_input_line(6, HOLD_LINE);
38563856}
38573857
38583858static TIMER_DEVICE_CALLBACK ( lhb_timer_irq_cb )
r17996r17997
38673867static MACHINE_CONFIG_DERIVED( lhb, igs011_base )
38683868   MCFG_CPU_MODIFY("maincpu")
38693869   MCFG_CPU_PROGRAM_MAP(lhb)
3870   MCFG_CPU_VBLANK_INT("screen",lhb_vblank_irq)
3870   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, lhb_vblank_irq)
38713871   MCFG_TIMER_ADD_PERIODIC("timer_irq", lhb_timer_irq_cb, attotime::from_hz(240)) // lev5 frequency drives the music tempo
38723872   // irq 3 points to an apparently unneeded routine
38733873MACHINE_CONFIG_END
r17996r17997
38853885static MACHINE_CONFIG_DERIVED( wlcc, igs011_base )
38863886   MCFG_CPU_MODIFY("maincpu")
38873887   MCFG_CPU_PROGRAM_MAP(wlcc)
3888   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3888   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
38893889   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev3_timer_irq_cb, attotime::from_hz(240)) // lev3 frequency drives the music tempo
38903890MACHINE_CONFIG_END
38913891
r17996r17997
38943894static MACHINE_CONFIG_DERIVED( xymg, igs011_base )
38953895   MCFG_CPU_MODIFY("maincpu")
38963896   MCFG_CPU_PROGRAM_MAP(xymg)
3897   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3897   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
38983898   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev3_timer_irq_cb, attotime::from_hz(240)) // lev3 frequency drives the music tempo
38993899MACHINE_CONFIG_END
39003900
r17996r17997
39033903static MACHINE_CONFIG_DERIVED( lhb2, igs011_base )
39043904   MCFG_CPU_MODIFY("maincpu")
39053905   MCFG_CPU_PROGRAM_MAP(lhb2)
3906   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3906   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
39073907   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev5_timer_irq_cb, attotime::from_hz(240)) // lev5 frequency drives the music tempo
39083908
39093909//  MCFG_GFXDECODE(igs011_hi)
r17996r17997
39173917static MACHINE_CONFIG_DERIVED( nkishusp, igs011_base )
39183918   MCFG_CPU_MODIFY("maincpu")
39193919   MCFG_CPU_PROGRAM_MAP(nkishusp)
3920   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3920   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
39213921   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev3_timer_irq_cb, attotime::from_hz(240)) // lev3 frequency drives the music tempo
39223922
39233923   // VSync 60.0052Hz, HSync 15.620kHz
r17996r17997
39383938static MACHINE_CONFIG_DERIVED( vbowl, igs011_base )
39393939   MCFG_CPU_MODIFY("maincpu")
39403940   MCFG_CPU_PROGRAM_MAP(vbowl)
3941   MCFG_CPU_VBLANK_INT("screen",irq6_line_hold)
3941   MCFG_CPU_VBLANK_INT_DRIVER("screen", igs011_state, irq6_line_hold)
39423942   MCFG_TIMER_ADD_PERIODIC("timer_irq", lev3_timer_irq_cb, attotime::from_hz(240)) // lev3 frequency drives the music tempo
39433943   // irq 5 points to a debug function (all routines are clearly patched out)
39443944   // irq 4 points to an apparently unneeded routine
trunk/src/mame/drivers/bwing.c
r17996r17997
3232//****************************************************************************
3333// Interrupt Handlers
3434
35static INTERRUPT_GEN ( bwp3_interrupt )
35INTERRUPT_GEN_MEMBER(bwing_state::bwp3_interrupt)
3636{
37   bwing_state *state = device->machine().driver_data<bwing_state>();
3837
39   if (!state->m_bwp3_nmimask)
40      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
38   if (!m_bwp3_nmimask)
39      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
4140}
4241
4342//****************************************************************************
r17996r17997
374373   MCFG_CPU_ADD("audiocpu", DECO16, 2000000)
375374   MCFG_CPU_PROGRAM_MAP(bwp3_map)
376375   MCFG_CPU_IO_MAP(bwp3_io_map)
377   MCFG_CPU_PERIODIC_INT(bwp3_interrupt, 1000)
376   MCFG_CPU_PERIODIC_INT_DRIVER(bwing_state, bwp3_interrupt, 1000)
378377
379378   MCFG_QUANTUM_TIME(attotime::from_hz(18000))      // high enough?
380379
trunk/src/mame/drivers/srmp6.c
r17996r17997
674674
675675   MCFG_CPU_ADD("maincpu", M68000, 16000000)
676676   MCFG_CPU_PROGRAM_MAP(srmp6_map)
677   MCFG_CPU_VBLANK_INT("screen",irq4_line_assert) // irq3 is a timer irq, but it's never enabled
677   MCFG_CPU_VBLANK_INT_DRIVER("screen", srmp6_state, irq4_line_assert) // irq3 is a timer irq, but it's never enabled
678678
679679   MCFG_SCREEN_ADD("screen", RASTER)
680680   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/sf.c
r17996r17997
838838   /* basic machine hardware */
839839   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz ? (xtal is 16MHz) */
840840   MCFG_CPU_PROGRAM_MAP(sf_map)
841   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
841   MCFG_CPU_VBLANK_INT_DRIVER("screen", sf_state, irq1_line_hold)
842842
843843   MCFG_CPU_ADD("audiocpu", Z80, 3579545)   /* ? xtal is 3.579545MHz */
844844   MCFG_CPU_PROGRAM_MAP(sound_map)
r17996r17997
848848   MCFG_CPU_ADD("audio2", Z80, 3579545)   /* ? xtal is 3.579545MHz */
849849   MCFG_CPU_PROGRAM_MAP(sound2_map)
850850   MCFG_CPU_IO_MAP(sound2_io_map)
851   MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
851   MCFG_CPU_PERIODIC_INT_DRIVER(sf_state, irq0_line_hold, 8000)
852852
853853   /* video hardware */
854854   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
902902
903903   /* basic machine hardware */
904904   MCFG_CPU_MODIFY("maincpu")
905   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
905   MCFG_CPU_VBLANK_INT_DRIVER("screen", sf_state, irq6_line_hold)
906906MACHINE_CONFIG_END
907907
908908
trunk/src/mame/drivers/konamim2.c
r17996r17997
250250   DECLARE_DRIVER_INIT(m2);
251251   virtual void video_start();
252252   UINT32 screen_update_m2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
253   INTERRUPT_GEN_MEMBER(m2);
253254};
254255
255256
r17996r17997
11501151   NULL
11511152};
11521153
1153static INTERRUPT_GEN(m2)
1154INTERRUPT_GEN_MEMBER(konamim2_state::m2)
11541155{
1155   konamim2_state *state = device->machine().driver_data<konamim2_state>();
1156   if (state->m_irq_enable & 0x800000)
1156   if (m_irq_enable & 0x800000)
11571157   {
1158      state->m_irq_active |= 0x800000;
1158      m_irq_active |= 0x800000;
11591159   }
11601160
1161   /*if (state->m_irq_enable & 0x8)
1161   /*if (m_irq_enable & 0x8)
11621162    {
1163        state->m_irq_active |= 0x8;
1163        m_irq_active |= 0x8;
11641164    }*/
11651165
1166   device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
1166   device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
11671167}
11681168
11691169static MACHINE_CONFIG_START( m2, konamim2_state )
r17996r17997
11721172   MCFG_CPU_ADD("maincpu", PPC602, 66000000)   /* actually PPC602, 66MHz */
11731173   MCFG_CPU_CONFIG(ppc602_config)
11741174   MCFG_CPU_PROGRAM_MAP(m2_main)
1175   MCFG_CPU_VBLANK_INT("screen", m2)
1175   MCFG_CPU_VBLANK_INT_DRIVER("screen", konamim2_state, m2)
11761176
11771177   MCFG_CPU_ADD("sub", PPC602, 66000000)   /* actually PPC602, 66MHz */
11781178   MCFG_CPU_CONFIG(ppc602_config)
trunk/src/mame/drivers/cave.c
r17996r17997
135135}
136136
137137/* Called once/frame to generate the VBLANK interrupt */
138static INTERRUPT_GEN( cave_interrupt )
138INTERRUPT_GEN_MEMBER(cave_state::cave_interrupt)
139139{
140   cave_state *state = device->machine().driver_data<cave_state>();
141   state->m_int_timer->adjust(attotime::from_usec(17376 - state->m_time_vblank_irq));
140   m_int_timer->adjust(attotime::from_usec(17376 - m_time_vblank_irq));
142141}
143142
144143/* Called by the YMZ280B to set the IRQ state */
r17996r17997
18541853   /* basic machine hardware */
18551854   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
18561855   MCFG_CPU_PROGRAM_MAP(dfeveron_map)
1857   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
1856   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
18581857
18591858   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
18601859   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
18961895   /* basic machine hardware */
18971896   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
18981897   MCFG_CPU_PROGRAM_MAP(ddonpach_map)
1899   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
1898   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
19001899
19011900   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
19021901   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
19421941   /* basic machine hardware */
19431942   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
19441943   MCFG_CPU_PROGRAM_MAP(donpachi_map)
1945   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
1944   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
19461945
19471946   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
19481947   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
19881987   /* basic machine hardware */
19891988   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
19901989   MCFG_CPU_PROGRAM_MAP(esprade_map)
1991   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
1990   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
19921991
19931992   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
19941993   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
20292028   /* basic machine hardware */
20302029   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
20312030   MCFG_CPU_PROGRAM_MAP(gaia_map)
2032   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2031   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
20332032
20342033   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
20352034   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
20692068   /* basic machine hardware */
20702069   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
20712070   MCFG_CPU_PROGRAM_MAP(guwange_map)
2072   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2071   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
20732072
20742073   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
20752074   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
21092108   /* basic machine hardware */
21102109   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
21112110   MCFG_CPU_PROGRAM_MAP(hotdogst_map)
2112   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2111   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
21132112
21142113   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz)
21152114   MCFG_CPU_PROGRAM_MAP(hotdogst_sound_map)
r17996r17997
21652164   /* basic machine hardware */
21662165   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
21672166   MCFG_CPU_PROGRAM_MAP(korokoro_map)
2168   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2167   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
21692168
21702169   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
21712170   MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
r17996r17997
22132212   /* basic machine hardware */
22142213   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
22152214   MCFG_CPU_PROGRAM_MAP(mazinger_map)
2216   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2215   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
22172216
22182217   MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz) // Bidirectional communication
22192218   MCFG_CPU_PROGRAM_MAP(mazinger_sound_map)
r17996r17997
22712270   /* basic machine hardware */
22722271   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz / 2)
22732272   MCFG_CPU_PROGRAM_MAP(metmqstr_map)
2274   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2273   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
22752274
22762275   MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz / 4)
22772276   MCFG_CPU_PROGRAM_MAP(metmqstr_sound_map)
r17996r17997
23302329   /* basic machine hardware */
23312330   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz / 2)
23322331   MCFG_CPU_PROGRAM_MAP(pacslot_map)
2333   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2332   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
23342333
23352334   MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(3))   /* a guess, and certainly wrong */
23362335
r17996r17997
23842383   /* basic machine hardware */
23852384   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)   /* 16 MHz */
23862385   MCFG_CPU_PROGRAM_MAP(pwrinst2_map)
2387   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2386   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
23882387
23892388   MCFG_CPU_ADD("audiocpu", Z80,XTAL_16MHz / 2)   /* 8 MHz */
23902389   MCFG_CPU_PROGRAM_MAP(pwrinst2_sound_map)
r17996r17997
24452444   /* basic machine hardware */
24462445   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
24472446   MCFG_CPU_PROGRAM_MAP(sailormn_map)
2448   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2447   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
24492448
24502449   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz) // Bidirectional Communication
24512450   MCFG_CPU_PROGRAM_MAP(sailormn_sound_map)
r17996r17997
25032502   /* basic machine hardware */
25042503   MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz / 2)
25052504   MCFG_CPU_PROGRAM_MAP(tjumpman_map)
2506   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2505   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
25072506
25082507   MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(3))   /* a guess, and certainly wrong */
25092508
r17996r17997
25472546   /* basic machine hardware */
25482547   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
25492548   MCFG_CPU_PROGRAM_MAP(uopoko_map)
2550   MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
2549   MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
25512550
25522551   MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
25532552   MCFG_EEPROM_93C46_ADD("eeprom")
trunk/src/mame/drivers/dec8.c
r17996r17997
19551955
19561956/******************************************************************************/
19571957
1958static INTERRUPT_GEN( gondo_interrupt )
1958INTERRUPT_GEN_MEMBER(dec8_state::gondo_interrupt)
19591959{
1960   dec8_state *state = device->machine().driver_data<dec8_state>();
1961   if (state->m_nmi_enable)
1962      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* VBL */
1960   if (m_nmi_enable)
1961      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* VBL */
19631962}
19641963
19651964/* Coins generate NMI's */
1966static INTERRUPT_GEN( oscar_interrupt )
1965INTERRUPT_GEN_MEMBER(dec8_state::oscar_interrupt)
19671966{
1968   dec8_state *state = device->machine().driver_data<dec8_state>();
1969   if ((state->ioport("IN2")->read() & 0x7) == 0x7) state->m_latch = 1;
1970   if (state->m_latch && (state->ioport("IN2")->read() & 0x7) != 0x7)
1967   if ((ioport("IN2")->read() & 0x7) == 0x7) m_latch = 1;
1968   if (m_latch && (ioport("IN2")->read() & 0x7) != 0x7)
19711969   {
1972      state->m_latch = 0;
1973      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
1970      m_latch = 0;
1971      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
19741972   }
19751973}
19761974
r17996r17997
21282126   /* basic machine hardware */
21292127   MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP */
21302128   MCFG_CPU_PROGRAM_MAP(gondo_map)
2131   MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
2129   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
21322130
21332131   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
21342132   MCFG_CPU_PROGRAM_MAP(oscar_s_map)
r17996r17997
21762174   /* basic machine hardware */
21772175   MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP */
21782176   MCFG_CPU_PROGRAM_MAP(garyoret_map)
2179   MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
2177   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
21802178
21812179   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
21822180   MCFG_CPU_PROGRAM_MAP(oscar_s_map)
r17996r17997
22242222   /* basic machine hardware */
22252223   MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)
22262224   MCFG_CPU_PROGRAM_MAP(meikyuh_map)
2227   MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
2225   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
22282226
22292227   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
22302228   MCFG_CPU_PROGRAM_MAP(dec8_s_map)
r17996r17997
22792277
22802278   MCFG_CPU_ADD("sub", M6809, XTAL_12MHz/8) /* verified on pcb */
22812279   MCFG_CPU_PROGRAM_MAP(csilver_sub_map)
2282   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2280   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
22832281
22842282   MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz/8) /* verified on pcb */
22852283   MCFG_CPU_PROGRAM_MAP(csilver_s_map)
r17996r17997
23282326   /* basic machine hardware */
23292327   MCFG_CPU_ADD("maincpu", HD6309, XTAL_12MHz/2) /* verified on pcb */
23302328   MCFG_CPU_PROGRAM_MAP(oscar_map)
2331   MCFG_CPU_VBLANK_INT("screen", oscar_interrupt)
2329   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, oscar_interrupt)
23322330
23332331   MCFG_CPU_ADD("sub", HD6309, XTAL_12MHz/2) /* verified on pcb */
23342332   MCFG_CPU_PROGRAM_MAP(oscar_sub_map)
r17996r17997
23792377   /* basic machine hardware */
23802378   MCFG_CPU_ADD("maincpu", M6809,2000000)  /* MC68A09EP */
23812379   MCFG_CPU_PROGRAM_MAP(srdarwin_map)
2382   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2380   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
23832381
23842382   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
23852383   MCFG_CPU_PROGRAM_MAP(dec8_s_map)
r17996r17997
24202418   /* basic machine hardware */
24212419   MCFG_CPU_ADD("maincpu", M6809, 2000000)
24222420   MCFG_CPU_PROGRAM_MAP(cobra_map)
2423   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
2421   MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
24242422
24252423   MCFG_CPU_ADD("audiocpu", M6502, 1500000)
24262424   MCFG_CPU_PROGRAM_MAP(dec8_s_map)
trunk/src/mame/drivers/rcorsair.c
r17996r17997
135135
136136   MCFG_CPU_ADD("maincpu", I8085A,8000000)       /* Sound CPU? */
137137   MCFG_CPU_PROGRAM_MAP(rcorsair_map)
138//  MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
138   MCFG_CPU_VBLANK_INT_DRIVER("screen", rcorsair_state, irq0_line_hold)
139139
140140   MCFG_SCREEN_ADD("screen", RASTER)
141141   MCFG_SCREEN_REFRESH_RATE(60)
trunk/src/mame/drivers/chance32.c
r17996r17997
471471   MCFG_CPU_ADD("maincpu", Z80,12000000/2)
472472   MCFG_CPU_PROGRAM_MAP(chance32_map)
473473   MCFG_CPU_IO_MAP(chance32_portmap)
474   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
474   MCFG_CPU_VBLANK_INT_DRIVER("screen", chance32_state, irq0_line_hold)
475475
476476
477477   /* video hardware */
trunk/src/mame/drivers/tbowl.c
r17996r17997
459459   /* CPU on Board '6206B' */
460460   MCFG_CPU_ADD("maincpu", Z80, 8000000) /* NEC D70008AC-8 (Z80 Clone) */
461461   MCFG_CPU_PROGRAM_MAP(6206B_map)
462   MCFG_CPU_VBLANK_INT("lscreen", irq0_line_hold)
462   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", tbowl_state, irq0_line_hold)
463463
464464   /* CPU on Board '6206C' */
465465   MCFG_CPU_ADD("sub", Z80, 8000000) /* NEC D70008AC-8 (Z80 Clone) */
466466   MCFG_CPU_PROGRAM_MAP(6206C_map)
467   MCFG_CPU_VBLANK_INT("lscreen", irq0_line_hold)
467   MCFG_CPU_VBLANK_INT_DRIVER("lscreen", tbowl_state, irq0_line_hold)
468468
469469   /* CPU on Board '6206A' */
470470   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* Actual Z80 */
trunk/src/mame/drivers/battlane.c
r17996r17997
7878   m_subcpu->set_input_line(M6809_IRQ_LINE, data & 0x02 ? CLEAR_LINE : HOLD_LINE);
7979}
8080
81static INTERRUPT_GEN( battlane_cpu1_interrupt )
81INTERRUPT_GEN_MEMBER(battlane_state::battlane_cpu1_interrupt)
8282{
83   battlane_state *state = device->machine().driver_data<battlane_state>();
8483
8584   /* See note in battlane_cpu_command_w */
86   if (~state->m_cpu_control & 0x08)
85   if (~m_cpu_control & 0x08)
8786   {
88      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
89      state->m_subcpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
87      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
88      m_subcpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
9089   }
9190}
9291
r17996r17997
289288   /* basic machine hardware */
290289   MCFG_CPU_ADD("maincpu", M6809, 1500000)        /* 1.5 MHz ? */
291290   MCFG_CPU_PROGRAM_MAP(battlane_map)
292   MCFG_CPU_VBLANK_INT("screen", battlane_cpu1_interrupt)
291   MCFG_CPU_VBLANK_INT_DRIVER("screen", battlane_state, battlane_cpu1_interrupt)
293292
294293   MCFG_CPU_ADD("sub", M6809, 1500000)        /* 1.5 MHz ? */
295294   MCFG_CPU_PROGRAM_MAP(battlane_map)
trunk/src/mame/drivers/crimfght.c
r17996r17997
2323/* prototypes */
2424static KONAMI_SETLINES_CALLBACK( crimfght_banking );
2525
26static INTERRUPT_GEN( crimfght_interrupt )
26INTERRUPT_GEN_MEMBER(crimfght_state::crimfght_interrupt)
2727{
28   crimfght_state *state = device->machine().driver_data<crimfght_state>();
2928
30   if (k051960_is_irq_enabled(state->m_k051960))
31      device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
29   if (k051960_is_irq_enabled(m_k051960))
30      device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
3231}
3332
3433WRITE8_MEMBER(crimfght_state::crimfght_coin_w)
r17996r17997
282281   /* basic machine hardware */
283282   MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8)      /* 052001 (verified on pcb) */
284283   MCFG_CPU_PROGRAM_MAP(crimfght_map)
285   MCFG_CPU_VBLANK_INT("screen", crimfght_interrupt)
284   MCFG_CPU_VBLANK_INT_DRIVER("screen", crimfght_state, crimfght_interrupt)
286285
287286   MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz)    /* verified on pcb */
288287   MCFG_CPU_PROGRAM_MAP(crimfght_sound_map)
trunk/src/mame/drivers/rabbit.c
r17996r17997
138138   TILE_GET_INFO_MEMBER(get_rabbit_tilemap3_tile_info);
139139   virtual void video_start();
140140   UINT32 screen_update_rabbit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
141   INTERRUPT_GEN_MEMBER(rabbit_vblank_interrupt);
141142};
142143
143144
r17996r17997
869870
870871  */
871872
872static INTERRUPT_GEN( rabbit_vblank_interrupt )
873INTERRUPT_GEN_MEMBER(rabbit_state::rabbit_vblank_interrupt)
873874{
874   rabbit_state *state = device->machine().driver_data<rabbit_state>();
875   device->machine().device("maincpu")->execute().set_input_line(state->m_vblirqlevel, HOLD_LINE);
875   machine().device("maincpu")->execute().set_input_line(m_vblirqlevel, HOLD_LINE);
876876}
877877
878878static MACHINE_CONFIG_START( rabbit, rabbit_state )
879879   MCFG_CPU_ADD("maincpu", M68EC020, XTAL_24MHz)
880880   MCFG_CPU_PROGRAM_MAP(rabbit_map)
881   MCFG_CPU_VBLANK_INT("screen", rabbit_vblank_interrupt)
881   MCFG_CPU_VBLANK_INT_DRIVER("screen", rabbit_state, rabbit_vblank_interrupt)
882882
883883   MCFG_EEPROM_93C46_ADD("eeprom")
884884
trunk/src/mame/drivers/triplhnt.c
r17996r17997
311311/* basic machine hardware */
312312   MCFG_CPU_ADD("maincpu", M6800, 800000)
313313   MCFG_CPU_PROGRAM_MAP(triplhnt_map)
314   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
314   MCFG_CPU_VBLANK_INT_DRIVER("screen", triplhnt_state, irq0_line_hold)
315315
316316   MCFG_NVRAM_ADD_0FILL("nvram")
317317
trunk/src/mame/drivers/asuka.c
r17996r17997
236236   state->m_maincpu->set_input_line(5, HOLD_LINE);
237237}
238238
239static INTERRUPT_GEN( cadash_interrupt )
239INTERRUPT_GEN_MEMBER(asuka_state::cadash_interrupt)
240240{
241   device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(500), FUNC(cadash_interrupt5));
242   device->execute().set_input_line(4, HOLD_LINE);  /* interrupt vector 4 */
241   machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(500), FUNC(cadash_interrupt5));
242   device.execute().set_input_line(4, HOLD_LINE);  /* interrupt vector 4 */
243243}
244244
245245
r17996r17997
896896   /* basic machine hardware */
897897   MCFG_CPU_ADD("maincpu", M68000, 8000000)    /* checked on PCB */
898898   MCFG_CPU_PROGRAM_MAP(bonzeadv_map)
899   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
899   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq4_line_hold)
900900
901901   MCFG_CPU_ADD("audiocpu", Z80,4000000)    /* sound CPU, also required for test mode */
902902   MCFG_CPU_PROGRAM_MAP(bonzeadv_z80_map)
r17996r17997
937937   /* basic machine hardware */
938938   MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2)   /* verified on pcb */
939939   MCFG_CPU_PROGRAM_MAP(asuka_map)
940   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
940   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
941941
942942   MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4)   /* verified on pcb */
943943   MCFG_CPU_PROGRAM_MAP(z80_map)
r17996r17997
983983   /* basic machine hardware */
984984   MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2)   /* 68000p12 running at 16Mhz, verified on pcb  */
985985   MCFG_CPU_PROGRAM_MAP(cadash_map)
986   MCFG_CPU_VBLANK_INT("screen", cadash_interrupt)
986   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, cadash_interrupt)
987987
988988   MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2)   /* verified on pcb */
989989   MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
r17996r17997
10291029   /* basic machine hardware */
10301030   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz ??? */
10311031   MCFG_CPU_PROGRAM_MAP(asuka_map)
1032   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1032   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
10331033
10341034   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ??? */
10351035   MCFG_CPU_PROGRAM_MAP(z80_map)
r17996r17997
10751075   /* basic machine hardware */
10761076   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz ??? */
10771077   MCFG_CPU_PROGRAM_MAP(asuka_map)
1078   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1078   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
10791079
10801080   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ??? */
10811081   MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
r17996r17997
11171117   /* basic machine hardware */
11181118   MCFG_CPU_ADD("maincpu", M68000, 8000000)   /* 8 MHz ??? */
11191119   MCFG_CPU_PROGRAM_MAP(eto_map)
1120   MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
1120   MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
11211121
11221122   MCFG_CPU_ADD("audiocpu", Z80, 4000000)   /* 4 MHz ??? */
11231123   MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
trunk/src/mame/drivers/pooyan.c
r17996r17997
2424 *
2525 *************************************/
2626
27static INTERRUPT_GEN( pooyan_interrupt )
27INTERRUPT_GEN_MEMBER(pooyan_state::pooyan_interrupt)
2828{
29   pooyan_state *state = device->machine().driver_data<pooyan_state>();
3029
31   if (state->m_irq_enable)
32      device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
30   if (m_irq_enable)
31      device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
3332}
3433
3534
r17996r17997
193192   /* basic machine hardware */
194193   MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/3/2)
195194   MCFG_CPU_PROGRAM_MAP(main_map)
196   MCFG_CPU_VBLANK_INT("screen", pooyan_interrupt)
195   MCFG_CPU_VBLANK_INT_DRIVER("screen", pooyan_state, pooyan_interrupt)
197196
198197
199198   /* video hardware */
trunk/src/mame/drivers/hvyunit.c
r17996r17997
661661   MCFG_CPU_ADD("slave", Z80, 6000000)
662662   MCFG_CPU_PROGRAM_MAP(slave_memory)
663663   MCFG_CPU_IO_MAP(slave_io)
664   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
664   MCFG_CPU_VBLANK_INT_DRIVER("screen", hvyunit_state, irq0_line_hold)
665665
666666   MCFG_CPU_ADD("soundcpu", Z80, 6000000)
667667   MCFG_CPU_PROGRAM_MAP(sound_memory)
668668   MCFG_CPU_IO_MAP(sound_io)
669   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
669   MCFG_CPU_VBLANK_INT_DRIVER("screen", hvyunit_state, irq0_line_hold)
670670
671671   MCFG_CPU_ADD("mermaid", I80C51, 6000000)
672672   MCFG_CPU_IO_MAP(mcu_io)
trunk/src/mame/drivers/rollerg.c
r17996r17997
277277   /* basic machine hardware */
278278   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)      /* ? */
279279   MCFG_CPU_PROGRAM_MAP(rollerg_map)
280   MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
280   MCFG_CPU_VBLANK_INT_DRIVER("screen", rollerg_state, irq0_line_assert)
281281
282282   MCFG_CPU_ADD("audiocpu", Z80, 3579545)
283283   MCFG_CPU_PROGRAM_MAP(rollerg_sound_map)
trunk/src/mame/drivers/pirates.c
r17996r17997
263263static MACHINE_CONFIG_START( pirates, pirates_state )
264264   MCFG_CPU_ADD("maincpu", M68000, 16000000) /* 16mhz */
265265   MCFG_CPU_PROGRAM_MAP(pirates_map)
266   MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
266   MCFG_CPU_VBLANK_INT_DRIVER("screen", pirates_state, irq1_line_hold)
267267
268268   MCFG_EEPROM_ADD("eeprom", eeprom_intf)
269269
trunk/src/mame/drivers/tankbatt.c
r17996r17997
179179   AM_RANGE(0x2000, 0xffff) AM_READNOP //anything else might be left-over for a diagnostic ROM or something related to the discrete sound HW
180180ADDRESS_MAP_END
181181
182static INTERRUPT_GEN( tankbatt_interrupt )
182INTERRUPT_GEN_MEMBER(tankbatt_state::tankbatt_interrupt)
183183{
184   tankbatt_state *state = device->machine().driver_data<tankbatt_state>();
185   if (state->m_nmi_enable) device->execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
184   if (m_nmi_enable) device.execute().set_input_line(INPUT_LINE_NMI,PULSE_LINE);
186185}
187186
188187INPUT_CHANGED_MEMBER(tankbatt_state::coin_inserted)
r17996r17997
287286   /* basic machine hardware */
288287   MCFG_CPU_ADD("maincpu", M6502, 1000000)   /* 1 MHz ???? */
289288   MCFG_CPU_PROGRAM_MAP(main_map)
290   MCFG_CPU_VBLANK_INT("screen", tankbatt_interrupt)
289   MCFG_CPU_VBLANK_INT_DRIVER("screen", tankbatt_state, tankbatt_interrupt)
291290
292291   /* video hardware */
293292   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/wrally.c
r17996r17997
248248   /* basic machine hardware */
249249   MCFG_CPU_ADD("maincpu", M68000,XTAL_24MHz/2)      /* verified on pcb */
250250   MCFG_CPU_PROGRAM_MAP(wrally_map)
251   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
251   MCFG_CPU_VBLANK_INT_DRIVER("screen", wrally_state, irq6_line_hold)
252252
253253   MCFG_CPU_ADD("mcu", DS5002FP, XTAL_24MHz/2)   /* verified on pcb */
254254   MCFG_CPU_CONFIG(dallas_config)
trunk/src/mame/drivers/royalmah.c
r17996r17997
197197   virtual void palette_init();
198198   DECLARE_PALETTE_INIT(mjderngr);
199199   UINT32 screen_update_royalmah(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
200   INTERRUPT_GEN_MEMBER(suzume_irq);
201   INTERRUPT_GEN_MEMBER(mjtensin_interrupt);
200202};
201203
202204
r17996r17997
31693171   MCFG_CPU_ADD("maincpu", Z80, 18432000/6)        /* 3.072 MHz */
31703172   MCFG_CPU_PROGRAM_MAP(royalmah_map)
31713173   MCFG_CPU_IO_MAP(royalmah_iomap)
3172   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3174   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, irq0_line_hold)
31733175
31743176   MCFG_NVRAM_ADD_0FILL("nvram")
31753177
r17996r17997
32003202   MCFG_CPU_ADD("sub", Z80, 4000000)        /* 4 MHz ? */
32013203   MCFG_CPU_PROGRAM_MAP(janoh_sub_map)
32023204   MCFG_CPU_IO_MAP(janoh_sub_iomap)
3203   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3205   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, irq0_line_hold)
32043206MACHINE_CONFIG_END
32053207
32063208static MACHINE_CONFIG_DERIVED( jansou, royalmah )
r17996r17997
32113213   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4.000 MHz */
32123214   MCFG_CPU_PROGRAM_MAP(jansou_sub_map)
32133215   MCFG_CPU_IO_MAP(jansou_sub_iomap)
3214   MCFG_CPU_PERIODIC_INT(irq0_line_hold,4000000/512)
3216   MCFG_CPU_PERIODIC_INT_DRIVER(royalmah_state, irq0_line_hold, 4000000/512)
32153217
32163218   MCFG_DAC_ADD("dac")
32173219   MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
r17996r17997
32463248   MCFG_CPU_IO_MAP(ippatsu_iomap)
32473249MACHINE_CONFIG_END
32483250
3249static INTERRUPT_GEN( suzume_irq )
3251INTERRUPT_GEN_MEMBER(royalmah_state::suzume_irq)
32503252{
3251   royalmah_state *state = device->machine().driver_data<royalmah_state>();
3252   if ( state->m_suzume_bank & 0x40 )
3253      device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
3253   if ( m_suzume_bank & 0x40 )
3254      device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
32543255}
32553256
32563257static MACHINE_CONFIG_DERIVED( suzume, dondenmj )
32573258   MCFG_CPU_MODIFY("maincpu")
32583259   MCFG_CPU_IO_MAP(suzume_iomap)
3259   MCFG_CPU_VBLANK_INT("screen", suzume_irq)
3260   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, suzume_irq)
32603261MACHINE_CONFIG_END
32613262
32623263static MACHINE_CONFIG_DERIVED( tontonb, dondenmj )
r17996r17997
33323333   MCFG_CPU_REPLACE("maincpu",TMP90841, 8000000)   /* ? */
33333334   MCFG_CPU_PROGRAM_MAP(mjifb_map)
33343335   MCFG_CPU_IO_MAP(mjifb_iomap)
3335   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3336   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, irq0_line_hold)
33363337
33373338   MCFG_SCREEN_MODIFY("screen")
33383339   MCFG_SCREEN_VISIBLE_AREA(0, 255, 8, 255-8)
r17996r17997
33433344   MCFG_CPU_REPLACE("maincpu",TMP90841, 8000000)   /* ? */
33443345   MCFG_CPU_PROGRAM_MAP(mjdejavu_map)
33453346   MCFG_CPU_IO_MAP(mjifb_iomap)
3346   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
3347   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, irq0_line_hold)
33473348
33483349   MCFG_SCREEN_MODIFY("screen")
33493350   MCFG_SCREEN_VISIBLE_AREA(0, 255, 8, 255-8)
33503351MACHINE_CONFIG_END
33513352
33523353
3353static INTERRUPT_GEN( mjtensin_interrupt )
3354INTERRUPT_GEN_MEMBER(royalmah_state::mjtensin_interrupt)
33543355{
3355   royalmah_state *state = device->machine().driver_data<royalmah_state>();
33563356
3357   state->m_maincpu->set_input_line(INPUT_LINE_IRQ0, HOLD_LINE);   // vblank
3357   m_maincpu->set_input_line(INPUT_LINE_IRQ0, HOLD_LINE);   // vblank
33583358}
33593359
33603360WRITE_LINE_MEMBER(royalmah_state::mjtensin_rtc_irq)
r17996r17997
33733373   MCFG_CPU_REPLACE("maincpu",TMP90841, 12000000)   /* ? */
33743374   MCFG_CPU_PROGRAM_MAP(mjtensin_map)
33753375   MCFG_CPU_IO_MAP(mjtensin_iomap)
3376   MCFG_CPU_VBLANK_INT("screen", mjtensin_interrupt)
3376   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, mjtensin_interrupt)
33773377
33783378   MCFG_SCREEN_MODIFY("screen")
33793379   MCFG_SCREEN_VISIBLE_AREA(0, 255, 8, 255-8)
r17996r17997
33863386   MCFG_CPU_REPLACE("maincpu",TMP90841, 12000000)   /* ? */
33873387   MCFG_CPU_PROGRAM_MAP(cafetime_map)
33883388   MCFG_CPU_IO_MAP(cafetime_iomap)
3389   MCFG_CPU_VBLANK_INT("screen", mjtensin_interrupt)
3389   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, mjtensin_interrupt)
33903390
33913391   MCFG_SCREEN_MODIFY("screen")
33923392   MCFG_SCREEN_VISIBLE_AREA(0, 255, 8, 255-8)
r17996r17997
33993399   MCFG_CPU_REPLACE("maincpu",TMP90841, XTAL_8MHz)   /* ? */
34003400   MCFG_CPU_PROGRAM_MAP(mjvegasa_map)
34013401   MCFG_CPU_IO_MAP(mjvegasa_iomap)
3402   MCFG_CPU_VBLANK_INT("screen", mjtensin_interrupt)
3402   MCFG_CPU_VBLANK_INT_DRIVER("screen", royalmah_state, mjtensin_interrupt)
34033403
34043404   MCFG_SCREEN_MODIFY("screen")
34053405   MCFG_SCREEN_VISIBLE_AREA(0, 255, 8, 255-8)
trunk/src/mame/drivers/crospang.c
r17996r17997
349349   /* basic machine hardware */
350350   MCFG_CPU_ADD("maincpu", M68000, 14318180)
351351   MCFG_CPU_PROGRAM_MAP(crospang_map)
352   MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
352   MCFG_CPU_VBLANK_INT_DRIVER("screen", crospang_state, irq6_line_hold)
353353
354354   MCFG_CPU_ADD("audiocpu", Z80, 14318180/4)
355355   MCFG_CPU_PROGRAM_MAP(crospang_sound_map)
trunk/src/mame/drivers/subs.c
r17996r17997
179179   /* basic machine hardware */
180180   MCFG_CPU_ADD("maincpu", M6502,12096000/16)      /* clock input is the "4H" signal */
181181   MCFG_CPU_PROGRAM_MAP(main_map)
182   MCFG_CPU_PERIODIC_INT(subs_interrupt,4*57)
182   MCFG_CPU_PERIODIC_INT_DRIVER(subs_state, subs_interrupt, 4*57)
183183
184184
185185   /* video hardware */
trunk/src/mame/drivers/ajax.c
r17996r17997
210210   /* basic machine hardware */
211211   MCFG_CPU_ADD("maincpu", KONAMI, 3000000)   /* 12/4 MHz*/
212212   MCFG_CPU_PROGRAM_MAP(ajax_main_map)
213   MCFG_CPU_VBLANK_INT("screen", ajax_interrupt)   /* IRQs triggered by the 051960 */
213   MCFG_CPU_VBLANK_INT_DRIVER("screen", ajax_state, ajax_interrupt)   /* IRQs triggered by the 051960 */
214214
215215   MCFG_CPU_ADD("sub", M6809, 3000000)   /* ? */
216216   MCFG_CPU_PROGRAM_MAP(ajax_sub_map)
trunk/src/mame/drivers/funybubl.c
r17996r17997
221221   MCFG_CPU_ADD("maincpu", Z80,12000000/2)       /* 6 MHz?? */
222222   MCFG_CPU_PROGRAM_MAP(funybubl_map)
223223   MCFG_CPU_IO_MAP(io_map)
224   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
224   MCFG_CPU_VBLANK_INT_DRIVER("screen", funybubl_state, irq0_line_hold)
225225
226226   MCFG_CPU_ADD("audiocpu", Z80,8000000/2)       /* 4 MHz?? */
227227   MCFG_CPU_PROGRAM_MAP(sound_map)
trunk/src/mame/drivers/shisen.c
r17996r17997
215215   MCFG_CPU_ADD("maincpu", Z80, 6000000)   /* 6 MHz ? */
216216   MCFG_CPU_PROGRAM_MAP(shisen_map)
217217   MCFG_CPU_IO_MAP(shisen_io_map)
218   MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
218   MCFG_CPU_VBLANK_INT_DRIVER("screen", shisen_state, irq0_line_hold)
219219
220220   MCFG_CPU_ADD("soundcpu", Z80, 3579645)
221221   MCFG_CPU_PROGRAM_MAP(shisen_sound_map)
222222   MCFG_CPU_IO_MAP(shisen_sound_io_map)
223   MCFG_CPU_PERIODIC_INT(nmi_line_pulse,128*55)   /* clocked by V1? (Vigilante) */
223   MCFG_CPU_PERIODIC_INT_DRIVER(shisen_state, nmi_line_pulse, 128*55)   /* clocked by V1? (Vigilante) */
224224                        /* IRQs are generated by main Z80 and YM2151 */
225225   /* video hardware */
226226   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/mame/drivers/nmk16.c
r17996r17997
35493549   /* basic machine hardware */
35503550   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz */
35513551   MCFG_CPU_PROGRAM_MAP(tharrier_map)
3552   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3552   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
35533553   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
35543554
35553555   MCFG_CPU_ADD("audiocpu", Z80, 3000000)
r17996r17997
35943594   /* basic machine hardware */
35953595   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10? MHz - check */
35963596   MCFG_CPU_PROGRAM_MAP(manybloc_map)
3597   MCFG_CPU_PERIODIC_INT(irq1_line_hold,56)/* this needs to equal the framerate on this, rather than being double it .. */
3597   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 56)/* this needs to equal the framerate on this, rather than being double it .. */
35983598   MCFG_TIMER_ADD_SCANLINE("scantimer", manybloc_scanline, "screen", 0, 1)
35993599
36003600   MCFG_CPU_ADD("audiocpu", Z80, 3000000)
r17996r17997
36373637   /* basic machine hardware */
36383638   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
36393639   MCFG_CPU_PROGRAM_MAP(mustang_map)
3640   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3640   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
36413641   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
36423642
36433643   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
36783678   /* basic machine hardware */
36793679   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
36803680   MCFG_CPU_PROGRAM_MAP(mustangb_map)
3681   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3681   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
36823682   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
36833683
36843684   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
r17996r17997
37123712   /* basic machine hardware */
37133713   MCFG_CPU_ADD("maincpu", M68000, BIOSHIP_CRYSTAL1 ) /* 10.0 MHz (verified) */
37143714   MCFG_CPU_PROGRAM_MAP(bioship_map)
3715   MCFG_CPU_PERIODIC_INT(irq1_line_hold,100)/* 112 breaks the title screen */
3715   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 100)/* 112 breaks the title screen */
37163716   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
37173717
37183718   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
37533753   /* basic machine hardware */
37543754   MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz) /* 68000p12 running at 10Mhz, verified on pcb */
37553755   MCFG_CPU_PROGRAM_MAP(vandyke_map)
3756   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3756   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
37573757   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
37583758
37593759   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
37943794   /* basic machine hardware */
37953795   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
37963796   MCFG_CPU_PROGRAM_MAP(vandykeb_map)
3797   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3797   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
37983798   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
37993799
38003800   MCFG_CPU_ADD("mcu", PIC16C57, 12000000)   /* 3MHz */
r17996r17997
38283828   /* basic machine hardware */
38293829   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz (verified on pcb) */
38303830   MCFG_CPU_PROGRAM_MAP(acrobatm_map)
3831   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3831   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
38323832   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
38333833
38343834   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
38703870   /* basic machine hardware */
38713871   MCFG_CPU_ADD("maincpu", M68000, 10000000)
38723872   MCFG_CPU_PROGRAM_MAP(tdragonb_map)
3873   //MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3874   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ?? drives music */
3873   //MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
3874   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ?? drives music */
38753875   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
38763876
38773877   SEIBU_SOUND_SYSTEM_CPU(14318180/4)
r17996r17997
39013901   /* basic machine hardware */
39023902   MCFG_CPU_ADD("maincpu", M68000, XTAL_8MHz) /* verified on pcb */
39033903   MCFG_CPU_PROGRAM_MAP(tdragon_map)
3904   //MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3905   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ?? drives music */
3904   //MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
3905   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ?? drives music */
39063906   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
39073907
39083908   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
39443944   /* basic machine hardware */
39453945   MCFG_CPU_ADD("maincpu", M68000, 8000000) /* 8 Mhz */
39463946   MCFG_CPU_PROGRAM_MAP(ssmissin_map)
3947   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
3948   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112) /* input related */
3947   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
3948   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112) /* input related */
39493949
39503950   MCFG_CPU_ADD("audiocpu", Z80, 8000000/2) /* 4 Mhz */
39513951   MCFG_CPU_PROGRAM_MAP(ssmissin_sound_map)
r17996r17997
39773977   /* basic machine hardware */
39783978   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* 12 MHz ? */
39793979   MCFG_CPU_PROGRAM_MAP(strahl_map)
3980   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
3980   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
39813981   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
39823982
39833983   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
r17996r17997
40184018   /* basic machine hardware */
40194019   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
40204020   MCFG_CPU_PROGRAM_MAP(hachamf_map)
4021   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4022   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4021   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4022   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
40234023
40244024   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
40254025
r17996r17997
40604060   /* basic machine hardware */
40614061   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
40624062   MCFG_CPU_PROGRAM_MAP(macross_map)
4063   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4064   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4063   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4064   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
40654065
40664066   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
40674067
r17996r17997
41014101   /* basic machine hardware */
41024102   MCFG_CPU_ADD("maincpu", M68000, XTAL_8MHz) /* verified on pcb */
41034103   MCFG_CPU_PROGRAM_MAP(macross_map)
4104   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4105   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4104   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4105   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
41064106
41074107   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
41084108
r17996r17997
41424142   /* basic machine hardware */
41434143   MCFG_CPU_ADD("maincpu", M68000, 12000000) /* 12 MHz? */
41444144   MCFG_CPU_PROGRAM_MAP(gunnail_map)
4145   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4146   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)
4145   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4146   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)
41474147
41484148   MCFG_MACHINE_RESET_OVERRIDE(nmk16_state,NMK004)
41494149
r17996r17997
41834183   /* basic machine hardware */
41844184   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz ? */
41854185   MCFG_CPU_PROGRAM_MAP(macross2_map)
4186   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4187   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4186   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4187   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
41884188
41894189   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz ? */
41904190   MCFG_CPU_PROGRAM_MAP(macross2_sound_map)
r17996r17997
42254225   /* basic machine hardware */
42264226   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz  */
42274227   MCFG_CPU_PROGRAM_MAP(macross2_map)
4228   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4229   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4228   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4229   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
42304230
42314231   MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz  */
42324232   MCFG_CPU_PROGRAM_MAP(macross2_sound_map)
r17996r17997
42674267   /* basic machine hardware */
42684268   MCFG_CPU_ADD("maincpu", M68000, 14000000) /* 14 MHz measured */
42694269   MCFG_CPU_PROGRAM_MAP(raphero_map)
4270   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4271   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4270   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4271   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
42724272
42734273   MCFG_CPU_ADD("audiocpu",TMP90841, 8000000)
42744274   MCFG_CPU_PROGRAM_MAP(raphero_sound_mem_map)
r17996r17997
43084308   /* basic machine hardware */
43094309   MCFG_CPU_ADD("maincpu", M68000, 10000000) /* verified on pcb */
43104310   MCFG_CPU_PROGRAM_MAP(bjtwin_map)
4311   MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
4312   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ?? drives music */
4311   MCFG_CPU_VBLANK_INT_DRIVER("screen", nmk16_state,  irq4_line_hold)
4312   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ?? drives music */
43134313
43144314   /* video hardware */
43154315   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
49344934   /* basic machine hardware */
49354935   MCFG_CPU_ADD("maincpu", M68000,12000000)
49364936   MCFG_CPU_PROGRAM_MAP(twinactn_map)
4937   MCFG_CPU_PERIODIC_INT(irq1_line_hold,112)/* ???????? */
4937   MCFG_CPU_PERIODIC_INT_DRIVER(nmk16_state, irq1_line_hold, 112)/* ???????? */
49384938   MCFG_TIMER_ADD_SCANLINE("scantimer", nmk16_scanline, "screen", 0, 1)
49394939
49404940   MCFG_CPU_ADD("audiocpu", Z80, 4000000)
trunk/src/mame/drivers/miniboy7.c
r17996r17997
451451   /* basic machine hardware */
452452   MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/16)   /* guess */
453453   MCFG_CPU_PROGRAM_MAP(miniboy7_map)
454   MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
454   MCFG_CPU_VBLANK_INT_DRIVER("screen", miniboy7_state, nmi_line_pulse)
455455
456456   MCFG_NVRAM_ADD_0FILL("nvram")
457457   MCFG_PIA6821_ADD("pia0", miniboy7_pia0_intf)
trunk/src/mame/drivers/m10.c
r17996r17997
523523}
524524
525525#if 0
526static INTERRUPT_GEN( m11_interrupt )
526INTERRUPT_GEN_MEMBER(m10_state::m11_interrupt)
527527{
528   device->execute().set_input_line(0, ASSERT_LINE);
529   //device->machine().scheduler().timer_set(machine.primary_screen->time_until_pos(IREMM10_VBEND), FUNC(interrupt_callback), -1);
528   device.execute().set_input_line(0, ASSERT_LINE);
529   //machine().scheduler().timer_set(machine.primary_screen->time_until_pos(IREMM10_VBEND), FUNC(interrupt_callback), -1);
530530}
531531
532static INTERRUPT_GEN( m10_interrupt )
532INTERRUPT_GEN_MEMBER(m10_state::m10_interrupt)
533533{
534   device->execute().set_input_line(0, ASSERT_LINE);
534   device.execute().set_input_line(0, ASSERT_LINE);
535535}
536536#endif
537537
538static INTERRUPT_GEN( m15_interrupt )
538INTERRUPT_GEN_MEMBER(m10_state::m15_interrupt)
539539{
540   device->execute().set_input_line(0, ASSERT_LINE);
541   device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_pos(IREMM10_VBSTART + 1, 80), FUNC(interrupt_callback), -1);
540   device.execute().set_input_line(0, ASSERT_LINE);
541   machine().scheduler().timer_set(machine().primary_screen->time_until_pos(IREMM10_VBSTART + 1, 80), FUNC(interrupt_callback), -1);
542542}
543543
544544/*************************************
r17996r17997
832832   MCFG_MACHINE_START_OVERRIDE(m10_state,m10)
833833   MCFG_MACHINE_RESET_OVERRIDE(m10_state,m10)
834834
835   //MCFG_CPU_VBLANK_INT("screen", m10_interrupt)
835   //MCFG_CPU_VBLANK_INT_DRIVER("screen", m10_state, m10_interrupt)
836836
837837   /* video hardware */
838838   MCFG_SCREEN_ADD("screen", RASTER)
r17996r17997
863863   /* basic machine hardware */
864864   MCFG_CPU_MODIFY("maincpu")
865865   MCFG_CPU_PROGRAM_MAP(m11_main)
866   //MCFG_CPU_VBLANK_INT("screen", m11_interrupt)
866   //MCFG_CPU_VBLANK_INT_DRIVER("screen", m10_state, m11_interrupt)
867867
868868   /* sound hardware */
869869MACHINE_CONFIG_END
r17996r17997
877877   MCFG_MACHINE_START_OVERRIDE(m10_state,m10)
878878   MCFG_MACHINE_RESET_OVERRIDE(m10_state,m10)
879879
880   MCFG_CPU_VBLANK_INT("screen", m15_interrupt)
880   MCFG_CPU_VBLANK_INT_DRIVER("screen", m10_state, m15_interrupt)
881881
882882   /* video hardware */
883883   MCFG_SCREEN_ADD("screen", RASTER)
trunk/src/emu/devcpu.h
r17996r17997
195195#define MCFG_CPU_VBLANK_INT MCFG_DEVICE_VBLANK_INT
196196#define MCFG_CPU_PERIODIC_INT MCFG_DEVICE_PERIODIC_INT
197197
198#define MCFG_CPU_VBLANK_INT_DRIVER MCFG_DEVICE_VBLANK_INT_DRIVER
199#define MCFG_CPU_PERIODIC_INT_DRIVER MCFG_DEVICE_PERIODIC_INT_DRIVER
198200
199201
200202//**************************************************************************

Previous 199869 Revisions Next


© 1997-2024 The MAME Team