summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatarGravatar Miodrag Milanovic <mmicko@gmail.com>2012-09-18 14:10:42 +0000
committerGravatarGravatar Miodrag Milanovic <mmicko@gmail.com>2012-09-18 14:10:42 +0000
commit3ac43e0187323c2b55dc00c79c31bdd2d50d9b20 (patch) (github)
treef3d239297dce0fbae1086ee57ff792c151d0ac52
parente58642872abb95b7ac7f6444abb75a8c33bcb068 (diff)
downloadmame-3ac43e0187323c2b55dc00c79c31bdd2d50d9b20.tar.bz2
mame-3ac43e0187323c2b55dc00c79c31bdd2d50d9b20.zip
INTERRUPT_GEN -> INTERRUPT_GEN_MEMBER (no whatsnew)
-rw-r--r--src/emu/devcpu.h2
-rw-r--r--src/mame/audio/aztarac.c9
-rw-r--r--src/mame/audio/cyberbal.c9
-rw-r--r--src/mame/audio/dkong.c4
-rw-r--r--src/mame/audio/redalert.c4
-rw-r--r--src/mame/drivers/1942.c2
-rw-r--r--src/mame/drivers/1943.c4
-rw-r--r--src/mame/drivers/1945kiii.c2
-rw-r--r--src/mame/drivers/20pacgal.c9
-rw-r--r--src/mame/drivers/2mindril.c14
-rw-r--r--src/mame/drivers/39in1.c5
-rw-r--r--src/mame/drivers/40love.c8
-rw-r--r--src/mame/drivers/4enraya.c2
-rw-r--r--src/mame/drivers/4roses.c2
-rw-r--r--src/mame/drivers/5clown.c2
-rw-r--r--src/mame/drivers/8080bw.c17
-rw-r--r--src/mame/drivers/88games.c7
-rw-r--r--src/mame/drivers/acefruit.c10
-rw-r--r--src/mame/drivers/actfancr.c4
-rw-r--r--src/mame/drivers/adp.c9
-rw-r--r--src/mame/drivers/aeroboto.c13
-rw-r--r--src/mame/drivers/aerofgt.c24
-rw-r--r--src/mame/drivers/airbustr.c8
-rw-r--r--src/mame/drivers/ajax.c2
-rw-r--r--src/mame/drivers/albazc.c2
-rw-r--r--src/mame/drivers/albazg.c2
-rw-r--r--src/mame/drivers/aliens.c9
-rw-r--r--src/mame/drivers/alpha68k.c55
-rw-r--r--src/mame/drivers/amaticmg.c12
-rw-r--r--src/mame/drivers/ambush.c2
-rw-r--r--src/mame/drivers/ampoker2.c2
-rw-r--r--src/mame/drivers/amspdwy.c2
-rw-r--r--src/mame/drivers/angelkds.c2
-rw-r--r--src/mame/drivers/appoooh.c9
-rw-r--r--src/mame/drivers/aquarium.c2
-rw-r--r--src/mame/drivers/arabian.c2
-rw-r--r--src/mame/drivers/aristmk4.c4
-rw-r--r--src/mame/drivers/arkanoid.c6
-rw-r--r--src/mame/drivers/armedf.c32
-rw-r--r--src/mame/drivers/ashnojoe.c2
-rw-r--r--src/mame/drivers/asterix.c9
-rw-r--r--src/mame/drivers/asteroid.c6
-rw-r--r--src/mame/drivers/astinvad.c2
-rw-r--r--src/mame/drivers/astrocorp.c2
-rw-r--r--src/mame/drivers/asuka.c18
-rw-r--r--src/mame/drivers/atarifb.c2
-rw-r--r--src/mame/drivers/atarisy2.c9
-rw-r--r--src/mame/drivers/atarisy4.c7
-rw-r--r--src/mame/drivers/atronic.c2
-rw-r--r--src/mame/drivers/attckufo.c8
-rw-r--r--src/mame/drivers/avalnche.c2
-rw-r--r--src/mame/drivers/avt.c8
-rw-r--r--src/mame/drivers/aztarac.c4
-rw-r--r--src/mame/drivers/backfire.c7
-rw-r--r--src/mame/drivers/badlands.c15
-rw-r--r--src/mame/drivers/bagman.c13
-rw-r--r--src/mame/drivers/balsente.c2
-rw-r--r--src/mame/drivers/bankp.c9
-rw-r--r--src/mame/drivers/baraduke.c4
-rw-r--r--src/mame/drivers/battlane.c11
-rw-r--r--src/mame/drivers/battlex.c9
-rw-r--r--src/mame/drivers/battlnts.c9
-rw-r--r--src/mame/drivers/bbusters.c4
-rw-r--r--src/mame/drivers/bestleag.c2
-rw-r--r--src/mame/drivers/bfcobra.c17
-rw-r--r--src/mame/drivers/bfm_sc1.c14
-rw-r--r--src/mame/drivers/bfm_sc2.c20
-rw-r--r--src/mame/drivers/bfm_sc5.c7
-rw-r--r--src/mame/drivers/bfmsys85.c12
-rw-r--r--src/mame/drivers/bigevglf.c6
-rw-r--r--src/mame/drivers/bigstrkb.c2
-rw-r--r--src/mame/drivers/bingoc.c4
-rw-r--r--src/mame/drivers/bingor.c18
-rw-r--r--src/mame/drivers/bionicc.c2
-rw-r--r--src/mame/drivers/bking.c4
-rw-r--r--src/mame/drivers/blackt96.c2
-rw-r--r--src/mame/drivers/blitz.c2
-rw-r--r--src/mame/drivers/blitz68k.c14
-rw-r--r--src/mame/drivers/blktiger.c4
-rw-r--r--src/mame/drivers/blmbycar.c4
-rw-r--r--src/mame/drivers/blockade.c13
-rw-r--r--src/mame/drivers/blockhl.c9
-rw-r--r--src/mame/drivers/bloodbro.c6
-rw-r--r--src/mame/drivers/blueprnt.c4
-rw-r--r--src/mame/drivers/bmcbowl.c2
-rw-r--r--src/mame/drivers/bmcpokr.c2
-rw-r--r--src/mame/drivers/bogeyman.c2
-rw-r--r--src/mame/drivers/bombjack.c11
-rw-r--r--src/mame/drivers/boogwing.c2
-rw-r--r--src/mame/drivers/bottom9.c18
-rw-r--r--src/mame/drivers/brkthru.c11
-rw-r--r--src/mame/drivers/btoads.c2
-rw-r--r--src/mame/drivers/bublbobl.c12
-rw-r--r--src/mame/drivers/buggychl.c4
-rw-r--r--src/mame/drivers/buster.c2
-rw-r--r--src/mame/drivers/bwidow.c2
-rw-r--r--src/mame/drivers/bwing.c9
-rw-r--r--src/mame/drivers/bzone.c10
-rw-r--r--src/mame/drivers/cabal.c8
-rw-r--r--src/mame/drivers/cabaret.c10
-rw-r--r--src/mame/drivers/calomega.c2
-rw-r--r--src/mame/drivers/calorie.c4
-rw-r--r--src/mame/drivers/canyon.c2
-rw-r--r--src/mame/drivers/capbowl.c8
-rw-r--r--src/mame/drivers/cardline.c2
-rw-r--r--src/mame/drivers/carjmbre.c11
-rw-r--r--src/mame/drivers/carpolo.c2
-rw-r--r--src/mame/drivers/carrera.c2
-rw-r--r--src/mame/drivers/caswin.c2
-rw-r--r--src/mame/drivers/cave.c35
-rw-r--r--src/mame/drivers/cb2001.c7
-rw-r--r--src/mame/drivers/cbasebal.c2
-rw-r--r--src/mame/drivers/cbuster.c2
-rw-r--r--src/mame/drivers/cchance.c2
-rw-r--r--src/mame/drivers/cclimber.c13
-rw-r--r--src/mame/drivers/cesclass.c4
-rw-r--r--src/mame/drivers/chaknpop.c2
-rw-r--r--src/mame/drivers/champbas.c17
-rw-r--r--src/mame/drivers/champbwl.c4
-rw-r--r--src/mame/drivers/chance32.c2
-rw-r--r--src/mame/drivers/changela.c7
-rw-r--r--src/mame/drivers/cheekyms.c9
-rw-r--r--src/mame/drivers/chinsan.c2
-rw-r--r--src/mame/drivers/chsuper.c2
-rw-r--r--src/mame/drivers/circusc.c9
-rw-r--r--src/mame/drivers/cischeat.c6
-rw-r--r--src/mame/drivers/citycon.c4
-rw-r--r--src/mame/drivers/clayshoo.c2
-rw-r--r--src/mame/drivers/cloak.c4
-rw-r--r--src/mame/drivers/clshroad.c8
-rw-r--r--src/mame/drivers/cmmb.c11
-rw-r--r--src/mame/drivers/cninja.c12
-rw-r--r--src/mame/drivers/cntsteer.c20
-rw-r--r--src/mame/drivers/cobra.c12
-rw-r--r--src/mame/drivers/coinmstr.c2
-rw-r--r--src/mame/drivers/coinmvga.c7
-rw-r--r--src/mame/drivers/combatsc.c6
-rw-r--r--src/mame/drivers/commando.c8
-rw-r--r--src/mame/drivers/compgolf.c2
-rw-r--r--src/mame/drivers/contra.c11
-rw-r--r--src/mame/drivers/coolridr.c7
-rw-r--r--src/mame/drivers/cop01.c4
-rw-r--r--src/mame/drivers/corona.c16
-rw-r--r--src/mame/drivers/cps1.c20
-rw-r--r--src/mame/drivers/cps3.c12
-rw-r--r--src/mame/drivers/crbaloon.c9
-rw-r--r--src/mame/drivers/crgolf.c4
-rw-r--r--src/mame/drivers/crimfght.c9
-rw-r--r--src/mame/drivers/crospang.c2
-rw-r--r--src/mame/drivers/crshrace.c2
-rw-r--r--src/mame/drivers/crystal.c7
-rw-r--r--src/mame/drivers/cubeqst.c12
-rw-r--r--src/mame/drivers/cultures.c10
-rw-r--r--src/mame/drivers/cvs.c10
-rw-r--r--src/mame/drivers/cyberbal.c2
-rw-r--r--src/mame/drivers/cybertnk.c4
-rw-r--r--src/mame/drivers/cyclemb.c2
-rw-r--r--src/mame/drivers/d9final.c2
-rw-r--r--src/mame/drivers/dacholer.c12
-rw-r--r--src/mame/drivers/dai3wksi.c2
-rw-r--r--src/mame/drivers/darius.c4
-rw-r--r--src/mame/drivers/darkseal.c2
-rw-r--r--src/mame/drivers/dassault.c4
-rw-r--r--src/mame/drivers/dblewing.c2
-rw-r--r--src/mame/drivers/dcheese.c8
-rw-r--r--src/mame/drivers/dcon.c4
-rw-r--r--src/mame/drivers/ddayjlc.c20
-rw-r--r--src/mame/drivers/ddealer.c9
-rw-r--r--src/mame/drivers/ddribble.c18
-rw-r--r--src/mame/drivers/ddz.c5
-rw-r--r--src/mame/drivers/dec0.c20
-rw-r--r--src/mame/drivers/dec8.c32
-rw-r--r--src/mame/drivers/deco156.c9
-rw-r--r--src/mame/drivers/deco32.c16
-rw-r--r--src/mame/drivers/deco_ld.c10
-rw-r--r--src/mame/drivers/deniam.c4
-rw-r--r--src/mame/drivers/deshoros.c2
-rw-r--r--src/mame/drivers/destroyr.c2
-rw-r--r--src/mame/drivers/dietgo.c2
-rw-r--r--src/mame/drivers/discoboy.c4
-rw-r--r--src/mame/drivers/diverboy.c2
-rw-r--r--src/mame/drivers/djboy.c4
-rw-r--r--src/mame/drivers/djmain.c13
-rw-r--r--src/mame/drivers/dkong.c17
-rw-r--r--src/mame/drivers/dlair.c13
-rw-r--r--src/mame/drivers/dmndrby.c14
-rw-r--r--src/mame/drivers/docastle.c6
-rw-r--r--src/mame/drivers/dogfgt.c2
-rw-r--r--src/mame/drivers/dominob.c2
-rw-r--r--src/mame/drivers/dooyong.c12
-rw-r--r--src/mame/drivers/dorachan.c2
-rw-r--r--src/mame/drivers/dotrikun.c2
-rw-r--r--src/mame/drivers/dragrace.c2
-rw-r--r--src/mame/drivers/dreamwld.c4
-rw-r--r--src/mame/drivers/drgnmst.c2
-rw-r--r--src/mame/drivers/dribling.c9
-rw-r--r--src/mame/drivers/drmicro.c9
-rw-r--r--src/mame/drivers/drtomy.c2
-rw-r--r--src/mame/drivers/drw80pkr.c2
-rw-r--r--src/mame/drivers/dunhuang.c2
-rw-r--r--src/mame/drivers/dynax.c65
-rw-r--r--src/mame/drivers/dynduke.c8
-rw-r--r--src/mame/drivers/egghunt.c2
-rw-r--r--src/mame/drivers/enigma2.c4
-rw-r--r--src/mame/drivers/epos.c4
-rw-r--r--src/mame/drivers/ertictac.c7
-rw-r--r--src/mame/drivers/esd16.c4
-rw-r--r--src/mame/drivers/esh.c9
-rw-r--r--src/mame/drivers/espial.c7
-rw-r--r--src/mame/drivers/esripsys.c2
-rw-r--r--src/mame/drivers/ettrivia.c11
-rw-r--r--src/mame/drivers/exedexes.c2
-rw-r--r--src/mame/drivers/exidy.c4
-rw-r--r--src/mame/drivers/exidy440.c2
-rw-r--r--src/mame/drivers/exprraid.c17
-rw-r--r--src/mame/drivers/exzisus.c6
-rw-r--r--src/mame/drivers/f-32.c2
-rw-r--r--src/mame/drivers/f1gp.c8
-rw-r--r--src/mame/drivers/fantland.c21
-rw-r--r--src/mame/drivers/fastfred.c18
-rw-r--r--src/mame/drivers/fcrash.c6
-rw-r--r--src/mame/drivers/feversoc.c7
-rw-r--r--src/mame/drivers/firebeat.c9
-rw-r--r--src/mame/drivers/firetrap.c11
-rw-r--r--src/mame/drivers/firetrk.c9
-rw-r--r--src/mame/drivers/fitfight.c10
-rw-r--r--src/mame/drivers/flipjack.c4
-rw-r--r--src/mame/drivers/flkatck.c9
-rw-r--r--src/mame/drivers/flower.c6
-rw-r--r--src/mame/drivers/flstory.c16
-rw-r--r--src/mame/drivers/flyball.c2
-rw-r--r--src/mame/drivers/fortecar.c2
-rw-r--r--src/mame/drivers/freekick.c11
-rw-r--r--src/mame/drivers/fromanc2.c10
-rw-r--r--src/mame/drivers/fromance.c6
-rw-r--r--src/mame/drivers/funkybee.c2
-rw-r--r--src/mame/drivers/funkyjet.c2
-rw-r--r--src/mame/drivers/funworld.c18
-rw-r--r--src/mame/drivers/funybubl.c2
-rw-r--r--src/mame/drivers/gaelco.c8
-rw-r--r--src/mame/drivers/gaelco2.c10
-rw-r--r--src/mame/drivers/gaelco3d.c10
-rw-r--r--src/mame/drivers/gaiden.c6
-rw-r--r--src/mame/drivers/gal3.c6
-rw-r--r--src/mame/drivers/galaga.c32
-rw-r--r--src/mame/drivers/galastrm.c9
-rw-r--r--src/mame/drivers/galaxi.c2
-rw-r--r--src/mame/drivers/galaxia.c10
-rw-r--r--src/mame/drivers/galaxian.c26
-rw-r--r--src/mame/drivers/galaxold.c17
-rw-r--r--src/mame/drivers/galgame.c12
-rw-r--r--src/mame/drivers/galivan.c8
-rw-r--r--src/mame/drivers/galspnbl.c2
-rw-r--r--src/mame/drivers/gamtor.c2
-rw-r--r--src/mame/drivers/gaplus.c35
-rw-r--r--src/mame/drivers/gatron.c2
-rw-r--r--src/mame/drivers/gberet.c4
-rw-r--r--src/mame/drivers/gbusters.c9
-rw-r--r--src/mame/drivers/gcpinbal.c10
-rw-r--r--src/mame/drivers/gei.c10
-rw-r--r--src/mame/drivers/gijoe.c17
-rw-r--r--src/mame/drivers/ginganin.c2
-rw-r--r--src/mame/drivers/gladiatr.c6
-rw-r--r--src/mame/drivers/glass.c11
-rw-r--r--src/mame/drivers/gng.c4
-rw-r--r--src/mame/drivers/go2000.c2
-rw-r--r--src/mame/drivers/goal92.c2
-rw-r--r--src/mame/drivers/goindol.c4
-rw-r--r--src/mame/drivers/goldngam.c2
-rw-r--r--src/mame/drivers/goldnpkr.c2
-rw-r--r--src/mame/drivers/goldstar.c53
-rw-r--r--src/mame/drivers/gomoku.c2
-rw-r--r--src/mame/drivers/good.c2
-rw-r--r--src/mame/drivers/goodejan.c7
-rw-r--r--src/mame/drivers/gotcha.c4
-rw-r--r--src/mame/drivers/gottlieb.c17
-rw-r--r--src/mame/drivers/gotya.c2
-rw-r--r--src/mame/drivers/gpworld.c18
-rw-r--r--src/mame/drivers/gradius3.c9
-rw-r--r--src/mame/drivers/grchamp.c20
-rw-r--r--src/mame/drivers/groundfx.c9
-rw-r--r--src/mame/drivers/gstream.c2
-rw-r--r--src/mame/drivers/gstriker.c4
-rw-r--r--src/mame/drivers/gsword.c15
-rw-r--r--src/mame/drivers/gticlub.c7
-rw-r--r--src/mame/drivers/gumbo.c2
-rw-r--r--src/mame/drivers/gunbustr.c8
-rw-r--r--src/mame/drivers/gunpey.c7
-rw-r--r--src/mame/drivers/gunsmoke.c4
-rw-r--r--src/mame/drivers/gyruss.c18
-rw-r--r--src/mame/drivers/halleys.c2
-rw-r--r--src/mame/drivers/hanaawas.c2
-rw-r--r--src/mame/drivers/harddriv.c2
-rw-r--r--src/mame/drivers/hcastle.c2
-rw-r--r--src/mame/drivers/highvdeo.c11
-rw-r--r--src/mame/drivers/himesiki.c2
-rw-r--r--src/mame/drivers/hitpoker.c7
-rw-r--r--src/mame/drivers/hnayayoi.c4
-rw-r--r--src/mame/drivers/holeland.c4
-rw-r--r--src/mame/drivers/homedata.c21
-rw-r--r--src/mame/drivers/homerun.c4
-rw-r--r--src/mame/drivers/hornet.c2
-rw-r--r--src/mame/drivers/hotblock.c7
-rw-r--r--src/mame/drivers/hotstuff.c2
-rw-r--r--src/mame/drivers/hvyunit.c4
-rw-r--r--src/mame/drivers/hyperspt.c9
-rw-r--r--src/mame/drivers/igs009.c10
-rw-r--r--src/mame/drivers/igs011.c22
-rw-r--r--src/mame/drivers/igs_m027.c7
-rw-r--r--src/mame/drivers/ikki.c2
-rw-r--r--src/mame/drivers/imolagp.c14
-rw-r--r--src/mame/drivers/intrscti.c2
-rw-r--r--src/mame/drivers/inufuku.c2
-rw-r--r--src/mame/drivers/invqix.c4
-rw-r--r--src/mame/drivers/istellar.c9
-rw-r--r--src/mame/drivers/itech32.c12
-rw-r--r--src/mame/drivers/itech8.c14
-rw-r--r--src/mame/drivers/jack.c16
-rw-r--r--src/mame/drivers/jackal.c11
-rw-r--r--src/mame/drivers/jackpool.c7
-rw-r--r--src/mame/drivers/jailbrek.c18
-rw-r--r--src/mame/drivers/jalmah.c2
-rw-r--r--src/mame/drivers/jangou.c2
-rw-r--r--src/mame/drivers/jantotsu.c2
-rw-r--r--src/mame/drivers/jclub2.c2
-rw-r--r--src/mame/drivers/jokrwild.c2
-rw-r--r--src/mame/drivers/jollyjgr.c10
-rw-r--r--src/mame/drivers/jongkyo.c2
-rw-r--r--src/mame/drivers/jrpacman.c10
-rw-r--r--src/mame/drivers/jubilee.c7
-rw-r--r--src/mame/drivers/junofrst.c12
-rw-r--r--src/mame/drivers/kangaroo.c4
-rw-r--r--src/mame/drivers/karnov.c29
-rw-r--r--src/mame/drivers/kchamp.c20
-rw-r--r--src/mame/drivers/kickgoal.c197
-rw-r--r--src/mame/drivers/kingdrby.c6
-rw-r--r--src/mame/drivers/kingobox.c23
-rw-r--r--src/mame/drivers/kingpin.c2
-rw-r--r--src/mame/drivers/kinst.c9
-rw-r--r--src/mame/drivers/kncljoe.c8
-rw-r--r--src/mame/drivers/koikoi.c2
-rw-r--r--src/mame/drivers/konamigq.c2
-rw-r--r--src/mame/drivers/konamigx.c16
-rw-r--r--src/mame/drivers/konamim2.c16
-rw-r--r--src/mame/drivers/kontest.c11
-rw-r--r--src/mame/drivers/kopunch.c8
-rw-r--r--src/mame/drivers/ksayakyu.c4
-rw-r--r--src/mame/drivers/kungfur.c10
-rw-r--r--src/mame/drivers/kyugo.c11
-rw-r--r--src/mame/drivers/labyrunr.c22
-rw-r--r--src/mame/drivers/ladybug.c4
-rw-r--r--src/mame/drivers/ladyfrog.c4
-rw-r--r--src/mame/drivers/laserbas.c2
-rw-r--r--src/mame/drivers/laserbat.c17
-rw-r--r--src/mame/drivers/lasso.c4
-rw-r--r--src/mame/drivers/lastbank.c2
-rw-r--r--src/mame/drivers/lastduel.c4
-rw-r--r--src/mame/drivers/lastfght.c10
-rw-r--r--src/mame/drivers/legionna.c14
-rw-r--r--src/mame/drivers/leland.c2
-rw-r--r--src/mame/drivers/lemmings.c2
-rw-r--r--src/mame/drivers/lethal.c9
-rw-r--r--src/mame/drivers/lgp.c12
-rw-r--r--src/mame/drivers/liberate.c27
-rw-r--r--src/mame/drivers/limenko.c4
-rw-r--r--src/mame/drivers/lkage.c4
-rw-r--r--src/mame/drivers/looping.c7
-rw-r--r--src/mame/drivers/lordgun.c4
-rw-r--r--src/mame/drivers/lsasquad.c4
-rw-r--r--src/mame/drivers/ltcasino.c2
-rw-r--r--src/mame/drivers/luckgrln.c10
-rw-r--r--src/mame/drivers/lucky74.c9
-rw-r--r--src/mame/drivers/lvcards.c2
-rw-r--r--src/mame/drivers/lwings.c22
-rw-r--r--src/mame/drivers/m10.c22
-rw-r--r--src/mame/drivers/m14.c9
-rw-r--r--src/mame/drivers/m52.c2
-rw-r--r--src/mame/drivers/m57.c2
-rw-r--r--src/mame/drivers/m58.c2
-rw-r--r--src/mame/drivers/m62.c2
-rw-r--r--src/mame/drivers/m63.c24
-rw-r--r--src/mame/drivers/m72.c44
-rw-r--r--src/mame/drivers/m79amb.c7
-rw-r--r--src/mame/drivers/m90.c44
-rw-r--r--src/mame/drivers/macrossp.c2
-rw-r--r--src/mame/drivers/macs.c2
-rw-r--r--src/mame/drivers/madalien.c2
-rw-r--r--src/mame/drivers/madmotor.c2
-rw-r--r--src/mame/drivers/magic10.c4
-rw-r--r--src/mame/drivers/magicard.c13
-rw-r--r--src/mame/drivers/magicfly.c2
-rw-r--r--src/mame/drivers/magmax.c2
-rw-r--r--src/mame/drivers/mainevt.c32
-rw-r--r--src/mame/drivers/mainsnk.c4
-rw-r--r--src/mame/drivers/majorpkr.c2
-rw-r--r--src/mame/drivers/mappy.c98
-rw-r--r--src/mame/drivers/marineb.c18
-rw-r--r--src/mame/drivers/marinedt.c2
-rw-r--r--src/mame/drivers/mario.c9
-rw-r--r--src/mame/drivers/markham.c4
-rw-r--r--src/mame/drivers/mastboy.c10
-rw-r--r--src/mame/drivers/matmania.c6
-rw-r--r--src/mame/drivers/maygayv1.c10
-rw-r--r--src/mame/drivers/mayumi.c10
-rw-r--r--src/mame/drivers/mazerbla.c13
-rw-r--r--src/mame/drivers/mcatadv.c2
-rw-r--r--src/mame/drivers/mcr68.c4
-rw-r--r--src/mame/drivers/meadows.c31
-rw-r--r--src/mame/drivers/megasys1.c6
-rw-r--r--src/mame/drivers/megazone.c11
-rw-r--r--src/mame/drivers/meijinsn.c2
-rw-r--r--src/mame/drivers/mermaid.c9
-rw-r--r--src/mame/drivers/metro.c118
-rw-r--r--src/mame/drivers/mexico86.c8
-rw-r--r--src/mame/drivers/micro3d.c2
-rw-r--r--src/mame/drivers/midas.c4
-rw-r--r--src/mame/drivers/midzeus.c10
-rw-r--r--src/mame/drivers/mikie.c9
-rw-r--r--src/mame/drivers/mil4000.c2
-rw-r--r--src/mame/drivers/miniboy7.c2
-rw-r--r--src/mame/drivers/minivadr.c2
-rw-r--r--src/mame/drivers/mirage.c2
-rw-r--r--src/mame/drivers/mirax.c12
-rw-r--r--src/mame/drivers/missb2.c13
-rw-r--r--src/mame/drivers/mitchell.c8
-rw-r--r--src/mame/drivers/mjkjidai.c9
-rw-r--r--src/mame/drivers/mjsister.c2
-rw-r--r--src/mame/drivers/mlanding.c6
-rw-r--r--src/mame/drivers/model2.c2
-rw-r--r--src/mame/drivers/mogura.c2
-rw-r--r--src/mame/drivers/mole.c2
-rw-r--r--src/mame/drivers/momoko.c2
-rw-r--r--src/mame/drivers/monzagp.c2
-rw-r--r--src/mame/drivers/moo.c26
-rw-r--r--src/mame/drivers/mosaic.c2
-rw-r--r--src/mame/drivers/mouser.c16
-rw-r--r--src/mame/drivers/mpoker.c2
-rw-r--r--src/mame/drivers/mpu4plasma.c2
-rw-r--r--src/mame/drivers/mrdo.c2
-rw-r--r--src/mame/drivers/mrflea.c2
-rw-r--r--src/mame/drivers/mrjong.c2
-rw-r--r--src/mame/drivers/msisaac.c4
-rw-r--r--src/mame/drivers/mugsmash.c2
-rw-r--r--src/mame/drivers/multfish.c2
-rw-r--r--src/mame/drivers/munchmo.c18
-rw-r--r--src/mame/drivers/murogem.c2
-rw-r--r--src/mame/drivers/mustache.c9
-rw-r--r--src/mame/drivers/mw18w.c2
-rw-r--r--src/mame/drivers/mwarr.c2
-rw-r--r--src/mame/drivers/mystwarr.c10
-rw-r--r--src/mame/drivers/namconb1.c30
-rw-r--r--src/mame/drivers/namcond1.c11
-rw-r--r--src/mame/drivers/namcos1.c8
-rw-r--r--src/mame/drivers/namcos2.c60
-rw-r--r--src/mame/drivers/namcos21.c32
-rw-r--r--src/mame/drivers/namcos22.c28
-rw-r--r--src/mame/drivers/namcos23.c24
-rw-r--r--src/mame/drivers/namcos86.c6
-rw-r--r--src/mame/drivers/nbmj9195.c6
-rw-r--r--src/mame/drivers/nemesis.c30
-rw-r--r--src/mame/drivers/neoprint.c8
-rw-r--r--src/mame/drivers/neptunp2.c2
-rw-r--r--src/mame/drivers/news.c2
-rw-r--r--src/mame/drivers/nightgal.c8
-rw-r--r--src/mame/drivers/ninjakd2.c6
-rw-r--r--src/mame/drivers/ninjaw.c8
-rw-r--r--src/mame/drivers/nitedrvr.c2
-rw-r--r--src/mame/drivers/niyanpai.c6
-rw-r--r--src/mame/drivers/nmg5.c2
-rw-r--r--src/mame/drivers/nmk16.c64
-rw-r--r--src/mame/drivers/norautp.c16
-rw-r--r--src/mame/drivers/nova2001.c12
-rw-r--r--src/mame/drivers/nsmpoker.c7
-rw-r--r--src/mame/drivers/nss.c11
-rw-r--r--src/mame/drivers/nycaptor.c18
-rw-r--r--src/mame/drivers/nyny.c12
-rw-r--r--src/mame/drivers/ohmygod.c2
-rw-r--r--src/mame/drivers/ojankohs.c8
-rw-r--r--src/mame/drivers/olibochu.c2
-rw-r--r--src/mame/drivers/omegrace.c4
-rw-r--r--src/mame/drivers/oneshot.c2
-rw-r--r--src/mame/drivers/onetwo.c2
-rw-r--r--src/mame/drivers/opwolf.c6
-rw-r--r--src/mame/drivers/orbit.c8
-rw-r--r--src/mame/drivers/othello.c2
-rw-r--r--src/mame/drivers/othldrby.c2
-rw-r--r--src/mame/drivers/othunder.c9
-rw-r--r--src/mame/drivers/overdriv.c9
-rw-r--r--src/mame/drivers/pachifev.c22
-rw-r--r--src/mame/drivers/pacland.c18
-rw-r--r--src/mame/drivers/pacman.c32
-rw-r--r--src/mame/drivers/pandoras.c18
-rw-r--r--src/mame/drivers/paradise.c11
-rw-r--r--src/mame/drivers/parodius.c9
-rw-r--r--src/mame/drivers/pasha2.c2
-rw-r--r--src/mame/drivers/pass.c4
-rw-r--r--src/mame/drivers/pastelg.c4
-rw-r--r--src/mame/drivers/pbaction.c15
-rw-r--r--src/mame/drivers/pcktgal.c2
-rw-r--r--src/mame/drivers/pengo.c10
-rw-r--r--src/mame/drivers/peyper.c2
-rw-r--r--src/mame/drivers/pgm.c2
-rw-r--r--src/mame/drivers/photon.c7
-rw-r--r--src/mame/drivers/pinkiri8.c2
-rw-r--r--src/mame/drivers/pipeline.c2
-rw-r--r--src/mame/drivers/pirates.c2
-rw-r--r--src/mame/drivers/pitnrun.c9
-rw-r--r--src/mame/drivers/pkscram.c2
-rw-r--r--src/mame/drivers/pktgaldx.c4
-rw-r--r--src/mame/drivers/playch10.c13
-rw-r--r--src/mame/drivers/playmark.c12
-rw-r--r--src/mame/drivers/plygonet.c12
-rw-r--r--src/mame/drivers/pokechmp.c4
-rw-r--r--src/mame/drivers/poker72.c2
-rw-r--r--src/mame/drivers/policetr.c8
-rw-r--r--src/mame/drivers/polyplay.c21
-rw-r--r--src/mame/drivers/poo.c6
-rw-r--r--src/mame/drivers/poolshrk.c2
-rw-r--r--src/mame/drivers/pooyan.c9
-rw-r--r--src/mame/drivers/popeye.c8
-rw-r--r--src/mame/drivers/popobear.c4
-rw-r--r--src/mame/drivers/popper.c11
-rw-r--r--src/mame/drivers/portrait.c2
-rw-r--r--src/mame/drivers/powerins.c4
-rw-r--r--src/mame/drivers/ppmast93.c4
-rw-r--r--src/mame/drivers/prehisle.c2
-rw-r--r--src/mame/drivers/progolf.c5
-rw-r--r--src/mame/drivers/psattack.c5
-rw-r--r--src/mame/drivers/psikyo.c8
-rw-r--r--src/mame/drivers/psikyo4.c6
-rw-r--r--src/mame/drivers/psikyosh.c6
-rw-r--r--src/mame/drivers/pturn.c20
-rw-r--r--src/mame/drivers/punchout.c11
-rw-r--r--src/mame/drivers/pushman.c4
-rw-r--r--src/mame/drivers/pzletime.c2
-rw-r--r--src/mame/drivers/qdrmfgp.c9
-rw-r--r--src/mame/drivers/quantum.c2
-rw-r--r--src/mame/drivers/quasar.c6
-rw-r--r--src/mame/drivers/quizdna.c2
-rw-r--r--src/mame/drivers/quizo.c2
-rw-r--r--src/mame/drivers/quizpani.c4
-rw-r--r--src/mame/drivers/quizpun2.c4
-rw-r--r--src/mame/drivers/r2dx_v33.c9
-rw-r--r--src/mame/drivers/rabbit.c8
-rw-r--r--src/mame/drivers/raiden.c8
-rw-r--r--src/mame/drivers/raiden2.c8
-rw-r--r--src/mame/drivers/rainbow.c4
-rw-r--r--src/mame/drivers/rallyx.c18
-rw-r--r--src/mame/drivers/rastan.c2
-rw-r--r--src/mame/drivers/rbmk.c9
-rw-r--r--src/mame/drivers/rcorsair.c2
-rw-r--r--src/mame/drivers/realbrk.c6
-rw-r--r--src/mame/drivers/redalert.c16
-rw-r--r--src/mame/drivers/retofinv.c20
-rw-r--r--src/mame/drivers/rgum.c2
-rw-r--r--src/mame/drivers/rltennis.c11
-rw-r--r--src/mame/drivers/rmhaihai.c2
-rw-r--r--src/mame/drivers/rockrage.c9
-rw-r--r--src/mame/drivers/rocnrope.c9
-rw-r--r--src/mame/drivers/rohga.c8
-rw-r--r--src/mame/drivers/rollerg.c2
-rw-r--r--src/mame/drivers/rollrace.c18
-rw-r--r--src/mame/drivers/roul.c2
-rw-r--r--src/mame/drivers/route16.c4
-rw-r--r--src/mame/drivers/royalmah.c32
-rw-r--r--src/mame/drivers/rungun.c18
-rw-r--r--src/mame/drivers/sandscrp.c10
-rw-r--r--src/mame/drivers/sauro.c8
-rw-r--r--src/mame/drivers/sbasketb.c9
-rw-r--r--src/mame/drivers/scotrsht.c9
-rw-r--r--src/mame/drivers/scramble.c2
-rw-r--r--src/mame/drivers/sderby.c8
-rw-r--r--src/mame/drivers/segag80r.c6
-rw-r--r--src/mame/drivers/segag80v.c2
-rw-r--r--src/mame/drivers/segajw.c2
-rw-r--r--src/mame/drivers/segald.c2
-rw-r--r--src/mame/drivers/segas32.c17
-rw-r--r--src/mame/drivers/seibuspi.c10
-rw-r--r--src/mame/drivers/seicross.c9
-rw-r--r--src/mame/drivers/sengokmj.c7
-rw-r--r--src/mame/drivers/senjyo.c9
-rw-r--r--src/mame/drivers/seta.c42
-rw-r--r--src/mame/drivers/seta2.c41
-rw-r--r--src/mame/drivers/sf.c6
-rw-r--r--src/mame/drivers/sfbonus.c4
-rw-r--r--src/mame/drivers/shangha3.c6
-rw-r--r--src/mame/drivers/shanghai.c11
-rw-r--r--src/mame/drivers/shangkid.c6
-rw-r--r--src/mame/drivers/shisen.c4
-rw-r--r--src/mame/drivers/shougi.c12
-rw-r--r--src/mame/drivers/sidearms.c8
-rw-r--r--src/mame/drivers/sidepckt.c2
-rw-r--r--src/mame/drivers/sigmab52.c9
-rw-r--r--src/mame/drivers/sigmab98.c7
-rw-r--r--src/mame/drivers/silkroad.c2
-rw-r--r--src/mame/drivers/silvmil.c2
-rw-r--r--src/mame/drivers/simpl156.c6
-rw-r--r--src/mame/drivers/simpsons.c15
-rw-r--r--src/mame/drivers/skimaxx.c2
-rw-r--r--src/mame/drivers/skyarmy.c10
-rw-r--r--src/mame/drivers/skydiver.c21
-rw-r--r--src/mame/drivers/skyfox.c7
-rw-r--r--src/mame/drivers/skykid.c18
-rw-r--r--src/mame/drivers/skylncr.c8
-rw-r--r--src/mame/drivers/skyraid.c2
-rw-r--r--src/mame/drivers/slapfght.c23
-rw-r--r--src/mame/drivers/slapshot.c10
-rw-r--r--src/mame/drivers/sliver.c2
-rw-r--r--src/mame/drivers/snk.c30
-rw-r--r--src/mame/drivers/snk6502.c15
-rw-r--r--src/mame/drivers/snk68.c2
-rw-r--r--src/mame/drivers/snookr10.c2
-rw-r--r--src/mame/drivers/snowbros.c2
-rw-r--r--src/mame/drivers/solomon.c11
-rw-r--r--src/mame/drivers/sonson.c4
-rw-r--r--src/mame/drivers/spaceg.c2
-rw-r--r--src/mame/drivers/spbactn.c2
-rw-r--r--src/mame/drivers/spcforce.c9
-rw-r--r--src/mame/drivers/speedatk.c2
-rw-r--r--src/mame/drivers/speedbal.c4
-rw-r--r--src/mame/drivers/speedspn.c2
-rw-r--r--src/mame/drivers/speglsht.c4
-rw-r--r--src/mame/drivers/spiders.c12
-rw-r--r--src/mame/drivers/splash.c17
-rw-r--r--src/mame/drivers/spoker.c12
-rw-r--r--src/mame/drivers/spool99.c2
-rw-r--r--src/mame/drivers/sprcros2.c9
-rw-r--r--src/mame/drivers/sprint2.c40
-rw-r--r--src/mame/drivers/spy.c9
-rw-r--r--src/mame/drivers/srmp2.c10
-rw-r--r--src/mame/drivers/srmp5.c4
-rw-r--r--src/mame/drivers/srmp6.c2
-rw-r--r--src/mame/drivers/srumbler.c2
-rw-r--r--src/mame/drivers/ssfindo.c12
-rw-r--r--src/mame/drivers/sshangha.c2
-rw-r--r--src/mame/drivers/ssingles.c7
-rw-r--r--src/mame/drivers/sslam.c4
-rw-r--r--src/mame/drivers/ssozumo.c11
-rw-r--r--src/mame/drivers/sspeedr.c2
-rw-r--r--src/mame/drivers/ssrj.c2
-rw-r--r--src/mame/drivers/sstrangr.c2
-rw-r--r--src/mame/drivers/stactics.c9
-rw-r--r--src/mame/drivers/stadhero.c2
-rw-r--r--src/mame/drivers/starcrus.c2
-rw-r--r--src/mame/drivers/starfire.c2
-rw-r--r--src/mame/drivers/starshp1.c8
-rw-r--r--src/mame/drivers/starwars.c2
-rw-r--r--src/mame/drivers/statriv2.c16
-rw-r--r--src/mame/drivers/stfight.c4
-rw-r--r--src/mame/drivers/stlforce.c2
-rw-r--r--src/mame/drivers/strnskil.c2
-rw-r--r--src/mame/drivers/sub.c12
-rw-r--r--src/mame/drivers/subs.c2
-rw-r--r--src/mame/drivers/subsino2.c14
-rw-r--r--src/mame/drivers/summit.c2
-rw-r--r--src/mame/drivers/suna16.c4
-rw-r--r--src/mame/drivers/suna8.c14
-rw-r--r--src/mame/drivers/supbtime.c4
-rw-r--r--src/mame/drivers/supdrapo.c2
-rw-r--r--src/mame/drivers/superchs.c4
-rw-r--r--src/mame/drivers/superdq.c12
-rw-r--r--src/mame/drivers/superqix.c22
-rw-r--r--src/mame/drivers/supertnk.c7
-rw-r--r--src/mame/drivers/superwng.c18
-rw-r--r--src/mame/drivers/suprgolf.c2
-rw-r--r--src/mame/drivers/suprloco.c4
-rw-r--r--src/mame/drivers/suprridr.c9
-rw-r--r--src/mame/drivers/suprslam.c2
-rw-r--r--src/mame/drivers/surpratk.c9
-rw-r--r--src/mame/drivers/system1.c12
-rw-r--r--src/mame/drivers/system16.c10
-rw-r--r--src/mame/drivers/tagteam.c11
-rw-r--r--src/mame/drivers/tail2nos.c2
-rw-r--r--src/mame/drivers/taito_b.c104
-rw-r--r--src/mame/drivers/taito_f2.c12
-rw-r--r--src/mame/drivers/taito_f3.c10
-rw-r--r--src/mame/drivers/taito_h.c6
-rw-r--r--src/mame/drivers/taito_l.c8
-rw-r--r--src/mame/drivers/taito_x.c8
-rw-r--r--src/mame/drivers/taito_z.c51
-rw-r--r--src/mame/drivers/taitoair.c2
-rw-r--r--src/mame/drivers/taitojc.c6
-rw-r--r--src/mame/drivers/taitosj.c4
-rw-r--r--src/mame/drivers/taitotz.c7
-rw-r--r--src/mame/drivers/tankbatt.c7
-rw-r--r--src/mame/drivers/tankbust.c9
-rw-r--r--src/mame/drivers/taotaido.c2
-rw-r--r--src/mame/drivers/tapatune.c2
-rw-r--r--src/mame/drivers/tasman.c2
-rw-r--r--src/mame/drivers/tatsumi.c20
-rw-r--r--src/mame/drivers/tattack.c2
-rw-r--r--src/mame/drivers/taxidriv.c6
-rw-r--r--src/mame/drivers/tbowl.c4
-rw-r--r--src/mame/drivers/tceptor.c31
-rw-r--r--src/mame/drivers/techno.c15
-rw-r--r--src/mame/drivers/tecmo.c4
-rw-r--r--src/mame/drivers/tecmo16.c2
-rw-r--r--src/mame/drivers/tecmosys.c2
-rw-r--r--src/mame/drivers/tehkanwc.c6
-rw-r--r--src/mame/drivers/tempest.c2
-rw-r--r--src/mame/drivers/terracre.c12
-rw-r--r--src/mame/drivers/tetrisp2.c16
-rw-r--r--src/mame/drivers/tgtpanic.c2
-rw-r--r--src/mame/drivers/thedeep.c7
-rw-r--r--src/mame/drivers/thepit.c11
-rw-r--r--src/mame/drivers/thief.c14
-rw-r--r--src/mame/drivers/thoop2.c2
-rw-r--r--src/mame/drivers/thunderx.c11
-rw-r--r--src/mame/drivers/tiamc1.c2
-rw-r--r--src/mame/drivers/tigeroad.c4
-rw-r--r--src/mame/drivers/timelimt.c11
-rw-r--r--src/mame/drivers/timeplt.c11
-rw-r--r--src/mame/drivers/timetrv.c14
-rw-r--r--src/mame/drivers/tmnt.c48
-rw-r--r--src/mame/drivers/tmspoker.c7
-rw-r--r--src/mame/drivers/tnzs.c28
-rw-r--r--src/mame/drivers/toaplan1.c16
-rw-r--r--src/mame/drivers/toaplan2.c48
-rw-r--r--src/mame/drivers/toki.c4
-rw-r--r--src/mame/drivers/tomcat.c4
-rw-r--r--src/mame/drivers/topspeed.c16
-rw-r--r--src/mame/drivers/toratora.c22
-rw-r--r--src/mame/drivers/toypop.c39
-rw-r--r--src/mame/drivers/tp84.c11
-rw-r--r--src/mame/drivers/trackfld.c31
-rw-r--r--src/mame/drivers/travrusa.c2
-rw-r--r--src/mame/drivers/triplhnt.c2
-rw-r--r--src/mame/drivers/truco.c15
-rw-r--r--src/mame/drivers/trucocl.c9
-rw-r--r--src/mame/drivers/trvmadns.c2
-rw-r--r--src/mame/drivers/trvquest.c9
-rw-r--r--src/mame/drivers/tryout.c2
-rw-r--r--src/mame/drivers/tsamurai.c20
-rw-r--r--src/mame/drivers/ttchamp.c7
-rw-r--r--src/mame/drivers/tubep.c2
-rw-r--r--src/mame/drivers/tugboat.c2
-rw-r--r--src/mame/drivers/tumbleb.c21
-rw-r--r--src/mame/drivers/tumblep.c2
-rw-r--r--src/mame/drivers/tunhunt.c2
-rw-r--r--src/mame/drivers/turbo.c6
-rw-r--r--src/mame/drivers/tutankhm.c11
-rw-r--r--src/mame/drivers/twin16.c20
-rw-r--r--src/mame/drivers/twincobr.c2
-rw-r--r--src/mame/drivers/twins.c4
-rw-r--r--src/mame/drivers/tx1.c10
-rw-r--r--src/mame/drivers/ultraman.c2
-rw-r--r--src/mame/drivers/ultrsprt.c9
-rw-r--r--src/mame/drivers/umipoker.c4
-rw-r--r--src/mame/drivers/undrfire.c13
-rw-r--r--src/mame/drivers/unico.c6
-rw-r--r--src/mame/drivers/unkhorse.c9
-rw-r--r--src/mame/drivers/usgames.c2
-rw-r--r--src/mame/drivers/vamphalf.c14
-rw-r--r--src/mame/drivers/vaportra.c2
-rw-r--r--src/mame/drivers/vastar.c11
-rw-r--r--src/mame/drivers/vcombat.c6
-rw-r--r--src/mame/drivers/vega.c2
-rw-r--r--src/mame/drivers/vendetta.c9
-rw-r--r--src/mame/drivers/vertigo.c2
-rw-r--r--src/mame/drivers/victory.c2
-rw-r--r--src/mame/drivers/videopkr.c2
-rw-r--r--src/mame/drivers/vigilant.c12
-rw-r--r--src/mame/drivers/viper.c9
-rw-r--r--src/mame/drivers/vmetal.c2
-rw-r--r--src/mame/drivers/volfied.c2
-rw-r--r--src/mame/drivers/vpoker.c2
-rw-r--r--src/mame/drivers/vroulet.c2
-rw-r--r--src/mame/drivers/vulgus.c8
-rw-r--r--src/mame/drivers/wallc.c2
-rw-r--r--src/mame/drivers/wardner.c2
-rw-r--r--src/mame/drivers/warpsped.c2
-rw-r--r--src/mame/drivers/warpwarp.c11
-rw-r--r--src/mame/drivers/warriorb.c4
-rw-r--r--src/mame/drivers/wc90.c4
-rw-r--r--src/mame/drivers/wc90b.c4
-rw-r--r--src/mame/drivers/wecleman.c6
-rw-r--r--src/mame/drivers/welltris.c2
-rw-r--r--src/mame/drivers/wgp.c10
-rw-r--r--src/mame/drivers/wheelfir.c2
-rw-r--r--src/mame/drivers/whitestar.c9
-rw-r--r--src/mame/drivers/wildpkr.c2
-rw-r--r--src/mame/drivers/wink.c10
-rw-r--r--src/mame/drivers/wiping.c18
-rw-r--r--src/mame/drivers/witch.c14
-rw-r--r--src/mame/drivers/wiz.c18
-rw-r--r--src/mame/drivers/wrally.c2
-rw-r--r--src/mame/drivers/xorworld.c4
-rw-r--r--src/mame/drivers/xtheball.c2
-rw-r--r--src/mame/drivers/xxmissio.c18
-rw-r--r--src/mame/drivers/xyonix.c4
-rw-r--r--src/mame/drivers/yiear.c18
-rw-r--r--src/mame/drivers/yunsun16.c4
-rw-r--r--src/mame/drivers/yunsung8.c4
-rw-r--r--src/mame/drivers/zaccaria.c20
-rw-r--r--src/mame/drivers/zaxxon.c11
-rw-r--r--src/mame/drivers/zerozone.c2
-rw-r--r--src/mame/drivers/zn.c11
-rw-r--r--src/mame/drivers/zodiack.c7
-rw-r--r--src/mame/drivers/zr107.c9
-rw-r--r--src/mame/includes/20pacgal.h1
-rw-r--r--src/mame/includes/8080bw.h1
-rw-r--r--src/mame/includes/88games.h1
-rw-r--r--src/mame/includes/aeroboto.h1
-rw-r--r--src/mame/includes/airbustr.h1
-rw-r--r--src/mame/includes/ajax.h5
-rw-r--r--src/mame/includes/aliens.h1
-rw-r--r--src/mame/includes/alpha68k.h1
-rw-r--r--src/mame/includes/appoooh.h1
-rw-r--r--src/mame/includes/asterix.h1
-rw-r--r--src/mame/includes/asteroid.h11
-rw-r--r--src/mame/includes/asuka.h1
-rw-r--r--src/mame/includes/atarisy2.h1
-rw-r--r--src/mame/includes/aztarac.h4
-rw-r--r--src/mame/includes/badlands.h1
-rw-r--r--src/mame/includes/bagman.h1
-rw-r--r--src/mame/includes/balsente.h3
-rw-r--r--src/mame/includes/bankp.h1
-rw-r--r--src/mame/includes/battlane.h1
-rw-r--r--src/mame/includes/battlex.h1
-rw-r--r--src/mame/includes/battlnts.h1
-rw-r--r--src/mame/includes/blockade.h1
-rw-r--r--src/mame/includes/blockhl.h1
-rw-r--r--src/mame/includes/bombjack.h1
-rw-r--r--src/mame/includes/bottom9.h2
-rw-r--r--src/mame/includes/brkthru.h1
-rw-r--r--src/mame/includes/bublbobl.h5
-rw-r--r--src/mame/includes/bwing.h1
-rw-r--r--src/mame/includes/bzone.h1
-rw-r--r--src/mame/includes/capbowl.h1
-rw-r--r--src/mame/includes/carjmbre.h1
-rw-r--r--src/mame/includes/carpolo.h3
-rw-r--r--src/mame/includes/cave.h1
-rw-r--r--src/mame/includes/cclimber.h1
-rw-r--r--src/mame/includes/champbas.h1
-rw-r--r--src/mame/includes/changela.h1
-rw-r--r--src/mame/includes/cheekyms.h1
-rw-r--r--src/mame/includes/circusc.h1
-rw-r--r--src/mame/includes/commando.h1
-rw-r--r--src/mame/includes/contra.h1
-rw-r--r--src/mame/includes/cps1.h4
-rw-r--r--src/mame/includes/cps3.h2
-rw-r--r--src/mame/includes/crbaloon.h1
-rw-r--r--src/mame/includes/crimfght.h1
-rw-r--r--src/mame/includes/cvs.h1
-rw-r--r--src/mame/includes/cyberbal.h2
-rw-r--r--src/mame/includes/dcheese.h1
-rw-r--r--src/mame/includes/ddribble.h2
-rw-r--r--src/mame/includes/dec8.h2
-rw-r--r--src/mame/includes/deco32.h1
-rw-r--r--src/mame/includes/djmain.h1
-rw-r--r--src/mame/includes/dkong.h2
-rw-r--r--src/mame/includes/dribling.h1
-rw-r--r--src/mame/includes/drmicro.h1
-rw-r--r--src/mame/includes/dynax.h5
-rw-r--r--src/mame/includes/dynduke.h1
-rw-r--r--src/mame/includes/espial.h1
-rw-r--r--src/mame/includes/esripsys.h2
-rw-r--r--src/mame/includes/exidy.h2
-rw-r--r--src/mame/includes/exidy440.h3
-rw-r--r--src/mame/includes/exprraid.h1
-rw-r--r--src/mame/includes/fantland.h2
-rw-r--r--src/mame/includes/fastfred.h2
-rw-r--r--src/mame/includes/firetrap.h1
-rw-r--r--src/mame/includes/firetrk.h1
-rw-r--r--src/mame/includes/fitfight.h1
-rw-r--r--src/mame/includes/flkatck.h1
-rw-r--r--src/mame/includes/freekick.h1
-rw-r--r--src/mame/includes/fromanc2.h1
-rw-r--r--src/mame/includes/gaelco3d.h1
-rw-r--r--src/mame/includes/galaga.h5
-rw-r--r--src/mame/includes/galastrm.h1
-rw-r--r--src/mame/includes/galaxia.h1
-rw-r--r--src/mame/includes/galaxian.h2
-rw-r--r--src/mame/includes/galaxold.h4
-rw-r--r--src/mame/includes/gameplan.h1
-rw-r--r--src/mame/includes/gaplus.h3
-rw-r--r--src/mame/includes/gbusters.h1
-rw-r--r--src/mame/includes/gcpinbal.h1
-rw-r--r--src/mame/includes/gijoe.h1
-rw-r--r--src/mame/includes/glass.h1
-rw-r--r--src/mame/includes/goldstar.h1
-rw-r--r--src/mame/includes/gottlieb.h1
-rw-r--r--src/mame/includes/gradius3.h1
-rw-r--r--src/mame/includes/grchamp.h2
-rw-r--r--src/mame/includes/groundfx.h1
-rw-r--r--src/mame/includes/gsword.h1
-rw-r--r--src/mame/includes/gunbustr.h1
-rw-r--r--src/mame/includes/gyruss.h2
-rw-r--r--src/mame/includes/harddriv.h4
-rw-r--r--src/mame/includes/homedata.h2
-rw-r--r--src/mame/includes/hyperspt.h1
-rw-r--r--src/mame/includes/itech32.h1
-rw-r--r--src/mame/includes/itech8.h1
-rw-r--r--src/mame/includes/jack.h1
-rw-r--r--src/mame/includes/jackal.h1
-rw-r--r--src/mame/includes/jailbrek.h2
-rw-r--r--src/mame/includes/karnov.h1
-rw-r--r--src/mame/includes/kchamp.h2
-rw-r--r--src/mame/includes/kickgoal.h1
-rw-r--r--src/mame/includes/kingobox.h1
-rw-r--r--src/mame/includes/kncljoe.h1
-rw-r--r--src/mame/includes/konamigx.h2
-rw-r--r--src/mame/includes/kopunch.h1
-rw-r--r--src/mame/includes/kyugo.h1
-rw-r--r--src/mame/includes/labyrunr.h2
-rw-r--r--src/mame/includes/laserbat.h2
-rw-r--r--src/mame/includes/leland.h15
-rw-r--r--src/mame/includes/lethal.h1
-rw-r--r--src/mame/includes/liberate.h2
-rw-r--r--src/mame/includes/lucky74.h1
-rw-r--r--src/mame/includes/lwings.h2
-rw-r--r--src/mame/includes/m10.h3
-rw-r--r--src/mame/includes/m72.h2
-rw-r--r--src/mame/includes/m90.h5
-rw-r--r--src/mame/includes/mainevt.h4
-rw-r--r--src/mame/includes/mappy.h6
-rw-r--r--src/mame/includes/marineb.h2
-rw-r--r--src/mame/includes/mario.h1
-rw-r--r--src/mame/includes/mcr68.h3
-rw-r--r--src/mame/includes/meadows.h3
-rw-r--r--src/mame/includes/megasys1.h1
-rw-r--r--src/mame/includes/megazone.h1
-rw-r--r--src/mame/includes/mermaid.h1
-rw-r--r--src/mame/includes/metro.h4
-rw-r--r--src/mame/includes/mexico86.h6
-rw-r--r--src/mame/includes/micro3d.h3
-rw-r--r--src/mame/includes/midzeus.h1
-rw-r--r--src/mame/includes/mikie.h1
-rw-r--r--src/mame/includes/mjkjidai.h1
-rw-r--r--src/mame/includes/moo.h2
-rw-r--r--src/mame/includes/mouser.h2
-rw-r--r--src/mame/includes/munchmo.h2
-rw-r--r--src/mame/includes/mustache.h1
-rw-r--r--src/mame/includes/mystwarr.h1
-rw-r--r--src/mame/includes/namconb1.h2
-rw-r--r--src/mame/includes/namcond1.h1
-rw-r--r--src/mame/includes/namcos2.h6
-rw-r--r--src/mame/includes/namcos22.h2
-rw-r--r--src/mame/includes/nbmj9195.h1
-rw-r--r--src/mame/includes/nemesis.h2
-rw-r--r--src/mame/includes/ninjakd2.h1
-rw-r--r--src/mame/includes/niyanpai.h1
-rw-r--r--src/mame/includes/orbit.h1
-rw-r--r--src/mame/includes/othunder.h1
-rw-r--r--src/mame/includes/overdriv.h1
-rw-r--r--src/mame/includes/pacland.h2
-rw-r--r--src/mame/includes/pacman.h3
-rw-r--r--src/mame/includes/pandoras.h2
-rw-r--r--src/mame/includes/paradise.h1
-rw-r--r--src/mame/includes/parodius.h1
-rw-r--r--src/mame/includes/pbaction.h2
-rw-r--r--src/mame/includes/pitnrun.h1
-rw-r--r--src/mame/includes/playch10.h1
-rw-r--r--src/mame/includes/plygonet.h2
-rw-r--r--src/mame/includes/policetr.h1
-rw-r--r--src/mame/includes/polyplay.h2
-rw-r--r--src/mame/includes/pooyan.h1
-rw-r--r--src/mame/includes/popeye.h1
-rw-r--r--src/mame/includes/popper.h1
-rw-r--r--src/mame/includes/psikyo4.h1
-rw-r--r--src/mame/includes/psikyosh.h1
-rw-r--r--src/mame/includes/punchout.h1
-rw-r--r--src/mame/includes/qdrmfgp.h1
-rw-r--r--src/mame/includes/quasar.h1
-rw-r--r--src/mame/includes/raiden.h1
-rw-r--r--src/mame/includes/raiden2.h1
-rw-r--r--src/mame/includes/rallyx.h2
-rw-r--r--src/mame/includes/realbrk.h1
-rw-r--r--src/mame/includes/redalert.h1
-rw-r--r--src/mame/includes/retofinv.h2
-rw-r--r--src/mame/includes/rltennis.h1
-rw-r--r--src/mame/includes/rockrage.h1
-rw-r--r--src/mame/includes/rocnrope.h1
-rw-r--r--src/mame/includes/rollrace.h2
-rw-r--r--src/mame/includes/rungun.h2
-rw-r--r--src/mame/includes/sauro.h1
-rw-r--r--src/mame/includes/sbasketb.h1
-rw-r--r--src/mame/includes/scotrsht.h1
-rw-r--r--src/mame/includes/segag80r.h5
-rw-r--r--src/mame/includes/segas32.h1
-rw-r--r--src/mame/includes/seibuspi.h1
-rw-r--r--src/mame/includes/seicross.h1
-rw-r--r--src/mame/includes/senjyo.h1
-rw-r--r--src/mame/includes/seta.h1
-rw-r--r--src/mame/includes/seta2.h3
-rw-r--r--src/mame/includes/simpl156.h1
-rw-r--r--src/mame/includes/simpsons.h1
-rw-r--r--src/mame/includes/skydiver.h1
-rw-r--r--src/mame/includes/skyfox.h1
-rw-r--r--src/mame/includes/skykid.h2
-rw-r--r--src/mame/includes/slapfght.h5
-rw-r--r--src/mame/includes/slapshot.h1
-rw-r--r--src/mame/includes/snk6502.h2
-rw-r--r--src/mame/includes/solomon.h1
-rw-r--r--src/mame/includes/spcforce.h1
-rw-r--r--src/mame/includes/spiders.h1
-rw-r--r--src/mame/includes/splash.h1
-rw-r--r--src/mame/includes/sprcros2.h1
-rw-r--r--src/mame/includes/sprint2.h1
-rw-r--r--src/mame/includes/spy.h1
-rw-r--r--src/mame/includes/ssozumo.h1
-rw-r--r--src/mame/includes/stactics.h1
-rw-r--r--src/mame/includes/starshp1.h1
-rw-r--r--src/mame/includes/stfight.h2
-rw-r--r--src/mame/includes/subs.h5
-rw-r--r--src/mame/includes/superqix.h2
-rw-r--r--src/mame/includes/suprridr.h1
-rw-r--r--src/mame/includes/surpratk.h1
-rw-r--r--src/mame/includes/system1.h1
-rw-r--r--src/mame/includes/system16.h1
-rw-r--r--src/mame/includes/tagteam.h1
-rw-r--r--src/mame/includes/taito_b.h11
-rw-r--r--src/mame/includes/taito_f2.h1
-rw-r--r--src/mame/includes/taito_f3.h1
-rw-r--r--src/mame/includes/taito_z.h1
-rw-r--r--src/mame/includes/taitojc.h1
-rw-r--r--src/mame/includes/tankbatt.h1
-rw-r--r--src/mame/includes/tankbust.h1
-rw-r--r--src/mame/includes/tatsumi.h1
-rw-r--r--src/mame/includes/tceptor.h3
-rw-r--r--src/mame/includes/thedeep.h1
-rw-r--r--src/mame/includes/thepit.h1
-rw-r--r--src/mame/includes/thief.h1
-rw-r--r--src/mame/includes/thunderx.h1
-rw-r--r--src/mame/includes/timelimt.h1
-rw-r--r--src/mame/includes/timeplt.h1
-rw-r--r--src/mame/includes/tmnt.h4
-rw-r--r--src/mame/includes/tnzs.h5
-rw-r--r--src/mame/includes/toaplan1.h3
-rw-r--r--src/mame/includes/toaplan2.h4
-rw-r--r--src/mame/includes/topspeed.h2
-rw-r--r--src/mame/includes/toypop.h3
-rw-r--r--src/mame/includes/tp84.h1
-rw-r--r--src/mame/includes/trackfld.h3
-rw-r--r--src/mame/includes/truco.h1
-rw-r--r--src/mame/includes/trucocl.h1
-rw-r--r--src/mame/includes/tsamurai.h2
-rw-r--r--src/mame/includes/tumbleb.h1
-rw-r--r--src/mame/includes/tutankhm.h1
-rw-r--r--src/mame/includes/twin16.h2
-rw-r--r--src/mame/includes/twincobr.h5
-rw-r--r--src/mame/includes/tx1.h1
-rw-r--r--src/mame/includes/undrfire.h1
-rw-r--r--src/mame/includes/vastar.h1
-rw-r--r--src/mame/includes/vendetta.h1
-rw-r--r--src/mame/includes/vertigo.h3
-rw-r--r--src/mame/includes/victory.h5
-rw-r--r--src/mame/includes/vulgus.h1
-rw-r--r--src/mame/includes/warpwarp.h1
-rw-r--r--src/mame/includes/wecleman.h1
-rw-r--r--src/mame/includes/wgp.h1
-rw-r--r--src/mame/includes/wiping.h2
-rw-r--r--src/mame/includes/wiz.h2
-rw-r--r--src/mame/includes/xxmissio.h2
-rw-r--r--src/mame/includes/yiear.h2
-rw-r--r--src/mame/includes/zaccaria.h2
-rw-r--r--src/mame/includes/zaxxon.h1
-rw-r--r--src/mame/includes/zodiack.h1
-rw-r--r--src/mame/machine/ajax.c7
-rw-r--r--src/mame/machine/asteroid.c18
-rw-r--r--src/mame/machine/balsente.c5
-rw-r--r--src/mame/machine/bublbobl.c6
-rw-r--r--src/mame/machine/carpolo.c49
-rw-r--r--src/mame/machine/galaxold.c4
-rw-r--r--src/mame/machine/harddriv.c7
-rw-r--r--src/mame/machine/leland.c6
-rw-r--r--src/mame/machine/mcr68.c9
-rw-r--r--src/mame/machine/mexico86.c15
-rw-r--r--src/mame/machine/namcos2.c22
-rw-r--r--src/mame/machine/slapfght.c7
-rw-r--r--src/mame/machine/stfight.c6
-rw-r--r--src/mame/machine/subs.c6
-rw-r--r--src/mame/machine/tnzs.c15
-rw-r--r--src/mame/machine/toaplan1.c7
-rw-r--r--src/mame/machine/twincobr.c18
-rw-r--r--src/mame/machine/vertigo.c6
-rw-r--r--src/mame/machine/xevious.c4
-rw-r--r--src/mame/video/esripsys.c7
-rw-r--r--src/mame/video/exidy.c9
-rw-r--r--src/mame/video/exidy440.c7
-rw-r--r--src/mame/video/micro3d.c7
-rw-r--r--src/mame/video/segag80r.c11
-rw-r--r--src/mame/video/victory.c7
1083 files changed, 3999 insertions, 3906 deletions
diff --git a/src/emu/devcpu.h b/src/emu/devcpu.h
index e0b18364ca9..35cff542e77 100644
--- a/src/emu/devcpu.h
+++ b/src/emu/devcpu.h
@@ -195,6 +195,8 @@ enum
#define MCFG_CPU_VBLANK_INT MCFG_DEVICE_VBLANK_INT
#define MCFG_CPU_PERIODIC_INT MCFG_DEVICE_PERIODIC_INT
+#define MCFG_CPU_VBLANK_INT_DRIVER MCFG_DEVICE_VBLANK_INT_DRIVER
+#define MCFG_CPU_PERIODIC_INT_DRIVER MCFG_DEVICE_PERIODIC_INT_DRIVER
//**************************************************************************
diff --git a/src/mame/audio/aztarac.c b/src/mame/audio/aztarac.c
index 0c04489387b..be011372708 100644
--- a/src/mame/audio/aztarac.c
+++ b/src/mame/audio/aztarac.c
@@ -43,11 +43,10 @@ WRITE8_MEMBER(aztarac_state::aztarac_snd_status_w)
m_sound_status &= ~0x10;
}
-INTERRUPT_GEN( aztarac_snd_timed_irq )
+INTERRUPT_GEN_MEMBER(aztarac_state::aztarac_snd_timed_irq)
{
- aztarac_state *state = device->machine().driver_data<aztarac_state>();
- state->m_sound_status ^= 0x10;
+ m_sound_status ^= 0x10;
- if (state->m_sound_status & 0x10)
- device->execute().set_input_line(0,HOLD_LINE);
+ if (m_sound_status & 0x10)
+ device.execute().set_input_line(0,HOLD_LINE);
}
diff --git a/src/mame/audio/cyberbal.c b/src/mame/audio/cyberbal.c
index 1276a25fc03..f23f39e6184 100644
--- a/src/mame/audio/cyberbal.c
+++ b/src/mame/audio/cyberbal.c
@@ -100,13 +100,12 @@ static void update_sound_68k_interrupts(running_machine &machine)
}
-INTERRUPT_GEN( cyberbal_sound_68k_irq_gen )
+INTERRUPT_GEN_MEMBER(cyberbal_state::cyberbal_sound_68k_irq_gen)
{
- cyberbal_state *state = device->machine().driver_data<cyberbal_state>();
- if (!state->m_fast_68k_int)
+ if (!m_fast_68k_int)
{
- state->m_fast_68k_int = 1;
- update_sound_68k_interrupts(device->machine());
+ m_fast_68k_int = 1;
+ update_sound_68k_interrupts(machine());
}
}
diff --git a/src/mame/audio/dkong.c b/src/mame/audio/dkong.c
index 6762d974238..a1a9050996e 100644
--- a/src/mame/audio/dkong.c
+++ b/src/mame/audio/dkong.c
@@ -1466,11 +1466,11 @@ MACHINE_CONFIG_FRAGMENT( dkong3_audio )
MCFG_CPU_ADD("n2a03a", N2A03,N2A03_DEFAULTCLOCK)
MCFG_CPU_PROGRAM_MAP(dkong3_sound1_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, nmi_line_pulse)
MCFG_CPU_ADD("n2a03b", N2A03,N2A03_DEFAULTCLOCK)
MCFG_CPU_PROGRAM_MAP(dkong3_sound2_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, nmi_line_pulse)
/* sound latches */
MCFG_LATCH8_ADD( "latch1")
diff --git a/src/mame/audio/redalert.c b/src/mame/audio/redalert.c
index 0498f11eabe..c819e3af37f 100644
--- a/src/mame/audio/redalert.c
+++ b/src/mame/audio/redalert.c
@@ -212,7 +212,7 @@ static MACHINE_CONFIG_FRAGMENT( redalert_audio_m37b )
MCFG_CPU_ADD("audiocpu", M6502, REDALERT_AUDIO_CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(redalert_audio_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)
+ MCFG_CPU_PERIODIC_INT_DRIVER(redalert_state, irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ)
MCFG_SOUND_ADD("aysnd", AY8910, REDALERT_AY8910_CLOCK)
MCFG_SOUND_CONFIG(redalert_ay8910_interface)
@@ -404,7 +404,7 @@ MACHINE_CONFIG_FRAGMENT( demoneye_audio )
MCFG_CPU_ADD("audiocpu", M6802, DEMONEYE_AUDIO_CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(demoneye_audio_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ) /* guess */
+ MCFG_CPU_PERIODIC_INT_DRIVER(redalert_state, irq0_line_hold, REDALERT_AUDIO_CPU_IRQ_FREQ) /* guess */
MCFG_PIA6821_ADD("sndpia", demoneye_pia_intf)
diff --git a/src/mame/drivers/1942.c b/src/mame/drivers/1942.c
index 7b0d663716c..f7882ac0363 100644
--- a/src/mame/drivers/1942.c
+++ b/src/mame/drivers/1942.c
@@ -262,7 +262,7 @@ static MACHINE_CONFIG_START( 1942, _1942_state )
MCFG_CPU_ADD("audiocpu", Z80, SOUND_CPU_CLOCK) /* 3 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(_1942_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/1943.c b/src/mame/drivers/1943.c
index f4a1f0f70ec..3c03db0f443 100644
--- a/src/mame/drivers/1943.c
+++ b/src/mame/drivers/1943.c
@@ -257,11 +257,11 @@ static MACHINE_CONFIG_START( 1943, _1943_state )
// basic machine hardware
MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(c1943_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _1943_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(_1943_state, irq0_line_hold, 4*60)
// video hardware
diff --git a/src/mame/drivers/1945kiii.c b/src/mame/drivers/1945kiii.c
index d7db5410a69..d7bd3a11aea 100644
--- a/src/mame/drivers/1945kiii.c
+++ b/src/mame/drivers/1945kiii.c
@@ -257,7 +257,7 @@ static MACHINE_CONFIG_START( k3, k3_state )
MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK)
MCFG_CPU_PROGRAM_MAP(k3_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", k3_state, irq4_line_hold)
MCFG_GFXDECODE(1945kiii)
diff --git a/src/mame/drivers/20pacgal.c b/src/mame/drivers/20pacgal.c
index cbe14fb11fd..4c41a0ab4c2 100644
--- a/src/mame/drivers/20pacgal.c
+++ b/src/mame/drivers/20pacgal.c
@@ -360,12 +360,11 @@ void _20pacgal_state::machine_reset()
m_game_selected = 0;
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(_20pacgal_state::vblank_irq)
{
- _20pacgal_state *state = device->machine().driver_data<_20pacgal_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, HOLD_LINE); // TODO: assert breaks the inputs in 25pacman test mode
+ if(m_irq_mask)
+ device.execute().set_input_line(0, HOLD_LINE); // TODO: assert breaks the inputs in 25pacman test mode
}
static MACHINE_CONFIG_START( 20pacgal, _20pacgal_state )
@@ -374,7 +373,7 @@ static MACHINE_CONFIG_START( 20pacgal, _20pacgal_state )
MCFG_CPU_ADD("maincpu", Z180, MAIN_CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(20pacgal_map)
MCFG_CPU_IO_MAP(20pacgal_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _20pacgal_state, vblank_irq)
MCFG_EEPROM_ADD("eeprom", _20pacgal_eeprom_intf)
diff --git a/src/mame/drivers/2mindril.c b/src/mame/drivers/2mindril.c
index f1a50371e72..9f46d0f8791 100644
--- a/src/mame/drivers/2mindril.c
+++ b/src/mame/drivers/2mindril.c
@@ -63,6 +63,8 @@ public:
DECLARE_DRIVER_INIT(drill);
DECLARE_MACHINE_START(drill);
DECLARE_MACHINE_RESET(drill);
+ INTERRUPT_GEN_MEMBER(drill_vblank_irq);
+ //INTERRUPT_GEN_MEMBER(drill_device_irq);
};
@@ -399,15 +401,15 @@ static GFXDECODE_START( 2mindril )
GFXDECODE_END
-static INTERRUPT_GEN( drill_vblank_irq )
+INTERRUPT_GEN_MEMBER(_2mindril_state::drill_vblank_irq)
{
- device->execute().set_input_line(4, ASSERT_LINE);
+ device.execute().set_input_line(4, ASSERT_LINE);
}
#if 0
-static INTERRUPT_GEN( drill_device_irq )
+INTERRUPT_GEN_MEMBER(_2mindril_state::drill_device_irq)
{
- device->execute().set_input_line(5, ASSERT_LINE);
+ device.execute().set_input_line(5, ASSERT_LINE);
}
#endif
@@ -445,8 +447,8 @@ static MACHINE_CONFIG_START( drill, _2mindril_state )
MCFG_CPU_ADD("maincpu", M68000, 16000000 )
MCFG_CPU_PROGRAM_MAP(drill_map)
- MCFG_CPU_VBLANK_INT("screen", drill_vblank_irq)
- //MCFG_CPU_PERIODIC_INT(drill_device_irq,60)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _2mindril_state, drill_vblank_irq)
+ //MCFG_CPU_PERIODIC_INT_DRIVER(_2mindril_state, drill_device_irq, 60)
MCFG_GFXDECODE(2mindril)
MCFG_MACHINE_START_OVERRIDE(_2mindril_state,drill)
diff --git a/src/mame/drivers/39in1.c b/src/mame/drivers/39in1.c
index 83badf7bae5..6b98d85e599 100644
--- a/src/mame/drivers/39in1.c
+++ b/src/mame/drivers/39in1.c
@@ -75,6 +75,7 @@ public:
DECLARE_DRIVER_INIT(39in1);
virtual void machine_start();
UINT32 screen_update_39in1(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(pxa255_vblank_start);
};
@@ -1353,7 +1354,7 @@ WRITE32_MEMBER(_39in1_state::pxa255_lcd_w)
}
}
-static INTERRUPT_GEN( pxa255_vblank_start )
+INTERRUPT_GEN_MEMBER(_39in1_state::pxa255_vblank_start)
{
}
@@ -1591,7 +1592,7 @@ static MACHINE_CONFIG_START( 39in1, _39in1_state )
MCFG_CPU_ADD("maincpu", PXA255, 200000000)
MCFG_CPU_PROGRAM_MAP(39in1_map)
- MCFG_CPU_VBLANK_INT("screen", pxa255_vblank_start)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _39in1_state, pxa255_vblank_start)
MCFG_PALETTE_LENGTH(32768)
diff --git a/src/mame/drivers/40love.c b/src/mame/drivers/40love.c
index 6f7d5026d53..c1356bbe74a 100644
--- a/src/mame/drivers/40love.c
+++ b/src/mame/drivers/40love.c
@@ -1060,11 +1060,11 @@ static MACHINE_CONFIG_START( 40love, fortyl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",Z80,8000000/2) /* OK */
MCFG_CPU_PROGRAM_MAP(40love_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fortyl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* OK */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* source/number of IRQs is unknown */
+ MCFG_CPU_PERIODIC_INT_DRIVER(fortyl_state, irq0_line_hold, 2*60) /* source/number of IRQs is unknown */
MCFG_CPU_ADD("mcu",M68705,18432000/6) /* OK */
MCFG_CPU_PROGRAM_MAP(buggychl_mcu_map)
@@ -1116,11 +1116,11 @@ static MACHINE_CONFIG_START( undoukai, fortyl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",Z80,8000000/2)
MCFG_CPU_PROGRAM_MAP(undoukai_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fortyl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu",Z80,8000000/2)
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* source/number of IRQs is unknown */
+ MCFG_CPU_PERIODIC_INT_DRIVER(fortyl_state, irq0_line_hold, 2*60) /* source/number of IRQs is unknown */
// MCFG_CPU_ADD("mcu",M68705,18432000/6)
// MCFG_CPU_PROGRAM_MAP(buggychl_mcu_map)
diff --git a/src/mame/drivers/4enraya.c b/src/mame/drivers/4enraya.c
index f37c19c75ed..3abedc5f7bd 100644
--- a/src/mame/drivers/4enraya.c
+++ b/src/mame/drivers/4enraya.c
@@ -321,7 +321,7 @@ static MACHINE_CONFIG_START( 4enraya, _4enraya_state )
MCFG_CPU_ADD("maincpu",Z80,MAIN_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60) // unknown timing
+ MCFG_CPU_PERIODIC_INT_DRIVER(_4enraya_state, irq0_line_hold, 4*60) // unknown timing
/* video hardware */
diff --git a/src/mame/drivers/4roses.c b/src/mame/drivers/4roses.c
index 79b4205400e..94048bd85eb 100644
--- a/src/mame/drivers/4roses.c
+++ b/src/mame/drivers/4roses.c
@@ -385,7 +385,7 @@ static MACHINE_CONFIG_START( 4roses, _4roses_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz, guess */
MCFG_CPU_PROGRAM_MAP(4roses_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _4roses_state, nmi_line_pulse)
// MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/5clown.c b/src/mame/drivers/5clown.c
index 17c4e32e0a9..bb0396e8288 100644
--- a/src/mame/drivers/5clown.c
+++ b/src/mame/drivers/5clown.c
@@ -1065,7 +1065,7 @@ static MACHINE_CONFIG_START( fclown, _5clown_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/8) /* guess, seems ok */
MCFG_CPU_PROGRAM_MAP(fclown_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _5clown_state, nmi_line_pulse)
MCFG_CPU_ADD("audiocpu", M6502, MASTER_CLOCK/8) /* guess, seems ok */
MCFG_CPU_PROGRAM_MAP(fcaudio_map)
diff --git a/src/mame/drivers/8080bw.c b/src/mame/drivers/8080bw.c
index 41f805af587..db458285acf 100644
--- a/src/mame/drivers/8080bw.c
+++ b/src/mame/drivers/8080bw.c
@@ -1214,7 +1214,7 @@ static MACHINE_CONFIG_DERIVED_CLASS( sflush, mw8080bw_root, _8080bw_state )
/* basic machine hardware */
MCFG_CPU_REPLACE("maincpu",M6800,1500000) // ?
MCFG_CPU_PROGRAM_MAP(sflush_map)
- MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(_8080bw_state,mw8080bw)
/* add shifter */
@@ -1363,15 +1363,14 @@ MACHINE_CONFIG_END
/* */
/*******************************************************/
-static INTERRUPT_GEN( polaris_interrupt )
+INTERRUPT_GEN_MEMBER(_8080bw_state::polaris_interrupt)
{
- _8080bw_state *state = device->machine().driver_data<_8080bw_state>();
- state->m_polaris_cloud_speed++;
+ m_polaris_cloud_speed++;
- if (state->m_polaris_cloud_speed >= 4) /* every 4 frames - this was verified against real machine */
+ if (m_polaris_cloud_speed >= 4) /* every 4 frames - this was verified against real machine */
{
- state->m_polaris_cloud_speed = 0;
- state->m_polaris_cloud_pos++;
+ m_polaris_cloud_speed = 0;
+ m_polaris_cloud_pos++;
}
}
@@ -1461,7 +1460,7 @@ static MACHINE_CONFIG_DERIVED_CLASS( polaris, mw8080bw_root, _8080bw_state )
MCFG_CPU_PROGRAM_MAP(schaser_map)
MCFG_CPU_IO_MAP(polaris_io_map)
MCFG_WATCHDOG_VBLANK_INIT(255)
- MCFG_CPU_VBLANK_INT("screen", polaris_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, polaris_interrupt)
MCFG_MACHINE_START_OVERRIDE(_8080bw_state,polaris)
/* add shifter */
@@ -2074,7 +2073,7 @@ static MACHINE_CONFIG_DERIVED_CLASS( darthvdr, mw8080bw_root, _8080bw_state )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(darthvdr_map)
MCFG_CPU_IO_MAP(darthvdr_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _8080bw_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(_8080bw_state,darthvdr)
MCFG_MACHINE_RESET_OVERRIDE(_8080bw_state,darthvdr)
diff --git a/src/mame/drivers/88games.c b/src/mame/drivers/88games.c
index 4f6f87bcdbb..f052294f6b6 100644
--- a/src/mame/drivers/88games.c
+++ b/src/mame/drivers/88games.c
@@ -22,11 +22,10 @@
*
*************************************/
-static INTERRUPT_GEN( k88games_interrupt )
+INTERRUPT_GEN_MEMBER(_88games_state::k88games_interrupt)
{
- _88games_state *state = device->machine().driver_data<_88games_state>();
- if (k052109_is_irq_enabled(state->m_k052109))
+ if (k052109_is_irq_enabled(m_k052109))
irq0_line_hold(device);
}
@@ -370,7 +369,7 @@ static MACHINE_CONFIG_START( 88games, _88games_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI, 3000000) /* ? */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", k88games_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", _88games_state, k88games_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/acefruit.c b/src/mame/drivers/acefruit.c
index 65d4c568396..09cb272f917 100644
--- a/src/mame/drivers/acefruit.c
+++ b/src/mame/drivers/acefruit.c
@@ -40,6 +40,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(acefruit_vblank);
};
@@ -83,11 +84,10 @@ void acefruit_state::video_start()
m_refresh_timer = machine().scheduler().timer_alloc(FUNC(acefruit_refresh));
}
-static INTERRUPT_GEN( acefruit_vblank )
+INTERRUPT_GEN_MEMBER(acefruit_state::acefruit_vblank)
{
- acefruit_state *state = device->machine().driver_data<acefruit_state>();
- device->execute().set_input_line(0, HOLD_LINE );
- state->m_refresh_timer->adjust( attotime::zero );
+ device.execute().set_input_line(0, HOLD_LINE );
+ m_refresh_timer->adjust( attotime::zero );
}
UINT32 acefruit_state::screen_update_acefruit(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
@@ -584,7 +584,7 @@ static MACHINE_CONFIG_START( acefruit, acefruit_state )
MCFG_CPU_PROGRAM_MAP(acefruit_map)
MCFG_CPU_IO_MAP(acefruit_io)
MCFG_GFXDECODE(acefruit)
- MCFG_CPU_VBLANK_INT("screen", acefruit_vblank)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", acefruit_state, acefruit_vblank)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/actfancr.c b/src/mame/drivers/actfancr.c
index ff35a1b2935..f053d2da77d 100644
--- a/src/mame/drivers/actfancr.c
+++ b/src/mame/drivers/actfancr.c
@@ -323,7 +323,7 @@ static MACHINE_CONFIG_START( actfancr, actfancr_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",H6280,21477200/3) /* Should be accurate */
MCFG_CPU_PROGRAM_MAP(actfan_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", actfancr_state, irq0_line_hold) /* VBL */
MCFG_CPU_ADD("audiocpu",M6502, 1500000) /* Should be accurate */
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -373,7 +373,7 @@ static MACHINE_CONFIG_START( triothep, actfancr_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",H6280,XTAL_21_4772MHz/3) /* XIN=21.4772Mhz, verified on pcb */
MCFG_CPU_PROGRAM_MAP(triothep_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", actfancr_state, irq0_line_hold) /* VBL */
MCFG_CPU_ADD("audiocpu",M6502, XTAL_12MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
diff --git a/src/mame/drivers/adp.c b/src/mame/drivers/adp.c
index 2af8f93c836..5770b1a3280 100644
--- a/src/mame/drivers/adp.c
+++ b/src/mame/drivers/adp.c
@@ -184,6 +184,7 @@ public:
DECLARE_MACHINE_RESET(skattv);
DECLARE_PALETTE_INIT(adp);
UINT32 screen_update_adp(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ //INTERRUPT_GEN_MEMBER(adp_int);
};
@@ -621,9 +622,9 @@ static INPUT_PORTS_START( skattv )
INPUT_PORTS_END
/*
-static INTERRUPT_GEN( adp_int )
+INTERRUPT_GEN_MEMBER(adp_state::adp_int)
{
- device->execute().set_input_line(1, HOLD_LINE); // ??? All irqs have the same vector, and the mask used is 0 or 7
+ device.execute().set_input_line(1, HOLD_LINE); // ??? All irqs have the same vector, and the mask used is 0 or 7
}
*/
static const ay8910_interface ay8910_config =
@@ -663,7 +664,7 @@ static MACHINE_CONFIG_START( quickjac, adp_state )
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(quickjac_mem)
-// MCFG_CPU_VBLANK_INT("screen", adp_int)
+ //MCFG_CPU_VBLANK_INT_DRIVER("screen", adp_state, adp_int)
MCFG_MACHINE_START_OVERRIDE(adp_state,skattv)
MCFG_MACHINE_RESET_OVERRIDE(adp_state,skattv)
@@ -695,7 +696,7 @@ static MACHINE_CONFIG_START( skattv, adp_state )
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(skattv_mem)
-// MCFG_CPU_VBLANK_INT("screen", adp_int)
+ //MCFG_CPU_VBLANK_INT_DRIVER("screen", adp_state, adp_int)
MCFG_MACHINE_START_OVERRIDE(adp_state,skattv)
MCFG_MACHINE_RESET_OVERRIDE(adp_state,skattv)
diff --git a/src/mame/drivers/aeroboto.c b/src/mame/drivers/aeroboto.c
index c7922e411e8..f701c52f00f 100644
--- a/src/mame/drivers/aeroboto.c
+++ b/src/mame/drivers/aeroboto.c
@@ -39,14 +39,13 @@ READ8_MEMBER(aeroboto_state::aeroboto_201_r)
}
-static INTERRUPT_GEN( aeroboto_interrupt )
+INTERRUPT_GEN_MEMBER(aeroboto_state::aeroboto_interrupt)
{
- aeroboto_state *state = device->machine().driver_data<aeroboto_state>();
- if (!state->m_disable_irq)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if (!m_disable_irq)
+ device.execute().set_input_line(0, ASSERT_LINE);
else
- state->m_disable_irq--;
+ m_disable_irq--;
}
READ8_MEMBER(aeroboto_state::aeroboto_irq_ack_r)
@@ -252,11 +251,11 @@ static MACHINE_CONFIG_START( formatz, aeroboto_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, XTAL_10MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", aeroboto_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aeroboto_state, aeroboto_interrupt)
MCFG_CPU_ADD("audiocpu", M6809, XTAL_10MHz/16) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aeroboto_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/aerofgt.c b/src/mame/drivers/aerofgt.c
index 23cf346dbba..89df34b0ec9 100644
--- a/src/mame/drivers/aerofgt.c
+++ b/src/mame/drivers/aerofgt.c
@@ -1327,7 +1327,7 @@ static MACHINE_CONFIG_START( pspikes, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(pspikes_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1366,7 +1366,7 @@ static MACHINE_CONFIG_START( spikes91, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(spikes91_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
/* + Z80 for sound */
@@ -1400,7 +1400,7 @@ static MACHINE_CONFIG_START( pspikesb, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(pspikesb_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
@@ -1430,7 +1430,7 @@ static MACHINE_CONFIG_START( pspikesc, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(pspikesc_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
@@ -1460,7 +1460,7 @@ static MACHINE_CONFIG_START( karatblz, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(karatblz_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1499,7 +1499,7 @@ static MACHINE_CONFIG_START( spinlbrk, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(spinlbrk_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* there are vectors for 3 and 4 too */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* there are vectors for 3 and 4 too */
MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4) /* 5mhz verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1538,7 +1538,7 @@ static MACHINE_CONFIG_START( turbofrc, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(turbofrc_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_CPU_ADD("audiocpu",Z80,XTAL_5MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1577,7 +1577,7 @@ static MACHINE_CONFIG_START( aerofgtb, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(aerofgtb_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1617,7 +1617,7 @@ static MACHINE_CONFIG_START( aerofgt, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(aerofgt_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_CPU_ADD("audiocpu",Z80,XTAL_20MHz/4) /* 5 MHz verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1657,7 +1657,7 @@ static MACHINE_CONFIG_START( aerfboot, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(aerfboot_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(aerfboot_sound_map)
@@ -1691,7 +1691,7 @@ static MACHINE_CONFIG_START( aerfboo2, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(aerfboo2_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq2_line_hold)
MCFG_MACHINE_START_OVERRIDE(aerofgt_state,common)
MCFG_MACHINE_RESET_OVERRIDE(aerofgt_state,common)
@@ -1722,7 +1722,7 @@ static MACHINE_CONFIG_START( wbbc97, aerofgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,20000000/2) /* 10 MHz (?) */
MCFG_CPU_PROGRAM_MAP(wbbc97_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* all irq vectors are the same */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aerofgt_state, irq1_line_hold)/* all irq vectors are the same */
MCFG_CPU_ADD("audiocpu",Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(wbbc97_sound_map)
diff --git a/src/mame/drivers/airbustr.c b/src/mame/drivers/airbustr.c
index 0d14e3b4965..3b74e1aa5a8 100644
--- a/src/mame/drivers/airbustr.c
+++ b/src/mame/drivers/airbustr.c
@@ -561,9 +561,9 @@ static TIMER_DEVICE_CALLBACK( airbustr_scanline )
}
/* Sub Z80 uses IM2 too, but 0xff irq routine just contains an irq ack in it */
-static INTERRUPT_GEN( slave_interrupt )
+INTERRUPT_GEN_MEMBER(airbustr_state::slave_interrupt)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xfd);
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xfd);
}
/* Machine Initialization */
@@ -630,12 +630,12 @@ static MACHINE_CONFIG_START( airbustr, airbustr_state )
MCFG_CPU_ADD("slave", Z80, 6000000) // ???
MCFG_CPU_PROGRAM_MAP(slave_map)
MCFG_CPU_IO_MAP(slave_io_map)
- MCFG_CPU_VBLANK_INT("screen", slave_interrupt) /* nmi signal from master cpu */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", airbustr_state, slave_interrupt) /* nmi signal from master cpu */
MCFG_CPU_ADD("audiocpu", Z80, 6000000) // ???
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) // nmi are caused by sub cpu writing a sound command
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", airbustr_state, irq0_line_hold) // nmi are caused by sub cpu writing a sound command
MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // Palette RAM is filled by sub cpu with data supplied by main cpu
// Maybe a high value is safer in order to avoid glitches
diff --git a/src/mame/drivers/ajax.c b/src/mame/drivers/ajax.c
index 2f7e61d8ebc..56201ccd4d5 100644
--- a/src/mame/drivers/ajax.c
+++ b/src/mame/drivers/ajax.c
@@ -210,7 +210,7 @@ static MACHINE_CONFIG_START( ajax, ajax_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI, 3000000) /* 12/4 MHz*/
MCFG_CPU_PROGRAM_MAP(ajax_main_map)
- MCFG_CPU_VBLANK_INT("screen", ajax_interrupt) /* IRQs triggered by the 051960 */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ajax_state, ajax_interrupt) /* IRQs triggered by the 051960 */
MCFG_CPU_ADD("sub", M6809, 3000000) /* ? */
MCFG_CPU_PROGRAM_MAP(ajax_sub_map)
diff --git a/src/mame/drivers/albazc.c b/src/mame/drivers/albazc.c
index c53b08cf9bf..ee19f57ae20 100644
--- a/src/mame/drivers/albazc.c
+++ b/src/mame/drivers/albazc.c
@@ -271,7 +271,7 @@ static MACHINE_CONFIG_START( hanaroku, albazc_state )
MCFG_CPU_ADD("maincpu", Z80,6000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(hanaroku_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", albazc_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/albazg.c b/src/mame/drivers/albazg.c
index ac7c64a0631..e12fdeba24c 100644
--- a/src/mame/drivers/albazg.c
+++ b/src/mame/drivers/albazg.c
@@ -380,7 +380,7 @@ static MACHINE_CONFIG_START( yumefuda, albazg_state )
MCFG_CPU_ADD("maincpu", Z80 , MASTER_CLOCK/2) /* xtal is 12 Mhz, unknown divider*/
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(port_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", albazg_state, irq0_line_hold)
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/aliens.c b/src/mame/drivers/aliens.c
index 50a11a7f01d..2e0d41b8de4 100644
--- a/src/mame/drivers/aliens.c
+++ b/src/mame/drivers/aliens.c
@@ -19,12 +19,11 @@ Preliminary driver by:
/* prototypes */
static KONAMI_SETLINES_CALLBACK( aliens_banking );
-static INTERRUPT_GEN( aliens_interrupt )
+INTERRUPT_GEN_MEMBER(aliens_state::aliens_interrupt)
{
- aliens_state *state = device->machine().driver_data<aliens_state>();
- if (k051960_is_irq_enabled(state->m_k051960))
- device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
+ if (k051960_is_irq_enabled(m_k051960))
+ device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
}
READ8_MEMBER(aliens_state::bankedram_r)
@@ -256,7 +255,7 @@ static MACHINE_CONFIG_START( aliens, aliens_state )
MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8) /* 052001 (verified on pcb) */
MCFG_CPU_PROGRAM_MAP(aliens_map)
- MCFG_CPU_VBLANK_INT("screen", aliens_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aliens_state, aliens_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(aliens_sound_map)
diff --git a/src/mame/drivers/alpha68k.c b/src/mame/drivers/alpha68k.c
index 5068f4b9e6d..b952fe37bbf 100644
--- a/src/mame/drivers/alpha68k.c
+++ b/src/mame/drivers/alpha68k.c
@@ -1955,14 +1955,14 @@ static MACHINE_CONFIG_START( sstingry, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 6000000) /* 24MHz/4? */
MCFG_CPU_PROGRAM_MAP(kyros_map)
- MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
- MCFG_CPU_PERIODIC_INT(irq2_line_hold,60) // MCU irq
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60) // MCU irq
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(sstingry_sound_map)
MCFG_CPU_IO_MAP(kyros_sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold, 2*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, nmi_line_pulse, 4000)
MCFG_CPU_ADD("mcu", I8748, 9263750) /* 9.263750 MHz oscillator, divided by 3*5 internally */
// MCFG_CPU_PROGRAM_MAP(i8748_map)
@@ -2005,14 +2005,14 @@ static MACHINE_CONFIG_START( kyros, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_24MHz/4) /* Verified on bootleg PCB */
MCFG_CPU_PROGRAM_MAP(kyros_map)
- MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
- MCFG_CPU_PERIODIC_INT(irq2_line_hold,60) // MCU irq
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60) // MCU irq
MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz/6) /* Verified on bootleg PCB */
MCFG_CPU_PROGRAM_MAP(kyros_sound_map)
MCFG_CPU_IO_MAP(kyros_sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold, 2*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, nmi_line_pulse, 4000)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,common)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,common)
@@ -2051,13 +2051,13 @@ static MACHINE_CONFIG_START( jongbou, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(kyros_map)
- MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
- MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*16) // MCU irq
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*16) // MCU irq
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(jongbou_sound_map)
MCFG_CPU_IO_MAP(jongbou_sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 160*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq0_line_hold, 160*60)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,common)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,common)
@@ -2088,7 +2088,7 @@ static MACHINE_CONFIG_START( alpha68k_I, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 6000000) /* 24MHz/4? */
MCFG_CPU_PROGRAM_MAP(alpha68k_I_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 4000000) // 4Mhz seems to yield the correct tone
MCFG_CPU_PROGRAM_MAP(alpha68k_I_s_map)
@@ -2117,12 +2117,11 @@ static MACHINE_CONFIG_START( alpha68k_I, alpha68k_state )
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0)
MACHINE_CONFIG_END
-static INTERRUPT_GEN( alpha68k_sound_nmi )
+INTERRUPT_GEN_MEMBER(alpha68k_state::alpha68k_sound_nmi)
{
- alpha68k_state *state = device->machine().driver_data<alpha68k_state>();
- if(state->m_sound_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_sound_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( alpha68k_II, alpha68k_state )
@@ -2130,12 +2129,12 @@ static MACHINE_CONFIG_START( alpha68k_II, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000) /* Correct */
MCFG_CPU_PROGRAM_MAP(alpha68k_II_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 3579545*2) /* Unlikely but needed to stop nested NMI's */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 7500)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 7500)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_II)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_II)
@@ -2169,8 +2168,8 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( btlfieldb, alpha68k_II )
MCFG_CPU_MODIFY("maincpu")
- MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
- MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*4) // MCU irq
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*4) // MCU irq
MACHINE_CONFIG_END
static MACHINE_CONFIG_START( alpha68k_II_gm, alpha68k_state )
@@ -2178,13 +2177,13 @@ static MACHINE_CONFIG_START( alpha68k_II_gm, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(alpha68k_II_map)
- MCFG_CPU_VBLANK_INT("screen",irq1_line_hold)
- MCFG_CPU_PERIODIC_INT(irq2_line_hold,60*3) // MCU irq
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, irq2_line_hold, 60*3) // MCU irq
MCFG_CPU_ADD("audiocpu", Z80, 4000000*2) // TODO: fix this
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 7500)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 7500)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_II)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_II)
@@ -2222,12 +2221,12 @@ static MACHINE_CONFIG_START( alpha68k_V, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
MCFG_CPU_PROGRAM_MAP(alpha68k_V_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, /*3579545*/3579545*2) /* Unlikely but needed to stop nested NMI's */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 8500)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 8500)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_V)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_V)
@@ -2264,12 +2263,12 @@ static MACHINE_CONFIG_START( alpha68k_V_sb, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
MCFG_CPU_PROGRAM_MAP(alpha68k_V_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq3_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, /*3579545*/3579545*2) /* Unlikely but needed to stop nested NMI's */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(alpha68k_sound_nmi, 8500)
+ MCFG_CPU_PERIODIC_INT_DRIVER(alpha68k_state, alpha68k_sound_nmi, 8500)
MCFG_MACHINE_START_OVERRIDE(alpha68k_state,alpha68k_V)
MCFG_MACHINE_RESET_OVERRIDE(alpha68k_state,alpha68k_V)
@@ -2306,7 +2305,7 @@ static MACHINE_CONFIG_START( tnextspc, alpha68k_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 9000000) /* Confirmed 18 MHz/2 */
MCFG_CPU_PROGRAM_MAP(tnextspc_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", alpha68k_state, irq1_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(tnextspc_sound_map)
diff --git a/src/mame/drivers/amaticmg.c b/src/mame/drivers/amaticmg.c
index 990f9f398dc..97d797a2fce 100644
--- a/src/mame/drivers/amaticmg.c
+++ b/src/mame/drivers/amaticmg.c
@@ -454,6 +454,7 @@ public:
DECLARE_PALETTE_INIT(amaticmg2);
UINT32 screen_update_amaticmg(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
UINT32 screen_update_amaticmg2(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(amaticmg2_irq);
};
@@ -866,7 +867,7 @@ static MACHINE_CONFIG_START( amaticmg, amaticmg_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK) /* WRONG! */
MCFG_CPU_PROGRAM_MAP(amaticmg_map)
MCFG_CPU_IO_MAP(amaticmg_portmap)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) // no NMI mask?
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", amaticmg_state, nmi_line_pulse) // no NMI mask?
// MCFG_NVRAM_ADD_0FILL("nvram")
@@ -903,12 +904,11 @@ static MACHINE_CONFIG_START( amaticmg, amaticmg_state )
MACHINE_CONFIG_END
-static INTERRUPT_GEN( amaticmg2_irq )
+INTERRUPT_GEN_MEMBER(amaticmg_state::amaticmg2_irq)
{
- amaticmg_state *state = device->machine().driver_data<amaticmg_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -916,7 +916,7 @@ static MACHINE_CONFIG_DERIVED( amaticmg2, amaticmg )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_IO_MAP(amaticmg2_portmap)
- MCFG_CPU_VBLANK_INT("screen", amaticmg2_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", amaticmg_state, amaticmg2_irq)
MCFG_SCREEN_MODIFY("screen")
MCFG_SCREEN_UPDATE_DRIVER(amaticmg_state, screen_update_amaticmg2)
diff --git a/src/mame/drivers/ambush.c b/src/mame/drivers/ambush.c
index c8f655547ac..c1322602dfc 100644
--- a/src/mame/drivers/ambush.c
+++ b/src/mame/drivers/ambush.c
@@ -232,7 +232,7 @@ static MACHINE_CONFIG_START( ambush, ambush_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6) /* XTAL confirmed, divisor guessed */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ambush_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/ampoker2.c b/src/mame/drivers/ampoker2.c
index a999d65a87a..72de4c13aa4 100644
--- a/src/mame/drivers/ampoker2.c
+++ b/src/mame/drivers/ampoker2.c
@@ -1169,7 +1169,7 @@ static MACHINE_CONFIG_START( ampoker2, ampoker2_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/2) /* 3 MHz */
MCFG_CPU_PROGRAM_MAP(ampoker2_map)
MCFG_CPU_IO_MAP(ampoker2_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 1536)
+ MCFG_CPU_PERIODIC_INT_DRIVER(ampoker2_state, nmi_line_pulse, 1536)
MCFG_WATCHDOG_TIME_INIT(attotime::from_msec(200)) /* 200 ms, measured */
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/amspdwy.c b/src/mame/drivers/amspdwy.c
index 0301cd17ae5..7fed59e03ea 100644
--- a/src/mame/drivers/amspdwy.c
+++ b/src/mame/drivers/amspdwy.c
@@ -275,7 +275,7 @@ static MACHINE_CONFIG_START( amspdwy, amspdwy_state )
MCFG_CPU_ADD("maincpu", Z80,3000000)
MCFG_CPU_PROGRAM_MAP(amspdwy_map)
MCFG_CPU_IO_MAP(amspdwy_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* IRQ: 60Hz, NMI: retn */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", amspdwy_state, irq0_line_hold) /* IRQ: 60Hz, NMI: retn */
MCFG_CPU_ADD("audiocpu", Z80,3000000) /* Can't be disabled: the YM2151 timers must work */
MCFG_CPU_PROGRAM_MAP(amspdwy_sound_map)
diff --git a/src/mame/drivers/angelkds.c b/src/mame/drivers/angelkds.c
index 736f2e78b2d..ea8cfb43d20 100644
--- a/src/mame/drivers/angelkds.c
+++ b/src/mame/drivers/angelkds.c
@@ -602,7 +602,7 @@ static MACHINE_CONFIG_START( angelkds, angelkds_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_6MHz)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", angelkds_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80, XTAL_4MHz)
MCFG_CPU_PROGRAM_MAP(sub_map)
diff --git a/src/mame/drivers/appoooh.c b/src/mame/drivers/appoooh.c
index 77f3c3c05cc..4bc50c4204a 100644
--- a/src/mame/drivers/appoooh.c
+++ b/src/mame/drivers/appoooh.c
@@ -429,12 +429,11 @@ void appoooh_state::machine_reset()
m_priority = 0;
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(appoooh_state::vblank_irq)
{
- appoooh_state *state = device->machine().driver_data<appoooh_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( appoooh_common, appoooh_state )
@@ -443,7 +442,7 @@ static MACHINE_CONFIG_START( appoooh_common, appoooh_state )
MCFG_CPU_ADD("maincpu", Z80,18432000/6) /* ??? the main xtal is 18.432 MHz */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", appoooh_state, vblank_irq)
/* sound hardware */
diff --git a/src/mame/drivers/aquarium.c b/src/mame/drivers/aquarium.c
index 0bec20ed5be..f2d5040de26 100644
--- a/src/mame/drivers/aquarium.c
+++ b/src/mame/drivers/aquarium.c
@@ -318,7 +318,7 @@ static MACHINE_CONFIG_START( aquarium, aquarium_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2) // clock not verified on pcb
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aquarium_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz/6) // clock not verified on pcb
MCFG_CPU_PROGRAM_MAP(snd_map)
diff --git a/src/mame/drivers/arabian.c b/src/mame/drivers/arabian.c
index 9ad4875559a..cba5b39b361 100644
--- a/src/mame/drivers/arabian.c
+++ b/src/mame/drivers/arabian.c
@@ -360,7 +360,7 @@ static MACHINE_CONFIG_START( arabian, arabian_state )
MCFG_CPU_ADD("maincpu", Z80, MAIN_OSC/4)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", arabian_state, irq0_line_hold)
MCFG_CPU_ADD("mcu", MB8841, MAIN_OSC/3/2)
MCFG_CPU_IO_MAP(mcu_io_map)
diff --git a/src/mame/drivers/aristmk4.c b/src/mame/drivers/aristmk4.c
index 2da557e44ca..07bdf58336e 100644
--- a/src/mame/drivers/aristmk4.c
+++ b/src/mame/drivers/aristmk4.c
@@ -1684,7 +1684,7 @@ static MACHINE_CONFIG_START( aristmk4, aristmk4_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, MAIN_CLOCK/8) // 1.5mhz
MCFG_CPU_PROGRAM_MAP(aristmk4_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aristmk4_state, irq0_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
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 ?
@@ -1727,7 +1727,7 @@ static MACHINE_CONFIG_DERIVED( aristmk4_poker, aristmk4 )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(aristmk4_poker_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aristmk4_state, irq0_line_hold)
MACHINE_CONFIG_END
/* same as Aristocrat Mark-IV HW color offset 7 */
diff --git a/src/mame/drivers/arkanoid.c b/src/mame/drivers/arkanoid.c
index 488a277edf1..6016478c4e4 100644
--- a/src/mame/drivers/arkanoid.c
+++ b/src/mame/drivers/arkanoid.c
@@ -1020,7 +1020,7 @@ static MACHINE_CONFIG_START( arkanoid, arkanoid_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(arkanoid_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
MCFG_CPU_ADD("mcu", M68705, XTAL_12MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(mcu_map)
@@ -1058,7 +1058,7 @@ static MACHINE_CONFIG_START( hexa, arkanoid_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* Imported from arkanoid - correct? */
MCFG_CPU_PROGRAM_MAP(hexa_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(arkanoid_state,arkanoid)
MCFG_MACHINE_RESET_OVERRIDE(arkanoid_state,arkanoid)
@@ -1100,7 +1100,7 @@ static MACHINE_CONFIG_DERIVED( brixian, arkanoid )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(brixian_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", arkanoid_state, irq0_line_hold)
MCFG_DEVICE_REMOVE("mcu")
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/armedf.c b/src/mame/drivers/armedf.c
index adc126d88e5..de4ea0773f9 100644
--- a/src/mame/drivers/armedf.c
+++ b/src/mame/drivers/armedf.c
@@ -1179,12 +1179,12 @@ static MACHINE_CONFIG_START( terraf, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(terraf_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1224,12 +1224,12 @@ static MACHINE_CONFIG_START( terrafb, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(terraf_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_CPU_ADD("extra", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(terrafb_extraz80_map)
@@ -1272,12 +1272,12 @@ static MACHINE_CONFIG_START( kozure, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(kozure_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1316,12 +1316,12 @@ static MACHINE_CONFIG_START( armedf, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(armedf_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1360,12 +1360,12 @@ static MACHINE_CONFIG_START( cclimbr2, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(cclimbr2_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1404,12 +1404,12 @@ static MACHINE_CONFIG_START( legion, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(legion_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1448,12 +1448,12 @@ static MACHINE_CONFIG_START( legiono, armedf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // 8mhz?
MCFG_CPU_PROGRAM_MAP(legiono_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq2_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(cclimbr2_soundmap)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(armedf_state,armedf)
MCFG_MACHINE_RESET_OVERRIDE(armedf_state,armedf)
@@ -1505,12 +1505,12 @@ static MACHINE_CONFIG_START( bigfghtr, bigfghtr_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) // verified
MCFG_CPU_PROGRAM_MAP(bigfghtr_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", armedf_state, irq1_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) // 4mhz?
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(armedf_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(bigfghtr_state,bigfghtr)
MCFG_MACHINE_RESET_OVERRIDE(bigfghtr_state,bigfghtr)
diff --git a/src/mame/drivers/ashnojoe.c b/src/mame/drivers/ashnojoe.c
index 15467971f7b..b6d6174a7a5 100644
--- a/src/mame/drivers/ashnojoe.c
+++ b/src/mame/drivers/ashnojoe.c
@@ -351,7 +351,7 @@ static MACHINE_CONFIG_START( ashnojoe, ashnojoe_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(ashnojoe_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ashnojoe_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/asterix.c b/src/mame/drivers/asterix.c
index c329451a059..b5e93469b6a 100644
--- a/src/mame/drivers/asterix.c
+++ b/src/mame/drivers/asterix.c
@@ -53,15 +53,14 @@ WRITE16_MEMBER(asterix_state::control2_w)
}
}
-static INTERRUPT_GEN( asterix_interrupt )
+INTERRUPT_GEN_MEMBER(asterix_state::asterix_interrupt)
{
- asterix_state *state = device->machine().driver_data<asterix_state>();
// global interrupt masking
- if (!k056832_is_irq_enabled(state->m_k056832, 0))
+ if (!k056832_is_irq_enabled(m_k056832, 0))
return;
- device->execute().set_input_line(5, HOLD_LINE); /* ??? All irqs have the same vector, and the mask used is 0 or 7 */
+ device.execute().set_input_line(5, HOLD_LINE); /* ??? All irqs have the same vector, and the mask used is 0 or 7 */
}
READ8_MEMBER(asterix_state::asterix_sound_r)
@@ -291,7 +290,7 @@ static MACHINE_CONFIG_START( asterix, asterix_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", asterix_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asterix_state, asterix_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 8000000)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/asteroid.c b/src/mame/drivers/asteroid.c
index 466dc1e137d..374dbf4ae94 100644
--- a/src/mame/drivers/asteroid.c
+++ b/src/mame/drivers/asteroid.c
@@ -615,7 +615,7 @@ static MACHINE_CONFIG_START( asteroid, asteroid_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/8)
MCFG_CPU_PROGRAM_MAP(asteroid_map)
- MCFG_CPU_PERIODIC_INT(asteroid_interrupt, (double)MASTER_CLOCK/4096/12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, asteroid_interrupt, (double)MASTER_CLOCK/4096/12)
/* video hardware */
@@ -639,7 +639,7 @@ static MACHINE_CONFIG_DERIVED( asterock, asteroid )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
- MCFG_CPU_PERIODIC_INT(asterock_interrupt, (double)MASTER_CLOCK/4096/12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, asterock_interrupt, (double)MASTER_CLOCK/4096/12)
MACHINE_CONFIG_END
@@ -668,7 +668,7 @@ static MACHINE_CONFIG_DERIVED( llander, asteroid )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(llander_map)
- MCFG_CPU_PERIODIC_INT(llander_interrupt, (double)MASTER_CLOCK/4096/12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(asteroid_state, llander_interrupt, (double)MASTER_CLOCK/4096/12)
MCFG_MACHINE_RESET(avgdvg)
diff --git a/src/mame/drivers/astinvad.c b/src/mame/drivers/astinvad.c
index 4e02c41746f..e1b0bba8547 100644
--- a/src/mame/drivers/astinvad.c
+++ b/src/mame/drivers/astinvad.c
@@ -625,7 +625,7 @@ static MACHINE_CONFIG_START( spaceint, astinvad_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK) /* a guess */
MCFG_CPU_PROGRAM_MAP(spaceint_map)
MCFG_CPU_IO_MAP(spaceint_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", astinvad_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(astinvad_state,spaceint)
MCFG_MACHINE_RESET_OVERRIDE(astinvad_state,spaceint)
diff --git a/src/mame/drivers/astrocorp.c b/src/mame/drivers/astrocorp.c
index 84376d98d29..aad63abf1a5 100644
--- a/src/mame/drivers/astrocorp.c
+++ b/src/mame/drivers/astrocorp.c
@@ -475,7 +475,7 @@ static MACHINE_CONFIG_START( showhand, astrocorp_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(showhand_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", astrocorp_state, irq4_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/asuka.c b/src/mame/drivers/asuka.c
index ae6f37a6c38..9f1d2906039 100644
--- a/src/mame/drivers/asuka.c
+++ b/src/mame/drivers/asuka.c
@@ -236,10 +236,10 @@ static TIMER_CALLBACK( cadash_interrupt5 )
state->m_maincpu->set_input_line(5, HOLD_LINE);
}
-static INTERRUPT_GEN( cadash_interrupt )
+INTERRUPT_GEN_MEMBER(asuka_state::cadash_interrupt)
{
- device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(500), FUNC(cadash_interrupt5));
- device->execute().set_input_line(4, HOLD_LINE); /* interrupt vector 4 */
+ machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(500), FUNC(cadash_interrupt5));
+ device.execute().set_input_line(4, HOLD_LINE); /* interrupt vector 4 */
}
@@ -896,7 +896,7 @@ static MACHINE_CONFIG_START( bonzeadv, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000) /* checked on PCB */
MCFG_CPU_PROGRAM_MAP(bonzeadv_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq4_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,4000000) /* sound CPU, also required for test mode */
MCFG_CPU_PROGRAM_MAP(bonzeadv_z80_map)
@@ -937,7 +937,7 @@ static MACHINE_CONFIG_START( asuka, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(asuka_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(z80_map)
@@ -983,7 +983,7 @@ static MACHINE_CONFIG_START( cadash, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz/2) /* 68000p12 running at 16Mhz, verified on pcb */
MCFG_CPU_PROGRAM_MAP(cadash_map)
- MCFG_CPU_VBLANK_INT("screen", cadash_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, cadash_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
@@ -1029,7 +1029,7 @@ static MACHINE_CONFIG_START( mofflott, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000) /* 8 MHz ??? */
MCFG_CPU_PROGRAM_MAP(asuka_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(z80_map)
@@ -1075,7 +1075,7 @@ static MACHINE_CONFIG_START( galmedes, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000) /* 8 MHz ??? */
MCFG_CPU_PROGRAM_MAP(asuka_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
@@ -1117,7 +1117,7 @@ static MACHINE_CONFIG_START( eto, asuka_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000) /* 8 MHz ??? */
MCFG_CPU_PROGRAM_MAP(eto_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", asuka_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(cadash_z80_map)
diff --git a/src/mame/drivers/atarifb.c b/src/mame/drivers/atarifb.c
index 335c2460b34..2a1ec3907ea 100644
--- a/src/mame/drivers/atarifb.c
+++ b/src/mame/drivers/atarifb.c
@@ -555,7 +555,7 @@ static MACHINE_CONFIG_START( atarifb, atarifb_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, 750000)
MCFG_CPU_PROGRAM_MAP(atarifb_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(atarifb_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/atarisy2.c b/src/mame/drivers/atarisy2.c
index dd03234c812..7099a43ce98 100644
--- a/src/mame/drivers/atarisy2.c
+++ b/src/mame/drivers/atarisy2.c
@@ -259,13 +259,12 @@ MACHINE_RESET_MEMBER(atarisy2_state,atarisy2)
*
*************************************/
-static INTERRUPT_GEN( vblank_int )
+INTERRUPT_GEN_MEMBER(atarisy2_state::vblank_int)
{
- atarisy2_state *state = device->machine().driver_data<atarisy2_state>();
/* clock the VBLANK through */
- if (state->m_interrupt_enable & 8)
- atarigen_video_int_gen(device);
+ if (m_interrupt_enable & 8)
+ atarigen_video_int_gen(&device);
}
@@ -1262,7 +1261,7 @@ static MACHINE_CONFIG_START( atarisy2, atarisy2_state )
MCFG_CPU_ADD("maincpu", T11, MASTER_CLOCK/2)
MCFG_CPU_CONFIG(t11_data)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_int)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", atarisy2_state, vblank_int)
MCFG_CPU_ADD("soundcpu", M6502, SOUND_CLOCK/8)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/atarisy4.c b/src/mame/drivers/atarisy4.c
index 392c1e45e98..b9b14ec227d 100644
--- a/src/mame/drivers/atarisy4.c
+++ b/src/mame/drivers/atarisy4.c
@@ -59,6 +59,7 @@ public:
virtual void video_reset();
DECLARE_MACHINE_RESET(airrace);
UINT32 screen_update_atarisy4(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_int);
};
@@ -516,10 +517,10 @@ READ16_MEMBER(atarisy4_state::gpu_r)
return res;
}
-static INTERRUPT_GEN( vblank_int )
+INTERRUPT_GEN_MEMBER(atarisy4_state::vblank_int)
{
if (gpu.mcr & 0x08)
- device->machine().device("maincpu")->execute().set_input_line(6, ASSERT_LINE);
+ machine().device("maincpu")->execute().set_input_line(6, ASSERT_LINE);
}
@@ -730,7 +731,7 @@ INPUT_PORTS_END
static MACHINE_CONFIG_START( atarisy4, atarisy4_state )
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_int)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", atarisy4_state, vblank_int)
MCFG_CPU_ADD("dsp0", TMS32010, 16000000)
MCFG_CPU_PROGRAM_MAP(dsp0_map)
diff --git a/src/mame/drivers/atronic.c b/src/mame/drivers/atronic.c
index 01160ad31f9..c29e473b38c 100644
--- a/src/mame/drivers/atronic.c
+++ b/src/mame/drivers/atronic.c
@@ -60,7 +60,7 @@ static MACHINE_CONFIG_START( atronic, atronic_state )
MCFG_CPU_ADD("maincpu", Z180, 6000000)
MCFG_CPU_PROGRAM_MAP(atronic_map)
MCFG_CPU_IO_MAP(atronic_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", atronic_state, irq0_line_hold)
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
diff --git a/src/mame/drivers/attckufo.c b/src/mame/drivers/attckufo.c
index 6c592e4a8e0..2ca49518587 100644
--- a/src/mame/drivers/attckufo.c
+++ b/src/mame/drivers/attckufo.c
@@ -69,6 +69,7 @@ public:
DECLARE_READ8_MEMBER( vic_videoram_r );
DECLARE_READ8_MEMBER( vic_colorram_r );
+ INTERRUPT_GEN_MEMBER(attckufo_raster_interrupt);
};
READ8_MEMBER(attckufo_state::attckufo_io_r)
@@ -148,10 +149,9 @@ static INPUT_PORTS_START( attckufo )
INPUT_PORTS_END
-static INTERRUPT_GEN( attckufo_raster_interrupt )
+INTERRUPT_GEN_MEMBER(attckufo_state::attckufo_raster_interrupt)
{
- attckufo_state *state = device->machine().driver_data<attckufo_state>();
- state->m_mos6560->raster_interrupt_gen();
+ m_mos6560->raster_interrupt_gen();
}
static MOS6560_INTERFACE( vic_intf )
@@ -166,7 +166,7 @@ static MACHINE_CONFIG_START( attckufo, attckufo_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, 14318181/14)
MCFG_CPU_PROGRAM_MAP(cpu_map)
- MCFG_CPU_PERIODIC_INT(attckufo_raster_interrupt, MOS656X_HRETRACERATE)
+ MCFG_CPU_PERIODIC_INT_DRIVER(attckufo_state, attckufo_raster_interrupt, MOS656X_HRETRACERATE)
/* video hardware */
MCFG_MOS656X_ATTACK_UFO_ADD("mos6560", "screen", 14318181/14, vic_intf, vic_videoram_map, vic_colorram_map)
diff --git a/src/mame/drivers/avalnche.c b/src/mame/drivers/avalnche.c
index 8a0eecc22c4..8ad7b3a7ed4 100644
--- a/src/mame/drivers/avalnche.c
+++ b/src/mame/drivers/avalnche.c
@@ -248,7 +248,7 @@ static MACHINE_CONFIG_START( avalnche, avalnche_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502,MASTER_CLOCK/16) /* clock input is the "2H" signal divided by two */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse,8*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(avalnche_state, nmi_line_pulse, 8*60)
/* video hardware */
diff --git a/src/mame/drivers/avt.c b/src/mame/drivers/avt.c
index 393c2da6dae..2033d641144 100644
--- a/src/mame/drivers/avt.c
+++ b/src/mame/drivers/avt.c
@@ -445,6 +445,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_avt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(avt_vblank_irq);
};
#define mc6845_h_char_total (state->m_crtc_vreg[0])
@@ -881,11 +882,10 @@ static const ay8910_interface ay8910_config =
*********************************************/
/* IM 2 */
-static INTERRUPT_GEN( avt_vblank_irq )
+INTERRUPT_GEN_MEMBER(avt_state::avt_vblank_irq)
{
- avt_state *state = device->machine().driver_data<avt_state>();
- state->m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0x06);
+ m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0x06);
}
static MACHINE_CONFIG_START( avt, avt_state )
@@ -894,7 +894,7 @@ static MACHINE_CONFIG_START( avt, avt_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK) /* guess */
MCFG_CPU_PROGRAM_MAP(avt_map)
MCFG_CPU_IO_MAP(avt_portmap)
- MCFG_CPU_VBLANK_INT("screen", avt_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", avt_state, avt_vblank_irq)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/aztarac.c b/src/mame/drivers/aztarac.c
index cc589560ab4..1e28e82b395 100644
--- a/src/mame/drivers/aztarac.c
+++ b/src/mame/drivers/aztarac.c
@@ -149,11 +149,11 @@ static MACHINE_CONFIG_START( aztarac, aztarac_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 8000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", aztarac_state, irq4_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 2000000)
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(aztarac_snd_timed_irq, 100)
+ MCFG_CPU_PERIODIC_INT_DRIVER(aztarac_state, aztarac_snd_timed_irq, 100)
MCFG_NVRAM_ADD_1FILL("nvram")
diff --git a/src/mame/drivers/backfire.c b/src/mame/drivers/backfire.c
index 441cd3c9b94..75f7c5d9e58 100644
--- a/src/mame/drivers/backfire.c
+++ b/src/mame/drivers/backfire.c
@@ -81,6 +81,7 @@ public:
virtual void video_start();
UINT32 screen_update_backfire_left(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
UINT32 screen_update_backfire_right(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(deco32_vbl_interrupt);
};
//UINT32 *backfire_180010, *backfire_188010;
@@ -432,9 +433,9 @@ static const ymz280b_interface ymz280b_intf =
sound_irq_gen
};
-static INTERRUPT_GEN( deco32_vbl_interrupt )
+INTERRUPT_GEN_MEMBER(backfire_state::deco32_vbl_interrupt)
{
- device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
+ device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
}
@@ -500,7 +501,7 @@ static MACHINE_CONFIG_START( backfire, backfire_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000/4) /* Unconfirmed */
MCFG_CPU_PROGRAM_MAP(backfire_map)
- MCFG_CPU_VBLANK_INT("lscreen", deco32_vbl_interrupt) /* or is it "rscreen?" */
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", backfire_state, deco32_vbl_interrupt) /* or is it "rscreen?" */
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/badlands.c b/src/mame/drivers/badlands.c
index 27391d806e3..75d094adbd6 100644
--- a/src/mame/drivers/badlands.c
+++ b/src/mame/drivers/badlands.c
@@ -227,21 +227,20 @@ MACHINE_RESET_MEMBER(badlands_state,badlands)
*
*************************************/
-static INTERRUPT_GEN( vblank_int )
+INTERRUPT_GEN_MEMBER(badlands_state::vblank_int)
{
- badlands_state *state = device->machine().driver_data<badlands_state>();
- int pedal_state = state->ioport("PEDALS")->read();
+ int pedal_state = ioport("PEDALS")->read();
int i;
/* update the pedals once per frame */
for (i = 0; i < 2; i++)
{
- state->m_pedal_value[i]--;
+ m_pedal_value[i]--;
if (pedal_state & (1 << i))
- state->m_pedal_value[i]++;
+ m_pedal_value[i]++;
}
- atarigen_video_int_gen(device);
+ atarigen_video_int_gen(&device);
}
@@ -502,7 +501,7 @@ static MACHINE_CONFIG_START( badlands, badlands_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, ATARI_CLOCK_14MHz/2)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_int)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", badlands_state, vblank_int)
MCFG_CPU_ADD("audiocpu", M6502, ATARI_CLOCK_14MHz/8)
MCFG_CPU_PROGRAM_MAP(audio_map)
@@ -708,7 +707,7 @@ static MACHINE_CONFIG_START( badlandsb, badlands_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/4) /* Divisor estimated */
MCFG_CPU_PROGRAM_MAP(bootleg_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_int)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", badlands_state, vblank_int)
// MCFG_CPU_ADD("audiocpu", Z80, XTAL_20MHz/12) /* Divisor estimated */
// MCFG_CPU_PROGRAM_MAP(bootleg_soundmap)
diff --git a/src/mame/drivers/bagman.c b/src/mame/drivers/bagman.c
index ebdba31fb80..906f795ece1 100644
--- a/src/mame/drivers/bagman.c
+++ b/src/mame/drivers/bagman.c
@@ -462,12 +462,11 @@ static const tms5110_interface bagman_tms5110_interface =
DEVCB_NULL /* rom clock - Only used to drive the data lines */
};
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(bagman_state::vblank_irq)
{
- bagman_state *state = device->machine().driver_data<bagman_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, HOLD_LINE);
+ if(m_irq_mask)
+ device.execute().set_input_line(0, HOLD_LINE);
}
@@ -477,7 +476,7 @@ static MACHINE_CONFIG_START( bagman, bagman_state )
MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
@@ -513,7 +512,7 @@ static MACHINE_CONFIG_START( pickin, bagman_state )
MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
MCFG_CPU_PROGRAM_MAP(pickin_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
@@ -565,7 +564,7 @@ static MACHINE_CONFIG_START( botanic, bagman_state )
MCFG_CPU_ADD("maincpu", Z80, BAGMAN_H0)
MCFG_CPU_PROGRAM_MAP(pickin_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bagman_state, vblank_irq)
MCFG_MACHINE_RESET_OVERRIDE(bagman_state,bagman)
diff --git a/src/mame/drivers/balsente.c b/src/mame/drivers/balsente.c
index 31387d9675d..9b809130ef4 100644
--- a/src/mame/drivers/balsente.c
+++ b/src/mame/drivers/balsente.c
@@ -1202,7 +1202,7 @@ static MACHINE_CONFIG_START( balsente, balsente_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, XTAL_20MHz/16) /* xtal verified but not speed */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", balsente_update_analog_inputs)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", balsente_state, balsente_update_analog_inputs)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* xtal verified but not speed */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
diff --git a/src/mame/drivers/bankp.c b/src/mame/drivers/bankp.c
index d426a6cc7e5..0d4a76158ce 100644
--- a/src/mame/drivers/bankp.c
+++ b/src/mame/drivers/bankp.c
@@ -289,12 +289,11 @@ void bankp_state::machine_reset()
m_priority = 0;
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(bankp_state::vblank_irq)
{
- bankp_state *state = device->machine().driver_data<bankp_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( bankp, bankp_state )
@@ -303,7 +302,7 @@ static MACHINE_CONFIG_START( bankp, bankp_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6)
MCFG_CPU_PROGRAM_MAP(bankp_map)
MCFG_CPU_IO_MAP(bankp_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bankp_state, vblank_irq)
/* video hardware */
diff --git a/src/mame/drivers/baraduke.c b/src/mame/drivers/baraduke.c
index 1538d242146..a1c96275fa2 100644
--- a/src/mame/drivers/baraduke.c
+++ b/src/mame/drivers/baraduke.c
@@ -379,12 +379,12 @@ static MACHINE_CONFIG_START( baraduke, baraduke_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809,49152000/32)
MCFG_CPU_PROGRAM_MAP(baraduke_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", baraduke_state, irq0_line_assert)
MCFG_CPU_ADD("mcu", HD63701,49152000/8)
MCFG_CPU_PROGRAM_MAP(mcu_map)
MCFG_CPU_IO_MAP(mcu_port_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", baraduke_state, irq0_line_hold)
MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* we need heavy synch */
diff --git a/src/mame/drivers/battlane.c b/src/mame/drivers/battlane.c
index e06e0e30147..92febf22851 100644
--- a/src/mame/drivers/battlane.c
+++ b/src/mame/drivers/battlane.c
@@ -78,15 +78,14 @@ WRITE8_MEMBER(battlane_state::battlane_cpu_command_w)
m_subcpu->set_input_line(M6809_IRQ_LINE, data & 0x02 ? CLEAR_LINE : HOLD_LINE);
}
-static INTERRUPT_GEN( battlane_cpu1_interrupt )
+INTERRUPT_GEN_MEMBER(battlane_state::battlane_cpu1_interrupt)
{
- battlane_state *state = device->machine().driver_data<battlane_state>();
/* See note in battlane_cpu_command_w */
- if (~state->m_cpu_control & 0x08)
+ if (~m_cpu_control & 0x08)
{
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
- state->m_subcpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ m_subcpu->set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
}
@@ -289,7 +288,7 @@ static MACHINE_CONFIG_START( battlane, battlane_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 1500000) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(battlane_map)
- MCFG_CPU_VBLANK_INT("screen", battlane_cpu1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", battlane_state, battlane_cpu1_interrupt)
MCFG_CPU_ADD("sub", M6809, 1500000) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(battlane_map)
diff --git a/src/mame/drivers/battlex.c b/src/mame/drivers/battlex.c
index fa884738b5c..aedc5678450 100644
--- a/src/mame/drivers/battlex.c
+++ b/src/mame/drivers/battlex.c
@@ -48,11 +48,10 @@
#include "includes/battlex.h"
-static INTERRUPT_GEN( battlex_interrupt )
+INTERRUPT_GEN_MEMBER(battlex_state::battlex_interrupt)
{
- battlex_state *state = device->machine().driver_data<battlex_state>();
- state->m_in0_b4 = 1;
- device->execute().set_input_line(0, ASSERT_LINE);
+ m_in0_b4 = 1;
+ device.execute().set_input_line(0, ASSERT_LINE);
}
CUSTOM_INPUT_MEMBER(battlex_state::battlex_in0_b4_r)
@@ -250,7 +249,7 @@ static MACHINE_CONFIG_START( battlex, battlex_state )
MCFG_CPU_ADD("maincpu", Z80,XTAL_10MHz/4 ) // ?
MCFG_CPU_PROGRAM_MAP(battlex_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_PERIODIC_INT(battlex_interrupt,400) /* controls game speed? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(battlex_state, battlex_interrupt, 400) /* controls game speed? */
/* video hardware */
diff --git a/src/mame/drivers/battlnts.c b/src/mame/drivers/battlnts.c
index febce81c0a1..f8906743244 100644
--- a/src/mame/drivers/battlnts.c
+++ b/src/mame/drivers/battlnts.c
@@ -25,11 +25,10 @@
*
*************************************/
-static INTERRUPT_GEN( battlnts_interrupt )
+INTERRUPT_GEN_MEMBER(battlnts_state::battlnts_interrupt)
{
- battlnts_state *state = device->machine().driver_data<battlnts_state>();
- if (k007342_is_int_enabled(state->m_k007342))
- device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
+ if (k007342_is_int_enabled(m_k007342))
+ device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
}
WRITE8_MEMBER(battlnts_state::battlnts_sh_irqtrigger_w)
@@ -248,7 +247,7 @@ static MACHINE_CONFIG_START( battlnts, battlnts_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, XTAL_24MHz / 2 /* 3000000*4? */)
MCFG_CPU_PROGRAM_MAP(battlnts_map)
- MCFG_CPU_VBLANK_INT("screen", battlnts_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", battlnts_state, battlnts_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_24MHz / 6 /* 3579545? */)
MCFG_CPU_PROGRAM_MAP(battlnts_sound_map)
diff --git a/src/mame/drivers/bbusters.c b/src/mame/drivers/bbusters.c
index 9e76a831418..5b1eea5d477 100644
--- a/src/mame/drivers/bbusters.c
+++ b/src/mame/drivers/bbusters.c
@@ -670,7 +670,7 @@ static MACHINE_CONFIG_START( bbusters, bbusters_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(bbusters_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bbusters_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,4000000) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -710,7 +710,7 @@ static MACHINE_CONFIG_START( mechatt, bbusters_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(mechatt_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bbusters_state, irq4_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,4000000) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/bestleag.c b/src/mame/drivers/bestleag.c
index a40698d8926..9201bd4c380 100644
--- a/src/mame/drivers/bestleag.c
+++ b/src/mame/drivers/bestleag.c
@@ -365,7 +365,7 @@ GFXDECODE_END
static MACHINE_CONFIG_START( bestleag, bestleag_state )
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(bestleag_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bestleag_state, irq6_line_hold)
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
diff --git a/src/mame/drivers/bfcobra.c b/src/mame/drivers/bfcobra.c
index f82c62af0a4..ac700c89c95 100644
--- a/src/mame/drivers/bfcobra.c
+++ b/src/mame/drivers/bfcobra.c
@@ -300,6 +300,8 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_bfcobra(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(timer_irq);
+ INTERRUPT_GEN_MEMBER(vblank_gen);
};
@@ -1762,28 +1764,27 @@ DRIVER_INIT_MEMBER(bfcobra_state,bfcobra)
}
/* TODO */
-static INTERRUPT_GEN( timer_irq )
+INTERRUPT_GEN_MEMBER(bfcobra_state::timer_irq)
{
- generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
+ generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
}
/* TODO */
-static INTERRUPT_GEN( vblank_gen )
+INTERRUPT_GEN_MEMBER(bfcobra_state::vblank_gen)
{
- bfcobra_state *state = device->machine().driver_data<bfcobra_state>();
- state->m_vblank_irq = 1;
- update_irqs(device->machine());
+ m_vblank_irq = 1;
+ update_irqs(machine());
}
static MACHINE_CONFIG_START( bfcobra, bfcobra_state )
MCFG_CPU_ADD("maincpu", Z80, Z80_XTAL)
MCFG_CPU_PROGRAM_MAP(z80_prog_map)
MCFG_CPU_IO_MAP(z80_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bfcobra_state, vblank_gen)
MCFG_CPU_ADD("audiocpu", M6809, M6809_XTAL)
MCFG_CPU_PROGRAM_MAP(m6809_prog_map)
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfcobra_state, timer_irq, 1000)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/bfm_sc1.c b/src/mame/drivers/bfm_sc1.c
index 53cb816a970..a25126b830d 100644
--- a/src/mame/drivers/bfm_sc1.c
+++ b/src/mame/drivers/bfm_sc1.c
@@ -175,6 +175,7 @@ public:
DECLARE_DRIVER_INIT(rou029);
DECLARE_DRIVER_INIT(nocrypt);
virtual void machine_reset();
+ INTERRUPT_GEN_MEMBER(timer_irq);
};
#define VFD_RESET 0x20
@@ -213,17 +214,16 @@ WRITE8_MEMBER(bfm_sc1_state::bankswitch_w)
///////////////////////////////////////////////////////////////////////////
-static INTERRUPT_GEN( timer_irq )
+INTERRUPT_GEN_MEMBER(bfm_sc1_state::timer_irq)
{
- bfm_sc1_state *state = device->machine().driver_data<bfm_sc1_state>();
- if ( state->m_is_timer_enabled )
+ if ( m_is_timer_enabled )
{
- state->m_irq_status = 0x01 |0x02; //0xff;
+ m_irq_status = 0x01 |0x02; //0xff;
- state->m_sc1_Inputs[2] = state->ioport("STROBE0")->read();
+ m_sc1_Inputs[2] = ioport("STROBE0")->read();
- generic_pulse_irq_line(device->machine().device("maincpu"), M6809_IRQ_LINE, 1);
+ generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
}
}
@@ -1095,7 +1095,7 @@ INPUT_PORTS_END
static MACHINE_CONFIG_START( scorpion1, bfm_sc1_state )
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4) // 6809 CPU at 1 Mhz
MCFG_CPU_PROGRAM_MAP(sc1_base) // setup read and write memorymap
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000 ) // generate 1000 IRQ's per second
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc1_state, timer_irq, 1000) // generate 1000 IRQ's per second
MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
MCFG_BFMBD1_ADD("vfd0",0)
diff --git a/src/mame/drivers/bfm_sc2.c b/src/mame/drivers/bfm_sc2.c
index 0c4f3734f53..0a69e2ccd9b 100644
--- a/src/mame/drivers/bfm_sc2.c
+++ b/src/mame/drivers/bfm_sc2.c
@@ -302,6 +302,7 @@ public:
DECLARE_MACHINE_RESET(awp_init);
DECLARE_MACHINE_START(sc2dmd);
DECLARE_MACHINE_RESET(dm01_init);
+ INTERRUPT_GEN_MEMBER(timer_irq);
};
@@ -503,17 +504,16 @@ WRITE8_MEMBER(bfm_sc2_state::bankswitch_w)
///////////////////////////////////////////////////////////////////////////
-static INTERRUPT_GEN( timer_irq )
+INTERRUPT_GEN_MEMBER(bfm_sc2_state::timer_irq)
{
- bfm_sc2_state *state = device->machine().driver_data<bfm_sc2_state>();
- state->m_timercnt++;
+ m_timercnt++;
- if ( state->m_is_timer_enabled )
+ if ( m_is_timer_enabled )
{
- state->m_irq_timer_stat = 0x01;
- state->m_irq_status = 0x02;
+ m_irq_timer_stat = 0x01;
+ m_irq_status = 0x02;
- generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
+ generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
}
}
@@ -2157,7 +2157,7 @@ static MACHINE_CONFIG_START( scorpion2_vid, bfm_sc2_state )
MCFG_QUANTUM_TIME(attotime::from_hz(960)) // needed for serial communication !!
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 ) // 6809 CPU at 2 Mhz
MCFG_CPU_PROGRAM_MAP(memmap_vid) // setup scorpion2 board memorymap
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000) // generate 1000 IRQ's per second
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000) // generate 1000 IRQ's per second
MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
MCFG_BFMBD1_ADD("vfd0",0)
@@ -3705,7 +3705,7 @@ static MACHINE_CONFIG_START( scorpion2, bfm_sc2_state )
MCFG_MACHINE_RESET_OVERRIDE(bfm_sc2_state,awp_init)
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 )
MCFG_CPU_PROGRAM_MAP(sc2_basemap)
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000)
MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
MCFG_BFMBD1_ADD("vfd0",0)
@@ -3739,7 +3739,7 @@ static MACHINE_CONFIG_START( scorpion2_dm01, bfm_sc2_state )
MCFG_QUANTUM_TIME(attotime::from_hz(960)) // needed for serial communication !!
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4 )
MCFG_CPU_PROGRAM_MAP(sc2_basemap)
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000 )
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfm_sc2_state, timer_irq, 1000)
MCFG_WATCHDOG_TIME_INIT(PERIOD_OF_555_MONOSTABLE(120000,100e-9))
MCFG_SPEAKER_STANDARD_MONO("mono")
diff --git a/src/mame/drivers/bfm_sc5.c b/src/mame/drivers/bfm_sc5.c
index 135bee44c85..8d42a4491fa 100644
--- a/src/mame/drivers/bfm_sc5.c
+++ b/src/mame/drivers/bfm_sc5.c
@@ -33,6 +33,7 @@ protected:
required_device<cpu_device> m_maincpu;
public:
DECLARE_DRIVER_INIT(sc5);
+ INTERRUPT_GEN_MEMBER(sc5_fake_timer_int);
};
@@ -45,16 +46,16 @@ ADDRESS_MAP_END
static INPUT_PORTS_START( sc5 )
INPUT_PORTS_END
-static INTERRUPT_GEN( sc5_fake_timer_int )
+INTERRUPT_GEN_MEMBER(sc5_state::sc5_fake_timer_int)
{
// this should be coming from the Timer / SIM modules of the Coldfire
- device->machine().device("maincpu")->execute().set_input_line_and_vector(5, HOLD_LINE, 0x8c);
+ machine().device("maincpu")->execute().set_input_line_and_vector(5, HOLD_LINE, 0x8c);
}
static MACHINE_CONFIG_START( sc5, sc5_state )
MCFG_CPU_ADD("maincpu", MCF5206E, 40000000) /* MCF5206eFT */
MCFG_CPU_PROGRAM_MAP(sc5_map)
- MCFG_CPU_PERIODIC_INT(sc5_fake_timer_int,1000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(sc5_state, sc5_fake_timer_int, 1000)
MCFG_SPEAKER_STANDARD_STEREO("lspeaker", "rspeaker")
/* unknown sound */
diff --git a/src/mame/drivers/bfmsys85.c b/src/mame/drivers/bfmsys85.c
index d117e747d35..43b54368b2f 100644
--- a/src/mame/drivers/bfmsys85.c
+++ b/src/mame/drivers/bfmsys85.c
@@ -112,6 +112,7 @@ public:
DECLARE_DRIVER_INIT(decode);
virtual void machine_start();
virtual void machine_reset();
+ INTERRUPT_GEN_MEMBER(timer_irq);
};
@@ -185,13 +186,12 @@ WRITE8_MEMBER(bfmsys85_state::watchdog_w)
///////////////////////////////////////////////////////////////////////////
-static INTERRUPT_GEN( timer_irq )
+INTERRUPT_GEN_MEMBER(bfmsys85_state::timer_irq)
{
- bfmsys85_state *state = device->machine().driver_data<bfmsys85_state>();
- if ( state->m_is_timer_enabled )
+ if ( m_is_timer_enabled )
{
- state->m_irq_status = 0x01 |0x02; //0xff;
- generic_pulse_irq_line(device, M6809_IRQ_LINE, 1);
+ m_irq_status = 0x01 |0x02; //0xff;
+ generic_pulse_irq_line(device.execute(), M6809_IRQ_LINE, 1);
}
}
@@ -418,7 +418,7 @@ ADDRESS_MAP_END
static MACHINE_CONFIG_START( bfmsys85, bfmsys85_state )
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/4) // 6809 CPU at 1 Mhz
MCFG_CPU_PROGRAM_MAP(memmap) // setup read and write memorymap
- MCFG_CPU_PERIODIC_INT(timer_irq, 1000 ) // generate 1000 IRQ's per second
+ MCFG_CPU_PERIODIC_INT_DRIVER(bfmsys85_state, timer_irq, 1000) // generate 1000 IRQ's per second
MCFG_MSC1937_ADD("vfd",0,RIGHT_TO_LEFT)
MCFG_ACIA6850_ADD("acia6850_0", m6809_acia_if)
diff --git a/src/mame/drivers/bigevglf.c b/src/mame/drivers/bigevglf.c
index 3c297d1cb82..4936d6f3581 100644
--- a/src/mame/drivers/bigevglf.c
+++ b/src/mame/drivers/bigevglf.c
@@ -494,16 +494,16 @@ static MACHINE_CONFIG_START( bigevglf, bigevglf_state )
MCFG_CPU_ADD("maincpu", Z80,10000000/2) /* 5 MHz ? */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(bigevglf_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* vblank */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bigevglf_state, irq0_line_hold) /* vblank */
MCFG_CPU_ADD("sub", Z80,10000000/2) /* 5 MHz ? */
MCFG_CPU_PROGRAM_MAP(sub_map)
MCFG_CPU_IO_MAP(bigevglf_sub_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* vblank */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bigevglf_state, irq0_line_hold) /* vblank */
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* IRQ generated by ???;
+ MCFG_CPU_PERIODIC_INT_DRIVER(bigevglf_state, irq0_line_hold, 2*60) /* IRQ generated by ???;
2 irqs/frame give good music tempo but also SOUND ERROR in test mode,
4 irqs/frame give SOUND OK in test mode but music seems to be running too fast */
diff --git a/src/mame/drivers/bigstrkb.c b/src/mame/drivers/bigstrkb.c
index 6a222ca54e4..3f78f6885c4 100644
--- a/src/mame/drivers/bigstrkb.c
+++ b/src/mame/drivers/bigstrkb.c
@@ -198,7 +198,7 @@ static MACHINE_CONFIG_START( bigstrkb, bigstrkb_state )
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(bigstrkb_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bigstrkb_state, irq6_line_hold)
MCFG_GFXDECODE(bigstrkb)
diff --git a/src/mame/drivers/bingoc.c b/src/mame/drivers/bingoc.c
index 507af29d7a4..f9b93af719f 100644
--- a/src/mame/drivers/bingoc.c
+++ b/src/mame/drivers/bingoc.c
@@ -146,13 +146,13 @@ static MACHINE_CONFIG_START( bingoc, bingoc_state )
MCFG_CPU_ADD("maincpu", M68000,8000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bingoc_state, irq2_line_hold)
MCFG_CPU_ADD("soundcpu", Z80,4000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_io)
#if SOUND_TEST
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bingoc_state, nmi_line_pulse)
#endif
/* video hardware */
diff --git a/src/mame/drivers/bingor.c b/src/mame/drivers/bingor.c
index e7e3d3d873a..b85a019a923 100644
--- a/src/mame/drivers/bingor.c
+++ b/src/mame/drivers/bingor.c
@@ -455,6 +455,8 @@ public:
DECLARE_READ8_MEMBER(test8_r);
virtual void video_start();
UINT32 screen_update_bingor(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_irq);
+ INTERRUPT_GEN_MEMBER(unk_irq);
};
@@ -587,15 +589,15 @@ static INPUT_PORTS_START( bingor )
PORT_DIPSETTING( 0x0000, DEF_STR( On ) )
INPUT_PORTS_END
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(bingor_state::vblank_irq)
{
-// device->execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4); // reads i/o 0x200 and puts the result in ram, pic irq?
- device->execute().set_input_line_and_vector(0,HOLD_LINE,0x4c/4); // ?
+// device.execute().set_input_line_and_vector(0,HOLD_LINE,0x08/4); // reads i/o 0x200 and puts the result in ram, pic irq?
+ device.execute().set_input_line_and_vector(0,HOLD_LINE,0x4c/4); // ?
}
-static INTERRUPT_GEN( unk_irq )
+INTERRUPT_GEN_MEMBER(bingor_state::unk_irq)
{
- device->execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); // ?
+ device.execute().set_input_line_and_vector(0,HOLD_LINE,0x48/4); // ?
}
@@ -619,9 +621,9 @@ static MACHINE_CONFIG_START( bingor, bingor_state )
MCFG_CPU_ADD("maincpu", I80186, 14000000 ) //?? Mhz
MCFG_CPU_PROGRAM_MAP(bingor_map)
MCFG_CPU_IO_MAP(bingor_io)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 30)
- MCFG_CPU_PERIODIC_INT(unk_irq, 30)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bingor_state, vblank_irq)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bingor_state, nmi_line_pulse, 30)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bingor_state, unk_irq, 30)
MCFG_CPU_ADD("pic", PIC16C57, 12000000) //?? Mhz
MCFG_CPU_IO_MAP(pic_io_map)
diff --git a/src/mame/drivers/bionicc.c b/src/mame/drivers/bionicc.c
index 8985f7bad24..1891a77c455 100644
--- a/src/mame/drivers/bionicc.c
+++ b/src/mame/drivers/bionicc.c
@@ -362,7 +362,7 @@ static MACHINE_CONFIG_START( bionicc, bionicc_state )
* schematics indicate that nmi_line is set on M680000 access with AB1=1
* and IOCS=0 (active low), see pages A-1/10, A-4/10 in schematics
*/
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bionicc_state, nmi_line_pulse, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/bking.c b/src/mame/drivers/bking.c
index 3a7fc0da52a..8451097c728 100644
--- a/src/mame/drivers/bking.c
+++ b/src/mame/drivers/bking.c
@@ -468,7 +468,7 @@ static MACHINE_CONFIG_START( bking, bking_state )
MCFG_CPU_ADD("main_cpu", Z80, XTAL_12MHz/4) /* 3 MHz */
MCFG_CPU_PROGRAM_MAP(bking_map)
MCFG_CPU_IO_MAP(bking_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bking_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_6MHz/2) /* 3 MHz */
MCFG_CPU_PROGRAM_MAP(bking_audio_map)
@@ -476,7 +476,7 @@ static MACHINE_CONFIG_START( bking, bking_state )
/* - no interrupts synced with vblank */
/* - NMI triggered by the main CPU */
/* - periodic IRQ, with frequency 6000000/(4*16*16*10*16) = 36.621 Hz, */
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)6000000/(4*16*16*10*16))
+ MCFG_CPU_PERIODIC_INT_DRIVER(bking_state, irq0_line_hold, (double)6000000/(4*16*16*10*16))
/* video hardware */
diff --git a/src/mame/drivers/blackt96.c b/src/mame/drivers/blackt96.c
index 41c50a5281a..a0780275892 100644
--- a/src/mame/drivers/blackt96.c
+++ b/src/mame/drivers/blackt96.c
@@ -608,7 +608,7 @@ ADDRESS_MAP_END
static MACHINE_CONFIG_START( blackt96, blackt96_state )
MCFG_CPU_ADD("maincpu", M68000, 18000000 /2)
MCFG_CPU_PROGRAM_MAP(blackt96_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blackt96_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", PIC16C57, 8000000) /* ? */
MCFG_CPU_IO_MAP(sound_io_map)
diff --git a/src/mame/drivers/blitz.c b/src/mame/drivers/blitz.c
index a192c1a304e..869b26c9d65 100644
--- a/src/mame/drivers/blitz.c
+++ b/src/mame/drivers/blitz.c
@@ -794,7 +794,7 @@ static MACHINE_CONFIG_START( megadpkr, blitz_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(megadpkr_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz_state, nmi_line_pulse)
// MCFG_CPU_ADD("mcu", M68705, CPU_CLOCK) /* unknown */
// MCFG_CPU_PROGRAM_MAP(mcu_map)
diff --git a/src/mame/drivers/blitz68k.c b/src/mame/drivers/blitz68k.c
index 9137906a00d..090227222cf 100644
--- a/src/mame/drivers/blitz68k.c
+++ b/src/mame/drivers/blitz68k.c
@@ -1715,7 +1715,7 @@ static RAMDAC_INTERFACE( ramdac_intf )
static MACHINE_CONFIG_START( ilpag, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, 11059200 ) // ?
MCFG_CPU_PROGRAM_MAP(ilpag_map)
- MCFG_CPU_VBLANK_INT("screen",irq4_line_hold) //3 & 6 used, mcu comms?
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq4_line_hold) //3 & 6 used, mcu comms?
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
@@ -1779,7 +1779,7 @@ static TIMER_DEVICE_CALLBACK( steaser_mcu_sim )
static MACHINE_CONFIG_DERIVED( steaser, ilpag )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(steaser_map)
- MCFG_CPU_VBLANK_INT("screen",irq5_line_hold) //3, 4 & 6 used, mcu comms?
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq5_line_hold) //3, 4 & 6 used, mcu comms?
MCFG_TIMER_ADD_PERIODIC("coinsim", steaser_mcu_sim, attotime::from_hz(10000)) // not real, but for simulating the MCU
MACHINE_CONFIG_END
@@ -1815,7 +1815,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( bankrob, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz)
MCFG_CPU_PROGRAM_MAP(bankrob_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold) // protection prevents correct irq frequency by crtc
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold) // protection prevents correct irq frequency by crtc
// irq 2 reads from MCUs
// MC68HC705C8P (MCU1)
@@ -1847,7 +1847,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( bankroba, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz )
MCFG_CPU_PROGRAM_MAP(bankroba_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold) // protection prevents correct irq frequency by crtc
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq5_line_hold) // protection prevents correct irq frequency by crtc
// irq 3,4 read from MCUs
// MC68HC705C8P (MCU)
@@ -1906,7 +1906,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( dualgame, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz )
MCFG_CPU_PROGRAM_MAP(dualgame_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold) // lev 2 = MCUs, lev 3 = vblank
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq2_line_hold) // lev 2 = MCUs, lev 3 = vblank
// MC68HC705C8P (MCU1)
@@ -1937,7 +1937,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( hermit, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_22_1184MHz/2 )
MCFG_CPU_PROGRAM_MAP(hermit_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) // protection prevents correct irq frequency by crtc
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq1_line_hold) // protection prevents correct irq frequency by crtc
// MC68HC705C8P (MCU)
@@ -1966,7 +1966,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( maxidbl, blitz68k_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_11_0592MHz)
MCFG_CPU_PROGRAM_MAP(maxidbl_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold) // protection prevents correct irq frequency by crtc
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blitz68k_state, irq3_line_hold) // protection prevents correct irq frequency by crtc
// irq 2 reads from MCUs
// MC68HC705C8P (MCU1)
diff --git a/src/mame/drivers/blktiger.c b/src/mame/drivers/blktiger.c
index 29b464b094e..1cfe5e3bc47 100644
--- a/src/mame/drivers/blktiger.c
+++ b/src/mame/drivers/blktiger.c
@@ -317,7 +317,7 @@ static MACHINE_CONFIG_START( blktiger, blktiger_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_24MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(blktiger_map)
MCFG_CPU_IO_MAP(blktiger_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blktiger_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(blktiger_sound_map)
@@ -325,7 +325,7 @@ static MACHINE_CONFIG_START( blktiger, blktiger_state )
MCFG_CPU_ADD("mcu", I8751, XTAL_24MHz/4) /* ??? */
MCFG_CPU_PROGRAM_MAP(blktiger_mcu_map)
MCFG_CPU_IO_MAP(blktiger_mcu_io_map)
- //MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ //MCFG_CPU_VBLANK_INT_DRIVER("screen", blktiger_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/blmbycar.c b/src/mame/drivers/blmbycar.c
index a023fa62425..83026fb4edc 100644
--- a/src/mame/drivers/blmbycar.c
+++ b/src/mame/drivers/blmbycar.c
@@ -355,7 +355,7 @@ static MACHINE_CONFIG_START( blmbycar, blmbycar_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
MCFG_CPU_PROGRAM_MAP(blmbycar_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blmbycar_state, irq1_line_hold)
MCFG_MACHINE_START_OVERRIDE(blmbycar_state,blmbycar)
MCFG_MACHINE_RESET_OVERRIDE(blmbycar_state,blmbycar)
@@ -398,7 +398,7 @@ static MACHINE_CONFIG_START( watrball, blmbycar_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* ? */
MCFG_CPU_PROGRAM_MAP(watrball_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blmbycar_state, irq1_line_hold)
MCFG_MACHINE_START_OVERRIDE(blmbycar_state,watrball)
MCFG_MACHINE_RESET_OVERRIDE(blmbycar_state,watrball)
diff --git a/src/mame/drivers/blockade.c b/src/mame/drivers/blockade.c
index 3b57e2d82f7..eb999714e7c 100644
--- a/src/mame/drivers/blockade.c
+++ b/src/mame/drivers/blockade.c
@@ -58,15 +58,14 @@
/* Need to check for a coin on the interrupt, */
/* This will reset the cpu */
-static INTERRUPT_GEN( blockade_interrupt )
+INTERRUPT_GEN_MEMBER(blockade_state::blockade_interrupt)
{
- blockade_state *state = device->machine().driver_data<blockade_state>();
- device->execute().resume(SUSPEND_ANY_REASON);
+ device.execute().resume(SUSPEND_ANY_REASON);
- if ((state->ioport("IN0")->read() & 0x80) == 0)
+ if ((ioport("IN0")->read() & 0x80) == 0)
{
- state->m_just_been_reset = 1;
- device->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
+ m_just_been_reset = 1;
+ device.execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
}
}
@@ -472,7 +471,7 @@ static MACHINE_CONFIG_START( blockade, blockade_state )
MCFG_CPU_ADD("maincpu", I8080, MASTER_CLOCK/10)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_io_map)
- MCFG_CPU_VBLANK_INT("screen", blockade_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blockade_state, blockade_interrupt)
/* video hardware */
diff --git a/src/mame/drivers/blockhl.c b/src/mame/drivers/blockhl.c
index 0c4d22d38a9..9650937fc16 100644
--- a/src/mame/drivers/blockhl.c
+++ b/src/mame/drivers/blockhl.c
@@ -30,12 +30,11 @@
/* prototypes */
static KONAMI_SETLINES_CALLBACK( blockhl_banking );
-static INTERRUPT_GEN( blockhl_interrupt )
+INTERRUPT_GEN_MEMBER(blockhl_state::blockhl_interrupt)
{
- blockhl_state *state = device->machine().driver_data<blockhl_state>();
- if (k052109_is_irq_enabled(state->m_k052109) && state->m_rombank == 0) /* kludge to prevent crashes */
- device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
+ if (k052109_is_irq_enabled(m_k052109) && m_rombank == 0) /* kludge to prevent crashes */
+ device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
}
READ8_MEMBER(blockhl_state::bankedram_r)
@@ -215,7 +214,7 @@ static MACHINE_CONFIG_START( blockhl, blockhl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI,3000000) /* Konami custom 052526 */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", blockhl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blockhl_state, blockhl_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(audio_map)
diff --git a/src/mame/drivers/bloodbro.c b/src/mame/drivers/bloodbro.c
index 28c19c9eaaa..bce4b45d483 100644
--- a/src/mame/drivers/bloodbro.c
+++ b/src/mame/drivers/bloodbro.c
@@ -436,7 +436,7 @@ static MACHINE_CONFIG_START( bloodbro, bloodbro_state )
// basic machine hardware
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(bloodbro_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq4_line_hold)
SEIBU_SOUND_SYSTEM_CPU(XTAL_7_15909MHz/2) /* verified on pcb */
@@ -463,7 +463,7 @@ static MACHINE_CONFIG_DERIVED( weststry, bloodbro )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(weststry_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq6_line_hold)
MCFG_GFXDECODE(weststry)
MCFG_PALETTE_LENGTH(1024)
@@ -475,7 +475,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( skysmash, bloodbro )
MCFG_CPU_MODIFY("maincpu")
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bloodbro_state, irq2_line_hold)
MCFG_SCREEN_MODIFY("screen")
MCFG_SCREEN_UPDATE_DRIVER(bloodbro_state, screen_update_skysmash)
diff --git a/src/mame/drivers/blueprnt.c b/src/mame/drivers/blueprnt.c
index a7c6f52d3ed..a2a0511ec30 100644
--- a/src/mame/drivers/blueprnt.c
+++ b/src/mame/drivers/blueprnt.c
@@ -296,11 +296,11 @@ static MACHINE_CONFIG_START( blueprnt, blueprnt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 7000000/2) // 3.5 MHz
MCFG_CPU_PROGRAM_MAP(blueprnt_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", blueprnt_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 10000000/2/2/2) // 1.25 MHz (2H)
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60) // IRQs connected to 32V
+ MCFG_CPU_PERIODIC_INT_DRIVER(blueprnt_state, irq0_line_hold, 4*60) // IRQs connected to 32V
// NMIs are caused by the main CPU
diff --git a/src/mame/drivers/bmcbowl.c b/src/mame/drivers/bmcbowl.c
index 758578226d0..b2946a53c1a 100644
--- a/src/mame/drivers/bmcbowl.c
+++ b/src/mame/drivers/bmcbowl.c
@@ -503,7 +503,7 @@ void bmcbowl_state::machine_reset()
static MACHINE_CONFIG_START( bmcbowl, bmcbowl_state )
MCFG_CPU_ADD("maincpu", M68000, 21477270/2 )
MCFG_CPU_PROGRAM_MAP(bmcbowl_mem)
- MCFG_CPU_VBLANK_INT("screen",irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bmcbowl_state, irq2_line_hold)
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
diff --git a/src/mame/drivers/bmcpokr.c b/src/mame/drivers/bmcpokr.c
index e26c97f9592..937ea21c831 100644
--- a/src/mame/drivers/bmcpokr.c
+++ b/src/mame/drivers/bmcpokr.c
@@ -230,7 +230,7 @@ void bmcpokr_state::video_start()
static MACHINE_CONFIG_START( bmcpokr, bmcpokr_state )
MCFG_CPU_ADD("maincpu", M68000, XTAL_42MHz/4)
MCFG_CPU_PROGRAM_MAP(bmcpokr_mem)
- MCFG_CPU_VBLANK_INT("screen",irq3_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bmcpokr_state, irq3_line_hold)
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
diff --git a/src/mame/drivers/bogeyman.c b/src/mame/drivers/bogeyman.c
index cf6845fee83..26fdbecd1dd 100644
--- a/src/mame/drivers/bogeyman.c
+++ b/src/mame/drivers/bogeyman.c
@@ -241,7 +241,7 @@ static MACHINE_CONFIG_START( bogeyman, bogeyman_state )
// basic machine hardware
MCFG_CPU_ADD("maincpu", M6502, 1500000) /* Verified */
MCFG_CPU_PROGRAM_MAP(bogeyman_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 16*60) // Controls sound
+ MCFG_CPU_PERIODIC_INT_DRIVER(bogeyman_state, irq0_line_hold, 16*60) // Controls sound
// video hardware
diff --git a/src/mame/drivers/bombjack.c b/src/mame/drivers/bombjack.c
index 825326241a1..0641431bb11 100644
--- a/src/mame/drivers/bombjack.c
+++ b/src/mame/drivers/bombjack.c
@@ -347,12 +347,11 @@ void bombjack_state::machine_reset()
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(bombjack_state::vblank_irq)
{
- bombjack_state *state = device->machine().driver_data<bombjack_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( bombjack, bombjack_state )
@@ -360,12 +359,12 @@ static MACHINE_CONFIG_START( bombjack, bombjack_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_4MHz) /* Confirmed from PCB */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bombjack_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4) /* Confirmed from PCB */
MCFG_CPU_PROGRAM_MAP(audio_map)
MCFG_CPU_IO_MAP(audio_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bombjack_state, nmi_line_pulse)
/* video hardware */
diff --git a/src/mame/drivers/boogwing.c b/src/mame/drivers/boogwing.c
index 4252b88568e..e31cf8de4a9 100644
--- a/src/mame/drivers/boogwing.c
+++ b/src/mame/drivers/boogwing.c
@@ -343,7 +343,7 @@ static MACHINE_CONFIG_START( boogwing, boogwing_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 14000000) /* DE102 */
MCFG_CPU_PROGRAM_MAP(boogwing_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", boogwing_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", H6280,32220000/4)
MCFG_CPU_PROGRAM_MAP(audio_map)
diff --git a/src/mame/drivers/bottom9.c b/src/mame/drivers/bottom9.c
index 84940e06bcd..dca0a865aae 100644
--- a/src/mame/drivers/bottom9.c
+++ b/src/mame/drivers/bottom9.c
@@ -20,12 +20,11 @@
#include "includes/konamipt.h"
#include "includes/bottom9.h"
-static INTERRUPT_GEN( bottom9_interrupt )
+INTERRUPT_GEN_MEMBER(bottom9_state::bottom9_interrupt)
{
- bottom9_state *state = device->machine().driver_data<bottom9_state>();
- if (k052109_is_irq_enabled(state->m_k052109))
- device->execute().set_input_line(0, HOLD_LINE);
+ if (k052109_is_irq_enabled(m_k052109))
+ device.execute().set_input_line(0, HOLD_LINE);
}
READ8_MEMBER(bottom9_state::k052109_051960_r)
@@ -138,11 +137,10 @@ WRITE8_MEMBER(bottom9_state::bottom9_sh_irqtrigger_w)
m_audiocpu->set_input_line_and_vector(0, HOLD_LINE, 0xff);
}
-static INTERRUPT_GEN( bottom9_sound_interrupt )
+INTERRUPT_GEN_MEMBER(bottom9_state::bottom9_sound_interrupt)
{
- bottom9_state *state = device->machine().driver_data<bottom9_state>();
- if (state->m_nmienable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmienable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
WRITE8_MEMBER(bottom9_state::nmi_enable_w)
@@ -353,11 +351,11 @@ static MACHINE_CONFIG_START( bottom9, bottom9_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2000000) /* ? */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", bottom9_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bottom9_state, bottom9_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(audio_map)
- MCFG_CPU_PERIODIC_INT(bottom9_sound_interrupt,8*60) /* irq is triggered by the main CPU */
+ MCFG_CPU_PERIODIC_INT_DRIVER(bottom9_state, bottom9_sound_interrupt, 8*60) /* irq is triggered by the main CPU */
/* video hardware */
diff --git a/src/mame/drivers/brkthru.c b/src/mame/drivers/brkthru.c
index ba04cf61e2f..986d05e3f3b 100644
--- a/src/mame/drivers/brkthru.c
+++ b/src/mame/drivers/brkthru.c
@@ -381,12 +381,11 @@ void brkthru_state::machine_reset()
m_flipscreen = 0;
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(brkthru_state::vblank_irq)
{
- brkthru_state *state = device->machine().driver_data<brkthru_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( brkthru, brkthru_state )
@@ -394,7 +393,7 @@ static MACHINE_CONFIG_START( brkthru, brkthru_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/8) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(brkthru_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", brkthru_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", M6809, MASTER_CLOCK/8) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -430,7 +429,7 @@ static MACHINE_CONFIG_START( darwin, brkthru_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, MASTER_CLOCK/8) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(darwin_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", brkthru_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", M6809, MASTER_CLOCK/8) /* 1.5 MHz ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/btoads.c b/src/mame/drivers/btoads.c
index 4a8b8b5e3a9..9a7ded3f231 100644
--- a/src/mame/drivers/btoads.c
+++ b/src/mame/drivers/btoads.c
@@ -327,7 +327,7 @@ static MACHINE_CONFIG_START( btoads, btoads_state )
MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/4)
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_assert, 183)
+ MCFG_CPU_PERIODIC_INT_DRIVER(btoads_state, irq0_line_assert, 183)
MCFG_NVRAM_ADD_1FILL("nvram")
diff --git a/src/mame/drivers/bublbobl.c b/src/mame/drivers/bublbobl.c
index a8f057b0e57..dd5340ab224 100644
--- a/src/mame/drivers/bublbobl.c
+++ b/src/mame/drivers/bublbobl.c
@@ -764,11 +764,11 @@ static MACHINE_CONFIG_START( tokio, bublbobl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MAIN_XTAL/4) // 6 MHz
MCFG_CPU_PROGRAM_MAP(tokio_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
MCFG_CPU_ADD("slave", Z80, MAIN_XTAL/4) // 6 MHz
MCFG_CPU_PROGRAM_MAP(tokio_slave_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, MAIN_XTAL/8) // 3 MHz
MCFG_CPU_PROGRAM_MAP(tokio_sound_map) // NMIs are triggered by the main CPU, IRQs are triggered by the YM2203
@@ -845,14 +845,14 @@ static MACHINE_CONFIG_START( bublbobl, bublbobl_state )
MCFG_CPU_ADD("slave", Z80, MAIN_XTAL/4) // 6 MHz
MCFG_CPU_PROGRAM_MAP(slave_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, MAIN_XTAL/8) // 3 MHz
MCFG_CPU_PROGRAM_MAP(sound_map) // IRQs are triggered by the YM2203
MCFG_CPU_ADD("mcu", M6801, 4000000) // actually 6801U4 // xtal is 4MHz, divided by 4 internally
MCFG_CPU_PROGRAM_MAP(mcu_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_pulse) // comes from the same clock that latches the INT pin on the second Z80
+ 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
MCFG_QUANTUM_TIME(attotime::from_hz(6000)) // 100 CPU slices per frame - a high value to ensure proper synchronization of the CPUs
@@ -901,7 +901,7 @@ static MACHINE_CONFIG_DERIVED( boblbobl, bublbobl )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(bootleg_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) // interrupt mode 1, unlike Bubble Bobble
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", bublbobl_state, irq0_line_hold) // interrupt mode 1, unlike Bubble Bobble
MCFG_MACHINE_START_OVERRIDE(bublbobl_state,boblbobl)
MCFG_MACHINE_RESET_OVERRIDE(bublbobl_state,boblbobl)
@@ -945,7 +945,7 @@ static MACHINE_CONFIG_DERIVED( bub68705, bublbobl )
MCFG_CPU_ADD("mcu", M68705, 4000000) // xtal is 4MHz, divided by 4 internally
MCFG_CPU_PROGRAM_MAP(bootlegmcu_map)
- MCFG_CPU_VBLANK_INT("screen",bublbobl_m68705_interrupt) // ??? should come from the same clock which latches the INT pin on the second Z80
+ 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
MCFG_MACHINE_START_OVERRIDE(bublbobl_state,bub68705)
MCFG_MACHINE_RESET_OVERRIDE(bublbobl_state,bub68705)
diff --git a/src/mame/drivers/buggychl.c b/src/mame/drivers/buggychl.c
index 3c26841180a..55cf785705b 100644
--- a/src/mame/drivers/buggychl.c
+++ b/src/mame/drivers/buggychl.c
@@ -394,11 +394,11 @@ static MACHINE_CONFIG_START( buggychl, buggychl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 4000000) /* 4 MHz??? */
MCFG_CPU_PROGRAM_MAP(buggychl_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", buggychl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,60*60) /* irq is timed, tied to the cpu clock and not to vblank */
+ MCFG_CPU_PERIODIC_INT_DRIVER(buggychl_state, irq0_line_hold, 60*60) /* irq is timed, tied to the cpu clock and not to vblank */
/* nmi is caused by the main cpu */
MCFG_CPU_ADD("mcu", M68705,8000000/2) /* 4 MHz */
diff --git a/src/mame/drivers/buster.c b/src/mame/drivers/buster.c
index 842a4198796..d5177f7f607 100644
--- a/src/mame/drivers/buster.c
+++ b/src/mame/drivers/buster.c
@@ -333,7 +333,7 @@ static MACHINE_CONFIG_START( buster, buster_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,XTAL_3_579545MHz) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(mainmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", buster_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/bwidow.c b/src/mame/drivers/bwidow.c
index 8d4c12757f9..e6b552b34e7 100644
--- a/src/mame/drivers/bwidow.c
+++ b/src/mame/drivers/bwidow.c
@@ -696,7 +696,7 @@ static MACHINE_CONFIG_START( bwidow, bwidow_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK / 8)
MCFG_CPU_PROGRAM_MAP(bwidow_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bwidow_state, irq0_line_assert, (double)MASTER_CLOCK / 4096 / 12)
MCFG_ATARIVGEAROM_ADD("earom")
diff --git a/src/mame/drivers/bwing.c b/src/mame/drivers/bwing.c
index d83c61eca49..9efdc9a75ae 100644
--- a/src/mame/drivers/bwing.c
+++ b/src/mame/drivers/bwing.c
@@ -32,12 +32,11 @@ Known issues:
//****************************************************************************
// Interrupt Handlers
-static INTERRUPT_GEN ( bwp3_interrupt )
+INTERRUPT_GEN_MEMBER(bwing_state::bwp3_interrupt)
{
- bwing_state *state = device->machine().driver_data<bwing_state>();
- if (!state->m_bwp3_nmimask)
- device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
+ if (!m_bwp3_nmimask)
+ device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
}
//****************************************************************************
@@ -374,7 +373,7 @@ static MACHINE_CONFIG_START( bwing, bwing_state )
MCFG_CPU_ADD("audiocpu", DECO16, 2000000)
MCFG_CPU_PROGRAM_MAP(bwp3_map)
MCFG_CPU_IO_MAP(bwp3_io_map)
- MCFG_CPU_PERIODIC_INT(bwp3_interrupt, 1000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bwing_state, bwp3_interrupt, 1000)
MCFG_QUANTUM_TIME(attotime::from_hz(18000)) // high enough?
diff --git a/src/mame/drivers/bzone.c b/src/mame/drivers/bzone.c
index e3f01181a95..b16256cf7ac 100644
--- a/src/mame/drivers/bzone.c
+++ b/src/mame/drivers/bzone.c
@@ -244,10 +244,10 @@ MACHINE_START_MEMBER(bzone_state,redbaron)
*
*************************************/
-static INTERRUPT_GEN( bzone_interrupt )
+INTERRUPT_GEN_MEMBER(bzone_state::bzone_interrupt)
{
- if (device->machine().root_device().ioport("IN0")->read() & 0x10)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (machine().root_device().ioport("IN0")->read() & 0x10)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -553,7 +553,7 @@ static MACHINE_CONFIG_START( bzone_base, bzone_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, BZONE_MASTER_CLOCK / 8)
MCFG_CPU_PROGRAM_MAP(bzone_map)
- MCFG_CPU_PERIODIC_INT(bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bzone_state, bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
/* video hardware */
@@ -584,7 +584,7 @@ static MACHINE_CONFIG_DERIVED( redbaron, bzone_base )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(redbaron_map)
- MCFG_CPU_PERIODIC_INT(bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
+ MCFG_CPU_PERIODIC_INT_DRIVER(bzone_state, bzone_interrupt, (double)BZONE_MASTER_CLOCK / 4096 / 12)
MCFG_MACHINE_START_OVERRIDE(bzone_state,redbaron)
diff --git a/src/mame/drivers/cabal.c b/src/mame/drivers/cabal.c
index e22b9b80c16..fc1fd29bf22 100644
--- a/src/mame/drivers/cabal.c
+++ b/src/mame/drivers/cabal.c
@@ -492,7 +492,7 @@ static MACHINE_CONFIG_START( cabal, cabal_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cabal_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -534,7 +534,7 @@ static MACHINE_CONFIG_START( cabalbl, cabal_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cabalbl_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cabal_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cabalbl_sound_map)
@@ -543,12 +543,12 @@ static MACHINE_CONFIG_START( cabalbl, cabal_state )
MCFG_CPU_ADD("adpcm1", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cabalbl_talk1_map)
MCFG_CPU_IO_MAP(cabalbl_talk1_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cabal_state, irq0_line_hold, 8000)
MCFG_CPU_ADD("adpcm2", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cabalbl_talk2_map)
MCFG_CPU_IO_MAP(cabalbl_talk2_portmap)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,8000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cabal_state, irq0_line_hold, 8000)
MCFG_QUANTUM_TIME(attotime::from_hz(600))
diff --git a/src/mame/drivers/cabaret.c b/src/mame/drivers/cabaret.c
index 065027206a0..2455e8af8be 100644
--- a/src/mame/drivers/cabaret.c
+++ b/src/mame/drivers/cabaret.c
@@ -56,6 +56,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_cabaret(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(cabaret_interrupt);
};
@@ -324,11 +325,10 @@ void cabaret_state::machine_reset()
m_nmi_enable = 0;
}
-static INTERRUPT_GEN( cabaret_interrupt )
+INTERRUPT_GEN_MEMBER(cabaret_state::cabaret_interrupt)
{
- cabaret_state *state = device->machine().driver_data<cabaret_state>();
- if (state->m_nmi_enable & 0x80)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmi_enable & 0x80)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( cabaret, cabaret_state )
@@ -336,7 +336,7 @@ static MACHINE_CONFIG_START( cabaret, cabaret_state )
MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2)
MCFG_CPU_PROGRAM_MAP(cabaret_map)
MCFG_CPU_IO_MAP(cabaret_portmap)
- MCFG_CPU_VBLANK_INT("screen",cabaret_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cabaret_state, cabaret_interrupt)
/* video hardware */
diff --git a/src/mame/drivers/calomega.c b/src/mame/drivers/calomega.c
index 9dbd4b57dec..68e056fbb27 100644
--- a/src/mame/drivers/calomega.c
+++ b/src/mame/drivers/calomega.c
@@ -2736,7 +2736,7 @@ static MACHINE_CONFIG_START( sys903, calomega_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK) /* confirmed */
MCFG_CPU_PROGRAM_MAP(sys903_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", calomega_state, irq0_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/calorie.c b/src/mame/drivers/calorie.c
index 30d760608c0..3250b726791 100644
--- a/src/mame/drivers/calorie.c
+++ b/src/mame/drivers/calorie.c
@@ -442,12 +442,12 @@ static MACHINE_CONFIG_START( calorie, calorie_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,4000000) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(calorie_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", calorie_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,3000000) /* 3 MHz */
MCFG_CPU_PROGRAM_MAP(calorie_sound_map)
MCFG_CPU_IO_MAP(calorie_sound_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 64)
+ MCFG_CPU_PERIODIC_INT_DRIVER(calorie_state, irq0_line_hold, 64)
/* video hardware */
diff --git a/src/mame/drivers/canyon.c b/src/mame/drivers/canyon.c
index a026acac13f..9e5707a4b99 100644
--- a/src/mame/drivers/canyon.c
+++ b/src/mame/drivers/canyon.c
@@ -239,7 +239,7 @@ static MACHINE_CONFIG_START( canyon, canyon_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, XTAL_12_096MHz / 16)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", canyon_state, nmi_line_pulse)
MCFG_WATCHDOG_VBLANK_INIT(8)
/* video hardware */
diff --git a/src/mame/drivers/capbowl.c b/src/mame/drivers/capbowl.c
index 5e800efb2fc..310fb6c78ab 100644
--- a/src/mame/drivers/capbowl.c
+++ b/src/mame/drivers/capbowl.c
@@ -105,10 +105,10 @@
*
*************************************/
-static INTERRUPT_GEN( capbowl_interrupt )
+INTERRUPT_GEN_MEMBER(capbowl_state::capbowl_interrupt)
{
- if (device->machine().root_device().ioport("SERVICE")->read() & 1) /* get status of the F2 key */
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* trigger self test */
+ if (machine().root_device().ioport("SERVICE")->read() & 1) /* get status of the F2 key */
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* trigger self test */
}
@@ -361,7 +361,7 @@ static MACHINE_CONFIG_START( capbowl, capbowl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809E, MASTER_CLOCK)
MCFG_CPU_PROGRAM_MAP(capbowl_map)
- MCFG_CPU_VBLANK_INT("screen", capbowl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", capbowl_state, capbowl_interrupt)
MCFG_CPU_ADD("audiocpu", M6809E, MASTER_CLOCK)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/cardline.c b/src/mame/drivers/cardline.c
index 4c1da2ba71d..143d9075fe7 100644
--- a/src/mame/drivers/cardline.c
+++ b/src/mame/drivers/cardline.c
@@ -218,7 +218,7 @@ static MACHINE_CONFIG_START( cardline, cardline_state )
MCFG_CPU_ADD("maincpu", I80C32,12000000)
MCFG_CPU_PROGRAM_MAP(mem_prg)
MCFG_CPU_IO_MAP(mem_io)
- //MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ //MCFG_CPU_VBLANK_INT_DRIVER("screen", cardline_state, irq1_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/carjmbre.c b/src/mame/drivers/carjmbre.c
index 385127fa447..ef6a6c6cef7 100644
--- a/src/mame/drivers/carjmbre.c
+++ b/src/mame/drivers/carjmbre.c
@@ -190,12 +190,11 @@ void carjmbre_state::machine_reset()
m_bgcolor = 0;
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(carjmbre_state::vblank_irq)
{
- carjmbre_state *state = device->machine().driver_data<carjmbre_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( carjmbre, carjmbre_state )
@@ -203,13 +202,13 @@ static MACHINE_CONFIG_START( carjmbre, carjmbre_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(carjmbre_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", carjmbre_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6/2)
MCFG_CPU_PROGRAM_MAP(carjmbre_sound_map)
MCFG_CPU_IO_MAP(carjmbre_sound_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", carjmbre_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/carpolo.c b/src/mame/drivers/carpolo.c
index ffe1421eba7..92d6a0bd04c 100644
--- a/src/mame/drivers/carpolo.c
+++ b/src/mame/drivers/carpolo.c
@@ -244,7 +244,7 @@ static MACHINE_CONFIG_START( carpolo, carpolo_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, XTAL_11_289MHz/12) /* 940.75 kHz */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", carpolo_timer_interrupt) /* this not strictly VBLANK,
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", carpolo_state, carpolo_timer_interrupt) /* this not strictly VBLANK,
but it's supposed to happen 60
times a sec, so it's a good place */
diff --git a/src/mame/drivers/carrera.c b/src/mame/drivers/carrera.c
index 7da2d28f529..0f0d6c435d1 100644
--- a/src/mame/drivers/carrera.c
+++ b/src/mame/drivers/carrera.c
@@ -330,7 +330,7 @@ static MACHINE_CONFIG_START( carrera, carrera_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK / 6)
MCFG_CPU_PROGRAM_MAP(carrera_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", carrera_state, nmi_line_pulse)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/caswin.c b/src/mame/drivers/caswin.c
index dd28e3ff9ca..7848a7e970e 100644
--- a/src/mame/drivers/caswin.c
+++ b/src/mame/drivers/caswin.c
@@ -305,7 +305,7 @@ static MACHINE_CONFIG_START( vvillage, caswin_state )
MCFG_CPU_ADD("maincpu", Z80,4000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(vvillage_mem)
MCFG_CPU_IO_MAP(vvillage_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold )
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", caswin_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/cave.c b/src/mame/drivers/cave.c
index d6594783e29..d10bf873255 100644
--- a/src/mame/drivers/cave.c
+++ b/src/mame/drivers/cave.c
@@ -135,10 +135,9 @@ static TIMER_DEVICE_CALLBACK( cave_vblank_start )
}
/* Called once/frame to generate the VBLANK interrupt */
-static INTERRUPT_GEN( cave_interrupt )
+INTERRUPT_GEN_MEMBER(cave_state::cave_interrupt)
{
- cave_state *state = device->machine().driver_data<cave_state>();
- state->m_int_timer->adjust(attotime::from_usec(17376 - state->m_time_vblank_irq));
+ m_int_timer->adjust(attotime::from_usec(17376 - m_time_vblank_irq));
}
/* Called by the YMZ280B to set the IRQ state */
@@ -1854,7 +1853,7 @@ static MACHINE_CONFIG_START( dfeveron, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(dfeveron_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -1896,7 +1895,7 @@ static MACHINE_CONFIG_START( ddonpach, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(ddonpach_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -1942,7 +1941,7 @@ static MACHINE_CONFIG_START( donpachi, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(donpachi_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -1988,7 +1987,7 @@ static MACHINE_CONFIG_START( esprade, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(esprade_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -2029,7 +2028,7 @@ static MACHINE_CONFIG_START( gaia, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(gaia_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -2069,7 +2068,7 @@ static MACHINE_CONFIG_START( guwange, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(guwange_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -2109,7 +2108,7 @@ static MACHINE_CONFIG_START( hotdogst, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(hotdogst_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz)
MCFG_CPU_PROGRAM_MAP(hotdogst_sound_map)
@@ -2165,7 +2164,7 @@ static MACHINE_CONFIG_START( korokoro, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(korokoro_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_MACHINE_RESET_OVERRIDE(cave_state,cave)
@@ -2213,7 +2212,7 @@ static MACHINE_CONFIG_START( mazinger, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(mazinger_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz) // Bidirectional communication
MCFG_CPU_PROGRAM_MAP(mazinger_sound_map)
@@ -2271,7 +2270,7 @@ static MACHINE_CONFIG_START( metmqstr, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_32MHz / 2)
MCFG_CPU_PROGRAM_MAP(metmqstr_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_32MHz / 4)
MCFG_CPU_PROGRAM_MAP(metmqstr_sound_map)
@@ -2330,7 +2329,7 @@ static MACHINE_CONFIG_START( pacslot, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz / 2)
MCFG_CPU_PROGRAM_MAP(pacslot_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(3)) /* a guess, and certainly wrong */
@@ -2384,7 +2383,7 @@ static MACHINE_CONFIG_START( pwrinst2, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz) /* 16 MHz */
MCFG_CPU_PROGRAM_MAP(pwrinst2_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_16MHz / 2) /* 8 MHz */
MCFG_CPU_PROGRAM_MAP(pwrinst2_sound_map)
@@ -2445,7 +2444,7 @@ static MACHINE_CONFIG_START( sailormn, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(sailormn_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz) // Bidirectional Communication
MCFG_CPU_PROGRAM_MAP(sailormn_sound_map)
@@ -2503,7 +2502,7 @@ static MACHINE_CONFIG_START( tjumpman, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz / 2)
MCFG_CPU_PROGRAM_MAP(tjumpman_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(3)) /* a guess, and certainly wrong */
@@ -2547,7 +2546,7 @@ static MACHINE_CONFIG_START( uopoko, cave_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_16MHz)
MCFG_CPU_PROGRAM_MAP(uopoko_map)
- MCFG_CPU_VBLANK_INT("screen", cave_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cave_state, cave_interrupt)
MCFG_MACHINE_START_OVERRIDE(cave_state,cave)
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/cb2001.c b/src/mame/drivers/cb2001.c
index f8857b1f75f..0d3ebd532ae 100644
--- a/src/mame/drivers/cb2001.c
+++ b/src/mame/drivers/cb2001.c
@@ -72,6 +72,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_cb2001(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_irq);
};
@@ -737,9 +738,9 @@ static INPUT_PORTS_START( cb2001 )
INPUT_PORTS_END
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(cb2001_state::vblank_irq)
{
- generic_pulse_irq_line(device, NEC_INPUT_LINE_INTP0, 1);
+ generic_pulse_irq_line(device.execute(), NEC_INPUT_LINE_INTP0, 1);
}
static const gfx_layout cb2001_layout =
@@ -836,7 +837,7 @@ static MACHINE_CONFIG_START( cb2001, cb2001_state )
MCFG_CPU_CONFIG(cb2001_config)
MCFG_CPU_PROGRAM_MAP(cb2001_map)
MCFG_CPU_IO_MAP(cb2001_io)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cb2001_state, vblank_irq)
MCFG_I8255A_ADD( "ppi8255_0", ppi8255_0_intf )
MCFG_I8255A_ADD( "ppi8255_1", ppi8255_1_intf )
diff --git a/src/mame/drivers/cbasebal.c b/src/mame/drivers/cbasebal.c
index bd05b4a4f2d..b31fe854717 100644
--- a/src/mame/drivers/cbasebal.c
+++ b/src/mame/drivers/cbasebal.c
@@ -277,7 +277,7 @@ static MACHINE_CONFIG_START( cbasebal, cbasebal_state )
MCFG_CPU_ADD("maincpu", Z80, 6000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(cbasebal_map)
MCFG_CPU_IO_MAP(cbasebal_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* ??? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cbasebal_state, irq0_line_hold) /* ??? */
MCFG_EEPROM_ADD("eeprom", cbasebal_eeprom_intf)
diff --git a/src/mame/drivers/cbuster.c b/src/mame/drivers/cbuster.c
index 668a2c47985..18c3dc71ec0 100644
--- a/src/mame/drivers/cbuster.c
+++ b/src/mame/drivers/cbuster.c
@@ -326,7 +326,7 @@ static MACHINE_CONFIG_START( twocrude, cbuster_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000) /* Custom chip 59 */
MCFG_CPU_PROGRAM_MAP(twocrude_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cbuster_state, irq4_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", H6280,32220000/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/cchance.c b/src/mame/drivers/cchance.c
index 76fecf8774e..dce58768901 100644
--- a/src/mame/drivers/cchance.c
+++ b/src/mame/drivers/cchance.c
@@ -221,7 +221,7 @@ static MACHINE_CONFIG_START( cchance, cchance_state )
MCFG_CPU_ADD("maincpu", Z80,4000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cchance_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(cchance_state,cchance)
MCFG_MACHINE_RESET_OVERRIDE(cchance_state,cchance)
diff --git a/src/mame/drivers/cclimber.c b/src/mame/drivers/cclimber.c
index 9e089fc2c6e..75ce44ece48 100644
--- a/src/mame/drivers/cclimber.c
+++ b/src/mame/drivers/cclimber.c
@@ -973,12 +973,11 @@ static GFXDECODE_START( toprollr )
GFXDECODE_ENTRY( "gfx3", 0x0000, cclimber_charlayout, 24*4, 16 )
GFXDECODE_END
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(cclimber_state::vblank_irq)
{
- cclimber_state *state = device->machine().driver_data<cclimber_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( root, cclimber_state )
@@ -987,7 +986,7 @@ static MACHINE_CONFIG_START( root, cclimber_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/3/2) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(cclimber_map)
MCFG_CPU_IO_MAP(cclimber_portmap)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cclimber_state, vblank_irq)
MCFG_MACHINE_RESET_OVERRIDE(cclimber_state,cclimber)
@@ -1082,12 +1081,12 @@ static MACHINE_CONFIG_START( swimmer, cclimber_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(swimmer_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cclimber_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_4MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(swimmer_audio_map)
MCFG_CPU_IO_MAP(swimmer_audio_portmap)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, (double)4000000/16384) /* IRQs are triggered by the main CPU */
+ MCFG_CPU_PERIODIC_INT_DRIVER(cclimber_state, nmi_line_pulse, (double)4000000/16384) /* IRQs are triggered by the main CPU */
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/cesclass.c b/src/mame/drivers/cesclass.c
index d0b94be5d0e..f4f6f79310e 100644
--- a/src/mame/drivers/cesclass.c
+++ b/src/mame/drivers/cesclass.c
@@ -245,8 +245,8 @@ static MACHINE_CONFIG_START( cesclassic, cesclassic_state )
MCFG_CPU_ADD("maincpu", M68000, 24000000/2 )
MCFG_CPU_PROGRAM_MAP(cesclassic_map)
- MCFG_CPU_VBLANK_INT("l_lcd", irq2_line_assert) // TODO: unknown sources
- MCFG_CPU_PERIODIC_INT(irq3_line_assert,60*8)
+ MCFG_CPU_VBLANK_INT_DRIVER("l_lcd", cesclassic_state, irq2_line_assert) // TODO: unknown sources
+ MCFG_CPU_PERIODIC_INT_DRIVER(cesclassic_state, irq3_line_assert, 60*8)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/chaknpop.c b/src/mame/drivers/chaknpop.c
index e789d71184b..7e99be833b9 100644
--- a/src/mame/drivers/chaknpop.c
+++ b/src/mame/drivers/chaknpop.c
@@ -375,7 +375,7 @@ static MACHINE_CONFIG_START( chaknpop, chaknpop_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz / 6) /* Verified on PCB */
MCFG_CPU_PROGRAM_MAP(chaknpop_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", chaknpop_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/champbas.c b/src/mame/drivers/champbas.c
index 8d02c617333..977198d22e6 100644
--- a/src/mame/drivers/champbas.c
+++ b/src/mame/drivers/champbas.c
@@ -604,12 +604,11 @@ MACHINE_RESET_MEMBER(champbas_state,champbas)
m_gfx_bank = 0; // talbot has only 1 bank
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(champbas_state::vblank_irq)
{
- champbas_state *state = device->machine().driver_data<champbas_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if(m_irq_mask)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
@@ -618,7 +617,7 @@ static MACHINE_CONFIG_START( talbot, champbas_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(talbot_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
/* MCU */
MCFG_CPU_ADD(CPUTAG_MCU, ALPHA8201, XTAL_18_432MHz/6/8)
@@ -654,7 +653,7 @@ static MACHINE_CONFIG_START( champbas, champbas_state )
/* main cpu */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(champbas_main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
MCFG_CPU_ADD("sub", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(champbas_sub_map)
@@ -705,12 +704,12 @@ static MACHINE_CONFIG_START( exctsccr, champbas_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6 )
MCFG_CPU_PROGRAM_MAP(exctsccr_main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz/4 )
MCFG_CPU_PROGRAM_MAP(exctsccr_sub_map)
MCFG_CPU_IO_MAP(exctsccr_sound_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 4000) /* 4 kHz, updates the dac */
+ MCFG_CPU_PERIODIC_INT_DRIVER(champbas_state, nmi_line_pulse, 4000) /* 4 kHz, updates the dac */
/* MCU */
MCFG_CPU_ADD(CPUTAG_MCU, ALPHA8301, XTAL_18_432MHz/6/8) /* Actually 8302 */
@@ -762,7 +761,7 @@ static MACHINE_CONFIG_START( exctsccrb, champbas_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(exctsccrb_main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbas_state, vblank_irq)
MCFG_CPU_ADD("sub", Z80, XTAL_18_432MHz/6)
MCFG_CPU_PROGRAM_MAP(champbas_sub_map)
diff --git a/src/mame/drivers/champbwl.c b/src/mame/drivers/champbwl.c
index 9e9486069ec..9e67909f442 100644
--- a/src/mame/drivers/champbwl.c
+++ b/src/mame/drivers/champbwl.c
@@ -480,7 +480,7 @@ static MACHINE_CONFIG_START( champbwl, champbwl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 16000000/4) /* 4MHz */
MCFG_CPU_PROGRAM_MAP(champbwl_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbwl_state, irq0_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
@@ -544,7 +544,7 @@ static MACHINE_CONFIG_START( doraemon, champbwl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_14_31818MHz/4)
MCFG_CPU_PROGRAM_MAP(doraemon)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", champbwl_state, irq0_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
MCFG_DEVICE_ADD("spritegen", SETA001_SPRITE, 0)
diff --git a/src/mame/drivers/chance32.c b/src/mame/drivers/chance32.c
index 3d3ff5f86ff..0a2f6127adc 100644
--- a/src/mame/drivers/chance32.c
+++ b/src/mame/drivers/chance32.c
@@ -471,7 +471,7 @@ static MACHINE_CONFIG_START( chance32, chance32_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/2)
MCFG_CPU_PROGRAM_MAP(chance32_map)
MCFG_CPU_IO_MAP(chance32_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", chance32_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/changela.c b/src/mame/drivers/changela.c
index 8b1272a14e9..07256919471 100644
--- a/src/mame/drivers/changela.c
+++ b/src/mame/drivers/changela.c
@@ -412,11 +412,10 @@ TIMER_DEVICE_CALLBACK( changela_scanline )
timer.machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE,0xcf);
}
-static INTERRUPT_GEN( chl_mcu_irq )
+INTERRUPT_GEN_MEMBER(changela_state::chl_mcu_irq)
{
- changela_state *state = device->machine().driver_data<changela_state>();
- generic_pulse_irq_line(state->m_mcu, 0, 1);
+ generic_pulse_irq_line(m_mcu->execute(), 0, 1);
}
void changela_state::machine_start()
@@ -508,7 +507,7 @@ static MACHINE_CONFIG_START( changela, changela_state )
MCFG_CPU_ADD("mcu", M68705,2500000)
MCFG_CPU_PROGRAM_MAP(mcu_map)
- MCFG_CPU_VBLANK_INT("screen",chl_mcu_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", changela_state, chl_mcu_irq)
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/cheekyms.c b/src/mame/drivers/cheekyms.c
index 978869a62a0..388adbdd3d6 100644
--- a/src/mame/drivers/cheekyms.c
+++ b/src/mame/drivers/cheekyms.c
@@ -115,12 +115,11 @@ void cheekyms_state::machine_start()
m_dac = machine().device<dac_device>("dac");
}
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(cheekyms_state::vblank_irq)
{
- cheekyms_state *state = device->machine().driver_data<cheekyms_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, HOLD_LINE);
+ if(m_irq_mask)
+ device.execute().set_input_line(0, HOLD_LINE);
}
@@ -130,7 +129,7 @@ static MACHINE_CONFIG_START( cheekyms, cheekyms_state )
MCFG_CPU_ADD("maincpu", Z80,5000000/2) /* 2.5 MHz */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cheekyms_state, vblank_irq)
/* video hardware */
diff --git a/src/mame/drivers/chinsan.c b/src/mame/drivers/chinsan.c
index 10890cd0ddf..14b851667cf 100644
--- a/src/mame/drivers/chinsan.c
+++ b/src/mame/drivers/chinsan.c
@@ -605,7 +605,7 @@ static MACHINE_CONFIG_START( chinsan, chinsan_state )
MCFG_CPU_ADD("maincpu", Z80,10000000/2) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(chinsan_map)
MCFG_CPU_IO_MAP(chinsan_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", chinsan_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/chsuper.c b/src/mame/drivers/chsuper.c
index 6f97c8c6eec..6e75ea0e22e 100644
--- a/src/mame/drivers/chsuper.c
+++ b/src/mame/drivers/chsuper.c
@@ -203,7 +203,7 @@ static MACHINE_CONFIG_START( chsuper, chsuper_state )
MCFG_CPU_ADD("maincpu", Z180, XTAL_12MHz / 2) /* HD64180RP8, 8 MHz? */
MCFG_CPU_PROGRAM_MAP(chsuper_prg_map)
MCFG_CPU_IO_MAP(chsuper_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", chsuper_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/circusc.c b/src/mame/drivers/circusc.c
index fb3bcc6b2a6..f90d0bc4a46 100644
--- a/src/mame/drivers/circusc.c
+++ b/src/mame/drivers/circusc.c
@@ -345,12 +345,11 @@ static DISCRETE_SOUND_START( circusc )
DISCRETE_SOUND_END
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(circusc_state::vblank_irq)
{
- circusc_state *state = device->machine().driver_data<circusc_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, HOLD_LINE);
+ if(m_irq_mask)
+ device.execute().set_input_line(0, HOLD_LINE);
}
static MACHINE_CONFIG_START( circusc, circusc_state )
@@ -358,7 +357,7 @@ static MACHINE_CONFIG_START( circusc, circusc_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2048000) /* 2 MHz? */
MCFG_CPU_PROGRAM_MAP(circusc_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", circusc_state, vblank_irq)
MCFG_WATCHDOG_VBLANK_INIT(8)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_14_31818MHz/4)
diff --git a/src/mame/drivers/cischeat.c b/src/mame/drivers/cischeat.c
index a292d13667c..5f9239f40eb 100644
--- a/src/mame/drivers/cischeat.c
+++ b/src/mame/drivers/cischeat.c
@@ -1564,15 +1564,15 @@ static MACHINE_CONFIG_START( bigrun, cischeat_state )
MCFG_CPU_ADD("cpu2", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(bigrun_map2)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cischeat_state, irq4_line_hold)
MCFG_CPU_ADD("cpu3", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(bigrun_map3)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cischeat_state, irq4_line_hold)
MCFG_CPU_ADD("soundcpu", M68000, 6000000)
MCFG_CPU_PROGRAM_MAP(bigrun_sound_map)
- MCFG_CPU_PERIODIC_INT(irq4_line_hold,16*30)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cischeat_state, irq4_line_hold, 16*30)
MCFG_QUANTUM_TIME(attotime::from_hz(1200))
diff --git a/src/mame/drivers/citycon.c b/src/mame/drivers/citycon.c
index 3a60804238d..3f9b39a85d6 100644
--- a/src/mame/drivers/citycon.c
+++ b/src/mame/drivers/citycon.c
@@ -206,11 +206,11 @@ static MACHINE_CONFIG_START( citycon, citycon_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2048000) /* 2.048 MHz ??? */
MCFG_CPU_PROGRAM_MAP(citycon_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", citycon_state, irq0_line_assert)
MCFG_CPU_ADD("audiocpu", M6809, 640000) /* 0.640 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
-// MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) //actually unused, probably it was during development
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", citycon_state, irq0_line_hold) //actually unused, probably it was during development
/* video hardware */
diff --git a/src/mame/drivers/clayshoo.c b/src/mame/drivers/clayshoo.c
index f8b4145b2a3..3cfadf46646 100644
--- a/src/mame/drivers/clayshoo.c
+++ b/src/mame/drivers/clayshoo.c
@@ -331,7 +331,7 @@ static MACHINE_CONFIG_START( clayshoo, clayshoo_state )
MCFG_CPU_ADD("maincpu", Z80,5068000/4) /* 5.068/4 Mhz (divider is a guess) */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", clayshoo_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/cloak.c b/src/mame/drivers/cloak.c
index e10fde1444f..c4ad239b5fe 100644
--- a/src/mame/drivers/cloak.c
+++ b/src/mame/drivers/cloak.c
@@ -333,11 +333,11 @@ static MACHINE_CONFIG_START( cloak, cloak_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, 1000000) /* 1 MHz ???? */
MCFG_CPU_PROGRAM_MAP(master_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cloak_state, irq0_line_hold, 4*60)
MCFG_CPU_ADD("slave", M6502, 1250000) /* 1.25 MHz ???? */
MCFG_CPU_PROGRAM_MAP(slave_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 2*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cloak_state, irq0_line_hold, 2*60)
MCFG_QUANTUM_TIME(attotime::from_hz(1000))
diff --git a/src/mame/drivers/clshroad.c b/src/mame/drivers/clshroad.c
index 27c05b6ed1d..00298804197 100644
--- a/src/mame/drivers/clshroad.c
+++ b/src/mame/drivers/clshroad.c
@@ -231,11 +231,11 @@ static MACHINE_CONFIG_START( firebatl, clshroad_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 3000000) /* ? */
MCFG_CPU_PROGRAM_MAP(clshroad_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* IRQ, no NMI */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold) /* IRQ, no NMI */
MCFG_CPU_ADD("audiocpu", Z80, 3000000) /* ? */
MCFG_CPU_PROGRAM_MAP(clshroad_sound_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* IRQ, no NMI */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold) /* IRQ, no NMI */
/* video hardware */
@@ -264,11 +264,11 @@ static MACHINE_CONFIG_START( clshroad, clshroad_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/4) /* ? real speed unknown. 3MHz is too low and causes problems */
MCFG_CPU_PROGRAM_MAP(clshroad_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* IRQ, no NMI */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold) /* IRQ, no NMI */
MCFG_CPU_ADD("audiocpu", Z80, XTAL_18_432MHz/6) /* ? */
MCFG_CPU_PROGRAM_MAP(clshroad_sound_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* IRQ, no NMI */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", clshroad_state, irq0_line_hold) /* IRQ, no NMI */
/* video hardware */
diff --git a/src/mame/drivers/cmmb.c b/src/mame/drivers/cmmb.c
index 43a014242b9..fdd13760d8a 100644
--- a/src/mame/drivers/cmmb.c
+++ b/src/mame/drivers/cmmb.c
@@ -67,6 +67,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_cmmb(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(cmmb_irq);
};
@@ -301,11 +302,11 @@ static GFXDECODE_START( cmmb )
GFXDECODE_ENTRY( "gfx", 0, spritelayout, 0x10, 4 )
GFXDECODE_END
-static INTERRUPT_GEN( cmmb_irq )
+INTERRUPT_GEN_MEMBER(cmmb_state::cmmb_irq)
{
- //if(device->machine().input().code_pressed_once(KEYCODE_Z))
- //if(device->machine().input().code_pressed(KEYCODE_Z))
-// device->execute().set_input_line(0, HOLD_LINE);
+ //if(machine().input().code_pressed_once(KEYCODE_Z))
+ //if(machine().input().code_pressed(KEYCODE_Z))
+// device.execute().set_input_line(0, HOLD_LINE);
}
void cmmb_state::machine_reset()
@@ -317,7 +318,7 @@ static MACHINE_CONFIG_START( cmmb, cmmb_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M65SC02, XTAL_72_576MHz/5) // Unknown clock, but chip rated for 14MHz
MCFG_CPU_PROGRAM_MAP(cmmb_map)
- MCFG_CPU_VBLANK_INT("screen",cmmb_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cmmb_state, cmmb_irq)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/cninja.c b/src/mame/drivers/cninja.c
index 0190aa2a8a8..d96313a04dc 100644
--- a/src/mame/drivers/cninja.c
+++ b/src/mame/drivers/cninja.c
@@ -906,7 +906,7 @@ static MACHINE_CONFIG_START( cninja, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(cninja_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", H6280,32220000/8) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -958,7 +958,7 @@ static MACHINE_CONFIG_START( stoneage, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(cninja_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(stoneage_s_map)
@@ -1010,7 +1010,7 @@ static MACHINE_CONFIG_START( cninjabl, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(cninjabl_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(stoneage_s_map)
@@ -1053,7 +1053,7 @@ static MACHINE_CONFIG_START( edrandy, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(edrandy_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", H6280,32220000/8) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1105,7 +1105,7 @@ static MACHINE_CONFIG_START( robocop2, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 14000000)
MCFG_CPU_PROGRAM_MAP(robocop2_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", H6280,32220000/8) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1160,7 +1160,7 @@ static MACHINE_CONFIG_START( mutantf, cninja_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 14000000)
MCFG_CPU_PROGRAM_MAP(mutantf_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cninja_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", H6280,32220000/8)
MCFG_CPU_PROGRAM_MAP(sound_map_mutantf)
diff --git a/src/mame/drivers/cntsteer.c b/src/mame/drivers/cntsteer.c
index a11a9cf536c..c3d5cf71728 100644
--- a/src/mame/drivers/cntsteer.c
+++ b/src/mame/drivers/cntsteer.c
@@ -92,6 +92,7 @@ public:
DECLARE_PALETTE_INIT(zerotrgt);
UINT32 screen_update_cntsteer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
UINT32 screen_update_zerotrgt(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(sound_interrupt);
};
@@ -595,11 +596,10 @@ WRITE8_MEMBER(cntsteer_state::nmimask_w)
m_nmimask = data & 0x80;
}
-static INTERRUPT_GEN ( sound_interrupt )
+INTERRUPT_GEN_MEMBER(cntsteer_state::sound_interrupt)
{
- cntsteer_state *state = device->machine().driver_data<cntsteer_state>();
- if (!state->m_nmimask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (!m_nmimask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static ADDRESS_MAP_START( sound_map, AS_PROGRAM, 8, cntsteer_state )
@@ -883,15 +883,15 @@ static MACHINE_CONFIG_START( cntsteer, cntsteer_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2000000) /* ? */
MCFG_CPU_PROGRAM_MAP(cntsteer_cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
MCFG_CPU_ADD("subcpu", M6809, 2000000) /* ? */
MCFG_CPU_PROGRAM_MAP(cntsteer_cpu2_map)
-// MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
MCFG_CPU_ADD("audiocpu", M6502, 1500000) /* ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(sound_interrupt, 480)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cntsteer_state, sound_interrupt, 480)
MCFG_MACHINE_START_OVERRIDE(cntsteer_state,cntsteer)
MCFG_MACHINE_RESET_OVERRIDE(cntsteer_state,cntsteer)
@@ -930,15 +930,15 @@ static MACHINE_CONFIG_START( zerotrgt, cntsteer_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2000000) /* ? */
MCFG_CPU_PROGRAM_MAP(gekitsui_cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
MCFG_CPU_ADD("subcpu", M6809, 2000000) /* ? */
MCFG_CPU_PROGRAM_MAP(gekitsui_cpu2_map)
-// MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse) /* ? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cntsteer_state, nmi_line_pulse) /* ? */
MCFG_CPU_ADD("audiocpu", M6502, 1500000) /* ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(sound_interrupt, 480)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cntsteer_state, sound_interrupt, 480)
MCFG_QUANTUM_TIME(attotime::from_hz(6000))
diff --git a/src/mame/drivers/cobra.c b/src/mame/drivers/cobra.c
index 8a1c74a7673..d9502c02a6f 100644
--- a/src/mame/drivers/cobra.c
+++ b/src/mame/drivers/cobra.c
@@ -721,6 +721,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_cobra(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(cobra_vblank);
};
void cobra_renderer::render_color_scan(INT32 scanline, const extent_t &extent, const cobra_polydata &extradata, int threadid)
@@ -3187,14 +3188,13 @@ static void ide_interrupt(device_t *device, int state)
}
-static INTERRUPT_GEN( cobra_vblank )
+INTERRUPT_GEN_MEMBER(cobra_state::cobra_vblank)
{
- cobra_state *cobra = device->machine().driver_data<cobra_state>();
- if (cobra->m_vblank_enable & 0x80)
+ if (m_vblank_enable & 0x80)
{
- device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
- cobra->m_gfx_unk_flag = 0x80;
+ device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
+ m_gfx_unk_flag = 0x80;
}
}
@@ -3236,7 +3236,7 @@ static MACHINE_CONFIG_START( cobra, cobra_state )
MCFG_CPU_ADD("maincpu", PPC603, 100000000) /* 603EV, 100? MHz */
MCFG_CPU_CONFIG(main_ppc_cfg)
MCFG_CPU_PROGRAM_MAP(cobra_main_map)
- MCFG_CPU_VBLANK_INT("screen", cobra_vblank)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cobra_state, cobra_vblank)
MCFG_CPU_ADD("subcpu", PPC403GA, 32000000) /* 403GA, 33? MHz */
MCFG_CPU_PROGRAM_MAP(cobra_sub_map)
diff --git a/src/mame/drivers/coinmstr.c b/src/mame/drivers/coinmstr.c
index 037676af032..b25b9f66bb2 100644
--- a/src/mame/drivers/coinmstr.c
+++ b/src/mame/drivers/coinmstr.c
@@ -1010,7 +1010,7 @@ static const mc6845_interface h46505_intf =
static MACHINE_CONFIG_START( coinmstr, coinmstr_state )
MCFG_CPU_ADD("maincpu",Z80,8000000) // ?
MCFG_CPU_PROGRAM_MAP(coinmstr_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", coinmstr_state, irq0_line_hold)
MCFG_PIA6821_ADD("pia0", pia_0_intf)
MCFG_PIA6821_ADD("pia1", pia_1_intf)
diff --git a/src/mame/drivers/coinmvga.c b/src/mame/drivers/coinmvga.c
index e7759b82139..730604cdf4b 100644
--- a/src/mame/drivers/coinmvga.c
+++ b/src/mame/drivers/coinmvga.c
@@ -237,6 +237,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_coinmvga(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_irq);
};
@@ -656,10 +657,10 @@ static const ymz280b_interface ymz280b_intf =
0 // irq ?
};
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(coinmvga_state::vblank_irq)
{
//printf("1\n");
- device->execute().set_input_line(2, HOLD_LINE);
+ device.execute().set_input_line(2, HOLD_LINE);
}
@@ -673,7 +674,7 @@ static MACHINE_CONFIG_START( coinmvga, coinmvga_state )
MCFG_CPU_ADD("maincpu", H83007, CPU_CLOCK) /* xtal */
MCFG_CPU_PROGRAM_MAP(coinmvga_map)
MCFG_CPU_IO_MAP(coinmvga_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq) /* wrong, fix me */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", coinmvga_state, vblank_irq) /* wrong, fix me */
// MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/combatsc.c b/src/mame/drivers/combatsc.c
index f29aff33055..e6a41994ff1 100644
--- a/src/mame/drivers/combatsc.c
+++ b/src/mame/drivers/combatsc.c
@@ -735,7 +735,7 @@ static MACHINE_CONFIG_START( combatsc, combatsc_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, 3000000*4) /* 3 MHz? */
MCFG_CPU_PROGRAM_MAP(combatsc_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", combatsc_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,3579545) /* 3.579545 MHz */
MCFG_CPU_PROGRAM_MAP(combatsc_sound_map)
@@ -785,11 +785,11 @@ static MACHINE_CONFIG_START( combatscb, combatsc_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, 3000000*4) /* 3 MHz? */
MCFG_CPU_PROGRAM_MAP(combatscb_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", combatsc_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,3579545) /* 3.579545 MHz */
MCFG_CPU_PROGRAM_MAP(combatscb_sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,3800) // controls BGM tempo
+ MCFG_CPU_PERIODIC_INT_DRIVER(combatsc_state, irq0_line_hold, 3800) // controls BGM tempo
MCFG_QUANTUM_TIME(attotime::from_hz(1200))
diff --git a/src/mame/drivers/commando.c b/src/mame/drivers/commando.c
index d8af16cd562..53dd2b50f7e 100644
--- a/src/mame/drivers/commando.c
+++ b/src/mame/drivers/commando.c
@@ -216,9 +216,9 @@ GFXDECODE_END
/* Interrupt Generator */
-static INTERRUPT_GEN( commando_interrupt )
+INTERRUPT_GEN_MEMBER(commando_state::commando_interrupt)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); // RST 10h - VBLANK
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); // RST 10h - VBLANK
}
/* Machine Driver */
@@ -247,11 +247,11 @@ static MACHINE_CONFIG_START( commando, commando_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, PHI_MAIN) // ???
MCFG_CPU_PROGRAM_MAP(commando_map)
- MCFG_CPU_VBLANK_INT("screen", commando_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", commando_state, commando_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, PHI_B) // 3 MHz
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(commando_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/compgolf.c b/src/mame/drivers/compgolf.c
index 2ce772f68b1..0e4ac3b72d1 100644
--- a/src/mame/drivers/compgolf.c
+++ b/src/mame/drivers/compgolf.c
@@ -248,7 +248,7 @@ static MACHINE_CONFIG_START( compgolf, compgolf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2000000)
MCFG_CPU_PROGRAM_MAP(compgolf_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", compgolf_state, nmi_line_pulse)
/* video hardware */
diff --git a/src/mame/drivers/contra.c b/src/mame/drivers/contra.c
index 8d98e8ac490..089d20f86ab 100644
--- a/src/mame/drivers/contra.c
+++ b/src/mame/drivers/contra.c
@@ -25,12 +25,11 @@ Dip locations and factory settings verified with manual
#include "includes/contra.h"
-static INTERRUPT_GEN( contra_interrupt )
+INTERRUPT_GEN_MEMBER(contra_state::contra_interrupt)
{
- contra_state *state = device->machine().driver_data<contra_state>();
- address_space &space = state->generic_space();
- if (k007121_ctrlram_r(state->m_k007121_1, space, 7) & 0x02)
- device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
+ address_space &space = generic_space();
+ if (k007121_ctrlram_r(m_k007121_1, space, 7) & 0x02)
+ device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
}
WRITE8_MEMBER(contra_state::contra_bankswitch_w)
@@ -192,7 +191,7 @@ static MACHINE_CONFIG_START( contra, contra_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, XTAL_24MHz / 2 /* 3000000*4? */)
MCFG_CPU_PROGRAM_MAP(contra_map)
- MCFG_CPU_VBLANK_INT("screen", contra_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", contra_state, contra_interrupt)
MCFG_CPU_ADD("audiocpu", M6809, XTAL_24MHz/8) /* 3000000? */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/coolridr.c b/src/mame/drivers/coolridr.c
index 7c85854ca9b..d6fd3bad0c9 100644
--- a/src/mame/drivers/coolridr.c
+++ b/src/mame/drivers/coolridr.c
@@ -320,6 +320,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_coolridr(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(system_h1);
};
@@ -1137,9 +1138,9 @@ INPUT_PORTS_END
// IRQs 4, 6 (& 8?) are valid on SH-2
-static INTERRUPT_GEN( system_h1 )
+INTERRUPT_GEN_MEMBER(coolridr_state::system_h1)
{
- device->execute().set_input_line(4, HOLD_LINE);
+ device.execute().set_input_line(4, HOLD_LINE);
}
//IRQs 10,12 and 14 are valid on SH-1 instead
@@ -1165,7 +1166,7 @@ void coolridr_state::machine_reset()
static MACHINE_CONFIG_START( coolridr, coolridr_state )
MCFG_CPU_ADD("maincpu", SH2, 28000000) // 28 mhz
MCFG_CPU_PROGRAM_MAP(system_h1_map)
- MCFG_CPU_VBLANK_INT("screen",system_h1)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", coolridr_state, system_h1)
MCFG_CPU_ADD("soundcpu", M68000, 11289600) //256 x 44100 Hz = 11.2896 MHz
MCFG_CPU_PROGRAM_MAP(system_h1_sound_map)
diff --git a/src/mame/drivers/cop01.c b/src/mame/drivers/cop01.c
index c2866446810..31ec1141ac0 100644
--- a/src/mame/drivers/cop01.c
+++ b/src/mame/drivers/cop01.c
@@ -454,7 +454,7 @@ static MACHINE_CONFIG_START( cop01, cop01_state )
MCFG_CPU_ADD("maincpu", Z80, MAINCPU_CLOCK/2) /* unknown clock / divider */
MCFG_CPU_PROGRAM_MAP(cop01_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cop01_state, irq0_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3MHz) /* unknown clock / divider, hand-tuned to match audio reference */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -492,7 +492,7 @@ static MACHINE_CONFIG_START( mightguy, cop01_state )
MCFG_CPU_ADD("maincpu", Z80, MAINCPU_CLOCK/2) /* unknown divider */
MCFG_CPU_PROGRAM_MAP(cop01_map)
MCFG_CPU_IO_MAP(mightguy_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cop01_state, irq0_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, AUDIOCPU_CLOCK/2) /* unknown divider */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/corona.c b/src/mame/drivers/corona.c
index 4ba6d045b85..986b91ada6e 100644
--- a/src/mame/drivers/corona.c
+++ b/src/mame/drivers/corona.c
@@ -1358,12 +1358,12 @@ static MACHINE_CONFIG_START( winner81, corona_state )
MCFG_CPU_ADD("maincpu", Z80, WC81_MAIN_XTAL/8) /* measured */
MCFG_CPU_PROGRAM_MAP(winner81_map)
MCFG_CPU_IO_MAP(winner81_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
MCFG_CPU_ADD("soundcpu", Z80, WC81_MAIN_XTAL/10) /* measured */
MCFG_CPU_PROGRAM_MAP(winner81_sound_map)
MCFG_CPU_IO_MAP(winner81_sound_cpu_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
+ MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
MCFG_NVRAM_ADD_0FILL("nvram")
@@ -1390,7 +1390,7 @@ static MACHINE_CONFIG_START( winner82, corona_state )
MCFG_CPU_ADD("maincpu", Z80, WC82_MAIN_XTAL/8) /* measured */
MCFG_CPU_PROGRAM_MAP(winner82_map)
MCFG_CPU_IO_MAP(winner82_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
MCFG_CPU_ADD("soundcpu", Z80, WC82_MAIN_XTAL/8) /* measured */
MCFG_CPU_PROGRAM_MAP(winner82_sound_map) /* IM1 instead of NMI */
@@ -1420,12 +1420,12 @@ static MACHINE_CONFIG_START( re800, corona_state )
MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(re800_map)
MCFG_CPU_IO_MAP(re800_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(re800_sound_map)
MCFG_CPU_IO_MAP(re800_sound_cpu_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
+ MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
MCFG_NVRAM_ADD_0FILL("nvram")
@@ -1451,7 +1451,7 @@ static MACHINE_CONFIG_START( rcirulet, corona_state )
MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(re800_map)
MCFG_CPU_IO_MAP(re800_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(winner82_sound_map) /* IM1 instead of NMI */
@@ -1481,12 +1481,12 @@ static MACHINE_CONFIG_START( luckyrlt, corona_state )
MCFG_CPU_ADD("maincpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(luckyrlt_map)
MCFG_CPU_IO_MAP(luckyrlt_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", corona_state, nmi_line_pulse)
MCFG_CPU_ADD("soundcpu", Z80, RE_MAIN_XTAL/8) /* measured 2MHz */
MCFG_CPU_PROGRAM_MAP(luckyrlt_sound_map)
MCFG_CPU_IO_MAP(luckyrlt_sound_cpu_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
+ MCFG_CPU_PERIODIC_INT_DRIVER(corona_state, nmi_line_pulse, 244) /* 244 Hz (1MHz/16/16/16) */
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/cps1.c b/src/mame/drivers/cps1.c
index cf612f93c48..16ab40ea26a 100644
--- a/src/mame/drivers/cps1.c
+++ b/src/mame/drivers/cps1.c
@@ -326,11 +326,11 @@ WRITE16_MEMBER(cps_state::cpsq_coinctrl2_w)
}
}
-INTERRUPT_GEN( cps1_interrupt )
+INTERRUPT_GEN_MEMBER(cps_state::cps1_interrupt)
{
/* Strider also has a IRQ4 handler. It is input port related, but the game */
/* works without it. It is the *only* CPS1 game to have that. */
- device->execute().set_input_line(2, HOLD_LINE);
+ device.execute().set_input_line(2, HOLD_LINE);
}
/********************************************************************
@@ -341,9 +341,9 @@ INTERRUPT_GEN( cps1_interrupt )
********************************************************************/
-static INTERRUPT_GEN( cps1_qsound_interrupt )
+INTERRUPT_GEN_MEMBER(cps_state::cps1_qsound_interrupt)
{
- device->execute().set_input_line(2, HOLD_LINE);
+ device.execute().set_input_line(2, HOLD_LINE);
}
@@ -3054,7 +3054,7 @@ static MACHINE_CONFIG_START( cps1_10MHz, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz ) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sub_map)
@@ -3109,11 +3109,11 @@ static MACHINE_CONFIG_DERIVED( qsound, cps1_12MHz )
MCFG_CPU_REPLACE("maincpu", M68000, XTAL_12MHz ) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(qsound_main_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_qsound_interrupt) /* ??? interrupts per frame */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_qsound_interrupt) /* ??? interrupts per frame */
MCFG_CPU_REPLACE("audiocpu", Z80, XTAL_8MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(qsound_sub_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 250) /* ?? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(cps_state, irq0_line_hold, 250) /* ?? */
MCFG_MACHINE_START_OVERRIDE(cps_state,qsound)
@@ -3138,7 +3138,7 @@ static MACHINE_CONFIG_START( cpspicb, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_qsound_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_qsound_interrupt)
MCFG_CPU_ADD("audiocpu", PIC16C57, 12000000)
MCFG_DEVICE_DISABLE() /* no valid dumps .. */
@@ -3212,7 +3212,7 @@ static MACHINE_CONFIG_START( sf2mdt, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 3579545)
MCFG_CPU_PROGRAM_MAP(sf2mdt_z80map)
@@ -3296,7 +3296,7 @@ static MACHINE_CONFIG_START( knightsb, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 24000000 / 2)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 29821000 / 8)
MCFG_CPU_PROGRAM_MAP(sf2mdt_z80map)
diff --git a/src/mame/drivers/cps3.c b/src/mame/drivers/cps3.c
index 59cfea2d4f1..9236e1638d1 100644
--- a/src/mame/drivers/cps3.c
+++ b/src/mame/drivers/cps3.c
@@ -2243,17 +2243,17 @@ static INPUT_PORTS_START( cps3_jojo)
PORT_BIT( 0x00200000, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_PLAYER(2)
INPUT_PORTS_END
-static INTERRUPT_GEN(cps3_vbl_interrupt)
+INTERRUPT_GEN_MEMBER(cps3_state::cps3_vbl_interrupt)
{
- device->execute().set_input_line(12, ASSERT_LINE);
+ device.execute().set_input_line(12, ASSERT_LINE);
}
-static INTERRUPT_GEN(cps3_other_interrupt)
+INTERRUPT_GEN_MEMBER(cps3_state::cps3_other_interrupt)
{
// this seems to need to be periodic (see the life bar portraits in sfiii2
// but also triggered on certain dma events (or warzard locks up in attract)
// what is the REAL source of IRQ10??
- device->execute().set_input_line(10, ASSERT_LINE);
+ device.execute().set_input_line(10, ASSERT_LINE);
}
@@ -2494,8 +2494,8 @@ static MACHINE_CONFIG_START( cps3, cps3_state )
/* basic machine hardware */
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..)
MCFG_CPU_PROGRAM_MAP(cps3_map)
- MCFG_CPU_VBLANK_INT("screen", cps3_vbl_interrupt)
- MCFG_CPU_PERIODIC_INT(cps3_other_interrupt,80) /* ?source? */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps3_state, cps3_vbl_interrupt)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cps3_state, cps3_other_interrupt, 80) /* ?source? */
MCFG_CPU_CONFIG(sh2_conf_cps3)
MCFG_SCSIBUS_ADD("scsi")
diff --git a/src/mame/drivers/crbaloon.c b/src/mame/drivers/crbaloon.c
index a9d51f3416d..e3d22444064 100644
--- a/src/mame/drivers/crbaloon.c
+++ b/src/mame/drivers/crbaloon.c
@@ -355,12 +355,11 @@ void crbaloon_state::machine_reset()
*
*************************************/
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(crbaloon_state::vblank_irq)
{
- crbaloon_state *state = device->machine().driver_data<crbaloon_state>();
- if(state->m_irq_mask)
- device->execute().set_input_line(0, HOLD_LINE);
+ if(m_irq_mask)
+ device.execute().set_input_line(0, HOLD_LINE);
}
@@ -370,7 +369,7 @@ static MACHINE_CONFIG_START( crbaloon, crbaloon_state )
MCFG_CPU_ADD("maincpu", Z80, CRBALOON_MASTER_XTAL / 3)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crbaloon_state, vblank_irq)
/* video hardware */
diff --git a/src/mame/drivers/crgolf.c b/src/mame/drivers/crgolf.c
index d325e738c31..23714e40ffd 100644
--- a/src/mame/drivers/crgolf.c
+++ b/src/mame/drivers/crgolf.c
@@ -404,11 +404,11 @@ static MACHINE_CONFIG_START( crgolf, crgolf_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,MASTER_CLOCK/3/2)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crgolf_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,MASTER_CLOCK/3/2)
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crgolf_state, irq0_line_hold)
MCFG_QUANTUM_TIME(attotime::from_hz(6000))
diff --git a/src/mame/drivers/crimfght.c b/src/mame/drivers/crimfght.c
index 34bd6a5e069..6e844038eda 100644
--- a/src/mame/drivers/crimfght.c
+++ b/src/mame/drivers/crimfght.c
@@ -23,12 +23,11 @@
/* prototypes */
static KONAMI_SETLINES_CALLBACK( crimfght_banking );
-static INTERRUPT_GEN( crimfght_interrupt )
+INTERRUPT_GEN_MEMBER(crimfght_state::crimfght_interrupt)
{
- crimfght_state *state = device->machine().driver_data<crimfght_state>();
- if (k051960_is_irq_enabled(state->m_k051960))
- device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
+ if (k051960_is_irq_enabled(m_k051960))
+ device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
}
WRITE8_MEMBER(crimfght_state::crimfght_coin_w)
@@ -282,7 +281,7 @@ static MACHINE_CONFIG_START( crimfght, crimfght_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI, XTAL_24MHz/8) /* 052001 (verified on pcb) */
MCFG_CPU_PROGRAM_MAP(crimfght_map)
- MCFG_CPU_VBLANK_INT("screen", crimfght_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crimfght_state, crimfght_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_3_579545MHz) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(crimfght_sound_map)
diff --git a/src/mame/drivers/crospang.c b/src/mame/drivers/crospang.c
index 2bc030be116..4b9437dd3d9 100644
--- a/src/mame/drivers/crospang.c
+++ b/src/mame/drivers/crospang.c
@@ -349,7 +349,7 @@ static MACHINE_CONFIG_START( crospang, crospang_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 14318180)
MCFG_CPU_PROGRAM_MAP(crospang_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crospang_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 14318180/4)
MCFG_CPU_PROGRAM_MAP(crospang_sound_map)
diff --git a/src/mame/drivers/crshrace.c b/src/mame/drivers/crshrace.c
index fb7c55d2ff2..0686ef1f2b2 100644
--- a/src/mame/drivers/crshrace.c
+++ b/src/mame/drivers/crshrace.c
@@ -463,7 +463,7 @@ static MACHINE_CONFIG_START( crshrace, crshrace_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,16000000) /* 16 MHz ??? */
MCFG_CPU_PROGRAM_MAP(crshrace_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crshrace_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,4000000) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/crystal.c b/src/mame/drivers/crystal.c
index 9421a359b88..984a4ee3a27 100644
--- a/src/mame/drivers/crystal.c
+++ b/src/mame/drivers/crystal.c
@@ -192,6 +192,7 @@ public:
virtual void machine_reset();
UINT32 screen_update_crystal(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void screen_eof_crystal(screen_device &screen, bool state);
+ INTERRUPT_GEN_MEMBER(crystal_interrupt);
};
static void IntReq( running_machine &machine, int num )
@@ -742,9 +743,9 @@ void crystal_state::screen_eof_crystal(screen_device &screen, bool state)
}
}
-static INTERRUPT_GEN(crystal_interrupt)
+INTERRUPT_GEN_MEMBER(crystal_state::crystal_interrupt)
{
- IntReq(device->machine(), 24); //VRender0 VBlank
+ IntReq(machine(), 24); //VRender0 VBlank
}
static INPUT_PORTS_START(crystal)
@@ -841,7 +842,7 @@ static MACHINE_CONFIG_START( crystal, crystal_state )
MCFG_CPU_ADD("maincpu", SE3208, 43000000)
MCFG_CPU_PROGRAM_MAP(crystal_mem)
- MCFG_CPU_VBLANK_INT("screen", crystal_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", crystal_state, crystal_interrupt)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/cubeqst.c b/src/mame/drivers/cubeqst.c
index 2c305b729c8..d237bd8ad77 100644
--- a/src/mame/drivers/cubeqst.c
+++ b/src/mame/drivers/cubeqst.c
@@ -57,6 +57,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_cubeqst(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank);
};
@@ -192,15 +193,14 @@ READ16_MEMBER(cubeqst_state::line_r)
return machine().primary_screen->vpos();
}
-static INTERRUPT_GEN( vblank )
+INTERRUPT_GEN_MEMBER(cubeqst_state::vblank)
{
- cubeqst_state *state = device->machine().driver_data<cubeqst_state>();
- int int_level = state->m_video_field == 0 ? 5 : 6;
+ int int_level = m_video_field == 0 ? 5 : 6;
- device->execute().set_input_line(int_level, HOLD_LINE);
+ device.execute().set_input_line(int_level, HOLD_LINE);
/* Update the laserdisc */
- state->m_video_field ^= 1;
+ m_video_field ^= 1;
}
@@ -513,7 +513,7 @@ static const cubeqst_lin_config lin_config =
static MACHINE_CONFIG_START( cubeqst, cubeqst_state )
MCFG_CPU_ADD("main_cpu", M68000, XTAL_16MHz / 2)
MCFG_CPU_PROGRAM_MAP(m68k_program_map)
- MCFG_CPU_VBLANK_INT("screen", vblank)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cubeqst_state, vblank)
MCFG_CPU_ADD("rotate_cpu", CQUESTROT, XTAL_10MHz / 2)
MCFG_CPU_PROGRAM_MAP(rotate_map)
diff --git a/src/mame/drivers/cultures.c b/src/mame/drivers/cultures.c
index 9c915e73ec7..52389170423 100644
--- a/src/mame/drivers/cultures.c
+++ b/src/mame/drivers/cultures.c
@@ -57,6 +57,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_cultures(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(cultures_interrupt);
};
@@ -362,11 +363,10 @@ static GFXDECODE_START( culture )
GFXDECODE_ENTRY("gfx3", 0, gfxlayout, 0x1000, 0x10 )
GFXDECODE_END
-static INTERRUPT_GEN( cultures_interrupt )
+INTERRUPT_GEN_MEMBER(cultures_state::cultures_interrupt)
{
- cultures_state *state = device->machine().driver_data<cultures_state>();
- if (state->m_irq_enable)
- device->execute().set_input_line(0, HOLD_LINE);
+ if (m_irq_enable)
+ device.execute().set_input_line(0, HOLD_LINE);
}
void cultures_state::machine_start()
@@ -398,7 +398,7 @@ static MACHINE_CONFIG_START( cultures, cultures_state )
MCFG_CPU_ADD("maincpu", Z80, MCLK/2) /* 8.000 MHz */
MCFG_CPU_PROGRAM_MAP(cultures_map)
MCFG_CPU_IO_MAP(cultures_io_map)
- MCFG_CPU_VBLANK_INT("screen", cultures_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cultures_state, cultures_interrupt)
/* video hardware */
diff --git a/src/mame/drivers/cvs.c b/src/mame/drivers/cvs.c
index 508d188e9bf..1708ef6eb23 100644
--- a/src/mame/drivers/cvs.c
+++ b/src/mame/drivers/cvs.c
@@ -226,12 +226,12 @@ WRITE8_MEMBER(cvs_state::cvs_s2636_2_or_character_ram_w)
*
*************************************/
-static INTERRUPT_GEN( cvs_main_cpu_interrupt )
+INTERRUPT_GEN_MEMBER(cvs_state::cvs_main_cpu_interrupt)
{
- device->execute().set_input_line_vector(0, 0x03);
- generic_pulse_irq_line(device, 0, 1);
+ device.execute().set_input_line_vector(0, 0x03);
+ generic_pulse_irq_line(device.execute(), 0, 1);
- cvs_scroll_stars(device->machine());
+ cvs_scroll_stars(machine());
}
@@ -1042,7 +1042,7 @@ static MACHINE_CONFIG_START( cvs, cvs_state )
MCFG_CPU_ADD("maincpu", S2650, 894886.25)
MCFG_CPU_PROGRAM_MAP(cvs_main_cpu_map)
MCFG_CPU_IO_MAP(cvs_main_cpu_io_map)
- MCFG_CPU_VBLANK_INT("screen", cvs_main_cpu_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cvs_state, cvs_main_cpu_interrupt)
MCFG_CPU_ADD("audiocpu", S2650, 894886.25)
MCFG_CPU_PROGRAM_MAP(cvs_dac_cpu_map)
diff --git a/src/mame/drivers/cyberbal.c b/src/mame/drivers/cyberbal.c
index e547255de08..544426130ca 100644
--- a/src/mame/drivers/cyberbal.c
+++ b/src/mame/drivers/cyberbal.c
@@ -440,7 +440,7 @@ static MACHINE_CONFIG_START( cyberbal, cyberbal_state )
MCFG_CPU_ADD("dac", M68000, ATARI_CLOCK_14MHz/2)
MCFG_CPU_PROGRAM_MAP(sound_68k_map)
- MCFG_CPU_PERIODIC_INT(cyberbal_sound_68k_irq_gen, 10000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(cyberbal_state, cyberbal_sound_68k_irq_gen, 10000)
MCFG_QUANTUM_TIME(attotime::from_hz(600))
diff --git a/src/mame/drivers/cybertnk.c b/src/mame/drivers/cybertnk.c
index 4e3e801c4d7..7d84b2bb316 100644
--- a/src/mame/drivers/cybertnk.c
+++ b/src/mame/drivers/cybertnk.c
@@ -834,11 +834,11 @@ static const y8950_interface y8950_config = {
static MACHINE_CONFIG_START( cybertnk, cybertnk_state )
MCFG_CPU_ADD("maincpu", M68000,XTAL_20MHz/2)
MCFG_CPU_PROGRAM_MAP(master_mem)
- MCFG_CPU_VBLANK_INT("lscreen", irq1_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", cybertnk_state, irq1_line_assert)
MCFG_CPU_ADD("slave", M68000,XTAL_20MHz/2)
MCFG_CPU_PROGRAM_MAP(slave_mem)
- MCFG_CPU_VBLANK_INT("lscreen", irq3_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", cybertnk_state, irq3_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_3_579545MHz)
MCFG_CPU_PROGRAM_MAP(sound_mem)
diff --git a/src/mame/drivers/cyclemb.c b/src/mame/drivers/cyclemb.c
index 3f3ae5fd36b..0e8af71729f 100644
--- a/src/mame/drivers/cyclemb.c
+++ b/src/mame/drivers/cyclemb.c
@@ -907,7 +907,7 @@ static MACHINE_CONFIG_START( cyclemb, cyclemb_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz/3) // Z8400BPS
MCFG_CPU_PROGRAM_MAP(cyclemb_map)
MCFG_CPU_IO_MAP(cyclemb_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cyclemb_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/6)
MCFG_CPU_PROGRAM_MAP(cyclemb_sound_map)
diff --git a/src/mame/drivers/d9final.c b/src/mame/drivers/d9final.c
index 55ed1a0d1bc..0f612032f20 100644
--- a/src/mame/drivers/d9final.c
+++ b/src/mame/drivers/d9final.c
@@ -284,7 +284,7 @@ static MACHINE_CONFIG_START( d9final, d9final_state )
MCFG_CPU_ADD("maincpu", Z80, 24000000/4)/* ? MHz */
MCFG_CPU_PROGRAM_MAP(d9final_map)
MCFG_CPU_IO_MAP(d9final_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", d9final_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/dacholer.c b/src/mame/drivers/dacholer.c
index bceae49218e..9afe5c4ec66 100644
--- a/src/mame/drivers/dacholer.c
+++ b/src/mame/drivers/dacholer.c
@@ -90,6 +90,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_dacholer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(sound_irq);
};
TILE_GET_INFO_MEMBER(dacholer_state::get_bg_tile_info)
@@ -549,12 +550,11 @@ static GFXDECODE_START( itaten )
GFXDECODE_END
-static INTERRUPT_GEN( sound_irq )
+INTERRUPT_GEN_MEMBER(dacholer_state::sound_irq)
{
- dacholer_state *state = device->machine().driver_data<dacholer_state>();
- if (state->m_music_interrupt_enable == 1)
+ if (m_music_interrupt_enable == 1)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x30);
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x30);
}
}
@@ -652,12 +652,12 @@ static MACHINE_CONFIG_START( dacholer, dacholer_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_16MHz/4) /* ? */
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dacholer_state, irq0_line_assert)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_19_968MHz/8) /* ? */
MCFG_CPU_PROGRAM_MAP(snd_map)
MCFG_CPU_IO_MAP(snd_io_map)
- MCFG_CPU_VBLANK_INT("screen",sound_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dacholer_state, sound_irq)
/* video hardware */
diff --git a/src/mame/drivers/dai3wksi.c b/src/mame/drivers/dai3wksi.c
index 50b0fe4dd11..15a84c4035b 100644
--- a/src/mame/drivers/dai3wksi.c
+++ b/src/mame/drivers/dai3wksi.c
@@ -591,7 +591,7 @@ static MACHINE_CONFIG_START( dai3wksi, dai3wksi_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_10MHz/4)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dai3wksi_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/darius.c b/src/mame/drivers/darius.c
index cdf09e14c53..20cef1e0392 100644
--- a/src/mame/drivers/darius.c
+++ b/src/mame/drivers/darius.c
@@ -918,14 +918,14 @@ static MACHINE_CONFIG_START( darius, darius_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,16000000/2) /* 8 MHz ? */
MCFG_CPU_PROGRAM_MAP(darius_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", darius_state, irq4_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz ? */
MCFG_CPU_PROGRAM_MAP(darius_sound_map)
MCFG_CPU_ADD("cpub", M68000,16000000/2) /* 8 MHz ? */
MCFG_CPU_PROGRAM_MAP(darius_cpub_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", darius_state, irq4_line_hold)
MCFG_CPU_ADD("adpcm", Z80,8000000/2) /* 4 MHz ? */ /* ADPCM player using MSM5205 */
MCFG_CPU_PROGRAM_MAP(darius_sound2_map)
diff --git a/src/mame/drivers/darkseal.c b/src/mame/drivers/darkseal.c
index 1585ae34e6f..d253097c82e 100644
--- a/src/mame/drivers/darkseal.c
+++ b/src/mame/drivers/darkseal.c
@@ -263,7 +263,7 @@ static MACHINE_CONFIG_START( darkseal, darkseal_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,12000000) /* Custom chip 59 */
MCFG_CPU_PROGRAM_MAP(darkseal_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", darkseal_state, irq6_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", H6280, 32220000/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/dassault.c b/src/mame/drivers/dassault.c
index 1cf0477cc63..094d506f2ef 100644
--- a/src/mame/drivers/dassault.c
+++ b/src/mame/drivers/dassault.c
@@ -506,11 +506,11 @@ static MACHINE_CONFIG_START( dassault, dassault_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2) /* 14MHz - Accurate */
MCFG_CPU_PROGRAM_MAP(dassault_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dassault_state, irq4_line_hold)
MCFG_CPU_ADD("sub", M68000, XTAL_28MHz/2) /* 14MHz - Accurate */
MCFG_CPU_PROGRAM_MAP(dassault_sub_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dassault_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/8) /* Accurate */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/dblewing.c b/src/mame/drivers/dblewing.c
index d8e0fc4d93a..21a6a26042a 100644
--- a/src/mame/drivers/dblewing.c
+++ b/src/mame/drivers/dblewing.c
@@ -641,7 +641,7 @@ static MACHINE_CONFIG_START( dblewing, dblewing_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 14000000) /* DE102 */
MCFG_CPU_PROGRAM_MAP(dblewing_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dblewing_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/dcheese.c b/src/mame/drivers/dcheese.c
index 108bf01894d..4fd8898fd79 100644
--- a/src/mame/drivers/dcheese.c
+++ b/src/mame/drivers/dcheese.c
@@ -79,10 +79,10 @@ void dcheese_signal_irq( running_machine &machine, int which )
}
-static INTERRUPT_GEN( dcheese_vblank )
+INTERRUPT_GEN_MEMBER(dcheese_state::dcheese_vblank)
{
logerror("---- VBLANK ----\n");
- dcheese_signal_irq(device->machine(), 4);
+ dcheese_signal_irq(machine(), 4);
}
@@ -409,11 +409,11 @@ static MACHINE_CONFIG_START( dcheese, dcheese_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, MAIN_OSC)
MCFG_CPU_PROGRAM_MAP(main_cpu_map)
- MCFG_CPU_VBLANK_INT("screen", dcheese_vblank)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dcheese_state, dcheese_vblank)
MCFG_CPU_ADD("audiocpu", M6809, SOUND_OSC/16)
MCFG_CPU_PROGRAM_MAP(sound_cpu_map)
- MCFG_CPU_PERIODIC_INT(irq1_line_hold, 480) /* accurate for fredmem */
+ MCFG_CPU_PERIODIC_INT_DRIVER(dcheese_state, irq1_line_hold, 480) /* accurate for fredmem */
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/dcon.c b/src/mame/drivers/dcon.c
index e884a3ea95f..6aa435fbf42 100644
--- a/src/mame/drivers/dcon.c
+++ b/src/mame/drivers/dcon.c
@@ -251,7 +251,7 @@ static MACHINE_CONFIG_START( dcon, dcon_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(dcon_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dcon_state, irq4_line_hold)
SEIBU_SOUND_SYSTEM_CPU(4000000) /* Perhaps 14318180/4? */
@@ -278,7 +278,7 @@ static MACHINE_CONFIG_START( sdgndmps, dcon_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(dcon_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dcon_state, irq4_line_hold)
SEIBU2_SOUND_SYSTEM_CPU(14318180/4)
diff --git a/src/mame/drivers/ddayjlc.c b/src/mame/drivers/ddayjlc.c
index 6c95e0ca4e0..12b51b81f6e 100644
--- a/src/mame/drivers/ddayjlc.c
+++ b/src/mame/drivers/ddayjlc.c
@@ -106,6 +106,8 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_ddayjlc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(ddayjlc_interrupt);
+ INTERRUPT_GEN_MEMBER(ddayjlc_snd_interrupt);
};
@@ -435,18 +437,16 @@ static const ay8910_interface ay8910_config =
DEVCB_NULL
};
-static INTERRUPT_GEN( ddayjlc_interrupt )
+INTERRUPT_GEN_MEMBER(ddayjlc_state::ddayjlc_interrupt)
{
- ddayjlc_state *state = device->machine().driver_data<ddayjlc_state>();
- if(state->m_main_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_main_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
-static INTERRUPT_GEN( ddayjlc_snd_interrupt )
+INTERRUPT_GEN_MEMBER(ddayjlc_state::ddayjlc_snd_interrupt)
{
- ddayjlc_state *state = device->machine().driver_data<ddayjlc_state>();
- if(state->m_sound_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_sound_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -518,11 +518,11 @@ static MACHINE_CONFIG_START( ddayjlc, ddayjlc_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,12000000/3)
MCFG_CPU_PROGRAM_MAP(main_cpu)
- MCFG_CPU_VBLANK_INT("screen", ddayjlc_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddayjlc_state, ddayjlc_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 12000000/4)
MCFG_CPU_PROGRAM_MAP(sound_cpu)
- MCFG_CPU_VBLANK_INT("screen", ddayjlc_snd_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddayjlc_state, ddayjlc_snd_interrupt)
MCFG_QUANTUM_TIME(attotime::from_hz(6000))
diff --git a/src/mame/drivers/ddealer.c b/src/mame/drivers/ddealer.c
index 5a32e8ea2fd..02214341454 100644
--- a/src/mame/drivers/ddealer.c
+++ b/src/mame/drivers/ddealer.c
@@ -157,6 +157,7 @@ public:
virtual void machine_reset();
virtual void video_start();
UINT32 screen_update_ddealer(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(ddealer_interrupt);
};
@@ -618,17 +619,17 @@ void ddealer_state::machine_reset()
m_coin_input = 0;
}
-static INTERRUPT_GEN( ddealer_interrupt )
+INTERRUPT_GEN_MEMBER(ddealer_state::ddealer_interrupt)
{
- device->execute().set_input_line(4, HOLD_LINE);
+ device.execute().set_input_line(4, HOLD_LINE);
}
static MACHINE_CONFIG_START( ddealer, ddealer_state )
MCFG_CPU_ADD("maincpu" , M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(ddealer)
- MCFG_CPU_VBLANK_INT("screen", ddealer_interrupt)
- MCFG_CPU_PERIODIC_INT(irq1_line_hold, 90)//guess,controls music tempo,112 is way too fast
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddealer_state, ddealer_interrupt)
+ MCFG_CPU_PERIODIC_INT_DRIVER(ddealer_state, irq1_line_hold, 90)//guess,controls music tempo,112 is way too fast
// M50747 or NMK-110 8131 MCU
diff --git a/src/mame/drivers/ddribble.c b/src/mame/drivers/ddribble.c
index ba59864cf75..114c11d4f36 100644
--- a/src/mame/drivers/ddribble.c
+++ b/src/mame/drivers/ddribble.c
@@ -18,18 +18,16 @@
#include "includes/ddribble.h"
-static INTERRUPT_GEN( ddribble_interrupt_0 )
+INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_0)
{
- ddribble_state *state = device->machine().driver_data<ddribble_state>();
- if (state->m_int_enable_0)
- device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
+ if (m_int_enable_0)
+ device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
}
-static INTERRUPT_GEN( ddribble_interrupt_1 )
+INTERRUPT_GEN_MEMBER(ddribble_state::ddribble_interrupt_1)
{
- ddribble_state *state = device->machine().driver_data<ddribble_state>();
- if (state->m_int_enable_1)
- device->execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
+ if (m_int_enable_1)
+ device.execute().set_input_line(M6809_FIRQ_LINE, HOLD_LINE);
}
@@ -282,11 +280,11 @@ static MACHINE_CONFIG_START( ddribble, ddribble_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, XTAL_18_432MHz/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu0_map)
- MCFG_CPU_VBLANK_INT("screen", ddribble_interrupt_0)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_0)
MCFG_CPU_ADD("cpu1", M6809, XTAL_18_432MHz/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", ddribble_interrupt_1)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddribble_state, ddribble_interrupt_1)
MCFG_CPU_ADD("cpu2", M6809, XTAL_18_432MHz/12) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
diff --git a/src/mame/drivers/ddz.c b/src/mame/drivers/ddz.c
index 49cff3f5cb8..dc51f249490 100644
--- a/src/mame/drivers/ddz.c
+++ b/src/mame/drivers/ddz.c
@@ -25,6 +25,7 @@ public:
virtual void video_start();
UINT32 screen_update_ddz(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
void screen_eof_ddz(screen_device &screen, bool state);
+ INTERRUPT_GEN_MEMBER(ddz_interrupt);
};
@@ -47,7 +48,7 @@ void ddz_state::screen_eof_ddz(screen_device &screen, bool state)
}
-static INTERRUPT_GEN(ddz_interrupt)
+INTERRUPT_GEN_MEMBER(ddz_state::ddz_interrupt)
{
// IntReq(24); //VRender0 VBlank
}
@@ -66,7 +67,7 @@ static const vr0_interface vr0_config =
static MACHINE_CONFIG_START( ddz, ddz_state )
MCFG_CPU_ADD("maincpu", SE3208, 43000000)
MCFG_CPU_PROGRAM_MAP(ddz_mem)
- MCFG_CPU_VBLANK_INT("screen", ddz_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ddz_state, ddz_interrupt)
//MCFG_MACHINE_RESET_OVERRIDE(ddz_state,ddz)
diff --git a/src/mame/drivers/dec0.c b/src/mame/drivers/dec0.c
index 5a1ab49d6d3..60c84931edf 100644
--- a/src/mame/drivers/dec0.c
+++ b/src/mame/drivers/dec0.c
@@ -1403,7 +1403,7 @@ static MACHINE_CONFIG_START( automat, dec0_automat_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(automat_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 3000000)// ?
MCFG_CPU_PROGRAM_MAP(automat_s_map)
@@ -1456,7 +1456,7 @@ static MACHINE_CONFIG_START( secretab, dec0_automat_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
MCFG_CPU_PROGRAM_MAP(secretab_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 3000000)// ?
MCFG_CPU_PROGRAM_MAP(automat_s_map)
@@ -1510,7 +1510,7 @@ static MACHINE_CONFIG_DERIVED( hbarrel, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1533,7 +1533,7 @@ static MACHINE_CONFIG_DERIVED( baddudes, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1553,7 +1553,7 @@ static MACHINE_CONFIG_DERIVED( birdtry, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL, level 5 interrupts from i8751 */
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1573,7 +1573,7 @@ static MACHINE_CONFIG_DERIVED( robocop, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1598,7 +1598,7 @@ static MACHINE_CONFIG_DERIVED( robocopb, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1618,7 +1618,7 @@ static MACHINE_CONFIG_DERIVED( hippodrm, dec0_base_sound )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz / 2)
MCFG_CPU_PROGRAM_MAP(dec0_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_assert)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_assert)/* VBL */
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz / 8)
MCFG_CPU_PROGRAM_MAP(dec0_s_map)
@@ -1649,7 +1649,7 @@ static MACHINE_CONFIG_DERIVED( slyspy, dec0_base_sound_alt )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
MCFG_CPU_PROGRAM_MAP(slyspy_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) /* VBL, apparently it auto-acks */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold) /* VBL, apparently it auto-acks */
MCFG_CPU_ADD("audiocpu", H6280, XTAL_12MHz/2/3) /* verified on pcb (6Mhz is XIN on pin 10 of H6280, verified on pcb */
MCFG_CPU_PROGRAM_MAP(slyspy_s_map)
@@ -1676,7 +1676,7 @@ static MACHINE_CONFIG_DERIVED( midres, dec0_base_sound_alt )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_20MHz/2) /* verified on pcb (20MHZ OSC) 68000P12 running at 10Mhz */
MCFG_CPU_PROGRAM_MAP(midres_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)/* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec0_state, irq6_line_hold)/* VBL */
MCFG_CPU_ADD("audiocpu", H6280, XTAL_24MHz/4/3) /* verified on pcb (6Mhz is XIN on pin 10 of H6280, verified on pcb */
MCFG_CPU_PROGRAM_MAP(midres_s_map)
diff --git a/src/mame/drivers/dec8.c b/src/mame/drivers/dec8.c
index 8a6863ae365..a2f3560821f 100644
--- a/src/mame/drivers/dec8.c
+++ b/src/mame/drivers/dec8.c
@@ -1955,22 +1955,20 @@ static const msm5205_interface msm5205_config =
/******************************************************************************/
-static INTERRUPT_GEN( gondo_interrupt )
+INTERRUPT_GEN_MEMBER(dec8_state::gondo_interrupt)
{
- dec8_state *state = device->machine().driver_data<dec8_state>();
- if (state->m_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* VBL */
+ if (m_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE); /* VBL */
}
/* Coins generate NMI's */
-static INTERRUPT_GEN( oscar_interrupt )
+INTERRUPT_GEN_MEMBER(dec8_state::oscar_interrupt)
{
- dec8_state *state = device->machine().driver_data<dec8_state>();
- if ((state->ioport("IN2")->read() & 0x7) == 0x7) state->m_latch = 1;
- if (state->m_latch && (state->ioport("IN2")->read() & 0x7) != 0x7)
+ if ((ioport("IN2")->read() & 0x7) == 0x7) m_latch = 1;
+ if (m_latch && (ioport("IN2")->read() & 0x7) != 0x7)
{
- state->m_latch = 0;
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ m_latch = 0;
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
}
@@ -2128,7 +2126,7 @@ static MACHINE_CONFIG_START( gondo, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP */
MCFG_CPU_PROGRAM_MAP(gondo_map)
- MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(oscar_s_map)
@@ -2176,7 +2174,7 @@ static MACHINE_CONFIG_START( garyoret, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP */
MCFG_CPU_PROGRAM_MAP(garyoret_map)
- MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(oscar_s_map)
@@ -2224,7 +2222,7 @@ static MACHINE_CONFIG_START( ghostb, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, 3000000*4)
MCFG_CPU_PROGRAM_MAP(meikyuh_map)
- MCFG_CPU_VBLANK_INT("screen", gondo_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, gondo_interrupt)
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(dec8_s_map)
@@ -2279,7 +2277,7 @@ static MACHINE_CONFIG_START( csilver, dec8_state )
MCFG_CPU_ADD("sub", M6809, XTAL_12MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(csilver_sub_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
MCFG_CPU_ADD("audiocpu", M6502, XTAL_12MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(csilver_s_map)
@@ -2328,7 +2326,7 @@ static MACHINE_CONFIG_START( oscar, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309, XTAL_12MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(oscar_map)
- MCFG_CPU_VBLANK_INT("screen", oscar_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, oscar_interrupt)
MCFG_CPU_ADD("sub", HD6309, XTAL_12MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(oscar_sub_map)
@@ -2379,7 +2377,7 @@ static MACHINE_CONFIG_START( srdarwin, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809,2000000) /* MC68A09EP */
MCFG_CPU_PROGRAM_MAP(srdarwin_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(dec8_s_map)
@@ -2420,7 +2418,7 @@ static MACHINE_CONFIG_START( cobracom, dec8_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 2000000)
MCFG_CPU_PROGRAM_MAP(cobra_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dec8_state, nmi_line_pulse)
MCFG_CPU_ADD("audiocpu", M6502, 1500000)
MCFG_CPU_PROGRAM_MAP(dec8_s_map)
diff --git a/src/mame/drivers/deco156.c b/src/mame/drivers/deco156.c
index 262f6613a6b..a87c9f4be05 100644
--- a/src/mame/drivers/deco156.c
+++ b/src/mame/drivers/deco156.c
@@ -55,6 +55,7 @@ public:
DECLARE_DRIVER_INIT(wcvol95);
virtual void video_start();
UINT32 screen_update_wcvol95(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(deco32_vbl_interrupt);
};
@@ -313,9 +314,9 @@ static const ymz280b_interface ymz280b_intf =
sound_irq_gen
};
-static INTERRUPT_GEN( deco32_vbl_interrupt )
+INTERRUPT_GEN_MEMBER(deco156_state::deco32_vbl_interrupt)
{
- device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
+ device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
}
static int deco156_bank_callback(const int bank)
@@ -354,7 +355,7 @@ static MACHINE_CONFIG_START( hvysmsh, deco156_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000) /* Unconfirmed */
MCFG_CPU_PROGRAM_MAP(hvysmsh_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco156_state, deco32_vbl_interrupt)
MCFG_EEPROM_93C46_ADD("eeprom")
@@ -391,7 +392,7 @@ static MACHINE_CONFIG_START( wcvol95, deco156_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000) /* Unconfirmed */
MCFG_CPU_PROGRAM_MAP(wcvol95_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco156_state, deco32_vbl_interrupt)
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/deco32.c b/src/mame/drivers/deco32.c
index 6c6c2377686..410dc01da5c 100644
--- a/src/mame/drivers/deco32.c
+++ b/src/mame/drivers/deco32.c
@@ -1671,9 +1671,9 @@ MACHINE_RESET_MEMBER(deco32_state,deco32)
decoprot_reset(machine());
}
-static INTERRUPT_GEN( deco32_vbl_interrupt )
+INTERRUPT_GEN_MEMBER(deco32_state::deco32_vbl_interrupt)
{
- device->execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
+ device.execute().set_input_line(ARM_IRQ_LINE, HOLD_LINE);
}
UINT16 captaven_pri_callback(UINT16 x)
@@ -1735,7 +1735,7 @@ static MACHINE_CONFIG_START( captaven, deco32_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, XTAL_28MHz/4) /* verified on pcb (Data East 101 custom)*/
MCFG_CPU_PROGRAM_MAP(captaven_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
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) */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1787,7 +1787,7 @@ static MACHINE_CONFIG_START( fghthist, deco32_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
MCFG_CPU_PROGRAM_MAP(fghthist_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1834,7 +1834,7 @@ static MACHINE_CONFIG_START( fghthsta, deco32_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
MCFG_CPU_PROGRAM_MAP(fghthsta_memmap)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -1943,7 +1943,7 @@ static MACHINE_CONFIG_START( dragngun, dragngun_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000/4)
MCFG_CPU_PROGRAM_MAP(dragngun_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
MCFG_CPU_ADD("audiocpu", H6280, 32220000/8)
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -2110,7 +2110,7 @@ static MACHINE_CONFIG_START( tattass, deco32_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28000000/*/4*/) /* Unconfirmed - the divider makes it far too slow, due to inaccurate core timings? */
MCFG_CPU_PROGRAM_MAP(tattass_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
MCFG_EEPROM_ADD("eeprom", eeprom_interface_tattass)
@@ -2144,7 +2144,7 @@ static MACHINE_CONFIG_START( nslasher, deco32_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", ARM, 28322000/4)
MCFG_CPU_PROGRAM_MAP(nslasher_map)
- MCFG_CPU_VBLANK_INT("screen", deco32_vbl_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco32_state, deco32_vbl_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 32220000/9)
MCFG_CPU_PROGRAM_MAP(nslasher_sound)
diff --git a/src/mame/drivers/deco_ld.c b/src/mame/drivers/deco_ld.c
index bc09dde4da6..235219b9ead 100644
--- a/src/mame/drivers/deco_ld.c
+++ b/src/mame/drivers/deco_ld.c
@@ -147,6 +147,7 @@ public:
DECLARE_INPUT_CHANGED_MEMBER(coin_inserted);
virtual void machine_start();
UINT32 screen_update_rblaster(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(sound_interrupt);
};
static void draw_sprites(running_machine &machine, bitmap_rgb32 &bitmap, const rectangle &cliprect, UINT8 *spriteram, UINT16 tile_bank )
@@ -295,10 +296,9 @@ WRITE8_MEMBER(deco_ld_state::nmimask_w)
}
#endif
-static INTERRUPT_GEN ( sound_interrupt )
+INTERRUPT_GEN_MEMBER(deco_ld_state::sound_interrupt)
{
- deco_ld_state *state = device->machine().driver_data<deco_ld_state>();
- if (!state->m_nmimask) device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (!m_nmimask) device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -459,11 +459,11 @@ static MACHINE_CONFIG_START( rblaster, deco_ld_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M6502,8000000/2)
MCFG_CPU_PROGRAM_MAP(rblaster_map)
- MCFG_CPU_VBLANK_INT("screen",irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deco_ld_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu",M6502,8000000/2)
MCFG_CPU_PROGRAM_MAP(rblaster_sound_map)
- MCFG_CPU_PERIODIC_INT(sound_interrupt, 640)
+ MCFG_CPU_PERIODIC_INT_DRIVER(deco_ld_state, sound_interrupt, 640)
// MCFG_QUANTUM_TIME(attotime::from_hz(6000))
diff --git a/src/mame/drivers/deniam.c b/src/mame/drivers/deniam.c
index 0f7b4839481..58209aa9086 100644
--- a/src/mame/drivers/deniam.c
+++ b/src/mame/drivers/deniam.c
@@ -272,7 +272,7 @@ static MACHINE_CONFIG_START( deniam16b, deniam_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,XTAL_25MHz/2) /* 12.5Mhz verified */
MCFG_CPU_PROGRAM_MAP(deniam16b_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deniam_state, irq4_line_assert)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_25MHz/4) /* 6.25Mhz verified */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -308,7 +308,7 @@ static MACHINE_CONFIG_START( deniam16c, deniam_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,XTAL_25MHz/2) /* 12.5Mhz verified */
MCFG_CPU_PROGRAM_MAP(deniam16c_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", deniam_state, irq4_line_assert)
/* video hardware */
diff --git a/src/mame/drivers/deshoros.c b/src/mame/drivers/deshoros.c
index a59a28765ec..e50116107be 100644
--- a/src/mame/drivers/deshoros.c
+++ b/src/mame/drivers/deshoros.c
@@ -261,7 +261,7 @@ static MACHINE_CONFIG_START( destiny, destiny_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, XTAL_4MHz/2)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 60) // timer irq controls update speed, frequency needs to be determined yet (2MHz through three 74LS390)
+ 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)
/* video hardware (dummy) */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/destroyr.c b/src/mame/drivers/destroyr.c
index 202f3ea43ad..6f0d27ea2ee 100644
--- a/src/mame/drivers/destroyr.c
+++ b/src/mame/drivers/destroyr.c
@@ -452,7 +452,7 @@ static MACHINE_CONFIG_START( destroyr, destroyr_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6800, XTAL_12_096MHz / 16)
MCFG_CPU_PROGRAM_MAP(destroyr_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_assert, 4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(destroyr_state, irq0_line_assert, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/dietgo.c b/src/mame/drivers/dietgo.c
index ce0a4c83f2b..b6b5fcaa73c 100644
--- a/src/mame/drivers/dietgo.c
+++ b/src/mame/drivers/dietgo.c
@@ -208,7 +208,7 @@ static MACHINE_CONFIG_START( dietgo, dietgo_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2) /* DE102 (verified on pcb) */
MCFG_CPU_PROGRAM_MAP(dietgo_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dietgo_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/4/3) /* Custom chip 45; XIN is 32.220MHZ/4, verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/discoboy.c b/src/mame/drivers/discoboy.c
index 53019051e0f..30c9c1b5134 100644
--- a/src/mame/drivers/discoboy.c
+++ b/src/mame/drivers/discoboy.c
@@ -498,11 +498,11 @@ static MACHINE_CONFIG_START( discoboy, discoboy_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6 MHz? */
MCFG_CPU_PROGRAM_MAP(discoboy_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", discoboy_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,10000000/2) /* 5 MHz? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse,32*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(discoboy_state, nmi_line_pulse, 32*60)
/* video hardware */
diff --git a/src/mame/drivers/diverboy.c b/src/mame/drivers/diverboy.c
index 372380f5e1f..771f7c5d129 100644
--- a/src/mame/drivers/diverboy.c
+++ b/src/mame/drivers/diverboy.c
@@ -257,7 +257,7 @@ static MACHINE_CONFIG_START( diverboy, diverboy_state )
MCFG_CPU_ADD("maincpu", M68000, 12000000) /* guess */
MCFG_CPU_PROGRAM_MAP(diverboy_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", diverboy_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(snd_map)
diff --git a/src/mame/drivers/djboy.c b/src/mame/drivers/djboy.c
index 80bb595b6fd..ede34e453b7 100644
--- a/src/mame/drivers/djboy.c
+++ b/src/mame/drivers/djboy.c
@@ -577,12 +577,12 @@ static MACHINE_CONFIG_START( djboy, djboy_state )
MCFG_CPU_ADD("cpu1", Z80, 6000000)
MCFG_CPU_PROGRAM_MAP(cpu1_am)
MCFG_CPU_IO_MAP(cpu1_port_am)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", djboy_state, irq0_line_hold)
MCFG_CPU_ADD("cpu2", Z80, 6000000)
MCFG_CPU_PROGRAM_MAP(cpu2_am)
MCFG_CPU_IO_MAP(cpu2_port_am)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", djboy_state, irq0_line_hold)
MCFG_CPU_ADD("beast", I80C51, 6000000)
MCFG_CPU_IO_MAP(djboy_mcu_io_map)
diff --git a/src/mame/drivers/djmain.c b/src/mame/drivers/djmain.c
index 78f646b546a..c802605a090 100644
--- a/src/mame/drivers/djmain.c
+++ b/src/mame/drivers/djmain.c
@@ -74,7 +74,7 @@ hard drive 3.5 adapter long 3.5 IDE cable 3.5 adapter PCB
-#define DISABLE_VB_INT (!(state->m_v_ctrl & 0x8000))
+#define DISABLE_VB_INT (!(m_v_ctrl & 0x8000))
@@ -396,19 +396,18 @@ WRITE32_MEMBER(djmain_state::unknownc02000_w)
*
*************************************/
-static INTERRUPT_GEN( vb_interrupt )
+INTERRUPT_GEN_MEMBER(djmain_state::vb_interrupt)
{
- djmain_state *state = device->machine().driver_data<djmain_state>();
- state->m_pending_vb_int = 0;
+ m_pending_vb_int = 0;
if (DISABLE_VB_INT)
{
- state->m_pending_vb_int = 1;
+ m_pending_vb_int = 1;
return;
}
//logerror("V-Blank interrupt\n");
- device->execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
+ device.execute().set_input_line(M68K_IRQ_4, HOLD_LINE);
}
@@ -1460,7 +1459,7 @@ static MACHINE_CONFIG_START( djmain, djmain_state )
//MCFG_CPU_ADD("maincpu", M68EC020, 18432000/2) /* 9.216 MHz!? */
MCFG_CPU_ADD("maincpu", M68EC020, 32000000/4) /* 8.000 MHz!? */
MCFG_CPU_PROGRAM_MAP(memory_map)
- MCFG_CPU_VBLANK_INT("screen", vb_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", djmain_state, vb_interrupt)
MCFG_IDE_CONTROLLER_ADD("ide", ide_intf, ide_devices, "hdd", NULL, true)
diff --git a/src/mame/drivers/dkong.c b/src/mame/drivers/dkong.c
index b6042d6f12b..01023ed37b7 100644
--- a/src/mame/drivers/dkong.c
+++ b/src/mame/drivers/dkong.c
@@ -389,9 +389,9 @@ static I8257_INTERFACE( hb_dma )
*
*************************************/
-static INTERRUPT_GEN( s2650_interrupt )
+INTERRUPT_GEN_MEMBER(dkong_state::s2650_interrupt)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
}
/*************************************
@@ -1638,12 +1638,11 @@ static void braze_decrypt_rom(running_machine &machine, UINT8 *dest)
*
*************************************/
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(dkong_state::vblank_irq)
{
- dkong_state *state = device->machine().driver_data<dkong_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( dkong_base, dkong_state )
@@ -1651,7 +1650,7 @@ static MACHINE_CONFIG_START( dkong_base, dkong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, CLOCK_1H)
MCFG_CPU_PROGRAM_MAP(dkong_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, vblank_irq)
MCFG_MACHINE_START_OVERRIDE(dkong_state,dkong2b)
MCFG_MACHINE_RESET_OVERRIDE(dkong_state,dkong)
@@ -1715,7 +1714,7 @@ static MACHINE_CONFIG_START( dkong3, dkong_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_8MHz / 2) /* verified in schematics */
MCFG_CPU_PROGRAM_MAP(dkong3_map)
MCFG_CPU_IO_MAP(dkong3_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, vblank_irq)
MCFG_MACHINE_START_OVERRIDE(dkong_state,dkong3)
@@ -1774,7 +1773,7 @@ static MACHINE_CONFIG_DERIVED( s2650, dkong2b )
MCFG_CPU_REPLACE("maincpu", S2650, CLOCK_1H / 2) /* ??? */
MCFG_CPU_PROGRAM_MAP(s2650_map)
MCFG_CPU_IO_MAP(s2650_io_map)
- MCFG_CPU_VBLANK_INT("screen", s2650_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dkong_state, s2650_interrupt)
MCFG_DEVICE_MODIFY("dma8257")
MCFG_DEVICE_CONFIG(hb_dma)
diff --git a/src/mame/drivers/dlair.c b/src/mame/drivers/dlair.c
index c99f3ffa7cb..2499adb6927 100644
--- a/src/mame/drivers/dlair.c
+++ b/src/mame/drivers/dlair.c
@@ -114,6 +114,7 @@ public:
DECLARE_MACHINE_RESET(dlair);
DECLARE_PALETTE_INIT(dleuro);
UINT32 screen_update_dleuro(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_callback);
};
@@ -277,13 +278,13 @@ MACHINE_RESET_MEMBER(dlair_state,dlair)
*
*************************************/
-static INTERRUPT_GEN( vblank_callback )
+INTERRUPT_GEN_MEMBER(dlair_state::vblank_callback)
{
/* also update the speaker on the European version */
- beep_device *beep = device->machine().device<beep_device>("beep");
+ beep_device *beep = machine().device<beep_device>("beep");
if (beep != NULL)
{
- z80ctc_device *ctc = device->machine().device<z80ctc_device>("ctc");
+ z80ctc_device *ctc = machine().device<z80ctc_device>("ctc");
beep_set_state(beep, 1);
beep_set_frequency(beep, ATTOSECONDS_TO_HZ(ctc->period(0).attoseconds));
}
@@ -723,8 +724,8 @@ static MACHINE_CONFIG_START( dlair_base, dlair_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK_US/4)
MCFG_CPU_PROGRAM_MAP(dlus_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_callback)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)MASTER_CLOCK_US/8/16/16/16/16)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dlair_state, vblank_callback)
+ MCFG_CPU_PERIODIC_INT_DRIVER(dlair_state, irq0_line_hold, (double)MASTER_CLOCK_US/8/16/16/16/16)
MCFG_MACHINE_START_OVERRIDE(dlair_state,dlair)
MCFG_MACHINE_RESET_OVERRIDE(dlair_state,dlair)
@@ -761,7 +762,7 @@ static MACHINE_CONFIG_START( dleuro, dlair_state )
MCFG_CPU_CONFIG(dleuro_daisy_chain)
MCFG_CPU_PROGRAM_MAP(dleuro_map)
MCFG_CPU_IO_MAP(dleuro_io_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_callback)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dlair_state, vblank_callback)
MCFG_Z80CTC_ADD("ctc", MASTER_CLOCK_EURO/4 /* same as "maincpu" */, ctc_intf)
MCFG_Z80SIO_ADD("sio", MASTER_CLOCK_EURO/4 /* same as "maincpu" */, sio_intf)
diff --git a/src/mame/drivers/dmndrby.c b/src/mame/drivers/dmndrby.c
index e9da0f5852b..76a1cd8273a 100644
--- a/src/mame/drivers/dmndrby.c
+++ b/src/mame/drivers/dmndrby.c
@@ -81,6 +81,8 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_dderby(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(dderby_irq);
+ INTERRUPT_GEN_MEMBER(dderby_timer_irq);
};
@@ -498,22 +500,22 @@ void dmndrby_state::palette_init()
}
/*Main Z80 is IM 0,HW-latched irqs. */
-static INTERRUPT_GEN( dderby_irq )
+INTERRUPT_GEN_MEMBER(dmndrby_state::dderby_irq)
{
- device->machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
+ machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xd7); /* RST 10h */
}
-static INTERRUPT_GEN( dderby_timer_irq )
+INTERRUPT_GEN_MEMBER(dmndrby_state::dderby_timer_irq)
{
- device->machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf); /* RST 08h */
+ machine().device("maincpu")->execute().set_input_line_and_vector(0, HOLD_LINE, 0xcf); /* RST 08h */
}
static MACHINE_CONFIG_START( dderby, dmndrby_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,4000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(memmap)
- MCFG_CPU_VBLANK_INT("screen", dderby_irq)
- MCFG_CPU_PERIODIC_INT(dderby_timer_irq, 244/2)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dmndrby_state, dderby_irq)
+ MCFG_CPU_PERIODIC_INT_DRIVER(dmndrby_state, dderby_timer_irq, 244/2)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* verified on schematics */
MCFG_CPU_PROGRAM_MAP(dderby_sound_map)
diff --git a/src/mame/drivers/docastle.c b/src/mame/drivers/docastle.c
index ff69b5d7460..96d72bfbc58 100644
--- a/src/mame/drivers/docastle.c
+++ b/src/mame/drivers/docastle.c
@@ -604,15 +604,15 @@ static MACHINE_CONFIG_START( docastle, docastle_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_4MHz)
MCFG_CPU_PROGRAM_MAP(docastle_map)
MCFG_CPU_IO_MAP(docastle_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", docastle_state, irq0_line_hold)
MCFG_CPU_ADD("slave", Z80, XTAL_4MHz)
MCFG_CPU_PROGRAM_MAP(docastle_map2)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 8*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(docastle_state, irq0_line_hold, 8*60)
MCFG_CPU_ADD("cpu3", Z80, XTAL_4MHz)
MCFG_CPU_PROGRAM_MAP(docastle_map3)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", docastle_state, nmi_line_pulse)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/dogfgt.c b/src/mame/drivers/dogfgt.c
index 729168fd2f4..c616af2a460 100644
--- a/src/mame/drivers/dogfgt.c
+++ b/src/mame/drivers/dogfgt.c
@@ -242,7 +242,7 @@ static MACHINE_CONFIG_START( dogfgt, dogfgt_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, 1500000) /* 1.5 MHz ???? */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,16*60) /* ? controls music tempo */
+ MCFG_CPU_PERIODIC_INT_DRIVER(dogfgt_state, irq0_line_hold, 16*60) /* ? controls music tempo */
MCFG_CPU_ADD("sub", M6502, 1500000) /* 1.5 MHz ???? */
MCFG_CPU_PROGRAM_MAP(sub_map)
diff --git a/src/mame/drivers/dominob.c b/src/mame/drivers/dominob.c
index d840eaa2545..34186cad893 100644
--- a/src/mame/drivers/dominob.c
+++ b/src/mame/drivers/dominob.c
@@ -299,7 +299,7 @@ static MACHINE_CONFIG_START( dominob, dominob_state )
MCFG_CPU_ADD("maincpu", Z80,XTAL_12MHz/2)
MCFG_CPU_PROGRAM_MAP(memmap)
MCFG_CPU_IO_MAP(portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dominob_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/dooyong.c b/src/mame/drivers/dooyong.c
index 3a1700401f1..2a522ad2345 100644
--- a/src/mame/drivers/dooyong.c
+++ b/src/mame/drivers/dooyong.c
@@ -865,7 +865,7 @@ static MACHINE_CONFIG_START( lastday, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(lastday_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(lastday_sound_map)
@@ -908,7 +908,7 @@ static MACHINE_CONFIG_START( gulfstrm, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(gulfstrm_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(lastday_sound_map)
@@ -941,7 +941,7 @@ static MACHINE_CONFIG_START( pollux, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(pollux_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(pollux_sound_map)
@@ -974,7 +974,7 @@ static MACHINE_CONFIG_START( bluehawk, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(bluehawk_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
@@ -1006,7 +1006,7 @@ static MACHINE_CONFIG_START( flytiger, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(flytiger_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
@@ -1038,7 +1038,7 @@ static MACHINE_CONFIG_START( primella, dooyong_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, 8000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(primella_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dooyong_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* ??? */
MCFG_CPU_PROGRAM_MAP(bluehawk_sound_map)
diff --git a/src/mame/drivers/dorachan.c b/src/mame/drivers/dorachan.c
index cee73b77946..774bb48b9ec 100644
--- a/src/mame/drivers/dorachan.c
+++ b/src/mame/drivers/dorachan.c
@@ -243,7 +243,7 @@ static MACHINE_CONFIG_START( dorachan, dorachan_state )
MCFG_CPU_ADD("maincpu", Z80, 2000000)
MCFG_CPU_PROGRAM_MAP(dorachan_map)
MCFG_CPU_IO_MAP(dorachan_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(dorachan_state, irq0_line_hold, 2*60)
/* video hardware */
diff --git a/src/mame/drivers/dotrikun.c b/src/mame/drivers/dotrikun.c
index 7e4bd3ffdcf..4bd41e3efac 100644
--- a/src/mame/drivers/dotrikun.c
+++ b/src/mame/drivers/dotrikun.c
@@ -155,7 +155,7 @@ static MACHINE_CONFIG_START( dotrikun, dotrikun_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(dotrikun_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dotrikun_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/dragrace.c b/src/mame/drivers/dragrace.c
index 1fe7413dc36..a6c06e21aa9 100644
--- a/src/mame/drivers/dragrace.c
+++ b/src/mame/drivers/dragrace.c
@@ -332,7 +332,7 @@ static MACHINE_CONFIG_START( dragrace, dragrace_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6800, XTAL_12_096MHz / 12)
MCFG_CPU_PROGRAM_MAP(dragrace_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(dragrace_state, irq0_line_hold, 4*60)
MCFG_WATCHDOG_VBLANK_INIT(8)
diff --git a/src/mame/drivers/dreamwld.c b/src/mame/drivers/dreamwld.c
index 2aa5016002c..fc0f33098c9 100644
--- a/src/mame/drivers/dreamwld.c
+++ b/src/mame/drivers/dreamwld.c
@@ -589,7 +589,7 @@ static MACHINE_CONFIG_START( baryon, dreamwld_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68EC020, MASTER_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(baryon_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold )
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dreamwld_state, irq4_line_hold)
/* video hardware */
@@ -617,7 +617,7 @@ static MACHINE_CONFIG_DERIVED( dreamwld, baryon )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(dreamwld_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dreamwld_state, irq4_line_hold)
MCFG_OKIM6295_ADD("oki2", MASTER_CLOCK/32, OKIM6295_PIN7_LOW)
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.50)
diff --git a/src/mame/drivers/drgnmst.c b/src/mame/drivers/drgnmst.c
index a866ba0021c..8244106901b 100644
--- a/src/mame/drivers/drgnmst.c
+++ b/src/mame/drivers/drgnmst.c
@@ -397,7 +397,7 @@ static MACHINE_CONFIG_START( drgnmst, drgnmst_state )
MCFG_CPU_ADD("maincpu", M68000, 12000000) /* Confirmed */
MCFG_CPU_PROGRAM_MAP(drgnmst_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", drgnmst_state, irq2_line_hold)
MCFG_CPU_ADD("audiocpu", PIC16C55, 32000000/8) /* Confirmed */
/* Program and Data Maps are internal to the MCU */
diff --git a/src/mame/drivers/dribling.c b/src/mame/drivers/dribling.c
index 85963f36b8c..544a5dbd705 100644
--- a/src/mame/drivers/dribling.c
+++ b/src/mame/drivers/dribling.c
@@ -38,11 +38,10 @@
*
*************************************/
-static INTERRUPT_GEN( dribling_irq_gen )
+INTERRUPT_GEN_MEMBER(dribling_state::dribling_irq_gen)
{
- dribling_state *state = device->machine().driver_data<dribling_state>();
- if (state->m_di)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if (m_di)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
@@ -305,7 +304,7 @@ static MACHINE_CONFIG_START( dribling, dribling_state )
MCFG_CPU_ADD("maincpu", Z80, 5000000)
MCFG_CPU_PROGRAM_MAP(dribling_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", dribling_irq_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dribling_state, dribling_irq_gen)
MCFG_I8255A_ADD( "ppi8255_0", ppi8255_0_intf )
MCFG_I8255A_ADD( "ppi8255_1", ppi8255_1_intf )
diff --git a/src/mame/drivers/drmicro.c b/src/mame/drivers/drmicro.c
index fe53f04931b..e04447e2cdb 100644
--- a/src/mame/drivers/drmicro.c
+++ b/src/mame/drivers/drmicro.c
@@ -23,12 +23,11 @@ Quite similar to Appoooh
*
*************************************/
-static INTERRUPT_GEN( drmicro_interrupt )
+INTERRUPT_GEN_MEMBER(drmicro_state::drmicro_interrupt)
{
- drmicro_state *state = device->machine().driver_data<drmicro_state>();
- if (state->m_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
WRITE8_MEMBER(drmicro_state::nmi_enable_w)
@@ -263,7 +262,7 @@ static MACHINE_CONFIG_START( drmicro, drmicro_state )
MCFG_CPU_ADD("maincpu", Z80,MCLK/6) /* 3.072MHz? */
MCFG_CPU_PROGRAM_MAP(drmicro_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", drmicro_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", drmicro_state, drmicro_interrupt)
MCFG_QUANTUM_TIME(attotime::from_hz(60))
diff --git a/src/mame/drivers/drtomy.c b/src/mame/drivers/drtomy.c
index 4e6e54000a7..bb30862ba75 100644
--- a/src/mame/drivers/drtomy.c
+++ b/src/mame/drivers/drtomy.c
@@ -300,7 +300,7 @@ static MACHINE_CONFIG_START( drtomy, drtomy_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,24000000/2) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(drtomy_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", drtomy_state, irq6_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/drw80pkr.c b/src/mame/drivers/drw80pkr.c
index 20e0a85a665..bc229a3bb13 100644
--- a/src/mame/drivers/drw80pkr.c
+++ b/src/mame/drivers/drw80pkr.c
@@ -467,7 +467,7 @@ static MACHINE_CONFIG_START( drw80pkr, drw80pkr_state )
MCFG_CPU_ADD("maincpu", I8039, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(drw80pkr_map)
MCFG_CPU_IO_MAP(drw80pkr_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", drw80pkr_state, irq0_line_hold)
// video hardware
diff --git a/src/mame/drivers/dunhuang.c b/src/mame/drivers/dunhuang.c
index c1a4cfa6c95..5c385f99ec0 100644
--- a/src/mame/drivers/dunhuang.c
+++ b/src/mame/drivers/dunhuang.c
@@ -819,7 +819,7 @@ static MACHINE_CONFIG_START( dunhuang, dunhuang_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/2)
MCFG_CPU_PROGRAM_MAP(dunhuang_map)
MCFG_CPU_IO_MAP(dunhuang_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dunhuang_state, irq0_line_hold)
MCFG_WATCHDOG_TIME_INIT(attotime::from_seconds(5))
diff --git a/src/mame/drivers/dynax.c b/src/mame/drivers/dynax.c
index dda1ca86c4a..4c664b96d81 100644
--- a/src/mame/drivers/dynax.c
+++ b/src/mame/drivers/dynax.c
@@ -117,11 +117,10 @@ WRITE8_MEMBER(dynax_state::dynax_blitter_ack_w)
sprtmtch_update_irq(machine());
}
-static INTERRUPT_GEN( sprtmtch_vblank_interrupt )
+INTERRUPT_GEN_MEMBER(dynax_state::sprtmtch_vblank_interrupt)
{
- dynax_state *state = device->machine().driver_data<dynax_state>();
- state->m_vblank_irq = 1;
- sprtmtch_update_irq(device->machine());
+ m_vblank_irq = 1;
+ sprtmtch_update_irq(machine());
}
static void sprtmtch_sound_callback( device_t *device, int state )
@@ -162,11 +161,10 @@ WRITE8_MEMBER(dynax_state::jantouki_blitter2_ack_w)
jantouki_update_irq(machine());
}
-static INTERRUPT_GEN( jantouki_vblank_interrupt )
+INTERRUPT_GEN_MEMBER(dynax_state::jantouki_vblank_interrupt)
{
- dynax_state *state = device->machine().driver_data<dynax_state>();
- state->m_vblank_irq = 1;
- jantouki_update_irq(device->machine());
+ m_vblank_irq = 1;
+ jantouki_update_irq(machine());
}
@@ -181,11 +179,10 @@ static void jantouki_sound_update_irq(running_machine &machine)
state->m_soundcpu->set_input_line_and_vector(0, irq ? ASSERT_LINE : CLEAR_LINE, 0xc7 | irq); /* rst $xx */
}
-static INTERRUPT_GEN( jantouki_sound_vblank_interrupt )
+INTERRUPT_GEN_MEMBER(dynax_state::jantouki_sound_vblank_interrupt)
{
- dynax_state *state = device->machine().driver_data<dynax_state>();
- state->m_sound_vblank_irq = 1;
- jantouki_sound_update_irq(device->machine());
+ m_sound_vblank_irq = 1;
+ jantouki_sound_update_irq(machine());
}
WRITE8_MEMBER(dynax_state::jantouki_sound_vblank_ack_w)
@@ -4288,7 +4285,7 @@ static MACHINE_CONFIG_START( hanamai, dynax_state )
MCFG_CPU_ADD("maincpu",Z80,22000000 / 4) /* 5.5MHz */
MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
MCFG_CPU_IO_MAP(hanamai_io_map)
- MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4345,7 +4342,7 @@ static MACHINE_CONFIG_START( hnoridur, dynax_state )
MCFG_CPU_ADD("maincpu",Z80,22000000 / 4) /* 5.5MHz */
MCFG_CPU_PROGRAM_MAP(hnoridur_mem_map)
MCFG_CPU_IO_MAP(hnoridur_io_map)
- MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_MACHINE_START_OVERRIDE(dynax_state,hnoridur)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4390,7 +4387,7 @@ static MACHINE_CONFIG_START( hjingi, dynax_state )
MCFG_CPU_ADD("maincpu",Z80, XTAL_22MHz / 4)
MCFG_CPU_PROGRAM_MAP(hjingi_mem_map)
MCFG_CPU_IO_MAP(hjingi_io_map)
- MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_MACHINE_START_OVERRIDE(dynax_state,hnoridur)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4448,7 +4445,7 @@ static MACHINE_CONFIG_START( sprtmtch, dynax_state )
MCFG_CPU_ADD("maincpu", Z80,22000000 / 4) /* 5.5MHz */
MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
MCFG_CPU_IO_MAP(sprtmtch_io_map)
- MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4490,7 +4487,7 @@ static MACHINE_CONFIG_START( mjfriday, dynax_state )
MCFG_CPU_ADD("maincpu",Z80,24000000/4) /* 6 MHz? */
MCFG_CPU_PROGRAM_MAP(sprtmtch_mem_map)
MCFG_CPU_IO_MAP(mjfriday_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(dynax_state,hanamai)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4538,17 +4535,16 @@ MACHINE_CONFIG_END
what was it trying to do?
set an irq and clear it before its even taken? */
-static INTERRUPT_GEN( yarunara_clock_interrupt )
+INTERRUPT_GEN_MEMBER(dynax_state::yarunara_clock_interrupt)
{
- dynax_state *state = device->machine().driver_data<dynax_state>();
- state->m_yarunara_clk_toggle ^= 1;
+ m_yarunara_clk_toggle ^= 1;
- if (state->m_yarunara_clk_toggle == 1)
- state->m_sound_irq = 0;
+ if (m_yarunara_clk_toggle == 1)
+ m_sound_irq = 0;
else
- state->m_sound_irq = 1;
+ m_sound_irq = 1;
- sprtmtch_update_irq(device->machine());
+ sprtmtch_update_irq(machine());
}
static MSM6242_INTERFACE( yarunara_rtc_intf )
@@ -4562,7 +4558,7 @@ static MACHINE_CONFIG_DERIVED( yarunara, hnoridur )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(yarunara_mem_map)
MCFG_CPU_IO_MAP(yarunara_io_map)
- MCFG_CPU_PERIODIC_INT(yarunara_clock_interrupt, 60) // RTC
+ MCFG_CPU_PERIODIC_INT_DRIVER(dynax_state, yarunara_clock_interrupt, 60) // RTC
MCFG_NVRAM_REPLACE_0FILL("nvram")
@@ -4646,12 +4642,12 @@ static MACHINE_CONFIG_START( jantouki, dynax_state )
MCFG_CPU_ADD("maincpu",Z80,22000000 / 4) /* 5.5MHz */
MCFG_CPU_PROGRAM_MAP(jantouki_mem_map)
MCFG_CPU_IO_MAP(jantouki_io_map)
- MCFG_CPU_VBLANK_INT("top", jantouki_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("top", dynax_state, jantouki_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_CPU_ADD("soundcpu",Z80,22000000 / 4) /* 5.5MHz */
MCFG_CPU_PROGRAM_MAP(jantouki_sound_mem_map)
MCFG_CPU_IO_MAP(jantouki_sound_io_map)
- MCFG_CPU_VBLANK_INT("top", jantouki_sound_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("top", dynax_state, jantouki_sound_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
MCFG_MACHINE_START_OVERRIDE(dynax_state,jantouki)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4715,21 +4711,20 @@ void mjelctrn_update_irq( running_machine &machine )
state->m_maincpu->set_input_line_and_vector(0, HOLD_LINE, 0xfa);
}
-static INTERRUPT_GEN( mjelctrn_vblank_interrupt )
+INTERRUPT_GEN_MEMBER(dynax_state::mjelctrn_vblank_interrupt)
{
- dynax_state *state = device->machine().driver_data<dynax_state>();
// This is a kludge to avoid losing blitter interrupts
// there should be a vblank ack mechanism
- if (!state->m_blitter_irq)
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xf8);
+ if (!m_blitter_irq)
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xf8);
}
static MACHINE_CONFIG_DERIVED( mjelctrn, hnoridur )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(nanajign_mem_map)
MCFG_CPU_IO_MAP(mjelctrn_io_map)
- MCFG_CPU_VBLANK_INT("screen", mjelctrn_vblank_interrupt) /* IM 2 needs a vector on the data bus */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, mjelctrn_vblank_interrupt) /* IM 2 needs a vector on the data bus */
MCFG_VIDEO_START_OVERRIDE(dynax_state,mjelctrn)
MACHINE_CONFIG_END
@@ -4826,8 +4821,8 @@ static MACHINE_CONFIG_START( htengoku, dynax_state )
MCFG_CPU_ADD("maincpu",Z80,20000000 / 4)
MCFG_CPU_PROGRAM_MAP(yarunara_mem_map)
MCFG_CPU_IO_MAP(htengoku_io_map)
- MCFG_CPU_VBLANK_INT("screen", sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
- MCFG_CPU_PERIODIC_INT(yarunara_clock_interrupt, 60) // RTC
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, sprtmtch_vblank_interrupt) /* IM 0 needs an opcode on the data bus */
+ MCFG_CPU_PERIODIC_INT_DRIVER(dynax_state, yarunara_clock_interrupt, 60) // RTC
MCFG_MACHINE_START_OVERRIDE(dynax_state,htengoku)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,dynax)
@@ -4979,7 +4974,7 @@ static MACHINE_CONFIG_START( gekisha, dynax_state )
MCFG_CPU_ADD("maincpu",TMP90841, XTAL_10MHz ) // ?
MCFG_CPU_PROGRAM_MAP(gekisha_map)
MCFG_CPU_IO_MAP(gekisha_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynax_state, irq0_line_hold)
MCFG_MACHINE_START_OVERRIDE(dynax_state,gekisha)
MCFG_MACHINE_RESET_OVERRIDE(dynax_state,gekisha)
diff --git a/src/mame/drivers/dynduke.c b/src/mame/drivers/dynduke.c
index f9e7f9c27a2..1d4b0b85173 100644
--- a/src/mame/drivers/dynduke.c
+++ b/src/mame/drivers/dynduke.c
@@ -263,9 +263,9 @@ GFXDECODE_END
/* Interrupt Generator */
-static INTERRUPT_GEN( dynduke_interrupt )
+INTERRUPT_GEN_MEMBER(dynduke_state::dynduke_interrupt)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4); // VBL
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0xc8/4); // VBL
}
/* Machine Driver */
@@ -274,11 +274,11 @@ static MACHINE_CONFIG_START( dynduke, dynduke_state )
// basic machine hardware
MCFG_CPU_ADD("maincpu", V30, 16000000/2) // NEC V30-8 CPU
MCFG_CPU_PROGRAM_MAP(master_map)
- MCFG_CPU_VBLANK_INT("screen", dynduke_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynduke_state, dynduke_interrupt)
MCFG_CPU_ADD("slave", V30, 16000000/2) // NEC V30-8 CPU
MCFG_CPU_PROGRAM_MAP(slave_map)
- MCFG_CPU_VBLANK_INT("screen", dynduke_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", dynduke_state, dynduke_interrupt)
SEIBU_SOUND_SYSTEM_CPU(14318180/4)
diff --git a/src/mame/drivers/egghunt.c b/src/mame/drivers/egghunt.c
index 6d7801658e4..c83c005f315 100644
--- a/src/mame/drivers/egghunt.c
+++ b/src/mame/drivers/egghunt.c
@@ -412,7 +412,7 @@ static MACHINE_CONFIG_START( egghunt, egghunt_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6 MHz ?*/
MCFG_CPU_PROGRAM_MAP(egghunt_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) // or 2 like mitchell.c?
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", egghunt_state, irq0_line_hold) // or 2 like mitchell.c?
MCFG_CPU_ADD("audiocpu", Z80,12000000/2) /* 6 MHz ?*/
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/enigma2.c b/src/mame/drivers/enigma2.c
index 13572a19bbc..07b07cb2db1 100644
--- a/src/mame/drivers/enigma2.c
+++ b/src/mame/drivers/enigma2.c
@@ -611,7 +611,7 @@ static MACHINE_CONFIG_START( enigma2, enigma2_state )
MCFG_CPU_ADD("audiocpu", Z80, 2500000)
MCFG_CPU_PROGRAM_MAP(engima2_audio_cpu_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*52)
+ MCFG_CPU_PERIODIC_INT_DRIVER(enigma2_state, irq0_line_hold, 8*52)
/* video hardware */
@@ -637,7 +637,7 @@ static MACHINE_CONFIG_START( enigma2a, enigma2_state )
MCFG_CPU_ADD("audiocpu", Z80, 2500000)
MCFG_CPU_PROGRAM_MAP(engima2_audio_cpu_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,8*52)
+ MCFG_CPU_PERIODIC_INT_DRIVER(enigma2_state, irq0_line_hold, 8*52)
/* video hardware */
diff --git a/src/mame/drivers/epos.c b/src/mame/drivers/epos.c
index 428556737f8..5a7cdfdba4f 100644
--- a/src/mame/drivers/epos.c
+++ b/src/mame/drivers/epos.c
@@ -398,7 +398,7 @@ static MACHINE_CONFIG_START( epos, epos_state )
MCFG_CPU_ADD("maincpu", Z80, 11000000/4) /* 2.75 MHz (see notes) */
MCFG_CPU_PROGRAM_MAP(epos_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", epos_state, irq0_line_hold)
/* video hardware */
@@ -422,7 +422,7 @@ static MACHINE_CONFIG_START( dealer, epos_state )
MCFG_CPU_ADD("maincpu", Z80, 11000000/4) /* 2.75 MHz (see notes) */
MCFG_CPU_PROGRAM_MAP(dealer_map)
MCFG_CPU_IO_MAP(dealer_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", epos_state, irq0_line_hold)
MCFG_I8255A_ADD( "ppi8255", ppi8255_intf )
diff --git a/src/mame/drivers/ertictac.c b/src/mame/drivers/ertictac.c
index 3dae19301ee..09cec2c2af6 100644
--- a/src/mame/drivers/ertictac.c
+++ b/src/mame/drivers/ertictac.c
@@ -38,6 +38,7 @@ public:
DECLARE_DRIVER_INIT(ertictac);
virtual void machine_start();
virtual void machine_reset();
+ INTERRUPT_GEN_MEMBER(ertictac_podule_irq);
};
@@ -208,9 +209,9 @@ void ertictac_state::machine_reset()
archimedes_reset(machine());
}
-static INTERRUPT_GEN( ertictac_podule_irq )
+INTERRUPT_GEN_MEMBER(ertictac_state::ertictac_podule_irq)
{
- archimedes_request_irq_b(device->machine(), ARCHIMEDES_IRQB_PODULE_IRQ);
+ archimedes_request_irq_b(machine(), ARCHIMEDES_IRQB_PODULE_IRQ);
}
/* TODO: Are we sure that this HW have I2C device? */
@@ -226,7 +227,7 @@ static MACHINE_CONFIG_START( ertictac, ertictac_state )
MCFG_CPU_ADD("maincpu", ARM, XTAL_24MHz/3) /* guess, 12MHz 8MHz or 6MHz, what's the correct divider 2, 3 or 4? */
MCFG_CPU_PROGRAM_MAP(ertictac_map)
- MCFG_CPU_PERIODIC_INT(ertictac_podule_irq,60) // FIXME: timing of this
+ MCFG_CPU_PERIODIC_INT_DRIVER(ertictac_state, ertictac_podule_irq, 60) // FIXME: timing of this
MCFG_I2CMEM_ADD("i2cmem",i2cmem_interface)
diff --git a/src/mame/drivers/esd16.c b/src/mame/drivers/esd16.c
index 76075fc2221..fd2ef836dc7 100644
--- a/src/mame/drivers/esd16.c
+++ b/src/mame/drivers/esd16.c
@@ -616,12 +616,12 @@ static MACHINE_CONFIG_START( esd16, esd16_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000, XTAL_16MHz) /* 16MHz */
MCFG_CPU_PROGRAM_MAP(multchmp_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", esd16_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_16MHz/4) /* 4MHz */
MCFG_CPU_PROGRAM_MAP(multchmp_sound_map)
MCFG_CPU_IO_MAP(multchmp_sound_io_map)
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse,32*60) /* IRQ By Main CPU */
+ MCFG_CPU_PERIODIC_INT_DRIVER(esd16_state, nmi_line_pulse, 32*60) /* IRQ By Main CPU */
/* video hardware */
diff --git a/src/mame/drivers/esh.c b/src/mame/drivers/esh.c
index fe9d1b782bf..e1b7cc45338 100644
--- a/src/mame/drivers/esh.c
+++ b/src/mame/drivers/esh.c
@@ -50,6 +50,7 @@ public:
virtual void machine_start();
virtual void palette_init();
UINT32 screen_update_esh(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_callback_esh);
};
@@ -283,11 +284,11 @@ static TIMER_CALLBACK( irq_stop )
machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
}
-static INTERRUPT_GEN( vblank_callback_esh )
+INTERRUPT_GEN_MEMBER(esh_state::vblank_callback_esh)
{
// IRQ
- device->execute().set_input_line(0, ASSERT_LINE);
- device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq_stop));
+ device.execute().set_input_line(0, ASSERT_LINE);
+ machine().scheduler().timer_set(attotime::from_usec(50), FUNC(irq_stop));
}
void esh_state::machine_start()
@@ -302,7 +303,7 @@ static MACHINE_CONFIG_START( esh, esh_state )
MCFG_CPU_ADD("maincpu", Z80, PCB_CLOCK/6) /* The denominator is a Daphne guess based on PacMan's hardware */
MCFG_CPU_PROGRAM_MAP(z80_0_mem)
MCFG_CPU_IO_MAP(z80_0_io)
- MCFG_CPU_VBLANK_INT("screen", vblank_callback_esh)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", esh_state, vblank_callback_esh)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/espial.c b/src/mame/drivers/espial.c
index 4b4d514b284..c94922951ce 100644
--- a/src/mame/drivers/espial.c
+++ b/src/mame/drivers/espial.c
@@ -88,11 +88,10 @@ static TIMER_DEVICE_CALLBACK( espial_scanline )
}
-INTERRUPT_GEN( espial_sound_nmi_gen )
+INTERRUPT_GEN_MEMBER(espial_state::espial_sound_nmi_gen)
{
- espial_state *state = device->machine().driver_data<espial_state>();
- if (state->m_sound_nmi_enabled)
+ if (m_sound_nmi_enabled)
nmi_line_pulse(device);
}
@@ -328,7 +327,7 @@ static MACHINE_CONFIG_START( espial, espial_state )
MCFG_CPU_ADD("audiocpu", Z80, 3072000) /* 2 MHz?????? */
MCFG_CPU_PROGRAM_MAP(espial_sound_map)
MCFG_CPU_IO_MAP(espial_sound_io_map)
- MCFG_CPU_PERIODIC_INT(espial_sound_nmi_gen,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(espial_state, espial_sound_nmi_gen, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/esripsys.c b/src/mame/drivers/esripsys.c
index cbc19d2c6a9..cbb911da7e0 100644
--- a/src/mame/drivers/esripsys.c
+++ b/src/mame/drivers/esripsys.c
@@ -699,7 +699,7 @@ static const esrip_config rip_config =
static MACHINE_CONFIG_START( esripsys, esripsys_state )
MCFG_CPU_ADD("game_cpu", M6809E, XTAL_8MHz)
MCFG_CPU_PROGRAM_MAP(game_cpu_map)
- MCFG_CPU_VBLANK_INT("screen", esripsys_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", esripsys_state, esripsys_vblank_irq)
MCFG_CPU_ADD("frame_cpu", M6809E, XTAL_8MHz)
MCFG_CPU_PROGRAM_MAP(frame_cpu_map)
diff --git a/src/mame/drivers/ettrivia.c b/src/mame/drivers/ettrivia.c
index 8143a1b7f3c..835f02dc3d9 100644
--- a/src/mame/drivers/ettrivia.c
+++ b/src/mame/drivers/ettrivia.c
@@ -61,6 +61,7 @@ public:
virtual void video_start();
virtual void palette_init();
UINT32 screen_update_ettrivia(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(ettrivia_interrupt);
};
@@ -289,19 +290,19 @@ static const ay8910_interface ay8912_interface_3 =
};
-static INTERRUPT_GEN( ettrivia_interrupt )
+INTERRUPT_GEN_MEMBER(ettrivia_state::ettrivia_interrupt)
{
- if( device->machine().root_device().ioport("COIN")->read() & 0x01 )
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if( machine().root_device().ioport("COIN")->read() & 0x01 )
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
else
- device->execute().set_input_line(0, HOLD_LINE);
+ device.execute().set_input_line(0, HOLD_LINE);
}
static MACHINE_CONFIG_START( ettrivia, ettrivia_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/4-48000) //should be ok, it gives the 300 interrupts expected
MCFG_CPU_PROGRAM_MAP(cpu_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", ettrivia_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ettrivia_state, ettrivia_interrupt)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/exedexes.c b/src/mame/drivers/exedexes.c
index bd12cd744cc..57f552c78cf 100644
--- a/src/mame/drivers/exedexes.c
+++ b/src/mame/drivers/exedexes.c
@@ -232,7 +232,7 @@ static MACHINE_CONFIG_START( exedexes, exedexes_state )
MCFG_CPU_ADD("audiocpu", Z80, 3000000) /* 3 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(exedexes_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/exidy.c b/src/mame/drivers/exidy.c
index b0b9c514ce3..ef58bcfb3f4 100644
--- a/src/mame/drivers/exidy.c
+++ b/src/mame/drivers/exidy.c
@@ -806,7 +806,7 @@ static MACHINE_CONFIG_START( base, exidy_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, EXIDY_CPU_CLOCK)
- MCFG_CPU_VBLANK_INT("screen", exidy_vblank_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", exidy_state, exidy_vblank_interrupt)
/* video hardware */
MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
@@ -878,7 +878,7 @@ static MACHINE_CONFIG_DERIVED( teetert, venture )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
- MCFG_CPU_PERIODIC_INT(nmi_line_pulse,10*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(exidy_state, nmi_line_pulse, 10*60)
MCFG_MACHINE_START_OVERRIDE(exidy_state, teetert )
diff --git a/src/mame/drivers/exidy440.c b/src/mame/drivers/exidy440.c
index 2a763ba0a16..7b5acefed25 100644
--- a/src/mame/drivers/exidy440.c
+++ b/src/mame/drivers/exidy440.c
@@ -999,7 +999,7 @@ static MACHINE_CONFIG_START( exidy440, exidy440_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, MAIN_CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(exidy440_map)
- MCFG_CPU_VBLANK_INT("screen", exidy440_vblank_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", exidy440_state, exidy440_vblank_interrupt)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/exprraid.c b/src/mame/drivers/exprraid.c
index 242a87544ea..4b037f23d10 100644
--- a/src/mame/drivers/exprraid.c
+++ b/src/mame/drivers/exprraid.c
@@ -446,23 +446,22 @@ static const ym3526_interface ym3526_config =
};
#if 0
-static INTERRUPT_GEN( exprraid_interrupt )
+INTERRUPT_GEN_MEMBER(exprraid_state::exprraid_interrupt)
{
- exprraid_state *state = device->machine().driver_data<exprraid_state>();
- if ((~state->ioport("IN2")->read()) & 0xc0)
+ if ((~ioport("IN2")->read()) & 0xc0)
{
- if (state->m_coin == 0)
+ if (m_coin == 0)
{
- state->m_coin = 1;
- //device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
- device->execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
+ m_coin = 1;
+ //device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ device.execute().set_input_line(DECO16_IRQ_LINE, ASSERT_LINE);
}
}
else
{
- device->execute().set_input_line(DECO16_IRQ_LINE, CLEAR_LINE);
- state->m_coin = 0;
+ device.execute().set_input_line(DECO16_IRQ_LINE, CLEAR_LINE);
+ m_coin = 0;
}
}
#endif
diff --git a/src/mame/drivers/exzisus.c b/src/mame/drivers/exzisus.c
index 161624f96fe..271bc0c9843 100644
--- a/src/mame/drivers/exzisus.c
+++ b/src/mame/drivers/exzisus.c
@@ -274,15 +274,15 @@ static MACHINE_CONFIG_START( exzisus, exzisus_state )
/* basic machine hardware */
MCFG_CPU_ADD("cpua", Z80, 6000000)
MCFG_CPU_PROGRAM_MAP(cpua_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
MCFG_CPU_ADD("cpub", Z80, 6000000)
MCFG_CPU_PROGRAM_MAP(cpub_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
MCFG_CPU_ADD("cpuc", Z80, 6000000)
MCFG_CPU_PROGRAM_MAP(cpuc_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", exzisus_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/f-32.c b/src/mame/drivers/f-32.c
index f865958d397..7b5bd37c849 100644
--- a/src/mame/drivers/f-32.c
+++ b/src/mame/drivers/f-32.c
@@ -137,7 +137,7 @@ static MACHINE_CONFIG_START( mosaicf2, mosaicf2_state )
MCFG_CPU_ADD("maincpu", E132XN, 20000000*4) /* 4x internal multiplier */
MCFG_CPU_PROGRAM_MAP(common_map)
MCFG_CPU_IO_MAP(mosaicf2_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", mosaicf2_state, irq0_line_hold)
MCFG_EEPROM_93C46_ADD("eeprom")
diff --git a/src/mame/drivers/f1gp.c b/src/mame/drivers/f1gp.c
index 6a5e0a69bc8..94d4428ef39 100644
--- a/src/mame/drivers/f1gp.c
+++ b/src/mame/drivers/f1gp.c
@@ -451,11 +451,11 @@ static MACHINE_CONFIG_START( f1gp, f1gp_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(f1gp_cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
MCFG_CPU_ADD("sub", M68000,XTAL_20MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(f1gp_cpu2_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_20MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -497,11 +497,11 @@ static MACHINE_CONFIG_START( f1gpb, f1gp_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",M68000,10000000) /* 10 MHz ??? */
MCFG_CPU_PROGRAM_MAP(f1gpb_cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
MCFG_CPU_ADD("sub", M68000,10000000) /* 10 MHz ??? */
MCFG_CPU_PROGRAM_MAP(f1gpb_cpu2_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", f1gp_state, irq1_line_hold)
/* NO sound CPU */
MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* 100 CPU slices per frame */
diff --git a/src/mame/drivers/fantland.c b/src/mame/drivers/fantland.c
index 471a1edde6d..8083f4a840f 100644
--- a/src/mame/drivers/fantland.c
+++ b/src/mame/drivers/fantland.c
@@ -829,16 +829,15 @@ MACHINE_RESET_MEMBER(fantland_state,fantland)
m_nmi_enable = 0;
}
-static INTERRUPT_GEN( fantland_irq )
+INTERRUPT_GEN_MEMBER(fantland_state::fantland_irq)
{
- fantland_state *state = device->machine().driver_data<fantland_state>();
- if (state->m_nmi_enable & 8)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmi_enable & 8)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
-static INTERRUPT_GEN( fantland_sound_irq )
+INTERRUPT_GEN_MEMBER(fantland_state::fantland_sound_irq)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x80 / 4);
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x80 / 4);
}
static MACHINE_CONFIG_START( fantland, fantland_state )
@@ -846,12 +845,12 @@ static MACHINE_CONFIG_START( fantland, fantland_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", I8086, 8000000) // ?
MCFG_CPU_PROGRAM_MAP(fantland_map)
- MCFG_CPU_VBLANK_INT("screen", fantland_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
MCFG_CPU_ADD("audiocpu", I8088, 8000000) // ?
MCFG_CPU_PROGRAM_MAP(fantland_sound_map)
MCFG_CPU_IO_MAP(fantland_sound_iomap)
- MCFG_CPU_PERIODIC_INT(fantland_sound_irq, 8000)
+ MCFG_CPU_PERIODIC_INT_DRIVER(fantland_state, fantland_sound_irq, 8000)
// NMI when soundlatch is written
MCFG_MACHINE_START_OVERRIDE(fantland_state,fantland)
@@ -899,7 +898,7 @@ static MACHINE_CONFIG_START( galaxygn, fantland_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", I8088, 8000000) // ?
MCFG_CPU_PROGRAM_MAP(galaxygn_map)
- MCFG_CPU_VBLANK_INT("screen", fantland_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
MCFG_CPU_ADD("audiocpu", I8088, 8000000) // ?
MCFG_CPU_PROGRAM_MAP(fantland_sound_map)
@@ -1005,7 +1004,7 @@ static MACHINE_CONFIG_START( borntofi, fantland_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", V20, 16000000/2) // D701080C-8 - NEC D70108C-8 V20 CPU, running at 8.000MHz [16/2]
MCFG_CPU_PROGRAM_MAP(borntofi_map)
- MCFG_CPU_VBLANK_INT("screen", fantland_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
MCFG_CPU_ADD("audiocpu", I8088, 18432000/3) // 8088 - AMD P8088-2 CPU, running at 6.144MHz [18.432/3]
MCFG_CPU_PROGRAM_MAP(borntofi_sound_map)
@@ -1044,7 +1043,7 @@ static MACHINE_CONFIG_START( wheelrun, fantland_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", V20, XTAL_18MHz/2) // D701080C-8 (V20)
MCFG_CPU_PROGRAM_MAP(wheelrun_map)
- MCFG_CPU_VBLANK_INT("screen", fantland_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fantland_state, fantland_irq)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/2) // Z8400BB1 (Z80B)
MCFG_CPU_PROGRAM_MAP(wheelrun_sound_map)
diff --git a/src/mame/drivers/fastfred.c b/src/mame/drivers/fastfred.c
index 08d14725f9e..0fd04efdee4 100644
--- a/src/mame/drivers/fastfred.c
+++ b/src/mame/drivers/fastfred.c
@@ -626,20 +626,18 @@ GFXDECODE_END
#define CLOCK 18432000 /* The crystal is 18.432MHz */
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(fastfred_state::vblank_irq)
{
- fastfred_state *state = device->machine().driver_data<fastfred_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
-static INTERRUPT_GEN( sound_timer_irq )
+INTERRUPT_GEN_MEMBER(fastfred_state::sound_timer_irq)
{
- fastfred_state *state = device->machine().driver_data<fastfred_state>();
- if(state->m_sound_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_sound_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( fastfred, fastfred_state )
@@ -647,11 +645,11 @@ static MACHINE_CONFIG_START( fastfred, fastfred_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(fastfred_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fastfred_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, CLOCK/12) /* 1.536 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(sound_timer_irq,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(fastfred_state, sound_timer_irq, 4*60)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/fcrash.c b/src/mame/drivers/fcrash.c
index 6d877fd4255..2283e9f85bf 100644
--- a/src/mame/drivers/fcrash.c
+++ b/src/mame/drivers/fcrash.c
@@ -726,7 +726,7 @@ static MACHINE_CONFIG_START( fcrash, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(fcrash_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
MCFG_CPU_ADD("soundcpu", Z80, 24000000/6) /* ? */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -777,7 +777,7 @@ static MACHINE_CONFIG_START( kodb, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(kodb_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
// MCFG_CPU_ADD("soundcpu", Z80, 3579545)
// MCFG_CPU_PROGRAM_MAP(sub_map)
@@ -933,7 +933,7 @@ static MACHINE_CONFIG_START( sgyxz, cps_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(kodb_map)
- MCFG_CPU_VBLANK_INT("screen", cps1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", cps_state, cps1_interrupt)
// MCFG_CPU_ADD("soundcpu", Z80, 3579545)
// MCFG_CPU_PROGRAM_MAP(sub_map)
diff --git a/src/mame/drivers/feversoc.c b/src/mame/drivers/feversoc.c
index 2cff200e19b..b51ee10b4a3 100644
--- a/src/mame/drivers/feversoc.c
+++ b/src/mame/drivers/feversoc.c
@@ -79,6 +79,7 @@ public:
DECLARE_DRIVER_INIT(feversoc);
virtual void video_start();
UINT32 screen_update_feversoc(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(feversoc_irq);
};
@@ -246,9 +247,9 @@ static INPUT_PORTS_START( feversoc )
PORT_BIT( 0xff00, IP_ACTIVE_LOW, IPT_UNUSED )
INPUT_PORTS_END
-static INTERRUPT_GEN( feversoc_irq )
+INTERRUPT_GEN_MEMBER(feversoc_state::feversoc_irq)
{
- device->machine().device("maincpu")->execute().set_input_line(8, HOLD_LINE );
+ machine().device("maincpu")->execute().set_input_line(8, HOLD_LINE );
}
static MACHINE_CONFIG_START( feversoc, feversoc_state )
@@ -256,7 +257,7 @@ static MACHINE_CONFIG_START( feversoc, feversoc_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu",SH2,MASTER_CLOCK)
MCFG_CPU_PROGRAM_MAP(feversoc_map)
- MCFG_CPU_VBLANK_INT("screen",feversoc_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", feversoc_state, feversoc_irq)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/firebeat.c b/src/mame/drivers/firebeat.c
index 709c9dd77a6..8c3709c40c4 100644
--- a/src/mame/drivers/firebeat.c
+++ b/src/mame/drivers/firebeat.c
@@ -185,6 +185,7 @@ public:
DECLARE_VIDEO_START(firebeat);
UINT32 screen_update_firebeat_0(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
UINT32 screen_update_firebeat_1(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(firebeat_interrupt);
};
@@ -1936,7 +1937,7 @@ static INPUT_PORTS_START(popn)
INPUT_PORTS_END
-static INTERRUPT_GEN(firebeat_interrupt)
+INTERRUPT_GEN_MEMBER(firebeat_state::firebeat_interrupt)
{
// IRQs
// IRQ 0: VBlank
@@ -1944,7 +1945,7 @@ static INTERRUPT_GEN(firebeat_interrupt)
// IRQ 2: Main board UART
// IRQ 4: ATAPI
- device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
+ device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
}
MACHINE_RESET_MEMBER(firebeat_state,firebeat)
@@ -1973,7 +1974,7 @@ static MACHINE_CONFIG_START( firebeat, firebeat_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", PPC403GCX, 66000000)
MCFG_CPU_PROGRAM_MAP(firebeat_map)
- MCFG_CPU_VBLANK_INT("screen", firebeat_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", firebeat_state, firebeat_interrupt)
MCFG_MACHINE_START_OVERRIDE(firebeat_state,firebeat)
MCFG_MACHINE_RESET_OVERRIDE(firebeat_state,firebeat)
@@ -2019,7 +2020,7 @@ static MACHINE_CONFIG_START( firebeat2, firebeat_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", PPC403GCX, 66000000)
MCFG_CPU_PROGRAM_MAP(firebeat_map)
- MCFG_CPU_VBLANK_INT("lscreen", firebeat_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", firebeat_state, firebeat_interrupt)
MCFG_MACHINE_START_OVERRIDE(firebeat_state,firebeat)
MCFG_MACHINE_RESET_OVERRIDE(firebeat_state,firebeat)
diff --git a/src/mame/drivers/firetrap.c b/src/mame/drivers/firetrap.c
index 30b54082786..edf900f1210 100644
--- a/src/mame/drivers/firetrap.c
+++ b/src/mame/drivers/firetrap.c
@@ -581,12 +581,11 @@ static const msm5205_interface msm5205_config =
MSM5205_S48_4B /* 7.8125kHz */
};
-static INTERRUPT_GEN( firetrap_irq )
+INTERRUPT_GEN_MEMBER(firetrap_state::firetrap_irq)
{
- firetrap_state *state = device->machine().driver_data<firetrap_state>();
- if (state->m_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -643,7 +642,7 @@ static MACHINE_CONFIG_START( firetrap, firetrap_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, FIRETRAP_XTAL/2) // 6 MHz
MCFG_CPU_PROGRAM_MAP(firetrap_map)
- MCFG_CPU_VBLANK_INT("screen",firetrap_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrap_state, firetrap_irq)
MCFG_CPU_ADD("audiocpu", M6502, FIRETRAP_XTAL/8) // 1.5 MHz
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -679,7 +678,7 @@ static MACHINE_CONFIG_START( firetrapbl, firetrap_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, FIRETRAP_XTAL/2) // 6 MHz
MCFG_CPU_PROGRAM_MAP(firetrap_bootleg_map)
- MCFG_CPU_VBLANK_INT("screen", firetrap_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrap_state, firetrap_irq)
MCFG_CPU_ADD("audiocpu", M6502, FIRETRAP_XTAL/8) // 1.5 MHz
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/firetrk.c b/src/mame/drivers/firetrk.c
index baa91dd8e4c..b2624e21926 100644
--- a/src/mame/drivers/firetrk.c
+++ b/src/mame/drivers/firetrk.c
@@ -47,13 +47,12 @@ INPUT_CHANGED_MEMBER(firetrk_state::gear_changed)
}
-static INTERRUPT_GEN( firetrk_interrupt )
+INTERRUPT_GEN_MEMBER(firetrk_state::firetrk_interrupt)
{
- firetrk_state *state = device->machine().driver_data<firetrk_state>();
/* NMI interrupts are disabled during service mode in firetrk and montecar */
- if (!state->m_in_service_mode)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (!m_in_service_mode)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
@@ -876,7 +875,7 @@ static MACHINE_CONFIG_START( firetrk, firetrk_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6800, MASTER_CLOCK/12) /* 750Khz during service mode */
MCFG_CPU_PROGRAM_MAP(firetrk_map)
- MCFG_CPU_VBLANK_INT("screen", firetrk_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", firetrk_state, firetrk_interrupt)
MCFG_WATCHDOG_VBLANK_INIT(5)
diff --git a/src/mame/drivers/fitfight.c b/src/mame/drivers/fitfight.c
index 233eaa4521b..b3cb8b89385 100644
--- a/src/mame/drivers/fitfight.c
+++ b/src/mame/drivers/fitfight.c
@@ -257,9 +257,9 @@ static ADDRESS_MAP_START( snd_io, AS_IO, 8, fitfight_state )
AM_RANGE(UPD7810_PORTC, UPD7810_PORTC) AM_READ(snd_portc_r) AM_WRITE(snd_portc_w)
ADDRESS_MAP_END
-static INTERRUPT_GEN( snd_irq )
+INTERRUPT_GEN_MEMBER(fitfight_state::snd_irq)
{
- device->execute().set_input_line(UPD7810_INTF2, HOLD_LINE);
+ device.execute().set_input_line(UPD7810_INTF2, HOLD_LINE);
}
static const UPD7810_CONFIG sound_cpu_config =
@@ -735,13 +735,13 @@ static MACHINE_CONFIG_START( fitfight, fitfight_state )
MCFG_CPU_ADD("maincpu",M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(fitfight_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, irq2_line_hold)
MCFG_CPU_ADD("audiocpu", UPD7810, 12000000)
MCFG_CPU_CONFIG(sound_cpu_config)
MCFG_CPU_PROGRAM_MAP(snd_mem)
MCFG_CPU_IO_MAP(snd_io)
- MCFG_CPU_VBLANK_INT("screen", snd_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, snd_irq)
MCFG_GFXDECODE(fitfight)
@@ -766,7 +766,7 @@ static MACHINE_CONFIG_START( bbprot, fitfight_state )
MCFG_CPU_ADD("maincpu",M68000, 12000000)
MCFG_CPU_PROGRAM_MAP(bbprot_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fitfight_state, irq2_line_hold)
MCFG_GFXDECODE(prot)
diff --git a/src/mame/drivers/flipjack.c b/src/mame/drivers/flipjack.c
index 815cd91e60d..d44c9f4c3d1 100644
--- a/src/mame/drivers/flipjack.c
+++ b/src/mame/drivers/flipjack.c
@@ -478,12 +478,12 @@ static MACHINE_CONFIG_START( flipjack, flipjack_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/4)
MCFG_CPU_PROGRAM_MAP(flipjack_main_map)
MCFG_CPU_IO_MAP(flipjack_main_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flipjack_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, MASTER_CLOCK/4)
MCFG_CPU_PROGRAM_MAP(flipjack_sound_map)
MCFG_CPU_IO_MAP(flipjack_sound_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_assert)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flipjack_state, nmi_line_assert)
MCFG_I8255A_ADD( "ppi8255", ppi8255_intf )
diff --git a/src/mame/drivers/flkatck.c b/src/mame/drivers/flkatck.c
index 7b4f052cd88..bd06804e0f4 100644
--- a/src/mame/drivers/flkatck.c
+++ b/src/mame/drivers/flkatck.c
@@ -20,12 +20,11 @@
#include "includes/flkatck.h"
-static INTERRUPT_GEN( flkatck_interrupt )
+INTERRUPT_GEN_MEMBER(flkatck_state::flkatck_interrupt)
{
- flkatck_state *state = device->machine().driver_data<flkatck_state>();
- if (state->m_irq_enabled)
- device->execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
+ if (m_irq_enabled)
+ device.execute().set_input_line(HD6309_IRQ_LINE, HOLD_LINE);
}
WRITE8_MEMBER(flkatck_state::flkatck_bankswitch_w)
@@ -222,7 +221,7 @@ static MACHINE_CONFIG_START( flkatck, flkatck_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", HD6309,3000000*4) /* HD63C09EP, 24/8 MHz */
MCFG_CPU_PROGRAM_MAP(flkatck_map)
- MCFG_CPU_VBLANK_INT("screen", flkatck_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flkatck_state, flkatck_interrupt)
MCFG_CPU_ADD("audiocpu", Z80,3579545) /* NEC D780C-1, 3.579545 MHz */
MCFG_CPU_PROGRAM_MAP(flkatck_sound_map)
diff --git a/src/mame/drivers/flower.c b/src/mame/drivers/flower.c
index bc54b918a6f..b8315aee509 100644
--- a/src/mame/drivers/flower.c
+++ b/src/mame/drivers/flower.c
@@ -250,15 +250,15 @@ static MACHINE_CONFIG_START( flower, flower_state )
// cpus are Z80 "A" type, official maximum speed of 4 MHz, but 4.6 MHz has been proven to work in practice
MCFG_CPU_ADD("maincpu", Z80,XTAL_18_432MHz/4)
MCFG_CPU_PROGRAM_MAP(flower_cpu1_2)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flower_state, irq0_line_hold)
MCFG_CPU_ADD("subcpu", Z80,XTAL_18_432MHz/4)
MCFG_CPU_PROGRAM_MAP(flower_cpu1_2)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 120) // controls game speed? irqsource and frequency unknown
+ MCFG_CPU_PERIODIC_INT_DRIVER(flower_state, irq0_line_hold, 120) // controls game speed? irqsource and frequency unknown
MCFG_CPU_ADD("audiocpu", Z80,XTAL_18_432MHz/4)
MCFG_CPU_PROGRAM_MAP(flower_sound_cpu)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 90) // controls music speed. irqsource and frequency unknown, same as subcpu perhaps?
+ MCFG_CPU_PERIODIC_INT_DRIVER(flower_state, irq0_line_hold, 90) // controls music speed. irqsource and frequency unknown, same as subcpu perhaps?
// tight sync, slowdowns otherwise
// MCFG_QUANTUM_PERFECT_CPU("maincpu")
diff --git a/src/mame/drivers/flstory.c b/src/mame/drivers/flstory.c
index 0e166f2a1f0..e0b65d1e1fc 100644
--- a/src/mame/drivers/flstory.c
+++ b/src/mame/drivers/flstory.c
@@ -1082,11 +1082,11 @@ static MACHINE_CONFIG_START( flstory, flstory_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,XTAL_10_733MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(flstory_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,XTAL_8MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* IRQ generated by ??? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60) /* IRQ generated by ??? */
/* NMI generated by the main CPU */
MCFG_CPU_ADD("mcu", M68705,XTAL_18_432MHz/6) /* verified on pcb */
@@ -1139,11 +1139,11 @@ static MACHINE_CONFIG_START( onna34ro, flstory_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,10733000/2) /* ??? */
MCFG_CPU_PROGRAM_MAP(onna34ro_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* IRQ generated by ??? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60) /* IRQ generated by ??? */
/* NMI generated by the main CPU */
// MCFG_CPU_ADD("mcu", M68705,4000000) /* ??? */
@@ -1196,11 +1196,11 @@ static MACHINE_CONFIG_START( victnine, flstory_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,8000000/2) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(victnine_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* IRQ generated by ??? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60) /* IRQ generated by ??? */
/* NMI generated by the main CPU */
// MCFG_CPU_ADD("mcu", M68705,4000000) /* ??? */
@@ -1259,11 +1259,11 @@ static MACHINE_CONFIG_START( rumba, flstory_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,8000000/2) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(rumba_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flstory_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60) /* IRQ generated by ??? */
+ MCFG_CPU_PERIODIC_INT_DRIVER(flstory_state, irq0_line_hold, 2*60) /* IRQ generated by ??? */
/* NMI generated by the main CPU */
// MCFG_CPU_ADD("mcu", M68705,18432000/6) /* ??? */
diff --git a/src/mame/drivers/flyball.c b/src/mame/drivers/flyball.c
index b52d627e861..9540a9b4a1a 100644
--- a/src/mame/drivers/flyball.c
+++ b/src/mame/drivers/flyball.c
@@ -415,7 +415,7 @@ static MACHINE_CONFIG_START( flyball, flyball_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, MASTER_CLOCK/16)
MCFG_CPU_PROGRAM_MAP(flyball_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", flyball_state, nmi_line_pulse)
/* video hardware */
diff --git a/src/mame/drivers/fortecar.c b/src/mame/drivers/fortecar.c
index d2b73f0e97a..e216cae170c 100644
--- a/src/mame/drivers/fortecar.c
+++ b/src/mame/drivers/fortecar.c
@@ -690,7 +690,7 @@ static MACHINE_CONFIG_START( fortecar, fortecar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK) /* 3 MHz, measured */
MCFG_CPU_PROGRAM_MAP(fortecar_map)
MCFG_CPU_IO_MAP(fortecar_ports)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fortecar_state, nmi_line_pulse)
MCFG_WATCHDOG_TIME_INIT(attotime::from_msec(200)) /* guess */
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/freekick.c b/src/mame/drivers/freekick.c
index d69780e18d9..648eb9799ee 100644
--- a/src/mame/drivers/freekick.c
+++ b/src/mame/drivers/freekick.c
@@ -76,11 +76,10 @@ WRITE8_MEMBER(freekick_state::nmi_enable_w)
m_nmi_en = data & 1;
}
-static INTERRUPT_GEN( freekick_irqgen )
+INTERRUPT_GEN_MEMBER(freekick_state::freekick_irqgen)
{
- freekick_state *state = device->machine().driver_data<freekick_state>();
- if (state->m_nmi_en)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if (m_nmi_en)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
WRITE8_MEMBER(freekick_state::oigas_5_w)
@@ -632,8 +631,8 @@ static MACHINE_CONFIG_START( base, freekick_state )
MCFG_CPU_ADD("maincpu",Z80, 18432000/6) //confirmed
MCFG_CPU_PROGRAM_MAP(pbillrd_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, 50*3) //??
- MCFG_CPU_VBLANK_INT("screen", freekick_irqgen)
+ MCFG_CPU_PERIODIC_INT_DRIVER(freekick_state, irq0_line_hold, 50*3) //??
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", freekick_state, freekick_irqgen)
MCFG_GFXDECODE(freekick)
diff --git a/src/mame/drivers/fromanc2.c b/src/mame/drivers/fromanc2.c
index 40c9b0d98ba..520856c4f49 100644
--- a/src/mame/drivers/fromanc2.c
+++ b/src/mame/drivers/fromanc2.c
@@ -31,9 +31,9 @@
*
*************************************/
-static INTERRUPT_GEN( fromanc2_interrupt )
+INTERRUPT_GEN_MEMBER(fromanc2_state::fromanc2_interrupt)
{
- device->execute().set_input_line(1, HOLD_LINE);
+ device.execute().set_input_line(1, HOLD_LINE);
}
@@ -546,7 +546,7 @@ static MACHINE_CONFIG_START( fromanc2, fromanc2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,32000000/2) /* 16.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromanc2_main_map)
- MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
MCFG_CPU_ADD("audiocpu", Z80,32000000/4) /* 8.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
@@ -596,7 +596,7 @@ static MACHINE_CONFIG_START( fromancr, fromanc2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,32000000/2) /* 16.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromancr_main_map)
- MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
MCFG_CPU_ADD("audiocpu", Z80,32000000/4) /* 8.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
@@ -646,7 +646,7 @@ static MACHINE_CONFIG_START( fromanc4, fromanc2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,32000000/2) /* 16.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromanc4_main_map)
- MCFG_CPU_VBLANK_INT("lscreen", fromanc2_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", fromanc2_state, fromanc2_interrupt)
MCFG_CPU_ADD("audiocpu", Z80,32000000/4) /* 8.00 MHz */
MCFG_CPU_PROGRAM_MAP(fromanc2_sound_map)
diff --git a/src/mame/drivers/fromance.c b/src/mame/drivers/fromance.c
index 41256814adf..5a26462a049 100644
--- a/src/mame/drivers/fromance.c
+++ b/src/mame/drivers/fromance.c
@@ -1004,7 +1004,7 @@ static MACHINE_CONFIG_START( nekkyoku, fromance_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(nekkyoku_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(nekkyoku_sub_map)
@@ -1042,7 +1042,7 @@ static MACHINE_CONFIG_START( idolmj, fromance_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(fromance_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(fromance_sub_map)
@@ -1080,7 +1080,7 @@ static MACHINE_CONFIG_START( fromance, fromance_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(fromance_main_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", fromance_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */
MCFG_CPU_PROGRAM_MAP(fromance_sub_map)
diff --git a/src/mame/drivers/funkybee.c b/src/mame/drivers/funkybee.c
index cef93cbe6a2..f3704c7af04 100644
--- a/src/mame/drivers/funkybee.c
+++ b/src/mame/drivers/funkybee.c
@@ -296,7 +296,7 @@ static MACHINE_CONFIG_START( funkybee, funkybee_state )
MCFG_CPU_ADD("maincpu", Z80, 3072000) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(funkybee_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funkybee_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/funkyjet.c b/src/mame/drivers/funkyjet.c
index b48686451d1..864f2a8556a 100644
--- a/src/mame/drivers/funkyjet.c
+++ b/src/mame/drivers/funkyjet.c
@@ -312,7 +312,7 @@ static MACHINE_CONFIG_START( funkyjet, funkyjet_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_28MHz/2) /* 28 MHz crystal */
MCFG_CPU_PROGRAM_MAP(funkyjet_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funkyjet_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", H6280, XTAL_32_22MHz/4) /* Custom chip 45, Audio section crystal is 32.220 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/funworld.c b/src/mame/drivers/funworld.c
index 3208b7740db..5b80993c163 100644
--- a/src/mame/drivers/funworld.c
+++ b/src/mame/drivers/funworld.c
@@ -2352,7 +2352,7 @@ static MACHINE_CONFIG_START( fw1stpal, funworld_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M65SC02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(funworld_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MCFG_NVRAM_ADD_0FILL("nvram")
@@ -2388,7 +2388,7 @@ static MACHINE_CONFIG_DERIVED( fw2ndpal, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(funworld_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MCFG_GFXDECODE(fw2ndpal)
MACHINE_CONFIG_END
@@ -2400,7 +2400,7 @@ static MACHINE_CONFIG_DERIVED( funquiz, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(funquiz_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MCFG_SOUND_REPLACE("ay8910", AY8910, MASTER_CLOCK/8) /* 2MHz */
MCFG_SOUND_CONFIG(funquiz_ay8910_intf)
@@ -2412,7 +2412,7 @@ static MACHINE_CONFIG_DERIVED( magicrd2, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(magicrd2_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MCFG_VIDEO_START_OVERRIDE(funworld_state,magicrd2)
@@ -2425,35 +2425,35 @@ static MACHINE_CONFIG_DERIVED( royalcd1, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* (G65SC02P in pro version) 2MHz */
MCFG_CPU_PROGRAM_MAP(magicrd2_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( royalcd2, fw2ndpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(magicrd2_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( cuoreuno, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(cuoreuno_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( saloon, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(saloon_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( witchryl, fw1stpal )
MCFG_CPU_REPLACE("maincpu", M65C02, MASTER_CLOCK/8) /* 2MHz */
MCFG_CPU_PROGRAM_MAP(witchryl_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funworld_state, nmi_line_pulse)
MACHINE_CONFIG_END
diff --git a/src/mame/drivers/funybubl.c b/src/mame/drivers/funybubl.c
index 58acb3889cf..6c295d7e53e 100644
--- a/src/mame/drivers/funybubl.c
+++ b/src/mame/drivers/funybubl.c
@@ -221,7 +221,7 @@ static MACHINE_CONFIG_START( funybubl, funybubl_state )
MCFG_CPU_ADD("maincpu", Z80,12000000/2) /* 6 MHz?? */
MCFG_CPU_PROGRAM_MAP(funybubl_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", funybubl_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz?? */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/gaelco.c b/src/mame/drivers/gaelco.c
index ea4aafeb7bf..65f842019be 100644
--- a/src/mame/drivers/gaelco.c
+++ b/src/mame/drivers/gaelco.c
@@ -506,7 +506,7 @@ static MACHINE_CONFIG_START( bigkarnk, gaelco_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* MC68000P10, 10 MHz */
MCFG_CPU_PROGRAM_MAP(bigkarnk_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", M6809, 8867000/4) /* 68B09, 2.21675 MHz? */
MCFG_CPU_PROGRAM_MAP(bigkarnk_snd_map)
@@ -542,7 +542,7 @@ static MACHINE_CONFIG_START( maniacsq, gaelco_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,24000000/2) /* 12 MHz */
MCFG_CPU_PROGRAM_MAP(maniacsq_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
/* video hardware */
@@ -570,7 +570,7 @@ static MACHINE_CONFIG_START( squash, gaelco_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000) /* MC68000P12, 12 MHz */
MCFG_CPU_PROGRAM_MAP(squash_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
MCFG_QUANTUM_TIME(attotime::from_hz(600))
@@ -600,7 +600,7 @@ static MACHINE_CONFIG_START( thoop, gaelco_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 12000000) /* MC68000P12, 12 MHz */
MCFG_CPU_PROGRAM_MAP(thoop_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco_state, irq6_line_hold)
MCFG_QUANTUM_TIME(attotime::from_hz(600))
diff --git a/src/mame/drivers/gaelco2.c b/src/mame/drivers/gaelco2.c
index 7d2e5c4be17..b5f86013da6 100644
--- a/src/mame/drivers/gaelco2.c
+++ b/src/mame/drivers/gaelco2.c
@@ -157,7 +157,7 @@ static MACHINE_CONFIG_START( maniacsq, gaelco2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 26000000/2) /* 13 MHz? */
MCFG_CPU_PROGRAM_MAP(maniacsq_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
/* video hardware */
MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
@@ -531,7 +531,7 @@ static MACHINE_CONFIG_START( alighunt, gaelco2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 24000000/2) /* 12 MHz */
MCFG_CPU_PROGRAM_MAP(alighunt_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
/* video hardware */
MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
@@ -773,7 +773,7 @@ static MACHINE_CONFIG_START( touchgo, gaelco2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 32000000/2) /* 16 MHz */
MCFG_CPU_PROGRAM_MAP(touchgo_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gaelco2_state, irq6_line_hold)
/* video hardware */
MCFG_BUFFERED_SPRITERAM16_ADD("spriteram")
@@ -965,7 +965,7 @@ static MACHINE_CONFIG_START( snowboar, gaelco2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 30000000/2) /* 15 MHz */
MCFG_CPU_PROGRAM_MAP(snowboar_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco2_state, irq6_line_hold)
MCFG_EEPROM_ADD("eeprom", gaelco2_eeprom_interface)
@@ -1206,7 +1206,7 @@ static MACHINE_CONFIG_START( wrally2, gaelco2_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 26000000/2) /* 13 MHz */
MCFG_CPU_PROGRAM_MAP(wrally2_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gaelco2_state, irq6_line_hold)
MCFG_EEPROM_ADD("eeprom", gaelco2_eeprom_interface)
diff --git a/src/mame/drivers/gaelco3d.c b/src/mame/drivers/gaelco3d.c
index c05073ff279..3c5ad6694e4 100644
--- a/src/mame/drivers/gaelco3d.c
+++ b/src/mame/drivers/gaelco3d.c
@@ -250,10 +250,10 @@ MACHINE_RESET_MEMBER(gaelco3d_state,gaelco3d2)
*
*************************************/
-static INTERRUPT_GEN( vblank_gen )
+INTERRUPT_GEN_MEMBER(gaelco3d_state::vblank_gen)
{
- gaelco3d_render(*device->machine().primary_screen);
- device->execute().set_input_line(2, ASSERT_LINE);
+ gaelco3d_render(*machine().primary_screen);
+ device.execute().set_input_line(2, ASSERT_LINE);
}
@@ -994,7 +994,7 @@ static MACHINE_CONFIG_START( gaelco3d, gaelco3d_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 15000000)
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco3d_state, vblank_gen)
MCFG_CPU_ADD("tms", TMS32031, 60000000)
MCFG_TMS3203X_CONFIG(tms_config)
@@ -1047,7 +1047,7 @@ static MACHINE_CONFIG_DERIVED( gaelco3d2, gaelco3d )
/* basic machine hardware */
MCFG_CPU_REPLACE("maincpu", M68EC020, 25000000)
MCFG_CPU_PROGRAM_MAP(main020_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaelco3d_state, vblank_gen)
MCFG_CPU_MODIFY("tms")
MCFG_CPU_CLOCK(50000000)
diff --git a/src/mame/drivers/gaiden.c b/src/mame/drivers/gaiden.c
index dc43a5d3f1d..76fc0ba31cf 100644
--- a/src/mame/drivers/gaiden.c
+++ b/src/mame/drivers/gaiden.c
@@ -764,7 +764,7 @@ static MACHINE_CONFIG_START( shadoww, gaiden_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 18432000/2) /* 9.216 MHz */
MCFG_CPU_PROGRAM_MAP(gaiden_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -820,7 +820,7 @@ static MACHINE_CONFIG_START( drgnbowl, gaiden_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 20000000/2) /* 10 MHz */
MCFG_CPU_PROGRAM_MAP(drgnbowl_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 12000000/2) /* 6 MHz */
MCFG_CPU_PROGRAM_MAP(drgnbowl_sound_map)
@@ -936,7 +936,7 @@ static MACHINE_CONFIG_START( mastninj, gaiden_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz? */
MCFG_CPU_PROGRAM_MAP(mastninj_map)
- MCFG_CPU_VBLANK_INT("screen", irq5_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaiden_state, irq5_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, 4000000) /* ?? MHz */
MCFG_CPU_PROGRAM_MAP(mastninj_sound_map)
diff --git a/src/mame/drivers/gal3.c b/src/mame/drivers/gal3.c
index d5fabde73dc..7483fcb8591 100644
--- a/src/mame/drivers/gal3.c
+++ b/src/mame/drivers/gal3.c
@@ -627,15 +627,15 @@ static const c140_interface C140_interface =
static MACHINE_CONFIG_START( gal3, gal3_state )
MCFG_CPU_ADD("cpumst", M68020, 49152000/2)
MCFG_CPU_PROGRAM_MAP(cpu_mst_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq1_line_hold)
MCFG_CPU_ADD("cpuslv", M68020, 49152000/2)
MCFG_CPU_PROGRAM_MAP(cpu_slv_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq1_line_hold)
MCFG_CPU_ADD("rs_cpu", M68000, 49152000/4)
MCFG_CPU_PROGRAM_MAP(rs_cpu_map)
- MCFG_CPU_VBLANK_INT("lscreen", irq5_line_hold) /// programmable via 148 IC
+ MCFG_CPU_VBLANK_INT_DRIVER("lscreen", gal3_state, irq5_line_hold) /// programmable via 148 IC
MCFG_CPU_ADD("sound_cpu", M68000, 12000000) // ??
MCFG_CPU_PROGRAM_MAP(sound_cpu_map)
diff --git a/src/mame/drivers/galaga.c b/src/mame/drivers/galaga.c
index 13c4d545aa3..5d7aca6a5a1 100644
--- a/src/mame/drivers/galaga.c
+++ b/src/mame/drivers/galaga.c
@@ -1637,20 +1637,18 @@ static const samples_interface battles_samples_interface =
};
-static INTERRUPT_GEN( main_vblank_irq )
+INTERRUPT_GEN_MEMBER(galaga_state::main_vblank_irq)
{
- galaga_state *state = device->machine().driver_data<galaga_state>();
- if(state->m_main_irq_mask)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if(m_main_irq_mask)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
-static INTERRUPT_GEN( sub_vblank_irq )
+INTERRUPT_GEN_MEMBER(galaga_state::sub_vblank_irq)
{
- galaga_state *state = device->machine().driver_data<galaga_state>();
- if(state->m_sub_irq_mask)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if(m_sub_irq_mask)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
const namco_06xx_config bosco_namco_06xx_0_intf =
@@ -1673,11 +1671,11 @@ static MACHINE_CONFIG_START( bosco, bosco_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(bosco_map)
- MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(bosco_map)
- MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(bosco_map)
@@ -1733,11 +1731,11 @@ static MACHINE_CONFIG_START( galaga, galaga_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(galaga_map)
- MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(galaga_map)
- MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(galaga_map)
@@ -1810,11 +1808,11 @@ static MACHINE_CONFIG_START( xevious, xevious_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(xevious_map)
- MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
MCFG_CPU_ADD("sub", Z80,MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(xevious_map)
- MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(xevious_map)
@@ -1873,7 +1871,7 @@ static MACHINE_CONFIG_DERIVED( battles, xevious )
MCFG_CPU_ADD("sub3", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(battles_mem4)
- MCFG_CPU_VBLANK_INT("screen", battles_interrupt_4)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", xevious_state, battles_interrupt_4)
MCFG_TIMER_ADD("battles_nmi", battles_nmi_generate)
@@ -1899,11 +1897,11 @@ static MACHINE_CONFIG_START( digdug, digdug_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(digdug_map)
- MCFG_CPU_VBLANK_INT("screen", main_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, main_vblank_irq)
MCFG_CPU_ADD("sub", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(digdug_map)
- MCFG_CPU_VBLANK_INT("screen", sub_vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaga_state, sub_vblank_irq)
MCFG_CPU_ADD("sub2", Z80, MASTER_CLOCK/6) /* 3.072 MHz */
MCFG_CPU_PROGRAM_MAP(digdug_map)
diff --git a/src/mame/drivers/galastrm.c b/src/mame/drivers/galastrm.c
index 1a73a00ba52..ed90ad1cc5c 100644
--- a/src/mame/drivers/galastrm.c
+++ b/src/mame/drivers/galastrm.c
@@ -48,11 +48,10 @@ $305.b invincibility
/*********************************************************************/
-static INTERRUPT_GEN( galastrm_interrupt )
+INTERRUPT_GEN_MEMBER(galastrm_state::galastrm_interrupt)
{
- galastrm_state *state = device->machine().driver_data<galastrm_state>();
- state->m_frame_counter ^= 1;
- device->execute().set_input_line(5, HOLD_LINE);
+ m_frame_counter ^= 1;
+ device.execute().set_input_line(5, HOLD_LINE);
}
static TIMER_CALLBACK( galastrm_interrupt6 )
@@ -310,7 +309,7 @@ static MACHINE_CONFIG_START( galastrm, galastrm_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68EC020, 16000000) /* 16 MHz */
MCFG_CPU_PROGRAM_MAP(galastrm_map)
- MCFG_CPU_VBLANK_INT("screen", galastrm_interrupt) /* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galastrm_state, galastrm_interrupt) /* VBL */
MCFG_EEPROM_ADD("eeprom", galastrm_eeprom_interface)
diff --git a/src/mame/drivers/galaxi.c b/src/mame/drivers/galaxi.c
index fbcc208ed83..cbb04a50433 100644
--- a/src/mame/drivers/galaxi.c
+++ b/src/mame/drivers/galaxi.c
@@ -406,7 +406,7 @@ static MACHINE_CONFIG_START( galaxi, galaxi_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_10MHz) // ?
MCFG_CPU_PROGRAM_MAP(galaxi_map)
- MCFG_CPU_VBLANK_INT("screen", irq4_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxi_state, irq4_line_hold)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/galaxia.c b/src/mame/drivers/galaxia.c
index c7ac0ad5d20..1da3dec7509 100644
--- a/src/mame/drivers/galaxia.c
+++ b/src/mame/drivers/galaxia.c
@@ -67,10 +67,10 @@ TODO:
#include "includes/galaxia.h"
-static INTERRUPT_GEN( galaxia_interrupt )
+INTERRUPT_GEN_MEMBER(galaxia_state::galaxia_interrupt)
{
- device->execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
- cvs_scroll_stars(device->machine());
+ device.execute().set_input_line_and_vector(0, HOLD_LINE, 0x03);
+ cvs_scroll_stars(machine());
}
@@ -296,7 +296,7 @@ static MACHINE_CONFIG_START( galaxia, galaxia_state )
MCFG_CPU_ADD("maincpu", S2650, 2000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(galaxia_mem_map)
MCFG_CPU_IO_MAP(galaxia_io_map)
- MCFG_CPU_VBLANK_INT("screen", galaxia_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxia_state, galaxia_interrupt)
/* video hardware */
MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
@@ -336,7 +336,7 @@ static MACHINE_CONFIG_START( astrowar, galaxia_state )
MCFG_CPU_ADD("maincpu", S2650, 2000000) /* ? MHz */
MCFG_CPU_PROGRAM_MAP(astrowar_mem_map)
MCFG_CPU_IO_MAP(galaxia_io_map)
- MCFG_CPU_VBLANK_INT("screen", galaxia_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxia_state, galaxia_interrupt)
/* video hardware */
MCFG_VIDEO_ATTRIBUTES(VIDEO_ALWAYS_UPDATE)
diff --git a/src/mame/drivers/galaxian.c b/src/mame/drivers/galaxian.c
index 6ff3b7e1dea..abb7fb77637 100644
--- a/src/mame/drivers/galaxian.c
+++ b/src/mame/drivers/galaxian.c
@@ -438,26 +438,24 @@ TO DO :
*
*************************************/
-static INTERRUPT_GEN( interrupt_gen )
+INTERRUPT_GEN_MEMBER(galaxian_state::interrupt_gen)
{
- galaxian_state *state = device->machine().driver_data<galaxian_state>();
/* interrupt line is clocked at VBLANK */
/* a flip-flop at 6F is held in the preset state based on the NMI ON signal */
- if (state->m_irq_enabled)
- device->execute().set_input_line(state->m_irq_line, ASSERT_LINE);
+ if (m_irq_enabled)
+ device.execute().set_input_line(m_irq_line, ASSERT_LINE);
}
-static INTERRUPT_GEN( fakechange_interrupt_gen )
+INTERRUPT_GEN_MEMBER(galaxian_state::fakechange_interrupt_gen)
{
- galaxian_state *state = device->machine().driver_data<galaxian_state>();
interrupt_gen(device);
- if (state->ioport("FAKE_SELECT")->read_safe(0x00))
+ if (ioport("FAKE_SELECT")->read_safe(0x00))
{
- state->m_tenspot_current_game++;
- state->m_tenspot_current_game%=10;
- state->tenspot_set_game_bank(device->machine(), state->m_tenspot_current_game, 1);
- device->machine().device("maincpu")->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
+ m_tenspot_current_game++;
+ m_tenspot_current_game%=10;
+ tenspot_set_game_bank(machine(), m_tenspot_current_game, 1);
+ machine().device("maincpu")->execute().set_input_line(INPUT_LINE_RESET, PULSE_LINE);
}
}
@@ -2084,7 +2082,7 @@ static MACHINE_CONFIG_START( galaxian_base, galaxian_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, GALAXIAN_PIXEL_CLOCK/3/2)
MCFG_CPU_PROGRAM_MAP(galaxian_map)
- MCFG_CPU_VBLANK_INT("screen", interrupt_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, interrupt_gen)
MCFG_WATCHDOG_VBLANK_INIT(8)
@@ -2180,7 +2178,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_DERIVED( tenspot, galaxian )
MCFG_CPU_MODIFY("maincpu")
- MCFG_CPU_VBLANK_INT("screen", fakechange_interrupt_gen)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, fakechange_interrupt_gen)
/* basic machine hardware */
MCFG_CPU_ADD("selectcpu", Z80, GALAXIAN_PIXEL_CLOCK/3/2) // ?? mhz
@@ -2260,7 +2258,7 @@ static MACHINE_CONFIG_DERIVED( checkman, mooncrst )
MCFG_CPU_ADD("audiocpu", Z80, 1620000) /* 1.62 MHz */
MCFG_CPU_PROGRAM_MAP(checkman_sound_map)
MCFG_CPU_IO_MAP(checkman_sound_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold) /* NMIs are triggered by the main CPU */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxian_state, irq0_line_hold) /* NMIs are triggered by the main CPU */
/* sound hardware */
MCFG_SOUND_ADD("aysnd", AY8910, 1789750)
diff --git a/src/mame/drivers/galaxold.c b/src/mame/drivers/galaxold.c
index 3e09b97c883..7de29557917 100644
--- a/src/mame/drivers/galaxold.c
+++ b/src/mame/drivers/galaxold.c
@@ -2314,7 +2314,7 @@ static MACHINE_CONFIG_DERIVED( ozon1, galaxold_base )
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(ozon1_map)
MCFG_CPU_IO_MAP(ozon1_io_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, nmi_line_pulse)
MCFG_MACHINE_RESET(0)
@@ -2332,7 +2332,7 @@ static MACHINE_CONFIG_START( drivfrcg, galaxold_state )
MCFG_CPU_ADD("maincpu", S2650, MASTER_CLOCK/6)
MCFG_CPU_PROGRAM_MAP(drivfrcg)
MCFG_CPU_IO_MAP(drivfrcg_io)
- MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
MCFG_SCREEN_ADD("screen", RASTER)
@@ -2384,12 +2384,11 @@ static MACHINE_CONFIG_DERIVED( hunchbkg, galaxold_base )
MCFG_FRAGMENT_ADD(galaxian_audio)
MACHINE_CONFIG_END
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(galaxold_state::vblank_irq)
{
- galaxold_state *state = device->machine().driver_data<galaxold_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_DERIVED( harem, galaxold_base )
@@ -2397,7 +2396,7 @@ static MACHINE_CONFIG_DERIVED( harem, galaxold_base )
/* basic machine hardware */
MCFG_CPU_MODIFY("maincpu")
MCFG_CPU_PROGRAM_MAP(harem_cpu1)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, vblank_irq)
MCFG_CPU_ADD("audiocpu", Z80, 1620000) //?
MCFG_CPU_PROGRAM_MAP(harem_cpu2)
@@ -2433,7 +2432,7 @@ static MACHINE_CONFIG_START( racknrol, galaxold_state )
MCFG_CPU_ADD("maincpu", S2650, PIXEL_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(racknrol)
MCFG_CPU_IO_MAP(racknrol_io)
- MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
MCFG_GFXDECODE(galaxian)
MCFG_PALETTE_LENGTH(32)
@@ -2491,7 +2490,7 @@ static MACHINE_CONFIG_START( hexpoola, galaxold_state )
MCFG_CPU_ADD("maincpu", S2650, PIXEL_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(racknrol)
MCFG_CPU_IO_MAP(hexpoola_io)
- MCFG_CPU_VBLANK_INT("screen", hunchbks_vh_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galaxold_state, hunchbks_vh_interrupt)
MCFG_GFXDECODE(galaxian)
MCFG_PALETTE_LENGTH(32)
diff --git a/src/mame/drivers/galgame.c b/src/mame/drivers/galgame.c
index c0eec734f56..fb4a8c7bd52 100644
--- a/src/mame/drivers/galgame.c
+++ b/src/mame/drivers/galgame.c
@@ -48,6 +48,7 @@ public:
virtual void machine_reset();
virtual void palette_init();
UINT32 screen_update_galaxygame(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(galaxygame_irq);
};
/*************************************
@@ -301,13 +302,12 @@ static IRQ_CALLBACK(galaxygame_irq_callback)
return 0x40;
}
-static INTERRUPT_GEN(galaxygame_irq)
+INTERRUPT_GEN_MEMBER(galaxygame_state::galaxygame_irq)
{
- galaxygame_state *state = device->machine().driver_data<galaxygame_state>();
- if ( state->m_clk & 0x40 )
+ if ( m_clk & 0x40 )
{
- device->execute().set_input_line(0, ASSERT_LINE);
- state->m_interrupt = 1;
+ device.execute().set_input_line(0, ASSERT_LINE);
+ m_interrupt = 1;
}
}
@@ -331,7 +331,7 @@ static MACHINE_CONFIG_START( galaxygame, galaxygame_state )
MCFG_CPU_ADD("maincpu", T11, 3000000 )
MCFG_CPU_PROGRAM_MAP(galaxygame_map)
MCFG_CPU_CONFIG(t11_data)
- MCFG_CPU_PERIODIC_INT(galaxygame_irq,60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(galaxygame_state, galaxygame_irq, 60)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/galivan.c b/src/mame/drivers/galivan.c
index 67905f3d460..a8eba034d8e 100644
--- a/src/mame/drivers/galivan.c
+++ b/src/mame/drivers/galivan.c
@@ -436,12 +436,12 @@ static MACHINE_CONFIG_START( galivan, galivan_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* 6 MHz? */
MCFG_CPU_PROGRAM_MAP(galivan_map)
MCFG_CPU_IO_MAP(io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galivan_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* 4 MHz? */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(galivan_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(galivan_state,galivan)
MCFG_MACHINE_RESET_OVERRIDE(galivan_state,galivan)
@@ -478,12 +478,12 @@ static MACHINE_CONFIG_START( ninjemak, galivan_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* 6 MHz? */
MCFG_CPU_PROGRAM_MAP(ninjemak_map)
MCFG_CPU_IO_MAP(ninjemak_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galivan_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_8MHz/2) /* 4 MHz? */
MCFG_CPU_PROGRAM_MAP(sound_map)
MCFG_CPU_IO_MAP(sound_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, XTAL_8MHz/2/512) // ?
+ MCFG_CPU_PERIODIC_INT_DRIVER(galivan_state, irq0_line_hold, XTAL_8MHz/2/512) // ?
MCFG_MACHINE_START_OVERRIDE(galivan_state,ninjemak)
MCFG_MACHINE_RESET_OVERRIDE(galivan_state,ninjemak)
diff --git a/src/mame/drivers/galspnbl.c b/src/mame/drivers/galspnbl.c
index 7289a278b23..dab38637648 100644
--- a/src/mame/drivers/galspnbl.c
+++ b/src/mame/drivers/galspnbl.c
@@ -229,7 +229,7 @@ static MACHINE_CONFIG_START( galspnbl, galspnbl_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, XTAL_12MHz) /* 12 MHz ??? - Use value from Temco's Super Pinball Action - NEEDS VERIFICATION!! */
MCFG_CPU_PROGRAM_MAP(main_map)
- MCFG_CPU_VBLANK_INT("screen", irq3_line_hold)/* also has vector for 6, but it does nothing */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", galspnbl_state, irq3_line_hold)/* also has vector for 6, but it does nothing */
MCFG_CPU_ADD("audiocpu", Z80, XTAL_4MHz) /* 4 MHz ??? - Use value from Temco's Super Pinball Action - NEEDS VERIFICATION!! */
MCFG_CPU_PROGRAM_MAP(audio_map)
diff --git a/src/mame/drivers/gamtor.c b/src/mame/drivers/gamtor.c
index 339c221f89f..3773064727b 100644
--- a/src/mame/drivers/gamtor.c
+++ b/src/mame/drivers/gamtor.c
@@ -70,7 +70,7 @@ INPUT_PORTS_END
static MACHINE_CONFIG_START( gaminator, gaminator_state )
MCFG_CPU_ADD("maincpu", MCF5206E, 40000000) /* definitely Coldfire, model / clock uncertain */
MCFG_CPU_PROGRAM_MAP(gaminator_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) // irq6 seems to be needed to get past the ROM checking
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaminator_state, irq6_line_hold) // irq6 seems to be needed to get past the ROM checking
MCFG_FRAGMENT_ADD( pcvideo_vga )
diff --git a/src/mame/drivers/gaplus.c b/src/mame/drivers/gaplus.c
index ee659ca7e8a..0708ccd8e59 100644
--- a/src/mame/drivers/gaplus.c
+++ b/src/mame/drivers/gaplus.c
@@ -250,37 +250,34 @@ static TIMER_CALLBACK( namcoio_run )
}
}
-static INTERRUPT_GEN( gaplus_vblank_main_irq )
+INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_main_irq)
{
- gaplus_state *state = device->machine().driver_data<gaplus_state>();
- device_t *io58xx = device->machine().device("58xx");
- device_t *io56xx = device->machine().device("56xx");
+ device_t *io58xx = machine().device("58xx");
+ device_t *io56xx = machine().device("56xx");
- if(state->m_main_irq_mask)
- device->machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
+ if(m_main_irq_mask)
+ machine().device("maincpu")->execute().set_input_line(0, ASSERT_LINE);
if (!namcoio_read_reset_line(io58xx)) /* give the cpu a tiny bit of time to write the command before processing it */
- device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
+ machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run));
if (!namcoio_read_reset_line(io56xx)) /* give the cpu a tiny bit of time to write the command before processing it */
- device->machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
+ machine().scheduler().timer_set(attotime::from_usec(50), FUNC(namcoio_run), 1);
}
-static INTERRUPT_GEN( gaplus_vblank_sub_irq )
+INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_sub_irq)
{
- gaplus_state *state = device->machine().driver_data<gaplus_state>();
- if(state->m_sub_irq_mask)
- device->machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
+ if(m_sub_irq_mask)
+ machine().device("sub")->execute().set_input_line(0, ASSERT_LINE);
}
-static INTERRUPT_GEN( gaplus_vblank_sub2_irq )
+INTERRUPT_GEN_MEMBER(gaplus_state::gaplus_vblank_sub2_irq)
{
- gaplus_state *state = device->machine().driver_data<gaplus_state>();
- if(state->m_sub2_irq_mask)
- device->machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
+ if(m_sub2_irq_mask)
+ machine().device("sub2")->execute().set_input_line(0, ASSERT_LINE);
}
@@ -560,15 +557,15 @@ static MACHINE_CONFIG_START( gaplus, gaplus_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, 24576000/16) /* 1.536 MHz */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
- MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_main_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_main_irq)
MCFG_CPU_ADD("sub", M6809, 24576000/16) /* 1.536 MHz */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
- MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_sub_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_sub_irq)
MCFG_CPU_ADD("sub2", M6809, 24576000/16) /* 1.536 MHz */
MCFG_CPU_PROGRAM_MAP(cpu3_map)
- MCFG_CPU_VBLANK_INT("screen", gaplus_vblank_sub2_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gaplus_state, gaplus_vblank_sub2_irq)
MCFG_QUANTUM_TIME(attotime::from_hz(6000)) /* a high value to ensure proper synchronization of the CPUs */
diff --git a/src/mame/drivers/gatron.c b/src/mame/drivers/gatron.c
index 721da7c69b7..49444be96c1 100644
--- a/src/mame/drivers/gatron.c
+++ b/src/mame/drivers/gatron.c
@@ -448,7 +448,7 @@ static MACHINE_CONFIG_START( gat, gatron_state )
MCFG_CPU_ADD("maincpu", Z80, MASTER_CLOCK/24) /* 666.66 kHz, guess */
MCFG_CPU_PROGRAM_MAP(gat_map)
MCFG_CPU_IO_MAP(gat_portmap)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gatron_state, nmi_line_pulse)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/gberet.c b/src/mame/drivers/gberet.c
index 32fb2b515fd..4639539a344 100644
--- a/src/mame/drivers/gberet.c
+++ b/src/mame/drivers/gberet.c
@@ -462,8 +462,8 @@ static MACHINE_CONFIG_START( gberetb, gberet_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_20MHz/4) // divider guessed
MCFG_CPU_PROGRAM_MAP(gberetb_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_assert)
- MCFG_CPU_PERIODIC_INT(nmi_line_assert, XTAL_20MHz/0x8000) // divider guessed
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gberet_state, irq0_line_assert)
+ MCFG_CPU_PERIODIC_INT_DRIVER(gberet_state, nmi_line_assert, XTAL_20MHz/0x8000) // divider guessed
MCFG_MACHINE_START_OVERRIDE(gberet_state,gberet)
MCFG_MACHINE_RESET_OVERRIDE(gberet_state,gberet)
diff --git a/src/mame/drivers/gbusters.c b/src/mame/drivers/gbusters.c
index 2e3f039a41c..a7b057edd18 100644
--- a/src/mame/drivers/gbusters.c
+++ b/src/mame/drivers/gbusters.c
@@ -19,12 +19,11 @@
/* prototypes */
static KONAMI_SETLINES_CALLBACK( gbusters_banking );
-static INTERRUPT_GEN( gbusters_interrupt )
+INTERRUPT_GEN_MEMBER(gbusters_state::gbusters_interrupt)
{
- gbusters_state *state = device->machine().driver_data<gbusters_state>();
- if (k052109_is_irq_enabled(state->m_k052109))
- device->execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
+ if (k052109_is_irq_enabled(m_k052109))
+ device.execute().set_input_line(KONAMI_IRQ_LINE, HOLD_LINE);
}
READ8_MEMBER(gbusters_state::bankedram_r)
@@ -303,7 +302,7 @@ static MACHINE_CONFIG_START( gbusters, gbusters_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", KONAMI, 3000000) /* Konami custom 052526 */
MCFG_CPU_PROGRAM_MAP(gbusters_map)
- MCFG_CPU_VBLANK_INT("screen", gbusters_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gbusters_state, gbusters_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 3579545) /* ? */
MCFG_CPU_PROGRAM_MAP(gbusters_sound_map)
diff --git a/src/mame/drivers/gcpinbal.c b/src/mame/drivers/gcpinbal.c
index 4a569b4cdf5..1daf1e46132 100644
--- a/src/mame/drivers/gcpinbal.c
+++ b/src/mame/drivers/gcpinbal.c
@@ -65,13 +65,13 @@ static TIMER_CALLBACK( gcpinbal_interrupt3 )
}
#endif
-static INTERRUPT_GEN( gcpinbal_interrupt )
+INTERRUPT_GEN_MEMBER(gcpinbal_state::gcpinbal_interrupt)
{
/* Unsure of actual sequence */
- device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(500), FUNC(gcpinbal_interrupt1));
-// device->machine().scheduler().timer_set(downcast<cpu_device *>(device)->cycles_to_attotime(1000), FUNC(gcpinbal_interrupt3));
- device->execute().set_input_line(4, HOLD_LINE);
+ machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(500), FUNC(gcpinbal_interrupt1));
+// machine().scheduler().timer_set(downcast<cpu_device *>(&device)->cycles_to_attotime(1000), FUNC(gcpinbal_interrupt3));
+ device.execute().set_input_line(4, HOLD_LINE);
}
@@ -439,7 +439,7 @@ static MACHINE_CONFIG_START( gcpinbal, gcpinbal_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 32000000/2) /* 16 MHz ? */
MCFG_CPU_PROGRAM_MAP(gcpinbal_map)
- MCFG_CPU_VBLANK_INT("screen", gcpinbal_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gcpinbal_state, gcpinbal_interrupt)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/gei.c b/src/mame/drivers/gei.c
index 10fb7779384..237d394f8f5 100644
--- a/src/mame/drivers/gei.c
+++ b/src/mame/drivers/gei.c
@@ -134,6 +134,7 @@ public:
DECLARE_DRIVER_INIT(setbank);
virtual void palette_init();
DECLARE_PALETTE_INIT(quizvid);
+ INTERRUPT_GEN_MEMBER(vblank_irq);
};
@@ -1105,19 +1106,18 @@ static I8255A_INTERFACE( findout_ppi8255_1_intf )
};
-static INTERRUPT_GEN( vblank_irq )
+INTERRUPT_GEN_MEMBER(gei_state::vblank_irq)
{
- gei_state *state = device->machine().driver_data<gei_state>();
- if(state->m_nmi_mask)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_mask)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( getrivia, gei_state )
MCFG_CPU_ADD("maincpu",Z80,4000000) /* 4 MHz */
MCFG_CPU_PROGRAM_MAP(getrivia_map)
- MCFG_CPU_VBLANK_INT("screen", vblank_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gei_state, vblank_irq)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/gijoe.c b/src/mame/drivers/gijoe.c
index f142369a499..2e29503340b 100644
--- a/src/mame/drivers/gijoe.c
+++ b/src/mame/drivers/gijoe.c
@@ -116,25 +116,24 @@ static TIMER_CALLBACK( dmaend_callback )
state->m_maincpu->set_input_line(6, HOLD_LINE);
}
-static INTERRUPT_GEN( gijoe_interrupt )
+INTERRUPT_GEN_MEMBER(gijoe_state::gijoe_interrupt)
{
- gijoe_state *state = device->machine().driver_data<gijoe_state>();
// global interrupt masking (*this game only)
- if (!k056832_is_irq_enabled(state->m_k056832, 0))
+ if (!k056832_is_irq_enabled(m_k056832, 0))
return;
- if (k053246_is_irq_enabled(state->m_k053246))
+ if (k053246_is_irq_enabled(m_k053246))
{
- gijoe_objdma(device->machine());
+ gijoe_objdma(machine());
// 42.7us(clr) + 341.3us(xfer) delay at 6Mhz dotclock
- state->m_dmadelay_timer->adjust(JOE_DMADELAY);
+ m_dmadelay_timer->adjust(JOE_DMADELAY);
}
// trigger V-blank interrupt
- if (state->m_cur_control2 & 0x0080)
- device->execute().set_input_line(5, HOLD_LINE);
+ if (m_cur_control2 & 0x0080)
+ device.execute().set_input_line(5, HOLD_LINE);
}
WRITE16_MEMBER(gijoe_state::sound_cmd_w)
@@ -296,7 +295,7 @@ static MACHINE_CONFIG_START( gijoe, gijoe_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 16000000) /* Confirmed */
MCFG_CPU_PROGRAM_MAP(gijoe_map)
- MCFG_CPU_VBLANK_INT("screen", gijoe_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gijoe_state, gijoe_interrupt)
MCFG_CPU_ADD("audiocpu", Z80, 8000000) /* Amuse & confirmed. z80e */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/ginganin.c b/src/mame/drivers/ginganin.c
index c83dd57e444..b494b16d7f7 100644
--- a/src/mame/drivers/ginganin.c
+++ b/src/mame/drivers/ginganin.c
@@ -261,7 +261,7 @@ static MACHINE_CONFIG_START( ginganin, ginganin_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, MAIN_CLOCK)
MCFG_CPU_PROGRAM_MAP(ginganin_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) /* ? (vectors 1-7 cointain the same address) */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", ginganin_state, irq1_line_hold) /* ? (vectors 1-7 cointain the same address) */
MCFG_CPU_ADD("audiocpu", M6809, SOUND_CLOCK)
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/gladiatr.c b/src/mame/drivers/gladiatr.c
index abf1671bd78..54cfe730581 100644
--- a/src/mame/drivers/gladiatr.c
+++ b/src/mame/drivers/gladiatr.c
@@ -666,12 +666,12 @@ static MACHINE_CONFIG_START( ppking, gladiatr_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(ppking_cpu1_map)
MCFG_CPU_IO_MAP(ppking_cpu1_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
MCFG_CPU_IO_MAP(ppking_cpu2_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", M6809, XTAL_12MHz/16) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(ppking_cpu3_map)
@@ -715,7 +715,7 @@ static MACHINE_CONFIG_START( gladiatr, gladiatr_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(gladiatr_cpu1_map)
MCFG_CPU_IO_MAP(gladiatr_cpu1_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gladiatr_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80, XTAL_12MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
diff --git a/src/mame/drivers/glass.c b/src/mame/drivers/glass.c
index 54a4168d9dd..8a4e6053d65 100644
--- a/src/mame/drivers/glass.c
+++ b/src/mame/drivers/glass.c
@@ -18,14 +18,13 @@ WRITE16_MEMBER(glass_state::clr_int_w)
m_cause_interrupt = 1;
}
-static INTERRUPT_GEN( glass_interrupt )
+INTERRUPT_GEN_MEMBER(glass_state::glass_interrupt)
{
- glass_state *state = device->machine().driver_data<glass_state>();
- if (state->m_cause_interrupt)
+ if (m_cause_interrupt)
{
- device->execute().set_input_line(6, HOLD_LINE);
- state->m_cause_interrupt = 0;
+ device.execute().set_input_line(6, HOLD_LINE);
+ m_cause_interrupt = 0;
}
}
@@ -196,7 +195,7 @@ static MACHINE_CONFIG_START( glass, glass_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,24000000/2) /* 12 MHz (M680000 P12) */
MCFG_CPU_PROGRAM_MAP(glass_map)
- MCFG_CPU_VBLANK_INT("screen", glass_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", glass_state, glass_interrupt)
/* video hardware */
diff --git a/src/mame/drivers/gng.c b/src/mame/drivers/gng.c
index 4e06e40b883..931889b63a7 100644
--- a/src/mame/drivers/gng.c
+++ b/src/mame/drivers/gng.c
@@ -343,11 +343,11 @@ static MACHINE_CONFIG_START( gng, gng_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6809, XTAL_12MHz/8) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(gng_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gng_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/4) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(gng_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/go2000.c b/src/mame/drivers/go2000.c
index 91524a70d04..2f84e2d2e8c 100644
--- a/src/mame/drivers/go2000.c
+++ b/src/mame/drivers/go2000.c
@@ -326,7 +326,7 @@ static MACHINE_CONFIG_START( go2000, go2000_state )
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(go2000_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", go2000_state, irq1_line_hold)
MCFG_CPU_ADD("soundcpu", Z80, 4000000)
MCFG_CPU_PROGRAM_MAP(go2000_sound_map)
diff --git a/src/mame/drivers/goal92.c b/src/mame/drivers/goal92.c
index d3b7afeaab6..c4e5ad72fbd 100644
--- a/src/mame/drivers/goal92.c
+++ b/src/mame/drivers/goal92.c
@@ -315,7 +315,7 @@ static MACHINE_CONFIG_START( goal92, goal92_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,12000000)
MCFG_CPU_PROGRAM_MAP(goal92_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold) /* VBL */
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goal92_state, irq6_line_hold) /* VBL */
MCFG_CPU_ADD("audiocpu", Z80, 2500000)
MCFG_CPU_PROGRAM_MAP(sound_cpu)
diff --git a/src/mame/drivers/goindol.c b/src/mame/drivers/goindol.c
index 5adb6525ff3..e1526623587 100644
--- a/src/mame/drivers/goindol.c
+++ b/src/mame/drivers/goindol.c
@@ -239,11 +239,11 @@ static MACHINE_CONFIG_START( goindol, goindol_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_12MHz/2) /* XTAL confirmed, divisor is not */
MCFG_CPU_PROGRAM_MAP(goindol_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goindol_state, irq0_line_hold)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_12MHz/2) /* XTAL confirmed, divisor is not */
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(goindol_state, irq0_line_hold, 4*60)
/* video hardware */
diff --git a/src/mame/drivers/goldngam.c b/src/mame/drivers/goldngam.c
index d8edff9974e..1cd8c14b8bc 100644
--- a/src/mame/drivers/goldngam.c
+++ b/src/mame/drivers/goldngam.c
@@ -560,7 +560,7 @@ static MACHINE_CONFIG_START( swisspkr, goldngam_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, MASTER_CLOCK)
MCFG_CPU_PROGRAM_MAP(swisspkr_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldngam_state, irq2_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/goldnpkr.c b/src/mame/drivers/goldnpkr.c
index 3273f937740..3fc4dc31e6a 100644
--- a/src/mame/drivers/goldnpkr.c
+++ b/src/mame/drivers/goldnpkr.c
@@ -3574,7 +3574,7 @@ static MACHINE_CONFIG_START( goldnpkr_base, goldnpkr_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M6502, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(goldnpkr_map)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldnpkr_state, nmi_line_pulse)
MCFG_NVRAM_ADD_0FILL("nvram")
diff --git a/src/mame/drivers/goldstar.c b/src/mame/drivers/goldstar.c
index 4fbdb1b23c5..609ba2ca0e8 100644
--- a/src/mame/drivers/goldstar.c
+++ b/src/mame/drivers/goldstar.c
@@ -5857,7 +5857,7 @@ static MACHINE_CONFIG_START( goldstar, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(goldstar_map)
MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
@@ -5891,7 +5891,7 @@ static MACHINE_CONFIG_START( goldstbl, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(goldstar_map)
MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
@@ -5924,7 +5924,7 @@ static MACHINE_CONFIG_START( moonlght, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(goldstar_map)
MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
@@ -6018,7 +6018,7 @@ static MACHINE_CONFIG_START( chrygld, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(ncb3_map)
MCFG_CPU_IO_MAP(ncb3_readwriteport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
@@ -6060,7 +6060,7 @@ static MACHINE_CONFIG_START( cb3c, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(ncb3_map)
MCFG_CPU_IO_MAP(ncb3_readwriteport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
@@ -6101,7 +6101,7 @@ static MACHINE_CONFIG_START( ncb3, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(ncb3_map)
MCFG_CPU_IO_MAP(ncb3_readwriteport)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", ncb3_ppi8255_0_intf )
@@ -6143,7 +6143,7 @@ static MACHINE_CONFIG_START( cm, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(cm_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6183,7 +6183,7 @@ static MACHINE_CONFIG_START( cmnobmp, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(cm_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6218,7 +6218,7 @@ static MACHINE_CONFIG_START( cmast91, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(cmast91_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6246,12 +6246,11 @@ static MACHINE_CONFIG_START( cmast91, goldstar_state )
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50)
MACHINE_CONFIG_END
-static INTERRUPT_GEN( lucky8_irq )
+INTERRUPT_GEN_MEMBER(goldstar_state::lucky8_irq)
{
- goldstar_state *state = device->machine().driver_data<goldstar_state>();
- if(state->m_lucky8_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_lucky8_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
static MACHINE_CONFIG_START( lucky8, goldstar_state )
@@ -6260,7 +6259,7 @@ static MACHINE_CONFIG_START( lucky8, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(lucky8_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
@@ -6300,7 +6299,7 @@ static MACHINE_CONFIG_START( bingowng, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(lucky8_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
@@ -6340,7 +6339,7 @@ static MACHINE_CONFIG_START( bingownga, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(lucky8_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
@@ -6397,7 +6396,7 @@ static MACHINE_CONFIG_START( magodds, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(magodds_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", lucky8_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, lucky8_irq)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
@@ -6438,7 +6437,7 @@ static MACHINE_CONFIG_START( kkotnoli, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(kkotnoli_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
/* 3x 8255 */
@@ -6476,7 +6475,7 @@ static MACHINE_CONFIG_START( ladylinr, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(ladylinr_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", ladylinr_ppi8255_0_intf )
@@ -6516,7 +6515,7 @@ static MACHINE_CONFIG_START( wcat3, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(wcat3_map)
//MCFG_CPU_IO_MAP(goldstar_readport)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
/* 3x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", lucky8_ppi8255_0_intf )
@@ -6559,7 +6558,7 @@ static MACHINE_CONFIG_START( amcoe1, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(amcoe1_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6598,7 +6597,7 @@ static MACHINE_CONFIG_START( amcoe1a, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(amcoe1_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6637,7 +6636,7 @@ static MACHINE_CONFIG_START( amcoe2, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(amcoe2_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6671,7 +6670,7 @@ static MACHINE_CONFIG_START( nfm, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(nfm_map)
MCFG_CPU_IO_MAP(amcoe2_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
@@ -6705,8 +6704,8 @@ static MACHINE_CONFIG_START( unkch, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(unkch_map)
MCFG_CPU_IO_MAP(unkch_portmap)
- MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
- //MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, nmi_line_pulse)
+ //MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
@@ -6750,7 +6749,7 @@ static MACHINE_CONFIG_START( pkrmast, goldstar_state )
MCFG_CPU_ADD("maincpu", Z80, CPU_CLOCK)
MCFG_CPU_PROGRAM_MAP(cm_map)
MCFG_CPU_IO_MAP(cm_portmap)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goldstar_state, irq0_line_hold)
/* 2x 8255 */
MCFG_I8255A_ADD( "ppi8255_0", cm_ppi8255_0_intf )
diff --git a/src/mame/drivers/gomoku.c b/src/mame/drivers/gomoku.c
index 3e71131b95a..53de11e3a70 100644
--- a/src/mame/drivers/gomoku.c
+++ b/src/mame/drivers/gomoku.c
@@ -121,7 +121,7 @@ static MACHINE_CONFIG_START( gomoku, gomoku_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80, XTAL_18_432MHz/12) /* 1.536 MHz ? */
MCFG_CPU_PROGRAM_MAP(gomoku_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gomoku_state, irq0_line_hold)
/* video hardware */
MCFG_SCREEN_ADD("screen", RASTER)
diff --git a/src/mame/drivers/good.c b/src/mame/drivers/good.c
index 3f2280b1de2..a093a1cd3de 100644
--- a/src/mame/drivers/good.c
+++ b/src/mame/drivers/good.c
@@ -279,7 +279,7 @@ static MACHINE_CONFIG_START( good, good_state )
MCFG_CPU_ADD("maincpu", M68000, 16000000 /2)
MCFG_CPU_PROGRAM_MAP(good_map)
- MCFG_CPU_VBLANK_INT("screen", irq2_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", good_state, irq2_line_hold)
MCFG_GFXDECODE(good)
diff --git a/src/mame/drivers/goodejan.c b/src/mame/drivers/goodejan.c
index 7da260070ea..12ffa8d90bf 100644
--- a/src/mame/drivers/goodejan.c
+++ b/src/mame/drivers/goodejan.c
@@ -67,6 +67,7 @@ public:
DECLARE_WRITE16_MEMBER(goodejan_gfxbank_w);
DECLARE_READ16_MEMBER(mahjong_panel_r);
DECLARE_WRITE16_MEMBER(mahjong_panel_w);
+ INTERRUPT_GEN_MEMBER(goodejan_irq);
};
@@ -329,9 +330,9 @@ static GFXDECODE_START( goodejan )
GFXDECODE_ENTRY( "tx_gfx", 0, charlayout, 0x100, 0x10 ) /* Text */
GFXDECODE_END
-static INTERRUPT_GEN( goodejan_irq )
+INTERRUPT_GEN_MEMBER(goodejan_state::goodejan_irq)
{
- device->execute().set_input_line_and_vector(0,HOLD_LINE,0x208/4);
+ device.execute().set_input_line_and_vector(0,HOLD_LINE,0x208/4);
/* vector 0x00c is just a reti */
}
@@ -341,7 +342,7 @@ static MACHINE_CONFIG_START( goodejan, goodejan_state )
MCFG_CPU_ADD("maincpu", V30, GOODEJAN_MHZ2/2)
MCFG_CPU_PROGRAM_MAP(goodejan_map)
MCFG_CPU_IO_MAP(goodejan_io_map)
- MCFG_CPU_VBLANK_INT("screen",goodejan_irq)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", goodejan_state, goodejan_irq)
SEIBU_SOUND_SYSTEM_CPU(GOODEJAN_MHZ1/2)
diff --git a/src/mame/drivers/gotcha.c b/src/mame/drivers/gotcha.c
index 054893a57e2..b5250be802e 100644
--- a/src/mame/drivers/gotcha.c
+++ b/src/mame/drivers/gotcha.c
@@ -278,11 +278,11 @@ static MACHINE_CONFIG_START( gotcha, gotcha_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000,14318180) /* 14.31818 MHz */
MCFG_CPU_PROGRAM_MAP(gotcha_map)
- MCFG_CPU_VBLANK_INT("screen", irq6_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gotcha_state, irq6_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,6000000) /* 6 MHz */
MCFG_CPU_PROGRAM_MAP(sound_map)
-// MCFG_CPU_VBLANK_INT("screen", nmi_line_pulse)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gotcha_state, nmi_line_pulse)
/* video hardware */
diff --git a/src/mame/drivers/gottlieb.c b/src/mame/drivers/gottlieb.c
index 942f5d81831..9ec580957d0 100644
--- a/src/mame/drivers/gottlieb.c
+++ b/src/mame/drivers/gottlieb.c
@@ -657,21 +657,20 @@ static TIMER_CALLBACK( nmi_clear )
}
-static INTERRUPT_GEN( gottlieb_interrupt )
+INTERRUPT_GEN_MEMBER(gottlieb_state::gottlieb_interrupt)
{
- gottlieb_state *state = device->machine().driver_data<gottlieb_state>();
/* assert the NMI and set a timer to clear it at the first visible line */
- device->execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
- device->machine().scheduler().timer_set(device->machine().primary_screen->time_until_pos(0), FUNC(nmi_clear));
+ device.execute().set_input_line(INPUT_LINE_NMI, ASSERT_LINE);
+ machine().scheduler().timer_set(machine().primary_screen->time_until_pos(0), FUNC(nmi_clear));
/* if we have a laserdisc, update it */
- if (state->m_laserdisc != NULL)
+ if (m_laserdisc != NULL)
{
/* set the "disc ready" bit, which basically indicates whether or not we have a proper video frame */
- if (!state->m_laserdisc->video_active())
- state->m_laserdisc_status &= ~0x20;
+ if (!m_laserdisc->video_active())
+ m_laserdisc_status &= ~0x20;
else
- state->m_laserdisc_status |= 0x20;
+ m_laserdisc_status |= 0x20;
}
}
@@ -1711,7 +1710,7 @@ static MACHINE_CONFIG_START( gottlieb_core, gottlieb_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", I8088, CPU_CLOCK/3)
MCFG_CPU_PROGRAM_MAP(gottlieb_map)
- MCFG_CPU_VBLANK_INT("screen", gottlieb_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gottlieb_state, gottlieb_interrupt)
MCFG_NVRAM_ADD_1FILL("nvram")
MCFG_WATCHDOG_VBLANK_INIT(16)
diff --git a/src/mame/drivers/gotya.c b/src/mame/drivers/gotya.c
index 1472cccfbc2..00c740bc8cc 100644
--- a/src/mame/drivers/gotya.c
+++ b/src/mame/drivers/gotya.c
@@ -195,7 +195,7 @@ static MACHINE_CONFIG_START( gotya, gotya_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", Z80,18432000/6) /* 3.072 MHz ??? */
MCFG_CPU_PROGRAM_MAP(gotya_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gotya_state, irq0_line_hold)
/* video hardware */
diff --git a/src/mame/drivers/gpworld.c b/src/mame/drivers/gpworld.c
index dc26dab3482..61f79def776 100644
--- a/src/mame/drivers/gpworld.c
+++ b/src/mame/drivers/gpworld.c
@@ -72,6 +72,7 @@ public:
DECLARE_DRIVER_INIT(gpworld);
virtual void machine_start();
UINT32 screen_update_gpworld(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
+ INTERRUPT_GEN_MEMBER(vblank_callback_gpworld);
};
@@ -429,20 +430,19 @@ static TIMER_CALLBACK( irq_stop )
machine.device("maincpu")->execute().set_input_line(0, CLEAR_LINE);
}
-static INTERRUPT_GEN( vblank_callback_gpworld )
+INTERRUPT_GEN_MEMBER(gpworld_state::vblank_callback_gpworld)
{
- gpworld_state *state = device->machine().driver_data<gpworld_state>();
/* Do an NMI if the enabled bit is set */
- if (state->m_nmi_enable)
+ if (m_nmi_enable)
{
- state->m_laserdisc->data_w(state->m_ldp_write_latch);
- state->m_ldp_read_latch = state->m_laserdisc->status_r();
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ m_laserdisc->data_w(m_ldp_write_latch);
+ m_ldp_read_latch = m_laserdisc->status_r();
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
/* The time the IRQ line stays high is set just long enough to happen after the NMI - hacky? */
- device->execute().set_input_line(0, ASSERT_LINE);
- device->machine().scheduler().timer_set(attotime::from_usec(100), FUNC(irq_stop));
+ device.execute().set_input_line(0, ASSERT_LINE);
+ machine().scheduler().timer_set(attotime::from_usec(100), FUNC(irq_stop));
}
static const gfx_layout gpworld_tile_layout =
@@ -467,7 +467,7 @@ static MACHINE_CONFIG_START( gpworld, gpworld_state )
MCFG_CPU_ADD("maincpu", Z80, GUESSED_CLOCK)
MCFG_CPU_PROGRAM_MAP(mainmem)
MCFG_CPU_IO_MAP(mainport)
- MCFG_CPU_VBLANK_INT("screen", vblank_callback_gpworld)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gpworld_state, vblank_callback_gpworld)
MCFG_LASERDISC_LDV1000_ADD("laserdisc")
diff --git a/src/mame/drivers/gradius3.c b/src/mame/drivers/gradius3.c
index 61d8e5a641d..32e62d7e34d 100644
--- a/src/mame/drivers/gradius3.c
+++ b/src/mame/drivers/gradius3.c
@@ -99,11 +99,10 @@ WRITE16_MEMBER(gradius3_state::cpuB_irqenable_w)
m_irqBmask = (data >> 8) & 0x07;
}
-static INTERRUPT_GEN( cpuA_interrupt )
+INTERRUPT_GEN_MEMBER(gradius3_state::cpuA_interrupt)
{
- gradius3_state *state = device->machine().driver_data<gradius3_state>();
- if (state->m_irqAen)
- device->execute().set_input_line(2, HOLD_LINE);
+ if (m_irqAen)
+ device.execute().set_input_line(2, HOLD_LINE);
}
@@ -317,7 +316,7 @@ static MACHINE_CONFIG_START( gradius3, gradius3_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68000, 10000000) /* 10 MHz */
MCFG_CPU_PROGRAM_MAP(gradius3_map)
- MCFG_CPU_VBLANK_INT("screen", cpuA_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gradius3_state, cpuA_interrupt)
MCFG_CPU_ADD("sub", M68000, 10000000) /* 10 MHz */
MCFG_CPU_PROGRAM_MAP(gradius3_map2)
diff --git a/src/mame/drivers/grchamp.c b/src/mame/drivers/grchamp.c
index f4b672db7ab..fb0b2fe1123 100644
--- a/src/mame/drivers/grchamp.c
+++ b/src/mame/drivers/grchamp.c
@@ -90,21 +90,19 @@ void grchamp_state::machine_reset()
*
*************************************/
-static INTERRUPT_GEN( grchamp_cpu0_interrupt )
+INTERRUPT_GEN_MEMBER(grchamp_state::grchamp_cpu0_interrupt)
{
- grchamp_state *state = device->machine().driver_data<grchamp_state>();
- if (state->m_cpu0_out[0] & 0x01)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if (m_cpu0_out[0] & 0x01)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
-static INTERRUPT_GEN( grchamp_cpu1_interrupt )
+INTERRUPT_GEN_MEMBER(grchamp_state::grchamp_cpu1_interrupt)
{
- grchamp_state *state = device->machine().driver_data<grchamp_state>();
- if (state->m_cpu1_out[4] & 0x01)
- device->execute().set_input_line(0, ASSERT_LINE);
+ if (m_cpu1_out[4] & 0x01)
+ device.execute().set_input_line(0, ASSERT_LINE);
}
@@ -671,18 +669,18 @@ static MACHINE_CONFIG_START( grchamp, grchamp_state )
MCFG_CPU_ADD("maincpu", Z80, PIXEL_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(main_map)
MCFG_CPU_IO_MAP(main_portmap)
- MCFG_CPU_VBLANK_INT("screen", grchamp_cpu0_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", grchamp_state, grchamp_cpu0_interrupt)
/* GAME BOARD */
MCFG_CPU_ADD("sub", Z80, PIXEL_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(sub_map)
MCFG_CPU_IO_MAP(sub_portmap)
- MCFG_CPU_VBLANK_INT("screen", grchamp_cpu1_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", grchamp_state, grchamp_cpu1_interrupt)
/* SOUND BOARD */
MCFG_CPU_ADD("audiocpu", Z80, SOUND_CLOCK/2)
MCFG_CPU_PROGRAM_MAP(sound_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold, (double)SOUND_CLOCK/4/16/16/10/16)
+ MCFG_CPU_PERIODIC_INT_DRIVER(grchamp_state, irq0_line_hold, (double)SOUND_CLOCK/4/16/16/10/16)
MCFG_WATCHDOG_VBLANK_INIT(8)
MCFG_QUANTUM_TIME(attotime::from_hz(6000))
diff --git a/src/mame/drivers/groundfx.c b/src/mame/drivers/groundfx.c
index 45046dd2bdf..510b10b4a0e 100644
--- a/src/mame/drivers/groundfx.c
+++ b/src/mame/drivers/groundfx.c
@@ -354,11 +354,10 @@ static const tc0480scp_interface groundfx_tc0480scp_intf =
0 /* col_base */
};
-static INTERRUPT_GEN( groundfx_interrupt )
+INTERRUPT_GEN_MEMBER(groundfx_state::groundfx_interrupt)
{
- groundfx_state *state = device->machine().driver_data<groundfx_state>();
- state->m_frame_counter^=1;
- device->execute().set_input_line(4, HOLD_LINE);
+ m_frame_counter^=1;
+ device.execute().set_input_line(4, HOLD_LINE);
}
static MACHINE_CONFIG_START( groundfx, groundfx_state )
@@ -366,7 +365,7 @@ static MACHINE_CONFIG_START( groundfx, groundfx_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", M68EC020, 16000000) /* 16 MHz */
MCFG_CPU_PROGRAM_MAP(groundfx_map)
- MCFG_CPU_VBLANK_INT("screen", groundfx_interrupt)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", groundfx_state, groundfx_interrupt)
MCFG_EEPROM_ADD("eeprom", groundfx_eeprom_interface)
diff --git a/src/mame/drivers/gstream.c b/src/mame/drivers/gstream.c
index 8000adf7aa4..2b65f3ecbd5 100644
--- a/src/mame/drivers/gstream.c
+++ b/src/mame/drivers/gstream.c
@@ -565,7 +565,7 @@ static MACHINE_CONFIG_START( gstream, gstream_state )
MCFG_CPU_ADD("maincpu", E132XT, 16000000*4) /* 4x internal multiplier */
MCFG_CPU_PROGRAM_MAP(gstream_32bit_map)
MCFG_CPU_IO_MAP(gstream_io)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gstream_state, irq0_line_hold)
MCFG_NVRAM_ADD_1FILL("nvram")
diff --git a/src/mame/drivers/gstriker.c b/src/mame/drivers/gstriker.c
index 745111bd3ac..d9ed0a29b42 100644
--- a/src/mame/drivers/gstriker.c
+++ b/src/mame/drivers/gstriker.c
@@ -542,7 +542,7 @@ INPUT_PORTS_END
static MACHINE_CONFIG_START( gstriker, gstriker_state )
MCFG_CPU_ADD("maincpu", M68000, 10000000)
MCFG_CPU_PROGRAM_MAP(gstriker_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gstriker_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
@@ -580,7 +580,7 @@ MACHINE_CONFIG_END
static MACHINE_CONFIG_START( vgoal, gstriker_state )
MCFG_CPU_ADD("maincpu", M68000, 16000000)
MCFG_CPU_PROGRAM_MAP(vgoal_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gstriker_state, irq1_line_hold)
MCFG_CPU_ADD("audiocpu", Z80,8000000/2) /* 4 MHz ??? */
MCFG_CPU_PROGRAM_MAP(sound_map)
diff --git a/src/mame/drivers/gsword.c b/src/mame/drivers/gsword.c
index 4552dcaa7bf..ec0c06865ac 100644
--- a/src/mame/drivers/gsword.c
+++ b/src/mame/drivers/gsword.c
@@ -247,12 +247,11 @@ MACHINE_RESET_MEMBER(gsword_state,josvolly)
josvolly_8741_reset();
}
-static INTERRUPT_GEN( gsword_snd_interrupt )
+INTERRUPT_GEN_MEMBER(gsword_state::gsword_snd_interrupt)
{
- gsword_state *state = device->machine().driver_data<gsword_state>();
- if(state->m_nmi_enable)
- device->execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
+ if(m_nmi_enable)
+ device.execute().set_input_line(INPUT_LINE_NMI, PULSE_LINE);
}
WRITE8_MEMBER(gsword_state::gsword_nmi_set_w)
@@ -661,12 +660,12 @@ static MACHINE_CONFIG_START( gsword, gsword_state )
MCFG_CPU_ADD("maincpu", Z80, XTAL_18MHz/6) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
MCFG_CPU_IO_MAP(cpu1_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gsword_state, irq0_line_hold)
MCFG_CPU_ADD("sub", Z80, XTAL_18MHz/6) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu2_map)
MCFG_CPU_IO_MAP(cpu2_io_map)
- MCFG_CPU_PERIODIC_INT(gsword_snd_interrupt,4*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(gsword_state, gsword_snd_interrupt, 4*60)
MCFG_CPU_ADD("audiocpu", Z80, XTAL_18MHz/6) /* verified on pcb */
MCFG_CPU_PROGRAM_MAP(cpu3_map)
@@ -714,12 +713,12 @@ static MACHINE_CONFIG_START( josvolly, gsword_state )
MCFG_CPU_ADD("maincpu", Z80, 18000000/6) /* ? */
MCFG_CPU_PROGRAM_MAP(cpu1_map)
MCFG_CPU_IO_MAP(josvolly_cpu1_io_map)
- MCFG_CPU_PERIODIC_INT(irq0_line_hold,2*60)
+ MCFG_CPU_PERIODIC_INT_DRIVER(gsword_state, irq0_line_hold, 2*60)
MCFG_CPU_ADD("audiocpu", Z80, 12000000/4) /* ? */
MCFG_CPU_PROGRAM_MAP(josvolly_cpu2_map)
MCFG_CPU_IO_MAP(josvolly_cpu2_io_map)
- MCFG_CPU_VBLANK_INT("screen", irq0_line_hold)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gsword_state, irq0_line_hold)
MCFG_MACHINE_RESET_OVERRIDE(gsword_state,josvolly)
diff --git a/src/mame/drivers/gticlub.c b/src/mame/drivers/gticlub.c
index 11d30c08207..171f213dfe0 100644
--- a/src/mame/drivers/gticlub.c
+++ b/src/mame/drivers/gticlub.c
@@ -263,6 +263,7 @@ public:
DECLARE_MACHINE_START(gticlub);
DECLARE_MACHINE_RESET(gticlub);
DECLARE_MACHINE_RESET(hangplt);
+ INTERRUPT_GEN_MEMBER(gticlub_vblank);
};
@@ -694,9 +695,9 @@ INPUT_PORTS_END
DMA0
*/
-static INTERRUPT_GEN( gticlub_vblank )
+INTERRUPT_GEN_MEMBER(gticlub_state::gticlub_vblank)
{
- device->execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
+ device.execute().set_input_line(INPUT_LINE_IRQ0, ASSERT_LINE);
}
@@ -806,7 +807,7 @@ static MACHINE_CONFIG_START( gticlub, gticlub_state )
/* basic machine hardware */
MCFG_CPU_ADD("maincpu", PPC403GA, 64000000/2) /* PowerPC 403GA 32MHz */
MCFG_CPU_PROGRAM_MAP(gticlub_map)
- MCFG_CPU_VBLANK_INT("screen", gticlub_vblank)
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gticlub_state, gticlub_vblank)
MCFG_CPU_ADD("audiocpu", M68000, 64000000/4) /* 16MHz */
MCFG_CPU_PROGRAM_MAP(sound_memmap)
diff --git a/src/mame/drivers/gumbo.c b/src/mame/drivers/gumbo.c
index 8029f277444..f069dadde8e 100644
--- a/src/mame/drivers/gumbo.c
+++ b/src/mame/drivers/gumbo.c
@@ -231,7 +231,7 @@ static MACHINE_CONFIG_START( gumbo, gumbo_state )
MCFG_CPU_ADD("maincpu", M68000, 14318180 /2) // or 10mhz? ?
MCFG_CPU_PROGRAM_MAP(gumbo_map)
- MCFG_CPU_VBLANK_INT("screen", irq1_line_hold) // all the same
+ MCFG_CPU_VBLANK_INT_DRIVER("screen", gumbo_state, irq1_line_hold) // all the same
MCFG_GFXDECODE(gumbo)
diff --git a/src/mame/drivers/gunbustr.c b/src/mame/drivers/gunbustr.c
index d87e9ee07d5..c79e8cf1dbd 100644
--- a/src/mame/drivers/gunbustr.c
+++ b/src/mame/drivers/gunbustr.c
@@ -57,10 +57,10 @@ static TIMER_CALLBACK( gunbustr_interrupt5 )
machine.device("maincpu")->execute().set_input_line(5, HOLD_LINE);
}
-static INTERRUPT_GEN( gunbustr_interrupt )
+INTERRUPT_GEN_MEMBER(gunbustr_state::gunbustr_interrupt)
{