| Previous | 15994 Revisions | Next |
| r3233 Thursday 11th September, 2008 at 23:52:28 UTC by Nathan Woods |
|---|
| Updated to MAME 0.127u3 core |
| [docs] | messnew.txt |
| [src/emu] | audit.c cheat.c clifront.c cpuexec.c cpuintrf.c crsshair.c devintrf.c devintrf.h info.c inptport.c inptport.h input.c input.h mame.c mamecore.h mconfig.c mconfig.h memory.c memory.h profiler.c profiler.h render.c render.h rendlay.c rendlay.h romload.c romload.h sound.c sound.h state.c state.h streams.c streams.h timer.c timer.h ui.c uigfx.c uiinput.c uiinput.h uimenu.c uimenu.h validity.c video.c video.h watchdog.c |
| [src/emu/cpu] | drcbex64.c drcbex86.c drcuml.c |
| [src/emu/cpu/cubeqcpu] | cubeqcpu.c |
| [src/emu/cpu/i8085] | i8085.c i8085.h i8085cpu.h |
| [src/emu/cpu/jaguar] | jaguar.c |
| [src/emu/cpu/mcs48] | mcs48.c mcs48.h |
| [src/emu/cpu/powerpc] | drc_ops.c ppcdrc.c |
| [src/emu/debug] | debugcmd.c debugcon.c debugcon.h debugcpu.c express.c |
| [src/emu/drivers] | empty.c |
| [src/emu/machine] | 6532riot.c 68681.c 8237dma.c 8255ppi.c 8257dma.c at28c16.c cdp1852.c idectrl.c laserdsc.c laserdsc.h latch8.c ldcore.c ldcore.h ldpr8210.c ldv1000.c msm6242.c pic8259.c pit8253.c smc91c9x.c timekpr.c z80dma.c |
| [src/emu/sound] | c352.c |
| [src/emu/video] | cdp1869.c mc6845.c voodoo.c |
| [src/ldplayer] | ldplayer.c ldplayer.mak |
| [src/ldplayer/layout] | pr8210.lay* |
| [src/lib/util] | corefile.c |
| [src/mame] | mame.mak mamedriv.c |
| [src/mame/audio] | atarijsa.c gottlieb.c mario.c mw8080bw.c namco54.h scramble.c t5182.h |
| [src/mame/drivers] | alg.c amspdwy.c angelkds.c arabian.c arcadia.c astrof.c atarig1.c atarig42.c atarisy1.c atarisy2.c balsente.c bbusters.c bfcobra.c bfm_sc2.c bishjan.c bladestl.c blstroid.c boogwing.c btime.c bzone.c cabal.c cave.c ccastles.c centiped.c champbas.c cidelsa.c cliffhgr.c cntsteer.c combatsc.c compgolf.c cop01.c cosmic.c cps1.c cps3.c crgolf.c cubeqst.c cultures.c darius.c darkhors.c darkmist.c ddenlovr.c dgpix.c djmain.c dlair.c dragrace.c dynax.c eprom.c equites.c esh.c fastfred.c filetto.c firebeat.c foodf.c fromance.c galaga.c gamecstl.c gameplan.c gomoku.c gottlieb.c gpworld.c gridlee.c guab.c halleys.c hitme.c hnayayoi.c homedata.c igs_180.c igs_blit.c istellar.c jack.c jailbrek.c kingpin.c kinst.c konamigv.c konamigx.c ksys573.c laserbat.c lethal.c lethalj.c lgp.c limenko.c lwings.c m72.c m90.c magic10.c mainsnk.c mario.c mazerbla.c mcr68.c mediagx.c megadriv.c megaplay.c megasys1.c megatech.c micro3d.c midvunit.c mirax.c mitchell.c mjkjidai.c mjsister.c model1.c model2.c model3.c mpu4.c mpu4drvr.c multigam.c munchmo.c mustache.c mw8080bw.c namcona1.c namcos21.c naomi.c nbmj8688.c neodrvr.c neogeo.c ninjakd2.c ninjaw.c ojankohs.c orbit.c othunder.c pacland.c panicr.c pasha2.c peplus.c poolshrk.c prehisle.c psikyo.c punchout.c quizdna.c raiden2.c rmhaihai.c rockola.c royalmah.c sbasketb.c scobra.c scramble.c sderby.c seattle.c segac2.c segae.c segag80r.c segahang.c segald.c segaorun.c segas16a.c segas16b.c segas18.c segas24.c segaybd.c seta.c shadfrce.c sidearms.c simpl156.c slapfght.c slapshot.c snk.c snk68.c snowbros.c sprcros2.c sprint8.c srmp2.c srmp6.c sspeedr.c ssrj.c ssv.c stv.c suna16.c suna8.c superdq.c system1.c system18.c taito_h.c taito_x.c taito_z.c taitoair.c taitojc.c taitowlf.c tankbust.c tatsumi.c tceptor.c terracre.c thayers.c tiamc1.c tnzs.c tourtabl.c trackfld.c trvmadns.c tsamurai.c tumbleb.c tx1.c vegas.c videopkr.c warpwarp.c warriorb.c welltris.c wgp.c wiping.c witch.c wwfwfest.c xexex.c yumefuda.c zaccaria.c zn.c zr107.c |
| [src/mame/includes] | mario.h neogeo.h wwfwfest.h |
| [src/mame/layout] | pmroulet.lay* sderby.lay* sgsafari.lay* spacewin.lay* |
| [src/mame/machine] | ajax.c balsente.c bublbobl.c carpolo.c decocass.c fd1089.c fddebug.c galaxold.c harddriv.c leland.c midtunit.c midwunit.c midyunit.c n64.c namco50.h neoboot.c neoprot.c vertigo.c vsnes.c |
| [src/mame/video] | 40love.c atarisy1.c combatsc.c dynax.c fastfred.c itech8.c jackal.c lethalj.c lordgun.c m90.c mainsnk.c munchmo.c nbmj8688.c qix.c taitojc.c tceptor.c wwfwfest.c |
| [src/mess] | device.c filemngr.c inputx.c mess.c mess.mak tapectrl.c uimess.c |
| [src/mess/audio] | lmc1992.c |
| [src/mess/devices] | appldriv.c basicdsk.c bitbngr.c cartslot.c cassette.c chd_cd.c coco_vhd.c dsk.c harddriv.c kermit.c mflopimg.c microdrv.c printer.c snapquik.c xmodem.c |
| [src/mess/drivers] | a2600.c advision.c apexc.c gamepock.c glasgow.c |
| [src/mess/formats] | thom_dsk.c |
| [src/mess/machine] | 68901mfp.c 8530scc.c 990_tap.c a7800.c adc080x.c advision.c amigafdc.c ap2_lang.c ap2_slot.c applefdc.c ay31015.c c128.c c64.c cbmserb.c cdp1871.c d88.c dgn_beta.c e0516.c gamecom.c gb.c hd63450.c hp48.c ins8154.c ins8250.c intv.c mockngbd.c nc.c ncr5380.c nes.c oric.c pdp1.c pokemini.c serial.c smartmed.c sms.c svi318.c thomson.c ti85.c ti99_4x.c tx0.c vc20.c wswan.c x68k_hdc.c zx8302.c |
| [src/mess/video] | cdp1861.c cdp1864.c crtc_ega.c dgn_beta.c dl1416.c i8275.c m6847.c msm6255.c zx8301.c |
| [src/osd/windows] | debugwin.c drawgdi.c drawnone.c input.c ledutil.c window.c |
| [src/osd/winui] | mui_util.c treeview.c |
| r3232 | r3233 | |
|---|---|---|
| 152 | 152 | |
| 153 | 153 | /* initialize JSA III ADPCM */ |
| 154 | 154 | { |
| 155 | static const char *regions[] = { "adpcm", "adcpml", "adpcmr" }; | |
| 155 | static const char *const regions[] = { "adpcm", "adcpml", "adpcmr" }; | |
| 156 | 156 | int rgn; |
| 157 | 157 | |
| 158 | 158 | /* expand the ADPCM data to avoid lots of memcpy's during gameplay */ |
| r3232 | r3233 | |
|---|---|---|
| 3 | 3 | |
| 4 | 4 | #include "sound/discrete.h" |
| 5 | 5 | |
| 6 | #define CPUTAG_54XX "54 | |
| 6 | #define CPUTAG_54XX "54xx" | |
| 7 | 7 | |
| 8 | 8 | ADDRESS_MAP_EXTERN( namco_54xx_map_program, 8 ); |
| 9 | 9 | ADDRESS_MAP_EXTERN( namco_54xx_map_data, 8 ); |
| r3232 | r3233 | |
|---|---|---|
| 2 | 2 | #include "sound/2151intf.h" |
| 3 | 3 | |
| 4 | 4 | |
| 5 | #define CPUTAG_T5182 " | |
| 5 | #define CPUTAG_T5182 "t5182" | |
| 6 | 6 | #define T5182COINPORT "T5182_COIN" |
| 7 | 7 | |
| 8 | 8 | ADDRESS_MAP_EXTERN( t5182_map, 8 ); |
| r3232 | r3233 | |
|---|---|---|
| 309 | 309 | * static const int prom[16] = {0x00, 0x00, 0x02, 0x00, 0x00, 0x02, 0x00, 0x00, |
| 310 | 310 | * 0x02, 0x00, 0x40, 0x00, 0x04, 0x06, 0x04, 0x84 }; |
| 311 | 311 | */ |
| 312 | UINT8 *prom = memory_region(machine, " | |
| 312 | UINT8 *prom = memory_region(machine, " | |
| 313 | 313 | UINT8 ctrl; |
| 314 | 314 | |
| 315 | 315 | if (param == 0) |
| r3232 | r3233 | |
|---|---|---|
| 240 | 240 | |
| 241 | 241 | static void set_ea(running_machine *machine, int ea) |
| 242 | 242 | { |
| 243 | mario_state *state = machine->driver_data; | |
| 243 | 244 | //printf("ea: %d\n", ea); |
| 244 | cputag_set_input_line(machine, "audio", MCS48_INPUT_EA, (ea) ? ASSERT_LINE : CLEAR_LINE); | |
| 245 | //memory_set_bank(MCS48_INTERNAL_ROMBANK, ea); | |
| 245 | //cputag_set_input_line(machine, "audio", MCS48_INPUT_EA, (ea) ? ASSERT_LINE : CLEAR_LINE); | |
| 246 | if (state->eabank != 0) | |
| 247 | memory_set_bank(state->eabank, ea); | |
| 246 | 248 | } |
| 247 | 249 | |
| 248 | 250 | /**************************************************************** |
| r3232 | r3233 | |
| 254 | 256 | static SOUND_START( mario ) |
| 255 | 257 | { |
| 256 | 258 | mario_state *state = machine->driver_data; |
| 259 | int audiocpu = mame_find_cpu_index(machine, "audio"); | |
| 257 | 260 | #if USE_8039 |
| 258 | 261 | UINT8 *SND = memory_region(machine, "audio"); |
| 259 | 262 | |
| 260 | 263 | SND[0x1001] = 0x01; |
| 261 | 264 | #endif |
| 262 | 265 | |
| 263 | memory_configure_bank(MCS48_INTERNAL_ROMBANK, 0, 1, memory_region(machine, "audio"), 0); | |
| 264 | memory_configure_bank(MCS48_INTERNAL_ROMBANK, 1, 1, memory_region(machine, "audio") + 0x1000, 0x800); | |
| 266 | state->eabank = 0; | |
| 267 | if (audiocpu != -1 && machine->config->cpu[audiocpu].type != CPU_Z80) | |
| 268 | { | |
| 269 | state->eabank = 1; | |
| 270 | memory_configure_bank(1, 0, 1, memory_region(machine, "audio"), 0); | |
| 271 | memory_configure_bank(1, 1, 1, memory_region(machine, "audio") + 0x1000, 0x800); | |
| 272 | } | |
| 265 | 273 | |
| 266 | 274 | state_save_register_global(state->last); |
| 267 | 275 | state_save_register_global(state->portT); |
| r3232 | r3233 | |
| 418 | 426 | *************************************/ |
| 419 | 427 | |
| 420 | 428 | static ADDRESS_MAP_START( mario_sound_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| 421 | #if USE_8039 | |
| 422 | AM_RANGE(0x0000, 0x07ff) AM_ROMBANK(MCS48_INTERNAL_ROMBANK) | |
| 423 | #endif | |
| 429 | AM_RANGE(0x0000, 0x07ff) AM_ROMBANK(1) AM_REGION("audio", 0) | |
| 424 | 430 | AM_RANGE(0x0800, 0x0fff) AM_ROM |
| 425 | 431 | ADDRESS_MAP_END |
| 426 | 432 |
| r3232 | r3233 | |
|---|---|---|
| 37 | 37 | static UINT8 *psg_latch; |
| 38 | 38 | static UINT8 *sp0250_latch; |
| 39 | 39 | |
| 40 | static int score_sample; | |
| 41 | static int random_offset; | |
| 40 | 42 | |
| 43 | ||
| 41 | 44 | static void gottlieb1_sh_w(const device_config *riot, UINT8 data); |
| 42 | 45 | static void gottlieb2_sh_w(running_machine *machine, UINT8 data); |
| 43 | 46 | static void trigger_sample(running_machine *machine, UINT8 data); |
| r3232 | r3233 | |
| 145 | 148 | |
| 146 | 149 | static void trigger_sample(running_machine *machine, UINT8 data) |
| 147 | 150 | { |
| 148 | static int score_sample = 7; | |
| 149 | static int random_offset = 0; | |
| 150 | ||
| 151 | 151 | /* Reactor samples */ |
| 152 | 152 | if (strcmp(machine->gamedrv->name, "reactor") == 0) |
| 153 | 153 | { |
| r3232 | r3233 | |
| 255 | 255 | phonemes[0] = 0; |
| 256 | 256 | for (i = 0;i < votrax_queuepos-1;i++) |
| 257 | 257 | { |
| 258 | static const char *inf[4] = { "[0]", "[1]", "[2]", "[3]" }; | |
| 258 | static const char *const inf[4] = { "[0]", "[1]", "[2]", "[3]" }; | |
| 259 | 259 | int phoneme = votrax_queue[i] & 0x3f; |
| 260 | 260 | int inflection = votrax_queue[i] >> 6; |
| 261 | 261 | if (inflection != last) strcat(phonemes, inf[inflection]); |
| r3232 | r3233 | |
| 295 | 295 | |
| 296 | 296 | static SOUND_START( gottlieb1 ) |
| 297 | 297 | { |
| 298 | score_sample = 7; | |
| 299 | random_offset = 0; | |
| 300 | ||
| 298 | 301 | state_save_register_global_array(votrax_queue); |
| 299 | 302 | state_save_register_global(votrax_queuepos); |
| 300 | 303 | } |
| r3232 | r3233 | |
|---|---|---|
| 4000 | 4000 | |
| 4001 | 4001 | |
| 4002 | 4002 | MACHINE_DRIVER_START( invad2ct_audio ) |
| 4003 | MDRV_SPEAKER_STANDARD_STEREO(" | |
| 4003 | MDRV_SPEAKER_STANDARD_STEREO("spk1", "spk2") | |
| 4004 | 4004 | |
| 4005 | 4005 | MDRV_SOUND_ADD("discrete", DISCRETE, 0) |
| 4006 | 4006 | MDRV_SOUND_CONFIG_DISCRETE(invad2ct) |
| 4007 | MDRV_SOUND_ROUTE(0, "#1", 0.5) | |
| 4008 | MDRV_SOUND_ROUTE(1, "#2", 0.5) | |
| 4007 | MDRV_SOUND_ROUTE(0, "spk1", 0.5) | |
| 4008 | MDRV_SOUND_ROUTE(1, "spk2", 0.5) | |
| 4009 | 4009 | |
| 4010 | 4010 | MDRV_SOUND_ADD("sn1", SN76477, 0) |
| 4011 | 4011 | MDRV_SOUND_CONFIG(invad2ct_p1_sn76477_interface) |
| 4012 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 4012 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "spk1", 0.3) | |
| 4013 | 4013 | |
| 4014 | 4014 | MDRV_SOUND_ADD("sn2", SN76477, 0) |
| 4015 | 4015 | MDRV_SOUND_CONFIG(invad2ct_p2_sn76477_interface) |
| 4016 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 4016 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "spk2", 0.3) | |
| 4017 | 4017 | MACHINE_DRIVER_END |
| 4018 | 4018 | |
| 4019 | 4019 |
| r3232 | r3233 | |
|---|---|---|
| 130 | 130 | int s7,s6,s5,s4,s3,s2,s1,s0; |
| 131 | 131 | }; |
| 132 | 132 | |
| 133 | static UINT8 basetable_fd1089[0x100] = | |
| 133 | static const UINT8 basetable_fd1089[0x100] = | |
| 134 | 134 | { |
| 135 | 135 | 0x00,0x1c,0x76,0x6a,0x5e,0x42,0x24,0x38,0x4b,0x67,0xad,0x81,0xe9,0xc5,0x03,0x2f, |
| 136 | 136 | 0x45,0x69,0xaf,0x83,0xe7,0xcb,0x01,0x2d,0x02,0x1e,0x78,0x64,0x5c,0x40,0x2a,0x36, |
| r3232 | r3233 | |
| 426 | 426 | |
| 427 | 427 | void fd1089a_decrypt(running_machine *machine) |
| 428 | 428 | { |
| 429 | sys16_decrypt(machine, memory_region(machine, "fd1089a | |
| 429 | sys16_decrypt(machine, memory_region(machine, "fd1089a | |
| 430 | 430 | } |
| 431 | 431 | |
| 432 | 432 | void fd1089b_decrypt(running_machine *machine) |
| 433 | 433 | { |
| 434 | sys16_decrypt(machine, memory_region(machine, "fd1089b | |
| 434 | sys16_decrypt(machine, memory_region(machine, "fd1089b | |
| 435 | 435 | } |
| 436 | 436 |
| r3232 | r3233 | |
|---|---|---|
| 216 | 216 | WRITE8_HANDLER( bublbobl_mcu_port2_w ) |
| 217 | 217 | { |
| 218 | 218 | //logerror("%04x: 6801U4 port 2 write %02x\n",activecpu_get_pc(),data); |
| 219 | static const char *portnames[] = { "DSW0", "DSW1", "IN1", "IN2" }; | |
| 219 | static const char *const portnames[] = { "DSW0", "DSW1", "IN1", "IN2" }; | |
| 220 | 220 | |
| 221 | 221 | // bits 0-3: bits 8-11 of shared RAM address |
| 222 | 222 | |
| r3232 | r3233 | |
| 430 | 430 | WRITE8_HANDLER( bublbobl_68705_portB_w ) |
| 431 | 431 | { |
| 432 | 432 | //logerror("%04x: 68705 port B write %02x\n",activecpu_get_pc(),data); |
| 433 | static const char *portnames[] = { "DSW0", "DSW1", "IN1", "IN2" }; | |
| 433 | static const char *const portnames[] = { "DSW0", "DSW1", "IN1", "IN2" }; | |
| 434 | 434 | |
| 435 | 435 | if ((ddrB & 0x01) && (~data & 0x01) && (portB_out & 0x01)) |
| 436 | 436 | { |
| r3232 | r3233 | |
|---|---|---|
| 141 | 141 | |
| 142 | 142 | READ16_HANDLER( midyunit_input_r ) |
| 143 | 143 | { |
| 144 | static const char *portnames[] = { "IN0", "IN1", "IN2", "DSW", "UNK0", "UNK1" }; | |
| 144 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "DSW", "UNK0", "UNK1" }; | |
| 145 | 145 | |
| 146 | 146 | return input_port_read(machine, portnames[offset]); |
| 147 | 147 | } |
| r3232 | r3233 | |
| 156 | 156 | |
| 157 | 157 | static READ16_HANDLER( term2_input_r ) |
| 158 | 158 | { |
| 159 | static const char *portnames[] = { "IN0", "IN1", NULL, "DSW", "UNK0", "UNK1" }; | |
| 159 | static const char *const portnames[] = { "IN0", "IN1", NULL, "DSW", "UNK0", "UNK1" }; | |
| 160 | 160 | |
| 161 | 161 | if (offset != 2) |
| 162 | 162 | return input_port_read(machine, portnames[offset]); |
| r3232 | r3233 | |
|---|---|---|
| 205 | 205 | READ8_HANDLER( decocass_input_r ) |
| 206 | 206 | { |
| 207 | 207 | UINT8 data = 0xff; |
| 208 | static const char *portnames[] = { "IN0", "IN1", "IN2" }; | |
| 208 | static const char *const portnames[] = { "IN0", "IN1", "IN2" }; | |
| 209 | 209 | |
| 210 | 210 | switch (offset & 7) |
| 211 | 211 | { |
| r3232 | r3233 | |
|---|---|---|
| 293 | 293 | |
| 294 | 294 | READ8_HANDLER( ataxx_trackball_r ) |
| 295 | 295 | { |
| 296 | static const char *tracknames[] = { "AN0", "AN1", "AN2", "AN3" }; | |
| 296 | static const char *const tracknames[] = { "AN0", "AN1", "AN2", "AN3" }; | |
| 297 | 297 | |
| 298 | 298 | return dial_compute_value(input_port_read(machine, tracknames[offset]), offset); |
| 299 | 299 | } |
| r3232 | r3233 | |
| 308 | 308 | |
| 309 | 309 | READ8_HANDLER( indyheat_wheel_r ) |
| 310 | 310 | { |
| 311 | static const char *tracknames[] = { "AN0", "AN1", "AN2" }; | |
| 311 | static const char *const tracknames[] = { "AN0", "AN1", "AN2" }; | |
| 312 | 312 | |
| 313 | 313 | return dial_compute_value(input_port_read(machine, tracknames[offset]), offset); |
| 314 | 314 | } |
| r3232 | r3233 | |
| 337 | 337 | |
| 338 | 338 | WRITE8_HANDLER( indyheat_analog_w ) |
| 339 | 339 | { |
| 340 | static const char *tracknames[] = { "AN3", "AN4", "AN5" }; | |
| 340 | static const char *const tracknames[] = { "AN3", "AN4", "AN5" }; | |
| 341 | 341 | |
| 342 | 342 | switch (offset) |
| 343 | 343 | { |
| r3232 | r3233 | |
| 1113 | 1113 | |
| 1114 | 1114 | WRITE8_HANDLER( leland_master_analog_key_w ) |
| 1115 | 1115 | { |
| 1116 | static const char *portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5" }; | |
| 1116 | static const char *const portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5" }; | |
| 1117 | 1117 | |
| 1118 | 1118 | switch (offset) |
| 1119 | 1119 | { |
| r3232 | r3233 | |
|---|---|---|
| 135 | 135 | |
| 136 | 136 | static UINT16 kof10thExtraRAMB[0x01000]; |
| 137 | 137 | |
| 138 | static void kof10thBankswitch(UINT16 nBank) | |
| 138 | static void kof10thBankswitch(running_machine *machine, UINT16 nBank) | |
| 139 | 139 | { |
| 140 | 140 | UINT32 bank = 0x100000 + ((nBank & 7) << 20); |
| 141 | 141 | if (bank >= 0x700000) |
| 142 | 142 | bank = 0x100000; |
| 143 | neogeo_set_main_cpu_bank_address(bank); | |
| 143 | neogeo_set_main_cpu_bank_address(machine, bank); | |
| 144 | 144 | } |
| 145 | 145 | |
| 146 | 146 | static READ16_HANDLER( kof10th_RAMB_r ) |
| r3232 | r3233 | |
| 163 | 163 | { |
| 164 | 164 | if (offset >= 0x5F000) { |
| 165 | 165 | if (offset == 0x5FFF8) { // Standard bankswitch |
| 166 | kof10thBankswitch(data); | |
| 166 | kof10thBankswitch(machine, data); | |
| 167 | 167 | } else if (offset == 0x5FFFC && kof10thExtraRAMB[0xFFC] != data) { // Special bankswitch |
| 168 | 168 | UINT8 *src = memory_region( machine, "main" ); |
| 169 | 169 | memcpy (src + 0x10000, src + ((data & 1) ? 0x810000 : 0x710000), 0xcffff); |
| r3232 | r3233 | |
| 209 | 209 | int i; |
| 210 | 210 | UINT16 *rom = (UINT16*)memory_region(machine, "main"); |
| 211 | 211 | UINT8 *src = memory_region(machine, "main"); |
| 212 | UINT16 *buf = (UINT16*)memory_region(machine, "audio | |
| 212 | UINT16 *buf = (UINT16*)memory_region(machine, "audio | |
| 213 | 213 | UINT8 *srom = (UINT8*)memory_region(machine, "fixed"); |
| 214 | 214 | UINT8 *sbuf = malloc_or_die(0x20000); |
| 215 | 215 | |
| r3232 | r3233 | |
| 421 | 421 | if (offset == 0) |
| 422 | 422 | { |
| 423 | 423 | bankaddress = 0x100000 + cthd2003_banks[data&7]*0x100000; |
| 424 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 424 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 425 | 425 | } |
| 426 | 426 | } |
| 427 | 427 | |
| r3232 | r3233 | |
| 647 | 647 | if ((offset == 0)&&(data == 0xa0)) |
| 648 | 648 | { |
| 649 | 649 | bankaddress=0xa0; |
| 650 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 650 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 651 | 651 | logerror("offset: %06x PC %06x: set banking %04x\n\n",offset,activecpu_get_pc(),bankaddress); |
| 652 | 652 | } |
| 653 | 653 | else if(offset == 2) |
| r3232 | r3233 | |
| 655 | 655 | data=data>>4; |
| 656 | 656 | //data=data&7; |
| 657 | 657 | bankaddress=data*0x100000; |
| 658 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 658 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 659 | 659 | logerror("offset: %06x PC %06x: set banking %04x\n\n",offset,activecpu_get_pc(),bankaddress); |
| 660 | 660 | } |
| 661 | 661 | } |
| r3232 | r3233 | |
| 832 | 832 | { |
| 833 | 833 | UINT32 bankaddress = (mv0_bank_ram[ 0 ] >> 8) + (mv0_bank_ram[ 1 ] << 8) + 0x100000; |
| 834 | 834 | COMBINE_DATA( &mv0_bank_ram[ offset ] ); |
| 835 | neogeo_set_main_cpu_bank_address( bankaddress ); | |
| 835 | neogeo_set_main_cpu_bank_address( machine, bankaddress ); | |
| 836 | 836 | } |
| 837 | 837 | #endif |
| 838 | 838 | |
| r3232 | r3233 | |
| 862 | 862 | cr[BYTE_XOR_LE(0x1ff0)] = 0xa0; |
| 863 | 863 | cr[BYTE_XOR_LE(0x1ff1)] &= 0xfe; |
| 864 | 864 | cr[BYTE_XOR_LE(0x1ff3)] &= 0x7f; |
| 865 | neogeo_set_main_cpu_bank_address(address+0x100000); | |
| 865 | neogeo_set_main_cpu_bank_address(machine, address+0x100000); | |
| 866 | 866 | |
| 867 | 867 | mem[BYTE_XOR_LE(0x58196)] = prt; |
| 868 | 868 | } |
| r3232 | r3233 | |
| 879 | 879 | |
| 880 | 880 | cr[BYTE_XOR_LE(0x1ff0)] &= 0xfe; |
| 881 | 881 | cr[BYTE_XOR_LE(0x1ff3)] &= 0x7f; |
| 882 | neogeo_set_main_cpu_bank_address(address+0x100000); | |
| 882 | neogeo_set_main_cpu_bank_address(machine, address+0x100000); | |
| 883 | 883 | |
| 884 | 884 | mem[BYTE_XOR_LE(0x58196)] = prt; |
| 885 | 885 | } |
| r3232 | r3233 | |
|---|---|---|
| 105 | 105 | |
| 106 | 106 | READ16_HANDLER( midtunit_input_r ) |
| 107 | 107 | { |
| 108 | static const char *portnames[] = { "IN0", "IN1", "IN2", "DSW" }; | |
| 108 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "DSW" }; | |
| 109 | 109 | |
| 110 | 110 | return input_port_read(machine, portnames[offset]); |
| 111 | 111 | } |
| r3232 | r3233 | |
|---|---|---|
| 259 | 259 | { |
| 260 | 260 | int movement_flip_flop = TTL7474_1F_1 + (2 * player); |
| 261 | 261 | int dir_flip_flop = movement_flip_flop + 1; |
| 262 | static const char *portnames[] = { "DIAL0", "DIAL1", "DIAL2", "DIAL3" }; | |
| 262 | static const char *const portnames[] = { "DIAL0", "DIAL1", "DIAL2", "DIAL3" }; | |
| 263 | 263 | |
| 264 | 264 | port_value = input_port_read(machine, portnames[player]); |
| 265 | 265 |
| r3232 | r3233 | |
|---|---|---|
| 261 | 261 | |
| 262 | 262 | static int instruction_hook(offs_t curpc); |
| 263 | 263 | |
| 264 | static void execute_fdsave(int ref, int params, const char **param); | |
| 265 | static void execute_fdoutput(int ref, int params, const char **param); | |
| 266 | static void execute_fdseed(int ref, int params, const char **param); | |
| 267 | static void execute_fdlockguess(int ref, int params, const char **param); | |
| 268 | static void execute_fdeliminate(int ref, int params, const char **param); | |
| 269 | static void execute_fdunlock(int ref, int params, const char **param); | |
| 270 | static void execute_fdignore(int ref, int params, const char **param); | |
| 271 | static void execute_fdundo(int ref, int params, const char **param); | |
| 272 | static void execute_fdstatus(int ref, int params, const char **param); | |
| 273 | static void execute_fdstate(int ref, int params, const char **param); | |
| 274 | static void execute_fdpc(int ref, int params, const char **param); | |
| 275 | static void execute_fdsearch(int ref, int params, const char **param); | |
| 276 | static void execute_fddasm(int ref, int params, const char **param); | |
| 277 | static void execute_fdcset(int ref, int params, const char **param); | |
| 278 | static void execute_fdclist(int ref, int params, const char **param); | |
| 279 | static void execute_fdcsearch(int ref, int params, const char **param); | |
| 264 | static void execute_fdsave(running_machine *machine, int ref, int params, const char **param); | |
| 265 | static void execute_fdoutput(running_machine *machine, int ref, int params, const char **param); | |
| 266 | static void execute_fdseed(running_machine *machine, int ref, int params, const char **param); | |
| 267 | static void execute_fdlockguess(running_machine *machine, int ref, int params, const char **param); | |
| 268 | static void execute_fdeliminate(running_machine *machine, int ref, int params, const char **param); | |
| 269 | static void execute_fdunlock(running_machine *machine, int ref, int params, const char **param); | |
| 270 | static void execute_fdignore(running_machine *machine, int ref, int params, const char **param); | |
| 271 | static void execute_fdundo(running_machine *machine, int ref, int params, const char **param); | |
| 272 | static void execute_fdstatus(running_machine *machine, int ref, int params, const char **param); | |
| 273 | static void execute_fdstate(running_machine *machine, int ref, int params, const char **param); | |
| 274 | static void execute_fdpc(running_machine *machine, int ref, int params, const char **param); | |
| 275 | static void execute_fdsearch(running_machine *machine, int ref, int params, const char **param); | |
| 276 | static void execute_fddasm(running_machine *machine, int ref, int params, const char **param); | |
| 277 | static void execute_fdcset(running_machine *machine, int ref, int params, const char **param); | |
| 278 | static void execute_fdclist(running_machine *machine, int ref, int params, const char **param); | |
| 279 | static void execute_fdcsearch(running_machine *machine, int ref, int params, const char **param); | |
| 280 | 280 | |
| 281 | static fd1094_possibility *try_all_possibilities(int basepc, int offset, int length, UINT8 *instrbuffer, UINT8 *keybuffer, fd1094_possibility *possdata); | |
| 281 | static fd1094_possibility *try_all_possibilities(running_machine *machine, int basepc, int offset, int length, UINT8 *instrbuffer, UINT8 *keybuffer, fd1094_possibility *possdata); | |
| 282 | 282 | static void tag_possibility(fd1094_possibility *possdata, UINT8 status); |
| 283 | 283 | |
| 284 | 284 | static void perform_constrained_search(void); |
| r3232 | r3233 | |
| 288 | 288 | static UINT32 reconstruct_base_seed(int keybaseaddr, UINT32 startseed); |
| 289 | 289 | |
| 290 | 290 | static void build_optable(void); |
| 291 | static int validate_ea(UINT32 pc, UINT8 modereg, const UINT8 *parambase, UINT32 flags); | |
| 292 | static int validate_opcode(UINT32 pc, const UINT8 *opdata, int maxwords); | |
| 291 | static int validate_ea(running_machine *machine, UINT32 pc, UINT8 modereg, const UINT8 *parambase, UINT32 flags); | |
| 292 | static int validate_opcode(running_machine *machine, UINT32 pc, const UINT8 *opdata, int maxwords); | |
| 293 | 293 | |
| 294 | 294 | |
| 295 | 295 | |
| r3232 | r3233 | |
| 430 | 430 | 0=no, 1=yes, 2=unlikely |
| 431 | 431 | -----------------------------------------------*/ |
| 432 | 432 | |
| 433 | INLINE int pc_is_valid(UINT32 pc, UINT32 flags) | |
| 433 | INLINE int pc_is_valid(running_machine *machine, UINT32 pc, UINT32 flags) | |
| 434 | 434 | { |
| 435 | 435 | /* if we're odd or out of range, fail */ |
| 436 | 436 | if ((pc & 1) == 1) |
| 437 | 437 | return 0; |
| 438 | 438 | if (pc & 0xff000000) |
| 439 | 439 | return 0; |
| 440 | if (memory_get_op_ptr(cpu_getactivecpu(), pc, 0) == NULL) | |
| 440 | if (memory_get_op_ptr(machine, cpu_getactivecpu(), pc, 0) == NULL) | |
| 441 | 441 | return 0; |
| 442 | 442 | return 1; |
| 443 | 443 | } |
| r3232 | r3233 | |
| 448 | 448 | valid? 0=no, 1=yes, 2=unlikely |
| 449 | 449 | -----------------------------------------------*/ |
| 450 | 450 | |
| 451 | INLINE int addr_is_valid(UINT32 addr, UINT32 flags) | |
| 451 | INLINE int addr_is_valid(running_machine *machine, UINT32 addr, UINT32 flags) | |
| 452 | 452 | { |
| 453 | 453 | /* if this a JMP, the address is a PC */ |
| 454 | 454 | if (flags & OF_JMP) |
| 455 | return pc_is_valid(addr, flags); | |
| 455 | return pc_is_valid(machine, addr, flags); | |
| 456 | 456 | |
| 457 | 457 | /* if we're odd or out of range, fail */ |
| 458 | 458 | if ((flags & OF_SIZEMASK) != OF_BYTE && (addr & 1) == 1) |
| r3232 | r3233 | |
| 518 | 518 | load_overlay_file(machine); |
| 519 | 519 | |
| 520 | 520 | /* add some commands */ |
| 521 | debug_console_register_command("fdsave", CMDFLAG_NONE, 0, 0, 0, execute_fdsave); | |
| 522 | debug_console_register_command("fdoutput", CMDFLAG_NONE, 0, 1, 1, execute_fdoutput); | |
| 523 | debug_console_register_command("fdseed", CMDFLAG_NONE, 0, 2, 2, execute_fdseed); | |
| 524 | debug_console_register_command("fdguess", CMDFLAG_NONE, STATUS_GUESS, 1, 1, execute_fdlockguess); | |
| 525 | debug_console_register_command("fdlock", CMDFLAG_NONE, STATUS_LOCKED, 1, 1, execute_fdlockguess); | |
| 526 | debug_console_register_command("fdeliminate", CMDFLAG_NONE, 0, 1, 10, execute_fdeliminate); | |
| 527 | debug_console_register_command("fdunlock", CMDFLAG_NONE, 0, 1, 1, execute_fdunlock); | |
| 528 | debug_console_register_command("fdignore", CMDFLAG_NONE, 0, 0, 1, execute_fdignore); | |
| 529 | debug_console_register_command("fdundo", CMDFLAG_NONE, 0, 0, 0, execute_fdundo); | |
| 530 | debug_console_register_command("fdstatus", CMDFLAG_NONE, 0, 0, 0, execute_fdstatus); | |
| 531 | debug_console_register_command("fdstate", CMDFLAG_NONE, 0, 0, 1, execute_fdstate); | |
| 532 | debug_console_register_command("fdpc", CMDFLAG_NONE, 0, 0, 1, execute_fdpc); | |
| 533 | debug_console_register_command("fdsearch", CMDFLAG_NONE, 0, 0, 0, execute_fdsearch); | |
| 534 | debug_console_register_command("fddasm", CMDFLAG_NONE, 0, 1, 1, execute_fddasm); | |
| 535 | debug_console_register_command("fdcset", CMDFLAG_NONE, 0, 2, 4, execute_fdcset); | |
| 536 | debug_console_register_command("fdclist", CMDFLAG_NONE, 0, 0, 0, execute_fdclist); | |
| 537 | debug_console_register_command("fdcsearch", CMDFLAG_NONE, 0, 0, 0, execute_fdcsearch); | |
| 521 | debug_console_register_command(machine, "fdsave", CMDFLAG_NONE, 0, 0, 0, execute_fdsave); | |
| 522 | debug_console_register_command(machine, "fdoutput", CMDFLAG_NONE, 0, 1, 1, execute_fdoutput); | |
| 523 | debug_console_register_command(machine, "fdseed", CMDFLAG_NONE, 0, 2, 2, execute_fdseed); | |
| 524 | debug_console_register_command(machine, "fdguess", CMDFLAG_NONE, STATUS_GUESS, 1, 1, execute_fdlockguess); | |
| 525 | debug_console_register_command(machine, "fdlock", CMDFLAG_NONE, STATUS_LOCKED, 1, 1, execute_fdlockguess); | |
| 526 | debug_console_register_command(machine, "fdeliminate", CMDFLAG_NONE, 0, 1, 10, execute_fdeliminate); | |
| 527 | debug_console_register_command(machine, "fdunlock", CMDFLAG_NONE, 0, 1, 1, execute_fdunlock); | |
| 528 | debug_console_register_command(machine, "fdignore", CMDFLAG_NONE, 0, 0, 1, execute_fdignore); | |
| 529 | debug_console_register_command(machine, "fdundo", CMDFLAG_NONE, 0, 0, 0, execute_fdundo); | |
| 530 | debug_console_register_command(machine, "fdstatus", CMDFLAG_NONE, 0, 0, 0, execute_fdstatus); | |
| 531 | debug_console_register_command(machine, "fdstate", CMDFLAG_NONE, 0, 0, 1, execute_fdstate); | |
| 532 | debug_console_register_command(machine, "fdpc", CMDFLAG_NONE, 0, 0, 1, execute_fdpc); | |
| 533 | debug_console_register_command(machine, "fdsearch", CMDFLAG_NONE, 0, 0, 0, execute_fdsearch); | |
| 534 | debug_console_register_command(machine, "fddasm", CMDFLAG_NONE, 0, 1, 1, execute_fddasm); | |
| 535 | debug_console_register_command(machine, "fdcset", CMDFLAG_NONE, 0, 2, 4, execute_fdcset); | |
| 536 | debug_console_register_command(machine, "fdclist", CMDFLAG_NONE, 0, 0, 0, execute_fdclist); | |
| 537 | debug_console_register_command(machine, "fdcsearch", CMDFLAG_NONE, 0, 0, 0, execute_fdcsearch); | |
| 538 | 538 | |
| 539 | 539 | /* set up the instruction hook */ |
| 540 | 540 | debug_cpu_set_instruction_hook(0, instruction_hook); |
| r3232 | r3233 | |
| 722 | 722 | } |
| 723 | 723 | |
| 724 | 724 | /* try all possible decodings at the current pc */ |
| 725 | posscount = try_all_possibilities(curpc, 0, 0, instrbuffer, keybuffer, posslist) - posslist; | |
| 725 | posscount = try_all_possibilities(Machine, curpc, 0, 0, instrbuffer, keybuffer, posslist) - posslist; | |
| 726 | 726 | if (keydirty) |
| 727 | 727 | fd1094_regenerate_key(); |
| 728 | 728 | |
| r3232 | r3233 | |
| 744 | 744 | execute_fdsave - handle the 'fdsave' command |
| 745 | 745 | -----------------------------------------------*/ |
| 746 | 746 | |
| 747 | static void execute_fdsave(int ref, int params, const char **param) | |
| 747 | static void execute_fdsave(running_machine *machine, int ref, int params, const char **param) | |
| 748 | 748 | { |
| 749 | save_overlay_file( | |
| 749 | save_overlay_file(machine); | |
| 750 | 750 | debug_console_printf("File saved\n"); |
| 751 | 751 | } |
| 752 | 752 | |
| r3232 | r3233 | |
| 756 | 756 | to a file |
| 757 | 757 | -----------------------------------------------*/ |
| 758 | 758 | |
| 759 | static void execute_fdoutput(int ref, int params, const char **param) | |
| 759 | static void execute_fdoutput(running_machine *machine, int ref, int params, const char **param) | |
| 760 | 760 | { |
| 761 | 761 | file_error filerr; |
| 762 | 762 | mame_file *file; |
| r3232 | r3233 | |
| 780 | 780 | execute_fdseed - handle the 'fdseed' command |
| 781 | 781 | -----------------------------------------------*/ |
| 782 | 782 | |
| 783 | static void execute_fdseed(int ref, int params, const char **param) | |
| 783 | static void execute_fdseed(running_machine *machine, int ref, int params, const char **param) | |
| 784 | 784 | { |
| 785 | 785 | UINT64 num1, num2; |
| 786 | 786 | |
| r3232 | r3233 | |
| 807 | 807 | and 'fdguess' commands |
| 808 | 808 | -----------------------------------------------*/ |
| 809 | 809 | |
| 810 | static void execute_fdlockguess(int ref, int params, const char **param) | |
| 810 | static void execute_fdlockguess(running_machine *machine, int ref, int params, const char **param) | |
| 811 | 811 | { |
| 812 | 812 | UINT64 num1; |
| 813 | 813 | |
| r3232 | r3233 | |
| 836 | 836 | 'fdeliminate' command |
| 837 | 837 | -----------------------------------------------*/ |
| 838 | 838 | |
| 839 | static void execute_fdeliminate(int ref, int params, const char **param) | |
| 839 | static void execute_fdeliminate(running_machine *machine, int ref, int params, const char **param) | |
| 840 | 840 | { |
| 841 | 841 | int pnum, posssrc, possdst; |
| 842 | 842 | int plist[10]; |
| r3232 | r3233 | |
| 887 | 887 | command |
| 888 | 888 | -----------------------------------------------*/ |
| 889 | 889 | |
| 890 | static void execute_fdunlock(int ref, int params, const char **param) | |
| 890 | static void execute_fdunlock(running_machine *machine, int ref, int params, const char **param) | |
| 891 | 891 | { |
| 892 | 892 | int reps = keystatus_words / KEY_SIZE; |
| 893 | 893 | int keyaddr, repnum; |
| r3232 | r3233 | |
| 924 | 924 | command |
| 925 | 925 | -----------------------------------------------*/ |
| 926 | 926 | |
| 927 | static void execute_fdignore(int ref, int params, const char **param) | |
| 927 | static void execute_fdignore(running_machine *machine, int ref, int params, const char **param) | |
| 928 | 928 | { |
| 929 | 929 | UINT64 offset; |
| 930 | 930 | |
| r3232 | r3233 | |
| 957 | 957 | command |
| 958 | 958 | -----------------------------------------------*/ |
| 959 | 959 | |
| 960 | static void execute_fdundo(int ref, int params, const char **param) | |
| 960 | static void execute_fdundo(running_machine *machine, int ref, int params, const char **param) | |
| 961 | 961 | { |
| 962 | 962 | /* copy the undobuffer back and regenerate the key */ |
| 963 | 963 | memcpy(keystatus, undobuff, keystatus_words * 2); |
| r3232 | r3233 | |
| 971 | 971 | command |
| 972 | 972 | -----------------------------------------------*/ |
| 973 | 973 | |
| 974 | static void execute_fdstatus(int ref, int params, const char **param) | |
| 974 | static void execute_fdstatus(running_machine *machine, int ref, int params, const char **param) | |
| 975 | 975 | { |
| 976 | 976 | int numreps = keystatus_words / KEY_SIZE; |
| 977 | 977 | int locked = 4, nomatter = 0, guesses = 0; |
| r3232 | r3233 | |
| 1003 | 1003 | command |
| 1004 | 1004 | -----------------------------------------------*/ |
| 1005 | 1005 | |
| 1006 | static void execute_fdstate(int ref, int params, const char **param) | |
| 1006 | static void execute_fdstate(running_machine *machine, int ref, int params, const char **param) | |
| 1007 | 1007 | { |
| 1008 | 1008 | UINT64 newstate; |
| 1009 | 1009 | |
| r3232 | r3233 | |
| 1028 | 1028 | command |
| 1029 | 1029 | -----------------------------------------------*/ |
| 1030 | 1030 | |
| 1031 | static void execute_fdpc(int ref, int params, const char **param) | |
| 1031 | static void execute_fdpc(running_machine *machine, int ref, int params, const char **param) | |
| 1032 | 1032 | { |
| 1033 | 1033 | UINT64 newpc; |
| 1034 | 1034 | |
| r3232 | r3233 | |
| 1049 | 1049 | command |
| 1050 | 1050 | -----------------------------------------------*/ |
| 1051 | 1051 | |
| 1052 | static void execute_fdsearch(int ref, int params, const char **param) | |
| 1052 | static void execute_fdsearch(running_machine *machine, int ref, int params, const char **param) | |
| 1053 | 1053 | { |
| 1054 | 1054 | int pc = activecpu_get_pc(); |
| 1055 | 1055 | int length, first = TRUE; |
| r3232 | r3233 | |
| 1102 | 1102 | instrdata[1] = decoded; |
| 1103 | 1103 | |
| 1104 | 1104 | /* get the opcode */ |
| 1105 | length = validate_opcode(pc, instrdata, 1); | |
| 1105 | length = validate_opcode(machine, pc, instrdata, 1); | |
| 1106 | 1106 | if (length < 0) |
| 1107 | 1107 | length = -length; |
| 1108 | 1108 | if (length == 0) |
| r3232 | r3233 | |
| 1174 | 1174 | command |
| 1175 | 1175 | -----------------------------------------------*/ |
| 1176 | 1176 | |
| 1177 | static void execute_fddasm(int ref, int params, const char **param) | |
| 1177 | static void execute_fddasm(running_machine *machine, int ref, int params, const char **param) | |
| 1178 | 1178 | { |
| 1179 | 1179 | int origstate = fd1094_set_state(keyregion, -1); |
| 1180 | 1180 | const char *filename; |
| r3232 | r3233 | |
| 1262 | 1262 | if (unknowns > 0) |
| 1263 | 1263 | { |
| 1264 | 1264 | UINT8 keybuffer[5]; |
| 1265 | int posscount = try_all_possibilities(pcaddr * 2, 0, 0, instrbuffer, keybuffer, posslist) - posslist; | |
| 1265 | int posscount = try_all_possibilities(machine, pcaddr * 2, 0, 0, instrbuffer, keybuffer, posslist) - posslist; | |
| 1266 | 1266 | for (pnum = 0; pnum < posscount; pnum++) |
| 1267 | 1267 | if (strcmp(disasm, posslist[pnum].dasm) != 0) |
| 1268 | 1268 | { |
| r3232 | r3233 | |
| 1291 | 1291 | command |
| 1292 | 1292 | -----------------------------------------------*/ |
| 1293 | 1293 | |
| 1294 | static void execute_fdcset(int ref, int params, const char **param) | |
| 1294 | static void execute_fdcset(running_machine *machine, int ref, int params, const char **param) | |
| 1295 | 1295 | { |
| 1296 | 1296 | UINT64 pc, value, mask = 0xffff, state = FD1094_STATE_RESET; |
| 1297 | 1297 | int cnum; |
| r3232 | r3233 | |
| 1349 | 1349 | command |
| 1350 | 1350 | -----------------------------------------------*/ |
| 1351 | 1351 | |
| 1352 | static void execute_fdclist(int ref, int params, const char **param) | |
| 1352 | static void execute_fdclist(running_machine *machine, int ref, int params, const char **param) | |
| 1353 | 1353 | { |
| 1354 | 1354 | int cnum; |
| 1355 | 1355 | |
| r3232 | r3233 | |
| 1368 | 1368 | command |
| 1369 | 1369 | -----------------------------------------------*/ |
| 1370 | 1370 | |
| 1371 | static void execute_fdcsearch(int ref, int params, const char **param) | |
| 1371 | static void execute_fdcsearch(running_machine *machine, int ref, int params, const char **param) | |
| 1372 | 1372 | { |
| 1373 | 1373 | // debug_console_printf("Searching for possible global keys....\n"); |
| 1374 | 1374 | perform_constrained_search(); |
| r3232 | r3233 | |
| 1382 | 1382 | length |
| 1383 | 1383 | -----------------------------------------------*/ |
| 1384 | 1384 | |
| 1385 | static fd1094_possibility *try_all_possibilities(int basepc, int offset, int length, UINT8 *instrbuffer, UINT8 *keybuffer, fd1094_possibility *possdata) | |
| 1385 | static fd1094_possibility *try_all_possibilities(running_machine *machine, int basepc, int offset, int length, UINT8 *instrbuffer, UINT8 *keybuffer, fd1094_possibility *possdata) | |
| 1386 | 1386 | { |
| 1387 | 1387 | UINT8 keymask, keystat; |
| 1388 | 1388 | UINT16 possvalue[4]; |
| r3232 | r3233 | |
| 1457 | 1457 | /* first make sure we are a valid instruction */ |
| 1458 | 1458 | if ((possvalue[i] & 0xf000) == 0xa000 || (possvalue[i] & 0xf000) == 0xf000) |
| 1459 | 1459 | continue; |
| 1460 | length = validate_opcode(basepc, instrbuffer, 1); | |
| 1460 | length = validate_opcode(machine, basepc, instrbuffer, 1); | |
| 1461 | 1461 | if (length == 0) |
| 1462 | 1462 | continue; |
| 1463 | 1463 | if (length < 0) |
| r3232 | r3233 | |
| 1466 | 1466 | |
| 1467 | 1467 | /* if we're not at our target length, recursively call ourselves */ |
| 1468 | 1468 | if (offset < length - 1) |
| 1469 | possdata = try_all_possibilities(basepc, offset + 1, length, instrbuffer, keybuffer, possdata); | |
| 1469 | possdata = try_all_possibilities(machine, basepc, offset + 1, length, instrbuffer, keybuffer, possdata); | |
| 1470 | 1470 | |
| 1471 | 1471 | /* otherwise, output what we have */ |
| 1472 | 1472 | else |
| r3232 | r3233 | |
| 1477 | 1477 | m68k_disassemble_raw(possdata->dasm, basepc, instrbuffer, instrbuffer, M68K_CPU_TYPE_68000); |
| 1478 | 1478 | |
| 1479 | 1479 | /* validate the opcode */ |
| 1480 | tlen = validate_opcode(basepc, instrbuffer, length); | |
| 1480 | tlen = validate_opcode(machine, basepc, instrbuffer, length); | |
| 1481 | 1481 | if (tlen == 0) |
| 1482 | 1482 | { |
| 1483 | 1483 | printf("Eliminated: %s [", possdata->dasm); |
| r3232 | r3233 | |
| 2223 | 2223 | valid or not, and return the length |
| 2224 | 2224 | -----------------------------------------------*/ |
| 2225 | 2225 | |
| 2226 | static int validate_ea(UINT32 pc, UINT8 modereg, const UINT8 *parambase, UINT32 flags) | |
| 2226 | static int validate_ea(running_machine *machine, UINT32 pc, UINT8 modereg, const UINT8 *parambase, UINT32 flags) | |
| 2227 | 2227 | { |
| 2228 | 2228 | UINT32 addr; |
| 2229 | 2229 | int valid; |
| r3232 | r3233 | |
| 2256 | 2256 | { |
| 2257 | 2257 | case 0: /* (xxx).W -- make sure it is not odd for word/long */ |
| 2258 | 2258 | addr = (INT16)((parambase[0] << 8) | parambase[1]); |
| 2259 | valid = addr_is_valid(addr & 0xffffff, flags); | |
| 2259 | valid = addr_is_valid(machine, addr & 0xffffff, flags); | |
| 2260 | 2260 | return (valid == 0) ? 1000 : (valid == 2) ? -1 : 1; |
| 2261 | 2261 | |
| 2262 | 2262 | case 1: /* (xxx).L -- make sure it is not odd for word/long, and make sure upper byte of addr is 0 */ |
| 2263 | valid = addr_is_valid((parambase[0] << 24) | (parambase[1] << 16) | (parambase[2] << 8) | parambase[3], flags); | |
| 2263 | valid = addr_is_valid(machine, (parambase[0] << 24) | (parambase[1] << 16) | (parambase[2] << 8) | parambase[3], flags); | |
| 2264 | 2264 | return (valid == 0) ? 1000 : (valid == 2) ? -2 : 2; |
| 2265 | 2265 | |
| 2266 | 2266 | case 2: /* (d16,PC) -- make sure it is not odd for word/long */ |
| 2267 | valid = addr_is_valid(pc + (INT16)((parambase[0] << 8) | parambase[1]), flags); | |
| 2267 | valid = addr_is_valid(machine, pc + (INT16)((parambase[0] << 8) | parambase[1]), flags); | |
| 2268 | 2268 | return (valid == 0) ? 1000 : (valid == 2) ? -1 : 1; |
| 2269 | 2269 | |
| 2270 | 2270 | case 3: /* (d8,PC,Xn) -- odd displacements are a warning for word/long */ |
| r3232 | r3233 | |
| 2293 | 2293 | the length specified |
| 2294 | 2294 | -----------------------------------------------*/ |
| 2295 | 2295 | |
| 2296 | static int validate_opcode(UINT32 pc, const UINT8 *opdata, int maxwords) | |
| 2296 | static int validate_opcode(running_machine *machine, UINT32 pc, const UINT8 *opdata, int maxwords) | |
| 2297 | 2297 | { |
| 2298 | 2298 | UINT32 immvalue = 0; |
| 2299 | 2299 | int iffy = FALSE; |
| r3232 | r3233 | |
| 2370 | 2370 | pc += immvalue; |
| 2371 | 2371 | |
| 2372 | 2372 | /* if we're odd or out of range, fail */ |
| 2373 | valid = pc_is_valid(pc, flags); | |
| 2373 | valid = pc_is_valid(machine, pc, flags); | |
| 2374 | 2374 | if (valid == 0) |
| 2375 | 2375 | return 0; |
| 2376 | 2376 | if (valid == 2) |
| r3232 | r3233 | |
| 2381 | 2381 | if (flags & (OF_EASRC | OF_EADST)) |
| 2382 | 2382 | { |
| 2383 | 2383 | int modereg = opcode & 0x003f; |
| 2384 | int ealen = validate_ea(pc + offset*2, modereg, &opdata[offset*2], flags); | |
| 2384 | int ealen = validate_ea(machine, pc + offset*2, modereg, &opdata[offset*2], flags); | |
| 2385 | 2385 | |
| 2386 | 2386 | /* if the ea was invalid, forward that result */ |
| 2387 | 2387 | if (ealen == 1000) |
| r3232 | r3233 | |
| 2402 | 2402 | if (flags & OF_MOVE) |
| 2403 | 2403 | { |
| 2404 | 2404 | int modereg = ((opcode & 0x01c0) >> 3) | ((opcode & 0x0e00) >> 9); |
| 2405 | int ealen = validate_ea(pc + offset*2, modereg, &opdata[offset*2], flags); | |
| 2405 | int ealen = validate_ea(machine, pc + offset*2, modereg, &opdata[offset*2], flags); | |
| 2406 | 2406 | |
| 2407 | 2407 | /* if the ea was invalid, forward that result */ |
| 2408 | 2408 | if (ealen == 1000) |
| r3232 | r3233 | |
|---|---|---|
| 1173 | 1173 | UINT16 buttons = 0; |
| 1174 | 1174 | INT8 x = 0, y = 0; |
| 1175 | 1175 | /* add here tags for P2, P3 and P4 when implemented */ |
| 1176 | static const char *portnames[] = { "P1", "P1_ANALOG_X", "P1_ANALOG_Y" }; | |
| 1176 | static const char *const portnames[] = { "P1", "P1_ANALOG_X", "P1_ANALOG_Y" }; | |
| 1177 | 1177 | |
| 1178 | 1178 | if (slength != 1 || rlength != 4) |
| 1179 | 1179 | { |
| r3232 | r3233 | |
|---|---|---|
| 604 | 604 | INTERRUPT_GEN( balsente_update_analog_inputs ) |
| 605 | 605 | { |
| 606 | 606 | int i; |
| 607 | static const char *analog[] = { "AN0", "AN1", "AN2", "AN3" }; | |
| 607 | static const char *const analog[] = { "AN0", "AN1", "AN2", "AN3" }; | |
| 608 | 608 | |
| 609 | 609 | /* the analog input system helpfully scales the value read by the percentage of time */ |
| 610 | 610 | /* into the current frame we are; unfortunately, this is bad for us, since the analog */ |
| r3232 | r3233 | |
|---|---|---|
| 21 | 21 | static const UINT8 *remapped_colortable; |
| 22 | 22 | |
| 23 | 23 | static int sound_fix=0; |
| 24 | static UINT8 last_bank; | |
| 25 | ||
| 24 | 26 | /************************************* |
| 25 | 27 | * |
| 26 | 28 | * Color Mapping |
| r3232 | r3233 | |
| 220 | 222 | |
| 221 | 223 | MACHINE_RESET( vsnes ) |
| 222 | 224 | { |
| 225 | last_bank = 0xff; | |
| 226 | sound_fix = 0; | |
| 223 | 227 | input_latch[0] = input_latch[1] = 0; |
| 224 | 228 | input_latch[2] = input_latch[3] = 0; |
| 225 | 229 | |
| r3232 | r3233 | |
| 854 | 858 | |
| 855 | 859 | static WRITE8_HANDLER( mapper4_w ) |
| 856 | 860 | { |
| 857 | static UINT8 last_bank = 0xff; | |
| 858 | ||
| 859 | 861 | switch (offset & 0x7001) |
| 860 | 862 | { |
| 861 | 863 | case 0x0000: /* $8000 */ |
| r3232 | r3233 | |
|---|---|---|
| 120 | 120 | |
| 121 | 121 | READ16_HANDLER( vertigo_io_convert ) |
| 122 | 122 | { |
| 123 | static const char *adcnames[] = { "P1X", "P1Y", "PADDLE" }; | |
| 123 | static const char *const adcnames[] = { "P1X", "P1Y", "PADDLE" }; | |
| 124 | 124 | |
| 125 | 125 | if (offset > 2) |
| 126 | 126 | adc_result = 0; |
| r3232 | r3233 | |
|---|---|---|
| 213 | 213 | |
| 214 | 214 | bankaddress = 0x100000 + bankoffset[data]; |
| 215 | 215 | |
| 216 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 216 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 217 | 217 | } |
| 218 | 218 | |
| 219 | 219 | |
| r3232 | r3233 | |
| 250 | 250 | |
| 251 | 251 | bankaddress = 0x100000 + bankoffset[data]; |
| 252 | 252 | |
| 253 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 253 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 254 | 254 | } |
| 255 | 255 | |
| 256 | 256 | |
| r3232 | r3233 | |
| 289 | 289 | |
| 290 | 290 | bankaddress = 0x100000 + bankoffset[data]; |
| 291 | 291 | |
| 292 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 292 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 293 | 293 | } |
| 294 | 294 | |
| 295 | 295 | |
| r3232 | r3233 | |
| 325 | 325 | |
| 326 | 326 | bankaddress = 0x100000 + bankoffset[data]; |
| 327 | 327 | |
| 328 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 328 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 329 | 329 | } |
| 330 | 330 | |
| 331 | 331 | |
| r3232 | r3233 | |
| 357 | 357 | |
| 358 | 358 | bankaddress = 0x100000 + bankoffset[data]; |
| 359 | 359 | |
| 360 | neogeo_set_main_cpu_bank_address(bankaddress); | |
| 360 | neogeo_set_main_cpu_bank_address(machine, bankaddress); | |
| 361 | 361 | } |
| 362 | 362 | |
| 363 | 363 | |
| r3232 | r3233 | |
| 490 | 490 | } |
| 491 | 491 | |
| 492 | 492 | |
| 493 | static void pvc_write_bankswitch( | |
| 493 | static void pvc_write_bankswitch( running_machine *machine ) | |
| 494 | 494 | { |
| 495 | 495 | UINT32 bankaddress; |
| 496 | 496 | bankaddress = ((pvc_cartridge_ram[0xff8]>>8)|(pvc_cartridge_ram[0xff9]<<8)); |
| 497 | 497 | *(((UINT8 *)pvc_cartridge_ram) + BYTE_XOR_LE(0x1ff0)) = 0xa0; |
| 498 | 498 | *(((UINT8 *)pvc_cartridge_ram) + BYTE_XOR_LE(0x1ff1)) &= 0xfe; |
| 499 | 499 | *(((UINT8 *)pvc_cartridge_ram) + BYTE_XOR_LE(0x1ff3)) &= 0x7f; |
| 500 | neogeo_set_main_cpu_bank_address(bankaddress+0x100000); | |
| 500 | neogeo_set_main_cpu_bank_address(machine, bankaddress+0x100000); | |
| 501 | 501 | } |
| 502 | 502 | |
| 503 | 503 | |
| r3232 | r3233 | |
| 512 | 512 | COMBINE_DATA( &pvc_cartridge_ram[ offset ] ); |
| 513 | 513 | if (offset == 0xff0)pvc_prot1(); |
| 514 | 514 | else if(offset >= 0xff4 && offset <= 0xff5)pvc_prot2(); |
| 515 | else if(offset >= 0xff8)pvc_write_bankswitch(); | |
| 515 | else if(offset >= 0xff8)pvc_write_bankswitch(machine); | |
| 516 | 516 | } |
| 517 | 517 | |
| 518 | 518 |
| r3232 | r3233 | |
|---|---|---|
| 179 | 179 | |
| 180 | 180 | READ16_HANDLER( midwunit_io_r ) |
| 181 | 181 | { |
| 182 | static const char *portnames[] = { "IN0", "IN1", "DSW", "IN2" }; | |
| 182 | static const char *const portnames[] = { "IN0", "IN1", "DSW", "IN2" }; | |
| 183 | 183 | |
| 184 | 184 | /* apply I/O shuffling */ |
| 185 | 185 | offset = ioshuffle[offset % 16]; |
| r3232 | r3233 | |
| 205 | 205 | |
| 206 | 206 | READ16_HANDLER( midxunit_io_r ) |
| 207 | 207 | { |
| 208 | static const char *portnames[] = { "IN0", "IN1", "IN2", "DSW" }; | |
| 208 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "DSW" }; | |
| 209 | 209 | |
| 210 | 210 | offset = (offset / 2) % 8; |
| 211 | 211 | |
| r3232 | r3233 | |
| 227 | 227 | |
| 228 | 228 | READ16_HANDLER( midxunit_analog_r ) |
| 229 | 229 | { |
| 230 | static const char *portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5" }; | |
| 230 | static const char *const portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5" }; | |
| 231 | 231 | |
| 232 | 232 | return input_port_read(machine, portnames[midxunit_analog_port]); |
| 233 | 233 | } |
| r3232 | r3233 | |
|---|---|---|
| 1 | 1 | #ifndef NAMCO50_H |
| 2 | 2 | #define NAMCO50_H |
| 3 | 3 | |
| 4 | #define CPUTAG_50XX "50XX" | |
| 5 | #define CPUTAG_50XX_2 "50XX_2" | |
| 4 | #define CPUTAG_50XX "50xx" | |
| 5 | #define CPUTAG_50XX_2 "50xx_2" | |
| 6 | 6 | |
| 7 | 7 | ADDRESS_MAP_EXTERN( namco_50xx_map_program, 8 ); |
| 8 | 8 | ADDRESS_MAP_EXTERN( namco_50xx_map_data, 8 ); |
| r3232 | r3233 | |
|---|---|---|
| 248 | 248 | |
| 249 | 249 | CUSTOM_INPUT( _4in1_fake_port_r ) |
| 250 | 250 | { |
| 251 | static const char *portnames[] = { "FAKE1", "FAKE2", "FAKE3", "FAKE4" }; | |
| 251 | static const char *const portnames[] = { "FAKE1", "FAKE2", "FAKE3", "FAKE4" }; | |
| 252 | 252 | int bit_mask = (FPTR)param; |
| 253 | 253 | |
| 254 | 254 | return (input_port_read(field->port->machine, portnames[_4in1_bank]) & bit_mask) ? 0x01 : 0x00; |
| r3232 | r3233 | |
|---|---|---|
| 432 | 432 | |
| 433 | 433 | WRITE16_HANDLER( hd68k_adc_control_w ) |
| 434 | 434 | { |
| 435 | static const char *adc8names[] = { "8BADC0", "8BADC1", "8BADC2", "8BADC3", "8BADC4", "8BADC5", "8BADC6", "8BADC7" }; | |
| 436 | static const char *adc12names[] = { "12BADC0", "12BADC1", "12BADC2", "12BADC3" }; | |
| 435 | static const char *const adc8names[] = { "8BADC0", "8BADC1", "8BADC2", "8BADC3", "8BADC4", "8BADC5", "8BADC6", "8BADC7" }; | |
| 436 | static const char *const adc12names[] = { "12BADC0", "12BADC1", "12BADC2", "12BADC3" }; | |
| 437 | 437 | |
| 438 | 438 | COMBINE_DATA(&adc_control); |
| 439 | 439 |
| r3232 | r3233 | |
|---|---|---|
| 109 | 109 | READ8_HANDLER( ajax_ls138_f10_r ) |
| 110 | 110 | { |
| 111 | 111 | int data = 0, index; |
| 112 | static const char *portnames[] = { "SYSTEM", "P1", "DSW1", "DSW2" }; | |
| 112 | static const char *const portnames[] = { "SYSTEM", "P1", "DSW1", "DSW2" }; | |
| 113 | 113 | |
| 114 | 114 | switch ((offset & 0x01c0) >> 6) |
| 115 | 115 | { |
| r3232 | r3233 | |
|---|---|---|
| 322 | 322 | DRIVER( jumpcoat ) /* (c) 1983 Taito */ |
| 323 | 323 | DRIVER( boggy84 ) /* bootleg, original is (c)1983 Taito/Kaneko */ |
| 324 | 324 | DRIVER( redrobin ) /* (c) 1986 Elettronolo */ |
| 325 | DRIVER( imago ) /* (c) 1983 Acom */ | |
| 325 | DRIVER( imago ) /* (c) 1984 Acom */ | |
| 326 | DRIVER( imagoa ) /* (c) 1983 Acom */ | |
| 326 | 327 | DRIVER( scorpion ) /* (c) 1982 Zaccaria */ |
| 327 | 328 | DRIVER( scrpiona ) /* (c) 1982 Zaccaria */ |
| 328 | 329 | DRIVER( scrpionb ) /* (c) 1982 Zaccaria */ |
| r3232 | r3233 | |
| 1766 | 1767 | DRIVER( kabukiz ) /* B50 (c) 1988 Taito Corporation Japan (World) */ |
| 1767 | 1768 | DRIVER( kabukizj ) /* B50 (c) 1988 Taito Corporation (Japan) */ |
| 1768 | 1769 | DRIVER( tnzs ) /* B53 (c) 1988 Taito Corporation Japan (World) (new logo) */ |
| 1770 | DRIVER( tnzsjn ) /* B53 (c) 1988 Taito Corporation (Japan) (new logo) */ | |
| 1769 | 1771 | DRIVER( tnzsj ) /* B53 (c) 1988 Taito Corporation (Japan) (new logo) */ |
| 1770 | 1772 | DRIVER( tnzso ) /* B53?(c) 1988 Taito Corporation Japan (World) (old logo) */ |
| 1771 | 1773 | DRIVER( insectx ) /* B97 (c) 1989 Taito Corporation Japan (World) */ |
| r3232 | r3233 | |
| 4076 | 4078 | DRIVER( dybbnao ) |
| 4077 | 4079 | |
| 4078 | 4080 | DRIVER( naomigd ) |
| 4081 | ||
| 4082 | DRIVER( gundmgd ) | |
| 4079 | 4083 | DRIVER( sfz3ugd ) |
| 4084 | DRIVER( cvsgd ) | |
| 4085 | DRIVER( gundmxgd ) | |
| 4080 | 4086 | DRIVER( cvs2gd ) |
| 4087 | DRIVER( ikaruga ) | |
| 4088 | DRIVER( ggxx ) | |
| 4089 | DRIVER( chocomk ) | |
| 4090 | DRIVER( quizqgd ) | |
| 4091 | DRIVER( ggxxrl ) | |
| 4092 | DRIVER( shikgam2 ) | |
| 4093 | DRIVER( meltybld ) | |
| 4094 | DRIVER( senko ) | |
| 4095 | DRIVER( ss2005 ) | |
| 4081 | 4096 | |
| 4097 | DRIVER( sprtjam ) | |
| 4098 | DRIVER( slashout ) | |
| 4099 | DRIVER( spkrbtl ) | |
| 4100 | DRIVER( dygolf ) | |
| 4101 | DRIVER( wsbbgd ) | |
| 4102 | DRIVER( vathlete ) | |
| 4103 | ||
| 4082 | 4104 | DRIVER( hod2bios ) |
| 4083 | 4105 | |
| 4084 | 4106 | DRIVER( naomi2 ) |
| 4107 | DRIVER( vstrik3 ) | |
| 4108 | DRIVER( vf4 ) | |
| 4109 | DRIVER( initd ) | |
| 4085 | 4110 | |
| 4086 | 4111 | /* Atomiswave (Dreamcast-based) games */ |
| 4087 | 4112 | DRIVER( awbios ) |
| r3232 | r3233 | |
| 4380 | 4405 | /* MBA ?? */ |
| 4381 | 4406 | /* MBB ?? */ |
| 4382 | 4407 | /* MBC ?? */ |
| 4383 | DRIVER( boogwing ) /* MBD (c) 1992 */ | |
| 4384 | DRIVER( boogwina ) /* MBD (c) 1992 */ | |
| 4385 | DRIVER( ragtime ) /* MBD (c) 1992 */ | |
| 4408 | DRIVER( boogwing ) /* MBD (c) 1992 (Euro) */ | |
| 4409 | DRIVER( boogwina ) /* MBD (c) 1992 (Asia) */ | |
| 4410 | DRIVER( ragtime ) /* MBD (c) 1992 (Japan) */ | |
| 4411 | DRIVER( ragtimea ) /* MBD (c) 1992 (Japan) */ | |
| 4386 | 4412 | DRIVER( dblewing ) /* MBE (c) 1993 Mitchell */ |
| 4387 | 4413 | DRIVER( fghthist ) /* MBF (c) 1993 Data East Corporation (World) */ |
| 4388 | 4414 | DRIVER( fghthstu ) /* MBF (c) 1993 Data East Corporation (US) */ |
| r3232 | r3233 | |
| 4539 | 4565 | DRIVER( tp84b ) /* GX388 (c) 1984 */ |
| 4540 | 4566 | DRIVER( hyperspt ) /* GX330 (c) 1984 + Centuri */ |
| 4541 | 4567 | DRIVER( hpolym84 ) /* GX330 (c) 1984 */ |
| 4542 | DRIVER( sbasketb ) /* GX405 (c) 1984 */ | |
| 4543 | DRIVER( sbasketo ) /* GX405 (c) 1984 */ | |
| 4544 | DRIVER( sbasketu ) /* GX405 (c) 1984 */ | |
| 4568 | DRIVER( sbasketb ) /* GX405 (c) 1984 (Version H, Unprotected) */ | |
| 4569 | DRIVER( sbasketg ) /* GX405 (c) 1984 (Version G, Encrypted) */ | |
| 4570 | DRIVER( sbaskete ) /* GX405 (c) 1984 (Version E, Encrypted) */ | |
| 4545 | 4571 | DRIVER( mikie ) /* GX469 (c) 1984 */ |
| 4546 | 4572 | DRIVER( mikiej ) /* GX469 (c) 1984 */ |
| 4547 | 4573 | DRIVER( mikiehs ) /* GX469 (c) 1984 */ |
| r3232 | r3233 | |
| 5130 | 5156 | DRIVER( jedi ) /* 136030 (c) 1984 */ |
| 5131 | 5157 | |
| 5132 | 5158 | /* Atari System 1 games */ |
| 5159 | DRIVER( atarisy1 ) /* 136033 (c) 1984 */ | |
| 5133 | 5160 | DRIVER( peterpak ) /* 136028 (c) 1984 */ |
| 5134 | 5161 | /* Marble Madness */ |
| 5135 | 5162 | DRIVER( marble ) /* 136033 (c) 1984 */ |
| 5136 | 5163 | DRIVER( marble2 ) /* 136033 (c) 1984 */ |
| 5137 | 5164 | DRIVER( marble3 ) /* 136033 (c) 1984 */ |
| 5138 | 5165 | DRIVER( marble4 ) /* 136033 (c) 1984 */ |
| 5166 | DRIVER( marble5 ) /* 136033 (c) 1984 (LSI Cartridge) */ | |
| 5139 | 5167 | /* Indiana Jones and the Temple of Doom */ |
| 5140 | 5168 | DRIVER( indytemp ) /* 136036 (c) 1985 */ |
| 5141 | 5169 | DRIVER( indytem2 ) /* 136036 (c) 1985 */ |
| r3232 | r3233 | |
| 5461 | 5489 | DRIVER( marvins ) /* A2003 (c) 1983 */ |
| 5462 | 5490 | DRIVER( madcrash ) /* A2005 (c) 1984 */ |
| 5463 | 5491 | DRIVER( vangrd2 ) /* A2005 (c) 1984 */ |
| 5464 | DRIVER( mainsnk ) /* fill in */ | |
| 5465 | DRIVER( canvas ) /* (c) 1985 */ | |
| 5492 | DRIVER( mainsnk ) /* (c) 1984 */ | |
| 5493 | DRIVER( canvas ) /* A3008 (c) 1985 */ | |
| 5466 | 5494 | DRIVER( jcross ) /* A3006 (c) 1984 */ |
| 5467 | 5495 | DRIVER( sgladiat ) /* A3006 (c) 1984 */ |
| 5468 | 5496 | DRIVER( hal21 ) /* A4031 (c) 1985 */ |
| r3232 | r3233 | |
| 7040 | 7068 | DRIVER( drtomy ) /* (c) 1993 no copyright message (1993 on pcb), some code taken from 'Big Karnak' */ |
| 7041 | 7069 | DRIVER( sderby ) /* (c) 1996 */ |
| 7042 | 7070 | DRIVER( pmroulet ) |
| 7071 | DRIVER( spacewin ) | |
| 7043 | 7072 | |
| 7044 | 7073 | /* Pacific Novelty games */ |
| 7045 | 7074 | DRIVER( sharkatt ) /* (c) 1980 */ |
| r3232 | r3233 | |
| 8042 | 8071 | DRIVER( suprpool ) /* (c) 1997 ABM Games */ |
| 8043 | 8072 | DRIVER( hotslot ) /* (c) 1996 ABM Electronics */ |
| 8044 | 8073 | DRIVER( mcolors ) /* 1999 unknown */ |
| 8074 | DRIVER( sgsafari ) /* 1996 New Impeuropex Corp. */ | |
| 8045 | 8075 | DRIVER( galaxi ) /* (c) 2000 BRL S.R.L. Bologna */ |
| 8046 | 8076 | DRIVER( magjoker ) /* (c) 2000 BRL S.R.L. Bologna */ |
| 8047 | 8077 | DRIVER( dwarfd ) /* (c) 198? Electro-Sports */ |
| r3232 | r3233 | |
|---|---|---|
| 40 | 40 | /* sound state */ |
| 41 | 41 | UINT8 last; |
| 42 | 42 | UINT8 portT; |
| 43 | UINT8 eabank; | |
| 43 | 44 | |
| 44 | 45 | /* video state */ |
| 45 | 46 | UINT8 gfx_bank; |
| r3232 | r3233 | |
|---|---|---|
| 34 | 34 | void neogeo_set_display_counter_msb(UINT16 data); |
| 35 | 35 | void neogeo_set_display_counter_lsb(running_machine *machine, UINT16 data); |
| 36 | 36 | void neogeo_acknowledge_interrupt(running_machine *machine, UINT16 data); |
| 37 | void neogeo_set_main_cpu_bank_address(UINT32 bank_address); | |
| 37 | void neogeo_set_main_cpu_bank_address(running_machine *machine, UINT32 bank_address); | |
| 38 | 38 | READ16_HANDLER( neogeo_unmapped_r ); |
| 39 | 39 | |
| 40 | 40 |
| r3232 | r3233 | |
|---|---|---|
| 1 | 1 | /*----------- defined in video/wwfwfest.c -----------*/ |
| 2 | 2 | |
| 3 | 3 | extern UINT16 *wwfwfest_fg0_videoram, *wwfwfest_bg0_videoram, *wwfwfest_bg1_videoram; |
| 4 | extern int wwfwfest_pri; | |
| 5 | extern int wwfwfest_bg0_scrollx, wwfwfest_bg0_scrolly, wwfwfest_bg1_scrollx, wwfwfest_bg1_scrolly; | |
| 4 | extern UINT16 wwfwfest_pri; | |
| 5 | extern UINT16 wwfwfest_bg0_scrollx, wwfwfest_bg0_scrolly, wwfwfest_bg1_scrollx, wwfwfest_bg1_scrolly; | |
| 6 | 6 | |
| 7 | 7 | VIDEO_START( wwfwfest ); |
| 8 | 8 | VIDEO_START( wwfwfstb ); |
| r3232 | r3233 | |
|---|---|---|
| 1720 | 1720 | |
| 1721 | 1721 | $(DRIVERS)/lucky74.o: $(LAYOUT)/lucky74.lh |
| 1722 | 1722 | |
| 1723 | $(DRIVERS)/magic10.o: $(LAYOUT)/sgsafari.lh | |
| 1724 | ||
| 1723 | 1725 | $(DRIVERS)/maxaflex.o: $(LAYOUT)/maxaflex.lh |
| 1724 | 1726 | |
| 1725 | 1727 | $(DRIVERS)/mpu4.o: $(LAYOUT)/mpu4.lh \ |
| r3232 | r3233 | |
| 1753 | 1755 | |
| 1754 | 1756 | $(DRIVERS)/sbrkout.o: $(LAYOUT)/sbrkout.lh |
| 1755 | 1757 | |
| 1758 | $(DRIVERS)/sderby.o: $(LAYOUT)/sderby.lh \ | |
| 1759 | $(LAYOUT)/spacewin.lh \ | |
| 1760 | $(LAYOUT)/pmroulet.lh \ | |
| 1761 | ||
| 1756 | 1762 | $(DRIVERS)/snookr10.o: $(LAYOUT)/snookr10.lh |
| 1757 | 1763 | |
| 1758 | 1764 | $(DRIVERS)/sspeedr.o: $(LAYOUT)/sspeedr.lh |
| r3232 | r3233 | |
|---|---|---|
| 1 | 1 | #include "driver.h" |
| 2 | 2 | |
| 3 | static UINT8 bg_color, old_bg_color; | |
| 4 | #define mainsnk_offset 8 | |
| 5 | static tilemap *me_fg_tilemap; | |
| 6 | static tilemap *me_bg_tilemap; | |
| 3 | static tilemap *tx_tilemap; | |
| 4 | static tilemap *bg_tilemap; | |
| 7 | 5 | UINT8 *mainsnk_fgram; |
| 8 | 6 | UINT8 *mainsnk_bgram; |
| 9 | static int me_gfx_ctrl; | |
| 10 | 7 | |
| 11 | WRITE8_HANDLER(mainsnk_c600_w) | |
| 8 | ||
| 9 | ||
| 10 | static TILEMAP_MAPPER( marvins_tx_scan_cols ) | |
| 12 | 11 | { |
| 13 | bg_color = data&0xf; | |
| 14 | me_gfx_ctrl=data; | |
| 15 | tilemap_mark_all_tiles_dirty (me_bg_tilemap); | |
| 16 | mame_printf_debug("canvas %04x\n",data&=0xf0); | |
| 12 | // tilemap is 36x28, the central part is from the first RAM page and the | |
| 13 | // extra 4 columns are from the second page | |
| 14 | col -= 2; | |
| 15 | if (col & 0x20) | |
| 16 | return 0x400 + row + ((col & 0x1f) << 5); | |
| 17 | else | |
| 18 | return row + (col << 5); | |
| 17 | 19 | } |
| 18 | 20 | |
| 19 | static TILE_GET_INFO( get_ | |
| 21 | static TILE_GET_INFO( get_tx | |
| 20 | 22 | { |
| 21 | int code = (mainsnk_fgram[tile_index]); | |
| 23 | int code = mainsnk_fgram[tile_index]; | |
| 24 | SET_TILE_INFO(0, | |
| 25 | code, | |
| 26 | 0, | |
| 27 | tile_index & 0x400 ? TILE_FORCE_LAYER0 : 0); | |
| 28 | } | |
| 22 | 29 | |
| 30 | static TILE_GET_INFO( get_bg_tile_info ) | |
| 31 | { | |
| 32 | int code = (mainsnk_bgram[tile_index]); | |
| 33 | ||
| 23 | 34 | SET_TILE_INFO( |
| 24 | 35 | 0, |
| 25 | 36 | code, |
| 26 | 0 | |
| 37 | 0 | |
| 27 | 38 | 0); |
| 28 | 39 | } |
| 29 | 40 | |
| 30 | static void stuff_palette( running_machine *machine, int source_index, int dest_index, int num_colors ) | |
| 41 | ||
| 42 | VIDEO_START(mainsnk) | |
| 31 | 43 | { |
| 44 | tx_tilemap = tilemap_create(get_tx_tile_info, marvins_tx_scan_cols, 8, 8, 36, 28); | |
| 45 | bg_tilemap = tilemap_create(get_bg_tile_info, tilemap_scan_cols, 8, 8, 32, 32); | |
| 32 | 46 | |
| 47 | tilemap_set_transparent_pen(tx_tilemap,15); | |
| 48 | tilemap_set_scrolldy(tx_tilemap, 8, 8); | |
| 33 | 49 | |
| 50 | tilemap_set_scrolldx(bg_tilemap, 16, 16); | |
| 51 | tilemap_set_scrolldy(bg_tilemap, 8, 8); | |
| 52 | } | |
| 34 | 53 | |
| 35 | UINT8 *color_prom = memory_region(machine, "proms") + source_index; | |
| 36 | int i; | |
| 37 | for( i=0; i<num_colors; i++ ) | |
| 38 | { | |
| 39 | int bit0=0,bit1,bit2,bit3; | |
| 40 | int red, green, blue; | |
| 41 | 54 | |
| 42 | bit0 = (color_prom[0x1000] >> 2) & 0x01; // ? | |
| 43 | bit1 = (color_prom[0x000] >> 1) & 0x01; | |
| 44 | bit2 = (color_prom[0x000] >> 2) & 0x01; | |
| 45 | bit3 = (color_prom[0x000] >> 3) & 0x01; | |
| 46 | red = 0x0e * bit0 + 0x1f * bit1 + 0x43 * bit2 + 0x8f * bit3; | |
| 55 | WRITE8_HANDLER(mainsnk_c600_w) | |
| 56 | { | |
| 57 | int bank; | |
| 47 | 58 | |
| 48 | bit0 = (color_prom[0x1000] >> 1) & 0x01; // ? | |
| 49 | bit1 = (color_prom[0x800] >> 2) & 0x01; | |
| 50 | bit2 = (color_prom[0x800] >> 3) & 0x01; | |
| 51 | bit3 = (color_prom[0x000] >> 0) & 0x01; | |
| 52 | green = 0x0e * bit0 + 0x1f * bit1 + 0x43 * bit2 + 0x8f * bit3; | |
| 59 | flip_screen_set(~data & 0x80); | |
| 53 | 60 | |
| 54 | bit0 = (color_prom[0x1000] >> 0) & 0x01; // ? | |
| 55 | bit1 = (color_prom[0x1000] >> 3) & 0x01; // ? | |
| 56 | bit2 = (color_prom[0x800] >> 0) & 0x01; | |
| 57 | bit3 = (color_prom[0x800] >> 1) & 0x01; | |
| 58 | blue = 0x0e * bit0 + 0x1f * bit1 + 0x43 * bit2 + 0x8f * bit3; | |
| 61 | tilemap_set_palette_offset(bg_tilemap, (data & 0x07) << 4); | |
| 62 | tilemap_set_palette_offset(tx_tilemap, (data & 0x07) << 4); | |
| 59 | 63 | |
| 60 | palette_set_color( machine, dest_index++, MAKE_RGB(red, green, blue) ); | |
| 61 | color_prom++; | |
| 62 | } | |
| 64 | bank = 0; | |
| 65 | if (machine->gfx[0]->total_elements == 0x400) // mainsnk | |
| 66 | bank = ((data & 0x30) >> 4); | |
| 67 | else if (machine->gfx[0]->total_elements == 0x800) // canvas | |
| 68 | bank = ((data & 0x40) >> 6) | ((data & 0x30) >> 3); | |
| 63 | 69 | |
| 70 | tilemap_set_pen_data_offset(bg_tilemap, (bank << 8) * machine->gfx[0]->char_modulo); | |
| 64 | 71 | } |
| 65 | 72 | |
| 66 | static void update_palette( running_machine *machine, int type ) | |
| 67 | { | |
| 68 | if( bg_color!=old_bg_color ) | |
| 69 | { | |
| 70 | stuff_palette( machine, 256+16*(bg_color&0x7), (0x11-type)*16, 16 ); | |
| 71 | old_bg_color = bg_color; | |
| 72 | } | |
| 73 | } | |
| 74 | ||
| 75 | ||
| 76 | 73 | WRITE8_HANDLER( mainsnk_fgram_w ) |
| 77 | 74 | { |
| 78 | 75 | mainsnk_fgram[offset] = data; |
| 79 | tilemap_mark_tile_dirty( | |
| 76 | tilemap_mark_tile_dirty(tx | |
| 80 | 77 | } |
| 81 | 78 | |
| 82 | ||
| 83 | static TILE_GET_INFO( get_me_bg_tile_info ) | |
| 84 | { | |
| 85 | int code = (mainsnk_bgram[tile_index]); | |
| 86 | ||
| 87 | SET_TILE_INFO( | |
| 88 | 0, | |
| 89 | code + ((me_gfx_ctrl<<4)&0x700), | |
| 90 | 0x10, | |
| 91 | 0); | |
| 92 | } | |
| 93 | ||
| 94 | ||
| 95 | 79 | WRITE8_HANDLER( mainsnk_bgram_w ) |
| 96 | 80 | { |
| 97 | 81 | mainsnk_bgram[offset] = data; |
| 98 | tilemap_mark_tile_dirty( | |
| 82 | tilemap_mark_tile_dirty( | |
| 99 | 83 | } |
| 100 | 84 | |
| 101 | 85 | |
| 102 | VIDEO_START(mainsnk) | |
| 103 | { | |
| 104 | old_bg_color = -1; | |
| 105 | stuff_palette( machine, 0, 0, 16*8 ); | |
| 106 | stuff_palette( machine, 16*8*3, 16*8, 16*8 ); | |
| 107 | me_fg_tilemap = tilemap_create(get_me_fg_tile_info,tilemap_scan_cols,8,8,32, 32); | |
| 108 | tilemap_set_transparent_pen(me_fg_tilemap,15); | |
| 109 | me_bg_tilemap = tilemap_create(get_me_bg_tile_info,tilemap_scan_cols,8,8,32, 32); | |
| 110 | tilemap_set_scrollx( me_fg_tilemap, 0, -mainsnk_offset ); | |
| 111 | tilemap_set_scrollx( me_bg_tilemap, 0, -mainsnk_offset ); | |
| 112 | } | |
| 113 | 86 | |
| 114 | 87 | static void draw_sprites(running_machine *machine, bitmap_t *bitmap, const rectangle *cliprect, int scrollx, int scrolly ) |
| 115 | 88 | { |
| 116 | 89 | const gfx_element *gfx = machine->gfx[1]; |
| 117 | 90 | const UINT8 *source, *finish; |
| 118 | 91 | source = spriteram; |
| 119 | finish = source + | |
| 92 | finish = source + 25*4; | |
| 120 | 93 | |
| 121 | 94 | while( source<finish ) |
| 122 | 95 | { |
| r3232 | r3233 | |
| 125 | 98 | int sy = source[0]; |
| 126 | 99 | int sx = source[2]; |
| 127 | 100 | int color = attributes&0xf; |
| 101 | int flipx = 0; | |
| 102 | int flipy = 0; | |
| 128 | 103 | if( sy>240 ) sy -= 256; |
| 129 | 104 | |
| 130 | 105 | tile_number |= attributes<<4 & 0x300; |
| 131 | 106 | |
| 107 | sx = 288-16 - sx; | |
| 108 | sy += 8; | |
| 109 | ||
| 110 | if (flip_screen_get()) | |
| 111 | { | |
| 112 | sx = 288-16 - sx; | |
| 113 | sy = 224-16 - sy; | |
| 114 | flipx = !flipx; | |
| 115 | flipy = !flipy; | |
| 116 | } | |
| 117 | ||
| 132 | 118 | drawgfx( bitmap,gfx, |
| 133 | 119 | tile_number, |
| 134 | 120 | color, |
| 135 | 0,0, | |
| 136 | 256-sx+mainsnk_offset,sy, | |
| 121 | flipx,flipy, | |
| 122 | sx,sy, | |
| 137 | 123 | cliprect,TRANSPARENCY_PEN,7); |
| 138 | 124 | |
| 139 | 125 | source+=4; |
| r3232 | r3233 | |
| 141 | 127 | } |
| 142 | 128 | |
| 143 | 129 | |
| 144 | static void draw_status(running_machine *machine, bitmap_t *bitmap, const rectangle *cliprect,int dx,int off ) | |
| 145 | { | |
| 146 | const UINT8 *base = mainsnk_fgram+off; | |
| 147 | const gfx_element *gfx = machine->gfx[0]; | |
| 148 | int row; | |
| 149 | for( row=0; row<4; row++ ) | |
| 150 | { | |
| 151 | int sy,sx = (row&1)*8; | |
| 152 | const UINT8 *source = base + (row&1)*32; | |
| 153 | if( row>1 ) | |
| 154 | { | |
| 155 | sx+=256+16; | |
| 156 | } | |
| 157 | else | |
| 158 | { | |
| 159 | source+=30*32; | |
| 160 | } | |
| 161 | ||
| 162 | for( sy=0; sy<256; sy+=8 ) | |
| 163 | { | |
| 164 | int tile_number = *source++; | |
| 165 | drawgfx( bitmap, gfx, | |
| 166 | tile_number, tile_number>>5, | |
| 167 | 0,0, | |
| 168 | sx+dx,sy, | |
| 169 | cliprect, | |
| 170 | TRANSPARENCY_NONE, 0xf ); | |
| 171 | } | |
| 172 | } | |
| 173 | } | |
| 174 | ||
| 175 | 130 | VIDEO_UPDATE(mainsnk) |
| 176 | 131 | { |
| 177 | rectangle myclip; | |
| 178 | myclip.min_x = cliprect->min_x+8; | |
| 179 | myclip.max_x = cliprect->max_x-8; | |
| 180 | myclip.min_y = cliprect->min_y; | |
| 181 | myclip.max_y = cliprect->max_y; | |
| 182 | tilemap_draw(bitmap,&myclip,me_bg_tilemap,0,0); | |
| 183 | draw_sprites(screen->machine,bitmap,&myclip, 0,0 ); | |
| 184 | tilemap_draw(bitmap,&myclip,me_fg_tilemap,0,0); | |
| 185 | draw_status(screen->machine,bitmap,cliprect,0,0x400 ); | |
| 186 | draw_status(screen->machine,bitmap,cliprect,32*8,0x40 ); | |
| 187 | update_palette(screen->machine, 1); | |
| 188 | return 0; | |
| 189 | } | |
| 132 | tilemap_draw(bitmap,cliprect,bg_tilemap,0,0); | |
| 133 | draw_sprites(screen->machine,bitmap,cliprect, 0,0 ); | |
| 134 | tilemap_draw(bitmap,cliprect,tx_tilemap,0,0); | |
| 190 | 135 | |
| 191 | VIDEO_UPDATE(canvas) | |
| 192 | { | |
| 193 | rectangle myclip; | |
| 194 | myclip.min_x = cliprect->min_x+8; | |
| 195 | myclip.max_x = cliprect->max_x-8; | |
| 196 | myclip.min_y = cliprect->min_y; | |
| 197 | myclip.max_y = cliprect->max_y; | |
| 198 | tilemap_draw(bitmap,&myclip,me_bg_tilemap,0,0); | |
| 199 | draw_sprites(screen->machine,bitmap,&myclip, 0,0 ); | |
| 200 | // tilemap_draw(bitmap,&myclip,me_fg_tilemap,0,0); | |
| 201 | // draw_status(screen->machine,bitmap,cliprect,0,0x400 ); | |
| 202 | // draw_status(screen->machine,bitmap,cliprect,32*8,0x40 ); | |
| 203 | update_palette(screen->machine, 1); | |
| 204 | 136 | return 0; |
| 205 | 137 | } |
| r3232 | r3233 | |
|---|---|---|
| 250 | 250 | } |
| 251 | 251 | |
| 252 | 252 | |
| 253 | static const char *gfxregions[] = { "gfx1", "gfx2", "gfx3", "gfx4", "gfx5", "gfx6", "gfx7", "gfx8" }; | |
| 253 | static const char *const gfxregions[] = { "gfx1", "gfx2", "gfx3", "gfx4", "gfx5", "gfx6", "gfx7", "gfx8" }; | |
| 254 | 254 | |
| 255 | 255 | WRITE8_HANDLER( dynax_blit_romregion_w ) |
| 256 | 256 | { |
| r3232 | r3233 | |
|---|---|---|
| 260 | 260 | if (fastfred_hardware_type == 3) |
| 261 | 261 | { |
| 262 | 262 | // Imago |
| 263 | ||
| 264 | //fastfred_spriteram[offs + 2] & 0xf8 get only set at startup | |
| 265 | //the code is greater than 0x3f only at startup | |
| 266 | ||
| 267 | /* TODO: find correct sprites banking */ | |
| 268 | ||
| 269 | code = (fastfred_spriteram[offs + 1]) & 0x1f; | |
| 270 | ||
| 271 | code |= fastfred_spriteram[offs + 2]<<5; | |
| 272 | ||
| 273 | if(fastfred_spriteram[offs + 1] & 0x20) | |
| 274 | code ^= 0xff; | |
| 275 | ||
| 263 | code = (fastfred_spriteram[offs + 1]) & 0x3f; | |
| 276 | 264 | flipx = 0; |
| 277 | 265 | flipy = 0; |
| 278 | 266 | } |
| r3232 | r3233 | |
|---|---|---|
| 38 | 38 | |
| 39 | 39 | for (i = 0x200; i < 0x300; i++) |
| 40 | 40 | { |
| 41 | UINT16 ctabentry = (color_prom[i - 0x | |
| 41 | UINT16 ctabentry = (color_prom[i - 0x100] & 0x0f) | 0x10; | |
| 42 | 42 | colortable_entry_set_value(machine->colortable, i, ctabentry); |
| 43 | 43 | } |
| 44 | 44 | } |
| r3232 | r3233 | |
|---|---|---|
| 35 | 35 | |
| 36 | 36 | INLINE void get_crosshair_xy(running_machine *machine, int player, int *x, int *y) |
| 37 | 37 | { |
| 38 | static const char *gunnames[] = { "LIGHT0_X", "LIGHT0_Y", "LIGHT1_X", "LIGHT1_Y" }; | |
| 38 | static const char *const gunnames[] = { "LIGHT0_X", "LIGHT0_Y", "LIGHT1_X", "LIGHT1_Y" }; | |
| 39 | 39 | const rectangle *visarea = video_screen_get_visible_area(machine->primary_screen); |
| 40 | 40 | int width = visarea->max_x + 1 - visarea->min_x; |
| 41 | 41 | int height = visarea->max_y + 1 - visarea->min_y; |
| r3232 | r3233 | |
|---|---|---|
| 459 | 459 | READ8_HANDLER( itech8_blitter_r ) |
| 460 | 460 | { |
| 461 | 461 | int result = blitter_data[offset / 2]; |
| 462 | static const char *portnames[] = { "AN_C", "AN_D", "AN_E", "AN_F" }; | |
| 462 | static const char *const portnames[] = { "AN_C", "AN_D", "AN_E", "AN_F" }; | |
| 463 | 463 | |
| 464 | 464 | /* debugging */ |
| 465 | 465 | if (FULL_LOGGING) logerror("%04x:blitter_r(%02x)\n", activecpu_get_previouspc(), offset / 2); |
| r3232 | r3233 | |
|---|---|---|
| 187 | 187 | }; |
| 188 | 188 | |
| 189 | 189 | |
| 190 | static const char *gunnames[] = { "LIGHT0_X", "LIGHT1_X", "LIGHT0_Y", "LIGHT1_Y" }; | |
| 190 | static const char *const gunnames[] = { "LIGHT0_X", "LIGHT1_X", "LIGHT0_Y", "LIGHT1_Y" }; | |
| 191 | 191 | |
| 192 | 192 | static void lorddgun_calc_gun_scr(running_machine *machine, int i) |
| 193 | 193 | { |
| r3232 | r3233 | |
|---|---|---|
| 25 | 25 | static UINT8 *taitojc_dirty_map; |
| 26 | 26 | static UINT32 *taitojc_char_ram; |
| 27 | 27 | static UINT32 *taitojc_tile_ram; |
| 28 | static int taitojc_char_dirty | |
| 28 | static int taitojc_char_dirty | |
| 29 | 29 | static tilemap *taitojc_tilemap; |
| 30 | 30 | |
| 31 | 31 | static poly_manager *poly; |
| r3232 | r3233 | |
| 196 | 196 | { |
| 197 | 197 | int width, height; |
| 198 | 198 | |
| 199 | taitojc_char_dirty = 1; | |
| 200 | ||
| 199 | 201 | poly = poly_alloc(4000, sizeof(poly_extra_data), POLYFLAG_ALLOW_QUADS); |
| 200 | 202 | add_exit_callback(machine, taitojc_exit); |
| 201 | 203 |
| r3232 | r3233 | |
|---|---|---|
| 18 | 18 | * |
| 19 | 19 | *************************************/ |
| 20 | 20 | |
| 21 | #define MC6845_TAG ("vid | |
| 21 | #define MC6845_TAG ("vid_u18") | |
| 22 | 22 | |
| 23 | 23 | |
| 24 | 24 | |
| r3232 | r3233 | |
| 376 | 376 | AM_RANGE(0x9400, 0x9400) AM_MIRROR(0x03fc) AM_READWRITE(qix_addresslatch_r, qix_addresslatch_w) |
| 377 | 377 | AM_RANGE(0x9402, 0x9403) AM_MIRROR(0x03fc) AM_WRITE(SMH_RAM) AM_BASE_MEMBER(qix_state, videoram_address) |
| 378 | 378 | AM_RANGE(0x9800, 0x9800) AM_MIRROR(0x03ff) AM_READ(SMH_RAM) AM_BASE_MEMBER(qix_state, scanline_latch) |
| 379 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid-u18", mc6845_address_w) | |
| 380 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid-u18", mc6845_register_r, mc6845_register_w) | |
| 379 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid_u18", mc6845_address_w) | |
| 380 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid_u18", mc6845_register_r, mc6845_register_w) | |
| 381 | 381 | AM_RANGE(0xa000, 0xffff) AM_ROM |
| 382 | 382 | ADDRESS_MAP_END |
| 383 | 383 | |
| r3232 | r3233 | |
| 394 | 394 | AM_RANGE(0x9400, 0x9400) AM_MIRROR(0x03fc) AM_READWRITE(qix_addresslatch_r, qix_addresslatch_w) |
| 395 | 395 | AM_RANGE(0x9402, 0x9403) AM_MIRROR(0x03fc) AM_WRITE(SMH_RAM) AM_BASE_MEMBER(qix_state, videoram_address) |
| 396 | 396 | AM_RANGE(0x9800, 0x9800) AM_MIRROR(0x03ff) AM_READ(SMH_RAM) AM_BASE_MEMBER(qix_state, scanline_latch) |
| 397 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid-u18", mc6845_address_w) | |
| 398 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid-u18", mc6845_register_r, mc6845_register_w) | |
| 397 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid_u18", mc6845_address_w) | |
| 398 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid_u18", mc6845_register_r, mc6845_register_w) | |
| 399 | 399 | AM_RANGE(0xa000, 0xbfff) AM_ROMBANK(1) |
| 400 | 400 | AM_RANGE(0xc000, 0xffff) AM_ROM |
| 401 | 401 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 413 | 413 | AM_RANGE(0x9401, 0x9401) AM_MIRROR(0x03fc) AM_WRITE(SMH_RAM) AM_BASE_MEMBER(qix_state, videoram_mask) |
| 414 | 414 | AM_RANGE(0x9402, 0x9403) AM_MIRROR(0x03fc) AM_WRITE(SMH_RAM) AM_BASE_MEMBER(qix_state, videoram_address) |
| 415 | 415 | AM_RANGE(0x9800, 0x9800) AM_MIRROR(0x03ff) AM_READ(SMH_RAM) AM_BASE_MEMBER(qix_state, scanline_latch) |
| 416 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid-u18", mc6845_address_w) | |
| 417 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid-u18", mc6845_register_r, mc6845_register_w) | |
| 416 | AM_RANGE(0x9c00, 0x9c00) AM_MIRROR(0x03fe) AM_DEVWRITE(MC6845, "vid_u18", mc6845_address_w) | |
| 417 | AM_RANGE(0x9c01, 0x9c01) AM_MIRROR(0x03fe) AM_DEVREADWRITE(MC6845, "vid_u18", mc6845_register_r, mc6845_register_w) | |
| 418 | 418 | AM_RANGE(0xa000, 0xffff) AM_ROM |
| 419 | 419 | ADDRESS_MAP_END |
| 420 | 420 |
| r3232 | r3233 | |
|---|---|---|
| 48 | 48 | } |
| 49 | 49 | |
| 50 | 50 | |
| 51 | READ8_HANDLER( mnchmobl_sprite_xpos_r ){ return mnchmobl_sprite_xpos[offset]; } | |
| 52 | WRITE8_HANDLER( mnchmobl_sprite_xpos_w ){ mnchmobl_sprite_xpos[offset] = data; } | |
| 53 | ||
| 54 | READ8_HANDLER( mnchmobl_sprite_attr_r ){ return mnchmobl_sprite_attr[offset]; } | |
| 55 | WRITE8_HANDLER( mnchmobl_sprite_attr_w ){ mnchmobl_sprite_attr[offset] = data; } | |
| 56 | ||
| 57 | READ8_HANDLER( mnchmobl_sprite_tile_r ){ return mnchmobl_sprite_tile[offset]; } | |
| 58 | WRITE8_HANDLER( mnchmobl_sprite_tile_w ){ mnchmobl_sprite_tile[offset] = data; } | |
| 59 | ||
| 60 | 51 | VIDEO_START( mnchmobl ) |
| 61 | 52 | { |
| 62 | 53 | tmpbitmap = auto_bitmap_alloc(512,512,video_screen_get_format(machine->primary_screen)); |
| r3232 | r3233 | |
|---|---|---|
| 656 | 656 | return bank_gfx[bpp - 4][bank_index]; |
| 657 | 657 | |
| 658 | 658 | /* if the bank is out of range, call it 0 */ |
| 659 | if (0x80000 * (bank_index - 1) >= memory_region_length(machine, " | |
| 659 | if (0x80000 * (bank_index - 1) >= memory_region_length(machine, "tiles")) | |
| 660 | 660 | return 0; |
| 661 | 661 | |
| 662 | 662 | /* don't have one? let's make it ... first find any empty slot */ |
| r3232 | r3233 | |
| 683 | 683 | default: |
| 684 | 684 | fatalerror("Unsupported bpp"); |
| 685 | 685 | } |
| 686 | decodegfx(machine->gfx[gfx_index], &memory_region(machine, " | |
| 686 | decodegfx(machine->gfx[gfx_index], &memory_region(machine, "tiles")[0x80000 * (bank_index - 1)], 0, machine->gfx[gfx_index]->total_elements); | |
| 687 | 687 | |
| 688 | 688 | /* set the color information */ |
| 689 | 689 | machine->gfx[gfx_index]->color_base = 256; |
| r3232 | r3233 | |
|---|---|---|
| 550 | 550 | int pri; |
| 551 | 551 | int bg_center = 144 - ((((bg1_scroll_x + bg2_scroll_x ) & 0x1ff) - 288) / 2); |
| 552 | 552 | |
| 553 | const device_config *_2d_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "2D"); | |
| 554 | const device_config *_3d_left_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "3D Left"); | |
| 555 | const device_config *_3d_right_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "3D Right"); | |
| 553 | const device_config *_2d_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "2d"); | |
| 554 | const device_config *_3d_left_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "3dleft"); | |
| 555 | const device_config *_3d_right_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "3dright"); | |
| 556 | 556 | |
| 557 | 557 | if (screen != _2d_screen) |
| 558 | 558 | { |
| r3232 | r3233 | |
|---|---|---|
| 11 | 11 | UINT8 *fortyl_video_ctrl; |
| 12 | 12 | |
| 13 | 13 | static UINT8 fortyl_flipscreen,fortyl_pix_redraw; |
| 14 | static UINT8 fortyl_xoffset = 128; | |
| 14 | static const UINT8 fortyl_xoffset = 128; | |
| 15 | 15 | |
| 16 | 16 | static UINT8 *fortyl_pixram1; |
| 17 | 17 | static UINT8 *fortyl_pixram2; |
| r3232 | r3233 | |
|---|---|---|
| 718 | 718 | int x, y, b; |
| 719 | 719 | |
| 720 | 720 | const device_config *main_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "main"); |
| 721 | const device_config *lcd0_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "LCD0"); | |
| 722 | const device_config *lcd1_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "LCD1"); | |
| 721 | const device_config *lcd0_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "lcd0"); | |
| 722 | const device_config *lcd1_screen = device_list_find_by_tag(screen->machine->config->devicelist, VIDEO_SCREEN, "lcd1"); | |
| 723 | 723 | |
| 724 | 724 | if (screen == main_screen) VIDEO_UPDATE_CALL(mbmj8688); |
| 725 | 725 |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | Bit 0x04 - Playfield 1 width (0 is 64 tiles, 0x4 is 128 tiles) |
| 14 | 14 | Bit 0x10 - Playfield 1 disable |
| 15 | 15 | Bit 0x20 - Playfield 1 rowscroll enable |
| 16 | Bit 0x40 - Playfield 1 y-offset table enable | |
| 16 | 17 | 12: Playfield 2 control |
| 17 | 18 | Bits0x03 - Playfield 2 VRAM base |
| 18 | 19 | Bit 0x04 - Playfield 2 width (0 is 64 tiles, 0x4 is 128 tiles) |
| 19 | 20 | Bit 0x10 - Playfield 2 disable |
| 20 | 21 | Bit 0x20 - Playfield 2 rowscroll enable |
| 22 | Bit 0x40 - Playfield 1 y-offset table enable | |
| 21 | 23 | 14: Bits0x03 - Sprite/Tile Priority (related to sprite color) |
| 22 | 24 | |
| 23 | 25 | Emulation by Bryan McPhail, mish@tendril.co.uk, thanks to Chris Hardy! |
| r3232 | r3233 | |
| 262 | 264 | WRITE16_HANDLER( m90_video_control_w ) |
| 263 | 265 | { |
| 264 | 266 | COMBINE_DATA(&m90_video_control_data[offset]); |
| 265 | // printf("%04x-%04x ",offset,m90_video_control_data[offset]); | |
| 266 | 267 | } |
| 267 | 268 | |
| 268 | 269 | static void markdirty(tilemap *tmap,int page,offs_t offset) |
| r3232 | r3233 | |
| 348 | 349 | tilemap_set_scrollx( pf2_wide_layer,0, m90_video_control_data[3]+256-2 ); |
| 349 | 350 | } |
| 350 | 351 | |
| 351 | tilemap_set_scrolly( pf1_layer,0, m90_video_control_data[0] ); | |
| 352 | tilemap_set_scrolly( pf2_layer,0, m90_video_control_data[2] ); | |
| 353 | tilemap_set_scrolly( pf1_wide_layer,0, m90_video_control_data[0] ); | |
| 354 | tilemap_set_scrolly( pf2_wide_layer,0, m90_video_control_data[2] ); | |
| 355 | ||
| 356 | 352 | fillbitmap(priority_bitmap,0,cliprect); |
| 357 | 353 | |
| 358 | 354 | if (video_enable) { |
| r3232 | r3233 | |
| 361 | 357 | |
| 362 | 358 | if (pf2_enable) |
| 363 | 359 | { |
| 364 | if (m90_video_control_data[6] & 0x4) { | |
| 365 | tilemap_draw(bitmap,cliprect,pf2_wide_layer,0,0); | |
| 366 | tilemap_draw(bitmap,cliprect,pf2_wide_layer,1,1); | |
| 367 | } else { | |
| 368 | tilemap_draw(bitmap,cliprect,pf2_layer,0,0); | |
| 369 | tilemap_draw(bitmap,cliprect,pf2_layer,1,1); | |
| 360 | // use the playfield 2 y-offset table for each scanline | |
| 361 | if (m90_video_control_data[6] & 0x40) { | |
| 362 | ||
| 363 | int line; | |
| 364 | rectangle clip; | |
| 365 | clip.min_x = cliprect->min_x; | |
| 366 | clip.max_x = cliprect->max_x; | |
| 367 | ||
| 368 | for(line = 0; line < 512; line++) | |
| 369 | { | |
| 370 | clip.min_y = clip.max_y = line; | |
| 371 | ||
| 372 | if (m90_video_control_data[6] & 0x4) { | |
| 373 | tilemap_set_scrolly(pf2_wide_layer, 0, m90_video_control_data[2] + m90_video_data[0xfc00/2 + line] + 128); | |
| 374 | tilemap_draw(bitmap,&clip,pf2_wide_layer,0,0); | |
| 375 | tilemap_draw(bitmap,&clip,pf2_wide_layer,1,1); | |
| 376 | } else { | |
| 377 | tilemap_set_scrolly(pf2_layer, 0, m90_video_control_data[2] + m90_video_data[0xfc00/2 + line] + 128); | |
| 378 | tilemap_draw(bitmap,&clip,pf2_layer,0,0); | |
| 379 | tilemap_draw(bitmap,&clip,pf2_layer,1,1); | |
| 380 | } | |
| 381 | } | |
| 370 | 382 | } |
| 383 | else | |
| 384 | { | |
| 385 | if (m90_video_control_data[6] & 0x4) { | |
| 386 | tilemap_set_scrolly( pf2_wide_layer,0, m90_video_control_data[2] ); | |
| 387 | tilemap_draw(bitmap,cliprect,pf2_wide_layer,0,0); | |
| 388 | tilemap_draw(bitmap,cliprect,pf2_wide_layer,1,1); | |
| 389 | } else { | |
| 390 | tilemap_set_scrolly( pf2_layer,0, m90_video_control_data[2] ); | |
| 391 | tilemap_draw(bitmap,cliprect,pf2_layer,0,0); | |
| 392 | tilemap_draw(bitmap,cliprect,pf2_layer,1,1); | |
| 393 | } | |
| 394 | } | |
| 371 | 395 | } |
| 372 | 396 | |
| 373 | 397 | if (pf1_enable) |
| 374 | 398 | { |
| 375 | if (m90_video_control_data[5] & 0x4) { | |
| 376 | tilemap_draw(bitmap,cliprect,pf1_wide_layer,0,0); | |
| 377 | tilemap_draw(bitmap,cliprect,pf1_wide_layer,1,1); | |
| 378 | } else { | |
| 379 | tilemap_draw(bitmap,cliprect,pf1_layer,0,0); | |
| 380 | tilemap_draw(bitmap,cliprect,pf1_layer,1,1); | |
| 399 | // use the playfield 1 y-offset table for each scanline | |
| 400 | if (m90_video_control_data[5] & 0x40) { | |
| 401 | ||
| 402 | int line; | |
| 403 | rectangle clip; | |
| 404 | clip.min_x = cliprect->min_x; | |
| 405 | clip.max_x = cliprect->max_x; | |
| 406 | ||
| 407 | for(line = 0; line < 512; line++) | |
| 408 | { | |
| 409 | clip.min_y = clip.max_y = line; | |
| 410 | ||
| 411 | if (m90_video_control_data[5] & 0x4) { | |
| 412 | tilemap_set_scrolly(pf1_wide_layer, 0, m90_video_control_data[0] + m90_video_data[0xf800/2 + line] + 128); | |
| 413 | tilemap_draw(bitmap,&clip,pf1_wide_layer,0,0); | |
| 414 | tilemap_draw(bitmap,&clip,pf1_wide_layer,1,1); | |
| 415 | } else { | |
| 416 | tilemap_set_scrolly(pf1_layer, 0, m90_video_control_data[0] + m90_video_data[0xf800/2 + line] + 128 ); | |
| 417 | tilemap_draw(bitmap,&clip,pf1_layer,0,0); | |
| 418 | tilemap_draw(bitmap,&clip,pf1_layer,1,1); | |
| 419 | } | |
| 420 | } | |
| 381 | 421 | } |
| 422 | else | |
| 423 | { | |
| 424 | if (m90_video_control_data[5] & 0x4) { | |
| 425 | tilemap_set_scrolly( pf1_wide_layer,0, m90_video_control_data[0] ); | |
| 426 | tilemap_draw(bitmap,cliprect,pf1_wide_layer,0,0); | |
| 427 | tilemap_draw(bitmap,cliprect,pf1_wide_layer,1,1); | |
| 428 | } else { | |
| 429 | tilemap_set_scrolly( pf1_layer,0, m90_video_control_data[0] ); | |
| 430 | tilemap_draw(bitmap,cliprect,pf1_layer,0,0); | |
| 431 | tilemap_draw(bitmap,cliprect,pf1_layer,1,1); | |
| 432 | } | |
| 433 | } | |
| 382 | 434 | } |
| 383 | 435 | |
| 384 | 436 | draw_sprites(screen->machine,bitmap,cliprect); |
| 437 | ||
| 385 | 438 | } else { |
| 386 | 439 | fillbitmap(bitmap,get_black_pen(screen->machine),cliprect); |
| 387 | 440 | } |
| r3232 | r3233 | |
|---|---|---|
| 346 | 346 | |
| 347 | 347 | static READ8_HANDLER( combascb_io_r ) |
| 348 | 348 | { |
| 349 | static const char *portnames[] = { "IN0", "IN1", "DSW1", "DSW2" }; | |
| 349 | static const char *const portnames[] = { "IN0", "IN1", "DSW1", "DSW2" }; | |
| 350 | 350 | |
| 351 | 351 | return input_port_read(machine, portnames[offset]); |
| 352 | 352 | } |
| r3232 | r3233 | |
|---|---|---|
| 10 | 10 | #include "includes/wwfwfest.h" |
| 11 | 11 | |
| 12 | 12 | static tilemap *fg0_tilemap, *bg0_tilemap, *bg1_tilemap; |
| 13 | int wwfwfest_pri; | |
| 14 | int wwfwfest_bg0_scrollx, wwfwfest_bg0_scrolly, wwfwfest_bg1_scrollx, wwfwfest_bg1_scrolly; | |
| 13 | UINT16 wwfwfest_pri; | |
| 14 | UINT16 wwfwfest_bg0_scrollx, wwfwfest_bg0_scrolly, wwfwfest_bg1_scrollx, wwfwfest_bg1_scrolly; | |
| 15 | 15 | UINT16 *wwfwfest_fg0_videoram, *wwfwfest_bg0_videoram, *wwfwfest_bg1_videoram; |
| 16 | static | |
| 16 | static UINT16 sprite_xoff, bg0_dx, bg1_dx[2]; | |
| 17 | 17 | |
| 18 | 18 | /******************************************************************************* |
| 19 | 19 | Write Handlers |
| r3232 | r3233 | |
| 224 | 224 | |
| 225 | 225 | VIDEO_START( wwfwfest ) |
| 226 | 226 | { |
| 227 | state_save_register_global(wwfwfest_pri); | |
| 228 | state_save_register_global(wwfwfest_bg0_scrollx); | |
| 229 | state_save_register_global(wwfwfest_bg0_scrolly); | |
| 230 | state_save_register_global(wwfwfest_bg1_scrollx); | |
| 231 | state_save_register_global(wwfwfest_bg1_scrolly); | |
| 232 | ||
| 227 | 233 | fg0_tilemap = tilemap_create(get_fg0_tile_info,tilemap_scan_rows, 8, 8,64,32); |
| 228 | 234 | bg1_tilemap = tilemap_create(get_bg1_tile_info,tilemap_scan_rows, 16, 16,32,32); |
| 229 | 235 | bg0_tilemap = tilemap_create(get_bg0_tile_info,tilemap_scan_rows, 16, 16,32,32); |
| r0 | r3233 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 2 | <mamelayout version="2"> | |
| 3 | <element name="L1" defstate="1"> | |
| 4 | <rect state="1"> | |
| 5 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 6 | </rect> | |
| 7 | <rect state="0"> | |
| 8 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 9 | </rect> | |
| 10 | <text string="HOLD1"> | |
| 11 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 12 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 13 | </text> | |
| 14 | </element> | |
| 15 | ||
| 16 | <element name="L2" defstate="1"> | |
| 17 | <rect state="1"> | |
| 18 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 19 | </rect> | |
| 20 | <rect state="0"> | |
| 21 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 22 | </rect> | |
| 23 | <text string="HOLD2"> | |
| 24 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 25 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 26 | </text> | |
| 27 | </element> | |
| 28 | ||
| 29 | <element name="L3" defstate="1"> | |
| 30 | <rect state="1"> | |
| 31 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 32 | </rect> | |
| 33 | <rect state="0"> | |
| 34 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 35 | </rect> | |
| 36 | <text string="HOLD3"> | |
| 37 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 38 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 39 | </text> | |
| 40 | </element> | |
| 41 | ||
| 42 | <element name="L4" defstate="1"> | |
| 43 | <rect state="1"> | |
| 44 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 45 | </rect> | |
| 46 | <rect state="0"> | |
| 47 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 48 | </rect> | |
| 49 | <text string="HOLD4"> | |
| 50 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 51 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 52 | </text> | |
| 53 | </element> | |
| 54 | ||
| 55 | <element name="L5" defstate="1"> | |
| 56 | <rect state="1"> | |
| 57 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 58 | </rect> | |
| 59 | <rect state="0"> | |
| 60 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 61 | </rect> | |
| 62 | <text string="HOLD5"> | |
| 63 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 64 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 65 | </text> | |
| 66 | </element> | |
| 67 | ||
| 68 | <element name="L6" defstate="1"> | |
| 69 | <rect state="1"> | |
| 70 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 71 | </rect> | |
| 72 | <rect state="0"> | |
| 73 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 74 | </rect> | |
| 75 | <text string="START"> | |
| 76 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 77 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 78 | </text> | |
| 79 | </element> | |
| 80 | ||
| 81 | <element name="L7" defstate="1"> | |
| 82 | <rect state="1"> | |
| 83 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 84 | </rect> | |
| 85 | <rect state="0"> | |
| 86 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 87 | </rect> | |
| 88 | <text string="BET/TAKE"> | |
| 89 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 90 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 91 | </text> | |
| 92 | </element> | |
| 93 | ||
| 94 | <element name="L8" defstate="1"> | |
| 95 | <rect state="1"> | |
| 96 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 97 | </rect> | |
| 98 | <rect state="0"> | |
| 99 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 100 | </rect> | |
| 101 | <text string="PAYOUT"> | |
| 102 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 103 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 104 | </text> | |
| 105 | </element> | |
| 106 | ||
| 107 | <view name="Button Lamps"> | |
| 108 | <screen index="0"> | |
| 109 | <bounds left="0" top="0" right="4" bottom="3" /> | |
| 110 | </screen> | |
| 111 | <bezel name="lamp1" element="L1"> | |
| 112 | <bounds x="1.6" y="3.13" width="0.40" height="0.24" /> | |
| 113 | </bezel> | |
| 114 | <bezel name="lamp2" element="L2"> | |
| 115 | <bounds x="2.1" y="3.13" width="0.40" height="0.24" /> | |
| 116 | </bezel> | |
| 117 | <bezel name="lamp3" element="L3"> | |
| 118 | <bounds x="2.6" y="3.13" width="0.40" height="0.24" /> | |
| 119 | </bezel> | |
| 120 | <bezel name="lamp4" element="L4"> | |
| 121 | <bounds x="3.1" y="3.13" width="0.40" height="0.24" /> | |
| 122 | </bezel> | |
| 123 | <bezel name="lamp5" element="L5"> | |
| 124 | <bounds x="3.6" y="3.13" width="0.40" height="0.24" /> | |
| 125 | </bezel> | |
| 126 | <bezel name="lamp6" element="L6"> | |
| 127 | <bounds x="0" y="3.13" width="0.40" height="0.24" /> | |
| 128 | </bezel> | |
| 129 | <bezel name="lamp7" element="L7"> | |
| 130 | <bounds x="0.5" y="3.13" width="0.40" height="0.24" /> | |
| 131 | </bezel> | |
| 132 | <bezel name="lamp8" element="L8"> | |
| 133 | <bounds x="1.0" y="3.13" width="0.40" height="0.24" /> | |
| 134 | </bezel> | |
| 135 | </view> | |
| 136 | </mamelayout> |
| r0 | r3233 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 2 | <mamelayout version="2"> | |
| 3 | <element name="L1" defstate="1"> | |
| 4 | <rect state="1"> | |
| 5 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 6 | </rect> | |
| 7 | <rect state="0"> | |
| 8 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 9 | </rect> | |
| 10 | <text string="HOLD1"> | |
| 11 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 12 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 13 | </text> | |
| 14 | </element> | |
| 15 | ||
| 16 | <element name="L2" defstate="1"> | |
| 17 | <rect state="1"> | |
| 18 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 19 | </rect> | |
| 20 | <rect state="0"> | |
| 21 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 22 | </rect> | |
| 23 | <text string="HOLD2"> | |
| 24 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 25 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 26 | </text> | |
| 27 | </element> | |
| 28 | ||
| 29 | <element name="L3" defstate="1"> | |
| 30 | <rect state="1"> | |
| 31 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 32 | </rect> | |
| 33 | <rect state="0"> | |
| 34 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 35 | </rect> | |
| 36 | <text string="HOLD3"> | |
| 37 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 38 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 39 | </text> | |
| 40 | </element> | |
| 41 | ||
| 42 | <element name="L4" defstate="1"> | |
| 43 | <rect state="1"> | |
| 44 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 45 | </rect> | |
| 46 | <rect state="0"> | |
| 47 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 48 | </rect> | |
| 49 | <text string="HOLD4"> | |
| 50 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 51 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 52 | </text> | |
| 53 | </element> | |
| 54 | ||
| 55 | <element name="L5" defstate="1"> | |
| 56 | <rect state="1"> | |
| 57 | <color red="1.0" green="0.0" blue="0.0" /> | |
| 58 | </rect> | |
| 59 | <rect state="0"> | |
| 60 | <color red="0.3" green="0.0" blue="0.0" /> | |
| 61 | </rect> | |
| 62 | <text string="HOLD5"> | |
| 63 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 64 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 65 | </text> | |
| 66 | </element> | |
| 67 | ||
| 68 | <element name="L6" defstate="1"> | |
| 69 | <rect state="1"> | |
| 70 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 71 | </rect> | |
| 72 | <rect state="0"> | |
| 73 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 74 | </rect> | |
| 75 | <text string="START"> | |
| 76 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 77 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 78 | </text> | |
| 79 | </element> | |
| 80 | ||
| 81 | <element name="L7" defstate="1"> | |
| 82 | <rect state="1"> | |
| 83 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 84 | </rect> | |
| 85 | <rect state="0"> | |
| 86 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 87 | </rect> | |
| 88 | <text string="BET"> | |
| 89 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 90 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 91 | </text> | |
| 92 | </element> | |
| 93 | ||
| 94 | ||
| 95 | <view name="Button Lamps"> | |
| 96 | <screen index="0"> | |
| 97 | <bounds left="0" top="0" right="4" bottom="3" /> | |
| 98 | </screen> | |
| 99 | <bezel name="lamp1" element="L1"> | |
| 100 | <bounds x="1.6" y="3.13" width="0.40" height="0.24" /> | |
| 101 | </bezel> | |
| 102 | <bezel name="lamp2" element="L2"> | |
| 103 | <bounds x="2.1" y="3.13" width="0.40" height="0.24" /> | |
| 104 | </bezel> | |
| 105 | <bezel name="lamp3" element="L3"> | |
| 106 | <bounds x="2.6" y="3.13" width="0.40" height="0.24" /> | |
| 107 | </bezel> | |
| 108 | <bezel name="lamp4" element="L4"> | |
| 109 | <bounds x="3.1" y="3.13" width="0.40" height="0.24" /> | |
| 110 | </bezel> | |
| 111 | <bezel name="lamp5" element="L5"> | |
| 112 | <bounds x="3.6" y="3.13" width="0.40" height="0.24" /> | |
| 113 | </bezel> | |
| 114 | <bezel name="lamp6" element="L6"> | |
| 115 | <bounds x="0" y="3.13" width="0.40" height="0.24" /> | |
| 116 | </bezel> | |
| 117 | <bezel name="lamp7" element="L7"> | |
| 118 | <bounds x="0.5" y="3.13" width="0.40" height="0.24" /> | |
| 119 | </bezel> | |
| 120 | </view> | |
| 121 | </mamelayout> |
| r0 | r3233 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 2 | <mamelayout version="2"> | |
| 3 | ||
| 4 | <element name="L1" defstate="1"> | |
| 5 | <rect state="1"> | |
| 6 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 7 | </rect> | |
| 8 | <rect state="0"> | |
| 9 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 10 | </rect> | |
| 11 | <text string="START"> | |
| 12 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 13 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 14 | </text> | |
| 15 | </element> | |
| 16 | ||
| 17 | <element name="L2" defstate="1"> | |
| 18 | <rect state="1"> | |
| 19 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 20 | </rect> | |
| 21 | <rect state="0"> | |
| 22 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 23 | </rect> | |
| 24 | <text string="BET"> | |
| 25 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 26 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 27 | </text> | |
| 28 | </element> | |
| 29 | ||
| 30 | ||
| 31 | <view name="Button Lamps"> | |
| 32 | <screen index="0"> | |
| 33 | <bounds left="0" top="0" right="4" bottom="3" /> | |
| 34 | </screen> | |
| 35 | <bezel name="lamp1" element="L1"> | |
| 36 | <bounds x="0" y="3.13" width="0.40" height="0.24" /> | |
| 37 | </bezel> | |
| 38 | <bezel name="lamp2" element="L2"> | |
| 39 | <bounds x="0.5" y="3.13" width="0.40" height="0.24" /> | |
| 40 | </bezel> | |
| 41 | </view> | |
| 42 | </mamelayout> |
| r0 | r3233 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 2 | <mamelayout version="2"> | |
| 3 | ||
| 4 | <element name="L1" defstate="1"> | |
| 5 | <rect state="1"> | |
| 6 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 7 | </rect> | |
| 8 | <rect state="0"> | |
| 9 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 10 | </rect> | |
| 11 | <text string="START"> | |
| 12 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 13 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 14 | </text> | |
| 15 | </element> | |
| 16 | ||
| 17 | <element name="L2" defstate="1"> | |
| 18 | <rect state="1"> | |
| 19 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 20 | </rect> | |
| 21 | <rect state="0"> | |
| 22 | <color red="0.3" green="0.3" blue="0.3" /> | |
| 23 | </rect> | |
| 24 | <text string="BET"> | |
| 25 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 26 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 27 | </text> | |
| 28 | </element> | |
| 29 | ||
| 30 | <element name="L3" defstate="1"> | |
| 31 | <rect state="1"> | |
| 32 | <color red="0.0" green="1.0" blue="0.0" /> | |
| 33 | </rect> | |
| 34 | <rect state="0"> | |
| 35 | <color red="0.0" green="0.3" blue="0.0" /> | |
| 36 | </rect> | |
| 37 | <text string="END OF RACE"> | |
| 38 | <color red="0.0" green="0.0" blue="0.0" /> | |
| 39 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 40 | </text> | |
| 41 | </element> | |
| 42 | ||
| 43 | ||
| 44 | <view name="Button Lamps"> | |
| 45 | <screen index="0"> | |
| 46 | <bounds left="0" top="0" right="4" bottom="3" /> | |
| 47 | </screen> | |
| 48 | <bezel name="lamp1" element="L1"> | |
| 49 | <bounds x="0" y="3.13" width="0.40" height="0.24" /> | |
| 50 | </bezel> | |
| 51 | <bezel name="lamp2" element="L2"> | |
| 52 | <bounds x="0.5" y="3.13" width="0.40" height="0.24" /> | |
| 53 | </bezel> | |
| 54 | <bezel name="lamp3" element="L3"> | |
| 55 | <bounds x="1.6" y="3.13" width="2.00" height="0.24" /> | |
| 56 | </bezel> | |
| 57 | </view> | |
| 58 | </mamelayout> |
| r3232 | r3233 | |
|---|---|---|
| 122 | 122 | /* |
| 123 | 123 | Function prototypes |
| 124 | 124 | */ |
| 125 | INLINE void z80_bank(int num, int data); | |
| 125 | INLINE void z80_bank(running_machine *machine, int num, int data); | |
| 126 | 126 | |
| 127 | 127 | |
| 128 | 128 | static void update_irqs(running_machine *machine) |
| r3232 | r3233 | |
| 380 | 380 | return 0; |
| 381 | 381 | } |
| 382 | 382 | |
| 383 | INLINE UINT8* blitter_get_addr(UINT32 addr) | |
| 383 | INLINE UINT8* blitter_get_addr(running_machine *machine, UINT32 addr) | |
| 384 | 384 | { |
| 385 | 385 | if (addr < 0x10000) |
| 386 | 386 | { |
| 387 | 387 | /* Is this region fixed? */ |
| 388 | return (UINT8*)(memory_region( | |
| 388 | return (UINT8*)(memory_region(machine, "user1") + addr); | |
| 389 | 389 | } |
| 390 | 390 | else if(addr < 0x20000) |
| 391 | 391 | { |
| 392 | 392 | addr &= 0xffff; |
| 393 | 393 | addr += (bank[0] & 1) ? 0x10000 : 0; |
| 394 | 394 | |
| 395 | return (UINT8*)(memory_region( | |
| 395 | return (UINT8*)(memory_region(machine, "user1") + addr + ((bank[0] >> 1) * 0x20000)); | |
| 396 | 396 | } |
| 397 | 397 | else if (addr >= 0x20000 && addr < 0x40000) |
| 398 | 398 | { |
| r3232 | r3233 | |
| 410 | 410 | The Flare One blitter is a simpler design with slightly different parameters |
| 411 | 411 | and will require hardware tests to figure everything out correctly. |
| 412 | 412 | */ |
| 413 | static void RunBlit( | |
| 413 | static void RunBlit(running_machine *machine) | |
| 414 | 414 | { |
| 415 | #define BLITPRG_READ(x) blitter.x = *(blitter_get_addr(blitter.program.addr++)) | |
| 415 | #define BLITPRG_READ(x) blitter.x = *(blitter_get_addr(machine, blitter.program.addr++)) | |
| 416 | 416 | |
| 417 | 417 | int cycles_used = 0; |
| 418 | 418 | |
| r3232 | r3233 | |
| 522 | 522 | blitter.source.addr0 -=blitter.step; |
| 523 | 523 | } |
| 524 | 524 | |
| 525 | *blitter_get_addr(blitter.dest.addr) = blitter.pattern; | |
| 525 | *blitter_get_addr(machine, blitter.dest.addr) = blitter.pattern; | |
| 526 | 526 | cycles_used++; |
| 527 | 527 | |
| 528 | 528 | } while (--innercnt); |
| r3232 | r3233 | |
| 536 | 536 | |
| 537 | 537 | if (LOOPTYPE == 3 && innercnt == blitter.innercnt) |
| 538 | 538 | { |
| 539 | srcdata = *(blitter_get_addr(blitter.source.addr & 0xfffff)); | |
| 539 | srcdata = *(blitter_get_addr(machine, blitter.source.addr & 0xfffff)); | |
| 540 | 540 | blitter.source.loword++; |
| 541 | 541 | cycles_used++; |
| 542 | 542 | } |
| r3232 | r3233 | |
| 546 | 546 | { |
| 547 | 547 | if (LOOPTYPE == 0 || LOOPTYPE == 1) |
| 548 | 548 | { |
| 549 | srcdata = *(blitter_get_addr(blitter.source.addr & 0xfffff)); | |
| 549 | srcdata = *(blitter_get_addr(machine, blitter.source.addr & 0xfffff)); | |
| 550 | 550 | cycles_used++; |
| 551 | 551 | |
| 552 | 552 | if (blitter.modectl & MODE_SSIGN) |
| r3232 | r3233 | |
| 561 | 561 | /* Read destination pixel? */ |
| 562 | 562 | if (LOOPTYPE == 0) |
| 563 | 563 | { |
| 564 | dstdata = *blitter_get_addr(blitter.dest.addr & 0xfffff); | |
| 564 | dstdata = *blitter_get_addr(machine, blitter.dest.addr & 0xfffff); | |
| 565 | 565 | cycles_used++; |
| 566 | 566 | } |
| 567 | 567 | |
| r3232 | r3233 | |
| 630 | 630 | The existing destination pixel is used as a lookup |
| 631 | 631 | into the table and the colours is replaced. |
| 632 | 632 | */ |
| 633 | UINT8 dest = *blitter_get_addr(blitter.dest.addr); | |
| 634 | UINT8 newcol = *(blitter_get_addr((blitter.source.addr + dest) & 0xfffff)); | |
| 633 | UINT8 dest = *blitter_get_addr(machine, blitter.dest.addr); | |
| 634 | UINT8 newcol = *(blitter_get_addr(machine, (blitter.source.addr + dest) & 0xfffff)); | |
| 635 | 635 | |
| 636 | *blitter_get_addr(blitter.dest.addr) = newcol; | |
| 636 | *blitter_get_addr(machine, blitter.dest.addr) = newcol; | |
| 637 | 637 | cycles_used += 3; |
| 638 | 638 | } |
| 639 | 639 | else |
| r3232 | r3233 | |
| 652 | 652 | if (blitter.compfunc & CMPFUNC_LOG0) |
| 653 | 653 | final_result |= ~result & ~dstdata; |
| 654 | 654 | |
| 655 | *blitter_get_addr(blitter.dest.addr) = final_result; | |
| 655 | *blitter_get_addr(machine, blitter.dest.addr) = final_result; | |
| 656 | 656 | cycles_used++; |
| 657 | 657 | } |
| 658 | 658 | } |
| r3232 | r3233 | |
| 888 | 888 | |
| 889 | 889 | data &= 0x3f; |
| 890 | 890 | bank[offset] = data; |
| 891 | z80_bank(offset, data); | |
| 891 | z80_bank(machine, offset, data); | |
| 892 | 892 | break; |
| 893 | 893 | } |
| 894 | 894 | |
| r3232 | r3233 | |
| 945 | 945 | blitter.command = data; |
| 946 | 946 | |
| 947 | 947 | if (data & CMD_RUN) |
| 948 | RunBlit(); | |
| 948 | RunBlit(machine); | |
| 949 | 949 | else |
| 950 | 950 | mame_printf_debug("Blitter stopped by IO.\n"); |
| 951 | 951 | |
| r3232 | r3233 | |
| 963 | 963 | } |
| 964 | 964 | } |
| 965 | 965 | |
| 966 | INLINE void z80_bank(int num, int data) | |
| 966 | INLINE void z80_bank(running_machine *machine, int num, int data) | |
| 967 | 967 | { |
| 968 | 968 | if (data < 0x08) |
| 969 | 969 | { |
| r3232 | r3233 | |
| 976 | 976 | |
| 977 | 977 | UINT32 offset = ((bank[0] >> 1) * 0x20000) + offs_table[bank[0] & 0x1][data]; |
| 978 | 978 | |
| 979 | memory_set_bankptr(num, memory_region( | |
| 979 | memory_set_bankptr(num, memory_region(machine, "user1") + offset); | |
| 980 | 980 | } |
| 981 | 981 | else if (data < 0x10) |
| 982 | 982 | { |
| r3232 | r3233 | |
| 991 | 991 | static WRITE8_HANDLER( rombank_w ) |
| 992 | 992 | { |
| 993 | 993 | bank[0] = data; |
| 994 | z80_bank(1, bank[1]); | |
| 995 | z80_bank(2, bank[2]); | |
| 996 | z80_bank(3, bank[3]); | |
| 994 | z80_bank(machine, 1, bank[1]); | |
| 995 | z80_bank(machine, 2, bank[2]); | |
| 996 | z80_bank(machine, 3, bank[3]); | |
| 997 | 997 | } |
| 998 | 998 | |
| 999 | 999 | |
| r3232 | r3233 | |
| 1397 | 1397 | case 0: |
| 1398 | 1398 | { |
| 1399 | 1399 | int changed = mux_outputlatch ^ data; |
| 1400 | static const char *port[] = { "STROBE0", "STROBE1", "STROBE2", "STROBE3", "STROBE4", "STROBE5", "STROBE6", "STROBE7" }; | |
| 1400 | static const char *const port[] = { "STROBE0", "STROBE1", "STROBE2", "STROBE3", "STROBE4", "STROBE5", "STROBE6", "STROBE7" }; | |
| 1401 | 1401 | |
| 1402 | 1402 | mux_outputlatch = data; |
| 1403 | 1403 |
| r3232 | r3233 | |
|---|---|---|
| 212 | 212 | static READ8_HANDLER( block_input_r ) |
| 213 | 213 | { |
| 214 | 214 | static int dir[2]; |
| 215 | static const char *dialnames[] = { "DIAL1", "DIAL2" }; | |
| 216 | static const char *portnames[] = { "IN1", "IN2" }; | |
| 215 | static const char *const dialnames[] = { "DIAL1", "DIAL2" }; | |
| 216 | static const char *const portnames[] = { "IN1", "IN2" }; | |
| 217 | 217 | |
| 218 | 218 | if (dial_selected) |
| 219 | 219 | { |
| r3232 | r3233 | |
| 295 | 295 | |
| 296 | 296 | static READ8_HANDLER( input_r ) |
| 297 | 297 | { |
| 298 | static const char *portnames[] = { "IN0", "IN1", "IN2" }; | |
| 298 | static const char *const portnames[] = { "IN0", "IN1", "IN2" }; | |
| 299 | 299 | |
| 300 | 300 | switch (input_type) |
| 301 | 301 | { |
| r3232 | r3233 | |
| 384 | 384 | AM_RANGE(0xe000, 0xffff) AM_WRITE(SMH_RAM) |
| 385 | 385 | ADDRESS_MAP_END |
| 386 | 386 | |
| 387 | static ADDRESS_MAP_START( | |
| 387 | static ADDRESS_MAP_START( io_ma | |
| 388 | 388 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 389 | AM_RANGE(0x00, 0x02) AM_READ(input_r) /* Super Pang needs a kludge to initialize EEPROM. | |
| 390 | The Mahjong games and Block Block need special input treatment */ | |
| 391 | AM_RANGE(0x03, 0x03) AM_READ(input_port_12_r) /* mgakuen only */ | |
| 392 | AM_RANGE(0x04, 0x04) AM_READ(input_port_13_r) /* mgakuen only */ | |
| 393 | AM_RANGE(0x05, 0x05) AM_READ(pang_port5_r) | |
| 394 | ADDRESS_MAP_END | |
| 395 | ||
| 396 | static ADDRESS_MAP_START( writeport, ADDRESS_SPACE_IO, 8 ) | |
| 397 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 398 | AM_RANGE(0x00, 0x00) AM_WRITE(pang_gfxctrl_w) /* Palette bank, layer enable, coin counters, more */ | |
| 389 | AM_RANGE(0x00, 0x00) AM_WRITE(pang_gfxctrl_w) /* Palette bank, layer enable, coin counters, more */ | |
| 390 | AM_RANGE(0x00, 0x02) AM_READ(input_r) /* Super Pang needs a kludge to initialize EEPROM. | |
| 391 | The Mahjong games and Block Block need special input treatment */ | |
| 399 | 392 | AM_RANGE(0x01, 0x01) AM_WRITE(input_w) |
| 400 | AM_RANGE(0x02, 0x02) AM_WRITE(pang_bankswitch_w) /* Code bank register */ | |
| 401 | AM_RANGE(0x03, 0x03) AM_WRITE(ym2413_data_port_0_w) | |
| 402 | AM_RANGE(0x04, 0x04) AM_WRITE(ym2413_register_port_0_w) | |
| 403 | AM_RANGE(0x05, 0x05) AM_WRITE(okim6295_data_0_w) | |
| 404 | AM_RANGE(0x06, 0x06) AM_WRITE(SMH_NOP) /* watchdog? irq ack? */ | |
| 405 | AM_RANGE(0x07, 0x07) AM_WRITE(pang_video_bank_w) /* Video RAM bank register */ | |
| 393 | AM_RANGE(0x02, 0x02) AM_WRITE(pang_bankswitch_w) /* Code bank register */ | |
| 394 | AM_RANGE(0x03, 0x03) AM_READWRITE(input_port_12_r, ym2413_data_port_0_w) /* mgakuen only */ | |
| 395 | AM_RANGE(0x04, 0x04) AM_READWRITE(input_port_13_r, ym2413_register_port_0_w) /* mgakuen only */ | |
| 396 | AM_RANGE(0x05, 0x05) AM_READWRITE(pang_port5_r, okim6295_data_0_w) | |
| 397 | AM_RANGE(0x06, 0x06) AM_WRITE(SMH_NOP) /* watchdog? irq ack? */ | |
| 398 | AM_RANGE(0x07, 0x07) AM_WRITE(pang_video_bank_w) /* Video RAM bank register */ | |
| 406 | 399 | AM_RANGE(0x08, 0x08) AM_WRITE(eeprom_cs_w) |
| 407 | 400 | AM_RANGE(0x10, 0x10) AM_WRITE(eeprom_clock_w) |
| 408 | 401 | AM_RANGE(0x18, 0x18) AM_WRITE(eeprom_serial_w) |
| 409 | 402 | ADDRESS_MAP_END |
| 410 | 403 | |
| 411 | ||
| 412 | 404 | /* spangbl */ |
| 413 | 405 | |
| 414 | 406 | static ADDRESS_MAP_START( spangb_memmap, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 487 | 479 | extern WRITE8_HANDLER( mstworld_gfxctrl_w ); |
| 488 | 480 | extern WRITE8_HANDLER( mstworld_video_bank_w ); |
| 489 | 481 | |
| 490 | static ADDRESS_MAP_START( mstworld_ | |
| 482 | static ADDRESS_MAP_START( mstworld_io_ma | |
| 491 | 483 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 492 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") /* coins */ | |
| 493 | AM_RANGE(0x01, 0x01) AM_READ_PORT("IN1") /* p1 */ | |
| 494 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN2") /* p2 */ | |
| 495 | AM_RANGE(0x03, 0x03) AM_READ_PORT("DSW1") /* dips? */ | |
| 484 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") AM_WRITE(mstworld_gfxctrl_w) /* Palette bank, layer enable, coin counters, more */ | |
| 485 | AM_RANGE(0x01, 0x01) AM_READ_PORT("IN1") | |
| 486 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN2") AM_WRITE(pang_bankswitch_w) /* Code bank register */ | |
| 487 | AM_RANGE(0x03, 0x03) AM_READ_PORT("DSW1") AM_WRITE(mstworld_sound_w) /* write to sound cpu */ | |
| 496 | 488 | AM_RANGE(0x04, 0x04) AM_READ_PORT("DSW2") /* dips? */ |
| 497 | 489 | AM_RANGE(0x05, 0x05) AM_READ_PORT("DSW0") /* special? */ |
| 498 | 490 | AM_RANGE(0x06, 0x06) AM_READ_PORT("DSW3") /* dips? */ |
| 491 | AM_RANGE(0x06, 0x06) AM_WRITE(SMH_NOP) /* watchdog? irq ack? */ | |
| 492 | AM_RANGE(0x07, 0x07) AM_WRITE(mstworld_video_bank_w) /* Video RAM bank register */ | |
| 499 | 493 | ADDRESS_MAP_END |
| 500 | 494 | |
| 501 | static ADDRESS_MAP_START( mstworld_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 502 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 503 | AM_RANGE(0x00, 0x00) AM_WRITE(mstworld_gfxctrl_w) /* Palette bank, layer enable, coin counters, more */ | |
| 504 | AM_RANGE(0x02, 0x02) AM_WRITE(pang_bankswitch_w) /* Code bank register */ | |
| 505 | AM_RANGE(0x03, 0x03) AM_WRITE(mstworld_sound_w) /* write to sound cpu */ | |
| 506 | AM_RANGE(0x06, 0x06) AM_WRITE(SMH_NOP) /* watchdog? irq ack? */ | |
| 507 | AM_RANGE(0x07, 0x07) AM_WRITE(mstworld_video_bank_w) /* Video RAM bank register */ | |
| 508 | ADDRESS_MAP_END | |
| 509 | ||
| 510 | 495 | /**** End Monsters World ****/ |
| 511 | 496 | |
| 512 | 497 | |
| r3232 | r3233 | |
| 1133 | 1118 | /* basic machine hardware */ |
| 1134 | 1119 | MDRV_CPU_ADD("main", Z80, 6000000) /* ??? */ |
| 1135 | 1120 | MDRV_CPU_PROGRAM_MAP(mgakuen_readmem,mgakuen_writemem) |
| 1136 | MDRV_CPU_IO_MAP( | |
| 1121 | MDRV_CPU_IO_MAP(io_ma | |
| 1137 | 1122 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,2) /* ??? one extra irq seems to be needed for music (see input5_r) */ |
| 1138 | 1123 | |
| 1139 | 1124 | /* video hardware */ |
| r3232 | r3233 | |
| 1167 | 1152 | /* basic machine hardware */ |
| 1168 | 1153 | MDRV_CPU_ADD("main",Z80, 8000000) /* (verified on pcb) */ |
| 1169 | 1154 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1170 | MDRV_CPU_IO_MAP( | |
| 1155 | MDRV_CPU_IO_MAP(io_ma | |
| 1171 | 1156 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,2) /* ??? one extra irq seems to be needed for music (see input5_r) */ |
| 1172 | 1157 | |
| 1173 | 1158 | MDRV_NVRAM_HANDLER(mitchell) |
| r3232 | r3233 | |
| 1266 | 1251 | MDRV_CPU_ADD("main", Z80, 6000000*4) |
| 1267 | 1252 | |
| 1268 | 1253 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1269 | MDRV_CPU_IO_MAP(mstworld_ | |
| 1254 | MDRV_CPU_IO_MAP(mstworld_i | |
| 1270 | 1255 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1271 | 1256 | |
| 1272 | 1257 | MDRV_CPU_ADD("audio", Z80,6000000) /* 6 MHz? */ |
| r3232 | r3233 | |
| 1300 | 1285 | /* basic machine hardware */ |
| 1301 | 1286 | MDRV_CPU_ADD("main", Z80, 8000000) /* Super Pang says 8MHZ ORIGINAL BOARD */ |
| 1302 | 1287 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1303 | MDRV_CPU_IO_MAP( | |
| 1288 | MDRV_CPU_IO_MAP(io_ma | |
| 1304 | 1289 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,2) /* ??? one extra irq seems to be needed for music (see input5_r) */ |
| 1305 | 1290 | |
| 1306 | 1291 | MDRV_NVRAM_HANDLER(mitchell) |
| r3232 | r3233 | |
| 2234 | 2219 | GAME( 1991, blockj, block, pang, block, block, ROT270, "Capcom", "Block Block (Japan 910910)", 0 ) |
| 2235 | 2220 | GAME( 1991, blockjoy, block, pang, blockjoy, block, ROT270, "Capcom", "Block Block (World 911106 Joystick)", 0 ) |
| 2236 | 2221 | GAME( 1991, blockbl, block, pang, block, blockbl, ROT270, "bootleg", "Block Block (bootleg)", 0 ) |
| 2222 |
| r3232 | r3233 | |
|---|---|---|
| 77 | 77 | |
| 78 | 78 | static UINT16 *bitmap0, *bitmap1, *wram; |
| 79 | 79 | static int vbuffer = 0; |
| 80 | static int old_bank; | |
| 80 | 81 | |
| 81 | 82 | static WRITE16_HANDLER( pasha2_misc_w ) |
| 82 | 83 | { |
| r3232 | r3233 | |
| 84 | 85 | { |
| 85 | 86 | if(data & 0x0800) |
| 86 | 87 | { |
| 87 | static int old_bank = -1; | |
| 88 | 88 | int bank = data & 0xf000; |
| 89 | 89 | |
| 90 | 90 | if(bank != old_bank) |
| r3232 | r3233 | |
| 386 | 386 | return 0; |
| 387 | 387 | } |
| 388 | 388 | |
| 389 | static MACHINE_RESET( pasha2 ) | |
| 390 | { | |
| 391 | old_bank = -1; | |
| 392 | vbuffer = 0; | |
| 393 | } | |
| 394 | ||
| 389 | 395 | static MACHINE_DRIVER_START( pasha2 ) |
| 390 | 396 | MDRV_CPU_ADD("main", E116XT, 20000000*4) /* 4x internal multiplier */ |
| 391 | 397 | MDRV_CPU_PROGRAM_MAP(pasha2_map,0) |
| 392 | 398 | MDRV_CPU_IO_MAP(pasha2_io,0) |
| 393 | 399 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 394 | 400 | |
| 401 | MDRV_MACHINE_RESET(pasha2) | |
| 395 | 402 | MDRV_NVRAM_HANDLER(93C46) |
| 396 | 403 | |
| 397 | 404 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 89 | 89 | static READ16_HANDLER( adc_r ) |
| 90 | 90 | { |
| 91 | 91 | static int last_offset; |
| 92 | static const char *adcnames[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 92 | static const char *const adcnames[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 93 | 93 | int result = input_port_read(machine, adcnames[last_offset & 3]); |
| 94 | 94 | |
| 95 | 95 | last_offset = offset; |
| r3232 | r3233 | |
|---|---|---|
| 1 | /* Main Event - SNK 1984 | |
| 2 | Canvas Croquis - SNK 1985 | |
| 1 | /* | |
| 2 | Main Event - SNK 1984 | |
| 3 | Canvas Croquis - SNK 1985 | |
| 3 | 4 | |
| 4 | driver by David Haywood | |
| 5 | Tomasz Slanina | |
| 5 | driver by David Haywood, Tomasz Slanina | |
| 6 | 6 | |
| 7 | Notes: Main Event | |
| 8 | ----------------- | |
| 9 | 7 | |
| 10 | ROM doesn't pass its internal checksum | |
| 8 | Notes: | |
| 9 | ------ | |
| 10 | - canvas doesn't use the tx layer, though the circuitry is presumably still | |
| 11 | present on the pcb. One gfx ROM socket is left empty which causes the tx layer | |
| 12 | to be completely transparent. | |
| 11 | 13 | |
| 12 | Todo: | |
| 13 | - fix controls (now you need to press button1 + direction for punch/block ) and DIPs | |
| 14 | - verify position of status bars | |
| 14 | - neither mainsnk nor canvas pass the ROM test in service mode. This looks like | |
| 15 | a bug (as in madcrash). SNK obviously didn't pay too much attention to details | |
| 16 | in those days. | |
| 17 | Note that in canvas you can't see the error since the tx layer is transparent. | |
| 18 | Load cc_p9.a2 at 0x0000 to see it. | |
| 15 | 19 | |
| 16 | Notes: Canvas Croquis | |
| 17 | --------------------- | |
| 20 | TODO: | |
| 21 | ----- | |
| 22 | - are mainsnk control right? The way the button works is awkward. | |
| 18 | 23 | |
| 19 | GFX banking is wrong? | |
| 20 | Doesn't have the front layer? | |
| 21 | Doesn't have the status bars? | |
| 24 | - several unknown dip switches | |
| 22 | 25 | |
| 26 | - the hardware surely supports sprite shadows as most of the games in snk.c, but | |
| 27 | the feature isn't used by these two games. | |
| 28 | ||
| 29 | - mainsnk doesn't seem to write to the bg/sprite scroll registers? SO I hardcoded | |
| 30 | scroll values for these two games, even if canvas does seem to write to them. | |
| 31 | ||
| 32 | - canvas writes to several unknown addresses on startup. Most of them should be | |
| 33 | the scroll registers while others are unknown. | |
| 34 | ||
| 35 | - the bg tilemap is set to 256x256, however it could well be 512x256 as in the | |
| 36 | other early SNK games in snk.c. | |
| 37 | ||
| 23 | 38 | ----- |
| 24 | 39 | |
| 25 | 40 | Canvas Croquis |
| r3232 | r3233 | |
| 71 | 86 | */ |
| 72 | 87 | |
| 73 | 88 | #include "driver.h" |
| 89 | #include "snk.h" | |
| 74 | 90 | #include "sound/ay8910.h" |
| 75 | #include "sound/snkwave.h" | |
| 76 | 91 | |
| 77 | 92 | extern UINT8 *mainsnk_fgram; |
| 78 | 93 | extern UINT8 *mainsnk_bgram; |
| r3232 | r3233 | |
| 83 | 98 | VIDEO_UPDATE(mainsnk); |
| 84 | 99 | VIDEO_UPDATE(canvas); |
| 85 | 100 | |
| 86 | static int sound_cpu_ready; | |
| 87 | static int sound_command; | |
| 88 | static int sound_fetched; | |
| 101 | static int sound_cpu_busy; | |
| 89 | 102 | |
| 90 | 103 | |
| 91 | 104 | static WRITE8_HANDLER( sound_command_w ) |
| 92 | 105 | { |
| 93 | if( sound_fetched==0 ){ | |
| 94 | logerror("missed sound command: %02x\n", sound_command ); | |
| 95 | } | |
| 96 | ||
| 97 | sound_fetched = 0; | |
| 98 | sound_command = data; | |
| 99 | sound_cpu_ready = 0; | |
| 106 | sound_cpu_busy = 1; | |
| 107 | soundlatch_w(machine, 0, data); | |
| 100 | 108 | cpunum_set_input_line(machine, 1, INPUT_LINE_NMI, PULSE_LINE); |
| 101 | 109 | } |
| 102 | 110 | |
| 103 | 111 | static READ8_HANDLER( sound_command_r ) |
| 104 | 112 | { |
| 105 | sound_fetched = 1; | |
| 106 | return sound_command; | |
| 113 | return soundlatch_r(machine, 0); | |
| 107 | 114 | } |
| 108 | 115 | |
| 109 | 116 | static READ8_HANDLER( sound_ack_r ) |
| 110 | 117 | { |
| 111 | sound_cpu_ | |
| 118 | sound_cpu_bus | |
| 112 | 119 | return 0xff; |
| 113 | 120 | } |
| 114 | 121 | |
| 115 | 122 | static CUSTOM_INPUT( mainsnk_sound_r ) |
| 116 | 123 | { |
| 117 | return ( | |
| 124 | return ( | |
| 118 | 125 | } |
| 119 | 126 | |
| 127 | ||
| 128 | ||
| 120 | 129 | static ADDRESS_MAP_START( main_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| 121 | 130 | AM_RANGE(0x0000, 0xbfff) AM_ROM |
| 122 | AM_RANGE(0xc000, 0xc000) AM_READ_PORT("SYSTEM") | |
| 123 | AM_RANGE(0xc100, 0xc100) AM_READ_PORT("P1") | |
| 124 | AM_RANGE(0xc200, 0xc200) AM_READ_PORT("P2") | |
| 125 | AM_RANGE(0xc300, 0xc300) AM_READ_PORT("BUTTONS") | |
| 126 | AM_RANGE(0xc400, 0xc400) AM_READ_PORT("UNK") | |
| 127 | AM_RANGE(0xc500, 0xc500) AM_READ_PORT("DSW") | |
| 131 | AM_RANGE(0xc000, 0xc000) AM_READ_PORT("IN0") | |
| 132 | AM_RANGE(0xc100, 0xc100) AM_READ_PORT("IN1") | |
| 133 | AM_RANGE(0xc200, 0xc200) AM_READ_PORT("IN2") | |
| 134 | AM_RANGE(0xc300, 0xc300) AM_READ_PORT("IN3") | |
| 135 | AM_RANGE(0xc400, 0xc400) AM_READ_PORT("DSW1") | |
| 136 | AM_RANGE(0xc500, 0xc500) AM_READ_PORT("DSW2") | |
| 128 | 137 | AM_RANGE(0xc600, 0xc600) AM_WRITE(mainsnk_c600_w) |
| 129 | 138 | AM_RANGE(0xc700, 0xc700) AM_WRITE(sound_command_w) |
| 130 | 139 | AM_RANGE(0xd800, 0xdbff) AM_RAM_WRITE(mainsnk_bgram_w) AM_BASE(&mainsnk_bgram) |
| 131 | 140 | AM_RANGE(0xdc00, 0xe7ff) AM_RAM |
| 132 | 141 | AM_RANGE(0xe800, 0xefff) AM_RAM AM_BASE(&spriteram) |
| 133 | AM_RANGE(0xf000, 0xf3ff) AM_RAM_WRITE(mainsnk_fgram_w) AM_BASE(&mainsnk_fgram) | |
| 134 | AM_RANGE(0xf400, 0xf7ff) AM_RAM | |
| 142 | AM_RANGE(0xf000, 0xf7ff) AM_RAM_WRITE(mainsnk_fgram_w) AM_BASE(&mainsnk_fgram) // + work RAM | |
| 135 | 143 | ADDRESS_MAP_END |
| 136 | 144 | |
| 137 | 145 | static ADDRESS_MAP_START( sound_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 141 | 149 | AM_RANGE(0xc000, 0xc000) AM_READ(sound_ack_r) |
| 142 | 150 | AM_RANGE(0xe000, 0xe000) AM_WRITE(ay8910_control_port_0_w) |
| 143 | 151 | AM_RANGE(0xe001, 0xe001) AM_WRITE(ay8910_write_port_0_w) |
| 144 | AM_RANGE(0xe002, 0xe00 | |
| 152 | AM_RANGE(0xe002, 0xe003) AM_WRITENOP // ? always FFFF, snkwave leftover? | |
| 145 | 153 | AM_RANGE(0xe008, 0xe008) AM_WRITE(ay8910_control_port_1_w) |
| 146 | 154 | AM_RANGE(0xe009, 0xe009) AM_WRITE(ay8910_write_port_1_w) |
| 147 | 155 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 151 | 159 | AM_RANGE(0x00, 0x00) AM_READNOP |
| 152 | 160 | ADDRESS_MAP_END |
| 153 | 161 | |
| 162 | ||
| 163 | ||
| 154 | 164 | static INPUT_PORTS_START( mainsnk ) |
| 155 | PORT_START(" | |
| 165 | PORT_START("IN0 | |
| 156 | 166 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) |
| 157 | 167 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN2 ) |
| 158 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_COIN3 ) | |
| 159 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 160 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 168 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 169 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 170 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 161 | 171 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(mainsnk_sound_r, NULL) /* sound CPU status */ |
| 162 | PORT_SERVICE( 0x80, IP_ACTIVE_LOW ) | |
| 172 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 173 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 163 | 174 | |
| 164 | PORT_START("P1") | |
| 165 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) | |
| 166 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) | |
| 167 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) | |
| 175 | PORT_START("IN1") | |
| 176 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) | |
| 177 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) | |
| 178 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) | |
| 168 | 179 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) |
| 180 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 181 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 182 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 183 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 169 | 184 | |
| 170 | PORT_START(" | |
| 185 | PORT_START("IN2") | |
| 171 | 186 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_PLAYER(2) |
| 172 | 187 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_PLAYER(2) |
| 173 | 188 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_PLAYER(2) |
| 174 | 189 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_PLAYER(2) |
| 190 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 191 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 192 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 193 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 175 | 194 | |
| 176 | PORT_START(" | |
| 195 | PORT_START("I | |
| 177 | 196 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_BUTTON1 ) /* ?? */ |
| 197 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 198 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 199 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 200 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_BUTTON1 ) PORT_PLAYER(2) /* ?? */ | |
| 201 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 202 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 203 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 178 | 204 | |
| 179 | PORT_START("DSW") | |
| 180 | PORT_DIPNAME( 0x07, 0x07, DEF_STR( Coinage ) ) | |
| 181 | PORT_DIPSETTING( 0x01, DEF_STR( 3C_1C ) ) /* also 02,04 */ | |
| 205 | PORT_START("DSW1") | |
| 206 | PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:1") | |
| 207 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) | |
| 208 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 209 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:2") | |
| 210 | PORT_DIPSETTING( 0x02, DEF_STR( Off ) ) | |
| 211 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 212 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:3") | |
| 213 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) | |
| 214 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 215 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:4") | |
| 216 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) | |
| 217 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 218 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:5") | |
| 219 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) | |
| 220 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 221 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:6") | |
| 222 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) | |
| 223 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 224 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:7") | |
| 225 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 226 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 227 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:8") | |
| 228 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 229 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 230 | ||
| 231 | PORT_START("DSW2") | |
| 232 | PORT_DIPNAME( 0x07, 0x07, DEF_STR( Coinage ) ) PORT_DIPLOCATION("DSW2:1,2,3") | |
| 233 | // PORT_DIPSETTING( 0x01, DEF_STR( 3C_1C ) ) // duplicate | |
| 234 | // PORT_DIPSETTING( 0x02, DEF_STR( 3C_1C ) ) // duplicate | |
| 235 | PORT_DIPSETTING( 0x04, DEF_STR( 3C_1C ) ) | |
| 182 | 236 | PORT_DIPSETTING( 0x06, DEF_STR( 2C_1C ) ) |
| 183 | 237 | PORT_DIPSETTING( 0x07, DEF_STR( 1C_1C ) ) |
| 184 | 238 | PORT_DIPSETTING( 0x03, DEF_STR( 1C_2C ) ) |
| 185 | 239 | PORT_DIPSETTING( 0x05, DEF_STR( 1C_3C ) ) |
| 186 | 240 | PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) |
| 187 | PORT_DIPNAME( 0x60, 0x60, "Game mode" ) | |
| 188 | PORT_DIPSETTING( 0x60, "Demo Sounds Off" ) | |
| 189 | PORT_DIPSETTING( 0x20, "Demo Sounds On" ) | |
| 190 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 191 | PORT_DIPSETTING( 0x00, "Freeze" ) | |
| 192 | PORT_DIPNAME( 0x08, 0x00, "SW 2-3" ) | |
| 241 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:4") | |
| 193 | 242 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) |
| 194 | 243 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 195 | PORT_DIPNAME( 0x10, 0x0 | |
| 244 | PORT_DIPNAME( 0x10, 0x10 | |
| 196 | 245 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) |
| 197 | 246 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 198 | PORT_DIPNAME( 0x80, 0x00, "SW 2-7" ) | |
| 199 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 200 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 201 | ||
| 202 | PORT_START("UNK") | |
| 247 | PORT_DIPNAME( 0x60, 0x20, "Game mode" ) PORT_DIPLOCATION("DSW2:6,7") | |
| 248 | PORT_DIPSETTING( 0x60, "Demo Sounds Off" ) | |
| 249 | PORT_DIPSETTING( 0x20, "Demo Sounds On" ) | |
| 250 | PORT_DIPSETTING( 0x00, "Freeze" ) | |
| 251 | PORT_DIPSETTING( 0x40, "Endless Game (Cheat)" ) | |
| 252 | PORT_DIPNAME( 0x80, 0x80, "2 Players Game" ) PORT_DIPLOCATION("DSW2:8") | |
| 253 | PORT_DIPSETTING( 0x80, "1 Credit" ) | |
| 254 | PORT_DIPSETTING( 0x00, "2 Credits" ) | |
| 203 | 255 | INPUT_PORTS_END |
| 204 | 256 | |
| 205 | 257 | static INPUT_PORTS_START( canvas ) |
| 206 | PORT_START(" | |
| 258 | PORT_START("IN0 | |
| 207 | 259 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) |
| 208 | 260 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN2 ) |
| 209 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_COIN3 ) | |
| 210 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 211 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 212 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNKNOWN ) /* sound CPU status? or vbl? */ | |
| 213 | PORT_SERVICE( 0x80, IP_ACTIVE_LOW ) | |
| 261 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 262 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 263 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 264 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(mainsnk_sound_r, NULL) /* sound CPU status */ | |
| 265 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 266 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 214 | 267 | |
| 215 | PORT_START(" | |
| 268 | PORT_START("IN1") | |
| 216 | 269 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) |
| 217 | 270 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) |
| 218 | 271 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) |
| 219 | 272 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) |
| 220 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_ | |
| 273 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_ | |
| 221 | 274 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON1 ) |
| 222 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) | |
| 223 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 224 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 225 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) | |
| 226 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 227 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 275 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 276 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 228 | 277 | |
| 229 | PORT_START("P2") | |
| 230 | PORT_DIPNAME( 0x01, 0x01, "2" ) | |
| 231 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) | |
| 232 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 233 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) | |
| 234 | PORT_DIPSETTING( 0x02, DEF_STR( Off ) ) | |
| 235 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 236 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) | |
| 237 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) | |
| 238 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 239 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) | |
| 240 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) | |
| 241 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 242 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) | |
| 243 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) | |
| 244 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 245 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) | |
| 246 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) | |
| 247 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 248 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) | |
| 249 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 250 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 251 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) | |
| 252 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 253 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 278 | PORT_START("IN2") | |
| 279 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP) PORT_COCKTAIL | |
| 280 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_JOYSTICK_DOWN ) PORT_COCKTAIL | |
| 281 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_JOYSTICK_LEFT ) PORT_COCKTAIL | |
| 282 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_COCKTAIL | |
| 283 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 284 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_COCKTAIL | |
| 285 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 286 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 254 | 287 | |
| 255 | PORT_START("BUTTONS") | |
| 256 | PORT_DIPNAME( 0x01, 0x01, "3" ) | |
| 257 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) | |
| 258 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 259 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) | |
| 260 | PORT_DIPSETTING( 0x02, DEF_STR( Off ) ) | |
| 261 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 262 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) | |
| 263 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) | |
| 264 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 265 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) | |
| 266 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) | |
| 267 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 268 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) | |
| 269 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) | |
| 270 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 271 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) | |
| 272 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) | |
| 273 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 274 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) | |
| 275 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 276 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 277 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) | |
| 278 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 279 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 288 | PORT_START("IN3") | |
| 289 | PORT_BIT( 0xff, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 280 | 290 | |
| 281 | PORT_START("DSW") | |
| 282 | PORT_DIPNAME( 0x01, 0x01, "4" ) | |
| 291 | PORT_START("DSW1") | |
| 292 | PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:1") | |
| 283 | 293 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) |
| 284 | 294 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 285 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) | |
| 286 | PORT_DIPSETTING( 0x02, DEF_STR( Off ) ) | |
| 287 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 288 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) | |
| 289 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) | |
| 290 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 291 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) | |
| 292 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) | |
| 293 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 294 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) | |
| 295 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) | |
| 296 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 297 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) | |
| 298 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) | |
| 299 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 300 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) | |
| 295 | PORT_DIPNAME( 0x02, 0x00, DEF_STR( Cabinet ) ) PORT_DIPLOCATION("DSW1:2") | |
| 296 | PORT_DIPSETTING( 0x00, DEF_STR( Upright ) ) | |
| 297 | PORT_DIPSETTING( 0x02, DEF_STR( Cocktail ) ) | |
| 298 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Lives ) ) PORT_DIPLOCATION("DSW1:3") | |
| 299 | PORT_DIPSETTING( 0x04, "3" ) | |
| 300 | PORT_DIPSETTING( 0x00, "5" ) | |
| 301 | PORT_DIPNAME( 0x38, 0x38, DEF_STR( Coinage ) ) PORT_DIPLOCATION("DSW1:4,5,6") | |
| 302 | // PORT_DIPSETTING( 0x08, DEF_STR( 5C_1C ) ) // duplicate | |
| 303 | PORT_DIPSETTING( 0x10, DEF_STR( 5C_1C ) ) | |
| 304 | PORT_DIPSETTING( 0x20, DEF_STR( 3C_1C ) ) | |
| 305 | PORT_DIPSETTING( 0x18, DEF_STR( 2C_1C ) ) | |
| 306 | PORT_DIPSETTING( 0x38, DEF_STR( 1C_1C ) ) | |
| 307 | PORT_DIPSETTING( 0x30, DEF_STR( 1C_2C ) ) | |
| 308 | PORT_DIPSETTING( 0x28, DEF_STR( 1C_3C ) ) | |
| 309 | PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) | |
| 310 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:7") // bonus life? | |
| 301 | 311 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) |
| 302 | 312 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 303 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) | |
| 313 | PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW1:8") // bonus life? | |
| 304 | 314 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 305 | 315 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 306 | 316 | |
| 307 | PORT_START("UNK") | |
| 308 | PORT_DIPNAME( 0x01, 0x01, "5" ) | |
| 317 | PORT_START("DSW2") | |
| 318 | PORT_DIPNAME( 0x01, 0x01, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:1") // bonus life? | |
| 309 | 319 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) |
| 310 | 320 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 311 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) | |
| 321 | PORT_DIPNAME( 0x02, 0x02, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:2") // difficulty? | |
| 312 | 322 | PORT_DIPSETTING( 0x02, DEF_STR( Off ) ) |
| 313 | 323 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 314 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) | |
| 324 | PORT_DIPNAME( 0x04, 0x04, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:3") // difficulty? | |
| 315 | 325 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) |
| 316 | 326 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 317 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Unknown ) ) | |
| 318 | PORT_DIPSETTING( 0x08, DEF_STR( Off ) ) | |
| 319 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 320 | PORT_DIPNAME( 0x10, 0x10, DEF_STR( Unknown ) ) | |
| 321 | PORT_DIPSETTING( 0x10, DEF_STR( Off ) ) | |
| 322 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 323 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Unknown ) ) | |
| 324 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) | |
| 325 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 326 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) | |
| 327 | PORT_DIPNAME( 0x18, 0x10, "Game mode" ) PORT_DIPLOCATION("DSW2:4,5") | |
| 328 | PORT_DIPSETTING( 0x18, "Demo Sounds Off" ) | |
| 329 | PORT_DIPSETTING( 0x10, "Demo Sounds On" ) | |
| 330 | PORT_DIPSETTING( 0x00, "Freeze" ) | |
| 331 | PORT_DIPSETTING( 0x08, "Infinite Lives (Cheat)" ) | |
| 332 | PORT_DIPNAME( 0x20, 0x00, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION("DSW2:6") | |
| 333 | PORT_DIPSETTING( 0x00, DEF_STR( Off ) ) | |
| 334 | PORT_DIPSETTING( 0x20, DEF_STR( On ) ) | |
| 335 | PORT_DIPNAME( 0x40, 0x40, DEF_STR( Unknown ) ) PORT_DIPLOCATION("DSW2:7") | |
| 327 | 336 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) |
| 328 | 337 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 329 | PORT_DIPNAME( 0x80, 0x | |
| 338 | PORT_DIPNAME( 0x80, 0x | |
| 330 | 339 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 331 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 340 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) // needs to be on otherwise pictures in later levels are wrong | |
| 332 | 341 | INPUT_PORTS_END |
| 333 | 342 | |
| 334 | 343 | |
| r3232 | r3233 | |
| 358 | 367 | |
| 359 | 368 | |
| 360 | 369 | static GFXDECODE_START( mainsnk ) |
| 361 | GFXDECODE_ENTRY( "gfx1", 0x0, tile_layout, 0, 8 ) | |
| 362 | GFXDECODE_ENTRY( "gfx2", 0x0, sprite_layout, 0, 16 ) | |
| 370 | GFXDECODE_ENTRY( "gfx1", 0, tile_layout, 0x100, 0x080>>4 ) | |
| 371 | GFXDECODE_ENTRY( "gfx2", 0, sprite_layout, 0x000, 0x080>>3 ) | |
| 363 | 372 | GFXDECODE_END |
| 364 | 373 | |
| 374 | ||
| 375 | ||
| 365 | 376 | static MACHINE_DRIVER_START( mainsnk ) |
| 366 | 377 | MDRV_CPU_ADD("main", Z80, 3360000) |
| 367 | 378 | MDRV_CPU_PROGRAM_MAP(main_map,0) |
| r3232 | r3233 | |
| 372 | 383 | MDRV_CPU_IO_MAP(sound_portmap,0) |
| 373 | 384 | MDRV_CPU_PERIODIC_INT(irq0_line_hold, 244) |
| 374 | 385 | |
| 375 | MDRV_GFXDECODE(mainsnk) | |
| 386 | /* video hardware */ | |
| 387 | MDRV_VIDEO_ATTRIBUTES(VIDEO_HAS_SHADOWS) | |
| 376 | 388 | |
| 377 | 389 | MDRV_SCREEN_ADD("main", RASTER) |
| 378 | MDRV_SCREEN_REFRESH_RATE(60.606060) | |
| 379 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500) /* not accurate */) | |
| 390 | MDRV_SCREEN_REFRESH_RATE(60) | |
| 380 | 391 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 381 | MDRV_SCREEN_SIZE(34*8, 32*8) | |
| 382 | MDRV_SCREEN_VISIBLE_AREA(0*8, 34*8-1, 0*8, 27*8-1) | |
| 392 | MDRV_SCREEN_SIZE(36*8, 28*8) | |
| 393 | MDRV_SCREEN_VISIBLE_AREA(0*8, 36*8-1, 1*8, 28*8-1) | |
| 383 | 394 | |
| 384 | MDRV_PALETTE_LENGTH((16+2)*16) | |
| 395 | MDRV_GFXDECODE(mainsnk) | |
| 396 | MDRV_PALETTE_LENGTH(0x400) | |
| 385 | 397 | |
| 398 | MDRV_PALETTE_INIT(tnk3) | |
| 386 | 399 | MDRV_VIDEO_START(mainsnk) |
| 387 | 400 | MDRV_VIDEO_UPDATE(mainsnk) |
| 388 | 401 | |
| r3232 | r3233 | |
| 393 | 406 | |
| 394 | 407 | MDRV_SOUND_ADD("ay2", AY8910, 2000000) |
| 395 | 408 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.35) |
| 396 | ||
| 397 | MDRV_SOUND_ADD("wave", SNKWAVE, 8000000) | |
| 398 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.08) | |
| 399 | 409 | MACHINE_DRIVER_END |
| 400 | 410 | |
| 401 | static MACHINE_DRIVER_START( canvas ) | |
| 402 | 411 | |
| 403 | /* basic machine hardware */ | |
| 404 | MDRV_IMPORT_FROM(mainsnk) | |
| 405 | ||
| 406 | MDRV_SCREEN_MODIFY("main") | |
| 407 | MDRV_SCREEN_VISIBLE_AREA(2*8, 32*8-1, 0*8, 27*8-1) | |
| 408 | ||
| 409 | MDRV_VIDEO_UPDATE(canvas) | |
| 410 | MACHINE_DRIVER_END | |
| 411 | ||
| 412 | ||
| 413 | 412 | ROM_START( mainsnk) |
| 414 | 413 | ROM_REGION( 0x10000, "main", 0 ) |
| 415 | ROM_LOAD( "snk.p01", 0x000000, 0x002000, CRC(00db1ca2) SHA1(efe83488cf88adc185e6024b8f6ad5f8ef7f4cfd) ) | |
| 416 | ROM_LOAD( "snk.p02", 0x002000, 0x002000, CRC(df5c86b5) SHA1(e9c854524e3d8231c874314cdff321e66ec7f0c4) ) | |
| 417 | ROM_LOAD( "snk.p03", 0x004000, 0x002000, CRC(5c2b7bca) SHA1(e02c72fcd029999b730abd91f07866418cfe6216) ) | |
| 418 | ROM_LOAD( "snk.p04", 0x006000, 0x002000, CRC(68b4b2a1) SHA1(8f3abc826df93f0748151624066e956b9670bc9d) ) | |
| 419 | ROM_LOAD( "snk.p05", 0x008000, 0x002000, CRC(580a29b4) SHA1(4a96af92d65f86aca7f3a70032b5e4dc29048483) ) | |
| 420 | ROM_LOAD( "snk.p06", 0x00a000, 0x002000, CRC(5f8a60a2) SHA1(88a051e13d6b3bbd3606a4c4cc0395da07e0f109) ) | |
| 414 | ROM_LOAD( "snk.p01", 0x0000, 0x2000, CRC(00db1ca2) SHA1(efe83488cf88adc185e6024b8f6ad5f8ef7f4cfd) ) | |
| 415 | ROM_LOAD( "snk.p02", 0x2000, 0x2000, CRC(df5c86b5) SHA1(e9c854524e3d8231c874314cdff321e66ec7f0c4) ) | |
| 416 | ROM_LOAD( "snk.p03", 0x4000, 0x2000, CRC(5c2b7bca) SHA1(e02c72fcd029999b730abd91f07866418cfe6216) ) | |
| 417 | ROM_LOAD( "snk.p04", 0x6000, 0x2000, CRC(68b4b2a1) SHA1(8f3abc826df93f0748151624066e956b9670bc9d) ) | |
| 418 | ROM_LOAD( "snk.p05", 0x8000, 0x2000, CRC(580a29b4) SHA1(4a96af92d65f86aca7f3a70032b5e4dc29048483) ) | |
| 419 | ROM_LOAD( "snk.p06", 0xa000, 0x2000, CRC(5f8a60a2) SHA1(88a051e13d6b3bbd3606a4c4cc0395da07e0f109) ) | |
| 421 | 420 | |
| 422 | 421 | ROM_REGION( 0x10000, "audio", 0 ) |
| 423 | ROM_LOAD( "snk.p07", 0x0000, 0x4000, CRC(4208391e) SHA1(d110ca4ff9d21fe7813f04ec43c2c23471c6517f) ) | |
| 422 | ROM_LOAD( "snk.p07", 0x0000, 0x4000, CRC(4208391e) SHA1(d110ca4ff9d21fe7813f04ec43c2c23471c6517f) ) | |
| 424 | 423 | |
| 425 | 424 | ROM_REGION( 0x08000, "gfx1", 0 ) |
| 426 | ROM_LOAD( "snk.p12", 0x000000, 0x002000, CRC(ecf87eb7) SHA1(83b8d19070d5930b306a0309ebba05b04c2abebf) ) | |
| 427 | ROM_LOAD( "snk.p11", 0x002000, 0x002000, CRC(3f6bc5ba) SHA1(02e49f58f5d94117113b59037fa49b8897d05b4b) ) | |
| 428 | ROM_LOAD( "snk.p10", 0x004000, 0x002000, CRC(b5147a96) SHA1(72641fadabd16f2de4f4cf6ff3ef07233de5ddfd) ) | |
| 429 | ROM_LOAD( "snk.p09", 0x006000, 0x002000, CRC(0ebcf837) SHA1(7b93cdffd3b8d768b98bb01956114e4ff012d029) ) | |
| 425 | ROM_LOAD( "snk.p12", 0x0000, 0x2000, CRC(ecf87eb7) SHA1(83b8d19070d5930b306a0309ebba05b04c2abebf) ) | |
| 426 | ROM_LOAD( "snk.p11", 0x2000, 0x2000, CRC(3f6bc5ba) SHA1(02e49f58f5d94117113b59037fa49b8897d05b4b) ) | |
| 427 | ROM_LOAD( "snk.p10", 0x4000, 0x2000, CRC(b5147a96) SHA1(72641fadabd16f2de4f4cf6ff3ef07233de5ddfd) ) | |
| 428 | ROM_LOAD( "snk.p09", 0x6000, 0x2000, CRC(0ebcf837) SHA1(7b93cdffd3b8d768b98bb01956114e4ff012d029) ) | |
| 430 | 429 | |
| 431 | 430 | ROM_REGION( 0x12000, "gfx2", 0 ) |
| 432 | ROM_LOAD( "snk.p13", 0x000000, 0x002000, CRC(2eb624a4) SHA1(157d7beb6ff0baa9276e388774a85996dc03821d) ) | |
| 433 | ROM_LOAD( "snk.p16", 0x002000, 0x002000, CRC(dc502869) SHA1(024c868e8cd74c52f4787a19b9ad292b7a9dcc1c) ) | |
| 434 | ROM_LOAD( "snk.p19", 0x004000, 0x002000, CRC(58d566a1) SHA1(1451b223ddb7c975b770f28af6c41775daaf95c1) ) | |
| 435 | ROM_LOAD( "snk.p14", 0x006000, 0x002000, CRC(bb927d82) SHA1(ac7ae1850cf22b73e31c92b6f598fb057470a570) ) | |
| 436 | ROM_LOAD( "snk.p17", 0x008000, 0x002000, CRC(66f60c32) SHA1(7a08d0a2c1804cdaad702a23ff33128d0b6d8084) ) | |
| 437 | ROM_LOAD( "snk.p20", 0x00a000, 0x002000, CRC(d12c6333) SHA1(bed1a0aedaa8f6fe9c33f49b5da00ab1c9045ddd) ) | |
| 438 | ROM_LOAD( "snk.p15", 0x00c000, 0x002000, CRC(d242486d) SHA1(0c24a3fdcb604b6231b75069c99009d68023bb8f) ) | |
| 439 | ROM_LOAD( "snk.p18", 0x00e000, 0x002000, CRC(838b12a3) SHA1(a3444f9b2aeef70caa93e5f642cb6c3b75e88ea4) ) | |
| 440 | ROM_LOAD( "snk.p21", 0x010000, 0x002000, CRC(8961a51e) SHA1(4f9d8358bc76118c4fab631ae73a02ab5aa0c036) ) | |
| 431 | ROM_LOAD( "snk.p13", 0x00000, 0x2000, CRC(2eb624a4) SHA1(157d7beb6ff0baa9276e388774a85996dc03821d) ) | |
| 432 | ROM_LOAD( "snk.p16", 0x02000, 0x2000, CRC(dc502869) SHA1(024c868e8cd74c52f4787a19b9ad292b7a9dcc1c) ) | |
| 433 | ROM_LOAD( "snk.p19", 0x04000, 0x2000, CRC(58d566a1) SHA1(1451b223ddb7c975b770f28af6c41775daaf95c1) ) | |
| 434 | ROM_LOAD( "snk.p14", 0x06000, 0x2000, CRC(bb927d82) SHA1(ac7ae1850cf22b73e31c92b6f598fb057470a570) ) | |
| 435 | ROM_LOAD( "snk.p17", 0x08000, 0x2000, CRC(66f60c32) SHA1(7a08d0a2c1804cdaad702a23ff33128d0b6d8084) ) | |
| 436 | ROM_LOAD( "snk.p20", 0x0a000, 0x2000, CRC(d12c6333) SHA1(bed1a0aedaa8f6fe9c33f49b5da00ab1c9045ddd) ) | |
| 437 | ROM_LOAD( "snk.p15", 0x0c000, 0x2000, CRC(d242486d) SHA1(0c24a3fdcb604b6231b75069c99009d68023bb8f) ) | |
| 438 | ROM_LOAD( "snk.p18", 0x0e000, 0x2000, CRC(838b12a3) SHA1(a3444f9b2aeef70caa93e5f642cb6c3b75e88ea4) ) | |
| 439 | ROM_LOAD( "snk.p21", 0x10000, 0x2000, CRC(8961a51e) SHA1(4f9d8358bc76118c4fab631ae73a02ab5aa0c036) ) | |
| 441 | 440 | |
| 442 | ROM_REGION( 0x1800, "proms", 0 ) | |
| 443 | ROM_LOAD( "main3.bin", 0x000000, 0x000800, CRC(78b29dde) SHA1(c2f93cde6fd8bc175e9e0d38af41b7710d7f1c82) ) | |
| 444 | ROM_LOAD( "main2.bin", 0x000800, 0x000800, CRC(7c314c93) SHA1(c6bd2a0eaf617448ef65dcbadced313b0d69ab88) ) | |
| 445 | ROM_LOAD( "main1.bin", 0x001000, 0x000800, CRC(deb895c4) SHA1(f1281dcb3471d9627565706ff09ba72f09dc62a4) ) | |
| 441 | ROM_REGION( 0x1000, "proms", 0 ) // overdumps? 2nd half is empty | |
| 442 | ROM_LOAD( "main3.bin", 0x0000, 0x0800, CRC(78b29dde) SHA1(c2f93cde6fd8bc175e9e0d38af41b7710d7f1c82) ) | |
| 443 | ROM_LOAD( "main2.bin", 0x0400, 0x0800, CRC(7c314c93) SHA1(c6bd2a0eaf617448ef65dcbadced313b0d69ab88) ) | |
| 444 | ROM_LOAD( "main1.bin", 0x0800, 0x0800, CRC(deb895c4) SHA1(f1281dcb3471d9627565706ff09ba72f09dc62a4) ) | |
| 446 | 445 | ROM_END |
| 447 | 446 | |
| 448 | 447 | ROM_START( canvas ) |
| 449 | 448 | ROM_REGION( 0x10000, "main", 0 ) |
| 450 | ROM_LOAD( "cc_p1.a2", 0x000000, 0x002000, CRC(fa7109e1) SHA1(23e31e14af2171ee2fd7290194805b95b0f7b35c) ) | |
| 451 | ROM_LOAD( "cc_p2.a3", 0x002000, 0x002000, CRC(8b8beb34) SHA1(c678ed7ec302eaac3594950f10f0a170353345e5) ) | |
| 452 | ROM_LOAD( "cc_p3.a4", 0x004000, 0x002000, CRC(ea342f87) SHA1(087e1260ba51bf47bf19942b59d21d067515989d) ) | |
| 453 | ROM_LOAD( "cc_p4.a5", 0x006000, 0x002000, CRC(9cf35d98) SHA1(08de7863f1a540b69487c87eb0a493ceeacffa1b) ) | |
| 454 | ROM_LOAD( "cc_p5.a7", 0x008000, 0x002000, CRC(c5ef1eda) SHA1(31cf3e7fe52718bebffdac9b3666454b0956a6d9) ) | |
| 455 | ROM_LOAD( "cc_p6.a8", 0x00a000, 0x002000, CRC(7b1dd7fc) SHA1(1287ab261885d5e9ba957024d7a00c7a0d31235b) ) | |
| 449 | ROM_LOAD( "cc_p1.a2", 0x0000, 0x2000, CRC(fa7109e1) SHA1(23e31e14af2171ee2fd7290194805b95b0f7b35c) ) | |
| 450 | ROM_LOAD( "cc_p2.a3", 0x2000, 0x2000, CRC(8b8beb34) SHA1(c678ed7ec302eaac3594950f10f0a170353345e5) ) | |
| 451 | ROM_LOAD( "cc_p3.a4", 0x4000, 0x2000, CRC(ea342f87) SHA1(087e1260ba51bf47bf19942b59d21d067515989d) ) | |
| 452 | ROM_LOAD( "cc_p4.a5", 0x6000, 0x2000, CRC(9cf35d98) SHA1(08de7863f1a540b69487c87eb0a493ceeacffa1b) ) | |
| 453 | ROM_LOAD( "cc_p5.a7", 0x8000, 0x2000, CRC(c5ef1eda) SHA1(31cf3e7fe52718bebffdac9b3666454b0956a6d9) ) | |
| 454 | ROM_LOAD( "cc_p6.a8", 0xa000, 0x2000, CRC(7b1dd7fc) SHA1(1287ab261885d5e9ba957024d7a00c7a0d31235b) ) | |
| 456 | 455 | |
| 457 | 456 | ROM_REGION( 0x10000, "audio", 0 ) |
| 458 | ROM_LOAD( "cc_p7.h2", 0x0000, 0x4000, CRC(029b5ea0) SHA1(88f84b4dd01656ded8d983396ded404c9d8186f1) ) | |
| 459 | ROM_LOAD( "cc_p8.f2", 0x4000, 0x2000, CRC(0f0368ce) SHA1(a02f066ea024285a931b85709822a50a4099e0b0) ) | |
| 457 | ROM_LOAD( "cc_p7.h2", 0x0000, 0x4000, CRC(029b5ea0) SHA1(88f84b4dd01656ded8d983396ded404c9d8186f1) ) | |
| 458 | ROM_LOAD( "cc_p8.f2", 0x4000, 0x2000, CRC(0f0368ce) SHA1(a02f066ea024285a931b85709822a50a4099e0b0) ) | |
| 460 | 459 | |
| 461 | 460 | ROM_REGION( 0x10000, "gfx1", 0 ) |
| 462 | ROM_LOAD( "cc_p9.a2", 0x006000, 0x002000, CRC(b58c5f24) SHA1(7026b3d4f8060fd6607eb6d356d6b61cc9cb75c3) ) // ok | |
| 463 | ROM_CONTINUE( 0xe000,0x2000) // ok | |
| 464 | ROM_LOAD( "cc_p10.b2", 0x004000, 0x002000, CRC(3c0a4eeb) SHA1(53742a5bef16e71bebefb0e43a175341f5bf0aa6) ) | |
| 465 | ROM_CONTINUE( 0xc000,0x2000) | |
| 466 | ROM_LOAD( "cc_p11.c2", 0x008000, 0x004000, CRC(4c8c2156) SHA1(7f1d9a1e1c6cab91f24c7fc75d0c7ec2702137af) ) | |
| 461 | ROM_FILL( 0x0000, 0x4000, 0xff ) // empty, causes tx layer to be fully transparent | |
| 462 | ROM_LOAD( "cc_p11.c2", 0x4000, 0x4000, CRC(4c8c2156) SHA1(7f1d9a1e1c6cab91f24c7fc75d0c7ec2702137af) ) // banks = 18&58 | |
| 463 | ROM_LOAD( "cc_p10.b2", 0x8000, 0x4000, CRC(3c0a4eeb) SHA1(53742a5bef16e71bebefb0e43a175341f5bf0aa6) ) // banks = 28&68 | |
| 464 | ROM_LOAD( "cc_p9.a2", 0xc000, 0x4000, CRC(b58c5f24) SHA1(7026b3d4f8060fd6607eb6d356d6b61cc9cb75c3) ) // banks = 30&70 | |
| 467 | 465 | |
| 468 | 466 | ROM_REGION( 0x6000, "gfx2", 0 ) |
| 469 | ROM_LOAD( "cc_p12.j8", 0x000000, 0x002000, CRC(9003a979) SHA1(f63959a9dc9ee67622865e783d2e501c640a4bed) ) | |
| 470 | ROM_LOAD( "cc_p13.j5", 0x002000, 0x002000, CRC(a52cd549) SHA1(1902b8c107c5156113068ced74349ac576ac047c) ) | |
| 471 | ROM_LOAD( "cc_p14.j2", 0x004000, 0x002000, CRC(edc6a1e8) SHA1(8c948a5f057e13bb9ed9738b66c702f45586fe59) ) | |
| 467 | ROM_LOAD( "cc_p12.j8", 0x0000, 0x2000, CRC(9003a979) SHA1(f63959a9dc9ee67622865e783d2e501c640a4bed) ) | |
| 468 | ROM_LOAD( "cc_p13.j5", 0x2000, 0x2000, CRC(a52cd549) SHA1(1902b8c107c5156113068ced74349ac576ac047c) ) | |
| 469 | ROM_LOAD( "cc_p14.j2", 0x4000, 0x2000, CRC(edc6a1e8) SHA1(8c948a5f057e13bb9ed9738b66c702f45586fe59) ) | |
| 472 | 470 | |
| 473 | ROM_REGION( 0x1800, "proms", 0 ) | |
| 474 | ROM_LOAD( "cc_bprom3.j8", 0x000000, 0x000400, CRC(21f72498) SHA1(a586c869cb4633fec0df92b5646ece78f99b6f2a) ) | |
| 475 | ROM_LOAD( "cc_bprom2.j9", 0x000800, 0x000400, CRC(19efe7df) SHA1(7e49af8b8b01fb929b87d6285da32fbe4c58606d) ) | |
| 476 | ROM_LOAD( "cc_bprom1.j10", 0x001000, 0x000400, CRC(fbbbf911) SHA1(86394a7f67bc4f89f72b9607ca3733ab3d690289) ) | |
| 471 | ROM_REGION( 0x0c00, "proms", 0 ) | |
| 472 | ROM_LOAD( "cc_bprom3.j8", 0x0000, 0x0400, CRC(21f72498) SHA1(a586c869cb4633fec0df92b5646ece78f99b6f2a) ) | |
| 473 | ROM_LOAD( "cc_bprom2.j9", 0x0400, 0x0400, CRC(19efe7df) SHA1(7e49af8b8b01fb929b87d6285da32fbe4c58606d) ) | |
| 474 | ROM_LOAD( "cc_bprom1.j10", 0x0800, 0x0400, CRC(fbbbf911) SHA1(86394a7f67bc4f89f72b9607ca3733ab3d690289) ) | |
| 477 | 475 | ROM_END |
| 478 | 476 | |
| 479 | 477 | |
| 480 | 478 | GAME( 1984, mainsnk, 0, mainsnk, mainsnk, 0, ROT0, "SNK", "Main Event (1984)", 0) |
| 481 | GAME( 1985, canvas, 0, | |
| 479 | GAME( 1985, canvas, 0, main |
| r3232 | r3233 | |
|---|---|---|
| 128 | 128 | |
| 129 | 129 | static UINT8 read_port_and_t0(running_machine *machine, int port) |
| 130 | 130 | { |
| 131 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 131 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 132 | 132 | |
| 133 | 133 | UINT8 val = input_port_read(machine, portnames[port]); |
| 134 | 134 | if (attotime_compare(timer_get_time(), timeout_time) > 0) |
| r3232 | r3233 | |
|---|---|---|
| 194 | 194 | AM_RANGE(0x8000, 0x87ff) AM_WRITE(SMH_RAM) |
| 195 | 195 | ADDRESS_MAP_END |
| 196 | 196 | |
| 197 | static ADDRESS_MAP_START( sound_ | |
| 197 | static ADDRESS_MAP_START( sound_io_ma | |
| 198 | 198 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 199 | AM_RANGE(0x02, 0x02) AM_READ(ym3812_status_port_0_r) | |
| 200 | AM_RANGE(0x04, 0x04) AM_READ(soundlatch_r) | |
| 201 | ADDRESS_MAP_END | |
| 202 | ||
| 203 | static ADDRESS_MAP_START( sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 204 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 205 | AM_RANGE(0x02, 0x02) AM_WRITE(ym3812_control_port_0_w) | |
| 199 | AM_RANGE(0x02, 0x02) AM_READWRITE(ym3812_status_port_0_r, ym3812_control_port_0_w) | |
| 206 | 200 | AM_RANGE(0x03, 0x03) AM_WRITE(ym3812_write_port_0_w) |
| 207 | AM_RANGE(0x04, 0x04) AM_WRITE(soundlatch_w) /* goes back to the main CPU, checked during boot */ | |
| 201 | AM_RANGE(0x04, 0x04) AM_READWRITE(soundlatch_r, soundlatch_w) /* goes back to the main CPU, checked during boot */ | |
| 208 | 202 | ADDRESS_MAP_END |
| 209 | 203 | |
| 210 | 204 | /* Winter Bobble - bootleg GFX chip */ |
| r3232 | r3233 | |
| 270 | 264 | AM_RANGE(0xe010, 0xe010) AM_WRITE(okim6295_data_0_w) |
| 271 | 265 | ADDRESS_MAP_END |
| 272 | 266 | |
| 273 | static ADDRESS_MAP_START( honeydol_sound_ | |
| 267 | static ADDRESS_MAP_START( honeydol_sound_io_ma | |
| 274 | 268 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 275 | AM_RANGE(0x02, 0x02) AM_READ(ym3812_status_port_0_r) // not connected? | |
| 276 | AM_RANGE(0x04, 0x04) AM_READ(soundlatch_r) | |
| 269 | AM_RANGE(0x02, 0x02) AM_READWRITE(ym3812_status_port_0_r, ym3812_control_port_0_w) // not connected? | |
| 270 | AM_RANGE(0x03, 0x03) AM_WRITE(ym3812_write_port_0_w) // not connected? | |
| 271 | AM_RANGE(0x04, 0x04) AM_READWRITE(soundlatch_r, soundlatch_w) /* goes back to the main CPU, checked during boot */ | |
| 277 | 272 | ADDRESS_MAP_END |
| 278 | 273 | |
| 279 | static ADDRESS_MAP_START( honeydol_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 280 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 281 | AM_RANGE(0x02, 0x02) AM_WRITE(ym3812_control_port_0_w) // not connected? | |
| 282 | AM_RANGE(0x03, 0x03) AM_WRITE(ym3812_write_port_0_w) // not connected? | |
| 283 | AM_RANGE(0x04, 0x04) AM_WRITE(soundlatch_w) /* goes back to the main CPU, checked during boot */ | |
| 284 | ADDRESS_MAP_END | |
| 285 | ||
| 286 | 274 | /* Twin Adventure */ |
| 287 | 275 | |
| 288 | 276 | static WRITE16_HANDLER( twinadv_68000_sound_w ) |
| r3232 | r3233 | |
| 340 | 328 | okim6295_set_bank_base(0, bank * 0x40000); |
| 341 | 329 | } |
| 342 | 330 | |
| 343 | static ADDRESS_MAP_START( twinadv_sound_ | |
| 331 | static ADDRESS_MAP_START( twinadv_sound_io_ma | |
| 344 | 332 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 345 | AM_RANGE(0x02, 0x02) AM_READ(soundlatch_r) | |
| 346 | AM_RANGE(0x06, 0x06) AM_READ(okim6295_status_0_r) | |
| 347 | ADDRESS_MAP_END | |
| 348 | ||
| 349 | static ADDRESS_MAP_START( twinadv_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 350 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 351 | AM_RANGE(0x02, 0x02) AM_WRITE(soundlatch_w) // back to 68k? | |
| 333 | AM_RANGE(0x02, 0x02) AM_READWRITE(soundlatch_r, soundlatch_w) // back to 68k? | |
| 352 | 334 | AM_RANGE(0x04, 0x04) AM_WRITE(twinadv_oki_bank_w) // oki bank? |
| 353 | AM_RANGE(0x06, 0x06) AM_WRITE(okim6295_data_0_w) | |
| 335 | AM_RANGE(0x06, 0x06) AM_READWRITE(okim6295_status_0_r, okim6295_data_0_w) | |
| 354 | 336 | ADDRESS_MAP_END |
| 355 | 337 | |
| 356 | 338 | |
| r3232 | r3233 | |
| 1559 | 1541 | |
| 1560 | 1542 | MDRV_CPU_ADD("sound", Z80, 6000000) /* 6 MHz - confirmed */ |
| 1561 | 1543 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 1562 | MDRV_CPU_IO_MAP(sound_ | |
| 1544 | MDRV_CPU_IO_MAP(sound_i | |
| 1563 | 1545 | |
| 1564 | 1546 | /* video hardware */ |
| 1565 | 1547 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 1655 | 1637 | |
| 1656 | 1638 | MDRV_CPU_ADD("sound", Z80, 4000000) |
| 1657 | 1639 | MDRV_CPU_PROGRAM_MAP(honeydol_sound_readmem,honeydol_sound_writemem) |
| 1658 | MDRV_CPU_IO_MAP(honeydol_sound_ | |
| 1640 | MDRV_CPU_IO_MAP(honeydol_sound_i | |
| 1659 | 1641 | |
| 1660 | 1642 | /* video hardware */ |
| 1661 | 1643 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 1694 | 1676 | |
| 1695 | 1677 | MDRV_CPU_ADD("sound", Z80, 4000000) |
| 1696 | 1678 | MDRV_CPU_PROGRAM_MAP(twinadv_sound_readmem,twinadv_sound_writemem) |
| 1697 | MDRV_CPU_IO_MAP(twinadv_sound_ | |
| 1679 | MDRV_CPU_IO_MAP(twinadv_sound_ | |
| 1698 | 1680 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1699 | 1681 | |
| 1700 | 1682 | /* video hardware */ |
| r3232 | r3233 | |
| 2781 | 2763 | GAME( 2002, 4in1boot, 0, _4in1, 4in1boot, 4in1boot, ROT0, "K1 Soft", "Puzzle King (includes bootleg of Snow Bros.)" , 0) |
| 2782 | 2764 | GAME( 2002, snowbro3, snowbros, snowbro3, snowbroj, snowbro3, ROT0, "Syrmex (bootleg/hack)", "Snow Brothers 3 - Magical Adventure", GAME_IMPERFECT_SOUND ) // its basically snowbros code?... |
| 2783 | 2765 | GAME( 1993, finalttr, 0, finalttr, finalttr, 0, ROT0, "Jeil Computer System", "Final Tetris", 0 ) |
| 2766 | ||
| 2767 |
| r3232 | r3233 | |
|---|---|---|
| 793 | 793 | |
| 794 | 794 | static WRITE8_HANDLER( analog_select_w ) |
| 795 | 795 | { |
| 796 | static const char *analog_port[] = { "AN0", "AN1", "AN2" }; | |
| 796 | static const char *const analog_port[] = { "AN0", "AN1", "AN2" }; | |
| 797 | 797 | |
| 798 | 798 | if (offset <= 2) |
| 799 | 799 | analog_data = input_port_read(machine, analog_port[offset]); |
| r3232 | r3233 | |
|---|---|---|
| 501 | 501 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 502 | 502 | |
| 503 | 503 | |
| 504 | MDRV_SOUND_ADD(" | |
| 504 | MDRV_SOUND_ADD("okisfx | |
| 505 | 505 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) |
| 506 | 506 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 0.6) |
| 507 | 507 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 0.6) |
| 508 | 508 | |
| 509 | MDRV_SOUND_ADD(" | |
| 509 | MDRV_SOUND_ADD("okimusic | |
| 510 | 510 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) |
| 511 | 511 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 0.2) |
| 512 | 512 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 0.2) |
| r3232 | r3233 | |
| 539 | 539 | MDRV_CPU_MODIFY("main") |
| 540 | 540 | MDRV_CPU_PROGRAM_MAP(mitchell156_map,0) |
| 541 | 541 | |
| 542 | MDRV_SOUND_REPLACE(" | |
| 542 | MDRV_SOUND_REPLACE("okimusic | |
| 543 | 543 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) |
| 544 | 544 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 0.2) |
| 545 | 545 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 0.2) |
| r3232 | r3233 | |
| 548 | 548 | |
| 549 | 549 | static DRIVER_INIT(simpl156) |
| 550 | 550 | { |
| 551 | UINT8 *rom = memory_region(machine, "OKIM6295_MUSIC"); | |
| 552 | int length = memory_region_length(machine, "OKIM6295_MUSIC"); | |
| 551 | UINT8 *rom = memory_region(machine, "okimusic"); | |
| 552 | int length = memory_region_length(machine, "okimusic"); | |
| 553 | 553 | UINT8 *buf1 = malloc_or_die(length); |
| 554 | 554 | |
| 555 | 555 | UINT32 x; |
| r3232 | r3233 | |
| 623 | 623 | ROM_LOAD16_BYTE( "mbn01", 0x000001, 0x080000, CRC(a3a37353) SHA1(c4509c8268afb647c20e71b42ae8ebd2bdf075e6) ) /* 03.u11 */ |
| 624 | 624 | ROM_LOAD16_BYTE( "mbn02", 0x000000, 0x080000, CRC(aa2230c5) SHA1(43b7ac5c69cde1840a5255a8897e1c5d5f89fd7b) ) /* 04.u12 */ |
| 625 | 625 | |
| 626 | ROM_REGION( 0x80000, " | |
| 626 | ROM_REGION( 0x80000, "okisfx | |
| 627 | 627 | ROM_LOAD( "mbn04", 0x00000, 0x40000, CRC(dcbd4771) SHA1(2a1ab6b0fc372333c7eb17aab077fe1ca5ba1dea) ) /* 07.u46 */ |
| 628 | 628 | |
| 629 | ROM_REGION( 0x200000, " | |
| 629 | ROM_REGION( 0x200000, "okimusic | |
| 630 | 630 | ROM_LOAD( "mbn03", 0x00000, 0x200000, CRC(70b71a2a) SHA1(45851b0692de73016fc9b913316001af4690534c) ) /* 06.u45 */ |
| 631 | 631 | ROM_END |
| 632 | 632 | |
| r3232 | r3233 | |
| 659 | 659 | ROM_LOAD16_BYTE( "mbn01", 0x000001, 0x080000, CRC(a3a37353) SHA1(c4509c8268afb647c20e71b42ae8ebd2bdf075e6) ) |
| 660 | 660 | ROM_LOAD16_BYTE( "mbn02", 0x000000, 0x080000, CRC(aa2230c5) SHA1(43b7ac5c69cde1840a5255a8897e1c5d5f89fd7b) ) |
| 661 | 661 | |
| 662 | ROM_REGION( 0x80000, " | |
| 662 | ROM_REGION( 0x80000, "okisfx | |
| 663 | 663 | ROM_LOAD( "mbn04", 0x00000, 0x40000, CRC(dcbd4771) SHA1(2a1ab6b0fc372333c7eb17aab077fe1ca5ba1dea) ) |
| 664 | 664 | |
| 665 | ROM_REGION( 0x200000, " | |
| 665 | ROM_REGION( 0x200000, "okimusic | |
| 666 | 666 | ROM_LOAD( "mbn03", 0x00000, 0x200000, CRC(70b71a2a) SHA1(45851b0692de73016fc9b913316001af4690534c) ) |
| 667 | 667 | ROM_END |
| 668 | 668 | |
| r3232 | r3233 | |
| 705 | 705 | ROM_LOAD32_BYTE( "u5", 0x000001, 0x080000, CRC(1b6f01ea) SHA1(753fc670707432e317d035b09b0bad0762fea731) ) |
| 706 | 706 | ROM_LOAD32_BYTE( "u6", 0x000003, 0x080000, CRC(531a56f2) SHA1(89602bb873a3b110bffc216f921ba228e53380f9) ) |
| 707 | 707 | |
| 708 | ROM_REGION( 0x80000, " | |
| 708 | ROM_REGION( 0x80000, "okisfx | |
| 709 | 709 | ROM_LOAD( "mcc-04", 0x00000, 0x40000, CRC(86ee6ade) SHA1(56ad3f432c7f430f19fcba7c89940c63da165906) ) |
| 710 | 710 | |
| 711 | ROM_REGION( 0x200000, " | |
| 711 | ROM_REGION( 0x200000, "okimusic | |
| 712 | 712 | ROM_LOAD( "mcc-03", 0x00000, 0x100000, CRC(da2ebba0) SHA1(96d31dea4c7226ee1d386b286919fa334388c7a1) ) |
| 713 | 713 | ROM_END |
| 714 | 714 | |
| r3232 | r3233 | |
| 747 | 747 | ROM_LOAD16_BYTE( "mcc-01.a13", 0x000001, 0x100000, CRC(13d88745) SHA1(0ce4ec1481f31be860ee80322de6e32f9a566229) ) |
| 748 | 748 | ROM_LOAD16_BYTE( "mcc-02.a14", 0x000000, 0x100000, CRC(d0f97126) SHA1(3848a6f00d0e57aaf383298c4d111eb63a88b073) ) |
| 749 | 749 | |
| 750 | ROM_REGION( 0x80000, " | |
| 750 | ROM_REGION( 0x80000, "okisfx | |
| 751 | 751 | ROM_LOAD( "mcc-04", 0x00000, 0x40000, CRC(86ee6ade) SHA1(56ad3f432c7f430f19fcba7c89940c63da165906) ) |
| 752 | 752 | |
| 753 | ROM_REGION( 0x200000, " | |
| 753 | ROM_REGION( 0x200000, "okimusic | |
| 754 | 754 | ROM_LOAD( "mcc-03", 0x00000, 0x100000, CRC(da2ebba0) SHA1(96d31dea4c7226ee1d386b286919fa334388c7a1) ) |
| 755 | 755 | |
| 756 | 756 | ROM_REGION( 0x80, "user1", 0 ) /* eeprom */ |
| r3232 | r3233 | |
| 768 | 768 | ROM_LOAD16_BYTE( "mcc-01.a13", 0x000001, 0x100000, CRC(13d88745) SHA1(0ce4ec1481f31be860ee80322de6e32f9a566229) ) |
| 769 | 769 | ROM_LOAD16_BYTE( "mcc-02.a14", 0x000000, 0x100000, CRC(d0f97126) SHA1(3848a6f00d0e57aaf383298c4d111eb63a88b073) ) |
| 770 | 770 | |
| 771 | ROM_REGION( 0x80000, " | |
| 771 | ROM_REGION( 0x80000, "okisfx | |
| 772 | 772 | ROM_LOAD( "mcc-04", 0x00000, 0x40000, CRC(86ee6ade) SHA1(56ad3f432c7f430f19fcba7c89940c63da165906) ) |
| 773 | 773 | |
| 774 | ROM_REGION( 0x200000, " | |
| 774 | ROM_REGION( 0x200000, "okimusic | |
| 775 | 775 | ROM_LOAD( "mcc-03", 0x00000, 0x100000, CRC(da2ebba0) SHA1(96d31dea4c7226ee1d386b286919fa334388c7a1) ) |
| 776 | 776 | |
| 777 | 777 | ROM_REGION( 0x80, "user1", 0 ) /* eeprom */ |
| r3232 | r3233 | |
| 834 | 834 | ROM_LOAD16_BYTE( "mbr-01.14a", 0x000001, 0x100000, CRC(46c90215) SHA1(152acdeea34ec1db3f761066a0c1ff6e43e47f9d) ) |
| 835 | 835 | ROM_LOAD16_BYTE( "mbr-03.14h", 0x000000, 0x100000, CRC(c448a68a) SHA1(4b607dfee269abdfeb710b74b73ef87dc2b30e8c) ) |
| 836 | 836 | |
| 837 | ROM_REGION( 0x80000, " | |
| 837 | ROM_REGION( 0x80000, "okisfx | |
| 838 | 838 | ROM_LOAD( "nd01-0.13h", 0x00000, 0x40000, CRC(635a100a) SHA1(f6ec70890892e7557097ccd519de37247bb8c98d) ) |
| 839 | 839 | |
| 840 | ROM_REGION( 0x200000, " | |
| 840 | ROM_REGION( 0x200000, "okimusic | |
| 841 | 841 | ROM_LOAD( "mbr-02.12f", 0x00000, 0x100000, CRC(4f67d333) SHA1(608f921bfa6b7020c0ce72e5229b3f1489208b23) ) // 00, 01, 04, 05 |
| 842 | 842 | ROM_END |
| 843 | 843 | |
| r3232 | r3233 | |
| 917 | 917 | ROM_LOAD16_BYTE( "mcb-01.13a", 0x400001, 0x200000, CRC(06f40a57) SHA1(896f1d373e911dcff7223bf21756ad35b28b4c5d) ) |
| 918 | 918 | ROM_LOAD16_BYTE( "mcb-03.14d", 0x400000, 0x200000, CRC(0aef73af) SHA1(76cf13f53da5202da80820f98660edee1eef7f1a) ) |
| 919 | 919 | |
| 920 | ROM_REGION( 0x80000, " | |
| 920 | ROM_REGION( 0x80000, "okisfx | |
| 921 | 921 | ROM_LOAD( "pz_01-0.13h", 0x00000, 0x40000, CRC(8925bce2) SHA1(0ff2d5db7a24a2af30bd753eba274572c32cc2e7) ) |
| 922 | 922 | |
| 923 | ROM_REGION( 0x200000, " | |
| 923 | ROM_REGION( 0x200000, "okimusic | |
| 924 | 924 | ROM_LOAD( "mcb-04.12f", 0x00000, 0x200000, CRC(e23d3590) SHA1(dc8418edc525f56e84f26e9334d5576000b14e5f) ) |
| 925 | 925 | ROM_END |
| 926 | 926 | |
| r3232 | r3233 | |
| 940 | 940 | ROM_LOAD16_BYTE( "mcb-01.13a", 0x400001, 0x200000, CRC(06f40a57) SHA1(896f1d373e911dcff7223bf21756ad35b28b4c5d) ) |
| 941 | 941 | ROM_LOAD16_BYTE( "mcb-03.14d", 0x400000, 0x200000, CRC(0aef73af) SHA1(76cf13f53da5202da80820f98660edee1eef7f1a) ) |
| 942 | 942 | |
| 943 | ROM_REGION( 0x80000, " | |
| 943 | ROM_REGION( 0x80000, "okisfx | |
| 944 | 944 | ROM_LOAD( "rd_01-0.13h", 0x00000, 0x40000, CRC(70fd18c6) SHA1(368cd8e10c5f5a13eb3813974a7e6b46a4fa6b6c) ) |
| 945 | 945 | |
| 946 | ROM_REGION( 0x200000, " | |
| 946 | ROM_REGION( 0x200000, "okimusic | |
| 947 | 947 | ROM_LOAD( "mcb-04.12f", 0x00000, 0x200000, CRC(e23d3590) SHA1(dc8418edc525f56e84f26e9334d5576000b14e5f) ) |
| 948 | 948 | ROM_END |
| 949 | 949 | |
| r3232 | r3233 | |
| 1002 | 1002 | ROM_LOAD16_BYTE( "mcf-01.13a", 0x400001, 0x200000, CRC(83881e25) SHA1(ae82cf0f704e6efea94c6c1d276d4e3e5b3ebe43) ) |
| 1003 | 1003 | ROM_LOAD16_BYTE( "mcf-03.14d", 0x400000, 0x200000, CRC(faf1d51d) SHA1(675dbbfe15b8010d54b2b3af26d42cdd753c2ce2) ) |
| 1004 | 1004 | |
| 1005 | ROM_REGION( 0x80000, " | |
| 1005 | ROM_REGION( 0x80000, "okisfx | |
| 1006 | 1006 | ROM_LOAD( "sa01-0.13h", 0x00000, 0x40000, CRC(cea8368e) SHA1(1fcc641381fdc29bd50d3a4b23e67647f79e505a)) |
| 1007 | 1007 | |
| 1008 | ROM_REGION( 0x200000, " | |
| 1008 | ROM_REGION( 0x200000, "okimusic | |
| 1009 | 1009 | ROM_LOAD( "mcf-05.12f", 0x00000, 0x200000, CRC(f007d376) SHA1(4ba20e5dabeacc3278b7f30c4462864cbe8f6984) ) |
| 1010 | 1010 | ROM_END |
| 1011 | 1011 | |
| r3232 | r3233 | |
| 1027 | 1027 | ROM_LOAD16_BYTE( "mcf-01.13a", 0x400001, 0x200000, CRC(83881e25) SHA1(ae82cf0f704e6efea94c6c1d276d4e3e5b3ebe43) ) |
| 1028 | 1028 | ROM_LOAD16_BYTE( "mcf-03.14d", 0x400000, 0x200000, CRC(faf1d51d) SHA1(675dbbfe15b8010d54b2b3af26d42cdd753c2ce2) ) |
| 1029 | 1029 | |
| 1030 | ROM_REGION( 0x80000, " | |
| 1030 | ROM_REGION( 0x80000, "okisfx | |
| 1031 | 1031 | ROM_LOAD( "sa01-0.13h", 0x00000, 0x40000, CRC(cea8368e) SHA1(1fcc641381fdc29bd50d3a4b23e67647f79e505a)) |
| 1032 | 1032 | |
| 1033 | ROM_REGION( 0x200000, " | |
| 1033 | ROM_REGION( 0x200000, "okimusic | |
| 1034 | 1034 | ROM_LOAD( "mcf-05.12f", 0x00000, 0x200000, CRC(f007d376) SHA1(4ba20e5dabeacc3278b7f30c4462864cbe8f6984) ) |
| 1035 | 1035 | ROM_END |
| 1036 | 1036 |
| r3232 | r3233 | |
|---|---|---|
| 326 | 326 | // IRQ |
| 327 | 327 | cpunum_set_input_line(machine, 0, 0, ASSERT_LINE); |
| 328 | 328 | timer_set(ATTOTIME_IN_USEC(50), NULL, 0, irq_stop); |
| 329 | ||
| 330 | laserdisc_vsync(laserdisc); | |
| 331 | 329 | } |
| 332 | 330 | |
| 333 | 331 | |
| r3232 | r3233 | |
| 352 | 350 | |
| 353 | 351 | MDRV_MACHINE_START(lgp) |
| 354 | 352 | |
| 355 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 353 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 356 | 354 | MDRV_LASERDISC_OVERLAY(lgp, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 357 | 355 | |
| 358 | 356 | /* video hardware */ |
| r3232 | r3233 | |
| 366 | 364 | /* sound hardware */ |
| 367 | 365 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 368 | 366 | |
| 369 | MDRV_SOUND_ADD("l | |
| 367 | MDRV_SOUND_ADD("l | |
| 370 | 368 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 371 | 369 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 372 | 370 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 107 | 107 | |
| 108 | 108 | static READ8_HANDLER( cliff_port_r ) |
| 109 | 109 | { |
| 110 | static const char *banknames[] = { "BANK0", "BANK1", "BANK2", "BANK3", "BANK4", "BANK5", "BANK6" }; | |
| 110 | static const char *const banknames[] = { "BANK0", "BANK1", "BANK2", "BANK3", "BANK4", "BANK5", "BANK6" }; | |
| 111 | 111 | |
| 112 | 112 | if ( port_bank < 7 ) |
| 113 | 113 | { |
| r3232 | r3233 | |
| 172 | 172 | |
| 173 | 173 | static INTERRUPT_GEN( cliff_vsync ) |
| 174 | 174 | { |
| 175 | /* clock the laserdisc and video chip every 60Hz */ | |
| 176 | laserdisc_vsync(laserdisc); | |
| 175 | /* clock the video chip every 60Hz */ | |
| 177 | 176 | TMS9928A_interrupt(machine); |
| 178 | 177 | } |
| 179 | 178 | |
| r3232 | r3233 | |
| 691 | 690 | |
| 692 | 691 | MDRV_NVRAM_HANDLER(generic_0fill) |
| 693 | 692 | |
| 694 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210) | |
| 693 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210, "main", "ldsound") | |
| 695 | 694 | MDRV_LASERDISC_OVERLAY(tms9928a, 15+32*8+15, 27+24*8+24, BITMAP_FORMAT_INDEXED16) |
| 696 | 695 | MDRV_LASERDISC_OVERLAY_CLIP(15-12, 15+32*8+12-1, 27-9, 27+24*8+9-1) |
| 697 | 696 | |
| r3232 | r3233 | |
| 705 | 704 | /* sound hardware */ |
| 706 | 705 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 707 | 706 | |
| 708 | MDRV_SOUND_ADD("l | |
| 707 | MDRV_SOUND_ADD("l | |
| 709 | 708 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 710 | 709 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 711 | 710 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 922 | 922 | |
| 923 | 923 | /***************************************************************************/ |
| 924 | 924 | |
| 925 | static void zerotrgt_rearrange_gfx(int romsize, int romarea) | |
| 925 | static void zerotrgt_rearrange_gfx(running_machine *machine, int romsize, int romarea) | |
| 926 | 926 | { |
| 927 | UINT8 *src = memory_region(Machine, "gfx4"); | |
| 928 | UINT8 *dst = memory_region(Machine, "gfx3"); | |
| 927 | UINT8 *src = memory_region(machine, "gfx4"); | |
| 928 | UINT8 *dst = memory_region(machine, "gfx3"); | |
| 929 | 929 | int rm; |
| 930 | 930 | int cnt1; |
| 931 | 931 | |
| r3232 | r3233 | |
| 952 | 952 | RAM[0xc2f1]=0x43; |
| 953 | 953 | RAM[0xc2f2]=0x43; |
| 954 | 954 | |
| 955 | zerotrgt_rearrange_gfx(0x02000, 0x10000); | |
| 955 | zerotrgt_rearrange_gfx(machine, 0x02000, 0x10000); | |
| 956 | 956 | |
| 957 | 957 | } |
| 958 | 958 | #endif |
| r3232 | r3233 | |
| 963 | 963 | for (i=0; i<ARRAY_LENGTH(newdata); i++) |
| 964 | 964 | newdata[i] = -1; |
| 965 | 965 | |
| 966 | zerotrgt_rearrange_gfx(0x02000, 0x10000); | |
| 966 | zerotrgt_rearrange_gfx(machine, 0x02000, 0x10000); | |
| 967 | 967 | } |
| 968 | 968 | |
| 969 | 969 |
| r3232 | r3233 | |
|---|---|---|
| 133 | 133 | /* alternate CPU's RAM space while the CPU is running. If the CPU is not */ |
| 134 | 134 | /* running (i.e., the /SRES line is low), it needs to look like RAM to pass */ |
| 135 | 135 | /* the self-tests */ |
| 136 | static const char *comnames[] = { "COM0", "COM1", "COM2", "COM3", "COM4", "COM5" }; | |
| 136 | static const char *const comnames[] = { "COM0", "COM1", "COM2", "COM3", "COM4", "COM5" }; | |
| 137 | 137 | |
| 138 | 138 | /* if the CPU reset line is being held down, just return RAM */ |
| 139 | 139 | if (custom_cpu_reset) |
| r3232 | r3233 | |
|---|---|---|
| 290 | 290 | |
| 291 | 291 | static READ8_HANDLER( leta_r ) |
| 292 | 292 | { |
| 293 | static const char *letanames[] = { "LETA0", "LETA1", "LETA2", "LETA3" }; | |
| 293 | static const char *const letanames[] = { "LETA0", "LETA1", "LETA2", "LETA3" }; | |
| 294 | 294 | |
| 295 | 295 | return input_port_read(machine, letanames[offset]); |
| 296 | 296 | } |
| r3232 | r3233 | |
|---|---|---|
| 17 | 17 | static TIMER_CALLBACK( dragrace_frame_callback ) |
| 18 | 18 | { |
| 19 | 19 | int i; |
| 20 | static const char *portnames[] = { "P1", "P2" }; | |
| 20 | static const char *const portnames[] = { "P1", "P2" }; | |
| 21 | 21 | |
| 22 | 22 | for (i = 0; i < 2; i++) |
| 23 | 23 | { |
| r3232 | r3233 | |
| 118 | 118 | static READ8_HANDLER( dragrace_input_r ) |
| 119 | 119 | { |
| 120 | 120 | int val = input_port_read(machine, "IN2"); |
| 121 | static const char *portnames[] = { "IN0", "IN1" }; | |
| 121 | static const char *const portnames[] = { "IN0", "IN1" }; | |
| 122 | 122 | |
| 123 | 123 | UINT8 maskA = 1 << (offset % 8); |
| 124 | 124 | UINT8 maskB = 1 << (offset / 8); |
| r3232 | r3233 | |
| 148 | 148 | { |
| 149 | 149 | int bitA[2]; |
| 150 | 150 | int bitB[2]; |
| 151 | static const char *dialnames[] = { "DIAL1", "DIAL2" }; | |
| 151 | static const char *const dialnames[] = { "DIAL1", "DIAL2" }; | |
| 152 | 152 | |
| 153 | 153 | int i; |
| 154 | 154 |
| r3232 | r3233 | |
|---|---|---|
| 503 | 503 | static READ32_HANDLER( parallel_port_r ) |
| 504 | 504 | { |
| 505 | 505 | UINT32 r = 0; |
| 506 | // | |
| 506 | // | |
| 507 | 507 | |
| 508 | 508 | if (ACCESSING_BITS_8_15) |
| 509 | 509 | { |
| r3232 | r3233 | |
| 535 | 535 | |
| 536 | 536 | static WRITE32_HANDLER( parallel_port_w ) |
| 537 | 537 | { |
| 538 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3", "IN4", "IN5", "IN6", "IN7", "IN8" }; // but parallel_pointer takes values 0 -> 23 | |
| 538 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3", "IN4", "IN5", "IN6", "IN7", "IN8" }; // but parallel_pointer takes values 0 -> 23 | |
| 539 | 539 | |
| 540 | 540 | COMBINE_DATA( &parport ); |
| 541 | 541 |
| r3232 | r3233 | |
|---|---|---|
| 295 | 295 | MDRV_CPU_PROGRAM_MAP(orbit_map, 0) |
| 296 | 296 | MDRV_CPU_VBLANK_INT("main", orbit_interrupt) |
| 297 | 297 | |
| 298 | MDRV_TIMER_ADD_SCANLINE("32 | |
| 298 | MDRV_TIMER_ADD_SCANLINE("32v", nmi_32v, "main", 0, 32) | |
| 299 | 299 | |
| 300 | 300 | MDRV_MACHINE_RESET(orbit) |
| 301 | 301 |
| r3232 | r3233 | |
|---|---|---|
| 1808 | 1808 | static MACHINE_DRIVER_START( system1 ) |
| 1809 | 1809 | |
| 1810 | 1810 | /* basic machine hardware */ |
| 1811 | MDRV_CPU_ADD("main", Z80, 4 | |
| 1811 | MDRV_CPU_ADD("main", Z80, XTAL_4MHz | |
| 1812 | 1812 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1813 | 1813 | MDRV_CPU_IO_MAP(readport,writeport) |
| 1814 | 1814 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1815 | 1815 | |
| 1816 | MDRV_CPU_ADD("sound", Z80, 4 | |
| 1816 | MDRV_CPU_ADD("sound", Z80, XTAL_4MHz | |
| 1817 | 1817 | MDRV_CPU_PROGRAM_MAP(sound_map,0) |
| 1818 | 1818 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,4) /* NMIs are caused by the main CPU */ |
| 1819 | 1819 | |
| r3232 | r3233 | |
| 3243 | 3243 | Choplifter (Bootleg) |
| 3244 | 3244 | Year: 1985 |
| 3245 | 3245 | System 2 |
| 3246 | ||
| 3247 | ||
| 3248 | ||
| 3249 | Small Daughterboard marked 600A | |
| 3250 | ||
| 3251 | |--------------------------------------------------------| | |
| 3252 | | | | |
| 3253 | A | 74ls244 74ls244 74ls669 74ls669 74ls669 74ls669 | | |
| 3254 | | | | |
| 3255 | B | 74ls240 74ls240 74ls283 74ls283 74ls283 74ls283 | | |
| 3256 | | | | |
| 3257 | C | 74ls10 74ls86 74ls157 74ls157 74ls157 74ls157 | | |
| 3258 | | | | |
| 3259 | D | 74ls157 74ls157 74ls157 74ls139 74ls74 | | |
| 3260 | | | | |
| 3261 | E | pal16r4 pal16l8 74ls161 74ls161 74ls109 | | |
| 3262 | | | | |
| 3263 | F | 74ls27 74ls08 74ls04 74ls74 74ls00 | | |
| 3264 | | 600A | | |
| 3265 | |--------------------------------------------------------| | |
| 3266 | 1 2 3 4 5 6 | |
| 3267 | ||
| 3268 | ||
| 3269 | Small Daughterboard marked 600B | |
| 3270 | ||
| 3271 | |--------------------------------------| | |
| 3272 | | 600B | | |
| 3273 | A | 74ls74 74ls174 pal20r4 | | |
| 3274 | | | | |
| 3275 | B | pal16l8 pal16l8 74ls374 74ls374 | | |
| 3276 | | | | |
| 3277 | C | 74ls283 pal16l8 pal16l8 74ls32 | | |
| 3278 | | | | |
| 3279 | D | 74ls283 74ls283 74ls85 74ls283 | | |
| 3280 | | | | |
| 3281 | E | 74ls04 74ls00 74ls00 74ls32 | | |
| 3282 | | | | |
| 3283 | |--------------------------------------| | |
| 3284 | 1 2 3 4 | |
| 3246 | 3285 | */ |
| 3247 | 3286 | |
| 3248 | 3287 | ROM_START( chplftbl ) |
| r3232 | r3233 | |
| 3271 | 3310 | ROM_LOAD( "pr7117.8", 0x0200, 0x0100, CRC(4124307e) SHA1(cee28d891e6ce732c43a61acb5beeafd2200cf37) ) /* palette blue component */ |
| 3272 | 3311 | ROM_LOAD( "pr5317.28", 0x0300, 0x0100, CRC(648350b8) SHA1(c7986aa9127ef5b50b845434cb4e81dff9861cd2) ) /* timing? (not used) */ |
| 3273 | 3312 | |
| 3274 | ROM_REGION( 0x0800, "plds", ROMREGION_DISPOSE ) | |
| 3313 | ROM_REGION( 0x0003, "plds_main", ROMREGION_DISPOSE ) | |
| 3314 | ROM_LOAD( "pal16r4.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16R4 located at IC13. */ | |
| 3315 | ROM_LOAD( "pal16r4.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16R4 located at IC14. */ | |
| 3316 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at IC62. */ | |
| 3317 | ||
| 3318 | ROM_REGION( 0x0002, "plds_600a", ROMREGION_DISPOSE ) | |
| 3319 | ROM_LOAD( "pal16r4.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16R4 located at E1. */ | |
| 3320 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at E2. */ | |
| 3321 | ||
| 3322 | ROM_REGION( 0x0005, "plds_600b", ROMREGION_DISPOSE ) | |
| 3323 | ROM_LOAD( "pal20r4.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL20R4 located at A4. */ | |
| 3324 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at B1. */ | |
| 3325 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at B2. */ | |
| 3326 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at C2. */ | |
| 3327 | ROM_LOAD( "pal16l8.bin", 0x00000, 0x0001, NO_DUMP ) /* PAL16L8 located at C3. */ | |
| 3328 | ||
| 3329 | ROM_REGION( 0x0410, "plds_unk", ROMREGION_DISPOSE ) | |
| 3330 | /* Do any of these dumps match what's on the physical boards? */ | |
| 3275 | 3331 | ROM_LOAD( "pal16r4a.ic9", 0x0000, 0x0104, CRC(dd223015) SHA1(8d70f91b118e8653dda1efee3eaea287ae63809f) ) |
| 3276 | ROM_LOAD( "pal16r4a.ic10", 0x0200, 0x0104, CRC(2c9229b4) SHA1(9755013afcf89f99d7a399c7e223e027761cf89a) ) | |
| 3277 | ROM_LOAD( "pal16r4a-chopbl1.bin", 0x0400, 0x0104, CRC(e1628a8e) SHA1(6b6df079cfadec71b38a53f107475f0dda428b00) ) | |
| 3278 | ROM_LOAD( "pal16l8a-chopbl2.bin", 0x0600, 0x0104, CRC(afa7425d) SHA1(09d8607b69ecfc0b12c8610751d489500b63c7d6) ) | |
| 3332 | ROM_LOAD( "pal16r4a.ic10", 0x0104, 0x0104, CRC(2c9229b4) SHA1(9755013afcf89f99d7a399c7e223e027761cf89a) ) | |
| 3333 | ROM_LOAD( "pal16r4a-chopbl1.bin", 0x0208, 0x0104, CRC(e1628a8e) SHA1(6b6df079cfadec71b38a53f107475f0dda428b00) ) | |
| 3334 | ROM_LOAD( "pal16l8a-chopbl2.bin", 0x030c, 0x0104, CRC(afa7425d) SHA1(09d8607b69ecfc0b12c8610751d489500b63c7d6) ) | |
| 3279 | 3335 | ROM_END |
| 3280 | 3336 | |
| 3281 | 3337 | ROM_START( 4dwarrio ) |
| r3232 | r3233 | |
|---|---|---|
| 20 | 20 | static int video_enable = 0; |
| 21 | 21 | static int irq_enable = 0; |
| 22 | 22 | static int bg1_bank = 0, bg2_bank = 0; |
| 23 | static int old_bank; | |
| 23 | 24 | |
| 24 | 25 | static TILE_GET_INFO( get_bg1_tile_info ) |
| 25 | 26 | { |
| r3232 | r3233 | |
| 110 | 111 | |
| 111 | 112 | static WRITE8_HANDLER( misc_w ) |
| 112 | 113 | { |
| 113 | static int old_bank = -1; | |
| 114 | 114 | int new_bank = data & 0xf; |
| 115 | 115 | |
| 116 | 116 | if(old_bank != new_bank) |
| r3232 | r3233 | |
| 351 | 351 | cpunum_set_input_line(machine, 0, 0, HOLD_LINE); |
| 352 | 352 | } |
| 353 | 353 | |
| 354 | static MACHINE_RESET( cultures ) | |
| 355 | { | |
| 356 | old_bank = -1; | |
| 357 | } | |
| 354 | 358 | |
| 359 | ||
| 355 | 360 | static MACHINE_DRIVER_START( cultures ) |
| 356 | 361 | |
| 357 | 362 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 360 | 365 | MDRV_CPU_IO_MAP(cultures_io_map,0) |
| 361 | 366 | MDRV_CPU_VBLANK_INT("main", cultures_interrupt) |
| 362 | 367 | |
| 368 | MDRV_MACHINE_RESET( cultures ) | |
| 369 | ||
| 363 | 370 | /* video hardware */ |
| 364 | 371 | MDRV_SCREEN_ADD("main", RASTER) |
| 365 | 372 | MDRV_SCREEN_REFRESH_RATE(60) |
| r3232 | r3233 | |
|---|---|---|
| 647 | 647 | static READ8_HANDLER( mux_input_r ) |
| 648 | 648 | { |
| 649 | 649 | int result = 0xFF,t1,t2; |
| 650 | static const char *port[] = { "STROBE0", "STROBE1", "STROBE2", "STROBE3", "STROBE4", "STROBE5", "STROBE6", "STROBE7", "STROBE8", "STROBE9", "STROBE10", "STROBE11" }; | |
| 650 | static const char *const port[] = { "STROBE0", "STROBE1", "STROBE2", "STROBE3", "STROBE4", "STROBE5", "STROBE6", "STROBE7", "STROBE8", "STROBE9", "STROBE10", "STROBE11" }; | |
| 651 | 651 | |
| 652 | 652 | if (offset < 8) |
| 653 | 653 | { |
| r3232 | r3233 | |
| 2228 | 2228 | MDRV_NVRAM_HANDLER(bfm_sc2) |
| 2229 | 2229 | MDRV_DEFAULT_LAYOUT(layout_bfm_sc2) |
| 2230 | 2230 | |
| 2231 | MDRV_SCREEN_ADD(" | |
| 2231 | MDRV_SCREEN_ADD("adder", RASTER) | |
| 2232 | 2232 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 2233 | 2233 | MDRV_SCREEN_SIZE( 400, 280) |
| 2234 | 2234 | MDRV_SCREEN_VISIBLE_AREA( 0, 400-1, 0, 280-1) |
| r3232 | r3233 | |
| 2244 | 2244 | |
| 2245 | 2245 | MDRV_CPU_ADD("adder2", M6809, MASTER_CLOCK/4 ) // adder2 board 6809 CPU at 2 Mhz |
| 2246 | 2246 | MDRV_CPU_PROGRAM_MAP(adder2_memmap,0) // setup adder2 board memorymap |
| 2247 | MDRV_CPU_VBLANK_INT(" | |
| 2247 | MDRV_CPU_VBLANK_INT("adder", adder2_vbl) // board has a VBL IRQ | |
| 2248 | 2248 | |
| 2249 | 2249 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 2250 | 2250 | MDRV_SOUND_ADD("upd", UPD7759, UPD7759_STANDARD_CLOCK) |
| r3232 | r3233 | |
|---|---|---|
| 211 | 211 | static int scrolly=0; |
| 212 | 212 | |
| 213 | 213 | static UINT8 reg_a002=0; |
| 214 | static int bank | |
| 214 | static int bank | |
| 215 | 215 | |
| 216 | 216 | static TILE_GET_INFO( get_gfx0b_tile_info ) |
| 217 | 217 | { |
| r3232 | r3233 | |
| 853 | 853 | memory_set_bankptr(1,&ROM[0x10000+UNBANKED_SIZE]); |
| 854 | 854 | |
| 855 | 855 | memory_install_read8_handler(machine, 1, ADDRESS_SPACE_PROGRAM, 0x7000, 0x700f, 0, 0, prot_read_700x); |
| 856 | bank = -1; | |
| 856 | 857 | } |
| 857 | 858 | |
| 858 | 859 | GAME( 1992, witch, 0, witch, witch, witch, ROT0, "Sega / Vic Tokai", "Witch", 0 ) |
| r3232 | r3233 | |
|---|---|---|
| 610 | 610 | |
| 611 | 611 | static READ8_HANDLER( yarunara_input_r ) |
| 612 | 612 | { |
| 613 | static const char *keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 614 | static const char *keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 613 | static const char *const keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 614 | static const char *const keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 615 | 615 | |
| 616 | 616 | switch (offset) |
| 617 | 617 | { |
| r3232 | r3233 | |
| 966 | 966 | static READ8_HANDLER( mjelctrn_dsw_r ) |
| 967 | 967 | { |
| 968 | 968 | int dsw = (keyb & 0xc0) >> 6; |
| 969 | static const char *dswnames[] = { "DSW2", "DSW1", "DSW3", "DSW4" }; | |
| 969 | static const char *const dswnames[] = { "DSW2", "DSW1", "DSW3", "DSW4" }; | |
| 970 | 970 | |
| 971 | 971 | return input_port_read(machine, dswnames[dsw]); |
| 972 | 972 | } |
| r3232 | r3233 | |
| 1069 | 1069 | |
| 1070 | 1070 | static READ8_HANDLER( htengoku_input_r ) |
| 1071 | 1071 | { |
| 1072 | static const char *keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 1073 | static const char *keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 1072 | static const char *const keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 1073 | static const char *const keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 1074 | 1074 | |
| 1075 | 1075 | switch( htengoku_select ) |
| 1076 | 1076 | { |
| r3232 | r3233 | |
| 1199 | 1199 | |
| 1200 | 1200 | static READ8_HANDLER( tenkai_ip_r ) |
| 1201 | 1201 | { |
| 1202 | static const char *keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 1203 | // static const char *keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 1202 | static const char *const keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 1203 | //static const char *const keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 1204 | 1204 | |
| 1205 | 1205 | switch (offset) |
| 1206 | 1206 | { |
| r3232 | r3233 | |
| 1280 | 1280 | } |
| 1281 | 1281 | } |
| 1282 | 1282 | |
| 1283 | static void tenkai_update_rombank( | |
| 1283 | static void tenkai_update_rombank(running_machine *machine) | |
| 1284 | 1284 | { |
| 1285 | romptr = memory_region( | |
| 1285 | romptr = memory_region(machine, "main") + 0x10000 + 0x8000 * rombank; | |
| 1286 | 1286 | // logerror("rombank = %02x\n",rombank); |
| 1287 | 1287 | } |
| 1288 | 1288 | |
| r3232 | r3233 | |
| 1293 | 1293 | static WRITE8_HANDLER( tenkai_p3_w ) |
| 1294 | 1294 | { |
| 1295 | 1295 | rombank = ((data & 0x04) << 1) | (rombank & 0x07); |
| 1296 | tenkai_update_rombank(); | |
| 1296 | tenkai_update_rombank(machine); | |
| 1297 | 1297 | } |
| 1298 | 1298 | static WRITE8_HANDLER( tenkai_p4_w ) |
| 1299 | 1299 | { |
| 1300 | 1300 | rombank = (rombank & 0x08) | ((data & 0x0e) >> 1); |
| 1301 | tenkai_update_rombank(); | |
| 1301 | tenkai_update_rombank(machine); | |
| 1302 | 1302 | } |
| 1303 | 1303 | // Added by Whistler - START |
| 1304 | 1304 | static READ8_HANDLER( tenkai_p5_r ) |
| r3232 | r3233 | |
| 1325 | 1325 | static WRITE8_HANDLER( tenkai_p8_w ) |
| 1326 | 1326 | { |
| 1327 | 1327 | rombank = ((data & 0x08) << 1) | (rombank & 0x0f); |
| 1328 | tenkai_update_rombank(); | |
| 1328 | tenkai_update_rombank(machine); | |
| 1329 | 1329 | } |
| 1330 | 1330 | static READ8_HANDLER( tenkai_p8_r ) |
| 1331 | 1331 | { |
| r3232 | r3233 | |
|---|---|---|
| 271 | 271 | if( ( m_n_znsecsel & 0x80 ) == 0 ) |
| 272 | 272 | { |
| 273 | 273 | psx_sio_install_handler( 0, sio_pad_handler ); |
| 274 | psx_sio_input( | |
| 274 | psx_sio_input( machine, 0, PSX_SIO_IN_DSR, 0 ); | |
| 275 | 275 | } |
| 276 | 276 | else if( ( m_n_znsecsel & 0x08 ) == 0 ) |
| 277 | 277 | { |
| 278 | 278 | znsec_start( 1 ); |
| 279 | 279 | psx_sio_install_handler( 0, sio_znsec1_handler ); |
| 280 | psx_sio_input( | |
| 280 | psx_sio_input( machine, 0, PSX_SIO_IN_DSR, 0 ); | |
| 281 | 281 | } |
| 282 | 282 | else if( ( m_n_znsecsel & 0x04 ) == 0 ) |
| 283 | 283 | { |
| 284 | 284 | znsec_start( 0 ); |
| 285 | 285 | psx_sio_install_handler( 0, sio_znsec0_handler ); |
| 286 | psx_sio_input( | |
| 286 | psx_sio_input( machine, 0, PSX_SIO_IN_DSR, 0 ); | |
| 287 | 287 | } |
| 288 | 288 | else |
| 289 | 289 | { |
| r3232 | r3233 | |
| 291 | 291 | m_b_lastclock = 1; |
| 292 | 292 | |
| 293 | 293 | psx_sio_install_handler( 0, sio_dip_handler ); |
| 294 | psx_sio_input( | |
| 294 | psx_sio_input( machine, 0, PSX_SIO_IN_DSR, 0 ); | |
| 295 | 295 | |
| 296 | 296 | timer_adjust_oneshot( dip_timer, ATTOTIME_IN_CYCLES( 100, 0 ), 1 ); |
| 297 | 297 | } |
| r3232 | r3233 | |
| 301 | 301 | |
| 302 | 302 | static TIMER_CALLBACK( dip_timer_fired ) |
| 303 | 303 | { |
| 304 | psx_sio_input( | |
| 304 | psx_sio_input( machine, 0, PSX_SIO_IN_DSR, param * PSX_SIO_IN_DSR ); | |
| 305 | 305 | |
| 306 | 306 | if( param ) |
| 307 | 307 | { |
| r3232 | r3233 | |
| 450 | 450 | |
| 451 | 451 | static MACHINE_DRIVER_START( zn1_1mb_vram ) |
| 452 | 452 | /* basic machine hardware */ |
| 453 | MDRV_CPU_ADD( " | |
| 453 | MDRV_CPU_ADD( "main", PSXCPU, XTAL_67_7376MHz ) | |
| 454 | 454 | MDRV_CPU_PROGRAM_MAP( zn_map, 0 ) |
| 455 | 455 | MDRV_CPU_VBLANK_INT("main", psx_vblank) |
| 456 | 456 | |
| r3232 | r3233 | |
| 489 | 489 | |
| 490 | 490 | static MACHINE_DRIVER_START( zn2 ) |
| 491 | 491 | /* basic machine hardware */ |
| 492 | MDRV_CPU_ADD( " | |
| 492 | MDRV_CPU_ADD( "main", PSXCPU, XTAL_100MHz ) | |
| 493 | 493 | MDRV_CPU_PROGRAM_MAP( zn_map, 0 ) |
| 494 | 494 | MDRV_CPU_VBLANK_INT("main", psx_vblank) |
| 495 | 495 | |
| r3232 | r3233 | |
| 2353 | 2353 | static MACHINE_DRIVER_START( coh1000a_ide ) |
| 2354 | 2354 | MDRV_IMPORT_FROM( zn1_2mb_vram ) |
| 2355 | 2355 | |
| 2356 | MDRV_CPU_MODIFY( " | |
| 2356 | MDRV_CPU_MODIFY( "main" ) | |
| 2357 | 2357 | MDRV_CPU_VBLANK_INT("main", jdredd_vblank) |
| 2358 | 2358 | |
| 2359 | 2359 | MDRV_MACHINE_RESET( coh1000a ) |
| r3232 | r3233 | |
|---|---|---|
| 563 | 563 | PORT_INCLUDE( sentetst ) |
| 564 | 564 | |
| 565 | 565 | PORT_MODIFY("SWH") |
| 566 | PORT_DIPNAME( 0x03, 0x01, DEF_STR( Coinage ) ) PORT_DIPLOCATION("H1:1,2") | |
| 567 | PORT_DIPSETTING( 0x03, DEF_STR( 2C_1C ) ) | |
| 568 | PORT_DIPSETTING( 0x01, DEF_STR( 1C_1C ) ) | |
| 569 | PORT_DIPSETTING( 0x02, DEF_STR( 1C_2C ) ) | |
| 570 | PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) | |
| 571 | ||
| 566 | 572 | PORT_DIPNAME( 0x1c, 0x00, "Bonus Coins" ) PORT_DIPLOCATION("H1:3,4,5") |
| 567 | 573 | PORT_DIPSETTING( 0x00, DEF_STR( None ) ) |
| 568 | 574 | PORT_DIPSETTING( 0x04, "2 Coins = 1 Bonus" ) |
| r3232 | r3233 | |
|---|---|---|
| 1698 | 1698 | INPUT_PORTS_END |
| 1699 | 1699 | |
| 1700 | 1700 | /* xxx_BUTTONs are used with player = 0, 1, 2, 3 so we need to return 0 for the missing 4th I/O port */ |
| 1701 | static const char *padnames[] = { "PAD1", "PAD2", "IN0", "UNK" }; | |
| 1701 | static const char *const padnames[] = { "PAD1", "PAD2", "IN0", "UNK" }; | |
| 1702 | 1702 | |
| 1703 | 1703 | #define MODE_BUTTON(player) ((input_port_read_safe(Machine, padnames[player], 0) & 0x0800) >> 11) |
| 1704 | 1704 | #define Z_BUTTON(player) ((input_port_read_safe(Machine, padnames[player], 0) & 0x0400) >> 10) |
| r3232 | r3233 | |
| 2617 | 2617 | if (d & 0x000f) { *dst &= ~0x000f; *dst |= d & 0x000f; } |
| 2618 | 2618 | } |
| 2619 | 2619 | |
| 2620 | static UINT32 pm_io(int reg, int write, UINT32 d) | |
| 2620 | static UINT32 pm_io(running_machine *machine, int reg, int write, UINT32 d) | |
| 2621 | 2621 | { |
| 2622 | 2622 | if (svp.emu_status & SSP_PMC_SET) |
| 2623 | 2623 | { |
| r3232 | r3233 | |
| 2672 | 2672 | int addr = svp.pmac_read[reg]&0xffff; |
| 2673 | 2673 | if ((mode & 0xfff0) == 0x0800) // ROM, inc 1, verified to be correct |
| 2674 | 2674 | { |
| 2675 | UINT16 *ROM = (UINT16 *) memory_region( | |
| 2675 | UINT16 *ROM = (UINT16 *) memory_region(machine, "main"); | |
| 2676 | 2676 | svp.pmac_read[reg] += 1; |
| 2677 | 2677 | d = ROM[addr|((mode&0xf)<<16)]; |
| 2678 | 2678 | } |
| r3232 | r3233 | |
| 2701 | 2701 | |
| 2702 | 2702 | static READ16_HANDLER( read_PM0 ) |
| 2703 | 2703 | { |
| 2704 | UINT32 d = pm_io(0, 0, 0); | |
| 2704 | UINT32 d = pm_io(machine, 0, 0, 0); | |
| 2705 | 2705 | if (d != (UINT32)-1) return d; |
| 2706 | 2706 | d = svp.XST2; |
| 2707 | 2707 | svp.XST2 &= ~2; // ? |
| r3232 | r3233 | |
| 2710 | 2710 | |
| 2711 | 2711 | static WRITE16_HANDLER( write_PM0 ) |
| 2712 | 2712 | { |
| 2713 | UINT32 r = pm_io(0, 1, data); | |
| 2713 | UINT32 r = pm_io(machine, 0, 1, data); | |
| 2714 | 2714 | if (r != (UINT32)-1) return; |
| 2715 | 2715 | svp.XST2 = data; // ? |
| 2716 | 2716 | } |
| 2717 | 2717 | |
| 2718 | 2718 | static READ16_HANDLER( read_PM1 ) |
| 2719 | 2719 | { |
| 2720 | UINT32 r = pm_io(1, 0, 0); | |
| 2720 | UINT32 r = pm_io(machine, 1, 0, 0); | |
| 2721 | 2721 | if (r != (UINT32)-1) return r; |
| 2722 | 2722 | logerror("svp: PM1 acces in non PM mode?\n"); |
| 2723 | 2723 | return 0; |
| r3232 | r3233 | |
| 2725 | 2725 | |
| 2726 | 2726 | static WRITE16_HANDLER( write_PM1 ) |
| 2727 | 2727 | { |
| 2728 | UINT32 r = pm_io(1, 1, data); | |
| 2728 | UINT32 r = pm_io(machine, 1, 1, data); | |
| 2729 | 2729 | if (r != (UINT32)-1) return; |
| 2730 | 2730 | logerror("svp: PM1 acces in non PM mode?\n"); |
| 2731 | 2731 | } |
| 2732 | 2732 | |
| 2733 | 2733 | static READ16_HANDLER( read_PM2 ) |
| 2734 | 2734 | { |
| 2735 | UINT32 r = pm_io(2, 0, 0); | |
| 2735 | UINT32 r = pm_io(machine, 2, 0, 0); | |
| 2736 | 2736 | if (r != (UINT32)-1) return r; |
| 2737 | 2737 | logerror("svp: PM2 acces in non PM mode?\n"); |
| 2738 | 2738 | return 0; |
| r3232 | r3233 | |
| 2740 | 2740 | |
| 2741 | 2741 | static WRITE16_HANDLER( write_PM2 ) |
| 2742 | 2742 | { |
| 2743 | UINT32 r = pm_io(2, 1, data); | |
| 2743 | UINT32 r = pm_io(machine, 2, 1, data); | |
| 2744 | 2744 | if (r != (UINT32)-1) return; |
| 2745 | 2745 | logerror("svp: PM2 acces in non PM mode?\n"); |
| 2746 | 2746 | } |
| 2747 | 2747 | |
| 2748 | 2748 | static READ16_HANDLER( read_XST ) |
| 2749 | 2749 | { |
| 2750 | UINT32 d = pm_io(3, 0, 0); | |
| 2750 | UINT32 d = pm_io(machine, 3, 0, 0); | |
| 2751 | 2751 | if (d != (UINT32)-1) return d; |
| 2752 | 2752 | |
| 2753 | 2753 | return svp.XST; |
| r3232 | r3233 | |
| 2755 | 2755 | |
| 2756 | 2756 | static WRITE16_HANDLER( write_XST ) |
| 2757 | 2757 | { |
| 2758 | UINT32 r = pm_io(3, 1, data); | |
| 2758 | UINT32 r = pm_io(machine, 3, 1, data); | |
| 2759 | 2759 | if (r != (UINT32)-1) return; |
| 2760 | 2760 | |
| 2761 | 2761 | svp.XST2 |= 1; |
| r3232 | r3233 | |
| 2764 | 2764 | |
| 2765 | 2765 | static READ16_HANDLER( read_PM4 ) |
| 2766 | 2766 | { |
| 2767 | return pm_io(4, 0, 0); | |
| 2767 | return pm_io(machine, 4, 0, 0); | |
| 2768 | 2768 | } |
| 2769 | 2769 | |
| 2770 | 2770 | static WRITE16_HANDLER( write_PM4 ) |
| 2771 | 2771 | { |
| 2772 | pm_io(4, 1, data); | |
| 2772 | pm_io(machine, 4, 1, data); | |
| 2773 | 2773 | } |
| 2774 | 2774 | |
| 2775 | 2775 | static READ16_HANDLER( read_PMC ) |
| r3232 | r3233 | |
|---|---|---|
| 155 | 155 | PORT_START("IN1") |
| 156 | 156 | /* The gas pedal is adjusted physically so the encoder is at position 2 when the pedal is not pressed. */ |
| 157 | 157 | /* It also only uses half of the encoder. */ |
| 158 | PORT_BIT( 0x1f, 0x00, IPT_POSITIONAL ) PORT_POSITIONS(30) PORT_REMAP_TABLE(sspeedr_controller_table + 2) PORT_SENSITIVITY(25) PORT_KEYDELTA(20) | |
| 158 | PORT_BIT( 0x1f, 0x00, IPT_POSITIONAL_V ) PORT_POSITIONS(30) PORT_REMAP_TABLE(sspeedr_controller_table + 2) PORT_SENSITIVITY(25) PORT_KEYDELTA(20) | |
| 159 | 159 | |
| 160 | 160 | PORT_START("DSW") |
| 161 | 161 | PORT_DIPNAME( 0x03, 0x00, DEF_STR( Coinage ) ) |
| r3232 | r3233 | |
|---|---|---|
| 82 | 82 | static UINT8 video_regs[0x19]; |
| 83 | 83 | static UINT8 *vga_mode; |
| 84 | 84 | static UINT8 hv_blank; |
| 85 | ||
| 86 | static int bank; | |
| 87 | static int lastvalue; | |
| 88 | ||
| 85 | 89 | /*Add here Video regs defines...*/ |
| 86 | 90 | |
| 87 | 91 | |
| r3232 | r3233 | |
| 328 | 332 | sets the selected rom that appears in $C0000-$CFFFF |
| 329 | 333 | |
| 330 | 334 | */ |
| 331 | static int bank = -1; | |
| 332 | static int lastvalue = -1; | |
| 333 | 335 | int newbank = 0; |
| 334 | 336 | |
| 335 | 337 | printf("bank %d set to %02X\n", offset,data); |
| r3232 | r3233 | |
| 732 | 734 | } |
| 733 | 735 | |
| 734 | 736 | |
| 737 | static MACHINE_RESET( filetto ) | |
| 738 | { | |
| 739 | bank = -1; | |
| 740 | lastvalue = -1; | |
| 741 | hv_blank = 0; | |
| 742 | } | |
| 743 | ||
| 735 | 744 | static MACHINE_DRIVER_START( filetto ) |
| 736 | 745 | MDRV_CPU_ADD("main", I8088, 8000000) |
| 737 | 746 | MDRV_CPU_PROGRAM_MAP(filetto_map,0) |
| 738 | 747 | MDRV_CPU_IO_MAP(filetto_io,0) |
| 739 | 748 | MDRV_CPU_VBLANK_INT_HACK(filetto_irq,200) |
| 740 | 749 | |
| 750 | MDRV_MACHINE_RESET( filetto ) | |
| 751 | ||
| 741 | 752 | MDRV_DEVICE_ADD( "pit8253", PIT8253 ) |
| 742 | 753 | MDRV_DEVICE_CONFIG( pc_pit8253_config ) |
| 743 | 754 |
| r3232 | r3233 | |
|---|---|---|
| 263 | 263 | AM_RANGE(0xc000, 0xcfff) AM_WRITE(SMH_RAM) |
| 264 | 264 | ADDRESS_MAP_END |
| 265 | 265 | |
| 266 | ||
| 267 | static ADDRESS_MAP_START( sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 266 | static ADDRESS_MAP_START( sound_3526_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 268 | 267 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 269 | AM_RANGE(0x04, 0x04) AM_READ(soundlatch_clear_r) | |
| 270 | AM_RANGE(0x06, 0x06) AM_READ(soundlatch_r) | |
| 271 | ADDRESS_MAP_END | |
| 272 | ||
| 273 | static ADDRESS_MAP_START( sound_writeport_3526, ADDRESS_SPACE_IO, 8 ) | |
| 274 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 275 | 268 | AM_RANGE(0x00, 0x00) AM_WRITE(ym3526_control_port_0_w) |
| 276 | 269 | AM_RANGE(0x01, 0x01) AM_WRITE(ym3526_write_port_0_w) |
| 277 | 270 | AM_RANGE(0x02, 0x02) AM_WRITE(dac_0_signed_data_w) |
| 278 | 271 | AM_RANGE(0x03, 0x03) AM_WRITE(dac_1_signed_data_w) |
| 272 | AM_RANGE(0x04, 0x04) AM_READ(soundlatch_clear_r) | |
| 273 | AM_RANGE(0x06, 0x06) AM_READ(soundlatch_r) | |
| 279 | 274 | ADDRESS_MAP_END |
| 280 | 275 | |
| 281 | static ADDRESS_MAP_START( sound_ | |
| 276 | static ADDRESS_MAP_START( sound_ | |
| 282 | 277 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 283 | 278 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2203_control_port_0_w) |
| 284 | 279 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2203_write_port_0_w) |
| 285 | 280 | AM_RANGE(0x02, 0x02) AM_WRITE(dac_0_signed_data_w) |
| 286 | 281 | AM_RANGE(0x03, 0x03) AM_WRITE(dac_1_signed_data_w) |
| 282 | AM_RANGE(0x04, 0x04) AM_READ(soundlatch_clear_r) | |
| 283 | AM_RANGE(0x06, 0x06) AM_READ(soundlatch_r) | |
| 287 | 284 | ADDRESS_MAP_END |
| 288 | 285 | |
| 289 | 286 | static INPUT_PORTS_START( terracre ) |
| r3232 | r3233 | |
| 568 | 565 | |
| 569 | 566 | MDRV_CPU_ADD("audio", Z80, 4000000) /* 4 MHz???? */ |
| 570 | 567 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 571 | MDRV_CPU_IO_MAP(sound_ | |
| 568 | MDRV_CPU_IO_MAP(sound_ | |
| 572 | 569 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,128) /* ??? */ |
| 573 | 570 | |
| 574 | 571 | MDRV_MACHINE_START(amazon) |
| r3232 | r3233 | |
| 607 | 604 | |
| 608 | 605 | MDRV_CPU_ADD("audio", Z80, 4000000) /* 4 MHz???? */ |
| 609 | 606 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 610 | MDRV_CPU_IO_MAP(sound_ | |
| 607 | MDRV_CPU_IO_MAP(sound_ | |
| 611 | 608 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,128) /* ??? */ |
| 612 | 609 | |
| 613 | 610 | |
| r3232 | r3233 | |
| 644 | 641 | |
| 645 | 642 | MDRV_CPU_ADD("audio", Z80, 4000000) /* 4 MHz???? */ |
| 646 | 643 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 647 | MDRV_CPU_IO_MAP(sound_ | |
| 644 | MDRV_CPU_IO_MAP(sound_2203 | |
| 648 | 645 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,128) /* ??? */ |
| 649 | 646 | |
| 650 | 647 | |
| r3232 | r3233 | |
| 1034 | 1031 | GAME( 1987, horekid, 0, amazon, horekid, horekid, ROT270, "Nichibutsu", "Kid no Hore Hore Daisakusen", GAME_SUPPORTS_SAVE ) |
| 1035 | 1032 | GAME( 1987, horekidb, horekid, amazon, horekid, horekid, ROT270, "bootleg", "Kid no Hore Hore Daisakusen (bootleg)", GAME_SUPPORTS_SAVE ) |
| 1036 | 1033 | GAME( 1987, boobhack, horekid, amazon, horekid, horekid, ROT270, "bootleg", "Booby Kids (Italian manufactured graphic hack / bootleg of Kid no Hore Hore Daisakusen (bootleg))", GAME_SUPPORTS_SAVE ) |
| 1034 |
| r3232 | r3233 | |
|---|---|---|
| 111 | 111 | |
| 112 | 112 | static INTERRUPT_GEN( superdq_vblank ) |
| 113 | 113 | { |
| 114 | laserdisc_vsync(laserdisc); | |
| 115 | ||
| 116 | 114 | /* status is read when the STATUS line from the laserdisc |
| 117 | 115 | toggles (600usec after the vblank). We could set up a |
| 118 | 116 | timer to do that, but this works as well */ |
| r3232 | r3233 | |
| 305 | 303 | MDRV_MACHINE_START(superdq) |
| 306 | 304 | MDRV_MACHINE_RESET(superdq) |
| 307 | 305 | |
| 308 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 306 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 309 | 307 | MDRV_LASERDISC_OVERLAY(superdq, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 310 | 308 | |
| 311 | 309 | /* video hardware */ |
| r3232 | r3233 | |
| 323 | 321 | MDRV_SOUND_ADD("sn", SN76496, MASTER_CLOCK/8) |
| 324 | 322 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 0.8) |
| 325 | 323 | |
| 326 | MDRV_SOUND_ADD("l | |
| 324 | MDRV_SOUND_ADD("l | |
| 327 | 325 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 328 | 326 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 329 | 327 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 183 | 183 | ADDRESS_MAP_END |
| 184 | 184 | |
| 185 | 185 | /* Reaktor reads / writes some I/O ports, no idea what they're connected to, if anything */ |
| 186 | static ADDRESS_MAP_START( reaktor_ | |
| 186 | static ADDRESS_MAP_START( reaktor_io_ma | |
| 187 | 187 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 188 | AM_RANGE(0x01, 0x01) AM_READ(SMH_NOP) | |
| 189 | ADDRESS_MAP_END | |
| 190 | ||
| 191 | static ADDRESS_MAP_START( reaktor_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 192 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 193 | 188 | AM_RANGE(0x00, 0x00) AM_WRITE(SMH_NOP) |
| 194 | AM_RANGE(0x01, 0x01) AM_WRITE(SMH_NOP) | |
| 189 | AM_RANGE(0x01, 0x01) AM_READWRITE(SMH_NOP, SMH_NOP) | |
| 195 | 190 | AM_RANGE(0x02, 0x02) AM_WRITE(SMH_NOP) |
| 196 | 191 | AM_RANGE(0x03, 0x03) AM_WRITE(SMH_NOP) |
| 197 | 192 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 903 | 898 | MDRV_IMPORT_FROM(trackfld) |
| 904 | 899 | MDRV_CPU_REPLACE("main",Z80,18432000/6) |
| 905 | 900 | MDRV_CPU_PROGRAM_MAP(reaktor_readmem,reaktor_writemem) |
| 906 | MDRV_CPU_IO_MAP(reaktor_ | |
| 901 | MDRV_CPU_IO_MAP(reaktor_i | |
| 907 | 902 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 908 | 903 | MACHINE_DRIVER_END |
| 909 | 904 | |
| r3232 | r3233 | |
| 1307 | 1302 | GAME( 1985, wizzquiz, 0, wizzquiz, wizzquiz, wizzquiz, ROT0, "Konami", "Wizz Quiz (Konami version)", 0 ) |
| 1308 | 1303 | GAME( 1985, wizzquza, wizzquiz, wizzquiz, wizzquiz, wizzquiz, ROT0, "Zilec - Zenitone", "Wizz Quiz (version 4)", 0 ) |
| 1309 | 1304 | GAME( 1987, reaktor, 0, reaktor, reaktor, 0, ROT90, "Zilec", "Reaktor (Track & Field conversion)", 0 ) |
| 1305 |
| r3232 | r3233 | |
|---|---|---|
| 109 | 109 | return 0x00; |
| 110 | 110 | } |
| 111 | 111 | |
| 112 | /* | |
| 113 | Imago sprites DMA | |
| 114 | */ | |
| 112 | 115 | |
| 116 | static UINT8 imago_sprites[0x800*3]; | |
| 117 | static UINT16 imago_sprites_address; | |
| 118 | static UINT8 imago_sprites_bank = 0; | |
| 119 | ||
| 120 | static WRITE8_HANDLER( imago_dma_irq_w ) | |
| 121 | { | |
| 122 | cpunum_set_input_line(machine, 0, 0, data & 1 ? ASSERT_LINE : CLEAR_LINE); | |
| 123 | } | |
| 124 | ||
| 125 | static WRITE8_HANDLER( imago_sprites_bank_w ) | |
| 126 | { | |
| 127 | imago_sprites_bank = (data & 2) >> 1; | |
| 128 | } | |
| 129 | ||
| 130 | static WRITE8_HANDLER( imago_sprites_dma_w ) | |
| 131 | { | |
| 132 | UINT8 *rom = (UINT8 *)memory_region(machine, "gfx2"); | |
| 133 | UINT8 sprites_data; | |
| 134 | ||
| 135 | sprites_data = rom[imago_sprites_address + 0x2000*0 + imago_sprites_bank * 0x1000]; | |
| 136 | imago_sprites[offset + 0x800*0] = sprites_data; | |
| 137 | ||
| 138 | sprites_data = rom[imago_sprites_address + 0x2000*1 + imago_sprites_bank * 0x1000]; | |
| 139 | imago_sprites[offset + 0x800*1] = sprites_data; | |
| 140 | ||
| 141 | sprites_data = rom[imago_sprites_address + 0x2000*2 + imago_sprites_bank * 0x1000]; | |
| 142 | imago_sprites[offset + 0x800*2] = sprites_data; | |
| 143 | ||
| 144 | decodechar(machine->gfx[1], offset/32, imago_sprites); | |
| 145 | } | |
| 146 | ||
| 147 | static READ8_HANDLER( imago_sprites_offset_r ) | |
| 148 | { | |
| 149 | imago_sprites_address = offset; | |
| 150 | return 0xff; //not really used | |
| 151 | } | |
| 152 | ||
| 113 | 153 | static ADDRESS_MAP_START( fastfred_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| 114 | 154 | AM_RANGE(0x0000, 0xbfff) AM_ROM |
| 115 | 155 | AM_RANGE(0xc000, 0xc7ff) AM_RAM |
| r3232 | r3233 | |
| 163 | 203 | |
| 164 | 204 | static ADDRESS_MAP_START( imago_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| 165 | 205 | AM_RANGE(0x0000, 0x0fff) AM_ROM |
| 206 | AM_RANGE(0x1000, 0x1fff) AM_READ(imago_sprites_offset_r) | |
| 166 | 207 | AM_RANGE(0x2000, 0x6fff) AM_ROM |
| 167 | AM_RANGE(0xb000, 0xb3ff) AM_RAM | |
| 208 | AM_RANGE(0xb000, 0xb3ff) AM_RAM // same fg videoram (which one of the 2 is really used?) | |
| 209 | AM_RANGE(0xb800, 0xbfff) AM_RAM_WRITE(imago_sprites_dma_w) | |
| 168 | 210 | AM_RANGE(0xc000, 0xc7ff) AM_RAM |
| 169 | 211 | AM_RANGE(0xc800, 0xcbff) AM_RAM_WRITE(imago_fg_videoram_w) AM_BASE(&imago_fg_videoram) |
| 170 | 212 | AM_RANGE(0xd000, 0xd3ff) AM_RAM_WRITE(fastfred_videoram_w) AM_BASE(&fastfred_videoram) |
| r3232 | r3233 | |
| 177 | 219 | AM_RANGE(0xf001, 0xf001) AM_WRITE(interrupt_enable_w) |
| 178 | 220 | AM_RANGE(0xf002, 0xf002) AM_WRITE(fastfred_colorbank1_w) |
| 179 | 221 | AM_RANGE(0xf003, 0xf003) AM_WRITE(fastfred_colorbank2_w) |
| 180 | AM_RANGE(0xf004, 0xf004) AM_WRITE( | |
| 222 | AM_RANGE(0xf004, 0xf004) AM_WRITE( | |
| 181 | 223 | AM_RANGE(0xf005, 0xf005) AM_WRITE(imago_charbank_w) |
| 182 | AM_RANGE(0xf006, 0xf006) AM_WRITE(fastfred_flip_screen_x_w) // always 0 | |
| 183 | AM_RANGE(0xf007, 0xf007) AM_WRITE(fastfred_flip_screen_y_w) // always 0 | |
| 224 | AM_RANGE(0xf006, 0xf006) AM_WRITE(fastfred_flip_screen_x_w) | |
| 225 | AM_RANGE(0xf007, 0xf007) AM_WRITE(fastfred_flip_screen_y_w) | |
| 226 | AM_RANGE(0xf400, 0xf400) AM_WRITENOP // writes 0 or 2 | |
| 227 | AM_RANGE(0xf401, 0xf401) AM_WRITE(imago_sprites_bank_w) | |
| 184 | 228 | AM_RANGE(0xf800, 0xf800) AM_READWRITE(SMH_NOP, soundlatch_w) |
| 185 | 229 | ADDRESS_MAP_END |
| 186 | 230 | |
| r3232 | r3233 | |
| 422 | 466 | |
| 423 | 467 | PORT_MODIFY("BUTTONS") |
| 424 | 468 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_UNKNOWN ) |
| 469 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 425 | 470 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN ) |
| 426 | 471 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNKNOWN ) |
| 472 | ||
| 473 | PORT_START("DSW") | |
| 474 | PORT_DIPNAME( 0x03, 0x01, DEF_STR( Lives ) ) | |
| 475 | PORT_DIPSETTING( 0x00, "2" ) | |
| 476 | PORT_DIPSETTING( 0x01, "3" ) | |
| 477 | PORT_DIPSETTING( 0x02, "4" ) | |
| 478 | PORT_DIPSETTING( 0x03, "5" ) | |
| 479 | PORT_DIPNAME( 0x04, 0x00, DEF_STR( Unknown ) ) | |
| 480 | PORT_DIPSETTING( 0x04, DEF_STR( Off ) ) | |
| 481 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 482 | PORT_DIPNAME( 0x38, 0x00, DEF_STR( Coinage ) ) | |
| 483 | PORT_DIPSETTING( 0x38, DEF_STR( 5C_1C ) ) | |
| 484 | PORT_DIPSETTING( 0x18, DEF_STR( 4C_1C ) ) | |
| 485 | PORT_DIPSETTING( 0x28, DEF_STR( 3C_1C ) ) | |
| 486 | PORT_DIPSETTING( 0x08, DEF_STR( 2C_1C ) ) | |
| 487 | PORT_DIPSETTING( 0x00, DEF_STR( 1C_1C ) ) | |
| 488 | PORT_DIPSETTING( 0x20, DEF_STR( 1C_2C ) ) | |
| 489 | PORT_DIPSETTING( 0x10, DEF_STR( 1C_3C ) ) | |
| 490 | PORT_DIPSETTING( 0x30, DEF_STR( 1C_4C ) ) | |
| 491 | PORT_DIPNAME( 0x40, 0x00, DEF_STR( Unknown ) ) | |
| 492 | PORT_DIPSETTING( 0x40, DEF_STR( Off ) ) | |
| 493 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 494 | PORT_DIPNAME( 0x80, 0x00, DEF_STR( Unknown ) ) | |
| 495 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) | |
| 496 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) | |
| 497 | INPUT_PORTS_END | |
| 498 | ||
| 499 | static INPUT_PORTS_START( imagoa ) | |
| 500 | PORT_INCLUDE( common ) | |
| 501 | ||
| 502 | PORT_MODIFY("BUTTONS") | |
| 503 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_UNKNOWN ) | |
| 504 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 505 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN ) | |
| 506 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_UNKNOWN ) | |
| 427 | 507 | PORT_BIT( 0x80, IP_ACTIVE_HIGH, IPT_UNKNOWN ) |
| 428 | 508 | |
| 429 | 509 | PORT_MODIFY("JOYS") |
| r3232 | r3233 | |
| 482 | 562 | 32*8 |
| 483 | 563 | }; |
| 484 | 564 | |
| 565 | static const gfx_layout imago_spritelayout = | |
| 566 | { | |
| 567 | 16,16, | |
| 568 | 0x40, | |
| 569 | 3, | |
| 570 | { 0x800*8*2, 0x800*8*1, 0x800*8*0 }, | |
| 571 | { 0, 1, 2, 3, 4, 5, 6, 7, | |
| 572 | 8*8+0, 8*8+1, 8*8+2, 8*8+3, 8*8+4, 8*8+5, 8*8+6, 8*8+7 }, | |
| 573 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8, | |
| 574 | 16*8, 17*8, 18*8, 19*8, 20*8, 21*8, 22*8, 23*8 }, | |
| 575 | 32*8 | |
| 576 | }; | |
| 577 | ||
| 485 | 578 | static const gfx_layout imago_char_1bpp = |
| 486 | 579 | { |
| 487 | 580 | 8,8, |
| r3232 | r3233 | |
| 504 | 597 | GFXDECODE_END |
| 505 | 598 | |
| 506 | 599 | static GFXDECODE_START( imago ) |
| 507 | GFXDECODE_ENTRY( "gfx1", 0, charlayout, 0, 32 ) | |
| 508 | GFXDECODE_ENTRY( "gfx2", 0, spritelayout, 0, 32 ) | |
| 509 | GFXDECODE_ENTRY( "gfx3", 0, charlayout, 0, 32 ) | |
| 510 | GFXDECODE_ENTRY( "gfx4", 0, imago_char_1bpp, 0x140, 1 ) | |
| 600 | GFXDECODE_ENTRY( "gfx1", 0, charlayout, 0, 32 ) | |
| 601 | GFXDECODE_ENTRY( NULL, 0xb800, imago_spritelayout, 0, 32 ) | |
| 602 | GFXDECODE_ENTRY( "gfx3", 0, charlayout, 0, 32 ) | |
| 603 | GFXDECODE_ENTRY( "gfx4", 0, imago_char_1bpp, 0x140, 1 ) | |
| 511 | 604 | GFXDECODE_END |
| 512 | 605 | |
| 513 | 606 | #define CLOCK 18432000 /* The crystal is 18.432MHz */ |
| r3232 | r3233 | |
| 784 | 877 | ROM_LOAD( "imago11.82", 0x0000, 0x1000, CRC(3cce69b4) SHA1(e7d52e388e09e86abb597493f5807ee088cf7a40) ) |
| 785 | 878 | ROM_CONTINUE( 0x2000, 0x1000 ) |
| 786 | 879 | ROM_LOAD( "imago12.83", 0x3000, 0x2000, CRC(8dff98c0) SHA1(e7311d9ca4544f1263e894e6d93ca52c87fc83bf) ) |
| 880 | ROM_LOAD( "13.bin", 0x5000, 0x2000, CRC(ae684602) SHA1(d187abbe62ee58a8190d9f428ded0feeb9484abd) ) | |
| 881 | ||
| 882 | ROM_REGION( 0x10000, "audio", 0 ) | |
| 883 | ROM_LOAD( "imago08.60", 0x0000, 0x1000, CRC(4f77c2c9) SHA1(1e046786fbad7fb8c7c462b7bd5d80152c6b8779) ) | |
| 884 | ||
| 885 | ROM_REGION( 0x3000, "gfx1", ROMREGION_DISPOSE ) | |
| 886 | ROM_LOAD( "1.bin", 0x0000, 0x1000, CRC(f80a0b69) SHA1(2b85179942586316eb61614d8697588aa9d26f9a) ) | |
| 887 | ROM_LOAD( "imago02.40", 0x1000, 0x1000, CRC(71354480) SHA1(f5f5e1cc336cae1778b7f6c744eb1bdc4226f138) ) | |
| 888 | ROM_LOAD( "3.bin", 0x2000, 0x1000, CRC(722fd625) SHA1(6f9a9f4f000cc0b251ca8d496a2ea4a708665dda) ) | |
| 889 | ||
| 890 | ROM_REGION( 0x6000, "gfx2", 0 ) | |
| 891 | ROM_LOAD( "imago04.51", 0x0000, 0x1000, CRC(ed987b3e) SHA1(2f88a0463b4323adb27467fb3d022144a4943793) ) | |
| 892 | ROM_LOAD( "imago05.52", 0x1000, 0x1000, CRC(77ee68ce) SHA1(a47af1bec81977d0f47463bd88e9f526fd2d6611) ) | |
| 893 | ROM_LOAD( "imago07.56", 0x2000, 0x1000, CRC(48b35190) SHA1(3a000264aad03f55fe67eed7c868acf87e804c0f) ) | |
| 894 | ROM_LOAD( "imago06.55", 0x3000, 0x1000, CRC(136990fc) SHA1(f3ecba92db25fbeb7df83c26667b7447c2d03b58) ) | |
| 895 | ROM_LOAD( "imago09.64", 0x4000, 0x1000, CRC(9efb806d) SHA1(504cc27cf071873714ec61835d9da676884fe1c8) ) | |
| 896 | ROM_LOAD( "imago10.65", 0x5000, 0x1000, CRC(801a18d3) SHA1(f798978a47124f50be25ab4e5c6a4974d9003634) ) | |
| 897 | ||
| 898 | ROM_REGION( 0x3000, "gfx3", ROMREGION_DISPOSE ) | |
| 899 | ROM_LOAD( "imago14.170", 0x0000, 0x1000, CRC(eded37f6) SHA1(c2ff5d4c1b001740ec4453467f879035db196a9b) ) | |
| 900 | ROM_FILL( 0x1000, 0x2000, 0 ) | |
| 901 | ||
| 902 | ROM_REGION( 0x1000, "gfx4", ROMREGION_DISPOSE ) | |
| 903 | ROM_LOAD( "imago15.191", 0x0000, 0x1000, CRC(85fcc195) SHA1(a76f24201c037d1e6f909fb0ea4ad59b1d6ddd57) ) | |
| 904 | ||
| 905 | ROM_REGION( 0x0300, "proms", 0 ) | |
| 906 | ROM_LOAD( "imago.96", 0x0000, 0x0100, CRC(5ba81edc) SHA1(b64ebbe054052583688cdf0f064794436c095e7e) ) | |
| 907 | ROM_LOAD( "imago.95", 0x0100, 0x0100, CRC(e2b7aa09) SHA1(f8edfccdd698793d9a9f423953a582b0f7b9b697) ) | |
| 908 | ROM_LOAD( "imago.97", 0x0200, 0x0100, CRC(e28a7f00) SHA1(05b4882c5ea5da332735866d858872bc5eeaca24) ) | |
| 909 | ROM_END | |
| 910 | ||
| 911 | /* this set has patched out the code to enable the cocktail mode for 2nd player at $5b24 */ | |
| 912 | ROM_START( imagoa ) | |
| 913 | ROM_REGION( 0x10000, "main", 0 ) | |
| 914 | ROM_LOAD( "imago11.82", 0x0000, 0x1000, CRC(3cce69b4) SHA1(e7d52e388e09e86abb597493f5807ee088cf7a40) ) | |
| 915 | ROM_CONTINUE( 0x2000, 0x1000 ) | |
| 916 | ROM_LOAD( "imago12.83", 0x3000, 0x2000, CRC(8dff98c0) SHA1(e7311d9ca4544f1263e894e6d93ca52c87fc83bf) ) | |
| 787 | 917 | ROM_LOAD( "imago13.84", 0x5000, 0x2000, CRC(f0f14b4d) SHA1(92b82080575a9c95df926c404c19875ac66c2b00) ) |
| 788 | 918 | |
| 789 | 919 | ROM_REGION( 0x10000, "audio", 0 ) |
| r3232 | r3233 | |
| 794 | 924 | ROM_LOAD( "imago02.40", 0x1000, 0x1000, CRC(71354480) SHA1(f5f5e1cc336cae1778b7f6c744eb1bdc4226f138) ) |
| 795 | 925 | ROM_LOAD( "imago03.41", 0x2000, 0x1000, CRC(7aba3d98) SHA1(5d058f39bf1339d523fe015b67083d44ff6a81d4) ) |
| 796 | 926 | |
| 797 | ROM_REGION( 0x6000, "gfx2", | |
| 927 | ROM_REGION( 0x6000, "gfx2", 0 | |
| 798 | 928 | ROM_LOAD( "imago04.51", 0x0000, 0x1000, CRC(ed987b3e) SHA1(2f88a0463b4323adb27467fb3d022144a4943793) ) |
| 799 | 929 | ROM_LOAD( "imago05.52", 0x1000, 0x1000, CRC(77ee68ce) SHA1(a47af1bec81977d0f47463bd88e9f526fd2d6611) ) |
| 800 | 930 | ROM_LOAD( "imago07.56", 0x2000, 0x1000, CRC(48b35190) SHA1(3a000264aad03f55fe67eed7c868acf87e804c0f) ) |
| r3232 | r3233 | |
| 815 | 945 | ROM_LOAD( "imago.97", 0x0200, 0x0100, CRC(e28a7f00) SHA1(05b4882c5ea5da332735866d858872bc5eeaca24) ) |
| 816 | 946 | ROM_END |
| 817 | 947 | |
| 948 | ||
| 818 | 949 | static DRIVER_INIT( flyboy ) |
| 819 | 950 | { |
| 820 | 951 | memory_install_read8_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xc085, 0xc099, 0, 0, flyboy_custom1_io_r); |
| r3232 | r3233 | |
| 857 | 988 | GAME( 1983, jumpcoat, jumpcoas, jumpcoas, jumpcoas, jumpcoas, ROT90, "Taito", "Jump Coaster (Taito)", 0 ) |
| 858 | 989 | GAME( 1983, boggy84, 0, jumpcoas, boggy84, boggy84, ROT90, "bootleg", "Boggy '84", 0 ) |
| 859 | 990 | GAME( 1986, redrobin, 0, fastfred, redrobin, flyboyb, ROT90, "Elettronolo", "Red Robin", 0 ) |
| 860 | GAME( 1983, imago, 0, imago, imago, imago, ROT90, "Acom", "Imago", GAME_IMPERFECT_GRAPHICS ) | |
| 991 | GAME( 1984, imago, 0, imago, imago, imago, ROT90, "Acom", "Imago (cocktail set)", 0 ) | |
| 992 | GAME( 1983, imagoa, imago, imago, imagoa, imago, ROT90, "Acom", "Imago (no cocktail set)", 0 ) |
| r3232 | r3233 | |
|---|---|---|
| 840 | 840 | |
| 841 | 841 | /* basic machine hardware */ |
| 842 | 842 | MDRV_CPU_ADD("main", M6502, MAIN_CPU_CLOCK) |
| 843 | MDRV_TIMER_ADD_SCANLINE(" | |
| 843 | MDRV_TIMER_ADD_SCANLINE("vblank", irq_callback, "main", VBSTART, 0) | |
| 844 | 844 | |
| 845 | 845 | /* video hardware */ |
| 846 | 846 | MDRV_VIDEO_START(astrof) |
| r3232 | r3233 | |
|---|---|---|
| 370 | 370 | AM_RANGE(0x0000, 0xffff) AM_WRITE(SMH_NOP) |
| 371 | 371 | ADDRESS_MAP_END |
| 372 | 372 | |
| 373 | static ADDRESS_MAP_START( avengers_adpcm_ | |
| 373 | static ADDRESS_MAP_START( avengers_adpcm_io_ma | |
| 374 | 374 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 375 | 375 | AM_RANGE(0x00, 0x00) AM_READ(avengers_adpcm_r) |
| 376 | AM_RANGE(0x01, 0x01) AM_WRITE(msm5205_w) | |
| 376 | 377 | ADDRESS_MAP_END |
| 377 | 378 | |
| 378 | static ADDRESS_MAP_START( adpcm_ | |
| 379 | static ADDRESS_MAP_START( adpcm_io_ma | |
| 379 | 380 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 380 | 381 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch_r) |
| 381 | ADDRESS_MAP_END | |
| 382 | ||
| 383 | static ADDRESS_MAP_START( adpcm_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 384 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 385 | 382 | AM_RANGE(0x01, 0x01) AM_WRITE(msm5205_w) |
| 386 | 383 | ADDRESS_MAP_END |
| 387 | 384 | |
| r3232 | r3233 | |
| 806 | 803 | |
| 807 | 804 | MDRV_CPU_ADD("adpcm", Z80, 4000000) // 3.579545 Mhz (?) |
| 808 | 805 | MDRV_CPU_PROGRAM_MAP(adpcm_readmem,adpcm_writemem) |
| 809 | MDRV_CPU_IO_MAP(adpcm_ | |
| 806 | MDRV_CPU_IO_MAP(adpcm_i | |
| 810 | 807 | MDRV_CPU_PERIODIC_INT(irq0_line_hold, 4000) |
| 811 | 808 | |
| 812 | 809 | /* video hardware */ |
| r3232 | r3233 | |
| 829 | 826 | MDRV_CPU_VBLANK_INT("main", nmi_line_pulse) // RST 38h triggered by software |
| 830 | 827 | |
| 831 | 828 | MDRV_CPU_MODIFY("adpcm") |
| 832 | MDRV_CPU_IO_MAP(avengers_adpcm_ | |
| 829 | MDRV_CPU_IO_MAP(avengers_adpcm_i | |
| 833 | 830 | |
| 834 | 831 | /* video hardware */ |
| 835 | 832 | MDRV_VIDEO_START(avengers) |
| r3232 | r3233 | |
| 1333 | 1330 | GAME( 1987, avengers, 0, avengers, avengers, 0, ROT90, "Capcom", "Avengers (US set 1)", 0 ) |
| 1334 | 1331 | GAME( 1987, avenger2, avengers, avengers, avengers, 0, ROT90, "Capcom", "Avengers (US set 2)", 0 ) |
| 1335 | 1332 | GAME( 1987, buraiken, avengers, avengers, avengers, 0, ROT90, "Capcom", "Hissatsu Buraiken (Japan)", 0 ) |
| 1333 |
| r3232 | r3233 | |
|---|---|---|
| 165 | 165 | cpunum_set_input_line(machine, 1, INPUT_LINE_RESET, CLEAR_LINE); |
| 166 | 166 | } |
| 167 | 167 | |
| 168 | static int prot_mode_sel | |
| 168 | static int prot_mode_sel | |
| 169 | 169 | static int prot_mem[16]; |
| 170 | 170 | |
| 171 | 171 | static READ8_HANDLER( spunchout_prot_r ) { |
| r3232 | r3233 | |
| 669 | 669 | "audio" |
| 670 | 670 | }; |
| 671 | 671 | |
| 672 | static MACHINE_RESET( punchout ) | |
| 673 | { | |
| 674 | prot_mode_sel = -1; | |
| 675 | memset(prot_mem, 0, sizeof(prot_mem)); | |
| 676 | } | |
| 672 | 677 | |
| 678 | ||
| 673 | 679 | static MACHINE_DRIVER_START( punchout ) |
| 674 | 680 | |
| 675 | 681 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 682 | 688 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 683 | 689 | MDRV_CPU_VBLANK_INT("top", nmi_line_pulse) |
| 684 | 690 | |
| 691 | MDRV_MACHINE_RESET(punchout) | |
| 685 | 692 | MDRV_NVRAM_HANDLER(generic_0fill) |
| 686 | 693 | |
| 687 | 694 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 1442 | 1442 | |
| 1443 | 1443 | static WRITE32_HANDLER( analog_port_w ) |
| 1444 | 1444 | { |
| 1445 | static const char *portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1445 | static const char *const portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1446 | 1446 | |
| 1447 | 1447 | if (data < 8 || data > 15) |
| 1448 | 1448 | logerror("%08X:Unexpected analog port select = %08X\n", activecpu_get_pc(), data); |
| r3232 | r3233 | |
|---|---|---|
| 227 | 227 | |
| 228 | 228 | static READ16_HANDLER( io_chip_r ) |
| 229 | 229 | { |
| 230 | static const char *portnames[] = { "P1", "GENERAL", "PORTC", "PORTD", "PORTE", "DSW", "COINAGE", "PORTH" }; | |
| 230 | static const char *const portnames[] = { "P1", "GENERAL", "PORTC", "PORTD", "PORTE", "DSW", "COINAGE", "PORTH" }; | |
| 231 | 231 | offset &= 0x1f/2; |
| 232 | 232 | |
| 233 | 233 | switch (offset) |
| r3232 | r3233 | |
|---|---|---|
| 1545 | 1545 | ROM_LOAD( "epr-10646.69", 0x30000, 0x08000, CRC(473cc411) SHA1(04ca2d047eb59581cd5d76e0ac6eca8b19eef497) ) |
| 1546 | 1546 | ROM_RELOAD( 0x38000, 0x08000 ) |
| 1547 | 1547 | |
| 1548 | ROM_REGION( 0x2000, "fd1089b | |
| 1548 | ROM_REGION( 0x2000, "fd1089b | |
| 1549 | 1549 | ROM_LOAD( "317-0034.key", 0x0000, 0x2000, CRC(263ca773) SHA1(8e80d69d61cf54fd02b0ca59dd397fa60c713f3d) ) |
| 1550 | 1550 | ROM_END |
| 1551 | 1551 | |
| r3232 | r3233 | |
| 1606 | 1606 | ROM_LOAD( "epr-10646.69", 0x30000, 0x08000, CRC(473cc411) SHA1(04ca2d047eb59581cd5d76e0ac6eca8b19eef497) ) |
| 1607 | 1607 | ROM_RELOAD( 0x38000, 0x08000 ) |
| 1608 | 1608 | |
| 1609 | ROM_REGION( 0x2000, "fd1089b | |
| 1609 | ROM_REGION( 0x2000, "fd1089b | |
| 1610 | 1610 | ROM_LOAD( "317-0034.key", 0x0000, 0x2000, CRC(263ca773) SHA1(8e80d69d61cf54fd02b0ca59dd397fa60c713f3d) ) |
| 1611 | 1611 | ROM_END |
| 1612 | 1612 | |
| r3232 | r3233 | |
| 1667 | 1667 | ROM_LOAD( "epr-10646.69", 0x30000, 0x08000, CRC(473cc411) SHA1(04ca2d047eb59581cd5d76e0ac6eca8b19eef497) ) |
| 1668 | 1668 | ROM_RELOAD( 0x38000, 0x08000 ) |
| 1669 | 1669 | |
| 1670 | ROM_REGION( 0x2000, "fd1089b | |
| 1670 | ROM_REGION( 0x2000, "fd1089b | |
| 1671 | 1671 | ROM_LOAD( "317-0034.key", 0x0000, 0x2000, CRC(263ca773) SHA1(8e80d69d61cf54fd02b0ca59dd397fa60c713f3d) ) |
| 1672 | 1672 | ROM_END |
| 1673 | 1673 |
| r3232 | r3233 | |
|---|---|---|
| 232 | 232 | |
| 233 | 233 | |
| 234 | 234 | #include "driver.h" |
| 235 | #include "cpu/mcs48/mcs48. | |
| 235 | #include "cpu/mcs48/mcs48.h" | |
| 236 | 236 | #include "sound/dac.h" |
| 237 | 237 | |
| 238 | 238 | #define DATA_NVRAM_SIZE 0x100 |
| r3232 | r3233 | |
| 377 | 377 | } |
| 378 | 378 | break; |
| 379 | 379 | } |
| 380 | case 0x5f: | |
| 380 | 381 | case 0xdf: |
| 381 | 382 | { |
| 382 | n_offs = ((p1 & 0xc0) << 2 ) + offset; | |
| 383 | 383 | valor = data_ram[offset]; |
| 384 | 384 | break; |
| 385 | 385 | } |
| 386 | case 0x5f: | |
| 387 | { | |
| 388 | n_offs = ((p1 & 0xc0) << 2 ) + offset; | |
| 389 | valor = data_ram[offset]; | |
| 390 | break; | |
| 391 | } | |
| 392 | 386 | case 0x7c: |
| 393 | 387 | case 0x7d: |
| 394 | 388 | case 0x7e: |
| r3232 | r3233 | |
| 617 | 611 | |
| 618 | 612 | if (dc_40103 == 0) |
| 619 | 613 | { |
| 620 | cpunum_set_input_line(machine, 1, 0, | |
| 614 | cpunum_set_input_line(machine, 1, 0, ASSERT_LINE); | |
| 621 | 615 | } |
| 622 | 616 | } |
| 623 | 617 | } |
| r3232 | r3233 | |
|---|---|---|
| 435 | 435 | |
| 436 | 436 | static READ8_HANDLER( zpu_inputs_r ) |
| 437 | 437 | { |
| 438 | static const char *strobenames[] = { "ZPU", "DSW0", "DSW1", "DSW2", "DSW3", "BUTTONS", "STICK0_X", "STICK0_Y", "STICK1_X", "STICK1_Y" }; | |
| 438 | static const char *const strobenames[] = { "ZPU", "DSW0", "DSW1", "DSW2", "DSW3", "BUTTONS", "STICK0_X", "STICK0_Y", "STICK1_X", "STICK1_Y" }; | |
| 439 | 439 | UINT8 ret = 0; |
| 440 | 440 | |
| 441 | 441 | if (bcd_7445<10) |
| r3232 | r3233 | |
| 470 | 470 | coin_counter_w(offset, (data&0x40)>>6 ); |
| 471 | 471 | } |
| 472 | 472 | |
| 473 | static ADDRESS_MAP_START( | |
| 473 | static ADDRESS_MAP_START( io_ma | |
| 474 | 474 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 475 | AM_RANGE(0x4c, 0x4f) AM_READ(ls670_1_r) | |
| 476 | AM_RANGE(0x62, 0x62) AM_READ(zpu_inputs_r) | |
| 477 | ADDRESS_MAP_END | |
| 478 | ||
| 479 | static ADDRESS_MAP_START( writeport, ADDRESS_SPACE_IO, 8 ) | |
| 480 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 481 | AM_RANGE(0x4c, 0x4f) AM_WRITE(ls670_0_w) | |
| 475 | AM_RANGE(0x4c, 0x4f) AM_READWRITE(ls670_1_r, ls670_0_w) | |
| 482 | 476 | AM_RANGE(0x60, 0x60) AM_WRITE(zpu_bcd_decoder_w) |
| 477 | AM_RANGE(0x62, 0x62) AM_READ(zpu_inputs_r) | |
| 483 | 478 | AM_RANGE(0x68, 0x68) AM_WRITE(zpu_coin_counter_w) |
| 484 | 479 | AM_RANGE(0x6a, 0x6a) AM_WRITE(zpu_lamps_w) |
| 485 | 480 | AM_RANGE(0x6e, 0x6f) AM_WRITE(zpu_led_w) |
| r3232 | r3233 | |
| 512 | 507 | } |
| 513 | 508 | |
| 514 | 509 | |
| 515 | static ADDRESS_MAP_START( | |
| 510 | static ADDRESS_MAP_START( | |
| 516 | 511 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 517 | AM_RANGE(0x80, 0x83) AM_READ(ls670_0_r) | |
| 518 | ADDRESS_MAP_END | |
| 519 | ||
| 520 | static ADDRESS_MAP_START( writeport_cpu2, ADDRESS_SPACE_IO, 8 ) | |
| 521 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 522 | 512 | AM_RANGE(0x00, 0x00) AM_WRITE(vsb_ls273_audio_control_w) |
| 523 | AM_RANGE(0x80, 0x83) AM_WRITE(ls670_1_w) | |
| 513 | AM_RANGE(0x80, 0x83) AM_READWRITE(ls670_0_r, ls670_1_w) | |
| 524 | 514 | ADDRESS_MAP_END |
| 525 | 515 | |
| 526 | 516 | static ADDRESS_MAP_START( readmem_cpu2, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 623 | 613 | return (port02_status); |
| 624 | 614 | } |
| 625 | 615 | |
| 626 | static ADDRESS_MAP_START( readport_cpu3, ADDRESS_SPACE_IO, 8 ) | |
| 627 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 628 | AM_RANGE(0x02, 0x02) AM_READ(cfb_port_02_r) /* VCU status ? */ | |
| 629 | ADDRESS_MAP_END | |
| 630 | 616 | |
| 631 | static ADDRESS_MAP_START( | |
| 617 | static ADDRESS_MAP_START( | |
| 632 | 618 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 633 | 619 | AM_RANGE(0x01, 0x01) AM_WRITE(cfb_backgnd_color_w) |
| 634 | AM_RANGE(0x02, 0x02) AM_WRITE(cfb_led_w) | |
| 620 | AM_RANGE(0x02, 0x02) AM_READWRITE(cfb_port_02_r, cfb_led_w) /* Read = VCU status ? */ | |
| 635 | 621 | AM_RANGE(0x03, 0x03) AM_WRITE(cfb_zpu_int_req_set_w) |
| 636 | 622 | AM_RANGE(0x04, 0x04) AM_WRITE(cfb_rom_bank_sel_w) |
| 637 | 623 | AM_RANGE(0x05, 0x05) AM_WRITE(cfb_vbank_w) //visible/writable videopage select? |
| 638 | 624 | ADDRESS_MAP_END |
| 639 | ||
| 640 | 625 | /* Great Guns has a little different banking layout */ |
| 641 | static ADDRESS_MAP_START( writeport_cpu3_gg, ADDRESS_SPACE_IO, 8 ) | |
| 626 | ||
| 627 | static ADDRESS_MAP_START( gg_cpu3_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 642 | 628 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 643 | 629 | AM_RANGE(0x00, 0x00) AM_WRITE(SMH_NOP) |
| 644 | 630 | AM_RANGE(0x01, 0x01) AM_WRITE(cfb_backgnd_color_w) |
| 645 | AM_RANGE(0x02, 0x02) AM_WRITE(cfb_led_w) | |
| 631 | AM_RANGE(0x02, 0x02) AM_READWRITE(cfb_port_02_r, cfb_led_w) /* Read = VCU status ? */ | |
| 646 | 632 | AM_RANGE(0x03, 0x03) AM_WRITE(cfb_zpu_int_req_set_w) |
| 647 | 633 | AM_RANGE(0x04, 0x04) AM_WRITE(cfb_rom_bank_sel_w_gg) |
| 648 | 634 | AM_RANGE(0x05, 0x05) AM_WRITE(cfb_vbank_w) //visible/writable videopage select? |
| 649 | 635 | ADDRESS_MAP_END |
| 650 | 636 | |
| 651 | 637 | |
| 652 | ||
| 653 | 638 | static UINT8 VCU_video_reg[4]; |
| 654 | 639 | static WRITE8_HANDLER( VCU_video_reg_w ) |
| 655 | 640 | { |
| r3232 | r3233 | |
| 1089 | 1074 | } |
| 1090 | 1075 | |
| 1091 | 1076 | |
| 1092 | static ADDRESS_MAP_START( gg_ | |
| 1077 | static ADDRESS_MAP_START( gg_io_ma | |
| 1093 | 1078 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 1094 | AM_RANGE(0x62, 0x62) AM_READ(zpu_inputs_r) | |
| 1095 | ADDRESS_MAP_END | |
| 1096 | static ADDRESS_MAP_START( gg_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1097 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1098 | 1079 | AM_RANGE(0x4c, 0x4c) AM_WRITE(main_sound_w) |
| 1099 | 1080 | AM_RANGE(0x60, 0x60) AM_WRITE(zpu_bcd_decoder_w) |
| 1081 | AM_RANGE(0x62, 0x62) AM_READ(zpu_inputs_r) | |
| 1100 | 1082 | AM_RANGE(0x66, 0x66) AM_WRITE(SMH_NOP) |
| 1101 | 1083 | AM_RANGE(0x68, 0x68) AM_WRITE(SMH_NOP) |
| 1102 | ||
| 1103 | 1084 | AM_RANGE(0x6e, 0x6f) AM_WRITE(zpu_led_w) |
| 1104 | 1085 | ADDRESS_MAP_END |
| 1105 | 1086 | |
| 1106 | 1087 | |
| 1107 | ||
| 1108 | ||
| 1109 | 1088 | /* frequency is 14.318 MHz/16/16/16/16 */ |
| 1110 | 1089 | static INTERRUPT_GEN( sound_interrupt ) |
| 1111 | 1090 | { |
| r3232 | r3233 | |
| 1495 | 1474 | /* basic machine hardware */ |
| 1496 | 1475 | MDRV_CPU_ADD("main", Z80, 4000000) /* 4 MHz, no NMI, IM2 - vectors at 0xf8, 0xfa, 0xfc */ |
| 1497 | 1476 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1498 | MDRV_CPU_IO_MAP( | |
| 1477 | MDRV_CPU_IO_MAP(io_ma | |
| 1499 | 1478 | |
| 1500 | 1479 | MDRV_CPU_ADD("sub", Z80, 4000000) /* 4 MHz, NMI, IM1 INT */ |
| 1501 | 1480 | MDRV_CPU_PROGRAM_MAP(readmem_cpu2,writemem_cpu2) |
| 1502 | MDRV_CPU_IO_MAP( | |
| 1481 | MDRV_CPU_IO_MAP( | |
| 1503 | 1482 | //MDRV_CPU_PERIODIC_INT(irq0_line_hold, 400 ) /* frequency in Hz */ |
| 1504 | 1483 | |
| 1505 | 1484 | MDRV_CPU_ADD("sub2", Z80, 4000000) /* 4 MHz, no NMI, IM1 INT */ |
| 1506 | 1485 | MDRV_CPU_PROGRAM_MAP(readmem_cpu3,writemem_cpu3) |
| 1507 | MDRV_CPU_IO_MAP( | |
| 1486 | MDRV_CPU_IO_MAP( | |
| 1508 | 1487 | /* (vblank related ??) int generated by a custom video processor |
| 1509 | 1488 | and cleared on ANY port access. |
| 1510 | 1489 | but handled differently for now |
| r3232 | r3233 | |
| 1538 | 1517 | /* basic machine hardware */ |
| 1539 | 1518 | MDRV_CPU_ADD("main", Z80, 4000000) /* 4 MHz, no NMI, IM2 - vectors at 0xf8, 0xfa, 0xfc */ |
| 1540 | 1519 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1541 | MDRV_CPU_IO_MAP(gg_ | |
| 1520 | MDRV_CPU_IO_MAP(gg_i | |
| 1542 | 1521 | |
| 1543 | 1522 | MDRV_CPU_ADD("sub", Z80, 14318000 / 4) /* 3.579500 MHz, NMI - caused by sound command write, periodic INT */ |
| 1544 | 1523 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| r3232 | r3233 | |
| 1546 | 1525 | |
| 1547 | 1526 | MDRV_CPU_ADD("sub2", Z80, 4000000) /* 4 MHz, no NMI, IM1 INT */ |
| 1548 | 1527 | MDRV_CPU_PROGRAM_MAP(readmem_cpu3,writemem_cpu3) |
| 1549 | MDRV_CPU_IO_MAP( | |
| 1528 | MDRV_CPU_IO_MAP(gg | |
| 1550 | 1529 | /* (vblank related ??) int generated by a custom video processor |
| 1551 | 1530 | and cleared on ANY port access. |
| 1552 | 1531 | but handled differently for now |
| r3232 | r3233 | |
| 1682 | 1661 | GAME( 1983, mazerbla, 0, mazerbla, mazerbla, 0, ROT0, "Stern", "Mazer Blazer (set 1)", GAME_IMPERFECT_GRAPHICS |GAME_NO_SOUND | GAME_NOT_WORKING ) |
| 1683 | 1662 | GAME( 1983, mzrblzra, mazerbla, mazerbla, mazerbla, 0, ROT0, "Stern", "Mazer Blazer (set 2)", GAME_IMPERFECT_GRAPHICS |GAME_NO_SOUND | GAME_NOT_WORKING ) |
| 1684 | 1663 | GAME( 1983, greatgun, 0, greatgun, greatgun, 0, ROT0, "Stern", "Great Guns", GAME_IMPERFECT_GRAPHICS ) |
| 1664 | ||
| 1665 |
| r3232 | r3233 | |
|---|---|---|
| 194 | 194 | |
| 195 | 195 | static READ16_HANDLER( analog_r ) |
| 196 | 196 | { |
| 197 | static const char *portnames[] = { "STICK0_X", "STICK1_X", "STICK0_Y", "STICK1_Y" }; | |
| 197 | static const char *const portnames[] = { "STICK0_X", "STICK1_X", "STICK0_Y", "STICK1_Y" }; | |
| 198 | 198 | |
| 199 | 199 | return input_port_read(machine, portnames[whichport]); |
| 200 | 200 | } |
| r3232 | r3233 | |
|---|---|---|
| 506 | 506 | int i; |
| 507 | 507 | UINT16 data; |
| 508 | 508 | UINT8 poll_coins; |
| 509 | static const char *portnames[] = { "P1", "P2", "P3", "P4" }; | |
| 509 | static const char *const portnames[] = { "P1", "P2", "P3", "P4" }; | |
| 510 | 510 | |
| 511 | 511 | namcona1_workram[0xf60/2] = 0x0000; /* mcu ready */ |
| 512 | 512 |
| r3232 | r3233 | |
|---|---|---|
| 360 | 360 | 06 blit_pen_mode (replace values stored in ROM) |
| 361 | 361 | */ |
| 362 | 362 | |
| 363 | static int blit_draw(int src,int sx) | |
| 363 | static int blit_draw(running_machine *machine, int src,int sx) | |
| 364 | 364 | { |
| 365 | UINT8 *src_data = memory_region(Machine, "gfx1"); | |
| 366 | int src_len = memory_region_length(Machine, "gfx1"); | |
| 365 | UINT8 *src_data = memory_region(machine, "gfx1"); | |
| 366 | int src_len = memory_region_length(machine, "gfx1"); | |
| 367 | 367 | int bit_addr = (src & 0xffffff) * ddenlovr_blit_rom_bits; /* convert to bit address */ |
| 368 | 368 | int pen_size, arg_size, cmd; |
| 369 | 369 | int x; |
| r3232 | r3233 | |
| 712 | 712 | case 0x14: blit_fill_xy(ddenlovr_blit_x, ddenlovr_blit_y); |
| 713 | 713 | break; |
| 714 | 714 | |
| 715 | case 0x10: ddenlovr_blit_address = blit_draw(ddenlovr_blit_address,ddenlovr_blit_x); | |
| 715 | case 0x10: ddenlovr_blit_address = blit_draw(machine,ddenlovr_blit_address,ddenlovr_blit_x); | |
| 716 | 716 | break; |
| 717 | 717 | |
| 718 | 718 | case 0x13: blit_horiz_line(); |
| r3232 | r3233 | |
| 879 | 879 | // case 0x14: blit_fill_xy(ddenlovr_blit_x, ddenlovr_blit_y); |
| 880 | 880 | // break; |
| 881 | 881 | |
| 882 | case 0x00/*0x10*/: ddenlovr_blit_address = blit_draw(ddenlovr_blit_address,ddenlovr_blit_x); | |
| 882 | case 0x00/*0x10*/: ddenlovr_blit_address = blit_draw(machine,ddenlovr_blit_address,ddenlovr_blit_x); | |
| 883 | 883 | break; |
| 884 | 884 | |
| 885 | 885 | case 0x0b: // same as 03? see the drawing of the R in "cRoss hatch" (key test) |
| r3232 | r3233 | |
| 1079 | 1079 | case 0x14: blit_fill_xy(ddenlovr_blit_x, ddenlovr_blit_y); |
| 1080 | 1080 | break; |
| 1081 | 1081 | |
| 1082 | case 0x10: ddenlovr_blit_address = blit_draw(ddenlovr_blit_address,ddenlovr_blit_x); | |
| 1082 | case 0x10: ddenlovr_blit_address = blit_draw(machine,ddenlovr_blit_address,ddenlovr_blit_x); | |
| 1083 | 1083 | break; |
| 1084 | 1084 | |
| 1085 | 1085 | case 0x13: blit_horiz_line(); |
| r3232 | r3233 | |
| 1232 | 1232 | ddenlovr_blit_pen_mode = 0; |
| 1233 | 1233 | ddenlovr_blit_y = 5; |
| 1234 | 1234 | ddenlovr_clip_ctrl = 0x0f; |
| 1235 | next = blit_draw(base,0); | |
| 1235 | next = blit_draw(screen->machine,base,0); | |
| 1236 | 1236 | popmessage("GFX %06x",base); |
| 1237 | 1237 | if (input_code_pressed(KEYCODE_S)) base = next; |
| 1238 | 1238 | if (input_code_pressed_once(KEYCODE_X)) base = next; |
| r3232 | r3233 | |
| 2495 | 2495 | |
| 2496 | 2496 | static UINT8 mjchuuka_romdata[2]; |
| 2497 | 2497 | |
| 2498 | static void mjchuuka_get_romdata( | |
| 2498 | static void mjchuuka_get_romdata(running_machine *machine) | |
| 2499 | 2499 | { |
| 2500 | UINT8 *rom = memory_region( Machine, "gfx1" ); | |
| 2501 | size_t size = memory_region_length( Machine, "gfx1" ); | |
| 2500 | UINT8 *rom = memory_region( machine, "gfx1" ); | |
| 2501 | size_t size = memory_region_length( machine, "gfx1" ); | |
| 2502 | 2502 | int address = (ddenlovr_blit_address & 0xffffff) * 2; |
| 2503 | 2503 | |
| 2504 | 2504 | if (address >= size) |
| r3232 | r3233 | |
| 2513 | 2513 | |
| 2514 | 2514 | static READ8_HANDLER( mjchuuka_gfxrom_0_r ) |
| 2515 | 2515 | { |
| 2516 | mjchuuka_get_romdata(); | |
| 2516 | mjchuuka_get_romdata(machine); | |
| 2517 | 2517 | ddenlovr_blit_address++; |
| 2518 | 2518 | return mjchuuka_romdata[0]; |
| 2519 | 2519 | } |
| r3232 | r3233 | |
| 2830 | 2830 | |
| 2831 | 2831 | static READ8_HANDLER( hginga_input_r ) |
| 2832 | 2832 | { |
| 2833 | static const char *keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 2834 | static const char *keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 2833 | static const char *const keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 2834 | static const char *const keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 2835 | 2835 | |
| 2836 | 2836 | switch( hginga_select ) |
| 2837 | 2837 | { |
| r3232 | r3233 | |
| 3043 | 3043 | |
| 3044 | 3044 | static READ8_HANDLER( hparadis_input_r ) |
| 3045 | 3045 | { |
| 3046 | static const char *keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 3047 | static const char *keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 3046 | static const char *const keynames0[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 3047 | static const char *const keynames1[] = { "KEY5", "KEY6", "KEY7", "KEY8", "KEY9" }; | |
| 3048 | 3048 | |
| 3049 | 3049 | switch (hginga_select) |
| 3050 | 3050 | { |
| r3232 | r3233 | |
|---|---|---|
| 949 | 949 | /* IC8, Inputs, TRIACS, alpha clock */ |
| 950 | 950 | static READ8_HANDLER( pia_ic8_porta_r ) |
| 951 | 951 | { |
| 952 | static const char *portnames[] = { "ORANGE1", "ORANGE2", "BLACK1", "BLACK2", "ORANGE1", "ORANGE2", "DIL1", "DIL2" }; | |
| 952 | static const char *const portnames[] = { "ORANGE1", "ORANGE2", "BLACK1", "BLACK2", "ORANGE1", "ORANGE2", "DIL1", "DIL2" }; | |
| 953 | 953 | |
| 954 | 954 | LOG_IC8(("%04x IC8 PIA Read of Port A (MUX input data)\n", activecpu_get_previouspc())); |
| 955 | 955 | /* The orange inputs are polled twice as often as the black ones, for reasons of efficiency. |
| r3232 | r3233 | |
| 1421 | 1421 | MDRV_CPU_ADD("main", M6809, MPU4_MASTER_CLOCK/4) |
| 1422 | 1422 | MDRV_CPU_PROGRAM_MAP(mod2_memmap,0) |
| 1423 | 1423 | |
| 1424 | MDRV_TIMER_ADD_PERIODIC("50 | |
| 1424 | MDRV_TIMER_ADD_PERIODIC("50hz",gen_50hz, HZ(100)) | |
| 1425 | 1425 | |
| 1426 | 1426 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 1427 | MDRV_SOUND_ADD(" | |
| 1427 | MDRV_SOUND_ADD("ay8913",AY8913, MPU4_MASTER_CLOCK/4) | |
| 1428 | 1428 | MDRV_SOUND_CONFIG(ay8910_config) |
| 1429 | 1429 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 1430 | 1430 |
| r3232 | r3233 | |
|---|---|---|
| 24 | 24 | */ |
| 25 | 25 | |
| 26 | 26 | #include "driver.h" |
| 27 | #include "machine/eeprom.h" | |
| 27 | 28 | #include "sound/okim6295.h" |
| 28 | #include "machine/eeprom.h" | |
| 29 | 29 | |
| 30 | 30 | static tilemap *bg_tilemap, *md_tilemap, *fg_tilemap; |
| 31 | 31 | static UINT32 *bg_videoram, *md_videoram, *fg_videoram, *limenko_videoreg; |
| 32 | 32 | |
| 33 | 33 | static UINT32 *mainram; |
| 34 | static int spriteram_bit; | |
| 34 | 35 | |
| 36 | static bitmap_t *sprites_bitmap; | |
| 37 | static bitmap_t *sprites_bitmap_pri; | |
| 38 | ||
| 39 | static int prev_sprites_count = 0; | |
| 40 | ||
| 41 | static void draw_sprites(running_machine *machine, UINT32 *sprites, const rectangle *cliprect, int count); | |
| 42 | ||
| 35 | 43 | /***************************************************************************************************** |
| 36 | 44 | MISC FUNCTIONS |
| 37 | 45 | *****************************************************************************************************/ |
| r3232 | r3233 | |
| 91 | 99 | soundlatch_w(machine, 0, (data >> 16) & 0xff); |
| 92 | 100 | } |
| 93 | 101 | |
| 102 | static CUSTOM_INPUT( spriteram_bit_r ) | |
| 103 | { | |
| 104 | return spriteram_bit; | |
| 105 | } | |
| 106 | ||
| 107 | static WRITE32_HANDLER( spriteram_buffer_w ) | |
| 108 | { | |
| 109 | rectangle clip; | |
| 110 | clip.min_x = 0; | |
| 111 | clip.max_x = 383; | |
| 112 | clip.min_y = 0; | |
| 113 | clip.max_y = 239; | |
| 114 | ||
| 115 | fillbitmap(sprites_bitmap_pri,0,&clip); | |
| 116 | fillbitmap(sprites_bitmap,0,&clip); | |
| 117 | ||
| 118 | // toggle spriterams location in the memory map | |
| 119 | spriteram_bit ^= 1; | |
| 120 | ||
| 121 | if(spriteram_bit) | |
| 122 | { | |
| 123 | // draw the sprites to the frame buffer | |
| 124 | draw_sprites(machine,spriteram32_2,&clip,prev_sprites_count); | |
| 125 | } | |
| 126 | else | |
| 127 | { | |
| 128 | // draw the sprites to the frame buffer | |
| 129 | draw_sprites(machine,spriteram32,&clip,prev_sprites_count); | |
| 130 | } | |
| 131 | ||
| 132 | // buffer the next number of sprites to draw | |
| 133 | prev_sprites_count = (limenko_videoreg[0] & 0x1ff0000) >> 16; | |
| 134 | } | |
| 135 | ||
| 94 | 136 | /***************************************************************************************************** |
| 95 | 137 | MEMORY MAPS |
| 96 | 138 | *****************************************************************************************************/ |
| r3232 | r3233 | |
| 101 | 143 | AM_RANGE(0x80000000, 0x80007fff) AM_RAM_WRITE(fg_videoram_w) AM_BASE(&fg_videoram) |
| 102 | 144 | AM_RANGE(0x80008000, 0x8000ffff) AM_RAM_WRITE(md_videoram_w) AM_BASE(&md_videoram) |
| 103 | 145 | AM_RANGE(0x80010000, 0x80017fff) AM_RAM_WRITE(bg_videoram_w) AM_BASE(&bg_videoram) |
| 104 | AM_RANGE(0x80018000, 0x80018fff) AM_RAM AM_BASE(&spriteram32) | |
| 146 | AM_RANGE(0x80018000, 0x80018fff) AM_RAM AM_BASE(&spriteram32) AM_SIZE(&spriteram_size) | |
| 105 | 147 | AM_RANGE(0x80019000, 0x80019fff) AM_RAM AM_BASE(&spriteram32_2) |
| 106 | 148 | AM_RANGE(0x8001c000, 0x8001dfff) AM_RAM_WRITE(limenko_paletteram_w) AM_BASE(&paletteram32) |
| 107 | 149 | AM_RANGE(0x8001e000, 0x8001ebff) AM_RAM // ? not used |
| 108 | 150 | AM_RANGE(0x8001ffec, 0x8001ffff) AM_RAM AM_BASE(&limenko_videoreg) |
| 109 | AM_RANGE(0x8003e000, 0x8003e003) AM_WRITE | |
| 151 | AM_RANGE(0x8003e000, 0x8003e003) AM_WRITE(spr | |
| 110 | 152 | AM_RANGE(0xffe00000, 0xffffffff) AM_ROM AM_REGION("user1",0) |
| 111 | 153 | ADDRESS_MAP_END |
| 112 | 154 | |
| r3232 | r3233 | |
| 128 | 170 | AM_RANGE(0x80000000, 0x80007fff) AM_RAM_WRITE(fg_videoram_w) AM_BASE(&fg_videoram) |
| 129 | 171 | AM_RANGE(0x80008000, 0x8000ffff) AM_RAM_WRITE(md_videoram_w) AM_BASE(&md_videoram) |
| 130 | 172 | AM_RANGE(0x80010000, 0x80017fff) AM_RAM_WRITE(bg_videoram_w) AM_BASE(&bg_videoram) |
| 131 | AM_RANGE(0x80018000, 0x80018fff) AM_RAM AM_BASE(&spriteram32) | |
| 173 | AM_RANGE(0x80018000, 0x80018fff) AM_RAM AM_BASE(&spriteram32) AM_SIZE(&spriteram_size) | |
| 132 | 174 | AM_RANGE(0x80019000, 0x80019fff) AM_RAM AM_BASE(&spriteram32_2) |
| 133 | 175 | AM_RANGE(0x8001c000, 0x8001dfff) AM_RAM_WRITE(limenko_paletteram_w) AM_BASE(&paletteram32) |
| 134 | 176 | AM_RANGE(0x8001e000, 0x8001ebff) AM_RAM // ? not used |
| 135 | 177 | AM_RANGE(0x8001ffec, 0x8001ffff) AM_RAM AM_BASE(&limenko_videoreg) |
| 136 | AM_RANGE(0x8003e000, 0x8003e003) AM_WRITE | |
| 178 | AM_RANGE(0x8003e000, 0x8003e003) AM_WRITE(spr | |
| 137 | 179 | AM_RANGE(0xfff00000, 0xffffffff) AM_ROM AM_REGION("user1",0) |
| 138 | 180 | ADDRESS_MAP_END |
| 139 | 181 | |
| r3232 | r3233 | |
| 150 | 192 | AM_RANGE(0x0000, 0x0fff) AM_ROM |
| 151 | 193 | ADDRESS_MAP_END |
| 152 | 194 | |
| 195 | static UINT8 spotty_sound_cmd=0; | |
| 196 | static WRITE8_HANDLER( spotty_sound_cmd_w ) | |
| 197 | { | |
| 198 | spotty_sound_cmd = data; | |
| 199 | } | |
| 200 | ||
| 201 | static READ8_HANDLER( spotty_sound_cmd_r ) | |
| 202 | { | |
| 203 | return 0; //??? some status bit? if set it executes a jump in the code | |
| 204 | } | |
| 205 | ||
| 206 | static READ8_HANDLER( spotty_sound_r ) | |
| 207 | { | |
| 208 | // check spotty_sound_cmd bits... | |
| 209 | ||
| 210 | if(spotty_sound_cmd == 0xf7) | |
| 211 | return soundlatch_r(machine,0); | |
| 212 | else | |
| 213 | return okim6295_status_0_r(machine,0); | |
| 214 | } | |
| 215 | ||
| 153 | 216 | static ADDRESS_MAP_START( spotty_sound_io_map, ADDRESS_SPACE_IO, 8 ) |
| 154 | AM_RANGE(0x0001, 0x0001) AM_READ(soundlatch_r) | |
| 155 | AM_RANGE(0x0003, 0x0003) AM_READ(okim6295_status_0_r) | |
| 156 | AM_RANGE(0x0001, 0x0001) AM_WRITE(okim6295_data_0_w) | |
| 157 | AM_RANGE(0x0003, 0x0003) AM_WRITENOP | |
| 217 | AM_RANGE(0x0001, 0x0001) AM_READWRITE(spotty_sound_r, okim6295_data_0_w) //? sound latch and ? | |
| 218 | AM_RANGE(0x0003, 0x0003) AM_READWRITE(spotty_sound_cmd_r, spotty_sound_cmd_w) //not sure about anything... | |
| 158 | 219 | ADDRESS_MAP_END |
| 159 | 220 | |
| 160 | 221 | /***************************************************************************************************** |
| r3232 | r3233 | |
| 182 | 243 | SET_TILE_INFO(0,tile,color,0); |
| 183 | 244 | } |
| 184 | 245 | |
| 246 | static void draw_single_sprite(bitmap_t *dest_bmp,const gfx_element *gfx, | |
| 247 | UINT32 code,UINT32 color,int flipx,int flipy,int sx,int sy, | |
| 248 | const rectangle *clip,int priority) | |
| 249 | { | |
| 250 | int pal_base = gfx->color_base + gfx->color_granularity * (color % gfx->total_colors); | |
| 251 | UINT8 *source_base = gfx->gfxdata + (code % gfx->total_elements) * gfx->char_modulo; | |
| 252 | ||
| 253 | int sprite_screen_height = ((1<<16)*gfx->height+0x8000)>>16; | |
| 254 | int sprite_screen_width = ((1<<16)*gfx->width+0x8000)>>16; | |
| 255 | ||
| 256 | if (sprite_screen_width && sprite_screen_height) | |
| 257 | { | |
| 258 | /* compute sprite increment per screen pixel */ | |
| 259 | int dx = (gfx->width<<16)/sprite_screen_width; | |
| 260 | int dy = (gfx->height<<16)/sprite_screen_height; | |
| 261 | ||
| 262 | int ex = sx+sprite_screen_width; | |
| 263 | int ey = sy+sprite_screen_height; | |
| 264 | ||
| 265 | int x_index_base; | |
| 266 | int y_index; | |
| 267 | ||
| 268 | if( flipx ) | |
| 269 | { | |
| 270 | x_index_base = (sprite_screen_width-1)*dx; | |
| 271 | dx = -dx; | |
| 272 | } | |
| 273 | else | |
| 274 | { | |
| 275 | x_index_base = 0; | |
| 276 | } | |
| 277 | ||
| 278 | if( flipy ) | |
| 279 | { | |
| 280 | y_index = (sprite_screen_height-1)*dy; | |
| 281 | dy = -dy; | |
| 282 | } | |
| 283 | else | |
| 284 | { | |
| 285 | y_index = 0; | |
| 286 | } | |
| 287 | ||
| 288 | if( clip ) | |
| 289 | { | |
| 290 | if( sx < clip->min_x) | |
| 291 | { /* clip left */ | |
| 292 | int pixels = clip->min_x-sx; | |
| 293 | sx += pixels; | |
| 294 | x_index_base += pixels*dx; | |
| 295 | } | |
| 296 | if( sy < clip->min_y ) | |
| 297 | { /* clip top */ | |
| 298 | int pixels = clip->min_y-sy; | |
| 299 | sy += pixels; | |
| 300 | y_index += pixels*dy; | |
| 301 | } | |
| 302 | /* NS 980211 - fixed incorrect clipping */ | |
| 303 | if( ex > clip->max_x+1 ) | |
| 304 | { /* clip right */ | |
| 305 | int pixels = ex-clip->max_x-1; | |
| 306 | ex -= pixels; | |
| 307 | } | |
| 308 | if( ey > clip->max_y+1 ) | |
| 309 | { /* clip bottom */ | |
| 310 | int pixels = ey-clip->max_y-1; | |
| 311 | ey -= pixels; | |
| 312 | } | |
| 313 | } | |
| 314 | ||
| 315 | if( ex>sx ) | |
| 316 | { /* skip if inner loop doesn't draw anything */ | |
| 317 | int y; | |
| 318 | ||
| 319 | for( y=sy; y<ey; y++ ) | |
| 320 | { | |
| 321 | UINT8 *source = source_base + (y_index>>16) * gfx->line_modulo; | |
| 322 | UINT16 *dest = BITMAP_ADDR16(dest_bmp, y, 0); | |
| 323 | UINT8 *pri = BITMAP_ADDR8(sprites_bitmap_pri, y, 0); | |
| 324 | ||
| 325 | int x, x_index = x_index_base; | |
| 326 | for( x=sx; x<ex; x++ ) | |
| 327 | { | |
| 328 | int c = source[x_index>>16]; | |
| 329 | if( c != 0 ) | |
| 330 | { | |
| 331 | if (pri[x]<priority) | |
| 332 | dest[x] = pal_base+c; | |
| 333 | ||
| 334 | pri[x] = priority; | |
| 335 | ||
| 336 | } | |
| 337 | x_index += dx; | |
| 338 | } | |
| 339 | ||
| 340 | y_index += dy; | |
| 341 | } | |
| 342 | } | |
| 343 | } | |
| 344 | } | |
| 345 | ||
| 185 | 346 | // sprites aren't tile based (except for 8x8 ones) |
| 186 | static void draw_sprites(running_machine *machine, | |
| 347 | static void draw_sprites(running_machine *machine, UINT32 | |
| 187 | 348 | { |
| 188 | 349 | int i; |
| 189 | int sprites_on_screen = (limenko_videoreg[0] & 0x1ff0000) >> 16; | |
| 190 | 350 | |
| 191 | 351 | UINT8 *base_gfx = memory_region(machine, "gfx1"); |
| 192 | 352 | UINT8 *gfx_max = base_gfx + memory_region_length(machine, "gfx1"); |
| r3232 | r3233 | |
| 194 | 354 | UINT8 *gfxdata; |
| 195 | 355 | gfx_element gfx; |
| 196 | 356 | |
| 197 | for(i = 0; i <= | |
| 357 | for(i = 0; i <= c | |
| 198 | 358 | { |
| 199 | 359 | int x, width, flipx, y, height, flipy, code, color, pri; |
| 200 | 360 | |
| 201 | if(~sprite | |
| 361 | if(~sprites | |
| 202 | 362 | |
| 203 | x = ((spriteram32[i] & 0x1ff0000) >> 16) - 1; | |
| 204 | width = (((spriteram32[i] & 0xe000000) >> 25) + 1) * 8; | |
| 205 | flipx = spriteram32[i] & 0x10000000; | |
| 206 | y = (spriteram32[i] & 0x1ff) + 1; | |
| 207 | height = (((spriteram32[i] & 0xe00) >> 9) + 1) * 8; | |
| 208 | flipy = spriteram32[i] & 0x1000; | |
| 209 | code = spriteram32[i + 1] & 0x7ffff; | |
| 210 | color = (spriteram32[i + 1] & 0xf0000000) >> 28; | |
| 363 | x = ((sprites[i] & 0x1ff0000) >> 16); | |
| 364 | width = (((sprites[i] & 0xe000000) >> 25) + 1) * 8; | |
| 365 | flipx = sprites[i] & 0x10000000; | |
| 366 | y = sprites[i] & 0x1ff; | |
| 367 | height = (((sprites[i] & 0xe00) >> 9) + 1) * 8; | |
| 368 | flipy = sprites[i] & 0x1000; | |
| 369 | code = sprites[i + 1] & 0x7ffff; | |
| 370 | color = (sprites[i + 1] & 0xf0000000) >> 28; | |
| 211 | 371 | |
| 212 | if(spriteram32[i + 1] & 0x04000000) | |
| 213 | pri = 0xfffe; // below fg | |
| 372 | if(sprites[i + 1] & 0x04000000) | |
| 373 | { | |
| 374 | // below fg | |
| 375 | pri = 1; | |
| 376 | } | |
| 214 | 377 | else |
| 215 | pri = 0; // above everything | |
| 378 | { | |
| 379 | // above everything | |
| 380 | pri = 2; | |
| 381 | } | |
| 216 | 382 | |
| 217 | gfxdata = base_gfx + | |
| 383 | gfxdata = base_gfx + | |
| 218 | 384 | |
| 219 | 385 | /* prepare GfxElement on the fly */ |
| 220 | 386 | gfx.width = width; |
| r3232 | r3233 | |
| 234 | 400 | if ( (gfxdata + width * height - 1) >= gfx_max ) |
| 235 | 401 | continue; |
| 236 | 402 | |
| 237 | pdrawgfx(bitmap,&gfx, | |
| 238 | 0, | |
| 239 | color, | |
| 240 | flipx,flipy, | |
| 241 | x,y, | |
| 242 | cliprect,TRANSPARENCY_PEN,0,pri); | |
| 403 | draw_single_sprite(sprites_bitmap,&gfx,0,color,flipx,flipy,x,y,cliprect,pri); | |
| 243 | 404 | |
| 405 | // wrap around x | |
| 406 | draw_single_sprite(sprites_bitmap,&gfx,0,color,flipx,flipy,x-512,y,cliprect,pri); | |
| 407 | ||
| 244 | 408 | // wrap around y |
| 245 | pdrawgfx(bitmap,&gfx, | |
| 246 | 0, | |
| 247 | color, | |
| 248 | flipx,flipy, | |
| 249 | x,y - 512, | |
| 250 | cliprect,TRANSPARENCY_PEN,0,pri); | |
| 409 | draw_single_sprite(sprites_bitmap,&gfx,0,color,flipx,flipy,x,y-512,cliprect,pri); | |
| 251 | 410 | |
| 252 | // wrap around x | |
| 253 | pdrawgfx(bitmap,&gfx, | |
| 254 | 0, | |
| 255 | color, | |
| 256 | flipx,flipy, | |
| 257 | x - 512,y, | |
| 258 | cliprect,TRANSPARENCY_PEN,0,pri); | |
| 259 | ||
| 260 | 411 | // wrap around x and y |
| 261 | pdrawgfx(bitmap,&gfx, | |
| 262 | 0, | |
| 263 | color, | |
| 264 | flipx,flipy, | |
| 265 | x - 512,y - 512, | |
| 266 | cliprect,TRANSPARENCY_PEN,0,pri); | |
| 412 | draw_single_sprite(sprites_bitmap,&gfx,0,color,flipx,flipy,x-512,y-512,cliprect,pri); | |
| 267 | 413 | } |
| 268 | 414 | } |
| 269 | 415 | |
| 416 | static void copy_sprites(running_machine *machine, bitmap_t *bitmap, bitmap_t *sprites_bitmap, const rectangle *cliprect) | |
| 417 | { | |
| 418 | int y; | |
| 419 | for( y=cliprect->min_y; y<=cliprect->max_y; y++ ) | |
| 420 | { | |
| 421 | UINT16 *source = BITMAP_ADDR16(sprites_bitmap, y, 0); | |
| 422 | UINT16 *dest = BITMAP_ADDR16(bitmap, y, 0); | |
| 423 | UINT8 *dest_pri = BITMAP_ADDR8(priority_bitmap, y, 0); | |
| 424 | UINT8 *source_pri = BITMAP_ADDR8(sprites_bitmap_pri, y, 0); | |
| 425 | ||
| 426 | int x; | |
| 427 | for( x=cliprect->min_x; x<=cliprect->max_x; x++ ) | |
| 428 | { | |
| 429 | if( source[x]!= 0 ) | |
| 430 | { | |
| 431 | if(dest_pri[x] < source_pri[x]) | |
| 432 | dest[x] = source[x]; | |
| 433 | } | |
| 434 | } | |
| 435 | } | |
| 436 | } | |
| 437 | ||
| 270 | 438 | static VIDEO_START( limenko ) |
| 271 | 439 | { |
| 272 | 440 | bg_tilemap = tilemap_create(get_bg_tile_info,tilemap_scan_rows,8,8,128,64); |
| r3232 | r3233 | |
| 275 | 443 | |
| 276 | 444 | tilemap_set_transparent_pen(md_tilemap,0); |
| 277 | 445 | tilemap_set_transparent_pen(fg_tilemap,0); |
| 446 | ||
| 447 | sprites_bitmap = auto_bitmap_alloc(384,240,BITMAP_FORMAT_INDEXED16); | |
| 448 | sprites_bitmap_pri = auto_bitmap_alloc(384,240,BITMAP_FORMAT_INDEXED8); | |
| 278 | 449 | } |
| 279 | 450 | |
| 280 | 451 | static VIDEO_UPDATE( limenko ) |
| 281 | 452 | { |
| 453 | // limenko_videoreg[4] ???? It always has this value: 0xffeffff8 (2 signed bytes? values: -17 and -8 ?) | |
| 454 | ||
| 282 | 455 | fillbitmap(priority_bitmap,0,cliprect); |
| 283 | 456 | |
| 284 | 457 | tilemap_set_enable(bg_tilemap, limenko_videoreg[0] & 4); |
| r3232 | r3233 | |
| 298 | 471 | tilemap_draw(bitmap,cliprect,fg_tilemap,0,1); |
| 299 | 472 | |
| 300 | 473 | if(limenko_videoreg[0] & 8) |
| 301 | | |
| 474 | copy_sprites(screen->machine, bitmap, sprites_bitmap, cliprect); | |
| 302 | 475 | |
| 303 | 476 | return 0; |
| 304 | 477 | } |
| r3232 | r3233 | |
| 363 | 536 | PORT_DIPNAME( 0x20000000, 0x00000000, "Sound Enable" ) |
| 364 | 537 | PORT_DIPSETTING( 0x20000000, DEF_STR( Off ) ) |
| 365 | 538 | PORT_DIPSETTING( 0x00000000, DEF_STR( On ) ) |
| 366 | PORT_BIT( 0x80000000, IP_ACTIVE_HIGH, IPT_SPECIAL ) //changes spriteram location | |
| 539 | PORT_BIT( 0x80000000, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(spriteram_bit_r, NULL) //changes spriteram location | |
| 367 | 540 | PORT_BIT( 0x4000ffff, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 368 | 541 | INPUT_PORTS_END |
| 369 | 542 | |
| r3232 | r3233 | |
| 401 | 574 | PORT_DIPNAME( 0x20000000, 0x00000000, "Sound Enable" ) |
| 402 | 575 | PORT_DIPSETTING( 0x20000000, DEF_STR( Off ) ) |
| 403 | 576 | PORT_DIPSETTING( 0x00000000, DEF_STR( On ) ) |
| 404 | PORT_BIT( 0x80000000, IP_ACTIVE_ | |
| 577 | PORT_BIT( 0x80000000, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(spriteram_bit_r, NULL) //changes spriteram location | |
| 405 | 578 | PORT_BIT( 0x5f10ffff, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 406 | 579 | INPUT_PORTS_END |
| 407 | 580 | |
| r3232 | r3233 | |
| 432 | 605 | PORT_BIT( 0x00010000, IP_ACTIVE_LOW, IPT_START1 ) |
| 433 | 606 | PORT_BIT( 0x00020000, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 434 | 607 | PORT_BIT( 0x00040000, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 435 | PORT_BIT( 0x00080000, IP_ACTIVE_ | |
| 608 | PORT_BIT( 0x00080000, IP_ACTIVE_HIGH, IPT_ | |
| 436 | 609 | PORT_SERVICE_NO_TOGGLE( 0x00200000, IP_ACTIVE_LOW ) |
| 437 | PORT_BIT( 0x00400000, IP_ACTIVE_LOW, IPT_ | |
| 610 | PORT_BIT( 0x00400000, IP_ACTIVE_LOW, IPT_ | |
| 438 | 611 | PORT_BIT( 0x00800000, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(eeprom_bit_r, NULL) //eeprom |
| 439 | 612 | PORT_DIPNAME( 0x20000000, 0x20000000, DEF_STR( Demo_Sounds ) ) |
| 440 | 613 | PORT_DIPSETTING( 0x00000000, DEF_STR( Off ) ) |
| r3232 | r3233 | |
| 840 | 1013 | static DRIVER_INIT( dynabomb ) |
| 841 | 1014 | { |
| 842 | 1015 | memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xe2784, 0xe2787, 0, 0, dynabomb_speedup_r ); |
| 1016 | ||
| 1017 | spriteram_bit = 1; | |
| 843 | 1018 | } |
| 844 | 1019 | |
| 845 | 1020 | static DRIVER_INIT( legendoh ) |
| 846 | 1021 | { |
| 847 | 1022 | memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x32ab0, 0x32ab3, 0, 0, legendoh_speedup_r ); |
| 1023 | ||
| 1024 | spriteram_bit = 1; | |
| 848 | 1025 | } |
| 849 | 1026 | |
| 850 | 1027 | static DRIVER_INIT( sb2003 ) |
| 851 | 1028 | { |
| 852 | 1029 | memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x135800, 0x135803, 0, 0, sb2003_speedup_r ); |
| 1030 | ||
| 1031 | spriteram_bit = 1; | |
| 853 | 1032 | } |
| 854 | 1033 | |
| 855 | 1034 | static DRIVER_INIT( spotty ) |
| r3232 | r3233 | |
| 868 | 1047 | } |
| 869 | 1048 | |
| 870 | 1049 | memory_install_read32_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x6626c, 0x6626f, 0, 0, spotty_speedup_r ); |
| 1050 | ||
| 1051 | spriteram_bit = 1; | |
| 871 | 1052 | } |
| 872 | 1053 | |
| 873 | 1054 | GAME( 2000, dynabomb, 0, limenko, sb2003, dynabomb, ROT0, "Limenko", "Dynamite Bomber (Korea, Rev 1.5)", GAME_NO_SOUND ) |
| r3232 | r3233 | |
| 876 | 1057 | GAME( 2003, sb2003a, sb2003, limenko, sb2003, sb2003, ROT0, "Limenko", "Super Bubble 2003 (Asia, Ver 1.0)", GAME_NO_SOUND ) |
| 877 | 1058 | |
| 878 | 1059 | // this game only use the same graphics chip used in limenko's system |
| 879 | GAME( 2001, spotty, 0, spotty, spotty, spotty, ROT0, "Prince Co.", "Spotty (Ver. 2.0.2)", | |
| 1060 | GAME( 2001, spotty, 0, spotty, spotty, spotty, ROT0, "Prince Co.", "Spotty (Ver. 2.0.2)", |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | |
| 23 | 23 | extern UINT16 *prehisle_bg_videoram16; |
| 24 | 24 | |
| 25 | static UINT16 *prehisle_ram16; | |
| 26 | ||
| 27 | 25 | /******************************************************************************/ |
| 28 | 26 | |
| 29 | 27 | static WRITE16_HANDLER( prehisle_sound16_w ) |
| r3232 | r3233 | |
| 34 | 32 | |
| 35 | 33 | /*******************************************************************************/ |
| 36 | 34 | |
| 37 | static ADDRESS_MAP_START( prehisle_readmem, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 38 | AM_RANGE(0x000000, 0x03ffff) AM_READ(SMH_ROM) | |
| 39 | AM_RANGE(0x070000, 0x073fff) AM_READ(SMH_RAM) | |
| 40 | AM_RANGE(0x090000, 0x0907ff) AM_READ(SMH_RAM) | |
| 41 | AM_RANGE(0x0a0000, 0x0a07ff) AM_READ(SMH_RAM) | |
| 42 | AM_RANGE(0x0b0000, 0x0b3fff) AM_READ(SMH_RAM) | |
| 43 | AM_RANGE(0x0d0000, 0x0d07ff) AM_READ(SMH_RAM) | |
| 35 | static ADDRESS_MAP_START( prehisle_map, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 36 | AM_RANGE(0x000000, 0x03ffff) AM_ROM | |
| 37 | AM_RANGE(0x070000, 0x073fff) AM_RAM | |
| 38 | AM_RANGE(0x090000, 0x0907ff) AM_RAM_WRITE(prehisle_fg_videoram16_w) AM_BASE(&videoram16) | |
| 39 | AM_RANGE(0x0a0000, 0x0a07ff) AM_RAM AM_BASE(&spriteram16) | |
| 40 | AM_RANGE(0x0b0000, 0x0b3fff) AM_RAM_WRITE(prehisle_bg_videoram16_w) AM_BASE(&prehisle_bg_videoram16) | |
| 41 | AM_RANGE(0x0d0000, 0x0d07ff) AM_RAM_WRITE(paletteram16_RRRRGGGGBBBBxxxx_word_w) AM_BASE(&paletteram16) | |
| 44 | 42 | AM_RANGE(0x0e0000, 0x0e00ff) AM_READ(prehisle_control16_r) |
| 45 | ADDRESS_MAP_END | |
| 46 | ||
| 47 | static ADDRESS_MAP_START( prehisle_writemem, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 48 | AM_RANGE(0x000000, 0x03ffff) AM_WRITE(SMH_ROM) | |
| 49 | AM_RANGE(0x070000, 0x073fff) AM_WRITE(SMH_RAM) AM_BASE(&prehisle_ram16) | |
| 50 | AM_RANGE(0x090000, 0x0907ff) AM_WRITE(prehisle_fg_videoram16_w) AM_BASE(&videoram16) | |
| 51 | AM_RANGE(0x0a0000, 0x0a07ff) AM_WRITE(SMH_RAM) AM_BASE(&spriteram16) | |
| 52 | AM_RANGE(0x0b0000, 0x0b3fff) AM_WRITE(prehisle_bg_videoram16_w) AM_BASE(&prehisle_bg_videoram16) | |
| 53 | AM_RANGE(0x0d0000, 0x0d07ff) AM_WRITE(paletteram16_RRRRGGGGBBBBxxxx_word_w) AM_BASE(&paletteram16) | |
| 54 | 43 | AM_RANGE(0x0f0070, 0x0ff071) AM_WRITE(prehisle_sound16_w) |
| 55 | 44 | AM_RANGE(0x0f0000, 0x0ff0ff) AM_WRITE(prehisle_control16_w) |
| 56 | 45 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 64 | 53 | upd7759_start_w (0,1); |
| 65 | 54 | } |
| 66 | 55 | |
| 67 | static ADDRESS_MAP_START( prehisle_sound_readmem, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 68 | AM_RANGE(0x0000, 0xefff) AM_READ(SMH_ROM) | |
| 69 | AM_RANGE(0xf000, 0xf7ff) AM_READ(SMH_RAM) | |
| 56 | static ADDRESS_MAP_START( prehisle_sound_map, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 57 | AM_RANGE(0x0000, 0xefff) AM_ROM | |
| 58 | AM_RANGE(0xf000, 0xf7ff) AM_RAM | |
| 70 | 59 | AM_RANGE(0xf800, 0xf800) AM_READ(soundlatch_r) |
| 60 | AM_RANGE(0xf800, 0xf800) AM_WRITENOP // ??? | |
| 71 | 61 | ADDRESS_MAP_END |
| 72 | 62 | |
| 73 | static ADDRESS_MAP_START( prehisle_sound_writemem, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 74 | AM_RANGE(0x0000, 0xefff) AM_WRITE(SMH_ROM) | |
| 75 | AM_RANGE(0xf000, 0xf7ff) AM_WRITE(SMH_RAM) | |
| 76 | AM_RANGE(0xf800, 0xf800) AM_WRITE(SMH_NOP) // ??? | |
| 77 | ADDRESS_MAP_END | |
| 78 | ||
| 79 | 63 | static ADDRESS_MAP_START( prehisle_sound_io_map, ADDRESS_SPACE_IO, 8 ) |
| 80 | 64 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 81 | 65 | AM_RANGE(0x00, 0x00) AM_READWRITE(ym3812_status_port_0_r, ym3812_control_port_0_w) |
| r3232 | r3233 | |
| 225 | 209 | |
| 226 | 210 | /* basic machine hardware */ |
| 227 | 211 | MDRV_CPU_ADD("main", M68000, XTAL_18MHz/2) /* verified on pcb */ |
| 228 | MDRV_CPU_PROGRAM_MAP(prehisle_ | |
| 212 | MDRV_CPU_PROGRAM_MAP(prehisle_ | |
| 229 | 213 | MDRV_CPU_VBLANK_INT("main", irq4_line_hold) |
| 230 | 214 | |
| 231 | 215 | MDRV_CPU_ADD("audio", Z80, XTAL_4MHz) /* verified on pcb */ |
| 232 | MDRV_CPU_PROGRAM_MAP(prehisle_sound_ | |
| 216 | MDRV_CPU_PROGRAM_MAP(prehisle_sound_ | |
| 233 | 217 | MDRV_CPU_IO_MAP(prehisle_sound_io_map,0) |
| 234 | 218 | |
| 235 | 219 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 642 | 642 | |
| 643 | 643 | static READ16_HANDLER( io_r ) |
| 644 | 644 | { |
| 645 | static const char *analognames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 646 | static const char *inputnames[] = { "IN0", "IN1", "IN2" }; | |
| 645 | static const char *const analognames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 646 | static const char *const inputnames[] = { "IN0", "IN1", "IN2" }; | |
| 647 | 647 | |
| 648 | 648 | if(offset < 0x8) |
| 649 | 649 | return input_port_read_safe(machine, analognames[offset], 0x00); |
| r3232 | r3233 | |
|---|---|---|
| 2160 | 2160 | MDRV_WATCHDOG_TIME_INIT(UINT64_ATTOTIME_IN_USEC(255000000 / (MW8080BW_PIXEL_CLOCK / MW8080BW_HTOTAL / MW8080BW_VTOTAL))) |
| 2161 | 2161 | |
| 2162 | 2162 | /* timers */ |
| 2163 | MDRV_TIMER_ADD_PERIODIC(" | |
| 2163 | MDRV_TIMER_ADD_PERIODIC("strobeon | |
| 2164 | 2164 | MDRV_TIMER_PARAM(TRUE) /* indicates strobe ON */ |
| 2165 | 2165 | |
| 2166 | MDRV_TIMER_ADD_PERIODIC(" | |
| 2166 | MDRV_TIMER_ADD_PERIODIC("strobeoff | |
| 2167 | 2167 | MDRV_TIMER_START_DELAY(HZ(SPCENCTR_STROBE_FREQ * 100 / SPCENCTR_STROBE_DUTY_CYCLE)) |
| 2168 | 2168 | MDRV_TIMER_PARAM(FALSE) /* indicates strobe OFF */ |
| 2169 | 2169 |
| r3232 | r3233 | |
|---|---|---|
| 554 | 554 | AM_RANGE(0xe000, 0xffff) AM_WRITE(suna8_spriteram_w) AM_BASE(&spriteram ) // Sprites |
| 555 | 555 | ADDRESS_MAP_END |
| 556 | 556 | |
| 557 | static ADDRESS_MAP_START( hardhead_readport, ADDRESS_SPACE_IO, 8 ) | |
| 557 | ||
| 558 | static ADDRESS_MAP_START( hardhead_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 558 | 559 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 559 | 560 | AM_RANGE(0x00, 0x00) AM_READ(SMH_NOP ) // ? IRQ Ack |
| 560 | 561 | ADDRESS_MAP_END |
| 561 | 562 | |
| 562 | static ADDRESS_MAP_START( hardhead_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 563 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 564 | ADDRESS_MAP_END | |
| 565 | ||
| 566 | ||
| 567 | 563 | /*************************************************************************** |
| 568 | 564 | Rough Ranger |
| 569 | 565 | ***************************************************************************/ |
| r3232 | r3233 | |
| 629 | 625 | AM_RANGE(0xe000, 0xffff) AM_WRITE(suna8_spriteram_w) AM_BASE(&spriteram ) // Sprites |
| 630 | 626 | ADDRESS_MAP_END |
| 631 | 627 | |
| 632 | static ADDRESS_MAP_START( rranger_readport, ADDRESS_SPACE_IO, 8 ) | |
| 628 | ||
| 629 | static ADDRESS_MAP_START( rranger_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 633 | 630 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 634 | 631 | AM_RANGE(0x00, 0x00) AM_READ(SMH_NOP ) // ? IRQ Ack |
| 635 | 632 | ADDRESS_MAP_END |
| 636 | 633 | |
| 637 | static ADDRESS_MAP_START( rranger_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 638 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 639 | ADDRESS_MAP_END | |
| 640 | ||
| 641 | ||
| 642 | 634 | /*************************************************************************** |
| 643 | 635 | Brick Zone |
| 644 | 636 | ***************************************************************************/ |
| r3232 | r3233 | |
| 720 | 712 | AM_RANGE(0xe000, 0xffff) AM_WRITE(suna8_banked_spriteram_w ) // Sprites (Banked) |
| 721 | 713 | ADDRESS_MAP_END |
| 722 | 714 | |
| 723 | static ADDRESS_MAP_START( brickzn_readport, ADDRESS_SPACE_IO, 8 ) | |
| 724 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 725 | ADDRESS_MAP_END | |
| 726 | 715 | |
| 727 | static ADDRESS_MAP_START( brickzn_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 728 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 729 | ADDRESS_MAP_END | |
| 730 | ||
| 731 | ||
| 732 | 716 | /*************************************************************************** |
| 733 | 717 | Hard Head 2 |
| 734 | 718 | ***************************************************************************/ |
| r3232 | r3233 | |
| 895 | 879 | AM_RANGE(0xe000, 0xffff) AM_WRITE(suna8_banked_spriteram_w ) // Sprites (Banked) |
| 896 | 880 | ADDRESS_MAP_END |
| 897 | 881 | |
| 898 | static ADDRESS_MAP_START( starfigh_readport, ADDRESS_SPACE_IO, 8 ) | |
| 899 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 900 | ADDRESS_MAP_END | |
| 901 | 882 | |
| 902 | static ADDRESS_MAP_START( starfigh_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 903 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 904 | ADDRESS_MAP_END | |
| 905 | ||
| 906 | ||
| 907 | 883 | /*************************************************************************** |
| 908 | 884 | Spark Man |
| 909 | 885 | ***************************************************************************/ |
| r3232 | r3233 | |
| 1021 | 997 | AM_RANGE(0xa003, 0xa003) AM_WRITE(ay8910_write_port_0_w ) |
| 1022 | 998 | ADDRESS_MAP_END |
| 1023 | 999 | |
| 1024 | static ADDRESS_MAP_START( hardhead_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 1000 | ||
| 1001 | static ADDRESS_MAP_START( hardhead_sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 1025 | 1002 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 1026 | 1003 | AM_RANGE(0x01, 0x01) AM_READ(SMH_NOP ) // ? IRQ Ack |
| 1027 | 1004 | ADDRESS_MAP_END |
| 1028 | 1005 | |
| 1029 | static ADDRESS_MAP_START( hardhead_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1030 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1031 | ADDRESS_MAP_END | |
| 1032 | 1006 | |
| 1033 | ||
| 1034 | ||
| 1035 | 1007 | /*************************************************************************** |
| 1036 | 1008 | Rough Ranger |
| 1037 | 1009 | ***************************************************************************/ |
| r3232 | r3233 | |
| 1052 | 1024 | AM_RANGE(0xa003, 0xa003) AM_WRITE(ym2203_write_port_1_w ) |
| 1053 | 1025 | ADDRESS_MAP_END |
| 1054 | 1026 | |
| 1055 | static ADDRESS_MAP_START( rranger_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 1056 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1057 | ADDRESS_MAP_END | |
| 1058 | 1027 | |
| 1059 | static ADDRESS_MAP_START( rranger_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1060 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1061 | ADDRESS_MAP_END | |
| 1062 | ||
| 1063 | ||
| 1064 | 1028 | /*************************************************************************** |
| 1065 | 1029 | Brick Zone |
| 1066 | 1030 | ***************************************************************************/ |
| r3232 | r3233 | |
| 1081 | 1045 | AM_RANGE(0xf000, 0xf000) AM_WRITE(soundlatch2_w ) // To PCM CPU |
| 1082 | 1046 | ADDRESS_MAP_END |
| 1083 | 1047 | |
| 1084 | static ADDRESS_MAP_START( brickzn_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 1085 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1086 | ADDRESS_MAP_END | |
| 1087 | 1048 | |
| 1088 | static ADDRESS_MAP_START( brickzn_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1089 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1090 | ADDRESS_MAP_END | |
| 1091 | ||
| 1092 | ||
| 1093 | 1049 | /* PCM Z80 , 4 DACs (4 bits per sample), NO RAM !! */ |
| 1094 | 1050 | |
| 1095 | 1051 | static ADDRESS_MAP_START( brickzn_pcm_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 1105 | 1061 | dac_signed_data_w( offset, (data & 0xf) * 0x11 ); |
| 1106 | 1062 | } |
| 1107 | 1063 | |
| 1108 | static ADDRESS_MAP_START( brickzn_pcm_readport, ADDRESS_SPACE_IO, 8 ) | |
| 1064 | ||
| 1065 | static ADDRESS_MAP_START( brickzn_pcm_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 1109 | 1066 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 1110 | 1067 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch2_r ) // From Sound CPU |
| 1068 | AM_RANGE(0x00, 0x03) AM_WRITE(brickzn_pcm_w ) // 4 x DAC | |
| 1111 | 1069 | ADDRESS_MAP_END |
| 1112 | static ADDRESS_MAP_START( brickzn_pcm_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1113 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1114 | AM_RANGE(0x00, 0x03) AM_WRITE(brickzn_pcm_w ) // 4 x DAC | |
| 1115 | ADDRESS_MAP_END | |
| 1116 | 1070 | |
| 1117 | ||
| 1118 | ||
| 1119 | 1071 | /*************************************************************************** |
| 1120 | 1072 | |
| 1121 | 1073 | |
| r3232 | r3233 | |
| 1554 | 1506 | /* basic machine hardware */ |
| 1555 | 1507 | MDRV_CPU_ADD("main", Z80, 24000000 / 4) /* ? */ |
| 1556 | 1508 | MDRV_CPU_PROGRAM_MAP(hardhead_readmem,hardhead_writemem) |
| 1557 | MDRV_CPU_IO_MAP(hardhead_ | |
| 1509 | MDRV_CPU_IO_MAP(hardhead_i | |
| 1558 | 1510 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) /* No NMI */ |
| 1559 | 1511 | |
| 1560 | 1512 | MDRV_CPU_ADD("audio", Z80, 24000000 / 4) /* ? */ |
| 1561 | 1513 | MDRV_CPU_PROGRAM_MAP(hardhead_sound_readmem,hardhead_sound_writemem) |
| 1562 | MDRV_CPU_IO_MAP(hardhead_sound_ | |
| 1514 | MDRV_CPU_IO_MAP(hardhead_sound_i | |
| 1563 | 1515 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,4) /* No NMI */ |
| 1564 | 1516 | |
| 1565 | 1517 | /* video hardware */ |
| r3232 | r3233 | |
| 1608 | 1560 | /* basic machine hardware */ |
| 1609 | 1561 | MDRV_CPU_ADD("main", Z80, 24000000 / 4) /* ? */ |
| 1610 | 1562 | MDRV_CPU_PROGRAM_MAP(rranger_readmem,rranger_writemem) |
| 1611 | MDRV_CPU_IO_MAP(rranger_ | |
| 1563 | MDRV_CPU_IO_MAP(rranger_i | |
| 1612 | 1564 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) /* IRQ & NMI ! */ |
| 1613 | 1565 | |
| 1614 | 1566 | MDRV_CPU_ADD("audio", Z80, 24000000 / 4) /* ? */ |
| 1615 | 1567 | MDRV_CPU_PROGRAM_MAP(rranger_sound_readmem,rranger_sound_writemem) |
| 1616 | MDRV_CPU_IO_MAP(rranger_sound_readport,rranger_sound_writeport) | |
| 1617 | 1568 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,4) /* NMI = retn */ |
| 1618 | 1569 | |
| 1619 | 1570 | /* video hardware */ |
| r3232 | r3233 | |
| 1665 | 1616 | /* basic machine hardware */ |
| 1666 | 1617 | MDRV_CPU_ADD("main", Z80, 24000000 / 4) /* SUNA PROTECTION BLOCK */ |
| 1667 | 1618 | MDRV_CPU_PROGRAM_MAP(brickzn_readmem,brickzn_writemem) |
| 1668 | MDRV_CPU_IO_MAP(brickzn_readport,brickzn_writeport) | |
| 1669 | 1619 | // MDRV_CPU_VBLANK_INT_HACK(brickzn_interrupt, 2) |
| 1670 | 1620 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) // nmi breaks ramtest but is needed! |
| 1671 | 1621 | |
| 1672 | 1622 | MDRV_CPU_ADD("sound", Z80, 24000000 / 4) /* Z0840006PSC */ |
| 1673 | 1623 | MDRV_CPU_PROGRAM_MAP(brickzn_sound_readmem,brickzn_sound_writemem) |
| 1674 | MDRV_CPU_IO_MAP(brickzn_sound_readport,brickzn_sound_writeport) | |
| 1675 | 1624 | |
| 1676 | 1625 | MDRV_CPU_ADD("pcm", Z80, 24000000 / 4) /* Z0840006PSC */ |
| 1677 | 1626 | MDRV_CPU_PROGRAM_MAP(brickzn_pcm_readmem,brickzn_pcm_writemem) |
| 1678 | MDRV_CPU_IO_MAP(brickzn_pcm_ | |
| 1627 | MDRV_CPU_IO_MAP(brickzn_pcm_ | |
| 1679 | 1628 | |
| 1680 | 1629 | /* video hardware */ |
| 1681 | 1630 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 1768 | 1717 | /* basic machine hardware */ |
| 1769 | 1718 | MDRV_CPU_ADD("main", Z80, 24000000 / 4) /* ? */ |
| 1770 | 1719 | MDRV_CPU_PROGRAM_MAP(starfigh_readmem,starfigh_writemem) |
| 1771 | MDRV_CPU_IO_MAP(starfigh_readport,starfigh_writeport) | |
| 1772 | 1720 | MDRV_CPU_VBLANK_INT_HACK(brickzn_interrupt,2) /* IRQ & NMI */ |
| 1773 | 1721 | |
| 1774 | 1722 | /* The sound section is identical to that of hardhead */ |
| 1775 | 1723 | MDRV_CPU_ADD("audio", Z80, 24000000 / 4) /* ? */ |
| 1776 | 1724 | MDRV_CPU_PROGRAM_MAP(hardhead_sound_readmem,hardhead_sound_writemem) |
| 1777 | MDRV_CPU_IO_MAP(hardhead_sound_ | |
| 1725 | MDRV_CPU_IO_MAP(hardhead_sound_i | |
| 1778 | 1726 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,4) /* No NMI */ |
| 1779 | 1727 | |
| 1780 | 1728 | /* video hardware */ |
| r3232 | r3233 | |
| 1832 | 1780 | |
| 1833 | 1781 | MDRV_CPU_ADD("audio", Z80, 24000000 / 4) /* ? */ |
| 1834 | 1782 | MDRV_CPU_PROGRAM_MAP(hardhead_sound_readmem,hardhead_sound_writemem) |
| 1835 | MDRV_CPU_IO_MAP(hardhead_sound_ | |
| 1783 | MDRV_CPU_IO_MAP(hardhead_sound_i | |
| 1836 | 1784 | MDRV_CPU_VBLANK_INT_HACK(irq0_line_hold,4) /* No NMI */ |
| 1837 | 1785 | |
| 1838 | 1786 | /* video hardware */ |
| r3232 | r3233 | |
| 2412 | 2360 | GAME( 1990, starfigh, 0, starfigh, hardhea2, starfigh, ROT90, "SunA", "Star Fighter (v1)", GAME_NOT_WORKING ) |
| 2413 | 2361 | GAME( 1992, brickzn, 0, brickzn, brickzn, brickzn, ROT90, "SunA", "Brick Zone (v5.0)", GAME_NOT_WORKING ) |
| 2414 | 2362 | GAME( 1992, brickzn3, brickzn, brickzn, brickzn, brickzn3, ROT90, "SunA", "Brick Zone (v4.0)", GAME_NOT_WORKING ) |
| 2363 |
| r3232 | r3233 | |
|---|---|---|
| 81 | 81 | } |
| 82 | 82 | |
| 83 | 83 | |
| 84 | static void btime_decrypt( | |
| 84 | static void btime_decrypt(running_machine *machine) | |
| 85 | 85 | { |
| 86 | 86 | UINT8 *src, *src1; |
| 87 | 87 | int addr, addr1; |
| r3232 | r3233 | |
| 98 | 98 | /* however if the previous instruction was JSR (which caused a write to */ |
| 99 | 99 | /* the stack), fetch the address of the next instruction. */ |
| 100 | 100 | addr1 = activecpu_get_previouspc(); |
| 101 | src1 = (addr1 < 0x9000) ? rambase : memory_region( | |
| 101 | src1 = (addr1 < 0x9000) ? rambase : memory_region(machine, "main"); | |
| 102 | 102 | if (decrypted[addr1] == 0x20) /* JSR $xxxx */ |
| 103 | 103 | addr = src1[addr1+1] + 256 * src1[addr1+2]; |
| 104 | 104 | |
| 105 | 105 | /* If the address of the next instruction is xxxx xxx1 xxxx x1xx, decode it. */ |
| 106 | src = (addr < 0x9000) ? rambase : memory_region( | |
| 106 | src = (addr < 0x9000) ? rambase : memory_region(machine, "main"); | |
| 107 | 107 | if ((addr & 0x0104) == 0x0104) |
| 108 | 108 | { |
| 109 | 109 | /* 76543210 -> 65342710 bit rotation */ |
| r3232 | r3233 | |
| 162 | 162 | |
| 163 | 163 | rambase[offset] = data; |
| 164 | 164 | |
| 165 | btime_decrypt(); | |
| 165 | btime_decrypt(machine); | |
| 166 | 166 | } |
| 167 | 167 | |
| 168 | 168 | static WRITE8_HANDLER( zoar_w ) |
| r3232 | r3233 | |
| 180 | 180 | |
| 181 | 181 | rambase[offset] = data; |
| 182 | 182 | |
| 183 | btime_decrypt(); | |
| 183 | btime_decrypt(machine); | |
| 184 | 184 | } |
| 185 | 185 | |
| 186 | 186 | static WRITE8_HANDLER( disco_w ) |
| r3232 | r3233 | |
| 194 | 194 | |
| 195 | 195 | rambase[offset] = data; |
| 196 | 196 | |
| 197 | btime_decrypt(); | |
| 197 | btime_decrypt(machine); | |
| 198 | 198 | } |
| 199 | 199 | |
| 200 | 200 | |
| r3232 | r3233 | |
| 1640 | 1640 | ROM_LOAD( "ao_04.10f", 0x1000, 0x1000, CRC(921952af) SHA1(4e9248f3493a5f4651278f27c11f507571242317) ) |
| 1641 | 1641 | ROM_END |
| 1642 | 1642 | |
| 1643 | static void decrypt_C10707_cpu(int cpu, const char *cputag) | |
| 1643 | static void decrypt_C10707_cpu(running_machine *machine, int cpu, const char *cputag) | |
| 1644 | 1644 | { |
| 1645 | 1645 | UINT8 *decrypt = auto_malloc(0x10000); |
| 1646 | UINT8 *rom = memory_region( | |
| 1646 | UINT8 *rom = memory_region(machine, cputag); | |
| 1647 | 1647 | offs_t addr; |
| 1648 | 1648 | |
| 1649 | 1649 | memory_set_decrypted_region(cpu, 0x0000, 0xffff, decrypt); |
| r3232 | r3233 | |
| 1669 | 1669 | return RAM[0xc15f]; |
| 1670 | 1670 | } |
| 1671 | 1671 | |
| 1672 | static void init_rom1( | |
| 1672 | static void init_rom1(running_machine *machine) | |
| 1673 | 1673 | { |
| 1674 | UINT8 *rom = memory_region( | |
| 1674 | UINT8 *rom = memory_region(machine, "main"); | |
| 1675 | 1675 | |
| 1676 | 1676 | decrypted = auto_malloc(0x10000); |
| 1677 | 1677 | memory_set_decrypted_region(0, 0x0000, 0xffff, decrypted); |
| r3232 | r3233 | |
| 1684 | 1684 | |
| 1685 | 1685 | static DRIVER_INIT( btime ) |
| 1686 | 1686 | { |
| 1687 | init_rom1(); | |
| 1687 | init_rom1(machine); | |
| 1688 | 1688 | } |
| 1689 | 1689 | |
| 1690 | 1690 | static DRIVER_INIT( zoar ) |
| r3232 | r3233 | |
| 1697 | 1697 | I'm NOPing it out for now. */ |
| 1698 | 1698 | memset(&rom[0xd50a],0xea,8); |
| 1699 | 1699 | |
| 1700 | init_rom1(); | |
| 1700 | init_rom1(machine); | |
| 1701 | 1701 | } |
| 1702 | 1702 | |
| 1703 | 1703 | static DRIVER_INIT( lnc ) |
| 1704 | 1704 | { |
| 1705 | decrypt_C10707_cpu(0, "main"); | |
| 1705 | decrypt_C10707_cpu(machine, 0, "main"); | |
| 1706 | 1706 | } |
| 1707 | 1707 | |
| 1708 | 1708 | static DRIVER_INIT( cookrace ) |
| 1709 | 1709 | { |
| 1710 | 1710 | memcpy(&audio_rambase[0x200], memory_region(machine, "audio") + 0xf200, 0x200); |
| 1711 | decrypt_C10707_cpu(0, "main"); | |
| 1711 | decrypt_C10707_cpu(machine, 0, "main"); | |
| 1712 | 1712 | } |
| 1713 | 1713 | |
| 1714 | 1714 | static DRIVER_INIT( wtennis ) |
| 1715 | 1715 | { |
| 1716 | 1716 | memcpy(&audio_rambase[0x200], memory_region(machine, "audio") + 0xf200, 0x200); |
| 1717 | 1717 | memory_install_read8_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0xc15f, 0xc15f, 0, 0, wtennis_reset_hack_r); |
| 1718 | decrypt_C10707_cpu(0, "main"); | |
| 1718 | decrypt_C10707_cpu(machine, 0, "main"); | |
| 1719 | 1719 | } |
| 1720 | 1720 | |
| 1721 | 1721 | static DRIVER_INIT( sdtennis ) |
| 1722 | 1722 | { |
| 1723 | decrypt_C10707_cpu(0, "main"); | |
| 1724 | decrypt_C10707_cpu(1, "audio"); | |
| 1723 | decrypt_C10707_cpu(machine, 0, "main"); | |
| 1724 | decrypt_C10707_cpu(machine, 1, "audio"); | |
| 1725 | 1725 | } |
| 1726 | 1726 | |
| 1727 | 1727 |
| r3232 | r3233 | |
|---|---|---|
| 2998 | 2998 | ROM_LOAD( "lw-03u.14c", 0x00000, 0x20000, CRC(807d051f) SHA1(720e4733787b9b11f4d1cdce0892b69475802844) ) |
| 2999 | 2999 | ROM_LOAD( "lw-04u.13c", 0x20000, 0x20000, CRC(e6cd098e) SHA1(667f6e5736f76a1c4c450c4e2035574ea89d7910) ) |
| 3000 | 3000 | |
| 3001 | ROM_REGION( 0x0200, "a | |
| 3001 | ROM_REGION( 0x0200, "a | |
| 3002 | 3002 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3003 | 3003 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3004 | 3004 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3066 | 3066 | ROM_LOAD( "lw-03u.12e", 0x00000, 0x20000, CRC(807d051f) SHA1(720e4733787b9b11f4d1cdce0892b69475802844) ) // == lw-03u.14c |
| 3067 | 3067 | ROM_LOAD( "lw-04u.13e", 0x20000, 0x20000, CRC(e6cd098e) SHA1(667f6e5736f76a1c4c450c4e2035574ea89d7910) ) // == lw-04u.13c |
| 3068 | 3068 | |
| 3069 | ROM_REGION( 0x0200, "a | |
| 3069 | ROM_REGION( 0x0200, "a | |
| 3070 | 3070 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3071 | 3071 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3072 | 3072 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3104 | 3104 | ROM_LOAD( "lw-03.14c", 0x00000, 0x20000, CRC(ce2159e7) SHA1(77d564f8b768c1cbd6e5b334f7ee86c4c3f9d62e) ) |
| 3105 | 3105 | ROM_LOAD( "lw-04.13c", 0x20000, 0x20000, CRC(39305536) SHA1(ad24d7b6df2dc5e84a35aecb9ba9b0aaa27ab6e5) ) |
| 3106 | 3106 | |
| 3107 | ROM_REGION( 0x0200, "a | |
| 3107 | ROM_REGION( 0x0200, "a | |
| 3108 | 3108 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3109 | 3109 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3110 | 3110 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3147 | 3147 | ROM_LOAD( "dm_26.10a", 0x00000, 0x08000, CRC(3692f6e5) SHA1(61b8438d60a39b4cf5062dff0a53228e8a4e4b5f) ) |
| 3148 | 3148 | ROM_CONTINUE( 0x10000, 0x08000 ) |
| 3149 | 3149 | |
| 3150 | ROM_REGION( 0x0200, "a | |
| 3150 | ROM_REGION( 0x0200, "a | |
| 3151 | 3151 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3152 | 3152 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3153 | 3153 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3154 | 3154 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3155 | 3155 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3156 | 3156 | |
| 3157 | ROM_REGION( 0x0200, "b | |
| 3157 | ROM_REGION( 0x0200, "b | |
| 3158 | 3158 | ROM_LOAD( "dm620.2a", 0x0000, 0x0117, CRC(f6e5f727) SHA1(8d38c458721347272ccc14b2c0e9885c4f891477) ) |
| 3159 | 3159 | ROM_LOAD( "lwio.8i", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3160 | 3160 | ROM_END |
| r3232 | r3233 | |
| 3194 | 3194 | ROM_LOAD( "dm_26.10a", 0x00000, 0x08000, CRC(3692f6e5) SHA1(61b8438d60a39b4cf5062dff0a53228e8a4e4b5f) ) |
| 3195 | 3195 | ROM_CONTINUE( 0x10000, 0x08000 ) |
| 3196 | 3196 | |
| 3197 | ROM_REGION( 0x0200, "a | |
| 3197 | ROM_REGION( 0x0200, "a | |
| 3198 | 3198 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3199 | 3199 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3200 | 3200 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3201 | 3201 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3202 | 3202 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3203 | 3203 | |
| 3204 | ROM_REGION( 0x0200, "b | |
| 3204 | ROM_REGION( 0x0200, "b | |
| 3205 | 3205 | ROM_LOAD( "dm620.2a", 0x0000, 0x0117, CRC(f6e5f727) SHA1(8d38c458721347272ccc14b2c0e9885c4f891477) ) |
| 3206 | 3206 | ROM_LOAD( "lwio.8i", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3207 | 3207 | ROM_END |
| r3232 | r3233 | |
| 3257 | 3257 | ROM_LOAD( "dm_37.13c", 0x00000, 0x08000, CRC(3692f6e5) SHA1(61b8438d60a39b4cf5062dff0a53228e8a4e4b5f) ) // == dm_26.10a |
| 3258 | 3258 | ROM_CONTINUE( 0x10000, 0x08000 ) |
| 3259 | 3259 | |
| 3260 | ROM_REGION( 0x0200, "a | |
| 3260 | ROM_REGION( 0x0200, "a | |
| 3261 | 3261 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3262 | 3262 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3263 | 3263 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3264 | 3264 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3265 | 3265 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3266 | 3266 | |
| 3267 | ROM_REGION( 0x0200, "b | |
| 3267 | ROM_REGION( 0x0200, "b | |
| 3268 | 3268 | ROM_LOAD( "dm22a.1a", 0x0000, 0x0117, NO_DUMP ) |
| 3269 | 3269 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3270 | 3270 | ROM_END |
| r3232 | r3233 | |
| 3292 | 3292 | ROM_LOAD( "dam_09.12a", 0x00000, 0x08000, CRC(0656ff53) SHA1(063a8124dbe73d014b11f72007f1b877afd1a661) ) // == dm_26.10a + garbage |
| 3293 | 3293 | ROM_CONTINUE( 0x10000, 0x18000 ) // second half of ROM is unused, not mapped in memory |
| 3294 | 3294 | |
| 3295 | ROM_REGION( 0x0200, "a | |
| 3295 | ROM_REGION( 0x0200, "a | |
| 3296 | 3296 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3297 | 3297 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3298 | 3298 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3299 | 3299 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3300 | 3300 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3301 | 3301 | |
| 3302 | ROM_REGION( 0x0200, "b | |
| 3302 | ROM_REGION( 0x0200, "b | |
| 3303 | 3303 | ROM_LOAD( "dam63b.1a", 0x0000, 0x0117, CRC(474b3c8a) SHA1(da364581685067fc955ed43b982a7aa7a2648286) ) |
| 3304 | 3304 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 3305 | 3305 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 3306 | 3306 | |
| 3307 | ROM_REGION( 0x0200, "c | |
| 3307 | ROM_REGION( 0x0200, "c | |
| 3308 | 3308 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 3309 | 3309 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 3310 | 3310 | ROM_END |
| r3232 | r3233 | |
| 3339 | 3339 | ROM_LOAD( "strider.18", 0x00000, 0x20000, CRC(4386bc80) SHA1(fb2b261995aeacfa13e7ee40b1a973dfb178f015) ) |
| 3340 | 3340 | ROM_LOAD( "strider.19", 0x20000, 0x20000, CRC(444536d7) SHA1(a14f5de2f6b5b29ae5161dca1f8c08c566301a91) ) |
| 3341 | 3341 | |
| 3342 | ROM_REGION( 0x0200, "a | |
| 3342 | ROM_REGION( 0x0200, "a | |
| 3343 | 3343 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3344 | 3344 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3345 | 3345 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3346 | 3346 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3347 | 3347 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3348 | 3348 | |
| 3349 | ROM_REGION( 0x0200, "b | |
| 3349 | ROM_REGION( 0x0200, "b | |
| 3350 | 3350 | ROM_LOAD( "st24m1.1a", 0x0000, 0x0117, CRC(a80d357e) SHA1(4cb79c99c62c8300e694f4cd26f41dab7818f17f) ) |
| 3351 | 3351 | ROM_LOAD( "lwio.11e", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3352 | 3352 | ROM_END |
| r3232 | r3233 | |
| 3381 | 3381 | ROM_LOAD( "strider.18", 0x00000, 0x20000, CRC(4386bc80) SHA1(fb2b261995aeacfa13e7ee40b1a973dfb178f015) ) |
| 3382 | 3382 | ROM_LOAD( "strider.19", 0x20000, 0x20000, CRC(444536d7) SHA1(a14f5de2f6b5b29ae5161dca1f8c08c566301a91) ) |
| 3383 | 3383 | |
| 3384 | ROM_REGION( 0x0200, "a | |
| 3384 | ROM_REGION( 0x0200, "a | |
| 3385 | 3385 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3386 | 3386 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3387 | 3387 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3388 | 3388 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3389 | 3389 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3390 | 3390 | |
| 3391 | ROM_REGION( 0x0200, "b | |
| 3391 | ROM_REGION( 0x0200, "b | |
| 3392 | 3392 | ROM_LOAD( "st24m1.1a", 0x0000, 0x0117, CRC(a80d357e) SHA1(4cb79c99c62c8300e694f4cd26f41dab7818f17f) ) |
| 3393 | 3393 | ROM_LOAD( "lwio.11e", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3394 | 3394 | ROM_END |
| r3232 | r3233 | |
| 3425 | 3425 | ROM_LOAD( "strider.18", 0x00000, 0x20000, CRC(4386bc80) SHA1(fb2b261995aeacfa13e7ee40b1a973dfb178f015) ) |
| 3426 | 3426 | ROM_LOAD( "strider.19", 0x20000, 0x20000, CRC(444536d7) SHA1(a14f5de2f6b5b29ae5161dca1f8c08c566301a91) ) |
| 3427 | 3427 | |
| 3428 | ROM_REGION( 0x0200, "a | |
| 3428 | ROM_REGION( 0x0200, "a | |
| 3429 | 3429 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3430 | 3430 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3431 | 3431 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3490 | 3490 | ROM_LOAD( "sth30.bin", 0x00000, 0x20000, CRC(4386bc80) SHA1(fb2b261995aeacfa13e7ee40b1a973dfb178f015) ) // == strider.18 |
| 3491 | 3491 | ROM_LOAD( "sth31.bin", 0x20000, 0x20000, CRC(444536d7) SHA1(a14f5de2f6b5b29ae5161dca1f8c08c566301a91) ) // == strider.19 |
| 3492 | 3492 | |
| 3493 | ROM_REGION( 0x0200, "a | |
| 3493 | ROM_REGION( 0x0200, "a | |
| 3494 | 3494 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3495 | 3495 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3496 | 3496 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3525 | 3525 | ROM_LOAD( "tke_18.11c", 0x00000, 0x20000, CRC(ac6e307d) SHA1(b490ce625bb7ce0904b0fd121fbfbd5252790f7a) ) |
| 3526 | 3526 | ROM_LOAD( "tke_19.12c", 0x20000, 0x20000, CRC(068741db) SHA1(ab48aff639a7ac218b7d5304145e10e92d61fd9f) ) |
| 3527 | 3527 | |
| 3528 | ROM_REGION( 0x0200, "a | |
| 3528 | ROM_REGION( 0x0200, "a | |
| 3529 | 3529 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3530 | 3530 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3531 | 3531 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3587 | 3587 | ROM_LOAD( "30", 0x00000, 0x20000, CRC(ac6e307d) SHA1(b490ce625bb7ce0904b0fd121fbfbd5252790f7a) ) // == tke_18.11c |
| 3588 | 3588 | ROM_LOAD( "31", 0x20000, 0x20000, CRC(068741db) SHA1(ab48aff639a7ac218b7d5304145e10e92d61fd9f) ) // == tke_19.12c |
| 3589 | 3589 | |
| 3590 | ROM_REGION( 0x0200, "a | |
| 3590 | ROM_REGION( 0x0200, "a | |
| 3591 | 3591 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3592 | 3592 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3593 | 3593 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3651 | 3651 | ROM_LOAD( "30.bin", 0x00000, 0x20000, CRC(7e5f6cb4) SHA1(c7b6b7d6dfe5f9f0e1521e7ce990229f480cf68d) ) |
| 3652 | 3652 | ROM_LOAD( "31.bin", 0x20000, 0x20000, CRC(4a30c737) SHA1(426eb90f2edf73eb468c94b4a094da3d46acbab2) ) |
| 3653 | 3653 | |
| 3654 | ROM_REGION( 0x0200, "a | |
| 3654 | ROM_REGION( 0x0200, "a | |
| 3655 | 3655 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3656 | 3656 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3657 | 3657 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 3690 | 3690 | ROM_LOAD( "wl_18.rom", 0x00000, 0x20000, CRC(bde23d4d) SHA1(d1fee2f99c858dfb07edcd600da491c7b656afe0) ) |
| 3691 | 3691 | ROM_LOAD( "wl_19.rom", 0x20000, 0x20000, CRC(683898f5) SHA1(316a77b663d78c8b9ff6d85756cb05aaaeef4003) ) |
| 3692 | 3692 | |
| 3693 | ROM_REGION( 0x0200, "a | |
| 3693 | ROM_REGION( 0x0200, "a | |
| 3694 | 3694 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3695 | 3695 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3696 | 3696 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3697 | 3697 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3698 | 3698 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3699 | 3699 | |
| 3700 | ROM_REGION( 0x0200, "b | |
| 3700 | ROM_REGION( 0x0200, "b | |
| 3701 | 3701 | ROM_LOAD( "wl24b.1a", 0x0000, 0x0117, CRC(7101cdf1) SHA1(c848f109d09641b3159dbbb2d2ee49cf30bc9e9c) ) |
| 3702 | 3702 | ROM_LOAD( "lwio.11e", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3703 | 3703 | ROM_END |
| r3232 | r3233 | |
| 3735 | 3735 | ROM_LOAD( "wl30.bin", 0x00000, 0x20000, CRC(bde23d4d) SHA1(d1fee2f99c858dfb07edcd600da491c7b656afe0) ) // == wl_18.rom |
| 3736 | 3736 | ROM_LOAD( "wl32.bin", 0x20000, 0x20000, CRC(683898f5) SHA1(316a77b663d78c8b9ff6d85756cb05aaaeef4003) ) // == wl_19.rom |
| 3737 | 3737 | |
| 3738 | ROM_REGION( 0x0200, "a | |
| 3738 | ROM_REGION( 0x0200, "a | |
| 3739 | 3739 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3740 | 3740 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3741 | 3741 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3742 | 3742 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3743 | 3743 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3744 | 3744 | |
| 3745 | ROM_REGION( 0x0200, "b | |
| 3745 | ROM_REGION( 0x0200, "b | |
| 3746 | 3746 | ROM_LOAD( "wl22b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 3747 | 3747 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3748 | 3748 | ROM_END |
| r3232 | r3233 | |
| 3778 | 3778 | ROM_LOAD( "wl_18.rom", 0x00000, 0x20000, CRC(bde23d4d) SHA1(d1fee2f99c858dfb07edcd600da491c7b656afe0) ) |
| 3779 | 3779 | ROM_LOAD( "wl_19.rom", 0x20000, 0x20000, CRC(683898f5) SHA1(316a77b663d78c8b9ff6d85756cb05aaaeef4003) ) |
| 3780 | 3780 | |
| 3781 | ROM_REGION( 0x0200, "a | |
| 3781 | ROM_REGION( 0x0200, "a | |
| 3782 | 3782 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3783 | 3783 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3784 | 3784 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3785 | 3785 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3786 | 3786 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3787 | 3787 | |
| 3788 | ROM_REGION( 0x0200, "b | |
| 3788 | ROM_REGION( 0x0200, "b | |
| 3789 | 3789 | ROM_LOAD( "wl24b.1a", 0x0000, 0x0117, CRC(7101cdf1) SHA1(c848f109d09641b3159dbbb2d2ee49cf30bc9e9c) ) |
| 3790 | 3790 | ROM_LOAD( "lwio.11e", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3791 | 3791 | ROM_END |
| r3232 | r3233 | |
| 3813 | 3813 | ROM_LOAD( "ar_18.11c", 0x00000, 0x20000, CRC(584b43a9) SHA1(7820815c8c67d484baf2fdad7e55d8c14b98b860) ) |
| 3814 | 3814 | /* 20000-3ffff empty */ |
| 3815 | 3815 | |
| 3816 | ROM_REGION( 0x0200, "a | |
| 3816 | ROM_REGION( 0x0200, "a | |
| 3817 | 3817 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3818 | 3818 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3819 | 3819 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3820 | 3820 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3821 | 3821 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3822 | 3822 | |
| 3823 | ROM_REGION( 0x0200, "b | |
| 3823 | ROM_REGION( 0x0200, "b | |
| 3824 | 3824 | ROM_LOAD( "ar24b.1a", 0x0000, 0x0117, CRC(09a51271) SHA1(147f53f426f258ad127157967fa59d4098e5ed16) ) |
| 3825 | 3825 | ROM_LOAD( "lwio.11e", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3826 | 3826 | ROM_END |
| r3232 | r3233 | |
| 3863 | 3863 | ROM_LOAD( "ar_30.12e", 0x00000, 0x20000, CRC(584b43a9) SHA1(7820815c8c67d484baf2fdad7e55d8c14b98b860) ) // == ar_18.11c |
| 3864 | 3864 | /* 20000-3ffff empty */ |
| 3865 | 3865 | |
| 3866 | ROM_REGION( 0x0200, "a | |
| 3866 | ROM_REGION( 0x0200, "a | |
| 3867 | 3867 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3868 | 3868 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3869 | 3869 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3870 | 3870 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3871 | 3871 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3872 | 3872 | |
| 3873 | ROM_REGION( 0x0200, "b | |
| 3873 | ROM_REGION( 0x0200, "b | |
| 3874 | 3874 | ROM_LOAD( "ar22b.1a", 0x0000, 0x0117, CRC(f1db9030) SHA1(85a6eefb93e7bf7c7d3980737365a425c5324c08) ) |
| 3875 | 3875 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 3876 | 3876 | ROM_END |
| r3232 | r3233 | |
| 3899 | 3899 | ROM_LOAD( "ff_18.11c", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) |
| 3900 | 3900 | ROM_LOAD( "ff_19.12c", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) |
| 3901 | 3901 | |
| 3902 | ROM_REGION( 0x0200, "a | |
| 3902 | ROM_REGION( 0x0200, "a | |
| 3903 | 3903 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3904 | 3904 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3905 | 3905 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3906 | 3906 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3907 | 3907 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3908 | 3908 | |
| 3909 | ROM_REGION( 0x0200, "b | |
| 3909 | ROM_REGION( 0x0200, "b | |
| 3910 | 3910 | ROM_LOAD( "s224b.1a", 0x0000, 0x0117, CRC(4e85b158) SHA1(0476840361fb8bcfacc60a213dbbc58bf242431e) ) |
| 3911 | 3911 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 3912 | 3912 | ROM_END |
| r3232 | r3233 | |
| 3934 | 3934 | ROM_LOAD( "ff_18.11c", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) |
| 3935 | 3935 | ROM_LOAD( "ff_19.12c", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) |
| 3936 | 3936 | |
| 3937 | ROM_REGION( 0x0200, "a | |
| 3937 | ROM_REGION( 0x0200, "a | |
| 3938 | 3938 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3939 | 3939 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3940 | 3940 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3941 | 3941 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3942 | 3942 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3943 | 3943 | |
| 3944 | ROM_REGION( 0x0200, "b | |
| 3944 | ROM_REGION( 0x0200, "b | |
| 3945 | 3945 | ROM_LOAD( "s224b.1a", 0x0000, 0x0117, CRC(4e85b158) SHA1(0476840361fb8bcfacc60a213dbbc58bf242431e) ) |
| 3946 | 3946 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 3947 | 3947 | ROM_END |
| r3232 | r3233 | |
| 3973 | 3973 | ROM_LOAD( "ff_18.11c", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) |
| 3974 | 3974 | ROM_LOAD( "ff_19.12c", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) |
| 3975 | 3975 | |
| 3976 | ROM_REGION( 0x0200, "a | |
| 3976 | ROM_REGION( 0x0200, "a | |
| 3977 | 3977 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 3978 | 3978 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 3979 | 3979 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 3980 | 3980 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 3981 | 3981 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 3982 | 3982 | |
| 3983 | ROM_REGION( 0x0200, "b | |
| 3983 | ROM_REGION( 0x0200, "b | |
| 3984 | 3984 | ROM_LOAD( "s224b.1a", 0x0000, 0x0117, CRC(4e85b158) SHA1(0476840361fb8bcfacc60a213dbbc58bf242431e) ) |
| 3985 | 3985 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 3986 | 3986 | ROM_END |
| r3232 | r3233 | |
| 4025 | 4025 | ROM_LOAD( "ff_18.11c", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) |
| 4026 | 4026 | ROM_LOAD( "ff_19.12c", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) |
| 4027 | 4027 | |
| 4028 | ROM_REGION( 0x0200, "a | |
| 4028 | ROM_REGION( 0x0200, "a | |
| 4029 | 4029 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4030 | 4030 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4031 | 4031 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4032 | 4032 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4033 | 4033 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4034 | 4034 | |
| 4035 | ROM_REGION( 0x0200, "b | |
| 4035 | ROM_REGION( 0x0200, "b | |
| 4036 | 4036 | ROM_LOAD( "s224b.1a", 0x0000, 0x0117, CRC(4e85b158) SHA1(0476840361fb8bcfacc60a213dbbc58bf242431e) ) |
| 4037 | 4037 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4038 | 4038 | ROM_END |
| r3232 | r3233 | |
| 4075 | 4075 | ROM_LOAD( "ffj_30.12e", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) // == ff_18.11c |
| 4076 | 4076 | ROM_LOAD( "ffj_31.13e", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) // == ff_19.12c |
| 4077 | 4077 | |
| 4078 | ROM_REGION( 0x0200, "a | |
| 4078 | ROM_REGION( 0x0200, "a | |
| 4079 | 4079 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4080 | 4080 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4081 | 4081 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4082 | 4082 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4083 | 4083 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4084 | 4084 | |
| 4085 | ROM_REGION( 0x0200, "b | |
| 4085 | ROM_REGION( 0x0200, "b | |
| 4086 | 4086 | ROM_LOAD( "s222b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4087 | 4087 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 4088 | 4088 | ROM_END |
| r3232 | r3233 | |
| 4125 | 4125 | ROM_LOAD( "ffj_30.12e", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) // == ff_18.11c |
| 4126 | 4126 | ROM_LOAD( "ffj_31.13e", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) // == ff_19.12c |
| 4127 | 4127 | |
| 4128 | ROM_REGION( 0x0200, "a | |
| 4128 | ROM_REGION( 0x0200, "a | |
| 4129 | 4129 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4130 | 4130 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4131 | 4131 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4132 | 4132 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4133 | 4133 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4134 | 4134 | |
| 4135 | ROM_REGION( 0x0200, "b | |
| 4135 | ROM_REGION( 0x0200, "b | |
| 4136 | 4136 | ROM_LOAD( "s222b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4137 | 4137 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 4138 | 4138 | ROM_END |
| r3232 | r3233 | |
| 4175 | 4175 | ROM_LOAD( "ffj_30.12e", 0x00000, 0x20000, CRC(375c66e7) SHA1(36189e23209ce4ae5d9cbabd1574540d0591e7b3) ) // == ff_18.11c |
| 4176 | 4176 | ROM_LOAD( "ffj_31.13e", 0x20000, 0x20000, CRC(1ef137f9) SHA1(974b5e72aa28b87ebfa7438efbdfeda769dedf5e) ) // == ff_19.12c |
| 4177 | 4177 | |
| 4178 | ROM_REGION( 0x0200, "a | |
| 4178 | ROM_REGION( 0x0200, "a | |
| 4179 | 4179 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4180 | 4180 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4181 | 4181 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4182 | 4182 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4183 | 4183 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4184 | 4184 | |
| 4185 | ROM_REGION( 0x0200, "b | |
| 4185 | ROM_REGION( 0x0200, "b | |
| 4186 | 4186 | ROM_LOAD( "s222b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4187 | 4187 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 4188 | 4188 | ROM_END |
| r3232 | r3233 | |
| 4206 | 4206 | ROM_LOAD( "41_09.rom", 0x00000, 0x08000, CRC(0f9d8527) SHA1(3a00dd5772f38081fde11d8d61ba467379e2a636) ) |
| 4207 | 4207 | ROM_CONTINUE( 0x10000, 0x08000 ) |
| 4208 | 4208 | |
| 4209 | ROM_REGION( 0x0200, "a | |
| 4209 | ROM_REGION( 0x0200, "a | |
| 4210 | 4210 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4211 | 4211 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4212 | 4212 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4242 | 4242 | ROM_LOAD( "41_18.rom", 0x00000, 0x20000, CRC(d1f15aeb) SHA1(88089383f2d54fc97026a67f067d448eee5bd0c2) ) |
| 4243 | 4243 | ROM_LOAD( "41_19.rom", 0x20000, 0x20000, CRC(15aec3a6) SHA1(8153c03aba005bab62bf0e8b3d15ec1c346326fd) ) |
| 4244 | 4244 | |
| 4245 | ROM_REGION( 0x0200, "a | |
| 4245 | ROM_REGION( 0x0200, "a | |
| 4246 | 4246 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4247 | 4247 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4248 | 4248 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4281 | 4281 | ROM_LOAD( "so2_18.11c", 0x00000, 0x20000, CRC(bbea1643) SHA1(d43d68a120550067bf0b181f88687ad230cd7908) ) |
| 4282 | 4282 | ROM_LOAD( "so2_19.12c", 0x20000, 0x20000, CRC(ac58aa71) SHA1(93102272e358bc49d3936302efdc5bb68df84d68) ) |
| 4283 | 4283 | |
| 4284 | ROM_REGION( 0x0200, "a | |
| 4284 | ROM_REGION( 0x0200, "a | |
| 4285 | 4285 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4286 | 4286 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4287 | 4287 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4288 | 4288 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4289 | 4289 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4290 | 4290 | |
| 4291 | ROM_REGION( 0x0200, "b | |
| 4291 | ROM_REGION( 0x0200, "b | |
| 4292 | 4292 | ROM_LOAD( "o224b.1a", 0x0000, 0x0117, CRC(c211c8cd) SHA1(d9464792e663549e6ad20aac6484622298f88a78) ) |
| 4293 | 4293 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4294 | 4294 | |
| 4295 | ROM_REGION( 0x0200, "c | |
| 4295 | ROM_REGION( 0x0200, "c | |
| 4296 | 4296 | ROM_LOAD( "c628", 0x0000, 0x0117, NO_DUMP ) |
| 4297 | 4297 | ROM_END |
| 4298 | 4298 | |
| r3232 | r3233 | |
| 4327 | 4327 | ROM_LOAD( "so2_18.11c", 0x00000, 0x20000, CRC(bbea1643) SHA1(d43d68a120550067bf0b181f88687ad230cd7908) ) |
| 4328 | 4328 | ROM_LOAD( "so2_19.12c", 0x20000, 0x20000, CRC(ac58aa71) SHA1(93102272e358bc49d3936302efdc5bb68df84d68) ) |
| 4329 | 4329 | |
| 4330 | ROM_REGION( 0x0200, "a | |
| 4330 | ROM_REGION( 0x0200, "a | |
| 4331 | 4331 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4332 | 4332 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4333 | 4333 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4334 | 4334 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4335 | 4335 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4336 | 4336 | |
| 4337 | ROM_REGION( 0x0200, "b | |
| 4337 | ROM_REGION( 0x0200, "b | |
| 4338 | 4338 | ROM_LOAD( "o224b.1a", 0x0000, 0x0117, CRC(c211c8cd) SHA1(d9464792e663549e6ad20aac6484622298f88a78) ) |
| 4339 | 4339 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4340 | 4340 | |
| 4341 | ROM_REGION( 0x0200, "c | |
| 4341 | ROM_REGION( 0x0200, "c | |
| 4342 | 4342 | ROM_LOAD( "c628", 0x0000, 0x0117, NO_DUMP ) |
| 4343 | 4343 | ROM_END |
| 4344 | 4344 | |
| r3232 | r3233 | |
| 4373 | 4373 | ROM_LOAD( "so2_18.11c", 0x00000, 0x20000, CRC(bbea1643) SHA1(d43d68a120550067bf0b181f88687ad230cd7908) ) |
| 4374 | 4374 | ROM_LOAD( "so2_19.12c", 0x20000, 0x20000, CRC(ac58aa71) SHA1(93102272e358bc49d3936302efdc5bb68df84d68) ) |
| 4375 | 4375 | |
| 4376 | ROM_REGION( 0x0200, "a | |
| 4376 | ROM_REGION( 0x0200, "a | |
| 4377 | 4377 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4378 | 4378 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4379 | 4379 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4380 | 4380 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4381 | 4381 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4382 | 4382 | |
| 4383 | ROM_REGION( 0x0200, "b | |
| 4383 | ROM_REGION( 0x0200, "b | |
| 4384 | 4384 | ROM_LOAD( "o224b.1a", 0x0000, 0x0117, CRC(c211c8cd) SHA1(d9464792e663549e6ad20aac6484622298f88a78) ) |
| 4385 | 4385 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4386 | 4386 | |
| 4387 | ROM_REGION( 0x0200, "c | |
| 4387 | ROM_REGION( 0x0200, "c | |
| 4388 | 4388 | ROM_LOAD( "c628", 0x0000, 0x0117, NO_DUMP ) |
| 4389 | 4389 | ROM_END |
| 4390 | 4390 | |
| r3232 | r3233 | |
| 4434 | 4434 | ROM_LOAD( "so2_30.bin", 0x00000, 0x20000, CRC(bbea1643) SHA1(d43d68a120550067bf0b181f88687ad230cd7908) ) // == so2_18.11c |
| 4435 | 4435 | ROM_LOAD( "so2_31.bin", 0x20000, 0x20000, CRC(ac58aa71) SHA1(93102272e358bc49d3936302efdc5bb68df84d68) ) // == so2_19.12c |
| 4436 | 4436 | |
| 4437 | ROM_REGION( 0x0200, "a | |
| 4437 | ROM_REGION( 0x0200, "a | |
| 4438 | 4438 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4439 | 4439 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4440 | 4440 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4441 | 4441 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4442 | 4442 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4443 | 4443 | |
| 4444 | ROM_REGION( 0x0200, "b | |
| 4444 | ROM_REGION( 0x0200, "b | |
| 4445 | 4445 | ROM_LOAD( "o222b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4446 | 4446 | ROM_LOAD( "iob1.12c", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) // could be LWIO, and 12E if board is 89625B |
| 4447 | 4447 | |
| 4448 | ROM_REGION( 0x0200, "c | |
| 4448 | ROM_REGION( 0x0200, "c | |
| 4449 | 4449 | ROM_LOAD( "c628", 0x0000, 0x0117, NO_DUMP ) |
| 4450 | 4450 | ROM_END |
| 4451 | 4451 | |
| r3232 | r3233 | |
| 4472 | 4472 | ROM_LOAD( "ch_18.12b", 0x00000, 0x20000, CRC(f909e8de) SHA1(2dd5bd4076e7d5ded98b72919f868ea700df2e4f) ) |
| 4473 | 4473 | ROM_LOAD( "ch_19.12c", 0x20000, 0x20000, CRC(fc158cf7) SHA1(294b93d0aea60663ffe96364671552e944a1264b) ) |
| 4474 | 4474 | |
| 4475 | ROM_REGION( 0x0200, "a | |
| 4475 | ROM_REGION( 0x0200, "a | |
| 4476 | 4476 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4477 | 4477 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4478 | 4478 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4518 | 4518 | ROM_LOAD( "ch_30.bin", 0x00000, 0x20000, CRC(f909e8de) SHA1(2dd5bd4076e7d5ded98b72919f868ea700df2e4f) ) // == ch_18.12b |
| 4519 | 4519 | ROM_LOAD( "ch_31.bin", 0x20000, 0x20000, CRC(fc158cf7) SHA1(294b93d0aea60663ffe96364671552e944a1264b) ) // == ch_19.12c |
| 4520 | 4520 | |
| 4521 | ROM_REGION( 0x0200, "a | |
| 4521 | ROM_REGION( 0x0200, "a | |
| 4522 | 4522 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4523 | 4523 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4524 | 4524 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4549 | 4549 | ROM_LOAD( "ms_18.11c", 0x00000, 0x20000, CRC(fb64e90d) SHA1(d1a596ce2f8ac14a80b34335b173369a14b45f55) ) |
| 4550 | 4550 | ROM_LOAD( "ms_19.12c", 0x20000, 0x20000, CRC(74f892b9) SHA1(bf48db5c438154e7b96fd31fde1be4aad5cf25eb) ) |
| 4551 | 4551 | |
| 4552 | ROM_REGION( 0x0200, "a | |
| 4552 | ROM_REGION( 0x0200, "a | |
| 4553 | 4553 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4554 | 4554 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4555 | 4555 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4556 | 4556 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4557 | 4557 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4558 | 4558 | |
| 4559 | ROM_REGION( 0x0200, "b | |
| 4559 | ROM_REGION( 0x0200, "b | |
| 4560 | 4560 | ROM_LOAD( "ms24b.1a", 0x0000, 0x0117, CRC(636dbe6d) SHA1(6622a2294f82e70e9eb5ff24f84e0dc13e9168b5) ) |
| 4561 | 4561 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4562 | 4562 | ROM_END |
| r3232 | r3233 | |
| 4584 | 4584 | ROM_LOAD( "ms_18.11c", 0x00000, 0x20000, CRC(fb64e90d) SHA1(d1a596ce2f8ac14a80b34335b173369a14b45f55) ) |
| 4585 | 4585 | ROM_LOAD( "ms_19.12c", 0x20000, 0x20000, CRC(74f892b9) SHA1(bf48db5c438154e7b96fd31fde1be4aad5cf25eb) ) |
| 4586 | 4586 | |
| 4587 | ROM_REGION( 0x0200, "a | |
| 4587 | ROM_REGION( 0x0200, "a | |
| 4588 | 4588 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4589 | 4589 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4590 | 4590 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4591 | 4591 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4592 | 4592 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4593 | 4593 | |
| 4594 | ROM_REGION( 0x0200, "b | |
| 4594 | ROM_REGION( 0x0200, "b | |
| 4595 | 4595 | ROM_LOAD( "ms24b.1a", 0x0000, 0x0117, CRC(636dbe6d) SHA1(6622a2294f82e70e9eb5ff24f84e0dc13e9168b5) ) |
| 4596 | 4596 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4597 | 4597 | ROM_END |
| r3232 | r3233 | |
| 4619 | 4619 | ROM_LOAD( "ms_18.11c", 0x00000, 0x20000, CRC(fb64e90d) SHA1(d1a596ce2f8ac14a80b34335b173369a14b45f55) ) |
| 4620 | 4620 | ROM_LOAD( "ms_19.12c", 0x20000, 0x20000, CRC(74f892b9) SHA1(bf48db5c438154e7b96fd31fde1be4aad5cf25eb) ) |
| 4621 | 4621 | |
| 4622 | ROM_REGION( 0x0200, "a | |
| 4622 | ROM_REGION( 0x0200, "a | |
| 4623 | 4623 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4624 | 4624 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4625 | 4625 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4626 | 4626 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4627 | 4627 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4628 | 4628 | |
| 4629 | ROM_REGION( 0x0200, "b | |
| 4629 | ROM_REGION( 0x0200, "b | |
| 4630 | 4630 | ROM_LOAD( "ms24b.1a", 0x0000, 0x0117, CRC(636dbe6d) SHA1(6622a2294f82e70e9eb5ff24f84e0dc13e9168b5) ) |
| 4631 | 4631 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4632 | 4632 | ROM_END |
| r3232 | r3233 | |
| 4669 | 4669 | ROM_LOAD( "ms_30.12c", 0x00000, 0x20000, CRC(fb64e90d) SHA1(d1a596ce2f8ac14a80b34335b173369a14b45f55) ) // == ms_18.11c |
| 4670 | 4670 | ROM_LOAD( "ms_31.13c", 0x20000, 0x20000, CRC(74f892b9) SHA1(bf48db5c438154e7b96fd31fde1be4aad5cf25eb) ) // == ms_19.12c |
| 4671 | 4671 | |
| 4672 | ROM_REGION( 0x0200, "a | |
| 4672 | ROM_REGION( 0x0200, "a | |
| 4673 | 4673 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4674 | 4674 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4675 | 4675 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4676 | 4676 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4677 | 4677 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4678 | 4678 | |
| 4679 | ROM_REGION( 0x0200, "b | |
| 4679 | ROM_REGION( 0x0200, "b | |
| 4680 | 4680 | ROM_LOAD( "ms22b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4681 | 4681 | ROM_LOAD( "iob1.12e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4682 | 4682 | ROM_END |
| r3232 | r3233 | |
| 4704 | 4704 | ROM_LOAD( "ca_18.11c", 0x00000, 0x20000, CRC(4a613a2c) SHA1(06e10644fc60925b85d2ca0888c9fa057bfe996a) ) |
| 4705 | 4705 | ROM_LOAD( "ca_19.12c", 0x20000, 0x20000, CRC(74584493) SHA1(5cfb15f1b9729323707972646313aee8ab3ac4eb) ) |
| 4706 | 4706 | |
| 4707 | ROM_REGION( 0x0200, "a | |
| 4707 | ROM_REGION( 0x0200, "a | |
| 4708 | 4708 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4709 | 4709 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4710 | 4710 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4735 | 4735 | ROM_LOAD( "ca_18.11c", 0x00000, 0x20000, CRC(4a613a2c) SHA1(06e10644fc60925b85d2ca0888c9fa057bfe996a) ) |
| 4736 | 4736 | ROM_LOAD( "ca_19.12c", 0x20000, 0x20000, CRC(74584493) SHA1(5cfb15f1b9729323707972646313aee8ab3ac4eb) ) |
| 4737 | 4737 | |
| 4738 | ROM_REGION( 0x0200, "a | |
| 4738 | ROM_REGION( 0x0200, "a | |
| 4739 | 4739 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4740 | 4740 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4741 | 4741 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4766 | 4766 | ROM_LOAD( "ca_18.11c", 0x00000, 0x20000, CRC(4a613a2c) SHA1(06e10644fc60925b85d2ca0888c9fa057bfe996a) ) |
| 4767 | 4767 | ROM_LOAD( "ca_19.12c", 0x20000, 0x20000, CRC(74584493) SHA1(5cfb15f1b9729323707972646313aee8ab3ac4eb) ) |
| 4768 | 4768 | |
| 4769 | ROM_REGION( 0x0200, "a | |
| 4769 | ROM_REGION( 0x0200, "a | |
| 4770 | 4770 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4771 | 4771 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4772 | 4772 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4812 | 4812 | ROM_LOAD( "caj_30.12c", 0x00000, 0x20000, CRC(4a613a2c) SHA1(06e10644fc60925b85d2ca0888c9fa057bfe996a) ) // == ca_18.11c |
| 4813 | 4813 | ROM_LOAD( "caj_31.13c", 0x20000, 0x20000, CRC(74584493) SHA1(5cfb15f1b9729323707972646313aee8ab3ac4eb) ) // == ca_19.12c |
| 4814 | 4814 | |
| 4815 | ROM_REGION( 0x0200, "a | |
| 4815 | ROM_REGION( 0x0200, "a | |
| 4816 | 4816 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4817 | 4817 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4818 | 4818 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 4843 | 4843 | ROM_LOAD( "nm_18.11c", 0x00000, 0x20000, CRC(bab333d4) SHA1(c1d0fb61ec46f17eb7edf69e1ad5ac91b5d51daa) ) |
| 4844 | 4844 | ROM_LOAD( "nm_19.12c", 0x20000, 0x20000, CRC(2650a0a8) SHA1(e9e8cc1b27a2cb3e87124061fabcf42982f0611f) ) |
| 4845 | 4845 | |
| 4846 | ROM_REGION( 0x0200, "a | |
| 4846 | ROM_REGION( 0x0200, "a | |
| 4847 | 4847 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4848 | 4848 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4849 | 4849 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4850 | 4850 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4851 | 4851 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4852 | 4852 | |
| 4853 | ROM_REGION( 0x0200, "b | |
| 4853 | ROM_REGION( 0x0200, "b | |
| 4854 | 4854 | ROM_LOAD( "nm24b.1a", 0x0000, 0x0117, CRC(7b25bac6) SHA1(fa0083c59c8d6da07798cb3a4fc25d388065b7cd) ) |
| 4855 | 4855 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4856 | 4856 | ROM_END |
| r3232 | r3233 | |
| 4893 | 4893 | ROM_LOAD( "nm_30.12c", 0x00000, 0x20000, CRC(bab333d4) SHA1(c1d0fb61ec46f17eb7edf69e1ad5ac91b5d51daa) ) // == nm_18.11c |
| 4894 | 4894 | ROM_LOAD( "nm_31.13c", 0x20000, 0x20000, CRC(2650a0a8) SHA1(e9e8cc1b27a2cb3e87124061fabcf42982f0611f) ) // == nm_19.12c |
| 4895 | 4895 | |
| 4896 | ROM_REGION( 0x0200, "a | |
| 4896 | ROM_REGION( 0x0200, "a | |
| 4897 | 4897 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4898 | 4898 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4899 | 4899 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 4900 | 4900 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 4901 | 4901 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 4902 | 4902 | |
| 4903 | ROM_REGION( 0x0200, "b | |
| 4903 | ROM_REGION( 0x0200, "b | |
| 4904 | 4904 | ROM_LOAD( "nm22b.1a", 0x0000, 0x0117, NO_DUMP ) |
| 4905 | 4905 | ROM_LOAD( "iob1.12e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 4906 | 4906 | ROM_END |
| r3232 | r3233 | |
| 4973 | 4973 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 4974 | 4974 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 4975 | 4975 | |
| 4976 | ROM_REGION( 0x0200, "a | |
| 4976 | ROM_REGION( 0x0200, "a | |
| 4977 | 4977 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 4978 | 4978 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 4979 | 4979 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5014 | 5014 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5015 | 5015 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5016 | 5016 | |
| 5017 | ROM_REGION( 0x0200, "a | |
| 5017 | ROM_REGION( 0x0200, "a | |
| 5018 | 5018 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5019 | 5019 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5020 | 5020 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5055 | 5055 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5056 | 5056 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5057 | 5057 | |
| 5058 | ROM_REGION( 0x0200, "a | |
| 5058 | ROM_REGION( 0x0200, "a | |
| 5059 | 5059 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5060 | 5060 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5061 | 5061 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5096 | 5096 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5097 | 5097 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5098 | 5098 | |
| 5099 | ROM_REGION( 0x0200, "a | |
| 5099 | ROM_REGION( 0x0200, "a | |
| 5100 | 5100 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5101 | 5101 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5102 | 5102 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5137 | 5137 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5138 | 5138 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5139 | 5139 | |
| 5140 | ROM_REGION( 0x0200, "a | |
| 5140 | ROM_REGION( 0x0200, "a | |
| 5141 | 5141 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5142 | 5142 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5143 | 5143 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5178 | 5178 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5179 | 5179 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5180 | 5180 | |
| 5181 | ROM_REGION( 0x0200, "a | |
| 5181 | ROM_REGION( 0x0200, "a | |
| 5182 | 5182 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5183 | 5183 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5184 | 5184 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5219 | 5219 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5220 | 5220 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5221 | 5221 | |
| 5222 | ROM_REGION( 0x0200, "a | |
| 5222 | ROM_REGION( 0x0200, "a | |
| 5223 | 5223 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5224 | 5224 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5225 | 5225 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5260 | 5260 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5261 | 5261 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5262 | 5262 | |
| 5263 | ROM_REGION( 0x0200, "a | |
| 5263 | ROM_REGION( 0x0200, "a | |
| 5264 | 5264 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5265 | 5265 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5266 | 5266 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5301 | 5301 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5302 | 5302 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5303 | 5303 | |
| 5304 | ROM_REGION( 0x0200, "a | |
| 5304 | ROM_REGION( 0x0200, "a | |
| 5305 | 5305 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5306 | 5306 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5307 | 5307 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5342 | 5342 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5343 | 5343 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5344 | 5344 | |
| 5345 | ROM_REGION( 0x0200, "a | |
| 5345 | ROM_REGION( 0x0200, "a | |
| 5346 | 5346 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5347 | 5347 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5348 | 5348 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5383 | 5383 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5384 | 5384 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5385 | 5385 | |
| 5386 | ROM_REGION( 0x0200, "a | |
| 5386 | ROM_REGION( 0x0200, "a | |
| 5387 | 5387 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5388 | 5388 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5389 | 5389 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5424 | 5424 | ROM_LOAD( "sf2_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 5425 | 5425 | ROM_LOAD( "sf2_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 5426 | 5426 | |
| 5427 | ROM_REGION( 0x0200, "a | |
| 5427 | ROM_REGION( 0x0200, "a | |
| 5428 | 5428 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5429 | 5429 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5430 | 5430 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5462 | 5462 | ROM_LOAD( "rt_18.11c", 0x00000, 0x20000, CRC(26b211ab) SHA1(0ea03fdd9edff41eacfc52aa9e0421c10968356b) ) |
| 5463 | 5463 | ROM_LOAD( "rt_19.12c", 0x20000, 0x20000, CRC(dbe64ad0) SHA1(09f2ad522fe75d7bcca094b8c6696c3733b539d5) ) |
| 5464 | 5464 | |
| 5465 | ROM_REGION( 0x0200, "a | |
| 5465 | ROM_REGION( 0x0200, "a | |
| 5466 | 5466 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5467 | 5467 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5468 | 5468 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5469 | 5469 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5470 | 5470 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5471 | 5471 | |
| 5472 | ROM_REGION( 0x0200, "b | |
| 5472 | ROM_REGION( 0x0200, "b | |
| 5473 | 5473 | ROM_LOAD( "rt24b.1a", 0x0000, 0x0117, CRC(54b85159) SHA1(c6f4fb5d747a215f4f50e4f2258e35d3f9bdbb2e) ) |
| 5474 | 5474 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5475 | 5475 | |
| 5476 | ROM_REGION( 0x0200, "c | |
| 5476 | ROM_REGION( 0x0200, "c | |
| 5477 | 5477 | ROM_LOAD( "ioc1.ic1", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5478 | 5478 | ROM_END |
| 5479 | 5479 | |
| r3232 | r3233 | |
| 5507 | 5507 | ROM_LOAD( "rt_18.11c", 0x00000, 0x20000, CRC(26b211ab) SHA1(0ea03fdd9edff41eacfc52aa9e0421c10968356b) ) |
| 5508 | 5508 | ROM_LOAD( "rt_19.12c", 0x20000, 0x20000, CRC(dbe64ad0) SHA1(09f2ad522fe75d7bcca094b8c6696c3733b539d5) ) |
| 5509 | 5509 | |
| 5510 | ROM_REGION( 0x0200, "a | |
| 5510 | ROM_REGION( 0x0200, "a | |
| 5511 | 5511 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5512 | 5512 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5513 | 5513 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5514 | 5514 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5515 | 5515 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5516 | 5516 | |
| 5517 | ROM_REGION( 0x0200, "b | |
| 5517 | ROM_REGION( 0x0200, "b | |
| 5518 | 5518 | ROM_LOAD( "rt24b.1a", 0x0000, 0x0117, CRC(54b85159) SHA1(c6f4fb5d747a215f4f50e4f2258e35d3f9bdbb2e) ) |
| 5519 | 5519 | ROM_LOAD( "iob1.11e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5520 | 5520 | |
| 5521 | ROM_REGION( 0x0200, "c | |
| 5521 | ROM_REGION( 0x0200, "c | |
| 5522 | 5522 | ROM_LOAD( "ioc1.ic1", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5523 | 5523 | ROM_END |
| 5524 | 5524 | |
| r3232 | r3233 | |
| 5576 | 5576 | ROM_LOAD( "rt_30.12c", 0x00000, 0x20000, CRC(26b211ab) SHA1(0ea03fdd9edff41eacfc52aa9e0421c10968356b) ) // == rt_18.11c |
| 5577 | 5577 | ROM_LOAD( "rt_31.13c", 0x20000, 0x20000, CRC(dbe64ad0) SHA1(09f2ad522fe75d7bcca094b8c6696c3733b539d5) ) // == rt_19.12c |
| 5578 | 5578 | |
| 5579 | ROM_REGION( 0x0200, "a | |
| 5579 | ROM_REGION( 0x0200, "a | |
| 5580 | 5580 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5581 | 5581 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5582 | 5582 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5583 | 5583 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5584 | 5584 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5585 | 5585 | |
| 5586 | ROM_REGION( 0x0200, "b | |
| 5586 | ROM_REGION( 0x0200, "b | |
| 5587 | 5587 | ROM_LOAD( "rt22b.1a", 0x0000, 0x0117, CRC(89560d6a) SHA1(0f88920536eb131948339becb14557d77e02b9f8) ) |
| 5588 | 5588 | ROM_LOAD( "iob1.12e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5589 | 5589 | |
| 5590 | ROM_REGION( 0x0200, "c | |
| 5590 | ROM_REGION( 0x0200, "c | |
| 5591 | 5591 | ROM_LOAD( "ioc1.ic1", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5592 | 5592 | ROM_END |
| 5593 | 5593 | |
| r3232 | r3233 | |
| 5621 | 5621 | ROM_LOAD( "kod18.rom", 0x00000, 0x20000, CRC(69ecb2c8) SHA1(fadf266b6b20bd6329a3e638918c5a3106413476) ) |
| 5622 | 5622 | ROM_LOAD( "kod19.rom", 0x20000, 0x20000, CRC(02d851c1) SHA1(c959a6fc3e7d893557f319debae91f28471f4be2) ) |
| 5623 | 5623 | |
| 5624 | ROM_REGION( 0x0200, "a | |
| 5624 | ROM_REGION( 0x0200, "a | |
| 5625 | 5625 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5626 | 5626 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5627 | 5627 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5659 | 5659 | ROM_LOAD( "kd18.bin", 0x00000, 0x20000, CRC(4c63181d) SHA1(270f27534a95cb0be3ff3f9ca71c502320d8090b) ) |
| 5660 | 5660 | ROM_LOAD( "kd19.bin", 0x20000, 0x20000, CRC(92941b80) SHA1(5fa7c2793e6febee54a83042d118ddd4f2b7d127) ) |
| 5661 | 5661 | |
| 5662 | ROM_REGION( 0x0200, "a | |
| 5662 | ROM_REGION( 0x0200, "a | |
| 5663 | 5663 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5664 | 5664 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5665 | 5665 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5694 | 5694 | ROM_LOAD( "kd18.bin", 0x00000, 0x20000, CRC(4c63181d) SHA1(270f27534a95cb0be3ff3f9ca71c502320d8090b) ) |
| 5695 | 5695 | ROM_LOAD( "kd19.bin", 0x20000, 0x20000, CRC(92941b80) SHA1(5fa7c2793e6febee54a83042d118ddd4f2b7d127) ) |
| 5696 | 5696 | |
| 5697 | ROM_REGION( 0x0200, "a | |
| 5697 | ROM_REGION( 0x0200, "a | |
| 5698 | 5698 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5699 | 5699 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5700 | 5700 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 5730 | 5730 | ROM_LOAD( "cc_18.rom", 0x00000, 0x20000, CRC(6de2c2db) SHA1(9a1eaba8d104f59a5e61f89679bb5de0c0c64364) ) |
| 5731 | 5731 | ROM_LOAD( "cc_19.rom", 0x20000, 0x20000, CRC(b99091ae) SHA1(b19197c7ad3aeaf5f41c26bf853b0c9b502ecfca) ) |
| 5732 | 5732 | |
| 5733 | ROM_REGION( 0x0200, "a | |
| 5733 | ROM_REGION( 0x0200, "a | |
| 5734 | 5734 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5735 | 5735 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5736 | 5736 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5737 | 5737 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5738 | 5738 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5739 | 5739 | |
| 5740 | ROM_REGION( 0x0200, "b | |
| 5740 | ROM_REGION( 0x0200, "b | |
| 5741 | 5741 | ROM_LOAD( "cc63b.1a", 0x0000, 0x0117, CRC(cae8f0f9) SHA1(eadbd45e184195b2d170cd71a68e5caed64b69f7) ) |
| 5742 | 5742 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5743 | 5743 | ROM_LOAD( "ccprg.11d", 0x0000, 0x0117, CRC(e1c225c4) SHA1(97146451ca9aa3cecd443cc6881151ed8df47fbf) ) |
| 5744 | 5744 | |
| 5745 | ROM_REGION( 0x0200, "c | |
| 5745 | ROM_REGION( 0x0200, "c | |
| 5746 | 5746 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5747 | 5747 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 5748 | 5748 | ROM_END |
| r3232 | r3233 | |
| 5773 | 5773 | ROM_LOAD( "cc_18.rom", 0x00000, 0x20000, CRC(6de2c2db) SHA1(9a1eaba8d104f59a5e61f89679bb5de0c0c64364) ) |
| 5774 | 5774 | ROM_LOAD( "cc_19.rom", 0x20000, 0x20000, CRC(b99091ae) SHA1(b19197c7ad3aeaf5f41c26bf853b0c9b502ecfca) ) |
| 5775 | 5775 | |
| 5776 | ROM_REGION( 0x0200, "a | |
| 5776 | ROM_REGION( 0x0200, "a | |
| 5777 | 5777 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5778 | 5778 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5779 | 5779 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5780 | 5780 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5781 | 5781 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5782 | 5782 | |
| 5783 | ROM_REGION( 0x0200, "b | |
| 5783 | ROM_REGION( 0x0200, "b | |
| 5784 | 5784 | ROM_LOAD( "cc63b.1a", 0x0000, 0x0117, CRC(cae8f0f9) SHA1(eadbd45e184195b2d170cd71a68e5caed64b69f7) ) |
| 5785 | 5785 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5786 | 5786 | ROM_LOAD( "ccprg.11d", 0x0000, 0x0117, CRC(e1c225c4) SHA1(97146451ca9aa3cecd443cc6881151ed8df47fbf) ) |
| 5787 | 5787 | |
| 5788 | ROM_REGION( 0x0200, "c | |
| 5788 | ROM_REGION( 0x0200, "c | |
| 5789 | 5789 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5790 | 5790 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 5791 | 5791 | ROM_END |
| r3232 | r3233 | |
| 5816 | 5816 | ROM_LOAD( "cc_18.rom", 0x00000, 0x20000, CRC(6de2c2db) SHA1(9a1eaba8d104f59a5e61f89679bb5de0c0c64364) ) |
| 5817 | 5817 | ROM_LOAD( "cc_19.rom", 0x20000, 0x20000, CRC(b99091ae) SHA1(b19197c7ad3aeaf5f41c26bf853b0c9b502ecfca) ) |
| 5818 | 5818 | |
| 5819 | ROM_REGION( 0x0200, "a | |
| 5819 | ROM_REGION( 0x0200, "a | |
| 5820 | 5820 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5821 | 5821 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5822 | 5822 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5823 | 5823 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5824 | 5824 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5825 | 5825 | |
| 5826 | ROM_REGION( 0x0200, "b | |
| 5826 | ROM_REGION( 0x0200, "b | |
| 5827 | 5827 | ROM_LOAD( "cc63b.1a", 0x0000, 0x0117, CRC(cae8f0f9) SHA1(eadbd45e184195b2d170cd71a68e5caed64b69f7) ) |
| 5828 | 5828 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5829 | 5829 | ROM_LOAD( "ccprg.11d", 0x0000, 0x0117, CRC(e1c225c4) SHA1(97146451ca9aa3cecd443cc6881151ed8df47fbf) ) |
| 5830 | 5830 | |
| 5831 | ROM_REGION( 0x0200, "c | |
| 5831 | ROM_REGION( 0x0200, "c | |
| 5832 | 5832 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5833 | 5833 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 5834 | 5834 | ROM_END |
| r3232 | r3233 | |
| 5916 | 5916 | ROM_LOAD( "kr_18.rom", 0x00000, 0x20000, CRC(da69d15f) SHA1(9616207e693bae85705f786cef60b9f6951b5067) ) |
| 5917 | 5917 | ROM_LOAD( "kr_19.rom", 0x20000, 0x20000, CRC(bfc654e9) SHA1(01b3d92e4dedf55ea3933d387c7ddb9ba2549773) ) |
| 5918 | 5918 | |
| 5919 | ROM_REGION( 0x0200, "a | |
| 5919 | ROM_REGION( 0x0200, "a | |
| 5920 | 5920 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5921 | 5921 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5922 | 5922 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5923 | 5923 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5924 | 5924 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5925 | 5925 | |
| 5926 | ROM_REGION( 0x0200, "b | |
| 5926 | ROM_REGION( 0x0200, "b | |
| 5927 | 5927 | ROM_LOAD( "kr63b.1a", 0x0000, 0x0117, CRC(fd5b6522) SHA1(5e6ebb2d736415402920a30d331d4b6dab557e5e) ) |
| 5928 | 5928 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5929 | 5929 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 5930 | 5930 | |
| 5931 | ROM_REGION( 0x0200, "c | |
| 5931 | ROM_REGION( 0x0200, "c | |
| 5932 | 5932 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5933 | 5933 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 5934 | 5934 | ROM_END |
| r3232 | r3233 | |
| 5957 | 5957 | ROM_LOAD( "kr_18.rom", 0x00000, 0x20000, CRC(da69d15f) SHA1(9616207e693bae85705f786cef60b9f6951b5067) ) |
| 5958 | 5958 | ROM_LOAD( "kr_19.rom", 0x20000, 0x20000, CRC(bfc654e9) SHA1(01b3d92e4dedf55ea3933d387c7ddb9ba2549773) ) |
| 5959 | 5959 | |
| 5960 | ROM_REGION( 0x0200, "a | |
| 5960 | ROM_REGION( 0x0200, "a | |
| 5961 | 5961 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 5962 | 5962 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 5963 | 5963 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 5964 | 5964 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 5965 | 5965 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 5966 | 5966 | |
| 5967 | ROM_REGION( 0x0200, "b | |
| 5967 | ROM_REGION( 0x0200, "b | |
| 5968 | 5968 | ROM_LOAD( "kr63b.1a", 0x0000, 0x0117, CRC(fd5b6522) SHA1(5e6ebb2d736415402920a30d331d4b6dab557e5e) ) |
| 5969 | 5969 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 5970 | 5970 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 5971 | 5971 | |
| 5972 | ROM_REGION( 0x0200, "c | |
| 5972 | ROM_REGION( 0x0200, "c | |
| 5973 | 5973 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 5974 | 5974 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 5975 | 5975 | ROM_END |
| r3232 | r3233 | |
| 6002 | 6002 | ROM_LOAD( "kr_18.rom", 0x00000, 0x20000, CRC(da69d15f) SHA1(9616207e693bae85705f786cef60b9f6951b5067) ) |
| 6003 | 6003 | ROM_LOAD( "kr_19.rom", 0x20000, 0x20000, CRC(bfc654e9) SHA1(01b3d92e4dedf55ea3933d387c7ddb9ba2549773) ) |
| 6004 | 6004 | |
| 6005 | ROM_REGION( 0x0200, "a | |
| 6005 | ROM_REGION( 0x0200, "a | |
| 6006 | 6006 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6007 | 6007 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6008 | 6008 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6038 | 6038 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 6039 | 6039 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 6040 | 6040 | |
| 6041 | ROM_REGION( 0x0200, "a | |
| 6041 | ROM_REGION( 0x0200, "a | |
| 6042 | 6042 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6043 | 6043 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6044 | 6044 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6074 | 6074 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 6075 | 6075 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 6076 | 6076 | |
| 6077 | ROM_REGION( 0x0200, "a | |
| 6077 | ROM_REGION( 0x0200, "a | |
| 6078 | 6078 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6079 | 6079 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6080 | 6080 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6110 | 6110 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 6111 | 6111 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 6112 | 6112 | |
| 6113 | ROM_REGION( 0x0200, "a | |
| 6113 | ROM_REGION( 0x0200, "a | |
| 6114 | 6114 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6115 | 6115 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6116 | 6116 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6146 | 6146 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 6147 | 6147 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 6148 | 6148 | |
| 6149 | ROM_REGION( 0x0200, "a | |
| 6149 | ROM_REGION( 0x0200, "a | |
| 6150 | 6150 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6151 | 6151 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6152 | 6152 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6182 | 6182 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 6183 | 6183 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 6184 | 6184 | |
| 6185 | ROM_REGION( 0x0200, "a | |
| 6185 | ROM_REGION( 0x0200, "a | |
| 6186 | 6186 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6187 | 6187 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6188 | 6188 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6690 | 6690 | ROM_LOAD( "va_18.11c", 0x00000, 0x20000, CRC(de30510e) SHA1(8e878696192606b76a3a0e53553e638d9621cff7) ) |
| 6691 | 6691 | ROM_LOAD( "va_19.12c", 0x20000, 0x20000, CRC(0610a4ac) SHA1(3da02ea6a7a56c85de898806d2a1cf6bc526c1b3) ) |
| 6692 | 6692 | |
| 6693 | ROM_REGION( 0x0200, "a | |
| 6693 | ROM_REGION( 0x0200, "a | |
| 6694 | 6694 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6695 | 6695 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6696 | 6696 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6724 | 6724 | ROM_LOAD( "va_18.11c", 0x00000, 0x20000, CRC(de30510e) SHA1(8e878696192606b76a3a0e53553e638d9621cff7) ) |
| 6725 | 6725 | ROM_LOAD( "va_19.12c", 0x20000, 0x20000, CRC(0610a4ac) SHA1(3da02ea6a7a56c85de898806d2a1cf6bc526c1b3) ) |
| 6726 | 6726 | |
| 6727 | ROM_REGION( 0x0200, "a | |
| 6727 | ROM_REGION( 0x0200, "a | |
| 6728 | 6728 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6729 | 6729 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6730 | 6730 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6752 | 6752 | ROM_LOAD( "va_18.bin", 0x00000, 0x20000, CRC(de30510e) SHA1(8e878696192606b76a3a0e53553e638d9621cff7) ) |
| 6753 | 6753 | ROM_LOAD( "va_19.bin", 0x20000, 0x20000, CRC(0610a4ac) SHA1(3da02ea6a7a56c85de898806d2a1cf6bc526c1b3) ) |
| 6754 | 6754 | |
| 6755 | ROM_REGION( 0x0200, "a | |
| 6755 | ROM_REGION( 0x0200, "a | |
| 6756 | 6756 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6757 | 6757 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6758 | 6758 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6798 | 6798 | ROM_LOAD( "va_30.12e", 0x00000, 0x20000, CRC(de30510e) SHA1(8e878696192606b76a3a0e53553e638d9621cff7) ) // == va_18.bin |
| 6799 | 6799 | ROM_LOAD( "va_31.13e", 0x20000, 0x20000, CRC(0610a4ac) SHA1(3da02ea6a7a56c85de898806d2a1cf6bc526c1b3) ) // == va_19.bin |
| 6800 | 6800 | |
| 6801 | ROM_REGION( 0x0200, "a | |
| 6801 | ROM_REGION( 0x0200, "a | |
| 6802 | 6802 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6803 | 6803 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6804 | 6804 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 6805 | 6805 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 6806 | 6806 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 6807 | 6807 | |
| 6808 | ROM_REGION( 0x0200, "b | |
| 6808 | ROM_REGION( 0x0200, "b | |
| 6809 | 6809 | ROM_LOAD( "va22b.1a", 0x0000, 0x0117, CRC(bd7cd574) SHA1(00e49631aceb2871e9313f40264fa55eaaa3538c) ) |
| 6810 | 6810 | ROM_LOAD( "lwio.12c", 0x0000, 0x0117, CRC(ad52b90c) SHA1(f0fd6aeea515ee449320fe15684e6b3ab7f97bf4) ) |
| 6811 | 6811 | |
| 6812 | ROM_REGION( 0x0200, "c | |
| 6812 | ROM_REGION( 0x0200, "c | |
| 6813 | 6813 | ROM_LOAD( "ioc1.ic1", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 6814 | 6814 | ROM_END |
| 6815 | 6815 | |
| r3232 | r3233 | |
| 6851 | 6851 | ROM_LOAD( "q530.bin", 0x00000, 0x20000, CRC(d10c1b68) SHA1(2423241f3340d8ab1b6bf9514ca8c3bba1273873) ) |
| 6852 | 6852 | ROM_LOAD( "q531.bin", 0x20000, 0x20000, CRC(7d17e496) SHA1(a274b94ec4f042dddc239ecb9ac2e1e2375f5eb2) ) |
| 6853 | 6853 | |
| 6854 | ROM_REGION( 0x0200, "a | |
| 6854 | ROM_REGION( 0x0200, "a | |
| 6855 | 6855 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6856 | 6856 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6857 | 6857 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 6885 | 6885 | ROM_LOAD( "tk2_q3.rom", 0x100000, 0x80000, CRC(bfcf6f52) SHA1(2a85ff3fc89b4cbabd20779ec12da2e116333c7c) ) |
| 6886 | 6886 | ROM_LOAD( "tk2_q4.rom", 0x180000, 0x80000, CRC(36642e88) SHA1(8ab25b19e2b67215a5cb1f3aa81b9d26009cfeb8) ) |
| 6887 | 6887 | |
| 6888 | ROM_REGION( 0x0200, "a | |
| 6888 | ROM_REGION( 0x0200, "a | |
| 6889 | 6889 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6890 | 6890 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6891 | 6891 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| 6892 | 6892 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 6893 | 6893 | |
| 6894 | ROM_REGION( 0x0200, "b | |
| 6894 | ROM_REGION( 0x0200, "b | |
| 6895 | 6895 | ROM_LOAD( "tk263b.1a", 0x0000, 0x0117, CRC(c4b0349b) SHA1(b4873dd5ad8735048deb3475222dde3c0b67eaaf) ) |
| 6896 | 6896 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 6897 | 6897 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 6898 | 6898 | |
| 6899 | ROM_REGION( 0x0200, "c | |
| 6899 | ROM_REGION( 0x0200, "c | |
| 6900 | 6900 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 6901 | 6901 | ROM_END |
| 6902 | 6902 | |
| r3232 | r3233 | |
| 6926 | 6926 | ROM_LOAD( "tk2_q3.rom", 0x100000, 0x80000, CRC(bfcf6f52) SHA1(2a85ff3fc89b4cbabd20779ec12da2e116333c7c) ) |
| 6927 | 6927 | ROM_LOAD( "tk2_q4.rom", 0x180000, 0x80000, CRC(36642e88) SHA1(8ab25b19e2b67215a5cb1f3aa81b9d26009cfeb8) ) |
| 6928 | 6928 | |
| 6929 | ROM_REGION( 0x0200, "a | |
| 6929 | ROM_REGION( 0x0200, "a | |
| 6930 | 6930 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6931 | 6931 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6932 | 6932 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| 6933 | 6933 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 6934 | 6934 | |
| 6935 | ROM_REGION( 0x0200, "b | |
| 6935 | ROM_REGION( 0x0200, "b | |
| 6936 | 6936 | ROM_LOAD( "tk263b.1a", 0x0000, 0x0117, CRC(c4b0349b) SHA1(b4873dd5ad8735048deb3475222dde3c0b67eaaf) ) |
| 6937 | 6937 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 6938 | 6938 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 6939 | 6939 | |
| 6940 | ROM_REGION( 0x0200, "c | |
| 6940 | ROM_REGION( 0x0200, "c | |
| 6941 | 6941 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 6942 | 6942 | ROM_END |
| 6943 | 6943 | |
| r3232 | r3233 | |
| 6967 | 6967 | ROM_LOAD( "tk2_q3.rom", 0x100000, 0x80000, CRC(bfcf6f52) SHA1(2a85ff3fc89b4cbabd20779ec12da2e116333c7c) ) |
| 6968 | 6968 | ROM_LOAD( "tk2_q4.rom", 0x180000, 0x80000, CRC(36642e88) SHA1(8ab25b19e2b67215a5cb1f3aa81b9d26009cfeb8) ) |
| 6969 | 6969 | |
| 6970 | ROM_REGION( 0x0200, "a | |
| 6970 | ROM_REGION( 0x0200, "a | |
| 6971 | 6971 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 6972 | 6972 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 6973 | 6973 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| 6974 | 6974 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 6975 | 6975 | |
| 6976 | ROM_REGION( 0x0200, "b | |
| 6976 | ROM_REGION( 0x0200, "b | |
| 6977 | 6977 | ROM_LOAD( "tk263b.1a", 0x0000, 0x0117, CRC(c4b0349b) SHA1(b4873dd5ad8735048deb3475222dde3c0b67eaaf) ) |
| 6978 | 6978 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 6979 | 6979 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 6980 | 6980 | |
| 6981 | ROM_REGION( 0x0200, "c | |
| 6981 | ROM_REGION( 0x0200, "c | |
| 6982 | 6982 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 6983 | 6983 | ROM_END |
| 6984 | 6984 | |
| r3232 | r3233 | |
| 7008 | 7008 | ROM_LOAD( "tk2_q3.rom", 0x100000, 0x80000, CRC(bfcf6f52) SHA1(2a85ff3fc89b4cbabd20779ec12da2e116333c7c) ) |
| 7009 | 7009 | ROM_LOAD( "tk2_q4.rom", 0x180000, 0x80000, CRC(36642e88) SHA1(8ab25b19e2b67215a5cb1f3aa81b9d26009cfeb8) ) |
| 7010 | 7010 | |
| 7011 | ROM_REGION( 0x0200, "a | |
| 7011 | ROM_REGION( 0x0200, "a | |
| 7012 | 7012 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7013 | 7013 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7014 | 7014 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| 7015 | 7015 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 7016 | 7016 | |
| 7017 | ROM_REGION( 0x0200, "b | |
| 7017 | ROM_REGION( 0x0200, "b | |
| 7018 | 7018 | ROM_LOAD( "tk263b.1a", 0x0000, 0x0117, CRC(c4b0349b) SHA1(b4873dd5ad8735048deb3475222dde3c0b67eaaf) ) |
| 7019 | 7019 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 7020 | 7020 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 7021 | 7021 | |
| 7022 | ROM_REGION( 0x0200, "c | |
| 7022 | ROM_REGION( 0x0200, "c | |
| 7023 | 7023 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 7024 | 7024 | ROM_END |
| 7025 | 7025 | |
| r3232 | r3233 | |
| 7078 | 7078 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 7079 | 7079 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 7080 | 7080 | |
| 7081 | ROM_REGION( 0x0200, "a | |
| 7081 | ROM_REGION( 0x0200, "a | |
| 7082 | 7082 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7083 | 7083 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7084 | 7084 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 7114 | 7114 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 7115 | 7115 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 7116 | 7116 | |
| 7117 | ROM_REGION( 0x0200, "a | |
| 7117 | ROM_REGION( 0x0200, "a | |
| 7118 | 7118 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7119 | 7119 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7120 | 7120 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 7150 | 7150 | ROM_LOAD( "s92_18.bin", 0x00000, 0x20000, CRC(7f162009) SHA1(346bf42992b4c36c593e21901e22c87ae4a7d86d) ) |
| 7151 | 7151 | ROM_LOAD( "s92_19.bin", 0x20000, 0x20000, CRC(beade53f) SHA1(277c397dc12752719ec6b47d2224750bd1c07f79) ) |
| 7152 | 7152 | |
| 7153 | ROM_REGION( 0x0200, "a | |
| 7153 | ROM_REGION( 0x0200, "a | |
| 7154 | 7154 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7155 | 7155 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7156 | 7156 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 7185 | 7185 | ROM_LOAD( "cd_q3.rom", 0x100000, 0x80000, CRC(2f273ffc) SHA1(f0de462f6c4d251911258e0ebd886152c14d1586) ) |
| 7186 | 7186 | ROM_LOAD( "cd_q4.rom", 0x180000, 0x80000, CRC(2c67821d) SHA1(6e2528d0b22508300a6a142a796dd3bf53a66946) ) |
| 7187 | 7187 | |
| 7188 | ROM_REGION( 0x0200, "a | |
| 7188 | ROM_REGION( 0x0200, "a | |
| 7189 | 7189 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7190 | 7190 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7191 | 7191 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7219 | 7219 | ROM_LOAD( "cd_q3.rom", 0x100000, 0x80000, CRC(2f273ffc) SHA1(f0de462f6c4d251911258e0ebd886152c14d1586) ) |
| 7220 | 7220 | ROM_LOAD( "cd_q4.rom", 0x180000, 0x80000, CRC(2c67821d) SHA1(6e2528d0b22508300a6a142a796dd3bf53a66946) ) |
| 7221 | 7221 | |
| 7222 | ROM_REGION( 0x0200, "a | |
| 7222 | ROM_REGION( 0x0200, "a | |
| 7223 | 7223 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7224 | 7224 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7225 | 7225 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7253 | 7253 | ROM_LOAD( "cd_q3.rom", 0x100000, 0x80000, CRC(2f273ffc) SHA1(f0de462f6c4d251911258e0ebd886152c14d1586) ) |
| 7254 | 7254 | ROM_LOAD( "cd_q4.rom", 0x180000, 0x80000, CRC(2c67821d) SHA1(6e2528d0b22508300a6a142a796dd3bf53a66946) ) |
| 7255 | 7255 | |
| 7256 | ROM_REGION( 0x0200, "a | |
| 7256 | ROM_REGION( 0x0200, "a | |
| 7257 | 7257 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7258 | 7258 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7259 | 7259 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7400 | 7400 | ROM_LOAD( "ps_q3.rom", 0x100000, 0x80000, CRC(0dd44491) SHA1(903cea1d7f3120545ea3229d30fbd687d11ad68f) ) |
| 7401 | 7401 | ROM_LOAD( "ps_q4.rom", 0x180000, 0x80000, CRC(bed42f03) SHA1(21302f7e75f9c795392a3b34e16a959fc5f6e4e9) ) |
| 7402 | 7402 | |
| 7403 | ROM_REGION( 0x0200, "a | |
| 7403 | ROM_REGION( 0x0200, "a | |
| 7404 | 7404 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7405 | 7405 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7406 | 7406 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7440 | 7440 | ROM_LOAD( "ps_q3.rom", 0x100000, 0x80000, CRC(0dd44491) SHA1(903cea1d7f3120545ea3229d30fbd687d11ad68f) ) |
| 7441 | 7441 | ROM_LOAD( "ps_q4.rom", 0x180000, 0x80000, CRC(bed42f03) SHA1(21302f7e75f9c795392a3b34e16a959fc5f6e4e9) ) |
| 7442 | 7442 | |
| 7443 | ROM_REGION( 0x0200, "a | |
| 7443 | ROM_REGION( 0x0200, "a | |
| 7444 | 7444 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7445 | 7445 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7446 | 7446 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7474 | 7474 | ROM_LOAD( "ps_q3.rom", 0x100000, 0x80000, CRC(0dd44491) SHA1(903cea1d7f3120545ea3229d30fbd687d11ad68f) ) |
| 7475 | 7475 | ROM_LOAD( "ps_q4.rom", 0x180000, 0x80000, CRC(bed42f03) SHA1(21302f7e75f9c795392a3b34e16a959fc5f6e4e9) ) |
| 7476 | 7476 | |
| 7477 | ROM_REGION( 0x0200, "a | |
| 7477 | ROM_REGION( 0x0200, "a | |
| 7478 | 7478 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7479 | 7479 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7480 | 7480 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7655 | 7655 | ROM_LOAD( "mb_q7.bin", 0x300000, 0x80000, CRC(041e49ba) SHA1(3220b033a5c0cfbbe75c0c113cf2db39fb093a7e) ) |
| 7656 | 7656 | ROM_LOAD( "mb_q8.bin", 0x380000, 0x80000, CRC(59fe702a) SHA1(807178dfc6d864e49fd7aabb5c4895835cf0e85b) ) |
| 7657 | 7657 | |
| 7658 | ROM_REGION( 0x0200, "a | |
| 7658 | ROM_REGION( 0x0200, "a | |
| 7659 | 7659 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7660 | 7660 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7661 | 7661 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7704 | 7704 | ROM_LOAD( "mb_q7.bin", 0x300000, 0x80000, CRC(041e49ba) SHA1(3220b033a5c0cfbbe75c0c113cf2db39fb093a7e) ) |
| 7705 | 7705 | ROM_LOAD( "mb_q8.bin", 0x380000, 0x80000, CRC(59fe702a) SHA1(807178dfc6d864e49fd7aabb5c4895835cf0e85b) ) |
| 7706 | 7706 | |
| 7707 | ROM_REGION( 0x0200, "a | |
| 7707 | ROM_REGION( 0x0200, "a | |
| 7708 | 7708 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7709 | 7709 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7710 | 7710 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7753 | 7753 | ROM_LOAD( "mb_q7.bin", 0x300000, 0x80000, CRC(041e49ba) SHA1(3220b033a5c0cfbbe75c0c113cf2db39fb093a7e) ) |
| 7754 | 7754 | ROM_LOAD( "mb_q8.bin", 0x380000, 0x80000, CRC(59fe702a) SHA1(807178dfc6d864e49fd7aabb5c4895835cf0e85b) ) |
| 7755 | 7755 | |
| 7756 | ROM_REGION( 0x0200, "a | |
| 7756 | ROM_REGION( 0x0200, "a | |
| 7757 | 7757 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7758 | 7758 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7759 | 7759 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7802 | 7802 | ROM_LOAD( "mb_q7.bin", 0x300000, 0x80000, CRC(041e49ba) SHA1(3220b033a5c0cfbbe75c0c113cf2db39fb093a7e) ) |
| 7803 | 7803 | ROM_LOAD( "mb_q8.bin", 0x380000, 0x80000, CRC(59fe702a) SHA1(807178dfc6d864e49fd7aabb5c4895835cf0e85b) ) |
| 7804 | 7804 | |
| 7805 | ROM_REGION( 0x0200, "a | |
| 7805 | ROM_REGION( 0x0200, "a | |
| 7806 | 7806 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7807 | 7807 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7808 | 7808 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7851 | 7851 | ROM_LOAD( "mb_q7.bin", 0x300000, 0x80000, CRC(041e49ba) SHA1(3220b033a5c0cfbbe75c0c113cf2db39fb093a7e) ) |
| 7852 | 7852 | ROM_LOAD( "mb_q8.bin", 0x380000, 0x80000, CRC(59fe702a) SHA1(807178dfc6d864e49fd7aabb5c4895835cf0e85b) ) |
| 7853 | 7853 | |
| 7854 | ROM_REGION( 0x0200, "a | |
| 7854 | ROM_REGION( 0x0200, "a | |
| 7855 | 7855 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7856 | 7856 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7857 | 7857 | ROM_LOAD( "prg2", 0x0000, 0x0117, CRC(4386879a) SHA1(c36896d169d8c78393609acbbe4397931292a033) ) |
| r3232 | r3233 | |
| 7890 | 7890 | ROM_LOAD( "pnij24.bin", 0x00000, 0x20000, CRC(5092257d) SHA1(95dc9d10940653b2fb37baf5c1ed27145b02104e) ) |
| 7891 | 7891 | ROM_LOAD( "pnij25.bin", 0x20000, 0x20000, CRC(22109aaa) SHA1(cf21e75674d81b2daae2083d02f9f4b6e52722c6) ) |
| 7892 | 7892 | |
| 7893 | ROM_REGION( 0x0200, "a | |
| 7893 | ROM_REGION( 0x0200, "a | |
| 7894 | 7894 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7895 | 7895 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7896 | 7896 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 7924 | 7924 | ROM_LOAD( "qdu_30.12c", 0x00000, 0x20000, CRC(f190da84) SHA1(d5cd4c69b5d135a2f2fea8ca9631251c9da79e70) ) |
| 7925 | 7925 | ROM_LOAD( "qdu_31.13c", 0x20000, 0x20000, CRC(b7583f73) SHA1(3896e0fcf375e9e5d9ba70cc1ed001cd702f9ff7) ) |
| 7926 | 7926 | |
| 7927 | ROM_REGION( 0x0200, "a | |
| 7927 | ROM_REGION( 0x0200, "a | |
| 7928 | 7928 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7929 | 7929 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7930 | 7930 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 7931 | 7931 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 7932 | 7932 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 7933 | 7933 | |
| 7934 | ROM_REGION( 0x0200, "b | |
| 7934 | ROM_REGION( 0x0200, "b | |
| 7935 | 7935 | ROM_LOAD( "qd22b.1a", 0x0000, 0x0117, CRC(783c53ab) SHA1(1bf87e5fe7e7cbcec0d76ed094dcac823e45af14) ) |
| 7936 | 7936 | ROM_LOAD( "iob1.12e", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 7937 | 7937 | |
| 7938 | ROM_REGION( 0x0200, "c | |
| 7938 | ROM_REGION( 0x0200, "c | |
| 7939 | 7939 | ROM_LOAD( "ioc1.ic1", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 7940 | 7940 | ROM_END |
| 7941 | 7941 | |
| r3232 | r3233 | |
| 7959 | 7959 | ROM_LOAD( "qad18.bin", 0x00000, 0x20000, CRC(2bfe6f6a) SHA1(b2a98ac034c65b7ac8167431f05f35d4799032ea) ) |
| 7960 | 7960 | ROM_LOAD( "qad19.bin", 0x20000, 0x20000, CRC(13d3236b) SHA1(785d49de484e9ac6971eaceebebfecb8e58563f6) ) |
| 7961 | 7961 | |
| 7962 | ROM_REGION( 0x0200, "a | |
| 7962 | ROM_REGION( 0x0200, "a | |
| 7963 | 7963 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 7964 | 7964 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 7965 | 7965 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 7996 | 7996 | ROM_LOAD( "tn2j-18.11c", 0x00000, 0x20000, CRC(a40bf9a7) SHA1(07cb1076262a281e31a621cbcc10be0cae883175) ) |
| 7997 | 7997 | ROM_LOAD( "tn2j-19.12c", 0x20000, 0x20000, CRC(5b3b931e) SHA1(cf28891f84814cbfaa3adaade8bb08b1e0546a3d) ) |
| 7998 | 7998 | |
| 7999 | ROM_REGION( 0x0200, "a | |
| 7999 | ROM_REGION( 0x0200, "a | |
| 8000 | 8000 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 8001 | 8001 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 8002 | 8002 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 8023 | 8023 | ROM_LOAD( "pa3-05.10d", 0x00000, 0x20000, CRC(73a10d5d) SHA1(999465e4fbc35a34746d2db61ad49f61403d5af7) ) |
| 8024 | 8024 | ROM_LOAD( "pa3-06.11d", 0x20000, 0x20000, CRC(affa4f82) SHA1(27b9292bbc121cf585f53297a79fe8f0d0a729ae) ) |
| 8025 | 8025 | |
| 8026 | ROM_REGION( 0x0200, "a | |
| 8026 | ROM_REGION( 0x0200, "a | |
| 8027 | 8027 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 8028 | 8028 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 8029 | 8029 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 8050 | 8050 | ROM_LOAD( "pa3-05.10d", 0x00000, 0x20000, CRC(73a10d5d) SHA1(999465e4fbc35a34746d2db61ad49f61403d5af7) ) |
| 8051 | 8051 | ROM_LOAD( "pa3-06.11d", 0x20000, 0x20000, CRC(affa4f82) SHA1(27b9292bbc121cf585f53297a79fe8f0d0a729ae) ) |
| 8052 | 8052 | |
| 8053 | ROM_REGION( 0x0200, "a | |
| 8053 | ROM_REGION( 0x0200, "a | |
| 8054 | 8054 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 8055 | 8055 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 8056 | 8056 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| r3232 | r3233 | |
| 8091 | 8091 | ROM_LOAD( "rcm_18.rom", 0x00000, 0x20000, CRC(80f1f8aa) SHA1(4a5b7b2a6941ad68da7472c63362c7bcd353fa54) ) |
| 8092 | 8092 | ROM_LOAD( "rcm_19.rom", 0x20000, 0x20000, CRC(f257dbe1) SHA1(967def6b6f93039dbc46373caabeb3301577be75) ) |
| 8093 | 8093 | |
| 8094 | ROM_REGION( 0x0200, "a | |
| 8094 | ROM_REGION( 0x0200, "a | |
| 8095 | 8095 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 8096 | 8096 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 8097 | 8097 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 8098 | 8098 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 8099 | 8099 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 8100 | 8100 | |
| 8101 | ROM_REGION( 0x0200, "b | |
| 8101 | ROM_REGION( 0x0200, "b | |
| 8102 | 8102 | ROM_LOAD( "rcm63b.1a", 0x0000, 0x0117, CRC(84acd494) SHA1(20c861714c8c68bc8cf3bde9d051969807e9b3a3) ) |
| 8103 | 8103 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 8104 | 8104 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 8105 | 8105 | |
| 8106 | ROM_REGION( 0x0200, "c | |
| 8106 | ROM_REGION( 0x0200, "c | |
| 8107 | 8107 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 8108 | 8108 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 8109 | 8109 | ROM_END |
| r3232 | r3233 | |
| 8141 | 8141 | ROM_LOAD( "rcm_18.rom", 0x00000, 0x20000, CRC(80f1f8aa) SHA1(4a5b7b2a6941ad68da7472c63362c7bcd353fa54) ) |
| 8142 | 8142 | ROM_LOAD( "rcm_19.rom", 0x20000, 0x20000, CRC(f257dbe1) SHA1(967def6b6f93039dbc46373caabeb3301577be75) ) |
| 8143 | 8143 | |
| 8144 | ROM_REGION( 0x0200, "a | |
| 8144 | ROM_REGION( 0x0200, "a | |
| 8145 | 8145 | ROM_LOAD( "buf1", 0x0000, 0x0117, CRC(eb122de7) SHA1(b26b5bfe258e3e184f069719f9fd008d6b8f6b9b) ) |
| 8146 | 8146 | ROM_LOAD( "ioa1", 0x0000, 0x0117, CRC(59c7ee3b) SHA1(fbb887c5b4f5cb8df77cec710eaac2985bc482a6) ) |
| 8147 | 8147 | ROM_LOAD( "prg1", 0x0000, 0x0117, CRC(f1129744) SHA1(a5300f301c1a08a7da768f0773fa0fe3f683b237) ) |
| 8148 | 8148 | ROM_LOAD( "rom1", 0x0000, 0x0117, CRC(41dc73b9) SHA1(7d4c9f1693c821fbf84e32dd6ef62ddf14967845) ) |
| 8149 | 8149 | ROM_LOAD( "sou1", 0x0000, 0x0117, CRC(84f4b2fe) SHA1(dcc9e86cc36316fe42eace02d6df75d08bc8bb6d) ) |
| 8150 | 8150 | |
| 8151 | ROM_REGION( 0x0200, "b | |
| 8151 | ROM_REGION( 0x0200, "b | |
| 8152 | 8152 | ROM_LOAD( "rcm63b.1a", 0x0000, 0x0117, CRC(84acd494) SHA1(20c861714c8c68bc8cf3bde9d051969807e9b3a3) ) |
| 8153 | 8153 | ROM_LOAD( "iob1.12d", 0x0000, 0x0117, CRC(3abc0700) SHA1(973043aa46ec6d5d1db20dc9d5937005a0f9f6ae) ) |
| 8154 | 8154 | ROM_LOAD( "bprg1.11d", 0x0000, 0x0117, CRC(31793da7) SHA1(400fa7ac517421c978c1ee7773c30b9ed0c5d3f3) ) |
| 8155 | 8155 | |
| 8156 | ROM_REGION( 0x0200, "c | |
| 8156 | ROM_REGION( 0x0200, "c | |
| 8157 | 8157 | ROM_LOAD( "ioc1.ic7", 0x0000, 0x0117, CRC(0d182081) SHA1(475b3d417785da4bc512cce2b274bb00d4cc6792) ) |
| 8158 | 8158 | ROM_LOAD( "c632.ic1", 0x0000, 0x0117, CRC(0fbd9270) SHA1(d7e737b20c44d41e29ca94be56114b31934dde81) ) |
| 8159 | 8159 | ROM_END |
| r3232 | r3233 | |
|---|---|---|
| 403 | 403 | ADDRESS_MAP_END |
| 404 | 404 | |
| 405 | 405 | |
| 406 | static ADDRESS_MAP_START( scobra_sound_ | |
| 406 | static ADDRESS_MAP_START( scobra_sound_io_ma | |
| 407 | 407 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 408 | AM_RANGE(0x20, 0x20) AM_READ(ay8910_read_port_0_r) | |
| 409 | AM_RANGE(0x80, 0x80) AM_READ(ay8910_read_port_1_r) | |
| 410 | ADDRESS_MAP_END | |
| 411 | ||
| 412 | static ADDRESS_MAP_START( scobra_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 413 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 414 | 408 | AM_RANGE(0x10, 0x10) AM_WRITE(ay8910_control_port_0_w) |
| 415 | AM_RANGE(0x20, 0x20) AM_WRITE(ay8910_write_port_0_w) | |
| 409 | AM_RANGE(0x20, 0x20) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 416 | 410 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_control_port_1_w) |
| 417 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_write_port_1_w) | |
| 411 | AM_RANGE(0x80, 0x80) AM_READWRITE(ay8910_read_port_1_r, ay8910_write_port_1_w) | |
| 418 | 412 | ADDRESS_MAP_END |
| 419 | 413 | |
| 420 | 414 | static ADDRESS_MAP_START( hustler_sound_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 428 | 422 | AM_RANGE(0x6000, 0x6fff) AM_WRITE(frogger_filter_w) |
| 429 | 423 | ADDRESS_MAP_END |
| 430 | 424 | |
| 431 | ||
| 432 | static ADDRESS_MAP_START( hustler_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 425 | static ADDRESS_MAP_START( hustler_sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 433 | 426 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 434 | AM_RANGE(0x40, 0x40) AM_READ(ay8910_read_port_0_r) | |
| 435 | ADDRESS_MAP_END | |
| 436 | ||
| 437 | static ADDRESS_MAP_START( hustler_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 438 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 439 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_write_port_0_w) | |
| 427 | AM_RANGE(0x40, 0x40) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 440 | 428 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_control_port_0_w) |
| 441 | 429 | ADDRESS_MAP_END |
| 442 | 430 | |
| 443 | static ADDRESS_MAP_START( hustlerb_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 444 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 445 | AM_RANGE(0x80, 0x80) AM_READ(ay8910_read_port_0_r) | |
| 446 | ADDRESS_MAP_END | |
| 447 | 431 | |
| 448 | static ADDRESS_MAP_START( hustlerb_sound_ | |
| 432 | static ADDRESS_MAP_START( hustlerb_sound_ | |
| 449 | 433 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 450 | 434 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_control_port_0_w) |
| 451 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_write_port_0_w) | |
| 435 | AM_RANGE(0x80, 0x80) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 452 | 436 | ADDRESS_MAP_END |
| 453 | 437 | |
| 454 | 438 | static INPUT_PORTS_START( scobra ) |
| r3232 | r3233 | |
| 1103 | 1087 | |
| 1104 | 1088 | MDRV_CPU_ADD("audio", Z80,14318000/8) /* 1.78975 MHz */ |
| 1105 | 1089 | MDRV_CPU_PROGRAM_MAP(scobra_sound_readmem,scobra_sound_writemem) |
| 1106 | MDRV_CPU_IO_MAP(scobra_sound_ | |
| 1090 | MDRV_CPU_IO_MAP(scobra_sound_i | |
| 1107 | 1091 | |
| 1108 | 1092 | MDRV_MACHINE_RESET(scramble) |
| 1109 | 1093 | |
| r3232 | r3233 | |
| 1241 | 1225 | |
| 1242 | 1226 | MDRV_CPU_ADD("audio",Z80,14318000/8) /* 1.78975 MHz */ |
| 1243 | 1227 | MDRV_CPU_PROGRAM_MAP(hustler_sound_readmem,hustler_sound_writemem) |
| 1244 | MDRV_CPU_IO_MAP(hustler_sound_ | |
| 1228 | MDRV_CPU_IO_MAP(hustler_sound_i | |
| 1245 | 1229 | |
| 1246 | 1230 | MDRV_MACHINE_RESET(scramble) |
| 1247 | 1231 | |
| r3232 | r3233 | |
| 1284 | 1268 | |
| 1285 | 1269 | MDRV_CPU_MODIFY("audio") |
| 1286 | 1270 | MDRV_CPU_PROGRAM_MAP(scobra_sound_readmem,hustlerb_sound_writemem) |
| 1287 | MDRV_CPU_IO_MAP(hustlerb_sound_ | |
| 1271 | MDRV_CPU_IO_MAP(hustlerb_sound_i | |
| 1288 | 1272 | MACHINE_DRIVER_END |
| 1289 | 1273 | |
| 1290 | 1274 | |
| r3232 | r3233 | |
| 1800 | 1784 | GAME( 1981, hustlerb, hustler, hustlerb, hustler, scramble_ppi, ROT90, "bootleg", "Video Hustler (bootleg)", GAME_SUPPORTS_SAVE ) |
| 1801 | 1785 | GAME( 198?, mimonkey, 0, mimonkey, mimonkey, mimonkey, ROT90, "Universal Video Games", "Mighty Monkey", GAME_SUPPORTS_SAVE ) |
| 1802 | 1786 | GAME( 198?, mimonsco, mimonkey, mimonkey, mimonsco, mimonsco, ROT90, "bootleg", "Mighty Monkey (bootleg on Super Cobra hardware)", GAME_SUPPORTS_SAVE ) |
| 1787 |
| r3232 | r3233 | |
|---|---|---|
| 58 | 58 | Note 1: Some PCBs use a 11.2896MHz OSC instead of the 11.0592MHz |
| 59 | 59 | Note 2: Some PCBs use a TMS34010FNL-40 instead of the TMS34010FNL-50 |
| 60 | 60 | |
| 61 | Egg Venture & Lethal Justice JAMMA Pinout | |
| 62 | ||
| 63 | Main Jamma Connector | |
| 64 | Solder Side | Parts Side | |
| 65 | ------------------------------------------------------------------ | |
| 66 | GND | A | 1 | GND | |
| 67 | GND | B | 2 | GND | |
| 68 | +5 | C | 3 | +5 | |
| 69 | +5 | D | 4 | +5 | |
| 70 | -5 | E | 5 | -5 | |
| 71 | +12 | F | 6 | +12 | |
| 72 | ------------ KEY ------------| H | 7 |------------ KEY ----------- | |
| 73 | | J | 8 | Coin Counter # 1 | |
| 74 | | K | 9 | | |
| 75 | L Speaker (-) | L | 10| L Speaker (+) | |
| 76 | R Speaker (-) | M | 11| R Speaker (+) | |
| 77 | Video Green | N | 12| Video Red | |
| 78 | Video Sync | P | 13| Video Blue | |
| 79 | Service Switch | R | 14| Video GND | |
| 80 | | S | 15| | |
| 81 | Coin Switch 2 | T | 16| Coin Switch 1 | |
| 82 | Start Player 2 | U | 17| Start Player 1 | |
| 83 | | V | 18| | |
| 84 | | W | 19| | |
| 85 | | X | 20| | |
| 86 | | Y | 21| | |
| 87 | | Z | 22| | |
| 88 | | a | 23| | |
| 89 | | b | 24| | |
| 90 | | c | 25| | |
| 91 | | d | 26| | |
| 92 | GND | e | 27| GND | |
| 93 | GND | f | 28| GND | |
| 94 | ||
| 95 | ||
| 96 | Gun Connector Pinout | |
| 97 | ||
| 98 | 1| +5 Volts | |
| 99 | 2| Gun OPTO Player 1 | |
| 100 | 3| Gun OPTO Player 2 | |
| 101 | 4| NOT USED | |
| 102 | 5| Gun Trigger Player 1 | |
| 103 | 6| NOT USED | |
| 104 | 7| Gun Trigger Player 2 | |
| 105 | 8| KEY | |
| 106 | 9| Ground | |
| 107 | ||
| 108 | +5v and GND are wired to both player 1 & 2 | |
| 109 | ||
| 110 | ||
| 111 | The Egg Venture/Lethal Justice PCB does NOT supply an amplified | |
| 112 | sound signal. An external sound AMP is required | |
| 113 | ||
| 114 | Addition information for Sound & AMP hookup: | |
| 115 | ||
| 116 | Power AMP /| | |
| 117 | +-------------------+ / | | |
| 118 | | | -------| | Right Speaker | |
| 119 | [| Volume/Gain | | ----| | | |
| 120 | | R+|]--| | \ | | |
| 121 | [| BASS R-|]-----| \| | |
| 122 | | | | |
| 123 | [| Treble L+|]-----| /| | |
| 124 | | L-|]--| | / | | |
| 125 | | | | ----| | Left Speaker | |
| 126 | Pin #L (-) | | -------| | | |
| 127 | --------->|\ | \ | | |
| 128 | Pin #10(+) | | L I | \| | |
| 129 | --------->|/ N | | |
| 130 | | P | | |
| 131 | Pin #M (-) | U | | |
| 132 | --------->|\ T | | |
| 133 | Pin #11(+) | | R | | |
| 134 | --------->|/ RMT|]--| +12 Volts | |
| 135 | | +12|]--+----------- To Power Source | |
| 136 | | GND|]-------------- | |
| 137 | +-------------------+ Ground | |
| 138 | ||
| 61 | 139 | ***************************************************************************/ |
| 62 | 140 | |
| 63 | 141 | #include "driver.h" |
| r3232 | r3233 | |
| 67 | 145 | #include "sound/okim6295.h" |
| 68 | 146 | |
| 69 | 147 | |
| 70 | #define MASTER_CLOCK XTAL_40MHz | |
| 71 | #define SOUND_CLOCK XTAL_2MHz | |
| 148 | #define MASTER_CLOCK XTAL_40MHz | |
| 149 | #define SOUND_CLOCK XTAL_2MHz | |
| 72 | 150 | |
| 73 | #define VIDEO_CLOCK XTAL_11_289MHz | |
| 74 | #define VIDEO_CLOCK_LETHALJ XTAL_11_0592MHz | |
| 151 | #define VIDEO_CLOCK XTAL_11_289MHz | |
| 152 | #define VIDEO_CLOCK_LETHALJ XTAL_11_0592MHz | |
| 75 | 153 | |
| 76 | 154 | |
| 77 | 155 | |
| r3232 | r3233 | |
| 174 | 252 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 175 | 253 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 176 | 254 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_COIN2 ) |
| 177 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage )) | |
| 178 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C )) | |
| 179 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 180 | PORT_DIPSETTING( 0x0080, DEF_STR( 1C_2C )) | |
| 181 | PORT_DIPSETTING( 0x00c0, DEF_STR( Free_Play )) | |
| 182 | PORT_DIPNAME( 0x0300, 0x0100, DEF_STR( Lives )) | |
| 255 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage ) ) | |
| 256 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C ) ) | |
| 257 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 258 | PORT_DIPSETTING( 0x0080, DEF_STR( 1C_2C ) ) | |
| 259 | PORT_DIPSETTING( 0x00c0, DEF_STR( Free_Play ) ) | |
| 260 | PORT_DIPNAME( 0x0300, 0x0100, DEF_STR( Lives ) ) | |
| 183 | 261 | PORT_DIPSETTING( 0x0000, "2" ) |
| 184 | 262 | PORT_DIPSETTING( 0x0100, "3" ) |
| 185 | 263 | PORT_DIPSETTING( 0x0200, "4" ) |
| r3232 | r3233 | |
| 229 | 307 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 230 | 308 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 231 | 309 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_COIN2 ) |
| 232 | PORT_DIPNAME( 0x0070, 0x0000, DEF_STR( Coinage )) | |
| 233 | PORT_DIPSETTING( 0x0040, DEF_STR( 8C_1C )) | |
| 234 | PORT_DIPSETTING( 0x0030, DEF_STR( 4C_1C )) | |
| 235 | PORT_DIPSETTING( 0x0020, DEF_STR( 3C_1C )) | |
| 236 | PORT_DIPSETTING( 0x0010, DEF_STR( 2C_1C )) | |
| 237 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 238 | PORT_DIPSETTING( 0x0050, DEF_STR( 1C_2C )) | |
| 239 | PORT_DIPSETTING( 0x0060, DEF_STR( 1C_4C )) | |
| 240 | PORT_DIPSETTING( 0x0070, DEF_STR( Free_Play )) | |
| 310 | PORT_DIPNAME( 0x0070, 0x0000, DEF_STR( Coinage ) ) | |
| 311 | PORT_DIPSETTING( 0x0040, DEF_STR( 8C_1C ) ) | |
| 312 | PORT_DIPSETTING( 0x0030, DEF_STR( 4C_1C ) ) | |
| 313 | PORT_DIPSETTING( 0x0020, DEF_STR( 3C_1C ) ) | |
| 314 | PORT_DIPSETTING( 0x0010, DEF_STR( 2C_1C ) ) | |
| 315 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 316 | PORT_DIPSETTING( 0x0050, DEF_STR( 1C_2C ) ) | |
| 317 | PORT_DIPSETTING( 0x0060, DEF_STR( 1C_4C ) ) | |
| 318 | PORT_DIPSETTING( 0x0070, DEF_STR( Free_Play ) ) | |
| 241 | 319 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 242 | 320 | PORT_DIPNAME( 0x0300, 0x0300, DEF_STR( Lives ) ) // Verified Correct |
| 243 | 321 | PORT_DIPSETTING( 0x0000, "3" ) |
| r3232 | r3233 | |
| 283 | 361 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 284 | 362 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 285 | 363 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_COIN2 ) |
| 286 | PORT_DIPNAME( 0x0070, 0x0000, DEF_STR( Coinage )) | |
| 287 | PORT_DIPSETTING( 0x0040, DEF_STR( 8C_1C )) | |
| 288 | PORT_DIPSETTING( 0x0030, DEF_STR( 4C_1C )) | |
| 289 | PORT_DIPSETTING( 0x0020, DEF_STR( 3C_1C )) | |
| 290 | PORT_DIPSETTING( 0x0010, DEF_STR( 2C_1C )) | |
| 291 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 292 | PORT_DIPSETTING( 0x0050, DEF_STR( 1C_2C )) | |
| 293 | PORT_DIPSETTING( 0x0060, DEF_STR( 1C_4C )) | |
| 294 | PORT_DIPSETTING( 0x0070, DEF_STR( Free_Play )) | |
| 364 | PORT_DIPNAME( 0x0070, 0x0000, DEF_STR( Coinage ) ) | |
| 365 | PORT_DIPSETTING( 0x0040, DEF_STR( 8C_1C ) ) | |
| 366 | PORT_DIPSETTING( 0x0030, DEF_STR( 4C_1C ) ) | |
| 367 | PORT_DIPSETTING( 0x0020, DEF_STR( 3C_1C ) ) | |
| 368 | PORT_DIPSETTING( 0x0010, DEF_STR( 2C_1C ) ) | |
| 369 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 370 | PORT_DIPSETTING( 0x0050, DEF_STR( 1C_2C ) ) | |
| 371 | PORT_DIPSETTING( 0x0060, DEF_STR( 1C_4C ) ) | |
| 372 | PORT_DIPSETTING( 0x0070, DEF_STR( Free_Play ) ) | |
| 295 | 373 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 296 | 374 | PORT_DIPNAME( 0x0300, 0x0300, DEF_STR( Lives ) ) // Verified Correct |
| 297 | 375 | PORT_DIPSETTING( 0x0000, "3" ) |
| r3232 | r3233 | |
| 346 | 424 | PORT_DIPNAME( 0x0020, 0x0020, DEF_STR( Unknown ) ) |
| 347 | 425 | PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) |
| 348 | 426 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) |
| 349 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage )) | |
| 350 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C )) | |
| 351 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C )) | |
| 352 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 353 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C )) | |
| 427 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage ) ) | |
| 428 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C ) ) | |
| 429 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C ) ) | |
| 430 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 431 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C ) ) | |
| 354 | 432 | PORT_DIPNAME( 0x0700, 0x0200, "Starting Jackpot" ) |
| 355 | 433 | PORT_DIPSETTING( 0x0000, "0" ) |
| 356 | 434 | PORT_DIPSETTING( 0x0100, "5" ) |
| r3232 | r3233 | |
| 383 | 461 | PORT_SERVICE_NO_TOGGLE( 0x0002, IP_ACTIVE_HIGH ) |
| 384 | 462 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 385 | 463 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 386 | PORT_DIPNAME( 0x0010, 0x0010, DEF_STR( Unknown ) ) | |
| 387 | PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) | |
| 388 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 389 | PORT_DIPNAME( 0x0020, 0x0020, DEF_STR( Unknown ) ) | |
| 390 | PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) | |
| 391 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 392 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage )) | |
| 393 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C )) | |
| 394 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C )) | |
| 395 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 396 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C )) | |
| 397 | PORT_DIPNAME( 0x0700, 0x0300, "Starting Jackpot" ) | |
| 398 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 399 | PORT_DIPSETTING( 0x0100, "5" ) | |
| 400 | PORT_DIPSETTING( 0x0200, "8" ) | |
| 401 | PORT_DIPSETTING( 0x0300, "10" ) | |
| 402 | PORT_DIPSETTING( 0x0400, "12" ) | |
| 403 | PORT_DIPSETTING( 0x0500, "15" ) | |
| 404 | PORT_DIPSETTING( 0x0600, "18" ) | |
| 405 | PORT_DIPSETTING( 0x0700, "20" ) | |
| 406 | PORT_DIPNAME( 0x1800, 0x1800, DEF_STR( Unknown ) ) | |
| 407 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 408 | PORT_DIPSETTING( 0x0800, "1" ) | |
| 409 | PORT_DIPSETTING( 0x1000, "2" ) | |
| 410 | PORT_DIPSETTING( 0x1800, "3" ) | |
| 411 | PORT_DIPNAME( 0xe000, 0x8000, "Eggs per Ticket" ) | |
| 412 | PORT_DIPSETTING( 0xe000, "1" ) | |
| 413 | PORT_DIPSETTING( 0xc000, "2" ) | |
| 414 | PORT_DIPSETTING( 0xa000, "3" ) | |
| 415 | PORT_DIPSETTING( 0x8000, "4" ) | |
| 416 | PORT_DIPSETTING( 0x6000, "5" ) | |
| 417 | PORT_DIPSETTING( 0x4000, "6" ) | |
| 418 | PORT_DIPSETTING( 0x2000, "8" ) | |
| 419 | PORT_DIPSETTING( 0x0000, "10" ) | |
| 464 | PORT_DIPNAME( 0x0010, 0x0010, DEF_STR( Unknown ) ) | |
| 465 | PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) | |
| 466 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 467 | PORT_DIPNAME( 0x0020, 0x0020, DEF_STR( Unknown ) ) | |
| 468 | PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) | |
| 469 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 470 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage ) ) | |
| 471 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C ) ) | |
| 472 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C ) ) | |
| 473 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 474 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C ) ) | |
| 475 | PORT_DIPNAME( 0x0700, 0x0300, "Starting Jackpot" ) | |
| 476 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 477 | PORT_DIPSETTING( 0x0100, "5" ) | |
| 478 | PORT_DIPSETTING( 0x0200, "8" ) | |
| 479 | PORT_DIPSETTING( 0x0300, "10" ) | |
| 480 | PORT_DIPSETTING( 0x0400, "12" ) | |
| 481 | PORT_DIPSETTING( 0x0500, "15" ) | |
| 482 | PORT_DIPSETTING( 0x0600, "18" ) | |
| 483 | PORT_DIPSETTING( 0x0700, "20" ) | |
| 484 | PORT_DIPNAME( 0x1800, 0x1800, DEF_STR( Unknown ) ) | |
| 485 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 486 | PORT_DIPSETTING( 0x0800, "1" ) | |
| 487 | PORT_DIPSETTING( 0x1000, "2" ) | |
| 488 | PORT_DIPSETTING( 0x1800, "3" ) | |
| 489 | PORT_DIPNAME( 0xe000, 0x8000, "Eggs per Ticket" ) | |
| 490 | PORT_DIPSETTING( 0xe000, "1" ) | |
| 491 | PORT_DIPSETTING( 0xc000, "2" ) | |
| 492 | PORT_DIPSETTING( 0xa000, "3" ) | |
| 493 | PORT_DIPSETTING( 0x8000, "4" ) | |
| 494 | PORT_DIPSETTING( 0x6000, "5" ) | |
| 495 | PORT_DIPSETTING( 0x4000, "6" ) | |
| 496 | PORT_DIPSETTING( 0x2000, "8" ) | |
| 497 | PORT_DIPSETTING( 0x0000, "10" ) | |
| 420 | 498 | |
| 421 | 499 | PORT_START("IN1") |
| 422 | 500 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_SPECIAL ) PORT_CUSTOM(ticket_status, NULL) |
| r3232 | r3233 | |
| 434 | 512 | PORT_SERVICE_NO_TOGGLE( 0x0002, IP_ACTIVE_HIGH ) |
| 435 | 513 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 436 | 514 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 437 | PORT_DIPNAME( 0x0010, 0x0010, DEF_STR( Unknown ) ) | |
| 438 | PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) | |
| 439 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 440 | PORT_DIPNAME( 0x0020, 0x0020, DEF_STR( Unknown ) ) | |
| 441 | PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) | |
| 442 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 443 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage )) | |
| 444 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C )) | |
| 445 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C )) | |
| 446 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C )) | |
| 447 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C )) | |
| 448 | PORT_DIPNAME( 0x0700, 0x0700, "Starting Jackpot" ) | |
| 449 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 450 | PORT_DIPSETTING( 0x0100, "2" ) | |
| 451 | PORT_DIPSETTING( 0x0200, "5" ) | |
| 452 | PORT_DIPSETTING( 0x0300, "8" ) | |
| 453 | PORT_DIPSETTING( 0x0400, "10" ) | |
| 454 | PORT_DIPSETTING( 0x0500, "15" ) | |
| 455 | PORT_DIPSETTING( 0x0600, "20" ) | |
| 456 | PORT_DIPSETTING( 0x0700, "30" ) | |
| 457 | PORT_DIPNAME( 0x1800, 0x1800, DEF_STR( Unknown ) ) | |
| 458 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 459 | PORT_DIPSETTING( 0x0800, "1" ) | |
| 460 | PORT_DIPSETTING( 0x1000, "2" ) | |
| 461 | PORT_DIPSETTING( 0x1800, "3" ) | |
| 462 | PORT_DIPNAME( 0xe000, 0x8000, "Points per Ticket" ) | |
| 463 | PORT_DIPSETTING( 0xe000, "700" ) | |
| 464 | PORT_DIPSETTING( 0xc000, "900" ) | |
| 465 | PORT_DIPSETTING( 0xa000, "1200" ) | |
| 466 | PORT_DIPSETTING( 0x8000, "1500" ) | |
| 467 | PORT_DIPSETTING( 0x6000, "1800" ) | |
| 468 | PORT_DIPSETTING( 0x4000, "2100" ) | |
| 469 | PORT_DIPSETTING( 0x2000, "2400" ) | |
| 470 | PORT_DIPSETTING( 0x0000, "3000" ) | |
| 515 | PORT_DIPNAME( 0x0010, 0x0010, DEF_STR( Unknown ) ) | |
| 516 | PORT_DIPSETTING( 0x0010, DEF_STR( Off ) ) | |
| 517 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 518 | PORT_DIPNAME( 0x0020, 0x0020, DEF_STR( Unknown ) ) | |
| 519 | PORT_DIPSETTING( 0x0020, DEF_STR( Off ) ) | |
| 520 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 521 | PORT_DIPNAME( 0x00c0, 0x0000, DEF_STR( Coinage ) ) | |
| 522 | PORT_DIPSETTING( 0x0080, DEF_STR( 3C_1C ) ) | |
| 523 | PORT_DIPSETTING( 0x0040, DEF_STR( 2C_1C ) ) | |
| 524 | PORT_DIPSETTING( 0x0000, DEF_STR( 1C_1C ) ) | |
| 525 | PORT_DIPSETTING( 0x00c0, DEF_STR( 1C_2C ) ) | |
| 526 | PORT_DIPNAME( 0x0700, 0x0700, "Starting Jackpot" ) | |
| 527 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 528 | PORT_DIPSETTING( 0x0100, "2" ) | |
| 529 | PORT_DIPSETTING( 0x0200, "5" ) | |
| 530 | PORT_DIPSETTING( 0x0300, "8" ) | |
| 531 | PORT_DIPSETTING( 0x0400, "10" ) | |
| 532 | PORT_DIPSETTING( 0x0500, "15" ) | |
| 533 | PORT_DIPSETTING( 0x0600, "20" ) | |
| 534 | PORT_DIPSETTING( 0x0700, "30" ) | |
| 535 | PORT_DIPNAME( 0x1800, 0x1800, DEF_STR( Unknown ) ) | |
| 536 | PORT_DIPSETTING( 0x0000, "0" ) | |
| 537 | PORT_DIPSETTING( 0x0800, "1" ) | |
| 538 | PORT_DIPSETTING( 0x1800, "3" ) | |
| 539 | PORT_DIPNAME( 0xe000, 0x8000, "Points per Ticket" ) | |
| 540 | PORT_DIPSETTING( 0xe000, "700" ) | |
| 541 | PORT_DIPSETTING( 0xc000, "900" ) | |
| 542 | PORT_DIPSETTING( 0xa000, "1200" ) | |
| 543 | PORT_DIPSETTING( 0x8000, "1500" ) | |
| 544 | PORT_DIPSETTING( 0x6000, "1800" ) | |
| 545 | PORT_DIPSETTING( 0x4000, "2100" ) | |
| 546 | PORT_DIPSETTING( 0x2000, "2400" ) | |
| 547 | PORT_DIPSETTING( 0x0000, "3000" ) | |
| 471 | 548 | |
| 472 | 549 | PORT_START("IN1") |
| 473 | 550 | PORT_BIT( 0x0f0f, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(cclownz_paddle, NULL) |
| r3232 | r3233 | |
| 590 | 667 | ROM_LOAD( "sound1.u20", 0x00000, 0x40000, CRC(7d93ca66) SHA1(9e1dc0efa5d0f770c7e1f10de56fbf5620dea437) ) |
| 591 | 668 | |
| 592 | 669 | ROM_REGION( 0x40000, "oki2", 0 ) /* sound data */ |
| 593 | ROM_LOAD( "sound1.u21", | |
| 670 | ROM_LOAD( "sound1.u21", | |
| 594 | 671 | |
| 595 | 672 | ROM_REGION( 0x40000, "oki3", 0 ) /* sound data */ |
| 596 | 673 | ROM_LOAD( "sound1.u18", 0x00000, 0x40000, CRC(7d93ca66) SHA1(9e1dc0efa5d0f770c7e1f10de56fbf5620dea437) ) |
| r3232 | r3233 | |
|---|---|---|
| 260 | 260 | |
| 261 | 261 | static READ16_HANDLER( control_3_r ) |
| 262 | 262 | { |
| 263 | static const char *port[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2", "GUNX3", "GUNY3" }; | |
| 263 | static const char *const port[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2", "GUNX3", "GUNY3" }; | |
| 264 | 264 | |
| 265 | 265 | return input_port_read(machine, port[gun_select]); |
| 266 | 266 | } |
| r3232 | r3233 | |
|---|---|---|
| 4 | 4 | |
| 5 | 5 | various SNK triple Z80 games |
| 6 | 6 | |
| 7 | ay8910x2 + "SNK wave" | |
| 8 | Marvin's Maze, Vanguard II, Mad Crasher | |
| 9 | ||
| 7 | 10 | ay8910x2 |
| 8 | 11 | Jumping Cross, Gladiator 1984, HAL21 |
| 9 | 12 | |
| r3232 | r3233 | |
| 67 | 70 | - the I/O area (C000-CFFF) is probably mirrored in large part on the two main |
| 68 | 71 | CPUs, however I mapped only the addresses actually used by the games. |
| 69 | 72 | |
| 73 | - marvins: the fg and bg tilemaps are set to be 512x256 like in madcrash and | |
| 74 | vangrd2, but they could be 256x256. | |
| 75 | ||
| 70 | 76 | - the Flip Screen dip switch in madcrash doesn't work correctly, the screen is |
| 71 | 77 | inverted but the bg and sprite positions are wrong. This is a bug in the game; |
| 72 | 78 | the Cocktail dip switch works correctly and the screen is properly flipped |
| r3232 | r3233 | |
| 712 | 718 | { |
| 713 | 719 | static int last_value[2] = {0, 0}; |
| 714 | 720 | static int cp_count[2] = {0, 0}; |
| 715 | static const char *ports[] = { "P1ROT", "P2ROT" }; | |
| 721 | static const char *const ports[] = { "P1ROT", "P2ROT" }; | |
| 716 | 722 | int which = (int)(FPTR)param; |
| 717 | 723 | int value = input_port_read(field->port->machine, ports[which]); |
| 718 | 724 | |
| r3232 | r3233 | |
| 1522 | 1528 | static INPUT_PORTS_START( vangrd2 ) |
| 1523 | 1529 | PORT_START("IN0") |
| 1524 | 1530 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) |
| 1525 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_UNKNOWN ) | |
| 1526 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNKNOWN ) | |
| 1531 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1532 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1527 | 1533 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) |
| 1528 | 1534 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) |
| 1529 | 1535 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(marvins_sound_busy, NULL) /* sound CPU status */ |
| r3232 | r3233 | |
| 1607 | 1613 | PORT_START("IN0") |
| 1608 | 1614 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) |
| 1609 | 1615 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN2 ) |
| 1610 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_ | |
| 1616 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 1611 | 1617 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) |
| 1612 | 1618 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) |
| 1613 | 1619 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(marvins_sound_busy, NULL) /* sound CPU status */ |
| r3232 | r3233 | |
| 1669 | 1675 | PORT_DIPNAME( 0x18, 0x10, "Game mode" ) PORT_DIPLOCATION("DSW2:4,5") |
| 1670 | 1676 | PORT_DIPSETTING( 0x18, "Demo Sounds Off" ) |
| 1671 | 1677 | PORT_DIPSETTING( 0x10, "Demo Sounds On" ) |
| 1678 | PORT_DIPSETTING( 0x00, "Freeze" ) | |
| 1672 | 1679 | PORT_DIPSETTING( 0x08, "Infinite Lives (Cheat)") |
| 1673 | PORT_DIPSETTING( 0x00, "Freeze" ) | |
| 1674 | 1680 | PORT_DIPNAME( 0x20, 0x20, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION("DSW2:6") |
| 1675 | 1681 | PORT_DIPSETTING( 0x20, DEF_STR( Off ) ) |
| 1676 | 1682 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) /* Check the "Non Bugs" page */ |
| r3232 | r3233 | |
| 1683 | 1689 | |
| 1684 | 1690 | static INPUT_PORTS_START( jcross ) |
| 1685 | 1691 | PORT_START("IN0") |
| 1686 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 1687 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1688 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1689 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1690 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1692 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 1693 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1694 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1695 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1696 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1691 | 1697 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 1692 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1693 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1698 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1699 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1694 | 1700 | |
| 1695 | 1701 | PORT_START("IN1") |
| 1696 | 1702 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 1768 | 1774 | |
| 1769 | 1775 | static INPUT_PORTS_START( sgladiat ) |
| 1770 | 1776 | PORT_START("IN0") |
| 1771 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 1772 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1773 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 1774 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1775 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1777 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 1778 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1779 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 1780 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1781 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1776 | 1782 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 1777 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1778 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE ) /* code at 0x054e */ | |
| 1783 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1784 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_SERVICE ) /* code at 0x054e */ | |
| 1779 | 1785 | |
| 1780 | 1786 | PORT_START("IN1") |
| 1781 | 1787 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 1852 | 1858 | |
| 1853 | 1859 | static INPUT_PORTS_START( hal21 ) |
| 1854 | 1860 | PORT_START("IN0") |
| 1855 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 1856 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1857 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 1858 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1859 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1861 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 1862 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1863 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 1864 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1865 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1860 | 1866 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 1861 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1862 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1867 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1868 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1863 | 1869 | |
| 1864 | 1870 | PORT_START("IN1") |
| 1865 | 1871 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 1935 | 1941 | |
| 1936 | 1942 | static INPUT_PORTS_START( aso ) |
| 1937 | 1943 | PORT_START("IN0") |
| 1938 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 1939 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1940 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* uses "Coinage" settings - code at 0x2e04 */ | |
| 1941 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1942 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1944 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 1945 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1946 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) /* uses "Coinage" settings - code at 0x2e04 */ | |
| 1947 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 1948 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 1943 | 1949 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 1944 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1945 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1950 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1951 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 1946 | 1952 | |
| 1947 | 1953 | PORT_START("IN1") |
| 1948 | 1954 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 2022 | 2028 | |
| 2023 | 2029 | static INPUT_PORTS_START( alphamis ) |
| 2024 | 2030 | PORT_START("IN0") |
| 2025 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2026 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2027 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x2e17 */ | |
| 2028 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2029 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2031 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2032 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2033 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x2e17 */ | |
| 2034 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2035 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2030 | 2036 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2031 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2032 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2037 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2038 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2033 | 2039 | |
| 2034 | 2040 | PORT_START("IN1") |
| 2035 | 2041 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 2104 | 2110 | |
| 2105 | 2111 | static INPUT_PORTS_START( tnk3 ) |
| 2106 | 2112 | PORT_START("IN0") |
| 2107 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2108 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2109 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2110 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2111 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2113 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2114 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2115 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2116 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2117 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2112 | 2118 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2113 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2114 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2119 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2120 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2115 | 2121 | |
| 2116 | 2122 | PORT_START("IN1") |
| 2117 | 2123 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 2194 | 2200 | static INPUT_PORTS_START( athena ) |
| 2195 | 2201 | PORT_START("IN0") |
| 2196 | 2202 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2197 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x09d4 */ | |
| 2198 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2199 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2200 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2201 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2202 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2203 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2203 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x09d4 */ | |
| 2204 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2205 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2206 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2207 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2208 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2209 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2204 | 2210 | |
| 2205 | 2211 | PORT_START("IN1") |
| 2206 | 2212 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY |
| r3232 | r3233 | |
| 2279 | 2285 | static INPUT_PORTS_START( fitegolf ) |
| 2280 | 2286 | PORT_START("IN0") |
| 2281 | 2287 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2282 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x045b */ | |
| 2283 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2284 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) /* same as the dip switch */ | |
| 2285 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2286 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2287 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2288 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2288 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x045b */ | |
| 2289 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2290 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) /* same as the dip switch */ | |
| 2291 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2292 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2293 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2294 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2289 | 2295 | |
| 2290 | 2296 | PORT_START("IN1") |
| 2291 | 2297 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 2364 | 2370 | static INPUT_PORTS_START( countryc ) |
| 2365 | 2371 | PORT_START("IN0") |
| 2366 | 2372 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2367 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x0450 */ | |
| 2368 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2369 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) /* same as the dip switch */ | |
| 2370 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2371 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2372 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2373 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2373 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) /* uses "Coin A" settings - code at 0x0450 */ | |
| 2374 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2375 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) /* same as the dip switch */ | |
| 2376 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2377 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2378 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2379 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2374 | 2380 | |
| 2375 | 2381 | PORT_START("IN1") |
| 2376 | 2382 | PORT_BIT( 0xff, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(countryc_trackball_x, 0) |
| r3232 | r3233 | |
| 2446 | 2452 | static INPUT_PORTS_START( ikari ) |
| 2447 | 2453 | PORT_START("IN0") |
| 2448 | 2454 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2449 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2450 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2451 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2452 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2453 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2454 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2455 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2455 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2456 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2457 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2458 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2459 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2460 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2461 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2456 | 2462 | |
| 2457 | 2463 | PORT_START("IN1") |
| 2458 | 2464 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 2533 | 2539 | // non-JAMMA system inputs |
| 2534 | 2540 | |
| 2535 | 2541 | PORT_MODIFY("IN0") |
| 2536 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2537 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2538 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2539 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2540 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2542 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2543 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2544 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2545 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2546 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2541 | 2547 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2542 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2543 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2548 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2549 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2544 | 2550 | INPUT_PORTS_END |
| 2545 | 2551 | |
| 2546 | 2552 | |
| r3232 | r3233 | |
| 2580 | 2586 | static INPUT_PORTS_START( victroad ) |
| 2581 | 2587 | PORT_START("IN0") |
| 2582 | 2588 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2583 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2584 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2585 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2586 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2587 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2588 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2589 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2589 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2590 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2591 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2592 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2593 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2594 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2595 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2590 | 2596 | |
| 2591 | 2597 | PORT_START("IN1") |
| 2592 | 2598 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 2682 | 2688 | static INPUT_PORTS_START( bermudat ) |
| 2683 | 2689 | PORT_START("IN0") |
| 2684 | 2690 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2685 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2686 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* tilt? */ | |
| 2687 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2688 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2689 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2690 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2691 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2691 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2692 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* tilt? */ | |
| 2693 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2694 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2695 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2696 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2697 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2692 | 2698 | |
| 2693 | 2699 | PORT_START("IN1") |
| 2694 | 2700 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 2803 | 2809 | static INPUT_PORTS_START( gwar ) |
| 2804 | 2810 | PORT_START("IN0") |
| 2805 | 2811 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2806 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2807 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* tilt? causes reset */ | |
| 2808 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 2809 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2810 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2811 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2812 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2812 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2813 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* tilt? causes reset */ | |
| 2814 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 2815 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2816 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2817 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2818 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2813 | 2819 | |
| 2814 | 2820 | PORT_START("IN1") |
| 2815 | 2821 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(1) |
| r3232 | r3233 | |
| 2907 | 2913 | static INPUT_PORTS_START( psychos ) |
| 2908 | 2914 | PORT_START("IN0") |
| 2909 | 2915 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2910 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2911 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2912 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2913 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2914 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2915 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2916 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2916 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2917 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* reset */ | |
| 2918 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 2919 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 2920 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 2921 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2922 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2917 | 2923 | |
| 2918 | 2924 | PORT_START("IN1") |
| 2919 | 2925 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_PLAYER(2) |
| r3232 | r3233 | |
| 2989 | 2995 | static INPUT_PORTS_START( chopper ) |
| 2990 | 2996 | PORT_START("IN0") |
| 2991 | 2997 | PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 2992 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 2993 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* Reset */ | |
| 2994 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 2995 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 2996 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 2997 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 2998 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2998 | PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 2999 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_TILT ) /* Reset */ | |
| 3000 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 3001 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 3002 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 3003 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START2 ) | |
| 3004 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START1 ) | |
| 2999 | 3005 | |
| 3000 | 3006 | PORT_START("IN1") |
| 3001 | 3007 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) PORT_8WAY PORT_COCKTAIL |
| r3232 | r3233 | |
| 3101 | 3107 | |
| 3102 | 3108 | static INPUT_PORTS_START( tdfever ) |
| 3103 | 3109 | PORT_START("IN0") |
| 3104 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 3105 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 3106 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 3110 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 3111 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE ) | |
| 3112 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 3107 | 3113 | PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 3108 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 3109 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 3110 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start Game A") | |
| 3111 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START2 ) PORT_NAME("Start Game B") | |
| 3114 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 3115 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 3116 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start Game A") | |
| 3117 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START2 ) PORT_NAME("Start Game B") | |
| 3112 | 3118 | |
| 3113 | 3119 | PORT_START("IN1") |
| 3114 | 3120 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| r3232 | r3233 | |
| 3242 | 3248 | |
| 3243 | 3249 | static INPUT_PORTS_START( fsoccer ) |
| 3244 | 3250 | PORT_START("IN0") |
| 3245 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 3246 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE ) // same as the dip switch | |
| 3247 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_SERVICE1 ) | |
| 3251 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 3252 | PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_SERVICE ) // same as the dip switch | |
| 3253 | PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_SERVICE1 ) | |
| 3248 | 3254 | PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_SPECIAL ) PORT_CUSTOM(snk_sound_busy, 0) |
| 3249 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 3250 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_COIN2 ) | |
| 3251 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start Game A") | |
| 3252 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START2 ) PORT_NAME("Start Game B") | |
| 3255 | PORT_BIT( 0x10, IP_ACTIVE_HIGH, IPT_COIN1 ) | |
| 3256 | PORT_BIT( 0x20, IP_ACTIVE_HIGH, IPT_COIN2 ) | |
| 3257 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start Game A") | |
| 3258 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_START2 ) PORT_NAME("Start Game B") | |
| 3253 | 3259 | |
| 3254 | 3260 | PORT_START("IN1") |
| 3255 | 3261 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| r3232 | r3233 | |
|---|---|---|
| 56 | 56 | |
| 57 | 57 | static int flash_roms; |
| 58 | 58 | static UINT32 flash_cmd = 0; |
| 59 | static INT32 first_offset; | |
| 59 | 60 | |
| 60 | 61 | static READ32_HANDLER( flash_r ) |
| 61 | 62 | { |
| r3232 | r3233 | |
| 90 | 91 | |
| 91 | 92 | static WRITE32_HANDLER( flash_w ) |
| 92 | 93 | { |
| 93 | static INT32 first_offset = -1; | |
| 94 | ||
| 95 | 94 | if(flash_cmd == 0x20200000) |
| 96 | 95 | { |
| 97 | 96 | // erase game settings |
| r3232 | r3233 | |
| 295 | 294 | return 0; |
| 296 | 295 | } |
| 297 | 296 | |
| 297 | static MACHINE_RESET( dgpix ) | |
| 298 | { | |
| 299 | vbuffer = 0; | |
| 300 | flash_cmd = 0; | |
| 301 | first_offset = -1; | |
| 302 | } | |
| 303 | ||
| 304 | ||
| 298 | 305 | static MACHINE_DRIVER_START( dgpix ) |
| 299 | 306 | MDRV_CPU_ADD("main", E132XT, 20000000*4) /* 4x internal multiplier */ |
| 300 | 307 | MDRV_CPU_PROGRAM_MAP(cpu_map,0) |
| r3232 | r3233 | |
| 305 | 312 | running at 16.9MHz |
| 306 | 313 | */ |
| 307 | 314 | |
| 315 | MDRV_MACHINE_RESET(dgpix) | |
| 308 | 316 | MDRV_NVRAM_HANDLER(flashroms) |
| 309 | 317 | |
| 310 | 318 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 263 | 263 | return pixel_clock; |
| 264 | 264 | } |
| 265 | 265 | |
| 266 | static | |
| 266 | static READ8 | |
| 267 | 267 | { |
| 268 | 268 | /* The top four address lines from the CRTC are bits 0-3 */ |
| 269 | return (video_screen_get_vpos(field->port->machine->primary_screen) & 0xf0) >> 4; | |
| 269 | ||
| 270 | return (input_port_read(machine, "IN0") & 0xf0) | ((video_screen_get_vpos(machine->primary_screen) & 0xf0) >> 4); | |
| 270 | 271 | } |
| 271 | 272 | |
| 272 | 273 | static READ8_HANDLER( magspot_coinage_dip_r ) |
| r3232 | r3233 | |
| 357 | 358 | AM_RANGE(0x2000, 0x3fff) AM_WRITE(SMH_RAM) AM_BASE(&videoram) AM_SIZE(&videoram_size) |
| 358 | 359 | ADDRESS_MAP_END |
| 359 | 360 | |
| 360 | static ADDRESS_MAP_START( cosmicg_readport, ADDRESS_SPACE_IO, 8 ) | |
| 361 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") | |
| 361 | static ADDRESS_MAP_START( cosmicg_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 362 | AM_RANGE(0x00, 0x00) AM_READ(cosmicg_port_0_r) | |
| 362 | 363 | AM_RANGE(0x01, 0x01) AM_READ_PORT("IN1") |
| 363 | ADDRESS_MAP_END | |
| 364 | ||
| 365 | static ADDRESS_MAP_START( cosmicg_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 366 | 364 | AM_RANGE(0x00, 0x15) AM_WRITE(cosmicg_output_w) |
| 367 | 365 | AM_RANGE(0x16, 0x17) AM_WRITE(cosmic_color_register_w) |
| 368 | 366 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 503 | 501 | |
| 504 | 502 | static INPUT_PORTS_START( cosmicg ) |
| 505 | 503 | PORT_START("IN0") /* 4-7 */ |
| 506 | PORT_BIT( 0x0f, IP_ACTIVE_ | |
| 504 | PORT_BIT( 0x0f, IP_ACTIVE_LOW | |
| 507 | 505 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_START1 ) |
| 508 | 506 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_START2 ) |
| 509 | 507 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_BUTTON1 ) |
| r3232 | r3233 | |
| 966 | 964 | fed to the tms9904 or tms9980. Also, I have never heard of a tms9900/9980 operating under |
| 967 | 965 | 1.5MHz. So, if someone can check this... */ |
| 968 | 966 | MDRV_CPU_PROGRAM_MAP(cosmicg_readmem,cosmicg_writemem) |
| 969 | MDRV_CPU_IO_MAP(cosmicg_ | |
| 967 | MDRV_CPU_IO_MAP(cosmicg_ | |
| 970 | 968 | MDRV_CPU_VBLANK_INT("main", cosmicg_interrupt) |
| 971 | 969 | |
| 972 | 970 | /* video hardware */ |
| r3232 | r3233 | |
| 1421 | 1419 | GAME( 1980, panicger, panic, panic, panic, 0, ROT270, "Universal (ADP Automaten license)", "Space Panic (German)", 0 ) |
| 1422 | 1420 | GAME( 1980, devzone, 0, devzone, devzone, devzone, ROT270, "Universal", "Devil Zone", GAME_IMPERFECT_SOUND ) |
| 1423 | 1421 | GAME( 1980, devzone2, devzone, devzone, devzone2, devzone, ROT270, "Universal", "Devil Zone (easier)", GAME_IMPERFECT_SOUND ) |
| 1422 |
| r3232 | r3233 | |
|---|---|---|
| 473 | 473 | UINT32 iptval=0x00ff; |
| 474 | 474 | if(analog_channel<4) |
| 475 | 475 | { |
| 476 | static const char *ports[] = { "ANA0", "ANA1", "ANA2", "ANA3" }; | |
| 476 | static const char *const ports[] = { "ANA0", "ANA1", "ANA2", "ANA3" }; | |
| 477 | 477 | iptval=input_port_read_safe(machine, ports[analog_channel], 0); |
| 478 | 478 | ++analog_channel; |
| 479 | 479 | } |
| r3232 | r3233 | |
|---|---|---|
| 74 | 74 | static READ8_HANDLER( ports_r ) |
| 75 | 75 | { |
| 76 | 76 | int i,res; |
| 77 | static const char *port[] = { "P1", "P2", "IN2", "IN3", "IN4", "IN5", "SYSTEM", "DSW" }; | |
| 77 | static const char *const portnames[] = { "P1", "P2", "IN2", "IN3", "IN4", "IN5", "SYSTEM", "DSW" }; | |
| 78 | 78 | |
| 79 | 79 | res = 0; |
| 80 | 80 | for (i = 0; i < 8; i++) |
| 81 | res |= ((input_port_read(machine, port[i]) >> offset) & 1) << i; | |
| 81 | res |= ((input_port_read(machine, portnames[i]) >> offset) & 1) << i; | |
| 82 | 82 | |
| 83 | 83 | return res; |
| 84 | 84 | } |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | extern VIDEO_START ( compgolf ); |
| 23 | 23 | extern VIDEO_UPDATE ( compgolf ); |
| 24 | 24 | |
| 25 | static int bank; | |
| 26 | ||
| 25 | 27 | static WRITE8_HANDLER( compgolf_scrollx_lo_w ) |
| 26 | 28 | { |
| 27 | 29 | compgolf_scrollx_lo = data; |
| r3232 | r3233 | |
| 36 | 38 | { |
| 37 | 39 | /* bit 4 and 6 are always set */ |
| 38 | 40 | |
| 39 | static int bank = -1; | |
| 40 | 41 | int new_bank = (data & 4) >> 2; |
| 41 | 42 | |
| 42 | 43 | if( bank != new_bank ) |
| r3232 | r3233 | |
| 304 | 305 | |
| 305 | 306 | static DRIVER_INIT( compgolf ) |
| 306 | 307 | { |
| 308 | bank = -1; | |
| 307 | 309 | compgolf_expand_bg(machine); |
| 308 | 310 | } |
| 309 | 311 |
| r3232 | r3233 | |
|---|---|---|
| 297 | 297 | /* sound hardware */ |
| 298 | 298 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 299 | 299 | |
| 300 | MDRV_SOUND_ADD("2 | |
| 300 | MDRV_SOUND_ADD("2 | |
| 301 | 301 | MDRV_SOUND_CONFIG(tiamc1_custom_interface) |
| 302 | 302 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 303 | 303 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
|---|---|---|
| 1406 | 1406 | * |
| 1407 | 1407 | *************************************/ |
| 1408 | 1408 | |
| 1409 | static void monsterb_expand_gfx(const char *region) | |
| 1409 | static void monsterb_expand_gfx(running_machine *machine, const char *region) | |
| 1410 | 1410 | { |
| 1411 | 1411 | UINT8 *temp, *dest; |
| 1412 | 1412 | int i; |
| 1413 | 1413 | |
| 1414 | 1414 | /* expand the background ROMs; A11/A12 of each ROM is independently controlled via */ |
| 1415 | 1415 | /* banking */ |
| 1416 | dest = memory_region( | |
| 1416 | dest = memory_region(machine, region); | |
| 1417 | 1417 | temp = malloc_or_die(0x4000); |
| 1418 | 1418 | memcpy(temp, dest, 0x4000); |
| 1419 | 1419 | |
| r3232 | r3233 | |
| 1488 | 1488 | |
| 1489 | 1489 | /* configure video */ |
| 1490 | 1490 | segag80r_background_pcb = G80_BACKGROUND_MONSTERB; |
| 1491 | monsterb_expand_gfx("gfx1"); | |
| 1491 | monsterb_expand_gfx(machine, "gfx1"); | |
| 1492 | 1492 | |
| 1493 | 1493 | /* install background board handlers */ |
| 1494 | 1494 | memory_install_write8_handler(machine, 0, ADDRESS_SPACE_IO, 0xb8, 0xbd, 0, 0, monsterb_back_port_w); |
| r3232 | r3233 | |
| 1504 | 1504 | |
| 1505 | 1505 | /* configure video */ |
| 1506 | 1506 | segag80r_background_pcb = G80_BACKGROUND_PIGNEWT; |
| 1507 | monsterb_expand_gfx("gfx1"); | |
| 1507 | monsterb_expand_gfx(machine, "gfx1"); | |
| 1508 | 1508 | |
| 1509 | 1509 | /* install background board handlers */ |
| 1510 | 1510 | memory_install_write8_handler(machine, 0, ADDRESS_SPACE_IO, 0xb4, 0xb5, 0, 0, pignewt_back_color_w); |
| r3232 | r3233 | |
| 1520 | 1520 | |
| 1521 | 1521 | /* configure video */ |
| 1522 | 1522 | segag80r_background_pcb = G80_BACKGROUND_PIGNEWT; |
| 1523 | monsterb_expand_gfx("gfx1"); | |
| 1523 | monsterb_expand_gfx(machine, "gfx1"); | |
| 1524 | 1524 | |
| 1525 | 1525 | /* install background board handlers */ |
| 1526 | 1526 | memory_install_write8_handler(machine, 0, ADDRESS_SPACE_IO, 0xb4, 0xb5, 0, 0, pignewt_back_color_w); |
| r3232 | r3233 | |
|---|---|---|
| 9 | 9 | |
| 10 | 10 | Supported games: |
| 11 | 11 | |
| 12 | Magic's 10 (ver. 16.15) (c) 1995 AWP Games | |
| 13 | Magic's 10 (ver. 16.45) (c) 1995 AWP Games | |
| 14 | Magic's 10 (ver. 16.55) (c) 1995 AWP Games | |
| 15 | Magic's 10 2 (c) 1997 ABM Games | |
| 16 | Super Pool (9743 rev.01) (c) 1997 ABM Games | |
| 17 | Hot Slot (ver. 05.01) (c) 1996 ABM Electronics | |
| 18 | Magic Colors (ver. 1.7a) 1999 Unknown | |
| 12 | Magic's 10 (ver. 16.15), 1995, AWP Games. | |
| 13 | Magic's 10 (ver. 16.45), 1995, AWP Games. | |
| 14 | Magic's 10 (ver. 16.55), 1995, AWP Games. | |
| 15 | Magic's 10 2, 1997, ABM Games. | |
| 16 | Super Pool (9743 rev.01), 1997, ABM Games. | |
| 17 | Hot Slot (ver. 05.01), 1996, ABM Electronics. | |
| 18 | Magic Colors (ver. 1.7a), 1999, Unknown. | |
| 19 | Super Gran Safari (ver 3.11), 1996, New Impeuropex Corp. | |
| 19 | 20 | |
| 20 | 21 | |
| 21 | 22 | ***************************************************************************** |
| 22 | 23 | |
| 23 | 24 | |
| 24 | Magic's 10 instruction for the 1st boot: | |
| 25 | Game Notes | |
| 26 | ========== | |
| 25 | 27 | |
| 28 | ||
| 29 | * Magic's 10 | |
| 30 | ||
| 31 | First time boot instructions: | |
| 32 | ||
| 26 | 33 | - Switch "Disable Free Play" to ON |
| 27 | 34 | - Enter a coin |
| 28 | 35 | - Press Collect to get the 1st game over |
| 29 | 36 | |
| 30 | 37 | |
| 38 | ||
| 39 | * Super Gran Safari | |
| 40 | ||
| 41 | There is a input sequence to initialize the game. | |
| 42 | ||
| 43 | The code expects a mask of 0x4c00 in the DIP switches port to allow | |
| 44 | enter the sequence, so DIP switches must be on default position. | |
| 45 | ||
| 46 | When you see the black screen, enter the following sequence: | |
| 47 | HOLD 4 (key V), HOLD 2 (key X), HOLD 5 (key B), START (key 1). | |
| 48 | ||
| 49 | The code is checking for a 5th entry. In fact expects HOLD 3 as the first | |
| 50 | entry, then the rest listed above. I don't know why bypass the first one. | |
| 51 | Input port bits are checked in the following order: 2, 3, 1, 4, 5. | |
| 52 | ||
| 53 | The player can play the "Super Game" to grab the points. | |
| 54 | In this subgame, you must to hit the lion to get the prize. | |
| 55 | For now, you must miss the shot till hopper & ticket dispenser are properly emulated. | |
| 56 | ||
| 57 | ||
| 58 | ***************************************************************************** | |
| 59 | ||
| 60 | ||
| 31 | 61 | TODO: |
| 32 | 62 | |
| 33 | - ticket / coin dispenser | |
| 34 | - some unknown writes | |
| 35 | - finish magic10_2 (association coin - credits handling its inputs | |
| 63 | - Ticket / Hopper support. | |
| 64 | - Some unknown writes | |
| 65 | - Finish magic10_2 (association coin - credits handling its inputs | |
| 36 | 66 | and some reads that drive the note displayed?) |
| 37 | - protection (suprpool, hotslot, mcolors) | |
| 67 | - protection (magic102, suprpool, hotslot, mcolors). | |
| 38 | 68 | |
| 39 | 69 | |
| 40 | 70 | ****************************************************************************/ |
| r3232 | r3233 | |
| 42 | 72 | |
| 43 | 73 | #include "driver.h" |
| 44 | 74 | #include "sound/okim6295.h" |
| 75 | #include "sgsafari.lh" | |
| 45 | 76 | |
| 46 | 77 | static tilemap *layer0_tilemap, *layer1_tilemap, *layer2_tilemap; |
| 47 | 78 | static UINT16 *layer0_videoram, *layer1_videoram, *layer2_videoram; |
| 48 | 79 | static int layer2_offset[2]; |
| 49 | 80 | |
| 81 | ||
| 82 | /*************************** | |
| 83 | * Video Hardware * | |
| 84 | ***************************/ | |
| 85 | ||
| 50 | 86 | static WRITE16_HANDLER( layer0_videoram_w ) |
| 51 | 87 | { |
| 52 | 88 | COMBINE_DATA(&layer0_videoram[offset]); |
| 53 | tilemap_mark_tile_dirty(layer0_tilemap,offset>>1); | |
| 89 | tilemap_mark_tile_dirty( layer0_tilemap, offset >> 1); | |
| 54 | 90 | } |
| 55 | 91 | |
| 56 | 92 | static WRITE16_HANDLER( layer1_videoram_w ) |
| 57 | 93 | { |
| 58 | 94 | COMBINE_DATA(&layer1_videoram[offset]); |
| 59 | tilemap_mark_tile_dirty(layer1_tilemap,offset>>1); | |
| 95 | tilemap_mark_tile_dirty( layer1_tilemap, offset >> 1); | |
| 60 | 96 | } |
| 61 | 97 | |
| 62 | 98 | static WRITE16_HANDLER( layer2_videoram_w ) |
| 63 | 99 | { |
| 64 | 100 | COMBINE_DATA(&layer2_videoram[offset]); |
| 65 | tilemap_mark_tile_dirty(layer2_tilemap,offset>>1); | |
| 101 | tilemap_mark_tile_dirty( layer2_tilemap, offset >> 1); | |
| 66 | 102 | } |
| 67 | 103 | |
| 68 | 104 | static WRITE16_HANDLER( paletteram_w ) |
| r3232 | r3233 | |
| 71 | 107 | palette_set_color_rgb( machine, offset, pal4bit(data >> 4), pal4bit(data >> 0), pal4bit(data >> 8)); |
| 72 | 108 | } |
| 73 | 109 | |
| 74 | static WRITE16_HANDLER( magic10_misc_w ) | |
| 110 | ||
| 111 | static TILE_GET_INFO( get_layer0_tile_info ) | |
| 75 | 112 | { |
| 76 | /* | |
| 77 | lamps: | |
| 78 | 1 -> data & 0x01 | |
| 79 | 2 -> data & 0x02 | |
| 80 | 3 -> data & 0x04 | |
| 81 | 4 -> data & 0x08 | |
| 82 | 5 -> data & 0x10 | |
| 83 | 6 -> data & 0x20 | |
| 84 | 7 -> data & 0x40 | |
| 85 | */ | |
| 113 | SET_TILE_INFO | |
| 114 | ( | |
| 115 | 1, | |
| 116 | layer0_videoram[tile_index * 2], | |
| 117 | layer0_videoram[tile_index * 2 + 1] & 0x0f, | |
| 118 | TILE_FLIPYX((layer0_videoram[tile_index * 2 + 1] & 0xc0) >> 6) | |
| 119 | ); | |
| 120 | } | |
| 86 | 121 | |
| 87 | /* | |
| 88 | data & 0x0180 toggles | |
| 89 | data & 0x2000 ? written with 0x400 when coin1 is inserted | |
| 90 | */ | |
| 122 | static TILE_GET_INFO( get_layer1_tile_info ) | |
| 123 | { | |
| 124 | SET_TILE_INFO | |
| 125 | ( | |
| 126 | 1, | |
| 127 | layer1_videoram[tile_index * 2], | |
| 128 | layer1_videoram[tile_index * 2 + 1] & 0x0f, | |
| 129 | TILE_FLIPYX((layer1_videoram[tile_index * 2 + 1] & 0xc0) >> 6) | |
| 130 | ); | |
| 131 | } | |
| 91 | 132 | |
| 92 | coin_counter_w(0, data & 0x400); | |
| 133 | static TILE_GET_INFO( get_layer2_tile_info ) | |
| 134 | { | |
| 135 | SET_TILE_INFO | |
| 136 | ( | |
| 137 | 0, | |
| 138 | layer2_videoram[tile_index * 2], | |
| 139 | layer2_videoram[tile_index * 2 + 1] & 0x0f, | |
| 140 | 0 | |
| 141 | ); | |
| 93 | 142 | } |
| 94 | 143 | |
| 144 | ||
| 145 | static VIDEO_START( magic10 ) | |
| 146 | { | |
| 147 | layer0_tilemap = tilemap_create(get_layer0_tile_info, tilemap_scan_rows, 16, 16, 32, 32); | |
| 148 | layer1_tilemap = tilemap_create(get_layer1_tile_info, tilemap_scan_rows, 16, 16, 32, 32); | |
| 149 | layer2_tilemap = tilemap_create(get_layer2_tile_info, tilemap_scan_rows, 8, 8, 64, 64); | |
| 150 | ||
| 151 | tilemap_set_transparent_pen(layer1_tilemap, 0); | |
| 152 | tilemap_set_transparent_pen(layer2_tilemap, 0); | |
| 153 | ||
| 154 | tilemap_set_scrollx(layer2_tilemap, 0, layer2_offset[0]); | |
| 155 | tilemap_set_scrolly(layer2_tilemap, 0, layer2_offset[1]); | |
| 156 | } | |
| 157 | ||
| 158 | static VIDEO_UPDATE( magic10 ) | |
| 159 | { | |
| 160 | tilemap_draw(bitmap, cliprect, layer0_tilemap, 0, 0); | |
| 161 | tilemap_draw(bitmap, cliprect, layer1_tilemap, 0, 0); | |
| 162 | tilemap_draw(bitmap, cliprect, layer2_tilemap, 0, 0); | |
| 163 | ||
| 164 | tilemap_set_scrollx(layer2_tilemap, 0, layer2_offset[0]); | |
| 165 | tilemap_set_scrolly(layer2_tilemap, 0, layer2_offset[1]); | |
| 166 | ||
| 167 | return 0; | |
| 168 | } | |
| 169 | ||
| 170 | ||
| 171 | /*************************** | |
| 172 | * R/W Handlers * | |
| 173 | ***************************/ | |
| 174 | ||
| 95 | 175 | static READ16_HANDLER( magic102_r ) |
| 96 | 176 | { |
| 97 | 177 | static UINT16 ret = 0; |
| r3232 | r3233 | |
| 110 | 190 | logerror("Writting to copro: %d \n", data); |
| 111 | 191 | } |
| 112 | 192 | |
| 113 | static WRITE16_HANDLER( | |
| 193 | static WRITE16_HANDLER( ma | |
| 114 | 194 | { |
| 195 | /* | |
| 196 | ---------------------------------------------- | |
| 197 | --- Super Gran Safari & Magic's 10 Outputs --- | |
| 198 | ---------------------------------------------- | |
| 199 | ||
| 200 | 0x0000 - Normal State (lamps off). | |
| 201 | 0x0001 - Hold 1 lamp. | |
| 202 | 0x0002 - Hold 2 lamp. | |
| 203 | 0x0004 - Hold 3 lamp. | |
| 204 | 0x0008 - Hold 4 lamp. | |
| 205 | 0x0010 - Hold 5 lamp. | |
| 206 | 0x0020 - Start lamp. | |
| 207 | 0x0040 - Play (Bet/Take/Cancel) lamp. | |
| 208 | 0x0100 - Payout lamp. | |
| 209 | 0x0400 - Coin counter. | |
| 210 | ||
| 211 | ||
| 212 | - Lbits - | |
| 213 | 7654 3210 | |
| 214 | ========= | |
| 215 | ---- ---x Hold1 lamp. | |
| 216 | ---- --x- Hold2 lamp. | |
| 217 | ---- -x-- Hold3 lamp. | |
| 218 | ---- x--- Hold4 lamp. | |
| 219 | ---x ---- Hold5 lamp. | |
| 220 | --x- ---- Start lamp. | |
| 221 | -x-- ---- Play (Bet/Take/Cancel) lamp. | |
| 222 | ||
| 223 | - Hbits - | |
| 224 | 7654 3210 | |
| 225 | ========= | |
| 226 | ---- ---x Payout lamp. | |
| 227 | ---- -x-- Coin counter. | |
| 228 | ||
| 229 | */ | |
| 230 | ||
| 231 | // popmessage("lamps: %02X", data); | |
| 232 | ||
| 233 | output_set_lamp_value(1, (data & 1)); /* Lamp 1 - HOLD 1 */ | |
| 234 | output_set_lamp_value(2, (data >> 1) & 1); /* Lamp 2 - HOLD 2 */ | |
| 235 | output_set_lamp_value(3, (data >> 2) & 1); /* Lamp 3 - HOLD 3 */ | |
| 236 | output_set_lamp_value(4, (data >> 3) & 1); /* Lamp 4 - HOLD 4 */ | |
| 237 | output_set_lamp_value(5, (data >> 4) & 1); /* Lamp 5 - HOLD 5 */ | |
| 238 | output_set_lamp_value(6, (data >> 5) & 1); /* Lamp 6 - START */ | |
| 239 | output_set_lamp_value(7, (data >> 6) & 1); /* Lamp 7 - PLAY (BET/TAKE/CANCEL) */ | |
| 240 | output_set_lamp_value(8, (data >> 8) & 1); /* Lamp 8 - PAYOUT/SUPERGAME */ | |
| 241 | ||
| 242 | coin_counter_w(0, data & 0x400); | |
| 243 | } | |
| 244 | ||
| 245 | static WRITE16_HANDLER( vid_reg_1_w ) /* layer pos control */ | |
| 246 | { | |
| 115 | 247 | layer2_offset[0] = -(data - 5); |
| 116 | 248 | } |
| 117 | 249 | |
| 250 | ||
| 251 | /*************************** | |
| 252 | * Memory Maps * | |
| 253 | ***************************/ | |
| 254 | ||
| 118 | 255 | static ADDRESS_MAP_START( magic10_map, ADDRESS_SPACE_PROGRAM, 16 ) |
| 119 | 256 | AM_RANGE(0x000000, 0x03ffff) AM_ROM |
| 120 | 257 | AM_RANGE(0x100000, 0x100fff) AM_RAM_WRITE(layer1_videoram_w) AM_BASE(&layer1_videoram) |
| r3232 | r3233 | |
| 124 | 261 | AM_RANGE(0x300000, 0x3001ff) AM_RAM_WRITE(paletteram_w) AM_BASE(&paletteram16) |
| 125 | 262 | AM_RANGE(0x400000, 0x400001) AM_READ_PORT("INPUTS") |
| 126 | 263 | AM_RANGE(0x400002, 0x400003) AM_READ_PORT("DSW") |
| 127 | AM_RANGE(0x400008, 0x400009) AM_WRITE(magic10_ | |
| 264 | AM_RANGE(0x400008, 0x400009) AM_WRITE(magic10_out | |
| 128 | 265 | AM_RANGE(0x40000a, 0x40000b) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) |
| 129 | 266 | AM_RANGE(0x40000e, 0x40000f) AM_WRITENOP |
| 130 | 267 | AM_RANGE(0x400080, 0x400087) AM_WRITENOP // video registers? |
| r3232 | r3233 | |
| 140 | 277 | AM_RANGE(0x300000, 0x3001ff) AM_RAM_WRITE(paletteram_w) AM_BASE(&paletteram16) |
| 141 | 278 | AM_RANGE(0x500000, 0x500001) AM_READ_PORT("INPUTS") |
| 142 | 279 | AM_RANGE(0x500002, 0x500003) AM_READ_PORT("DSW") |
| 143 | AM_RANGE(0x500008, 0x500009) AM_WRITE(magic10_ | |
| 280 | AM_RANGE(0x500008, 0x500009) AM_WRITE(magic10_out | |
| 144 | 281 | AM_RANGE(0x50000a, 0x50000b) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) |
| 145 | 282 | AM_RANGE(0x50000e, 0x50000f) AM_WRITENOP |
| 146 | 283 | AM_RANGE(0x500080, 0x500087) AM_WRITENOP // video registers? |
| r3232 | r3233 | |
| 188 | 325 | AM_RANGE(0x700086, 0x700087) AM_WRITENOP // video registers |
| 189 | 326 | ADDRESS_MAP_END |
| 190 | 327 | |
| 328 | static ADDRESS_MAP_START( sgsafari_map, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 329 | AM_RANGE(0x000000, 0x03ffff) AM_ROM | |
| 330 | AM_RANGE(0x100000, 0x100fff) AM_RAM_WRITE(layer1_videoram_w) AM_BASE(&layer1_videoram) | |
| 331 | AM_RANGE(0x101000, 0x101fff) AM_RAM_WRITE(layer0_videoram_w) AM_BASE(&layer0_videoram) | |
| 332 | AM_RANGE(0x102000, 0x103fff) AM_RAM_WRITE(layer2_videoram_w) AM_BASE(&layer2_videoram) | |
| 333 | AM_RANGE(0x200000, 0x203fff) AM_RAM AM_BASE(&generic_nvram16) AM_SIZE(&generic_nvram_size) | |
| 334 | AM_RANGE(0x300000, 0x3001ff) AM_RAM_WRITE(paletteram_w) AM_BASE(&paletteram16) | |
| 335 | AM_RANGE(0x500002, 0x500003) AM_READ_PORT("DSW1") | |
| 336 | AM_RANGE(0x500008, 0x500009) AM_WRITE(magic10_out_w) | |
| 337 | AM_RANGE(0x50000a, 0x50000b) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) | |
| 338 | AM_RANGE(0x50000e, 0x50000f) AM_READ_PORT("IN0") | |
| 339 | AM_RANGE(0x600000, 0x603fff) AM_RAM | |
| 340 | ADDRESS_MAP_END | |
| 341 | /* | |
| 191 | 342 | |
| 343 | SGSafari unimplemented writes: | |
| 192 | 344 | |
| 345 | 0x500000 - 0x500007 ; unknown. | |
| 346 | 0x50000c - 0x50007f ; unknown. | |
| 347 | 0x500080 - 0x500083 ; video registers (layer scroll) | |
| 348 | 0x500084 - 0x500087 ; video registers (unknown) | |
| 349 | 0x500088 - 0x5000ff ; unknown. | |
| 350 | ||
| 351 | */ | |
| 352 | ||
| 353 | /*************************** | |
| 354 | * Input Ports * | |
| 355 | ***************************/ | |
| 356 | ||
| 193 | 357 | static INPUT_PORTS_START( magic10 ) |
| 194 | 358 | PORT_START("INPUTS") |
| 195 | 359 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("Hold 1") PORT_CODE(KEYCODE_Z) |
| r3232 | r3233 | |
| 198 | 362 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("Hold 4") PORT_CODE(KEYCODE_V) |
| 199 | 363 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("Hold 5") PORT_CODE(KEYCODE_B) |
| 200 | 364 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_START1 ) |
| 201 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_ | |
| 365 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_NAME("Play (Bet/Take)") PORT_CODE(KEYCODE_A) | |
| 202 | 366 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_OTHER ) PORT_NAME("Lots FC") PORT_CODE(KEYCODE_S) |
| 203 | 367 | PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 204 | 368 | PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_COIN2 ) PORT_NAME("Note A") |
| r3232 | r3233 | |
| 207 | 371 | PORT_SERVICE_NO_TOGGLE( 0x1000, IP_ACTIVE_LOW ) |
| 208 | 372 | PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_OTHER ) PORT_NAME("Out Hole") PORT_CODE(KEYCODE_D) |
| 209 | 373 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_COIN5 ) PORT_NAME("Note D") PORT_CODE(KEYCODE_9) |
| 210 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_ | |
| 374 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_NAME("Collect") PORT_CODE(KEYCODE_M) | |
| 211 | 375 | |
| 212 | 376 | PORT_START("DSW") |
| 213 | 377 | PORT_DIPNAME( 0x0001, 0x0001, "Display Logo" ) |
| r3232 | r3233 | |
| 386 | 550 | PORT_DIPSETTING( 0x80, "Tickets Only" ) |
| 387 | 551 | PORT_DIPSETTING( 0xc0, "Tickets & Tokens" ) |
| 388 | 552 | PORT_BIT( 0xff00, IP_ACTIVE_HIGH, IPT_UNUSED ) |
| 389 | ||
| 390 | 553 | INPUT_PORTS_END |
| 391 | 554 | |
| 392 | static TILE_GET_INFO( get_layer0_tile_info ) | |
| 393 | { | |
| 394 | SET_TILE_INFO(1,layer0_videoram[tile_index*2],layer0_videoram[tile_index*2+1] & 0xf,TILE_FLIPYX((layer0_videoram[tile_index*2+1] & 0xc0) >> 6)); | |
| 395 | } | |
| 555 | static INPUT_PORTS_START( sgsafari ) | |
| 556 | PORT_START("IN0") | |
| 557 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("Hold 1") PORT_CODE(KEYCODE_Z) | |
| 558 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("Hold 2 / Head") PORT_CODE(KEYCODE_X) | |
| 559 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_NAME("Hold 3") PORT_CODE(KEYCODE_C) | |
| 560 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("Hold 4 / Tail") PORT_CODE(KEYCODE_V) | |
| 561 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("Hold 5 / Half Gamble") PORT_CODE(KEYCODE_B) | |
| 562 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_START1 ) PORT_NAME("Start") | |
| 563 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_NAME("Play (Bet/Take/Cancel)") PORT_CODE(KEYCODE_A) | |
| 564 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 396 | 565 | |
| 397 | static TILE_GET_INFO( get_layer1_tile_info ) | |
| 398 | { | |
| 399 | SET_TILE_INFO(1,layer1_videoram[tile_index*2],layer1_videoram[tile_index*2+1] & 0xf,TILE_FLIPYX((layer1_videoram[tile_index*2+1] & 0xc0) >> 6)); | |
| 400 | } | |
| 566 | PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) PORT_NAME("Coin 1") | |
| 567 | PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_COIN2 ) PORT_NAME("Coin 2") | |
| 568 | PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_COIN3 ) PORT_NAME("Note B") | |
| 569 | PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_COIN4 ) PORT_NAME("Note C") | |
| 570 | PORT_SERVICE_NO_TOGGLE( 0x1000, IP_ACTIVE_LOW ) | |
| 571 | PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 572 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_COIN5 ) PORT_NAME("Note D") PORT_CODE(KEYCODE_9) | |
| 573 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_BUTTON7 ) PORT_NAME("Payout / Super Game") PORT_CODE(KEYCODE_W) | |
| 401 | 574 | |
| 402 | static TILE_GET_INFO( get_layer2_tile_info ) | |
| 403 | { | |
| 404 | SET_TILE_INFO(0,layer2_videoram[tile_index*2],layer2_videoram[tile_index*2+1] & 0xf,0); | |
| 405 | } | |
| 575 | PORT_START("DSW1") | |
| 576 | PORT_BIT( 0x00ff, IP_ACTIVE_HIGH, IPT_UNUSED ) | |
| 577 | PORT_DIPNAME( 0x0300, 0x0000, DEF_STR( Difficulty ) ) PORT_DIPLOCATION("SW1:1,2") | |
| 578 | PORT_DIPSETTING( 0x0300, DEF_STR( Easy ) ) | |
| 579 | PORT_DIPSETTING( 0x0200, DEF_STR( Normal ) ) | |
| 580 | PORT_DIPSETTING( 0x0100, DEF_STR( Hard ) ) | |
| 581 | PORT_DIPSETTING( 0x0000, DEF_STR( Hardest ) ) | |
| 582 | PORT_DIPNAME( 0x0c00, 0x0c00, DEF_STR( Coinage ) ) | |
| 583 | PORT_DIPSETTING( 0x0c00, DEF_STR( 1C_1C ) ) PORT_DIPLOCATION("SW1:3,4") | |
| 584 | PORT_DIPSETTING( 0x0800, DEF_STR( 1C_2C ) ) | |
| 585 | PORT_DIPSETTING( 0x0400, DEF_STR( 1C_4C ) ) | |
| 586 | PORT_DIPSETTING( 0x0000, "1 Coin/10 Credits" ) | |
| 587 | PORT_DIPNAME( 0x3000, 0x0000, "Payout Options" ) PORT_DIPLOCATION("SW1:5,6") | |
| 588 | PORT_DIPSETTING( 0x3000, "Pay at 100 points" ) | |
| 589 | PORT_DIPSETTING( 0x2000, "Pay at 200 points" ) | |
| 590 | PORT_DIPSETTING( 0x1000, "Pay at 400 points" ) | |
| 591 | PORT_DIPSETTING( 0x0000, "Pay at 500 points" ) | |
| 592 | PORT_DIPNAME( 0x4000, 0x4000, "Tickets" ) PORT_DIPLOCATION("SW1:7") | |
| 593 | PORT_DIPSETTING( 0x4000, DEF_STR( Off ) ) | |
| 594 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 595 | PORT_DIPNAME( 0x8000, 0x0000, "Hopper" ) PORT_DIPLOCATION("SW1:8") | |
| 596 | PORT_DIPSETTING( 0x8000, DEF_STR( Off ) ) | |
| 597 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 598 | INPUT_PORTS_END | |
| 406 | 599 | |
| 407 | 600 | |
| 408 | static VIDEO_START( magic10 ) | |
| 409 | { | |
| 410 | layer0_tilemap = tilemap_create(get_layer0_tile_info,tilemap_scan_rows,16,16,32,32); | |
| 411 | layer1_tilemap = tilemap_create(get_layer1_tile_info,tilemap_scan_rows,16,16,32,32); | |
| 412 | layer2_tilemap = tilemap_create(get_layer2_tile_info,tilemap_scan_rows, 8, 8,64,64); | |
| 601 | /**************************** | |
| 602 | * Graphics Layouts * | |
| 603 | ****************************/ | |
| 413 | 604 | |
| 414 | tilemap_set_transparent_pen(layer1_tilemap,0); | |
| 415 | tilemap_set_transparent_pen(layer2_tilemap,0); | |
| 416 | ||
| 417 | tilemap_set_scrollx(layer2_tilemap,0,layer2_offset[0]); | |
| 418 | tilemap_set_scrolly(layer2_tilemap,0,layer2_offset[1]); | |
| 419 | } | |
| 420 | ||
| 421 | static VIDEO_UPDATE( magic10 ) | |
| 422 | { | |
| 423 | tilemap_draw(bitmap,cliprect,layer0_tilemap,0,0); | |
| 424 | tilemap_draw(bitmap,cliprect,layer1_tilemap,0,0); | |
| 425 | tilemap_draw(bitmap,cliprect,layer2_tilemap,0,0); | |
| 426 | ||
| 427 | tilemap_set_scrollx(layer2_tilemap,0,layer2_offset[0]); | |
| 428 | tilemap_set_scrolly(layer2_tilemap,0,layer2_offset[1]); | |
| 429 | ||
| 430 | return 0; | |
| 431 | } | |
| 432 | ||
| 433 | 605 | static const gfx_layout tiles8x8_layout = |
| 434 | 606 | { |
| 435 | 607 | 8,8, |
| 436 | 608 | RGN_FRAC(1,4), |
| 437 | 609 | 4, |
| 438 | { RGN_FRAC(3,4),RGN_FRAC(2,4),RGN_FRAC(1,4),RGN_FRAC(0,4) }, | |
| 610 | { RGN_FRAC(3,4), RGN_FRAC(2,4), RGN_FRAC(1,4), RGN_FRAC(0,4) }, | |
| 439 | 611 | { 0, 1, 2, 3, 4, 5, 6, 7 }, |
| 440 | 612 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 }, |
| 441 | 613 | 8*8 |
| r3232 | r3233 | |
| 454 | 626 | 32*8 |
| 455 | 627 | }; |
| 456 | 628 | |
| 629 | ||
| 630 | /**************************** | |
| 631 | * Graphics Decode * | |
| 632 | ****************************/ | |
| 633 | ||
| 457 | 634 | static GFXDECODE_START( magic10 ) |
| 458 | 635 | GFXDECODE_ENTRY( "gfx1", 0, tiles8x8_layout, 0, 16 ) |
| 459 | 636 | GFXDECODE_ENTRY( "gfx1", 0, tiles16x16_layout, 0, 16 ) |
| 460 | 637 | GFXDECODE_END |
| 461 | 638 | |
| 639 | ||
| 640 | /**************************** | |
| 641 | * Machine Drivers * | |
| 642 | ****************************/ | |
| 643 | ||
| 462 | 644 | static MACHINE_DRIVER_START( magic10 ) |
| 645 | /* basic machine hardware */ | |
| 463 | 646 | MDRV_CPU_ADD("cpu", M68000, 10000000) // ? |
| 464 | 647 | MDRV_CPU_PROGRAM_MAP(magic10_map,0) |
| 465 | 648 | MDRV_CPU_VBLANK_INT("main", irq1_line_hold) |
| 466 | 649 | |
| 467 | 650 | MDRV_NVRAM_HANDLER(generic_0fill) |
| 468 | 651 | |
| 469 | ||
| 470 | 652 | MDRV_SCREEN_ADD("main", RASTER) |
| 471 | 653 | MDRV_SCREEN_REFRESH_RATE(60) |
| 472 | 654 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| r3232 | r3233 | |
| 480 | 662 | MDRV_VIDEO_START(magic10) |
| 481 | 663 | MDRV_VIDEO_UPDATE(magic10) |
| 482 | 664 | |
| 665 | /* sound hardware */ | |
| 483 | 666 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 484 | ||
| 485 | 667 | MDRV_SOUND_ADD("oki", OKIM6295, 1056000) |
| 486 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) | |
| 668 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) /* clock frequency & pin 7 not verified */ | |
| 487 | 669 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 488 | 670 | MACHINE_DRIVER_END |
| 489 | 671 | |
| 672 | ||
| 490 | 673 | static MACHINE_DRIVER_START( magic10a ) |
| 491 | ||
| 492 | 674 | /* basic machine hardware */ |
| 493 | 675 | MDRV_IMPORT_FROM(magic10) |
| 494 | 676 | MDRV_CPU_MODIFY("cpu") |
| 495 | 677 | MDRV_CPU_PROGRAM_MAP(magic10a_map,0) |
| 496 | 678 | MACHINE_DRIVER_END |
| 497 | 679 | |
| 680 | ||
| 498 | 681 | static MACHINE_DRIVER_START( magic102 ) |
| 499 | ||
| 500 | 682 | /* basic machine hardware */ |
| 501 | 683 | MDRV_IMPORT_FROM(magic10) |
| 502 | 684 | MDRV_CPU_MODIFY("cpu") |
| r3232 | r3233 | |
| 506 | 688 | MDRV_SCREEN_VISIBLE_AREA(0*8, 48*8-1, 0*8, 30*8-1) |
| 507 | 689 | MACHINE_DRIVER_END |
| 508 | 690 | |
| 691 | ||
| 509 | 692 | static MACHINE_DRIVER_START( hotslot ) |
| 510 | ||
| 511 | 693 | /* basic machine hardware */ |
| 512 | 694 | MDRV_IMPORT_FROM(magic10) |
| 513 | 695 | MDRV_CPU_MODIFY("cpu") |
| r3232 | r3233 | |
| 517 | 699 | MDRV_SCREEN_VISIBLE_AREA(8*8, 56*8-1, 2*8, 32*8-1) |
| 518 | 700 | MACHINE_DRIVER_END |
| 519 | 701 | |
| 702 | ||
| 703 | static MACHINE_DRIVER_START( sgsafari ) | |
| 704 | /* basic machine hardware */ | |
| 705 | MDRV_IMPORT_FROM(magic10) | |
| 706 | MDRV_CPU_MODIFY("cpu") | |
| 707 | MDRV_CPU_PROGRAM_MAP(sgsafari_map,0) | |
| 708 | MDRV_CPU_VBLANK_INT("main", irq2_line_hold) /* L1 interrupts */ | |
| 709 | ||
| 710 | MDRV_SCREEN_MODIFY("main") | |
| 711 | MDRV_SCREEN_VISIBLE_AREA(0*8, 44*8-1, 0*8, 30*8-1) | |
| 712 | MACHINE_DRIVER_END | |
| 713 | ||
| 714 | ||
| 715 | /**************************** | |
| 716 | * Rom Loads * | |
| 717 | ****************************/ | |
| 718 | ||
| 520 | 719 | /* |
| 521 | 720 | |
| 522 | 721 | Magic 10 (videopoker) |
| r3232 | r3233 | |
| 530 | 729 | 1x Dallas Ds1220y-200 Nonvolatile ram |
| 531 | 730 | |
| 532 | 731 | */ |
| 533 | ||
| 534 | 732 | ROM_START( magic10 ) |
| 535 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 733 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 536 | 734 | ROM_LOAD16_BYTE( "u3.bin", 0x000000, 0x20000, CRC(191a46f4) SHA1(65bc22cdcc4b2f102d3eef595626819af709cacb) ) |
| 537 | 735 | ROM_LOAD16_BYTE( "u2.bin", 0x000001, 0x20000, CRC(a03a80bc) SHA1(a21da8912f1d2c8c2fa4a8d3ce4d43da8a934e21) ) |
| 538 | 736 | |
| 539 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* | |
| 737 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* tiles */ | |
| 540 | 738 | ROM_LOAD( "u25.bin", 0x00000, 0x20000, CRC(7abb8136) SHA1(1d4daf6a4477853d89d08afb524516ef79f60dd6) ) |
| 541 | 739 | ROM_LOAD( "u26.bin", 0x20000, 0x20000, CRC(fd0b912d) SHA1(1cd15fa3459e7fece9fc37595f2b6848c00ffa43) ) |
| 542 | 740 | ROM_LOAD( "u27.bin", 0x40000, 0x20000, CRC(8178c907) SHA1(8c3440769ed4e113d84d1f8f9079783497791859) ) |
| 543 | 741 | ROM_LOAD( "u28.bin", 0x60000, 0x20000, CRC(dfd41aab) SHA1(82248c7fa4febb1c453f35a0e4cfae062c5da2d5) ) |
| 544 | 742 | |
| 545 | ROM_REGION( 0x40000, "oki", 0 ) /* | |
| 743 | ROM_REGION( 0x40000, "oki", 0 ) /* ADPCM samples */ | |
| 546 | 744 | ROM_LOAD( "u22.bin", 0x00000, 0x40000, CRC(98885246) SHA1(752d549e6248074f2a7f6c5cc4d0bbc44c7fa4c3) ) |
| 547 | 745 | ROM_END |
| 548 | 746 | |
| 549 | 747 | ROM_START( magic10a ) |
| 550 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 748 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 551 | 749 | ROM_LOAD16_BYTE( "u3_1645.bin", 0x00000, 0x20000, CRC(7f2549e4) SHA1(6578ad29273c357faae7c6be3fa1b49087e088a2) ) |
| 552 | 750 | ROM_LOAD16_BYTE( "u2_1645.bin", 0x00001, 0x20000, CRC(c075234e) SHA1(d9bc38f0b984082a77088fbb52b02c8f5c49846c) ) |
| 553 | 751 | |
| 554 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* | |
| 752 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* tiles */ | |
| 555 | 753 | ROM_LOAD( "u25.bin", 0x00000, 0x20000, CRC(7abb8136) SHA1(1d4daf6a4477853d89d08afb524516ef79f60dd6) ) |
| 556 | 754 | ROM_LOAD( "u26.bin", 0x20000, 0x20000, CRC(fd0b912d) SHA1(1cd15fa3459e7fece9fc37595f2b6848c00ffa43) ) |
| 557 | 755 | ROM_LOAD( "u27.bin", 0x40000, 0x20000, CRC(8178c907) SHA1(8c3440769ed4e113d84d1f8f9079783497791859) ) |
| 558 | 756 | ROM_LOAD( "u28.bin", 0x60000, 0x20000, CRC(dfd41aab) SHA1(82248c7fa4febb1c453f35a0e4cfae062c5da2d5) ) |
| 559 | 757 | |
| 560 | ROM_REGION( 0x40000, "oki", 0 ) /* | |
| 758 | ROM_REGION( 0x40000, "oki", 0 ) /* ADPCM samples */ | |
| 561 | 759 | ROM_LOAD( "u22.bin", 0x00000, 0x40000, CRC(98885246) SHA1(752d549e6248074f2a7f6c5cc4d0bbc44c7fa4c3) ) |
| 562 | 760 | ROM_END |
| 563 | 761 | |
| r3232 | r3233 | |
| 594 | 792 | 1x battery |
| 595 | 793 | |
| 596 | 794 | */ |
| 597 | ||
| 598 | 795 | ROM_START( magic10b ) |
| 599 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 796 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 600 | 797 | ROM_LOAD16_BYTE( "2.u3", 0x000000, 0x20000, CRC(32c12ad6) SHA1(93340df2c0f4c260837bd6649008e26a17a22015) ) |
| 601 | 798 | ROM_LOAD16_BYTE( "3.u2", 0x000001, 0x20000, CRC(a9945aaa) SHA1(97d4f6441b96618f2e3ce14095ffc5628cb14f0e) ) |
| 602 | 799 | |
| 603 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* | |
| 800 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* tiles */ | |
| 604 | 801 | ROM_LOAD( "6.u25", 0x00000, 0x20000, CRC(7abb8136) SHA1(1d4daf6a4477853d89d08afb524516ef79f60dd6) ) |
| 605 | 802 | ROM_LOAD( "4.u26", 0x20000, 0x20000, CRC(fd0b912d) SHA1(1cd15fa3459e7fece9fc37595f2b6848c00ffa43) ) |
| 606 | 803 | ROM_LOAD( "5.u27", 0x40000, 0x20000, CRC(8178c907) SHA1(8c3440769ed4e113d84d1f8f9079783497791859) ) |
| 607 | 804 | ROM_LOAD( "7.u28", 0x60000, 0x20000, CRC(dfd41aab) SHA1(82248c7fa4febb1c453f35a0e4cfae062c5da2d5) ) |
| 608 | 805 | |
| 609 | ROM_REGION( 0x40000, "oki", 0 ) /* | |
| 806 | ROM_REGION( 0x40000, "oki", 0 ) /* ADPCM samples */ | |
| 610 | 807 | ROM_LOAD( "1.u22", 0x00000, 0x40000, CRC(98885246) SHA1(752d549e6248074f2a7f6c5cc4d0bbc44c7fa4c3) ) |
| 611 | 808 | ROM_END |
| 612 | 809 | |
| r3232 | r3233 | |
| 624 | 821 | 1x oki6295 |
| 625 | 822 | |
| 626 | 823 | */ |
| 627 | ||
| 628 | 824 | ROM_START( magic102 ) |
| 629 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 825 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 630 | 826 | ROM_LOAD16_BYTE( "2.u3", 0x00000, 0x20000, CRC(6fc55fe4) SHA1(392ad92e55aeac9bf5235cceb6b0b415942105a4) ) |
| 631 | 827 | ROM_LOAD16_BYTE( "1.u2", 0x00001, 0x20000, CRC(501507af) SHA1(ceed50c9380a9838cd3d171d2387334edfeff77f) ) |
| 632 | 828 | |
| 633 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* | |
| 829 | ROM_REGION( 0x80000, "gfx1", ROMREGION_DISPOSE ) /* tiles */ | |
| 634 | 830 | ROM_LOAD( "3.u35", 0x00000, 0x20000, CRC(df47bb12) SHA1(b8bcbc9ab764d3159344d93776d13a14c9154086) ) |
| 635 | 831 | ROM_LOAD( "4.u36", 0x20000, 0x20000, CRC(dc242034) SHA1(6a2983c79776df07f29b77f23799fef6f20df24f) ) |
| 636 | 832 | ROM_LOAD( "5.u37", 0x40000, 0x20000, CRC(a048e26e) SHA1(788c28470298896902120e74fd8b9b283b8e9b79) ) |
| 637 | 833 | ROM_LOAD( "6.u38", 0x60000, 0x20000, CRC(469efb34) SHA1(b16646fb0c4757132e272b3877cf546b6f616786) ) |
| 638 | 834 | |
| 639 | ROM_REGION( 0x40000, "oki", 0 ) /* | |
| 835 | ROM_REGION( 0x40000, "oki", 0 ) /* ADPCM samples */ | |
| 640 | 836 | ROM_LOAD( "7.u32", 0x00000, 0x40000, CRC(47804af7) SHA1(602dc0361869b52532e2adcb0de3cbdd042761b3) ) |
| 641 | 837 | ROM_END |
| 642 | 838 | |
| r3232 | r3233 | |
| 681 | 877 | Fixed layers = yes. |
| 682 | 878 | |
| 683 | 879 | */ |
| 684 | ||
| 685 | 880 | ROM_START( suprpool ) |
| 686 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 881 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 687 | 882 | ROM_LOAD16_BYTE( "2-1.22a.u3", 0x00000, 0x20000,CRC(5d15037a) SHA1(74cab79a1b08910267262a4c6b501126a4df6cda) ) |
| 688 | 883 | ROM_LOAD16_BYTE( "3-1.22a.u2", 0x00001, 0x20000,CRC(c762cd1c) SHA1(ee05a9e8147d613eb14333e6e7b743fc05982e7c) ) |
| 689 | 884 | |
| 690 | ROM_REGION( 0x80000, "gfx1", 0 ) /* | |
| 885 | ROM_REGION( 0x80000, "gfx1", 0 ) /* g | |
| 691 | 886 | ROM_LOAD( "7.u35", 0x00000, 0x20000, CRC(357d145f) SHA1(9fea0d0c5d6c27bf520c4f81eb0f48a65ff60142) ) |
| 692 | 887 | ROM_LOAD( "6.u36", 0x20000, 0x20000, CRC(c4448813) SHA1(6e168eb8503b852179f2d743f1cba935592e0a60) ) |
| 693 | 888 | ROM_LOAD( "5.u37", 0x40000, 0x20000, CRC(6e99af07) SHA1(85e7a76724fd9ce8d07b5088cb6e0d933fd95692) ) |
| 694 | 889 | ROM_LOAD( "4.u38", 0x60000, 0x20000, CRC(0660a169) SHA1(1cb34b3da4b144028519a3c5b32ef7da44af0624) ) |
| 695 | 890 | |
| 696 | ROM_REGION( 0x080000, "oki", 0 ) /* | |
| 891 | ROM_REGION( 0x080000, "oki", 0 ) /* ADPCM samples */ | |
| 697 | 892 | ROM_LOAD( "1.u32", 0x00000, 0x40000, CRC(47804af7) SHA1(602dc0361869b52532e2adcb0de3cbdd042761b3) ) |
| 698 | 893 | ROM_END |
| 699 | 894 | |
| r3232 | r3233 | |
| 752 | 947 | Fixed layers = yes. |
| 753 | 948 | |
| 754 | 949 | */ |
| 755 | ||
| 756 | 950 | ROM_START( hotslot ) |
| 757 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 951 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 758 | 952 | ROM_LOAD16_BYTE( "hotslot2.u3", 0x00000, 0x20000, CRC(676cbe32) SHA1(78721326f3334fcdfdaffb72dbcacfb8bb591d51) ) |
| 759 | 953 | ROM_LOAD16_BYTE( "hotslot3.u2", 0x00001, 0x20000, CRC(2c362765) SHA1(c41741c97fe8e5b3a66eb08ebf68d24c6c771ba8) ) |
| 760 | 954 | |
| 761 | ROM_REGION( 0x100000, "gfx1", 0 ) /* | |
| 955 | ROM_REGION( 0x100000, "gfx1", 0 ) /* g | |
| 762 | 956 | ROM_LOAD( "hotslot7.u35", 0x00000, 0x40000, CRC(715073c2) SHA1(39085871fee182a9b22c3e042211e76da0ee3024) ) |
| 763 | 957 | ROM_LOAD( "hotslot6.u36", 0x40000, 0x40000, CRC(8ef2e25a) SHA1(d4a3288878fabab7ea193d5dadde1fe9fea6bc8a) ) |
| 764 | 958 | ROM_LOAD( "hotslot5.u37", 0x80000, 0x40000, CRC(98375b25) SHA1(2167f3374bdfc5e1fef7b9ec4361bc68223876b8) ) |
| 765 | 959 | ROM_LOAD( "hotslot4.u38", 0xc0000, 0x40000, CRC(cc8a241a) SHA1(8c6ea51d5f7475be79775df0b976ffddc5a960ed) ) |
| 766 | 960 | |
| 767 | ROM_REGION( 0x080000, "oki", 0 ) /* | |
| 961 | ROM_REGION( 0x080000, "oki", 0 ) /* ADPCM samples */ | |
| 768 | 962 | ROM_LOAD( "hotslot1.u32", 0x00000, 0x40000, CRC(ae880970) SHA1(3c302b3f6f6bbf72a522889592add3b6ef8ce1b0) ) |
| 769 | 963 | ROM_END |
| 770 | 964 | |
| r3232 | r3233 | |
| 807 | 1001 | Fixed layers = yes. |
| 808 | 1002 | |
| 809 | 1003 | */ |
| 810 | ||
| 811 | 1004 | ROM_START( mcolors ) |
| 812 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 | |
| 1005 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 813 | 1006 | ROM_LOAD16_BYTE( "m.colors1.7a-2.u3", 0x00000, 0x20000, CRC(02ce6aab) SHA1(349cb639024a818cb88e911788a0146f48d25333) ) |
| 814 | 1007 | ROM_LOAD16_BYTE( "m.colors1.7a-3.u2", 0x00001, 0x20000, CRC(076b9680) SHA1(856d1cfaca886d78a36e129a7b41455362932e66) ) |
| 815 | 1008 | |
| 816 | ROM_REGION( 0x80000, "gfx1", 0 ) /* | |
| 1009 | ROM_REGION( 0x80000, "gfx1", 0 ) /* g | |
| 817 | 1010 | ROM_LOAD( "m.colors1.7-7.u35", 0x00000, 0x20000, CRC(ec44b289) SHA1(269c965112f0ba308bb5f02d965e32df70310b2c) ) |
| 818 | 1011 | ROM_LOAD( "m.colors1.7-6.u36", 0x20000, 0x20000, CRC(44e550e2) SHA1(abfc05b386efb0f9ad7479ff53079e6ecbaec137) ) |
| 819 | 1012 | ROM_LOAD( "m.colors1.7-5.u37", 0x40000, 0x20000, CRC(ec363d0d) SHA1(283f0bf3e3d76d64389f0abdffbeaa3d538b8991) ) |
| 820 | 1013 | ROM_LOAD( "m.colors1.7-4.u38", 0x60000, 0x20000, CRC(7845667d) SHA1(66b1409b8b661b95e2658385da9c2662430d8030) ) |
| 821 | 1014 | |
| 822 | ROM_REGION( 0x080000, "oki", 0 ) /* | |
| 1015 | ROM_REGION( 0x080000, "oki", 0 ) /* ADPCM samples */ | |
| 823 | 1016 | ROM_LOAD( "m.color1.u32", 0x00000, 0x40000, CRC(db8d6769) SHA1(2ab7730fd8ae9522e5452fe1f535002e11db5e7b) ) |
| 824 | 1017 | ROM_END |
| 825 | 1018 | |
| 1019 | /* | |
| 826 | 1020 | |
| 1021 | Super Gran Safari | |
| 1022 | 1996 - New Impeuropex Corp. | |
| 1023 | ||
| 1024 | CPU: | |
| 1025 | 1x MC68000P12 (main) | |
| 1026 | 2x A1020B-PL84C (not dumped) | |
| 1027 | ||
| 1028 | 1x M6295 (sound) | |
| 1029 | 1x TDA2002 (sound) | |
| 1030 | 1x GL324 (sound) | |
| 1031 | ||
| 1032 | 1x oscillator 30.000MHz | |
| 1033 | ||
| 1034 | ROMs: | |
| 1035 | 2x M27C512 (1,2) | |
| 1036 | 1x M27C2001 (3) | |
| 1037 | 4x M27C1001 (4,5,6,7) | |
| 1038 | ||
| 1039 | Note: | |
| 1040 | 1x JAMMA edge connector | |
| 1041 | 1x 12 legs connector (j2) | |
| 1042 | 1x 8x2 switches dip | |
| 1043 | 1x 4 legs jumper (j3) | |
| 1044 | 1x 2 legs jumper (j4) | |
| 1045 | 1x trimmer (volume) | |
| 1046 | ||
| 1047 | ||
| 1048 | STATUS: | |
| 1049 | ||
| 1050 | Memory map = done. | |
| 1051 | Inputs = done. | |
| 1052 | Machine = done. | |
| 1053 | ||
| 1054 | OKI 6295 = ok. | |
| 1055 | Screen size = ok. | |
| 1056 | Fixed layers = yes. | |
| 1057 | ||
| 1058 | */ | |
| 1059 | ROM_START( sgsafari ) | |
| 1060 | ROM_REGION( 0x40000, "cpu", 0 ) /* 68000 code */ | |
| 1061 | ROM_LOAD16_BYTE( "2.u7", 0x00000, 0x10000, CRC(797ceeac) SHA1(19055b6700f8523785790992adfeb67faa2358e0) ) | |
| 1062 | ROM_LOAD16_BYTE( "1.u2", 0x00001, 0x10000, CRC(549872f5) SHA1(2228c51541e3b059d5b16f50387e4215b82f78f6) ) | |
| 1063 | ||
| 1064 | ROM_REGION( 0x80000, "gfx1", 0 ) /* graphics */ | |
| 1065 | ROM_LOAD( "4.u15", 0x00000, 0x20000, CRC(f9233481) SHA1(1d1aca9a61f0285a6f6f12f6169d9cfc2c5e6991) ) | |
| 1066 | ROM_LOAD( "5.u18", 0x20000, 0x20000, CRC(9561aa47) SHA1(140e0d9104c677de911d4d12ff617d84449d907b) ) | |
| 1067 | ROM_LOAD( "6.u16", 0x40000, 0x20000, CRC(91c22541) SHA1(e419a2d5e71b6c64992a08fa9bd82718350ca7da) ) | |
| 1068 | ROM_LOAD( "7.u19", 0x60000, 0x20000, CRC(3e3a5fbd) SHA1(c3511b488ecb4759a5fdea478007a4a1c2b5f9e0) ) | |
| 1069 | ||
| 1070 | ROM_REGION( 0x040000, "oki", 0 ) /* ADPCM samples */ | |
| 1071 | ROM_LOAD( "3.u39", 0x00000, 0x40000, CRC(43257bb5) SHA1(993fbeb6ee0a8a4da185303ec24eee8424b90cd0) ) | |
| 1072 | ROM_END | |
| 1073 | ||
| 1074 | ||
| 1075 | /**************************** | |
| 1076 | * Driver Init * | |
| 1077 | ****************************/ | |
| 1078 | ||
| 827 | 1079 | static DRIVER_INIT( magic10 ) |
| 828 | 1080 | { |
| 829 | 1081 | layer2_offset[0] = 32; |
| r3232 | r3233 | |
| 851 | 1103 | layer2_offset[1] = 0; // Y offset. |
| 852 | 1104 | } |
| 853 | 1105 | |
| 1106 | static DRIVER_INIT( sgsafari ) | |
| 1107 | { | |
| 1108 | layer2_offset[0] = 16; | |
| 1109 | layer2_offset[1] = 20; | |
| 1110 | } | |
| 854 | 1111 | |
| 855 | GAME( 1995, magic10, 0, magic10, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.55)", 0 ) | |
| 856 | GAME( 1995, magic10a, magic10, magic10a, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.45)", 0 ) | |
| 857 | GAME( 1995, magic10b, magic10, magic10a, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.15)", 0 ) | |
| 858 | GAME( 1997, magic102, 0, magic102, magic102, magic102, ROT0, "ABM Games", "Magic's 10 2 (ver 1.1)", GAME_NOT_WORKING ) | |
| 859 | GAME( 1997, suprpool, 0, magic102, magic102, suprpool, ROT0, "ABM Games", "Super Pool (9743 rev.01)", GAME_NOT_WORKING ) | |
| 860 | GAME( 1996, hotslot, 0, hotslot, hotslot, hotslot, ROT0, "ABM Electronics", "Hot Slot (ver. 05.01)", GAME_NOT_WORKING ) | |
| 861 | GAME( 1999, mcolors, 0, magic102, magic102, magic102, ROT0, "unknown", "Magic Colors (ver. 1.7a)", GAME_NOT_WORKING ) | |
| 1112 | ||
| 1113 | /****************************** | |
| 1114 | * Game Drivers * | |
| 1115 | ******************************/ | |
| 1116 | ||
| 1117 | /* YEAR NAME PARENT MACHINE INPUT INIT ROT COMPANY FULLNAME FLAGS LAYOUT */ | |
| 1118 | GAMEL( 1995, magic10, 0, magic10, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.55)", 0, layout_sgsafari ) | |
| 1119 | GAMEL( 1995, magic10a, magic10, magic10a, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.45)", 0, layout_sgsafari ) | |
| 1120 | GAMEL( 1995, magic10b, magic10, magic10a, magic10, magic10, ROT0, "A.W.P. Games", "Magic's 10 (ver. 16.15)", 0, layout_sgsafari ) | |
| 1121 | GAME( 1997, magic102, 0, magic102, magic102, magic102, ROT0, "ABM Games", "Magic's 10 2 (ver 1.1)", GAME_NOT_WORKING ) | |
| 1122 | GAME( 1997, suprpool, 0, magic102, magic102, suprpool, ROT0, "ABM Games", "Super Pool (9743 rev.01)", GAME_NOT_WORKING ) | |
| 1123 | GAME( 1996, hotslot, 0, hotslot, hotslot, hotslot, ROT0, "ABM Electronics", "Hot Slot (ver. 05.01)", GAME_NOT_WORKING ) | |
| 1124 | GAME( 1999, mcolors, 0, magic102, magic102, magic102, ROT0, "unknown", "Magic Colors (ver. 1.7a)", GAME_NOT_WORKING ) | |
| 1125 | GAMEL( 1996, sgsafari, 0, sgsafari, sgsafari, sgsafari, ROT0, "New Impeuropex Corp.", "Super Gran Safari (ver 3.11)", 0, layout_sgsafari ) |
| r3232 | r3233 | |
|---|---|---|
| 54 | 54 | { |
| 55 | 55 | int res = 0x3f; |
| 56 | 56 | int i; |
| 57 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 57 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 58 | 58 | |
| 59 | 59 | for (i = 0;i < 5;i++) |
| 60 | 60 | if (~keyb & (1 << i)) res &= input_port_read(machine, keynames[i]); |
| r3232 | r3233 | |
|---|---|---|
| 146 | 146 | |
| 147 | 147 | static tilemap *background_layer,*midground_layer,*foreground_layer,*text_layer; |
| 148 | 148 | static UINT16 *back_data,*fore_data,*mid_data, *w1ram; |
| 149 | static int bg_bank=0, fg_bank=6, mid_bank=1, bg_col=0, fg_col=1, mid_col=2; | |
| 149 | static int bg_bank, fg_bank, mid_bank; | |
| 150 | static int bg_col, fg_col, mid_col; | |
| 150 | 151 | |
| 151 | 152 | static int tick; |
| 152 | 153 | static UINT16 *mainram; |
| r3232 | r3233 | |
| 812 | 813 | } |
| 813 | 814 | #endif |
| 814 | 815 | |
| 816 | static void common_reset(void) | |
| 817 | { | |
| 818 | bg_bank=0; | |
| 819 | fg_bank=6; | |
| 820 | mid_bank=1; | |
| 821 | bg_col=0; | |
| 822 | fg_col=1; | |
| 823 | mid_col=2; | |
| 824 | } | |
| 825 | ||
| 815 | 826 | static MACHINE_RESET(raiden2) |
| 816 | 827 | { |
| 828 | common_reset(); | |
| 817 | 829 | sprcpt_init(); |
| 818 | 830 | MACHINE_RESET_CALL(seibu_sound); |
| 819 | 831 | |
| r3232 | r3233 | |
| 2041 | 2053 | logerror("VSYNC\n"); |
| 2042 | 2054 | } |
| 2043 | 2055 | |
| 2056 | static MACHINE_RESET( rdx_v33 ) | |
| 2057 | { | |
| 2058 | common_reset(); | |
| 2059 | } | |
| 2060 | ||
| 2044 | 2061 | static MACHINE_DRIVER_START( rdx_v33 ) |
| 2045 | 2062 | |
| 2046 | 2063 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 2048 | 2065 | MDRV_CPU_PROGRAM_MAP(rdx_v33_map, 0) |
| 2049 | 2066 | MDRV_CPU_VBLANK_INT("main", rdx_v33_interrupt) |
| 2050 | 2067 | |
| 2068 | MDRV_MACHINE_RESET(rdx_v33) | |
| 2051 | 2069 | MDRV_NVRAM_HANDLER(rdx_v33) |
| 2052 | 2070 | |
| 2053 | 2071 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 408 | 408 | AM_RANGE(0xe800, 0xebff) AM_RAM |
| 409 | 409 | ADDRESS_MAP_END |
| 410 | 410 | |
| 411 | static ADDRESS_MAP_START( triplep_ | |
| 411 | static ADDRESS_MAP_START( triplep_io_ma | |
| 412 | 412 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 413 | AM_RANGE(0x01, 0x01) AM_READ(ay8910_read_port_0_r) | |
| 413 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_write_port_0_w) | |
| 414 | AM_RANGE(0x01, 0x01) AM_READWRITE(ay8910_read_port_0_r, ay8910_control_port_0_w) | |
| 414 | 415 | AM_RANGE(0x02, 0x02) AM_READ(triplep_pip_r) |
| 415 | 416 | AM_RANGE(0x03, 0x03) AM_READ(triplep_pap_r) |
| 416 | 417 | ADDRESS_MAP_END |
| 417 | 418 | |
| 418 | static ADDRESS_MAP_START( t | |
| 419 | static ADDRESS_MAP_START( hotshock | |
| 419 | 420 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 420 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_write_port_0_w) | |
| 421 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_control_port_0_w) | |
| 422 | ADDRESS_MAP_END | |
| 423 | ||
| 424 | ||
| 425 | static ADDRESS_MAP_START( hotshock_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 426 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 427 | AM_RANGE(0x20, 0x20) AM_READ(ay8910_read_port_0_r) | |
| 428 | AM_RANGE(0x40, 0x40) AM_READ(ay8910_read_port_1_r) | |
| 429 | ADDRESS_MAP_END | |
| 430 | ||
| 431 | static ADDRESS_MAP_START( hotshock_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 432 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 433 | 421 | AM_RANGE(0x10, 0x10) AM_WRITE(ay8910_control_port_0_w) |
| 434 | AM_RANGE(0x20, 0x20) AM_WRITE(ay8910_write_port_0_w) | |
| 435 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_write_port_1_w) | |
| 422 | AM_RANGE(0x20, 0x20) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 423 | AM_RANGE(0x40, 0x40) AM_READWRITE(ay8910_read_port_1_r, ay8910_write_port_1_w) | |
| 436 | 424 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_control_port_1_w) |
| 437 | 425 | ADDRESS_MAP_END |
| 438 | 426 | |
| r3232 | r3233 | |
| 1845 | 1833 | AM_RANGE(0x9000, 0x9fff) AM_WRITE(scramble_filter_w) |
| 1846 | 1834 | ADDRESS_MAP_END |
| 1847 | 1835 | |
| 1848 | static ADDRESS_MAP_START( scramble_sound_ | |
| 1836 | static ADDRESS_MAP_START( scramble_sound_io_ma | |
| 1849 | 1837 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 1850 | AM_RANGE(0x20, 0x20) AM_READ(ay8910_read_port_0_r) | |
| 1851 | AM_RANGE(0x80, 0x80) AM_READ(ay8910_read_port_1_r) | |
| 1852 | ADDRESS_MAP_END | |
| 1853 | ||
| 1854 | static ADDRESS_MAP_START( scramble_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 1855 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 1856 | 1838 | AM_RANGE(0x10, 0x10) AM_WRITE(ay8910_control_port_0_w) |
| 1857 | AM_RANGE(0x20, 0x20) AM_WRITE(ay8910_write_port_0_w) | |
| 1839 | AM_RANGE(0x20, 0x20) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 1858 | 1840 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_control_port_1_w) |
| 1859 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_write_port_1_w) | |
| 1841 | AM_RANGE(0x80, 0x80) AM_READWRITE(ay8910_read_port_1_r, ay8910_write_port_1_w) | |
| 1860 | 1842 | ADDRESS_MAP_END |
| 1861 | 1843 | |
| 1862 | ||
| 1863 | 1844 | static MACHINE_DRIVER_START( scramble ) |
| 1864 | 1845 | |
| 1865 | 1846 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 1868 | 1849 | |
| 1869 | 1850 | MDRV_CPU_ADD("audio", Z80, 14318000/8) /* 1.78975 MHz */ |
| 1870 | 1851 | MDRV_CPU_PROGRAM_MAP(scramble_sound_readmem,scramble_sound_writemem) |
| 1871 | MDRV_CPU_IO_MAP(scramble_sound_ | |
| 1852 | MDRV_CPU_IO_MAP(scramble_sound_i | |
| 1872 | 1853 | |
| 1873 | 1854 | MDRV_MACHINE_RESET(scramble) |
| 1874 | 1855 | |
| r3232 | r3233 | |
| 2083 | 2064 | MDRV_DEVICE_REMOVE( "ppi8255_1", PPI8255 ) |
| 2084 | 2065 | |
| 2085 | 2066 | MDRV_CPU_MODIFY("audio") |
| 2086 | MDRV_CPU_IO_MAP(hotshock_sound_ | |
| 2067 | MDRV_CPU_IO_MAP(hotshock_sound_i | |
| 2087 | 2068 | |
| 2088 | 2069 | MDRV_MACHINE_RESET(galaxold) |
| 2089 | 2070 | |
| r3232 | r3233 | |
| 2133 | 2114 | /* basic machine hardware */ |
| 2134 | 2115 | MDRV_IMPORT_FROM(scramble) |
| 2135 | 2116 | MDRV_CPU_MODIFY("main") |
| 2136 | MDRV_CPU_IO_MAP(triplep_ | |
| 2117 | MDRV_CPU_IO_MAP(triplep_ | |
| 2137 | 2118 | |
| 2138 | 2119 | MDRV_CPU_REMOVE("audio") |
| 2139 | 2120 | |
| r3232 | r3233 | |
| 2927 | 2908 | ROM_REGION( 0x0020, "proms", 0 ) |
| 2928 | 2909 | ROM_LOAD( "prom-am27s19dc.1m", 0x0000, 0x0020, CRC(2759aebd) SHA1(644fd2c95ca49cbbc0ee1b88ca2563451ddd4fe0) ) |
| 2929 | 2910 | |
| 2930 | ROM_REGION( 0x0020, " | |
| 2911 | ROM_REGION( 0x0020, " | |
| 2931 | 2912 | ROM_LOAD( "prom-sn74s188.8a", 0x0000, 0x0020, BAD_DUMP CRC(c58a4f6a) SHA1(35ef244b3e94032df2610aa594ea5670b91e1449) ) |
| 2932 | 2913 | ROM_END |
| 2933 | 2914 | |
| r3232 | r3233 | |
| 2999 | 2980 | GAME( 198?, mimonscr, mimonkey, mimonscr, mimonscr, mimonscr, ROT90, "bootleg", "Mighty Monkey (bootleg on Scramble hardware)", GAME_SUPPORTS_SAVE ) |
| 3000 | 2981 | GAME( 1983, ad2083, 0, ad2083, ad2083, ad2083, ROT90, "Midcoin", "A. D. 2083", GAME_IMPERFECT_SOUND | GAME_SUPPORTS_SAVE) |
| 3001 | 2982 | GAME( 1981, turpins, turtles, turpins, turpins, 0, ROT90, "[Sega] (bootleg)", "Turpin (bootleg on Scramble hardware)", GAME_NO_SOUND | GAME_SUPPORTS_SAVE ) // haven't hooked up the sound CPU yet |
| 2983 |
| r3232 | r3233 | |
|---|---|---|
| 257 | 257 | AM_RANGE(0xe000, 0xffff) AM_WRITE(SMH_RAM) |
| 258 | 258 | ADDRESS_MAP_END |
| 259 | 259 | |
| 260 | static ADDRESS_MAP_START( shdancbl_sound_ | |
| 260 | static ADDRESS_MAP_START( shdancbl_sound_io_ma | |
| 261 | 261 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 262 | AM_RANGE(0xa0, 0xbf) AM_WRITE(SMH_NOP) | |
| 262 | 263 | AM_RANGE(0xc0, 0xdf) AM_READ(SMH_NOP) |
| 263 | 264 | ADDRESS_MAP_END |
| 264 | 265 | |
| 265 | static ADDRESS_MAP_START( shdancbl_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 266 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 267 | AM_RANGE(0xa0, 0xbf) AM_WRITE(SMH_NOP) | |
| 268 | ADDRESS_MAP_END | |
| 269 | ||
| 270 | 266 | /***************************************************************************/ |
| 271 | 267 | |
| 272 | 268 | static UINT8 *sys18_SoundMemBank; |
| r3232 | r3233 | |
| 306 | 302 | else sys18_SoundMemBank = NULL; |
| 307 | 303 | } |
| 308 | 304 | |
| 309 | ||
| 310 | static ADDRESS_MAP_START( sound_readport_18, ADDRESS_SPACE_IO, 8 ) | |
| 305 | static ADDRESS_MAP_START( sound_18_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 311 | 306 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 312 | AM_RANGE(0x80, 0x80) AM_READ(ym3438_status_port_0_a_r) | |
| 313 | // AM_RANGE(0x82, 0x82) AM_READ(ym3438_status_port_0_b_r) | |
| 314 | // AM_RANGE(0x90, 0x90) AM_READ(ym3438_status_port_1_a_r) | |
| 315 | // AM_RANGE(0x92, 0x92) AM_READ(ym3438_status_port_1_b_r) | |
| 316 | AM_RANGE(0xc0, 0xc0) AM_READ(soundlatch_r) | |
| 317 | ADDRESS_MAP_END | |
| 318 | ||
| 319 | static ADDRESS_MAP_START( sound_writeport_18, ADDRESS_SPACE_IO, 8 ) | |
| 320 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 321 | AM_RANGE(0x80, 0x80) AM_WRITE(ym3438_control_port_0_a_w) | |
| 307 | AM_RANGE(0x80, 0x80) AM_READWRITE(ym3438_status_port_0_a_r, ym3438_control_port_0_a_w) | |
| 322 | 308 | AM_RANGE(0x81, 0x81) AM_WRITE(ym3438_data_port_0_a_w) |
| 309 | // AM_RANGE(0x82, 0x82) AM_READ(ym3438_status_port_0_b_r) | |
| 323 | 310 | AM_RANGE(0x82, 0x82) AM_WRITE(ym3438_control_port_0_b_w) |
| 324 | 311 | AM_RANGE(0x83, 0x83) AM_WRITE(ym3438_data_port_0_b_w) |
| 312 | // AM_RANGE(0x90, 0x90) AM_READ(ym3438_status_port_1_a_r) | |
| 325 | 313 | AM_RANGE(0x90, 0x90) AM_WRITE(ym3438_control_port_1_a_w) |
| 326 | 314 | AM_RANGE(0x91, 0x91) AM_WRITE(ym3438_data_port_1_a_w) |
| 315 | // AM_RANGE(0x92, 0x92) AM_READ(ym3438_status_port_1_b_r) | |
| 327 | 316 | AM_RANGE(0x92, 0x92) AM_WRITE(ym3438_control_port_1_b_w) |
| 328 | 317 | AM_RANGE(0x93, 0x93) AM_WRITE(ym3438_data_port_1_b_w) |
| 329 | 318 | AM_RANGE(0xa0, 0xa0) AM_WRITE(sys18_soundbank_w) |
| 319 | AM_RANGE(0xc0, 0xc0) AM_READ(soundlatch_r) | |
| 330 | 320 | ADDRESS_MAP_END |
| 331 | 321 | |
| 332 | 322 | static WRITE16_HANDLER( sound_command_nmi_w ){ |
| r3232 | r3233 | |
| 1095 | 1085 | |
| 1096 | 1086 | MDRV_CPU_ADD("sound", Z80, 8000000) |
| 1097 | 1087 | MDRV_CPU_PROGRAM_MAP(sound_readmem_18,sound_writemem_18) |
| 1098 | MDRV_CPU_IO_MAP(sound_ | |
| 1088 | MDRV_CPU_IO_MAP(sound_ | |
| 1099 | 1089 | |
| 1100 | 1090 | /* video hardware */ |
| 1101 | 1091 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 1163 | 1153 | |
| 1164 | 1154 | MDRV_CPU_MODIFY("sound") |
| 1165 | 1155 | MDRV_CPU_PROGRAM_MAP(shdancbl_sound_readmem,shdancbl_sound_writemem) |
| 1166 | MDRV_CPU_IO_MAP(shdancbl_sound_ | |
| 1156 | MDRV_CPU_IO_MAP(shdancbl_sound_i | |
| 1167 | 1157 | MDRV_SOUND_REMOVE("5c68") |
| 1168 | 1158 | |
| 1169 | 1159 | MDRV_SOUND_ADD("5205", MSM5205, 200000) |
| r3232 | r3233 | |
| 1545 | 1535 | GAME( 1990, mwalkbl, mwalk, mwalkbl, mwalkbl, mwalkbl, ROT0, "bootleg", "Michael Jackson's Moonwalker (bootleg)", GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND ) |
| 1546 | 1536 | |
| 1547 | 1537 | GAME( 1989, shdancbl, shdancer, shdancbl, mwalkbl, shdancbl, ROT0, "bootleg", "Shadow Dancer (bootleg)", GAME_IMPERFECT_GRAPHICS | GAME_IMPERFECT_SOUND ) |
| 1538 |
| r3232 | r3233 | |
|---|---|---|
| 745 | 745 | } |
| 746 | 746 | #endif |
| 747 | 747 | |
| 748 | static int first_dsp_reset | |
| 748 | static int first_dsp_reset | |
| 749 | 749 | static WRITE32_HANDLER(dsp_shared_w) |
| 750 | 750 | { |
| 751 | 751 | //mame_printf_debug("dsp_shared_ram: %08X, %04X at %08X\n", offset, data >> 16, activecpu_get_pc()); |
| r3232 | r3233 | |
| 866 | 866 | |
| 867 | 867 | static READ8_HANDLER(hc11_analog_r) |
| 868 | 868 | { |
| 869 | static const char *portnames[] = { "ANALOG1", "ANALOG2", "ANALOG3", "ANALOG4", | |
| 869 | static const char *const portnames[] = { "ANALOG1", "ANALOG2", "ANALOG3", "ANALOG4", | |
| 870 | 870 | "ANALOG5", "ANALOG6", "ANALOG7", "ANALOG8" }; |
| 871 | 871 | |
| 872 | 872 | return input_port_read_safe(machine, portnames[offset], 0); |
| r3232 | r3233 | |
| 1252 | 1252 | |
| 1253 | 1253 | static MACHINE_RESET( taitojc ) |
| 1254 | 1254 | { |
| 1255 | first_dsp_reset = 1; | |
| 1256 | ||
| 1257 | mcu_comm_main = 0; | |
| 1258 | mcu_comm_hc11 = 0; | |
| 1259 | mcu_data_main = 0; | |
| 1260 | mcu_data_hc11 = 0; | |
| 1261 | ||
| 1262 | texture_x = 0; | |
| 1263 | texture_y = 0; | |
| 1264 | ||
| 1265 | dsp_rom_pos = 0; | |
| 1266 | dsp_tex_address = 0; | |
| 1267 | dsp_tex_offset = 0; | |
| 1268 | ||
| 1269 | projected_point_x = 0; | |
| 1270 | projected_point_y = 0; | |
| 1271 | ||
| 1272 | memset(viewport_data, 0, sizeof(viewport_data)); | |
| 1273 | memset(projection_data, 0, sizeof(projection_data)); | |
| 1274 | memset(intersection_data, 0, sizeof(intersection_data)); | |
| 1275 | ||
| 1255 | 1276 | taito_f3_soundsystem_reset(machine); |
| 1256 | 1277 | |
| 1257 | 1278 | f3_68681_reset(); |
| r3232 | r3233 | |
|---|---|---|
| 414 | 414 | AM_RANGE(0x8000, 0xffff) AM_WRITE(SMH_ROM ) // Banked ROM |
| 415 | 415 | ADDRESS_MAP_END |
| 416 | 416 | |
| 417 | ||
| 418 | static ADDRESS_MAP_START( sngkace_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 417 | static ADDRESS_MAP_START( sngkace_sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 419 | 418 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 420 | AM_RANGE(0x00, 0x00) AM_READ(ym2610_status_port_0_a_r ) | |
| 421 | AM_RANGE(0x02, 0x02) AM_READ(ym2610_status_port_0_b_r ) | |
| 422 | AM_RANGE(0x08, 0x08) AM_READ(psikyo_soundlatch_r ) | |
| 419 | AM_RANGE(0x00, 0x00) AM_READWRITE(ym2610_status_port_0_a_r, ym2610_control_port_0_a_w ) | |
| 420 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2610_data_port_0_a_w ) | |
| 421 | AM_RANGE(0x02, 0x02) AM_READWRITE(ym2610_status_port_0_b_r, ym2610_control_port_0_b_w ) | |
| 422 | AM_RANGE(0x03, 0x03) AM_WRITE(ym2610_data_port_0_b_w ) | |
| 423 | AM_RANGE(0x04, 0x04) AM_WRITE(sngkace_sound_bankswitch_w ) | |
| 424 | AM_RANGE(0x08, 0x08) AM_READ(psikyo_soundlatch_r ) | |
| 425 | AM_RANGE(0x0c, 0x0c) AM_WRITE(psikyo_clear_nmi_w ) | |
| 423 | 426 | ADDRESS_MAP_END |
| 424 | 427 | |
| 425 | static ADDRESS_MAP_START( sngkace_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 426 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 427 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2610_control_port_0_a_w ) | |
| 428 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2610_data_port_0_a_w ) | |
| 429 | AM_RANGE(0x02, 0x02) AM_WRITE(ym2610_control_port_0_b_w ) | |
| 430 | AM_RANGE(0x03, 0x03) AM_WRITE(ym2610_data_port_0_b_w ) | |
| 431 | AM_RANGE(0x04, 0x04) AM_WRITE(sngkace_sound_bankswitch_w ) | |
| 432 | AM_RANGE(0x0c, 0x0c) AM_WRITE(psikyo_clear_nmi_w ) | |
| 433 | ADDRESS_MAP_END | |
| 434 | ||
| 435 | ||
| 436 | 428 | /*************************************************************************** |
| 437 | 429 | Gun Bird |
| 438 | 430 | ***************************************************************************/ |
| r3232 | r3233 | |
| 460 | 452 | AM_RANGE(0x8200, 0xffff) AM_WRITE(SMH_ROM ) // Banked ROM |
| 461 | 453 | ADDRESS_MAP_END |
| 462 | 454 | |
| 463 | ||
| 464 | static ADDRESS_MAP_START( gunbird_sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 455 | static ADDRESS_MAP_START( gunbird_sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 465 | 456 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 466 | AM_RANGE(0x04, 0x04) AM_READ(ym2610_status_port_0_a_r ) | |
| 467 | AM_RANGE(0x06, 0x06) AM_READ(ym2610_status_port_0_b_r ) | |
| 468 | AM_RANGE(0x08, 0x08) AM_READ(psikyo_soundlatch_r ) | |
| 457 | AM_RANGE(0x00, 0x00) AM_WRITE(gunbird_sound_bankswitch_w ) | |
| 458 | AM_RANGE(0x04, 0x04) AM_READWRITE(ym2610_status_port_0_a_r, ym2610_control_port_0_a_w ) | |
| 459 | AM_RANGE(0x05, 0x05) AM_WRITE(ym2610_data_port_0_a_w ) | |
| 460 | AM_RANGE(0x06, 0x06) AM_READWRITE(ym2610_status_port_0_b_r, ym2610_control_port_0_b_w ) | |
| 461 | AM_RANGE(0x07, 0x07) AM_WRITE(ym2610_data_port_0_b_w ) | |
| 462 | AM_RANGE(0x08, 0x08) AM_READ(psikyo_soundlatch_r ) | |
| 463 | AM_RANGE(0x0c, 0x0c) AM_WRITE(psikyo_clear_nmi_w ) | |
| 469 | 464 | ADDRESS_MAP_END |
| 470 | 465 | |
| 471 | static ADDRESS_MAP_START( gunbird_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 472 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 473 | AM_RANGE(0x00, 0x00) AM_WRITE(gunbird_sound_bankswitch_w ) | |
| 474 | AM_RANGE(0x04, 0x04) AM_WRITE(ym2610_control_port_0_a_w ) | |
| 475 | AM_RANGE(0x05, 0x05) AM_WRITE(ym2610_data_port_0_a_w ) | |
| 476 | AM_RANGE(0x06, 0x06) AM_WRITE(ym2610_control_port_0_b_w ) | |
| 477 | AM_RANGE(0x07, 0x07) AM_WRITE(ym2610_data_port_0_b_w ) | |
| 478 | AM_RANGE(0x0c, 0x0c) AM_WRITE(psikyo_clear_nmi_w ) | |
| 479 | ADDRESS_MAP_END | |
| 480 | ||
| 481 | ||
| 482 | 466 | /*************************************************************************** |
| 483 | 467 | Strikers 1945 / Tengai |
| 484 | 468 | ***************************************************************************/ |
| 485 | 469 | |
| 486 | static ADDRESS_MAP_START( s1945_sound_ | |
| 470 | static ADDRESS_MAP_START( s1945_sound_io_ma | |
| 487 | 471 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 488 | AM_RANGE(0x08, 0x08) AM_READ(ymf278b_status_port_0_r ) | |
| 489 | AM_RANGE(0x10, 0x10) AM_READ(psikyo_soundlatch_r ) | |
| 472 | AM_RANGE(0x00, 0x00) AM_WRITE(gunbird_sound_bankswitch_w ) | |
| 473 | AM_RANGE(0x02, 0x03) AM_WRITE(SMH_NOP ) | |
| 474 | AM_RANGE(0x08, 0x08) AM_READWRITE(ymf278b_status_port_0_r, ymf278b_control_port_0_a_w ) | |
| 475 | AM_RANGE(0x09, 0x09) AM_WRITE(ymf278b_data_port_0_a_w ) | |
| 476 | AM_RANGE(0x0a, 0x0a) AM_WRITE(ymf278b_control_port_0_b_w ) | |
| 477 | AM_RANGE(0x0b, 0x0b) AM_WRITE(ymf278b_data_port_0_b_w ) | |
| 478 | AM_RANGE(0x0c, 0x0c) AM_WRITE(ymf278b_control_port_0_c_w ) | |
| 479 | AM_RANGE(0x0d, 0x0d) AM_WRITE(ymf278b_data_port_0_c_w ) | |
| 480 | AM_RANGE(0x10, 0x10) AM_READ(psikyo_soundlatch_r ) | |
| 481 | AM_RANGE(0x18, 0x18) AM_WRITE(psikyo_clear_nmi_w ) | |
| 490 | 482 | ADDRESS_MAP_END |
| 491 | 483 | |
| 492 | static ADDRESS_MAP_START( s1945_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 493 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 494 | AM_RANGE(0x00, 0x00) AM_WRITE(gunbird_sound_bankswitch_w ) | |
| 495 | AM_RANGE(0x02, 0x03) AM_WRITE(SMH_NOP ) | |
| 496 | AM_RANGE(0x08, 0x08) AM_WRITE(ymf278b_control_port_0_a_w ) | |
| 497 | AM_RANGE(0x09, 0x09) AM_WRITE(ymf278b_data_port_0_a_w ) | |
| 498 | AM_RANGE(0x0a, 0x0a) AM_WRITE(ymf278b_control_port_0_b_w ) | |
| 499 | AM_RANGE(0x0b, 0x0b) AM_WRITE(ymf278b_data_port_0_b_w ) | |
| 500 | AM_RANGE(0x0c, 0x0c) AM_WRITE(ymf278b_control_port_0_c_w ) | |
| 501 | AM_RANGE(0x0d, 0x0d) AM_WRITE(ymf278b_data_port_0_c_w ) | |
| 502 | AM_RANGE(0x18, 0x18) AM_WRITE(psikyo_clear_nmi_w ) | |
| 503 | ADDRESS_MAP_END | |
| 504 | ||
| 505 | ||
| 506 | 484 | /*************************************************************************** |
| 507 | 485 | |
| 508 | 486 | |
| r3232 | r3233 | |
| 1252 | 1230 | |
| 1253 | 1231 | MDRV_CPU_ADD("audio", Z80, 4000000) /* ? */ |
| 1254 | 1232 | MDRV_CPU_PROGRAM_MAP(sngkace_sound_readmem,sngkace_sound_writemem) |
| 1255 | MDRV_CPU_IO_MAP(sngkace_sound_ | |
| 1233 | MDRV_CPU_IO_MAP(sngkace_sound_i | |
| 1256 | 1234 | |
| 1257 | 1235 | MDRV_MACHINE_RESET(psikyo) |
| 1258 | 1236 | |
| r3232 | r3233 | |
| 1303 | 1281 | |
| 1304 | 1282 | MDRV_CPU_ADD("audio", Z80, 4000000) /* ! LZ8420M (Z80 core) ! */ |
| 1305 | 1283 | MDRV_CPU_PROGRAM_MAP(gunbird_sound_readmem,gunbird_sound_writemem) |
| 1306 | MDRV_CPU_IO_MAP(gunbird_sound_ | |
| 1284 | MDRV_CPU_IO_MAP(gunbird_sound_ | |
| 1307 | 1285 | |
| 1308 | 1286 | MDRV_MACHINE_RESET(psikyo) |
| 1309 | 1287 | |
| r3232 | r3233 | |
| 1363 | 1341 | |
| 1364 | 1342 | MDRV_CPU_ADD("audio", Z80, 4000000) /* ! LZ8420M (Z80 core) ! */ |
| 1365 | 1343 | MDRV_CPU_PROGRAM_MAP(gunbird_sound_readmem,gunbird_sound_writemem) |
| 1366 | MDRV_CPU_IO_MAP(s1945_sound_ | |
| 1344 | MDRV_CPU_IO_MAP(s1945_sound_i | |
| 1367 | 1345 | |
| 1368 | 1346 | /* MCU should go here */ |
| 1369 | 1347 | |
| r3232 | r3233 | |
| 2057 | 2035 | GAME( 1995, s1945jn, s1945, gunbird, s1945j, s1945jn, ROT270, "Psikyo", "Strikers 1945 (Japan, unprotected)", 0 ) |
| 2058 | 2036 | GAME( 1995, s1945k, s1945, s1945, s1945j, s1945, ROT270, "Psikyo", "Strikers 1945 (Korea)", 0 ) |
| 2059 | 2037 | GAME( 1996, tengai, 0, s1945, tengai, tengai, ROT0, "Psikyo", "Tengai / Sengoku Blade: Sengoku Ace Episode II", 0 ) |
| 2038 |
| r3232 | r3233 | |
|---|---|---|
| 1115 | 1115 | case 7: |
| 1116 | 1116 | if (ACCESSING_BITS_24_31) /* ADC Data read */ |
| 1117 | 1117 | { |
| 1118 | static const char *adcnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1118 | static const char *const adcnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1119 | 1119 | UINT8 adc_data = input_port_read_safe(machine, adcnames[adc_channel], 0); |
| 1120 | 1120 | adc_channel++; |
| 1121 | 1121 | adc_channel &= 0x7; |
| r3232 | r3233 | |
|---|---|---|
| 343 | 343 | } *mpDspState; |
| 344 | 344 | |
| 345 | 345 | static INT32 |
| 346 | ReadPointROMData( unsigned offset ) | |
| 346 | ReadPointROMData( running_machine *machine, unsigned offset ) | |
| 347 | 347 | { |
| 348 | const INT32 *pPointData = (INT32 *)memory_region( | |
| 348 | const INT32 *pPointData = (INT32 *)memory_region( machine, "user2" ); | |
| 349 | 349 | INT32 result = pPointData[offset]; |
| 350 | 350 | return result; |
| 351 | 351 | } |
| r3232 | r3233 | |
| 426 | 426 | } /* TransmitWordToSlave */ |
| 427 | 427 | |
| 428 | 428 | static void |
| 429 | TransferDspData( | |
| 429 | TransferDspData( running_machine *machine ) | |
| 430 | 430 | { |
| 431 | 431 | UINT16 addr = mpDspState->masterSourceAddr; |
| 432 | 432 | int mode = addr&0x8000; |
| r3232 | r3233 | |
| 479 | 479 | } |
| 480 | 480 | else |
| 481 | 481 | { |
| 482 | INT32 masterAddr = ReadPointROMData(code); | |
| 482 | INT32 masterAddr = ReadPointROMData(machine, code); | |
| 483 | 483 | logerror( "OBJ TFR(0x%x)\n", code ); |
| 484 | 484 | { |
| 485 | 485 | UINT16 len = namcos21_dspram16[addr++]; |
| 486 | 486 | for(;;) |
| 487 | 487 | { |
| 488 | int subAddr = ReadPointROMData(masterAddr++); | |
| 488 | int subAddr = ReadPointROMData(machine, masterAddr++); | |
| 489 | 489 | if( subAddr==0xffffff ) |
| 490 | 490 | { |
| 491 | 491 | break; |
| 492 | 492 | } |
| 493 | 493 | else |
| 494 | 494 | { |
| 495 | int primWords = (UINT16)ReadPointROMData(subAddr++); | |
| 495 | int primWords = (UINT16)ReadPointROMData(machine, subAddr++); | |
| 496 | 496 | if( primWords>2 ) |
| 497 | 497 | { |
| 498 | 498 | TransmitWordToSlave( 0 ); /* pad1 */ |
| r3232 | r3233 | |
| 505 | 505 | TransmitWordToSlave( primWords+1 ); |
| 506 | 506 | for( i=0; i<primWords; i++ ) |
| 507 | 507 | { |
| 508 | TransmitWordToSlave( (UINT16)ReadPointROMData(subAddr+i) ); | |
| 508 | TransmitWordToSlave( (UINT16)ReadPointROMData(machine, subAddr+i) ); | |
| 509 | 509 | } |
| 510 | 510 | } |
| 511 | 511 | else |
| r3232 | r3233 | |
| 603 | 603 | offset == 1+(mpDspState->masterSourceAddr&0x7fff) ) |
| 604 | 604 | { |
| 605 | 605 | logerror( "IDC-CONTINUE\n" ); |
| 606 | TransferDspData(); | |
| 606 | TransferDspData(machine); | |
| 607 | 607 | } |
| 608 | 608 | else if( namcos2_gametype == NAMCOS21_SOLVALOU && |
| 609 | 609 | offset == 0x103 && |
| r3232 | r3233 | |
| 617 | 617 | /************************************************************************************/ |
| 618 | 618 | |
| 619 | 619 | static int |
| 620 | InitDSP( | |
| 620 | InitDSP( running_machine *machine ) | |
| 621 | 621 | { |
| 622 | UINT16 *pMem = (UINT16 *)memory_region( | |
| 622 | UINT16 *pMem = (UINT16 *)memory_region(machine, "dspmaster"); | |
| 623 | 623 | /** |
| 624 | 624 | * DSP BIOS tests "CPU ID" on startup |
| 625 | 625 | * "JAPAN (C)1990 NAMCO LTD. by H.F " |
| r3232 | r3233 | |
| 643 | 643 | |
| 644 | 644 | static READ16_HANDLER( dsp_port0_r ) |
| 645 | 645 | { |
| 646 | INT32 data = ReadPointROMData(pointrom_idx++); | |
| 646 | INT32 data = ReadPointROMData(machine, pointrom_idx++); | |
| 647 | 647 | mPointRomMSB = (UINT8)(data>>16); |
| 648 | 648 | mbPointRomDataAvailable = 1; |
| 649 | 649 | return (UINT16)data; |
| r3232 | r3233 | |
| 678 | 678 | { |
| 679 | 679 | logerror( "IDC ADDR INIT(0x%04x)\n", data ); |
| 680 | 680 | mpDspState->masterSourceAddr = data; |
| 681 | TransferDspData(); | |
| 681 | TransferDspData(machine); | |
| 682 | 682 | } /* dsp_port2_w */ |
| 683 | 683 | |
| 684 | 684 | static READ16_HANDLER( dsp_port3_idc_rcv_enable_r ) |
| r3232 | r3233 | |
| 2196 | 2196 | ROM_LOAD("avo3.11e",0x080000,0x80000,CRC(76e22f92) SHA1(0e1b8d35a5b9c20cc3192d935f0c9da1e69679d2) ) |
| 2197 | 2197 | ROM_END |
| 2198 | 2198 | |
| 2199 | static void namcos21_init( int game_type ) | |
| 2199 | static void namcos21_init( running_machine *machine, int game_type ) | |
| 2200 | 2200 | { |
| 2201 | 2201 | namcos2_gametype = game_type; |
| 2202 | 2202 | pointram = auto_malloc(PTRAM_SIZE); |
| 2203 | mpDataROM = (UINT16 *)memory_region( Machine, "user1" ); | |
| 2204 | InitDSP(); | |
| 2203 | mpDataROM = (UINT16 *)memory_region( machine, "user1" ); | |
| 2204 | InitDSP(machine); | |
| 2205 | 2205 | mbNeedsKickstart = 20; |
| 2206 | 2206 | if( game_type==NAMCOS21_CYBERSLED ) |
| 2207 | 2207 | { |
| r3232 | r3233 | |
| 2227 | 2227 | |
| 2228 | 2228 | static DRIVER_INIT( aircombt ) |
| 2229 | 2229 | { |
| 2230 | namcos21_init( NAMCOS21_AIRCOMBAT ); | |
| 2230 | namcos21_init( machine, NAMCOS21_AIRCOMBAT ); | |
| 2231 | 2231 | } |
| 2232 | 2232 | |
| 2233 | 2233 | static DRIVER_INIT( starblad ) |
| 2234 | 2234 | { |
| 2235 | namcos21_init( NAMCOS21_STARBLADE ); | |
| 2235 | namcos21_init( machine, NAMCOS21_STARBLADE ); | |
| 2236 | 2236 | } |
| 2237 | 2237 | |
| 2238 | 2238 | |
| 2239 | 2239 | static DRIVER_INIT( cybsled ) |
| 2240 | 2240 | { |
| 2241 | namcos21_init( NAMCOS21_CYBERSLED ); | |
| 2241 | namcos21_init( machine, NAMCOS21_CYBERSLED ); | |
| 2242 | 2242 | } |
| 2243 | 2243 | |
| 2244 | 2244 | static DRIVER_INIT( solvalou ) |
| r3232 | r3233 | |
| 2249 | 2249 | mem[0x20cf4/2+1] = 0x4e71; |
| 2250 | 2250 | mem[0x20cf4/2+2] = 0x4e71; |
| 2251 | 2251 | |
| 2252 | namcos21_init( NAMCOS21_SOLVALOU ); | |
| 2252 | namcos21_init( machine, NAMCOS21_SOLVALOU ); | |
| 2253 | 2253 | } |
| 2254 | 2254 | |
| 2255 | 2255 | static DRIVER_INIT( driveyes ) |
| r3232 | r3233 | |
|---|---|---|
| 95 | 95 | |
| 96 | 96 | static READ8_HANDLER( io_port_r ) |
| 97 | 97 | { |
| 98 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3", "DSW0", "DSW1" }; | |
| 98 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3", "DSW0", "DSW1" }; | |
| 99 | 99 | gameplan_state *state = machine->driver_data; |
| 100 | 100 | |
| 101 | 101 | return input_port_read(machine, portnames[state->current_port]); |
| r3232 | r3233 | |
|---|---|---|
| 292 | 292 | SOUND |
| 293 | 293 | *****************************************************/ |
| 294 | 294 | |
| 295 | static INT32 banknum | |
| 295 | static INT32 banknum | |
| 296 | 296 | static UINT8 adpcm_command = 0; |
| 297 | 297 | static UINT8 nmi_enable = 0; |
| 298 | 298 | |
| r3232 | r3233 | |
| 884 | 884 | |
| 885 | 885 | MDRV_SOUND_ADD("ym1", YM2203, 4000000) |
| 886 | 886 | MDRV_SOUND_CONFIG(ym2203_interface_1) |
| 887 | MDRV_SOUND_ROUTE(0, "filter.2203.0.0l", 0.08) | |
| 888 | MDRV_SOUND_ROUTE(0, "filter.2203.0.0r", 0.08) | |
| 889 | MDRV_SOUND_ROUTE(1, "filter.2203.0.1l", 0.08) | |
| 890 | MDRV_SOUND_ROUTE(1, "filter.2203.0.1r", 0.08) | |
| 891 | MDRV_SOUND_ROUTE(2, "filter.2203.0.2l", 0.08) | |
| 892 | MDRV_SOUND_ROUTE(2, "filter.2203.0.2r", 0.08) | |
| 893 | MDRV_SOUND_ROUTE(3, "filter.2203.0.3l", 0.60) | |
| 894 | MDRV_SOUND_ROUTE(3, "filter.2203.0.3r", 0.60) | |
| 887 | MDRV_SOUND_ROUTE(0, "filter0.0l", 0.08) | |
| 888 | MDRV_SOUND_ROUTE(0, "filter0.0r", 0.08) | |
| 889 | MDRV_SOUND_ROUTE(1, "filter0.1l", 0.08) | |
| 890 | MDRV_SOUND_ROUTE(1, "filter0.1r", 0.08) | |
| 891 | MDRV_SOUND_ROUTE(2, "filter0.2l", 0.08) | |
| 892 | MDRV_SOUND_ROUTE(2, "filter0.2r", 0.08) | |
| 893 | MDRV_SOUND_ROUTE(3, "filter0.3l", 0.60) | |
| 894 | MDRV_SOUND_ROUTE(3, "filter0.3r", 0.60) | |
| 895 | 895 | |
| 896 | 896 | MDRV_SOUND_ADD("ym2", YM2203, 4000000) |
| 897 | 897 | MDRV_SOUND_CONFIG(ym2203_interface_2) |
| 898 | MDRV_SOUND_ROUTE(0, "filter.2203.1.0l", 0.08) | |
| 899 | MDRV_SOUND_ROUTE(0, "filter.2203.1.0r", 0.08) | |
| 900 | MDRV_SOUND_ROUTE(1, "filter.2203.1.1l", 0.08) | |
| 901 | MDRV_SOUND_ROUTE(1, "filter.2203.1.1r", 0.08) | |
| 902 | MDRV_SOUND_ROUTE(2, "filter.2203.1.2l", 0.08) | |
| 903 | MDRV_SOUND_ROUTE(2, "filter.2203.1.2r", 0.08) | |
| 904 | MDRV_SOUND_ROUTE(3, "filter.2203.1.3l", 0.60) | |
| 905 | MDRV_SOUND_ROUTE(3, "filter.2203.1.3r", 0.60) | |
| 898 | MDRV_SOUND_ROUTE(0, "filter1.0l", 0.08) | |
| 899 | MDRV_SOUND_ROUTE(0, "filter1.0r", 0.08) | |
| 900 | MDRV_SOUND_ROUTE(1, "filter1.1l", 0.08) | |
| 901 | MDRV_SOUND_ROUTE(1, "filter1.1r", 0.08) | |
| 902 | MDRV_SOUND_ROUTE(2, "filter1.2l", 0.08) | |
| 903 | MDRV_SOUND_ROUTE(2, "filter1.2r", 0.08) | |
| 904 | MDRV_SOUND_ROUTE(3, "filter1.3l", 0.60) | |
| 905 | MDRV_SOUND_ROUTE(3, "filter1.3r", 0.60) | |
| 906 | 906 | |
| 907 | 907 | MDRV_SOUND_ADD("msm", MSM5205, 384000) |
| 908 | 908 | MDRV_SOUND_CONFIG(msm5205_config) |
| 909 | 909 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "msm5205.l", 1.0) |
| 910 | 910 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "msm5205.r", 1.0) |
| 911 | 911 | |
| 912 | MDRV_SOUND_ADD("filter | |
| 912 | MDRV_SOUND_ADD("filter | |
| 913 | 913 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 914 | MDRV_SOUND_ADD("filter | |
| 914 | MDRV_SOUND_ADD("filter | |
| 915 | 915 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 916 | MDRV_SOUND_ADD("filter | |
| 916 | MDRV_SOUND_ADD("filter | |
| 917 | 917 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 918 | MDRV_SOUND_ADD("filter | |
| 918 | MDRV_SOUND_ADD("filter | |
| 919 | 919 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 920 | MDRV_SOUND_ADD("filter | |
| 920 | MDRV_SOUND_ADD("filter | |
| 921 | 921 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 922 | MDRV_SOUND_ADD("filter | |
| 922 | MDRV_SOUND_ADD("filter | |
| 923 | 923 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 924 | MDRV_SOUND_ADD("filter | |
| 924 | MDRV_SOUND_ADD("filter | |
| 925 | 925 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 926 | MDRV_SOUND_ADD("filter | |
| 926 | MDRV_SOUND_ADD("filter | |
| 927 | 927 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 928 | 928 | |
| 929 | MDRV_SOUND_ADD("filter | |
| 929 | MDRV_SOUND_ADD("filter | |
| 930 | 930 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 931 | MDRV_SOUND_ADD("filter | |
| 931 | MDRV_SOUND_ADD("filter | |
| 932 | 932 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 933 | MDRV_SOUND_ADD("filter | |
| 933 | MDRV_SOUND_ADD("filter | |
| 934 | 934 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 935 | MDRV_SOUND_ADD("filter | |
| 935 | MDRV_SOUND_ADD("filter | |
| 936 | 936 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 937 | MDRV_SOUND_ADD("filter | |
| 937 | MDRV_SOUND_ADD("filter | |
| 938 | 938 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 939 | MDRV_SOUND_ADD("filter | |
| 939 | MDRV_SOUND_ADD("filter | |
| 940 | 940 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 941 | MDRV_SOUND_ADD("filter | |
| 941 | MDRV_SOUND_ADD("filter | |
| 942 | 942 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 943 | MDRV_SOUND_ADD("filter | |
| 943 | MDRV_SOUND_ADD("filter | |
| 944 | 944 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 945 | 945 | |
| 946 | 946 | MDRV_SOUND_ADD("msm5205.l", FILTER_VOLUME, 0) |
| r3232 | r3233 | |
| 1183 | 1183 | { |
| 1184 | 1184 | // taitosnd_setz80_soundcpu( 2 ); |
| 1185 | 1185 | |
| 1186 | cpua_ctrl = 0xff; | |
| 1187 | ||
| 1188 | banknum = -1; | |
| 1189 | 1186 | } |
| 1190 | 1187 | |
| 1191 | 1188 | |
| r3232 | r3233 | |
| 1197 | 1194 | |
| 1198 | 1195 | static MACHINE_START( darius ) |
| 1199 | 1196 | { |
| 1197 | cpua_ctrl = 0xff; | |
| 1198 | banknum = -1; | |
| 1199 | adpcm_command = 0; | |
| 1200 | nmi_enable = 0; | |
| 1201 | ||
| 1200 | 1202 | state_save_register_global(cpua_ctrl); |
| 1201 | 1203 | |
| 1202 | 1204 | // (there are other sound vars that may need saving too) // |
| r3232 | r3233 | |
|---|---|---|
| 326 | 326 | static READ32_HANDLER( kinst_control_r ) |
| 327 | 327 | { |
| 328 | 328 | UINT32 result; |
| 329 | static const char *portnames[] = { "P1", "P2", "VOLUME", "UNUSED", "DSW" }; | |
| 329 | static const char *const portnames[] = { "P1", "P2", "VOLUME", "UNUSED", "DSW" }; | |
| 330 | 330 | |
| 331 | 331 | /* apply shuffling */ |
| 332 | 332 | offset = control_map[offset / 2]; |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | 3800-39ff Sprite RAM |
| 14 | 14 | 6000-ffff ROM |
| 15 | 15 | |
| 16 | ||
| 17 | Konami designated Super Basketball with the label of GX405. | |
| 18 | ||
| 19 | Super Basketball is composed of two boards. A Sound board with the | |
| 20 | label PWB(B)3000288A and a CPU/Video board with the label | |
| 21 | PWB(A)2000177C silked screened onto them. All Konami custom chips have | |
| 22 | had their labels scratched off. | |
| 23 | ||
| 24 | Sound Board Parts: | |
| 25 | ||
| 26 | VLM5030 @ 11e (According to the schematics, part number scratched off) | |
| 27 | Z80 @ 6a (According to the schematics, part number scratched off) | |
| 28 | 14.31818MHz @ x1 | |
| 29 | 3.579545MHz @ x2 | |
| 30 | SN76489AN @ 8d (According to the schematics, part number scratched off) | |
| 31 | 4118 or 6116 @ 10a (According to the schematics pins match these two types of sram, part number scratched off) | |
| 32 | ||
| 33 | ||
| 34 | CPU/Video Board Parts: | |
| 35 | ||
| 36 | 18.432000MHz @ 1f | |
| 37 | M2BC200 (CR2032) Battery @ 19j | |
| 38 | ||
| 16 | 39 | ***************************************************************************/ |
| 17 | 40 | |
| 18 | 41 | #include "driver.h" |
| r3232 | r3233 | |
| 130 | 153 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_COCKTAIL |
| 131 | 154 | PORT_BIT( 0x80, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 132 | 155 | |
| 133 | PORT_START("DSW1") | |
| 134 | PORT_DIPNAME( 0x03, 0x00, DEF_STR( Game_Time ) ) | |
| 156 | PORT_START("DSW2") | |
| 157 | PORT_DIPNAME( 0x03, 0x00, DEF_STR( Game_Time ) ) PORT_DIPLOCATION( "SW2:1,2" ) | |
| 135 | 158 | PORT_DIPSETTING( 0x03, "30" ) |
| 136 | 159 | PORT_DIPSETTING( 0x01, "40" ) |
| 137 | 160 | PORT_DIPSETTING( 0x02, "50" ) |
| 138 | 161 | PORT_DIPSETTING( 0x00, "60" ) |
| 139 | PORT_DIPNAME( 0x04, 0x00, DEF_STR( Cabinet ) ) | |
| 162 | PORT_DIPNAME( 0x04, 0x00, DEF_STR( Cabinet ) ) PORT_DIPLOCATION( "SW2:3" ) | |
| 140 | 163 | PORT_DIPSETTING( 0x00, DEF_STR( Upright ) ) |
| 141 | 164 | PORT_DIPSETTING( 0x04, DEF_STR( Cocktail ) ) |
| 142 | PORT_DIPNAME( 0x08, 0x08, "Starting Score" ) | |
| 165 | PORT_DIPNAME( 0x08, 0x08, "Starting Score" ) PORT_DIPLOCATION( "SW2:4" ) | |
| 143 | 166 | PORT_DIPSETTING( 0x08, "70-78" ) |
| 144 | 167 | PORT_DIPSETTING( 0x00, "100-115" ) |
| 145 | PORT_DIPNAME( 0x10, 0x00, "Ranking" ) | |
| 168 | PORT_DIPNAME( 0x10, 0x00, "Ranking" ) PORT_DIPLOCATION( "SW2:5" ) | |
| 146 | 169 | PORT_DIPSETTING( 0x00, "Data Remaining" ) |
| 147 | 170 | PORT_DIPSETTING( 0x10, "Data Initialized" ) |
| 148 | PORT_DIPNAME( 0x60, 0x60, DEF_STR( Difficulty ) ) | |
| 171 | PORT_DIPNAME( 0x60, 0x60, DEF_STR( Difficulty ) ) PORT_DIPLOCATION( "SW2:6,7" ) | |
| 149 | 172 | PORT_DIPSETTING( 0x60, DEF_STR( Easy ) ) |
| 150 | 173 | PORT_DIPSETTING( 0x40, DEF_STR( Medium ) ) |
| 151 | 174 | PORT_DIPSETTING( 0x20, DEF_STR( Hard ) ) |
| 152 | 175 | PORT_DIPSETTING( 0x00, DEF_STR( Hardest ) ) |
| 153 | PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) ) | |
| 176 | PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION( "SW2:8" ) | |
| 154 | 177 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 155 | 178 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 156 | 179 | |
| 157 | PORT_START("DSW2") | |
| 158 | PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coin_A ) ) | |
| 180 | PORT_START("DSW1") | |
| 181 | PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coin_A ) ) PORT_DIPLOCATION( "SW1:1,2,3,4" ) | |
| 159 | 182 | PORT_DIPSETTING( 0x02, DEF_STR( 4C_1C ) ) |
| 160 | 183 | PORT_DIPSETTING( 0x05, DEF_STR( 3C_1C ) ) |
| 161 | 184 | PORT_DIPSETTING( 0x08, DEF_STR( 2C_1C ) ) |
| r3232 | r3233 | |
| 172 | 195 | PORT_DIPSETTING( 0x0a, DEF_STR( 1C_6C ) ) |
| 173 | 196 | PORT_DIPSETTING( 0x09, DEF_STR( 1C_7C ) ) |
| 174 | 197 | PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) |
| 175 | PORT_DIPNAME( 0xf0, 0xf0, DEF_STR( Coin_B ) ) | |
| 198 | PORT_DIPNAME( 0xf0, 0xf0, DEF_STR( Coin_B ) ) PORT_DIPLOCATION( "SW1:5,6,7,8" ) | |
| 176 | 199 | PORT_DIPSETTING( 0x20, DEF_STR( 4C_1C ) ) |
| 177 | 200 | PORT_DIPSETTING( 0x50, DEF_STR( 3C_1C ) ) |
| 178 | 201 | PORT_DIPSETTING( 0x80, DEF_STR( 2C_1C ) ) |
| r3232 | r3233 | |
| 188 | 211 | PORT_DIPSETTING( 0xb0, DEF_STR( 1C_5C ) ) |
| 189 | 212 | PORT_DIPSETTING( 0xa0, DEF_STR( 1C_6C ) ) |
| 190 | 213 | PORT_DIPSETTING( 0x90, DEF_STR( 1C_7C ) ) |
| 191 | PORT_DIPSETTING( 0x00, | |
| 214 | PORT_DIPSETTING( 0x00, "Inv | |
| 192 | 215 | INPUT_PORTS_END |
| 193 | 216 | |
| 194 | 217 | |
| r3232 | r3233 | |
| 233 | 256 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 234 | 257 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 235 | 258 | |
| 236 | MDRV_CPU_ADD("audio", Z80,14318 | |
| 259 | MDRV_CPU_ADD("audio", Z80, XTAL_14_31818MHz / 4) /* 3.5795 MHz */ | |
| 237 | 260 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 238 | 261 | |
| 239 | 262 | /* video hardware */ |
| r3232 | r3233 | |
| 257 | 280 | MDRV_SOUND_ADD("dac", DAC, 0) |
| 258 | 281 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.80) |
| 259 | 282 | |
| 260 | MDRV_SOUND_ADD("sn", SN7649 | |
| 283 | MDRV_SOUND_ADD("sn", SN76489 | |
| 261 | 284 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 262 | 285 | |
| 263 | MDRV_SOUND_ADD("vlm", VLM5030, 35 | |
| 286 | MDRV_SOUND_ADD("vlm", VLM5030, XTAL_3_579545MHz) /* Schematics say 3.58MHz, but board uses 3.579545MHz xtal */ | |
| 264 | 287 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 265 | 288 | MACHINE_DRIVER_END |
| 266 | 289 | |
| r3232 | r3233 | |
| 272 | 295 | |
| 273 | 296 | ***************************************************************************/ |
| 274 | 297 | |
| 298 | /* | |
| 299 | Super Basketball (version H, unprotected) | |
| 300 | ||
| 301 | Jumper Settings for CPU/Video Board | |
| 302 | ||
| 303 | JP6 set to 27128 with a null resistor | |
| 304 | JP5 set to A with a null resistor | |
| 305 | JP4 set to 27128 with a null resistor | |
| 306 | JP3 connected with a solder blob | |
| 307 | JP2 connected | |
| 308 | ||
| 309 | Jumper Settings for Sound Board | |
| 310 | ||
| 311 | J1 connected with a null resistor | |
| 312 | */ | |
| 313 | ||
| 275 | 314 | ROM_START( sbasketb ) |
| 276 | ROM_REGION( 0x10000, "main", 0 ) | |
| 277 | ROM_LOAD( "405g05", 0x6000, 0x2000, CRC(336dc0ab) SHA1(0fe47fdbf183683c569785fc6b980337a9cfde95) ) | |
| 278 | ROM_LOAD( "405g04", 0x8000, 0x2000, CRC(f064a9bc) SHA1(4f1b94a880385c6ba74cc0883b24f6fec934e35d) ) | |
| 279 | ROM_LOAD( "405g03", 0xa000, 0x2000, CRC(b9de7d53) SHA1(5a4e5491ff3511992d949367fd7b5d383c2727db) ) | |
| 280 | ROM_LOAD( "405g02", 0xc000, 0x2000, CRC(e98470a0) SHA1(79af25af941fe357a8c9f0a2f11e5558670b8027) ) | |
| 281 | ROM_LOAD( "405g01", 0xe000, 0x2000, CRC(1bd0cd2e) SHA1(d162f9b989f718d9882a02a8c64743adf3d8e239) ) | |
| 315 | ROM_REGION( 0x10000, "main", 0 ) /* roms located on the CPU/Video board */ | |
| 316 | ROM_LOAD( "405h05.14j", 0x6000, 0x2000, CRC(263ec36b) SHA1(b445b600726ba4935623311e1a178aeb4a356b0a) ) | |
| 317 | ROM_LOAD( "405h03.11j", 0x8000, 0x4000, CRC(0a4d7a82) SHA1(2e0153b41e23284427881258a44bd55be3570eb2) ) | |
| 318 | ROM_LOAD( "405h01.9j", 0xc000, 0x4000, CRC(4f9dd9a0) SHA1(97f4c208509d50a7ce4c1ebe8a3f643ad75e833b) ) | |
| 282 | 319 | |
| 283 | ROM_REGION( 0x10000, "audio", 0 ) | |
| 284 | ROM_LOAD( "405e13", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 320 | ROM_REGION( 0x10000, "audio", 0 ) /* roms located on Sound Board */ | |
| 321 | ROM_LOAD( "405e13.7a", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 285 | 322 | |
| 286 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) | |
| 287 | ROM_LOAD( "405e12", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 323 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 324 | ROM_LOAD( "405e12.22f", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 288 | 325 | |
| 289 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) | |
| 290 | ROM_LOAD( "405e06", 0x0000, 0x2000, CRC(7e2f5bb2) SHA1(e22008c0ef7ae000dcca7f43a386d43064aaea62) ) | |
| 291 | ROM_LOAD( "405e07", 0x2000, 0x2000, CRC(963a44f9) SHA1(03cd7699668b010f27af025ba6bd44509526ec7b) ) | |
| 292 | ROM_LOAD( "405e08", 0x4000, 0x2000, CRC(63901deb) SHA1(c65d896298846ed8b70a4d38b32820746214fa5c) ) | |
| 293 | ROM_LOAD( "405e09", 0x6000, 0x2000, CRC(e1873677) SHA1(19788e43cc1a6cf5ab375cbc2c745bb6cc8c163d) ) | |
| 294 | ROM_LOAD( "405e10", 0x8000, 0x2000, CRC(824815e8) SHA1(470e9d74fa2c397605a74e0bf173a6d9db4cc721) ) | |
| 295 | ROM_LOAD( "405e11", 0xa000, 0x2000, CRC(dca9b447) SHA1(12d7e85dc2fc6bd4ea7ad9035ae0b7487e4bc4bc) ) | |
| 326 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 327 | ROM_LOAD( "405h06.14g", 0x0000, 0x4000, CRC(cfbbff07) SHA1(39b19866b21372524933b5eef511bb5b7ad92556) ) | |
| 328 | ROM_LOAD( "405h08.17g", 0x4000, 0x4000, CRC(c75901b6) SHA1(4ff87123228da068f0c0ffffa4a3f03765eccd8d) ) | |
| 329 | ROM_LOAD( "405h10.20g", 0x8000, 0x4000, CRC(95bc5942) SHA1(55bf35283385d0ae768210706720a3b289ebd9a2) ) | |
| 296 | 330 | |
| 297 | ROM_REGION( 0x0500, "proms", 0 ) | |
| 298 | ROM_LOAD( "405e17", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 299 | ROM_LOAD( "405e16", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 300 | ROM_LOAD( "405e18", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 301 | ROM_LOAD( "405e20", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 302 | ROM_LOAD( "405e19", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 331 | ROM_REGION( 0x0500, "proms", 0 ) /* roms located on the CPU/Video board */ | |
| 332 | ROM_LOAD( "405e17.5a", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 333 | ROM_LOAD( "405e16.4a", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 334 | ROM_LOAD( "405e18.6a", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 335 | ROM_LOAD( "405e20.19d", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 336 | ROM_LOAD( "405e19.16d", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 303 | 337 | |
| 304 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom */ | |
| 305 | ROM_LOAD( "405e15", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 338 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom, located on Sound Board */ | |
| 339 | ROM_LOAD( "405e15.11f", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 306 | 340 | ROM_END |
| 307 | 341 | |
| 308 | ROM_START( sbasketo ) | |
| 309 | ROM_REGION( 0x10000, "main", 0 ) | |
| 310 | ROM_LOAD( "405e05", 0x6000, 0x2000, CRC(32ea5b71) SHA1(d917c31d2c9a7229396e4a930e8d27394329533a) ) | |
| 311 | ROM_LOAD( "405e04", 0x8000, 0x2000, CRC(7abf3087) SHA1(fbaaaaae0b8bed1bc6ad7f2da267c2ef8bd75b15) ) | |
| 312 | ROM_LOAD( "405e03", 0xa000, 0x2000, CRC(9c6fcdcd) SHA1(a644ec98f49f84311829149c181aba25e7681793) ) | |
| 313 | ROM_LOAD( "405e02", 0xc000, 0x2000, CRC(0f145648) SHA1(2e238eb0663295887bf6b4905f1fd386db16d82a) ) | |
| 314 | ROM_LOAD( "405e01", 0xe000, 0x2000, CRC(6a27f1b1) SHA1(38c0be98fb122a7a6ed833af011bda5663a06510) ) | |
| 315 | 342 | |
| 316 | ROM_REGION( 0x10000, "audio", 0 ) | |
| 317 | ROM_LOAD( "405e13", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 343 | /* | |
| 344 | Super Basketball (version G, encrypted) | |
| 345 | */ | |
| 318 | 346 | |
| 319 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) | |
| 320 | ROM_LOAD( "405e12", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 347 | ROM_START( sbasketg ) | |
| 348 | ROM_REGION( 0x10000, "main", 0 ) /* roms located on the CPU/Video board */ | |
| 349 | ROM_LOAD( "405g05", 0x6000, 0x2000, CRC(336dc0ab) SHA1(0fe47fdbf183683c569785fc6b980337a9cfde95) ) | |
| 350 | ROM_LOAD( "405g04", 0x8000, 0x2000, CRC(f064a9bc) SHA1(4f1b94a880385c6ba74cc0883b24f6fec934e35d) ) | |
| 351 | ROM_LOAD( "405g03", 0xa000, 0x2000, CRC(b9de7d53) SHA1(5a4e5491ff3511992d949367fd7b5d383c2727db) ) | |
| 352 | ROM_LOAD( "405g02", 0xc000, 0x2000, CRC(e98470a0) SHA1(79af25af941fe357a8c9f0a2f11e5558670b8027) ) | |
| 353 | ROM_LOAD( "405g01", 0xe000, 0x2000, CRC(1bd0cd2e) SHA1(d162f9b989f718d9882a02a8c64743adf3d8e239) ) | |
| 321 | 354 | |
| 322 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) | |
| 323 | ROM_LOAD( "405e06", 0x0000, 0x2000, CRC(7e2f5bb2) SHA1(e22008c0ef7ae000dcca7f43a386d43064aaea62) ) | |
| 324 | ROM_LOAD( "405e07", 0x2000, 0x2000, CRC(963a44f9) SHA1(03cd7699668b010f27af025ba6bd44509526ec7b) ) | |
| 325 | ROM_LOAD( "405e08", 0x4000, 0x2000, CRC(63901deb) SHA1(c65d896298846ed8b70a4d38b32820746214fa5c) ) | |
| 326 | ROM_LOAD( "405e09", 0x6000, 0x2000, CRC(e1873677) SHA1(19788e43cc1a6cf5ab375cbc2c745bb6cc8c163d) ) | |
| 327 | ROM_LOAD( "405e10", 0x8000, 0x2000, CRC(824815e8) SHA1(470e9d74fa2c397605a74e0bf173a6d9db4cc721) ) | |
| 328 | ROM_LOAD( "405e11", 0xa000, 0x2000, CRC(dca9b447) SHA1(12d7e85dc2fc6bd4ea7ad9035ae0b7487e4bc4bc) ) | |
| 355 | ROM_REGION( 0x10000, "audio", 0 ) /* roms located on Sound Board */ | |
| 356 | ROM_LOAD( "405e13.7a", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 329 | 357 | |
| 330 | ROM_REGION( 0x0500, "proms", 0 ) | |
| 331 | ROM_LOAD( "405e17", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 332 | ROM_LOAD( "405e16", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 333 | ROM_LOAD( "405e18", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 334 | ROM_LOAD( "405e20", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 335 | ROM_LOAD( "405e19", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 358 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 359 | ROM_LOAD( "405e12.22f", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 336 | 360 | |
| 337 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom */ | |
| 338 | ROM_LOAD( "405e15", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 361 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 362 | ROM_LOAD( "405e06", 0x0000, 0x2000, CRC(7e2f5bb2) SHA1(e22008c0ef7ae000dcca7f43a386d43064aaea62) ) | |
| 363 | ROM_LOAD( "405e07", 0x2000, 0x2000, CRC(963a44f9) SHA1(03cd7699668b010f27af025ba6bd44509526ec7b) ) | |
| 364 | ROM_LOAD( "405e08", 0x4000, 0x2000, CRC(63901deb) SHA1(c65d896298846ed8b70a4d38b32820746214fa5c) ) | |
| 365 | ROM_LOAD( "405e09", 0x6000, 0x2000, CRC(e1873677) SHA1(19788e43cc1a6cf5ab375cbc2c745bb6cc8c163d) ) | |
| 366 | ROM_LOAD( "405e10", 0x8000, 0x2000, CRC(824815e8) SHA1(470e9d74fa2c397605a74e0bf173a6d9db4cc721) ) | |
| 367 | ROM_LOAD( "405e11", 0xa000, 0x2000, CRC(dca9b447) SHA1(12d7e85dc2fc6bd4ea7ad9035ae0b7487e4bc4bc) ) | |
| 368 | ||
| 369 | ROM_REGION( 0x0500, "proms", 0 ) /* roms located on the CPU/Video board */ | |
| 370 | ROM_LOAD( "405e17.5a", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 371 | ROM_LOAD( "405e16.4a", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 372 | ROM_LOAD( "405e18.6a", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 373 | ROM_LOAD( "405e20.19d", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 374 | ROM_LOAD( "405e19.16d", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 375 | ||
| 376 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom, located on Sound Board */ | |
| 377 | ROM_LOAD( "405e15.11f", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 339 | 378 | ROM_END |
| 340 | 379 | |
| 341 | ROM_START( sbasketu ) | |
| 342 | ROM_REGION( 0x10000, "main", 0 ) | |
| 343 | ROM_LOAD( "sbb_j13.bin", 0x6000, 0x2000, CRC(263ec36b) SHA1(b445b600726ba4935623311e1a178aeb4a356b0a) ) | |
| 344 | ROM_LOAD( "sbb_j11.bin", 0x8000, 0x4000, CRC(0a4d7a82) SHA1(2e0153b41e23284427881258a44bd55be3570eb2) ) | |
| 345 | ROM_LOAD( "sbb_j09.bin", 0xc000, 0x4000, CRC(4f9dd9a0) SHA1(97f4c208509d50a7ce4c1ebe8a3f643ad75e833b) ) | |
| 346 | 380 | |
| 347 | ROM_REGION( 0x10000, "audio", 0 ) | |
| 348 | ROM_LOAD( "405e13", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 381 | /* | |
| 382 | Super Basketball (version E, encrypted) | |
| 383 | */ | |
| 349 | 384 | |
| 350 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) | |
| 351 | ROM_LOAD( "405e12", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 385 | ROM_START( sbaskete ) | |
| 386 | ROM_REGION( 0x10000, "main", 0 ) /* roms located on the CPU/Video board */ | |
| 387 | ROM_LOAD( "405e05", 0x6000, 0x2000, CRC(32ea5b71) SHA1(d917c31d2c9a7229396e4a930e8d27394329533a) ) | |
| 388 | ROM_LOAD( "405e04", 0x8000, 0x2000, CRC(7abf3087) SHA1(fbaaaaae0b8bed1bc6ad7f2da267c2ef8bd75b15) ) | |
| 389 | ROM_LOAD( "405e03", 0xa000, 0x2000, CRC(9c6fcdcd) SHA1(a644ec98f49f84311829149c181aba25e7681793) ) | |
| 390 | ROM_LOAD( "405e02", 0xc000, 0x2000, CRC(0f145648) SHA1(2e238eb0663295887bf6b4905f1fd386db16d82a) ) | |
| 391 | ROM_LOAD( "405e01", 0xe000, 0x2000, CRC(6a27f1b1) SHA1(38c0be98fb122a7a6ed833af011bda5663a06510) ) | |
| 352 | 392 | |
| 353 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) | |
| 354 | ROM_LOAD( "405e06", 0x0000, 0x2000, CRC(7e2f5bb2) SHA1(e22008c0ef7ae000dcca7f43a386d43064aaea62) ) | |
| 355 | ROM_LOAD( "405e07", 0x2000, 0x2000, CRC(963a44f9) SHA1(03cd7699668b010f27af025ba6bd44509526ec7b) ) | |
| 356 | ROM_LOAD( "405e08", 0x4000, 0x2000, CRC(63901deb) SHA1(c65d896298846ed8b70a4d38b32820746214fa5c) ) | |
| 357 | ROM_LOAD( "405e09", 0x6000, 0x2000, CRC(e1873677) SHA1(19788e43cc1a6cf5ab375cbc2c745bb6cc8c163d) ) | |
| 358 | ROM_LOAD( "405e10", 0x8000, 0x2000, CRC(824815e8) SHA1(470e9d74fa2c397605a74e0bf173a6d9db4cc721) ) | |
| 359 | ROM_LOAD( "405e11", 0xa000, 0x2000, CRC(dca9b447) SHA1(12d7e85dc2fc6bd4ea7ad9035ae0b7487e4bc4bc) ) | |
| 393 | ROM_REGION( 0x10000, "audio", 0 ) /* roms located on Sound Board */ | |
| 394 | ROM_LOAD( "405e13.7a", 0x0000, 0x2000, CRC(1ec7458b) SHA1(a015b982bff5f9e7ece33f2e69ff8c6c2174e710) ) | |
| 360 | 395 | |
| 361 | ROM_REGION( 0x0500, "proms", 0 ) | |
| 362 | ROM_LOAD( "405e17", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 363 | ROM_LOAD( "405e16", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 364 | ROM_LOAD( "405e18", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 365 | ROM_LOAD( "405e20", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 366 | ROM_LOAD( "405e19", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 396 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 397 | ROM_LOAD( "405e12.22f", 0x0000, 0x4000, CRC(e02c54da) SHA1(2fa19f3bce894ef05820f95e0b88428e4f946a35) ) | |
| 367 | 398 | |
| 368 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom */ | |
| 369 | ROM_LOAD( "405e15", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 399 | ROM_REGION( 0x0c000, "gfx2", ROMREGION_DISPOSE ) /* roms located on the CPU/Video board */ | |
| 400 | ROM_LOAD( "405e06", 0x0000, 0x2000, CRC(7e2f5bb2) SHA1(e22008c0ef7ae000dcca7f43a386d43064aaea62) ) | |
| 401 | ROM_LOAD( "405e07", 0x2000, 0x2000, CRC(963a44f9) SHA1(03cd7699668b010f27af025ba6bd44509526ec7b) ) | |
| 402 | ROM_LOAD( "405e08", 0x4000, 0x2000, CRC(63901deb) SHA1(c65d896298846ed8b70a4d38b32820746214fa5c) ) | |
| 403 | ROM_LOAD( "405e09", 0x6000, 0x2000, CRC(e1873677) SHA1(19788e43cc1a6cf5ab375cbc2c745bb6cc8c163d) ) | |
| 404 | ROM_LOAD( "405e10", 0x8000, 0x2000, CRC(824815e8) SHA1(470e9d74fa2c397605a74e0bf173a6d9db4cc721) ) | |
| 405 | ROM_LOAD( "405e11", 0xa000, 0x2000, CRC(dca9b447) SHA1(12d7e85dc2fc6bd4ea7ad9035ae0b7487e4bc4bc) ) | |
| 406 | ||
| 407 | ROM_REGION( 0x0500, "proms", 0 ) /* roms located on the CPU/Video board */ | |
| 408 | ROM_LOAD( "405e17.5a", 0x0000, 0x0100, CRC(b4c36d57) SHA1(c4a63f57edce2b9588e2394ff54a28f91213d550) ) /* palette red component */ | |
| 409 | ROM_LOAD( "405e16.4a", 0x0100, 0x0100, CRC(0b7b03b8) SHA1(81297cb2b0b28b0fc0939a37ff30844d69fb65ac) ) /* palette green component */ | |
| 410 | ROM_LOAD( "405e18.6a", 0x0200, 0x0100, CRC(9e533bad) SHA1(611e7af6813caaf2bc36c311ae48a5efd30e6f0c) ) /* palette blue component */ | |
| 411 | ROM_LOAD( "405e20.19d", 0x0300, 0x0100, CRC(8ca6de2f) SHA1(67d29708d1a07d17c5dc5793a3293e7ace3a4e19) ) /* character lookup table */ | |
| 412 | ROM_LOAD( "405e19.16d", 0x0400, 0x0100, CRC(e0bc782f) SHA1(9f71e696d11a60f771535f6837ecad6132047b0a) ) /* sprite lookup table */ | |
| 413 | ||
| 414 | ROM_REGION( 0x10000, "vlm", 0 ) /* 64k for speech rom, located on Sound Board */ | |
| 415 | ROM_LOAD( "405e15.11f", 0x0000, 0x2000, CRC(01bb5ce9) SHA1(f48477b4011befba13c8bcd83e0c9f7deb14a1e1) ) | |
| 370 | 416 | ROM_END |
| 371 | 417 | |
| 372 | 418 | |
| r3232 | r3233 | |
| 375 | 421 | konami1_decode(machine, "main"); |
| 376 | 422 | } |
| 377 | 423 | |
| 378 | ||
| 379 | GAME( 1984, sbasketb, 0, sbasketb, sbasketb, sbasketb, ROT90, "Konami", "Super Basketball (version G)", 0 ) | |
| 380 | GAME( 1984, sbasketo, sbasketb, sbasketb, sbasketb, sbasketb, ROT90, "Konami", "Super Basketball (version E)", 0 ) | |
| 381 | GAME( 1984, sbasketu, sbasketb, sbasketb, sbasketb, 0, ROT90, "Konami", "Super Basketball (not encrypted)", 0 ) | |
| 424 | GAME( 1984, sbasketb, 0, sbasketb, sbasketb, 0, ROT90, "Konami", "Super Basketball (version H, unprotected)", GAME_SUPPORTS_SAVE ) | |
| 425 | GAME( 1984, sbasketg, sbasketb, sbasketb, sbasketb, sbasketb, ROT90, "Konami", "Super Basketball (version G, encrypted)", GAME_SUPPORTS_SAVE ) | |
| 426 | GAME( 1984, sbaskete, sbasketb, sbasketb, sbasketb, sbasketb, ROT90, "Konami", "Super Basketball (version E, encrypted)", GAME_SUPPORTS_SAVE ) |
| r3232 | r3233 | |
|---|---|---|
| 83 | 83 | static INT32 cur_sound_region, xexex_strip0x1a; |
| 84 | 84 | static int suspension_active, resume_trigger; |
| 85 | 85 | static emu_timer *dmadelay_timer; |
| 86 | static int frame; | |
| 86 | 87 | |
| 87 | 88 | |
| 88 | 89 | static const eeprom_interface eeprom_intf = |
| r3232 | r3233 | |
| 147 | 148 | |
| 148 | 149 | static void xexex_objdma(running_machine *machine, int limiter) |
| 149 | 150 | { |
| 150 | static int frame = -1; | |
| 151 | ||
| 152 | 151 | int counter, num_inactive; |
| 153 | 152 | UINT16 *src, *dst; |
| 154 | 153 | |
| r3232 | r3233 | |
| 602 | 601 | |
| 603 | 602 | static MACHINE_RESET( xexex ) |
| 604 | 603 | { |
| 604 | cur_control2 = 0; | |
| 605 | init_eeprom_count = 0; | |
| 605 | 606 | cur_sound_region = 0; |
| 606 | 607 | suspension_active = 0; |
| 608 | resume_trigger = 0; | |
| 609 | frame = -1; | |
| 607 | 610 | k054539_init_flags(0, K054539_REVERSE_STEREO); |
| 608 | 611 | } |
| 609 | 612 |
| r3232 | r3233 | |
|---|---|---|
| 1973 | 1973 | static UINT32 chardma_other; |
| 1974 | 1974 | |
| 1975 | 1975 | //static UINT8* current_table; |
| 1976 | static UINT32 current_table_address | |
| 1976 | static UINT32 current_table_address | |
| 1977 | 1977 | |
| 1978 | 1978 | static int cps3_rle_length = 0; |
| 1979 | 1979 | |
| r3232 | r3233 | |
| 2459 | 2459 | |
| 2460 | 2460 | static MACHINE_RESET( cps3 ) |
| 2461 | 2461 | { |
| 2462 | current_table_address = -1; | |
| 2463 | ||
| 2462 | 2464 | if (cps3_use_fastboot) |
| 2463 | 2465 | { |
| 2464 | 2466 | fastboot_timer = timer_alloc(fastboot_timer_callback, NULL); |
| r3232 | r3233 | |
|---|---|---|
| 104 | 104 | static READ8_HANDLER( keyboard_r ) |
| 105 | 105 | { |
| 106 | 106 | int res = 0x3f,i; |
| 107 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5", "KEY6", "KEY7", "KEY8", "KEY9", "KEY10", "KEY11" }; | |
| 107 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5", "KEY6", "KEY7", "KEY8", "KEY9", "KEY10", "KEY11" }; | |
| 108 | 108 | |
| 109 | 109 | // logerror("%04x: keyboard_r\n", activecpu_get_pc()); |
| 110 | 110 |
| r3232 | r3233 | |
|---|---|---|
| 5 | 5 | Ernesto Corvi |
| 6 | 6 | ernesto@imagina.com |
| 7 | 7 | |
| 8 | ||
| 9 | Konami designated Jail Break with the label of GX507. (There is also | |
| 10 | the label PWB 300394A silk screened onto the board.) | |
| 11 | ||
| 12 | ||
| 13 | Board Parts: | |
| 14 | ||
| 15 | Konami A082 @ 11a (Encrypted 6809 CPU) | |
| 16 | VLM5030 @ 6a | |
| 17 | Konami 005849 @ 8e | |
| 18 | 18.432000MHz @ OSC | |
| 19 | 3.579545MHz @ XTAL | |
| 20 | SN76489AN @ 6d | |
| 21 | 6301 @ 6f and 7f (PROM's) | |
| 22 | 6331 @ 1f and 2f (PROM's) | |
| 23 | ||
| 8 | 24 | ***************************************************************************/ |
| 9 | 25 | |
| 10 | 26 | /* |
| r3232 | r3233 | |
| 126 | 142 | PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 127 | 143 | |
| 128 | 144 | PORT_START("DSW1") /* $3303 */ |
| 129 | PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coin_A ) ) | |
| 145 | PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coin_A ) ) PORT_DIPLOCATION( "SW1:4,3,2,1" ) | |
| 130 | 146 | PORT_DIPSETTING( 0x02, DEF_STR( 4C_1C ) ) |
| 131 | 147 | PORT_DIPSETTING( 0x05, DEF_STR( 3C_1C ) ) |
| 132 | 148 | PORT_DIPSETTING( 0x08, DEF_STR( 2C_1C ) ) |
| r3232 | r3233 | |
| 143 | 159 | PORT_DIPSETTING( 0x0a, DEF_STR( 1C_6C ) ) |
| 144 | 160 | PORT_DIPSETTING( 0x09, DEF_STR( 1C_7C ) ) |
| 145 | 161 | PORT_DIPSETTING( 0x00, DEF_STR( Free_Play ) ) |
| 146 | PORT_DIPNAME( 0xf0, 0xf0, DEF_STR( Coin_B ) ) | |
| 162 | PORT_DIPNAME( 0xf0, 0xf0, DEF_STR( Coin_B ) ) PORT_DIPLOCATION( "SW1:8,7,6,5" ) | |
| 147 | 163 | PORT_DIPSETTING( 0x20, DEF_STR( 4C_1C ) ) |
| 148 | 164 | PORT_DIPSETTING( 0x50, DEF_STR( 3C_1C ) ) |
| 149 | 165 | PORT_DIPSETTING( 0x80, DEF_STR( 2C_1C ) ) |
| r3232 | r3233 | |
| 162 | 178 | PORT_DIPSETTING( 0x00, "Invalid" ) |
| 163 | 179 | |
| 164 | 180 | PORT_START("DSW2") /* $3100 */ |
| 165 | PORT_DIPNAME( 0x03, 0x01, DEF_STR( Lives ) ) | |
| 181 | PORT_DIPNAME( 0x03, 0x01, DEF_STR( Lives ) ) PORT_DIPLOCATION( "SW2:1,2" ) | |
| 166 | 182 | PORT_DIPSETTING( 0x03, "1" ) |
| 167 | 183 | PORT_DIPSETTING( 0x02, "2" ) |
| 168 | 184 | PORT_DIPSETTING( 0x01, "3" ) |
| 169 | 185 | PORT_DIPSETTING( 0x00, "5" ) |
| 170 | PORT_DIPNAME( 0x04, 0x00, DEF_STR( Cabinet ) ) | |
| 186 | PORT_DIPNAME( 0x04, 0x00, DEF_STR( Cabinet ) ) PORT_DIPLOCATION( "SW2:3" ) | |
| 171 | 187 | PORT_DIPSETTING( 0x00, DEF_STR( Upright ) ) |
| 172 | 188 | PORT_DIPSETTING( 0x04, DEF_STR( Cocktail ) ) |
| 173 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Bonus_Life ) ) | |
| 189 | PORT_DIPNAME( 0x08, 0x08, DEF_STR( Bonus_Life ) ) PORT_DIPLOCATION( "SW2:4" ) | |
| 174 | 190 | PORT_DIPSETTING( 0x08, "30K 70K+" ) |
| 175 | 191 | PORT_DIPSETTING( 0x00, "40K 80K+" ) |
| 176 | PORT_DIPNAME( 0x30, 0x10, DEF_STR( Difficulty ) ) | |
| 192 | PORT_DIPNAME( 0x30, 0x10, DEF_STR( Difficulty ) ) PORT_DIPLOCATION( "SW2:5,6" ) | |
| 177 | 193 | PORT_DIPSETTING( 0x30, DEF_STR( Easy ) ) |
| 178 | 194 | PORT_DIPSETTING( 0x20, DEF_STR( Normal ) ) |
| 179 | 195 | PORT_DIPSETTING( 0x10, "Difficult" ) |
| 180 | 196 | PORT_DIPSETTING( 0x00, "Very Difficult" ) |
| 181 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 182 | PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) ) | |
| 197 | PORT_BIT( 0x40, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_DIPLOCATION( "SW2:7" ) | |
| 198 | PORT_DIPNAME( 0x80, 0x00, DEF_STR( Demo_Sounds ) ) PORT_DIPLOCATION( "SW2:8" ) | |
| 183 | 199 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 184 | 200 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 185 | 201 | |
| 186 | 202 | PORT_START("DSW3") /* $3200 */ |
| 187 | PORT_DIPNAME( 0x01, 0x01, DEF_STR( Flip_Screen ) ) | |
| 203 | PORT_DIPNAME( 0x01, 0x01, DEF_STR( Flip_Screen ) ) PORT_DIPLOCATION( "SW3:1" ) | |
| 188 | 204 | PORT_DIPSETTING( 0x01, DEF_STR( Off ) ) |
| 189 | 205 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 190 | PORT_DIPNAME( 0x02, 0x02, "Upright Controls" ) | |
| 206 | PORT_DIPNAME( 0x02, 0x02, "Upright Controls" ) PORT_DIPLOCATION( "SW3:2" ) | |
| 191 | 207 | PORT_DIPSETTING( 0x02, DEF_STR( Single ) ) |
| 192 | 208 | PORT_DIPSETTING( 0x00, DEF_STR( Dual ) ) |
| 193 | PORT_BIT( 0x0c, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 209 | PORT_BIT( 0x04, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_DIPLOCATION( "SW3:3" ) | |
| 210 | PORT_BIT( 0x08, IP_ACTIVE_LOW, IPT_UNUSED ) PORT_DIPLOCATION( "SW3:4" ) | |
| 194 | 211 | INPUT_PORTS_END |
| 195 | 212 | |
| 196 | 213 | |
| r3232 | r3233 | |
| 256 | 273 | /* sound hardware */ |
| 257 | 274 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 258 | 275 | |
| 259 | MDRV_SOUND_ADD("sn", SN7649 | |
| 276 | MDRV_SOUND_ADD("sn", SN76489 | |
| 260 | 277 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 261 | 278 | |
| 262 | 279 | MDRV_SOUND_ADD("vlm", VLM5030, VOICE_CLOCK) |
| r3232 | r3233 | |
| 272 | 289 | |
| 273 | 290 | ROM_START( jailbrek ) |
| 274 | 291 | ROM_REGION( 0x10000, "main", 0 ) |
| 275 | ROM_LOAD( "jailb11d.bin", 0x8000, 0x4000, CRC(a0b88dfd) SHA1(f999e382b9d3b812fca41f4d0da3ea692fef6b19) ) | |
| 276 | ROM_LOAD( "jailb9d.bin", 0xc000, 0x4000, CRC(444b7d8e) SHA1(c708b67c2d249448dae9a3d10c24d13ba6849597) ) | |
| 292 | ROM_LOAD( "507p03.11d", 0x8000, 0x4000, CRC(a0b88dfd) SHA1(f999e382b9d3b812fca41f4d0da3ea692fef6b19) ) | |
| 293 | ROM_LOAD( "507p02.9d", 0xc000, 0x4000, CRC(444b7d8e) SHA1(c708b67c2d249448dae9a3d10c24d13ba6849597) ) | |
| 277 | 294 | |
| 278 | 295 | ROM_REGION( 0x08000, "gfx1", ROMREGION_DISPOSE ) |
| 279 | ROM_LOAD( "jailb4f.bin", 0x00000, 0x4000, CRC(e3b7a226) SHA1(c19a02a2def65648bf198fccec98ebbd2fc7c0fb) ) /* characters */ | |
| 280 | ROM_LOAD( "jailb5f.bin", 0x04000, 0x4000, CRC(504f0912) SHA1(b51a45dd5506bccdf0061dd6edd7f49ac86ed0f8) ) | |
| 296 | ROM_LOAD( "507l08.4f", 0x0000, 0x4000, CRC(e3b7a226) SHA1(c19a02a2def65648bf198fccec98ebbd2fc7c0fb) ) /* characters */ | |
| 297 | ROM_LOAD( "507j09.5f", 0x4000, 0x4000, CRC(504f0912) SHA1(b51a45dd5506bccdf0061dd6edd7f49ac86ed0f8) ) | |
| 281 | 298 | |
| 282 | 299 | ROM_REGION( 0x10000, "gfx2", ROMREGION_DISPOSE ) |
| 283 | ROM_LOAD( "jailb3e.bin", 0x00000, 0x4000, CRC(0d269524) SHA1(a10ddb405e884bfec521a3c7a29d22f63e535b59) ) /* sprites */ | |
| 284 | ROM_LOAD( "jailb4e.bin", 0x04000, 0x4000, CRC(27d4f6f4) SHA1(c42c064dbd7c5cf0b1d99651367e0bee1728a5b0) ) | |
| 285 | ROM_LOAD( "jailb5e.bin", 0x08000, 0x4000, CRC(717485cb) SHA1(22609489186dcb3d7cd49b7ddfdc6f04d0739354) ) | |
| 286 | ROM_LOAD( "jailb3f.bin", 0x0c000, 0x4000, CRC(e933086f) SHA1(c0fd1e8d23c0f7e14c0b75f629448034420cf8ef) ) | |
| 300 | ROM_LOAD( "507j04.3e", 0x0000, 0x4000, CRC(0d269524) SHA1(a10ddb405e884bfec521a3c7a29d22f63e535b59) ) /* sprites */ | |
| 301 | ROM_LOAD( "507j05.4e", 0x4000, 0x4000, CRC(27d4f6f4) SHA1(c42c064dbd7c5cf0b1d99651367e0bee1728a5b0) ) | |
| 302 | ROM_LOAD( "507j06.5e", 0x8000, 0x4000, CRC(717485cb) SHA1(22609489186dcb3d7cd49b7ddfdc6f04d0739354) ) | |
| 303 | ROM_LOAD( "507j07.3f", 0xc000, 0x4000, CRC(e933086f) SHA1(c0fd1e8d23c0f7e14c0b75f629448034420cf8ef) ) | |
| 287 | 304 | |
| 288 | 305 | ROM_REGION( 0x0240, "proms", 0 ) |
| 289 | ROM_LOAD( "jailbbl.cl2", 0x0000, 0x0020, CRC(f1909605) SHA1(91eaa865375b3bc052897732b64b1ff7df3f78f6) ) /* red & green */ | |
| 290 | ROM_LOAD( "jailbbl.cl1", 0x0020, 0x0020, CRC(f70bb122) SHA1(bf77990260e8346faa3d3481718cbe46a4a27150) ) /* blue */ | |
| 291 | ROM_LOAD( "jailbbl.bp2", 0x0040, 0x0100, CRC(d4fe5c97) SHA1(972e9dab6c53722545dd3a43e3ada7921e88708b) ) /* char lookup */ | |
| 292 | ROM_LOAD( "jailbbl.bp1", 0x0140, 0x0100, CRC(0266c7db) SHA1(a8f21e86e6d974c9bfd92a147689d0e7316d66e2) ) /* sprites lookup */ | |
| 306 | ROM_LOAD( "507j10.1f", 0x0000, 0x0020, CRC(f1909605) SHA1(91eaa865375b3bc052897732b64b1ff7df3f78f6) ) /* red & green */ | |
| 307 | ROM_LOAD( "507j11.2f", 0x0020, 0x0020, CRC(f70bb122) SHA1(bf77990260e8346faa3d3481718cbe46a4a27150) ) /* blue */ | |
| 308 | ROM_LOAD( "507j13.7f", 0x0040, 0x0100, CRC(d4fe5c97) SHA1(972e9dab6c53722545dd3a43e3ada7921e88708b) ) /* char lookup */ | |
| 309 | ROM_LOAD( "507j12.6f", 0x0140, 0x0100, CRC(0266c7db) SHA1(a8f21e86e6d974c9bfd92a147689d0e7316d66e2) ) /* sprites lookup */ | |
| 293 | 310 | |
| 294 | ROM_REGION( 0x2000, "vlm", 0 ) /* speech rom */ | |
| 295 | ROM_LOAD( "jailb8c.bin", 0x0000, 0x2000, CRC(d91d15e3) SHA1(475fe50aafbf8f2fb79880ef0e2c25158eda5270) ) | |
| 311 | ROM_REGION( 0x4000, "vlm", 0 ) /* speech rom */ | |
| 312 | ROM_LOAD( "507l01.8c", 0x0000, 0x4000, CRC(0c8a3605) SHA1(d886b66d3861c3a90a1825ccf5bf0011831ca366) ) | |
| 296 | 313 | ROM_END |
| 297 | 314 | |
| 298 | 315 | ROM_START( manhatan ) |
| 299 | 316 | ROM_REGION( 0x10000, "main", 0 ) |
| 300 | ROM_LOAD( "507-n03.11d", 0x8000, 0x4000, CRC(e5039f7e) SHA1(0f12484ed40444d978e0405c27bdd027ae2e2a0b) ) | |
| 301 | ROM_LOAD( "507-n02.9d", 0xc000, 0x4000, CRC(143cc62c) SHA1(9520dbb1b6f1fa439e03d4caa9bed96ef8f805f2) ) | |
| 317 | ROM_LOAD( "507n03.11d", 0x8000, 0x4000, CRC(e5039f7e) SHA1(0f12484ed40444d978e0405c27bdd027ae2e2a0b) ) | |
| 318 | ROM_LOAD( "507n02.9d", 0xc000, 0x4000, CRC(143cc62c) SHA1(9520dbb1b6f1fa439e03d4caa9bed96ef8f805f2) ) | |
| 302 | 319 | |
| 303 | 320 | ROM_REGION( 0x08000, "gfx1", ROMREGION_DISPOSE ) |
| 304 | ROM_LOAD( "507-j08.4f", 0x00000, 0x4000, CRC(175e1b49) SHA1(4cfe982cdf7729bd05c6da803480571876320bf6) ) /* characters */ | |
| 305 | ROM_LOAD( "507-j09.5f", 0x04000, 0x4000, CRC(504f0912) SHA1(b51a45dd5506bccdf0061dd6edd7f49ac86ed0f8) ) | |
| 321 | ROM_LOAD( "507j08.4f", 0x0000, 0x4000, CRC(175e1b49) SHA1(4cfe982cdf7729bd05c6da803480571876320bf6) ) /* characters */ | |
| 322 | ROM_LOAD( "507j09.5f", 0x4000, 0x4000, CRC(504f0912) SHA1(b51a45dd5506bccdf0061dd6edd7f49ac86ed0f8) ) | |
| 306 | 323 | |
| 307 | 324 | ROM_REGION( 0x10000, "gfx2", ROMREGION_DISPOSE ) |
| 308 | ROM_LOAD( "507-j04.3e", 0x00000, 0x4000, CRC(0d269524) SHA1(a10ddb405e884bfec521a3c7a29d22f63e535b59) ) /* sprites */ | |
| 309 | ROM_LOAD( "507-j05.4e", 0x04000, 0x4000, CRC(27d4f6f4) SHA1(c42c064dbd7c5cf0b1d99651367e0bee1728a5b0) ) | |
| 310 | ROM_LOAD( "507-j06.5e", 0x08000, 0x4000, CRC(717485cb) SHA1(22609489186dcb3d7cd49b7ddfdc6f04d0739354) ) | |
| 311 | ROM_LOAD( "507-j07.3f", 0x0c000, 0x4000, CRC(e933086f) SHA1(c0fd1e8d23c0f7e14c0b75f629448034420cf8ef) ) | |
| 325 | ROM_LOAD( "507j04.3e", 0x0000, 0x4000, CRC(0d269524) SHA1(a10ddb405e884bfec521a3c7a29d22f63e535b59) ) /* sprites */ | |
| 326 | ROM_LOAD( "507j05.4e", 0x4000, 0x4000, CRC(27d4f6f4) SHA1(c42c064dbd7c5cf0b1d99651367e0bee1728a5b0) ) | |
| 327 | ROM_LOAD( "507j06.5e", 0x8000, 0x4000, CRC(717485cb) SHA1(22609489186dcb3d7cd49b7ddfdc6f04d0739354) ) | |
| 328 | ROM_LOAD( "507j07.3f", 0xc000, 0x4000, CRC(e933086f) SHA1(c0fd1e8d23c0f7e14c0b75f629448034420cf8ef) ) | |
| 312 | 329 | |
| 313 | 330 | ROM_REGION( 0x0240, "proms", 0 ) |
| 314 | ROM_LOAD( "507j10.1f", 0x0000, 0x0020, CRC(f1909605) SHA1(91eaa865375b3bc052897732b64b1ff7df3f78f6) ) /* red & green */ | |
| 315 | ROM_LOAD( "507j11.2f", 0x0020, 0x0020, CRC(f70bb122) SHA1(bf77990260e8346faa3d3481718cbe46a4a27150) ) /* blue */ | |
| 316 | ROM_LOAD( "507j13.7f", 0x0040, 0x0100, CRC(d4fe5c97) SHA1(972e9dab6c53722545dd3a43e3ada7921e88708b) ) /* char lookup */ | |
| 317 | ROM_LOAD( "507j12.6f", 0x0140, 0x0100, CRC(0266c7db) SHA1(a8f21e86e6d974c9bfd92a147689d0e7316d66e2) ) /* sprites lookup */ | |
| 331 | ROM_LOAD( "507j10.1f", 0x0000, 0x0020, CRC(f1909605) SHA1(91eaa865375b3bc052897732b64b1ff7df3f78f6) ) /* red & green */ | |
| 332 | ROM_LOAD( "507j11.2f", 0x0020, 0x0020, CRC(f70bb122) SHA1(bf77990260e8346faa3d3481718cbe46a4a27150) ) /* blue */ | |
| 333 | ROM_LOAD( "507j13.7f", 0x0040, 0x0100, CRC(d4fe5c97) SHA1(972e9dab6c53722545dd3a43e3ada7921e88708b) ) /* char lookup */ | |
| 334 | ROM_LOAD( "507j12.6f", 0x0140, 0x0100, CRC(0266c7db) SHA1(a8f21e86e6d974c9bfd92a147689d0e7316d66e2) ) /* sprites lookup */ | |
| 318 | 335 | |
| 319 | 336 | ROM_REGION( 0x4000, "vlm", 0 ) /* speech rom */ |
| 320 | ROM_LOAD( "507 | |
| 337 | ROM_LOAD( "507 | |
| 321 | 338 | ROM_END |
| 322 | 339 | |
| 323 | 340 | /* |
| r3232 | r3233 | |
|---|---|---|
| 184 | 184 | } |
| 185 | 185 | #endif |
| 186 | 186 | |
| 187 | static | |
| 187 | static UINT8 variable_data | |
| 188 | 188 | static READ8_HANDLER( some_changing_input ) |
| 189 | 189 | { |
| 190 | variable_data = | |
| 190 | variable_data += | |
| 191 | 191 | return variable_data; |
| 192 | 192 | } |
| 193 | 193 | |
| r3232 | r3233 | |
| 333 | 333 | NULL |
| 334 | 334 | }; |
| 335 | 335 | |
| 336 | static MACHINE_RESET( tankbust ) | |
| 337 | { | |
| 338 | variable_data = 0x11; | |
| 339 | } | |
| 340 | ||
| 341 | ||
| 336 | 342 | static MACHINE_DRIVER_START( tankbust ) |
| 337 | 343 | |
| 338 | 344 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 346 | 352 | |
| 347 | 353 | MDRV_INTERLEAVE(100) |
| 348 | 354 | |
| 349 | ||
| 355 | | |
| 350 | 356 | |
| 351 | 357 | /* video hardware */ |
| 352 | 358 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
|---|---|---|
| 1396 | 1396 | |
| 1397 | 1397 | static WRITE32_HANDLER( analog_port_w ) |
| 1398 | 1398 | { |
| 1399 | static const char *portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1399 | static const char *const portnames[] = { "AN0", "AN1", "AN2", "AN3", "AN4", "AN5", "AN6", "AN7" }; | |
| 1400 | 1400 | |
| 1401 | 1401 | if (data < 8 || data > 15) |
| 1402 | 1402 | logerror("%08X:Unexpected analog port select = %08X\n", activecpu_get_pc(), data); |
| r3232 | r3233 | |
|---|---|---|
| 30 | 30 | VIDEO_START( mnchmobl ); |
| 31 | 31 | WRITE8_HANDLER( mnchmobl_palette_bank_w ); |
| 32 | 32 | WRITE8_HANDLER( mnchmobl_flipscreen_w ); |
| 33 | READ8_HANDLER( mnchmobl_sprite_xpos_r ); | |
| 34 | WRITE8_HANDLER( mnchmobl_sprite_xpos_w ); | |
| 35 | READ8_HANDLER( mnchmobl_sprite_attr_r ); | |
| 36 | WRITE8_HANDLER( mnchmobl_sprite_attr_w ); | |
| 37 | READ8_HANDLER( mnchmobl_sprite_tile_r ); | |
| 38 | WRITE8_HANDLER( mnchmobl_sprite_tile_w ); | |
| 39 | 33 | VIDEO_UPDATE( mnchmobl ); |
| 40 | 34 | |
| 41 | 35 | |
| r3232 | r3233 | |
| 67 | 61 | cpunum_set_input_line(machine, 1, INPUT_LINE_NMI, CLEAR_LINE); |
| 68 | 62 | } |
| 69 | 63 | |
| 70 | static ADDRESS_MAP_START( readmem, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 71 | AM_RANGE(0x0000, 0x3fff) AM_READ(SMH_ROM) | |
| 72 | AM_RANGE(0x8000, 0x83ff) AM_READ(SMH_RAM) /* working RAM */ | |
| 73 | AM_RANGE(0xa000, 0xa3ff) AM_READ(SMH_RAM) | |
| 74 | AM_RANGE(0xa400, 0xa7ff) AM_READ(mnchmobl_sprite_xpos_r) /* mirrored */ | |
| 75 | AM_RANGE(0xa800, 0xabff) AM_READ(SMH_RAM) | |
| 76 | AM_RANGE(0xac00, 0xafff) AM_READ(mnchmobl_sprite_tile_r) /* mirrored */ | |
| 77 | AM_RANGE(0xb000, 0xb3ff) AM_READ(SMH_RAM) | |
| 78 | AM_RANGE(0xb400, 0xb7ff) AM_READ(mnchmobl_sprite_attr_r) /* mirrored */ | |
| 79 | AM_RANGE(0xb800, 0xb8ff) AM_MIRROR(0x0100) AM_READ(SMH_RAM) | |
| 80 | AM_RANGE(0xbe02, 0xbe02) AM_READ_PORT("DSW1") | |
| 81 | AM_RANGE(0xbe03, 0xbe03) AM_READ_PORT("DSW2") | |
| 82 | AM_RANGE(0xbf01, 0xbf01) AM_READ_PORT("SYSTEM") | |
| 83 | AM_RANGE(0xbf02, 0xbf02) AM_READ_PORT("P1") | |
| 84 | AM_RANGE(0xbf03, 0xbf03) AM_READ_PORT("P2") | |
| 85 | ADDRESS_MAP_END | |
| 86 | 64 | |
| 87 | static ADDRESS_MAP_START( writemem, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 88 | AM_RANGE(0x0000, 0x3fff) AM_WRITE(SMH_ROM) | |
| 89 | AM_RANGE(0x8000, 0x83ff) AM_WRITE(SMH_RAM) /* working RAM */ | |
| 90 | AM_RANGE(0xa000, 0xa3ff) AM_WRITE(SMH_RAM) AM_BASE(&mnchmobl_sprite_xpos) | |
| 91 | AM_RANGE(0xa400, 0xa7ff) AM_WRITE(mnchmobl_sprite_xpos_w) | |
| 92 | AM_RANGE(0xa800, 0xabff) AM_WRITE(SMH_RAM) AM_BASE(&mnchmobl_sprite_tile) | |
| 93 | AM_RANGE(0xac00, 0xafff) AM_WRITE(mnchmobl_sprite_tile_w) | |
| 94 | AM_RANGE(0xb000, 0xb3ff) AM_WRITE(SMH_RAM) AM_BASE(&mnchmobl_sprite_attr) | |
| 95 | AM_RANGE(0xb400, 0xb7ff) AM_WRITE(mnchmobl_sprite_attr_w) | |
| 96 | AM_RANGE(0xb800, 0xb8ff) AM_MIRROR(0x0100) AM_WRITE(SMH_RAM) AM_BASE(&videoram) | |
| 97 | AM_RANGE(0xba00, 0xbbff) AM_WRITE(SMH_RAM) | |
| 98 | AM_RANGE(0xbc00, 0xbc7f) AM_WRITE(SMH_RAM) AM_BASE(&mnchmobl_status_vram) | |
| 65 | static ADDRESS_MAP_START( munchmo_map, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 66 | AM_RANGE(0x0000, 0x3fff) AM_ROM | |
| 67 | AM_RANGE(0x8000, 0x83ff) AM_RAM | |
| 68 | AM_RANGE(0xa000, 0xa3ff) AM_MIRROR(0x0400) AM_RAM AM_BASE(&mnchmobl_sprite_xpos) | |
| 69 | AM_RANGE(0xa800, 0xabff) AM_MIRROR(0x0400) AM_RAM AM_BASE(&mnchmobl_sprite_tile) | |
| 70 | AM_RANGE(0xb000, 0xb3ff) AM_MIRROR(0x0400) AM_RAM AM_BASE(&mnchmobl_sprite_attr) | |
| 71 | AM_RANGE(0xb800, 0xb8ff) AM_MIRROR(0x0100) AM_RAM AM_BASE(&videoram) | |
| 72 | AM_RANGE(0xbaba, 0xbaba) AM_WRITENOP /* ? */ | |
| 73 | AM_RANGE(0xbc00, 0xbc7f) AM_RAM AM_BASE(&mnchmobl_status_vram) | |
| 99 | 74 | AM_RANGE(0xbe00, 0xbe00) AM_WRITE(mnchmobl_soundlatch_w) |
| 100 | 75 | AM_RANGE(0xbe01, 0xbe01) AM_WRITE(mnchmobl_palette_bank_w) |
| 101 | AM_RANGE(0xbe11, 0xbe11) AM_WRITE(SMH_RAM) /* ? */ | |
| 102 | AM_RANGE(0xbe21, 0xbe21) AM_WRITE(SMH_RAM) /* ? */ | |
| 103 | AM_RANGE(0xbe31, 0xbe31) AM_WRITE(SMH_RAM) /* ? */ | |
| 76 | AM_RANGE(0xbe02, 0xbe02) AM_READ_PORT("DSW1") | |
| 77 | AM_RANGE(0xbe03, 0xbe03) AM_READ_PORT("DSW2") | |
| 78 | AM_RANGE(0xbe11, 0xbe11) AM_WRITENOP /* ? */ | |
| 79 | AM_RANGE(0xbe21, 0xbe21) AM_WRITENOP /* ? */ | |
| 80 | AM_RANGE(0xbe31, 0xbe31) AM_WRITENOP /* ? */ | |
| 104 | 81 | AM_RANGE(0xbe41, 0xbe41) AM_WRITE(mnchmobl_flipscreen_w) |
| 105 | 82 | AM_RANGE(0xbe61, 0xbe61) AM_WRITE(mnchmobl_nmi_enable_w) /* ENI 1-10C */ |
| 106 | 83 | AM_RANGE(0xbf00, 0xbf07) AM_WRITE(SMH_RAM) AM_BASE(&mnchmobl_vreg) /* MY0 1-8C */ |
| 84 | AM_RANGE(0xbf01, 0xbf01) AM_READ_PORT("SYSTEM") | |
| 85 | AM_RANGE(0xbf02, 0xbf02) AM_READ_PORT("P1") | |
| 86 | AM_RANGE(0xbf03, 0xbf03) AM_READ_PORT("P2") | |
| 107 | 87 | ADDRESS_MAP_END |
| 108 | 88 | |
| 109 | static ADDRESS_MAP_START( readmem_sound, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 110 | AM_RANGE(0x0000, 0x1fff) AM_READ(SMH_ROM) | |
| 89 | static ADDRESS_MAP_START( sound_map, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 90 | AM_RANGE(0x0000, 0x1fff) AM_ROM | |
| 111 | 91 | AM_RANGE(0x2000, 0x2000) AM_READ(soundlatch_r) |
| 112 | AM_RANGE(0xe000, 0xe7ff) AM_READ(SMH_RAM) | |
| 113 | ADDRESS_MAP_END | |
| 114 | ||
| 115 | static ADDRESS_MAP_START( writemem_sound, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 116 | AM_RANGE(0x0000, 0x1fff) AM_WRITE(SMH_ROM) | |
| 117 | 92 | AM_RANGE(0x4000, 0x4000) AM_WRITE(ay8910_write_port_0_w) |
| 118 | 93 | AM_RANGE(0x5000, 0x5000) AM_WRITE(ay8910_control_port_0_w) |
| 119 | 94 | AM_RANGE(0x6000, 0x6000) AM_WRITE(ay8910_write_port_1_w) |
| 120 | 95 | AM_RANGE(0x7000, 0x7000) AM_WRITE(ay8910_control_port_1_w) |
| 121 | AM_RANGE(0x8000, 0x8000) AM_WRITE(SMH_NOP) /* ? */ | |
| 122 | AM_RANGE(0xa000, 0xa000) AM_WRITE(SMH_NOP) /* ? */ | |
| 96 | AM_RANGE(0x8000, 0x8000) AM_WRITENOP /* ? */ | |
| 97 | AM_RANGE(0xa000, 0xa000) AM_WRITENOP /* ? */ | |
| 123 | 98 | AM_RANGE(0xc000, 0xc000) AM_WRITE(sound_nmi_ack_w) |
| 124 | AM_RANGE(0xe000, 0xe7ff) AM_ | |
| 99 | AM_RANGE(0xe000, 0xe7ff) AM_ | |
| 125 | 100 | ADDRESS_MAP_END |
| 126 | 101 | |
| 102 | ||
| 127 | 103 | static INPUT_PORTS_START( mnchmobl ) |
| 128 | 104 | PORT_START("SYSTEM") |
| 129 | 105 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 ) |
| r3232 | r3233 | |
| 282 | 258 | |
| 283 | 259 | /* basic machine hardware */ |
| 284 | 260 | MDRV_CPU_ADD("main", Z80, 3750000) /* ? */ |
| 285 | MDRV_CPU_PROGRAM_MAP( | |
| 261 | MDRV_CPU_PROGRAM_MAP( | |
| 286 | 262 | MDRV_CPU_VBLANK_INT_HACK(mnchmobl_interrupt,2) |
| 287 | 263 | |
| 288 | 264 | MDRV_CPU_ADD("audio", Z80, 3750000) /* ? */ |
| 289 | MDRV_CPU_PROGRAM_MAP( | |
| 265 | MDRV_CPU_PROGRAM_MAP( | |
| 290 | 266 | MDRV_CPU_VBLANK_INT("main", nmi_line_assert) |
| 291 | 267 | |
| 292 | 268 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 861 | 861 | MDRV_SOUND_CONFIG(sasuke_samples_interface) |
| 862 | 862 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.12) |
| 863 | 863 | |
| 864 | MDRV_SOUND_ADD(" | |
| 864 | MDRV_SOUND_ADD("sn76477.1", SN76477, 0) | |
| 865 | 865 | MDRV_SOUND_CONFIG(sasuke_sn76477_intf_1) |
| 866 | 866 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 867 | 867 | |
| 868 | MDRV_SOUND_ADD(" | |
| 868 | MDRV_SOUND_ADD("sn76477.2", SN76477, 0) | |
| 869 | 869 | MDRV_SOUND_CONFIG(sasuke_sn76477_intf_2) |
| 870 | 870 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 871 | 871 | |
| 872 | MDRV_SOUND_ADD(" | |
| 872 | MDRV_SOUND_ADD("sn76477.3", SN76477, 0) | |
| 873 | 873 | MDRV_SOUND_CONFIG(sasuke_sn76477_intf_3) |
| 874 | 874 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 875 | 875 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 890 | 890 | MDRV_SOUND_CONFIG(vanguard_samples_interface) |
| 891 | 891 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) |
| 892 | 892 | |
| 893 | MDRV_SOUND_REPLACE(" | |
| 893 | MDRV_SOUND_REPLACE("sn76477.1", SN76477, 0) | |
| 894 | 894 | MDRV_SOUND_CONFIG(satansat_sn76477_intf) |
| 895 | 895 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 896 | 896 | |
| 897 | MDRV_SOUND_REMOVE("SN76477.2") | |
| 898 | MDRV_SOUND_REMOVE("SN76477.3") | |
| 897 | MDRV_SOUND_REMOVE("sn76477.2") | |
| 898 | MDRV_SOUND_REMOVE("sn76477.3") | |
| 899 | 899 | MACHINE_DRIVER_END |
| 900 | 900 | |
| 901 | 901 | static MACHINE_DRIVER_START( vanguard ) |
| r3232 | r3233 | |
| 936 | 936 | MDRV_SOUND_CONFIG(vanguard_samples_interface) |
| 937 | 937 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) |
| 938 | 938 | |
| 939 | MDRV_SOUND_ADD(" | |
| 939 | MDRV_SOUND_ADD("sn76477.1", SN76477, 0) | |
| 940 | 940 | MDRV_SOUND_CONFIG(vanguard_sn76477_intf_1) |
| 941 | 941 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 942 | 942 | |
| 943 | MDRV_SOUND_ADD(" | |
| 943 | MDRV_SOUND_ADD("sn76477.2", SN76477, 0) | |
| 944 | 944 | MDRV_SOUND_CONFIG(vanguard_sn76477_intf_2) |
| 945 | 945 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) |
| 946 | 946 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 956 | 956 | MDRV_SOUND_CONFIG(fantasy_samples_interface) |
| 957 | 957 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.5) |
| 958 | 958 | |
| 959 | MDRV_SOUND_REPLACE(" | |
| 959 | MDRV_SOUND_REPLACE("sn76477.1", SN76477, 0) | |
| 960 | 960 | MDRV_SOUND_CONFIG(fantasy_sn76477_intf) |
| 961 | 961 | MDRV_SOUND_ROUTE_EX(0, "discrete", 1.0, 0) |
| 962 | 962 | |
| r3232 | r3233 | |
| 964 | 964 | MDRV_SOUND_CONFIG_DISCRETE(fantasy) |
| 965 | 965 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.5) |
| 966 | 966 | |
| 967 | MDRV_SOUND_REMOVE(" | |
| 967 | MDRV_SOUND_REMOVE("sn76477.2") | |
| 968 | 968 | MACHINE_DRIVER_END |
| 969 | 969 | |
| 970 | 970 | static MACHINE_DRIVER_START( nibbler ) |
| r3232 | r3233 | |
|---|---|---|
| 509 | 509 | INLINE int read_trackball(running_machine *machine, int idx, int switch_port) |
| 510 | 510 | { |
| 511 | 511 | UINT8 newpos; |
| 512 | static const char *portnames[] = { "IN0", "IN1", "IN2" }; | |
| 513 | static const char *tracknames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 512 | static const char *const portnames[] = { "IN0", "IN1", "IN2" }; | |
| 513 | static const char *const tracknames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 514 | 514 | |
| 515 | 515 | /* adjust idx if we're cocktail flipped */ |
| 516 | 516 | if (centiped_flipscreen) |
| r3232 | r3233 | |
| 585 | 585 | |
| 586 | 586 | static READ8_HANDLER( mazeinv_input_r ) |
| 587 | 587 | { |
| 588 | static const char *sticknames[] = { "STICK0", "STICK1", "STICK2", "STICK3" }; | |
| 588 | static const char *const sticknames[] = { "STICK0", "STICK1", "STICK2", "STICK3" }; | |
| 589 | 589 | |
| 590 | 590 | return input_port_read(machine, sticknames[control_select]); |
| 591 | 591 | } |
| r3232 | r3233 | |
| 1589 | 1589 | MDRV_NVRAM_HANDLER(atari_vg) |
| 1590 | 1590 | |
| 1591 | 1591 | /* timer */ |
| 1592 | MDRV_TIMER_ADD_SCANLINE("32 | |
| 1592 | MDRV_TIMER_ADD_SCANLINE("32v", generate_interrupt, "main", 0, 16) | |
| 1593 | 1593 | |
| 1594 | 1594 | /* video hardware */ |
| 1595 | 1595 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
|---|---|---|
| 1 | 1 | /*************************************************************************** |
| 2 | 2 | |
| 3 | Atari System 1 hardware | |
| 3 | Atari System 1 hardware (available in TTL or LSI version) | |
| 4 | 4 | |
| 5 | 5 | driver by Aaron Giles |
| 6 | 6 | |
| 7 | 7 | Games supported: |
| 8 | * Marble Madness (1984) [ | |
| 8 | * Marble Madness (1984) [5 sets, available in either a TTL or LSI version] | |
| 9 | 9 | * Peter Packrat (1984) |
| 10 | 10 | * Indiana Jones & the Temple of Doom (1985) [6 sets] |
| 11 | 11 | * Road Runner (1985) [3 sets] |
| r3232 | r3233 | |
| 198 | 198 | static READ16_HANDLER( joystick_r ) |
| 199 | 199 | { |
| 200 | 200 | int newval = 0xff; |
| 201 | static const char *portnames[] = { "IN0", "IN1" }; | |
| 201 | static const char *const portnames[] = { "IN0", "IN1" }; | |
| 202 | 202 | |
| 203 | 203 | /* digital joystick type */ |
| 204 | 204 | if (joystick_type == 1) |
| r3232 | r3233 | |
| 660 | 660 | |
| 661 | 661 | |
| 662 | 662 | static GFXDECODE_START( atarisy1 ) |
| 663 | GFXDECODE_ENTRY( " | |
| 663 | GFXDECODE_ENTRY( "alpha", 0x00000, anlayout, 0, 64 ) | |
| 664 | 664 | GFXDECODE_END |
| 665 | 665 | |
| 666 | 666 | |
| r3232 | r3233 | |
| 736 | 736 | * |
| 737 | 737 | *************************************/ |
| 738 | 738 | |
| 739 | #define ROM_LOAD16_BYTE_BIOS(bios,name,offset,length,hash) \ | |
| 740 | ROMX_LOAD(name, offset, length, hash, ROM_BIOS(bios+1) | ROM_SKIP(1)) /* Note '+1' */ | |
| 741 | ||
| 742 | #define ROM_LOAD_BIOS(bios,name,offset,length,hash) \ | |
| 743 | ROMX_LOAD(name, offset, length, hash, ROM_BIOS(bios+1)) /* Note '+1' */ | |
| 744 | ||
| 745 | #define MOTHERBOARD_BIOS \ | |
| 746 | ROM_SYSTEM_BIOS( 0, "ttl", "TTL Motherboard (TM277 and SP277 manuals)" ) \ | |
| 747 | ROM_LOAD16_BYTE_BIOS(0, "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) \ | |
| 748 | ROM_LOAD16_BYTE_BIOS(0, "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) \ | |
| 749 | ROM_SYSTEM_BIOS( 1, "lsi", "LSI Motherboard (TM286 and SP286 manuals)" ) \ | |
| 750 | ROM_LOAD16_BYTE_BIOS(1, "136032.114", 0x00000, 0x04000, CRC(195c54ad) SHA1(d7cda3cd3db4c6f77074ca05e96ae11b62e048b7) ) /* Located at J11 */ \ | |
| 751 | ROM_LOAD16_BYTE_BIOS(1, "136032.115", 0x00001, 0x04000, CRC(7275b4dc) SHA1(0896ab37ea832a1335046353612c1b4c86d8d040) ) /* Located at J10 */ | |
| 752 | ||
| 753 | #define MOTHERBOARD_ALPHA \ | |
| 754 | ROM_LOAD_BIOS(0, "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) \ | |
| 755 | ROM_LOAD_BIOS(1, "136028.107", 0x00000, 0x02000, CRC(315e4bea) SHA1(a00ea23fbdbf075f8f3f184275be83387e8ac82b) ) \ | |
| 756 | ||
| 757 | ||
| 758 | ROM_START( atarisy1 ) | |
| 759 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ | |
| 760 | MOTHERBOARD_BIOS | |
| 761 | ||
| 762 | ROM_REGION( 0x10000, "audio", ROMREGION_ERASE00 ) /* 64k for 6502 code */ | |
| 763 | ||
| 764 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 765 | MOTHERBOARD_ALPHA | |
| 766 | ||
| 767 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 768 | ||
| 769 | ROM_REGION( 0x400, "proms", ROMREGION_ERASE00 ) /* graphics mapping PROMs */ | |
| 770 | ROM_END | |
| 771 | ||
| 772 | ||
| 739 | 773 | ROM_START( marble ) |
| 740 | 774 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 741 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 742 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 775 | MOTHERBOARD_BIOS | |
| 743 | 776 | ROM_LOAD16_BYTE( "136033.623", 0x10000, 0x04000, CRC(284ed2e9) SHA1(a24d2fd587dffcc8536ef28fcbcf5c964a6b67a9) ) |
| 744 | 777 | ROM_LOAD16_BYTE( "136033.624", 0x10001, 0x04000, CRC(d541b021) SHA1(978b1565da746f7389eaf7646604990fb28d47ed) ) |
| 745 | 778 | ROM_LOAD16_BYTE( "136033.625", 0x18000, 0x04000, CRC(563755c7) SHA1(a444b72ff4cdecee3b9dd7e636d658c31ecc186c) ) |
| r3232 | r3233 | |
| 755 | 788 | ROM_LOAD( "136033.421", 0x8000, 0x4000, CRC(78153dc3) SHA1(d4e68226b87df8834dc3d6daa9d683f17896c32e) ) |
| 756 | 789 | ROM_LOAD( "136033.422", 0xc000, 0x4000, CRC(2e66300e) SHA1(49acb9443c5d2c1016cde7f489deab2575dd82ca) ) |
| 757 | 790 | |
| 758 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 759 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 791 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 792 | MOTHERBOARD_ALPHA | |
| 760 | 793 | |
| 761 | ROM_REGION( 0x100000, " | |
| 794 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 762 | 795 | ROM_LOAD( "136033.137", 0x00000, 0x04000, CRC(7a45f5c1) SHA1(b826a178660ff2e278558e4779586737751dca5e) ) /* bank 1, plane 0 */ |
| 763 | 796 | ROM_LOAD( "136033.138", 0x04000, 0x04000, CRC(7e954a88) SHA1(238a913529781f424a6f49c3fba1524684d0cbcf) ) |
| 764 | 797 | ROM_LOAD( "136033.139", 0x10000, 0x04000, CRC(1eb1bb5f) SHA1(987a8289fd4be06b6899bb8c620ddfa4c4b966b0) ) /* bank 1, plane 1 */ |
| r3232 | r3233 | |
| 782 | 815 | |
| 783 | 816 | ROM_START( marble2 ) |
| 784 | 817 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 785 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 786 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 818 | MOTHERBOARD_BIOS | |
| 787 | 819 | ROM_LOAD16_BYTE( "136033.401", 0x10000, 0x08000, CRC(ecfc25a2) SHA1(45d98bea8d6bed5ecdcde1049c3a3f6e0fa6ee4c) ) |
| 788 | 820 | ROM_LOAD16_BYTE( "136033.402", 0x10001, 0x08000, CRC(7ce9bf53) SHA1(0a5761d4856cd055e8a58b36276945e06c01d08d) ) |
| 789 | 821 | ROM_LOAD16_BYTE( "136033.403", 0x20000, 0x08000, CRC(dafee7a2) SHA1(6e4aa9721b5fd4385422c146a84a5e271124abcb) ) |
| r3232 | r3233 | |
| 795 | 827 | ROM_LOAD( "136033.421", 0x8000, 0x4000, CRC(78153dc3) SHA1(d4e68226b87df8834dc3d6daa9d683f17896c32e) ) |
| 796 | 828 | ROM_LOAD( "136033.422", 0xc000, 0x4000, CRC(2e66300e) SHA1(49acb9443c5d2c1016cde7f489deab2575dd82ca) ) |
| 797 | 829 | |
| 798 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 799 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 830 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 831 | MOTHERBOARD_ALPHA | |
| 800 | 832 | |
| 801 | ROM_REGION( 0x100000, " | |
| 833 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 802 | 834 | ROM_LOAD( "136033.137", 0x00000, 0x04000, CRC(7a45f5c1) SHA1(b826a178660ff2e278558e4779586737751dca5e) ) /* bank 1, plane 0 */ |
| 803 | 835 | ROM_LOAD( "136033.138", 0x04000, 0x04000, CRC(7e954a88) SHA1(238a913529781f424a6f49c3fba1524684d0cbcf) ) |
| 804 | 836 | ROM_LOAD( "136033.139", 0x10000, 0x04000, CRC(1eb1bb5f) SHA1(987a8289fd4be06b6899bb8c620ddfa4c4b966b0) ) /* bank 1, plane 1 */ |
| r3232 | r3233 | |
| 822 | 854 | |
| 823 | 855 | ROM_START( marble3 ) |
| 824 | 856 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 825 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 826 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 857 | MOTHERBOARD_BIOS | |
| 827 | 858 | ROM_LOAD16_BYTE( "136033.201", 0x10000, 0x08000, CRC(9395804d) SHA1(7cca2cc85a9678199c7a60c0976f3e0362f8538f) ) |
| 828 | 859 | ROM_LOAD16_BYTE( "136033.202", 0x10001, 0x08000, CRC(edd313f5) SHA1(f3ec6f5812287e187026446fe286f257b54c426e) ) |
| 829 | 860 | ROM_LOAD16_BYTE( "136033.403", 0x20000, 0x08000, CRC(dafee7a2) SHA1(6e4aa9721b5fd4385422c146a84a5e271124abcb) ) |
| r3232 | r3233 | |
| 835 | 866 | ROM_LOAD( "136033.121", 0x8000, 0x4000, CRC(73fe2b46) SHA1(09fceb60c831972f544c92a84c6d0cbc2481b9f5) ) |
| 836 | 867 | ROM_LOAD( "136033.122", 0xc000, 0x4000, CRC(03bf65c3) SHA1(4f4a4e4b5bd202da2d18c062f585a842082f08db) ) |
| 837 | 868 | |
| 838 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 839 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 869 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 870 | MOTHERBOARD_ALPHA | |
| 840 | 871 | |
| 841 | ROM_REGION( 0x100000, " | |
| 872 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 842 | 873 | ROM_LOAD( "136033.137", 0x00000, 0x04000, CRC(7a45f5c1) SHA1(b826a178660ff2e278558e4779586737751dca5e) ) /* bank 1, plane 0 */ |
| 843 | 874 | ROM_LOAD( "136033.138", 0x04000, 0x04000, CRC(7e954a88) SHA1(238a913529781f424a6f49c3fba1524684d0cbcf) ) |
| 844 | 875 | ROM_LOAD( "136033.139", 0x10000, 0x04000, CRC(1eb1bb5f) SHA1(987a8289fd4be06b6899bb8c620ddfa4c4b966b0) ) /* bank 1, plane 1 */ |
| r3232 | r3233 | |
| 862 | 893 | |
| 863 | 894 | ROM_START( marble4 ) |
| 864 | 895 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 865 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 866 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 896 | MOTHERBOARD_BIOS | |
| 867 | 897 | ROM_LOAD16_BYTE( "136033.323", 0x10000, 0x04000, CRC(4dc2987a) SHA1(abe155f773dfa623aee6c3952941426adb4c8c9c) ) |
| 868 | 898 | ROM_LOAD16_BYTE( "136033.324", 0x10001, 0x04000, CRC(e22e6e11) SHA1(aedb18f25aad846b82690c70b917e97cdcfbd09e) ) |
| 869 | 899 | ROM_LOAD16_BYTE( "136033.225", 0x18000, 0x04000, CRC(743f6c5c) SHA1(b69b7dc9923f514b8de207895bbe0c2038dc519d) ) |
| r3232 | r3233 | |
| 879 | 909 | ROM_LOAD( "136033.257", 0x8000, 0x4000, CRC(2e2e0df8) SHA1(e76f7297a3e78ebbc00e3a4c468149f9f7124b16) ) |
| 880 | 910 | ROM_LOAD( "136033.258", 0xc000, 0x4000, CRC(1b9655cd) SHA1(deb8728ee9620718e449f1e55a6fe115256c00c9) ) |
| 881 | 911 | |
| 882 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 883 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 912 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 913 | MOTHERBOARD_ALPHA | |
| 884 | 914 | |
| 885 | ROM_REGION( 0x100000, " | |
| 915 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 886 | 916 | ROM_LOAD( "136033.137", 0x00000, 0x04000, CRC(7a45f5c1) SHA1(b826a178660ff2e278558e4779586737751dca5e) ) /* bank 1, plane 0 */ |
| 887 | 917 | ROM_LOAD( "136033.138", 0x04000, 0x04000, CRC(7e954a88) SHA1(238a913529781f424a6f49c3fba1524684d0cbcf) ) |
| 888 | 918 | ROM_LOAD( "136033.139", 0x10000, 0x04000, CRC(1eb1bb5f) SHA1(987a8289fd4be06b6899bb8c620ddfa4c4b966b0) ) /* bank 1, plane 1 */ |
| r3232 | r3233 | |
| 904 | 934 | ROM_END |
| 905 | 935 | |
| 906 | 936 | |
| 937 | ROM_START( marble5 ) /* LSI Cartridge */ | |
| 938 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ | |
| 939 | MOTHERBOARD_BIOS | |
| 940 | ROM_LOAD16_BYTE( "136033.201", 0x10000, 0x08000, CRC(9395804d) SHA1(7cca2cc85a9678199c7a60c0976f3e0362f8538f) ) /* Located at B10 */ | |
| 941 | ROM_LOAD16_BYTE( "136033.202", 0x10001, 0x08000, CRC(edd313f5) SHA1(f3ec6f5812287e187026446fe286f257b54c426e) ) /* Located at A10 */ | |
| 942 | ROM_LOAD16_BYTE( "136033.203", 0x20000, 0x08000, CRC(dafee7a2) SHA1(6e4aa9721b5fd4385422c146a84a5e271124abcb) ) /* Located at B12 */ | |
| 943 | ROM_LOAD16_BYTE( "136033.204", 0x20001, 0x08000, CRC(4d621731) SHA1(619d74abe750aac61c3425bcb584ffdafdfc809a) ) /* Located at A12 */ | |
| 944 | ROM_LOAD16_BYTE( "136033.107", 0x80000, 0x04000, CRC(f3b8745b) SHA1(4754eac5e6d8547b3ee00f3f48eaa560eb403862) ) /* Located at B16 */ | |
| 945 | ROM_LOAD16_BYTE( "136033.108", 0x80001, 0x04000, CRC(e51eecaa) SHA1(37d51a9e9cb33d1156d02a312ac8e202a18d7c20) ) /* Located at A16 */ | |
| 946 | ||
| 947 | ROM_REGION( 0x10000, "audio", 0 ) /* 64k for 6502 code */ | |
| 948 | ROM_LOAD( "136033.121", 0x08000, 0x04000, CRC(73fe2b46) SHA1(09fceb60c831972f544c92a84c6d0cbc2481b9f5) ) /* Located at D14 */ | |
| 949 | ROM_LOAD( "136033.122", 0x0c000, 0x04000, CRC(03bf65c3) SHA1(4f4a4e4b5bd202da2d18c062f585a842082f08db) ) /* Located at D16 */ | |
| 950 | ||
| 951 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 952 | MOTHERBOARD_ALPHA | |
| 953 | ||
| 954 | ROM_REGION( 0x100000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 955 | ROM_LOAD( "136033.109", 0x00000, 0x08000, CRC(467208f4) SHA1(a050991bb684fa51720c0ac33b9bf68a373e8856) ) /* bank 1, plane 0 - located at B1 */ | |
| 956 | ROM_LOAD( "136033.110", 0x10000, 0x08000, CRC(b883ec76) SHA1(ec048e19395fd617f2cd0d3edea728799bdca037) ) /* bank 1, plane 1 - located at B6 */ | |
| 957 | ROM_LOAD( "136033.111", 0x20000, 0x08000, CRC(c208bd5e) SHA1(e75f7d33c66b58e3c72a83d0dc7a6427a57d0de9) ) /* bank 1, plane 2 - located at C1 */ | |
| 958 | ROM_LOAD( "136033.112", 0x30000, 0x08000, CRC(042673d4) SHA1(499c1edf82834d5ff6144ee4349b2349db7a57c2) ) /* bank 1, plane 3 - located at C6 */ | |
| 959 | ROM_LOAD( "136033.113", 0x40000, 0x08000, CRC(b390aef3) SHA1(2cd58071d1c09058af7876c35484c3b571774a06) ) /* bank 1, plane 4 - located at D1 */ | |
| 960 | ROM_LOAD( "136033.115", 0x84000, 0x04000, CRC(b6658f06) SHA1(e719d956f4f9d703a12e2c5520cac0a2f47ea058) ) /* bank 2, plane 0 - located at B2 */ | |
| 961 | ROM_LOAD( "136033.116", 0x94000, 0x04000, CRC(84ee1c80) SHA1(5192c0a2887f46b616d130bdbfffbbd5e394e9a3) ) /* bank 2, plane 1 - located at B7 */ | |
| 962 | ROM_LOAD( "136033.117", 0xa4000, 0x04000, CRC(daa02926) SHA1(33c7a38c66fb4d67a6ee88ef2da2bba091439e0c) ) /* bank 2, plane 2 - located at C7 */ | |
| 963 | ||
| 964 | ROM_REGION( 0x400, "proms", 0 ) /* graphics mapping PROMs */ | |
| 965 | ROM_LOAD( "136033.118", 0x00000, 0x00200, CRC(2101b0ed) SHA1(e4fb8dfa80ed78847c697f9de2bd8540b0c04889) ) /* remap, located at A7 */ | |
| 966 | ROM_LOAD( "136033.159", 0x00200, 0x00200, CRC(19f6e767) SHA1(041f24cc03c9043c31c3294c9565dfda9bdada74) ) /* color, located at A5 */ | |
| 967 | ROM_END | |
| 968 | ||
| 969 | ||
| 907 | 970 | ROM_START( peterpak ) |
| 908 | 971 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 909 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 910 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 972 | MOTHERBOARD_BIOS | |
| 911 | 973 | ROM_LOAD16_BYTE( "136028.142", 0x10000, 0x04000, CRC(4f9fc020) SHA1(7e0d5660ea395ded7e0e4c9122bc41f9bb9a483d) ) |
| 912 | 974 | ROM_LOAD16_BYTE( "136028.143", 0x10001, 0x04000, CRC(9fb257cc) SHA1(5590fc2b4e79a071ae5ba04e23aadb3e35614a73) ) |
| 913 | 975 | ROM_LOAD16_BYTE( "136028.144", 0x18000, 0x04000, CRC(50267619) SHA1(7aec7e4c8b97313d18c8eb55e078157776e29842) ) |
| r3232 | r3233 | |
| 921 | 983 | ROM_LOAD( "136028.101", 0x8000, 0x4000, CRC(ff712aa2) SHA1(07beeb51f41d406782965dddb6fe73fdc49529df) ) |
| 922 | 984 | ROM_LOAD( "136028.102", 0xc000, 0x4000, CRC(89ea21a1) SHA1(a7cb6eceb45d54406d6fc692f50a4e34564d6170) ) |
| 923 | 985 | |
| 924 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 925 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 986 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 987 | MOTHERBOARD_ALPHA | |
| 926 | 988 | |
| 927 | ROM_REGION( 0x180000, " | |
| 989 | ROM_REGION( 0x180000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 928 | 990 | ROM_LOAD( "136028.138", 0x000000, 0x08000, CRC(53eaa018) SHA1(3f9887d4996e6a7c894732e9c9ebe4408fb60192) ) /* bank 1, plane 0 */ |
| 929 | 991 | ROM_LOAD( "136028.139", 0x010000, 0x08000, CRC(354a19cb) SHA1(84a145d0f1624315923d389b4b746db5fbc672df) ) /* bank 1, plane 1 */ |
| 930 | 992 | ROM_LOAD( "136028.140", 0x020000, 0x08000, CRC(8d2c4717) SHA1(d7709d5859b5276d46799ff39a375929a48e34ae) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 948 | 1010 | |
| 949 | 1011 | ROM_START( indytemp ) |
| 950 | 1012 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 951 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 952 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1013 | MOTHERBOARD_BIOS | |
| 953 | 1014 | ROM_LOAD16_BYTE( "136036.432", 0x10000, 0x08000, CRC(d888cdf1) SHA1(c9cbc0d429755611b3749e018d3817d4d7042425) ) |
| 954 | 1015 | ROM_LOAD16_BYTE( "136036.431", 0x10001, 0x08000, CRC(b7ac7431) SHA1(b062258746ca5f9c3f9cf8a6186eb3c370ac3a77) ) |
| 955 | 1016 | ROM_LOAD16_BYTE( "136036.434", 0x20000, 0x08000, CRC(802495fd) SHA1(228f48ef067a758fe0d3bfe0508765a52bb579eb) ) |
| r3232 | r3233 | |
| 964 | 1025 | ROM_LOAD( "136036.154", 0x8000, 0x4000, CRC(cbfc6adb) SHA1(ee132eced924435f1214e2997533e866a3e5364b) ) |
| 965 | 1026 | ROM_LOAD( "136036.155", 0xc000, 0x4000, CRC(4c8233ac) SHA1(3d2bdb71b8f499a21f0b0e1686be7fe6f23efede) ) |
| 966 | 1027 | |
| 967 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 968 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1028 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1029 | MOTHERBOARD_ALPHA | |
| 969 | 1030 | |
| 970 | ROM_REGION( 0x200000, " | |
| 1031 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 971 | 1032 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 972 | 1033 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 973 | 1034 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 996 | 1057 | |
| 997 | 1058 | ROM_START( indytem2 ) |
| 998 | 1059 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 999 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1000 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1060 | MOTHERBOARD_BIOS | |
| 1001 | 1061 | ROM_LOAD16_BYTE( "136036.470", 0x10000, 0x08000, CRC(7fac1dd8) SHA1(043daf709209e76115899a1e301f8fb262b3a749) ) |
| 1002 | 1062 | ROM_LOAD16_BYTE( "136036.471", 0x10001, 0x08000, CRC(e93272fb) SHA1(bb5741419a9d1a54ae16bfd6d2fcf64627e8a5c3) ) |
| 1003 | 1063 | ROM_LOAD16_BYTE( "136036.434", 0x20000, 0x08000, CRC(802495fd) SHA1(228f48ef067a758fe0d3bfe0508765a52bb579eb) ) |
| r3232 | r3233 | |
| 1012 | 1072 | ROM_LOAD( "136036.154", 0x8000, 0x4000, CRC(cbfc6adb) SHA1(ee132eced924435f1214e2997533e866a3e5364b) ) |
| 1013 | 1073 | ROM_LOAD( "136036.155", 0xc000, 0x4000, CRC(4c8233ac) SHA1(3d2bdb71b8f499a21f0b0e1686be7fe6f23efede) ) |
| 1014 | 1074 | |
| 1015 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1016 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1075 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1076 | MOTHERBOARD_ALPHA | |
| 1017 | 1077 | |
| 1018 | ROM_REGION( 0x200000, " | |
| 1078 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1019 | 1079 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 1020 | 1080 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 1021 | 1081 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1044 | 1104 | |
| 1045 | 1105 | ROM_START( indytem3 ) |
| 1046 | 1106 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1047 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1048 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1107 | MOTHERBOARD_BIOS | |
| 1049 | 1108 | ROM_LOAD16_BYTE( "232.10b", 0x10000, 0x08000, CRC(1e80108f) SHA1(663ef81b865c4d13fd73eca4f82ee64a4bdeaad5) ) |
| 1050 | 1109 | ROM_LOAD16_BYTE( "231.10a", 0x10001, 0x08000, CRC(8ae54c0c) SHA1(c7ab4a2e2af8f2336baa8c7b2a80af7c9bfd0435) ) |
| 1051 | 1110 | ROM_LOAD16_BYTE( "234.12b", 0x20000, 0x08000, CRC(86be7e07) SHA1(b6b0d9c6d81d446dab675c71d60f792f6a657c5b) ) |
| r3232 | r3233 | |
| 1060 | 1119 | ROM_LOAD( "136036.154", 0x8000, 0x4000, CRC(cbfc6adb) SHA1(ee132eced924435f1214e2997533e866a3e5364b) ) |
| 1061 | 1120 | ROM_LOAD( "136036.155", 0xc000, 0x4000, CRC(4c8233ac) SHA1(3d2bdb71b8f499a21f0b0e1686be7fe6f23efede) ) |
| 1062 | 1121 | |
| 1063 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1064 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1122 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1123 | MOTHERBOARD_ALPHA | |
| 1065 | 1124 | |
| 1066 | ROM_REGION( 0x200000, " | |
| 1125 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1067 | 1126 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 1068 | 1127 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 1069 | 1128 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1092 | 1151 | |
| 1093 | 1152 | ROM_START( indytem4 ) |
| 1094 | 1153 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1095 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1096 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1154 | MOTHERBOARD_BIOS | |
| 1097 | 1155 | ROM_LOAD16_BYTE( "136036.332", 0x10000, 0x08000, CRC(a5563773) SHA1(52701b53e62aae691f7b9483f5e843d805223a0a) ) |
| 1098 | 1156 | ROM_LOAD16_BYTE( "136036.331", 0x10001, 0x08000, CRC(7d562141) SHA1(a2143ed473e40a5a46679e7751fc37475768885f) ) |
| 1099 | 1157 | ROM_LOAD16_BYTE( "136036.334", 0x20000, 0x08000, CRC(e40828e5) SHA1(a5c50693bddcc394711859bdc36d9ff93d02b82e) ) |
| r3232 | r3233 | |
| 1108 | 1166 | ROM_LOAD( "136036.154", 0x8000, 0x4000, CRC(cbfc6adb) SHA1(ee132eced924435f1214e2997533e866a3e5364b) ) |
| 1109 | 1167 | ROM_LOAD( "136036.155", 0xc000, 0x4000, CRC(4c8233ac) SHA1(3d2bdb71b8f499a21f0b0e1686be7fe6f23efede) ) |
| 1110 | 1168 | |
| 1111 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1112 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1169 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1170 | MOTHERBOARD_ALPHA | |
| 1113 | 1171 | |
| 1114 | ROM_REGION( 0x200000, " | |
| 1172 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1115 | 1173 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 1116 | 1174 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 1117 | 1175 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1140 | 1198 | |
| 1141 | 1199 | ROM_START( indytemc ) |
| 1142 | 1200 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1143 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1144 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1201 | MOTHERBOARD_BIOS | |
| 1145 | 1202 | ROM_LOAD16_BYTE( "136036.632", 0x10000, 0x08000, BAD_DUMP CRC(8af67d9b) SHA1(5777ed2048fe1a58a1cac8276185843396754d38) ) |
| 1146 | 1203 | ROM_LOAD16_BYTE( "136036.631", 0x10001, 0x08000, CRC(9ac96ba8) SHA1(d80adabb4198461b5976577bdd8cc4e650de1c8e) ) |
| 1147 | 1204 | ROM_LOAD16_BYTE( "136036.534", 0x20000, 0x08000, CRC(eae396be) SHA1(6d7a82a2fd43b91c6c1e2c07d33c81487b845bba) ) |
| r3232 | r3233 | |
| 1155 | 1212 | ROM_LOAD( "136036.153", 0x4000, 0x4000, CRC(95294641) SHA1(00f90a0d49d2c77d5288080036f81a74ad31f8bc) ) |
| 1156 | 1213 | ROM_LOAD( "136036.170", 0x8000, 0x8000, BAD_DUMP CRC(8af67d9b) SHA1(5777ed2048fe1a58a1cac8276185843396754d38) ) |
| 1157 | 1214 | |
| 1158 | ROM_REGION( 0x4000, " | |
| 1215 | ROM_REGION( 0x4000, "alpha", ROMREGION_DISPOSE ) | |
| 1159 | 1216 | ROM_LOAD( "136032.120", 0x00000, 0x04000, CRC(90a1950d) SHA1(fba32c255850312175d1e3c03d677ffb57e09e07) ) /* alpha font */ |
| 1160 | 1217 | |
| 1161 | ROM_REGION( 0x200000, " | |
| 1218 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1162 | 1219 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 1163 | 1220 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 1164 | 1221 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1187 | 1244 | |
| 1188 | 1245 | ROM_START( indytemd ) |
| 1189 | 1246 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1190 | ROM_LOAD16_BYTE( "136032.205", 0x00000, 0x04000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1191 | ROM_LOAD16_BYTE( "136032.206", 0x00001, 0x04000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1247 | MOTHERBOARD_BIOS | |
| 1192 | 1248 | ROM_LOAD16_BYTE( "136036.462", 0x10000, 0x08000, CRC(317dc430) SHA1(563f09fb1b096bd40e1a73acb7f11d3809f9f19f) ) |
| 1193 | 1249 | ROM_LOAD16_BYTE( "136036.461", 0x10001, 0x08000, CRC(8c73f974) SHA1(023b55f1d54606f5c51b86b802d417099d775f14) ) |
| 1194 | 1250 | ROM_LOAD16_BYTE( "136036.464", 0x20000, 0x08000, CRC(3fcb199f) SHA1(11a8a17bf0100b5f16e9148669b2ec5bf81b3d62) ) |
| r3232 | r3233 | |
| 1203 | 1259 | ROM_LOAD( "136036.154", 0x8000, 0x4000, CRC(cbfc6adb) SHA1(ee132eced924435f1214e2997533e866a3e5364b) ) |
| 1204 | 1260 | ROM_LOAD( "136036.155", 0xc000, 0x4000, CRC(4c8233ac) SHA1(3d2bdb71b8f499a21f0b0e1686be7fe6f23efede) ) |
| 1205 | 1261 | |
| 1206 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1207 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1262 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1263 | MOTHERBOARD_ALPHA | |
| 1208 | 1264 | |
| 1209 | ROM_REGION( 0x200000, " | |
| 1265 | ROM_REGION( 0x200000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1210 | 1266 | ROM_LOAD( "136036.135", 0x000000, 0x08000, CRC(ffa8749c) SHA1(b0bec9b8364a15606d9f4d11f674dea2ec25279f) ) /* bank 1, plane 0 */ |
| 1211 | 1267 | ROM_LOAD( "136036.139", 0x010000, 0x08000, CRC(b682bfca) SHA1(21625ea29609560b31b28c669b2599cfcdab8ea7) ) /* bank 1, plane 1 */ |
| 1212 | 1268 | ROM_LOAD( "136036.143", 0x020000, 0x08000, CRC(7697da26) SHA1(546b95467ca61fab9ac853635c8972a2dedb6581) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1235 | 1291 | |
| 1236 | 1292 | ROM_START( roadrunn ) |
| 1237 | 1293 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1238 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1239 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1294 | MOTHERBOARD_BIOS | |
| 1240 | 1295 | ROM_LOAD16_BYTE( "136040-228.11c", 0x010000, 0x008000, CRC(b66c629a) SHA1(94dc13f2f151a4109ee50016bcc1392aef0d5a22) ) |
| 1241 | 1296 | ROM_LOAD16_BYTE( "136040-229.11a", 0x010001, 0x008000, CRC(5638959f) SHA1(486bd13ba151558b72bf29de9ecc14944e56435c) ) |
| 1242 | 1297 | ROM_LOAD16_BYTE( "136040-230.13c", 0x020000, 0x008000, CRC(cd7956a3) SHA1(d72aa90b74a77e5fa49cb34515383c8ab054d654) ) |
| r3232 | r3233 | |
| 1254 | 1309 | ROM_LOAD( "136040-143.15e", 0x008000, 0x004000, CRC(62b9878e) SHA1(db6072a7c8600d85fb70dac3d940a200d0cb5d0a) ) |
| 1255 | 1310 | ROM_LOAD( "136040-144.17e", 0x00c000, 0x004000, CRC(6ef1b804) SHA1(176066c6946090c87945213145960754cd315acb) ) |
| 1256 | 1311 | |
| 1257 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1258 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1312 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1313 | MOTHERBOARD_ALPHA | |
| 1259 | 1314 | |
| 1260 | ROM_REGION( 0x300000, " | |
| 1315 | ROM_REGION( 0x300000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1261 | 1316 | ROM_LOAD( "136040-101.4b", 0x000000, 0x008000, CRC(26d9f29c) SHA1(e03a03484ede4ea209040faf64e88f0667a0ab40) ) /* bank 1, plane 0 */ |
| 1262 | 1317 | ROM_LOAD( "136040-107.9b", 0x010000, 0x008000, CRC(8aac0ba4) SHA1(67a6412c77d08eab6745db9dff3e32a1bb768901) ) /* bank 1, plane 1 */ |
| 1263 | 1318 | ROM_LOAD( "136040-113.4f", 0x020000, 0x008000, CRC(48b74c52) SHA1(d8328a9ff715247d841be02b1bb7aa043dcb77e1) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1296 | 1351 | |
| 1297 | 1352 | ROM_START( roadrun2 ) |
| 1298 | 1353 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1299 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1300 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1354 | MOTHERBOARD_BIOS | |
| 1301 | 1355 | ROM_LOAD16_BYTE( "136040-x28.11c", 0x010000, 0x008000, CRC(fbd43085) SHA1(57f2f2f01e235f4525507583887d52b09f6267b4) ) |
| 1302 | 1356 | ROM_LOAD16_BYTE( "136040-x29.11a", 0x010001, 0x008000, CRC(f8d8819b) SHA1(dddb44290e3d2728845639611c3a66c3389c8f69) ) |
| 1303 | 1357 | ROM_LOAD16_BYTE( "136040-x30.13c", 0x020000, 0x008000, CRC(6a273375) SHA1(2e222ad4a4d53ec50f848386fca12f74e98814ed) ) |
| r3232 | r3233 | |
| 1315 | 1369 | ROM_LOAD( "136040-143.15e", 0x008000, 0x004000, CRC(62b9878e) SHA1(db6072a7c8600d85fb70dac3d940a200d0cb5d0a) ) |
| 1316 | 1370 | ROM_LOAD( "136040-144.17e", 0x00c000, 0x004000, CRC(6ef1b804) SHA1(176066c6946090c87945213145960754cd315acb) ) |
| 1317 | 1371 | |
| 1318 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1319 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1372 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1373 | MOTHERBOARD_ALPHA | |
| 1320 | 1374 | |
| 1321 | ROM_REGION( 0x300000, " | |
| 1375 | ROM_REGION( 0x300000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1322 | 1376 | ROM_LOAD( "136040-101.4b", 0x000000, 0x008000, CRC(26d9f29c) SHA1(e03a03484ede4ea209040faf64e88f0667a0ab40) ) /* bank 1, plane 0 */ |
| 1323 | 1377 | ROM_LOAD( "136040-107.9b", 0x010000, 0x008000, CRC(8aac0ba4) SHA1(67a6412c77d08eab6745db9dff3e32a1bb768901) ) /* bank 1, plane 1 */ |
| 1324 | 1378 | ROM_LOAD( "136040-113.4f", 0x020000, 0x008000, CRC(48b74c52) SHA1(d8328a9ff715247d841be02b1bb7aa043dcb77e1) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1357 | 1411 | |
| 1358 | 1412 | ROM_START( roadrun1 ) |
| 1359 | 1413 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1360 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1361 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1414 | MOTHERBOARD_BIOS | |
| 1362 | 1415 | ROM_LOAD16_BYTE( "136040-128.11c", 0x010000, 0x008000, CRC(5e39d540) SHA1(69fae4c7db247062dffda0138a6e3bfb697f17bf) ) |
| 1363 | 1416 | ROM_LOAD16_BYTE( "136040-129.11a", 0x010001, 0x008000, CRC(d79bfea1) SHA1(eb265ff5f3f08bbdb3b19f9c7dece7e58dd2c6ba) ) |
| 1364 | 1417 | ROM_LOAD16_BYTE( "136040-130.13c", 0x020000, 0x008000, CRC(66453b37) SHA1(cb467a9c8109475bbc6d24b4a3559fa2f2edc887) ) |
| r3232 | r3233 | |
| 1376 | 1429 | ROM_LOAD( "136040-143.15e", 0x008000, 0x004000, CRC(62b9878e) SHA1(db6072a7c8600d85fb70dac3d940a200d0cb5d0a) ) |
| 1377 | 1430 | ROM_LOAD( "136040-144.17e", 0x00c000, 0x004000, CRC(6ef1b804) SHA1(176066c6946090c87945213145960754cd315acb) ) |
| 1378 | 1431 | |
| 1379 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1380 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1432 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1433 | MOTHERBOARD_ALPHA | |
| 1381 | 1434 | |
| 1382 | ROM_REGION( 0x300000, " | |
| 1435 | ROM_REGION( 0x300000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1383 | 1436 | ROM_LOAD( "136040-101.4b", 0x000000, 0x008000, CRC(26d9f29c) SHA1(e03a03484ede4ea209040faf64e88f0667a0ab40) ) /* bank 1, plane 0 */ |
| 1384 | 1437 | ROM_LOAD( "136040-107.9b", 0x010000, 0x008000, CRC(8aac0ba4) SHA1(67a6412c77d08eab6745db9dff3e32a1bb768901) ) /* bank 1, plane 1 */ |
| 1385 | 1438 | ROM_LOAD( "136040-113.4f", 0x020000, 0x008000, CRC(48b74c52) SHA1(d8328a9ff715247d841be02b1bb7aa043dcb77e1) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1418 | 1471 | |
| 1419 | 1472 | ROM_START( roadblst ) |
| 1420 | 1473 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1421 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1422 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1474 | MOTHERBOARD_BIOS | |
| 1423 | 1475 | ROM_LOAD16_BYTE( "136048-1157.11c", 0x010000, 0x008000, CRC(6d9ad91e) SHA1(15815d3777be5377e053a39c1cef20eb101d9b92) ) |
| 1424 | 1476 | ROM_LOAD16_BYTE( "136048-1158.11a", 0x010001, 0x008000, CRC(7d4cf151) SHA1(979006149906638b942a3157b237112acc16183d) ) |
| 1425 | 1477 | ROM_LOAD16_BYTE( "136048-1159.13c", 0x020000, 0x008000, CRC(921c0e34) SHA1(bcc90a73baaecc551e1065037681a79e260905ff) ) |
| r3232 | r3233 | |
| 1438 | 1490 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1439 | 1491 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1440 | 1492 | |
| 1441 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1442 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1493 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1494 | MOTHERBOARD_ALPHA | |
| 1443 | 1495 | |
| 1444 | ROM_REGION( 0x380000, " | |
| 1496 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1445 | 1497 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1446 | 1498 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1447 | 1499 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1484 | 1536 | |
| 1485 | 1537 | ROM_START( roadblsg ) |
| 1486 | 1538 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1487 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1488 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1539 | MOTHERBOARD_BIOS | |
| 1489 | 1540 | ROM_LOAD16_BYTE( "136048-2257.11c", 0x010000, 0x008000, CRC(6e9de790) SHA1(348d4953b63f577b2b1ad747c6fb32c8ec55d310) ) |
| 1490 | 1541 | ROM_LOAD16_BYTE( "136048-2258.11a", 0x010001, 0x008000, CRC(5160c69e) SHA1(a4aa4ae0cf24f0d3c768186332b4b0f8e55d2700) ) |
| 1491 | 1542 | ROM_LOAD16_BYTE( "136048-2259.13c", 0x020000, 0x008000, CRC(62f10976) SHA1(e3c832304ad9163ed43d128aa68c321af655958d) ) |
| r3232 | r3233 | |
| 1504 | 1555 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1505 | 1556 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1506 | 1557 | |
| 1507 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1508 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1558 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1559 | MOTHERBOARD_ALPHA | |
| 1509 | 1560 | |
| 1510 | ROM_REGION( 0x380000, " | |
| 1561 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1511 | 1562 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1512 | 1563 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1513 | 1564 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1550 | 1601 | |
| 1551 | 1602 | ROM_START( roadbls3 ) |
| 1552 | 1603 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1553 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1554 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1604 | MOTHERBOARD_BIOS | |
| 1555 | 1605 | ROM_LOAD16_BYTE( "136048-3157.11c", 0x010000, 0x008000, CRC(ce88fe34) SHA1(72a311e7e2e5f588226168e048905281f71f0aef) ) |
| 1556 | 1606 | ROM_LOAD16_BYTE( "136048-3158.11a", 0x010001, 0x008000, CRC(03bf2879) SHA1(27f2622b9e2a3f823557fd231a8b0e3234fea5cb) ) |
| 1557 | 1607 | ROM_LOAD16_BYTE( "136048-3159.13c", 0x020000, 0x008000, CRC(4305d74a) SHA1(618e0c638efb4110daf0954e89368c7b68a2a155) ) |
| r3232 | r3233 | |
| 1570 | 1620 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1571 | 1621 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1572 | 1622 | |
| 1573 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1574 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1623 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1624 | MOTHERBOARD_ALPHA | |
| 1575 | 1625 | |
| 1576 | ROM_REGION( 0x380000, " | |
| 1626 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1577 | 1627 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1578 | 1628 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1579 | 1629 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1616 | 1666 | |
| 1617 | 1667 | ROM_START( roadblg2 ) |
| 1618 | 1668 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1619 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1620 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1669 | MOTHERBOARD_BIOS | |
| 1621 | 1670 | ROM_LOAD16_BYTE( "136048-1239.11c", 0x010000, 0x008000, CRC(3b2bb14b) SHA1(e5eac61a4249a644fbc27908b443a3830d4488e6) ) |
| 1622 | 1671 | ROM_CONTINUE( 0x050000, 0x008000 ) |
| 1623 | 1672 | ROM_LOAD16_BYTE( "136048-1240.11a", 0x010001, 0x008000, CRC(2a5ab597) SHA1(3bdd27c67b05a426bd57e03a5c71948b6b57a40a) ) |
| r3232 | r3233 | |
| 1636 | 1685 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1637 | 1686 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1638 | 1687 | |
| 1639 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1640 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1688 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1689 | MOTHERBOARD_ALPHA | |
| 1641 | 1690 | |
| 1642 | ROM_REGION( 0x380000, " | |
| 1691 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1643 | 1692 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1644 | 1693 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1645 | 1694 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1682 | 1731 | |
| 1683 | 1732 | ROM_START( roadbls2 ) |
| 1684 | 1733 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1685 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1686 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1734 | MOTHERBOARD_BIOS | |
| 1687 | 1735 | ROM_LOAD16_BYTE( "136048-1139.11c", 0x010000, 0x008000, CRC(b73c1bd5) SHA1(c4de0267a75225db22c771bec14b8da2fc9f06bf) ) |
| 1688 | 1736 | ROM_CONTINUE( 0x050000, 0x008000 ) |
| 1689 | 1737 | ROM_LOAD16_BYTE( "136048-1140.11a", 0x010001, 0x008000, CRC(6305429b) SHA1(c4180f6438a539ddc34c12529e5ac6d59c107728) ) |
| r3232 | r3233 | |
| 1702 | 1750 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1703 | 1751 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1704 | 1752 | |
| 1705 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1706 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1753 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1754 | MOTHERBOARD_ALPHA | |
| 1707 | 1755 | |
| 1708 | ROM_REGION( 0x380000, " | |
| 1756 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1709 | 1757 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1710 | 1758 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1711 | 1759 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1748 | 1796 | |
| 1749 | 1797 | ROM_START( roadblg1 ) |
| 1750 | 1798 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1751 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1752 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1799 | MOTHERBOARD_BIOS | |
| 1753 | 1800 | ROM_LOAD16_BYTE( "136048-1251.11c", 0x010000, 0x008000, CRC(7e94d6a2) SHA1(985b7537dc484975b458a9ae5780e32a5f742d1c) ) |
| 1754 | 1801 | ROM_CONTINUE( 0x050000, 0x008000 ) |
| 1755 | 1802 | ROM_LOAD16_BYTE( "136048-1252.11a", 0x010001, 0x008000, CRC(d7a66215) SHA1(f9797384f2d01b0dda2ff47c3560ca3489a7a38c) ) |
| r3232 | r3233 | |
| 1768 | 1815 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1769 | 1816 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1770 | 1817 | |
| 1771 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1772 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1818 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1819 | MOTHERBOARD_ALPHA | |
| 1773 | 1820 | |
| 1774 | ROM_REGION( 0x380000, " | |
| 1821 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1775 | 1822 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1776 | 1823 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1777 | 1824 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1814 | 1861 | |
| 1815 | 1862 | ROM_START( roadbls1 ) |
| 1816 | 1863 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1817 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1818 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1864 | MOTHERBOARD_BIOS | |
| 1819 | 1865 | ROM_LOAD16_BYTE( "136048-2151.11c", 0x010000, 0x008000, CRC(ea6b3060) SHA1(0786f2e528c6a77ad7422ae199d06b7261cb4f2c) ) |
| 1820 | 1866 | ROM_CONTINUE( 0x050000, 0x008000 ) |
| 1821 | 1867 | ROM_LOAD16_BYTE( "136048-2152.11a", 0x010001, 0x008000, CRC(f5c1fbe0) SHA1(1917f2110a8021198b0cdadbaeab44c71b3bb0b5) ) |
| r3232 | r3233 | |
| 1834 | 1880 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1835 | 1881 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1836 | 1882 | |
| 1837 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1838 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1883 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1884 | MOTHERBOARD_ALPHA | |
| 1839 | 1885 | |
| 1840 | ROM_REGION( 0x380000, " | |
| 1886 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1841 | 1887 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1842 | 1888 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1843 | 1889 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1880 | 1926 | |
| 1881 | 1927 | ROM_START( roadblsc ) |
| 1882 | 1928 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1883 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1884 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1929 | MOTHERBOARD_BIOS | |
| 1885 | 1930 | ROM_LOAD16_BYTE( "136048-1179.7p", 0x010000, 0x008000, CRC(ef448f96) SHA1(238a6c435e317383a1983702ef0a1f2b757ebe8c) ) |
| 1886 | 1931 | ROM_LOAD16_BYTE( "136048-1180.8p", 0x010001, 0x008000, CRC(bdb368d5) SHA1(9c79b053708ff619a2733664f881abb849ae2371) ) |
| 1887 | 1932 | ROM_LOAD16_BYTE( "136048-1181.7r", 0x020000, 0x008000, CRC(d52581da) SHA1(d0a475f9d8199bc7c0ce6e6a663f214df9bffc39) ) |
| r3232 | r3233 | |
| 1900 | 1945 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1901 | 1946 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1902 | 1947 | |
| 1903 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1904 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 1948 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 1949 | MOTHERBOARD_ALPHA | |
| 1905 | 1950 | |
| 1906 | ROM_REGION( 0x380000, " | |
| 1951 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1907 | 1952 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1908 | 1953 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1909 | 1954 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 1946 | 1991 | |
| 1947 | 1992 | ROM_START( roadblcg ) |
| 1948 | 1993 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 1949 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 1950 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 1994 | MOTHERBOARD_BIOS | |
| 1951 | 1995 | ROM_LOAD16_BYTE( "136048-1235.7p", 0x010000, 0x008000, CRC(58b2998f) SHA1(7e9f4ca2b15cf60c61e0615f214f9fcc518cb194) ) |
| 1952 | 1996 | ROM_LOAD16_BYTE( "136048-1236.8p", 0x010001, 0x008000, CRC(02e23a40) SHA1(6525351669e95dab869c7adc7d992d12d9313aee) ) |
| 1953 | 1997 | ROM_LOAD16_BYTE( "136048-1237.7r", 0x020000, 0x008000, CRC(5e0a7c5d) SHA1(fb3688fbadc05f96980c67f5446ccb250d20b1a3) ) |
| r3232 | r3233 | |
| 1966 | 2010 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 1967 | 2011 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 1968 | 2012 | |
| 1969 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 1970 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 2013 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 2014 | MOTHERBOARD_ALPHA | |
| 1971 | 2015 | |
| 1972 | ROM_REGION( 0x380000, " | |
| 2016 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 1973 | 2017 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 1974 | 2018 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 1975 | 2019 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 2012 | 2056 | |
| 2013 | 2057 | ROM_START( roadblc1 ) |
| 2014 | 2058 | ROM_REGION( 0x88000, "main", 0 ) /* 8.5*64k for 68000 code & slapstic ROM */ |
| 2015 | ROM_LOAD16_BYTE( "136032.205", 0x000000, 0x004000, CRC(88d0be26) SHA1(d124045eccc562ff0423b23a240e27ad740fa0c9) ) | |
| 2016 | ROM_LOAD16_BYTE( "136032.206", 0x000001, 0x004000, CRC(3c79ef05) SHA1(20fdca7131478e1ee12691bdafd2d5bb74cbd16f) ) | |
| 2059 | MOTHERBOARD_BIOS | |
| 2017 | 2060 | ROM_LOAD16_BYTE( "136048-2135.7p", 0x010000, 0x008000, CRC(c0ef86df) SHA1(7dd4d2acba55dc001e009c37fae5a97a53ea1e66) ) |
| 2018 | 2061 | ROM_LOAD16_BYTE( "136048-2136.8p", 0x010001, 0x008000, CRC(9637e2f0) SHA1(86257e1316356c1a7d86bcf7b57bcaff33ac3df5) ) |
| 2019 | 2062 | ROM_LOAD16_BYTE( "136048-2137.7r", 0x020000, 0x008000, CRC(5382ab85) SHA1(1511dfaf8537980e506e4180a23ffcfcfec81451) ) |
| r3232 | r3233 | |
| 2032 | 2075 | ROM_LOAD( "136048-1169.1516e", 0x8000, 0x4000, CRC(ee318052) SHA1(f66ff39499697b7439dc62567e727fec769c1505) ) |
| 2033 | 2076 | ROM_LOAD( "136048-1170.17e", 0xc000, 0x4000, CRC(75dfec33) SHA1(3092348b98419bb23181d21406733d5d21cd3d82) ) |
| 2034 | 2077 | |
| 2035 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) | |
| 2036 | ROM_LOAD( "136032.107", 0x00000, 0x02000, CRC(7a29dc07) SHA1(72ba464da01bd6d3a91b8d9997d5ac14b6f47aad) ) /* alpha font */ | |
| 2078 | ROM_REGION( 0x2000, "alpha", ROMREGION_DISPOSE ) | |
| 2079 | MOTHERBOARD_ALPHA | |
| 2037 | 2080 | |
| 2038 | ROM_REGION( 0x380000, " | |
| 2081 | ROM_REGION( 0x380000, "tiles", ROMREGION_DISPOSE | ROMREGION_INVERT | ROMREGION_ERASEFF ) | |
| 2039 | 2082 | ROM_LOAD( "136048-1101.2s", 0x000000, 0x008000, CRC(fe342d27) SHA1(72deac16ab9b6b811f49d70d700d6bc3a904f9d5) ) /* bank 1, plane 0 */ |
| 2040 | 2083 | ROM_LOAD( "136048-1102.2r", 0x010000, 0x008000, CRC(17c7e780) SHA1(675a2fe5ac55c97d54153eacabf863a525e4b71f) ) /* bank 1, plane 1 */ |
| 2041 | 2084 | ROM_LOAD( "136048-1103.2n", 0x020000, 0x008000, CRC(39688e01) SHA1(1b273e26b48a2f69b0895c29c9b3e762c686661d) ) /* bank 1, plane 2 */ |
| r3232 | r3233 | |
| 2162 | 2205 | * |
| 2163 | 2206 | *************************************/ |
| 2164 | 2207 | |
| 2165 | GAME( 1984, marble, 0, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 1)", 0 ) | |
| 2208 | GAME( 1984, atarisy1, 0, atarisy1, peterpak, peterpak, ROT0, "Atari Games", "Atari System 1 BIOS", GAME_IS_BIOS_ROOT ) | |
| 2209 | ||
| 2210 | GAME( 1984, marble, atarisy1, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 1)", 0 ) | |
| 2166 | 2211 | GAME( 1984, marble2, marble, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 2)", 0 ) |
| 2167 | 2212 | GAME( 1984, marble3, marble, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 3)", 0 ) |
| 2168 | 2213 | GAME( 1984, marble4, marble, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 4)", 0 ) |
| 2214 | GAME( 1984, marble5, marble, atarisy1, marble, marble, ROT0, "Atari Games", "Marble Madness (set 5 - LSI Cartridge)", 0 ) | |
| 2169 | 2215 | |
| 2170 | GAME( 1984, peterpak, | |
| 2216 | GAME( 1984, peterpak, atarisy1, | |
| 2171 | 2217 | |
| 2172 | GAME( 1985, indytemp, | |
| 2218 | GAME( 1985, indytemp, atarisy1, | |
| 2173 | 2219 | GAME( 1985, indytem2, indytemp, atarisy1, indytemp, indytemp, ROT0, "Atari Games", "Indiana Jones and the Temple of Doom (set 2)", 0 ) |
| 2174 | 2220 | GAME( 1985, indytem3, indytemp, atarisy1, indytemp, indytemp, ROT0, "Atari Games", "Indiana Jones and the Temple of Doom (set 3)", 0 ) |
| 2175 | 2221 | GAME( 1985, indytem4, indytemp, atarisy1, indytemp, indytemp, ROT0, "Atari Games", "Indiana Jones and the Temple of Doom (set 4)", 0 ) |
| 2176 | 2222 | GAME( 1985, indytemd, indytemp, atarisy1, indytemp, indytemp, ROT0, "Atari Games", "Indiana Jones and the Temple of Doom (German)", 0 ) |
| 2177 | 2223 | GAME( 1985, indytemc, indytemp, atarisy1, indytemp, indytemp, ROT0, "Atari Games", "Indiana Jones and the Temple of Doom (Cocktail)", 0 ) |
| 2178 | 2224 | |
| 2179 | GAME( 1985, roadrunn, | |
| 2225 | GAME( 1985, roadrunn, atarisy1, | |
| 2180 | 2226 | GAME( 1985, roadrun2, roadrunn, atarisy1, roadrunn, roadrunn, ROT0, "Atari Games", "Road Runner (rev 1+)", 0 ) |
| 2181 | 2227 | GAME( 1985, roadrun1, roadrunn, atarisy1, roadrunn, roadrunn, ROT0, "Atari Games", "Road Runner (rev 1)", 0 ) |
| 2182 | 2228 | |
| 2183 | GAME( 1987, roadblst, | |
| 2229 | GAME( 1987, roadblst, atarisy1, | |
| 2184 | 2230 | GAME( 1987, roadblsg, roadblst, atarisy1, roadblst, roadb109, ROT0, "Atari Games", "Road Blasters (upright, German, rev 3)", 0 ) |
| 2185 | 2231 | GAME( 1987, roadbls3, roadblst, atarisy1, roadblst, roadb109, ROT0, "Atari Games", "Road Blasters (upright, rev 3)", 0 ) |
| 2186 | 2232 | GAME( 1987, roadblg2, roadblst, atarisy1, roadblst, roadb110, ROT0, "Atari Games", "Road Blasters (upright, German, rev 2)", 0 ) |
| r3232 | r3233 | |
|---|---|---|
| 415 | 415 | READ16_HANDLER ( wgp_piv_ctrl_word_r ); |
| 416 | 416 | WRITE16_HANDLER( wgp_piv_ctrl_word_w ); |
| 417 | 417 | |
| 418 | static UINT16 cpua_ctrl | |
| 418 | static UINT16 cpua_ctrl | |
| 419 | 419 | static UINT16 port_sel=0; |
| 420 | 420 | extern UINT16 wgp_rotate_ctrl[8]; |
| 421 | 421 | |
| r3232 | r3233 | |
| 619 | 619 | SOUND |
| 620 | 620 | **********************************************************/ |
| 621 | 621 | |
| 622 | static INT32 banknum | |
| 622 | static INT32 banknum | |
| 623 | 623 | |
| 624 | 624 | static void reset_sound_region(running_machine *machine) /* assumes Z80 sandwiched between the 68Ks */ |
| 625 | 625 | { |
| r3232 | r3233 | |
| 938 | 938 | reset_sound_region(machine); |
| 939 | 939 | } |
| 940 | 940 | |
| 941 | static MACHINE_RESET( wgp ) | |
| 942 | { | |
| 943 | banknum = -1; | |
| 944 | cpua_ctrl = 0xff; | |
| 945 | port_sel=0; | |
| 946 | } | |
| 947 | ||
| 941 | 948 | static MACHINE_START( wgp ) |
| 942 | 949 | { |
| 943 | 950 | state_save_register_global(cpua_ctrl); |
| r3232 | r3233 | |
| 960 | 967 | MDRV_CPU_VBLANK_INT("main", wgp_cpub_interrupt) |
| 961 | 968 | |
| 962 | 969 | MDRV_MACHINE_START(wgp) |
| 970 | MDRV_MACHINE_RESET(wgp) | |
| 963 | 971 | |
| 964 | 972 | MDRV_INTERLEAVE(250) |
| 965 | 973 | |
| r3232 | r3233 | |
| 1213 | 1221 | #endif |
| 1214 | 1222 | |
| 1215 | 1223 | // taitosnd_setz80_soundcpu( 2 ); |
| 1216 | cpua_ctrl = 0xff; | |
| 1217 | 1224 | } |
| 1218 | 1225 | |
| 1219 | 1226 | static DRIVER_INIT( wgp2 ) |
| r3232 | r3233 | |
| 1222 | 1229 | UINT16 *ROM = (UINT16 *)memory_region(machine, "sub"); |
| 1223 | 1230 | ROM[0x8008 / 2] = 0x0; |
| 1224 | 1231 | ROM[0x8010 / 2] = 0x0; |
| 1225 | ||
| 1226 | cpua_ctrl = 0xff; | |
| 1227 | 1232 | } |
| 1228 | 1233 | |
| 1229 | 1234 | /* Working Games with some graphics problems - e.g. missing rotation */ |
| r3232 | r3233 | |
|---|---|---|
| 764 | 764 | |
| 765 | 765 | ROM_START( welltris ) |
| 766 | 766 | ROM_REGION( 0x180000, "main", 0 ) /* 68000 code */ |
| 767 | ROM_LOAD16_BYTE( "j2u.8", 0x000000, 0x20000, BAD_DUMP CRC(00a382a4) SHA1(b6a7e1b360e3cefc582983c8dff6aa28a7c77124) ) | |
| 768 | ROM_LOAD16_BYTE( "j1u.7", 0x000001, 0x20000, BAD_DUMP CRC(abcb008b) SHA1(c71ed431cbd8aea0b4396029203a7b735a8fdac3) ) | |
| 767 | ROM_LOAD16_BYTE( "j2u.8", 0x000000, 0x20000, CRC(7488fe94) SHA1(41874366e2ab763cd827ff712b76ea2da0f9af6a) ) | |
| 768 | ROM_LOAD16_BYTE( "j1u.7", 0x000001, 0x20000, CRC(571413ac) SHA1(5eb9387efb9c1597005abff4d79f4b32aa7c93b2) ) | |
| 769 | 769 | /* Space */ |
| 770 | 770 | ROM_LOAD16_BYTE( "lh532j10.10", 0x100000, 0x40000, CRC(1187c665) SHA1(c6c55016e46805694348b386e521a3ef1a443621) ) |
| 771 | 771 | ROM_LOAD16_BYTE( "lh532j11.9", 0x100001, 0x40000, CRC(18eda9e5) SHA1(c01d1dc6bfde29797918490947c89440b58d5372) ) |
| r3232 | r3233 | |
|---|---|---|
| 28 | 28 | static TIMER_CALLBACK( input_callback ) |
| 29 | 29 | { |
| 30 | 30 | static UINT8 dial[8]; |
| 31 | static const char *dialnames[] = { "DIAL1", "DIAL2", "DIAL3", "DIAL4", "DIAL5", "DIAL6", "DIAL7", "DIAL8" }; | |
| 31 | static const char *const dialnames[] = { "DIAL1", "DIAL2", "DIAL3", "DIAL4", "DIAL5", "DIAL6", "DIAL7", "DIAL8" }; | |
| 32 | 32 | |
| 33 | 33 | int i; |
| 34 | 34 | |
| r3232 | r3233 | |
| 71 | 71 | |
| 72 | 72 | static READ8_HANDLER( sprint8_input_r ) |
| 73 | 73 | { |
| 74 | static const char *portnames[] = { "P1", "P2", "P3", "P4", "P5", "P6", "P7", "P8" }; | |
| 74 | static const char *const portnames[] = { "P1", "P2", "P3", "P4", "P5", "P6", "P7", "P8" }; | |
| 75 | 75 | UINT8 val = input_port_read(machine, portnames[offset]); |
| 76 | 76 | |
| 77 | 77 | if (steer_dir[offset]) |
| r3232 | r3233 | |
|---|---|---|
| 491 | 491 | |
| 492 | 492 | static READ16_HANDLER( gdfs_eeprom_r ) |
| 493 | 493 | { |
| 494 | static const char *gunnames[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2" }; | |
| 494 | static const char *const gunnames[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2" }; | |
| 495 | 495 | |
| 496 | 496 | return (((gdfs_lightgun_select & 1) ? 0 : 0xff) ^ input_port_read(machine, gunnames[gdfs_lightgun_select])) | (eeprom_read_bit() << 8); |
| 497 | 497 | } |
| r3232 | r3233 | |
|---|---|---|
| 341 | 341 | } |
| 342 | 342 | |
| 343 | 343 | |
| 344 | static INT32 banknum | |
| 344 | static INT32 banknum | |
| 345 | 345 | |
| 346 | 346 | static void reset_sound_region(running_machine *machine) |
| 347 | 347 | { |
| r3232 | r3233 | |
| 362 | 362 | static MACHINE_START( taitoair ) |
| 363 | 363 | { |
| 364 | 364 | dsp_HOLD_signal = ASSERT_LINE; |
| 365 | banknum = -1; | |
| 365 | 366 | |
| 366 | 367 | state_save_register_global(banknum); |
| 367 | 368 | state_save_register_postload(machine, taitoair_postload, NULL); |
| r3232 | r3233 | |
|---|---|---|
| 84 | 84 | |
| 85 | 85 | static WRITE16_HANDLER( a2d_select_w ) |
| 86 | 86 | { |
| 87 | static const char *portnames[] = { "A2D0", "A2D1" }; | |
| 87 | static const char *const portnames[] = { "A2D0", "A2D1" }; | |
| 88 | 88 | |
| 89 | 89 | analog_data = input_port_read(machine, portnames[offset != 0]); |
| 90 | 90 | } |
| r3232 | r3233 | |
|---|---|---|
| 319 | 319 | |
| 320 | 320 | PORT_MODIFY("DSW2") |
| 321 | 321 | PORT_DIPNAME( 0x04, 0x04, "MODE" ) |
| 322 | PORT_DIPSETTING( 0x00, "2 | |
| 322 | PORT_DIPSETTING( 0x00, "2d" ) | |
| 323 | 323 | PORT_DIPSETTING( 0x04, "3D" ) |
| 324 | 324 | PORT_BIT( 0xf8, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 325 | 325 | INPUT_PORTS_END |
| r3232 | r3233 | |
| 383 | 383 | /* basic machine hardware */ |
| 384 | 384 | MDRV_CPU_ADD("main", M6809, 49152000/32) |
| 385 | 385 | MDRV_CPU_PROGRAM_MAP(m6809_map,0) |
| 386 | MDRV_CPU_VBLANK_INT("2 | |
| 386 | MDRV_CPU_VBLANK_INT("2d", m6809_vb_interrupt) | |
| 387 | 387 | |
| 388 | 388 | MDRV_CPU_ADD("audio", M65C02, 49152000/24) |
| 389 | 389 | MDRV_CPU_PROGRAM_MAP(m6502_a_map,0) |
| r3232 | r3233 | |
| 393 | 393 | |
| 394 | 394 | MDRV_CPU_ADD("sub", M68000, 49152000/4) |
| 395 | 395 | MDRV_CPU_PROGRAM_MAP(m68k_map,0) |
| 396 | MDRV_CPU_VBLANK_INT("2 | |
| 396 | MDRV_CPU_VBLANK_INT("2d", m68k_vb_interrupt) | |
| 397 | 397 | |
| 398 | 398 | MDRV_CPU_ADD("mcu", HD63701, 49152000/8) /* or compatible 6808 with extra instructions */ |
| 399 | 399 | MDRV_CPU_PROGRAM_MAP(mcu_map,0) |
| 400 | 400 | MDRV_CPU_IO_MAP(mcu_io_map,0) |
| 401 | MDRV_CPU_VBLANK_INT("2 | |
| 401 | MDRV_CPU_VBLANK_INT("2d", mcu_vb_interrupt) | |
| 402 | 402 | |
| 403 | 403 | MDRV_INTERLEAVE(100) |
| 404 | 404 | |
| r3232 | r3233 | |
| 412 | 412 | MDRV_PALETTE_LENGTH(4096) |
| 413 | 413 | MDRV_DEFAULT_LAYOUT(layout_horizont) |
| 414 | 414 | |
| 415 | MDRV_SCREEN_ADD("2 | |
| 415 | MDRV_SCREEN_ADD("2d", RASTER) | |
| 416 | 416 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 417 | 417 | MDRV_SCREEN_REFRESH_RATE(60.606060) |
| 418 | 418 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| 419 | 419 | MDRV_SCREEN_SIZE(38*8, 32*8) |
| 420 | 420 | MDRV_SCREEN_VISIBLE_AREA(2*8, 34*8-1 + 2*8, 0*8, 28*8-1 + 0) |
| 421 | 421 | |
| 422 | MDRV_SCREEN_ADD("3 | |
| 422 | MDRV_SCREEN_ADD("3dl | |
| 423 | 423 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 424 | 424 | MDRV_SCREEN_REFRESH_RATE(60.606060) |
| 425 | 425 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| 426 | 426 | MDRV_SCREEN_SIZE(38*8, 32*8) |
| 427 | 427 | MDRV_SCREEN_VISIBLE_AREA(2*8, 34*8-1 + 2*8, 0*8, 28*8-1 + 0) |
| 428 | 428 | |
| 429 | MDRV_SCREEN_ADD("3 | |
| 429 | MDRV_SCREEN_ADD("3dr | |
| 430 | 430 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 431 | 431 | MDRV_SCREEN_REFRESH_RATE(60.606060) |
| 432 | 432 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| r3232 | r3233 | |
|---|---|---|
| 114 | 114 | AM_RANGE(0xf000, 0xf3ff) AM_WRITE(cop01_foreground_w) AM_BASE(&cop01_fgvideoram) |
| 115 | 115 | ADDRESS_MAP_END |
| 116 | 116 | |
| 117 | static ADDRESS_MAP_START( | |
| 117 | static ADDRESS_MAP_START( io_ma | |
| 118 | 118 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 119 | 119 | AM_RANGE(0x00, 0x00) AM_READ_PORT("P1") |
| 120 | 120 | AM_RANGE(0x01, 0x01) AM_READ_PORT("P2") |
| 121 | 121 | AM_RANGE(0x02, 0x02) AM_READ_PORT("SYSTEM") |
| 122 | 122 | AM_RANGE(0x03, 0x03) AM_READ_PORT("DSW1") |
| 123 | 123 | AM_RANGE(0x04, 0x04) AM_READ_PORT("DSW2") |
| 124 | AM_RANGE(0x40, 0x43) AM_WRITE(cop01_vreg_w) | |
| 125 | AM_RANGE(0x44, 0x44) AM_WRITE(cop01_sound_command_w) | |
| 126 | AM_RANGE(0x45, 0x45) AM_WRITE(watchdog_reset_w) /* ? */ | |
| 124 | 127 | ADDRESS_MAP_END |
| 125 | 128 | |
| 126 | static ADDRESS_MAP_START( mightguy_ | |
| 129 | static ADDRESS_MAP_START( mightguy_io_ma | |
| 127 | 130 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 128 | 131 | AM_RANGE(0x00, 0x00) AM_READ_PORT("P1") |
| 129 | 132 | AM_RANGE(0x01, 0x01) AM_READ_PORT("P2") |
| 130 | 133 | AM_RANGE(0x02, 0x02) AM_READ_PORT("SYSTEM") |
| 131 | 134 | AM_RANGE(0x03, 0x03) AM_READ_PORT("DSW1") |
| 132 | 135 | AM_RANGE(0x04, 0x04) AM_READ_PORT("DSW2") |
| 133 | ADDRESS_MAP_END | |
| 134 | ||
| 135 | static ADDRESS_MAP_START( writeport, ADDRESS_SPACE_IO, 8 ) | |
| 136 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 137 | 136 | AM_RANGE(0x40, 0x43) AM_WRITE(cop01_vreg_w) |
| 138 | 137 | AM_RANGE(0x44, 0x44) AM_WRITE(cop01_sound_command_w) |
| 139 | 138 | AM_RANGE(0x45, 0x45) AM_WRITE(watchdog_reset_w) /* ? */ |
| r3232 | r3233 | |
| 150 | 149 | AM_RANGE(0xc000, 0xc7ff) AM_WRITE(SMH_RAM) |
| 151 | 150 | ADDRESS_MAP_END |
| 152 | 151 | |
| 153 | static ADDRESS_MAP_START( | |
| 152 | static ADDRESS_MAP_START( a | |
| 154 | 153 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 155 | AM_RANGE(0x06, 0x06) AM_READ(cop01_sound_command_r) | |
| 156 | ADDRESS_MAP_END | |
| 157 | ||
| 158 | static ADDRESS_MAP_START( sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 159 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 160 | 154 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_control_port_0_w) |
| 161 | 155 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_write_port_0_w) |
| 162 | 156 | AM_RANGE(0x02, 0x02) AM_WRITE(ay8910_control_port_1_w) |
| 163 | 157 | AM_RANGE(0x03, 0x03) AM_WRITE(ay8910_write_port_1_w) |
| 164 | 158 | AM_RANGE(0x04, 0x04) AM_WRITE(ay8910_control_port_2_w) |
| 165 | 159 | AM_RANGE(0x05, 0x05) AM_WRITE(ay8910_write_port_2_w) |
| 160 | AM_RANGE(0x06, 0x06) AM_READ(cop01_sound_command_r) | |
| 166 | 161 | ADDRESS_MAP_END |
| 167 | 162 | |
| 163 | ||
| 168 | 164 | /* this just gets some garbage out of the YM3526 */ |
| 169 | 165 | static READ8_HANDLER( kludge ) { static int timer; return timer++; } |
| 170 | 166 | |
| 171 | static ADDRESS_MAP_START( mightguy_ | |
| 167 | static ADDRESS_MAP_START( mightguy_a | |
| 172 | 168 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 173 | AM_RANGE(0x03, 0x03) AM_READ(kludge) /* 1412M2? */ | |
| 174 | AM_RANGE(0x06, 0x06) AM_READ(cop01_sound_command_r) | |
| 175 | ADDRESS_MAP_END | |
| 176 | ||
| 177 | static ADDRESS_MAP_START( mightguy_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 178 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 179 | 169 | AM_RANGE(0x00, 0x00) AM_WRITE(ym3526_control_port_0_w) |
| 180 | 170 | AM_RANGE(0x01, 0x01) AM_WRITE(ym3526_write_port_0_w) |
| 181 | 171 | AM_RANGE(0x02, 0x02) AM_WRITE(SMH_NOP) /* 1412M2? */ |
| 182 | 172 | AM_RANGE(0x03, 0x03) AM_WRITE(SMH_NOP) /* 1412M2? */ |
| 173 | AM_RANGE(0x03, 0x03) AM_READ(kludge) /* 1412M2? */ | |
| 174 | AM_RANGE(0x06, 0x06) AM_READ(cop01_sound_command_r) | |
| 183 | 175 | ADDRESS_MAP_END |
| 184 | 176 | |
| 185 | 177 | |
| r3232 | r3233 | |
| 407 | 399 | /* basic machine hardware */ |
| 408 | 400 | MDRV_CPU_ADD("main", Z80, 4000000) /* ???? */ |
| 409 | 401 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 410 | MDRV_CPU_IO_MAP( | |
| 402 | MDRV_CPU_IO_MAP(io_ma | |
| 411 | 403 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 412 | 404 | |
| 413 | 405 | MDRV_CPU_ADD("audio", Z80, 3000000) /* ???? */ |
| 414 | 406 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 415 | MDRV_CPU_IO_MAP( | |
| 407 | MDRV_CPU_IO_MAP( | |
| 416 | 408 | |
| 417 | 409 | /* video hardware */ |
| 418 | 410 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 447 | 439 | /* basic machine hardware */ |
| 448 | 440 | MDRV_CPU_ADD("main", Z80, 4000000) /* ???? */ |
| 449 | 441 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 450 | MDRV_CPU_IO_MAP(mightguy_ | |
| 442 | MDRV_CPU_IO_MAP(mightguy_io_ma | |
| 451 | 443 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 452 | 444 | |
| 453 | 445 | MDRV_CPU_ADD("audio", Z80, 3000000) /* ???? */ |
| 454 | 446 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 455 | MDRV_CPU_IO_MAP(mightguy_ | |
| 447 | MDRV_CPU_IO_MAP(mightguy_a | |
| 456 | 448 | |
| 457 | 449 | /* video hardware */ |
| 458 | 450 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
|---|---|---|
| 668 | 668 | static UINT8 scn2674_display_enabled; |
| 669 | 669 | static UINT8 scn2674_cursor_enabled; |
| 670 | 670 | |
| 671 | static void scn2674_write_command(UINT8 data) | |
| 671 | static void scn2674_write_command(running_machine *machine, UINT8 data) | |
| 672 | 672 | { |
| 673 | 673 | UINT8 oprand; |
| 674 | 674 | int i; |
| r3232 | r3233 | |
| 777 | 777 | { |
| 778 | 778 | scn2674_irq_state = 1; |
| 779 | 779 | } |
| 780 | update_mpu68_interrupts( | |
| 780 | update_mpu68_interrupts(machine); | |
| 781 | 781 | } |
| 782 | 782 | if ((data&0xe0)==0x80) |
| 783 | 783 | { |
| r3232 | r3233 | |
| 803 | 803 | scn2674_irq_state = 1; |
| 804 | 804 | } |
| 805 | 805 | } |
| 806 | update_mpu68_interrupts( | |
| 806 | update_mpu68_interrupts(machine); | |
| 807 | 807 | |
| 808 | 808 | } |
| 809 | 809 | |
| r3232 | r3233 | |
| 828 | 828 | scn2674_irq_state = 1; |
| 829 | 829 | } |
| 830 | 830 | } |
| 831 | update_mpu68_interrupts( | |
| 831 | update_mpu68_interrupts(machine); | |
| 832 | 832 | } |
| 833 | 833 | |
| 834 | 834 | /* Delayed Commands */ |
| r3232 | r3233 | |
| 962 | 962 | break; |
| 963 | 963 | |
| 964 | 964 | case 1: |
| 965 | scn2674_write_command(data); | |
| 965 | scn2674_write_command(machine, data); | |
| 966 | 966 | break; |
| 967 | 967 | |
| 968 | 968 | case 2: scn2674_screen1_l = data; break; |
| r3232 | r3233 | |
| 1655 | 1655 | static MACHINE_DRIVER_START( mpu4_vid ) |
| 1656 | 1656 | MDRV_CPU_ADD("main", M6809, MPU4_MASTER_CLOCK/4 ) |
| 1657 | 1657 | MDRV_CPU_PROGRAM_MAP(mpu4_6809_map,0) |
| 1658 | MDRV_TIMER_ADD_PERIODIC("50 | |
| 1658 | MDRV_TIMER_ADD_PERIODIC("50hz",gen_50hz, HZ(100)) | |
| 1659 | 1659 | |
| 1660 | 1660 | MDRV_NVRAM_HANDLER(generic_0fill) /* confirm */ |
| 1661 | 1661 | |
| r3232 | r3233 | |
| 1680 | 1680 | MDRV_PALETTE_LENGTH(16) |
| 1681 | 1681 | |
| 1682 | 1682 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 1683 | MDRV_SOUND_ADD(" | |
| 1683 | MDRV_SOUND_ADD("ay8913",AY8913, MPU4_MASTER_CLOCK/4) | |
| 1684 | 1684 | MDRV_SOUND_CONFIG(ay8910_config) |
| 1685 | 1685 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 1686 | 1686 | |
| r3232 | r3233 | |
| 1704 | 1704 | MDRV_CPU_ADD("main", M6809, MPU4_MASTER_CLOCK/4) |
| 1705 | 1705 | MDRV_CPU_PROGRAM_MAP(dealem_memmap,0) |
| 1706 | 1706 | |
| 1707 | MDRV_TIMER_ADD_PERIODIC("50 | |
| 1707 | MDRV_TIMER_ADD_PERIODIC("50hz",gen_50hz, HZ(100)) | |
| 1708 | 1708 | |
| 1709 | 1709 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 1710 | MDRV_SOUND_ADD(" | |
| 1710 | MDRV_SOUND_ADD("ay8913",AY8913, MPU4_MASTER_CLOCK/4) | |
| 1711 | 1711 | MDRV_SOUND_CONFIG(ay8910_config) |
| 1712 | 1712 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 1713 | 1713 |
| r3232 | r3233 | |
|---|---|---|
| 181 | 181 | static READ8_HANDLER( angelkds_input_r ) |
| 182 | 182 | { |
| 183 | 183 | int fake; |
| 184 | static const char *portnames[] = { "I81", "I82" }; | |
| 185 | static const char *fakenames[] = { "FAKE1", "FAKE2" }; | |
| 184 | static const char *const portnames[] = { "I81", "I82" }; | |
| 185 | static const char *const fakenames[] = { "FAKE1", "FAKE2" }; | |
| 186 | 186 | |
| 187 | 187 | fake = input_port_read(machine, fakenames[offset]); |
| 188 | 188 | |
| r3232 | r3233 | |
| 193 | 193 | |
| 194 | 194 | static READ8_HANDLER( angelkds_input_r ) |
| 195 | 195 | { |
| 196 | static const char *portnames[] = { "I81", "I82" }; | |
| 196 | static const char *const portnames[] = { "I81", "I82" }; | |
| 197 | 197 | |
| 198 | 198 | return input_port_read(machine, portnames[offset]); |
| 199 | 199 | } |
| r3232 | r3233 | |
|---|---|---|
| 150 | 150 | |
| 151 | 151 | static WRITE32_HANDLER( midvunit_adc_w ) |
| 152 | 152 | { |
| 153 | static const char *adcnames[] = { "WHEEL", "ACCEL", "BRAKE" }; | |
| 153 | static const char *const adcnames[] = { "WHEEL", "ACCEL", "BRAKE" }; | |
| 154 | 154 | |
| 155 | 155 | if (!(control_data & 0x20)) |
| 156 | 156 | { |
| r3232 | r3233 | |
|---|---|---|
| 91 | 91 | AM_RANGE(0xf000, 0xf7ff) AM_RAM AM_BASE(&generic_nvram) AM_SIZE(&generic_nvram_size) |
| 92 | 92 | ADDRESS_MAP_END |
| 93 | 93 | |
| 94 | static ADDRESS_MAP_START( kingpin_ | |
| 94 | static ADDRESS_MAP_START( kingpin_io_ma | |
| 95 | 95 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 96 | 96 | AM_RANGE(0x00, 0x00) AM_READ(io_read_missing_dips) |
| 97 | 97 | AM_RANGE(0x01, 0x01) AM_READ_PORT("DSW") |
| 98 | 98 | /* AM_RANGE(0x02, 0x02) AM_READ(io_read_missing_dips) */ |
| 99 | /* AM_RANGE(0x02, 0x02) AM_WRITE(NO IDEA) */ | |
| 99 | 100 | AM_RANGE(0x10, 0x10) AM_READ_PORT("IN0") |
| 100 | 101 | AM_RANGE(0x11, 0x11) AM_READ_PORT("IN1") |
| 101 | AM_RANGE(0x20, 0x20) AM_READ(TMS9928A_vram_r) | |
| 102 | AM_RANGE(0x21, 0x21) AM_READ(TMS9928A_register_r) | |
| 103 | ADDRESS_MAP_END | |
| 104 | ||
| 105 | static ADDRESS_MAP_START( kingpin_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 106 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 107 | /* AM_RANGE(0x02, 0x02) AM_WRITE(NO IDEA) */ | |
| 108 | 102 | /* AM_RANGE(0x12, 0x12) AM_WRITE(NO IDEA) */ |
| 109 | 103 | /* AM_RANGE(0x13, 0x13) AM_WRITE(NO IDEA) */ |
| 110 | AM_RANGE(0x20, 0x20) AM_WRITE(TMS9928A_vram_w) | |
| 111 | AM_RANGE(0x21, 0x21) AM_WRITE(TMS9928A_register_w) | |
| 104 | AM_RANGE(0x20, 0x20) AM_READWRITE(TMS9928A_vram_r, TMS9928A_vram_w) | |
| 105 | AM_RANGE(0x21, 0x21) AM_READWRITE(TMS9928A_register_r, TMS9928A_register_w) | |
| 112 | 106 | /* AM_RANGE(0x30, 0x30) AM_WRITE(LIKELY LIGHTS) */ |
| 113 | 107 | /* AM_RANGE(0x40, 0x40) AM_WRITE(LIKELY LIGHTS) */ |
| 114 | 108 | /* AM_RANGE(0x50, 0x50) AM_WRITE(LIKELY LIGHTS) */ |
| r3232 | r3233 | |
| 147 | 141 | /* MAIN CPU */ |
| 148 | 142 | MDRV_CPU_ADD("main", Z80, 3579545) |
| 149 | 143 | MDRV_CPU_PROGRAM_MAP(kingpin_program_map,0) |
| 150 | MDRV_CPU_IO_MAP(kingpin_ | |
| 144 | MDRV_CPU_IO_MAP(kingpin_ | |
| 151 | 145 | MDRV_CPU_VBLANK_INT("main", kingpin_video_interrupt) |
| 152 | 146 | |
| 153 | 147 | /* SOUND CPU */ |
| 154 | 148 | MDRV_CPU_ADD("audio", Z80, 3579545) |
| 155 | 149 | MDRV_CPU_PROGRAM_MAP(kingpin_sound_map,0) |
| 156 | /*MDRV_CPU_IO_MAP( | |
| 150 | /*MDRV_CPU_IO_MAP(s | |
| 157 | 151 | |
| 158 | 152 | /* VIDEO */ |
| 159 | 153 | MDRV_IMPORT_FROM(tms9928a) |
| r3232 | r3233 | |
|---|---|---|
| 385 | 385 | dac_data_w( 2 + (offset & 1), (data & 0xf) * 0x11 ); |
| 386 | 386 | } |
| 387 | 387 | |
| 388 | ||
| 389 | ||
| 390 | static ADDRESS_MAP_START( bssoccer_pcm_1_readport, ADDRESS_SPACE_IO, 8 ) | |
| 388 | static ADDRESS_MAP_START( bssoccer_pcm_1_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 391 | 389 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 392 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch2_r ) // From The Sound Z80 | |
| 393 | ADDRESS_MAP_END | |
| 394 | static ADDRESS_MAP_START( bssoccer_pcm_1_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 395 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 390 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch2_r ) // From The Sound Z80 | |
| 396 | 391 | AM_RANGE(0x00, 0x01) AM_WRITE(bssoccer_DAC_1_w ) // 2 x DAC |
| 397 | 392 | AM_RANGE(0x03, 0x03) AM_WRITE(bssoccer_pcm_1_bankswitch_w ) // Rom Bank |
| 398 | 393 | ADDRESS_MAP_END |
| 399 | 394 | |
| 400 | static ADDRESS_MAP_START( bssoccer_pcm_2_ | |
| 395 | static ADDRESS_MAP_START( bssoccer_pcm_2_io_ma | |
| 401 | 396 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 402 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch3_r ) // From The Sound Z80 | |
| 403 | ADDRESS_MAP_END | |
| 404 | static ADDRESS_MAP_START( bssoccer_pcm_2_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 405 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 397 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch3_r ) // From The Sound Z80 | |
| 406 | 398 | AM_RANGE(0x00, 0x01) AM_WRITE(bssoccer_DAC_2_w ) // 2 x DAC |
| 407 | 399 | AM_RANGE(0x03, 0x03) AM_WRITE(bssoccer_pcm_2_bankswitch_w ) // Rom Bank |
| 408 | 400 | ADDRESS_MAP_END |
| 409 | 401 | |
| 410 | 402 | |
| 411 | ||
| 412 | 403 | /*************************************************************************** |
| 413 | 404 | Ultra Balloon |
| 414 | 405 | ***************************************************************************/ |
| r3232 | r3233 | |
| 426 | 417 | /* Memory maps: Yes, *no* RAM */ |
| 427 | 418 | |
| 428 | 419 | static ADDRESS_MAP_START( uballoon_pcm_1_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| 429 | AM_RANGE(0x0000, 0x03ff) AM_READ(SMH_ROM | |
| 420 | AM_RANGE(0x0000, 0x03ff) AM_READ(SMH_ROM | |
| 430 | 421 | AM_RANGE(0x0400, 0xffff) AM_READ(SMH_BANK1 ) // Banked ROM |
| 431 | 422 | ADDRESS_MAP_END |
| 423 | ||
| 432 | 424 | static ADDRESS_MAP_START( uballoon_pcm_1_writemem, ADDRESS_SPACE_PROGRAM, 8 ) |
| 433 | AM_RANGE(0x0000, 0xffff) AM_WRITE(SMH_ROM | |
| 425 | AM_RANGE(0x0000, 0xffff) AM_WRITE(SMH_ROM | |
| 434 | 426 | ADDRESS_MAP_END |
| 435 | 427 | |
| 436 | ||
| 437 | static ADDRESS_MAP_START( uballoon_pcm_1_readport, ADDRESS_SPACE_IO, 8 ) | |
| 428 | static ADDRESS_MAP_START( uballoon_pcm_1_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 438 | 429 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 439 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch2_r ) // From The Sound Z80 | |
| 440 | ADDRESS_MAP_END | |
| 441 | static ADDRESS_MAP_START( uballoon_pcm_1_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 442 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 430 | AM_RANGE(0x00, 0x00) AM_READ(soundlatch2_r ) // From The Sound Z80 | |
| 443 | 431 | AM_RANGE(0x00, 0x01) AM_WRITE(bssoccer_DAC_1_w ) // 2 x DAC |
| 444 | 432 | AM_RANGE(0x03, 0x03) AM_WRITE(uballoon_pcm_1_bankswitch_w ) // Rom Bank |
| 445 | 433 | ADDRESS_MAP_END |
| 446 | 434 | |
| 447 | ||
| 448 | 435 | static MACHINE_RESET(uballoon) |
| 449 | 436 | { |
| 450 | 437 | uballoon_pcm_1_bankswitch_w(machine, 0, 0); |
| r3232 | r3233 | |
| 859 | 846 | |
| 860 | 847 | MDRV_CPU_ADD("pcm1", Z80, 5000000) /* Z80B */ |
| 861 | 848 | MDRV_CPU_PROGRAM_MAP(bssoccer_pcm_1_readmem,bssoccer_pcm_1_writemem) |
| 862 | MDRV_CPU_IO_MAP(bssoccer_pcm_1_ | |
| 849 | MDRV_CPU_IO_MAP(bssoccer_pcm_1_i | |
| 863 | 850 | |
| 864 | 851 | MDRV_CPU_ADD("pcm2", Z80, 5000000) /* Z80B */ |
| 865 | 852 | MDRV_CPU_PROGRAM_MAP(bssoccer_pcm_2_readmem,bssoccer_pcm_2_writemem) |
| 866 | MDRV_CPU_IO_MAP(bssoccer_pcm_2_ | |
| 853 | MDRV_CPU_IO_MAP(bssoccer_pcm_2_i | |
| 867 | 854 | |
| 868 | 855 | MDRV_INTERLEAVE(100) |
| 869 | 856 | |
| r3232 | r3233 | |
| 919 | 906 | |
| 920 | 907 | MDRV_CPU_ADD("pcm", Z80, 5000000) /* ? */ |
| 921 | 908 | MDRV_CPU_PROGRAM_MAP(uballoon_pcm_1_readmem,uballoon_pcm_1_writemem) |
| 922 | MDRV_CPU_IO_MAP(uballoon_pcm_1_ | |
| 909 | MDRV_CPU_IO_MAP(uballoon_pcm_1_i | |
| 923 | 910 | |
| 924 | 911 | /* 2nd PCM Z80 missing */ |
| 925 | 912 | |
| r3232 | r3233 | |
| 970 | 957 | |
| 971 | 958 | MDRV_CPU_ADD("pcm", Z80, 24000000/4) /* Z80B */ |
| 972 | 959 | MDRV_CPU_PROGRAM_MAP(bssoccer_pcm_1_readmem,bssoccer_pcm_1_writemem) |
| 973 | MDRV_CPU_IO_MAP(bssoccer_pcm_1_ | |
| 960 | MDRV_CPU_IO_MAP(bssoccer_pcm_1_i | |
| 974 | 961 | |
| 975 | 962 | /* 2nd PCM Z80 missing */ |
| 976 | 963 | |
| r3232 | r3233 | |
| 1345 | 1332 | GAME( 1994, sunaq, 0, sunaq, sunaq, 0, ROT0, "SunA", "SunA Quiz 6000 Academy (940620-6)", 0 ) // Date/Version on-screen is 940620-6, but in the program rom it's 1994,6,30 K.H.T V6.00 |
| 1346 | 1333 | GAME( 1996, bssoccer, 0, bssoccer, bssoccer, 0, ROT0, "SunA", "Back Street Soccer", 0 ) |
| 1347 | 1334 | GAME( 1996, uballoon, 0, uballoon, uballoon, uballoon, ROT0, "SunA", "Ultra Balloon", 0 ) |
| 1335 |
| r3232 | r3233 | |
|---|---|---|
| 78 | 78 | |
| 79 | 79 | static READ8_HANDLER( zaccaria_dsw_r ) |
| 80 | 80 | { |
| 81 | static const char *dswnames[] = { "IN0", "DSW0", "DSW1" }; | |
| 81 | static const char *const dswnames[] = { "IN0", "DSW0", "DSW1" }; | |
| 82 | 82 | |
| 83 | 83 | return input_port_read(machine, dswnames[dsw]); |
| 84 | 84 | } |
| r3232 | r3233 | |
|---|---|---|
| 9 | 9 | - As for some other M68000 Technos games (or games running on similar hardware |
| 10 | 10 | such as 'mugsmash'), the Inputs and the Dip Switches are mangled, so you need |
| 11 | 11 | a specific read handler so end-uers can see them in a "standard" order. |
| 12 | IMO you should set the USE_SHADFRCE_FAKE_INPUT_PORTS macro to 1. | |
| 13 | 12 | |
| 14 | 13 | 01-Sept-2008 - Pierpaolo Prazzoli |
| 15 | 14 | - Added irqs ack |
| r3232 | r3233 | |
| 188 | 187 | |
| 189 | 188 | */ |
| 190 | 189 | |
| 191 | #define USE_SHADFRCE_FAKE_INPUT_PORTS 1 | |
| 192 | 190 | |
| 193 | #if USE_SHADFRCE_FAKE_INPUT_PORTS | |
| 194 | ||
| 195 | 191 | static READ16_HANDLER( shadfrce_input_ports_r ) |
| 196 | 192 | { |
| 197 | 193 | UINT16 data = 0xffff; |
| r3232 | r3233 | |
| 215 | 211 | return (data); |
| 216 | 212 | } |
| 217 | 213 | |
| 218 | #else | |
| 219 | 214 | |
| 220 | static READ16_HANDLER( shadfrce_input_ports_3_r ) | |
| 221 | { | |
| 222 | return (input_port_read(machine, "IN3") & ~0x0400) | (vblank << 8); | |
| 223 | } | |
| 224 | ||
| 225 | #endif | |
| 226 | ||
| 227 | 215 | static WRITE16_HANDLER ( shadfrce_sound_brt_w ) |
| 228 | 216 | { |
| 229 | 217 | if (ACCESSING_BITS_8_15) |
| r3232 | r3233 | |
| 321 | 309 | AM_RANGE(0x1d0012, 0x1d0013) AM_WRITENOP /* ?? */ |
| 322 | 310 | AM_RANGE(0x1d0014, 0x1d0015) AM_WRITENOP /* ?? */ |
| 323 | 311 | AM_RANGE(0x1d0016, 0x1d0017) AM_WRITE(watchdog_reset16_w) |
| 324 | #if USE_SHADFRCE_FAKE_INPUT_PORTS | |
| 325 | 312 | AM_RANGE(0x1d0020, 0x1d0027) AM_READ(shadfrce_input_ports_r) |
| 326 | #else | |
| 327 | AM_RANGE(0x1d0020, 0x1d0021) AM_READ_PORT("IN0") | |
| 328 | AM_RANGE(0x1d0022, 0x1d0023) AM_READ_PORT("IN1") | |
| 329 | AM_RANGE(0x1d0024, 0x1d0025) AM_READ_PORT("IN2") | |
| 330 | AM_RANGE(0x1d0026, 0x1d0027) AM_READ(shadfrce_input_ports_3_r) | |
| 331 | #endif | |
| 332 | 313 | AM_RANGE(0x1f0000, 0x1fffff) AM_RAM |
| 333 | 314 | ADDRESS_MAP_END |
| 334 | 315 | |
| r3232 | r3233 | |
| 365 | 346 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, start ) |
| 366 | 347 | |
| 367 | 348 | |
| 368 | #if USE_SHADFRCE_FAKE_INPUT_PORTS | |
| 369 | 349 | static INPUT_PORTS_START( shadfrce ) |
| 370 | 350 | PORT_START("P1") /* Fake IN0 (player 1 inputs) */ |
| 371 | 351 | SHADFRCE_PLAYER_INPUT( 1, IPT_START1 ) |
| r3232 | r3233 | |
| 444 | 424 | PORT_DIPSETTING( 0x80, DEF_STR( Off ) ) |
| 445 | 425 | PORT_DIPSETTING( 0x00, DEF_STR( On ) ) |
| 446 | 426 | INPUT_PORTS_END |
| 447 | #else | |
| 448 | static INPUT_PORTS_START( shadfrce ) | |
| 449 | PORT_START("IN0") /* IN0 - $1d0020.w */ | |
| 450 | SHADFRCE_PLAYER_INPUT( 1, IPT_START1 ) | |
| 451 | PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 452 | PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_COIN2 ) /* only in "test mode" ? */ | |
| 453 | PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_SERVICE1 ) /* only in "test mode" ? */ | |
| 454 | PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 455 | PORT_DIPNAME( 0x1000, 0x1000, "Unused DIP 2-7" ) | |
| 456 | PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) | |
| 457 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 458 | PORT_DIPNAME( 0x2000, 0x2000, "Unused DIP 2-8" ) | |
| 459 | PORT_DIPSETTING( 0x2000, DEF_STR( Off ) ) | |
| 460 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 461 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 462 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 463 | 427 | |
| 464 | PORT_START("IN1") /* IN1 - $1d0022.w */ | |
| 465 | SHADFRCE_PLAYER_INPUT( 2, IPT_START2 ) | |
| 466 | PORT_DIPNAME( 0x0300, 0x0300, DEF_STR( Difficulty ) ) | |
| 467 | PORT_DIPSETTING( 0x0100, DEF_STR( Easy ) ) | |
| 468 | PORT_DIPSETTING( 0x0300, DEF_STR( Normal ) ) | |
| 469 | PORT_DIPSETTING( 0x0200, DEF_STR( Hard ) ) /* "Advanced" */ | |
| 470 | PORT_DIPSETTING( 0x0000, DEF_STR( Hardest ) ) /* "Expert" */ | |
| 471 | PORT_DIPNAME( 0x0c00, 0x0c00, "Stage Clear Energy Regain" ) | |
| 472 | PORT_DIPSETTING( 0x0400, "50%" ) | |
| 473 | PORT_DIPSETTING( 0x0c00, "25%" ) | |
| 474 | PORT_DIPSETTING( 0x0800, "10%" ) | |
| 475 | PORT_DIPSETTING( 0x0000, "0%" ) | |
| 476 | PORT_DIPNAME( 0x1000, 0x1000, "Unused DIP 2-5" ) | |
| 477 | PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) | |
| 478 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 479 | PORT_DIPNAME( 0x2000, 0x2000, "Unused DIP 2-6" ) | |
| 480 | PORT_DIPSETTING( 0x2000, DEF_STR( Off ) ) | |
| 481 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 482 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 483 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 484 | ||
| 485 | PORT_START("IN2") /* IN2 - $1d0024.w */ | |
| 486 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_PLAYER(1) | |
| 487 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_PLAYER(1) | |
| 488 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_PLAYER(1) | |
| 489 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_PLAYER(2) | |
| 490 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_PLAYER(2) | |
| 491 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_PLAYER(2) | |
| 492 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 493 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 494 | PORT_DIPNAME( 0x0100, 0x0100, "Unused DIP 1-1" ) | |
| 495 | PORT_DIPSETTING( 0x0100, DEF_STR( Off ) ) | |
| 496 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 497 | PORT_DIPNAME( 0x0600, 0x0600, DEF_STR( Coinage ) ) | |
| 498 | PORT_DIPSETTING( 0x0000, DEF_STR( 3C_1C ) ) | |
| 499 | PORT_DIPSETTING( 0x0200, DEF_STR( 2C_1C ) ) | |
| 500 | PORT_DIPSETTING( 0x0600, DEF_STR( 1C_1C ) ) | |
| 501 | PORT_DIPSETTING( 0x0400, DEF_STR( 1C_2C ) ) | |
| 502 | PORT_DIPNAME( 0x0800, 0x0800, DEF_STR( Continue_Price ) ) | |
| 503 | PORT_DIPSETTING( 0x0800, DEF_STR( Off ) ) | |
| 504 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 505 | PORT_DIPNAME( 0x1000, 0x1000, DEF_STR( Free_Play ) ) | |
| 506 | PORT_DIPSETTING( 0x1000, DEF_STR( Off ) ) | |
| 507 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 508 | PORT_DIPNAME( 0x2000, 0x2000, DEF_STR( Flip_Screen ) ) | |
| 509 | PORT_DIPSETTING( 0x2000, DEF_STR( Off ) ) | |
| 510 | PORT_DIPSETTING( 0x0000, DEF_STR( On ) ) | |
| 511 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 512 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 513 | ||
| 514 | PORT_START("IN3") /* IN3 - $1d0026.w */ | |
| 515 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 516 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 517 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 518 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 519 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 520 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 521 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 522 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 523 | PORT_DIPNAME( 0x0100, 0x0100, DEF_STR( Demo_Sounds ) ) | |
| 524 | PORT_DIPSETTING( 0x0000, DEF_STR( Off ) ) | |
| 525 | PORT_DIPSETTING( 0x0100, DEF_STR( On ) ) | |
| 526 | PORT_SERVICE( 0x0200, IP_ACTIVE_LOW ) | |
| 527 | PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_SPECIAL ) /* guess */ | |
| 528 | PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_VBLANK ) /* guess */ | |
| 529 | PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 530 | PORT_BIT( 0x1000, IP_ACTIVE_LOW, IPT_UNKNOWN ) /* must be ACTIVE_LOW or 'shadfrcj' jumps to the end (code at 0x04902e) */ | |
| 531 | PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 532 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 533 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNUSED ) | |
| 534 | INPUT_PORTS_END | |
| 535 | #endif | |
| 536 | ||
| 537 | 428 | /* Graphic Decoding */ |
| 538 | 429 | |
| 539 | 430 | static const gfx_layout fg8x8x4_layout = |
| r3232 | r3233 | |
|---|---|---|
| 57 | 57 | #include "sound/ay8910.h" |
| 58 | 58 | |
| 59 | 59 | static tilemap *bg_tilemap; |
| 60 | static UINT8 mux_data; | |
| 61 | static int bank; | |
| 62 | static UINT8 *cus_ram; | |
| 63 | static UINT8 prot_lock; | |
| 60 | 64 | |
| 65 | ||
| 66 | ||
| 61 | 67 | static TILE_GET_INFO( y_get_bg_tile_info ) |
| 62 | 68 | { |
| 63 | 69 | int code = videoram[tile_index]; |
| r3232 | r3233 | |
| 114 | 120 | tilemap_mark_tile_dirty(bg_tilemap,offset); |
| 115 | 121 | } |
| 116 | 122 | |
| 117 | static UINT8 *cus_ram; | |
| 118 | static UINT8 prot_lock; | |
| 119 | ||
| 120 | 123 | /*Custom RAM (Protection)*/ |
| 121 | 124 | static READ8_HANDLER( custom_ram_r ) |
| 122 | 125 | { |
| r3232 | r3233 | |
| 155 | 158 | return ((~eeprom_read_bit() & 0x01)<<6) | (0xff & ~0x40); |
| 156 | 159 | } |
| 157 | 160 | |
| 158 | static UINT8 mux_data; | |
| 159 | ||
| 160 | 161 | static READ8_HANDLER( mux_r ) |
| 161 | 162 | { |
| 162 | 163 | switch(mux_data) |
| r3232 | r3233 | |
| 175 | 176 | |
| 176 | 177 | static WRITE8_HANDLER( mux_w ) |
| 177 | 178 | { |
| 178 | static int bank=-1; | |
| 179 | ||
| 180 | 179 | int new_bank = (data&0xc0)>>6; |
| 181 | 180 | |
| 182 | 181 | //0x10000 service mode |
| r3232 | r3233 | |
| 220 | 219 | AM_RANGE(0xc0, 0xc0) AM_WRITE(port_c0_w) /*watchdog write?*/ |
| 221 | 220 | ADDRESS_MAP_END |
| 222 | 221 | |
| 222 | static MACHINE_RESET( yumefuda ) | |
| 223 | { | |
| 224 | mux_data = 0; | |
| 225 | bank = -1; | |
| 226 | prot_lock = 0; | |
| 227 | } | |
| 228 | ||
| 223 | 229 | static MACHINE_DRIVER_START( yumefuda ) |
| 224 | 230 | |
| 225 | 231 | /* basic machine hardware */ |
| r3232 | r3233 | |
| 228 | 234 | MDRV_CPU_IO_MAP(port_map,0) |
| 229 | 235 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 230 | 236 | |
| 237 | MDRV_MACHINE_RESET(yumefuda) | |
| 231 | 238 | MDRV_NVRAM_HANDLER(93C46) |
| 232 | 239 | |
| 233 | 240 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 1481 | 1481 | static TIMER_CALLBACK( keyboard_timer_callback ) |
| 1482 | 1482 | { |
| 1483 | 1483 | static const int kb_uart_channel[2] = { 1, 0 }; |
| 1484 | static const char *keynames[] = { "KEYBOARD_P1", "KEYBOARD_P2" }; | |
| 1484 | static const char *const keynames[] = { "KEYBOARD_P1", "KEYBOARD_P2" }; | |
| 1485 | 1485 | int keyboard; |
| 1486 | 1486 | int i; |
| 1487 | 1487 |
| r3232 | r3233 | |
|---|---|---|
| 423 | 423 | |
| 424 | 424 | static READ16_HANDLER( adc_r ) |
| 425 | 425 | { |
| 426 | static const char *adcnames[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 426 | static const char *const adcnames[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 427 | 427 | |
| 428 | 428 | if (which_adc < pedal_count) |
| 429 | 429 | return ~input_port_read(machine, adcnames[which_adc]); |
| r3232 | r3233 | |
| 434 | 434 | |
| 435 | 435 | static READ8_HANDLER( leta_r ) |
| 436 | 436 | { |
| 437 | static const char *letanames[] = { "LETA0", "LETA1", "LETA2", "LETA3" }; | |
| 437 | static const char *const letanames[] = { "LETA0", "LETA1", "LETA2", "LETA3" }; | |
| 438 | 438 | |
| 439 | 439 | if (pedal_count == -1) /* 720 */ |
| 440 | 440 | { |
| r3232 | r3233 | |
|---|---|---|
| 134 | 134 | static READ8_HANDLER( mjsister_keys_r ) |
| 135 | 135 | { |
| 136 | 136 | int p,i,ret = 0; |
| 137 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5" }; | |
| 137 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5" }; | |
| 138 | 138 | |
| 139 | 139 | p = mjsister_input_sel1 & 0x3f; |
| 140 | 140 | // p |= ((mjsister_input_sel2 & 8) << 4) | ((mjsister_input_sel2 & 0x20) << 1); |
| r3232 | r3233 | |
|---|---|---|
| 971 | 971 | MDRV_SOUND_ROUTE(2, "mono", 0.10) |
| 972 | 972 | MDRV_SOUND_ROUTE(3, "mono", 0.50) |
| 973 | 973 | |
| 974 | MDRV_SOUND_ADD(" | |
| 974 | MDRV_SOUND_ADD("pcm", SAMPLES, 0) | |
| 975 | 975 | MDRV_SOUND_CONFIG(ninjakd2_samples_interface) |
| 976 | 976 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.80) |
| 977 | 977 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 988 | 988 | MDRV_VIDEO_START(mnight) |
| 989 | 989 | |
| 990 | 990 | /* sound hardware */ |
| 991 | MDRV_SOUND_REMOVE(" | |
| 991 | MDRV_SOUND_REMOVE("pcm") | |
| 992 | 992 | MACHINE_DRIVER_END |
| 993 | 993 | |
| 994 | 994 | static MACHINE_DRIVER_START( robokid ) |
| r3232 | r3233 | |
|---|---|---|
| 144 | 144 | static READ8_HANDLER( geebee_in_r ) |
| 145 | 145 | { |
| 146 | 146 | int res; |
| 147 | static const char *portnames[] = { "SW0", "SW1", "DSW2", "PLACEHOLDER" }; // "IN1" & "IN2" are read separately when offset==3 | |
| 147 | static const char *const portnames[] = { "SW0", "SW1", "DSW2", "PLACEHOLDER" }; // "IN1" & "IN2" are read separately when offset==3 | |
| 148 | 148 | |
| 149 | 149 | offset &= 3; |
| 150 | 150 | res = input_port_read_safe(machine, portnames[offset], 0); |
| r3232 | r3233 | |
|---|---|---|
| 280 | 280 | ADDRESS_MAP_END |
| 281 | 281 | |
| 282 | 282 | |
| 283 | static ADDRESS_MAP_START( | |
| 283 | static ADDRESS_MAP_START( | |
| 284 | 284 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 285 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") | |
| 286 | AM_RANGE(0x01, 0x01) AM_READ(ojankohs_keymatrix_r) | |
| 287 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN1") | |
| 288 | AM_RANGE(0x06, 0x06) AM_READ(ay8910_read_port_0_r) | |
| 289 | ADDRESS_MAP_END | |
| 290 | ||
| 291 | static ADDRESS_MAP_START( writeport_ojankohs, ADDRESS_SPACE_IO, 8 ) | |
| 292 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 293 | AM_RANGE(0x00, 0x00) AM_WRITE(ojankohs_portselect_w) | |
| 294 | AM_RANGE(0x01, 0x01) AM_WRITE(ojankohs_rombank_w) | |
| 295 | AM_RANGE(0x02, 0x02) AM_WRITE(ojankohs_gfxreg_w) | |
| 285 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") AM_WRITE(ojankohs_portselect_w) | |
| 286 | AM_RANGE(0x01, 0x01) AM_READWRITE(ojankohs_keymatrix_r, ojankohs_rombank_w) | |
| 287 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN1") AM_WRITE(ojankohs_gfxreg_w) | |
| 296 | 288 | AM_RANGE(0x03, 0x03) AM_WRITE(ojankohs_adpcm_reset_w) |
| 297 | 289 | AM_RANGE(0x04, 0x04) AM_WRITE(ojankohs_flipscreen_w) |
| 298 | 290 | AM_RANGE(0x05, 0x05) AM_WRITE(ojankohs_msm5205_w) |
| 299 | AM_RANGE(0x06, 0x06) AM_WRITE(ay8910_write_port_0_w) | |
| 291 | AM_RANGE(0x06, 0x06) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 300 | 292 | AM_RANGE(0x07, 0x07) AM_WRITE(ay8910_control_port_0_w) |
| 301 | 293 | AM_RANGE(0x10, 0x10) AM_WRITE(SMH_NOP) // unknown |
| 302 | 294 | AM_RANGE(0x11, 0x11) AM_WRITE(SMH_NOP) // unknown |
| 303 | 295 | ADDRESS_MAP_END |
| 304 | 296 | |
| 305 | static ADDRESS_MAP_START( | |
| 297 | static ADDRESS_MAP_START( | |
| 306 | 298 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 307 | AM_RANGE(0x00, 0x00) AM_WRITE(ojankohs_portselect_w) | |
| 308 | AM_RANGE(0x01, 0x01) AM_WRITE(ojankoy_rombank_w) | |
| 309 | AM_RANGE(0x02, 0x02) AM_WRITE(ojankoy_coinctr_w) | |
| 299 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") AM_WRITE(ojankohs_portselect_w) | |
| 300 | AM_RANGE(0x01, 0x01) AM_READWRITE(ojankohs_keymatrix_r, ojankoy_rombank_w) | |
| 301 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN1") AM_WRITE(ojankoy_coinctr_w) | |
| 310 | 302 | AM_RANGE(0x04, 0x04) AM_WRITE(ojankohs_flipscreen_w) |
| 311 | 303 | AM_RANGE(0x05, 0x05) AM_WRITE(ojankohs_msm5205_w) |
| 312 | AM_RANGE(0x06, 0x06) AM_WRITE(ay8910_write_port_0_w) | |
| 304 | AM_RANGE(0x06, 0x06) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 313 | 305 | AM_RANGE(0x07, 0x07) AM_WRITE(ay8910_control_port_0_w) |
| 314 | 306 | ADDRESS_MAP_END |
| 315 | 307 | |
| 316 | static ADDRESS_MAP_START( | |
| 308 | static ADDRESS_MAP_START( | |
| 317 | 309 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 318 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") | |
| 319 | AM_RANGE(0x01, 0x01) AM_READ(ojankohs_keymatrix_r) | |
| 320 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN1") | |
| 321 | AM_RANGE(0x03, 0x03) AM_READ(ccasino_dipsw3_r) | |
| 322 | AM_RANGE(0x04, 0x04) AM_READ(ccasino_dipsw4_r) | |
| 323 | AM_RANGE(0x06, 0x06) AM_READ(ay8910_read_port_0_r) | |
| 324 | ADDRESS_MAP_END | |
| 325 | ||
| 326 | static ADDRESS_MAP_START( writeport_ccasino, ADDRESS_SPACE_IO, 8 ) | |
| 327 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 328 | AM_RANGE(0x00, 0x00) AM_WRITE(ojankohs_portselect_w) | |
| 329 | AM_RANGE(0x01, 0x01) AM_WRITE(ojankohs_rombank_w) | |
| 330 | AM_RANGE(0x02, 0x02) AM_WRITE(ccasino_coinctr_w) | |
| 331 | AM_RANGE(0x03, 0x03) AM_WRITE(ojankohs_adpcm_reset_w) | |
| 332 | AM_RANGE(0x04, 0x04) AM_WRITE(ojankohs_flipscreen_w) | |
| 310 | AM_RANGE(0x00, 0x00) AM_READ_PORT("IN0") AM_WRITE(ojankohs_portselect_w) | |
| 311 | AM_RANGE(0x01, 0x01) AM_READWRITE(ojankohs_keymatrix_r, ojankohs_rombank_w) | |
| 312 | AM_RANGE(0x02, 0x02) AM_READ_PORT("IN1") AM_WRITE(ccasino_coinctr_w) | |
| 313 | AM_RANGE(0x03, 0x03) AM_READWRITE(ccasino_dipsw3_r, ojankohs_adpcm_reset_w) | |
| 314 | AM_RANGE(0x04, 0x04) AM_READWRITE(ccasino_dipsw4_r, ojankohs_flipscreen_w) | |
| 333 | 315 | AM_RANGE(0x05, 0x05) AM_WRITE(ojankohs_msm5205_w) |
| 334 | AM_RANGE(0x06, 0x06) AM_WRITE(ay8910_write_port_0_w) | |
| 316 | AM_RANGE(0x06, 0x06) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 335 | 317 | AM_RANGE(0x07, 0x07) AM_WRITE(ay8910_control_port_0_w) |
| 336 | 318 | AM_RANGE(0x08, 0x0f) AM_WRITE(ccasino_palette_w) // 16bit address access |
| 337 | 319 | AM_RANGE(0x10, 0x10) AM_WRITE(SMH_NOP) |
| 338 | 320 | AM_RANGE(0x11, 0x11) AM_WRITE(SMH_NOP) |
| 339 | 321 | ADDRESS_MAP_END |
| 340 | 322 | |
| 341 | static ADDRESS_MAP_START( | |
| 323 | static ADDRESS_MAP_START( | |
| 342 | 324 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 343 | AM_RANGE(0xfc, 0xfd) AM_READ(ojankoc_keymatrix_r) | |
| 344 | AM_RANGE(0xff, 0xff) AM_READ(ay8910_read_port_0_r) | |
| 345 | ADDRESS_MAP_END | |
| 346 | ||
| 347 | static ADDRESS_MAP_START( writeport_ojankoc, ADDRESS_SPACE_IO, 8 ) | |
| 348 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 349 | 325 | AM_RANGE(0x00, 0x1f) AM_WRITE(ojankoc_palette_w) |
| 350 | 326 | AM_RANGE(0xf9, 0xf9) AM_WRITE(ojankohs_msm5205_w) |
| 351 | 327 | AM_RANGE(0xfb, 0xfb) AM_WRITE(ojankoc_ctrl_w) |
| 328 | AM_RANGE(0xfc, 0xfd) AM_READ(ojankoc_keymatrix_r) | |
| 352 | 329 | AM_RANGE(0xfd, 0xfd) AM_WRITE(ojankohs_portselect_w) |
| 353 | 330 | AM_RANGE(0xfe, 0xfe) AM_WRITE(ay8910_write_port_0_w) |
| 354 | AM_RANGE(0xff, 0xff) AM_WRITE(ay8910_control_port_0_w) | |
| 331 | AM_RANGE(0xff, 0xff) AM_READWRITE(ay8910_read_port_0_r, ay8910_control_port_0_w) | |
| 355 | 332 | ADDRESS_MAP_END |
| 356 | 333 | |
| 334 | ||
| 357 | 335 | static INPUT_PORTS_START( mahjong_p1 ) |
| 358 | 336 | PORT_START("KEY0") /* PORT 1-0 */ |
| 359 | 337 | PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_MAHJONG_A ) |
| r3232 | r3233 | |
| 876 | 854 | /* basic machine hardware */ |
| 877 | 855 | MDRV_CPU_ADD("main", Z80,12000000/2) /* 6.00 MHz ? */ |
| 878 | 856 | MDRV_CPU_PROGRAM_MAP(readmem_ojankohs,writemem_ojankohs) |
| 879 | MDRV_CPU_IO_MAP( | |
| 857 | MDRV_CPU_IO_MAP( | |
| 880 | 858 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 881 | 859 | |
| 882 | 860 | MDRV_MACHINE_RESET(ojankohs) |
| r3232 | r3233 | |
| 913 | 891 | /* basic machine hardware */ |
| 914 | 892 | MDRV_CPU_ADD("main", Z80,12000000/2) /* 6.00 MHz ? */ |
| 915 | 893 | MDRV_CPU_PROGRAM_MAP(readmem_ojankoy,writemem_ojankoy) |
| 916 | MDRV_CPU_IO_MAP( | |
| 894 | MDRV_CPU_IO_MAP( | |
| 917 | 895 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 918 | 896 | |
| 919 | 897 | MDRV_MACHINE_RESET(ojankohs) |
| r3232 | r3233 | |
| 951 | 929 | /* basic machine hardware */ |
| 952 | 930 | MDRV_CPU_ADD("main", Z80,12000000/2) /* 6.00 MHz ? */ |
| 953 | 931 | MDRV_CPU_PROGRAM_MAP(readmem_ojankoy,writemem_ojankoy) |
| 954 | MDRV_CPU_IO_MAP( | |
| 932 | MDRV_CPU_IO_MAP( | |
| 955 | 933 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 956 | 934 | |
| 957 | 935 | MDRV_MACHINE_RESET(ojankohs) |
| r3232 | r3233 | |
| 988 | 966 | /* basic machine hardware */ |
| 989 | 967 | MDRV_CPU_ADD("main", Z80,8000000/2) /* 4.00 MHz */ |
| 990 | 968 | MDRV_CPU_PROGRAM_MAP(readmem_ojankoc,writemem_ojankoc) |
| 991 | MDRV_CPU_IO_MAP( | |
| 969 | MDRV_CPU_IO_MAP( | |
| 992 | 970 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 993 | 971 | |
| 994 | 972 | MDRV_MACHINE_RESET(ojankohs) |
| r3232 | r3233 | |
|---|---|---|
| 1966 | 1966 | |
| 1967 | 1967 | static READ16_HANDLER( zombraid_gun_r ) // Serial interface |
| 1968 | 1968 | { |
| 1969 | static const char *portnames[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2" }; | |
| 1969 | static const char *const portnames[] = { "GUNX1", "GUNY1", "GUNX2", "GUNY2" }; | |
| 1970 | 1970 | |
| 1971 | 1971 | int data = input_port_read(machine, portnames[gun_input_src]); // Input Ports 5-8 |
| 1972 | 1972 | return (data >> gun_input_bit) & 1; |
| r3232 | r3233 | |
| 2604 | 2604 | { |
| 2605 | 2605 | int row_select = kiwame_nvram_r( machine,0x10a/2,0x00ff ) & 0x1f; |
| 2606 | 2606 | int i; |
| 2607 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 2607 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 2608 | 2608 | |
| 2609 | 2609 | for(i = 0; i < 5; i++) |
| 2610 | 2610 | if (row_select & (1<<i)) break; |
| r3232 | r3233 | |
|---|---|---|
| 89 | 89 | |
| 90 | 90 | static READ8_HANDLER( laserbat_input_r ) |
| 91 | 91 | { |
| 92 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 92 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 93 | 93 | |
| 94 | 94 | return input_port_read(machine, portnames[laserbat_input_mux]); |
| 95 | 95 | } |
| r3232 | r3233 | |
|---|---|---|
| 511 | 511 | AM_RANGE(0xe000, 0xffff) AM_RAM |
| 512 | 512 | ADDRESS_MAP_END |
| 513 | 513 | |
| 514 | static ADDRESS_MAP_START( tnzsb_ | |
| 514 | static ADDRESS_MAP_START( tnzsb_io_ma | |
| 515 | 515 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 516 | AM_RANGE(0x00, 0x00) AM_READ(ym2203_status_port_0_r) | |
| 516 | AM_RANGE(0x00, 0x00) AM_READWRITE(ym2203_status_port_0_r, ym2203_control_port_0_w) | |
| 517 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2203_write_port_0_w) | |
| 517 | 518 | AM_RANGE(0x02, 0x02) AM_READ(soundlatch_r) |
| 518 | 519 | ADDRESS_MAP_END |
| 519 | 520 | |
| 520 | static ADDRESS_MAP_START( tnzsb_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 521 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 522 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2203_control_port_0_w) | |
| 523 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2203_write_port_0_w) | |
| 524 | ADDRESS_MAP_END | |
| 525 | 521 | |
| 526 | ||
| 527 | 522 | static ADDRESS_MAP_START( i8742_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| 528 | 523 | AM_RANGE(0x0000, 0x07ff) AM_READ(SMH_ROM) |
| 529 | 524 | AM_RANGE(0x0800, 0x08ff) AM_RAM /* Internal i8742 RAM */ |
| r3232 | r3233 | |
| 534 | 529 | AM_RANGE(0x0800, 0x08ff) AM_WRITE(SMH_RAM) /* Internal i8742 RAM */ |
| 535 | 530 | ADDRESS_MAP_END |
| 536 | 531 | |
| 537 | static ADDRESS_MAP_START( i8742_readport, ADDRESS_SPACE_IO, 8 ) | |
| 532 | static ADDRESS_MAP_START( i8742_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 533 | AM_RANGE(0x02, 0x02) AM_WRITE(tnzs_port2_w) | |
| 538 | 534 | AM_RANGE(I8X41_p1, I8X41_p1) AM_READ(tnzs_port1_r) |
| 539 | 535 | AM_RANGE(I8X41_p2, I8X41_p2) AM_READ(tnzs_port2_r) |
| 540 | 536 | AM_RANGE(I8X41_t0, I8X41_t0) AM_READ_PORT("COIN1") |
| 541 | 537 | AM_RANGE(I8X41_t1, I8X41_t1) AM_READ_PORT("COIN2") |
| 542 | 538 | ADDRESS_MAP_END |
| 543 | 539 | |
| 544 | static ADDRESS_MAP_START( i8742_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 545 | AM_RANGE(0x02, 0x02) AM_WRITE(tnzs_port2_w) | |
| 546 | ADDRESS_MAP_END | |
| 547 | 540 | |
| 548 | ||
| 549 | 541 | static WRITE8_HANDLER( jpopnics_palette_w ) |
| 550 | 542 | { |
| 551 | 543 | int r,g,b; |
| r3232 | r3233 | |
| 1471 | 1463 | |
| 1472 | 1464 | MDRV_CPU_ADD("mcu", I8X41,12000000/2) /* 400KHz ??? - Main board Crystal is 12MHz */ |
| 1473 | 1465 | MDRV_CPU_PROGRAM_MAP(i8742_readmem,i8742_writemem) |
| 1474 | MDRV_CPU_IO_MAP(i8742_ | |
| 1466 | MDRV_CPU_IO_MAP(i8742_ | |
| 1475 | 1467 | MDRV_CPU_CONFIG( i8042_config ) |
| 1476 | 1468 | |
| 1477 | 1469 | MDRV_INTERLEAVE(100) |
| r3232 | r3233 | |
| 1597 | 1589 | |
| 1598 | 1590 | MDRV_CPU_ADD("audio", Z80, XTAL_12MHz/2) /* verified on pcb */ |
| 1599 | 1591 | MDRV_CPU_PROGRAM_MAP(tnzsb_cpu2_map,0) |
| 1600 | MDRV_CPU_IO_MAP(tnzsb_ | |
| 1592 | MDRV_CPU_IO_MAP(tnzsb_i | |
| 1601 | 1593 | |
| 1602 | 1594 | MDRV_INTERLEAVE(100) |
| 1603 | 1595 | |
| r3232 | r3233 | |
| 2215 | 2207 | All ROMs are 27010 (DIP32) |
| 2216 | 2208 | */ |
| 2217 | 2209 | |
| 2210 | /* tnzs - new style PCB sets */ | |
| 2211 | ||
| 2218 | 2212 | ROM_START( tnzs ) |
| 2219 | 2213 | ROM_REGION( 0x30000, "main", 0 ) /* 64k + bankswitch areas for the first CPU */ |
| 2220 | 2214 | ROM_LOAD( "b53-24.1", 0x00000, 0x08000, CRC(d66824c6) SHA1(fd381ac0dc52ce670c3fde320ea60a209e288a52) ) |
| r3232 | r3233 | |
| 2227 | 2221 | ROM_REGION( 0x10000, "audio", 0 ) /* 64k for the third CPU */ |
| 2228 | 2222 | ROM_LOAD( "b53-26.34", 0x00000, 0x10000, CRC(cfd5649c) SHA1(4f6afccd535d39b41661dc3ccd17af125bfac015) ) |
| 2229 | 2223 | |
| 2230 | ROM_REGION( 0x100000, "gfx1", ROMREGION_DISPOSE ) | |
| 2231 | ROM_LOAD( "b53-08.8", 0x00000, 0x20000, CRC(c3519c2a) SHA1(30fe7946fbc95ab6b3ccb6944fb24bf47bf3d743) ) // b53-16 | |
| 2232 | ROM_LOAD( "b53-07.7", 0x20000, 0x20000, CRC(2bf199e8) SHA1(4ed73e4f00ae2f5f4028a0ea5ae3cd238863a370) ) // b53-17 | |
| 2233 | ROM_LOAD( "b53-06.6", 0x40000, 0x20000, CRC(92f35ed9) SHA1(5fdd8d6ddbb7be9887af3c8dea9ad3b58c4e86f9) ) // b53-18 | |
| 2234 | ROM_LOAD( "b53-05.5", 0x60000, 0x20000, CRC(edbb9581) SHA1(539396a01ca0b69455f000d446759b232530b542) ) // b53-19 | |
| 2235 | ROM_LOAD( "b53-04.4", 0x80000, 0x20000, CRC(59d2aef6) SHA1(b657b7603c3eb5f169000d38497ebb93f26f7832) ) // b53-22 | |
| 2236 | ROM_LOAD( "b53-03.3", 0xa0000, 0x20000, CRC(74acfb9b) SHA1(90b544ed7ede7565660bdd13c94c15c54423cda9) ) // b53-23 | |
| 2237 | ROM_LOAD( "b53-02.2", 0xc0000, 0x20000, CRC(095d0dc0) SHA1(ced2937d0594fa00ae344a4e3a3cba23772dc160) ) // b53-20 | |
| 2238 | ROM_LOAD( "b53-01.1", 0xe0000, 0x20000, CRC(9800c54d) SHA1(761647177d621ac2cdd8b009876eed35809f3c92) ) // b53-21 | |
| 2224 | ROM_REGION( 0x100000, "gfx1", ROMREGION_DISPOSE ) /* the newer PCBs have updated GFX rom labels, content is the same */ | |
| 2225 | ROM_LOAD( "b53-16.8", 0x00000, 0x20000, CRC(c3519c2a) SHA1(30fe7946fbc95ab6b3ccb6944fb24bf47bf3d743) ) | |
| 2226 | ROM_LOAD( "b53-17.7", 0x20000, 0x20000, CRC(2bf199e8) SHA1(4ed73e4f00ae2f5f4028a0ea5ae3cd238863a370) ) | |
| 2227 | ROM_LOAD( "b53-18.6", 0x40000, 0x20000, CRC(92f35ed9) SHA1(5fdd8d6ddbb7be9887af3c8dea9ad3b58c4e86f9) ) | |
| 2228 | ROM_LOAD( "b53-19.5", 0x60000, 0x20000, CRC(edbb9581) SHA1(539396a01ca0b69455f000d446759b232530b542) ) | |
| 2229 | ROM_LOAD( "b53-22.4", 0x80000, 0x20000, CRC(59d2aef6) SHA1(b657b7603c3eb5f169000d38497ebb93f26f7832) ) | |
| 2230 | ROM_LOAD( "b53-23.3", 0xa0000, 0x20000, CRC(74acfb9b) SHA1(90b544ed7ede7565660bdd13c94c15c54423cda9) ) | |
| 2231 | ROM_LOAD( "b53-20.2", 0xc0000, 0x20000, CRC(095d0dc0) SHA1(ced2937d0594fa00ae344a4e3a3cba23772dc160) ) | |
| 2232 | ROM_LOAD( "b53-21.1", 0xe0000, 0x20000, CRC(9800c54d) SHA1(761647177d621ac2cdd8b009876eed35809f3c92) ) | |
| 2239 | 2233 | ROM_END |
| 2240 | 2234 | |
| 2235 | ROM_START( tnzsjn ) | |
| 2236 | ROM_REGION( 0x30000, "main", 0 ) /* 64k + bankswitch areas for the first CPU */ | |
| 2237 | ROM_LOAD( "b53-24.1", 0x00000, 0x08000, CRC(d66824c6) SHA1(fd381ac0dc52ce670c3fde320ea60a209e288a52) ) | |
| 2238 | ROM_CONTINUE( 0x18000, 0x18000 ) /* banked at 8000-bfff */ | |
| 2239 | ||
| 2240 | ROM_REGION( 0x18000, "sub", 0 ) /* 64k for the second CPU */ | |
| 2241 | ROM_LOAD( "b53-27.u3", 0x00000, 0x08000, CRC(b3415fc3) SHA1(a12b1788509e2ac2b05a083f432eecdce00769f6) ) | |
| 2242 | ROM_CONTINUE( 0x10000, 0x08000 ) /* banked at 8000-9fff */ | |
| 2243 | ||
| 2244 | ROM_REGION( 0x10000, "audio", 0 ) /* 64k for the third CPU */ | |
| 2245 | ROM_LOAD( "b53-26.34", 0x00000, 0x10000, CRC(cfd5649c) SHA1(4f6afccd535d39b41661dc3ccd17af125bfac015) ) | |
| 2246 | ||
| 2247 | ROM_REGION( 0x100000, "gfx1", ROMREGION_DISPOSE ) /* the newer PCBs have updated GFX rom labels, content is the same */ | |
| 2248 | ROM_LOAD( "b53-16.8", 0x00000, 0x20000, CRC(c3519c2a) SHA1(30fe7946fbc95ab6b3ccb6944fb24bf47bf3d743) ) | |
| 2249 | ROM_LOAD( "b53-17.7", 0x20000, 0x20000, CRC(2bf199e8) SHA1(4ed73e4f00ae2f5f4028a0ea5ae3cd238863a370) ) | |
| 2250 | ROM_LOAD( "b53-18.6", 0x40000, 0x20000, CRC(92f35ed9) SHA1(5fdd8d6ddbb7be9887af3c8dea9ad3b58c4e86f9) ) | |
| 2251 | ROM_LOAD( "b53-19.5", 0x60000, 0x20000, CRC(edbb9581) SHA1(539396a01ca0b69455f000d446759b232530b542) ) | |
| 2252 | ROM_LOAD( "b53-22.4", 0x80000, 0x20000, CRC(59d2aef6) SHA1(b657b7603c3eb5f169000d38497ebb93f26f7832) ) | |
| 2253 | ROM_LOAD( "b53-23.3", 0xa0000, 0x20000, CRC(74acfb9b) SHA1(90b544ed7ede7565660bdd13c94c15c54423cda9) ) | |
| 2254 | ROM_LOAD( "b53-20.2", 0xc0000, 0x20000, CRC(095d0dc0) SHA1(ced2937d0594fa00ae344a4e3a3cba23772dc160) ) | |
| 2255 | ROM_LOAD( "b53-21.1", 0xe0000, 0x20000, CRC(9800c54d) SHA1(761647177d621ac2cdd8b009876eed35809f3c92) ) | |
| 2256 | ROM_END | |
| 2257 | ||
| 2258 | /* tnzs - old style PCB sets */ | |
| 2259 | ||
| 2241 | 2260 | ROM_START( tnzsj ) |
| 2242 | 2261 | ROM_REGION( 0x30000, "main", 0 ) /* 64k + bankswitch areas for the first CPU */ |
| 2243 | 2262 | ROM_LOAD( "b53-10.32", 0x00000, 0x08000, CRC(a73745c6) SHA1(73eb38e75e08312d752332f988dc655084b4a86d) ) |
| r3232 | r3233 | |
| 2401 | 2420 | GAME( 1988, chukatai, 0, tnzs, chukatai, chukatai, ROT0, "Taito Corporation Japan", "Chuka Taisen (World)", 0 ) /* Possible region hack */ |
| 2402 | 2421 | GAME( 1988, chukatau, chukatai, tnzs, chukatau, chukatai, ROT0, "Taito America Corporation", "Chuka Taisen (US)", 0 ) /* Possible region hack */ |
| 2403 | 2422 | GAME( 1988, chukataj, chukatai, tnzs, chukatau, chukatai, ROT0, "Taito Corporation", "Chuka Taisen (Japan)", 0 ) |
| 2404 | GAME( 1988, tnzs, 0, tnzsb, tnzsb, tnzsb, ROT0, "Taito Corporation Japan", "The NewZealand Story (World, newer)", 0 ) | |
| 2405 | GAME( 1988, tnzsj, tnzs, tnzs, tnzs, tnzs, ROT0, "Taito Corporation", "The NewZealand Story (Japan)", 0 ) | |
| 2406 | GAME( 1988, tnzso, tnzs, tnzs, tnzs2, tnzs, ROT0, "Taito Corporation Japan", "The NewZealand Story (World, older)", 0 ) | |
| 2423 | GAME( 1988, tnzs, 0, tnzsb, tnzsb, tnzsb, ROT0, "Taito Corporation Japan", "The NewZealand Story (World, newer) (newer PCB)", 0 ) | |
| 2424 | GAME( 1988, tnzsjn, tnzs, tnzsb, tnzsb, tnzsb, ROT0, "Taito Corporation", "The NewZealand Story (Japan) (newer PCB)", 0 ) | |
| 2425 | GAME( 1988, tnzsj, tnzs, tnzs, tnzs, tnzs, ROT0, "Taito Corporation", "The NewZealand Story (Japan) (older PCB)", 0 ) | |
| 2426 | GAME( 1988, tnzso, tnzs, tnzs, tnzs2, tnzs, ROT0, "Taito Corporation Japan", "The NewZealand Story (World, older) (older PCB)", 0 ) | |
| 2407 | 2427 | GAME( 1988, kabukiz, 0, kabukiz, kabukiz, kabukiz, ROT0, "Taito Corporation Japan", "Kabuki-Z (World)", 0 ) |
| 2408 | 2428 | GAME( 1988, kabukizj, kabukiz, kabukiz, kabukiz, kabukiz, ROT0, "Taito Corporation", "Kabuki-Z (Japan)", 0 ) |
| 2409 | 2429 | GAME( 1989, insectx, 0, insectx, insectx, insectx, ROT0, "Taito Corporation Japan", "Insector X (World)", 0 ) |
| 2410 | 2430 | GAME( 1992, jpopnics, 0, jpopnics, jpopnics, 0, ROT0, "Nics", "Jumping Pop (Nics, Korean bootleg of Plump Pop)", GAME_IMPERFECT_GRAPHICS ) |
| 2431 |
| r3232 | r3233 | |
|---|---|---|
| 1176 | 1176 | */ |
| 1177 | 1177 | |
| 1178 | 1178 | #define NAOMI2_BIOS \ |
| 1179 | ROM_REGION( 0x200000, "main", 0) \ | |
| 1179 | 1180 | ROM_SYSTEM_BIOS( 0, "bios0", "epr-23608b (Export)" ) \ |
| 1180 | 1181 | ROM_LOAD16_WORD_SWAP_BIOS( 0, "epr-23608b.bin", 0x000000, 0x200000, CRC(a554b1e3) SHA1(343b727a3619d1c75a9b6d4cc156a9050447f155) ) \ |
| 1181 | 1182 | ROM_SYSTEM_BIOS( 1, "bios1", "epr-23608 (Export)" ) \ |
| r3232 | r3233 | |
| 1195 | 1196 | #define AW_BIOS \ |
| 1196 | 1197 | ROM_SYSTEM_BIOS( 0, "bios0", "Atomiswave BIOS" ) \ |
| 1197 | 1198 | ROM_LOAD16_WORD_SWAP_BIOS( 0, "bios.ic23_l", 0x000000, 0x010000, BAD_DUMP CRC(e5693ce3) SHA1(1bde3ed87af64b0f675ebd47f12a53e1fc5709c1) ) /* Might be bad.. especially. bytes 0x0000, 0x6000, 0x8000 which gave different reads */ \ |
| 1198 | ROM_LOAD16_WORD_SWAP_BIOS( 0, "bios.ic23_h-dol | |
| 1199 | ROM_LOAD16_WORD_SWAP_BIOS( 0, "bios.ic23_h-dol | |
| 1199 | 1200 | |
| 1200 | 1201 | |
| 1201 | 1202 | ROM_START( naomi ) |
| r3232 | r3233 | |
| 1219 | 1220 | ROM_END |
| 1220 | 1221 | |
| 1221 | 1222 | ROM_START( naomi2 ) |
| 1222 | ROM_REGION( 0x200000, "main", 0) | |
| 1223 | 1223 | NAOMI2_BIOS |
| 1224 | 1224 | |
| 1225 | 1225 | ROM_REGION( 0x8400000, "user1", ROMREGION_ERASE) |
| r3232 | r3233 | |
| 2792 | 2792 | |
| 2793 | 2793 | |
| 2794 | 2794 | } |
| 2795 | ||
| 2796 | ROM_START( sfz3ugd ) | |
| 2797 | NAOMIGD_BIOS | |
| 2798 | ||
| 2799 | ROM_REGION( 0xac00000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2800 | ROM_LOAD_OPTIONAL("zero3rom.bin", 0x0000000, 0xac00000, CRC(4eabda58) SHA1(e70db0e93c821838c77510fd47c91f0c4cfb09c9) ) | |
| 2801 | ||
| 2802 | /* GD-ROM dump, this will be replaced once an appropriate CHD format has been decided upon for the GD images*/ | |
| 2803 | ROM_REGION( 0x3d8ab000, "user3", ROMREGION_ERASE) | |
| 2804 | ROM_LOAD("track.txt", 0x0000000, 0x000000ad, CRC(bf017e1d) SHA1(0345310b6982f818a07dec8739efe1709281f1e6) ) | |
| 2805 | ROM_LOAD("track01.iso",0x0000000, 0x000e1000, CRC(8af2e370) SHA1(0f359d423f72055e6a5c81e7075df1ffd3ccfa5c) ) | |
| 2806 | ROM_LOAD("track02.raw",0x0000000, 0x004c8cf0, CRC(c5628df6) SHA1(0d1a24e6271c3b0ef92c55ec9d63e2326892f1d8) ) | |
| 2807 | ROM_LOAD("track03.iso",0x0000000, 0x3d8ab000, CRC(195f0d93) SHA1(183412704bd90750355e7af019b78541328fe633) ) | |
| 2808 | ||
| 2809 | ||
| 2810 | ROM_REGION( 0x50, "pic_response", ROMREGION_ERASE) | |
| 2811 | ROM_LOAD("317-5072-com.data", 0x00, 0x50, CRC(6d2992b9) SHA1(88e6dc6711f9f883362ba1217a3350d452a70896) ) | |
| 2812 | ROM_END | |
| 2813 | ||
| 2814 | 2795 | extern void naomi_game_decrypt(UINT64 key, UINT8* region, int length); |
| 2815 | 2796 | |
| 2816 | DRIVER_INIT( cvs2gd ) | |
| 2817 | { | |
| 2818 | // get from key file instead | |
| 2819 | naomi_game_decrypt( 0x2f3226165b9e407cULL, memory_region(machine,"user1"), memory_region_length(machine,"user1")); | |
| 2820 | } | |
| 2821 | 2797 | |
| 2822 | DRIVER_INIT( sfz3ugd ) | |
| 2823 | { | |
| 2824 | // get from key file instead | |
| 2825 | naomi_game_decrypt( 0x4FF16D1A9E0BFBCDULL, memory_region(machine,"user1"), memory_region_length(machine,"user1")); | |
| 2826 | // naomi_write_keyfile(); | |
| 2827 | } | |
| 2828 | 2798 | |
| 2829 | 2799 | |
| 2830 | 2800 | |
| 2831 | ROM_START( cvs2gd ) | |
| 2832 | NAOMIGD_BIOS | |
| 2833 | 2801 | |
| 2834 | ROM_REGION( 0x9800000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2835 | ROM_LOAD("snkgd_sl.bin", 0x0000000, 0x9800000, CRC(f153421d) SHA1(0c2b935ae3cfb6c85410a209fec4eab497066d84) ) | |
| 2836 | 2802 | |
| 2837 | /* GD-ROM dump, this will be replaced once an appropriate CHD format has been decided upon for the GD images*/ | |
| 2838 | ROM_REGION( 0x26ad4620, "user3", ROMREGION_ERASE) | |
| 2839 | ROM_LOAD("capcom_vs_snk2.txt", 0x0000000, 0x00000141, CRC(0db478be) SHA1(a18f87b76139e4a845ecc1456b6195574110e30c) ) | |
| 2840 | ROM_LOAD("track01.bin",0x0000000, 0x00ac440, CRC(d48bd072) SHA1(2fc840586c655dee2686ee3b520c7760bd3b8dcb) ) | |
| 2841 | ROM_LOAD("track02.raw",0x0000000, 0x004c8cf0, CRC(3b3a2e7b) SHA1(fd8e5cac5bd387229f4ffbe05d1bf2fabf7ea3f9) ) | |
| 2842 | ROM_LOAD("track03.bin",0x0000000, 0x26ad4620, CRC(670d2182) SHA1(a99ceb7bb74e4a0fe6ae80b33cd2963465ae9d14) ) | |
| 2843 | ROM_CONTINUE(0x0000000, 0x20000000) | |
| 2844 | 2803 | |
| 2845 | ROM_REGION( 0x50, "pic_response", ROMREGION_ERASE) | |
| 2846 | ROM_LOAD("317-5078-com.data", 0x00, 0x50, CRC(1c8d94ee) SHA1(bec4a6901f62dc8f76f7b9d72284b3eaac340bf3) ) | |
| 2847 | ROM_END | |
| 2848 | ||
| 2849 | ||
| 2850 | ||
| 2851 | 2804 | /* All games have the regional titles at the start of the IC22 rom in the following order |
| 2852 | 2805 | |
| 2853 | 2806 | JAPAN |
| r3232 | r3233 | |
| 2903 | 2856 | /* HOTD2 isn't dumped */ |
| 2904 | 2857 | |
| 2905 | 2858 | |
| 2906 | /* No GD-Rom Sets Supported */ | |
| 2907 | GAME( 2001, naomigd, 0, naomi, naomi, 0, ROT0, "Sega", "Naomi GD-ROM Bios", GAME_NO_SOUND|GAME_NOT_WORKING|GAME_IS_BIOS_ROOT ) | |
| 2908 | GAME( 2001, sfz3ugd, naomigd, naomi, naomi, sfz3ugd, ROT0, "Capcom", "Street Fighter Zero 3 Upper", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 2909 | GAME( 2001, cvs2gd, naomigd, naomi, naomi, cvs2gd, ROT0, "Capcom", "Capcom Vs. SNK 2", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 2910 | 2859 | |
| 2860 | DRIVER_INIT( ngdkey ) | |
| 2861 | { | |
| 2862 | UINT8* picdata = memory_region(machine,"picreturn"); | |
| 2863 | UINT64 key; | |
| 2911 | 2864 | |
| 2865 | key =(((UINT64)picdata[0x31] << 56) | | |
| 2866 | ((UINT64)picdata[0x32] << 48) | | |
| 2867 | ((UINT64)picdata[0x33] << 40) | | |
| 2868 | ((UINT64)picdata[0x34] << 32) | | |
| 2869 | ((UINT64)picdata[0x35] << 24) | | |
| 2870 | ((UINT64)picdata[0x36] << 16) | | |
| 2871 | ((UINT64)picdata[0x37] << 8) | | |
| 2872 | ((UINT64)picdata[0x29] << 0)); | |
| 2873 | ||
| 2874 | printf("key is %08x%08x\n", (UINT32)((key & 0xffffffff00000000ULL)>>32), (UINT32)(key & 0x00000000ffffffffULL)); | |
| 2875 | ||
| 2876 | naomi_game_decrypt( key, memory_region(machine,"user1"), memory_region_length(machine,"user1")); | |
| 2877 | } | |
| 2878 | ||
| 2879 | ||
| 2880 | ROM_START( gundmgd ) | |
| 2881 | NAOMIGD_BIOS | |
| 2882 | ||
| 2883 | ROM_REGION( 0xa000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2884 | ROM_LOAD_OPTIONAL("gdmgd_sl.bin", 0x0000000, 0xa000000, CRC(d07ee020) SHA1(751033d48e021908958757125cf3b96a89d0e765) ) | |
| 2885 | ||
| 2886 | DISK_REGION( "gdrom" ) | |
| 2887 | DISK_IMAGE_READONLY( "gdl-0001", 0, SHA1(f525111e2762e5895fd0016a9bd41210c1125499) MD5(dcba598e76646a5a6b6e6da70552a7c5) ) | |
| 2888 | ||
| 2889 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2890 | //PIC16C622A (317-5069-COM) | |
| 2891 | //(sticker 253-5509-5069) | |
| 2892 | ROM_LOAD("317-5069-com.data", 0x00, 0x50, CRC(8e2f0cbd) SHA1(a5f3a990a03bfa50a1a742593c5ec07645c8718d) ) | |
| 2893 | ROM_END | |
| 2894 | ||
| 2895 | ||
| 2896 | ROM_START( sfz3ugd ) | |
| 2897 | NAOMIGD_BIOS | |
| 2898 | ||
| 2899 | ROM_REGION( 0xac00000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2900 | ROM_LOAD_OPTIONAL("zero3rom.bin", 0x0000000, 0xac00000, CRC(4eabda58) SHA1(e70db0e93c821838c77510fd47c91f0c4cfb09c9) ) | |
| 2901 | ||
| 2902 | DISK_REGION( "gdrom" ) | |
| 2903 | DISK_IMAGE_READONLY( "gdl-0002", 0, SHA1(6e7cb0df5feea41ae0b5eb72a92adcd8966595dc) MD5(6340b2527673a8cf387dcda52ecae0ca) ) | |
| 2904 | ||
| 2905 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2906 | //PIC16C622A (317-5072-COM) | |
| 2907 | //(sticker 253-5509-5072) | |
| 2908 | ROM_LOAD("317-5072-com.data", 0x00, 0x50, CRC(6d2992b9) SHA1(88e6dc6711f9f883362ba1217a3350d452a70896) ) | |
| 2909 | ROM_END | |
| 2910 | ||
| 2911 | ROM_START( cvsgd ) | |
| 2912 | NAOMIGD_BIOS | |
| 2913 | ||
| 2914 | ROM_REGION( 0x7800000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2915 | ROM_LOAD_OPTIONAL("snkgd_sl.bin", 0x0000000, 0x7800000, CRC(83ec3894) SHA1(d07271d964bf6421ea9f13e10ecec57c6e995b2e) ) | |
| 2916 | ||
| 2917 | DISK_REGION( "gdrom" ) | |
| 2918 | DISK_IMAGE_READONLY( "gdl-0004", 0, SHA1(8f8651527463aa01d40c280c0d9b03b7a0650a32) MD5(2d17eaf881c06bd95847e54878bc2ba9) ) | |
| 2919 | ||
| 2920 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2921 | //PIC16C622A (317-5076-JPN) | |
| 2922 | //(sticker 253-5509-5076J) | |
| 2923 | ROM_LOAD("317-5076-jpn.data", 0x00, 0x50, CRC(5004161b) SHA1(8b2cdfec12ffd9160bc74659e08d07cbc46a4011) ) | |
| 2924 | ROM_END | |
| 2925 | ||
| 2926 | ||
| 2927 | ROM_START( gundmxgd ) | |
| 2928 | NAOMIGD_BIOS | |
| 2929 | ||
| 2930 | ROM_REGION( 0xc800000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2931 | ROM_LOAD_OPTIONAL("gdmgd_sl.bin", 0x0000000, 0xc800000, CRC(322e503c) SHA1(10a0e3e079d9724e6bc2d4916a4f64384d00d202) ) | |
| 2932 | ||
| 2933 | DISK_REGION( "gdrom" ) | |
| 2934 | DISK_IMAGE_READONLY( "gdl-0006", 0, SHA1(b95bc07e61e57a62e276ba7fef0ae9a5c19667d9) MD5(90b1980605e7f53b38292ae32d547c8b) ) | |
| 2935 | ||
| 2936 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2937 | //PIC16C622A (317-5079-COM) | |
| 2938 | //(sticker 253-5509-5079) | |
| 2939 | ROM_LOAD("317-5079-com.data", 0x00, 0x50, CRC(e6abe978) SHA1(700e610d84e517793a22d6cabd1aef9c3b8bc092) ) | |
| 2940 | ROM_END | |
| 2941 | ||
| 2942 | ||
| 2943 | ROM_START( cvs2gd ) | |
| 2944 | NAOMIGD_BIOS | |
| 2945 | ||
| 2946 | ROM_REGION( 0x9800000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2947 | ROM_LOAD("snkgd_sl.bin", 0x0000000, 0x9800000, CRC(f153421d) SHA1(0c2b935ae3cfb6c85410a209fec4eab497066d84) ) | |
| 2948 | ||
| 2949 | DISK_REGION( "gdrom" ) | |
| 2950 | DISK_IMAGE_READONLY( "gdl-0007a", 0, SHA1(e8f199f2743a63765bcbcd533bbe5eed82f959a8) MD5(1f434e6f610987987d1d130e454f5c74) ) | |
| 2951 | ||
| 2952 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2953 | //PIC16C622A (317-5078-COM) | |
| 2954 | //(sticker 253-5509-5078) | |
| 2955 | ROM_LOAD("317-5078-com.data", 0x00, 0x50, CRC(1c8d94ee) SHA1(bec4a6901f62dc8f76f7b9d72284b3eaac340bf3) ) | |
| 2956 | ROM_END | |
| 2957 | ||
| 2958 | ROM_START( ikaruga ) | |
| 2959 | NAOMIGD_BIOS | |
| 2960 | ||
| 2961 | ROM_REGION( 0x9800000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2962 | ROM_LOAD("ikaruga.bin", 0x0000000, 0x2000000, CRC(e0369676) SHA1(87f1d01ed81a612b44ed2e1bc48098c3ba92c238) ) | |
| 2963 | ||
| 2964 | DISK_REGION( "gdrom" ) | |
| 2965 | DISK_IMAGE_READONLY( "gdl-0010", 0, SHA1(3b853be7208f523100690e12a661173d023af9c1) MD5(83f1877b979b0e5fd77ebfa1ddd9fd56) ) | |
| 2966 | ||
| 2967 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2968 | //PIC16C622A (317-5081-JPN) | |
| 2969 | //(sticker 253-5509-5081J) | |
| 2970 | ROM_LOAD("317-5081-jpn.data", 0x00, 0x50, CRC(d4cc5c8c) SHA1(44c0c5c2744fbd419b684cbc36f01973487bafbc) ) | |
| 2971 | ROM_END | |
| 2972 | ||
| 2973 | ||
| 2974 | ROM_START( ggxx ) | |
| 2975 | NAOMIGD_BIOS | |
| 2976 | ||
| 2977 | ROM_REGION( 0xf000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2978 | ROM_LOAD("ggx2.bin", 0x0000000, 0xf000000, CRC(666676ee) SHA1(24302e6f10e0d4d41f432cabf9d2743c0aa8fa7c) ) | |
| 2979 | ||
| 2980 | DISK_REGION( "gdrom" ) | |
| 2981 | DISK_IMAGE_READONLY( "gdl-0011", 0, SHA1(c08a19acb5641d2fd14b54cc149459c345dae013) MD5(25ab6d42bf07dd26e7033cf201322d9c) ) | |
| 2982 | ||
| 2983 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 2984 | //PIC16C622A (317-5082-COM) | |
| 2985 | //(sticker 253-5509-5082) | |
| 2986 | ROM_LOAD("317-5082-com.data", 0x00, 0x50, CRC(fa31209d) SHA1(bb18e6412a02510832f7200a06a3179ef1695ef2) ) | |
| 2987 | ROM_END | |
| 2988 | ||
| 2989 | ||
| 2990 | ROM_START( chocomk ) | |
| 2991 | NAOMIGD_BIOS | |
| 2992 | ||
| 2993 | ROM_REGION( 0x3f1f000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 2994 | ROM_LOAD("typ.bin", 0x0000000, 0x3f1f000, CRC(d3976ae9) SHA1(764675d0b612b856dab95caa3000b31206439db4) ) | |
| 2995 | ||
| 2996 | DISK_REGION( "gdrom" ) | |
| 2997 | DISK_IMAGE_READONLY( "gdl-0014a", 0, SHA1(ee71e76f136b1a25855233a614d5c60a6a3e587d) MD5(1e5a028b0ae5cf3c5602cdc657fa2bc4) ) | |
| 2998 | ||
| 2999 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3000 | //PIC16C622A (317-5085-JPN) | |
| 3001 | //(sticker 253-5509-5085J) | |
| 3002 | ROM_LOAD("317-5085-jpn.data", 0x00, 0x50, CRC(eecd8140) SHA1(471fb6b242eff646173265df891109e3e0a37a7d) ) | |
| 3003 | ROM_END | |
| 3004 | ||
| 3005 | ||
| 3006 | ROM_START( quizqgd ) | |
| 3007 | NAOMIGD_BIOS | |
| 3008 | ||
| 3009 | ROM_REGION( 0x9000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3010 | ROM_LOAD("game.bin", 0x0000000, 0x9000000, CRC(0075dd46) SHA1(8f0cb3f8bce492c8d2bdec607a4b95d36ddea404) ) | |
| 3011 | ||
| 3012 | DISK_REGION( "gdrom" ) | |
| 3013 | DISK_IMAGE_READONLY( "gdl-0017", 0, SHA1(b6f3fbc81d9aea18551134b93ba3b612254bbc43) MD5(af4be08bf65cbddf2177ccf838c0df20) ) | |
| 3014 | ||
| 3015 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3016 | //PIC16C622A (317-5090-JPN) | |
| 3017 | //(sticker 253-5509-5090J) | |
| 3018 | ROM_LOAD("317-5090-jpn.data", 0x00, 0x50, CRC(b4dd88f6) SHA1(c9aacd79c1088225fa5a69b7bd31a7c1286160e1) ) | |
| 3019 | ROM_END | |
| 3020 | ||
| 3021 | ROM_START( ggxxrl ) | |
| 3022 | NAOMIGD_BIOS | |
| 3023 | ||
| 3024 | ROM_REGION( 0xf000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3025 | ROM_LOAD("ggx2.bin", 0x0000000, 0xf000000, CRC(96ee0174) SHA1(3063682aa31b983fc8dcc2a86bf57dc50da5d904) ) | |
| 3026 | ||
| 3027 | DISK_REGION( "gdrom" ) | |
| 3028 | DISK_IMAGE_READONLY( "gdl-0019a", 0, SHA1(50ec9bba5a7ba71f8543763cb139bab46dc487a5) MD5(b09c865e3e06e6e4467acf45b04e9caa) ) | |
| 3029 | ||
| 3030 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3031 | //PIC16C622A (317-5092-JPN) | |
| 3032 | //(sticker 253-5509-5092J) | |
| 3033 | ROM_LOAD("317-5092-jpn.data", 0x00, 0x50, CRC(7c8cca4b) SHA1(92c5a0fd8916744eefc023e64daea69803573928) ) | |
| 3034 | ROM_END | |
| 3035 | ||
| 3036 | ROM_START( shikgam2 ) | |
| 3037 | NAOMIGD_BIOS | |
| 3038 | ||
| 3039 | ROM_REGION( 0x704e000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3040 | ROM_LOAD("game.bin", 0x0000000, 0x704e000, CRC(f658311f) SHA1(d4b780d5954dd41bfe6ceff5fb358d94bc836126) ) | |
| 3041 | ||
| 3042 | DISK_REGION( "gdrom" ) | |
| 3043 | DISK_IMAGE_READONLY( "gdl-0021", 0, SHA1(ca6a9f78b2f6b18be3fb926ebcd20c2e90923882) MD5(ba448900dd5cbc9f1f75f285f5d72231) ) | |
| 3044 | ||
| 3045 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3046 | //PIC16C622A (317-5095-JPN) | |
| 3047 | //(sticker 253-5509-5095J) | |
| 3048 | ROM_LOAD("317-5095-jpn.data", 0x00, 0x50, CRC(6033ec89) SHA1(9e99a8ad43fa29296dbf2e13b3a3d4552130b4e8) ) | |
| 3049 | ROM_END | |
| 3050 | ||
| 3051 | ||
| 3052 | ROM_START( meltybld ) | |
| 3053 | NAOMIGD_BIOS | |
| 3054 | ||
| 3055 | ROM_REGION( 0xdc2c000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3056 | ROM_LOAD("mel.bin", 0x0000000, 0xdc2c000, CRC(2af7db27) SHA1(2569b6f84be411928764fb513503dfe116f957f5) ) | |
| 3057 | ||
| 3058 | DISK_REGION( "gdrom" ) | |
| 3059 | DISK_IMAGE_READONLY( "gdl-0028c", 0, SHA1(bbe95fd6bb39a33e979a0d9d8a63c0f2df1e9e96) MD5(b3318abacfea682605aaa24c756f225d) ) | |
| 3060 | ||
| 3061 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3062 | //PIC16C622A (317-5104-JPN) | |
| 3063 | //(sticker 253-5509-5104J) | |
| 3064 | ROM_LOAD("317-5104-jpn.data", 0x00, 0x50, CRC(fedc8305) SHA1(c535545937213f726f25e6aa8eb3746a794e9100) ) | |
| 3065 | ROM_END | |
| 3066 | ||
| 3067 | ||
| 3068 | ||
| 3069 | ROM_START( senko ) | |
| 3070 | NAOMIGD_BIOS | |
| 3071 | ||
| 3072 | ROM_REGION( 0xfe40000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3073 | ROM_LOAD("ronde.bin", 0x0000000, 0xfe40000, CRC(49bff4cb) SHA1(bd67522ed781cdd70b4c652cbb1befddb395a4b7) ) | |
| 3074 | ||
| 3075 | DISK_REGION( "gdrom" ) | |
| 3076 | DISK_IMAGE_READONLY( "gdl-0030a", 0, SHA1(bb9727f69f7e5452e09b151c1198d006a81aeb0e) MD5(12885cd794d8a5a839699aef4769b2dd) ) | |
| 3077 | ||
| 3078 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3079 | //PIC16C622A (317-5107-JPN) | |
| 3080 | //(sticker 253-5509-5107J) | |
| 3081 | ROM_LOAD("317-5107-jpn.data", 0x00, 0x50, CRC(7b607409) SHA1(a9946a0637453e4813bef18060d4420355cff800) ) | |
| 3082 | ROM_END | |
| 3083 | ||
| 3084 | ||
| 3085 | ||
| 3086 | ROM_START( ss2005 ) | |
| 3087 | NAOMIGD_BIOS | |
| 3088 | ||
| 3089 | ROM_REGION( 0x5504800, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3090 | ROM_LOAD("sh2sl.bin", 0x0000000, 0x5504800, CRC(5c1d2394) SHA1(197cb74c00adb2acafa927045a2fa7b5730605c7) ) | |
| 3091 | ||
| 3092 | DISK_REGION( "gdrom" ) | |
| 3093 | DISK_IMAGE_READONLY( "gdl-0031a", 0, SHA1(09a47ce506b9696d7bdf4d7c95aa3182cc0d9efa) MD5(1a83930f2083397868172745d3ab2926) ) | |
| 3094 | ||
| 3095 | ||
| 3096 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3097 | //PIC16C622A (317-5108-JPN) | |
| 3098 | //(sticker 253-5509-5108J) | |
| 3099 | ROM_LOAD("317-5108-jpn.data", 0x00, 0x50, CRC(6a2eb334) SHA1(cab407d2e994f33aa921d50f399b17e6fbf98eb0) ) | |
| 3100 | ROM_END | |
| 3101 | ||
| 3102 | ||
| 3103 | ||
| 3104 | ROM_START( sprtjam ) | |
| 3105 | NAOMIGD_BIOS | |
| 3106 | ||
| 3107 | ROM_REGION( 0xb000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3108 | ROM_LOAD("rom.enc", 0x0000000, 0xb000000, CRC(1f6daa8d) SHA1(41c40da36c0448d0a8695fef2fd304b9caaf7562) ) | |
| 3109 | ||
| 3110 | DISK_REGION( "gdrom" ) | |
| 3111 | DISK_IMAGE_READONLY( "gds-0003", 0, SHA1(bfabb0da1d4f0422e0b62d8a7bb67dbcdb0d5954) MD5(3a8d3cbc4067f9b5f50be9b9abdc689b) ) | |
| 3112 | ||
| 3113 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3114 | //PIC16C622A (317-0300-COM) | |
| 3115 | //(sticker 253-5508-0300) | |
| 3116 | ROM_LOAD("317-0300-com.data", 0x00, 0x50, CRC(9a08413f) SHA1(d57649dcc3af578d55a93dd7a3f41da62d580f54) ) | |
| 3117 | ROM_END | |
| 3118 | ||
| 3119 | ||
| 3120 | ROM_START( slashout ) | |
| 3121 | NAOMIGD_BIOS | |
| 3122 | ||
| 3123 | ROM_REGION( 0x9000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3124 | ROM_LOAD("slash.bin", 0x0000000, 0x9000000, CRC(e1f9320f) SHA1(09f1a69aee6e401acbe2099e10193d3fb575eeeb) ) | |
| 3125 | ||
| 3126 | DISK_REGION( "gdrom" ) | |
| 3127 | DISK_IMAGE_READONLY( "gds-0004", 0, SHA1(ec1758f5ae359bcb3c66c7ce9ebcb7443c4fd967) MD5(f5228f26e661ab0cb67414f51fe1a5bc) ) | |
| 3128 | ||
| 3129 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3130 | //PIC16C622A (317-0302-COM) | |
| 3131 | //(sticker 253-5508-0302) | |
| 3132 | ROM_LOAD("317-0302-com.data", 0x00, 0x50, CRC(4bf6cd62) SHA1(c1fdf12a4d80fa3008170c89d2dc583f19e0450b) ) | |
| 3133 | ROM_END | |
| 3134 | ||
| 3135 | ||
| 3136 | ROM_START( spkrbtl ) | |
| 3137 | NAOMIGD_BIOS | |
| 3138 | ||
| 3139 | ROM_REGION( 0xb000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3140 | ROM_LOAD("spkb.bin", 0x0000000, 0xb000000, CRC(ca11d20e) SHA1(e2e2710a8c69eeb970e131be80e0ec19e91d90c6) ) | |
| 3141 | ||
| 3142 | DISK_REGION( "gdrom" ) | |
| 3143 | DISK_IMAGE_READONLY( "gds-0005", 0, SHA1(ca6e7ed2e161acad8600898e1b83aded9bb31d3b) MD5(a8a05ce6ab7d9ea67e015cd4853a5b80) ) | |
| 3144 | ||
| 3145 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3146 | //PIC16C622A (317-0303-COM) | |
| 3147 | //(sticker 253-5508-0303) | |
| 3148 | ROM_LOAD("317-0303-com.data", 0x00, 0x50, CRC(6e7888a3) SHA1(5ca78052bcfd9e9f81934cbddd9c173e88973e0e) ) | |
| 3149 | ROM_END | |
| 3150 | ||
| 3151 | ||
| 3152 | ROM_START( dygolf ) | |
| 3153 | NAOMIGD_BIOS | |
| 3154 | ||
| 3155 | ROM_REGION( 0x6000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3156 | ROM_LOAD("game.enc", 0x0000000, 0x6000000, CRC(ab02d769) SHA1(3d96d43522357950a3928717464ecf854dd6e385) ) | |
| 3157 | ||
| 3158 | DISK_REGION( "gdrom" ) | |
| 3159 | DISK_IMAGE_READONLY( "gds-0009", 0, SHA1(d58a42586c65dcb44282bf930631ea8b663c6aa7) MD5(e553e1811f28b67fd57fa8e34d978d87) ) | |
| 3160 | ||
| 3161 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3162 | //PIC16C622A (317-0308-COM) | |
| 3163 | //(sticker 253-5508-0308) | |
| 3164 | ROM_LOAD("317-0308-com.data", 0x00, 0x50, CRC(56f63af0) SHA1(3c453226fc53d2f700b3634db3ef8ce206d94392) ) | |
| 3165 | ROM_END | |
| 3166 | ||
| 3167 | ROM_START( wsbbgd ) | |
| 3168 | NAOMIGD_BIOS | |
| 3169 | ||
| 3170 | ROM_REGION( 0xa000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3171 | ROM_LOAD("wsb_sl.bin", 0x0000000, 0xa000000, CRC(e61f37f1) SHA1(ba7b97eec6df672b520c57422287f699438267c5) ) | |
| 3172 | ||
| 3173 | DISK_REGION( "gdrom" ) | |
| 3174 | DISK_IMAGE_READONLY( "gds-0010", 0, SHA1(8ce36c9710a8d55e8c19d7f218500b7074b66dec) MD5(bfb8c5ead5ac9e2a82bca9114390a99f) ) | |
| 3175 | ||
| 3176 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3177 | //PIC16C622A (317-0309-COM) | |
| 3178 | //(sticker 253-5508-0309) | |
| 3179 | ROM_LOAD("317-0309-com.data", 0x00, 0x50, CRC(8792c550) SHA1(e8d6d91583d1673d8d3fa9ccb0ab1097c5c5ad08) ) | |
| 3180 | ROM_END | |
| 3181 | ||
| 3182 | ||
| 3183 | ROM_START( vathlete ) | |
| 3184 | NAOMIGD_BIOS | |
| 3185 | ||
| 3186 | ROM_REGION( 0x7000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3187 | ROM_LOAD("va.bin", 0x0000000, 0x7000000, CRC(82992bf8) SHA1(1c36e1d8e5bf392b760c934b358963b92fc716cf) ) | |
| 3188 | ||
| 3189 | DISK_REGION( "gdrom" ) | |
| 3190 | DISK_IMAGE_READONLY( "gds-0019", 0, SHA1(2167bbdde987c16949c5814ab7cff6eefd9f9326) MD5(67499591f2c61cda14fa581db9294315) ) | |
| 3191 | ||
| 3192 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3193 | //PIC16C622A (317-0330-COM) | |
| 3194 | //(sticker 253-5508-0330) | |
| 3195 | ROM_LOAD("317-0330-com.data", 0x00, 0x50, CRC(f5e7f7d4) SHA1(3903337e82011d132993e4366475586866bd39b1) ) | |
| 3196 | ROM_END | |
| 3197 | ||
| 3198 | /* Naomi GD-Rom Sets */ | |
| 3199 | GAME( 2001, naomigd, 0, naomi, naomi, 0, ROT0, "Sega", "Naomi GD-ROM Bios", GAME_NO_SOUND|GAME_NOT_WORKING|GAME_IS_BIOS_ROOT ) | |
| 3200 | ||
| 3201 | // GDL-xxxx (licensed games?) | |
| 3202 | GAME( 200?, gundmgd, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Mobile Suit Gundam: Federation VS Zeon (GDL-0001)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3203 | GAME( 200?, sfz3ugd, naomigd, naomi, naomi, ngdkey, ROT0, "Capcom", "Street Fighter Zero 3 Upper (GDL-0002)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3204 | GAME( 200?, cvsgd, naomigd, naomi, naomi, ngdkey, ROT0, "Capcom", "Capcom vs SNK Millenium Fight 2000 Pro (GDL-0004)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3205 | GAME( 200?, gundmxgd, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Mobile Suit Gundam: Federation VS Zeon DX (GDL-0006)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3206 | GAME( 200?, cvs2gd, naomigd, naomi, naomi, ngdkey, ROT0, "Capcom", "Capcom vs SNK 2 Millionaire Fighting 2001 (GDL-0007A)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3207 | GAME( 2001, ikaruga, naomigd, naomi, naomi, ngdkey, ROT270, "Treasure", "Ikaruga (GDL-0010)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3208 | GAME( 200?, ggxx, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Guilty Gear XX (GDL-0011)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3209 | GAME( 200?, chocomk, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Musapey's Choco Marker (GDL-0014A)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3210 | GAME( 200?, quizqgd, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Quiz Keitai Q mode (GDL-0017)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3211 | GAME( 200?, ggxxrl, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Guilty Gear XX #Reload (GDL-0019A)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3212 | GAME( 200?, shikgam2, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Shikigami No Shiro II / The Castle of Shikigami II (GDL-0021)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3213 | GAME( 2004, meltybld, naomigd, naomi, naomi, ngdkey, ROT0, "Ecole", "Melty Blood Act Cadenza (GDL-0028C)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3214 | GAME( 200?, senko, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Senko No Ronde (GDL-0030A)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3215 | GAME( 2005, ss2005, naomigd, naomi, naomi, ngdkey, ROT0, "unknown", "Super Shanghai 2005 (GDL-0031A)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3216 | ||
| 3217 | // GDS-xxxx (first party games?) | |
| 3218 | GAME( 200?, sprtjam, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "Sports Jam (GDS-0003)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3219 | GAME( 200?, slashout, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "Slashout (GDS-0004)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3220 | GAME( 200?, spkrbtl, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "Spikers Battle (GDS-0005)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3221 | GAME( 200?, dygolf, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "Virtua Golf / Dynamic Golf (GDS-0009)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3222 | GAME( 200?, wsbbgd, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "World Series Baseball (GDS-0010)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3223 | GAME( 200?, vathlete, naomigd, naomi, naomi, ngdkey, ROT0, "Sega", "Virtua Athletics / Virtua Athlete (GDS-0019)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3224 | ||
| 2912 | 3225 | /* Naomi 2 & Naomi 2 GD-ROM */ |
| 3226 | ||
| 3227 | ||
| 3228 | ROM_START( vstrik3 ) | |
| 3229 | NAOMI2_BIOS | |
| 3230 | ||
| 3231 | ROM_REGION( 0xb000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3232 | ROM_LOAD("vs3.bin", 0x0000000, 0xb000000, CRC(79d44ff4) SHA1(af0b892531c60999f0ef5db7525de50836764c77) ) | |
| 3233 | ||
| 3234 | DISK_REGION( "gdrom" ) | |
| 3235 | DISK_IMAGE_READONLY( "gds-0006", 0, SHA1(293b84c7f4547060f57598b796b6fc49513cc839) MD5(060d9fef55d8f0fc1986ecc991478942) ) | |
| 3236 | ||
| 3237 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3238 | //PIC16C622A (317-0304-COM) | |
| 3239 | //(sticker 253-5508-0304) | |
| 3240 | ROM_LOAD("317-0304-com.data", 0x00, 0x50, CRC(a181c601) SHA1(6a489904941e638ac1069b66e76ee0bcec7d0bab) ) | |
| 3241 | ROM_END | |
| 3242 | ||
| 3243 | ROM_START( vf4 ) | |
| 3244 | NAOMI2_BIOS | |
| 3245 | ||
| 3246 | ROM_REGION( 0xf000000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3247 | ROM_LOAD("vf4.bin", 0x0000000, 0xf000000, CRC(a81e3277) SHA1(fb162f34720d6ba49297ecb5e2869b2afffc307b) ) | |
| 3248 | ||
| 3249 | DISK_REGION( "gdrom" ) | |
| 3250 | DISK_IMAGE_READONLY( "gds-0012", 0, SHA1(d68436ee72ea5db40e184b7ff38903a9cadb6df7) MD5(5a18300646a68f2994ed8c81abe9bdd8) ) | |
| 3251 | ||
| 3252 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3253 | // this key is wrong! not for this game | |
| 3254 | // (it's for game with a BDR.bin file on the GD-ROM, vf4 has BDM.bin) | |
| 3255 | ||
| 3256 | //PIC16C622A (317-0317-COM) | |
| 3257 | //(sticker 253-5508-0317) | |
| 3258 | ROM_LOAD("317-0317-com.data", 0x00, 0x50, BAD_DUMP CRC(66efe433) SHA1(7f7b52202ed9b1e20516aaa7553cc3cc677a70b5) ) | |
| 3259 | ROM_END | |
| 3260 | ||
| 3261 | ROM_START( initd ) | |
| 3262 | NAOMI2_BIOS | |
| 3263 | ||
| 3264 | ROM_REGION( 0xc2ed000, "user1", ROMREGION_ERASE) // this is the 'rom' file from the GDROM DISC, once the GDROM is emulated this won't be loaded | |
| 3265 | ROM_LOAD("inid.bin", 0x0000000, 0xc2ed000, CRC(524ca451) SHA1(cc8dd06e4fe50e70f277043bd1b817e41c5db8cf) ) | |
| 3266 | ||
| 3267 | DISK_REGION( "gdrom" ) | |
| 3268 | DISK_IMAGE_READONLY( "gds-0020b", 0, SHA1(5f386183e856722fee4a6ddb0146350b73349181) MD5(b085005215e2766e0fc1e3bd16b2fd95) ) | |
| 3269 | ||
| 3270 | ROM_REGION( 0x50, "picreturn", ROMREGION_ERASE) | |
| 3271 | //PIC16C622A (317-0331-JPN) | |
| 3272 | //(sticker 253-5508-0331J) | |
| 3273 | ROM_LOAD("317-0331-jpn.data", 0x00, 0x50, CRC(bb39742e) SHA1(b3100b18aeb80ebfd5312ba5c320e7e647710b55) ) | |
| 3274 | ROM_END | |
| 3275 | ||
| 2913 | 3276 | GAME( 2001, naomi2, 0, naomi, naomi, 0, ROT0, "Sega", "Naomi 2 Bios", GAME_NO_SOUND|GAME_NOT_WORKING|GAME_IS_BIOS_ROOT ) |
| 2914 | /* No Supported Sets */ | |
| 3277 | // GDS-xxxx (first party games?) | |
| 3278 | GAME( 200?, vstrik3, naomi2, naomi, naomi, ngdkey, ROT0, "Sega", "Virtua Striker 3 (GDS-0006)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3279 | GAME( 200?, vf4, naomi2, naomi, naomi, ngdkey, ROT0, "Sega", "Virtua Fighter 4 (GDS-0012)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 3280 | GAME( 200?, initd, naomi2, naomi, naomi, ngdkey, ROT0, "Sega", "Initial D (GDS-0020b)", GAME_NO_SOUND|GAME_NOT_WORKING ) | |
| 2915 | 3281 | |
| 3282 | ||
| 2916 | 3283 | /* Atomiswave */ |
| 2917 | 3284 | GAME( 2001, awbios, 0, naomi, naomi, 0, ROT0, "Sammy", "Atomiswave Bios", GAME_NO_SOUND|GAME_NOT_WORKING|GAME_IS_BIOS_ROOT ) |
| 2918 | 3285 | GAME( 2005, fotns, awbios, naomi, naomi, fotns, ROT0, "Sammy", "Fist Of The North Star", GAME_NO_SOUND|GAME_NOT_WORKING ) |
| r3232 | r3233 | |
|---|---|---|
| 891 | 891 | }; |
| 892 | 892 | |
| 893 | 893 | static UINT8 port_sel,mux_data; |
| 894 | static int port_i; | |
| 894 | 895 | |
| 895 | 896 | static READ32_HANDLER ( stv_io_r32 ) |
| 896 | 897 | { |
| 897 | static int i= -1; | |
| 898 | 898 | //if(LOG_IOGA) logerror("(PC=%08X): I/O r %08X & %08X\n", activecpu_get_pc(), offset*4, mem_mask); |
| 899 | 899 | |
| 900 | 900 | switch(offset) |
| r3232 | r3233 | |
| 984 | 984 | case 7: |
| 985 | 985 | if(LOG_IOGA) logerror("(PC %d=%06x) Warning: READ from PORT_AD\n",cpu_getactivecpu(), activecpu_get_pc()); |
| 986 | 986 | popmessage("Read from PORT_AD"); |
| 987 | i++; | |
| 988 | return port_ad[i & 7]; | |
| 987 | port_i++; | |
| 988 | return port_ad[port_i & 7]; | |
| 989 | 989 | default: |
| 990 | 990 | return ioga[offset]; |
| 991 | 991 | } |
| r3232 | r3233 | |
| 2577 | 2577 | NMI_reset = 1; |
| 2578 | 2578 | smpc_ram[0x21] = (0x80) | ((NMI_reset & 1) << 6); |
| 2579 | 2579 | |
| 2580 | port_sel = mux_data = 0; | |
| 2581 | port_i = -1; | |
| 2582 | ||
| 2580 | 2583 | cpunum_set_clock(machine, 0, MASTER_CLOCK_320/2); |
| 2581 | 2584 | cpunum_set_clock(machine, 1, MASTER_CLOCK_320/2); |
| 2582 | 2585 | cpunum_set_clock(machine, 2, MASTER_CLOCK_320/5); |
| r3232 | r3233 | |
|---|---|---|
| 224 | 224 | |
| 225 | 225 | static READ8_HANDLER( megatech_instr_r ) |
| 226 | 226 | { |
| 227 | UINT8* instr = memory_region(machine, "m | |
| 227 | UINT8* instr = memory_region(machine, "m | |
| 228 | 228 | |
| 229 | 229 | return instr[offset/2]; |
| 230 | 230 | // else |
| r3232 | r3233 | |
| 376 | 376 | /* if the regions exist we're fine */ |
| 377 | 377 | if (game_region && bios_region) |
| 378 | 378 | { |
| 379 | memcpy(memory_region(machine, "m | |
| 379 | memcpy(memory_region(machine, "m | |
| 380 | 380 | memcpy(memory_region(machine, "main"), game_region, 0x300000); |
| 381 | 381 | |
| 382 | 382 | // I store an extra byte at the end of the instruction rom region when loading |
| r3232 | r3233 | |
| 413 | 413 | // cpunum_set_input_line(machine, 1, INPUT_LINE_RESET, ASSERT_LINE); |
| 414 | 414 | |
| 415 | 415 | /* no cart.. */ |
| 416 | memset(memory_region(machine, "m | |
| 416 | memset(memory_region(machine, "m | |
| 417 | 417 | memset(memory_region(machine, "main"), 0x00, 0x300000); |
| 418 | 418 | } |
| 419 | 419 | |
| r3232 | r3233 | |
| 438 | 438 | if (mt_cart_select_reg==2) |
| 439 | 439 | { |
| 440 | 440 | printf("game 2 selected\n"); |
| 441 | memcpy(memory_region(machine, "m | |
| 441 | memcpy(memory_region(machine, "m | |
| 442 | 442 | } |
| 443 | 443 | // else if (mt_cart_select_reg==0) |
| 444 | 444 | // { |
| 445 | 445 | // printf("game 0 selected\n"); |
| 446 | // memcpy(memory_region(machine, "m | |
| 446 | // memcpy(memory_region(machine, "m | |
| 447 | 447 | // } |
| 448 | 448 | else if (mt_cart_select_reg==6) |
| 449 | 449 | { |
| 450 | 450 | printf("game 6 selected\n"); |
| 451 | memcpy(memory_region(machine, "m | |
| 451 | memcpy(memory_region(machine, "m | |
| 452 | 452 | } |
| 453 | 453 | else |
| 454 | 454 | { |
| 455 | memset(memory_region(machine, "m | |
| 455 | memset(memory_region(machine, "m | |
| 456 | 456 | } |
| 457 | 457 | */ |
| 458 | 458 | |
| r3232 | r3233 | |
| 616 | 616 | MDRV_IMPORT_FROM(megadriv) |
| 617 | 617 | |
| 618 | 618 | /* Megatech has an extra SMS based bios *and* an additional screen */ |
| 619 | MDRV_CPU_ADD("m | |
| 619 | MDRV_CPU_ADD("m | |
| 620 | 620 | MDRV_CPU_PROGRAM_MAP(megatech_bios_map, 0) |
| 621 | 621 | MDRV_CPU_IO_MAP(megatech_bios_portmap,0) |
| 622 | 622 | |
| r3232 | r3233 | |
| 657 | 657 | |
| 658 | 658 | #define MEGATECH_BIOS \ |
| 659 | 659 | ROM_REGION( 0x400000, "main", ROMREGION_ERASEFF ) \ |
| 660 | ROM_REGION( 0x10000, "m | |
| 660 | ROM_REGION( 0x10000, "m | |
| 661 | 661 | ROM_LOAD( "epr12664.20", 0x000000, 0x8000, CRC(f71e9526) SHA1(1c7887541d02c41426992d17f8e3db9e03975953) ) \ |
| 662 | 662 | |
| 663 | 663 | /* no games */ |
| r3232 | r3233 | |
|---|---|---|
| 164 | 164 | SOUND |
| 165 | 165 | ***********************************************************/ |
| 166 | 166 | |
| 167 | static INT32 banknum | |
| 167 | static INT32 banknum | |
| 168 | 168 | |
| 169 | 169 | static void reset_sound_region(running_machine *machine) |
| 170 | 170 | { |
| r3232 | r3233 | |
| 703 | 703 | |
| 704 | 704 | static MACHINE_RESET( taito_dualscreen ) |
| 705 | 705 | { |
| 706 | banknum = -1; | |
| 707 | ||
| 706 | 708 | /**** mixer control enable ****/ |
| 707 | 709 | sound_global_enable( 1 ); /* mixer enabled */ |
| 708 | 710 | } |
| r3232 | r3233 | |
|---|---|---|
| 351 | 351 | { \ |
| 352 | 352 | int i; \ |
| 353 | 353 | UINT16 ret=0; \ |
| 354 | static const char *dipnames[] = { "DSW1", "DSW2", "DSW3", "DSW4", "DSW5" }; | |
| 354 | static const char *const dipnames[] = { "DSW1", "DSW2", "DSW3", "DSW4", "DSW5" }; | |
| 355 | 355 | \ |
| 356 | 356 | for (i = 0; i < NUM; i++) \ |
| 357 | 357 | if ((~igs_dips_sel) & (1 << i) ) \ |
| r3232 | r3233 | |
|---|---|---|
| 71 | 71 | |
| 72 | 72 | static READ8_HANDLER( poolshrk_input_r ) |
| 73 | 73 | { |
| 74 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 74 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 75 | 75 | UINT8 val = input_port_read(machine, portnames[offset & 3]); |
| 76 | 76 | |
| 77 | 77 | int x = input_port_read(machine, (offset & 1) ? "AN1" : "AN0"); |
| r3232 | r3233 | |
|---|---|---|
| 126 | 126 | |
| 127 | 127 | static void vsync_callback(void) |
| 128 | 128 | { |
| 129 | /* only clock the disc every other frame */ | |
| 130 | laserdisc_vsync(laserdisc); | |
| 131 | ||
| 132 | 129 | /* if we have data available, set a timer to read it */ |
| 133 | 130 | if (!serial_timer_active && laserdisc_line_r(laserdisc, LASERDISC_LINE_DATA_AVAIL) == ASSERT_LINE) |
| 134 | 131 | { |
| r3232 | r3233 | |
| 400 | 397 | MDRV_MACHINE_RESET(alg) |
| 401 | 398 | MDRV_NVRAM_HANDLER(generic_0fill) |
| 402 | 399 | |
| 403 | MDRV_LASERDISC_ADD("laserdisc", SONY_LDP1450) | |
| 400 | MDRV_LASERDISC_ADD("laserdisc", SONY_LDP1450, "main", "ldsound") | |
| 404 | 401 | MDRV_LASERDISC_OVERLAY(amiga, 512*2, 262, BITMAP_FORMAT_INDEXED16) |
| 405 | 402 | MDRV_LASERDISC_OVERLAY_CLIP((129-8)*2, (449+8-1)*2, 44-8, 244+8-1) |
| 406 | 403 | |
| r3232 | r3233 | |
| 425 | 422 | MDRV_SOUND_ROUTE(2, "right", 0.25) |
| 426 | 423 | MDRV_SOUND_ROUTE(3, "left", 0.25) |
| 427 | 424 | |
| 428 | MDRV_SOUND_ADD("l | |
| 425 | MDRV_SOUND_ADD("l | |
| 429 | 426 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 430 | 427 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 431 | 428 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 663 | 660 | |
| 664 | 661 | /* set up memory */ |
| 665 | 662 | memory_configure_bank(1, 0, 1, amiga_chip_ram, 0); |
| 666 | memory_configure_bank(1, 1, 1, memory_region( | |
| 663 | memory_configure_bank(1, 1, 1, memory_region(machine, "user1"), 0); | |
| 667 | 664 | } |
| 668 | 665 | |
| 669 | 666 |
| r3232 | r3233 | |
|---|---|---|
| 172 | 172 | { |
| 173 | 173 | int delta, sign, magnitude; |
| 174 | 174 | UINT8 newval; |
| 175 | static const char *portnames[] = { "TRACK0_Y", "TRACK0_X", "TRACK1_Y", "TRACK1_X" }; | |
| 175 | static const char *const portnames[] = { "TRACK0_Y", "TRACK0_X", "TRACK1_Y", "TRACK1_X" }; | |
| 176 | 176 | |
| 177 | 177 | /* first read the new trackball value and compute the signed delta */ |
| 178 | 178 | newval = input_port_read(machine, portnames[offset + 2 * gridlee_cocktail_flip]); |
| r3232 | r3233 | |
|---|---|---|
| 631 | 631 | * |
| 632 | 632 | *************************************/ |
| 633 | 633 | |
| 634 | INLINE void generic_decode(const char *tag, int bit7, int bit6, int bit5, int bit4, int bit3, int bit2, int bit1, int bit0) | |
| 634 | INLINE void generic_decode(running_machine *machine, const char *tag, int bit7, int bit6, int bit5, int bit4, int bit3, int bit2, int bit1, int bit0) | |
| 635 | 635 | { |
| 636 | UINT16 *rom = (UINT16 *)memory_region( | |
| 636 | UINT16 *rom = (UINT16 *)memory_region(machine, tag); | |
| 637 | 637 | int i; |
| 638 | 638 | |
| 639 | 639 | /* only the low byte of ROMs are encrypted in these games */ |
| r3232 | r3233 | |
| 671 | 671 | |
| 672 | 672 | /* set up memory */ |
| 673 | 673 | memory_configure_bank(1, 0, 1, amiga_chip_ram, 0); |
| 674 | memory_configure_bank(1, 1, 1, memory_region( | |
| 674 | memory_configure_bank(1, 1, 1, memory_region(machine, "user1"), 0); | |
| 675 | 675 | |
| 676 | 676 | /* OnePlay bios is encrypted, TenPlay is not */ |
| 677 | biosrom = (UINT16 *)memory_region( | |
| 677 | biosrom = (UINT16 *)memory_region(machine, "user2"); | |
| 678 | 678 | if (biosrom[0] != 0x4afc) |
| 679 | generic_decode("user2", 6, 1, 0, 2, 3, 4, 5, 7); | |
| 679 | generic_decode(machine, "user2", 6, 1, 0, 2, 3, 4, 5, 7); | |
| 680 | 680 | } |
| 681 | 681 | |
| 682 | 682 | |
| r3232 | r3233 | |
| 688 | 688 | *************************************/ |
| 689 | 689 | |
| 690 | 690 | static DRIVER_INIT( none ) { arcadia_init(machine); } |
| 691 | static DRIVER_INIT( airh ) { generic_decode("user3", 5, 0, 2, 4, 7, 6, 1, 3); arcadia_init(machine); } | |
| 692 | static DRIVER_INIT( bowl ) { generic_decode("user3", 7, 6, 0, 1, 2, 3, 4, 5); arcadia_init(machine); } | |
| 693 | static DRIVER_INIT( dart ) { generic_decode("user3", 4, 0, 7, 6, 3, 1, 2, 5); arcadia_init(machine); } | |
| 694 | static DRIVER_INIT( ldrba ) { generic_decode("user3", 2, 3, 4, 1, 0, 7, 5, 6); arcadia_init(machine); } | |
| 695 | static DRIVER_INIT( ninj ) { generic_decode("user3", 1, 6, 5, 7, 4, 2, 0, 3); arcadia_init(machine); } | |
| 696 | static DRIVER_INIT( rdwr ) { generic_decode("user3", 3, 1, 6, 4, 0, 5, 2, 7); arcadia_init(machine); } | |
| 697 | static DRIVER_INIT( sdwr ) { generic_decode("user3", 6, 3, 4, 5, 2, 1, 0, 7); arcadia_init(machine); } | |
| 698 | static DRIVER_INIT( socc ) { generic_decode("user3", 0, 7, 1, 6, 5, 4, 3, 2); arcadia_init(machine); } | |
| 699 | static DRIVER_INIT( sprg ) { generic_decode("user3", 4, 7, 3, 0, 6, 5, 2, 1); arcadia_init(machine); } | |
| 700 | static DRIVER_INIT( xeon ) { generic_decode("user3", 3, 1, 2, 4, 0, 5, 6, 7); arcadia_init(machine); } | |
| 691 | static DRIVER_INIT( airh ) { generic_decode(machine, "user3", 5, 0, 2, 4, 7, 6, 1, 3); arcadia_init(machine); } | |
| 692 | static DRIVER_INIT( bowl ) { generic_decode(machine, "user3", 7, 6, 0, 1, 2, 3, 4, 5); arcadia_init(machine); } | |
| 693 | static DRIVER_INIT( dart ) { generic_decode(machine, "user3", 4, 0, 7, 6, 3, 1, 2, 5); arcadia_init(machine); } | |
| 694 | static DRIVER_INIT( ldrba ) { generic_decode(machine, "user3", 2, 3, 4, 1, 0, 7, 5, 6); arcadia_init(machine); } | |
| 695 | static DRIVER_INIT( ninj ) { generic_decode(machine, "user3", 1, 6, 5, 7, 4, 2, 0, 3); arcadia_init(machine); } | |
| 696 | static DRIVER_INIT( rdwr ) { generic_decode(machine, "user3", 3, 1, 6, 4, 0, 5, 2, 7); arcadia_init(machine); } | |
| 697 | static DRIVER_INIT( sdwr ) { generic_decode(machine, "user3", 6, 3, 4, 5, 2, 1, 0, 7); arcadia_init(machine); } | |
| 698 | static DRIVER_INIT( socc ) { generic_decode(machine, "user3", 0, 7, 1, 6, 5, 4, 3, 2); arcadia_init(machine); } | |
| 699 | static DRIVER_INIT( sprg ) { generic_decode(machine, "user3", 4, 7, 3, 0, 6, 5, 2, 1); arcadia_init(machine); } | |
| 700 | static DRIVER_INIT( xeon ) { generic_decode(machine, "user3", 3, 1, 2, 4, 0, 5, 6, 7); arcadia_init(machine); } | |
| 701 | 701 | |
| 702 | 702 | |
| 703 | 703 |
| r3232 | r3233 | |
|---|---|---|
| 1705 | 1705 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90) |
| 1706 | 1706 | |
| 1707 | 1707 | /* discrete circuit on the 54XX outputs */ |
| 1708 | MDRV_SOUND_ADD(" | |
| 1708 | MDRV_SOUND_ADD("discrete", DISCRETE, 0) | |
| 1709 | 1709 | MDRV_SOUND_CONFIG_DISCRETE(bosco) |
| 1710 | 1710 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90) |
| 1711 | 1711 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 1760 | 1760 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90 * 10.0 / 16.0) |
| 1761 | 1761 | |
| 1762 | 1762 | /* discrete circuit on the 54XX outputs */ |
| 1763 | MDRV_SOUND_ADD(" | |
| 1763 | MDRV_SOUND_ADD("discrete", DISCRETE, 0) | |
| 1764 | 1764 | MDRV_SOUND_CONFIG_DISCRETE(galaga) |
| 1765 | 1765 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90) |
| 1766 | 1766 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 1776 | 1776 | MDRV_CPU_PROGRAM_MAP(readmem4_galaga,writemem4_galaga) |
| 1777 | 1777 | |
| 1778 | 1778 | /* sound hardware */ |
| 1779 | MDRV_SOUND_REMOVE(" | |
| 1779 | MDRV_SOUND_REMOVE("discrete") | |
| 1780 | 1780 | MACHINE_DRIVER_END |
| 1781 | 1781 | |
| 1782 | 1782 | |
| r3232 | r3233 | |
| 1833 | 1833 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90 * 10.0 / 16.0) |
| 1834 | 1834 | |
| 1835 | 1835 | /* discrete circuit on the 54XX outputs */ |
| 1836 | MDRV_SOUND_ADD(" | |
| 1836 | MDRV_SOUND_ADD("discrete", DISCRETE, 0) | |
| 1837 | 1837 | MDRV_SOUND_CONFIG_DISCRETE(galaga) |
| 1838 | 1838 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90) |
| 1839 | 1839 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
| 1856 | 1856 | MDRV_PALETTE_INIT(battles) |
| 1857 | 1857 | |
| 1858 | 1858 | /* sound hardware */ |
| 1859 | MDRV_SOUND_REMOVE(" | |
| 1859 | MDRV_SOUND_REMOVE("discrete") | |
| 1860 | 1860 | |
| 1861 | 1861 | MDRV_SOUND_ADD("samples", SAMPLES, 0) |
| 1862 | 1862 | MDRV_SOUND_CONFIG(battles_samples_interface) |
| r3232 | r3233 | |
|---|---|---|
| 393 | 393 | ROM_LOAD16_BYTE("2.19m", 0x0f0000, 0x08000, CRC(3d48b0b5) SHA1(a6e8b38971a8964af463c16f32bb7dbd301dd314) ) |
| 394 | 394 | ROM_LOAD16_BYTE("1.19n", 0x0f0001, 0x08000, CRC(674131b9) SHA1(63499cd5ad39e79e70f3ba7060680f0aa133f095) ) |
| 395 | 395 | |
| 396 | ROM_REGION( 0x10000, " | |
| 396 | ROM_REGION( 0x10000, "t5182", 0 ) /* Toshiba T5182 module */ | |
| 397 | 397 | ROM_LOAD( "t5182.rom", 0x0000, 0x2000, CRC(d354c8fc) SHA1(a1c9e1ac293f107f69cc5788cf6abc3db1646e33) ) |
| 398 | 398 | ROM_LOAD( "22d.bin", 0x8000, 0x8000, CRC(eb1a46e1) SHA1(278859ae4bca9f421247e646d789fa1206dcd8fc) ) |
| 399 | 399 |
| r3232 | r3233 | |
|---|---|---|
| 315 | 315 | |
| 316 | 316 | /* Interrupt presumably comes from the LDP's status strobe */ |
| 317 | 317 | cpunum_set_input_line(machine, 2, 0, ASSERT_LINE); |
| 318 | ||
| 319 | /* Only do the LDP's sync once */ | |
| 320 | if (cpunum == 0) | |
| 321 | laserdisc_vsync(laserdisc); | |
| 322 | 318 | } |
| 323 | 319 | |
| 324 | 320 | |
| r3232 | r3233 | |
| 342 | 338 | |
| 343 | 339 | MDRV_MACHINE_START(istellar) |
| 344 | 340 | |
| 345 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 341 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 346 | 342 | MDRV_LASERDISC_OVERLAY(istellar, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 347 | 343 | |
| 348 | 344 | /* video hardware */ |
| r3232 | r3233 | |
| 356 | 352 | /* sound hardware */ |
| 357 | 353 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 358 | 354 | |
| 359 | MDRV_SOUND_ADD("l | |
| 355 | MDRV_SOUND_ADD("l | |
| 360 | 356 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 361 | 357 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 362 | 358 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 2958 | 2958 | MDRV_SCREEN_SIZE(512, 256) |
| 2959 | 2959 | MDRV_SCREEN_VISIBLE_AREA(0, 512-1, 16, 240-1) |
| 2960 | 2960 | |
| 2961 | MDRV_SCREEN_ADD(" | |
| 2961 | MDRV_SCREEN_ADD("lcd0", RASTER) | |
| 2962 | 2962 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 2963 | 2963 | MDRV_SCREEN_REFRESH_RATE(60) |
| 2964 | 2964 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| 2965 | 2965 | MDRV_SCREEN_SIZE(480, 64) |
| 2966 | 2966 | MDRV_SCREEN_VISIBLE_AREA(0, 480-1, 0, 64-1) |
| 2967 | 2967 | |
| 2968 | MDRV_SCREEN_ADD(" | |
| 2968 | MDRV_SCREEN_ADD("lcd1", RASTER) | |
| 2969 | 2969 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 2970 | 2970 | MDRV_SCREEN_REFRESH_RATE(60) |
| 2971 | 2971 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| r3232 | r3233 | |
|---|---|---|
| 236 | 236 | } |
| 237 | 237 | |
| 238 | 238 | |
| 239 | static INT32 banknum | |
| 239 | static INT32 banknum | |
| 240 | 240 | |
| 241 | 241 | static void reset_sound_region(running_machine *machine) |
| 242 | 242 | { |
| r3232 | r3233 | |
| 564 | 564 | reset_sound_region(machine); |
| 565 | 565 | } |
| 566 | 566 | |
| 567 | static MACHINE_RESET( taitoh ) | |
| 568 | { | |
| 569 | banknum = -1; | |
| 570 | } | |
| 571 | ||
| 567 | 572 | static MACHINE_START( taitoh ) |
| 568 | 573 | { |
| 569 | 574 | state_save_register_global(banknum); |
| r3232 | r3233 | |
| 582 | 587 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 583 | 588 | |
| 584 | 589 | MDRV_MACHINE_START(taitoh) |
| 590 | MDRV_MACHINE_RESET(taitoh) | |
| 585 | 591 | |
| 586 | 592 | MDRV_INTERLEAVE(10) |
| 587 | 593 | |
| r3232 | r3233 | |
| 621 | 627 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 622 | 628 | |
| 623 | 629 | MDRV_MACHINE_START(taitoh) |
| 630 | MDRV_MACHINE_RESET(taitoh) | |
| 624 | 631 | |
| 625 | 632 | MDRV_INTERLEAVE(10) |
| 626 | 633 | |
| r3232 | r3233 | |
| 660 | 667 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 661 | 668 | |
| 662 | 669 | MDRV_MACHINE_START(taitoh) |
| 670 | MDRV_MACHINE_RESET(taitoh) | |
| 663 | 671 | |
| 664 | 672 | MDRV_INTERLEAVE(10) |
| 665 | 673 |
| r3232 | r3233 | |
|---|---|---|
| 433 | 433 | SOUND |
| 434 | 434 | *****************************************/ |
| 435 | 435 | |
| 436 | static INT32 banknum | |
| 436 | static INT32 banknum | |
| 437 | 437 | |
| 438 | 438 | static void reset_sound_region(running_machine *machine) |
| 439 | 439 | { |
| r3232 | r3233 | |
| 447 | 447 | |
| 448 | 448 | static MACHINE_START( othunder ) |
| 449 | 449 | { |
| 450 | banknum = -1; | |
| 450 | 451 | state_save_register_global(banknum); |
| 451 | 452 | state_save_register_postload(machine, othunder_postload, NULL); |
| 452 | 453 | } |
| r3232 | r3233 | |
|---|---|---|
| 211 | 211 | |
| 212 | 212 | static READ16_HANDLER( opwolf3_adc_r ) |
| 213 | 213 | { |
| 214 | static const char *adcnames[] = { "GUN1X", "GUN1Y", "GUN2X", "GUN2Y" }; | |
| 214 | static const char *const adcnames[] = { "GUN1X", "GUN1Y", "GUN2X", "GUN2Y" }; | |
| 215 | 215 | |
| 216 | 216 | return input_port_read(machine, adcnames[offset]) << 8; |
| 217 | 217 | } |
| r3232 | r3233 | |
| 226 | 226 | SOUND |
| 227 | 227 | *****************************************************/ |
| 228 | 228 | |
| 229 | static INT32 banknum | |
| 229 | static INT32 banknum | |
| 230 | 230 | |
| 231 | 231 | static void reset_sound_region(running_machine *machine) |
| 232 | 232 | { |
| r3232 | r3233 | |
| 240 | 240 | |
| 241 | 241 | static MACHINE_START( slapshot ) |
| 242 | 242 | { |
| 243 | banknum = -1; | |
| 243 | 244 | state_save_register_global(banknum); |
| 244 | 245 | state_save_register_postload(machine, slapshot_postload, NULL); |
| 245 | 246 | } |
| r3232 | r3233 | |
|---|---|---|
| 209 | 209 | { |
| 210 | 210 | int shift = 4 * (offset & 1); |
| 211 | 211 | int port = offset & 2; |
| 212 | static const char *portnames[] = { "DSWA", "DSWB", "IN0", "IN1" }; | |
| 212 | static const char *const portnames[] = { "DSWA", "DSWB", "IN0", "IN1" }; | |
| 213 | 213 | int r = (input_port_read(machine, portnames[port]) << shift) & 0xf0; |
| 214 | 214 | r |= (input_port_read(machine, portnames[port+1]) >> (4-shift)) & 0x0f; |
| 215 | 215 |
| r3232 | r3233 | |
|---|---|---|
| 74 | 74 | static READ8_HANDLER( turtship_ports_r ) |
| 75 | 75 | { |
| 76 | 76 | int i,res; |
| 77 | static const char *portnames[] = { "SYSTEM", "P1", "P2", "DSW0", "DSW1", "NOT_PRESENT", "NOT_PRESENT", "NOT_PRESENT" }; // only inputs 0-4 are present | |
| 77 | static const char *const portnames[] = { "SYSTEM", "P1", "P2", "DSW0", "DSW1", "NOT_PRESENT", "NOT_PRESENT", "NOT_PRESENT" }; // only inputs 0-4 are present | |
| 78 | 78 | |
| 79 | 79 | res = 0; |
| 80 | 80 | for (i = 0;i < 8;i++) |
| r3232 | r3233 | |
| 226 | 226 | AM_RANGE(0xf800, 0xffff) AM_WRITE(SMH_RAM) |
| 227 | 227 | ADDRESS_MAP_END |
| 228 | 228 | |
| 229 | static ADDRESS_MAP_START( whizz_ | |
| 229 | static ADDRESS_MAP_START( whizz_io_ma | |
| 230 | 230 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 231 | AM_RANGE(0x01, 0x01) AM_READ(ym2151_status_port_0_r) | |
| 232 | AM_RANGE(0xc0, 0xc0) AM_READ(soundlatch_r) | |
| 233 | ADDRESS_MAP_END | |
| 234 | ||
| 235 | static ADDRESS_MAP_START( whizz_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 236 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 237 | 231 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2151_register_port_0_w) |
| 238 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2151_data_port_0_w) | |
| 232 | AM_RANGE(0x01, 0x01) AM_READWRITE(ym2151_status_port_0_r, ym2151_data_port_0_w) | |
| 239 | 233 | AM_RANGE(0x40, 0x40) AM_WRITE(SMH_NOP) |
| 234 | AM_RANGE(0xc0, 0xc0) AM_READ(soundlatch_r) | |
| 240 | 235 | ADDRESS_MAP_END |
| 241 | 236 | |
| 242 | 237 | |
| r3232 | r3233 | |
| 814 | 809 | |
| 815 | 810 | MDRV_CPU_ADD("audio", Z80, 4000000) |
| 816 | 811 | MDRV_CPU_PROGRAM_MAP(whizz_sound_readmem,whizz_sound_writemem) |
| 817 | MDRV_CPU_IO_MAP(whizz_ | |
| 812 | MDRV_CPU_IO_MAP(whizz_ | |
| 818 | 813 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 819 | 814 | |
| 820 | 815 | MDRV_INTERLEAVE(1000) |
| r3232 | r3233 | |
| 1228 | 1223 | GAME( 1989, whizz, twinfalc, whizz, whizz, whizz, ROT0, "Philko", "Whizz", 0 ) |
| 1229 | 1224 | |
| 1230 | 1225 | |
| 1226 |
| r3232 | r3233 | |
|---|---|---|
| 393 | 393 | |
| 394 | 394 | /**************************************************************************/ |
| 395 | 395 | |
| 396 | static INT32 banknum | |
| 396 | static INT32 banknum | |
| 397 | 397 | |
| 398 | 398 | static void reset_sound_region(running_machine *machine) |
| 399 | 399 | { |
| r3232 | r3233 | |
| 986 | 986 | |
| 987 | 987 | static MACHINE_START( taitox ) |
| 988 | 988 | { |
| 989 | banknum = -1; | |
| 989 | 990 | state_save_register_global(banknum); |
| 990 | 991 | state_save_register_postload(machine, taitox_postload, NULL); |
| 991 | 992 | } |
| r3232 | r3233 | |
|---|---|---|
| 193 | 193 | AM_RANGE(0x6000, 0x6fff) AM_WRITE(SMH_NOP) /* R/C filter ??? */ |
| 194 | 194 | ADDRESS_MAP_END |
| 195 | 195 | |
| 196 | ||
| 197 | static ADDRESS_MAP_START( sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 196 | static ADDRESS_MAP_START( sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 198 | 197 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 199 | AM_RANGE(0x40, 0x40) AM_READ(ay8910_read_port_0_r) | |
| 200 | ADDRESS_MAP_END | |
| 201 | ||
| 202 | static ADDRESS_MAP_START( sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 203 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 198 | AM_RANGE(0x40, 0x40) AM_READWRITE(ay8910_read_port_0_r, ay8910_write_port_0_w) | |
| 204 | 199 | AM_RANGE(0x80, 0x80) AM_WRITE(ay8910_control_port_0_w) |
| 205 | AM_RANGE(0x40, 0x40) AM_WRITE(ay8910_write_port_0_w) | |
| 206 | 200 | ADDRESS_MAP_END |
| 207 | 201 | |
| 208 | 202 | |
| r3232 | r3233 | |
| 866 | 860 | |
| 867 | 861 | MDRV_CPU_ADD("audio", Z80,18000000/12) /* 1.5 MHz */ |
| 868 | 862 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 869 | MDRV_CPU_IO_MAP(sound_ | |
| 863 | MDRV_CPU_IO_MAP(sound_i | |
| 870 | 864 | |
| 871 | 865 | /* video hardware */ |
| 872 | 866 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 1337 | 1331 | ROM_END |
| 1338 | 1332 | |
| 1339 | 1333 | |
| 1340 | static void treahunt_decode( | |
| 1334 | static void treahunt_decode(running_machine *machine) | |
| 1341 | 1335 | { |
| 1342 | 1336 | int A; |
| 1343 | UINT8 *rom = memory_region( | |
| 1337 | UINT8 *rom = memory_region(machine, "main"); | |
| 1344 | 1338 | UINT8 *decrypt = auto_malloc(0x4000); |
| 1345 | 1339 | int data; |
| 1346 | 1340 | |
| r3232 | r3233 | |
| 1389 | 1383 | static DRIVER_INIT( treahunt ) |
| 1390 | 1384 | { |
| 1391 | 1385 | timer_rate = 128; |
| 1392 | treahunt_decode(); | |
| 1386 | treahunt_decode(machine); | |
| 1393 | 1387 | } |
| 1394 | 1388 | |
| 1395 | 1389 | static DRIVER_INIT( zzyzzyxx ) |
| r3232 | r3233 | |
| 1463 | 1457 | GAME( 1986, joinem, 0, joinem, joinem, zzyzzyxx, ROT90, "Global Corporation", "Joinem", 0 ) |
| 1464 | 1458 | GAME( 1983, loverboy, 0, loverboy,loverboy, loverboy, ROT90, "G.T Enterprise Inc", "Lover Boy", 0 ) |
| 1465 | 1459 | GAME( 1985, striv, 0, jack, striv, striv, ROT270,"Hara Industries", "Super Triv", GAME_IMPERFECT_SOUND | GAME_IMPERFECT_COLORS ) |
| 1460 |
| r3232 | r3233 | |
|---|---|---|
| 225 | 225 | AM_RANGE(0xfc07, 0xfc07) AM_WRITE(tsamurai_textbank2_w)/* Mission 660 uses a bit here */ |
| 226 | 226 | ADDRESS_MAP_END |
| 227 | 227 | |
| 228 | static ADDRESS_MAP_START( z80_ | |
| 228 | static ADDRESS_MAP_START( z80_io_ma | |
| 229 | 229 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 230 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_control_port_0_w) | |
| 231 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_write_port_0_w) | |
| 230 | 232 | ADDRESS_MAP_END |
| 231 | 233 | |
| 232 | static ADDRESS_MAP_START( z80_ | |
| 234 | static ADDRESS_MAP_START( z80_m660_i | |
| 233 | 235 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 234 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_control_port_0_w) | |
| 235 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_write_port_0_w) | |
| 236 | AM_RANGE(0x00, 0x00) AM_WRITE(SMH_NOP) /* ? */ | |
| 237 | AM_RANGE(0x01, 0x01) AM_WRITE(SMH_NOP) /* Written continuously. Increments with level. */ | |
| 238 | AM_RANGE(0x02, 0x02) AM_WRITE(SMH_NOP) /* Always follows above with 0x01 data */ | |
| 236 | 239 | ADDRESS_MAP_END |
| 237 | 240 | |
| 238 | static ADDRESS_MAP_START( | |
| 241 | static ADDRESS_MAP_START( vsgongf_audi | |
| 239 | 242 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 240 | AM_RANGE(0x00, 0x00) AM_WRITE(SMH_NOP) /* ? */ | |
| 241 | AM_RANGE(0x01, 0x01) AM_WRITE(SMH_NOP) /* Written continuously. Increments with level. */ | |
| 242 | AM_RANGE(0x02, 0x02) AM_WRITE(SMH_NOP) /* Always follows above with 0x01 data */ | |
| 243 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_control_port_0_w) | |
| 244 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_write_port_0_w) | |
| 243 | 245 | ADDRESS_MAP_END |
| 244 | 246 | |
| 245 | 247 | static READ8_HANDLER( sound_command1_r ) |
| r3232 | r3233 | |
| 326 | 328 | |
| 327 | 329 | /*******************************************************************************/ |
| 328 | 330 | |
| 329 | static ADDRESS_MAP_START( | |
| 331 | static ADDRESS_MAP_START( | |
| 330 | 332 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 331 | ADDRESS_MAP_END | |
| 332 | ||
| 333 | static ADDRESS_MAP_START( writeport_sound3_m660, ADDRESS_SPACE_IO, 8 ) | |
| 334 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 335 | 333 | AM_RANGE(0x00, 0x00) AM_WRITE(ay8910_control_port_0_w) |
| 336 | 334 | AM_RANGE(0x01, 0x01) AM_WRITE(ay8910_write_port_0_w) |
| 337 | 335 | ADDRESS_MAP_END |
| r3232 | r3233 | |
| 735 | 733 | /* basic machine hardware */ |
| 736 | 734 | MDRV_CPU_ADD("main", Z80, 4000000) |
| 737 | 735 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 738 | MDRV_CPU_IO_MAP(z80_ | |
| 736 | MDRV_CPU_IO_MAP(z80_io_ma | |
| 739 | 737 | MDRV_CPU_VBLANK_INT("main", samurai_interrupt) |
| 740 | 738 | |
| 741 | 739 | MDRV_CPU_ADD("audio", Z80, 2000000) |
| r3232 | r3233 | |
| 778 | 776 | /* basic machine hardware */ |
| 779 | 777 | MDRV_CPU_ADD("main", Z80, 4000000) |
| 780 | 778 | MDRV_CPU_PROGRAM_MAP(readmem_m660,writemem_m660) |
| 781 | MDRV_CPU_IO_MAP(z80_ | |
| 779 | MDRV_CPU_IO_MAP(z80_m66 | |
| 782 | 780 | MDRV_CPU_VBLANK_INT("main", samurai_interrupt) |
| 783 | 781 | |
| 784 | 782 | MDRV_CPU_ADD("audio", Z80, 2000000) |
| r3232 | r3233 | |
| 789 | 787 | |
| 790 | 788 | MDRV_CPU_ADD("audio3", Z80, 2000000) |
| 791 | 789 | MDRV_CPU_PROGRAM_MAP(readmem_sound3_m660,writemem_sound3_m660) |
| 792 | MDRV_CPU_IO_MAP( | |
| 790 | MDRV_CPU_IO_MAP( | |
| 793 | 791 | MDRV_CPU_VBLANK_INT("main", nmi_line_pulse) |
| 794 | 792 | |
| 795 | 793 | /* video hardware */ |
| r3232 | r3233 | |
| 830 | 828 | |
| 831 | 829 | MDRV_CPU_ADD("audio", Z80, 4000000) |
| 832 | 830 | MDRV_CPU_PROGRAM_MAP(readmem_sound_vsgongf,writemem_sound_vsgongf) |
| 833 | MDRV_CPU_IO_MAP( | |
| 831 | MDRV_CPU_IO_MAP(vsgongf_audi | |
| 834 | 832 | MDRV_CPU_VBLANK_INT_HACK(vsgongf_sound_interrupt,3) |
| 835 | 833 | |
| 836 | 834 | /* video hardware */ |
| r3232 | r3233 | |
| 1273 | 1271 | GAME( 1986, m660j, m660, m660, m660, 0, ROT90, "[Woodplace Inc.] Taito Corporation", "Mission 660 (Japan)", 0 ) |
| 1274 | 1272 | GAME( 1986, m660b, m660, m660, m660, 0, ROT90, "bootleg", "Mission 660 (bootleg)", 0 ) |
| 1275 | 1273 | GAME( 1986, alphaxz, m660, m660, m660, 0, ROT90, "Ed / Woodplace Inc.", "The Alphax Z (Japan)", 0 ) |
| 1274 | ||
| 1275 |
| r3232 | r3233 | |
|---|---|---|
| 740 | 740 | MDRV_VIDEO_START(tx1) |
| 741 | 741 | MDRV_VIDEO_UPDATE(tx1) |
| 742 | 742 | |
| 743 | MDRV_SPEAKER_STANDARD_STEREO("Front Left", "Front Right") | |
| 744 | // MDRV_SPEAKER_STANDARD_STEREO("Rear Left", "Rear Right") | |
| 743 | MDRV_SPEAKER_STANDARD_STEREO("frontleft", "frontright") | |
| 744 | // MDRV_SPEAKER_STANDARD_STEREO("rearleft", "rearright") | |
| 745 | 745 | |
| 746 | 746 | MDRV_SOUND_ADD("ay", AY8910, TX1_PIXEL_CLOCK / 8) |
| 747 | 747 | MDRV_SOUND_CONFIG(tx1_ay8910_interface) |
| 748 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "Front Left", 0.1) | |
| 749 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "Front Right", 0.1) | |
| 748 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontleft", 0.1) | |
| 749 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontright", 0.1) | |
| 750 | 750 | |
| 751 | 751 | MDRV_SOUND_ADD("tx1", CUSTOM, 0) |
| 752 | 752 | MDRV_SOUND_CONFIG(tx1_custom_interface) |
| 753 | MDRV_SOUND_ROUTE(0, "Front Left", 0.2) | |
| 754 | MDRV_SOUND_ROUTE(1, "Front Right", 0.2) | |
| 753 | MDRV_SOUND_ROUTE(0, "frontleft", 0.2) | |
| 754 | MDRV_SOUND_ROUTE(1, "frontright", 0.2) | |
| 755 | 755 | MACHINE_DRIVER_END |
| 756 | 756 | |
| 757 | 757 | |
| r3232 | r3233 | |
| 795 | 795 | MDRV_VIDEO_START(buggyboy) |
| 796 | 796 | MDRV_VIDEO_UPDATE(buggyboy) |
| 797 | 797 | |
| 798 | MDRV_SPEAKER_STANDARD_STEREO("Front Left", "Front Right") | |
| 799 | // MDRV_SPEAKER_STANDARD_STEREO("Rear Left", "Rear Right") | |
| 798 | MDRV_SPEAKER_STANDARD_STEREO("frontleft", "frontright") | |
| 799 | // MDRV_SPEAKER_STANDARD_STEREO("rearleft", "rearright") | |
| 800 | 800 | |
| 801 | 801 | MDRV_SOUND_ADD("ym1", YM2149, BUGGYBOY_ZCLK / 4) |
| 802 | 802 | MDRV_SOUND_CONFIG(buggyboy_ym2149_interface_1) |
| 803 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 803 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontl | |
| 804 | 804 | |
| 805 | 805 | MDRV_SOUND_ADD("ym2", YM2149, BUGGYBOY_ZCLK / 4) |
| 806 | 806 | MDRV_SOUND_CONFIG(buggyboy_ym2149_interface_2) |
| 807 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 807 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontr | |
| 808 | 808 | |
| 809 | 809 | MDRV_SOUND_ADD("buggyboy", CUSTOM, 0) |
| 810 | 810 | MDRV_SOUND_CONFIG(bb_custom_interface) |
| 811 | MDRV_SOUND_ROUTE(0, "Front Left", 0.2) | |
| 812 | MDRV_SOUND_ROUTE(1, "Front Right", 0.2) | |
| 811 | MDRV_SOUND_ROUTE(0, "frontleft", 0.2) | |
| 812 | MDRV_SOUND_ROUTE(1, "frontright", 0.2) | |
| 813 | 813 | MACHINE_DRIVER_END |
| 814 | 814 | |
| 815 | 815 | |
| r3232 | r3233 | |
| 848 | 848 | MDRV_VIDEO_UPDATE(buggybjr) |
| 849 | 849 | MDRV_VIDEO_EOF(buggyboy) |
| 850 | 850 | |
| 851 | MDRV_SPEAKER_STANDARD_STEREO("Front Left", "Front Right") | |
| 852 | // MDRV_SPEAKER_STANDARD_STEREO("Rear Left", "Rear Right") | |
| 851 | MDRV_SPEAKER_STANDARD_STEREO("frontleft", "frontright") | |
| 852 | // MDRV_SPEAKER_STANDARD_STEREO("rearleft", "rearright") | |
| 853 | 853 | |
| 854 | 854 | MDRV_SOUND_ADD("ym1", YM2149, BUGGYBOY_ZCLK / 4) |
| 855 | 855 | MDRV_SOUND_CONFIG(buggyboy_ym2149_interface_1) |
| 856 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 856 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontl | |
| 857 | 857 | |
| 858 | 858 | MDRV_SOUND_ADD("ym2", YM2149, BUGGYBOY_ZCLK / 4) |
| 859 | 859 | MDRV_SOUND_CONFIG(buggyboy_ym2149_interface_2) |
| 860 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, " | |
| 860 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "frontr | |
| 861 | 861 | |
| 862 | 862 | MDRV_SOUND_ADD("buggyboy", CUSTOM, 0) |
| 863 | 863 | MDRV_SOUND_CONFIG(bb_custom_interface) |
| 864 | MDRV_SOUND_ROUTE(0, "Front Left", 0.2) | |
| 865 | MDRV_SOUND_ROUTE(1, "Front Right", 0.2) | |
| 864 | MDRV_SOUND_ROUTE(0, "frontleft", 0.2) | |
| 865 | MDRV_SOUND_ROUTE(1, "frontright", 0.2) | |
| 866 | 866 | MACHINE_DRIVER_END |
| 867 | 867 | |
| 868 | 868 | /************************************* |
| r3232 | r3233 | |
|---|---|---|
| 747 | 747 | device_set_info_int(laserdisc, LDINFO_INT_TYPE, newtype); |
| 748 | 748 | } |
| 749 | 749 | |
| 750 | static INTERRUPT_GEN( vblank_callback_thayers ) | |
| 751 | { | |
| 752 | laserdisc_vsync(laserdisc); | |
| 753 | } | |
| 754 | ||
| 755 | 750 | /* COP400 Interface */ |
| 756 | 751 | |
| 757 | 752 | static COP400_INTERFACE( thayers_cop_intf ) |
| r3232 | r3233 | |
| 768 | 763 | MDRV_CPU_ADD("main", Z80, XTAL_4MHz) |
| 769 | 764 | MDRV_CPU_PROGRAM_MAP(thayers_map, 0) |
| 770 | 765 | MDRV_CPU_IO_MAP(thayers_io_map, 0) |
| 771 | MDRV_CPU_VBLANK_INT("main", vblank_callback_thayers) | |
| 772 | 766 | |
| 773 | 767 | MDRV_CPU_ADD("mcu", COP421, XTAL_4MHz/2) // COP421L-PCA/N |
| 774 | 768 | MDRV_CPU_PROGRAM_MAP(thayers_cop_map, 0) |
| r3232 | r3233 | |
| 778 | 772 | MDRV_MACHINE_START(thayers) |
| 779 | 773 | MDRV_MACHINE_RESET(thayers) |
| 780 | 774 | |
| 781 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR7820) | |
| 775 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR7820, "main", "ldsound") | |
| 782 | 776 | |
| 783 | 777 | /* video hardware */ |
| 784 | 778 | MDRV_LASERDISC_SCREEN_ADD_NTSC("main", BITMAP_FORMAT_RGB32) |
| r3232 | r3233 | |
| 786 | 780 | MDRV_PALETTE_LENGTH(256) |
| 787 | 781 | |
| 788 | 782 | /* sound hardware */ |
| 783 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") | |
| 789 | 784 | // SSI 263 @ 2MHz |
| 785 | ||
| 786 | MDRV_SOUND_ADD("ldsound", CUSTOM, 0) | |
| 787 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) | |
| 788 | MDRV_SOUND_ROUTE(0, "left", 1.0) | |
| 789 | MDRV_SOUND_ROUTE(1, "right", 1.0) | |
| 790 | 790 | MACHINE_DRIVER_END |
| 791 | 791 | |
| 792 | 792 | /* ROMs */ |
| r3232 | r3233 | |
|---|---|---|
| 45 | 45 | VIDEO_UPDATE( ssrj ); |
| 46 | 46 | PALETTE_INIT( ssrj ); |
| 47 | 47 | |
| 48 | static int oldport | |
| 48 | static int oldport | |
| 49 | 49 | |
| 50 | 50 | static MACHINE_RESET(ssrj) |
| 51 | 51 | { |
| r3232 | r3233 | |
|---|---|---|
| 62 | 62 | |
| 63 | 63 | static READ16_HANDLER( inputs_r ) |
| 64 | 64 | { |
| 65 | static const char *iptnames[] = { "IN0", "IN1" }; | |
| 65 | static const char *const iptnames[] = { "IN0", "IN1" }; | |
| 66 | 66 | int temp = input_port_read(machine, iptnames[offset & 1]); |
| 67 | 67 | |
| 68 | 68 | if (atarigen_cpu_to_sound_ready) temp ^= 0x0040; |
| r3232 | r3233 | |
|---|---|---|
| 167 | 167 | |
| 168 | 168 | static READ16_HANDLER(cyclwarr_input_r) |
| 169 | 169 | { |
| 170 | static const char *port[] = { "SERVICE", "P1", "P2", "DSW3" }; | |
| 170 | static const char *const port[] = { "SERVICE", "P1", "P2", "DSW3" }; | |
| 171 | 171 | return input_port_read(machine, port[offset]); |
| 172 | 172 | } |
| 173 | 173 | |
| 174 | 174 | static READ16_HANDLER(cyclwarr_input2_r) |
| 175 | 175 | { |
| 176 | static const char *port2[] = { "DSW1", "DSW2", "P3", "P4" }; | |
| 176 | static const char *const port2[] = { "DSW1", "DSW2", "P3", "P4" }; | |
| 177 | 177 | return input_port_read(machine, port2[offset]); |
| 178 | 178 | } |
| 179 | 179 |
| r3232 | r3233 | |
|---|---|---|
| 561 | 561 | |
| 562 | 562 | static READ8_HANDLER( bank_r ) |
| 563 | 563 | { |
| 564 | UINT8* bank = memory_region(machine, "m | |
| 564 | UINT8* bank = memory_region(machine, "m | |
| 565 | 565 | UINT8* game = memory_region(machine, "main"); |
| 566 | 566 | |
| 567 | 567 | if(game_banksel == 0x142) // Genesis I/O |
| r3232 | r3233 | |
| 789 | 789 | |
| 790 | 790 | /* The Megaplay has an extra BIOS cpu which drives an SMS VDP |
| 791 | 791 | which includes an SN76496 for sound */ |
| 792 | MDRV_CPU_ADD("m | |
| 792 | MDRV_CPU_ADD("m | |
| 793 | 793 | MDRV_CPU_PROGRAM_MAP(megaplay_bios_readmem, megaplay_bios_writemem) |
| 794 | 794 | MDRV_CPU_IO_MAP(megaplay_bios_io_map,0) |
| 795 | 795 | MDRV_CPU_VBLANK_INT_HACK(megaplay_bios_irq, 262) |
| r3232 | r3233 | |
| 822 | 822 | |
| 823 | 823 | ROM_REGION( 0x8000, "user1", ROMREGION_ERASEFF ) |
| 824 | 824 | |
| 825 | ROM_REGION( 0x28000, "m | |
| 825 | ROM_REGION( 0x28000, "m | |
| 826 | 826 | MEGAPLAY_BIOS |
| 827 | 827 | ROM_END |
| 828 | 828 | |
| r3232 | r3233 | |
| 835 | 835 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 836 | 836 | ROM_LOAD( "ep15175-01.ic3", 0x000000, 0x08000, CRC(99246889) SHA1(184aa3b7fdedcf578c5e34edb7ed44f57f832258) ) |
| 837 | 837 | |
| 838 | ROM_REGION( 0x28000, "m | |
| 838 | ROM_REGION( 0x28000, "m | |
| 839 | 839 | MEGAPLAY_BIOS |
| 840 | 840 | ROM_END |
| 841 | 841 | |
| r3232 | r3233 | |
| 851 | 851 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 852 | 852 | ROM_LOAD( "1.ic3", 0x000000, 0x08000, CRC(dac9bf91) SHA1(0117972a7181f8aaf942a259cc8764b821031253) ) |
| 853 | 853 | |
| 854 | ROM_REGION( 0x28000, "m | |
| 854 | ROM_REGION( 0x28000, "m | |
| 855 | 855 | MEGAPLAY_BIOS |
| 856 | 856 | ROM_END |
| 857 | 857 | |
| r3232 | r3233 | |
| 864 | 864 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 865 | 865 | ROM_LOAD( "ep15175-02b.ic3", 0x000000, 0x08000, CRC(3039b653) SHA1(b19874c74d0fc0cca1169f62e5e74f0e8ca83679) ) // 15175-02b.ic3 |
| 866 | 866 | |
| 867 | ROM_REGION( 0x28000, "m | |
| 867 | ROM_REGION( 0x28000, "m | |
| 868 | 868 | MEGAPLAY_BIOS |
| 869 | 869 | ROM_END |
| 870 | 870 | |
| r3232 | r3233 | |
| 877 | 877 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 878 | 878 | ROM_LOAD( "epr-15175-03.ic3", 0x000000, 0x08000, CRC(70ea1aec) SHA1(0d9d82a1f8aa51d02707f7b343e7cfb6591efccd) ) // 15175-02b.ic3 |
| 879 | 879 | |
| 880 | ROM_REGION( 0x28000, "m | |
| 880 | ROM_REGION( 0x28000, "m | |
| 881 | 881 | MEGAPLAY_BIOS |
| 882 | 882 | ROM_END |
| 883 | 883 | |
| r3232 | r3233 | |
| 891 | 891 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 892 | 892 | ROM_LOAD( "ep15175-04.ic3", 0x000000, 0x08000, CRC(faf7c030) SHA1(16ef405335b4d3ecb0b7d97b088dafc4278d4726) ) |
| 893 | 893 | |
| 894 | ROM_REGION( 0x28000, "m | |
| 894 | ROM_REGION( 0x28000, "m | |
| 895 | 895 | MEGAPLAY_BIOS |
| 896 | 896 | ROM_END |
| 897 | 897 | |
| r3232 | r3233 | |
| 903 | 903 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 904 | 904 | ROM_LOAD( "epr-15175-05.ic2", 0x000000, 0x08000, CRC(1df5347c) SHA1(faced2e875e1914392f61577b5256d006eebeef9) ) |
| 905 | 905 | |
| 906 | ROM_REGION( 0x28000, "m | |
| 906 | ROM_REGION( 0x28000, "m | |
| 907 | 907 | MEGAPLAY_BIOS |
| 908 | 908 | ROM_END |
| 909 | 909 | |
| r3232 | r3233 | |
| 915 | 915 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 916 | 916 | ROM_LOAD( "epr-15175-06.ic2", 0x000000, 0x08000, CRC(1ef64e41) SHA1(13984b714b014ea41963b70de74a5358ed223bc5) ) |
| 917 | 917 | |
| 918 | ROM_REGION( 0x28000, "m | |
| 918 | ROM_REGION( 0x28000, "m | |
| 919 | 919 | MEGAPLAY_BIOS |
| 920 | 920 | ROM_END |
| 921 | 921 | |
| r3232 | r3233 | |
| 927 | 927 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 928 | 928 | ROM_LOAD( "epr-15175-07.ic1", 0x000000, 0x08000, CRC(bb5f67f0) SHA1(33b7a5d14015a5fcf41976a8f648f8f48ce9bb03) ) |
| 929 | 929 | |
| 930 | ROM_REGION( 0x28000, "m | |
| 930 | ROM_REGION( 0x28000, "m | |
| 931 | 931 | MEGAPLAY_BIOS |
| 932 | 932 | ROM_END |
| 933 | 933 | |
| r3232 | r3233 | |
| 939 | 939 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 940 | 940 | ROM_LOAD( "epr-15175-11.ic2", 0x000000, 0x08000, CRC(bb651120) SHA1(81cb736f2732373e260dde162249c1d29a3489c3) ) |
| 941 | 941 | |
| 942 | ROM_REGION( 0x28000, "m | |
| 942 | ROM_REGION( 0x28000, "m | |
| 943 | 943 | MEGAPLAY_BIOS |
| 944 | 944 | ROM_END |
| 945 | 945 | |
| r3232 | r3233 | |
| 951 | 951 | ROM_REGION( 0x8000, "user1", 0 ) /* Game Instructions */ |
| 952 | 952 | ROM_LOAD( "epr-15175-09.ic2", 0x000000, 0x08000, CRC(6254e45a) SHA1(8667922a6eade03c964ce224f7fa39ba871c60a4) ) |
| 953 | 953 | |
| 954 | ROM_REGION( 0x28000, "m | |
| 954 | ROM_REGION( 0x28000, "m | |
| 955 | 955 | MEGAPLAY_BIOS |
| 956 | 956 | ROM_END |
| 957 | 957 | |
| 958 | 958 | |
| 959 | 959 | static void megplay_stat(running_machine *machine) |
| 960 | 960 | { |
| 961 | UINT8 *src = memory_region(machine, "m | |
| 961 | UINT8 *src = memory_region(machine, "m | |
| 962 | 962 | UINT8 *instruction_rom = memory_region(machine, "user1"); |
| 963 | 963 | UINT8 *game_rom = memory_region(machine, "main"); |
| 964 | 964 | int offs; |
| r3232 | r3233 | |
|---|---|---|
| 288 | 288 | ---x xxxx : Key code |
| 289 | 289 | --x- ---- : Player 1 and 2 side flag |
| 290 | 290 | */ |
| 291 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3" }; | |
| 291 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3" }; | |
| 292 | 292 | |
| 293 | 293 | if (!ACCESSING_BITS_0_7) |
| 294 | 294 | { |
| r3232 | r3233 | |
| 512 | 512 | /* Currently I/O port of srmp3 is fully understood. */ |
| 513 | 513 | |
| 514 | 514 | int keydata = 0xff; |
| 515 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3" }; | |
| 515 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3" }; | |
| 516 | 516 | |
| 517 | 517 | logerror("PC:%04X srmp3_input_r\n", activecpu_get_pc()); |
| 518 | 518 | |
| r3232 | r3233 | |
| 582 | 582 | AM_RANGE(0xe000, 0xffff) AM_WRITE(SMH_RAM) AM_BASE(&spriteram_3) |
| 583 | 583 | ADDRESS_MAP_END |
| 584 | 584 | |
| 585 | static ADDRESS_MAP_START( srmp3_ | |
| 585 | static ADDRESS_MAP_START( srmp3_io_ma | |
| 586 | 586 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 587 | AM_RANGE(0x40, 0x40) AM_READ_PORT("SYSTEM") /* coin, service */ | |
| 588 | AM_RANGE(0xa1, 0xa1) AM_READ(srmp3_cchip_status_0_r) /* custom chip status ??? */ | |
| 589 | AM_RANGE(0xc0, 0xc0) AM_READ(srmp3_input_r) /* key matrix */ | |
| 590 | AM_RANGE(0xc1, 0xc1) AM_READ(srmp3_cchip_status_1_r) /* custom chip status ??? */ | |
| 591 | AM_RANGE(0xe2, 0xe2) AM_READ(ay8910_read_port_0_r) | |
| 592 | ADDRESS_MAP_END | |
| 593 | ||
| 594 | static ADDRESS_MAP_START( srmp3_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 595 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 596 | AM_RANGE(0x20, 0x20) AM_WRITE(SMH_NOP) /* elapsed interrupt signal */ | |
| 597 | AM_RANGE(0x40, 0x40) AM_WRITE(srmp3_flags_w) /* GFX bank, counter, lockout */ | |
| 598 | AM_RANGE(0x60, 0x60) AM_WRITE(srmp3_rombank_w) /* ROM bank select */ | |
| 587 | AM_RANGE(0x20, 0x20) AM_WRITE(SMH_NOP) /* elapsed interrupt signal */ | |
| 588 | AM_RANGE(0x40, 0x40) AM_READ_PORT("SYSTEM") AM_WRITE(srmp3_flags_w) /* coin, service | GFX bank, counter, lockout */ | |
| 589 | AM_RANGE(0x60, 0x60) AM_WRITE(srmp3_rombank_w) /* ROM bank select */ | |
| 599 | 590 | AM_RANGE(0xa0, 0xa0) AM_WRITE(srmp3_adpcm_code_w) /* ADPCM number */ |
| 600 | AM_RANGE(0xc0, 0xc0) AM_WRITE(srmp3_input_1_w) /* I/O ??? */ | |
| 601 | AM_RANGE(0xc1, 0xc1) AM_WRITE(srmp3_input_2_w) /* I/O ??? */ | |
| 591 | AM_RANGE(0xa1, 0xa1) AM_READ(srmp3_cchip_status_0_r) /* custom chip status ??? */ | |
| 592 | AM_RANGE(0xc0, 0xc0) AM_READWRITE(srmp3_input_r, srmp3_input_1_w) /* key matrix | I/O ??? */ | |
| 593 | AM_RANGE(0xc1, 0xc1) AM_READWRITE(srmp3_cchip_status_1_r, srmp3_input_2_w) /* custom chip status ??? | I/O ??? */ | |
| 602 | 594 | AM_RANGE(0xe0, 0xe0) AM_WRITE(ay8910_control_port_0_w) |
| 603 | 595 | AM_RANGE(0xe1, 0xe1) AM_WRITE(ay8910_write_port_0_w) |
| 596 | AM_RANGE(0xe2, 0xe2) AM_READ(ay8910_read_port_0_r) | |
| 604 | 597 | ADDRESS_MAP_END |
| 605 | 598 | |
| 606 | 599 | |
| r3232 | r3233 | |
| 1107 | 1100 | MDRV_CPU_ADD("main", Z80, 3500000) /* 3.50 MHz ? */ |
| 1108 | 1101 | // 4000000, /* 4.00 MHz ? */ |
| 1109 | 1102 | MDRV_CPU_PROGRAM_MAP(srmp3_readmem,srmp3_writemem) |
| 1110 | MDRV_CPU_IO_MAP(srmp3_ | |
| 1103 | MDRV_CPU_IO_MAP(srmp3_i | |
| 1111 | 1104 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1112 | 1105 | |
| 1113 | 1106 | MDRV_MACHINE_RESET(srmp3) |
| r3232 | r3233 | |
| 1376 | 1369 | GAME( 1990, mjyuugia, mjyuugi, mjyuugi, mjyuugi, 0, ROT0, "Visco", "Mahjong Yuugi (Japan set 2)", 0 ) |
| 1377 | 1370 | GAME( 1991, ponchin, 0, mjyuugi, ponchin, 0, ROT0, "Visco", "Mahjong Pon Chin Kan (Japan set 1)", 0 ) |
| 1378 | 1371 | GAME( 1991, ponchina, ponchin, mjyuugi, ponchin, 0, ROT0, "Visco", "Mahjong Pon Chin Kan (Japan set 2)", 0 ) |
| 1372 | ||
| 1373 |
| r3232 | r3233 | |
|---|---|---|
| 620 | 620 | static READ16_HANDLER( poundfor_trackball_r ) |
| 621 | 621 | { |
| 622 | 622 | static int prev[4],diff[4]; |
| 623 | static const char *axisnames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 623 | static const char *const axisnames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 624 | 624 | |
| 625 | 625 | if (offset == 0) |
| 626 | 626 | { |
| r3232 | r3233 | |
|---|---|---|
| 102 | 102 | |
| 103 | 103 | static READ16_HANDLER( protcontrols_r ) |
| 104 | 104 | { |
| 105 | static const char *portnames[] = { "P1", "P2", "SYSTEM" }; | |
| 105 | static const char *const portnames[] = { "P1", "P2", "SYSTEM" }; | |
| 106 | 106 | return input_port_read(machine, portnames[offset]) ^ invert_controls; |
| 107 | 107 | } |
| 108 | 108 |
| r3232 | r3233 | |
|---|---|---|
| 262 | 262 | Decryption |
| 263 | 263 | ***************************************************************************/ |
| 264 | 264 | |
| 265 | static void decrypt_program_rom(int mask, int a7, int a6, int a5, int a4, int a3, int a2, int a1, int a0) | |
| 265 | static void decrypt_program_rom(running_machine *machine, int mask, int a7, int a6, int a5, int a4, int a3, int a2, int a1, int a0) | |
| 266 | 266 | { |
| 267 | int length = memory_region_length(Machine, "main"); | |
| 268 | UINT8 *rom = memory_region(Machine, "main"); | |
| 267 | int length = memory_region_length(machine, "main"); | |
| 268 | UINT8 *rom = memory_region(machine, "main"); | |
| 269 | 269 | UINT8 *tmp = auto_malloc(length); |
| 270 | 270 | int i; |
| 271 | 271 | |
| r3232 | r3233 | |
| 342 | 342 | |
| 343 | 343 | static DRIVER_INIT( iqblocka ) |
| 344 | 344 | { |
| 345 | decrypt_program_rom(0x11, 7, 6, 5, 4, 3, 2, 1, 0); | |
| 345 | decrypt_program_rom(machine, 0x11, 7, 6, 5, 4, 3, 2, 1, 0); | |
| 346 | 346 | iqblocka_patch_rom(machine); |
| 347 | 347 | |
| 348 | 348 | expand_sprites(machine); |
| r3232 | r3233 | |
| 352 | 352 | |
| 353 | 353 | static DRIVER_INIT( iqblockf ) |
| 354 | 354 | { |
| 355 | decrypt_program_rom(0x11, 7, 6, 5, 4, 3, 2, 1, 0); | |
| 355 | decrypt_program_rom(machine, 0x11, 7, 6, 5, 4, 3, 2, 1, 0); | |
| 356 | 356 | // iqblockf_patch_rom(machine); |
| 357 | 357 | |
| 358 | 358 | expand_sprites(machine); |
| r3232 | r3233 | |
| 398 | 398 | |
| 399 | 399 | static DRIVER_INIT( tjsb ) |
| 400 | 400 | { |
| 401 | decrypt_program_rom(0x05, 7, 6, 3, 2, 5, 4, 1, 0); | |
| 401 | decrypt_program_rom(machine, 0x05, 7, 6, 3, 2, 5, 4, 1, 0); | |
| 402 | 402 | tjsb_patch_rom(machine); |
| 403 | 403 | |
| 404 | 404 | tjsb_decrypt_sprites(machine); |
| r3232 | r3233 | |
|---|---|---|
| 517 | 517 | int axis; |
| 518 | 518 | UINT16 diff; |
| 519 | 519 | UINT16 value; |
| 520 | static const char *axisnames[] = { "TRACK0_X", "TRACK0_Y" }; | |
| 520 | static const char *const axisnames[] = { "TRACK0_X", "TRACK0_Y" }; | |
| 521 | 521 | |
| 522 | 522 | for( axis = 0; axis < 2; axis++ ) |
| 523 | 523 | { |
| r3232 | r3233 | |
| 602 | 602 | int axis; |
| 603 | 603 | UINT16 diff; |
| 604 | 604 | UINT16 value; |
| 605 | static const char *axisnames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 605 | static const char *const axisnames[] = { "TRACK0_X", "TRACK0_Y", "TRACK1_X", "TRACK1_Y" }; | |
| 606 | 606 | |
| 607 | 607 | for( axis = 0; axis < 4; axis++ ) |
| 608 | 608 | { |
| r3232 | r3233 | |
|---|---|---|
| 83 | 83 | |
| 84 | 84 | static READ8_HANDLER( switch_input_r ) |
| 85 | 85 | { |
| 86 | static const char *portnames[] = { "IN0", "IN1", "P1", "P2", "DSW", "UNUSED0", "UNUSED1" }; | |
| 86 | static const char *const portnames[] = { "IN0", "IN1", "P1", "P2", "DSW", "UNUSED0", "UNUSED1" }; | |
| 87 | 87 | |
| 88 | 88 | return input_port_read(machine, portnames[port_select]); |
| 89 | 89 | } |
| r3232 | r3233 | |
|---|---|---|
| 74 | 74 | |
| 75 | 75 | static READ8_HANDLER( keyboard_r ) |
| 76 | 76 | { |
| 77 | static const char *keynames[] = { "KEY0", "KEY1" }; | |
| 77 | static const char *const keynames[] = { "KEY0", "KEY1" }; | |
| 78 | 78 | |
| 79 | 79 | logerror("%04x: keyboard_r\n",activecpu_get_pc()); |
| 80 | 80 | switch(activecpu_get_pc()) |
| r3232 | r3233 | |
| 198 | 198 | AM_RANGE(0xe000, 0xffff) AM_WRITE(SMH_ROM) /* rmhaisei only */ |
| 199 | 199 | ADDRESS_MAP_END |
| 200 | 200 | |
| 201 | static ADDRESS_MAP_START( | |
| 201 | static ADDRESS_MAP_START( io_ma | |
| 202 | 202 | AM_RANGE(0x0000, 0x7fff) AM_READ(samples_r) |
| 203 | AM_RANGE(0x8000, 0x8000) AM_READ(keyboard_r) | |
| 204 | AM_RANGE(0x8001, 0x8001) AM_READ(SMH_NOP) // ?? | |
| 205 | AM_RANGE(0x8020, 0x8020) AM_READ(ay8910_read_port_0_r) | |
| 206 | ADDRESS_MAP_END | |
| 207 | ||
| 208 | static ADDRESS_MAP_START( writeport, ADDRESS_SPACE_IO, 8 ) | |
| 209 | AM_RANGE(0x8000, 0x8000) AM_WRITE(SMH_NOP) // ?? | |
| 210 | AM_RANGE(0x8001, 0x8001) AM_WRITE(keyboard_w) | |
| 211 | AM_RANGE(0x8020, 0x8020) AM_WRITE(ay8910_control_port_0_w) | |
| 203 | AM_RANGE(0x8000, 0x8000) AM_READWRITE(keyboard_r, SMH_NOP) // ?? | |
| 204 | AM_RANGE(0x8001, 0x8001) AM_READWRITE(SMH_NOP, keyboard_w) // ?? | |
| 205 | AM_RANGE(0x8020, 0x8020) AM_READWRITE(ay8910_read_port_0_r, ay8910_control_port_0_w) | |
| 212 | 206 | AM_RANGE(0x8021, 0x8021) AM_WRITE(ay8910_write_port_0_w) |
| 213 | 207 | AM_RANGE(0x8040, 0x8040) AM_WRITE(adpcm_w) |
| 214 | 208 | AM_RANGE(0x8060, 0x8060) AM_WRITE(ctrl_w) |
| r3232 | r3233 | |
| 217 | 211 | AM_RANGE(0xbc0c, 0xbc0c) AM_WRITE(SMH_NOP) // ?? |
| 218 | 212 | ADDRESS_MAP_END |
| 219 | 213 | |
| 220 | ||
| 221 | static ADDRESS_MAP_START( themj_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 222 | AM_RANGE(0x8000, 0x8000) AM_WRITE(SMH_NOP) // ?? | |
| 223 | AM_RANGE(0x8001, 0x8001) AM_WRITE(keyboard_w) | |
| 224 | AM_RANGE(0x8020, 0x8020) AM_WRITE(ay8910_control_port_0_w) | |
| 214 | static ADDRESS_MAP_START( themj_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 215 | AM_RANGE(0x0000, 0x7fff) AM_READ(samples_r) | |
| 216 | AM_RANGE(0x8000, 0x8000) AM_READWRITE(keyboard_r, SMH_NOP) // ?? | |
| 217 | AM_RANGE(0x8001, 0x8001) AM_READWRITE(SMH_NOP, keyboard_w) // ?? | |
| 218 | AM_RANGE(0x8020, 0x8020) AM_READWRITE(ay8910_read_port_0_r, ay8910_control_port_0_w) | |
| 225 | 219 | AM_RANGE(0x8021, 0x8021) AM_WRITE(ay8910_write_port_0_w) |
| 226 | 220 | AM_RANGE(0x8040, 0x8040) AM_WRITE(adpcm_w) |
| 227 | 221 | AM_RANGE(0x8060, 0x8060) AM_WRITE(ctrl_w) |
| r3232 | r3233 | |
| 451 | 445 | /* basic machine hardware */ |
| 452 | 446 | MDRV_CPU_ADD("main",Z80,20000000/4) /* 5 MHz ??? */ |
| 453 | 447 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 454 | MDRV_CPU_IO_MAP( | |
| 448 | MDRV_CPU_IO_MAP(io_ma | |
| 455 | 449 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 456 | 450 | |
| 457 | 451 | /* video hardware */ |
| r3232 | r3233 | |
| 498 | 492 | |
| 499 | 493 | MDRV_CPU_MODIFY("main") |
| 500 | 494 | MDRV_CPU_PROGRAM_MAP(themj_readmem,writemem) |
| 501 | MDRV_CPU_IO_MAP( | |
| 495 | MDRV_CPU_IO_MAP( | |
| 502 | 496 | |
| 503 | 497 | MDRV_MACHINE_RESET(themj) |
| 504 | 498 |
| r3232 | r3233 | |
|---|---|---|
| 309 | 309 | static READ8_HANDLER( sysreg_r ) |
| 310 | 310 | { |
| 311 | 311 | UINT32 r = 0; |
| 312 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 312 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 313 | 313 | |
| 314 | 314 | switch (offset) |
| 315 | 315 | { |
| r3232 | r3233 | |
|---|---|---|
| 46 | 46 | static READ8_HANDLER( amspdwy_wheel_##_n_##_r ) \ |
| 47 | 47 | { \ |
| 48 | 48 | static UINT8 wheel_old, ret; \ |
| 49 | static const char *portnames[] = { "WHEEL1", "WHEEL2", "AN1", "AN2" };\ | |
| 49 | static const char *const portnames[] = { "WHEEL1", "WHEEL2", "AN1", "AN2" };\ | |
| 50 | 50 | UINT8 wheel; \ |
| 51 | 51 | wheel = input_port_read(machine, portnames[2 + _n_]); \ |
| 52 | 52 | if (wheel != wheel_old) \ |
| r3232 | r3233 | |
|---|---|---|
| 343 | 343 | // AM_RANGE(0xc000 , 0xdfff) AM_WRITE(SMH_RAM) AM_MIRROR(0x2000) |
| 344 | 344 | ADDRESS_MAP_END |
| 345 | 345 | |
| 346 | static ADDRESS_MAP_START( sms_ | |
| 346 | static ADDRESS_MAP_START( sms_io_ma | |
| 347 | 347 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 348 | 348 | ADDRESS_MAP_END |
| 349 | 349 | |
| 350 | static ADDRESS_MAP_START( sms_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 351 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 352 | ADDRESS_MAP_END | |
| 353 | ||
| 354 | 350 | /* Precalculated tables for H/V counters. Note the position the counter 'jumps' is marked with with |
| 355 | 351 | an empty comment */ |
| 356 | 352 | static const UINT8 hc_256[] = |
| r3232 | r3233 | |
| 2052 | 2048 | static MACHINE_DRIVER_START( systeme ) |
| 2053 | 2049 | MDRV_CPU_ADD("z80", Z80, 10738600/2) /* correct for hangonjr, and astroflash/transformer at least */ |
| 2054 | 2050 | MDRV_CPU_PROGRAM_MAP(systeme_readmem,systeme_writemem) |
| 2055 | MDRV_CPU_IO_MAP(sms_ | |
| 2051 | MDRV_CPU_IO_MAP(sms_i | |
| 2056 | 2052 | |
| 2057 | 2053 | /* IRQ handled via the timers */ |
| 2058 | 2054 | MDRV_MACHINE_RESET(systeme) |
| r3232 | r3233 | |
| 2379 | 2375 | GAME( 1987, opaopa, 0, systeme, opaopa, opaopa, ROT0, "Sega", "Opa Opa (MC-8123, 317-0042)", 0 ) |
| 2380 | 2376 | GAME( 1988, fantzn2, 0, systeme, fantzn2, fantzn2, ROT0, "Sega", "Fantasy Zone 2 (MC-8123, 317-0057)", 0 ) |
| 2381 | 2377 | GAME( 1988, tetrisse, 0, systeme, tetrisse, segasyse, ROT0, "Sega", "Tetris (Japan, System E)", 0 ) |
| 2378 |
| r3232 | r3233 | |
|---|---|---|
| 255 | 255 | static int chiptype[ 2 ]; |
| 256 | 256 | static int has_ds2401[ 2 ]; |
| 257 | 257 | |
| 258 | static const char *diskregions[] = { "cdrom0", "cdrom1" }; | |
| 258 | static const char *const diskregions[] = { "cdrom0", "cdrom1" }; | |
| 259 | 259 | |
| 260 | 260 | /* EEPROM handlers */ |
| 261 | 261 |
| r3232 | r3233 | |
|---|---|---|
| 116 | 116 | |
| 117 | 117 | static READ16_HANDLER( a2d_data_r ) |
| 118 | 118 | { |
| 119 | static const char *adcnames[] = { "ADC0", "ADC1", "ADC2" }; | |
| 119 | static const char *const adcnames[] = { "ADC0", "ADC1", "ADC2" }; | |
| 120 | 120 | |
| 121 | 121 | /* Pit Fighter has no A2D, just another input port */ |
| 122 | 122 | if (atarig1_pitfight) |
| r3232 | r3233 | |
|---|---|---|
| 55 | 55 | { |
| 56 | 56 | static int last[4]; |
| 57 | 57 | int curr,delta; |
| 58 | static const char *port[] = { "TRACKBALL_P1_1", "TRACKBALL_P1_2", "TRACKBALL_P2_1", "TRACKBALL_P1_2" }; | |
| 58 | static const char *const port[] = { "TRACKBALL_P1_1", "TRACKBALL_P1_2", "TRACKBALL_P2_1", "TRACKBALL_P1_2" }; | |
| 59 | 59 | |
| 60 | 60 | curr = input_port_read(machine, port[offset]); |
| 61 | 61 | delta = (curr - last[offset]) & 0xff; |
| r3232 | r3233 | |
|---|---|---|
| 135 | 135 | |
| 136 | 136 | static READ16_HANDLER( spyhunt2_port_0_r ) |
| 137 | 137 | { |
| 138 | static const char *portnames[] = { "AN1", "AN2", "AN3", "AN4" }; | |
| 138 | static const char *const portnames[] = { "AN1", "AN2", "AN3", "AN4" }; | |
| 139 | 139 | int result = input_port_read(machine, "IN0"); |
| 140 | 140 | int which = (control_word >> 3) & 3; |
| 141 | 141 | int analog = input_port_read(machine, portnames[which]); |
| r3232 | r3233 | |
|---|---|---|
| 405 | 405 | ROM_LOAD( "tma1-c.7d_e-1", 0x4000, 0x2000, CRC(dcceb6c1) SHA1(b19804e69ce2c98cf276c6055c3a250316b96b45) ) |
| 406 | 406 | ROM_LOAD( "tma1-c.7c_e-3", 0xf000, 0x1000, CRC(0d31bd1c) SHA1(a2e238470ba2ea3c81225fec687f61f047c68c59) ) |
| 407 | 407 | |
| 408 | ROM_REGION( 0x | |
| 408 | ROM_REGION( 0x1800, "audio", 0 ) /* sound */ | |
| 409 | 409 | /* internal rom */ |
| 410 | 410 | ROM_FILL( 0x0000, 0x0800, 0x00) |
| 411 | 411 | /* first half banked */ |
| r3232 | r3233 | |
| 436 | 436 | ROM_LOAD( "mario.7d", 0x4000, 0x2000, CRC(dcceb6c1) SHA1(b19804e69ce2c98cf276c6055c3a250316b96b45) ) |
| 437 | 437 | ROM_LOAD( "mario.7c", 0xf000, 0x1000, CRC(4a63d96b) SHA1(b09060b2c84ab77cc540a27b8f932cb60ec8d442) ) |
| 438 | 438 | |
| 439 | ROM_REGION( 0x1000, "audio", 0 ) /* sound */ | |
| 440 | ROM_LOAD( "tma1c-a.6k", 0x0000, 0x1000, CRC(06b9ff85) SHA1(111a29bcb9cda0d935675fa26eca6b099a88427f) ) | |
| 439 | ROM_REGION( 0x1800, "audio", 0 ) /* sound */ | |
| 440 | /* internal rom */ | |
| 441 | ROM_FILL( 0x0000, 0x0800, 0x00) | |
| 442 | /* first half banked */ | |
| 443 | ROM_LOAD( "tma1c-a.6k", 0x1000, 0x0800, CRC(06b9ff85) SHA1(111a29bcb9cda0d935675fa26eca6b099a88427f) ) | |
| 444 | /* second half always read */ | |
| 445 | ROM_CONTINUE( 0x0800, 0x0800) | |
| 441 | 446 | |
| 442 | 447 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) |
| 443 | 448 | ROM_LOAD( "mario.3f", 0x0000, 0x1000, CRC(28b0c42c) SHA1(46749568aff88a28c3b6a1ac423abd1b90742a4d) ) |
| r3232 | r3233 | |
| 462 | 467 | ROM_LOAD( "tma1c-a1.7d", 0x4000, 0x2000, CRC(f8575f31) SHA1(710d0e72fcfce700ed2a22fb9c7c392cc76b250b) ) |
| 463 | 468 | ROM_LOAD( "tma1c-a2.7c", 0xf000, 0x1000, CRC(a3c11e9e) SHA1(d0612b0f8c2ea4e798f551922a04a324f4ed5f3d) ) |
| 464 | 469 | |
| 465 | ROM_REGION( 0x1000, "audio", 0 ) /* sound */ | |
| 466 | ROM_LOAD( "tma1c-a.6k", 0x0000, 0x1000, CRC(06b9ff85) SHA1(111a29bcb9cda0d935675fa26eca6b099a88427f) ) | |
| 470 | ROM_REGION( 0x1800, "audio", 0 ) /* sound */ | |
| 471 | /* internal rom */ | |
| 472 | ROM_FILL( 0x0000, 0x0800, 0x00) | |
| 473 | /* first half banked */ | |
| 474 | ROM_LOAD( "tma1c-a.6k", 0x1000, 0x0800, CRC(06b9ff85) SHA1(111a29bcb9cda0d935675fa26eca6b099a88427f) ) | |
| 475 | /* second half always read */ | |
| 476 | ROM_CONTINUE( 0x0800, 0x0800) | |
| 467 | 477 | |
| 468 | 478 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) |
| 469 | 479 | ROM_LOAD( "tma1v-a.3f", 0x0000, 0x1000, CRC(adf49ee0) SHA1(11fc2cd197bfe3ecb6af55c3c7a326c94988d2bd) ) |
| r3232 | r3233 | |
|---|---|---|
| 176 | 176 | #define SOUND_CLOCK XTAL_18_432MHz |
| 177 | 177 | |
| 178 | 178 | |
| 179 | static const char *gunnames[] = { "LIGHT0_X", "LIGHT0_Y", "LIGHT1_X", "LIGHT1_Y" }; | |
| 179 | static const char *const gunnames[] = { "LIGHT0_X", "LIGHT0_Y", "LIGHT1_X", "LIGHT1_Y" }; | |
| 180 | 180 | |
| 181 | 181 | /* a = 1, 2 = player # */ |
| 182 | 182 | #define GUNX( a ) (( ( input_port_read(machine, gunnames[2 * (a - 1)]) * 287 ) / 0xff ) + 16) |
| r3232 | r3233 | |
|---|---|---|
| 128 | 128 | return mxtc_config_reg[reg]; |
| 129 | 129 | } |
| 130 | 130 | |
| 131 | static void mxtc_config_w(int function, int reg, UINT8 data) | |
| 131 | static void mxtc_config_w(running_machine *machine, int function, int reg, UINT8 data) | |
| 132 | 132 | { |
| 133 | 133 | // mame_printf_debug("MXTC: write %d, %02X, %02X at %08X\n", function, reg, data, activecpu_get_pc()); |
| 134 | 134 | |
| r3232 | r3233 | |
| 142 | 142 | } |
| 143 | 143 | else // disable RAM access (reads go to BIOS ROM) |
| 144 | 144 | { |
| 145 | memory_set_bankptr(1, memory_region( | |
| 145 | memory_set_bankptr(1, memory_region(machine, "user1") + 0x30000); | |
| 146 | 146 | } |
| 147 | 147 | break; |
| 148 | 148 | } |
| r3232 | r3233 | |
| 187 | 187 | { |
| 188 | 188 | if (ACCESSING_BITS_24_31) |
| 189 | 189 | { |
| 190 | mxtc_config_w(function, reg + 3, (data >> 24) & 0xff); | |
| 190 | mxtc_config_w(Machine, function, reg + 3, (data >> 24) & 0xff); | |
| 191 | 191 | } |
| 192 | 192 | if (ACCESSING_BITS_16_23) |
| 193 | 193 | { |
| 194 | mxtc_config_w(function, reg + 2, (data >> 16) & 0xff); | |
| 194 | mxtc_config_w(Machine, function, reg + 2, (data >> 16) & 0xff); | |
| 195 | 195 | } |
| 196 | 196 | if (ACCESSING_BITS_8_15) |
| 197 | 197 | { |
| 198 | mxtc_config_w(function, reg + 1, (data >> 8) & 0xff); | |
| 198 | mxtc_config_w(Machine, function, reg + 1, (data >> 8) & 0xff); | |
| 199 | 199 | } |
| 200 | 200 | if (ACCESSING_BITS_0_7) |
| 201 | 201 | { |
| 202 | mxtc_config_w(function, reg + 0, (data >> 0) & 0xff); | |
| 202 | mxtc_config_w(Machine, function, reg + 0, (data >> 0) & 0xff); | |
| 203 | 203 | } |
| 204 | 204 | } |
| 205 | 205 |
| r3232 | r3233 | |
|---|---|---|
| 3282 | 3282 | /******************************************************************************/ |
| 3283 | 3283 | |
| 3284 | 3284 | #if TUMBLEP_HACK |
| 3285 | void tumblepb_patch_code(UINT16 offset) | |
| 3285 | void tumblepb_patch_code(running_machine *machine, UINT16 offset) | |
| 3286 | 3286 | { |
| 3287 | 3287 | /* A hack which enables all Dip Switches effects */ |
| 3288 | UINT16 *RAM = (UINT16 *)memory_region( | |
| 3288 | UINT16 *RAM = (UINT16 *)memory_region(machine, "main"); | |
| 3289 | 3289 | RAM[(offset + 0)/2] = 0x0240; |
| 3290 | 3290 | RAM[(offset + 2)/2] = 0xffff; // andi.w #$f3ff, D0 |
| 3291 | 3291 | } |
| r3232 | r3233 | |
| 3318 | 3318 | tumblepb_gfx1_rearrange(machine); |
| 3319 | 3319 | |
| 3320 | 3320 | #if TUMBLEP_HACK |
| 3321 | tumblepb_patch_code(0x000132); | |
| 3321 | tumblepb_patch_code(machine, 0x000132); | |
| 3322 | 3322 | #endif |
| 3323 | 3323 | } |
| 3324 | 3324 | |
| r3232 | r3233 | |
| 3327 | 3327 | tumblepb_gfx1_rearrange(machine); |
| 3328 | 3328 | |
| 3329 | 3329 | #if TUMBLEP_HACK |
| 3330 | tumblepb_patch_code(0x000132); | |
| 3330 | tumblepb_patch_code(machine, 0x000132); | |
| 3331 | 3331 | #endif |
| 3332 | 3332 | |
| 3333 | 3333 | memory_install_write16_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x100000, 0x100001, 0, 0, tumbleb2_soundmcu_w ); |
| r3232 | r3233 | |
| 3339 | 3339 | tumblepb_gfx1_rearrange(machine); |
| 3340 | 3340 | |
| 3341 | 3341 | #if TUMBLEP_HACK |
| 3342 | tumblepb_patch_code(0x00013a); | |
| 3342 | tumblepb_patch_code(machine, 0x00013a); | |
| 3343 | 3343 | #endif |
| 3344 | 3344 | } |
| 3345 | 3345 |
| r3232 | r3233 | |
|---|---|---|
| 93 | 93 | static int ti_uart_mode_cycle=0; |
| 94 | 94 | static int ti_uart_sync_cycle=0; |
| 95 | 95 | |
| 96 | static void m68901_int_gen(int source); | |
| 96 | static void m68901_int_gen(running_machine *machine, int source); | |
| 97 | 97 | |
| 98 | 98 | /* 68901 */ |
| 99 | 99 | enum{ TMRB=0,TXERR,TBE,RXERR,RBF,TMRA,GPIP6,GPIP7, // A Registers |
| r3232 | r3233 | |
| 125 | 125 | } |
| 126 | 126 | |
| 127 | 127 | |
| 128 | static void changecolor_BBBBBRRRRRGGGGGG(pen_t color,int data) | |
| 128 | static void changecolor_BBBBBRRRRRGGGGGG(running_machine *machine,pen_t color,int data) | |
| 129 | 129 | { |
| 130 | palette_set_color_rgb( | |
| 130 | palette_set_color_rgb(machine,color,pal5bit(data >> 6),pal5bit(data >> 1),pal5bit(data >> 11)); | |
| 131 | 131 | } |
| 132 | 132 | |
| 133 | 133 | static WRITE16_HANDLER( paletteram16_BBBBBRRRRRGGGGGG_word_w ) |
| 134 | 134 | { |
| 135 | 135 | COMBINE_DATA(&paletteram16[offset]); |
| 136 | changecolor_BBBBBRRRRRGGGGGG(offset,paletteram16[offset]); | |
| 136 | changecolor_BBBBBRRRRRGGGGGG(machine,offset,paletteram16[offset]); | |
| 137 | 137 | } |
| 138 | 138 | |
| 139 | 139 | |
| r3232 | r3233 | |
| 392 | 392 | |
| 393 | 393 | static void tms_interrupt(int state) |
| 394 | 394 | { |
| 395 | m68901_int_gen(GPIP4); | |
| 395 | m68901_int_gen(Machine, GPIP4); | |
| 396 | 396 | } |
| 397 | 397 | |
| 398 | 398 | static INTERRUPT_GEN( micro3d_vblank ) |
| 399 | 399 | { |
| 400 | m68901_int_gen(GPIP7); | |
| 400 | m68901_int_gen(machine, GPIP7); | |
| 401 | 401 | } |
| 402 | 402 | |
| 403 | 403 | |
| r3232 | r3233 | |
| 407 | 407 | { |
| 408 | 408 | // timer_set(attotime_mul(ATTOTIME_IN_HZ(M68901_CLK), ((m68901_base[0xf]>>8) & 0xff) * 200),0,timera_int); // Set the timer again. |
| 409 | 409 | timer_set(ATTOTIME_IN_USEC(1000), NULL,0,timera_int); // Set the timer again. |
| 410 | m68901_int_gen(TMRA); // Fire an interrupt. | |
| 410 | m68901_int_gen(machine, TMRA); // Fire an interrupt. | |
| 411 | 411 | } |
| 412 | 412 | |
| 413 | 413 | #ifdef UNUSED_FUNCTION |
| 414 | 414 | static TIMER_CALLBACK( timerb_int ) |
| 415 | 415 | { |
| 416 | 416 | timer_set(attotime_mul(ATTOTIME_IN_HZ(M68901_CLK), ((m68901_base[0x10]>>8) & 0xff) * 200),0,timera_int); |
| 417 | m68901_int_gen(TMRB); // Fire an interrupt. | |
| 417 | m68901_int_gen(machine, TMRB); // Fire an interrupt. | |
| 418 | 418 | } |
| 419 | 419 | |
| 420 | 420 | static TIMER_CALLBACK( timerc_int ) |
| 421 | 421 | { |
| 422 | 422 | timer_set(attotime_mul(ATTOTIME_IN_HZ(M68901_CLK), ((m68901_base[0x11]>>8) & 0xff) * 200),0,timera_int); |
| 423 | m68901_int_gen(TMRC); // Fire an interrupt. | |
| 423 | m68901_int_gen(machine, TMRC); // Fire an interrupt. | |
| 424 | 424 | } |
| 425 | 425 | #endif |
| 426 | 426 | |
| 427 | 427 | static TIMER_CALLBACK( timerd_int ) |
| 428 | 428 | { |
| 429 | 429 | timer_set(ATTOTIME_IN_USEC(250), NULL,0,timerd_int); |
| 430 | m68901_int_gen(TMRD); // Fire an interrupt. | |
| 430 | m68901_int_gen(machine, TMRD); // Fire an interrupt. | |
| 431 | 431 | } |
| 432 | 432 | |
| 433 | 433 | |
| 434 | 434 | /* Called by anything that generates a MFD interrupt */ |
| 435 | 435 | /* Requires: MFD line number */ |
| 436 | 436 | |
| 437 | static void m68901_int_gen(int source) | |
| 437 | static void m68901_int_gen(running_machine *machine, int source) | |
| 438 | 438 | { |
| 439 | 439 | // logerror("M68901 interrupt %d requested.\n",source); |
| 440 | 440 | |
| r3232 | r3233 | |
| 451 | 451 | |
| 452 | 452 | if(m68901_base[IMASK_REG] & (bit<<8)) // If interrupt is not masked by MFD, trigger a 68k INT |
| 453 | 453 | { |
| 454 | cpunum_set_input_line( | |
| 454 | cpunum_set_input_line(machine, 0,4, HOLD_LINE); | |
| 455 | 455 | // logerror("M68901 interrupt %d serviced.\n",source); |
| 456 | 456 | } |
| 457 | 457 | } |
| r3232 | r3233 | |
|---|---|---|
| 120 | 120 | AM_RANGE(0xffff0, 0xfffff) AM_ROM |
| 121 | 121 | ADDRESS_MAP_END |
| 122 | 122 | |
| 123 | static ADDRESS_MAP_START( main_cpu_io, ADDRESS_SPACE_IO, 16 ) | |
| 123 | static ADDRESS_MAP_START( main_cpu_io_map, ADDRESS_SPACE_IO, 16 ) | |
| 124 | 124 | AM_RANGE(0x00, 0x01) AM_WRITE(m72_sound_command_w) |
| 125 | 125 | AM_RANGE(0x00, 0x01) AM_READ_PORT("P1_P2") |
| 126 | 126 | AM_RANGE(0x02, 0x03) AM_WRITE(m90_coincounter_w) |
| r3232 | r3233 | |
| 155 | 155 | AM_RANGE(0xf000, 0xffff) AM_WRITE(SMH_RAM) |
| 156 | 156 | ADDRESS_MAP_END |
| 157 | 157 | |
| 158 | static ADDRESS_MAP_START( sound_ | |
| 158 | static ADDRESS_MAP_START( sound_io_ma | |
| 159 | 159 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 160 | AM_RANGE(0x01, 0x01) AM_READ(ym2151_status_port_0_r) | |
| 161 | AM_RANGE(0x80, 0x80) AM_READ(soundlatch_r) | |
| 162 | AM_RANGE(0x84, 0x84) AM_READ(m72_sample_r) | |
| 163 | ADDRESS_MAP_END | |
| 164 | ||
| 165 | static ADDRESS_MAP_START( sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 166 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 167 | 160 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2151_register_port_0_w) |
| 168 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2151_data_port_0_w) | |
| 161 | AM_RANGE(0x01, 0x01) AM_READWRITE(ym2151_status_port_0_r, ym2151_data_port_0_w) | |
| 162 | AM_RANGE(0x80, 0x80) AM_READ(soundlatch_r) | |
| 169 | 163 | AM_RANGE(0x80, 0x81) AM_WRITE(rtype2_sample_addr_w) |
| 170 | 164 | AM_RANGE(0x82, 0x82) AM_WRITE(m72_sample_w) |
| 171 | 165 | AM_RANGE(0x83, 0x83) AM_WRITE(m72_sound_irq_ack_w) |
| 166 | AM_RANGE(0x84, 0x84) AM_READ(m72_sample_r) | |
| 172 | 167 | ADDRESS_MAP_END |
| 173 | 168 | |
| 174 | static ADDRESS_MAP_START( bbmanw_sound_ | |
| 169 | static ADDRESS_MAP_START( bbmanw_sound_io_ma | |
| 175 | 170 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 176 | AM_RANGE(0x41, 0x41) AM_READ(ym2151_status_port_0_r) | |
| 177 | AM_RANGE(0x42, 0x42) AM_READ(soundlatch_r) | |
| 178 | // AM_RANGE(0x41, 0x41) AM_READ(m72_sample_r) | |
| 179 | ADDRESS_MAP_END | |
| 180 | ||
| 181 | static ADDRESS_MAP_START( bbmanw_sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 182 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 183 | 171 | AM_RANGE(0x40, 0x40) AM_WRITE(ym2151_register_port_0_w) |
| 184 | AM_RANGE(0x41, 0x41) AM_WRITE(ym2151_data_port_0_w) | |
| 185 | AM_RANGE(0x42, 0x42) AM_WRITE(m72_sound_irq_ack_w) | |
| 172 | AM_RANGE(0x41, 0x41) AM_READWRITE(ym2151_status_port_0_r, ym2151_data_port_0_w) | |
| 173 | AM_RANGE(0x42, 0x42) AM_READWRITE(soundlatch_r, m72_sound_irq_ack_w) | |
| 186 | 174 | // AM_RANGE(0x40, 0x41) AM_WRITE(rtype2_sample_addr_w) |
| 175 | // AM_RANGE(0x41, 0x41) AM_READ(m72_sample_r) | |
| 187 | 176 | // AM_RANGE(0x42, 0x42) AM_WRITE(m72_sample_w) |
| 188 | 177 | ADDRESS_MAP_END |
| 189 | 178 | |
| r3232 | r3233 | |
| 722 | 711 | /* basic machine hardware */ |
| 723 | 712 | MDRV_CPU_ADD("main", V30,XTAL_32MHz/2/2) /* verified clock on cpu is 16Mhz but probably divided internally by 2 */ |
| 724 | 713 | MDRV_CPU_PROGRAM_MAP(main_cpu,0) |
| 725 | MDRV_CPU_IO_MAP(main_cpu_io,0) | |
| 714 | MDRV_CPU_IO_MAP(main_cpu_io_map,0) | |
| 726 | 715 | MDRV_CPU_VBLANK_INT("main", m90_interrupt) |
| 727 | 716 | |
| 728 | 717 | MDRV_CPU_ADD("audio", Z80, XTAL_3_579545MHz) /* verified on pcb */ |
| 729 | 718 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 730 | MDRV_CPU_IO_MAP(sound_ | |
| 719 | MDRV_CPU_IO_MAP(sound_i | |
| 731 | 720 | MDRV_CPU_VBLANK_INT_HACK(nmi_line_pulse,128) /* clocked by V1? (Vigilante) */ |
| 732 | 721 | /* IRQs are generated by main Z80 and YM2151 */ |
| 733 | 722 | |
| r3232 | r3233 | |
| 804 | 793 | MDRV_CPU_CONFIG(bomberman_config) |
| 805 | 794 | |
| 806 | 795 | MDRV_CPU_PROGRAM_MAP(main_cpu,0) |
| 807 | MDRV_CPU_IO_MAP(main_cpu_io,0) | |
| 796 | MDRV_CPU_IO_MAP(main_cpu_io_map,0) | |
| 808 | 797 | MDRV_CPU_VBLANK_INT("main", m90_interrupt) |
| 809 | 798 | |
| 810 | 799 | MDRV_CPU_ADD("audio", Z80, XTAL_3_579545MHz) /* verified on pcb */ |
| 811 | 800 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 812 | MDRV_CPU_IO_MAP(sound_ | |
| 801 | MDRV_CPU_IO_MAP(sound_i | |
| 813 | 802 | MDRV_CPU_VBLANK_INT_HACK(nmi_line_pulse,128) /* clocked by V1? (Vigilante) */ |
| 814 | 803 | /* IRQs are generated by main Z80 and YM2151 */ |
| 815 | 804 | MDRV_MACHINE_RESET(m72_sound) |
| r3232 | r3233 | |
| 849 | 838 | MDRV_CPU_CONFIG(dynablaster_config) |
| 850 | 839 | |
| 851 | 840 | MDRV_CPU_PROGRAM_MAP(main_cpu,0) |
| 852 | MDRV_CPU_IO_MAP(main_cpu_io,0) | |
| 841 | MDRV_CPU_IO_MAP(main_cpu_io_map,0) | |
| 853 | 842 | MDRV_CPU_VBLANK_INT("main", m90_interrupt) |
| 854 | 843 | |
| 855 | 844 | MDRV_CPU_ADD("audio", Z80, XTAL_3_579545MHz) /* verified on pcb */ |
| 856 | 845 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 857 | MDRV_CPU_IO_MAP(bbmanw_sound_ | |
| 846 | MDRV_CPU_IO_MAP(bbmanw_sound_i | |
| 858 | 847 | MDRV_CPU_VBLANK_INT_HACK(nmi_line_pulse,128) /* clocked by V1? (Vigilante) */ |
| 859 | 848 | /* IRQs are generated by main Z80 and YM2151 */ |
| 860 | 849 | MDRV_MACHINE_RESET(m72_sound) |
| r3232 | r3233 | |
| 915 | 904 | |
| 916 | 905 | MDRV_CPU_ADD("audio", Z80, XTAL_3_579545MHz) /* 3.579545 MHz */ |
| 917 | 906 | MDRV_CPU_PROGRAM_MAP(sound_readmem,sound_writemem) |
| 918 | MDRV_CPU_IO_MAP(sound_ | |
| 907 | MDRV_CPU_IO_MAP(sound_i | |
| 919 | 908 | MDRV_CPU_VBLANK_INT_HACK(nmi_line_pulse,128) /* clocked by V1? (Vigilante) */ |
| 920 | 909 | /* IRQs are generated by main Z80 and YM2151 */ |
| 921 | 910 | MDRV_MACHINE_RESET(m72_sound) |
| r3232 | r3233 | |
| 1313 | 1302 | GAME( 1993, gussun, riskchal, riskchal, riskchal, 0, ROT0, "Irem", "Gussun Oyoyo (Japan)", GAME_IMPERFECT_GRAPHICS ) |
| 1314 | 1303 | GAME( 1993, matchit2, 0, matchit2, matchit2, 0, ROT0, "Tamtex", "Match It II", GAME_NO_COCKTAIL ) |
| 1315 | 1304 | GAME( 1993, shisen2, matchit2, matchit2, shisen2, 0, ROT0, "Tamtex", "Shisensho II", GAME_NO_COCKTAIL ) |
| 1305 |
| r3232 | r3233 | |
|---|---|---|
| 885 | 885 | READ16_HANDLER ( TC0150ROD_word_r ); /* Road generator */ |
| 886 | 886 | WRITE16_HANDLER( TC0150ROD_word_w ); |
| 887 | 887 | |
| 888 | static UINT16 cpua_ctrl | |
| 888 | static UINT16 cpua_ctrl | |
| 889 | 889 | static INT32 sci_int6 = 0; |
| 890 | 890 | static INT32 dblaxle_int6 = 0; |
| 891 | 891 | static INT32 ioc220_port = 0; |
| r3232 | r3233 | |
| 1412 | 1412 | SOUND |
| 1413 | 1413 | *****************************************************/ |
| 1414 | 1414 | |
| 1415 | static INT32 banknum | |
| 1415 | static INT32 banknum | |
| 1416 | 1416 | |
| 1417 | 1417 | static void reset_sound_region(running_machine *machine) /* assumes Z80 sandwiched between 68Ks */ |
| 1418 | 1418 | { |
| r3232 | r3233 | |
| 1510 | 1510 | |
| 1511 | 1511 | static MACHINE_START( taitoz ) |
| 1512 | 1512 | { |
| 1513 | banknum = -1; | |
| 1514 | cpua_ctrl = 0xff; | |
| 1515 | sci_int6 = 0; | |
| 1516 | dblaxle_int6 = 0; | |
| 1517 | ioc220_port = 0; | |
| 1518 | ||
| 1513 | 1519 | state_save_register_global(cpua_ctrl); |
| 1514 | 1520 | |
| 1515 | 1521 | /* these are specific to various games: we ought to split the inits */ |
| r3232 | r3233 | |
| 4764 | 4770 | static DRIVER_INIT( taitoz ) |
| 4765 | 4771 | { |
| 4766 | 4772 | // taitosnd_setz80_soundcpu( 2 ); |
| 4767 | ||
| 4768 | cpua_ctrl = 0xff; | |
| 4769 | 4773 | } |
| 4770 | 4774 | |
| 4771 | 4775 | static STATE_POSTLOAD( bshark_postload ) |
| r3232 | r3233 | |
| 4775 | 4779 | |
| 4776 | 4780 | static DRIVER_INIT( bshark ) |
| 4777 | 4781 | { |
| 4778 | | |
| 4782 | eep | |
| 4779 | 4783 | state_save_register_postload(machine, bshark_postload, NULL); |
| 4780 | 4784 | |
| 4781 | 4785 | state_save_register_global(eep_latch); |
| r3232 | r3233 | |
|---|---|---|
| 498 | 498 | AM_RANGE(0xf800, 0xffff) AM_WRITE(slapfight_fixcol_w) AM_BASE(&slapfight_colorram) |
| 499 | 499 | ADDRESS_MAP_END |
| 500 | 500 | |
| 501 | static ADDRESS_MAP_START( | |
| 501 | static ADDRESS_MAP_START( io_ma | |
| 502 | 502 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 503 | AM_RANGE(0x00, 0x00) AM_READ(slapfight_port_00_r) /* status register */ | |
| 503 | AM_RANGE(0x00, 0x00) AM_READWRITE(slapfight_port_00_r, slapfight_port_00_w) /* status register */ | |
| 504 | AM_RANGE(0x01, 0x01) AM_WRITE(slapfight_port_01_w) | |
| 505 | AM_RANGE(0x02, 0x03) AM_WRITE(slapfight_flipscreen_w) | |
| 506 | // AM_RANGE(0x04, 0x04) AM_WRITE(getstar_port_04_w) | |
| 507 | AM_RANGE(0x06, 0x06) AM_WRITE(slapfight_port_06_w) | |
| 508 | AM_RANGE(0x07, 0x07) AM_WRITE(slapfight_port_07_w) | |
| 509 | AM_RANGE(0x08, 0x08) AM_WRITE(slapfight_port_08_w) /* select bank 0 */ | |
| 510 | AM_RANGE(0x09, 0x09) AM_WRITE(slapfight_port_09_w) /* select bank 1 */ | |
| 511 | AM_RANGE(0x0c, 0x0d) AM_WRITE(slapfight_palette_bank_w) | |
| 504 | 512 | ADDRESS_MAP_END |
| 505 | 513 | |
| 506 | 514 | static READ8_HANDLER(tigerh_status_r) |
| r3232 | r3233 | |
| 508 | 516 | return (slapfight_port_00_r(machine,0)&0xf9)| ((tigerh_mcu_status_r(machine,0))); |
| 509 | 517 | } |
| 510 | 518 | |
| 511 | static ADDRESS_MAP_START( tigerh_ | |
| 519 | static ADDRESS_MAP_START( tigerh_io_ma | |
| 512 | 520 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 513 | AM_RANGE(0x00, 0x00) AM_READ(tigerh_status_r) /* status register */ | |
| 521 | AM_RANGE(0x00, 0x00) AM_READWRITE(tigerh_status_r, slapfight_port_00_w) /* status register */ | |
| 522 | AM_RANGE(0x01, 0x01) AM_WRITE(slapfight_port_01_w) | |
| 523 | AM_RANGE(0x02, 0x03) AM_WRITE(slapfight_flipscreen_w) | |
| 524 | AM_RANGE(0x06, 0x06) AM_WRITE(slapfight_port_06_w) | |
| 525 | AM_RANGE(0x07, 0x07) AM_WRITE(slapfight_port_07_w) | |
| 514 | 526 | ADDRESS_MAP_END |
| 515 | 527 | |
| 516 | 528 | static ADDRESS_MAP_START( m68705_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 534 | 546 | AM_RANGE(0x0080, 0x07ff) AM_WRITE(SMH_ROM) |
| 535 | 547 | ADDRESS_MAP_END |
| 536 | 548 | |
| 537 | static ADDRESS_MAP_START( tigerh_ | |
| 549 | static ADDRESS_MAP_START( tigerhb_ | |
| 538 | 550 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 539 | AM_RANGE(0x00, 0x00) AM_WRITE(slapfight_port_00_w) | |
| 551 | AM_RANGE(0x00, 0x00) AM_READWRITE(slapfight_port_00_r, slapfight_port_00_w) /* status register */ | |
| 540 | 552 | AM_RANGE(0x01, 0x01) AM_WRITE(slapfight_port_01_w) |
| 541 | 553 | AM_RANGE(0x02, 0x03) AM_WRITE(slapfight_flipscreen_w) |
| 542 | 554 | AM_RANGE(0x06, 0x06) AM_WRITE(slapfight_port_06_w) |
| 543 | 555 | AM_RANGE(0x07, 0x07) AM_WRITE(slapfight_port_07_w) |
| 544 | 556 | ADDRESS_MAP_END |
| 545 | 557 | |
| 546 | static ADDRESS_MAP_START( writeport, ADDRESS_SPACE_IO, 8 ) | |
| 547 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 548 | AM_RANGE(0x00, 0x00) AM_WRITE(slapfight_port_00_w) | |
| 549 | AM_RANGE(0x01, 0x01) AM_WRITE(slapfight_port_01_w) | |
| 550 | AM_RANGE(0x02, 0x03) AM_WRITE(slapfight_flipscreen_w) | |
| 551 | // AM_RANGE(0x04, 0x04) AM_WRITE(getstar_port_04_w) | |
| 552 | AM_RANGE(0x06, 0x06) AM_WRITE(slapfight_port_06_w) | |
| 553 | AM_RANGE(0x07, 0x07) AM_WRITE(slapfight_port_07_w) | |
| 554 | AM_RANGE(0x08, 0x08) AM_WRITE(slapfight_port_08_w) /* select bank 0 */ | |
| 555 | AM_RANGE(0x09, 0x09) AM_WRITE(slapfight_port_09_w) /* select bank 1 */ | |
| 556 | AM_RANGE(0x0c, 0x0d) AM_WRITE(slapfight_palette_bank_w) | |
| 557 | ADDRESS_MAP_END | |
| 558 | ||
| 559 | ||
| 560 | 558 | static ADDRESS_MAP_START( perfrman_sound_readmem, ADDRESS_SPACE_PROGRAM, 8 ) |
| 561 | 559 | AM_RANGE(0x0000, 0x1fff) AM_READ(SMH_ROM) |
| 562 | 560 | AM_RANGE(0x8800, 0x880f) AM_READ(slapfight_dpram_r) |
| r3232 | r3233 | |
| 926 | 924 | /* basic machine hardware */ |
| 927 | 925 | MDRV_CPU_ADD("main", Z80,16000000/4) /* 4MHz ???, 16MHz Oscillator */ |
| 928 | 926 | MDRV_CPU_PROGRAM_MAP(perfrman_readmem,perfrman_writemem) |
| 929 | MDRV_CPU_IO_MAP( | |
| 927 | MDRV_CPU_IO_MAP(io_ma | |
| 930 | 928 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 931 | 929 | |
| 932 | 930 | MDRV_CPU_ADD("audio", Z80,16000000/8) /* 2MHz ???, 16MHz Oscillator */ |
| r3232 | r3233 | |
| 973 | 971 | /* basic machine hardware */ |
| 974 | 972 | MDRV_CPU_ADD("main", Z80, 6000000) |
| 975 | 973 | MDRV_CPU_PROGRAM_MAP(tigerh_readmem,writemem) |
| 976 | MDRV_CPU_IO_MAP( | |
| 974 | MDRV_CPU_IO_MAP( | |
| 977 | 975 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 978 | 976 | |
| 979 | 977 | MDRV_CPU_ADD("audio", Z80, 6000000) |
| r3232 | r3233 | |
| 1019 | 1017 | /* basic machine hardware */ |
| 1020 | 1018 | MDRV_CPU_ADD("main", Z80, XTAL_36MHz/6) /* verified on pcb */ |
| 1021 | 1019 | MDRV_CPU_PROGRAM_MAP(tigerh_readmem,writemem) |
| 1022 | MDRV_CPU_IO_MAP(tigerh_ | |
| 1020 | MDRV_CPU_IO_MAP(tigerh_ | |
| 1023 | 1021 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1024 | 1022 | |
| 1025 | 1023 | MDRV_CPU_ADD("audio", Z80, XTAL_36MHz/12) /* verified on pcb */ |
| r3232 | r3233 | |
| 1069 | 1067 | /* basic machine hardware */ |
| 1070 | 1068 | MDRV_CPU_ADD("main",Z80, XTAL_36MHz/6) /* verified on pcb */ |
| 1071 | 1069 | MDRV_CPU_PROGRAM_MAP(readmem,writemem) |
| 1072 | MDRV_CPU_IO_MAP( | |
| 1070 | MDRV_CPU_IO_MAP(io_ma | |
| 1073 | 1071 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 1074 | 1072 | |
| 1075 | 1073 | MDRV_CPU_ADD("audio", Z80, XTAL_36MHz/12) /* verified on pcb */ |
| r3232 | r3233 | |
| 1926 | 1924 | GAME( 1986, getstarj, getstar, slapfigh, getstarj, getstarj, ROT0, "Taito", "Get Star (Japan)", GAME_NO_COCKTAIL ) |
| 1927 | 1925 | GAME( 1986, gtstarb1, getstar, slapfigh, getstarj, gtstarb1, ROT0, "bootleg", "Get Star (bootleg set 1)", GAME_NO_COCKTAIL ) |
| 1928 | 1926 | GAME( 1986, gtstarb2, getstar, slapfigh, gtstarb2, gtstarb2, ROT0, "bootleg", "Get Star (bootleg set 2)", GAME_NO_COCKTAIL ) |
| 1927 |
| r3232 | r3233 | |
|---|---|---|
| 8 | 8 | Sound: HuC6280A, YM2151, YM3012, OKI M6295 (x2) |
| 9 | 9 | OSC: 32.220MHz, 28.000MHz |
| 10 | 10 | DIPs: 8 position (x2) |
| 11 | PALs: (not dumped) VF-01 (PAL16L8) | |
| 12 | VF-02 (22CV10P) | |
| 13 | VF-03 (PAL16L8) | |
| 14 | VF-04 (PAL 16L8) | |
| 15 | VF-05 (PAL 16L8) | |
| 11 | PALs: (not dumped) VF-00 (PAL16L8) | |
| 12 | VF-01 (PAL16L8) | |
| 13 | VF-02 (22CV10P) | |
| 14 | VF-03 (PAL16L8) | |
| 15 | VF-04 (PAL16L8) | |
| 16 | VF-05 (PAL16L8) | |
| 16 | 17 | |
| 17 | 18 | PROM: MB7122 (compatible to 82S137, located near MBD-09) |
| 18 | 19 | |
| r3232 | r3233 | |
| 340 | 341 | |
| 341 | 342 | /**********************************************************************************/ |
| 342 | 343 | |
| 343 | ROM_START( boogwing ) | |
| 344 | ROM_START( boogwing ) /* VER 1.5 EUR 92.12.07 */ | |
| 344 | 345 | ROM_REGION( 0x100000, "main", 0 ) /* DE102 code (encrypted) */ |
| 345 | ROM_LOAD16_BYTE( "kn00-2.2b", 0x000000, 0x040000, CRC(e38892b9) SHA1(49b5637965a43e0378e1258c5f0a780926f1f283) ) | |
| 346 | ROM_LOAD16_BYTE( "kn02-2.2e", 0x000001, 0x040000, CRC(8426efef) SHA1(2ea33cbd58b638053d75668a484648dbf67dabb8) ) | |
| 347 | ROM_LOAD16_BYTE( "kn01-2.4b", 0x080000, 0x040000, CRC(3ad4b54c) SHA1(5141001768266995078407851b445378b21453de) ) | |
| 348 | ROM_LOAD16_BYTE( "kn03-2.4e", 0x080001, 0x040000, CRC(10b61f4a) SHA1(41d7f670defbd7dae89afafac9839a9e237814d5) ) | |
| 346 | ROM_LOAD16_BYTE( "kn_00-2.2b", 0x000000, 0x040000, CRC(e38892b9) SHA1(49b5637965a43e0378e1258c5f0a780926f1f283) ) | |
| 347 | ROM_LOAD16_BYTE( "kn_02-2.2e", 0x000001, 0x040000, CRC(8426efef) SHA1(2ea33cbd58b638053d75668a484648dbf67dabb8) ) | |
| 348 | ROM_LOAD16_BYTE( "kn_01-2.4b", 0x080000, 0x040000, CRC(3ad4b54c) SHA1(5141001768266995078407851b445378b21453de) ) | |
| 349 | ROM_LOAD16_BYTE( "kn_03-2.4e", 0x080001, 0x040000, CRC(10b61f4a) SHA1(41d7f670defbd7dae89afafac9839a9e237814d5) ) | |
| 349 | 350 | |
| 350 | 351 | ROM_REGION( 0x10000, "audio", 0 ) |
| 351 | ROM_LOAD( "k | |
| 352 | ROM_LOAD( "km06.18p", 0x00000, 0x10000, CRC(3e8bc4e1) SHA1(7e4c357afefa47b8f101727e06485eb9ebae635d) ) | |
| 352 | 353 | |
| 353 | 354 | ROM_REGION( 0x20000, "tiles1", ROMREGION_DISPOSE ) /* Tiles 1 */ |
| 354 | ROM_LOAD16_BYTE( "kn05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 355 | ROM_LOAD16_BYTE( "kn04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 355 | ROM_LOAD16_BYTE( "km05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 356 | ROM_LOAD16_BYTE( "km04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 356 | 357 | |
| 357 | 358 | ROM_REGION( 0x300000, "tiles2", ROMREGION_DISPOSE ) /* Tiles 2 */ |
| 358 | 359 | ROM_LOAD( "mbd-01.9b", 0x000000, 0x100000, CRC(d7de4f4b) SHA1(4747f8795e277ed8106667b6f68e1176d95db684) ) |
| r3232 | r3233 | |
| 386 | 387 | |
| 387 | 388 | ROM_START( boogwina ) |
| 388 | 389 | ROM_REGION( 0x100000, "main", 0 ) /* DE102 code (encrypted) */ |
| 389 | ROM_LOAD16_BYTE( "km00-2.2b", 0x000000, 0x040000, CRC(71ab71c6) SHA1(00bfd71dd9ae5f12c574ab0ecc07d85898930c4b) ) | |
| 390 | ROM_LOAD16_BYTE( "km02-2.2e", 0x000001, 0x040000, CRC(e90f07f9) SHA1(1e8bd3983ed875f4752cbf2ab1c7e748d3df019c) ) | |
| 391 | ROM_LOAD16_BYTE( "km01-2.4b", 0x080000, 0x040000, CRC(7fdce2d3) SHA1(5ce9b8ac26700f1c3bfb3ce4845f890b81241823) ) | |
| 392 | ROM_LOAD16_BYTE( "km03-2.4e", 0x080001, 0x040000, CRC(0b582de3) SHA1(f5c58c7e0e8a227506a81e38c266356596dcda7b) ) | |
| 390 | ROM_LOAD16_BYTE( "km_00-2.2b", 0x000000, 0x040000, CRC(71ab71c6) SHA1(00bfd71dd9ae5f12c574ab0ecc07d85898930c4b) ) | |
| 391 | ROM_LOAD16_BYTE( "km_02-2.2e", 0x000001, 0x040000, CRC(e90f07f9) SHA1(1e8bd3983ed875f4752cbf2ab1c7e748d3df019c) ) | |
| 392 | ROM_LOAD16_BYTE( "km_01-2.4b", 0x080000, 0x040000, CRC(7fdce2d3) SHA1(5ce9b8ac26700f1c3bfb3ce4845f890b81241823) ) | |
| 393 | ROM_LOAD16_BYTE( "km_03-2.4e", 0x080001, 0x040000, CRC(0b582de3) SHA1(f5c58c7e0e8a227506a81e38c266356596dcda7b) ) | |
| 393 | 394 | |
| 394 | 395 | ROM_REGION( 0x10000, "audio", 0 ) |
| 395 | 396 | ROM_LOAD( "km06.18p", 0x00000, 0x10000, CRC(3e8bc4e1) SHA1(7e4c357afefa47b8f101727e06485eb9ebae635d) ) |
| 396 | 397 | |
| 397 | 398 | ROM_REGION( 0x20000, "tiles1", ROMREGION_DISPOSE ) /* Tiles 1 */ |
| 398 | ROM_LOAD16_BYTE( "kn05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 399 | ROM_LOAD16_BYTE( "kn04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 399 | ROM_LOAD16_BYTE( "km05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 400 | ROM_LOAD16_BYTE( "km04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 400 | 401 | |
| 401 | 402 | ROM_REGION( 0x300000, "tiles2", ROMREGION_DISPOSE ) /* Tiles 2 */ |
| 402 | 403 | ROM_LOAD( "mbd-01.9b", 0x000000, 0x100000, CRC(d7de4f4b) SHA1(4747f8795e277ed8106667b6f68e1176d95db684) ) |
| r3232 | r3233 | |
| 428 | 429 | ROM_LOAD( "kj-00.15n", 0x000000, 0x00400, CRC(add4d50b) SHA1(080e5a8192a146d5141aef5c8d9996ddf8cd3ab4) ) |
| 429 | 430 | ROM_END |
| 430 | 431 | |
| 431 | ROM_START( ragtime ) | |
| 432 | ROM_START( ragtime ) /* VER 1.5 JPN 92.12.07 */ | |
| 432 | 433 | ROM_REGION( 0x100000, "main", 0 ) /* DE102 code (encrypted) */ |
| 433 | ROM_LOAD16_BYTE( "kh00-1.2b", 0x000000, 0x040000, CRC(553e179f) SHA1(ab156d9eca4a74084da944989529fd8f5a147dfc) ) | |
| 434 | ROM_LOAD16_BYTE( "kh02-1.2e", 0x000001, 0x040000, CRC(6c759ec0) SHA1(f503d225c31543a7cd975fc599811a31ff729251) ) | |
| 435 | ROM_LOAD16_BYTE( "kh01-1.4b", 0x080000, 0x040000, CRC(12dfee70) SHA1(a7c8fd118f589ef13bcb43a6aa446ff81015f5b3) ) | |
| 436 | ROM_LOAD16_BYTE( "kh03-1.4e", 0x080001, 0x040000, CRC(076fea18) SHA1(342ca71b6d8c8be92dbf221ada717bdbd0061226) ) | |
| 434 | ROM_LOAD16_BYTE( "kh_00-2.2b", 0x000000, 0x040000, CRC(553e179f) SHA1(ab156d9eca4a74084da944989529fd8f5a147dfc) ) | |
| 435 | ROM_LOAD16_BYTE( "kh_02-2.2e", 0x000001, 0x040000, CRC(6c759ec0) SHA1(f503d225c31543a7cd975fc599811a31ff729251) ) | |
| 436 | ROM_LOAD16_BYTE( "kh_01-2.4b", 0x080000, 0x040000, CRC(12dfee70) SHA1(a7c8fd118f589ef13bcb43a6aa446ff81015f5b3) ) | |
| 437 | ROM_LOAD16_BYTE( "kh_03-2.4e", 0x080001, 0x040000, CRC(076fea18) SHA1(342ca71b6d8c8be92dbf221ada717bdbd0061226) ) | |
| 437 | 438 | |
| 438 | 439 | ROM_REGION( 0x10000, "audio", 0 ) |
| 439 | 440 | ROM_LOAD( "km06.18p", 0x00000, 0x10000, CRC(3e8bc4e1) SHA1(7e4c357afefa47b8f101727e06485eb9ebae635d) ) |
| 440 | 441 | |
| 441 | 442 | ROM_REGION( 0x20000, "tiles1", ROMREGION_DISPOSE ) /* Tiles 1 */ |
| 442 | ROM_LOAD16_BYTE( "kn05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 443 | ROM_LOAD16_BYTE( "kn04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 443 | ROM_LOAD16_BYTE( "km05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 444 | ROM_LOAD16_BYTE( "km04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 444 | 445 | |
| 445 | 446 | ROM_REGION( 0x300000, "tiles2", ROMREGION_DISPOSE ) /* Tiles 2 */ |
| 446 | 447 | ROM_LOAD( "mbd-01.9b", 0x000000, 0x100000, CRC(d7de4f4b) SHA1(4747f8795e277ed8106667b6f68e1176d95db684) ) |
| r3232 | r3233 | |
| 472 | 473 | ROM_LOAD( "kj-00.15n", 0x000000, 0x00400, CRC(add4d50b) SHA1(080e5a8192a146d5141aef5c8d9996ddf8cd3ab4) ) |
| 473 | 474 | ROM_END |
| 474 | 475 | |
| 476 | ROM_START( ragtimea ) /* VER 1.3 JPN 92.11.26 */ | |
| 477 | ROM_REGION( 0x100000, "main", 0 ) /* DE102 code (encrypted) */ | |
| 478 | ROM_LOAD16_BYTE( "kh_00-1.2b", 0x000000, 0x040000, CRC(88f0155a) SHA1(6f11cc91e36cd68b7143e3326d92b258f051012e) ) | |
| 479 | ROM_LOAD16_BYTE( "kh_02-1.2e", 0x000001, 0x040000, CRC(8811b41b) SHA1(d395338bcd812add0de3d1554d1dc3e048d0e4c9) ) | |
| 480 | ROM_LOAD16_BYTE( "kh_01-1.4b", 0x080000, 0x040000, CRC(4dab63ad) SHA1(8c6f6e8382bcbba6e1a7ced504397181e7d6e1d1) ) | |
| 481 | ROM_LOAD16_BYTE( "kh_03-1.4e", 0x080001, 0x040000, CRC(8a4cbb18) SHA1(272c8e2b20b0a38ce37552be00130c4117533ea9) ) | |
| 482 | ||
| 483 | ROM_REGION( 0x10000, "audio", 0 ) | |
| 484 | ROM_LOAD( "km06.18p", 0x00000, 0x10000, CRC(3e8bc4e1) SHA1(7e4c357afefa47b8f101727e06485eb9ebae635d) ) | |
| 485 | ||
| 486 | ROM_REGION( 0x20000, "tiles1", ROMREGION_DISPOSE ) /* Tiles 1 */ | |
| 487 | ROM_LOAD16_BYTE( "km05.9e", 0x00000, 0x010000, CRC(d10aef95) SHA1(a611a35ab312caee19c31da079c647679d31673d) ) | |
| 488 | ROM_LOAD16_BYTE( "km04.8e", 0x00001, 0x010000, CRC(329323a8) SHA1(e2ec7b059301c0a2e052dfc683e044c808ad9b33) ) | |
| 489 | ||
| 490 | ROM_REGION( 0x300000, "tiles2", ROMREGION_DISPOSE ) /* Tiles 2 */ | |
| 491 | ROM_LOAD( "mbd-01.9b", 0x000000, 0x100000, CRC(d7de4f4b) SHA1(4747f8795e277ed8106667b6f68e1176d95db684) ) | |
| 492 | ROM_LOAD( "mbd-00.8b", 0x100000, 0x100000, CRC(adb20ba9) SHA1(2ffa1dd19a438a4d2f5743b1050a8037183a3e7d) ) | |
| 493 | /* 0x100000 bytes expanded from mbd-02.10e copied here later */ | |
| 494 | ||
| 495 | ROM_REGION( 0x200000, "tiles3", ROMREGION_DISPOSE ) /* Tiles 3 */ | |
| 496 | ROM_LOAD( "mbd-03.13b", 0x000000, 0x100000, CRC(cf798f2c) SHA1(f484a22679d6a4d4b0dcac820de3f1a37cbc478f) ) | |
| 497 | ROM_LOAD( "mbd-04.14b", 0x100000, 0x100000, CRC(d9764d0b) SHA1(74d6f09d65d073606a6e10556cedf740aa50ff08) ) | |
| 498 | ||
| 499 | ROM_REGION( 0x400000, "sprites1", ROMREGION_DISPOSE ) /* Sprites 1 */ | |
| 500 | ROM_LOAD16_BYTE( "mbd-05.16b", 0x000001, 0x200000, CRC(1768c66a) SHA1(06bf3bb187c65db9dcce959a43a7231e2ac45c17) ) | |
| 501 | ROM_LOAD16_BYTE( "mbd-06.17b", 0x000000, 0x200000, CRC(7750847a) SHA1(358266ed68a9816094e7aab0905d958284c8ce98) ) | |
| 502 | ||
| 503 | ROM_REGION( 0x400000, "sprites2", ROMREGION_DISPOSE ) /* Sprites 2 */ | |
| 504 | ROM_LOAD16_BYTE( "mbd-07.18b", 0x000001, 0x200000, CRC(241faac1) SHA1(588be0cf2647c1d185a99c987a5a20ab7ad8dea8) ) | |
| 505 | ROM_LOAD16_BYTE( "mbd-08.19b", 0x000000, 0x200000, CRC(f13b1e56) SHA1(f8f5e8c4e6c159f076d4e6505bd901ade5c6a0ca) ) | |
| 506 | ||
| 507 | ROM_REGION( 0x0100000, "gfx6", ROMREGION_DISPOSE ) /* 1bpp graphics */ | |
| 508 | ROM_LOAD16_BYTE( "mbd-02.10e", 0x000000, 0x080000, CRC(b25aa721) SHA1(efe800759080bd1dac2da93bd79062a48c5da2b2) ) | |
| 509 | ||
| 510 | ROM_REGION( 0x80000, "oki1", 0 ) /* Oki samples 1 */ | |
| 511 | ROM_LOAD( "mbd-10.17p", 0x000000, 0x080000, CRC(f159f76a) SHA1(0b1ea69fecdd151e2b1fa96a21eade492499691d) ) | |
| 512 | ||
| 513 | ROM_REGION( 0x80000, "oki2", 0 ) /* Oki samples 1 */ | |
| 514 | ROM_LOAD( "mbd-09.16p", 0x000000, 0x080000, CRC(f44f2f87) SHA1(d941520bdfc9e6d88c45462bc1f697c18f33498e) ) | |
| 515 | ||
| 516 | ROM_REGION( 0x000400, "proms", ROMREGION_DISPOSE ) /* Priority (not used) */ | |
| 517 | ROM_LOAD( "kj-00.15n", 0x000000, 0x00400, CRC(add4d50b) SHA1(080e5a8192a146d5141aef5c8d9996ddf8cd3ab4) ) | |
| 518 | ROM_END | |
| 519 | ||
| 475 | 520 | static DRIVER_INIT( boogwing ) |
| 476 | 521 | { |
| 477 | 522 | const UINT8* src=memory_region(machine, "gfx6"); |
| r3232 | r3233 | |
| 488 | 533 | GAME( 1992, boogwing, 0, boogwing, boogwing, boogwing, ROT0, "Data East Corporation", "Boogie Wings (Euro v1.5, 92.12.07)", 0 ) |
| 489 | 534 | GAME( 1992, boogwina, boogwing, boogwing, boogwing, boogwing, ROT0, "Data East Corporation", "Boogie Wings (Asia v1.5, 92.12.07)", 0 ) |
| 490 | 535 | GAME( 1992, ragtime, boogwing, boogwing, boogwing, boogwing, ROT0, "Data East Corporation", "The Great Ragtime Show (Japan v1.5, 92.12.07)", 0 ) |
| 536 | GAME( 1992, ragtimea, boogwing, boogwing, boogwing, boogwing, ROT0, "Data East Corporation", "The Great Ragtime Show (Japan v1.3, 92.11.26)", 0 ) |
| r3232 | r3233 | |
|---|---|---|
| 66 | 66 | AM_RANGE(0xf200, 0xffff) AM_WRITE(SMH_RAM) |
| 67 | 67 | ADDRESS_MAP_END |
| 68 | 68 | |
| 69 | static ADDRESS_MAP_START( quizdna_ | |
| 69 | static ADDRESS_MAP_START( quizdna_io_ma | |
| 70 | 70 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 71 | AM_RANGE(0x02, 0x03) AM_WRITE(quizdna_bg_xscroll_w) | |
| 72 | AM_RANGE(0x04, 0x04) AM_WRITE(quizdna_bg_yscroll_w) | |
| 73 | AM_RANGE(0x05, 0x06) AM_WRITE(SMH_NOP) /* unknown */ | |
| 71 | 74 | AM_RANGE(0x80, 0x80) AM_READ_PORT("P1") |
| 72 | 75 | AM_RANGE(0x81, 0x81) AM_READ_PORT("P2") |
| 73 | 76 | AM_RANGE(0x90, 0x90) AM_READ_PORT("SYSTEM") |
| 74 | 77 | AM_RANGE(0x91, 0x91) AM_READ_PORT("SERVICE") |
| 75 | AM_RANGE(0xe0, 0xe0) AM_READ(ym2203_status_port_0_r) | |
| 76 | AM_RANGE(0xe1, 0xe1) AM_READ(ym2203_read_port_0_r) | |
| 77 | AM_RANGE(0xf0, 0xf0) AM_READ(okim6295_status_0_r) | |
| 78 | ||
| 79 | ADDRESS_MAP_END | |
| 80 | ||
| 81 | static ADDRESS_MAP_START( quizdna_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 82 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 83 | AM_RANGE(0x02, 0x03) AM_WRITE(quizdna_bg_xscroll_w) | |
| 84 | AM_RANGE(0x04, 0x04) AM_WRITE(quizdna_bg_yscroll_w) | |
| 85 | AM_RANGE(0x05, 0x06) AM_WRITE(SMH_NOP) /* unknown */ | |
| 86 | 78 | AM_RANGE(0xc0, 0xc0) AM_WRITE(quizdna_rombank_w) |
| 87 | 79 | AM_RANGE(0xd0, 0xd0) AM_WRITE(quizdna_screen_ctrl_w) |
| 88 | AM_RANGE(0xe0, 0xe0) AM_WRITE(ym2203_control_port_0_w) | |
| 89 | AM_RANGE(0xe1, 0xe1) AM_WRITE(ym2203_write_port_0_w) | |
| 90 | AM_RANGE(0xf0, 0xf0) AM_WRITE(okim6295_data_0_w) | |
| 80 | AM_RANGE(0xe0, 0xe0) AM_READWRITE(ym2203_status_port_0_r, ym2203_control_port_0_w) | |
| 81 | AM_RANGE(0xe1, 0xe1) AM_READWRITE(ym2203_read_port_0_r, ym2203_write_port_0_w) | |
| 82 | AM_RANGE(0xf0, 0xf0) AM_READWRITE(okim6295_status_0_r, okim6295_data_0_w) | |
| 91 | 83 | ADDRESS_MAP_END |
| 92 | 84 | |
| 93 | static ADDRESS_MAP_START( gakupara_ | |
| 85 | static ADDRESS_MAP_START( gakupara_ | |
| 94 | 86 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 95 | 87 | AM_RANGE(0x00, 0x01) AM_WRITE(quizdna_bg_xscroll_w) |
| 96 | 88 | AM_RANGE(0x02, 0x02) AM_WRITE(quizdna_bg_yscroll_w) |
| 97 | 89 | AM_RANGE(0x03, 0x04) AM_WRITE(SMH_NOP) /* unknown */ |
| 90 | AM_RANGE(0x80, 0x80) AM_READ_PORT("P1") | |
| 91 | AM_RANGE(0x81, 0x81) AM_READ_PORT("P2") | |
| 92 | AM_RANGE(0x90, 0x90) AM_READ_PORT("SYSTEM") | |
| 93 | AM_RANGE(0x91, 0x91) AM_READ_PORT("SERVICE") | |
| 98 | 94 | AM_RANGE(0xc0, 0xc0) AM_WRITE(quizdna_rombank_w) |
| 99 | 95 | AM_RANGE(0xd0, 0xd0) AM_WRITE(quizdna_screen_ctrl_w) |
| 100 | AM_RANGE(0xe0, 0xe0) AM_WRITE(ym2203_control_port_0_w) | |
| 101 | AM_RANGE(0xe1, 0xe1) AM_WRITE(ym2203_write_port_0_w) | |
| 102 | AM_RANGE(0xf0, 0xf0) AM_WRITE(okim6295_data_0_w) | |
| 96 | AM_RANGE(0xe0, 0xe0) AM_READWRITE(ym2203_status_port_0_r, ym2203_control_port_0_w) | |
| 97 | AM_RANGE(0xe1, 0xe1) AM_READWRITE(ym2203_read_port_0_r, ym2203_write_port_0_w) | |
| 98 | AM_RANGE(0xf0, 0xf0) AM_READWRITE(okim6295_status_0_r, okim6295_data_0_w) | |
| 103 | 99 | ADDRESS_MAP_END |
| 104 | 100 | |
| 105 | static ADDRESS_MAP_START( gekiretu_ | |
| 101 | static ADDRESS_MAP_START( gekiretu_ | |
| 106 | 102 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 107 | 103 | AM_RANGE(0x02, 0x03) AM_WRITE(quizdna_bg_xscroll_w) |
| 108 | 104 | AM_RANGE(0x04, 0x04) AM_WRITE(quizdna_bg_yscroll_w) |
| 109 | 105 | AM_RANGE(0x05, 0x06) AM_WRITE(SMH_NOP) /* unknown */ |
| 106 | AM_RANGE(0x80, 0x80) AM_READ_PORT("P1") | |
| 107 | AM_RANGE(0x81, 0x81) AM_READ_PORT("P2") | |
| 108 | AM_RANGE(0x90, 0x90) AM_READ_PORT("SYSTEM") | |
| 109 | AM_RANGE(0x91, 0x91) AM_READ_PORT("SERVICE") | |
| 110 | 110 | AM_RANGE(0xc0, 0xc0) AM_WRITE(gekiretu_rombank_w) |
| 111 | 111 | AM_RANGE(0xd0, 0xd0) AM_WRITE(quizdna_screen_ctrl_w) |
| 112 | AM_RANGE(0xe0, 0xe0) AM_WRITE(ym2203_control_port_0_w) | |
| 113 | AM_RANGE(0xe1, 0xe1) AM_WRITE(ym2203_write_port_0_w) | |
| 114 | AM_RANGE(0xf0, 0xf0) AM_WRITE(okim6295_data_0_w) | |
| 112 | AM_RANGE(0xe0, 0xe0) AM_READWRITE(ym2203_status_port_0_r, ym2203_control_port_0_w) | |
| 113 | AM_RANGE(0xe1, 0xe1) AM_READWRITE(ym2203_read_port_0_r, ym2203_write_port_0_w) | |
| 114 | AM_RANGE(0xf0, 0xf0) AM_READWRITE(okim6295_status_0_r, okim6295_data_0_w) | |
| 115 | 115 | ADDRESS_MAP_END |
| 116 | 116 | |
| 117 | ||
| 117 | 118 | /****************************************************************************/ |
| 118 | 119 | |
| 119 | 120 | static INPUT_PORTS_START( quizdna ) |
| r3232 | r3233 | |
| 462 | 463 | /* basic machine hardware */ |
| 463 | 464 | MDRV_CPU_ADD("main", Z80, MCLK/2) /* 8.000 MHz */ |
| 464 | 465 | MDRV_CPU_PROGRAM_MAP(quizdna_readmem,quizdna_writemem) |
| 465 | MDRV_CPU_IO_MAP(quizdna_ | |
| 466 | MDRV_CPU_IO_MAP(quizdna_ | |
| 466 | 467 | MDRV_CPU_VBLANK_INT("main", irq0_line_hold) |
| 467 | 468 | |
| 468 | 469 | /* video hardware */ |
| r3232 | r3233 | |
| 500 | 501 | MDRV_IMPORT_FROM(quizdna) |
| 501 | 502 | |
| 502 | 503 | MDRV_CPU_MODIFY("main") |
| 503 | MDRV_CPU_IO_MAP( | |
| 504 | MDRV_CPU_IO_MAP( | |
| 504 | 505 | |
| 505 | 506 | MACHINE_DRIVER_END |
| 506 | 507 | |
| r3232 | r3233 | |
| 511 | 512 | |
| 512 | 513 | MDRV_CPU_MODIFY("main") |
| 513 | 514 | MDRV_CPU_PROGRAM_MAP(quizdna_readmem,gekiretu_writemem) |
| 514 | MDRV_CPU_IO_MAP( | |
| 515 | MDRV_CPU_IO_MAP( | |
| 515 | 516 | |
| 516 | 517 | MACHINE_DRIVER_END |
| 517 | 518 | |
| r3232 | r3233 | |
| 541 | 542 | |
| 542 | 543 | ROM_REGION( 0x00020, "user1", 0 ) /* fg control */ |
| 543 | 544 | ROM_LOAD( "quiz2.148", 0x000000, 0x000020, CRC(91267e8a) SHA1(ae5bd8efea5322c4d9986d06680a781392f9a642) ) |
| 544 | ||
| 545 | 545 | ROM_END |
| 546 | 546 | |
| 547 | 547 | ROM_START( gakupara ) |
| r3232 | r3233 | |
| 567 | 567 | |
| 568 | 568 | ROM_REGION( 0x00020, "user1", 0 ) /* fg control */ |
| 569 | 569 | ROM_LOAD( "u148.bin", 0x000000, 0x000020, CRC(971df9d2) SHA1(280f5b386922b9902ca9211c719642c2bd0ba899) ) |
| 570 | ||
| 571 | 570 | ROM_END |
| 572 | 571 | |
| 573 | 572 | ROM_START( gekiretu ) |
| r3232 | r3233 | |
| 593 | 592 | |
| 594 | 593 | ROM_REGION( 0x00020, "user1", 0 ) /* fg control */ |
| 595 | 594 | ROM_LOAD( "quiz3.148", 0x000000, 0x000020, CRC(91267e8a) SHA1(ae5bd8efea5322c4d9986d06680a781392f9a642) ) |
| 596 | ||
| 597 | 595 | ROM_END |
| 598 | 596 | |
| 599 | 597 | GAME( 1991, gakupara, 0, gakupara, gakupara, 0, ROT0, "NMK", "Quiz Gakuen Paradise (Japan)", 0 ) |
| r3232 | r3233 | |
|---|---|---|
| 295 | 295 | // from bit mask to bit number |
| 296 | 296 | int bit_p1 = mask_to_bit((input_sel & 0x00ff0000) >> 16); |
| 297 | 297 | int bit_p2 = mask_to_bit((input_sel & 0xff000000) >> 24); |
| 298 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3", "IN4", "IN5", "IN6", "IN7" }; | |
| 298 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3", "IN4", "IN5", "IN6", "IN7" }; | |
| 299 | 299 | |
| 300 | 300 | return (input_port_read(machine, portnames[bit_p1]) & 0x00ffffff) | |
| 301 | 301 | (input_port_read(machine, portnames[bit_p2]) & 0xff000000) ; |
| r3232 | r3233 | |
|---|---|---|
| 221 | 221 | { |
| 222 | 222 | int i; |
| 223 | 223 | UINT16 res = 0xff; |
| 224 | static const char *port[] = { "KEYB_0", "KEYB_1", "KEYB_2", "KEYB_3", "KEYB_4" }; | |
| 224 | static const char *const port[] = { "KEYB_0", "KEYB_1", "KEYB_2", "KEYB_3", "KEYB_4" }; | |
| 225 | 225 | |
| 226 | 226 | for (i = 0; i < 5; i++) |
| 227 | 227 | if (bishjan_input & (1 << i)) |
| r3232 | r3233 | |
|---|---|---|
| 1295 | 1295 | ROM_LOAD( "ev3.1k", 0x04000, 0x2000, CRC(10ff140b) SHA1(7c28f988a9c8b2a702d007096199e67b447a183c) ) |
| 1296 | 1296 | ROM_LOAD( "ev4.1h", 0x06000, 0x2000, CRC(b7917264) SHA1(e58345fda088b171fd348959de15082f3cb42514) ) |
| 1297 | 1297 | |
| 1298 | ROM_REGION( 0x2000, " | |
| 1298 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1299 | 1299 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1300 | 1300 | |
| 1301 | 1301 | ROM_REGION( 0x1000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 1359 | 1359 | ROM_LOAD( "ev3.1k", 0x04000, 0x2000, CRC(10ff140b) SHA1(7c28f988a9c8b2a702d007096199e67b447a183c) ) |
| 1360 | 1360 | ROM_LOAD( "ev4.1h", 0x06000, 0x2000, CRC(b7917264) SHA1(e58345fda088b171fd348959de15082f3cb42514) ) |
| 1361 | 1361 | |
| 1362 | ROM_REGION( 0x2000, " | |
| 1362 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1363 | 1363 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1364 | 1364 | |
| 1365 | 1365 | ROM_REGION( 0x1000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 1417 | 1417 | ROM_LOAD( "hv3vr.bin", 0x04000, 0x2000, CRC(51ee751c) SHA1(60bf848dfdfe313ab05df5a5c05819b0fa87ca50) ) |
| 1418 | 1418 | ROM_LOAD( "hv4vr.bin", 0x06000, 0x2000, CRC(62c7a25b) SHA1(237d3cbdfbf45b33c2f65d30faba151380866a93) ) |
| 1419 | 1419 | |
| 1420 | ROM_REGION( 0x2000, " | |
| 1420 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1421 | 1421 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1422 | 1422 | |
| 1423 | 1423 | ROM_REGION( 0x1000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 1499 | 1499 | ROM_LOAD( "hv3vr.bin", 0x04000, 0x2000, CRC(51ee751c) SHA1(60bf848dfdfe313ab05df5a5c05819b0fa87ca50) ) |
| 1500 | 1500 | ROM_LOAD( "hv4vr.bin", 0x06000, 0x2000, CRC(62c7a25b) SHA1(237d3cbdfbf45b33c2f65d30faba151380866a93) ) |
| 1501 | 1501 | |
| 1502 | ROM_REGION( 0x2000, " | |
| 1502 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1503 | 1503 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1504 | 1504 | |
| 1505 | 1505 | ROM_REGION( 0x1000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 1697 | 1697 | ROM_LOAD( "3_v.1k", 0x04000, 0x2000, CRC(bbee5346) SHA1(753cb784b04f081fa1f8590dc28056d9918f313b) ) |
| 1698 | 1698 | ROM_LOAD( "4_v.1h", 0x06000, 0x2000, CRC(10f45af4) SHA1(00fa599bad8bf3ba6deee54165f381403096e8f9) ) |
| 1699 | 1699 | |
| 1700 | ROM_REGION( 0x2000, " | |
| 1700 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1701 | 1701 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1702 | 1702 | |
| 1703 | 1703 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 1800 | 1800 | /******************************************************************************/ |
| 1801 | 1801 | // Initializations |
| 1802 | 1802 | |
| 1803 | static void unpack_block(const char *region, int offset, int size) | |
| 1803 | static void unpack_block(running_machine *machine, const char *region, int offset, int size) | |
| 1804 | 1804 | { |
| 1805 | UINT8 *rom = memory_region( | |
| 1805 | UINT8 *rom = memory_region(machine, region); | |
| 1806 | 1806 | int i; |
| 1807 | 1807 | |
| 1808 | 1808 | for (i = 0; i < size; ++i) |
| r3232 | r3233 | |
| 1812 | 1812 | } |
| 1813 | 1813 | } |
| 1814 | 1814 | |
| 1815 | static void unpack_region(const char *region) | |
| 1815 | static void unpack_region(running_machine *machine, const char *region) | |
| 1816 | 1816 | { |
| 1817 | unpack_block(region, 0x0000, 0x2000); | |
| 1818 | unpack_block(region, 0x4000, 0x2000); | |
| 1817 | unpack_block(machine, region, 0x0000, 0x2000); | |
| 1818 | unpack_block(machine, region, 0x4000, 0x2000); | |
| 1819 | 1819 | } |
| 1820 | 1820 | |
| 1821 | 1821 | |
| 1822 | 1822 | static DRIVER_INIT( equites ) |
| 1823 | 1823 | { |
| 1824 | unpack_region("gfx2"); | |
| 1825 | unpack_region("gfx3"); | |
| 1824 | unpack_region(machine, "gfx2"); | |
| 1825 | unpack_region(machine, "gfx3"); | |
| 1826 | 1826 | } |
| 1827 | 1827 | |
| 1828 | 1828 | static DRIVER_INIT( bullfgtr ) |
| 1829 | 1829 | { |
| 1830 | unpack_region("gfx2"); | |
| 1831 | unpack_region("gfx3"); | |
| 1830 | unpack_region(machine, "gfx2"); | |
| 1831 | unpack_region(machine, "gfx3"); | |
| 1832 | 1832 | } |
| 1833 | 1833 | |
| 1834 | 1834 | static DRIVER_INIT( kouyakyu ) |
| 1835 | 1835 | { |
| 1836 | unpack_region("gfx2"); | |
| 1837 | unpack_region("gfx3"); | |
| 1836 | unpack_region(machine, "gfx2"); | |
| 1837 | unpack_region(machine, "gfx3"); | |
| 1838 | 1838 | } |
| 1839 | 1839 | |
| 1840 | 1840 | static DRIVER_INIT( gekisou ) |
| 1841 | 1841 | { |
| 1842 | unpack_region("gfx2"); | |
| 1843 | unpack_region("gfx3"); | |
| 1842 | unpack_region(machine, "gfx2"); | |
| 1843 | unpack_region(machine, "gfx3"); | |
| 1844 | 1844 | |
| 1845 | 1845 | // install special handlers for unknown device (protection?) |
| 1846 | 1846 | memory_install_write16_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x580000, 0x580001, 0, 0, gekisou_unknown_0_w); |
| r3232 | r3233 | |
| 1849 | 1849 | |
| 1850 | 1850 | static DRIVER_INIT( splndrbt ) |
| 1851 | 1851 | { |
| 1852 | unpack_region("gfx3"); | |
| 1852 | unpack_region(machine, "gfx3"); | |
| 1853 | 1853 | } |
| 1854 | 1854 | |
| 1855 | 1855 | static DRIVER_INIT( hvoltage ) |
| 1856 | 1856 | { |
| 1857 | unpack_region("gfx3"); | |
| 1857 | unpack_region(machine, "gfx3"); | |
| 1858 | 1858 | |
| 1859 | 1859 | #if HVOLTAGE_DEBUG |
| 1860 | 1860 | memory_install_read16_handler(machine, 0, ADDRESS_SPACE_PROGRAM, 0x000038, 0x000039, 0, 0, hvoltage_debug_r); |
| r3232 | r3233 | |
|---|---|---|
| 266 | 266 | // IRQ |
| 267 | 267 | cpunum_set_input_line(machine, 0, 0, ASSERT_LINE); |
| 268 | 268 | timer_set(ATTOTIME_IN_USEC(50), NULL, 0, irq_stop); |
| 269 | ||
| 270 | laserdisc_vsync(laserdisc); | |
| 271 | 269 | } |
| 272 | 270 | |
| 273 | 271 | static MACHINE_START( esh ) |
| r3232 | r3233 | |
| 289 | 287 | |
| 290 | 288 | MDRV_MACHINE_START(esh) |
| 291 | 289 | |
| 292 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 290 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 293 | 291 | MDRV_LASERDISC_OVERLAY(esh, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 294 | 292 | |
| 295 | 293 | /* video hardware */ |
| r3232 | r3233 | |
| 303 | 301 | /* sound hardware */ |
| 304 | 302 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 305 | 303 | |
| 306 | MDRV_SOUND_ADD("l | |
| 304 | MDRV_SOUND_ADD("l | |
| 307 | 305 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 308 | 306 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 309 | 307 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 4999 | 4999 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5000 | 5000 | |
| 5001 | 5001 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 5002 | ROM_REGION( 0x40000, "audio | |
| 5002 | ROM_REGION( 0x40000, "audio | |
| 5003 | 5003 | ROM_LOAD( "257-m1.bin", 0x00000, 0x40000, CRC(4b749113) SHA1(2af2361146edd0ce3966614d90165a5c1afb8de4) ) |
| 5004 | 5004 | NEO_BIOS_AUDIO_256K( "257-m1_decrypted.bin", CRC(d404db70) SHA1(8cd1f3e140a9a367de23544e76371b0491287909) ) |
| 5005 | 5005 | |
| r3232 | r3233 | |
| 5036 | 5036 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5037 | 5037 | |
| 5038 | 5038 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 5039 | ROM_REGION( 0x40000, "audio | |
| 5039 | ROM_REGION( 0x40000, "audio | |
| 5040 | 5040 | ROM_LOAD( "257-m1.bin", 0x00000, 0x40000, CRC(4b749113) SHA1(2af2361146edd0ce3966614d90165a5c1afb8de4) ) |
| 5041 | 5041 | NEO_BIOS_AUDIO_256K( "257-m1_decrypted.bin", CRC(d404db70) SHA1(8cd1f3e140a9a367de23544e76371b0491287909) ) |
| 5042 | 5042 | |
| r3232 | r3233 | |
| 5205 | 5205 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5206 | 5206 | |
| 5207 | 5207 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 5208 | ROM_REGION( 0x40000, "audio | |
| 5208 | ROM_REGION( 0x40000, "audio | |
| 5209 | 5209 | ROM_LOAD( "265-262-m1.bin", 0x00000, 0x40000, CRC(a7f8119f) SHA1(71805b39b8b09c32425cf39f9de59b2f755976c2) ) /* yes it really does have a strange name */ |
| 5210 | 5210 | /* Decrypted */ |
| 5211 | 5211 | NEO_BIOS_AUDIO_256K( "265-262_decrypted-m1.bin", CRC(4bcc537b) SHA1(9fcf1342bcd53d5eec12c46ee41a51bf543256c2) ) |
| r3232 | r3233 | |
| 5244 | 5244 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5245 | 5245 | |
| 5246 | 5246 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 5247 | ROM_REGION( 0x40000, "audio | |
| 5247 | ROM_REGION( 0x40000, "audio | |
| 5248 | 5248 | ROM_LOAD( "265-262-m1.bin", 0x00000, 0x40000, CRC(a7f8119f) SHA1(71805b39b8b09c32425cf39f9de59b2f755976c2) ) /* yes it really does have a strange name */ |
| 5249 | 5249 | /* Decrypted */ |
| 5250 | 5250 | NEO_BIOS_AUDIO_256K( "265-262_decrypted-m1.bin", CRC(4bcc537b) SHA1(9fcf1342bcd53d5eec12c46ee41a51bf543256c2) ) |
| r3232 | r3233 | |
| 5283 | 5283 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5284 | 5284 | |
| 5285 | 5285 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 5286 | ROM_REGION( 0x20000, "audio | |
| 5286 | ROM_REGION( 0x20000, "audio | |
| 5287 | 5287 | ROM_LOAD( "263-m1.bin", 0x00000, 0x20000, CRC(46ac8228) SHA1(5aeea221050c98e4bb0f16489ce772bf1c80f787) ) |
| 5288 | 5288 | /* Decrypted */ |
| 5289 | 5289 | NEO_BIOS_AUDIO_128K( "263-m1_decrypted.bin", CRC(ef5db532) SHA1(4aeba9e206b8f309610eb7e1891644f39aa61830) ) |
| r3232 | r3233 | |
| 5344 | 5344 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5345 | 5345 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5346 | 5346 | |
| 5347 | ROM_REGION( 0x20000, "audio | |
| 5347 | ROM_REGION( 0x20000, "audio | |
| 5348 | 5348 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5349 | 5349 | ROM_LOAD( "264-m1.bin", 0x00000, 0x20000, CRC(4dbd7b43) SHA1(6b63756b0d2d30bbf13fbd219833c81fd060ef96) ) |
| 5350 | 5350 | /* Decrypted */ |
| r3232 | r3233 | |
| 5382 | 5382 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5383 | 5383 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5384 | 5384 | |
| 5385 | ROM_REGION( 0x20000, "audio | |
| 5385 | ROM_REGION( 0x20000, "audio | |
| 5386 | 5386 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5387 | 5387 | ROM_LOAD( "265-m1.bin", 0x00000, 0x20000, CRC(85aaa632) SHA1(744fba4ca3bc3a5873838af886efb97a8a316104) ) |
| 5388 | 5388 | /* Decrypted */ |
| r3232 | r3233 | |
| 5414 | 5414 | |
| 5415 | 5415 | NEO_SFIX_128K( "265-s1p.bin", CRC(595e0006) SHA1(ff086bdaa6f40e9ad963e1100a27f44618d684ed) ) |
| 5416 | 5416 | |
| 5417 | ROM_REGION( 0x20000, "audio | |
| 5417 | ROM_REGION( 0x20000, "audio | |
| 5418 | 5418 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5419 | 5419 | ROM_LOAD( "265-m1.bin", 0x00000, 0x20000, CRC(85aaa632) SHA1(744fba4ca3bc3a5873838af886efb97a8a316104) ) |
| 5420 | 5420 | /* Decrypted */ |
| r3232 | r3233 | |
| 5446 | 5446 | |
| 5447 | 5447 | NEO_SFIX_128K( "265-s1pa.bin", CRC(1a3ed064) SHA1(9749bb55c750e6b65d651998c2649c5fb68db68e)) |
| 5448 | 5448 | |
| 5449 | ROM_REGION( 0x20000, "audio | |
| 5449 | ROM_REGION( 0x20000, "audio | |
| 5450 | 5450 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5451 | 5451 | ROM_LOAD( "265-m1.bin", 0x00000, 0x20000, CRC(85aaa632) SHA1(744fba4ca3bc3a5873838af886efb97a8a316104) ) |
| 5452 | 5452 | /* Decrypted */ |
| r3232 | r3233 | |
| 5538 | 5538 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5539 | 5539 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5540 | 5540 | |
| 5541 | ROM_REGION( 0x20000, "audio | |
| 5541 | ROM_REGION( 0x20000, "audio | |
| 5542 | 5542 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5543 | 5543 | ROM_LOAD( "266-m1.bin", 0x00000, 0x20000, CRC(456c3e6c) SHA1(5a07d0186198a18d2dda1331093cf29b0b9b2984) ) |
| 5544 | 5544 | /* Decrypted */ |
| r3232 | r3233 | |
| 5575 | 5575 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5576 | 5576 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5577 | 5577 | |
| 5578 | ROM_REGION( 0x80000, "audio | |
| 5578 | ROM_REGION( 0x80000, "audio | |
| 5579 | 5579 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5580 | 5580 | ROM_LOAD( "267-m1.bin", 0x00000, 0x80000, CRC(c7853ccd) SHA1(1b7a4c5093cf0fe3861ce44fd1d3b30c71ad0abe) ) |
| 5581 | 5581 | /* Decrypted */ |
| r3232 | r3233 | |
| 5606 | 5606 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5607 | 5607 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5608 | 5608 | |
| 5609 | ROM_REGION( 0x80000, "audio | |
| 5609 | ROM_REGION( 0x80000, "audio | |
| 5610 | 5610 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5611 | 5611 | ROM_LOAD( "268-m1.bin", 0x00000, 0x80000, CRC(4a5a6e0e) SHA1(df0f660f2465e1db7be5adfcaf5e88ad61a74a42) ) |
| 5612 | 5612 | /* Decrypted */ |
| r3232 | r3233 | |
| 5644 | 5644 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5645 | 5645 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5646 | 5646 | |
| 5647 | ROM_REGION( 0x80000, "audio | |
| 5647 | ROM_REGION( 0x80000, "audio | |
| 5648 | 5648 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5649 | 5649 | ROM_LOAD( "268-m1h.bin", 0x00000, 0x80000, CRC(4a5a6e0e) SHA1(df0f660f2465e1db7be5adfcaf5e88ad61a74a42) ) /* Same as MVS above, but different label */ |
| 5650 | 5650 | /* Decrypted */ |
| r3232 | r3233 | |
| 5721 | 5721 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5722 | 5722 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5723 | 5723 | |
| 5724 | ROM_REGION( 0x80000, "audio | |
| 5724 | ROM_REGION( 0x80000, "audio | |
| 5725 | 5725 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5726 | 5726 | ROM_LOAD( "268-m1.bin", 0x00000, 0x80000, CRC(4a5a6e0e) SHA1(df0f660f2465e1db7be5adfcaf5e88ad61a74a42) ) |
| 5727 | 5727 | /* Decrypted */ |
| r3232 | r3233 | |
| 5828 | 5828 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 5829 | 5829 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 5830 | 5830 | |
| 5831 | ROM_REGION( 0x80000, "audio | |
| 5831 | ROM_REGION( 0x80000, "audio | |
| 5832 | 5832 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 5833 | 5833 | ROM_LOAD( "269-m1.bin", 0x00000, 0x80000, CRC(f6819d00) SHA1(d3bbe09df502464f104e53501708ac6e2c1832c6) ) |
| 5834 | 5834 | /* Decrypted */ |
| r3232 | r3233 | |
| 6020 | 6020 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6021 | 6021 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6022 | 6022 | |
| 6023 | ROM_REGION( 0x80000, "audio | |
| 6023 | ROM_REGION( 0x80000, "audio | |
| 6024 | 6024 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6025 | 6025 | ROM_LOAD( "270-m1.bin", 0x00000, 0x80000, CRC(49c9901a) SHA1(2623e9765a0eba58fee2de72851e9dc502344a3d) ) |
| 6026 | 6026 | /* Decrypted */ |
| r3232 | r3233 | |
| 6058 | 6058 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6059 | 6059 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6060 | 6060 | |
| 6061 | ROM_REGION( 0x80000, "audio | |
| 6061 | ROM_REGION( 0x80000, "audio | |
| 6062 | 6062 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6063 | 6063 | ROM_LOAD( "270-m1.bin", 0x00000, 0x80000, CRC(49c9901a) SHA1(2623e9765a0eba58fee2de72851e9dc502344a3d) ) |
| 6064 | 6064 | /* Decrypted */ |
| r3232 | r3233 | |
| 6096 | 6096 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6097 | 6097 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6098 | 6098 | |
| 6099 | ROM_REGION( 0x80000, "audio | |
| 6099 | ROM_REGION( 0x80000, "audio | |
| 6100 | 6100 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6101 | 6101 | ROM_LOAD( "270-m1.bin", 0x00000, 0x80000, CRC(49c9901a) SHA1(2623e9765a0eba58fee2de72851e9dc502344a3d) ) |
| 6102 | 6102 | /* Decrypted */ |
| r3232 | r3233 | |
| 6174 | 6174 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6175 | 6175 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6176 | 6176 | |
| 6177 | ROM_REGION( 0x080000, "audio | |
| 6177 | ROM_REGION( 0x080000, "audio | |
| 6178 | 6178 | /* The M1 ROM is encrypted, we load it here for reference and replace it with a decrypted version */ |
| 6179 | 6179 | ROM_LOAD( "271-m1c.bin", 0x00000, 0x080000, CRC(f5515629) SHA1(7516bf1b0207a3c8d41dc30c478f8d8b1f71304b) ) |
| 6180 | 6180 | /* Decrypted */ |
| r3232 | r3233 | |
| 6329 | 6329 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6330 | 6330 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6331 | 6331 | |
| 6332 | ROM_REGION( 0x80000, "audio | |
| 6332 | ROM_REGION( 0x80000, "audio | |
| 6333 | 6333 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6334 | 6334 | ROM_LOAD( "272-m1.bin", 0x00000, 0x80000, CRC(adeebf40) SHA1(8cbd63dda3fff4de38060405bf70cd9308c9e66e) ) |
| 6335 | 6335 | /* Decrypted */ |
| r3232 | r3233 | |
| 6367 | 6367 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6368 | 6368 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6369 | 6369 | |
| 6370 | ROM_REGION( 0x80000, "audio | |
| 6370 | ROM_REGION( 0x80000, "audio | |
| 6371 | 6371 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6372 | 6372 | ROM_LOAD( "272-m1.bin", 0x00000, 0x80000, CRC(adeebf40) SHA1(8cbd63dda3fff4de38060405bf70cd9308c9e66e) ) |
| 6373 | 6373 | /* Decrypted */ |
| r3232 | r3233 | |
| 6405 | 6405 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6406 | 6406 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6407 | 6407 | |
| 6408 | ROM_REGION( 0x80000, "audio | |
| 6408 | ROM_REGION( 0x80000, "audio | |
| 6409 | 6409 | /* Encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6410 | 6410 | ROM_LOAD( "272-m1.bin", 0x00000, 0x80000, CRC(adeebf40) SHA1(8cbd63dda3fff4de38060405bf70cd9308c9e66e) ) |
| 6411 | 6411 | /* Decrypted */ |
| r3232 | r3233 | |
| 6443 | 6443 | ROM_REGION( 0x20000, "fixedbios", 0 ) |
| 6444 | 6444 | ROM_LOAD( "sfix.sfx", 0x000000, 0x20000, CRC(354029fc) SHA1(4ae4bf23b4c2acff875775d4cbff5583893ce2a1) ) |
| 6445 | 6445 | |
| 6446 | ROM_REGION( 0x80000, "audio | |
| 6446 | ROM_REGION( 0x80000, "audio | |
| 6447 | 6447 | /* encrypted, we load it here for reference and replace with decrypted ROM */ |
| 6448 | 6448 | ROM_LOAD( "jgp-m1.bin", 0x00000, 0x80000, CRC(d163c690) SHA1(1dfd04d20c5985037f07cd01000d0b04f3a8f4f4) ) |
| 6449 | 6449 | /* Decrypted */ |
| r3232 | r3233 | |
| 6722 | 6722 | ROM_LOAD16_WORD_SWAP( "5008-p2.rom", 0x100000, 0x400000, CRC(a649ec38) SHA1(5c63ed5e5c848940f587c966da4908d04cf1293c) ) |
| 6723 | 6723 | ROM_LOAD16_WORD_SWAP( "5008-p3.rom", 0x500000, 0x200000, CRC(e629e13c) SHA1(6ebe080ce01c51064cb2f4d89315ba98a45ae727) ) |
| 6724 | 6724 | |
| 6725 | ROM_REGION( 0x200000, "audio | |
| 6725 | ROM_REGION( 0x200000, "audio | |
| 6726 | 6726 | ROM_LOAD( "5008-p1.rom", 0x000000, 0x200000, CRC(bf5469ba) SHA1(f05236d8fffab5836c0d27becdeeb80def32ee49) ) |
| 6727 | 6727 | |
| 6728 | 6728 | NEO_SFIX_128K( "5008-s1.rom", CRC(92410064) SHA1(1fb800b46341858207d3b6961a760289fbec7faa) ) |
| r3232 | r3233 | |
|---|---|---|
| 64 | 64 | #include "deprecat.h" |
| 65 | 65 | #include "sound/ay8910.h" |
| 66 | 66 | |
| 67 | static int nSndNum=0x10; | |
| 68 | static int nAyCtrl, nAyData; | |
| 67 | static UINT8 nSndNum; | |
| 68 | static UINT8 nAyCtrl, nAyData; | |
| 69 | 69 | |
| 70 | 70 | static VIDEO_START(mirax) |
| 71 | 71 | { |
| r3232 | r3233 | |
| 85 | 85 | } |
| 86 | 86 | |
| 87 | 87 | |
| 88 | static SOUND_START(mirax) | |
| 89 | { | |
| 90 | nSndNum = 0x10; | |
| 91 | nAyCtrl = 0x00; | |
| 92 | nAyData = 0x00; | |
| 93 | } | |
| 94 | ||
| 88 | 95 | static READ8_HANDLER(snd_read) |
| 89 | 96 | { |
| 90 | 97 | /* bit 6 is used to select AY (1st or 2nd) */ |
| r3232 | r3233 | |
| 195 | 202 | MDRV_VIDEO_START(mirax) |
| 196 | 203 | MDRV_VIDEO_UPDATE(mirax) |
| 197 | 204 | |
| 205 | MDRV_SOUND_START(mirax) | |
| 206 | ||
| 198 | 207 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 199 | 208 | MDRV_SOUND_ADD("ay1", AY8910, 12000000/6 /* guess */) |
| 200 | 209 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.80) |
| r3232 | r3233 | |
|---|---|---|
| 326 | 326 | * |
| 327 | 327 | *************************************/ |
| 328 | 328 | |
| 329 | static ADDRESS_MAP_START( nekkyoku_ | |
| 329 | static ADDRESS_MAP_START( nekkyoku_ | |
| 330 | 330 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 331 | AM_RANGE(0x12, 0x12) AM_READ(SMH_NOP) // unknown | |
| 332 | AM_RANGE(0xe1, 0xe1) AM_READ(fromance_busycheck_sub_r) | |
| 333 | AM_RANGE(0xe6, 0xe6) AM_READ(fromance_commanddata_r) | |
| 334 | ADDRESS_MAP_END | |
| 335 | ||
| 336 | static ADDRESS_MAP_START( nekkyoku_writeport_sub, ADDRESS_SPACE_IO, 8 ) | |
| 337 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 338 | 331 | AM_RANGE(0x10, 0x10) AM_WRITE(fromance_crtc_data_w) |
| 339 | 332 | AM_RANGE(0x11, 0x11) AM_WRITE(fromance_crtc_register_w) |
| 333 | AM_RANGE(0x12, 0x12) AM_READ(SMH_NOP) // unknown | |
| 340 | 334 | AM_RANGE(0xe0, 0xe0) AM_WRITE(fromance_rombank_w) |
| 341 | AM_RANGE(0xe1, 0xe1) AM_WRITE(fromance_gfxreg_w) | |
| 335 | AM_RANGE(0xe1, 0xe1) AM_READWRITE(fromance_busycheck_sub_r, fromance_gfxreg_w) | |
| 342 | 336 | AM_RANGE(0xe2, 0xe5) AM_WRITE(fromance_scroll_w) |
| 343 | AM_RANGE(0xe6, 0xe6) AM_WRITE(fromance_busycheck_sub_w) | |
| 337 | AM_RANGE(0xe6, 0xe6) AM_READWRITE(fromance_commanddata_r, fromance_busycheck_sub_w) | |
| 344 | 338 | AM_RANGE(0xe7, 0xe7) AM_WRITE(fromance_adpcm_reset_w) |
| 345 | 339 | AM_RANGE(0xe8, 0xe8) AM_WRITE(fromance_adpcm_w) |
| 346 | 340 | AM_RANGE(0xe9, 0xe9) AM_WRITE(ay8910_write_port_0_w) |
| 347 | 341 | AM_RANGE(0xea, 0xea) AM_WRITE(ay8910_control_port_0_w) |
| 348 | 342 | ADDRESS_MAP_END |
| 349 | 343 | |
| 350 | static ADDRESS_MAP_START( | |
| 344 | static ADDRESS_MAP_START( idolmj | |
| 351 | 345 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 352 | AM_RANGE(0x12, 0x12) AM_READ(SMH_NOP) // unknown | |
| 353 | AM_RANGE(0x21, 0x21) AM_READ(fromance_busycheck_sub_r) | |
| 354 | AM_RANGE(0x26, 0x26) AM_READ(fromance_commanddata_r) | |
| 355 | ADDRESS_MAP_END | |
| 356 | ||
| 357 | static ADDRESS_MAP_START( idolmj_writeport_sub, ADDRESS_SPACE_IO, 8 ) | |
| 358 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 359 | 346 | AM_RANGE(0x10, 0x10) AM_WRITE(fromance_crtc_data_w) |
| 360 | 347 | AM_RANGE(0x11, 0x11) AM_WRITE(fromance_crtc_register_w) |
| 348 | AM_RANGE(0x12, 0x12) AM_READ(SMH_NOP) // unknown | |
| 361 | 349 | AM_RANGE(0x20, 0x20) AM_WRITE(fromance_rombank_w) |
| 362 | AM_RANGE(0x21, 0x21) AM_WRITE(fromance_gfxreg_w) | |
| 350 | AM_RANGE(0x21, 0x21) AM_READWRITE(fromance_busycheck_sub_r, fromance_gfxreg_w) | |
| 363 | 351 | AM_RANGE(0x22, 0x25) AM_WRITE(fromance_scroll_w) |
| 364 | AM_RANGE(0x26, 0x26) AM_WRITE(fromance_busycheck_sub_w) | |
| 352 | AM_RANGE(0x26, 0x26) AM_READWRITE(fromance_commanddata_r, fromance_busycheck_sub_w) | |
| 365 | 353 | AM_RANGE(0x27, 0x27) AM_WRITE(fromance_adpcm_reset_w) |
| 366 | 354 | AM_RANGE(0x28, 0x28) AM_WRITE(fromance_adpcm_w) |
| 367 | 355 | AM_RANGE(0x29, 0x29) AM_WRITE(ay8910_write_port_0_w) |
| 368 | 356 | AM_RANGE(0x2a, 0x2a) AM_WRITE(ay8910_control_port_0_w) |
| 369 | 357 | ADDRESS_MAP_END |
| 370 | 358 | |
| 371 | static ADDRESS_MAP_START( fromance_ | |
| 359 | static ADDRESS_MAP_START( fromance_ | |
| 372 | 360 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 373 | 361 | AM_RANGE(0x10, 0x10) AM_WRITE(fromance_crtc_data_w) |
| 374 | 362 | AM_RANGE(0x11, 0x11) AM_WRITE(fromance_crtc_register_w) |
| 363 | AM_RANGE(0x12, 0x12) AM_READ(SMH_NOP) // unknown | |
| 375 | 364 | AM_RANGE(0x20, 0x20) AM_WRITE(fromance_rombank_w) |
| 376 | AM_RANGE(0x21, 0x21) AM_WRITE(fromance_gfxreg_w) | |
| 365 | AM_RANGE(0x21, 0x21) AM_READWRITE(fromance_busycheck_sub_r, fromance_gfxreg_w) | |
| 377 | 366 | AM_RANGE(0x22, 0x25) AM_WRITE(fromance_scroll_w) |
| 378 | AM_RANGE(0x26, 0x26) AM_WRITE(fromance_busycheck_sub_w) | |
| 367 | AM_RANGE(0x26, 0x26) AM_READWRITE(fromance_commanddata_r, fromance_busycheck_sub_w) | |
| 379 | 368 | AM_RANGE(0x27, 0x27) AM_WRITE(fromance_adpcm_reset_w) |
| 380 | 369 | AM_RANGE(0x28, 0x28) AM_WRITE(fromance_adpcm_w) |
| 381 | 370 | AM_RANGE(0x2a, 0x2a) AM_WRITE(ym2413_register_port_0_w) |
| r3232 | r3233 | |
| 383 | 372 | ADDRESS_MAP_END |
| 384 | 373 | |
| 385 | 374 | |
| 386 | ||
| 387 | 375 | /************************************* |
| 388 | 376 | * |
| 389 | 377 | * Port definitions |
| r3232 | r3233 | |
| 1032 | 1020 | |
| 1033 | 1021 | MDRV_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */ |
| 1034 | 1022 | MDRV_CPU_PROGRAM_MAP(nekkyoku_readmem_sub,nekkyoku_writemem_sub) |
| 1035 | MDRV_CPU_IO_MAP(nekkyoku_ | |
| 1023 | MDRV_CPU_IO_MAP(nekkyoku_ | |
| 1036 | 1024 | |
| 1037 | 1025 | MDRV_MACHINE_RESET(fromance) |
| 1038 | 1026 | |
| r3232 | r3233 | |
| 1070 | 1058 | |
| 1071 | 1059 | MDRV_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */ |
| 1072 | 1060 | MDRV_CPU_PROGRAM_MAP(fromance_readmem_sub,fromance_writemem_sub) |
| 1073 | MDRV_CPU_IO_MAP( | |
| 1061 | MDRV_CPU_IO_MAP( | |
| 1074 | 1062 | |
| 1075 | 1063 | MDRV_MACHINE_RESET(fromance) |
| 1076 | 1064 | |
| r3232 | r3233 | |
| 1108 | 1096 | |
| 1109 | 1097 | MDRV_CPU_ADD("sub", Z80,12000000/2) /* 6.00 Mhz ? */ |
| 1110 | 1098 | MDRV_CPU_PROGRAM_MAP(fromance_readmem_sub,fromance_writemem_sub) |
| 1111 | MDRV_CPU_IO_MAP(fromance_ | |
| 1099 | MDRV_CPU_IO_MAP(fromance_ | |
| 1112 | 1100 | |
| 1113 | 1101 | MDRV_MACHINE_RESET(fromance) |
| 1114 | 1102 | |
| r3232 | r3233 | |
| 1357 | 1345 | GAME( 1990, daiyogen, 0, fromance, daiyogen, 0, ROT0, "Video System Co.", "Mahjong Daiyogen (Japan)", 0 ) |
| 1358 | 1346 | GAME( 1991, nmsengen, 0, fromance, nmsengen, 0, ROT0, "Video System Co.", "Nekketsu Mahjong Sengen! AFTER 5 (Japan)", 0 ) |
| 1359 | 1347 | GAME( 1991, fromance, 0, fromance, fromance, 0, ROT0, "Video System Co.", "Idol-Mahjong Final Romance (Japan)", 0 ) |
| 1348 |
| r3232 | r3233 | |
|---|---|---|
| 222 | 222 | |
| 223 | 223 | static INTERRUPT_GEN( vblank_callback ) |
| 224 | 224 | { |
| 225 | /* update the laserdisc */ | |
| 226 | laserdisc_vsync(laserdisc); | |
| 227 | ||
| 228 | 225 | /* also update the speaker on the European version */ |
| 229 | 226 | if (sndti_exists(SOUND_BEEP, 0)) |
| 230 | 227 | { |
| r3232 | r3233 | |
| 727 | 724 | MDRV_SOUND_CONFIG(ay8910_config) |
| 728 | 725 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 0.33) |
| 729 | 726 | |
| 730 | MDRV_SOUND_ADD("l | |
| 727 | MDRV_SOUND_ADD("l | |
| 731 | 728 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 732 | 729 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 733 | 730 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 736 | 733 | |
| 737 | 734 | static MACHINE_DRIVER_START( dlair_pr7820 ) |
| 738 | 735 | MDRV_IMPORT_FROM(dlair_base) |
| 739 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR7820) | |
| 736 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR7820, "main", "ldsound") | |
| 740 | 737 | MACHINE_DRIVER_END |
| 741 | 738 | |
| 742 | 739 | |
| 743 | 740 | static MACHINE_DRIVER_START( dlair_ldv1000 ) |
| 744 | 741 | MDRV_IMPORT_FROM(dlair_base) |
| 745 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 742 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 746 | 743 | MACHINE_DRIVER_END |
| 747 | 744 | |
| 748 | 745 | |
| r3232 | r3233 | |
| 760 | 757 | MDRV_MACHINE_START(dleuro) |
| 761 | 758 | MDRV_MACHINE_RESET(dlair) |
| 762 | 759 | |
| 763 | MDRV_LASERDISC_ADD("laserdisc", PHILLIPS_22VP932) | |
| 760 | MDRV_LASERDISC_ADD("laserdisc", PHILLIPS_22VP932, "main", "ldsound") | |
| 764 | 761 | MDRV_LASERDISC_OVERLAY(dleuro, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 765 | 762 | |
| 766 | 763 | /* video hardware */ |
| r3232 | r3233 | |
|---|---|---|
| 1605 | 1605 | |
| 1606 | 1606 | static READ8_HANDLER( io_mirror_r ) |
| 1607 | 1607 | { |
| 1608 | static const char *portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 1608 | static const char *const portnames[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 1609 | 1609 | |
| 1610 | 1610 | return input_port_read(machine, portnames[offset]); |
| 1611 | 1611 | } |
| r3232 | r3233 | |
|---|---|---|
| 49 | 49 | static READ8_HANDLER( input_port_r ) |
| 50 | 50 | { |
| 51 | 51 | int i, res; |
| 52 | static const char *portnames[] = { "IN0", "IN1", "DSW", "UNUSED0", "UNUSED1", "UNUSED2", "UNUSED3", "UNUSED4" }; | |
| 52 | static const char *const portnames[] = { "IN0", "IN1", "DSW", "UNUSED0", "UNUSED1", "UNUSED2", "UNUSED3", "UNUSED4" }; | |
| 53 | 53 | |
| 54 | 54 | res = 0; |
| 55 | 55 | for (i = 0; i < 8; i++) |
| r3232 | r3233 | |
|---|---|---|
| 287 | 287 | static READ32_HANDLER( turntable_r ) |
| 288 | 288 | { |
| 289 | 289 | UINT32 result = 0; |
| 290 | static const char *ttnames[] = { "TT1", "TT2" }; | |
| 290 | static const char *const ttnames[] = { "TT1", "TT2" }; | |
| 291 | 291 | |
| 292 | 292 | if (ACCESSING_BITS_8_15) |
| 293 | 293 | { |
| r3232 | r3233 | |
|---|---|---|
| 805 | 805 | |
| 806 | 806 | PORT_START("SW1") |
| 807 | 807 | PORT_DIPNAME( 0x01, 0x01, "Line Frequency" ) |
| 808 | PORT_DIPSETTING( 0x01, "60HZ" ) | |
| 809 | PORT_DIPSETTING( 0x00, "50HZ" ) | |
| 808 | PORT_DIPSETTING( 0x01, "60Hz" ) | |
| 809 | PORT_DIPSETTING( 0x00, "50Hz" ) | |
| 810 | 810 | PORT_DIPUNUSED( 0x02, IP_ACTIVE_LOW ) |
| 811 | 811 | PORT_DIPUNUSED( 0x04, IP_ACTIVE_LOW ) |
| 812 | 812 | PORT_DIPUNUSED( 0x08, IP_ACTIVE_LOW ) |
| r3232 | r3233 | |
|---|---|---|
| 561 | 561 | |
| 562 | 562 | static UINT8 mahmajn_io_r(running_machine *machine, int port) |
| 563 | 563 | { |
| 564 | static const char *keynames[] = { "MJ0", "MJ1", "MJ2", "MJ3", "MJ4", "MJ5", "P1", "P2" }; | |
| 564 | static const char *const keynames[] = { "MJ0", "MJ1", "MJ2", "MJ3", "MJ4", "MJ5", "P1", "P2" }; | |
| 565 | 565 | |
| 566 | 566 | switch(port) |
| 567 | 567 | { |
| r3232 | r3233 | |
| 619 | 619 | |
| 620 | 620 | static WRITE16_HANDLER( hotrod3_ctrl_w ) |
| 621 | 621 | { |
| 622 | static const char *portnames[] = { "PEDAL1", "PEDAL2", "PEDAL3", "PEDAL4" }; | |
| 622 | static const char *const portnames[] = { "PEDAL1", "PEDAL2", "PEDAL3", "PEDAL4" }; | |
| 623 | 623 | |
| 624 | 624 | if(ACCESSING_BITS_0_7) |
| 625 | 625 | { |
| r3232 | r3233 | |
|---|---|---|
| 233 | 233 | ROM_LOAD( "mustache.h18", 0x0000, 0x8000, CRC(123bd9b8) SHA1(33a7cba5c3a54b0b1a15dd1e24d298b6f7274321) ) |
| 234 | 234 | ROM_LOAD( "mustache.h16", 0x8000, 0x4000, CRC(62552beb) SHA1(ee10991d7de0596608fa1db48805781cbfbbdb9f) ) |
| 235 | 235 | |
| 236 | ROM_REGION( 0x10000, " | |
| 236 | ROM_REGION( 0x10000, "t5182", 0 ) /* Toshiba T5182 module */ | |
| 237 | 237 | ROM_LOAD( "t5182.rom", 0x0000, 0x2000, CRC(d354c8fc) SHA1(a1c9e1ac293f107f69cc5788cf6abc3db1646e33) ) |
| 238 | 238 | ROM_LOAD( "mustache.e5", 0x8000, 0x8000, CRC(efbb1943) SHA1(3320e9eaeb776d09ed63f7dedc79e720674e6718) ) |
| 239 | 239 |
| r3232 | r3233 | |
|---|---|---|
| 1922 | 1922 | ROM_REGION( 0x10000, "sound", 0 ) /* sound CPU */ |
| 1923 | 1923 | ROM_LOAD( "10284", 0x00000, 0x8000, CRC(8ff09116) SHA1(8b99b6d2499897cfbd037a7e7cf5bc53bce8a63a) ) |
| 1924 | 1924 | |
| 1925 | ROM_REGION( 0x2000, "fd1089a | |
| 1925 | ROM_REGION( 0x2000, "fd1089a | |
| 1926 | 1926 | ROM_LOAD( "317-0018.key", 0x0000, 0x2000, CRC(fee04be8) SHA1(c58d78299ef4cede517be823a8a8a90e46c6ba0d) ) |
| 1927 | 1927 | ROM_END |
| 1928 | 1928 | |
| r3232 | r3233 | |
| 2002 | 2002 | ROM_LOAD( "10435.1", 0x0000, 0x8000, CRC(ad89f6e3) SHA1(812a132142065b0fe13b5f0ac534b6d8830ba102) ) |
| 2003 | 2003 | ROM_LOAD( "10436.2", 0x8000, 0x8000, CRC(96c76613) SHA1(fe3e4e649fd2cb2453eec0c92015bd54b3b9a1b5) ) |
| 2004 | 2004 | |
| 2005 | ROM_REGION( 0x2000, "fd1089a | |
| 2005 | ROM_REGION( 0x2000, "fd1089a | |
| 2006 | 2006 | ROM_LOAD( "317-0021.key", 0x0000, 0x2000, BAD_DUMP CRC(85be8eac) SHA1(3857bf43b3b0ab60c04223e2393d99504a730d73) ) |
| 2007 | 2007 | ROM_END |
| 2008 | 2008 | |
| r3232 | r3233 | |
| 2056 | 2056 | ROM_LOAD( "10707", 0x08000, 0x8000, CRC(800c1d82) SHA1(aac4123bd35f87da09264649f4cf8326b2ba3cb8) ) |
| 2057 | 2057 | ROM_LOAD( "10708", 0x10000, 0x8000, CRC(5921ef52) SHA1(eff9978361692e6e60a9c6caf5740dd6182cfe4a) ) |
| 2058 | 2058 | |
| 2059 | ROM_REGION( 0x2000, "fd1089b | |
| 2059 | ROM_REGION( 0x2000, "fd1089b | |
| 2060 | 2060 | ROM_LOAD( "317-0037.key", 0x0000, 0x2000, CRC(49e882e5) SHA1(29d87af8fc775b22a9a546c112f8f5e7f700ac1a) ) |
| 2061 | 2061 | ROM_END |
| 2062 | 2062 | |
| r3232 | r3233 | |
| 2110 | 2110 | ROM_LOAD( "10707", 0x08000, 0x8000, CRC(800c1d82) SHA1(aac4123bd35f87da09264649f4cf8326b2ba3cb8) ) |
| 2111 | 2111 | ROM_LOAD( "10708", 0x10000, 0x8000, CRC(5921ef52) SHA1(eff9978361692e6e60a9c6caf5740dd6182cfe4a) ) |
| 2112 | 2112 | |
| 2113 | ROM_REGION( 0x2000, "fd1089a | |
| 2113 | ROM_REGION( 0x2000, "fd1089a | |
| 2114 | 2114 | ROM_LOAD( "317-0033.key", 0x0000, 0x2000, CRC(49e882e5) SHA1(29d87af8fc775b22a9a546c112f8f5e7f700ac1a) ) |
| 2115 | 2115 | ROM_END |
| 2116 | 2116 | |
| r3232 | r3233 | |
| 2161 | 2161 | ROM_LOAD( "10707", 0x08000, 0x8000, CRC(800c1d82) SHA1(aac4123bd35f87da09264649f4cf8326b2ba3cb8) ) |
| 2162 | 2162 | ROM_LOAD( "10708", 0x10000, 0x8000, CRC(5921ef52) SHA1(eff9978361692e6e60a9c6caf5740dd6182cfe4a) ) |
| 2163 | 2163 | |
| 2164 | ROM_REGION( 0x2000, "fd1089a | |
| 2164 | ROM_REGION( 0x2000, "fd1089a | |
| 2165 | 2165 | ROM_LOAD( "317-0033.key", 0x0000, 0x2000, CRC(49e882e5) SHA1(29d87af8fc775b22a9a546c112f8f5e7f700ac1a) ) |
| 2166 | 2166 | ROM_END |
| 2167 | 2167 | |
| r3232 | r3233 | |
| 2642 | 2642 | ROM_REGION( 0x10000, "sound", 0 ) /* sound CPU */ |
| 2643 | 2643 | ROM_LOAD( "epr10759.12", 0x0000, 0x8000, CRC(d7f9649f) SHA1(ce4abe7dd7e33da048569d7817063345fab75ea7) ) |
| 2644 | 2644 | |
| 2645 | ROM_REGION( 0x2000, "fd1089b | |
| 2645 | ROM_REGION( 0x2000, "fd1089b | |
| 2646 | 2646 | ROM_LOAD( "317-0027.key", 0x0000, 0x2000, BAD_DUMP CRC(9a5307b2) SHA1(2fcc576ed95b96ff6ea71252c3fab33b8b3fc1f5) ) |
| 2647 | 2647 | ROM_END |
| 2648 | 2648 | |
| r3232 | r3233 | |
| 2845 | 2845 | ROM_LOAD( "epr12230.4", 0x10000, 0x8000, CRC(d0f61fd4) SHA1(e6f29459d7395122f26957f56e38926aebd9004c) ) |
| 2846 | 2846 | ROM_LOAD( "epr12231.5", 0x18000, 0x8000, CRC(780bdc57) SHA1(8c859043bba389292604385b88c743728180f9a9) ) |
| 2847 | 2847 | |
| 2848 | ROM_REGION( 0x2000, "fd1089b | |
| 2848 | ROM_REGION( 0x2000, "fd1089b | |
| 2849 | 2849 | ROM_LOAD( "317-5021.key", 0x0000, 0x2000, BAD_DUMP CRC(4a3422e4) SHA1(69a32a6987ff2481f6d6cbbe399269a2461b8bad) ) |
| 2850 | 2850 | ROM_END |
| 2851 | 2851 | |
| r3232 | r3233 | |
| 3014 | 3014 | ROM_REGION( 0x08000, "n7751data", 0 ) /* 7751 sound data */ |
| 3015 | 3015 | ROM_LOAD( "epr10547.1", 0x0000, 0x8000, CRC(d24ffc4b) SHA1(3b250e1f026664f7a37f65d1c1a07381e88f11e8) ) |
| 3016 | 3016 | |
| 3017 | ROM_REGION( 0x2000, "fd1089b | |
| 3017 | ROM_REGION( 0x2000, "fd1089b | |
| 3018 | 3018 | ROM_LOAD( "317-0024.key", 0x0000, 0x2000, BAD_DUMP CRC(ee42ec18) SHA1(cb65dd681f38ce20440ddcb01a935c2c8eecc77f) ) |
| 3019 | 3019 | ROM_END |
| 3020 | 3020 | |
| r3232 | r3233 | |
| 3101 | 3101 | ROM_REGION( 0x10000, "sound", 0 ) /* sound CPU */ |
| 3102 | 3102 | ROM_LOAD( "epr12089.12", 0x0000, 0x8000, CRC(8321eb0b) SHA1(61cf95833c0aa38e35fc18db39d4ec74e4aaf01e) ) |
| 3103 | 3103 | |
| 3104 | ROM_REGION( 0x2000, "fd1089a | |
| 3104 | ROM_REGION( 0x2000, "fd1089a | |
| 3105 | 3105 | ROM_LOAD( "317-wb35.key", 0x0000, 0x2000, BAD_DUMP CRC(8a2e0575) SHA1(e43a2c8ca102ec38871067685a860da53d748765) ) |
| 3106 | 3106 | ROM_END |
| 3107 | 3107 |
| r3232 | r3233 | |
|---|---|---|
| 80 | 80 | ****************************************************************************/ |
| 81 | 81 | |
| 82 | 82 | #include "driver.h" |
| 83 | #include "deprecat.h" | |
| 84 | 83 | #include "neogeo.h" |
| 85 | 84 | #include "machine/pd4990a.h" |
| 86 | 85 | #include "cpu/z80/z80.h" |
| r3232 | r3233 | |
| 625 | 624 | } |
| 626 | 625 | |
| 627 | 626 | |
| 628 | void neogeo_set_main_cpu_bank_address(UINT32 bank_address) | |
| 627 | void neogeo_set_main_cpu_bank_address(running_machine *machine, UINT32 bank_address) | |
| 629 | 628 | { |
| 630 | 629 | if (LOG_MAIN_CPU_BANKING) logerror("MAIN CPU PC %06x: neogeo_set_main_cpu_bank_address %06x\n", safe_activecpu_get_pc(), bank_address); |
| 631 | 630 | |
| 632 | 631 | main_cpu_bank_address = bank_address; |
| 633 | 632 | |
| 634 | _set_main_cpu_bank_address( | |
| 633 | _set_main_cpu_bank_address(machine); | |
| 635 | 634 | } |
| 636 | 635 | |
| 637 | 636 | |
| r3232 | r3233 | |
| 652 | 651 | bank_address = 0x100000; |
| 653 | 652 | } |
| 654 | 653 | |
| 655 | neogeo_set_main_cpu_bank_address(bank_address); | |
| 654 | neogeo_set_main_cpu_bank_address(machine, bank_address); | |
| 656 | 655 | } |
| 657 | 656 | } |
| 658 | 657 | |
| r3232 | r3233 | |
| 665 | 664 | |
| 666 | 665 | /* set initial main CPU bank */ |
| 667 | 666 | if (memory_region_length(machine, "main") > 0x100000) |
| 668 | neogeo_set_main_cpu_bank_address(0x100000); | |
| 667 | neogeo_set_main_cpu_bank_address(machine, 0x100000); | |
| 669 | 668 | else |
| 670 | neogeo_set_main_cpu_bank_address(0x000000); | |
| 669 | neogeo_set_main_cpu_bank_address(machine, 0x000000); | |
| 671 | 670 | } |
| 672 | 671 | |
| 673 | 672 |
| r3232 | r3233 | |
|---|---|---|
| 939 | 939 | return sync_frame; |
| 940 | 940 | } |
| 941 | 941 | |
| 942 | static int last_prot_op | |
| 942 | static int last_prot_op | |
| 943 | 943 | |
| 944 | 944 | /* |
| 945 | 945 | Run and Gun 2, Rushing Heroes, Winning Spike, and Vs. Net Soccer contain a XILINX FPGA that serves as security. |
| r3232 | r3233 | |
|---|---|---|
| 158 | 158 | |
| 159 | 159 | case 0x1000/2: /* Input ports and DIP switches */ |
| 160 | 160 | { |
| 161 | static const char *sysports[] = { "SERVICE", "COINAGE", "DSW", "UNKNOWN" }; | |
| 161 | static const char *const sysports[] = { "SERVICE", "COINAGE", "DSW", "UNKNOWN" }; | |
| 162 | 162 | return input_port_read(machine, sysports[offset & 3]); |
| 163 | 163 | } |
| 164 | 164 | |
| r3232 | r3233 | |
| 167 | 167 | |
| 168 | 168 | case 0x3020/2: /* ADC0804 data output */ |
| 169 | 169 | { |
| 170 | static const char *adcports[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 170 | static const char *const adcports[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 171 | 171 | return input_port_read_safe(machine, adcports[adc_select], 0); |
| 172 | 172 | } |
| 173 | 173 | } |
| r3232 | r3233 | |
| 209 | 209 | |
| 210 | 210 | case 0x0010/2: /* Input ports and DIP switches */ |
| 211 | 211 | { |
| 212 | static const char *sysports[] = { "SERVICE", "UNKNOWN", "COINAGE", "DSW" }; | |
| 212 | static const char *const sysports[] = { "SERVICE", "UNKNOWN", "COINAGE", "DSW" }; | |
| 213 | 213 | return input_port_read(machine, sysports[offset & 3]); |
| 214 | 214 | } |
| 215 | 215 | |
| r3232 | r3233 | |
| 219 | 219 | |
| 220 | 220 | case 0x0030/2: /* ADC0804 data output */ |
| 221 | 221 | { |
| 222 | static const char *adcports[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 222 | static const char *const adcports[] = { "ADC0", "ADC1", "ADC2", "ADC3" }; | |
| 223 | 223 | return input_port_read_safe(machine, adcports[adc_select], 0); |
| 224 | 224 | } |
| 225 | 225 | } |
| r3232 | r3233 | |
| 1473 | 1473 | ROM_REGION( 0x2000, "proms", 0 ) /* zoom table */ |
| 1474 | 1474 | ROM_LOAD( "epr-6844.ic123", 0x0000, 0x2000, CRC(e3ec7bd6) SHA1(feec0fe664e16fac0fde61cf64b401b9b0575323) ) |
| 1475 | 1475 | |
| 1476 | ROM_REGION( 0x2000, "fd1089b | |
| 1476 | ROM_REGION( 0x2000, "fd1089b | |
| 1477 | 1477 | ROM_LOAD( "317-0013a.key", 0x0000, 0x2000, CRC(295e6737) SHA1(2eff36f1f24db1154cf970d4c9fd481ae4f9a57c) ) |
| 1478 | 1478 | ROM_END |
| 1479 | 1479 | |
| r3232 | r3233 | |
| 1553 | 1553 | ROM_REGION( 0x2000, "proms", 0 ) /* zoom table */ |
| 1554 | 1554 | ROM_LOAD( "epr-6844.ic123", 0x0000, 0x2000, CRC(e3ec7bd6) SHA1(feec0fe664e16fac0fde61cf64b401b9b0575323) ) |
| 1555 | 1555 | |
| 1556 | ROM_REGION( 0x2000, "fd1089b | |
| 1556 | ROM_REGION( 0x2000, "fd1089b | |
| 1557 | 1557 | ROM_LOAD( "317-0013a.key", 0x0000, 0x2000, CRC(295e6737) SHA1(2eff36f1f24db1154cf970d4c9fd481ae4f9a57c) ) |
| 1558 | 1558 | ROM_END |
| 1559 | 1559 |
| r3232 | r3233 | |
|---|---|---|
| 138 | 138 | AM_RANGE(0xf800, 0xffff) AM_WRITE(SMH_RAM) AM_BASE(&sprcros2_sharedram) //shared with slave cpu |
| 139 | 139 | ADDRESS_MAP_END |
| 140 | 140 | |
| 141 | static ADDRESS_MAP_START( | |
| 141 | static ADDRESS_MAP_START( i | |
| 142 | 142 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 143 | AM_RANGE(0x00, 0x00) AM_READ_PORT("P1") | |
| 144 | AM_RANGE(0x01, 0x01) AM_READ_PORT("P2") | |
| 145 | AM_RANGE(0x02, 0x02) AM_READ_PORT("EXTRA") | |
| 143 | AM_RANGE(0x00, 0x00) AM_READ_PORT("P1") AM_WRITE(sn76496_0_w) | |
| 144 | AM_RANGE(0x01, 0x01) AM_READ_PORT("P2") AM_WRITE(sn76496_1_w) | |
| 145 | AM_RANGE(0x02, 0x02) AM_READ_PORT("EXTRA") AM_WRITE(sn76496_2_w) | |
| 146 | 146 | AM_RANGE(0x04, 0x04) AM_READ_PORT("DSW1") |
| 147 | 147 | AM_RANGE(0x05, 0x05) AM_READ_PORT("DSW2") |
| 148 | ADDRESS_MAP_END | |
| 149 | ||
| 150 | static ADDRESS_MAP_START( sprcros2_m_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 151 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 152 | AM_RANGE(0x00, 0x00) AM_WRITE(sn76496_0_w) | |
| 153 | AM_RANGE(0x01, 0x01) AM_WRITE(sn76496_1_w) | |
| 154 | AM_RANGE(0x02, 0x02) AM_WRITE(sn76496_2_w) | |
| 155 | 148 | AM_RANGE(0x07, 0x07) AM_WRITE(sprcros2_m_port7_w) |
| 156 | 149 | ADDRESS_MAP_END |
| 157 | 150 | |
| r3232 | r3233 | |
| 173 | 166 | AM_RANGE(0xf800, 0xffff) AM_WRITE(sprcros2_sharedram_w) |
| 174 | 167 | ADDRESS_MAP_END |
| 175 | 168 | |
| 176 | static ADDRESS_MAP_START( | |
| 169 | static ADDRESS_MAP_START( audi | |
| 177 | 170 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 178 | 171 | AM_RANGE(0x00, 0x00) AM_WRITE(sprcros2_bgscrollx_w) |
| 179 | 172 | AM_RANGE(0x01, 0x01) AM_WRITE(sprcros2_bgscrolly_w) |
| r3232 | r3233 | |
| 303 | 296 | /* basic machine hardware */ |
| 304 | 297 | MDRV_CPU_ADD("main", Z80,10000000/2) |
| 305 | 298 | MDRV_CPU_PROGRAM_MAP(sprcros2_m_readmem,sprcros2_m_writemem) |
| 306 | MDRV_CPU_IO_MAP( | |
| 299 | MDRV_CPU_IO_MAP(i | |
| 307 | 300 | MDRV_CPU_VBLANK_INT_HACK(sprcros2_m_interrupt,2) //1 nmi + 1 irq |
| 308 | 301 | |
| 309 | 302 | MDRV_CPU_ADD("audio", Z80,10000000/2) |
| 310 | 303 | MDRV_CPU_PROGRAM_MAP(sprcros2_s_readmem,sprcros2_s_writemem) |
| 311 | MDRV_CPU_IO_MAP( | |
| 304 | MDRV_CPU_IO_MAP(audi | |
| 312 | 305 | MDRV_CPU_VBLANK_INT_HACK(sprcros2_s_interrupt,2) //2 nmis |
| 313 | 306 | |
| 314 | 307 | MDRV_MACHINE_START(sprcros2) |
| r3232 | r3233 | |
|---|---|---|
| 167 | 167 | if (offset == 0) |
| 168 | 168 | { |
| 169 | 169 | int i,dir[4]; |
| 170 | static const char *tracknames[] = { "TRACK0_Y", "TRACK0_X", "TRACK1_Y", "TRACK1_X" }; | |
| 170 | static const char *const tracknames[] = { "TRACK0_Y", "TRACK0_X", "TRACK1_Y", "TRACK1_X" }; | |
| 171 | 171 | |
| 172 | 172 | for (i = 0; i < 4; i++) |
| 173 | 173 | { |
| r3232 | r3233 | |
|---|---|---|
| 355 | 355 | |
| 356 | 356 | static READ16_HANDLER( io_chip_r ) |
| 357 | 357 | { |
| 358 | static const char *portnames[] = { "P1", "P2", "PORTC", "PORTD", "SERVICE", "COINAGE", "DSW", "PORTH" }; | |
| 358 | static const char *const portnames[] = { "P1", "P2", "PORTC", "PORTD", "SERVICE", "COINAGE", "DSW", "PORTH" }; | |
| 359 | 359 | offset &= 0x1f/2; |
| 360 | 360 | |
| 361 | 361 | switch (offset) |
| r3232 | r3233 | |
|---|---|---|
| 322 | 322 | |
| 323 | 323 | static CUSTOM_INPUT( stooges_joystick_r ) |
| 324 | 324 | { |
| 325 | static const char *joyport[] = { "P1JOY", "P2JOY", "P3JOY", NULL }; | |
| 325 | static const char *const joyport[] = { "P1JOY", "P2JOY", "P3JOY", NULL }; | |
| 326 | 326 | return (joyport[joystick_select & 3] != NULL) ? input_port_read(field->port->machine, joyport[joystick_select & 3]) : 0xff; |
| 327 | 327 | } |
| 328 | 328 | |
| r3232 | r3233 | |
| 679 | 679 | { |
| 680 | 680 | bitmap_t *dummy; |
| 681 | 681 | |
| 682 | laserdisc_vsync(laserdisc); | |
| 683 | ||
| 684 | 682 | /* set the "disc ready" bit, which basically indicates whether or not we have a proper video frame */ |
| 685 | 683 | if (laserdisc_get_video(laserdisc, &dummy) == 0) |
| 686 | 684 | laserdisc_status &= ~0x20; |
| r3232 | r3233 | |
| 1889 | 1887 | MDRV_IMPORT_FROM(gottlieb_core) |
| 1890 | 1888 | MDRV_IMPORT_FROM(gottlieb_soundrev2) |
| 1891 | 1889 | |
| 1892 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210) | |
| 1890 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210, "main", "ldsound") | |
| 1893 | 1891 | MDRV_LASERDISC_AUDIO(laserdisc_audio_process) |
| 1894 | 1892 | MDRV_LASERDISC_OVERLAY(gottlieb, GOTTLIEB_VIDEO_HCOUNT, GOTTLIEB_VIDEO_VCOUNT, BITMAP_FORMAT_INDEXED16) |
| 1895 | 1893 | MDRV_LASERDISC_OVERLAY_CLIP(0, GOTTLIEB_VIDEO_HBLANK-1, 0, GOTTLIEB_VIDEO_VBLANK-8) |
| r3232 | r3233 | |
| 1897 | 1895 | MDRV_SCREEN_REMOVE("main") |
| 1898 | 1896 | MDRV_LASERDISC_SCREEN_ADD_NTSC("main", BITMAP_FORMAT_INDEXED16) |
| 1899 | 1897 | |
| 1900 | MDRV_SOUND_ADD("l | |
| 1898 | MDRV_SOUND_ADD("l | |
| 1901 | 1899 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 1902 | 1900 | MDRV_SOUND_ROUTE(0, "mono", 1.0) |
| 1903 | 1901 | /* right channel is processed as data */ |
| r3232 | r3233 | |
|---|---|---|
| 405 | 405 | /* The time the IRQ line stays high is set just long enough to happen after the NMI - hacky? */ |
| 406 | 406 | cpunum_set_input_line(machine, 0, 0, ASSERT_LINE); |
| 407 | 407 | timer_set(ATTOTIME_IN_USEC(100), NULL, 0, irq_stop); |
| 408 | ||
| 409 | laserdisc_vsync(laserdisc); | |
| 410 | 408 | } |
| 411 | 409 | |
| 412 | 410 | static const gfx_layout gpworld_tile_layout = |
| r3232 | r3233 | |
| 435 | 433 | |
| 436 | 434 | MDRV_MACHINE_START(gpworld) |
| 437 | 435 | |
| 438 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 436 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 439 | 437 | MDRV_LASERDISC_OVERLAY(gpworld, 512, 256, BITMAP_FORMAT_INDEXED16) |
| 440 | 438 | |
| 441 | 439 | /* video hardware */ |
| r3232 | r3233 | |
| 447 | 445 | /* sound hardware */ |
| 448 | 446 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 449 | 447 | |
| 450 | MDRV_SOUND_ADD("l | |
| 448 | MDRV_SOUND_ADD("l | |
| 451 | 449 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 452 | 450 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 453 | 451 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 255 | 255 | static READ8_HANDLER( mrokumei_keyboard_r ) |
| 256 | 256 | { |
| 257 | 257 | int res = 0x3f,i; |
| 258 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 258 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4" }; | |
| 259 | 259 | |
| 260 | 260 | /* offset 0 is player 1, offset 1 player 2 (not supported) */ |
| 261 | 261 | if (offset == 0) |
| r3232 | r3233 | |
| 468 | 468 | |
| 469 | 469 | static READ8_HANDLER( pteacher_keyboard_r ) |
| 470 | 470 | { |
| 471 | static const char *keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5" }; | |
| 471 | static const char *const keynames[] = { "KEY0", "KEY1", "KEY2", "KEY3", "KEY4", "KEY5" }; | |
| 472 | 472 | int dips = input_port_read(machine, "DSW"); |
| 473 | 473 | |
| 474 | 474 | // logerror("%04x: keyboard_r with port A = %02x\n",activecpu_get_pc(),upd7807_porta); |
| r3232 | r3233 | |
|---|---|---|
| 162 | 162 | return mxtc_config_reg[reg]; |
| 163 | 163 | } |
| 164 | 164 | |
| 165 | static void mxtc_config_w(int function, int reg, UINT8 data) | |
| 165 | static void mxtc_config_w(running_machine *machine, int function, int reg, UINT8 data) | |
| 166 | 166 | { |
| 167 | 167 | // mame_printf_debug("MXTC: write %d, %02X, %02X at %08X\n", function, reg, data, activecpu_get_pc()); |
| 168 | 168 | |
| r3232 | r3233 | |
| 176 | 176 | } |
| 177 | 177 | else // disable RAM access (reads go to BIOS ROM) |
| 178 | 178 | { |
| 179 | memory_set_bankptr(1, memory_region( | |
| 179 | memory_set_bankptr(1, memory_region(machine, "user1") + 0x30000); | |
| 180 | 180 | } |
| 181 | 181 | break; |
| 182 | 182 | } |
| r3232 | r3233 | |
| 221 | 221 | { |
| 222 | 222 | if (ACCESSING_BITS_24_31) |
| 223 | 223 | { |
| 224 | mxtc_config_w(function, reg + 3, (data >> 24) & 0xff); | |
| 224 | mxtc_config_w(Machine, function, reg + 3, (data >> 24) & 0xff); | |
| 225 | 225 | } |
| 226 | 226 | if (ACCESSING_BITS_16_23) |
| 227 | 227 | { |
| 228 | mxtc_config_w(function, reg + 2, (data >> 16) & 0xff); | |
| 228 | mxtc_config_w(Machine, function, reg + 2, (data >> 16) & 0xff); | |
| 229 | 229 | } |
| 230 | 230 | if (ACCESSING_BITS_8_15) |
| 231 | 231 | { |
| 232 | mxtc_config_w(function, reg + 1, (data >> 8) & 0xff); | |
| 232 | mxtc_config_w(Machine, function, reg + 1, (data >> 8) & 0xff); | |
| 233 | 233 | } |
| 234 | 234 | if (ACCESSING_BITS_0_7) |
| 235 | 235 | { |
| 236 | mxtc_config_w(function, reg + 0, (data >> 0) & 0xff); | |
| 236 | mxtc_config_w(Machine, function, reg + 0, (data >> 0) & 0xff); | |
| 237 | 237 | } |
| 238 | 238 | } |
| 239 | 239 |
| r3232 | r3233 | |
|---|---|---|
| 321 | 321 | PORT_BIT ( 0x80, IP_ACTIVE_LOW, IPT_UNUSED ) /* SW15 = nonJAMMA pin W = unused? */ |
| 322 | 322 | INPUT_PORTS_END |
| 323 | 323 | |
| 324 | static INTERRUPT_GEN( vblank_callback_astron ) | |
| 325 | { | |
| 326 | laserdisc_vsync(laserdisc); | |
| 327 | } | |
| 328 | ||
| 329 | 324 | static GFXDECODE_START( segald ) |
| 330 | 325 | GFXDECODE_ENTRY( "gfx1", 0, gfx_8x8x1, 0, 1 ) /* CHARACTERS */ |
| 331 | 326 | /* SPRITES are apparently non-uniform in width - not straightforward to decode */ |
| r3232 | r3233 | |
| 345 | 340 | MDRV_CPU_ADD("main", Z80, SCHEMATIC_CLOCK/4) |
| 346 | 341 | MDRV_CPU_PROGRAM_MAP(mainmem,0) |
| 347 | 342 | MDRV_CPU_IO_MAP(mainport,0) |
| 348 | MDRV_CPU_VBLANK_INT("main", vblank_callback_astron) | |
| 349 | 343 | MDRV_CPU_PERIODIC_INT(nmi_line_pulse, 1000.0/59.94) |
| 350 | 344 | |
| 351 | 345 | MDRV_MACHINE_START(astron) |
| 352 | 346 | |
| 353 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 347 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 354 | 348 | MDRV_LASERDISC_OVERLAY(astron, 256, 256, BITMAP_FORMAT_INDEXED16) |
| 355 | 349 | |
| 356 | 350 | /* video hardware */ |
| r3232 | r3233 | |
| 362 | 356 | /* sound hardare */ |
| 363 | 357 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 364 | 358 | |
| 365 | MDRV_SOUND_ADD("l | |
| 359 | MDRV_SOUND_ADD("l | |
| 366 | 360 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 367 | 361 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 368 | 362 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
|---|---|---|
| 88 | 88 | static WRITE16_HANDLER( track_reset_w ) |
| 89 | 89 | { |
| 90 | 90 | int i; |
| 91 | static const char *track_names[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 91 | static const char *const track_names[] = { "IN0", "IN1", "IN2", "IN3" }; | |
| 92 | 92 | |
| 93 | 93 | for (i = 0; i < 4; i++) |
| 94 | 94 | last[i] = input_port_read(machine, track_names[i]); |
| r3232 | r3233 | |
|---|---|---|
| 336 | 336 | ADDRESS_MAP_END |
| 337 | 337 | |
| 338 | 338 | static ADDRESS_MAP_START( altair_io_map, ADDRESS_SPACE_IO, 8 ) |
| 339 | AM_RANGE(0x01, 0x01) AM_DEVREAD(CDP1852, "IC23", cdp1852_data_r) AM_DEVWRITE(CDP1852, "IC26", cdp1852_data_w) | |
| 340 | AM_RANGE(0x02, 0x02) AM_DEVREAD(CDP1852, "IC24", cdp1852_data_r) | |
| 339 | AM_RANGE(0x01, 0x01) AM_DEVREAD(CDP1852, "ic23", cdp1852_data_r) AM_DEVWRITE(CDP1852, "ic26", cdp1852_data_w) | |
| 340 | AM_RANGE(0x02, 0x02) AM_DEVREAD(CDP1852, "ic24", cdp1852_data_r) | |
| 341 | 341 | AM_RANGE(0x03, 0x03) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out3_w) |
| 342 | AM_RANGE(0x04, 0x04) AM_DEVREAD(CDP1852, " | |
| 342 | AM_RANGE(0x04, 0x04) AM_DEVREAD(CDP1852, "ic25", cdp1852_data_r) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out4_w) | |
| 343 | 343 | AM_RANGE(0x05, 0x05) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out5_w) |
| 344 | 344 | AM_RANGE(0x06, 0x06) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out6_w) |
| 345 | 345 | AM_RANGE(0x07, 0x07) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out7_w) |
| r3232 | r3233 | |
| 355 | 355 | ADDRESS_MAP_END |
| 356 | 356 | |
| 357 | 357 | static ADDRESS_MAP_START( draco_io_map, ADDRESS_SPACE_IO, 8 ) |
| 358 | AM_RANGE(0x01, 0x01) AM_DEVREAD(CDP1852, "IC29", cdp1852_data_r) AM_DEVWRITE(CDP1852, "IC32", cdp1852_data_w) | |
| 359 | AM_RANGE(0x02, 0x02) AM_DEVREAD(CDP1852, "IC30", cdp1852_data_r) | |
| 358 | AM_RANGE(0x01, 0x01) AM_DEVREAD(CDP1852, "ic29", cdp1852_data_r) AM_DEVWRITE(CDP1852, "ic32", cdp1852_data_w) | |
| 359 | AM_RANGE(0x02, 0x02) AM_DEVREAD(CDP1852, "ic30", cdp1852_data_r) | |
| 360 | 360 | AM_RANGE(0x03, 0x03) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out3_w) |
| 361 | AM_RANGE(0x04, 0x04) AM_DEVREAD(CDP1852, " | |
| 361 | AM_RANGE(0x04, 0x04) AM_DEVREAD(CDP1852, "ic31", cdp1852_data_r) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out4_w) | |
| 362 | 362 | AM_RANGE(0x05, 0x05) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out5_w) |
| 363 | 363 | AM_RANGE(0x06, 0x06) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out6_w) |
| 364 | 364 | AM_RANGE(0x07, 0x07) AM_DEVWRITE(CDP1869_VIDEO, CDP1869_TAG, cdp1869_out7_w) |
| r3232 | r3233 | |
| 651 | 651 | |
| 652 | 652 | // input/output hardware |
| 653 | 653 | |
| 654 | MDRV_DEVICE_ADD(" | |
| 654 | MDRV_DEVICE_ADD("ic23", CDP1852) | |
| 655 | 655 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in0_intf) |
| 656 | 656 | |
| 657 | MDRV_DEVICE_ADD(" | |
| 657 | MDRV_DEVICE_ADD("ic24", CDP1852) | |
| 658 | 658 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in1_intf) |
| 659 | 659 | |
| 660 | MDRV_DEVICE_ADD(" | |
| 660 | MDRV_DEVICE_ADD("ic25", CDP1852) | |
| 661 | 661 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in2_intf) |
| 662 | 662 | |
| 663 | MDRV_DEVICE_ADD(" | |
| 663 | MDRV_DEVICE_ADD("ic26", CDP1852) | |
| 664 | 664 | MDRV_DEVICE_CONFIG(altair_cdp1852_out1_intf) |
| 665 | 665 | |
| 666 | 666 | // video hardware |
| r3232 | r3233 | |
| 696 | 696 | |
| 697 | 697 | // input/output hardware |
| 698 | 698 | |
| 699 | MDRV_DEVICE_ADD(" | |
| 699 | MDRV_DEVICE_ADD("ic29", CDP1852) | |
| 700 | 700 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in0_intf) |
| 701 | 701 | |
| 702 | MDRV_DEVICE_ADD(" | |
| 702 | MDRV_DEVICE_ADD("ic30", CDP1852) | |
| 703 | 703 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in1_intf) |
| 704 | 704 | |
| 705 | MDRV_DEVICE_ADD(" | |
| 705 | MDRV_DEVICE_ADD("ic31", CDP1852) | |
| 706 | 706 | MDRV_DEVICE_CONFIG(cidelsa_cdp1852_in2_intf) |
| 707 | 707 | |
| 708 | MDRV_DEVICE_ADD(" | |
| 708 | MDRV_DEVICE_ADD("ic32", CDP1852) | |
| 709 | 709 | MDRV_DEVICE_CONFIG(draco_cdp1852_out1_intf) |
| 710 | 710 | |
| 711 | 711 | // video hardware |
| r3232 | r3233 | |
|---|---|---|
| 3439 | 3439 | ROM_LOAD( "epr10725.a9", 0x20000, 0x8000, CRC(6a50e08f) SHA1(d34b2ccadb8b07d5ad99cab5c5b5b79642c65574) ) |
| 3440 | 3440 | ROM_LOAD( "epr10726.a10", 0x30000, 0x8000, CRC(d50b7736) SHA1(b1f8e3b0cf2ffee5382098100cfabe21b383cd51) ) |
| 3441 | 3441 | |
| 3442 | ROM_REGION( 0x2000, "fd1089a | |
| 3442 | ROM_REGION( 0x2000, "fd1089a | |
| 3443 | 3443 | ROM_LOAD( "317-0033.key", 0x0000, 0x2000, CRC(49e882e5) SHA1(29d87af8fc775b22a9a546c112f8f5e7f700ac1a) ) |
| 3444 | 3444 | ROM_END |
| 3445 | 3445 | |
| r3232 | r3233 | |
| 3868 | 3868 | ROM_LOAD( "mpr13449.a11", 0x10000, 0x20000, CRC(d3d9aaf9) SHA1(0fb3a8cb11033accceb3a43a691fb424cf8b9619) ) |
| 3869 | 3869 | ROM_RELOAD( 0x30000, 0x20000 ) |
| 3870 | 3870 | |
| 3871 | ROM_REGION( 0x2000, "fd1089b | |
| 3871 | ROM_REGION( 0x2000, "fd1089b | |
| 3872 | 3872 | ROM_LOAD( "317-0168.key", 0x0000, 0x2000, CRC(bc2d1792) SHA1(e66d2582eb74ae35f27715fcc9df3e77aba67509) ) |
| 3873 | 3873 | ROM_END |
| 3874 | 3874 | |
| r3232 | r3233 | |
| 3936 | 3936 | ROM_LOAD( "mpr13449.a11", 0x10000, 0x20000, CRC(d3d9aaf9) SHA1(0fb3a8cb11033accceb3a43a691fb424cf8b9619) ) |
| 3937 | 3937 | ROM_RELOAD( 0x30000, 0x20000 ) |
| 3938 | 3938 | |
| 3939 | ROM_REGION( 0x2000, "fd1089a | |
| 3939 | ROM_REGION( 0x2000, "fd1089a | |
| 3940 | 3940 | ROM_LOAD( "317-0167.key", 0x0000, 0x2000, CRC(bc2d1792) SHA1(e66d2582eb74ae35f27715fcc9df3e77aba67509) ) |
| 3941 | 3941 | ROM_END |
| 3942 | 3942 | |
| r3232 | r3233 | |
| 4288 | 4288 | ROM_LOAD( "epr10475.a9", 0x20000, 0x08000, CRC(17d55e85) SHA1(0c414bafecbfaa82679cc155f15f5255c186358d) ) |
| 4289 | 4289 | ROM_LOAD( "epr10476.a10", 0x30000, 0x08000, CRC(a6be0956) SHA1(fc4d6e25e0b46679f94fddbb1850fb0b02f8d84b) ) |
| 4290 | 4290 | |
| 4291 | ROM_REGION( 0x2000, "fd1089a | |
| 4291 | ROM_REGION( 0x2000, "fd1089a | |
| 4292 | 4292 | ROM_LOAD( "317-0022.key", 0x0000, 0x2000, CRC(4eedc66d) SHA1(50588fa13bf25a2d1322579cdc9937450543c978) ) |
| 4293 | 4293 | ROM_END |
| 4294 | 4294 | |
| r3232 | r3233 | |
| 5242 | 5242 | ROM_REGION( 0x10000, "sound", 0 ) /* sound CPU */ |
| 5243 | 5243 | ROM_LOAD( "10775.a7", 0x0000, 0x8000, CRC(4cbd55a8) SHA1(8af2c52ab61338c8a9f1a74a05470dd3d5e0c42f) ) |
| 5244 | 5244 | |
| 5245 | ROM_REGION( 0x2000, "fd1089a | |
| 5245 | ROM_REGION( 0x2000, "fd1089a | |
| 5246 | 5246 | ROM_LOAD( "317-0028.key", 0x0000, 0x2000, BAD_DUMP CRC(9a5307b2) SHA1(2fcc576ed95b96ff6ea71252c3fab33b8b3fc1f5) ) |
| 5247 | 5247 | ROM_END |
| 5248 | 5248 | |
| r3232 | r3233 | |
| 5280 | 5280 | ROM_REGION( 0x10000, "sound", 0 ) /* sound CPU */ |
| 5281 | 5281 | ROM_LOAD( "10775.a7", 0x0000, 0x8000, CRC(4cbd55a8) SHA1(8af2c52ab61338c8a9f1a74a05470dd3d5e0c42f) ) |
| 5282 | 5282 | |
| 5283 | ROM_REGION( 0x2000, "fd1089a | |
| 5283 | ROM_REGION( 0x2000, "fd1089a | |
| 5284 | 5284 | ROM_LOAD( "317-0028.key", 0x0000, 0x2000, BAD_DUMP CRC(9a5307b2) SHA1(2fcc576ed95b96ff6ea71252c3fab33b8b3fc1f5) ) |
| 5285 | 5285 | ROM_END |
| 5286 | 5286 | |
| r3232 | r3233 | |
| 5552 | 5552 | ROM_LOAD( "epr12247.a10",0x30000, 0x8000, CRC(ef8a64c6) SHA1(525e0d968c72c6dd73df69b55b8626495d154649) ) |
| 5553 | 5553 | ROM_LOAD( "epr12248.a11",0x40000, 0x8000, CRC(d1eabdab) SHA1(f255a66e082353768e8d2bb574e883a4a45f7670) ) |
| 5554 | 5554 | |
| 5555 | ROM_REGION( 0x2000, "fd1089b | |
| 5555 | ROM_REGION( 0x2000, "fd1089b | |
| 5556 | 5556 | ROM_LOAD( "317-5021.key", 0x0000, 0x2000, BAD_DUMP CRC(4a3422e4) SHA1(69a32a6987ff2481f6d6cbbe399269a2461b8bad) ) |
| 5557 | 5557 | ROM_END |
| 5558 | 5558 |
| r3232 | r3233 | |
|---|---|---|
| 366 | 366 | static MACHINE_DRIVER_START( wwfwfest ) |
| 367 | 367 | |
| 368 | 368 | /* basic machine hardware */ |
| 369 | MDRV_CPU_ADD("main", M68000, 24 | |
| 369 | MDRV_CPU_ADD("main", M68000, XTAL_24MHz | |
| 370 | 370 | MDRV_CPU_PROGRAM_MAP(main_map,0) |
| 371 | 371 | MDRV_CPU_VBLANK_INT_HACK(wwfwfest_interrupt,2) |
| 372 | 372 | |
| 373 | MDRV_CPU_ADD("audio", Z80, 3579545) | |
| 373 | MDRV_CPU_ADD("audio", Z80, XTAL_3_579545MHz) | |
| 374 | 374 | MDRV_CPU_PROGRAM_MAP(sound_map,0) |
| 375 | 375 | |
| 376 | 376 | /* video hardware */ |
| r3232 | r3233 | |
| 393 | 393 | /* sound hardware */ |
| 394 | 394 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 395 | 395 | |
| 396 | MDRV_SOUND_ADD("ym", YM2151, 3579545) | |
| 396 | MDRV_SOUND_ADD("ym", YM2151, XTAL_3_579545MHz) | |
| 397 | 397 | MDRV_SOUND_CONFIG(ym2151_config) |
| 398 | 398 | MDRV_SOUND_ROUTE(0, "mono", 0.45) |
| 399 | 399 | MDRV_SOUND_ROUTE(1, "mono", 0.45) |
| 400 | 400 | |
| 401 | 401 | MDRV_SOUND_ADD("oki", OKIM6295, 1024188) |
| 402 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) / | |
| 402 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) /* Ve | |
| 403 | 403 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.90) |
| 404 | 404 | MACHINE_DRIVER_END |
| 405 | 405 | |
| r3232 | r3233 | |
| 442 | 442 | 31J8_IC14 TJ-003 31A11-2 M6295 31J10_IC73 |
| 443 | 443 | 31J9_IC15 61C16-35 61C16-35 Z80 YM2151 |
| 444 | 444 | |
| 445 | ||
| 446 | Clock Crystals: | |
| 447 | ||
| 448 | X1 - 28.000 MHz | |
| 449 | X2 - 3.579545 MHz (for Z80) | |
| 450 | X3 - 24.000 MHz (for 68000) | |
| 451 | X4 - 1.056 MHz (not used, initially intended for OKI6295?) | |
| 452 | ||
| 453 | ||
| 454 | The mask roms at IC1 and IC2 have the same pinouts as a MX27C4100 or M27C400 | |
| 455 | except pin 1 is not A17 but instead not used (not connected). | |
| 456 | ||
| 445 | 457 | *******************************************************************************/ |
| 458 | ||
| 446 | 459 | ROM_START( wwfwfest ) |
| 447 | 460 | ROM_REGION( 0x80000, "main", 0 ) /* Main CPU (68000) */ |
| 448 | ROM_LOAD16_BYTE( "31a13-2.19", 0x00001, 0x40000, CRC(7175bca7) SHA1(992b47a787b5bc2a5a381ec78b8dfaf7d42c614b) ) | |
| 449 | ROM_LOAD16_BYTE( "31a14-2.18", 0x00000, 0x40000, CRC(5d06bfd1) SHA1(39a93da662158aa5a9953dcabfcb47c2fc196dc7) ) | |
| 461 | ROM_LOAD16_BYTE( "31a13-2.ic19", 0x00001, 0x40000, CRC(7175bca7) SHA1(992b47a787b5bc2a5a381ec78b8dfaf7d42c614b) ) | |
| 462 | ROM_LOAD16_BYTE( "31a14-2.ic18", 0x00000, 0x40000, CRC(5d06bfd1) SHA1(39a93da662158aa5a9953dcabfcb47c2fc196dc7) ) | |
| 450 | 463 | |
| 451 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 452 | ROM_LOAD( "31a11-2.42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 464 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 465 | ROM_LOAD( "31a11-2.ic42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 453 | 466 | |
| 454 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 455 | ROM_LOAD( "wf_73a.rom", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 467 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 468 | ROM_LOAD( "31j10.ic73", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 456 | 469 | |
| 457 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 458 | ROM_LOAD( "31a12-0.33", 0x00000, 0x20000, CRC(d0803e20) SHA1(b68758e9a5522396f831a3972571f8aed54c64de) ) | |
| 470 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 471 | ROM_LOAD( "31a12-0.ic33", 0x00000, 0x20000, CRC(d0803e20) SHA1(b68758e9a5522396f831a3972571f8aed54c64de) ) | |
| 459 | 472 | |
| 460 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16) */ | |
| 461 | ROM_LOAD( "wf_09.rom", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 462 | ROM_LOAD( "wf_08.rom", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 463 | ROM_LOAD( "wf_11.rom", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 464 | ROM_LOAD( "wf_10.rom", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 465 | ROM_LOAD( "wf_12.rom", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 466 | ROM_LOAD( "wf_13.rom", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 467 | ROM_LOAD( "wf_15.rom", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 468 | ROM_LOAD( "wf_14.rom", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 473 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16), 27080 Mask ROM's */ | |
| 474 | ROM_LOAD( "31j3.ic9", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 475 | ROM_LOAD( "31j2.ic8", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 476 | ROM_LOAD( "31j5.ic11", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 477 | ROM_LOAD( "31j4.ic10", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 478 | ROM_LOAD( "31j6.ic12", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 479 | ROM_LOAD( "31j7.ic13", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 480 | ROM_LOAD( "31j9.ic15", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 481 | ROM_LOAD( "31j8.ic14", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 469 | 482 | |
| 470 | 483 | ROM_REGION( 0x80000, "gfx3", ROMREGION_DISPOSE ) /* BG0 / BG1 Tiles (16x16) */ |
| 471 | ROM_LOAD( "wf_01.rom", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 472 | ROM_LOAD( "wf_02.rom", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 484 | ROM_LOAD( "31j0.ic1", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 485 | ROM_LOAD( "31j1.ic2", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 473 | 486 | ROM_END |
| 474 | 487 | |
| 475 | 488 | ROM_START( wwfwfsta ) |
| r3232 | r3233 | |
| 477 | 490 | ROM_LOAD16_BYTE( "wf_18.rom", 0x00000, 0x40000, CRC(933ea1a0) SHA1(61da142cfa7abd3b77ab21979c061a078c0d0c63) ) |
| 478 | 491 | ROM_LOAD16_BYTE( "wf_19.rom", 0x00001, 0x40000, CRC(bd02e3c4) SHA1(7ae63e48caf9919ce7b63b4c5aa9474ba8c336da) ) |
| 479 | 492 | |
| 480 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 481 | ROM_LOAD( "31a11-2.42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 493 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 494 | ROM_LOAD( "31a11-2.ic42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 482 | 495 | |
| 483 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 484 | ROM_LOAD( "wf_73a.rom", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 496 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 497 | ROM_LOAD( "31j10.ic73", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 485 | 498 | |
| 486 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 499 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 487 | 500 | ROM_LOAD( "wf_33.rom", 0x00000, 0x20000, CRC(06f22615) SHA1(2e9418e372da85ea597977d912d8b35753655f4e) ) |
| 488 | 501 | |
| 489 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16) */ | |
| 490 | ROM_LOAD( "wf_09.rom", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 491 | ROM_LOAD( "wf_08.rom", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 492 | ROM_LOAD( "wf_11.rom", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 493 | ROM_LOAD( "wf_10.rom", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 494 | ROM_LOAD( "wf_12.rom", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 495 | ROM_LOAD( "wf_13.rom", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 496 | ROM_LOAD( "wf_15.rom", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 497 | ROM_LOAD( "wf_14.rom", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 502 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16), 27080 Mask ROM's */ | |
| 503 | ROM_LOAD( "31j3.ic9", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 504 | ROM_LOAD( "31j2.ic8", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 505 | ROM_LOAD( "31j5.ic11", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 506 | ROM_LOAD( "31j4.ic10", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 507 | ROM_LOAD( "31j6.ic12", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 508 | ROM_LOAD( "31j7.ic13", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 509 | ROM_LOAD( "31j9.ic15", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 510 | ROM_LOAD( "31j8.ic14", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 498 | 511 | |
| 499 | 512 | ROM_REGION( 0x80000, "gfx3", ROMREGION_DISPOSE ) /* BG0 / BG1 Tiles (16x16) */ |
| 500 | ROM_LOAD( "wf_01.rom", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 501 | ROM_LOAD( "wf_02.rom", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 513 | ROM_LOAD( "31j0.ic1", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 514 | ROM_LOAD( "31j1.ic2", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 502 | 515 | ROM_END |
| 503 | 516 | |
| 504 | 517 | ROM_START( wwfwfstb ) |
| r3232 | r3233 | |
| 534 | 547 | |
| 535 | 548 | ROM_START( wwfwfstj ) |
| 536 | 549 | ROM_REGION( 0x80000, "main", 0 ) /* Main CPU (68000) */ |
| 537 | ROM_LOAD16_BYTE( "31j13-0.bin", 0x00001, 0x40000, CRC(2147780d) SHA1(9a7a5db06117f3780e084d3f0c7b642ff8a9db55) ) | |
| 538 | ROM_LOAD16_BYTE( "31j14-0.bin", 0x00000, 0x40000, CRC(d76fc747) SHA1(5f6819bc61756d1df4ac0776ac420a59c438cf8a) ) | |
| 550 | ROM_LOAD16_BYTE( "31j13-0.ic19", 0x00001, 0x40000, CRC(2147780d) SHA1(9a7a5db06117f3780e084d3f0c7b642ff8a9db55) ) | |
| 551 | ROM_LOAD16_BYTE( "31j14-0.ic18", 0x00000, 0x40000, CRC(d76fc747) SHA1(5f6819bc61756d1df4ac0776ac420a59c438cf8a) ) | |
| 539 | 552 | |
| 540 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 541 | ROM_LOAD( "31a11-2.42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 553 | ROM_REGION( 0x10000, "audio", 0 ) /* Sound CPU (Z80) */ | |
| 554 | ROM_LOAD( "31a11-2.ic42", 0x00000, 0x10000, CRC(5ddebfea) SHA1(30073963e965250d94f0dc3bd261a054850adf95) ) | |
| 542 | 555 | |
| 543 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 544 | ROM_LOAD( "wf_73a.rom", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 556 | ROM_REGION( 0x80000, "oki", 0 ) /* ADPCM samples */ | |
| 557 | ROM_LOAD( "31j10.ic73", 0x00000, 0x80000, CRC(6c522edb) SHA1(8005d59c94160638ba2ea7caf4e991fff03003d5) ) | |
| 545 | 558 | |
| 546 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 547 | ROM_LOAD( "31j12-0.bin", 0x00000, 0x20000, CRC(f4821fe0) SHA1(e5faa9860e9d4e75393b64ca85a8bfc4852fd4fd) ) | |
| 559 | ROM_REGION( 0x20000, "gfx1", ROMREGION_DISPOSE ) /* FG0 Tiles (8x8) */ | |
| 560 | ROM_LOAD( "31j12-0.ic33", 0x00000, 0x20000, CRC(f4821fe0) SHA1(e5faa9860e9d4e75393b64ca85a8bfc4852fd4fd) ) | |
| 548 | 561 | |
| 549 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16) */ | |
| 550 | ROM_LOAD( "wf_09.rom", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 551 | ROM_LOAD( "wf_08.rom", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 552 | ROM_LOAD( "wf_11.rom", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 553 | ROM_LOAD( "wf_10.rom", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 554 | ROM_LOAD( "wf_12.rom", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 555 | ROM_LOAD( "wf_13.rom", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 556 | ROM_LOAD( "wf_15.rom", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 557 | ROM_LOAD( "wf_14.rom", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 562 | ROM_REGION( 0x800000, "gfx2", ROMREGION_DISPOSE ) /* SPR Tiles (16x16), 27080 Mask ROM's */ | |
| 563 | ROM_LOAD( "31j3.ic9", 0x000000, 0x100000, CRC(e395cf1d) SHA1(241f98145e295993c9b6a44dc087a9b61fbc9a6f) ) /* Tiles 0 */ | |
| 564 | ROM_LOAD( "31j2.ic8", 0x100000, 0x100000, CRC(b5a97465) SHA1(08d82c29a5c02b83fdbd0bad649b74eb35ab7e54) ) /* Tiles 1 */ | |
| 565 | ROM_LOAD( "31j5.ic11", 0x200000, 0x100000, CRC(2ce545e8) SHA1(82173e58a8476a6fe9d2c990fce1f71af117a0ea) ) /* Tiles 0 */ | |
| 566 | ROM_LOAD( "31j4.ic10", 0x300000, 0x100000, CRC(00edb66a) SHA1(926606d1923936b6e75391b1ab03b369d9822d13) ) /* Tiles 1 */ | |
| 567 | ROM_LOAD( "31j6.ic12", 0x400000, 0x100000, CRC(79956cf8) SHA1(52207263620a6b6dde66d3f8749b772577899ea5) ) /* Tiles 0 */ | |
| 568 | ROM_LOAD( "31j7.ic13", 0x500000, 0x100000, CRC(74d774c3) SHA1(a723ac5d481bf91b12e17652fbb2d869c886dec0) ) /* Tiles 1 */ | |
| 569 | ROM_LOAD( "31j9.ic15", 0x600000, 0x100000, CRC(dd387289) SHA1(2cad42d4e7cd1a49346f844058ae18c38bc686a8) ) /* Tiles 0 */ | |
| 570 | ROM_LOAD( "31j8.ic14", 0x700000, 0x100000, CRC(44abe127) SHA1(c723e1dea117534e976d2d383e634faf073cd57b) ) /* Tiles 1 */ | |
| 558 | 571 | |
| 559 | 572 | ROM_REGION( 0x80000, "gfx3", ROMREGION_DISPOSE ) /* BG0 / BG1 Tiles (16x16) */ |
| 560 | ROM_LOAD( "wf_01.rom", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 561 | ROM_LOAD( "wf_02.rom", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 573 | ROM_LOAD( "31j0.ic1", 0x40000, 0x40000, CRC(8a12b450) SHA1(2e15c949efcda8bb6f11afe3ff07ba1dee9c771c) ) /* 0,1 */ | |
| 574 | ROM_LOAD( "31j1.ic2", 0x00000, 0x40000, CRC(82ed7155) SHA1(b338e1150ffe3277c11d4d6e801a7d3bd7c58492) ) /* 2,3 */ | |
| 562 | 575 | ROM_END |
| 563 | 576 | |
| 564 | GAME( 1991, wwfwfest, 0, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan", "WWF WrestleFest (US set 1)", 0 ) | |
| 565 | GAME( 1991, wwfwfsta, wwfwfest, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan (Tecmo license)", "WWF WrestleFest (US Tecmo)", 0 ) | |
| 566 | GAME( 1991, wwfwfstb, wwfwfest, wwfwfstb, wwfwfest, 0, ROT0, "bootleg", "WWF WrestleFest (US bootleg)", 0 ) | |
| 567 | GAME( 1991, wwfwfstj, wwfwfest, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan", "WWF WrestleFest (Japan)", 0 ) | |
| 577 | GAME( 1991, wwfwfest, 0, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan", "WWF WrestleFest (US set 1)", GAME_SUPPORTS_SAVE ) | |
| 578 | GAME( 1991, wwfwfsta, wwfwfest, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan (Tecmo license)", "WWF WrestleFest (US Tecmo)", GAME_SUPPORTS_SAVE ) | |
| 579 | GAME( 1991, wwfwfstb, wwfwfest, wwfwfstb, wwfwfest, 0, ROT0, "bootleg", "WWF WrestleFest (US bootleg)", GAME_SUPPORTS_SAVE ) | |
| 580 | GAME( 1991, wwfwfstj, wwfwfest, wwfwfest, wwfwfest, 0, ROT0, "Technos Japan", "WWF WrestleFest (Japan)", GAME_SUPPORTS_SAVE ) |
| r3232 | r3233 | |
|---|---|---|
| 203 | 203 | static int multigam3_mmc3_scanline_latch; |
| 204 | 204 | static int multigam3_mmc3_banks[2]; |
| 205 | 205 | static int multigam3_mmc3_4screen; |
| 206 | static int multigam3_mmc3_last_bank | |
| 206 | static int multigam3_mmc3_last_bank | |
| 207 | 207 | static UINT8* multigmc_mmc3_6000_ram; |
| 208 | 208 | |
| 209 | 209 | static void multigam3_mmc3_scanline_cb( int num, int scanline, int vblank, int blanked ) |
| r3232 | r3233 | |
|---|---|---|
| 1 | /* | |
| 1 | /******************************************************************************************* | |
| 2 | ||
| 2 | 3 | Playmark 'Super Derby' Hardware |
| 4 | ------------------------------- | |
| 3 | 5 | |
| 6 | Driver by David Haywood. | |
| 7 | Additional work by Roberto Fresca. | |
| 4 | 8 | |
| 5 | Super Derby - Playmark | |
| 6 | Roulette(?) - Playmark | |
| 7 | 9 | |
| 8 | | |
| 10 | | |
| 9 | 11 | |
| 10 | Roulette appears to have some kind of MCU device | |
| 11 | between the processor and the hopper | |
| 12 | Super Derby, 1996, Playmark. | |
| 13 | Scacco Matto / Space Win, 1996, Playmark. | |
| 14 | Croupier (Playmark Roulette), 1997, Playmark. | |
| 12 | 15 | |
| 13 | 16 | |
| 14 | * | |
| 17 | ******************************************************************************************** | |
| 15 | 18 | |
| 19 | NOTES: | |
| 20 | ----- | |
| 16 | 21 | |
| 17 | / | |
| 22 | Payout / hopper controls not connected | |
| 18 | 23 | |
| 19 | Super Derby | |
| 20 | Playmark '96 | |
| 24 | Roulette appears to have some kind of MCU device | |
| 25 | between the processor and the hopper | |
| 21 | 26 | |
| 22 | mc 68k 12mhz | |
| 23 | OKI m6295 | |
| 24 | 27 | |
| 25 | 2x GM 76c88al (8kx8 6264) near program ROMs | |
| 26 | 2x 6264 near gfx ROMs | |
| 27 | 16k nonvolatile SRAM (Dallas 1220Y) | |
| 28 | two FPGA chips - one labelled 'Playmark 010412' | |
| 29 | 4x hm3-65728bk-5 | |
| 30 | -- | |
| 31 | 21.bin 6F9F2F2B - near OKI (samples?) | |
| 28 | Working notes: (Relating to SDERBY) | |
| 32 | 29 | |
| 33 | 22.bin A319F1E0 - program code | |
| 34 | 23.bin 1D6E2321 / | |
| 30 | Stephh's notes : | |
| 35 | 31 | |
| 36 | 24.bin 93C917DF - gfx | |
| 37 | 25.bin 7BA485CD | |
| 38 | 26.bin BEABE4F7 | |
| 39 | 27.bin 672CE5DF | |
| 40 | 28.bin 39CA3B52 | |
| 41 | -- | |
| 42 | ||
| 43 | */ | |
| 44 | ||
| 45 | /* working notes: (Relating to SDERBY) | |
| 46 | ||
| 47 | Stephh's notes : | |
| 48 | ||
| 49 | 32 | - The game is playable, but : |
| 50 | 33 | |
| 51 | 34 | * it isn't possible to decrease the bet (but it might be an ingame "feature") |
| r3232 | r3233 | |
| 56 | 39 | input ports. |
| 57 | 40 | |
| 58 | 41 | |
| 59 | EC notes : | |
| 42 | EC notes : | |
| 60 | 43 | |
| 61 | Thinks... Those three reads at the beginning - hopper, ticket and note acceptor tests? | |
| 62 | The system certainly performs those before printing the error. | |
| 63 | (There are three different error graphics in the ROM, depending on what is wrong) | |
| 64 | Also, hardware freezes if we try to turn the dispenser or acceptor on, because it's waiting | |
| 65 | for the response back from NOP? | |
| 44 | Thinks... Those three reads at the beginning - hopper, ticket and note acceptor tests? | |
| 45 | The system certainly performs those before printing the error. | |
| 46 | (There are three different error graphics in the ROM, depending on what is wrong) | |
| 47 | Also, hardware freezes if we try to turn the dispenser or acceptor on, because it's waiting | |
| 48 | for the response back from NOP? | |
| 66 | 49 | |
| 67 | 50 | |
| 68 | ||
| 51 | ******************************************************************************************** | |
| 69 | 52 | |
| 53 | TO DO : | |
| 54 | ||
| 70 | 55 | - figure out the reads from 0x308002.w and 0x30800e.w (see sderby_input_r read handler) |
| 71 | 56 | (by default, demo sounds are OFF, so change this in the "test mode") |
| 72 | 57 | |
| 73 | */ | |
| 74 | 58 | |
| 59 | *******************************************************************************************/ | |
| 60 | ||
| 75 | 61 | #include "driver.h" |
| 76 | 62 | #include "sound/okim6295.h" |
| 63 | #include "sderby.lh" | |
| 64 | #include "spacewin.lh" | |
| 65 | #include "pmroulet.lh" | |
| 77 | 66 | |
| 78 | 67 | UINT16 *sderby_fg_videoram; |
| 79 | 68 | UINT16 *sderby_md_videoram; |
| r3232 | r3233 | |
| 88 | 77 | WRITE16_HANDLER( sderby_scroll_w ); |
| 89 | 78 | |
| 90 | 79 | |
| 80 | /*************************** | |
| 81 | * R/W Handlers * | |
| 82 | ***************************/ | |
| 83 | ||
| 91 | 84 | static READ16_HANDLER ( sderby_input_r ) |
| 92 | 85 | { |
| 93 | 86 | switch (offset) |
| r3232 | r3233 | |
| 107 | 100 | { |
| 108 | 101 | switch (offset) |
| 109 | 102 | { |
| 110 | case 0x00 >>1: | |
| 111 | return input_port_read(machine, "IN0"); | |
| 112 | case 0x02 >>1: | |
| 113 | return input_port_read(machine, "IN1"); | |
| 114 | case 0x04 >>1: | |
| 115 | return input_port_read(machine, "IN2"); | |
| 103 | case 0x00 >> 1: | |
| 104 | return input_port_read(machine, "IN0"); | |
| 105 | case 0x02 >> 1: | |
| 106 | return input_port_read(machine, "IN1"); | |
| 107 | case 0x04 >> 1: | |
| 108 | return input_port_read(machine, "IN2"); | |
| 116 | 109 | } |
| 110 | ||
| 117 | 111 | return 0xffff; |
| 112 | } | |
| 118 | 113 | |
| 114 | ||
| 115 | /*************************************************************** | |
| 116 | ||
| 117 | Roulette MCU communication. | |
| 118 | --------------------------- | |
| 119 | ||
| 120 | Defeating the 'always win' protection... | |
| 121 | ||
| 122 | Offset: 0x70800e - 0x70800f. | |
| 123 | ||
| 124 | Writes to the MCU are always the same values. | |
| 125 | At begining, the code writes 3 values: 0x53, 0x5a and 0x0d. | |
| 126 | Then, whith each placed bet the code normally writes 0x4e. | |
| 127 | After that, there are 2 reads expecting the MCU response. | |
| 128 | ||
| 129 | Most probably there is a shared RAM there for communication, | |
| 130 | but for now, I temporarily simulated the MCU response till | |
| 131 | we can get the MCU decapped. | |
| 132 | ||
| 133 | ||
| 134 | ****************************************************************/ | |
| 135 | ||
| 136 | static READ16_HANDLER( rprot_r ) | |
| 137 | { | |
| 138 | logerror("rprot_r : offset = %02x\n",activecpu_get_pc()); | |
| 139 | ||
| 140 | /* This is the only mask I found that allow a normal play. | |
| 141 | Using other values, the game hangs waiting for response, | |
| 142 | or simply throw a deliberated losing number. | |
| 143 | ||
| 144 | If someone more skilled in 68K code can help to trace it, | |
| 145 | searching for an accurated response, I'll appreciate. | |
| 146 | */ | |
| 147 | return mame_rand(machine) & 0x1f; | |
| 119 | 148 | } |
| 120 | 149 | |
| 121 | static ADDRESS_MAP_START( sderby_readmem, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 122 | AM_RANGE(0x000000, 0x07ffff) AM_READ(SMH_ROM) | |
| 123 | AM_RANGE(0x100000, 0x103fff) AM_READ(SMH_RAM) | |
| 124 | AM_RANGE(0x200000, 0x200fff) AM_READ(SMH_RAM) | |
| 150 | static WRITE16_HANDLER( rprot_w ) | |
| 151 | { | |
| 152 | logerror("rprot_w %02x\n", data); | |
| 153 | } | |
| 154 | ||
| 155 | ||
| 156 | /****************************** | |
| 157 | * Outputs / Lamps * | |
| 158 | ******************************/ | |
| 159 | ||
| 160 | static WRITE16_HANDLER( sderby_out_w ) | |
| 161 | { | |
| 162 | /* | |
| 163 | --------------------------- | |
| 164 | --- Super Derby Outputs --- | |
| 165 | --------------------------- | |
| 166 | ||
| 167 | 0x0000 - Normal State (lamps off). | |
| 168 | 0x0001 - Start lamp. | |
| 169 | 0x0002 - Bet lamp. | |
| 170 | ||
| 171 | 0x0100 - Ticket dispenser out. | |
| 172 | 0x0800 - Unknown (always activated). | |
| 173 | 0x1000 - Hopper out. | |
| 174 | 0x2000 - Coin counter. | |
| 175 | 0x4000 - Unknown. | |
| 176 | 0x8000 - End of Race lamp. | |
| 177 | ||
| 178 | ||
| 179 | - Lbits - | |
| 180 | 7654 3210 | |
| 181 | ========= | |
| 182 | ---- ---x Start lamp. | |
| 183 | ---- --x- Bet lamp. | |
| 184 | ||
| 185 | - Hbits - | |
| 186 | 7654 3210 | |
| 187 | ========= | |
| 188 | ---- ---x Ticket dispenser out. | |
| 189 | ---- x--- unknown (always activated). | |
| 190 | ---x ---- Hopper out. | |
| 191 | --x- ---- Coin counter. | |
| 192 | -x-- ---- unknown. | |
| 193 | x--- ---- End of Race lamp. | |
| 194 | ||
| 195 | */ | |
| 196 | output_set_lamp_value(1, (data & 1)); /* Lamp 1 - START */ | |
| 197 | output_set_lamp_value(2, (data >> 1) & 1); /* Lamp 2 - BET */ | |
| 198 | output_set_lamp_value(3, (data >> 15) & 1); /* Lamp 3 - END OF RACE */ | |
| 199 | ||
| 200 | coin_counter_w(0, data & 0x2000); | |
| 201 | } | |
| 202 | ||
| 203 | ||
| 204 | static WRITE16_HANDLER( scmatto_out_w ) | |
| 205 | { | |
| 206 | /* | |
| 207 | ---------------------------------------- | |
| 208 | --- Scacco Matto / Space Win Outputs --- | |
| 209 | ---------------------------------------- | |
| 210 | ||
| 211 | 0x0000 - Normal State (lamps off). | |
| 212 | 0x0001 - Hold 1 lamp. | |
| 213 | 0x0002 - Hold 2 lamp. | |
| 214 | 0x0004 - Hold 3 lamp. | |
| 215 | 0x0008 - Hold 4 lamp. | |
| 216 | 0x0010 - Hold 5 lamp. | |
| 217 | 0x0020 - Start lamp. | |
| 218 | 0x0040 - Bet lamp. | |
| 219 | 0x1000 - Hopper out. | |
| 220 | 0x2000 - Coin counter. | |
| 221 | ||
| 222 | ||
| 223 | - Lbits - | |
| 224 | 7654 3210 | |
| 225 | ========= | |
| 226 | ---- ---x Hold1 lamp. | |
| 227 | ---- --x- Hold2 lamp. | |
| 228 | ---- -x-- Hold3 lamp. | |
| 229 | ---- x--- Hold4 lamp. | |
| 230 | ---x ---- Hold5 lamp. | |
| 231 | --x- ---- Start lamp. | |
| 232 | -x-- ---- Bet lamp. | |
| 233 | ||
| 234 | - Hbits - | |
| 235 | 7654 3210 | |
| 236 | ========= | |
| 237 | ---x ---- Hopper out. | |
| 238 | --x- ---- Coin counter. | |
| 239 | ||
| 240 | */ | |
| 241 | output_set_lamp_value(1, (data & 1)); /* Lamp 1 - HOLD 1 */ | |
| 242 | output_set_lamp_value(2, (data >> 1) & 1); /* Lamp 2 - HOLD 2 */ | |
| 243 | output_set_lamp_value(3, (data >> 2) & 1); /* Lamp 3 - HOLD 3 */ | |
| 244 | output_set_lamp_value(4, (data >> 3) & 1); /* Lamp 4 - HOLD 4 */ | |
| 245 | output_set_lamp_value(5, (data >> 4) & 1); /* Lamp 5 - HOLD 5 */ | |
| 246 | output_set_lamp_value(6, (data >> 5) & 1); /* Lamp 6 - START */ | |
| 247 | output_set_lamp_value(7, (data >> 6) & 1); /* Lamp 7 - BET */ | |
| 248 | ||
| 249 | coin_counter_w(0, data & 0x2000); | |
| 250 | } | |
| 251 | ||
| 252 | ||
| 253 | static WRITE16_HANDLER( roulette_out_w ) | |
| 254 | { | |
| 255 | /* | |
| 256 | ----------------------------------- | |
| 257 | --- Croupier (Roulette) Outputs --- | |
| 258 | ----------------------------------- | |
| 259 | ||
| 260 | 0x708006 - 0x708007 | |
| 261 | =================== | |
| 262 | ||
| 263 | 0x0000 - Normal State (lamps off). | |
| 264 | 0x0001 - Start lamp. | |
| 265 | 0x0002 - Bet lamp. | |
| 266 | 0x0008 - Unknown (always activated). | |
| 267 | ||
| 268 | ||
| 269 | - Lbits - | |
| 270 | 7654 3210 | |
| 271 | ========= | |
| 272 | ---- ---x Start lamp. | |
| 273 | ---- --x- Bet lamp. | |
| 274 | ---- x--- Unknown (always activated). | |
| 275 | ||
| 276 | */ | |
| 277 | output_set_lamp_value(1, (data & 1)); /* Lamp 1 - START */ | |
| 278 | output_set_lamp_value(2, (data >> 1) & 1); /* Lamp 2 - BET */ | |
| 279 | } | |
| 280 | ||
| 281 | ||
| 282 | /*************************** | |
| 283 | * Memory Maps * | |
| 284 | ***************************/ | |
| 285 | ||
| 286 | static ADDRESS_MAP_START( sderby_map, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 287 | AM_RANGE(0x000000, 0x07ffff) AM_ROM | |
| 288 | AM_RANGE(0x100000, 0x100fff) AM_RAM AM_WRITE(sderby_videoram_w) AM_BASE(&sderby_videoram) /* bg */ | |
| 289 | AM_RANGE(0x101000, 0x101fff) AM_RAM AM_WRITE(sderby_md_videoram_w) AM_BASE(&sderby_md_videoram) /* mid */ | |
| 290 | AM_RANGE(0x102000, 0x103fff) AM_RAM AM_WRITE(sderby_fg_videoram_w) AM_BASE(&sderby_fg_videoram) /* fg */ | |
| 291 | AM_RANGE(0x104000, 0x10400b) AM_WRITE(sderby_scroll_w) | |
| 292 | AM_RANGE(0x10400c, 0x10400d) AM_WRITE(SMH_NOP) /* ??? - check code at 0x000456 (executed once at startup) */ | |
| 293 | AM_RANGE(0x10400e, 0x10400f) AM_WRITE(SMH_NOP) /* ??? - check code at 0x000524 (executed once at startup) */ | |
| 294 | AM_RANGE(0x200000, 0x200fff) AM_RAM AM_WRITE(SMH_RAM) AM_BASE(&spriteram16) AM_SIZE(&spriteram_size) | |
| 125 | 295 | AM_RANGE(0x308000, 0x30800d) AM_READ(sderby_input_r) |
| 126 | AM_RANGE(0x30800e, 0x30800f) AM_READ(okim6295_status_0_lsb_r) | |
| 127 | AM_RANGE(0xd00000, 0xd001ff) AM_READ(SMH_RAM) | |
| 128 | AM_RANGE(0xf00000, 0xffffff) AM_READ(SMH_RAM) | |
| 296 | AM_RANGE(0x308008, 0x308009) AM_WRITE(sderby_out_w) /* output port */ | |
| 297 | AM_RANGE(0x30800e, 0x30800f) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) | |
| 298 | AM_RANGE(0x380000, 0x380fff) AM_WRITE(paletteram16_RRRRRGGGGGBBBBBx_word_w) AM_BASE(&paletteram16) | |
| 299 | AM_RANGE(0x500000, 0x500001) AM_WRITE(SMH_NOP) /* unknown... write 0x01 in game, and 0x00 on reset */ | |
| 300 | AM_RANGE(0xd00000, 0xd007ff) AM_RAM AM_BASE(&generic_nvram16) AM_SIZE(&generic_nvram_size) | |
| 301 | AM_RANGE(0xffc000, 0xffffff) AM_RAM | |
| 129 | 302 | ADDRESS_MAP_END |
| 130 | 303 | |
| 131 | static ADDRESS_MAP_START( sderby_writemem, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 132 | AM_RANGE(0x000000, 0x07ffff) AM_WRITE(SMH_ROM) | |
| 133 | AM_RANGE(0x100000, 0x100fff) AM_WRITE(sderby_videoram_w) AM_BASE(&sderby_videoram) // bg | |
| 134 | AM_RANGE(0x101000, 0x101fff) AM_WRITE(sderby_md_videoram_w) AM_BASE(&sderby_md_videoram) // mid | |
| 135 | AM_RANGE(0x102000, 0x103fff) AM_WRITE(sderby_fg_videoram_w) AM_BASE(&sderby_fg_videoram) // fg | |
| 136 | AM_RANGE(0x104000, 0x10400b) AM_WRITE(sderby_scroll_w) | |
| 137 | AM_RANGE(0x10400c, 0x10400d) AM_WRITE(SMH_NOP) // ??? - check code at 0x000456 (executed once at startup) | |
| 138 | AM_RANGE(0x10400e, 0x10400f) AM_WRITE(SMH_NOP) // ??? - check code at 0x000524 (executed once at startup) | |
| 139 | AM_RANGE(0x200000, 0x200fff) AM_WRITE(SMH_RAM) AM_BASE(&spriteram16) AM_SIZE(&spriteram_size) | |
| 140 | AM_RANGE(0x308008, 0x308009) AM_WRITE(SMH_NOP) // ??? | |
| 141 | AM_RANGE(0x30800e, 0x30800f) AM_WRITE(okim6295_data_0_lsb_w) | |
| 304 | static ADDRESS_MAP_START( spacewin_map, ADDRESS_SPACE_PROGRAM, 16 ) | |
| 305 | AM_RANGE(0x000000, 0x03ffff) AM_ROM | |
| 306 | AM_RANGE(0x100000, 0x100fff) AM_RAM AM_WRITE(sderby_videoram_w) AM_BASE(&sderby_videoram) /* bg */ | |
| 307 | AM_RANGE(0x101000, 0x101fff) AM_RAM AM_WRITE(sderby_md_videoram_w) AM_BASE(&sderby_md_videoram) /* mid */ | |
| 308 | AM_RANGE(0x102000, 0x103fff) AM_RAM AM_WRITE(sderby_fg_videoram_w) AM_BASE(&sderby_fg_videoram) /* fg */ | |
| 309 | AM_RANGE(0x104000, 0x10400b) AM_WRITE(sderby_scroll_w) /* tilemaps offset control */ | |
| 310 | AM_RANGE(0x10400c, 0x10400d) AM_WRITE(SMH_NOP) /* seems another video register. constantly used */ | |
| 311 | AM_RANGE(0x10400e, 0x10400f) AM_WRITE(SMH_NOP) /* seems another video register. constantly used */ | |
| 312 | AM_RANGE(0x104010, 0x105fff) AM_WRITE(SMH_NOP) /* unknown */ | |
| 313 | AM_RANGE(0x300000, 0x300001) AM_WRITE(SMH_NOP) /* unknown... write 0x01 in game, and 0x00 on reset */ | |
| 314 | AM_RANGE(0x308000, 0x30800d) AM_READ(sderby_input_r) | |
| 315 | AM_RANGE(0x308008, 0x308009) AM_WRITE(scmatto_out_w) /* output port */ | |
| 316 | AM_RANGE(0x30800e, 0x30800f) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) | |
| 142 | 317 | AM_RANGE(0x380000, 0x380fff) AM_WRITE(paletteram16_RRRRRGGGGGBBBBBx_word_w) AM_BASE(&paletteram16) |
| 143 | AM_RANGE(0x500000, 0x500001) AM_WRITE(SMH_NOP) // ??? - check code at 0x00042e (executed once at startup) | |
| 144 | AM_RANGE(0xd00000, 0xd001ff) AM_WRITE(SMH_RAM) | |
| 145 | AM_RANGE(0xf00000, 0xffffff) AM_WRITE(SMH_RAM) | |
| 318 | AM_RANGE(0xd00000, 0xd001ff) AM_RAM | |
| 319 | AM_RANGE(0x800000, 0x800fff) AM_RAM AM_WRITE(SMH_RAM) AM_BASE(&spriteram16) AM_SIZE(&spriteram_size) | |
| 320 | AM_RANGE(0x801000, 0x80100d) AM_WRITE(SMH_NOP) /* unknown */ | |
| 321 | AM_RANGE(0x8f0000, 0x8f07ff) AM_RAM AM_BASE(&generic_nvram16) AM_SIZE(&generic_nvram_size) /* 16K Dallas DS1220Y-200 NVRAM */ | |
| 322 | AM_RANGE(0x8fc000, 0x8fffff) AM_RAM | |
| 146 | 323 | ADDRESS_MAP_END |
| 147 | 324 | |
| 148 | 325 | static ADDRESS_MAP_START( roulette_map, ADDRESS_SPACE_PROGRAM, 16 ) |
| 149 | 326 | AM_RANGE(0x000000, 0x03ffff) AM_ROM |
| 150 | 327 | AM_RANGE(0x440000, 0x440fff) AM_WRITE(SMH_RAM) AM_BASE(&spriteram16) AM_SIZE(&spriteram_size) |
| 151 | AM_RANGE(0x500000, 0x500fff) AM_RAM_WRITE(sderby_videoram_w) AM_BASE(&sderby_videoram) // bg | |
| 152 | AM_RANGE(0x501000, 0x501fff) AM_RAM_WRITE(sderby_md_videoram_w) AM_BASE(&sderby_md_videoram) // mid | |
| 153 | AM_RANGE(0x502000, 0x503fff) AM_RAM_WRITE(sderby_fg_videoram_w) AM_BASE(&sderby_fg_videoram) // fg | |
| 328 | AM_RANGE(0x500000, 0x500fff) AM_RAM_WRITE(sderby_videoram_w) AM_BASE(&sderby_videoram) /* bg */ | |
| 329 | AM_RANGE(0x501000, 0x501fff) AM_RAM_WRITE(sderby_md_videoram_w) AM_BASE(&sderby_md_videoram) /* mid */ | |
| 330 | AM_RANGE(0x502000, 0x503fff) AM_RAM_WRITE(sderby_fg_videoram_w) AM_BASE(&sderby_fg_videoram) /* fg */ | |
| 154 | 331 | AM_RANGE(0x504000, 0x50400b) AM_RAM_WRITE(sderby_scroll_w) |
| 155 | AM_RANGE(0x50400e, 0x50400f) AM_WRITE( | |
| 332 | AM_RANGE(0x50400e, 0x50400f) AM_WRITE( | |
| 156 | 333 | |
| 157 | AM_RANGE(0x708000, 0x70800d) AM_READ(roulette_input_r) AM_WRITE(SMH_NOP) // what are the writes? | |
| 158 | AM_RANGE(0x708008, 0x708009) AM_WRITE(SMH_NOP) // ??? | |
| 159 | AM_RANGE(0x70800e, 0x70800f) AM_READ(okim6295_status_0_lsb_r) AM_WRITE(okim6295_data_0_lsb_w) // ?? it only ever plays 1 sound | |
| 334 | AM_RANGE(0x708000, 0x708009) AM_READ(roulette_input_r) | |
| 335 | AM_RANGE(0x708006, 0x708007) AM_WRITE(roulette_out_w) | |
| 336 | AM_RANGE(0x70800a, 0x70800b) AM_READWRITE(okim6295_status_0_lsb_r, okim6295_data_0_lsb_w) | |
| 337 | AM_RANGE(0x70800c, 0x70800d) AM_WRITE(SMH_NOP) /* watchdog?? (0x0003) */ | |
| 338 | AM_RANGE(0x70800e, 0x70800f) AM_READWRITE(rprot_r, rprot_w) /* MCU communication */ | |
| 160 | 339 | AM_RANGE(0x780000, 0x780fff) AM_WRITE(paletteram16_RRRRRGGGGGBBBBBx_word_w) AM_BASE(&paletteram16) |
| 161 | 340 | |
| 162 | AM_RANGE(0xf00000, 0xffffff) AM_RAM | |
| 341 | AM_RANGE(0xff0000, 0xff07ff) AM_RAM AM_BASE(&generic_nvram16) AM_SIZE(&generic_nvram_size) | |
| 342 | AM_RANGE(0xffc000, 0xffffff) AM_RAM | |
| 163 | 343 | ADDRESS_MAP_END |
| 164 | 344 | |
| 165 | 345 | |
| 166 | 346 | |
| 347 | /*************************** | |
| 348 | * Input Ports * | |
| 349 | ***************************/ | |
| 350 | ||
| 167 | 351 | static INPUT_PORTS_START( sderby ) |
| 168 | 352 | PORT_START("IN0") /* 0x308000.w */ |
| 169 | 353 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) PORT_4WAY |
| r3232 | r3233 | |
| 184 | 368 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) |
| 185 | 369 | INPUT_PORTS_END |
| 186 | 370 | |
| 371 | static INPUT_PORTS_START( spacewin ) | |
| 372 | PORT_START("IN0") /* 0x308000.w */ | |
| 373 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_BUTTON1 ) PORT_NAME("Hold 1") PORT_CODE(KEYCODE_Z) | |
| 374 | PORT_BIT( 0x0002, IP_ACTIVE_LOW, IPT_BUTTON2 ) PORT_NAME("Hold 2") PORT_CODE(KEYCODE_X) | |
| 375 | PORT_BIT( 0x0004, IP_ACTIVE_LOW, IPT_BUTTON3 ) PORT_NAME("Hold 3") PORT_CODE(KEYCODE_C) | |
| 376 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_BUTTON4 ) PORT_NAME("Hold 4") PORT_CODE(KEYCODE_V) | |
| 377 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON5 ) PORT_NAME("Hold 5") PORT_CODE(KEYCODE_B) | |
| 378 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_START ) PORT_NAME("Start") | |
| 379 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTTON6 ) PORT_NAME("Bet") PORT_CODE(KEYCODE_A) | |
| 380 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 381 | PORT_BIT( 0x0100, IP_ACTIVE_LOW, IPT_COIN1 ) | |
| 382 | PORT_BIT( 0x0200, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 383 | PORT_BIT( 0x0400, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 384 | PORT_BIT( 0x0800, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 385 | PORT_SERVICE_NO_TOGGLE(0x1000, IP_ACTIVE_LOW) | |
| 386 | PORT_BIT( 0x2000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 387 | PORT_BIT( 0x4000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 388 | PORT_BIT( 0x8000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 389 | INPUT_PORTS_END | |
| 390 | ||
| 187 | 391 | static INPUT_PORTS_START( pmroulet ) |
| 188 | 392 | PORT_START("IN0") |
| 189 | PORT_BIT( 0x000f, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 190 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_VBLANK ) // it must be toggled to boot anyway | |
| 191 | PORT_SERVICE_NO_TOGGLE(0x0020, IP_ACTIVE_LOW) // seems to be .. | |
| 192 | PORT_BIT( 0x00c0, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 193 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 194 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 393 | PORT_BIT( 0x000f, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 394 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_VBLANK ) /* it must be toggled to boot anyway */ | |
| 395 | PORT_SERVICE_NO_TOGGLE(0x0020, IP_ACTIVE_LOW) | |
| 396 | PORT_BIT( 0x00c0, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 397 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 398 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 195 | 399 | |
| 196 | 400 | PORT_START("IN1") |
| 197 | 401 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_COIN1 ) |
| 198 | PORT_BIT( 0x000e, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 199 | PORT_BIT( 0x00f0, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 200 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 201 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 402 | PORT_BIT( 0x000e, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 403 | PORT_BIT( 0x00f0, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 404 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 405 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 202 | 406 | |
| 203 | 407 | PORT_START("IN2") |
| 204 | 408 | PORT_BIT( 0x0001, IP_ACTIVE_LOW, IPT_JOYSTICK_UP ) |
| r3232 | r3233 | |
| 207 | 411 | PORT_BIT( 0x0008, IP_ACTIVE_LOW, IPT_JOYSTICK_RIGHT ) |
| 208 | 412 | PORT_BIT( 0x0010, IP_ACTIVE_LOW, IPT_BUTTON1 ) |
| 209 | 413 | PORT_BIT( 0x0020, IP_ACTIVE_LOW, IPT_BUTTON2 ) |
| 210 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_U | |
| 414 | PORT_BIT( 0x0040, IP_ACTIVE_LOW, IPT_BUTT | |
| 211 | 415 | PORT_BIT( 0x0080, IP_ACTIVE_LOW, IPT_START1 ) |
| 212 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 213 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) // ? | |
| 416 | PORT_BIT( 0x0f00, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 417 | PORT_BIT( 0xf000, IP_ACTIVE_LOW, IPT_UNKNOWN ) | |
| 214 | 418 | INPUT_PORTS_END |
| 215 | 419 | |
| 420 | ||
| 421 | /**************************** | |
| 422 | * Graphics Layouts * | |
| 423 | ****************************/ | |
| 424 | ||
| 216 | 425 | static const gfx_layout tiles8x8_layout = |
| 217 | 426 | { |
| 218 | 8,8, | |
| 427 | 8, 8, | |
| 219 | 428 | RGN_FRAC(1,5), |
| 220 | 429 | 5, |
| 221 | { RGN_FRAC(4,5),RGN_FRAC(3,5),RGN_FRAC(2,5),RGN_FRAC(1,5),RGN_FRAC(0,5) }, | |
| 430 | { RGN_FRAC(4,5), RGN_FRAC(3,5), RGN_FRAC(2,5), RGN_FRAC(1,5), RGN_FRAC(0,5) }, | |
| 222 | 431 | { 0, 1, 2, 3, 4, 5, 6, 7 }, |
| 223 | 432 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 }, |
| 224 | 433 | 8*8 |
| 225 | 434 | }; |
| 226 | 435 | |
| 227 | ||
| 228 | 436 | static const gfx_layout tiles16x16_layout = |
| 229 | 437 | { |
| 230 | 16,16, | |
| 438 | 16, 16, | |
| 231 | 439 | RGN_FRAC(1,5), |
| 232 | 440 | 5, |
| 233 | { RGN_FRAC(4,5),RGN_FRAC(3,5),RGN_FRAC(2,5),RGN_FRAC(1,5),RGN_FRAC(0,5) }, | |
| 441 | { RGN_FRAC(4,5), RGN_FRAC(3,5), RGN_FRAC(2,5), RGN_FRAC(1,5), RGN_FRAC(0,5) }, | |
| 234 | 442 | { 0, 1, 2, 3, 4, 5, 6, 7, |
| 235 | 128+0, 128+1,128+2,128+3,128+4,128+5,128+6,128+7 | |
| 443 | 128+0, 128+1, 128+2, 128+3, 128+4, 128+5, 128+6, 128+7 | |
| 236 | 444 | }, |
| 237 | 445 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8, |
| 238 | 64+0*8,64+1*8,64+2*8,64+3*8,64+4*8,64+5*8,64+6*8,64+7*8 | |
| 239 | ||
| 240 | }, | |
| 241 | ||
| 446 | 64+0*8,64+1*8,64+2*8,64+3*8,64+4*8,64+5*8,64+6*8,64+7*8 | |
| 447 | }, | |
| 242 | 448 | 256, |
| 243 | 449 | }; |
| 244 | 450 | |
| 245 | 451 | |
| 452 | /**************************** | |
| 453 | * Graphics Decode * | |
| 454 | ****************************/ | |
| 246 | 455 | |
| 247 | 456 | static GFXDECODE_START( sderby ) |
| 248 | 457 | GFXDECODE_ENTRY( "gfx1", 0, tiles8x8_layout, 0x000, 256 ) /* sprites */ |
| 249 | GFXDECODE_ENTRY( "gfx1", 0, tiles16x16_layout, 0x000, 256 ) /* sprites */ | |
| 250 | ||
| 458 | GFXDECODE_ENTRY( "gfx1", 0, tiles16x16_layout, 0x000, 256 ) /* sprites */ | |
| 251 | 459 | GFXDECODE_END |
| 252 | 460 | |
| 461 | ||
| 462 | /**************************** | |
| 463 | * Machine Drivers * | |
| 464 | ****************************/ | |
| 465 | ||
| 253 | 466 | static MACHINE_DRIVER_START( sderby ) |
| 254 | 467 | MDRV_CPU_ADD("main", M68000, 12000000) |
| 255 | MDRV_CPU_PROGRAM_MAP(sderby_ | |
| 468 | MDRV_CPU_PROGRAM_MAP(sderby_ | |
| 256 | 469 | MDRV_CPU_VBLANK_INT("main", irq2_line_hold) |
| 257 | 470 | |
| 471 | MDRV_NVRAM_HANDLER(generic_0fill) | |
| 472 | ||
| 473 | MDRV_SCREEN_ADD("main", RASTER) | |
| 474 | MDRV_SCREEN_REFRESH_RATE(60) | |
| 475 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) | |
| 476 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) | |
| 477 | MDRV_SCREEN_SIZE(64*8, 64*8) | |
| 478 | MDRV_SCREEN_VISIBLE_AREA(4*8, 44*8-1, 3*8, 33*8-1) | |
| 479 | ||
| 258 | 480 | MDRV_GFXDECODE(sderby) |
| 481 | MDRV_PALETTE_LENGTH(0x1000) | |
| 482 | MDRV_VIDEO_START(sderby) | |
| 483 | MDRV_VIDEO_UPDATE(sderby) | |
| 259 | 484 | |
| 485 | MDRV_SPEAKER_STANDARD_MONO("mono") | |
| 486 | MDRV_SOUND_ADD("oki", OKIM6295, 1056000) | |
| 487 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) /* clock frequency & pin 7 not verified */ | |
| 488 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) | |
| 489 | MACHINE_DRIVER_END | |
| 260 | 490 | |
| 491 | static MACHINE_DRIVER_START( spacewin ) | |
| 492 | MDRV_CPU_ADD("main", M68000, 12000000) | |
| 493 | MDRV_CPU_PROGRAM_MAP(spacewin_map,0) | |
| 494 | MDRV_CPU_VBLANK_INT("main", irq2_line_hold) | |
| 495 | ||
| 496 | MDRV_NVRAM_HANDLER(generic_0fill) | |
| 497 | ||
| 261 | 498 | MDRV_SCREEN_ADD("main", RASTER) |
| 262 | 499 | MDRV_SCREEN_REFRESH_RATE(60) |
| 263 | 500 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0)) |
| r3232 | r3233 | |
| 265 | 502 | MDRV_SCREEN_SIZE(64*8, 64*8) |
| 266 | 503 | MDRV_SCREEN_VISIBLE_AREA(4*8, 44*8-1, 3*8, 33*8-1) |
| 267 | 504 | |
| 505 | MDRV_GFXDECODE(sderby) | |
| 268 | 506 | MDRV_PALETTE_LENGTH(0x1000) |
| 269 | ||
| 270 | 507 | MDRV_VIDEO_START(sderby) |
| 271 | MDRV_VIDEO_UPDATE( | |
| 508 | MDRV_VIDEO_UPDATE(pm | |
| 272 | 509 | |
| 273 | 510 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 274 | ||
| 275 | 511 | MDRV_SOUND_ADD("oki", OKIM6295, 1056000) |
| 276 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) / | |
| 512 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) /* clock frequency & pin 7 not verified */ | |
| 277 | 513 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 278 | ||
| 279 | 514 | MACHINE_DRIVER_END |
| 280 | 515 | |
| 281 | 516 | static MACHINE_DRIVER_START( pmroulet ) |
| r3232 | r3233 | |
| 283 | 518 | MDRV_CPU_PROGRAM_MAP(roulette_map,0) |
| 284 | 519 | MDRV_CPU_VBLANK_INT("main", irq2_line_hold) |
| 285 | 520 | |
| 286 | MDRV_ | |
| 521 | MDRV_NVRAM_HANDLER | |
| 287 | 522 | |
| 288 | ||
| 289 | 523 | MDRV_SCREEN_ADD("main", RASTER) |
| 290 | 524 | MDRV_SCREEN_REFRESH_RATE(60) |
| 291 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500) /* not accurate */ | |
| 525 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ | |
| 292 | 526 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 293 | 527 | MDRV_SCREEN_SIZE(64*8, 64*8) |
| 294 | 528 | MDRV_SCREEN_VISIBLE_AREA(4*8, 44*8-1, 3*8, 33*8-1) |
| 295 | 529 | |
| 530 | MDRV_GFXDECODE(sderby) | |
| 296 | 531 | MDRV_PALETTE_LENGTH(0x1000) |
| 297 | ||
| 298 | 532 | MDRV_VIDEO_START(sderby) |
| 299 | 533 | MDRV_VIDEO_UPDATE(pmroulet) |
| 300 | 534 | |
| 301 | 535 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 302 | ||
| 303 | 536 | MDRV_SOUND_ADD("oki", OKIM6295, 1056000) |
| 304 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) / | |
| 537 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) /* clock frequency & pin 7 not verified */ | |
| 305 | 538 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.0) |
| 306 | ||
| 307 | 539 | MACHINE_DRIVER_END |
| 308 | 540 | |
| 309 | 541 | |
| 542 | /**************************** | |
| 543 | * Rom Loads * | |
| 544 | ****************************/ | |
| 545 | /* | |
| 546 | ||
| 547 | Super Derby | |
| 548 | Playmark '96 | |
| 549 | ||
| 550 | mc 68k 12mhz | |
| 551 | OKI m6295 | |
| 552 | ||
| 553 | 2x GM 76c88al (8kx8 6264) near program ROMs | |
| 554 | 2x 6264 near gfx ROMs | |
| 555 | 16k nonvolatile SRAM (Dallas 1220Y) | |
| 556 | two FPGA chips - one labelled 'Playmark 010412' | |
| 557 | 4x hm3-65728bk-5 | |
| 558 | -- | |
| 559 | 21.bin 6F9F2F2B - near OKI (samples?) | |
| 560 | ||
| 561 | 22.bin A319F1E0 - program code | |
| 562 | 23.bin 1D6E2321 / | |
| 563 | ||
| 564 | 24.bin 93C917DF - gfx | |
| 565 | 25.bin 7BA485CD | |
| 566 | 26.bin BEABE4F7 | |
| 567 | 27.bin 672CE5DF | |
| 568 | 28.bin 39CA3B52 | |
| 569 | ||
| 570 | */ | |
| 310 | 571 | ROM_START( sderby ) |
| 311 | 572 | ROM_REGION( 0x80000, "main", 0 ) /* 68000 Code */ |
| 312 | 573 | ROM_LOAD16_BYTE( "22.bin", 0x00000, 0x20000, CRC(a319f1e0) SHA1(d932cc7e990aa87308dcd9ffa5af2aaea333aa9a) ) |
| r3232 | r3233 | |
| 323 | 584 | ROM_LOAD( "28.bin", 0x80000, 0x20000, CRC(39ca3b52) SHA1(9a03e73d88a1551cd3cfe616ab71e67dced1272a) ) |
| 324 | 585 | ROM_END |
| 325 | 586 | |
| 587 | /* Scacco Matto / Space Win | |
| 588 | Playmark, 1996. | |
| 326 | 589 | |
| 590 | CPU: | |
| 591 | 1x MC68000P12 (main)(u24) | |
| 592 | ||
| 593 | Sound: | |
| 594 | 1x M6295 (sound)(u146) | |
| 595 | 1x TDA2003 (sound)(td1) | |
| 596 | 1x 358D (sound)(u155) | |
| 597 | ||
| 598 | PLDs: | |
| 599 | 2x A1020B-PL84C (u110,u137)(not dumped) | |
| 600 | ||
| 601 | Xtals: | |
| 602 | 1x oscillator 24.000000MHz (xl1) | |
| 603 | 1x oscillator 28.000000MHz (xl2) | |
| 604 | 1x blu resonator 1000J (sound)(y1) | |
| 605 | ||
| 606 | ROMs: | |
| 607 | 1x M27C2001 (1) | |
| 608 | 7x M27C1001 (2,3,4,5,6,7,8) | |
| 609 | ||
| 610 | 4x PALCE22V10H (not dumped) | |
| 611 | 1x PALCE16V8H (not dumped) | |
| 612 | 1x DS1220Y-200 (non volatile ram) | |
| 613 | ||
| 614 | Note: | |
| 615 | 1x JAMMA edge connector | |
| 616 | 1x 12 legs connector | |
| 617 | 2x 6 legs connector | |
| 618 | 1x pushbutton (cb1) | |
| 619 | 1x trimmer (volume) | |
| 620 | ||
| 621 | Title depends on graphics type in test mode. | |
| 622 | ||
| 623 | */ | |
| 624 | ROM_START( spacewin ) | |
| 625 | ROM_REGION( 0x40000, "main", 0 ) /* 68000 Code */ | |
| 626 | ROM_LOAD16_BYTE( "2.u16", 0x00000, 0x20000, CRC(2d17c2ab) SHA1(833ab39081fbc3d114103055e3a3f2ea2a28f158) ) | |
| 627 | ROM_LOAD16_BYTE( "3.u15", 0x00001, 0x20000, CRC(fd6f93ef) SHA1(1dc35fd92a0185434b44aa3c7da47a408fb2ce27) ) | |
| 628 | ||
| 629 | ROM_REGION( 0x080000, "oki", 0 ) /* Samples */ | |
| 630 | ROM_LOAD( "1.u147", 0x00000, 0x40000, CRC(eedc7090) SHA1(fc8cabf7a11a1de3ccc3b8860afd8f32669608b8) ) | |
| 631 | ||
| 632 | ROM_REGION( 0xa0000, "gfx1", 0 ) /* Sprites */ | |
| 633 | ROM_LOAD( "4.u141", 0x000000, 0x20000, CRC(ce20c599) SHA1(93358c3a891c66ca944eb684bd47e9c25bfcb88d) ) | |
| 634 | ROM_LOAD( "5.u142", 0x020000, 0x20000, CRC(ae4f8e06) SHA1(cb3b941c67ae5c9df005d9f8b2105dc5a114f19f) ) | |
| 635 | ROM_LOAD( "6.u143", 0x040000, 0x20000, CRC(b99afc96) SHA1(589270dbd5022db2d032da85a9813c271fa71a90) ) | |
| 636 | ROM_LOAD( "7.u144", 0x060000, 0x20000, CRC(30f212ad) SHA1(ecafd93b11ff15386ef02e9f6657a52baf7932b4) ) | |
| 637 | ROM_LOAD( "8.u145", 0x080000, 0x20000, CRC(541a73fd) SHA1(fede5e2fcbb18e90cc50995d44e831c3f9b56614) ) | |
| 638 | ROM_END | |
| 639 | ||
| 327 | 640 | ROM_START( pmroulet ) |
| 328 | ROM_REGION( 0x40000, "main", 0 ) /* 68000 | |
| 641 | ROM_REGION( 0x40000, "main", 0 ) /* 68000 code */ | |
| 329 | 642 | ROM_LOAD16_BYTE( "2.bin", 0x00000, 0x20000, CRC(1677a2de) SHA1(4dcbb3c1ce9b65e06ba7e0cffa00c0c8016538f5)) |
| 330 | 643 | ROM_LOAD16_BYTE( "3.bin", 0x00001, 0x20000, CRC(11acaac2) SHA1(19e7bbbf4356fc9a866f9f36d0568c42d6a36c07)) |
| 331 | 644 | |
| 332 | ROM_REGION( 0x080000, "oki", 0 ) /* | |
| 645 | ROM_REGION( 0x080000, "oki", 0 ) /* samples are ok */ | |
| 333 | 646 | ROM_LOAD( "1.bin", 0x00000, 0x40000, CRC(6673de85) SHA1(df390cd6268efc0e743a9020f19bc0cbeb757cfa)) |
| 334 | 647 | |
| 335 | ROM_REGION( 0x280000, "gfx1", 0 ) /* | |
| 648 | ROM_REGION( 0x280000, "gfx1", 0 ) /* sprites */ | |
| 336 | 649 | ROM_LOAD( "4.bin", 0x000000, 0x80000, CRC(efcddac9) SHA1(72435ec478b70a067d47f3daf7c224169ee5827a)) |
| 337 | 650 | ROM_LOAD( "5.bin", 0x080000, 0x80000, CRC(bc75ef8f) SHA1(1f3dc457e5ae143d53cfef0e1fcb4586dceefb67)) |
| 338 | 651 | ROM_LOAD( "6.bin", 0x100000, 0x80000, CRC(e47d5f55) SHA1(a341e24f98125265cb3986f8c7ce84eedd056b71)) |
| r3232 | r3233 | |
| 340 | 653 | ROM_LOAD( "8.bin", 0x200000, 0x80000, CRC(d4c2b7da) SHA1(515be861443acc5b911241dbaafa42e02f79985a)) |
| 341 | 654 | ROM_END |
| 342 | 655 | |
| 343 | GAME( 1996, sderby, 0, sderby, sderby, 0, ROT0, "Playmark", "Super Derby", 0 ) | |
| 344 | GAME( 1997, pmroulet, 0, pmroulet, pmroulet, 0, ROT0, "Playmark", "Croupier (Playmark Roulette)", GAME_NOT_WORKING | GAME_UNEMULATED_PROTECTION ) | |
| 345 | 656 | |
| 657 | /****************************** | |
| 658 | * Game Drivers * | |
| 659 | ******************************/ | |
| 660 | ||
| 661 | /* YEAR NAME PARENT MACHINE INPUT INIT ROT COMPANY FULLNAME FLAGS LAYOUT */ | |
| 662 | GAMEL( 1996, sderby, 0, sderby, sderby, 0, ROT0, "Playmark", "Super Derby", 0, layout_sderby ) | |
| 663 | GAMEL( 1996, spacewin, 0, spacewin, spacewin, 0, ROT0, "Playmark", "Scacco Matto / Space Win", 0, layout_spacewin ) | |
| 664 | GAMEL( 1997, pmroulet, 0, pmroulet, pmroulet, 0, ROT0, "Playmark", "Croupier (Playmark Roulette)", GAME_UNEMULATED_PROTECTION | GAME_NOT_WORKING, layout_pmroulet ) | |
| 665 |
| r3232 | r3233 | |
|---|---|---|
| 540 | 540 | |
| 541 | 541 | static READ16_HANDLER( io_r ) |
| 542 | 542 | { |
| 543 | static const char *portnames[] = { "IN0", "IN1", "IN2" }; | |
| 543 | static const char *const portnames[] = { "IN0", "IN1", "IN2" }; | |
| 544 | 544 | |
| 545 | 545 | switch (offset) |
| 546 | 546 | { |
| r3232 | r3233 | |
|---|---|---|
| 85 | 85 | #include "sound/dac.h" |
| 86 | 86 | |
| 87 | 87 | |
| 88 | #define CPUTAG_MCU " | |
| 88 | #define CPUTAG_MCU "mcu" | |
| 89 | 89 | |
| 90 | 90 | extern UINT8 *champbas_bg_videoram; |
| 91 | 91 | |
| r3232 | r3233 | |
| 743 | 743 | ROM_LOAD( "15.10i", 0x4000, 0x1000, CRC(0225b7ef) SHA1(9adee4831eb633b0a31580596205a655df94c2b2) ) |
| 744 | 744 | ROM_LOAD( "16.11i", 0x5000, 0x1000, CRC(1612adf5) SHA1(9adeb21d5d1692f6e31460062f03f2008076b307) ) |
| 745 | 745 | |
| 746 | ROM_REGION( 0x2000, " | |
| 746 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 747 | 747 | ROM_LOAD( "8201.bin", 0x0000, 0x2000, CRC(b77931ac) SHA1(405b02585e80d95a2821455538c5c2c31ce262d1) ) |
| 748 | 748 | |
| 749 | 749 | ROM_REGION( 0x1000, "gfx1", ROMREGION_DISPOSE ) // chars |
| r3232 | r3233 | |
| 790 | 790 | ROM_LOAD( "17.2l", 0x2000, 0x2000, CRC(f10b148b) SHA1(d66516d509f6f16e51ee59d27c4867e276064c3f) ) |
| 791 | 791 | ROM_LOAD( "18.2n", 0x4000, 0x2000, CRC(2dc484dd) SHA1(28bd68c787d7e6989849ca52009948dbd5cdcc79) ) |
| 792 | 792 | |
| 793 | ROM_REGION( 0x2000, " | |
| 793 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 794 | 794 | ROM_LOAD( "8201.bin", 0x0000, 0x2000, CRC(b77931ac) SHA1(405b02585e80d95a2821455538c5c2c31ce262d1) ) |
| 795 | 795 | |
| 796 | 796 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) // chars + sprites: rearranged by DRIVER_INIT to leave only chars |
| r3232 | r3233 | |
| 839 | 839 | ROM_LOAD( "epr5935", 0x4000, 0x2000, CRC(3c911786) SHA1(eea0c467e213d237b5bb9d04b19a418d6090c2dc) ) |
| 840 | 840 | |
| 841 | 841 | // the pcb has a 8302 on it, though only the 8201 instructions are used |
| 842 | ROM_REGION( 0x2000, " | |
| 842 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 843 | 843 | ROM_LOAD( "8302.bin", 0x0000, 0x2000, CRC(edabac6c) SHA1(eaf1c51b63023256df526b0d3fd53cffc919c901) ) |
| 844 | 844 | |
| 845 | 845 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) // chars + sprites: rearranged by DRIVER_INIT to leave only chars |
| r3232 | r3233 | |
| 867 | 867 | ROM_LOAD( "epr5935", 0x4000, 0x2000, CRC(3c911786) SHA1(eea0c467e213d237b5bb9d04b19a418d6090c2dc) ) |
| 868 | 868 | |
| 869 | 869 | // the pcb has a 8302 on it, though only the 8201 instructions are used |
| 870 | ROM_REGION( 0x2000, " | |
| 870 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 871 | 871 | ROM_LOAD( "8302.bin", 0x0000, 0x2000, CRC(edabac6c) SHA1(eaf1c51b63023256df526b0d3fd53cffc919c901) ) |
| 872 | 872 | |
| 873 | 873 | ROM_REGION( 0x2000, "gfx1", ROMREGION_DISPOSE ) // chars + sprites: rearranged by DRIVER_INIT to leave only chars |
| r3232 | r3233 | |
| 1000 | 1000 | ROM_LOAD( "7_c6.bin", 0x6000, 0x2000, CRC(6d51521e) SHA1(2809bd2e61f40dcd31d43c62520982bdcfb0a865) ) /* vr.7h */ |
| 1001 | 1001 | ROM_LOAD( "1_a6.bin", 0x8000, 0x1000, CRC(20f2207e) SHA1(b1ed2237d0bd50ddbe593fd2fbff9f1d67c1eb11) ) /* vr.7k */ |
| 1002 | 1002 | |
| 1003 | ROM_REGION( 0x2000, " | |
| 1003 | ROM_REGION( 0x2000, "mcu", 0 ) | |
| 1004 | 1004 | ROM_LOAD( "8303.bin", 0x0000, 0x2000, CRC(66adcb37) SHA1(e1c72ecb161129dcbddc0b16dd90e716d0c79311) ) |
| 1005 | 1005 | |
| 1006 | 1006 | ROM_REGION( 0x04000, "gfx1", ROMREGION_DISPOSE ) // 3bpp chars + sprites: rearranged by DRIVER_INIT to leave only chars |
| r3232 | r3233 | |
|---|---|---|
| 205 | 205 | VIDEO_START( ninjaw ); |
| 206 | 206 | VIDEO_UPDATE( ninjaw ); |
| 207 | 207 | |
| 208 | static UINT16 cpua_ctrl | |
| 208 | static UINT16 cpua_ctrl | |
| 209 | 209 | |
| 210 | 210 | static void parse_control(running_machine *machine) /* assumes Z80 sandwiched between 68Ks */ |
| 211 | 211 | { |
| r3232 | r3233 | |
| 232 | 232 | SOUND |
| 233 | 233 | *****************************************/ |
| 234 | 234 | |
| 235 | static INT32 banknum | |
| 235 | static INT32 banknum | |
| 236 | 236 | |
| 237 | 237 | static void reset_sound_region(running_machine *machine) |
| 238 | 238 | { |
| r3232 | r3233 | |
| 931 | 931 | static MACHINE_START( ninjaw ) |
| 932 | 932 | { |
| 933 | 933 | cpua_ctrl = 0xff; |
| 934 | banknum = -1; | |
| 935 | memset(ninjaw_pandata, 0, sizeof(ninjaw_pandata)); | |
| 936 | ||
| 934 | 937 | state_save_register_global(cpua_ctrl); |
| 935 | 938 | state_save_register_global(banknum); |
| 936 | 939 | state_save_register_postload(machine, ninjaw_postload, NULL); |
| r3232 | r3233 | |
|---|---|---|
| 528 | 528 | AM_RANGE(0xf000, 0xf000) AM_WRITE(SMH_NOP) /* ?? */ |
| 529 | 529 | ADDRESS_MAP_END |
| 530 | 530 | |
| 531 | ||
| 532 | static ADDRESS_MAP_START( sound_readport, ADDRESS_SPACE_IO, 8 ) | |
| 531 | static ADDRESS_MAP_START( sound_io_map, ADDRESS_SPACE_IO, 8 ) | |
| 533 | 532 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 534 | AM_RANGE(0x00, 0x00) AM_READ(ym2203_status_port_0_r) | |
| 535 | ADDRESS_MAP_END | |
| 536 | ||
| 537 | static ADDRESS_MAP_START( sound_writeport, ADDRESS_SPACE_IO, 8 ) | |
| 538 | ADDRESS_MAP_GLOBAL_MASK(0xff) | |
| 539 | AM_RANGE(0x00, 0x00) AM_WRITE(ym2203_control_port_0_w) | |
| 533 | AM_RANGE(0x00, 0x00) AM_READWRITE(ym2203_status_port_0_r, ym2203_control_port_0_w) | |
| 540 | 534 | AM_RANGE(0x01, 0x01) AM_WRITE(ym2203_write_port_0_w) |
| 541 | 535 | ADDRESS_MAP_END |
| 542 | 536 | |
| 543 | 537 | |
| 544 | 538 | |
| 545 | 539 | |
| 546 | ||
| 547 | ||
| 548 | ||
| 549 | 540 | static const gfx_layout tilelayout = |
| 550 | 541 | { |
| 551 | 542 | 8,8, |
| r3232 | r3233 | |
| 783 | 774 | |
| 784 | 775 | MDRV_CPU_ADD("audio", Z80, 3000000) /* OSC 12MHz divided by 4 ??? */ |
| 785 | 776 | MDRV_CPU_PROGRAM_MAP(sound_readmem_z80,sound_writemem_z80) |
| 786 | MDRV_CPU_IO_MAP(sound_ | |
| 777 | MDRV_CPU_IO_MAP(sound_i | |
| 787 | 778 | |
| 788 | 779 | /* video hardware */ |
| 789 | 780 | MDRV_SCREEN_ADD("main", RASTER) |
| r3232 | r3233 | |
| 4093 | 4084 | GAME( 1993, cybattlr, 0, system_C, cybattlr, cybattlr, ROT90, "Jaleco", "Cybattler", 0 ) |
| 4094 | 4085 | GAME( 1993, hayaosi1, 0, system_B_hayaosi1, hayaosi1, hayaosi1, ROT0, "Jaleco", "Hayaoshi Quiz Ouza Ketteisen - The King Of Quiz", GAME_IMPERFECT_GRAPHICS ) |
| 4095 | 4086 | GAME( 1993, peekaboo, 0, system_D, peekaboo, peekaboo, ROT0, "Jaleco", "Peek-a-Boo!", 0 ) |
| 4087 |
| r3232 | r3233 | |
|---|---|---|
| 92 | 92 | 8*64 |
| 93 | 93 | }; |
| 94 | 94 | |
| 95 | static void update_palette( | |
| 95 | static void update_palette(running_machine *machine) | |
| 96 | 96 | { |
| 97 | 97 | INT8 r, g ,b; |
| 98 | 98 | int brg = brightness - 0x60; |
| r3232 | r3233 | |
| 120 | 120 | b += ((0x1F - b) * brg) >> 5; |
| 121 | 121 | if(b > 0x1F) b = 0x1F; |
| 122 | 122 | } |
| 123 | palette_set_color( | |
| 123 | palette_set_color(machine, i, MAKE_RGB(r << 3, g << 3, b << 3)); | |
| 124 | 124 | } |
| 125 | 125 | } |
| 126 | 126 | |
| r3232 | r3233 | |
| 147 | 147 | |
| 148 | 148 | /* Debug code */ |
| 149 | 149 | #ifdef UNUSED_FUNCTION |
| 150 | static void srmp6_decode_charram( | |
| 150 | static void srmp6_decode_charram(running_machine *machine) | |
| 151 | 151 | { |
| 152 | 152 | if(input_code_pressed_once(KEYCODE_Z)) |
| 153 | 153 | { |
| 154 | 154 | int i; |
| 155 | 155 | for (i=0;i<(0x100000*16)/0x40;i++) |
| 156 | 156 | { |
| 157 | decodechar( | |
| 157 | decodechar(machine->gfx[0], i, (UINT8*)tileram); | |
| 158 | 158 | dirty_tileram[i] = 0; |
| 159 | 159 | } |
| 160 | 160 | } |
| r3232 | r3233 | |
| 182 | 182 | |
| 183 | 183 | #if 0 |
| 184 | 184 | /* debug */ |
| 185 | srmp6_decode_charram(); | |
| 185 | srmp6_decode_charram(screen->machine); | |
| 186 | 186 | |
| 187 | 187 | |
| 188 | 188 | |
| r3232 | r3233 | |
| 350 | 350 | data = (!data)?0x60:(data == 0x5e)?0x60:data; |
| 351 | 351 | if(brightness != data) { |
| 352 | 352 | brightness = data; |
| 353 | update_palette(); | |
| 353 | update_palette(machine); | |
| 354 | 354 | } |
| 355 | 355 | break; |
| 356 | 356 |
| r3232 | r3233 | |
|---|---|---|
| 1989 | 1989 | static MACHINE_DRIVER_START( dfeveron ) |
| 1990 | 1990 | |
| 1991 | 1991 | /* basic machine hardware */ |
| 1992 | MDRV_CPU_ADD("main", M68000, 16 | |
| 1992 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 1993 | 1993 | MDRV_CPU_PROGRAM_MAP(dfeveron_readmem,dfeveron_writemem) |
| 1994 | 1994 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 1995 | 1995 | |
| r3232 | r3233 | |
| 2014 | 2014 | /* sound hardware */ |
| 2015 | 2015 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2016 | 2016 | |
| 2017 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2017 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2018 | 2018 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2019 | 2019 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2020 | 2020 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2028 | 2028 | static MACHINE_DRIVER_START( ddonpach ) |
| 2029 | 2029 | |
| 2030 | 2030 | /* basic machine hardware */ |
| 2031 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2031 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2032 | 2032 | MDRV_CPU_PROGRAM_MAP(ddonpach_readmem,ddonpach_writemem) |
| 2033 | 2033 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2034 | 2034 | |
| r3232 | r3233 | |
| 2053 | 2053 | /* sound hardware */ |
| 2054 | 2054 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2055 | 2055 | |
| 2056 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2056 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2057 | 2057 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2058 | 2058 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2059 | 2059 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2067 | 2067 | static MACHINE_DRIVER_START( donpachi ) |
| 2068 | 2068 | |
| 2069 | 2069 | /* basic machine hardware */ |
| 2070 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2070 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2071 | 2071 | MDRV_CPU_PROGRAM_MAP(donpachi_readmem,donpachi_writemem) |
| 2072 | 2072 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2073 | 2073 | |
| r3232 | r3233 | |
| 2092 | 2092 | /* sound hardware */ |
| 2093 | 2093 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2094 | 2094 | |
| 2095 | MDRV_SOUND_ADD("oki1", OKIM6295, 1056 | |
| 2095 | MDRV_SOUND_ADD("oki1", OKIM6295, XTAL_1_056MHz) | |
| 2096 | 2096 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) // clock frequency & pin 7 not verified |
| 2097 | 2097 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.60) |
| 2098 | 2098 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.60) |
| r3232 | r3233 | |
| 2111 | 2111 | static MACHINE_DRIVER_START( esprade ) |
| 2112 | 2112 | |
| 2113 | 2113 | /* basic machine hardware */ |
| 2114 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2114 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2115 | 2115 | MDRV_CPU_PROGRAM_MAP(esprade_readmem,esprade_writemem) |
| 2116 | 2116 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2117 | 2117 | |
| r3232 | r3233 | |
| 2136 | 2136 | /* sound hardware */ |
| 2137 | 2137 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2138 | 2138 | |
| 2139 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2139 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2140 | 2140 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2141 | 2141 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2142 | 2142 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2150 | 2150 | static MACHINE_DRIVER_START( gaia ) |
| 2151 | 2151 | |
| 2152 | 2152 | /* basic machine hardware */ |
| 2153 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2153 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2154 | 2154 | MDRV_CPU_PROGRAM_MAP(gaia_readmem,gaia_writemem) |
| 2155 | 2155 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2156 | 2156 | |
| r3232 | r3233 | |
| 2174 | 2174 | /* sound hardware */ |
| 2175 | 2175 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2176 | 2176 | |
| 2177 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2177 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2178 | 2178 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2179 | 2179 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2180 | 2180 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2188 | 2188 | static MACHINE_DRIVER_START( guwange ) |
| 2189 | 2189 | |
| 2190 | 2190 | /* basic machine hardware */ |
| 2191 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2191 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2192 | 2192 | MDRV_CPU_PROGRAM_MAP(guwange_readmem,guwange_writemem) |
| 2193 | 2193 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2194 | 2194 | |
| r3232 | r3233 | |
| 2213 | 2213 | /* sound hardware */ |
| 2214 | 2214 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2215 | 2215 | |
| 2216 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2216 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2217 | 2217 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2218 | 2218 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2219 | 2219 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2226 | 2226 | static MACHINE_DRIVER_START( hotdogst ) |
| 2227 | 2227 | |
| 2228 | 2228 | /* basic machine hardware */ |
| 2229 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2229 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2230 | 2230 | MDRV_CPU_PROGRAM_MAP(hotdogst_readmem,hotdogst_writemem) |
| 2231 | 2231 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2232 | 2232 | |
| 2233 | MDRV_CPU_ADD("audio", Z80, 4 | |
| 2233 | MDRV_CPU_ADD("audio", Z80, XTAL_4MHz | |
| 2234 | 2234 | MDRV_CPU_PROGRAM_MAP(hotdogst_sound_readmem,hotdogst_sound_writemem) |
| 2235 | 2235 | MDRV_CPU_IO_MAP(hotdogst_sound_readport,hotdogst_sound_writeport) |
| 2236 | 2236 | |
| r3232 | r3233 | |
| 2255 | 2255 | /* sound hardware */ |
| 2256 | 2256 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2257 | 2257 | |
| 2258 | MDRV_SOUND_ADD("ym", YM2203, 4 | |
| 2258 | MDRV_SOUND_ADD("ym", YM2203, XTAL_4MHz | |
| 2259 | 2259 | MDRV_SOUND_CONFIG(ym2203_config) |
| 2260 | 2260 | MDRV_SOUND_ROUTE(0, "left", 0.20) |
| 2261 | 2261 | MDRV_SOUND_ROUTE(0, "right", 0.20) |
| r3232 | r3233 | |
| 2266 | 2266 | MDRV_SOUND_ROUTE(3, "left", 0.80) |
| 2267 | 2267 | MDRV_SOUND_ROUTE(3, "right", 0.80) |
| 2268 | 2268 | |
| 2269 | MDRV_SOUND_ADD("oki", OKIM6295, 1056 | |
| 2269 | MDRV_SOUND_ADD("oki", OKIM6295, XTAL_1_056MHz) | |
| 2270 | 2270 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) // clock frequency & pin 7 not verified |
| 2271 | 2271 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 2272 | 2272 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| r3232 | r3233 | |
| 2280 | 2280 | static MACHINE_DRIVER_START( korokoro ) |
| 2281 | 2281 | |
| 2282 | 2282 | /* basic machine hardware */ |
| 2283 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2283 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2284 | 2284 | MDRV_CPU_PROGRAM_MAP(korokoro_readmem,korokoro_writemem) |
| 2285 | 2285 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2286 | 2286 | |
| r3232 | r3233 | |
| 2305 | 2305 | /* sound hardware */ |
| 2306 | 2306 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2307 | 2307 | |
| 2308 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2308 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2309 | 2309 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2310 | 2310 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2311 | 2311 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 2319 | 2319 | static MACHINE_DRIVER_START( mazinger ) |
| 2320 | 2320 | |
| 2321 | 2321 | /* basic machine hardware */ |
| 2322 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2322 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2323 | 2323 | MDRV_CPU_PROGRAM_MAP(mazinger_readmem,mazinger_writemem) |
| 2324 | 2324 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2325 | 2325 | |
| 2326 | MDRV_CPU_ADD("audio", Z80, 4 | |
| 2326 | MDRV_CPU_ADD("audio", Z80, XTAL_4MHz | |
| 2327 | 2327 | MDRV_CPU_PROGRAM_MAP(mazinger_sound_readmem,mazinger_sound_writemem) |
| 2328 | 2328 | MDRV_CPU_IO_MAP(mazinger_sound_readport,mazinger_sound_writeport) |
| 2329 | 2329 | |
| r3232 | r3233 | |
| 2350 | 2350 | /* sound hardware */ |
| 2351 | 2351 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2352 | 2352 | |
| 2353 | MDRV_SOUND_ADD("ym", YM2203, 4 | |
| 2353 | MDRV_SOUND_ADD("ym", YM2203, XTAL_4MHz | |
| 2354 | 2354 | MDRV_SOUND_CONFIG(ym2203_config) |
| 2355 | 2355 | MDRV_SOUND_ROUTE(0, "left", 0.20) |
| 2356 | 2356 | MDRV_SOUND_ROUTE(0, "right", 0.20) |
| r3232 | r3233 | |
| 2361 | 2361 | MDRV_SOUND_ROUTE(3, "left", 0.60) |
| 2362 | 2362 | MDRV_SOUND_ROUTE(3, "right", 0.60) |
| 2363 | 2363 | |
| 2364 | MDRV_SOUND_ADD("oki", OKIM6295, 1056 | |
| 2364 | MDRV_SOUND_ADD("oki", OKIM6295, XTAL_1_056MHz) | |
| 2365 | 2365 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) // clock frequency & pin 7 not verified |
| 2366 | 2366 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 2.0) |
| 2367 | 2367 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 2.0) |
| r3232 | r3233 | |
| 2375 | 2375 | static MACHINE_DRIVER_START( metmqstr ) |
| 2376 | 2376 | |
| 2377 | 2377 | /* basic machine hardware */ |
| 2378 | MDRV_CPU_ADD("main", M68000,32 | |
| 2378 | MDRV_CPU_ADD("main", M68000, XTAL_32MHz | |
| 2379 | 2379 | MDRV_CPU_PROGRAM_MAP(metmqstr_readmem,metmqstr_writemem) |
| 2380 | 2380 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2381 | 2381 | |
| 2382 | MDRV_CPU_ADD("audio", Z80,32 | |
| 2382 | MDRV_CPU_ADD("audio", Z80, XTAL_32MHz | |
| 2383 | 2383 | MDRV_CPU_PROGRAM_MAP(metmqstr_sound_readmem,metmqstr_sound_writemem) |
| 2384 | 2384 | MDRV_CPU_IO_MAP(metmqstr_sound_readport,metmqstr_sound_writeport) |
| 2385 | 2385 | |
| r3232 | r3233 | |
| 2406 | 2406 | /* sound hardware */ |
| 2407 | 2407 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2408 | 2408 | |
| 2409 | MDRV_SOUND_ADD("ym", YM2151, 16 | |
| 2409 | MDRV_SOUND_ADD("ym", YM2151, XTAL_16MHz | |
| 2410 | 2410 | MDRV_SOUND_CONFIG(ym2151_config) |
| 2411 | 2411 | MDRV_SOUND_ROUTE(0, "left", 1.20) |
| 2412 | 2412 | MDRV_SOUND_ROUTE(1, "right", 1.20) |
| 2413 | 2413 | |
| 2414 | MDRV_SOUND_ADD("oki1", OKIM6295, 32 | |
| 2414 | MDRV_SOUND_ADD("oki1", OKIM6295, XTAL_32MHz | |
| 2415 | 2415 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) |
| 2416 | 2416 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 2417 | 2417 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| 2418 | 2418 | |
| 2419 | MDRV_SOUND_ADD("oki2", OKIM6295, 32 | |
| 2419 | MDRV_SOUND_ADD("oki2", OKIM6295, XTAL_32MHz | |
| 2420 | 2420 | MDRV_SOUND_CONFIG(okim6295_interface_pin7high) |
| 2421 | 2421 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.0) |
| 2422 | 2422 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.0) |
| r3232 | r3233 | |
| 2432 | 2432 | static MACHINE_DRIVER_START( pwrinst2 ) |
| 2433 | 2433 | |
| 2434 | 2434 | /* basic machine hardware */ |
| 2435 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2435 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2436 | 2436 | MDRV_CPU_PROGRAM_MAP(pwrinst2_readmem,pwrinst2_writemem) |
| 2437 | 2437 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2438 | 2438 | |
| 2439 | MDRV_CPU_ADD("audio", Z80,16 | |
| 2439 | MDRV_CPU_ADD("audio", Z80,XTAL_16MHz | |
| 2440 | 2440 | MDRV_CPU_PROGRAM_MAP(pwrinst2_sound_readmem,pwrinst2_sound_writemem) |
| 2441 | 2441 | MDRV_CPU_IO_MAP(pwrinst2_sound_readport,pwrinst2_sound_writeport) |
| 2442 | 2442 | |
| r3232 | r3233 | |
| 2461 | 2461 | /* sound hardware */ |
| 2462 | 2462 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2463 | 2463 | |
| 2464 | MDRV_SOUND_ADD("ym", YM2203, 16 | |
| 2464 | MDRV_SOUND_ADD("ym", YM2203, XTAL_16MHz | |
| 2465 | 2465 | MDRV_SOUND_CONFIG(ym2203_config) |
| 2466 | 2466 | MDRV_SOUND_ROUTE(0, "left", 0.40) |
| 2467 | 2467 | MDRV_SOUND_ROUTE(0, "right", 0.40) |
| r3232 | r3233 | |
| 2472 | 2472 | MDRV_SOUND_ROUTE(3, "left", 0.80) |
| 2473 | 2473 | MDRV_SOUND_ROUTE(3, "right", 0.80) |
| 2474 | 2474 | |
| 2475 | MDRV_SOUND_ADD("oki1", OKIM6295, 3 | |
| 2475 | MDRV_SOUND_ADD("oki1", OKIM6295, XTAL_3MHz | |
| 2476 | 2476 | MDRV_SOUND_CONFIG(okim6295_interface_pin7low) |
| 2477 | 2477 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 0.80) |
| 2478 | 2478 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 0.80) |
| 2479 | 2479 | |
| 2480 | MDRV_SOUND_ADD("oki2", OKIM6295, 3 | |
| 2480 | MDRV_SOUND_ADD("oki2", OKIM6295, XTAL_3MHz | |
| 2481 | 2481 | MDRV_SOUND_CONFIG(okim6295_interface_pin7low) |
| 2482 | 2482 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "left", 1.00) |
| 2483 | 2483 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "right", 1.00) |
| r3232 | r3233 | |
| 2491 | 2491 | static MACHINE_DRIVER_START( sailormn ) |
| 2492 | 2492 | |
| 2493 | 2493 | /* basic machine hardware */ |
| 2494 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2494 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2495 | 2495 | MDRV_CPU_PROGRAM_MAP(sailormn_readmem,sailormn_writemem) |
| 2496 | 2496 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2497 | 2497 | |
| 2498 | MDRV_CPU_ADD("audio", Z80, 8 | |
| 2498 | MDRV_CPU_ADD("audio", Z80, XTAL_8MHz | |
| 2499 | 2499 | MDRV_CPU_PROGRAM_MAP(sailormn_sound_readmem,sailormn_sound_writemem) |
| 2500 | 2500 | MDRV_CPU_IO_MAP(sailormn_sound_readport,sailormn_sound_writeport) |
| 2501 | 2501 | |
| r3232 | r3233 | |
| 2521 | 2521 | |
| 2522 | 2522 | /* sound hardware */ |
| 2523 | 2523 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2524 | MDRV_SOUND_ADD("ym", YM2151, 16 | |
| 2524 | MDRV_SOUND_ADD("ym", YM2151, XTAL_16MHz | |
| 2525 | 2525 | MDRV_SOUND_CONFIG(ym2151_config) |
| 2526 | 2526 | MDRV_SOUND_ROUTE(0, "left", 0.30) |
| 2527 | 2527 | MDRV_SOUND_ROUTE(1, "right", 0.30) |
| r3232 | r3233 | |
| 2545 | 2545 | static MACHINE_DRIVER_START( uopoko ) |
| 2546 | 2546 | |
| 2547 | 2547 | /* basic machine hardware */ |
| 2548 | MDRV_CPU_ADD("main", M68000, 16 | |
| 2548 | MDRV_CPU_ADD("main", M68000, XTAL_16MHz | |
| 2549 | 2549 | MDRV_CPU_PROGRAM_MAP(uopoko_readmem,uopoko_writemem) |
| 2550 | 2550 | MDRV_CPU_VBLANK_INT("main", cave_interrupt) |
| 2551 | 2551 | |
| r3232 | r3233 | |
| 2569 | 2569 | /* sound hardware */ |
| 2570 | 2570 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 2571 | 2571 | |
| 2572 | MDRV_SOUND_ADD("ymz", YMZ280B, 169344 | |
| 2572 | MDRV_SOUND_ADD("ymz", YMZ280B, XTAL_16_9344MHz) | |
| 2573 | 2573 | MDRV_SOUND_CONFIG(ymz280b_intf) |
| 2574 | 2574 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 2575 | 2575 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 3320 | 3320 | |
| 3321 | 3321 | ROM_REGION( 0x400000, "ymz", 0 ) /* Samples */ |
| 3322 | 3322 | ROM_LOAD( "u0462.bin", 0x000000, 0x400000, CRC(b3d75691) SHA1(71d8dae92be1542a3cff50efeec0bf3c14ab59f5) ) |
| 3323 | ||
| 3324 | ROM_REGION( 0x0004, "plds", ROMREGION_DISPOSE ) | |
| 3325 | ROM_LOAD( "atc05-1.bin", 0x0000, 0x0001, NO_DUMP ) /* GAL16V8D-15LP located at U159 */ | |
| 3326 | ROM_LOAD( "u0259.bin", 0x0000, 0x0001, NO_DUMP ) /* XC9536-15PC44C Located at U0249. (Chip label different then label silk screened onto the board.) */ | |
| 3327 | ROM_LOAD( "u108.bin", 0x0000, 0x0001, NO_DUMP ) /* XC9536-15PC44C Located at U108. */ | |
| 3328 | ROM_LOAD( "u084.bin", 0x0000, 0x0001, NO_DUMP ) /* XC9536-15PC44C Located at U084. */ | |
| 3323 | 3329 | ROM_END |
| 3324 | 3330 | |
| 3325 | 3331 |
| r3232 | r3233 | |
|---|---|---|
| 29 | 29 | |
| 30 | 30 | static READ16_HANDLER( tourtabl_read_input_port ) |
| 31 | 31 | { |
| 32 | static const char *tianames[] = { "PADDLE4", "PADDLE3", "PADDLE2", "PADDLE1", "TIA_IN4", "TIA_IN5" }; | |
| 32 | static const char *const tianames[] = { "PADDLE4", "PADDLE3", "PADDLE2", "PADDLE1", "TIA_IN4", "TIA_IN5" }; | |
| 33 | 33 | |
| 34 | 34 | return input_port_read(machine, tianames[offset]); |
| 35 | 35 | } |
| r3232 | r3233 | |
|---|---|---|
| 66 | 66 | static tilemap *bg_tilemap; |
| 67 | 67 | static UINT8 *trvmadns_gfxram; |
| 68 | 68 | static UINT8 *trvmadns_tileram; |
| 69 | static int old_data; | |
| 69 | 70 | |
| 70 | 71 | static WRITE8_HANDLER( trvmadns_banking_w ) |
| 71 | 72 | { |
| 72 | static int old = -1; | |
| 73 | 73 | |
| 74 | 74 | UINT8 *rom; |
| 75 | 75 | int address = 0; |
| r3232 | r3233 | |
| 100 | 100 | } |
| 101 | 101 | else |
| 102 | 102 | { |
| 103 | if(data != old) | |
| 103 | if(data != old_data) | |
| 104 | 104 | { |
| 105 | printf("port80 = %02X\n",old=data); | |
| 106 | // logerror("port80 = %02X\n",old=data); | |
| 105 | old_data = data; | |
| 106 | printf("port80 = %02X\n",data); | |
| 107 | //logerror("port80 = %02X\n",data); | |
| 107 | 108 | } |
| 108 | 109 | |
| 109 | 110 | rom = memory_region(machine, "user1"); |
| r3232 | r3233 | |
| 277 | 278 | return 0; |
| 278 | 279 | } |
| 279 | 280 | |
| 281 | static MACHINE_RESET( trvmadns ) | |
| 282 | { | |
| 283 | old_data = -1; | |
| 284 | } | |
| 285 | ||
| 280 | 286 | static MACHINE_DRIVER_START( trvmadns ) |
| 281 | 287 | MDRV_CPU_ADD("main", Z80,10000000/2) // ? |
| 282 | 288 | MDRV_CPU_PROGRAM_MAP(cpu_map,0) |
| 283 | 289 | MDRV_CPU_IO_MAP(io_map,0) |
| 284 | 290 | MDRV_CPU_VBLANK_INT("main", nmi_line_pulse) |
| 285 | 291 | |
| 292 | MDRV_MACHINE_RESET(trvmadns) | |
| 293 | ||
| 286 | 294 | /* video hardware */ |
| 287 | 295 | MDRV_SCREEN_ADD("main", RASTER) |
| 288 | 296 | MDRV_SCREEN_REFRESH_RATE(60) |
| r3232 | r3233 | |
|---|---|---|
| 210 | 210 | cpunum_set_input_line(machine, MAIN_CPU, int_level, HOLD_LINE); |
| 211 | 211 | |
| 212 | 212 | /* Update the laserdisc */ |
| 213 | laserdisc_vsync(laserdisc); | |
| 214 | 213 | video_field ^= 1; |
| 215 | 214 | } |
| 216 | 215 | |
| r3232 | r3233 | |
| 534 | 533 | static const cubeqst_snd_config snd_config = |
| 535 | 534 | { |
| 536 | 535 | sound_dac_w, |
| 537 | "sound | |
| 536 | "sound | |
| 538 | 537 | }; |
| 539 | 538 | |
| 540 | 539 | |
| r3232 | r3233 | |
| 577 | 576 | MDRV_PALETTE_LENGTH(8192 + 1) |
| 578 | 577 | MDRV_PALETTE_INIT(cubeqst) |
| 579 | 578 | |
| 580 | MDRV_LASERDISC_ADD("laserdisc", SIMUTREK_SPECIAL) | |
| 579 | MDRV_LASERDISC_ADD("laserdisc", SIMUTREK_SPECIAL, "main", "ldsound") | |
| 581 | 580 | MDRV_LASERDISC_OVERLAY(cubeqst, CUBEQST_HBLANK, CUBEQST_VCOUNT, BITMAP_FORMAT_INDEXED16) |
| 582 | 581 | MDRV_LASERDISC_OVERLAY_CLIP(0, 320-1, 0, 256-8) |
| 583 | 582 | MDRV_LASERDISC_OVERLAY_POSITION(0.002, -0.018) |
| 584 | 583 | |
| 585 | 584 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 586 | 585 | |
| 587 | MDRV_SOUND_ADD("l | |
| 586 | MDRV_SOUND_ADD("l | |
| 588 | 587 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 589 | 588 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 590 | 589 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 662 | 661 | ROM_REGION( 0x10000, "ldp_cpu", 0) |
| 663 | 662 | ROM_LOAD( "laser_player_interface_d8748_a308.bin", 0x0000, 0x0400, CRC(eed3e728) SHA1(1eb3467f1c41553375b2c21952cd593b167f5416) ) |
| 664 | 663 | |
| 665 | ROM_REGION16_BE( 0x1000, "sound | |
| 664 | ROM_REGION16_BE( 0x1000, "sound | |
| 666 | 665 | ROMX_LOAD( "mother_sounds_82s185.17f", 0x0, 0x800, CRC(0f49d40e) SHA1(40340833ab27ccb5b60baf44ad01930f204f5318), ROM_NIBBLE | ROM_SHIFT_NIBBLE_LO | ROM_SKIP(1) ) |
| 667 | 666 | ROMX_LOAD( "mother_sounds_82s185.19f", 0x0, 0x800, CRC(a041ce92) SHA1(9bc92992de22b830e479933c50650c7dc23f5713), ROM_NIBBLE | ROM_SHIFT_NIBBLE_HI | ROM_SKIP(1) ) |
| 668 | 667 | ROMX_LOAD( "mother_sounds_82s185.16f", 0x1, 0x800, CRC(75b1749f) SHA1(71da8224e72fb5250e2097666a47314d0a818ee9), ROM_NIBBLE | ROM_SHIFT_NIBBLE_LO | ROM_SKIP(1) ) |
| 669 | 668 | ROMX_LOAD( "mother_sounds_82s185.18f", 0x1, 0x800, CRC(ae4c78ae) SHA1(76fdb8eab372065882caaa5b93ce9e21efe54da5), ROM_NIBBLE | ROM_SHIFT_NIBBLE_HI | ROM_SKIP(1) ) |
| 670 | 669 | |
| 671 | ROM_REGION( 0x1000, "video | |
| 670 | ROM_REGION( 0x1000, "video | |
| 672 | 671 | /* Horizontal and vertical video timing PROMs */ |
| 673 | 672 | ROM_LOAD( "rotate_video_board_82s129.4h", 0x000, 0x100, CRC(6ed1b8d3) SHA1(c392855e1ff8637e551891aefd6c6a3bbcf273a5) ) |
| 674 | 673 | ROM_LOAD( "rotate_video_board_82s129.5h", 0x100, 0x100, CRC(32d839d4) SHA1(7b82e5c1ea5a351eba60c19560a10e4702ae2c22) ) |
| r3232 | r3233 | |
|---|---|---|
| 215 | 215 | |
| 216 | 216 | static READ16_HANDLER( io_chip_r ) |
| 217 | 217 | { |
| 218 | static const char *portnames[] = { "P1", "P2", "PORTC", "PORTD", "SERVICE", "COINAGE", "DSW", "PORTH" }; | |
| 218 | static const char *const portnames[] = { "P1", "P2", "PORTC", "PORTD", "SERVICE", "COINAGE", "DSW", "PORTH" }; | |
| 219 | 219 | offset &= 0x1f/2; |
| 220 | 220 | |
| 221 | 221 | switch (offset) |
| r3232 | r3233 | |
| 318 | 318 | |
| 319 | 319 | static READ16_HANDLER( misc_io_r ) |
| 320 | 320 | { |
| 321 | static const char *portnames[] = { "SERVICE", "COINAGE" }; | |
| 321 | static const char *const portnames[] = { "SERVICE", "COINAGE" }; | |
| 322 | 322 | |
| 323 | 323 | offset &= 0x1fff; |
| 324 | 324 |
| r3232 | r3233 | |
|---|---|---|
| 734 | 734 | return 0xff; |
| 735 | 735 | } |
| 736 | 736 | |
| 737 | static void mjtensin_update_rombank( | |
| 737 | static void mjtensin_update_rombank(running_machine *machine) | |
| 738 | 738 | { |
| 739 | memory_set_bankptr( 1, memory_region( | |
| 739 | memory_set_bankptr( 1, memory_region(machine, "main") + 0x10000 + rombank * 0x8000 ); | |
| 740 | 740 | } |
| 741 | 741 | static WRITE8_HANDLER( mjtensin_p4_w ) |
| 742 | 742 | { |
| 743 | 743 | rombank = (rombank & 0xf0) | (data & 0x0f); |
| 744 | mjtensin_update_rombank(); | |
| 744 | mjtensin_update_rombank(machine); | |
| 745 | 745 | } |
| 746 | 746 | static WRITE8_HANDLER( mjtensin_6ff3_w ) |
| 747 | 747 | { |
| 748 | 748 | rombank = (data << 4) | (rombank & 0x0f); |
| 749 | mjtensin_update_rombank(); | |
| 749 | mjtensin_update_rombank(machine); | |
| 750 | 750 | } |
| 751 | 751 | |
| 752 | 752 | static ADDRESS_MAP_START( mjtensin_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| r3232 | r3233 | |
| 776 | 776 | Mahjong Cafe Time |
| 777 | 777 | ****************************************************************************/ |
| 778 | 778 | |
| 779 | static void cafetime_update_rombank( | |
| 779 | static void cafetime_update_rombank(running_machine *machine) | |
| 780 | 780 | { |
| 781 | memory_set_bankptr( 1, memory_region( | |
| 781 | memory_set_bankptr( 1, memory_region(machine, "main") + 0x10000 + rombank * 0x8000 ); | |
| 782 | 782 | } |
| 783 | 783 | static WRITE8_HANDLER( cafetime_p4_w ) |
| 784 | 784 | { |
| 785 | 785 | rombank = (rombank & 0xf0) | (data & 0x0f); |
| 786 | cafetime_update_rombank(); | |
| 786 | cafetime_update_rombank(machine); | |
| 787 | 787 | } |
| 788 | 788 | static WRITE8_HANDLER( cafetime_p3_w ) |
| 789 | 789 | { |
| 790 | 790 | rombank = (rombank & 0x0f) | ((data & 0x0c) << 2); |
| 791 | cafetime_update_rombank(); | |
| 791 | cafetime_update_rombank(machine); | |
| 792 | 792 | } |
| 793 | 793 | |
| 794 | 794 | static WRITE8_HANDLER( cafetime_dsw_w ) |
| r3232 | r3233 | |
|---|---|---|
| 285 | 285 | |
| 286 | 286 | ROM_LOAD( "dm_16.rom", 0x10000, 0x08000, CRC(094579d9) SHA1(2449bc9ba38396912ee9b72dd870ea9fcff95776) ) |
| 287 | 287 | |
| 288 | ROM_REGION( 0x10000, " | |
| 288 | ROM_REGION( 0x10000, "t5182", 0 ) /* Toshiba T5182 module */ | |
| 289 | 289 | ROM_LOAD( "t5182.rom", 0x0000, 0x2000, CRC(d354c8fc) SHA1(a1c9e1ac293f107f69cc5788cf6abc3db1646e33) ) |
| 290 | 290 | ROM_LOAD( "dm_17.rom", 0x8000, 0x8000, CRC(7723dcae) SHA1(a0c69e7a7b6fd74f7ed6b9c6419aed94aabcd4b0) ) |
| 291 | 291 | |
| r3232 | r3233 | |
| 414 | 414 | static void decrypt_snd(running_machine *machine) |
| 415 | 415 | { |
| 416 | 416 | int i; |
| 417 | UINT8 *ROM = memory_region(machine, " | |
| 417 | UINT8 *ROM = memory_region(machine, "t5182"); | |
| 418 | 418 | |
| 419 | 419 | for(i=0x8000;i<0x10000;i++) |
| 420 | 420 | ROM[i] = BITSWAP8(ROM[i], 7,1,2,3,4,5,6,0); |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | |
| 14 | 14 | // MAME headers |
| 15 | 15 | #include "mamecore.h" |
| 16 | #include "deprecat.h" | |
| 16 | 17 | |
| 17 | 18 | // MAMEOS headers |
| 18 | 19 | #include "window.h" |
| r3232 | r3233 | |
|---|---|---|
| 14 | 14 | // MAME headers |
| 15 | 15 | #include "mamecore.h" |
| 16 | 16 | #include "restrack.h" |
| 17 | #include "deprecat.h" | |
| 17 | 18 | |
| 18 | 19 | // MAMEOS headers |
| 19 | 20 | #include "window.h" |
| r3232 | r3233 | |
|---|---|---|
| 939 | 939 | break; |
| 940 | 940 | |
| 941 | 941 | // add the device |
| 942 | devinfo->device = input_device_add(DEVICE_CLASS_LIGHTGUN, devinfo->name, devinfo); | |
| 942 | devinfo->device = input_device_add(machine, DEVICE_CLASS_LIGHTGUN, devinfo->name, devinfo); | |
| 943 | 943 | |
| 944 | 944 | // populate the axes |
| 945 | 945 | for (axisnum = 0; axisnum < 2; axisnum++) |
| r3232 | r3233 | |
| 1317 | 1317 | goto exit; |
| 1318 | 1318 | |
| 1319 | 1319 | // add the device |
| 1320 | devinfo->device = input_device_add(DEVICE_CLASS_KEYBOARD, devinfo->name, devinfo); | |
| 1320 | devinfo->device = input_device_add(Machine, DEVICE_CLASS_KEYBOARD, devinfo->name, devinfo); | |
| 1321 | 1321 | devinfo->poll = dinput_keyboard_poll; |
| 1322 | 1322 | |
| 1323 | 1323 | // populate it |
| r3232 | r3233 | |
| 1389 | 1389 | } |
| 1390 | 1390 | |
| 1391 | 1391 | // add the device |
| 1392 | devinfo->device = input_device_add(DEVICE_CLASS_MOUSE, devinfo->name, devinfo); | |
| 1392 | devinfo->device = input_device_add(Machine, DEVICE_CLASS_MOUSE, devinfo->name, devinfo); | |
| 1393 | 1393 | devinfo->poll = dinput_mouse_poll; |
| 1394 | 1394 | if (guninfo != NULL) |
| 1395 | 1395 | { |
| 1396 | guninfo->device = input_device_add(DEVICE_CLASS_LIGHTGUN, guninfo->name, guninfo); | |
| 1396 | guninfo->device = input_device_add(Machine, DEVICE_CLASS_LIGHTGUN, guninfo->name, guninfo); | |
| 1397 | 1397 | guninfo->poll = win32_lightgun_poll; |
| 1398 | 1398 | } |
| 1399 | 1399 | |
| r3232 | r3233 | |
| 1493 | 1493 | devinfo->dinput.caps.dwButtons = MIN(devinfo->dinput.caps.dwButtons, 128); |
| 1494 | 1494 | |
| 1495 | 1495 | // add the device |
| 1496 | devinfo->device = input_device_add(DEVICE_CLASS_JOYSTICK, devinfo->name, devinfo); | |
| 1496 | devinfo->device = input_device_add(Machine, DEVICE_CLASS_JOYSTICK, devinfo->name, devinfo); | |
| 1497 | 1497 | devinfo->poll = dinput_joystick_poll; |
| 1498 | 1498 | |
| 1499 | 1499 | // populate the axes |
| r3232 | r3233 | |
| 1926 | 1926 | return; |
| 1927 | 1927 | |
| 1928 | 1928 | // add the device |
| 1929 | devinfo->device = input_device_add(DEVICE_CLASS_KEYBOARD, devinfo->name, devinfo); | |
| 1929 | devinfo->device = input_device_add(Machine, DEVICE_CLASS_KEYBOARD, devinfo->name, devinfo); | |
| 1930 | 1930 | |
| 1931 | 1931 | // populate it |
| 1932 | 1932 | for (keynum = 0; keynum < MAX_KEYS; keynum++) |
| r3232 | r3233 | |
| 1999 | 1999 | } |
| 2000 | 2000 | |
| 2001 | 2001 | // add the device |
| 2002 | devinfo->device = input_device_add(DEVICE_CLASS_MOUSE, devinfo->name, devinfo); | |
| 2002 | devinfo->device = input_device_add(Machine, DEVICE_CLASS_MOUSE, devinfo->name, devinfo); | |
| 2003 | 2003 | if (guninfo != NULL) |
| 2004 | 2004 | { |
| 2005 | guninfo->device = input_device_add(DEVICE_CLASS_LIGHTGUN, guninfo->name, guninfo); | |
| 2005 | guninfo->device = input_device_add(Machine, DEVICE_CLASS_LIGHTGUN, guninfo->name, guninfo); | |
| 2006 | 2006 | guninfo->poll = (guninfo == lightgun_list) ? win32_lightgun_poll : NULL; |
| 2007 | 2007 | guninfo->mouse.partner = &devinfo->mouse; |
| 2008 | 2008 | } |
| r3232 | r3233 | |
|---|---|---|
| 382 | 382 | |
| 383 | 383 | // allocate memory |
| 384 | 384 | entry = malloc(sizeof(*entry)); |
| 385 | if (entry == NULL) | |
| 386 | return 0; | |
| 387 | ||
| 385 | 388 | string = malloc(strlen(data->string) + 1); |
| 389 | if (string == NULL) | |
| 390 | { | |
| 391 | free(entry); | |
| 392 | return 0; | |
| 393 | } | |
| 386 | 394 | |
| 387 | 395 | // if all allocations worked, make a new entry |
| 388 | if (entry != NULL && string != NULL) | |
| 389 | { | |
| 390 | entry->next = idmaplist; | |
| 391 | entry->name = string; | |
| 392 | entry->id = data->id; | |
| 396 | entry->next = idmaplist; | |
| 397 | entry->name = string; | |
| 398 | entry->id = data->id; | |
| 393 | 399 | |
| 394 | // copy the string and hook us into the list | |
| 395 | strcpy(string, data->string); | |
| 396 | idmaplist = entry; | |
| 400 | // copy the string and hook us into the list | |
| 401 | strcpy(string, data->string); | |
| 402 | idmaplist = entry; | |
| 397 | 403 | |
| 398 | DEBUG_PRINTF((" id %d = '%s'\n", entry->id, entry->name)); | |
| 399 | } | |
| 404 | DEBUG_PRINTF((" id %d = '%s'\n", entry->id, entry->name)); | |
| 400 | 405 | |
| 401 | 406 | return 0; |
| 402 | 407 | } |
| r3232 | r3233 | |
|---|---|---|
| 2460 | 2460 | |
| 2461 | 2461 | active_address = debug_view_get_property_UINT32(info->view[0].view, DVP_DASM_ACTIVE_ADDRESS); |
| 2462 | 2462 | sprintf(command, "go %X", BYTE2ADDR(active_address, cpuinfo, ADDRESS_SPACE_PROGRAM)); |
| 2463 | debug_console_execute_command(command, 1); | |
| 2463 | debug_console_execute_command(Machine, command, 1); | |
| 2464 | 2464 | } |
| 2465 | 2465 | return 1; |
| 2466 | 2466 | |
| r3232 | r3233 | |
| 2494 | 2494 | sprintf(command, "bpset %X", BYTE2ADDR(active_address, cpuinfo, ADDRESS_SPACE_PROGRAM)); |
| 2495 | 2495 | else |
| 2496 | 2496 | sprintf(command, "bpclear %X", bp_num); |
| 2497 | debug_console_execute_command(command, 1); | |
| 2497 | debug_console_execute_command(Machine, command, 1); | |
| 2498 | 2498 | } |
| 2499 | 2499 | return 1; |
| 2500 | 2500 | } |
| r3232 | r3233 | |
| 2768 | 2768 | |
| 2769 | 2769 | // otherwise, just process the command |
| 2770 | 2770 | else |
| 2771 | debug_console_execute_command(string, 1); | |
| 2771 | debug_console_execute_command(Machine, string, 1); | |
| 2772 | 2772 | |
| 2773 | 2773 | // clear the edit text box |
| 2774 | 2774 | SendMessage(info->editwnd, WM_SETTEXT, 0, (LPARAM)&buffer); |
| r3232 | r3233 | |
|---|---|---|
| 134 | 134 | static void create_window_class(void); |
| 135 | 135 | static void set_starting_view(running_machine *machine, int index, win_window_info *window, const char *view); |
| 136 | 136 | |
| 137 | static void constrain_to_aspect_ratio(win_window_info *window, RECT *rect, int adjustment); | |
| 138 | static void get_min_bounds(win_window_info *window, RECT *bounds, int constrain); | |
| 139 | static void get_max_bounds(win_window_info *window, RECT *bounds, int constrain); | |
| 140 | static void update_minmax_state(win_window_info *window); | |
| 141 | static void minimize_window(win_window_info *window); | |
| 142 | static void maximize_window(win_window_info *window); | |
| 137 | static void constrain_to_aspect_ratio(running_machine *machine, win_window_info *window, RECT *rect, int adjustment); | |
| 138 | static void get_min_bounds(running_machine *mchine, win_window_info *window, RECT *bounds, int constrain); | |
| 139 | static void get_max_bounds(running_machine *machine, win_window_info *window, RECT *bounds, int constrain); | |
| 140 | static void update_minmax_state(running_machine *machine, win_window_info *window); | |
| 141 | static void minimize_window(running_machine *machine, win_window_info *window); | |
| 142 | static void maximize_window(running_machine *machine, win_window_info *window); | |
| 143 | 143 | |
| 144 | static void adjust_window_position_after_major_change(win_window_info *window); | |
| 145 | static void set_fullscreen(win_window_info *window, int fullscreen); | |
| 144 | static void adjust_window_position_after_major_change(running_machine *machine, win_window_info *window); | |
| 145 | static void set_fullscreen(running_machine *machine, win_window_info *window, int fullscreen); | |
| 146 | 146 | |
| 147 | 147 | |
| 148 | 148 | // temporary hacks |
| r3232 | r3233 | |
| 223 | 223 | fatalerror("Failed to create window thread ready event"); |
| 224 | 224 | |
| 225 | 225 | // create a thread to run the windows from |
| 226 | temp = _beginthreadex(NULL, 0, thread_entry, | |
| 226 | temp = _beginthreadex(NULL, 0, thread_entry, (void*)machine, 0, (unsigned *)&window_threadid); | |
| 227 | 227 | window_thread = (HANDLE)temp; |
| 228 | 228 | if (window_thread == NULL) |
| 229 | 229 | fatalerror("Failed to create window thread"); |
| r3232 | r3233 | |
| 994 | 994 | static unsigned __stdcall thread_entry(void *param) |
| 995 | 995 | { |
| 996 | 996 | MSG message; |
| 997 | running_machine *machine = (running_machine*)param; | |
| 997 | 998 | |
| 998 | 999 | // make a bogus user call to make us a message thread |
| 999 | 1000 | PeekMessage(&message, NULL, 0, 0, PM_NOREMOVE); |
| r3232 | r3233 | |
| 1063 | 1064 | case WM_USER_FINISH_CREATE_WINDOW: |
| 1064 | 1065 | { |
| 1065 | 1066 | win_window_info *window = (win_window_info *)message.lParam; |
| 1066 | window->init_state = complete_create( | |
| 1067 | window->init_state = complete_create(machine, window) ? -1 : 1; | |
| 1067 | 1068 | dispatch = FALSE; |
| 1068 | 1069 | break; |
| 1069 | 1070 | } |
| r3232 | r3233 | |
| 1137 | 1138 | |
| 1138 | 1139 | // maximum or minimize as appropriate |
| 1139 | 1140 | if (window->startmaximized) |
| 1140 | maximize_window(window); | |
| 1141 | maximize_window(machine, window); | |
| 1141 | 1142 | else |
| 1142 | minimize_window(window); | |
| 1143 | adjust_window_position_after_major_change(window); | |
| 1143 | minimize_window(machine, window); | |
| 1144 | adjust_window_position_after_major_change(machine, window); | |
| 1144 | 1145 | |
| 1145 | 1146 | // show the window |
| 1146 | 1147 | if (!window->fullscreen || window->fullscreen_safe) |
| r3232 | r3233 | |
| 1175 | 1176 | if (window != NULL) |
| 1176 | 1177 | { |
| 1177 | 1178 | assert(GetCurrentThreadId() == window_threadid); |
| 1178 | update_minmax_state(window); | |
| 1179 | update_minmax_state(Machine, window); | |
| 1179 | 1180 | } |
| 1180 | 1181 | |
| 1181 | 1182 | // handle a few messages |
| r3232 | r3233 | |
| 1221 | 1222 | case WM_LBUTTONDOWN: |
| 1222 | 1223 | { |
| 1223 | 1224 | DWORD ticks = GetTickCount(); |
| 1224 | ui_input_push_mouse_ | |
| 1225 | ui_input_push_mouse_down | |
| 1225 | 1226 | |
| 1226 | 1227 | // check for a double-click |
| 1227 | 1228 | if (ticks - window->lastclicktime < GetDoubleClickTime() && |
| r3232 | r3233 | |
| 1240 | 1241 | break; |
| 1241 | 1242 | } |
| 1242 | 1243 | |
| 1244 | case WM_LBUTTONUP: | |
| 1245 | ui_input_push_mouse_up_event(Machine, window->target, GET_X_LPARAM(lparam), GET_Y_LPARAM(lparam)); | |
| 1246 | break; | |
| 1247 | ||
| 1243 | 1248 | case WM_CHAR: |
| 1244 | 1249 | ui_input_push_char_event(Machine, window->target, (unicode_char) wparam); |
| 1245 | 1250 | break; |
| r3232 | r3233 | |
| 1273 | 1278 | { |
| 1274 | 1279 | RECT *rect = (RECT *)lparam; |
| 1275 | 1280 | if (video_config.keepaspect && !(GetAsyncKeyState(VK_CONTROL) & 0x8000)) |
| 1276 | constrain_to_aspect_ratio(window, rect, wparam); | |
| 1281 | constrain_to_aspect_ratio(Machine, window, rect, wparam); | |
| 1277 | 1282 | InvalidateRect(wnd, NULL, FALSE); |
| 1278 | 1283 | break; |
| 1279 | 1284 | } |
| r3232 | r3233 | |
| 1291 | 1296 | // handle maximize |
| 1292 | 1297 | if ((wparam & 0xfff0) == SC_MAXIMIZE) |
| 1293 | 1298 | { |
| 1294 | update_minmax_state(window); | |
| 1299 | update_minmax_state(Machine, window); | |
| 1295 | 1300 | if (window->ismaximized) |
| 1296 | minimize_window(window); | |
| 1301 | minimize_window(Machine, window); | |
| 1297 | 1302 | else |
| 1298 | maximize_window(window); | |
| 1303 | maximize_window(Machine, window); | |
| 1299 | 1304 | break; |
| 1300 | 1305 | } |
| 1301 | 1306 | return DefWindowProc(wnd, message, wparam, lparam); |
| r3232 | r3233 | |
| 1341 | 1346 | |
| 1342 | 1347 | // fullscreen set |
| 1343 | 1348 | case WM_USER_SET_FULLSCREEN: |
| 1344 | set_fullscreen(window, wparam); | |
| 1349 | set_fullscreen(Machine, window, wparam); | |
| 1345 | 1350 | break; |
| 1346 | 1351 | |
| 1347 | 1352 | // minimum size set |
| 1348 | 1353 | case WM_USER_SET_MINSIZE: |
| 1349 | minimize_window(window); | |
| 1354 | minimize_window(Machine, window); | |
| 1350 | 1355 | break; |
| 1351 | 1356 | |
| 1352 | 1357 | // maximum size set |
| 1353 | 1358 | case WM_USER_SET_MAXSIZE: |
| 1354 | maximize_window(window); | |
| 1359 | maximize_window(Machine, window); | |
| 1355 | 1360 | break; |
| 1356 | 1361 | |
| 1357 | 1362 | // set focus: if we're not the primary window, switch back |
| r3232 | r3233 | |
| 1418 | 1423 | // (window thread) |
| 1419 | 1424 | //============================================================ |
| 1420 | 1425 | |
| 1421 | static void constrain_to_aspect_ratio(win_window_info *window, RECT *rect, int adjustment) | |
| 1426 | static void constrain_to_aspect_ratio(running_machine *machine, win_window_info *window, RECT *rect, int adjustment) | |
| 1422 | 1427 | { |
| 1423 | 1428 | win_monitor_info *monitor = winwindow_video_window_monitor(window, rect); |
| 1424 | 1429 | INT32 extrawidth = wnd_extra_width(window); |
| r3232 | r3233 | |
| 1534 | 1539 | // (window thread) |
| 1535 | 1540 | //============================================================ |
| 1536 | 1541 | |
| 1537 | static void get_min_bounds(win_window_info *window, RECT *bounds, int constrain) | |
| 1542 | static void get_min_bounds(running_machine *machine, win_window_info *window, RECT *bounds, int constrain) | |
| 1538 | 1543 | { |
| 1539 | 1544 | INT32 minwidth, minheight; |
| 1540 | 1545 | |
| r3232 | r3233 | |
| 1562 | 1567 | test1.top = test1.left = 0; |
| 1563 | 1568 | test1.right = minwidth; |
| 1564 | 1569 | test1.bottom = 10000; |
| 1565 | constrain_to_aspect_ratio(window, &test1, WMSZ_BOTTOMRIGHT); | |
| 1570 | constrain_to_aspect_ratio(machine, window, &test1, WMSZ_BOTTOMRIGHT); | |
| 1566 | 1571 | |
| 1567 | 1572 | // then constrain with no width limit |
| 1568 | 1573 | test2.top = test2.left = 0; |
| 1569 | 1574 | test2.right = 10000; |
| 1570 | 1575 | test2.bottom = minheight; |
| 1571 | constrain_to_aspect_ratio(window, &test2, WMSZ_BOTTOMRIGHT); | |
| 1576 | constrain_to_aspect_ratio(machine, window, &test2, WMSZ_BOTTOMRIGHT); | |
| 1572 | 1577 | |
| 1573 | 1578 | // pick the larger |
| 1574 | 1579 | if (rect_width(&test1) > rect_width(&test2)) |
| r3232 | r3233 | |
| 1598 | 1603 | // (window thread) |
| 1599 | 1604 | //============================================================ |
| 1600 | 1605 | |
| 1601 | static void get_max_bounds(win_window_info *window, RECT *bounds, int constrain) | |
| 1606 | static void get_max_bounds(running_machine *machine, win_window_info *window, RECT *bounds, int constrain) | |
| 1602 | 1607 | { |
| 1603 | 1608 | RECT maximum; |
| 1604 | 1609 | |
| r3232 | r3233 | |
| 1624 | 1629 | |
| 1625 | 1630 | // constrain to fit |
| 1626 | 1631 | if (constrain) |
| 1627 | constrain_to_aspect_ratio(window, &maximum, WMSZ_BOTTOMRIGHT); | |
| 1632 | constrain_to_aspect_ratio(machine, window, &maximum, WMSZ_BOTTOMRIGHT); | |
| 1628 | 1633 | else |
| 1629 | 1634 | { |
| 1630 | 1635 | maximum.right -= wnd_extra_width(window); |
| r3232 | r3233 | |
| 1645 | 1650 | // (window thread) |
| 1646 | 1651 | //============================================================ |
| 1647 | 1652 | |
| 1648 | static void update_minmax_state(win_window_info *window) | |
| 1653 | static void update_minmax_state(running_machine *machine, win_window_info *window) | |
| 1649 | 1654 | { |
| 1650 | 1655 | assert(GetCurrentThreadId() == window_threadid); |
| 1651 | 1656 | |
| r3232 | r3233 | |
| 1654 | 1659 | RECT bounds, minbounds, maxbounds; |
| 1655 | 1660 | |
| 1656 | 1661 | // compare the maximum bounds versus the current bounds |
| 1657 | get_min_bounds(window, &minbounds, video_config.keepaspect); | |
| 1658 | get_max_bounds(window, &maxbounds, video_config.keepaspect); | |
| 1662 | get_min_bounds(machine, window, &minbounds, video_config.keepaspect); | |
| 1663 | get_max_bounds(machine, window, &maxbounds, video_config.keepaspect); | |
| 1659 | 1664 | GetWindowRect(window->hwnd, &bounds); |
| 1660 | 1665 | |
| 1661 | 1666 | // if either the width or height matches, we were maximized |
| r3232 | r3233 | |
| 1678 | 1683 | // (window thread) |
| 1679 | 1684 | //============================================================ |
| 1680 | 1685 | |
| 1681 | static void minimize_window(win_window_info *window) | |
| 1686 | static void minimize_window(running_machine *machine, win_window_info *window) | |
| 1682 | 1687 | { |
| 1683 | 1688 | RECT newsize; |
| 1684 | 1689 | |
| 1685 | 1690 | assert(GetCurrentThreadId() == window_threadid); |
| 1686 | 1691 | |
| 1687 | get_min_bounds(window, &newsize, video_config.keepaspect); | |
| 1692 | get_min_bounds(machine, window, &newsize, video_config.keepaspect); | |
| 1688 | 1693 | SetWindowPos(window->hwnd, NULL, newsize.left, newsize.top, rect_width(&newsize), rect_height(&newsize), SWP_NOZORDER); |
| 1689 | 1694 | } |
| 1690 | 1695 | |
| r3232 | r3233 | |
| 1695 | 1700 | // (window thread) |
| 1696 | 1701 | //============================================================ |
| 1697 | 1702 | |
| 1698 | static void maximize_window(win_window_info *window) | |
| 1703 | static void maximize_window(running_machine *machine, win_window_info *window) | |
| 1699 | 1704 | { |
| 1700 | 1705 | RECT newsize; |
| 1701 | 1706 | |
| 1702 | 1707 | assert(GetCurrentThreadId() == window_threadid); |
| 1703 | 1708 | |
| 1704 | get_max_bounds(window, &newsize, video_config.keepaspect); | |
| 1709 | get_max_bounds(machine, window, &newsize, video_config.keepaspect); | |
| 1705 | 1710 | SetWindowPos(window->hwnd, NULL, newsize.left, newsize.top, rect_width(&newsize), rect_height(&newsize), SWP_NOZORDER); |
| 1706 | 1711 | } |
| 1707 | 1712 | |
| r3232 | r3233 | |
| 1712 | 1717 | // (window thread) |
| 1713 | 1718 | //============================================================ |
| 1714 | 1719 | |
| 1715 | static void adjust_window_position_after_major_change(win_window_info *window) | |
| 1720 | static void adjust_window_position_after_major_change(running_machine *machine, win_window_info *window) | |
| 1716 | 1721 | { |
| 1717 | 1722 | RECT oldrect, newrect; |
| 1718 | 1723 | |
| r3232 | r3233 | |
| 1727 | 1732 | // constrain the existing size to the aspect ratio |
| 1728 | 1733 | newrect = oldrect; |
| 1729 | 1734 | if (video_config.keepaspect) |
| 1730 | constrain_to_aspect_ratio(window, &newrect, WMSZ_BOTTOMRIGHT); | |
| 1735 | constrain_to_aspect_ratio(machine, window, &newrect, WMSZ_BOTTOMRIGHT); | |
| 1731 | 1736 | } |
| 1732 | 1737 | |
| 1733 | 1738 | // in full screen, make sure it covers the primary display |
| r3232 | r3233 | |
| 1760 | 1765 | // (window thread) |
| 1761 | 1766 | //============================================================ |
| 1762 | 1767 | |
| 1763 | static void set_fullscreen(win_window_info *window, int fullscreen) | |
| 1768 | static void set_fullscreen(running_machine *machine, win_window_info *window, int fullscreen) | |
| 1764 | 1769 | { |
| 1765 | 1770 | assert(GetCurrentThreadId() == window_threadid); |
| 1766 | 1771 | |
| r3232 | r3233 | |
| 1799 | 1804 | else |
| 1800 | 1805 | { |
| 1801 | 1806 | SetWindowPos(window->hwnd, HWND_TOP, 0, 0, MIN_WINDOW_DIM, MIN_WINDOW_DIM, SWP_NOZORDER); |
| 1802 | maximize_window(window); | |
| 1807 | maximize_window(machine, window); | |
| 1803 | 1808 | } |
| 1804 | 1809 | } |
| 1805 | 1810 | |
| r3232 | r3233 | |
| 1819 | 1824 | } |
| 1820 | 1825 | |
| 1821 | 1826 | // adjust the window to compensate for the change |
| 1822 | adjust_window_position_after_major_change(window); | |
| 1827 | adjust_window_position_after_major_change(machine, window); | |
| 1823 | 1828 | |
| 1824 | 1829 | // show ourself |
| 1825 | 1830 | if (!window->fullscreen || window->fullscreen_safe) |
| r3232 | r3233 | |
| 1831 | 1836 | } |
| 1832 | 1837 | |
| 1833 | 1838 | // ensure we're still adjusted correctly |
| 1834 | adjust_window_position_after_major_change(window); | |
| 1839 | adjust_window_position_after_major_change(machine, window); | |
| 1835 | 1840 | } |
| r3232 | r3233 | |
|---|---|---|
| 354 | 354 | for (ndriver = 0; ndriver < driver_list_get_count(drivers); ndriver++) |
| 355 | 355 | { |
| 356 | 356 | const game_driver *gamedrv = drivers[ndriver]; |
| 357 | const rom_source *source; | |
| 357 | 358 | struct DriversInfo *gameinfo = &drivers_info[ndriver]; |
| 358 | 359 | const rom_entry *region, *rom; |
| 359 | 360 | machine_config *config; |
| r3232 | r3233 | |
| 368 | 369 | gameinfo->supportsSaveState = ((gamedrv->flags & GAME_SUPPORTS_SAVE) != 0); |
| 369 | 370 | gameinfo->isHarddisk = FALSE; |
| 370 | 371 | gameinfo->isVertical = (gamedrv->flags & ORIENTATION_SWAP_XY) ? TRUE : FALSE; |
| 371 | for (re | |
| 372 | for (source | |
| 372 | 373 | { |
| 373 | if (ROMREGION_ISDISKDATA(region)) | |
| 374 | gameinfo->isHarddisk = TRUE; | |
| 374 | for (region = rom_first_region(gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 375 | { | |
| 376 | if (ROMREGION_ISDISKDATA(region)) | |
| 377 | gameinfo->isHarddisk = TRUE; | |
| 378 | } | |
| 375 | 379 | } |
| 376 | 380 | gameinfo->hasOptionalBIOS = FALSE; |
| 377 | 381 | if (gamedrv->rom != NULL) |
| r3232 | r3233 | |
| 394 | 398 | gameinfo->isMultiMon = 0; |
| 395 | 399 | gameinfo->isVector = isDriverVector(config); // ((drv.video_attributes & VIDEO_TYPE_VECTOR) != 0); |
| 396 | 400 | gameinfo->usesRoms = FALSE; |
| 397 | for (region = rom_first_region(gamedrv); region; region = rom_next_region(region)) | |
| 398 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 401 | for (source = rom_first_source(gamedrv, config); source != NULL; source = rom_next_source(gamedrv, config, source)) | |
| 402 | { | |
| 403 | for (region = rom_first_region(gamedrv, source); region; region = rom_next_region(region)) | |
| 399 | 404 | { |
| 400 | gameinfo->usesRoms = TRUE; | |
| 401 | break; | |
| 405 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 406 | { | |
| 407 | gameinfo->usesRoms = TRUE; | |
| 408 | break; | |
| 409 | } | |
| 402 | 410 | } |
| 411 | } | |
| 403 | 412 | gameinfo->usesSamples = FALSE; |
| 404 | 413 | |
| 405 | 414 | if (HAS_SAMPLES || HAS_VLM5030) |
| r3232 | r3233 | |
|---|---|---|
| 1134 | 1134 | const rom_entry *region, *rom; |
| 1135 | 1135 | const char *name; |
| 1136 | 1136 | const game_driver *gamedrv; |
| 1137 | const rom_source *source; | |
| 1138 | machine_config *config; | |
| 1137 | 1139 | |
| 1138 | 1140 | // create our two subfolders |
| 1139 | 1141 | LPTREEFOLDER lpBad, lpNo; |
| r3232 | r3233 | |
| 1173 | 1175 | continue; |
| 1174 | 1176 | bBadDump = FALSE; |
| 1175 | 1177 | bNoDump = FALSE; |
| 1176 | for (region = rom_first_region(gamedrv); region; region = rom_next_region(region)) | |
| 1178 | config = machine_config_alloc(gamedrv->machine_config); | |
| 1179 | for (source = rom_first_source(gamedrv, config); source != NULL; source = rom_next_source(gamedrv, config, source)) | |
| 1177 | 1180 | { |
| 1178 | for (ro | |
| 1181 | for (region = rom_first_ | |
| 1179 | 1182 | { |
| 1180 | | |
| 1183 | | |
| 1181 | 1184 | { |
| 1182 | name = ROM_GETNAME(rom); | |
| 1183 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP)) | |
| 1184 | bBadDump = TRUE; | |
| 1185 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 1186 | bNoDump = TRUE; | |
| 1185 | if (ROMREGION_ISROMDATA(region) || ROMREGION_ISDISKDATA(region) ) | |
| 1186 | { | |
| 1187 | name = ROM_GETNAME(rom); | |
| 1188 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP)) | |
| 1189 | bBadDump = TRUE; | |
| 1190 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 1191 | bNoDump = TRUE; | |
| 1192 | } | |
| 1187 | 1193 | } |
| 1188 | 1194 | } |
| 1189 | 1195 | } |
| 1196 | machine_config_free(config); | |
| 1197 | config = NULL; | |
| 1190 | 1198 | if (bBadDump) |
| 1191 | 1199 | { |
| 1192 | 1200 | AddGame(lpBad,jj); |
| r3232 | r3233 | |
|---|---|---|
| 68 | 68 | #define ROMREGION_DATATYPEROM 0x00000000 |
| 69 | 69 | #define ROMREGION_DATATYPEDISK 0x00004000 |
| 70 | 70 | |
| 71 | #define ROMREGION_LOADBYNAMEMASK 0x00008000 /* use region name as path to read from */ | |
| 72 | #define ROMREGION_NOLOADBYNAME 0x00000000 | |
| 73 | #define ROMREGION_LOADBYNAME 0x00008000 | |
| 74 | ||
| 71 | 75 | #define ROMREGION_ERASEVALMASK 0x00ff0000 /* value to erase the region to */ |
| 72 | 76 | #define ROMREGION_ERASEVAL(x) ((((x) & 0xff) << 16) | ROMREGION_ERASE) |
| 73 | 77 | #define ROMREGION_ERASE00 ROMREGION_ERASEVAL(0) |
| r3232 | r3233 | |
| 122 | 126 | TYPE DEFINITIONS |
| 123 | 127 | ***************************************************************************/ |
| 124 | 128 | |
| 129 | typedef struct _rom_source rom_source; | |
| 130 | ||
| 131 | ||
| 125 | 132 | typedef struct _rom_entry rom_entry; |
| 126 | 133 | struct _rom_entry |
| 127 | 134 | { |
| r3232 | r3233 | |
| 185 | 192 | #define ROMREGION_GETDATATYPE(r) (ROMREGION_GETFLAGS(r) & ROMREGION_DATATYPEMASK) |
| 186 | 193 | #define ROMREGION_ISROMDATA(r) (ROMREGION_GETDATATYPE(r) == ROMREGION_DATATYPEROM) |
| 187 | 194 | #define ROMREGION_ISDISKDATA(r) (ROMREGION_GETDATATYPE(r) == ROMREGION_DATATYPEDISK) |
| 195 | #define ROMREGION_ISLOADBYNAME(r) ((ROMREGION_GETFLAGS(r) & ROMREGION_LOADBYNAMEMASK) == ROMREGION_LOADBYNAME) | |
| 188 | 196 | |
| 189 | 197 | |
| 190 | 198 | /* ----- per-ROM macros ----- */ |
| r3232 | r3233 | |
| 283 | 291 | void set_disk_handle(const char *region, mame_file *file, chd_file *chd); |
| 284 | 292 | |
| 285 | 293 | /* ROM processing */ |
| 286 | void rom_init(running_machine *machine | |
| 294 | void rom_init(running_machine *machine | |
| 287 | 295 | int rom_load_warnings(void); |
| 288 | const rom_entry *rom_first_region(const game_driver *drv); | |
| 296 | const rom_source *rom_first_source(const game_driver *drv, const machine_config *config); | |
| 297 | const rom_source *rom_next_source(const game_driver *drv, const machine_config *config, const rom_source *previous); | |
| 298 | const rom_entry *rom_first_region(const game_driver *drv, const rom_source *romp); | |
| 289 | 299 | const rom_entry *rom_next_region(const rom_entry *romp); |
| 290 | 300 | const rom_entry *rom_first_file(const rom_entry *romp); |
| 291 | 301 | const rom_entry *rom_next_file(const rom_entry *romp); |
| 292 | 302 | const rom_entry *rom_first_chunk(const rom_entry *romp); |
| 293 | 303 | const rom_entry *rom_next_chunk(const rom_entry *romp); |
| 294 | 304 | |
| 305 | int rom_source_is_gamedrv(const game_driver *drv, const rom_source *source); | |
| 306 | astring *rom_region_name(astring *result, const game_driver *drv, const rom_source *source, const rom_entry *romp); | |
| 295 | 307 | |
| 296 | 308 | #endif /* __ROMLOAD_H__ */ |
| r3232 | r3233 | |
|---|---|---|
| 59 | 59 | UINT8 within_instruction_hook; |
| 60 | 60 | UINT8 vblank_occurred; |
| 61 | 61 | UINT8 memory_modified; |
| 62 | UINT8 debugger_access; | |
| 62 | 63 | |
| 63 | 64 | int execution_state; |
| 64 | 65 | |
| r3232 | r3233 | |
| 90 | 91 | ***************************************************************************/ |
| 91 | 92 | |
| 92 | 93 | static void debug_cpu_exit(running_machine *machine); |
| 93 | static void perform_trace(debug_cpu_info *info); | |
| 94 | static void perform_trace(running_machine *machine, debug_cpu_info *info); | |
| 94 | 95 | static void prepare_for_step_overout(debug_cpu_info *info); |
| 95 | static void process_source_file(void); | |
| 96 | static void breakpoint_check(debug_cpu_info *info, offs_t pc); | |
| 96 | static void process_source_file(running_machine *machine); | |
| 97 | static void breakpoint_check(running_machine *machine, debug_cpu_info *info, offs_t pc); | |
| 97 | 98 | static void watchpoint_check(running_machine *machine, int cpunum, int spacenum, int type, offs_t address, UINT64 value_to_write, UINT64 mem_mask); |
| 98 | 99 | static void check_hotspots(int cpunum, int spacenum, offs_t address); |
| 99 | 100 | |
| r3232 | r3233 | |
| 158 | 159 | on_vblank - called when a VBLANK hits |
| 159 | 160 | -------------------------------------------------*/ |
| 160 | 161 | |
| 161 | static void on_vblank(const device_config *device, int vblank_state) | |
| 162 | static void on_vblank(const device_config *device, void *param, int vblank_state) | |
| 162 | 163 | { |
| 163 | 164 | /* just set a global flag to be consumed later */ |
| 164 | 165 | if (vblank_state) |
| r3232 | r3233 | |
| 300 | 301 | |
| 301 | 302 | /* add callback for breaking on VBLANK */ |
| 302 | 303 | if (machine->primary_screen != NULL) |
| 303 | video_screen_register_vblank_callback(machine->primary_screen, on_vblank); | |
| 304 | video_screen_register_vblank_callback(machine->primary_screen, on_vblank, NULL); | |
| 304 | 305 | |
| 305 | 306 | add_exit_callback(machine, debug_cpu_exit); |
| 306 | 307 | } |
| r3232 | r3233 | |
| 383 | 384 | |
| 384 | 385 | /* if any of the watchpoint flags are set and we're live, tell the memory system */ |
| 385 | 386 | if (global.livecpu != NULL && ((info->flags & DEBUG_FLAG_WATCHPOINT) != 0)) |
| 386 | memory_set_context(-1); | |
| 387 | memory_set_context(machine, -1); | |
| 387 | 388 | } |
| 388 | 389 | |
| 389 | 390 | |
| r3232 | r3233 | |
| 532 | 533 | |
| 533 | 534 | /* are we tracing? */ |
| 534 | 535 | if (info->flags & DEBUG_FLAG_TRACING_ANY) |
| 535 | perform_trace(info); | |
| 536 | perform_trace(machine, info); | |
| 536 | 537 | |
| 537 | 538 | /* per-instruction hook? */ |
| 538 | 539 | if (global.execution_state != EXECUTION_STATE_STOPPED && (info->flags & DEBUG_FLAG_HOOKED) != 0 && (*info->instrhook)(curpc)) |
| r3232 | r3233 | |
| 580 | 581 | |
| 581 | 582 | /* check for execution breakpoints */ |
| 582 | 583 | else if ((info->flags & DEBUG_FLAG_LIVE_BP) != 0) |
| 583 | breakpoint_check(info, curpc); | |
| 584 | breakpoint_check(machine, info, curpc); | |
| 584 | 585 | } |
| 585 | 586 | |
| 586 | 587 | /* if we are supposed to halt, do it now */ |
| r3232 | r3233 | |
| 612 | 613 | } |
| 613 | 614 | |
| 614 | 615 | /* check for commands in the source file */ |
| 615 | process_source_file(); | |
| 616 | process_source_file(machine); | |
| 616 | 617 | |
| 617 | 618 | /* if an event got scheduled, resume */ |
| 618 | 619 | if (mame_is_scheduled_event_pending(machine)) |
| r3232 | r3233 | |
| 975 | 976 | } |
| 976 | 977 | |
| 977 | 978 | |
| 978 | static void perform_trace(debug_cpu_info *info) | |
| 979 | static void perform_trace(running_machine *machine, debug_cpu_info *info) | |
| 979 | 980 | { |
| 980 | 981 | offs_t pc = activecpu_get_pc(); |
| 981 | 982 | int offset, count, i; |
| r3232 | r3233 | |
| 1005 | 1006 | |
| 1006 | 1007 | /* execute any trace actions first */ |
| 1007 | 1008 | if (info->trace.action != NULL) |
| 1008 | debug_console_execute_command(info->trace.action, 0); | |
| 1009 | debug_console_execute_command(machine, info->trace.action, 0); | |
| 1009 | 1010 | |
| 1010 | 1011 | /* print the address */ |
| 1011 | 1012 | offset = sprintf(buffer, "%0*X: ", info->space[ADDRESS_SPACE_PROGRAM].logchars, pc); |
| r3232 | r3233 | |
| 1082 | 1083 | a source file |
| 1083 | 1084 | -------------------------------------------------*/ |
| 1084 | 1085 | |
| 1085 | static void process_source_file( | |
| 1086 | static void process_source_file(running_machine *machine) | |
| 1086 | 1087 | { |
| 1087 | 1088 | /* loop until the file is exhausted or until we are executing again */ |
| 1088 | 1089 | while (debug_source_file != NULL && global.execution_state == EXECUTION_STATE_STOPPED) |
| r3232 | r3233 | |
| 1115 | 1116 | |
| 1116 | 1117 | /* execute the command */ |
| 1117 | 1118 | if (buf[0]) |
| 1118 | debug_console_execute_command(buf, 1); | |
| 1119 | debug_console_execute_command(machine, buf, 1); | |
| 1119 | 1120 | } |
| 1120 | 1121 | } |
| 1121 | 1122 | |
| r3232 | r3233 | |
| 1172 | 1173 | a given CPU |
| 1173 | 1174 | -------------------------------------------------*/ |
| 1174 | 1175 | |
| 1175 | static void breakpoint_check(debug_cpu_info *info, offs_t pc) | |
| 1176 | static void breakpoint_check(running_machine *machine, debug_cpu_info *info, offs_t pc) | |
| 1176 | 1177 | { |
| 1177 | 1178 | debug_cpu_breakpoint *bp; |
| 1178 | 1179 | UINT64 result; |
| r3232 | r3233 | |
| 1189 | 1190 | |
| 1190 | 1191 | /* if we hit, evaluate the action */ |
| 1191 | 1192 | if (bp->action != NULL) |
| 1192 | debug_console_execute_command(bp->action, 0); | |
| 1193 | debug_console_execute_command(machine, bp->action, 0); | |
| 1193 | 1194 | |
| 1194 | 1195 | /* print a notification, unless the action made us go again */ |
| 1195 | 1196 | if (global.execution_state == EXECUTION_STATE_STOPPED) |
| r3232 | r3233 | |
| 1361 | 1362 | UINT64 result; |
| 1362 | 1363 | |
| 1363 | 1364 | /* if we're within debugger code, don't stop */ |
| 1364 | if (global.within_instruction_hook) | |
| 1365 | if (global.within_instruction_hook || global.debugger_access) | |
| 1365 | 1366 | return; |
| 1366 | 1367 | |
| 1367 | 1368 | global.within_instruction_hook = TRUE; |
| r3232 | r3233 | |
| 1408 | 1409 | |
| 1409 | 1410 | /* if we hit, evaluate the action */ |
| 1410 | 1411 | if (wp->action != NULL) |
| 1411 | debug_console_execute_command(wp->action, 0); | |
| 1412 | debug_console_execute_command(machine, wp->action, 0); | |
| 1412 | 1413 | |
| 1413 | 1414 | /* print a notification, unless the action made us go again */ |
| 1414 | 1415 | if (global.execution_state == EXECUTION_STATE_STOPPED) |
| r3232 | r3233 | |
| 1642 | 1643 | address &= info->space[spacenum].logbytemask; |
| 1643 | 1644 | |
| 1644 | 1645 | /* all accesses from this point on are for the debugger */ |
| 1645 | memory_set_debugger_access( | |
| 1646 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1646 | 1647 | |
| 1647 | 1648 | /* translate if necessary; if not mapped, return 0xff */ |
| 1648 | 1649 | if (apply_translation && info->translate != NULL && !(*info->translate)(spacenum, TRANSLATE_READ_DEBUG, &address)) |
| r3232 | r3233 | |
| 1657 | 1658 | result = (*active_address_space[spacenum].accessors->read_byte)(address); |
| 1658 | 1659 | |
| 1659 | 1660 | /* no longer accessing via the debugger */ |
| 1660 | memory_set_debugger_access( | |
| 1661 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1661 | 1662 | return result; |
| 1662 | 1663 | } |
| 1663 | 1664 | |
| r3232 | r3233 | |
| 1693 | 1694 | else |
| 1694 | 1695 | { |
| 1695 | 1696 | /* all accesses from this point on are for the debugger */ |
| 1696 | memory_set_debugger_access( | |
| 1697 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1697 | 1698 | |
| 1698 | 1699 | /* translate if necessary; if not mapped, return 0xffff */ |
| 1699 | 1700 | if (apply_translation && info->translate != NULL && !(*info->translate)(spacenum, TRANSLATE_READ_DEBUG, &address)) |
| r3232 | r3233 | |
| 1708 | 1709 | result = (*active_address_space[spacenum].accessors->read_word)(address); |
| 1709 | 1710 | |
| 1710 | 1711 | /* no longer accessing via the debugger */ |
| 1711 | memory_set_debugger_access( | |
| 1712 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1712 | 1713 | } |
| 1713 | 1714 | |
| 1714 | 1715 | return result; |
| r3232 | r3233 | |
| 1746 | 1747 | else |
| 1747 | 1748 | { |
| 1748 | 1749 | /* all accesses from this point on are for the debugger */ |
| 1749 | memory_set_debugger_access( | |
| 1750 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1750 | 1751 | |
| 1751 | 1752 | /* translate if necessary; if not mapped, return 0xffffffff */ |
| 1752 | 1753 | if (apply_translation && info->translate != NULL && !(*info->translate)(spacenum, TRANSLATE_READ_DEBUG, &address)) |
| r3232 | r3233 | |
| 1761 | 1762 | result = (*active_address_space[spacenum].accessors->read_dword)(address); |
| 1762 | 1763 | |
| 1763 | 1764 | /* no longer accessing via the debugger */ |
| 1764 | memory_set_debugger_access( | |
| 1765 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1765 | 1766 | } |
| 1766 | 1767 | |
| 1767 | 1768 | return result; |
| r3232 | r3233 | |
| 1799 | 1800 | else |
| 1800 | 1801 | { |
| 1801 | 1802 | /* all accesses from this point on are for the debugger */ |
| 1802 | memory_set_debugger_access( | |
| 1803 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1803 | 1804 | |
| 1804 | 1805 | /* translate if necessary; if not mapped, return 0xffffffffffffffff */ |
| 1805 | 1806 | if (apply_translation && info->translate != NULL && !(*info->translate)(spacenum, TRANSLATE_READ_DEBUG, &address)) |
| r3232 | r3233 | |
| 1814 | 1815 | result = (*active_address_space[spacenum].accessors->read_qword)(address); |
| 1815 | 1816 | |
| 1816 | 1817 | /* no longer accessing via the debugger */ |
| 1817 | memory_set_debugger_access( | |
| 1818 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1818 | 1819 | } |
| 1819 | 1820 | |
| 1820 | 1821 | return result; |
| r3232 | r3233 | |
| 1834 | 1835 | address &= info->space[spacenum].logbytemask; |
| 1835 | 1836 | |
| 1836 | 1837 | /* all accesses from this point on are for the debugger */ |
| 1837 | memory_set_debugger_access( | |
| 1838 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1838 | 1839 | |
| 1839 | 1840 | /* translate if necessary; if not mapped, we're done */ |
| 1840 | 1841 | if (apply_translation && info->translate != NULL && !(*info->translate)(spacenum, TRANSLATE_WRITE_DEBUG, &address)) |
| r3232 | r3233 | |
| 1849 | 1850 | (*active_address_space[spacenum].accessors->write_byte)(address, data); |
| 1850 | 1851 | |
| 1851 | 1852 | /* no longer accessing via the debugger */ |
| 1852 | memory_set_debugger_access( | |
| 1853 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1853 | 1854 | global.memory_modified = TRUE; |
| 1854 | 1855 | } |
| 1855 | 1856 | |
| r3232 | r3233 | |
| 1885 | 1886 | else |
| 1886 | 1887 | { |
| 1887 | 1888 | /* all accesses from this point on are for the debugger */ |
| 1888 | memory_set_debugger_access( | |
| 1889 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1889 | 1890 | |
| 1890 | 1891 | /* translate if necessary; if not mapped, we're done */ |
| 1891 | 1892 | if (apply_translation && info->translate && !(*info->translate)(spacenum, TRANSLATE_WRITE_DEBUG, &address)) |
| r3232 | r3233 | |
| 1900 | 1901 | (*active_address_space[spacenum].accessors->write_word)(address, data); |
| 1901 | 1902 | |
| 1902 | 1903 | /* no longer accessing via the debugger */ |
| 1903 | memory_set_debugger_access( | |
| 1904 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1904 | 1905 | global.memory_modified = TRUE; |
| 1905 | 1906 | } |
| 1906 | 1907 | } |
| r3232 | r3233 | |
| 1937 | 1938 | else |
| 1938 | 1939 | { |
| 1939 | 1940 | /* all accesses from this point on are for the debugger */ |
| 1940 | memory_set_debugger_access( | |
| 1941 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1941 | 1942 | |
| 1942 | 1943 | /* translate if necessary; if not mapped, we're done */ |
| 1943 | 1944 | if (apply_translation && info->translate && !(*info->translate)(spacenum, TRANSLATE_WRITE_DEBUG, &address)) |
| r3232 | r3233 | |
| 1952 | 1953 | (*active_address_space[spacenum].accessors->write_dword)(address, data); |
| 1953 | 1954 | |
| 1954 | 1955 | /* no longer accessing via the debugger */ |
| 1955 | memory_set_debugger_access( | |
| 1956 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 1956 | 1957 | global.memory_modified = TRUE; |
| 1957 | 1958 | } |
| 1958 | 1959 | } |
| r3232 | r3233 | |
| 1988 | 1989 | else |
| 1989 | 1990 | { |
| 1990 | 1991 | /* all accesses from this point on are for the debugger */ |
| 1991 | memory_set_debugger_access( | |
| 1992 | memory_set_debugger_access(global.debugger_access = TRUE); | |
| 1992 | 1993 | |
| 1993 | 1994 | /* translate if necessary; if not mapped, we're done */ |
| 1994 | 1995 | if (apply_translation && info->translate && !(*info->translate)(spacenum, TRANSLATE_WRITE_DEBUG, &address)) |
| r3232 | r3233 | |
| 2003 | 2004 | (*active_address_space[spacenum].accessors->write_qword)(address, data); |
| 2004 | 2005 | |
| 2005 | 2006 | /* no longer accessing via the debugger */ |
| 2006 | memory_set_debugger_access( | |
| 2007 | memory_set_debugger_access(global.debugger_access = FALSE); | |
| 2007 | 2008 | global.memory_modified = TRUE; |
| 2008 | 2009 | } |
| 2009 | 2010 | } |
| r3232 | r3233 | |
| 2110 | 2111 | /* get pointer to data */ |
| 2111 | 2112 | /* note that we query aligned to the bus width, and then add back the low bits */ |
| 2112 | 2113 | lowbits_mask = info->space[ADDRESS_SPACE_PROGRAM].databytes - 1; |
| 2113 | ptr = memory_get_op_ptr(cpu_getactivecpu(), address & ~lowbits_mask, arg); | |
| 2114 | ptr = memory_get_op_ptr(Machine, cpu_getactivecpu(), address & ~lowbits_mask, arg); | |
| 2114 | 2115 | if (!ptr) |
| 2115 | 2116 | return ~(UINT64)0 & (~(UINT64)0 >> (64 - 8*size)); |
| 2116 | 2117 | ptr = (UINT8 *)ptr + (address & lowbits_mask); |
| r3232 | r3233 | |
| 2264 | 2265 | |
| 2265 | 2266 | /* get the base of memory, aligned to the address minus the lowbits */ |
| 2266 | 2267 | if (opcode & 1) |
| 2267 | base = memory_get_op_ptr(cpuindex, address & ~lowmask, FALSE); | |
| 2268 | base = memory_get_op_ptr(Machine, cpuindex, address & ~lowmask, FALSE); | |
| 2268 | 2269 | else |
| 2269 | 2270 | base = memory_get_read_ptr(cpuindex, ADDRESS_SPACE_PROGRAM, address & ~lowmask); |
| 2270 | 2271 | |
| r3232 | r3233 | |
| 2478 | 2479 | |
| 2479 | 2480 | /* get the base of memory, aligned to the address minus the lowbits */ |
| 2480 | 2481 | if (opcode & 1) |
| 2481 | base = memory_get_op_ptr(cpuindex, address & ~lowmask, FALSE); | |
| 2482 | base = memory_get_op_ptr(Machine, cpuindex, address & ~lowmask, FALSE); | |
| 2482 | 2483 | else |
| 2483 | 2484 | base = memory_get_read_ptr(cpuindex, ADDRESS_SPACE_PROGRAM, address & ~lowmask); |
| 2484 | 2485 |
| r3232 | r3233 | |
|---|---|---|
| 18 | 18 | #include "debughlp.h" |
| 19 | 19 | #include "debugvw.h" |
| 20 | 20 | #include "render.h" |
| 21 | #include "deprecat.h" | |
| 22 | 21 | #include <ctype.h> |
| 23 | 22 | |
| 24 | 23 | |
| r3232 | r3233 | |
| 65 | 64 | static UINT64 global_get(void *ref); |
| 66 | 65 | static void global_set(void *ref, UINT64 value); |
| 67 | 66 | |
| 68 | static void execute_help(int ref, int params, const char **param); | |
| 69 | static void execute_print(int ref, int params, const char **param); | |
| 70 | static void execute_printf(int ref, int params, const char **param); | |
| 71 | static void execute_logerror(int ref, int params, const char **param); | |
| 72 | static void execute_tracelog(int ref, int params, const char **param); | |
| 73 | static void execute_quit(int ref, int params, const char **param); | |
| 74 | static void execute_do(int ref, int params, const char **param); | |
| 75 | static void execute_step(int ref, int params, const char **param); | |
| 76 | static void execute_over(int ref, int params, const char **param); | |
| 77 | static void execute_out(int ref, int params, const char **param); | |
| 78 | static void execute_go(int ref, int params, const char **param); | |
| 79 | static void execute_go_vblank(int ref, int params, const char **param); | |
| 80 | static void execute_go_interrupt(int ref, int params, const char **param); | |
| 81 | static void execute_go_time(int ref, int params, const char *param[]); | |
| 82 | static void execute_focus(int ref, int params, const char **param); | |
| 83 | static void execute_ignore(int ref, int params, const char **param); | |
| 84 | static void execute_observe(int ref, int params, const char **param); | |
| 85 | static void execute_next(int ref, int params, const char **param); | |
| 86 | static void execute_comment(int ref, int params, const char **param); | |
| 87 | static void execute_comment_del(int ref, int params, const char **param); | |
| 88 | static void execute_comment_save(int ref, int params, const char **param); | |
| 89 | static void execute_bpset(int ref, int params, const char **param); | |
| 90 | static void execute_bpclear(int ref, int params, const char **param); | |
| 91 | static void execute_bpdisenable(int ref, int params, const char **param); | |
| 92 | static void execute_bplist(int ref, int params, const char **param); | |
| 93 | static void execute_wpset(int ref, int params, const char **param); | |
| 94 | static void execute_wpclear(int ref, int params, const char **param); | |
| 95 | static void execute_wpdisenable(int ref, int params, const char **param); | |
| 96 | static void execute_wplist(int ref, int params, const char **param); | |
| 97 | static void execute_hotspot(int ref, int params, const char **param); | |
| 98 | static void execute_save(int ref, int params, const char **param); | |
| 99 | static void execute_dump(int ref, int params, const char **param); | |
| 100 | static void execute_dasm(int ref, int params, const char **param); | |
| 101 | static void execute_find(int ref, int params, const char **param); | |
| 102 | static void execute_trace(int ref, int params, const char **param); | |
| 103 | static void execute_traceover(int ref, int params, const char **param); | |
| 104 | static void execute_traceflush(int ref, int params, const char **param); | |
| 105 | static void execute_history(int ref, int params, const char **param); | |
| 106 | static void execute_snap(int ref, int params, const char **param); | |
| 107 | static void execute_source(int ref, int params, const char **param); | |
| 108 | static void execute_map(int ref, int params, const char **param); | |
| 109 | static void execute_memdump(int ref, int params, const char **param); | |
| 110 | static void execute_symlist(int ref, int params, const char **param); | |
| 111 | static void execute_softreset(int ref, int params, const char **param); | |
| 112 | static void execute_hardreset(int ref, int params, const char **param); | |
| 67 | static void execute_help(running_machine *machine, int ref, int params, const char **param); | |
| 68 | static void execute_print(running_machine *machine, int ref, int params, const char **param); | |
| 69 | static void execute_printf(running_machine *machine, int ref, int params, const char **param); | |
| 70 | static void execute_logerror(running_machine *machine, int ref, int params, const char **param); | |
| 71 | static void execute_tracelog(running_machine *machine, int ref, int params, const char **param); | |
| 72 | static void execute_quit(running_machine *machine, int ref, int params, const char **param); | |
| 73 | static void execute_do(running_machine *machine, int ref, int params, const char **param); | |
| 74 | static void execute_step(running_machine *machine, int ref, int params, const char **param); | |
| 75 | static void execute_over(running_machine *machine, int ref, int params, const char **param); | |
| 76 | static void execute_out(running_machine *machine, int ref, int params, const char **param); | |
| 77 | static void execute_go(running_machine *machine, int ref, int params, const char **param); | |
| 78 | static void execute_go_vblank(running_machine *machine, int ref, int params, const char **param); | |
| 79 | static void execute_go_interrupt(running_machine *machine, int ref, int params, const char **param); | |
| 80 | static void execute_go_time(running_machine *machine, int ref, int params, const char *param[]); | |
| 81 | static void execute_focus(running_machine *machine, int ref, int params, const char **param); | |
| 82 | static void execute_ignore(running_machine *machine, int ref, int params, const char **param); | |
| 83 | static void execute_observe(running_machine *machine, int ref, int params, const char **param); | |
| 84 | static void execute_next(running_machine *machine, int ref, int params, const char **param); | |
| 85 | static void execute_comment(running_machine *machine, int ref, int params, const char **param); | |
| 86 | static void execute_comment_del(running_machine *machine, int ref, int params, const char **param); | |
| 87 | static void execute_comment_save(running_machine *machine, int ref, int params, const char **param); | |
| 88 | static void execute_bpset(running_machine *machine, int ref, int params, const char **param); | |
| 89 | static void execute_bpclear(running_machine *machine, int ref, int params, const char **param); | |
| 90 | static void execute_bpdisenable(running_machine *machine, int ref, int params, const char **param); | |
| 91 | static void execute_bplist(running_machine *machine, int ref, int params, const char **param); | |
| 92 | static void execute_wpset(running_machine *machine, int ref, int params, const char **param); | |
| 93 | static void execute_wpclear(running_machine *machine, int ref, int params, const char **param); | |
| 94 | static void execute_wpdisenable(running_machine *machine, int ref, int params, const char **param); | |
| 95 | static void execute_wplist(running_machine *machine, int ref, int params, const char **param); | |
| 96 | static void execute_hotspot(running_machine *machine, int ref, int params, const char **param); | |
| 97 | static void execute_save(running_machine *machine, int ref, int params, const char **param); | |
| 98 | static void execute_dump(running_machine *machine, int ref, int params, const char **param); | |
| 99 | static void execute_dasm(running_machine *machine, int ref, int params, const char **param); | |
| 100 | static void execute_find(running_machine *machine, int ref, int params, const char **param); | |
| 101 | static void execute_trace(running_machine *machine, int ref, int params, const char **param); | |
| 102 | static void execute_traceover(running_machine *machine, int ref, int params, const char **param); | |
| 103 | static void execute_traceflush(running_machine *machine, int ref, int params, const char **param); | |
| 104 | static void execute_history(running_machine *machine, int ref, int params, const char **param); | |
| 105 | static void execute_snap(running_machine *machine, int ref, int params, const char **param); | |
| 106 | static void execute_source(running_machine *machine, int ref, int params, const char **param); | |
| 107 | static void execute_map(running_machine *machine, int ref, int params, const char **param); | |
| 108 | static void execute_memdump(running_machine *machine, int ref, int params, const char **param); | |
| 109 | static void execute_symlist(running_machine *machine, int ref, int params, const char **param); | |
| 110 | static void execute_softreset(running_machine *machine, int ref, int params, const char **param); | |
| 111 | static void execute_hardreset(running_machine *machine, int ref, int params, const char **param); | |
| 113 | 112 | |
| 114 | 113 | |
| 115 | 114 | |
| r3232 | r3233 | |
| 157 | 156 | } |
| 158 | 157 | |
| 159 | 158 | /* add all the commands */ |
| 160 | debug_console_register_command("help", CMDFLAG_NONE, 0, 0, 1, execute_help); | |
| 161 | debug_console_register_command("print", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_print); | |
| 162 | debug_console_register_command("printf", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_printf); | |
| 163 | debug_console_register_command("logerror", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_logerror); | |
| 164 | debug_console_register_command("tracelog", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_tracelog); | |
| 165 | debug_console_register_command("quit", CMDFLAG_NONE, 0, 0, 0, execute_quit); | |
| 166 | debug_console_register_command("do", CMDFLAG_NONE, 0, 1, 1, execute_do); | |
| 167 | debug_console_register_command("step", CMDFLAG_NONE, 0, 0, 1, execute_step); | |
| 168 | debug_console_register_command("s", CMDFLAG_NONE, 0, 0, 1, execute_step); | |
| 169 | debug_console_register_command("over", CMDFLAG_NONE, 0, 0, 1, execute_over); | |
| 170 | debug_console_register_command("o", CMDFLAG_NONE, 0, 0, 1, execute_over); | |
| 171 | debug_console_register_command("out" , CMDFLAG_NONE, 0, 0, 0, execute_out); | |
| 172 | debug_console_register_command("go", CMDFLAG_NONE, 0, 0, 1, execute_go); | |
| 173 | debug_console_register_command("g", CMDFLAG_NONE, 0, 0, 1, execute_go); | |
| 174 | debug_console_register_command("gvblank", CMDFLAG_NONE, 0, 0, 0, execute_go_vblank); | |
| 175 | debug_console_register_command("gv", CMDFLAG_NONE, 0, 0, 0, execute_go_vblank); | |
| 176 | debug_console_register_command("gint", CMDFLAG_NONE, 0, 0, 1, execute_go_interrupt); | |
| 177 | debug_console_register_command("gi", CMDFLAG_NONE, 0, 0, 1, execute_go_interrupt); | |
| 178 | debug_console_register_command("gtime", CMDFLAG_NONE, 0, 0, 1, execute_go_time); | |
| 179 | debug_console_register_command("gt", CMDFLAG_NONE, 0, 0, 1, execute_go_time); | |
| 180 | debug_console_register_command("next", CMDFLAG_NONE, 0, 0, 0, execute_next); | |
| 181 | debug_console_register_command("n", CMDFLAG_NONE, 0, 0, 0, execute_next); | |
| 182 | debug_console_register_command("focus", CMDFLAG_NONE, 0, 1, 1, execute_focus); | |
| 183 | debug_console_register_command("ignore", CMDFLAG_NONE, 0, 0, MAX_COMMAND_PARAMS, execute_ignore); | |
| 184 | debug_console_register_command("observe", CMDFLAG_NONE, 0, 0, MAX_COMMAND_PARAMS, execute_observe); | |
| 159 | debug_console_register_command(machine, "help", CMDFLAG_NONE, 0, 0, 1, execute_help); | |
| 160 | debug_console_register_command(machine, "print", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_print); | |
| 161 | debug_console_register_command(machine, "printf", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_printf); | |
| 162 | debug_console_register_command(machine, "logerror", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_logerror); | |
| 163 | debug_console_register_command(machine, "tracelog", CMDFLAG_NONE, 0, 1, MAX_COMMAND_PARAMS, execute_tracelog); | |
| 164 | debug_console_register_command(machine, "quit", CMDFLAG_NONE, 0, 0, 0, execute_quit); | |
| 165 | debug_console_register_command(machine, "do", CMDFLAG_NONE, 0, 1, 1, execute_do); | |
| 166 | debug_console_register_command(machine, "step", CMDFLAG_NONE, 0, 0, 1, execute_step); | |
| 167 | debug_console_register_command(machine, "s", CMDFLAG_NONE, 0, 0, 1, execute_step); | |
| 168 | debug_console_register_command(machine, "over", CMDFLAG_NONE, 0, 0, 1, execute_over); | |
| 169 | debug_console_register_command(machine, "o", CMDFLAG_NONE, 0, 0, 1, execute_over); | |
| 170 | debug_console_register_command(machine, "out" , CMDFLAG_NONE, 0, 0, 0, execute_out); | |
| 171 | debug_console_register_command(machine, "go", CMDFLAG_NONE, 0, 0, 1, execute_go); | |
| 172 | debug_console_register_command(machine, "g", CMDFLAG_NONE, 0, 0, 1, execute_go); | |
| 173 | debug_console_register_command(machine, "gvblank", CMDFLAG_NONE, 0, 0, 0, execute_go_vblank); | |
| 174 | debug_console_register_command(machine, "gv", CMDFLAG_NONE, 0, 0, 0, execute_go_vblank); | |
| 175 | debug_console_register_command(machine, "gint", CMDFLAG_NONE, 0, 0, 1, execute_go_interrupt); | |
| 176 | debug_console_register_command(machine, "gi", CMDFLAG_NONE, 0, 0, 1, execute_go_interrupt); | |
| 177 | debug_console_register_command(machine, "gtime", CMDFLAG_NONE, 0, 0, 1, execute_go_time); | |
| 178 | debug_console_register_command(machine, "gt", CMDFLAG_NONE, 0, 0, 1, execute_go_time); | |
| 179 | debug_console_register_command(machine, "next", CMDFLAG_NONE, 0, 0, 0, execute_next); | |
| 180 | debug_console_register_command(machine, "n", CMDFLAG_NONE, 0, 0, 0, execute_next); | |
| 181 | debug_console_register_command(machine, "focus", CMDFLAG_NONE, 0, 1, 1, execute_focus); | |
| 182 | debug_console_register_command(machine, "ignore", CMDFLAG_NONE, 0, 0, MAX_COMMAND_PARAMS, execute_ignore); | |
| 183 | debug_console_register_command(machine, "observe", CMDFLAG_NONE, 0, 0, MAX_COMMAND_PARAMS, execute_observe); | |
| 185 | 184 | |
| 186 | debug_console_register_command("comadd", CMDFLAG_NONE, 0, 1, 2, execute_comment); | |
| 187 | debug_console_register_command("//", CMDFLAG_NONE, 0, 1, 2, execute_comment); | |
| 188 | debug_console_register_command("comdelete", CMDFLAG_NONE, 0, 1, 1, execute_comment_del); | |
| 189 | debug_console_register_command("comsave", CMDFLAG_NONE, 0, 0, 0, execute_comment_save); | |
| 185 | debug_console_register_command(machine, "comadd", CMDFLAG_NONE, 0, 1, 2, execute_comment); | |
| 186 | debug_console_register_command(machine, "//", CMDFLAG_NONE, 0, 1, 2, execute_comment); | |
| 187 | debug_console_register_command(machine, "comdelete", CMDFLAG_NONE, 0, 1, 1, execute_comment_del); | |
| 188 | debug_console_register_command(machine, "comsave", CMDFLAG_NONE, 0, 0, 0, execute_comment_save); | |
| 190 | 189 | |
| 191 | debug_console_register_command("bpset", CMDFLAG_NONE, 0, 1, 3, execute_bpset); | |
| 192 | debug_console_register_command("bp", CMDFLAG_NONE, 0, 1, 3, execute_bpset); | |
| 193 | debug_console_register_command("bpclear", CMDFLAG_NONE, 0, 0, 1, execute_bpclear); | |
| 194 | debug_console_register_command("bpdisable", CMDFLAG_NONE, 0, 0, 1, execute_bpdisenable); | |
| 195 | debug_console_register_command("bpenable", CMDFLAG_NONE, 1, 0, 1, execute_bpdisenable); | |
| 196 | debug_console_register_command("bplist", CMDFLAG_NONE, 0, 0, 0, execute_bplist); | |
| 190 | debug_console_register_command(machine, "bpset", CMDFLAG_NONE, 0, 1, 3, execute_bpset); | |
| 191 | debug_console_register_command(machine, "bp", CMDFLAG_NONE, 0, 1, 3, execute_bpset); | |
| 192 | debug_console_register_command(machine, "bpclear", CMDFLAG_NONE, 0, 0, 1, execute_bpclear); | |
| 193 | debug_console_register_command(machine, "bpdisable", CMDFLAG_NONE, 0, 0, 1, execute_bpdisenable); | |
| 194 | debug_console_register_command(machine, "bpenable", CMDFLAG_NONE, 1, 0, 1, execute_bpdisenable); | |
| 195 | debug_console_register_command(machine, "bplist", CMDFLAG_NONE, 0, 0, 0, execute_bplist); | |
| 197 | 196 | |
| 198 | debug_console_register_command("wpset", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 5, execute_wpset); | |
| 199 | debug_console_register_command("wp", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 5, execute_wpset); | |
| 200 | debug_console_register_command("wpdset", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 5, execute_wpset); | |
| 201 | debug_console_register_command("wpd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 5, execute_wpset); | |
| 202 | debug_console_register_command("wpiset", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 5, execute_wpset); | |
| 203 | debug_console_register_command("wpi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 5, execute_wpset); | |
| 204 | debug_console_register_command("wpclear", CMDFLAG_NONE, 0, 0, 1, execute_wpclear); | |
| 205 | debug_console_register_command("wpdisable", CMDFLAG_NONE, 0, 0, 1, execute_wpdisenable); | |
| 206 | debug_console_register_command("wpenable", CMDFLAG_NONE, 1, 0, 1, execute_wpdisenable); | |
| 207 | debug_console_register_command("wplist", CMDFLAG_NONE, 0, 0, 0, execute_wplist); | |
| 197 | debug_console_register_command(machine, "wpset", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 5, execute_wpset); | |
| 198 | debug_console_register_command(machine, "wp", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 5, execute_wpset); | |
| 199 | debug_console_register_command(machine, "wpdset", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 5, execute_wpset); | |
| 200 | debug_console_register_command(machine, "wpd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 5, execute_wpset); | |
| 201 | debug_console_register_command(machine, "wpiset", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 5, execute_wpset); | |
| 202 | debug_console_register_command(machine, "wpi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 5, execute_wpset); | |
| 203 | debug_console_register_command(machine, "wpclear", CMDFLAG_NONE, 0, 0, 1, execute_wpclear); | |
| 204 | debug_console_register_command(machine, "wpdisable", CMDFLAG_NONE, 0, 0, 1, execute_wpdisenable); | |
| 205 | debug_console_register_command(machine, "wpenable", CMDFLAG_NONE, 1, 0, 1, execute_wpdisenable); | |
| 206 | debug_console_register_command(machine, "wplist", CMDFLAG_NONE, 0, 0, 0, execute_wplist); | |
| 208 | 207 | |
| 209 | debug_console_register_command("hotspot", CMDFLAG_NONE, 0, 0, 3, execute_hotspot); | |
| 208 | debug_console_register_command(machine, "hotspot", CMDFLAG_NONE, 0, 0, 3, execute_hotspot); | |
| 210 | 209 | |
| 211 | debug_console_register_command("save", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 4, execute_save); | |
| 212 | debug_console_register_command("saved", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 4, execute_save); | |
| 213 | debug_console_register_command("savei", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 4, execute_save); | |
| 210 | debug_console_register_command(machine, "save", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 4, execute_save); | |
| 211 | debug_console_register_command(machine, "saved", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 4, execute_save); | |
| 212 | debug_console_register_command(machine, "savei", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 4, execute_save); | |
| 214 | 213 | |
| 215 | debug_console_register_command("dump", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 6, execute_dump); | |
| 216 | debug_console_register_command("dumpd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 6, execute_dump); | |
| 217 | debug_console_register_command("dumpi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 6, execute_dump); | |
| 214 | debug_console_register_command(machine, "dump", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 3, 6, execute_dump); | |
| 215 | debug_console_register_command(machine, "dumpd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 3, 6, execute_dump); | |
| 216 | debug_console_register_command(machine, "dumpi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 3, 6, execute_dump); | |
| 218 | 217 | |
| 219 | debug_console_register_command("f", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_PROGRAM, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 220 | debug_console_register_command("find", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_PROGRAM, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 221 | debug_console_register_command("fd", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_DATA, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 222 | debug_console_register_command("findd", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_DATA, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 223 | debug_console_register_command("fi", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_IO, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 224 | debug_console_register_command("findi", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_IO, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 218 | debug_console_register_command(machine, "f", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_PROGRAM, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 219 | debug_console_register_command(machine, "find", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_PROGRAM, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 220 | debug_console_register_command(machine, "fd", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_DATA, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 221 | debug_console_register_command(machine, "findd", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_DATA, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 222 | debug_console_register_command(machine, "fi", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_IO, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 223 | debug_console_register_command(machine, "findi", CMDFLAG_KEEP_QUOTES, ADDRESS_SPACE_IO, 3, MAX_COMMAND_PARAMS, execute_find); | |
| 225 | 224 | |
| 226 | debug_console_register_command("dasm", CMDFLAG_NONE, 0, 3, 5, execute_dasm); | |
| 225 | debug_console_register_command(machine, "dasm", CMDFLAG_NONE, 0, 3, 5, execute_dasm); | |
| 227 | 226 | |
| 228 | debug_console_register_command("trace", CMDFLAG_NONE, 0, 1, 3, execute_trace); | |
| 229 | debug_console_register_command("traceover", CMDFLAG_NONE, 0, 1, 3, execute_traceover); | |
| 230 | debug_console_register_command("traceflush",CMDFLAG_NONE, 0, 0, 0, execute_traceflush); | |
| 227 | debug_console_register_command(machine, "trace", CMDFLAG_NONE, 0, 1, 3, execute_trace); | |
| 228 | debug_console_register_command(machine, "traceover", CMDFLAG_NONE, 0, 1, 3, execute_traceover); | |
| 229 | debug_console_register_command(machine, "traceflush",CMDFLAG_NONE, 0, 0, 0, execute_traceflush); | |
| 231 | 230 | |
| 232 | debug_console_register_command("history", CMDFLAG_NONE, 0, 0, 2, execute_history); | |
| 231 | debug_console_register_command(machine, "history", CMDFLAG_NONE, 0, 0, 2, execute_history); | |
| 233 | 232 | |
| 234 | debug_console_register_command("snap", CMDFLAG_NONE, 0, 0, 1, execute_snap); | |
| 233 | debug_console_register_command(machine, "snap", CMDFLAG_NONE, 0, 0, 1, execute_snap); | |
| 235 | 234 | |
| 236 | debug_console_register_command("source", CMDFLAG_NONE, 0, 1, 1, execute_source); | |
| 235 | debug_console_register_command(machine, "source", CMDFLAG_NONE, 0, 1, 1, execute_source); | |
| 237 | 236 | |
| 238 | debug_console_register_command("map", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 1, 1, execute_map); | |
| 239 | debug_console_register_command("mapd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 1, 1, execute_map); | |
| 240 | debug_console_register_command("mapi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 1, 1, execute_map); | |
| 241 | debug_console_register_command("memdump", CMDFLAG_NONE, 0, 0, 1, execute_memdump); | |
| 237 | debug_console_register_command(machine, "map", CMDFLAG_NONE, ADDRESS_SPACE_PROGRAM, 1, 1, execute_map); | |
| 238 | debug_console_register_command(machine, "mapd", CMDFLAG_NONE, ADDRESS_SPACE_DATA, 1, 1, execute_map); | |
| 239 | debug_console_register_command(machine, "mapi", CMDFLAG_NONE, ADDRESS_SPACE_IO, 1, 1, execute_map); | |
| 240 | debug_console_register_command(machine, "memdump", CMDFLAG_NONE, 0, 0, 1, execute_memdump); | |
| 242 | 241 | |
| 243 | debug_console_register_command("symlist", CMDFLAG_NONE, 0, 0, 1, execute_symlist); | |
| 242 | debug_console_register_command(machine, "symlist", CMDFLAG_NONE, 0, 0, 1, execute_symlist); | |
| 244 | 243 | |
| 245 | debug_console_register_command("softreset", CMDFLAG_NONE, 0, 0, 1, execute_softreset); | |
| 246 | debug_console_register_command("hardreset", CMDFLAG_NONE, 0, 0, 1, execute_hardreset); | |
| 244 | debug_console_register_command(machine, "softreset", CMDFLAG_NONE, 0, 0, 1, execute_softreset); | |
| 245 | debug_console_register_command(machine, "hardreset", CMDFLAG_NONE, 0, 0, 1, execute_hardreset); | |
| 247 | 246 | |
| 248 | 247 | /* ask all the CPUs if they would like to register functions or symbols */ |
| 249 | 248 | for (cpunum = 0; cpunum < cpu_gettotalcpu(); cpunum++) |
| r3232 | r3233 | |
| 402 | 401 | command parameter |
| 403 | 402 | -------------------------------------------------*/ |
| 404 | 403 | |
| 405 | static int debug_command_parameter_command(const char *param) | |
| 404 | static int debug_command_parameter_command(running_machine *machine, const char *param) | |
| 406 | 405 | { |
| 407 | CMDERR err = debug_console_validate_command(param); | |
| 406 | CMDERR err = debug_console_validate_command(machine, param); | |
| 408 | 407 | if (err == CMDERR_NONE) |
| 409 | 408 | return 1; |
| 410 | 409 | debug_console_printf("Error in command: %s\n", param); |
| r3232 | r3233 | |
| 425 | 424 | execute_help - execute the help command |
| 426 | 425 | -------------------------------------------------*/ |
| 427 | 426 | |
| 428 | static void execute_help(int ref, int params, const char *param[]) | |
| 427 | static void execute_help(running_machine *machine, int ref, int params, const char *param[]) | |
| 429 | 428 | { |
| 430 | 429 | if (params == 0) |
| 431 | 430 | debug_console_printf_wrap(80, "%s\n", debug_get_help("")); |
| r3232 | r3233 | |
| 438 | 437 | execute_print - execute the print command |
| 439 | 438 | -------------------------------------------------*/ |
| 440 | 439 | |
| 441 | static void execute_print(int ref, int params, const char *param[]) | |
| 440 | static void execute_print(running_machine *machine, int ref, int params, const char *param[]) | |
| 442 | 441 | { |
| 443 | 442 | UINT64 values[MAX_COMMAND_PARAMS]; |
| 444 | 443 | int i; |
| r3232 | r3233 | |
| 558 | 557 | execute_printf - execute the printf command |
| 559 | 558 | -------------------------------------------------*/ |
| 560 | 559 | |
| 561 | static void execute_printf(int ref, int params, const char *param[]) | |
| 560 | static void execute_printf(running_machine *machine, int ref, int params, const char *param[]) | |
| 562 | 561 | { |
| 563 | 562 | UINT64 values[MAX_COMMAND_PARAMS]; |
| 564 | 563 | char buffer[1024]; |
| r3232 | r3233 | |
| 579 | 578 | execute_logerror - execute the logerror command |
| 580 | 579 | -------------------------------------------------*/ |
| 581 | 580 | |
| 582 | static void execute_logerror(int ref, int params, const char *param[]) | |
| 581 | static void execute_logerror(running_machine *machine, int ref, int params, const char *param[]) | |
| 583 | 582 | { |
| 584 | 583 | UINT64 values[MAX_COMMAND_PARAMS]; |
| 585 | 584 | char buffer[1024]; |
| r3232 | r3233 | |
| 600 | 599 | execute_tracelog - execute the tracelog command |
| 601 | 600 | -------------------------------------------------*/ |
| 602 | 601 | |
| 603 | static void execute_tracelog(int ref, int params, const char *param[]) | |
| 602 | static void execute_tracelog(running_machine *machine, int ref, int params, const char *param[]) | |
| 604 | 603 | { |
| 605 | 604 | FILE *file = debug_get_cpu_info(cpu_getactivecpu())->trace.file; |
| 606 | 605 | UINT64 values[MAX_COMMAND_PARAMS]; |
| r3232 | r3233 | |
| 626 | 625 | execute_quit - execute the quit command |
| 627 | 626 | -------------------------------------------------*/ |
| 628 | 627 | |
| 629 | static void execute_quit(int ref, int params, const char *param[]) | |
| 628 | static void execute_quit(running_machine *machine, int ref, int params, const char *param[]) | |
| 630 | 629 | { |
| 631 | 630 | mame_printf_error("Exited via the debugger\n"); |
| 632 | mame_schedule_exit( | |
| 631 | mame_schedule_exit(machine); | |
| 633 | 632 | } |
| 634 | 633 | |
| 635 | 634 | |
| r3232 | r3233 | |
| 637 | 636 | execute_do - execute the do command |
| 638 | 637 | -------------------------------------------------*/ |
| 639 | 638 | |
| 640 | static void execute_do(int ref, int params, const char *param[]) | |
| 639 | static void execute_do(running_machine *machine, int ref, int params, const char *param[]) | |
| 641 | 640 | { |
| 642 | 641 | UINT64 dummy; |
| 643 | 642 | debug_command_parameter_number(param[0], &dummy); |
| r3232 | r3233 | |
| 648 | 647 | execute_step - execute the step command |
| 649 | 648 | -------------------------------------------------*/ |
| 650 | 649 | |
| 651 | static void execute_step(int ref, int params, const char *param[]) | |
| 650 | static void execute_step(running_machine *machine, int ref, int params, const char *param[]) | |
| 652 | 651 | { |
| 653 | 652 | UINT64 steps = 1; |
| 654 | 653 | |
| r3232 | r3233 | |
| 664 | 663 | execute_over - execute the over command |
| 665 | 664 | -------------------------------------------------*/ |
| 666 | 665 | |
| 667 | static void execute_over(int ref, int params, const char *param[]) | |
| 666 | static void execute_over(running_machine *machine, int ref, int params, const char *param[]) | |
| 668 | 667 | { |
| 669 | 668 | UINT64 steps = 1; |
| 670 | 669 | |
| r3232 | r3233 | |
| 680 | 679 | execute_out - execute the out command |
| 681 | 680 | -------------------------------------------------*/ |
| 682 | 681 | |
| 683 | static void execute_out(int ref, int params, const char *param[]) | |
| 682 | static void execute_out(running_machine *machine, int ref, int params, const char *param[]) | |
| 684 | 683 | { |
| 685 | 684 | debug_cpu_single_step_out(); |
| 686 | 685 | } |
| r3232 | r3233 | |
| 690 | 689 | execute_go - execute the go command |
| 691 | 690 | -------------------------------------------------*/ |
| 692 | 691 | |
| 693 | static void execute_go(int ref, int params, const char *param[]) | |
| 692 | static void execute_go(running_machine *machine, int ref, int params, const char *param[]) | |
| 694 | 693 | { |
| 695 | 694 | UINT64 addr = ~0; |
| 696 | 695 | |
| r3232 | r3233 | |
| 707 | 706 | command |
| 708 | 707 | -------------------------------------------------*/ |
| 709 | 708 | |
| 710 | static void execute_go_vblank(int ref, int params, const char *param[]) | |
| 709 | static void execute_go_vblank(running_machine *machine, int ref, int params, const char *param[]) | |
| 711 | 710 | { |
| 712 | 711 | debug_cpu_go_vblank(); |
| 713 | 712 | } |
| r3232 | r3233 | |
| 717 | 716 | execute_go_interrupt - execute the goint command |
| 718 | 717 | -------------------------------------------------*/ |
| 719 | 718 | |
| 720 | static void execute_go_interrupt(int ref, int params, const char *param[]) | |
| 719 | static void execute_go_interrupt(running_machine *machine, int ref, int params, const char *param[]) | |
| 721 | 720 | { |
| 722 | 721 | UINT64 irqline = -1; |
| 723 | 722 | |
| r3232 | r3233 | |
| 733 | 732 | execute_go_time - execute the gtime command |
| 734 | 733 | -------------------------------------------------*/ |
| 735 | 734 | |
| 736 | static void execute_go_time(int ref, int params, const char *param[]) | |
| 735 | static void execute_go_time(running_machine *machine, int ref, int params, const char *param[]) | |
| 737 | 736 | { |
| 738 | 737 | UINT64 milliseconds = -1; |
| 739 | 738 | |
| r3232 | r3233 | |
| 749 | 748 | execute_next - execute the next command |
| 750 | 749 | -------------------------------------------------*/ |
| 751 | 750 | |
| 752 | static void execute_next(int ref, int params, const char *param[]) | |
| 751 | static void execute_next(running_machine *machine, int ref, int params, const char *param[]) | |
| 753 | 752 | { |
| 754 | 753 | debug_cpu_next_cpu(); |
| 755 | 754 | } |
| r3232 | r3233 | |
| 759 | 758 | execute_focus - execute the focus command |
| 760 | 759 | -------------------------------------------------*/ |
| 761 | 760 | |
| 762 | static void execute_focus(int ref, int params, const char *param[]) | |
| 761 | static void execute_focus(running_machine *machine, int ref, int params, const char *param[]) | |
| 763 | 762 | { |
| 764 | 763 | UINT64 cpuwhich; |
| 765 | 764 | int cpunum; |
| r3232 | r3233 | |
| 791 | 790 | execute_ignore - execute the ignore command |
| 792 | 791 | -------------------------------------------------*/ |
| 793 | 792 | |
| 794 | static void execute_ignore(int ref, int params, const char *param[]) | |
| 793 | static void execute_ignore(running_machine *machine, int ref, int params, const char *param[]) | |
| 795 | 794 | { |
| 796 | 795 | UINT64 cpuwhich[MAX_COMMAND_PARAMS]; |
| 797 | 796 | int cpunum, paramnum; |
| r3232 | r3233 | |
| 862 | 861 | execute_observe - execute the observe command |
| 863 | 862 | -------------------------------------------------*/ |
| 864 | 863 | |
| 865 | static void execute_observe(int ref, int params, const char *param[]) | |
| 864 | static void execute_observe(running_machine *machine, int ref, int params, const char *param[]) | |
| 866 | 865 | { |
| 867 | 866 | UINT64 cpuwhich[MAX_COMMAND_PARAMS]; |
| 868 | 867 | int cpunum, paramnum; |
| r3232 | r3233 | |
| 920 | 919 | execute_comment - add a comment to a line |
| 921 | 920 | -------------------------------------------------*/ |
| 922 | 921 | |
| 923 | static void execute_comment(int ref, int params, const char *param[]) | |
| 922 | static void execute_comment(running_machine *machine, int ref, int params, const char *param[]) | |
| 924 | 923 | { |
| 925 | 924 | UINT64 address; |
| 926 | 925 | |
| r3232 | r3233 | |
| 945 | 944 | execute_comment_del - remove a comment from an addr |
| 946 | 945 | --------------------------------------------------------*/ |
| 947 | 946 | |
| 948 | static void execute_comment_del(int ref, int params, const char *param[]) | |
| 947 | static void execute_comment_del(running_machine *machine, int ref, int params, const char *param[]) | |
| 949 | 948 | { |
| 950 | 949 | UINT64 address; |
| 951 | 950 | |
| r3232 | r3233 | |
| 964 | 963 | execute_comment - add a comment to a line |
| 965 | 964 | -------------------------------------------------*/ |
| 966 | 965 | |
| 967 | static void execute_comment_save(int ref, int params, const char *param[]) | |
| 966 | static void execute_comment_save(running_machine *machine, int ref, int params, const char *param[]) | |
| 968 | 967 | { |
| 969 | if (debug_comment_save( | |
| 968 | if (debug_comment_save(machine)) | |
| 970 | 969 | debug_console_printf("Comments successfully saved\n"); |
| 971 | 970 | } |
| 972 | 971 | |
| r3232 | r3233 | |
| 976 | 975 | command |
| 977 | 976 | -------------------------------------------------*/ |
| 978 | 977 | |
| 979 | static void execute_bpset(int ref, int params, const char *param[]) | |
| 978 | static void execute_bpset(running_machine *machine, int ref, int params, const char *param[]) | |
| 980 | 979 | { |
| 981 | 980 | parsed_expression *condition = NULL; |
| 982 | 981 | const char *action = NULL; |
| r3232 | r3233 | |
| 999 | 998 | return; |
| 1000 | 999 | |
| 1001 | 1000 | /* param 3 is the action */ |
| 1002 | if (params > 2 && !debug_command_parameter_command(action = param[2])) | |
| 1001 | if (params > 2 && !debug_command_parameter_command(machine, action = param[2])) | |
| 1003 | 1002 | return; |
| 1004 | 1003 | |
| 1005 | 1004 | /* set the breakpoint */ |
| 1006 | bpnum = debug_cpu_breakpoint_set( | |
| 1005 | bpnum = debug_cpu_breakpoint_set(machine, cpu_getactivecpu(), address, condition, action); | |
| 1007 | 1006 | debug_console_printf("Breakpoint %X set\n", bpnum); |
| 1008 | 1007 | } |
| 1009 | 1008 | |
| r3232 | r3233 | |
| 1013 | 1012 | clear command |
| 1014 | 1013 | -------------------------------------------------*/ |
| 1015 | 1014 | |
| 1016 | static void execute_bpclear(int ref, int params, const char *param[]) | |
| 1015 | static void execute_bpclear(running_machine *machine, int ref, int params, const char *param[]) | |
| 1017 | 1016 | { |
| 1018 | 1017 | UINT64 bpindex; |
| 1019 | 1018 | |
| r3232 | r3233 | |
| 1029 | 1028 | { |
| 1030 | 1029 | debug_cpu_breakpoint *bp; |
| 1031 | 1030 | while ((bp = cpuinfo->bplist) != NULL) |
| 1032 | debug_cpu_breakpoint_clear( | |
| 1031 | debug_cpu_breakpoint_clear(machine, bp->index); | |
| 1033 | 1032 | } |
| 1034 | 1033 | } |
| 1035 | 1034 | debug_console_printf("Cleared all breakpoints\n"); |
| r3232 | r3233 | |
| 1040 | 1039 | return; |
| 1041 | 1040 | else |
| 1042 | 1041 | { |
| 1043 | int found = debug_cpu_breakpoint_clear( | |
| 1042 | int found = debug_cpu_breakpoint_clear(machine, bpindex); | |
| 1044 | 1043 | if (found) |
| 1045 | 1044 | debug_console_printf("Breakpoint %X cleared\n", (UINT32)bpindex); |
| 1046 | 1045 | else |
| r3232 | r3233 | |
| 1054 | 1053 | disable/enable commands |
| 1055 | 1054 | -------------------------------------------------*/ |
| 1056 | 1055 | |
| 1057 | static void execute_bpdisenable(int ref, int params, const char *param[]) | |
| 1056 | static void execute_bpdisenable(running_machine *machine, int ref, int params, const char *param[]) | |
| 1058 | 1057 | { |
| 1059 | 1058 | UINT64 bpindex; |
| 1060 | 1059 | |
| r3232 | r3233 | |
| 1070 | 1069 | { |
| 1071 | 1070 | debug_cpu_breakpoint *bp; |
| 1072 | 1071 | for (bp = cpuinfo->bplist; bp != NULL; bp = bp->next) |
| 1073 | debug_cpu_breakpoint_enable( | |
| 1072 | debug_cpu_breakpoint_enable(machine, bp->index, ref); | |
| 1074 | 1073 | } |
| 1075 | 1074 | } |
| 1076 | 1075 | if (ref == 0) |
| r3232 | r3233 | |
| 1084 | 1083 | return; |
| 1085 | 1084 | else |
| 1086 | 1085 | { |
| 1087 | int found = debug_cpu_breakpoint_enable( | |
| 1086 | int found = debug_cpu_breakpoint_enable(machine, bpindex, ref); | |
| 1088 | 1087 | if (found) |
| 1089 | 1088 | debug_console_printf("Breakpoint %X %s\n", (UINT32)bpindex, ref ? "enabled" : "disabled"); |
| 1090 | 1089 | else |
| r3232 | r3233 | |
| 1098 | 1097 | command |
| 1099 | 1098 | -------------------------------------------------*/ |
| 1100 | 1099 | |
| 1101 | static void execute_bplist(int ref, int params, const char *param[]) | |
| 1100 | static void execute_bplist(running_machine *machine, int ref, int params, const char *param[]) | |
| 1102 | 1101 | { |
| 1103 | 1102 | int cpunum, printed = 0; |
| 1104 | 1103 | char buffer[256]; |
| r3232 | r3233 | |
| 1139 | 1138 | command |
| 1140 | 1139 | -------------------------------------------------*/ |
| 1141 | 1140 | |
| 1142 | static void execute_wpset(int ref, int params, const char *param[]) | |
| 1141 | static void execute_wpset(running_machine *machine, int ref, int params, const char *param[]) | |
| 1143 | 1142 | { |
| 1144 | 1143 | parsed_expression *condition = NULL; |
| 1145 | 1144 | const char *action = NULL; |
| r3232 | r3233 | |
| 1173 | 1172 | return; |
| 1174 | 1173 | |
| 1175 | 1174 | /* param 5 is the action */ |
| 1176 | if (params > 4 && !debug_command_parameter_command(action = param[4])) | |
| 1175 | if (params > 4 && !debug_command_parameter_command(machine, action = param[4])) | |
| 1177 | 1176 | return; |
| 1178 | 1177 | |
| 1179 | 1178 | /* set the watchpoint */ |
| 1180 | wpnum = debug_cpu_watchpoint_set( | |
| 1179 | wpnum = debug_cpu_watchpoint_set(machine, cpu_getactivecpu(), ref, type, address, length, condition, action); | |
| 1181 | 1180 | debug_console_printf("Watchpoint %X set\n", wpnum); |
| 1182 | 1181 | } |
| 1183 | 1182 | |
| r3232 | r3233 | |
| 1187 | 1186 | clear command |
| 1188 | 1187 | -------------------------------------------------*/ |
| 1189 | 1188 | |
| 1190 | static void execute_wpclear(int ref, int params, const char *param[]) | |
| 1189 | static void execute_wpclear(running_machine *machine, int ref, int params, const char *param[]) | |
| 1191 | 1190 | { |
| 1192 | 1191 | UINT64 wpindex; |
| 1193 | 1192 | |
| r3232 | r3233 | |
| 1207 | 1206 | { |
| 1208 | 1207 | debug_cpu_watchpoint *wp; |
| 1209 | 1208 | while ((wp = cpuinfo->space[spacenum].wplist) != NULL) |
| 1210 | debug_cpu_watchpoint_clear( | |
| 1209 | debug_cpu_watchpoint_clear(machine, wp->index); | |
| 1211 | 1210 | } |
| 1212 | 1211 | } |
| 1213 | 1212 | } |
| r3232 | r3233 | |
| 1219 | 1218 | return; |
| 1220 | 1219 | else |
| 1221 | 1220 | { |
| 1222 | int found = debug_cpu_watchpoint_clear( | |
| 1221 | int found = debug_cpu_watchpoint_clear(machine, wpindex); | |
| 1223 | 1222 | if (found) |
| 1224 | 1223 | debug_console_printf("Watchpoint %X cleared\n", (UINT32)wpindex); |
| 1225 | 1224 | else |
| r3232 | r3233 | |
| 1233 | 1232 | disable/enable commands |
| 1234 | 1233 | -------------------------------------------------*/ |
| 1235 | 1234 | |
| 1236 | static void execute_wpdisenable(int ref, int params, const char *param[]) | |
| 1235 | static void execute_wpdisenable(running_machine *machine, int ref, int params, const char *param[]) | |
| 1237 | 1236 | { |
| 1238 | 1237 | UINT64 wpindex; |
| 1239 | 1238 | |
| r3232 | r3233 | |
| 1253 | 1252 | { |
| 1254 | 1253 | debug_cpu_watchpoint *wp; |
| 1255 | 1254 | for (wp = cpuinfo->space[spacenum].wplist; wp != NULL; wp = wp->next) |
| 1256 | debug_cpu_watchpoint_enable( | |
| 1255 | debug_cpu_watchpoint_enable(machine, wp->index, ref); | |
| 1257 | 1256 | } |
| 1258 | 1257 | } |
| 1259 | 1258 | } |
| r3232 | r3233 | |
| 1268 | 1267 | return; |
| 1269 | 1268 | else |
| 1270 | 1269 | { |
| 1271 | int found = debug_cpu_watchpoint_enable( | |
| 1270 | int found = debug_cpu_watchpoint_enable(machine, wpindex, ref); | |
| 1272 | 1271 | if (found) |
| 1273 | 1272 | debug_console_printf("Watchpoint %X %s\n", (UINT32)wpindex, ref ? "enabled" : "disabled"); |
| 1274 | 1273 | else |
| r3232 | r3233 | |
| 1282 | 1281 | command |
| 1283 | 1282 | -------------------------------------------------*/ |
| 1284 | 1283 | |
| 1285 | static void execute_wplist(int ref, int params, const char *param[]) | |
| 1284 | static void execute_wplist(running_machine *machine, int ref, int params, const char *param[]) | |
| 1286 | 1285 | { |
| 1287 | 1286 | int cpunum, printed = 0; |
| 1288 | 1287 | char buffer[256]; |
| r3232 | r3233 | |
| 1333 | 1332 | command |
| 1334 | 1333 | -------------------------------------------------*/ |
| 1335 | 1334 | |
| 1336 | static void execute_hotspot(int ref, int params, const char *param[]) | |
| 1335 | static void execute_hotspot(running_machine *machine, int ref, int params, const char *param[]) | |
| 1337 | 1336 | { |
| 1338 | 1337 | UINT64 threshhold; |
| 1339 | 1338 | UINT64 cpunum; |
| r3232 | r3233 | |
| 1351 | 1350 | |
| 1352 | 1351 | if (cpuinfo->valid && cpuinfo->hotspots) |
| 1353 | 1352 | { |
| 1354 | debug_cpu_hotspot_track( | |
| 1353 | debug_cpu_hotspot_track(machine, cpunum, 0, 0); | |
| 1355 | 1354 | debug_console_printf("Cleared hotspot tracking on CPU %d\n", (int)cpunum); |
| 1356 | 1355 | cleared = TRUE; |
| 1357 | 1356 | } |
| r3232 | r3233 | |
| 1374 | 1373 | return; |
| 1375 | 1374 | |
| 1376 | 1375 | /* attempt to install */ |
| 1377 | if (debug_cpu_hotspot_track( | |
| 1376 | if (debug_cpu_hotspot_track(machine, cpunum, count, threshhold)) | |
| 1378 | 1377 | debug_console_printf("Now tracking hotspots on CPU %d using %d slots with a threshhold of %d\n", (int)cpunum, (int)count, (int)threshhold); |
| 1379 | 1378 | else |
| 1380 | 1379 | debug_console_printf("Error setting up the hotspot tracking\n"); |
| r3232 | r3233 | |
| 1385 | 1384 | execute_save - execute the save command |
| 1386 | 1385 | -------------------------------------------------*/ |
| 1387 | 1386 | |
| 1388 | static void execute_save(int ref, int params, const char *param[]) | |
| 1387 | static void execute_save(running_machine *machine, int ref, int params, const char *param[]) | |
| 1389 | 1388 | { |
| 1390 | 1389 | UINT64 offset, endoffset, length, cpunum = cpu_getactivecpu(); |
| 1391 | 1390 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 1433 | 1432 | execute_dump - execute the dump command |
| 1434 | 1433 | -------------------------------------------------*/ |
| 1435 | 1434 | |
| 1436 | static void execute_dump(int ref, int params, const char *param[]) | |
| 1435 | static void execute_dump(running_machine *machine, int ref, int params, const char *param[]) | |
| 1437 | 1436 | { |
| 1438 | 1437 | UINT64 offset, endoffset, length, width = 0, ascii = 1, cpunum = cpu_getactivecpu(); |
| 1439 | 1438 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 1602 | 1601 | execute_find - execute the find command |
| 1603 | 1602 | -------------------------------------------------*/ |
| 1604 | 1603 | |
| 1605 | static void execute_find(int ref, int params, const char *param[]) | |
| 1604 | static void execute_find(running_machine *machine, int ref, int params, const char *param[]) | |
| 1606 | 1605 | { |
| 1607 | 1606 | UINT64 offset, endoffset, length, cpunum = cpu_getactivecpu(); |
| 1608 | 1607 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 1708 | 1707 | execute_dasm - execute the dasm command |
| 1709 | 1708 | -------------------------------------------------*/ |
| 1710 | 1709 | |
| 1711 | static void execute_dasm(int ref, int params, const char *param[]) | |
| 1710 | static void execute_dasm(running_machine *machine, int ref, int params, const char *param[]) | |
| 1712 | 1711 | { |
| 1713 | 1712 | UINT64 offset, length, bytes = 1, cpunum = cpu_getactivecpu(); |
| 1714 | 1713 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 1855 | 1854 | trace over and trace info |
| 1856 | 1855 | -------------------------------------------------*/ |
| 1857 | 1856 | |
| 1858 | static void execute_trace_internal(int ref, int params, const char *param[], int trace_over) | |
| 1857 | static void execute_trace_internal(running_machine *machine, int ref, int params, const char *param[], int trace_over) | |
| 1859 | 1858 | { |
| 1860 | 1859 | const char *action = NULL, *filename = param[0]; |
| 1861 | 1860 | FILE *f = NULL; |
| r3232 | r3233 | |
| 1867 | 1866 | /* validate parameters */ |
| 1868 | 1867 | if (params > 1 && !debug_command_parameter_number(param[1], &cpunum)) |
| 1869 | 1868 | return; |
| 1870 | if (params > 2 && !debug_command_parameter_command(action = param[2])) | |
| 1869 | if (params > 2 && !debug_command_parameter_command(machine, action = param[2])) | |
| 1871 | 1870 | return; |
| 1872 | 1871 | |
| 1873 | 1872 | /* further validation */ |
| r3232 | r3233 | |
| 1912 | 1911 | execute_trace - execute the trace command |
| 1913 | 1912 | -------------------------------------------------*/ |
| 1914 | 1913 | |
| 1915 | static void execute_trace(int ref, int params, const char *param[]) | |
| 1914 | static void execute_trace(running_machine *machine, int ref, int params, const char *param[]) | |
| 1916 | 1915 | { |
| 1917 | execute_trace_internal(ref, params, param, 0); | |
| 1916 | execute_trace_internal(machine, ref, params, param, 0); | |
| 1918 | 1917 | } |
| 1919 | 1918 | |
| 1920 | 1919 | |
| r3232 | r3233 | |
| 1922 | 1921 | execute_traceover - execute the trace over command |
| 1923 | 1922 | -------------------------------------------------*/ |
| 1924 | 1923 | |
| 1925 | static void execute_traceover(int ref, int params, const char *param[]) | |
| 1924 | static void execute_traceover(running_machine *machine, int ref, int params, const char *param[]) | |
| 1926 | 1925 | { |
| 1927 | execute_trace_internal(ref, params, param, 1); | |
| 1926 | execute_trace_internal(machine, ref, params, param, 1); | |
| 1928 | 1927 | } |
| 1929 | 1928 | |
| 1930 | 1929 | |
| r3232 | r3233 | |
| 1932 | 1931 | execute_traceflush - execute the trace flush command |
| 1933 | 1932 | -------------------------------------------------*/ |
| 1934 | 1933 | |
| 1935 | static void execute_traceflush(int ref, int params, const char *param[]) | |
| 1934 | static void execute_traceflush(running_machine *machine, int ref, int params, const char *param[]) | |
| 1936 | 1935 | { |
| 1937 | 1936 | debug_cpu_flush_traces(); |
| 1938 | 1937 | } |
| r3232 | r3233 | |
| 1942 | 1941 | execute_history - execute the history command |
| 1943 | 1942 | -------------------------------------------------*/ |
| 1944 | 1943 | |
| 1945 | static void execute_history(int ref, int params, const char *param[]) | |
| 1944 | static void execute_history(running_machine *machine, int ref, int params, const char *param[]) | |
| 1946 | 1945 | { |
| 1947 | 1946 | UINT64 count = DEBUG_HISTORY_SIZE; |
| 1948 | 1947 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 1999 | 1998 | execute_snap - execute the trace over command |
| 2000 | 1999 | -------------------------------------------------*/ |
| 2001 | 2000 | |
| 2002 | static void execute_snap(int ref, int params, const char *param[]) | |
| 2001 | static void execute_snap(running_machine *machine, int ref, int params, const char *param[]) | |
| 2003 | 2002 | { |
| 2004 | 2003 | /* if no params, use the default behavior */ |
| 2005 | 2004 | if (params == 0) |
| 2006 | 2005 | { |
| 2007 | video_save_active_screen_snapshots( | |
| 2006 | video_save_active_screen_snapshots(machine); | |
| 2008 | 2007 | debug_console_printf("Saved snapshot\n"); |
| 2009 | 2008 | } |
| 2010 | 2009 | |
| r3232 | r3233 | |
| 2017 | 2016 | int scrnum = (params > 1) ? atoi(param[1]) : 0; |
| 2018 | 2017 | astring *fname; |
| 2019 | 2018 | |
| 2020 | const device_config *screen = device_list_find_by_index( | |
| 2019 | const device_config *screen = device_list_find_by_index(machine->config->devicelist, VIDEO_SCREEN, scrnum); | |
| 2021 | 2020 | |
| 2022 | 2021 | if ((screen == NULL) || !render_is_live_screen(screen)) |
| 2023 | 2022 | { |
| r3232 | r3233 | |
| 2048 | 2047 | execute_source - execute the source command |
| 2049 | 2048 | -------------------------------------------------*/ |
| 2050 | 2049 | |
| 2051 | static void execute_source(int ref, int params, const char *param[]) | |
| 2050 | static void execute_source(running_machine *machine, int ref, int params, const char *param[]) | |
| 2052 | 2051 | { |
| 2053 | debug_cpu_source_script( | |
| 2052 | debug_cpu_source_script(machine, param[0]); | |
| 2054 | 2053 | } |
| 2055 | 2054 | |
| 2056 | 2055 | |
| r3232 | r3233 | |
| 2058 | 2057 | execute_map - execute the map command |
| 2059 | 2058 | -------------------------------------------------*/ |
| 2060 | 2059 | |
| 2061 | static void execute_map(int ref, int params, const char *param[]) | |
| 2060 | static void execute_map(running_machine *machine, int ref, int params, const char *param[]) | |
| 2062 | 2061 | { |
| 2063 | 2062 | UINT64 address, cpunum = cpu_getactivecpu(); |
| 2064 | 2063 | const debug_cpu_info *info; |
| r3232 | r3233 | |
| 2074 | 2073 | /* do the translation first */ |
| 2075 | 2074 | for (intention = TRANSLATE_READ_DEBUG; intention <= TRANSLATE_FETCH_DEBUG; intention++) |
| 2076 | 2075 | { |
| 2077 | static const char *intnames[] = { "Read", "Write", "Fetch" }; | |
| 2076 | static const char *const intnames[] = { "Read", "Write", "Fetch" }; | |
| 2078 | 2077 | taddress = ADDR2BYTE_MASKED(address, info, spacenum); |
| 2079 | 2078 | if (info->translate != NULL) |
| 2080 | 2079 | { |
| r3232 | r3233 | |
| 2099 | 2098 | execute_memdump - execute the memdump command |
| 2100 | 2099 | -------------------------------------------------*/ |
| 2101 | 2100 | |
| 2102 | static void execute_memdump(int ref, int params, const char **param) | |
| 2101 | static void execute_memdump(running_machine *machine, int ref, int params, const char **param) | |
| 2103 | 2102 | { |
| 2104 | 2103 | FILE *file; |
| 2105 | 2104 | const char *filename; |
| r3232 | r3233 | |
| 2128 | 2127 | return strcmp(str1, str2); |
| 2129 | 2128 | } |
| 2130 | 2129 | |
| 2131 | static void execute_symlist(int ref, int params, const char **param) | |
| 2130 | static void execute_symlist(running_machine *machine, int ref, int params, const char **param) | |
| 2132 | 2131 | { |
| 2133 | 2132 | const char *namelist[1000]; |
| 2134 | 2133 | symbol_table *symtable; |
| r3232 | r3233 | |
| 2197 | 2196 | execute_softreset - execute the softreset command |
| 2198 | 2197 | -------------------------------------------------*/ |
| 2199 | 2198 | |
| 2200 | static void execute_softreset(int ref, int params, const char **param) | |
| 2199 | static void execute_softreset(running_machine *machine, int ref, int params, const char **param) | |
| 2201 | 2200 | { |
| 2202 | mame_schedule_soft_reset( | |
| 2201 | mame_schedule_soft_reset(machine); | |
| 2203 | 2202 | } |
| 2204 | 2203 | |
| 2205 | 2204 | |
| r3232 | r3233 | |
| 2207 | 2206 | execute_hardreset - execute the hardreset command |
| 2208 | 2207 | -------------------------------------------------*/ |
| 2209 | 2208 | |
| 2210 | static void execute_hardreset(int ref, int params, const char **param) | |
| 2209 | static void execute_hardreset(running_machine *machine, int ref, int params, const char **param) | |
| 2211 | 2210 | { |
| 2212 | mame_schedule_hard_reset( | |
| 2211 | mame_schedule_hard_reset(machine); | |
| 2213 | 2212 | } |
| r3232 | r3233 | |
|---|---|---|
| 15 | 15 | #include "debughlp.h" |
| 16 | 16 | #include "debugvw.h" |
| 17 | 17 | #include "textbuf.h" |
| 18 | #include "deprecat.h" | |
| 19 | 18 | #include "debugger.h" |
| 20 | 19 | #include <ctype.h> |
| 21 | 20 | |
| r3232 | r3233 | |
| 44 | 43 | char command[32]; |
| 45 | 44 | const char * params; |
| 46 | 45 | const char * help; |
| 47 | void (*handler)(int ref, int params, const char **param); | |
| 46 | void (*handler)(running_machine *machine, int ref, int params, const char **param); | |
| 48 | 47 | void (*handler_ex)(int ref); |
| 49 | 48 | UINT32 flags; |
| 50 | 49 | int ref; |
| r3232 | r3233 | |
| 186 | 185 | command |
| 187 | 186 | -------------------------------------------------*/ |
| 188 | 187 | |
| 189 | static CMDERR internal_execute_command(int execute, int params, char **param) | |
| 188 | static CMDERR internal_execute_command(running_machine *machine, int execute, int params, char **param) | |
| 190 | 189 | { |
| 191 | 190 | debug_command *cmd, *found = NULL; |
| 192 | 191 | int i, foundcount = 0; |
| r3232 | r3233 | |
| 248 | 247 | |
| 249 | 248 | /* execute the handler */ |
| 250 | 249 | if (execute) |
| 251 | (*found->handler)(found->ref, params, (const char **)param); | |
| 250 | (*found->handler)(machine, found->ref, params, (const char **)param); | |
| 252 | 251 | return CMDERR_NONE; |
| 253 | 252 | } |
| 254 | 253 | |
| r3232 | r3233 | |
| 258 | 257 | and either executes or just validates it |
| 259 | 258 | -------------------------------------------------*/ |
| 260 | 259 | |
| 261 | static CMDERR internal_parse_command(const char *original_command, int execute) | |
| 260 | static CMDERR internal_parse_command(running_machine *machine, const char *original_command, int execute) | |
| 262 | 261 | { |
| 263 | 262 | char command[MAX_COMMAND_LENGTH], parens[MAX_COMMAND_LENGTH]; |
| 264 | 263 | char *params[MAX_COMMAND_PARAMS]; |
| r3232 | r3233 | |
| 335 | 334 | } |
| 336 | 335 | else |
| 337 | 336 | { |
| 338 | result = internal_execute_command(execute, paramcount, ¶ms[0]); | |
| 337 | result = internal_execute_command(machine, execute, paramcount, ¶ms[0]); | |
| 339 | 338 | if (result != CMDERR_NONE) |
| 340 | 339 | return MAKE_CMDERR(CMDERR_ERROR_CLASS(result), command_start - command); |
| 341 | 340 | } |
| r3232 | r3233 | |
| 349 | 348 | command string |
| 350 | 349 | -------------------------------------------------*/ |
| 351 | 350 | |
| 352 | CMDERR debug_console_execute_command(const char *command, int echo) | |
| 351 | CMDERR debug_console_execute_command(running_machine *machine, const char *command, int echo) | |
| 353 | 352 | { |
| 354 | 353 | CMDERR result; |
| 355 | 354 | |
| r3232 | r3233 | |
| 358 | 357 | debug_console_printf(">%s\n", command); |
| 359 | 358 | |
| 360 | 359 | /* parse and execute */ |
| 361 | result = internal_parse_command(command, TRUE); | |
| 360 | result = internal_parse_command(machine, command, TRUE); | |
| 362 | 361 | |
| 363 | 362 | /* display errors */ |
| 364 | 363 | if (result != CMDERR_NONE) |
| r3232 | r3233 | |
| 373 | 372 | if (echo) |
| 374 | 373 | { |
| 375 | 374 | debug_view_update_all(); |
| 376 | debugger_refresh_display( | |
| 375 | debugger_refresh_display(machine); | |
| 377 | 376 | } |
| 378 | 377 | return result; |
| 379 | 378 | } |
| r3232 | r3233 | |
| 384 | 383 | command string |
| 385 | 384 | -------------------------------------------------*/ |
| 386 | 385 | |
| 387 | CMDERR debug_console_validate_command(const char *command) | |
| 386 | CMDERR debug_console_validate_command(running_machine *machine, const char *command) | |
| 388 | 387 | { |
| 389 | return internal_parse_command(command, FALSE); | |
| 388 | return internal_parse_command(machine, command, FALSE); | |
| 390 | 389 | } |
| 391 | 390 | |
| 392 | 391 | |
| r3232 | r3233 | |
| 395 | 394 | command handler |
| 396 | 395 | -------------------------------------------------*/ |
| 397 | 396 | |
| 398 | void debug_console_register_command(const char *command, UINT32 flags, int ref, int minparams, int maxparams, void (*handler)(int ref, int params, const char **param)) | |
| 397 | void debug_console_register_command(running_machine *machine, const char *command, UINT32 flags, int ref, int minparams, int maxparams, void (*handler)(running_machine *machine, int ref, int params, const char **param)) | |
| 399 | 398 | { |
| 400 | 399 | debug_command *cmd; |
| 401 | 400 | |
| 402 | assert_always(mame_get_phase(Machine) == MAME_PHASE_INIT, "Can only call debug_console_register_command() at init time!"); | |
| 403 | assert_always((Machine->debug_flags & DEBUG_FLAG_ENABLED) != 0, "Cannot call debug_console_register_command() when debugger is not running"); | |
| 401 | assert_always(mame_get_phase(machine) == MAME_PHASE_INIT, "Can only call debug_console_register_command() at init time!"); | |
| 402 | assert_always((machine->debug_flags & DEBUG_FLAG_ENABLED) != 0, "Cannot call debug_console_register_command() when debugger is not running"); | |
| 404 | 403 | |
| 405 | 404 | cmd = auto_malloc(sizeof(*cmd)); |
| 406 | 405 | memset(cmd, 0, sizeof(*cmd)); |
| r3232 | r3233 | |
|---|---|---|
| 816 | 816 | |
| 817 | 817 | default: |
| 818 | 818 | { |
| 819 | static const char valid[] = "abcdefghijklmnopqrstuvwxyz0123456789_$#."; | |
| 819 | static const char valid[] = "abcdefghijklmnopqrstuvwxyz0123456789_$#.:"; | |
| 820 | 820 | static const char numbers[] = "0123456789abcdef"; |
| 821 | 821 | int bufindex = 0, must_be_number = 0, numbase = DEFAULT_BASE; |
| 822 | 822 | char buffer[MAX_SYMBOL_LENGTH]; |
| r3232 | r3233 | |
|---|---|---|
| 62 | 62 | #define MAKE_CMDERR_EXPRESSION_ERROR(x) MAKE_CMDERR(CMDERR_EXPRESSION_ERROR, (x)) |
| 63 | 63 | |
| 64 | 64 | |
| 65 | ||
| 66 | 65 | /*************************************************************************** |
| 67 | 66 | TYPE DEFINITIONS |
| 68 | 67 | ***************************************************************************/ |
| r3232 | r3233 | |
| 81 | 80 | void debug_console_exit(running_machine *machine); |
| 82 | 81 | |
| 83 | 82 | /* command handling */ |
| 84 | CMDERR debug_console_execute_command(const char *command, int echo); | |
| 85 | CMDERR debug_console_validate_command(const char *command); | |
| 86 | void debug_console_register_command(const char *command, UINT32 flags, int ref, int minparams, int maxparams, void (*handler)(int ref, int params, const char **param)); | |
| 83 | CMDERR debug_console_execute_command(running_machine *machine, const char *command, int echo); | |
| 84 | CMDERR debug_console_validate_command(running_machine *machine, const char *command); | |
| 85 | void debug_console_register_command(running_machine *machine, const char *command, UINT32 flags, int ref, int minparams, int maxparams, void (*handler)(running_machine *machine, int ref, int params, const char **param)); | |
| 87 | 86 | const char * debug_cmderr_to_string(CMDERR error); |
| 88 | 87 | |
| 89 | 88 | /* console management */ |
| r3232 | r3233 | |
|---|---|---|
| 956 | 956 | |
| 957 | 957 | /* FIXME: the memory maps should probably support rom banking for EA */ |
| 958 | 958 | static ADDRESS_MAP_START(program_10bit, ADDRESS_SPACE_PROGRAM, 8) |
| 959 | AM_RANGE(0x00, 0x3ff) AM_ROM | |
| 959 | AM_RANGE(0x00, 0x3ff) AM_ROM | |
| 960 | 960 | ADDRESS_MAP_END |
| 961 | 961 | |
| 962 | 962 | static ADDRESS_MAP_START(program_11bit, ADDRESS_SPACE_PROGRAM, 8) |
| 963 | AM_RANGE(0x00, 0x7ff) AM_ROM | |
| 963 | AM_RANGE(0x00, 0x7ff) AM_ROM | |
| 964 | 964 | ADDRESS_MAP_END |
| 965 | 965 | |
| 966 | 966 | static ADDRESS_MAP_START(data_6bit, ADDRESS_SPACE_DATA, 8) |
| r3232 | r3233 | |
| 1016 | 1016 | { |
| 1017 | 1017 | /* --- the following bits of info are set as 64-bit signed integers --- */ |
| 1018 | 1018 | case CPUINFO_INT_INPUT_STATE + MCS48_INPUT_IRQ: mcs48.irq_state = (info->i != CLEAR_LINE); break; |
| 1019 | case CPUINFO_INT_INPUT_STATE + MCS48_INPUT_EA: mcs48.ea = (info->i != CLEAR_LINE); | |
| 1020 | memory_set_bank(MCS48_INTERNAL_ROMBANK, mcs48.ea); | |
| 1021 | break; | |
| 1019 | case CPUINFO_INT_INPUT_STATE + MCS48_INPUT_EA: mcs48.ea = (info->i != CLEAR_LINE); break; | |
| 1022 | 1020 | |
| 1023 | 1021 | case CPUINFO_INT_PC: |
| 1024 | 1022 | case CPUINFO_INT_REGISTER + MCS48_PC: PC = info->i; break; |
| r3232 | r3233 | |
|---|---|---|
| 18 | 18 | #include "cpuintrf.h" |
| 19 | 19 | |
| 20 | 20 | /*************************************************************************** |
| 21 | DEFINES | |
| 22 | ***************************************************************************/ | |
| 23 | ||
| 24 | #define MCS48_INTERNAL_ROMBANK (31) | |
| 25 | ||
| 26 | /*************************************************************************** | |
| 27 | 21 | CONSTANTS |
| 28 | 22 | ***************************************************************************/ |
| 29 | 23 |
| r3232 | r3233 | |
|---|---|---|
| 20 | 20 | ***************************************************************************/ |
| 21 | 21 | |
| 22 | 22 | /* Am2901 Instruction Fields */ |
| 23 | static const char* ins[] = | |
| 23 | static const char *const ins[] = | |
| 24 | 24 | { |
| 25 | 25 | "ADD ", |
| 26 | 26 | "SUBR ", |
| r3232 | r3233 | |
| 32 | 32 | "EXNOR", |
| 33 | 33 | }; |
| 34 | 34 | |
| 35 | static const char* src[] = | |
| 35 | static const char *const src[] = | |
| 36 | 36 | { |
| 37 | 37 | "A,Q", |
| 38 | 38 | "A,B", |
| r3232 | r3233 | |
| 44 | 44 | "D,0", |
| 45 | 45 | }; |
| 46 | 46 | |
| 47 | static const char* dst[] = | |
| 47 | static const char *const dst[] = | |
| 48 | 48 | { |
| 49 | 49 | "QREG ", |
| 50 | 50 | "NOP ", |
| r3232 | r3233 | |
| 749 | 749 | |
| 750 | 750 | static offs_t cquestsnd_dasm(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram) |
| 751 | 751 | { |
| 752 | static const char* jmps[] = | |
| 752 | static const char *const jmps[] = | |
| 753 | 753 | { |
| 754 | 754 | "JUMP ", |
| 755 | 755 | " ", |
| r3232 | r3233 | |
| 762 | 762 | }; |
| 763 | 763 | |
| 764 | 764 | |
| 765 | static const char* latches[] = | |
| 765 | static const char *const latches[] = | |
| 766 | 766 | { |
| 767 | 767 | "PLTCH ", |
| 768 | 768 | "DAC ", |
| r3232 | r3233 | |
| 1202 | 1202 | |
| 1203 | 1203 | static offs_t cquestrot_dasm(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram) |
| 1204 | 1204 | { |
| 1205 | static const char* jmps[] = | |
| 1205 | static const char *const jmps[] = | |
| 1206 | 1206 | { |
| 1207 | 1207 | " ", |
| 1208 | 1208 | "JSEQ ", |
| r3232 | r3233 | |
| 1223 | 1223 | "JNZERO ", |
| 1224 | 1224 | }; |
| 1225 | 1225 | |
| 1226 | static const char* youts[] = | |
| 1226 | static const char *const youts[] = | |
| 1227 | 1227 | { |
| 1228 | 1228 | " ", |
| 1229 | 1229 | " ", |
| r3232 | r3233 | |
| 1235 | 1235 | "Y2D ", |
| 1236 | 1236 | }; |
| 1237 | 1237 | |
| 1238 | static const char* spfs[] = | |
| 1238 | static const char *const spfs[] = | |
| 1239 | 1239 | { |
| 1240 | 1240 | " ", |
| 1241 | 1241 | " ", |
| r3232 | r3233 | |
| 1760 | 1760 | |
| 1761 | 1761 | static offs_t cquestlin_dasm(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram) |
| 1762 | 1762 | { |
| 1763 | static const char* jmps[] = | |
| 1763 | static const char *const jmps[] = | |
| 1764 | 1764 | { |
| 1765 | 1765 | " ", |
| 1766 | 1766 | "JMSB ", |
| r3232 | r3233 | |
| 1781 | 1781 | "?????", |
| 1782 | 1782 | }; |
| 1783 | 1783 | |
| 1784 | static const char* latches[] = | |
| 1784 | static const char *const latches[] = | |
| 1785 | 1785 | { |
| 1786 | 1786 | " ", |
| 1787 | 1787 | "SEQLTCH", |
| r3232 | r3233 | |
| 1793 | 1793 | "ZLTCH ", |
| 1794 | 1794 | }; |
| 1795 | 1795 | |
| 1796 | static const char* spfs[] = | |
| 1796 | static const char *const spfs[] = | |
| 1797 | 1797 | { |
| 1798 | 1798 | " ", |
| 1799 | 1799 | "FSTOP ", |
| r3232 | r3233 | |
|---|---|---|
| 1137 | 1137 | |
| 1138 | 1138 | void drcuml_disasm(const drcuml_instruction *inst, char *buffer, drcuml_state *drcuml) |
| 1139 | 1139 | { |
| 1140 | static const char *conditions[] = { "z", "nz", "s", "ns", "c", "nc", "v", "nv", "u", "nu", "a", "be", "g", "le", "l", "ge" }; | |
| 1141 | static const char *pound_size[] = { "?", "?", "?", "?", "s", "?", "?", "?", "d" }; | |
| 1142 | static const char *bang_size[] = { "?", "b", "h", "?", "", "?", "?", "?", "d" }; | |
| 1143 | static const char *fmods[] = { "trunc", "round", "ceil", "floor", "default" }; | |
| 1144 | static const char *sizes[] = { "byte", "word", "dword", "qword" }; | |
| 1140 | static const char *const conditions[] = { "z", "nz", "s", "ns", "c", "nc", "v", "nv", "u", "nu", "a", "be", "g", "le", "l", "ge" }; | |
| 1141 | static const char *const pound_size[] = { "?", "?", "?", "?", "s", "?", "?", "?", "d" }; | |
| 1142 | static const char *const bang_size[] = { "?", "b", "h", "?", "", "?", "?", "?", "d" }; | |
| 1143 | static const char *const fmods[] = { "trunc", "round", "ceil", "floor", "default" }; | |
| 1144 | static const char *const sizes[] = { "byte", "word", "dword", "qword" }; | |
| 1145 | 1145 | const drcuml_opcode_info *opinfo = opcode_info_table[inst->opcode]; |
| 1146 | 1146 | char *dest = buffer; |
| 1147 | 1147 | const char *opsrc; |
| r3232 | r3233 | |
|---|---|---|
| 173 | 173 | #include "drcuml.h" |
| 174 | 174 | #include "drcbeut.h" |
| 175 | 175 | #include "debugger.h" |
| 176 | #include "deprecat.h" | |
| 176 | 177 | #include "x86emit.h" |
| 177 | 178 | #include "eminline.h" |
| 178 | 179 | #undef REG_SP |
| r3232 | r3233 | |
| 339 | 340 | static const UINT64 size_to_mask[] = { 0, 0xff, 0xffff, 0, 0xffffffff, 0, 0, 0, U64(0xffffffffffffffff) }; |
| 340 | 341 | |
| 341 | 342 | /* register mapping tables */ |
| 342 | static UINT8 int_register_map[DRCUML_REG_I_END - DRCUML_REG_I0] = | |
| 343 | static const UINT8 int_register_map[DRCUML_REG_I_END - DRCUML_REG_I0] = | |
| 343 | 344 | { |
| 344 | 345 | #ifdef X64_WINDOWS_ABI |
| 345 | 346 | REG_RBX, REG_RSI, REG_RDI, REG_R12, REG_R13, REG_R14, REG_R15 |
| r3232 | r3233 | |
| 354 | 355 | }; |
| 355 | 356 | |
| 356 | 357 | /* condition mapping table */ |
| 357 | static UINT8 condition_map[DRCUML_COND_MAX - DRCUML_COND_Z] = | |
| 358 | static const UINT8 condition_map[DRCUML_COND_MAX - DRCUML_COND_Z] = | |
| 358 | 359 | { |
| 359 | 360 | COND_Z, /* DRCUML_COND_Z = 0x80, requires Z */ |
| 360 | 361 | COND_NZ, /* DRCUML_COND_NZ, requires Z */ |
| r3232 | r3233 | |
|---|---|---|
| 116 | 116 | static jaguar_regs jaguar; |
| 117 | 117 | static UINT16 * mirror_table; |
| 118 | 118 | static UINT8 * condition_table; |
| 119 | static int executing_cpu | |
| 119 | static int executing_cpu | |
| 120 | 120 | |
| 121 | 121 | static const UINT32 convert_zero[32] = |
| 122 | 122 | { 32,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 }; |
| r3232 | r3233 | |
| 460 | 460 | { |
| 461 | 461 | init_tables(); |
| 462 | 462 | |
| 463 | executing_cpu = -1; | |
| 463 | 464 | jaguar.b0 = jaguar.r; |
| 464 | 465 | jaguar.b1 = jaguar.a; |
| 465 | 466 |
| r3232 | r3233 | |
|---|---|---|
| 8 | 8 | I8085_PC=1, I8085_SP, I8085_AF ,I8085_BC, I8085_DE, I8085_HL, |
| 9 | 9 | I8085_HALT, I8085_IM, I8085_IREQ, I8085_ISRV, I8085_VECTOR, |
| 10 | 10 | I8085_TRAP_STATE, I8085_INTR_STATE, |
| 11 | I8085_RST55_STATE, I8085_RST65_STATE, I8085_RST75_STATE | |
| 11 | I8085_RST55_STATE, I8085_RST65_STATE, I8085_RST75_STATE, I8085_STATUS | |
| 12 | 12 | }; |
| 13 | 13 | |
| 14 | 14 | enum |
| r3232 | r3233 | |
| 41 | 41 | #define I8080_VECTOR I8085_VECTOR |
| 42 | 42 | #define I8080_TRAP_STATE I8085_TRAP_STATE |
| 43 | 43 | #define I8080_INTR_STATE I8085_INTR_STATE |
| 44 | ||
| 44 | #define I8080_STATUS I8085_STATUS | |
| 45 | 45 | #define I8080_REG_LAYOUT \ |
| 46 | 46 | { CPU_8080, \ |
| 47 | 47 | I8080_AF,I8080_BC,I8080_DE,I8080_HL,I8080_SP,I8080_PC, DBG_ROW, \ |
| 48 | I8080_HALT,I8080_IREQ,I8080_ISRV,I8080_VECTOR, \ | |
| 48 | I8080_HALT,I8080_IREQ,I8080_ISRV,I8080_VECTOR, I8080_STATUS, \ | |
| 49 | 49 | DBG_END } |
| 50 | 50 | |
| 51 | 51 | #define I8080_INTR_LINE I8085_INTR_LINE |
| r3232 | r3233 | |
|---|---|---|
| 41 | 41 | #define M_DCR(R) {UINT8 hc = ((R & 0x0f) == 0x00) ? HF : 0; --R; I.AF.b.l= (I.AF.b.l & CF ) | ZSP[R] | hc | NF; } |
| 42 | 42 | #define M_MVI(R) R=ARG() |
| 43 | 43 | |
| 44 | #define M_ANA(R) { int i = ((I.AF.b.h | R)>>3)& | |
| 44 | #define M_ANA(R) { int i = (((I.AF.b.h | R)>>3) & | |
| 45 | 45 | #define M_ORA(R) I.AF.b.h|=R; I.AF.b.l=ZSP[I.AF.b.h] |
| 46 | 46 | #define M_XRA(R) I.AF.b.h^=R; I.AF.b.l=ZSP[I.AF.b.h] |
| 47 | 47 | |
| r3232 | r3233 | |
| 107 | 107 | } |
| 108 | 108 | |
| 109 | 109 | #define M_IN \ |
| 110 | I.STATUS = 0x42; \ | |
| 110 | 111 | I.XX.d=ARG(); \ |
| 111 | 112 | I.AF.b.h=io_read_byte_8le(I.XX.d); |
| 112 | 113 | |
| 113 | 114 | #define M_OUT \ |
| 115 | I.STATUS = 0x10; \ | |
| 114 | 116 | I.XX.d=ARG(); \ |
| 115 | 117 | io_write_byte_8le(I.XX.d,I.AF.b.h) |
| 116 | 118 | |
| r3232 | r3233 | |
| 123 | 125 | } |
| 124 | 126 | |
| 125 | 127 | #define M_PUSH(R) { \ |
| 126 | WM(--I.SP.w.l, I.R.b.h); \ | |
| 127 | WM(--I.SP.w.l, I.R.b.l); \ | |
| 128 | I.STATUS = 0x04; \ | |
| 129 | program_write_byte_8le(--I.SP.w.l, I.R.b.h); \ | |
| 130 | program_write_byte_8le(--I.SP.w.l, I.R.b.l); \ | |
| 128 | 131 | } |
| 129 | 132 | |
| 130 | 133 | #define M_POP(R) { \ |
| 131 | I.R.b.l = RM(I.SP.w.l++); \ | |
| 132 | I.R.b.h = RM(I.SP.w.l++); \ | |
| 134 | I.STATUS = 0x86; \ | |
| 135 | I.R.b.l = program_read_byte_8le(I.SP.w.l++); \ | |
| 136 | I.R.b.h = program_read_byte_8le(I.SP.w.l++); \ | |
| 133 | 137 | } |
| 134 | 138 | |
| 135 | 139 | #define M_RET(cc) \ |
| r3232 | r3233 | |
|---|---|---|
| 146 | 146 | UINT32 INTR; /* vector for INTR */ |
| 147 | 147 | UINT32 IRQ2; /* scheduled interrupt address */ |
| 148 | 148 | UINT32 IRQ1; /* executed interrupt address */ |
| 149 | UINT8 STATUS; /* status word */ | |
| 149 | 150 | INT8 irq_state[4]; |
| 150 | 151 | int (*irq_callback)(int); |
| 151 | 152 | void (*sod_callback)(int state); |
| r3232 | r3233 | |
| 160 | 161 | static UINT8 RIM_IEN = 0; //AT: IEN status latch used by the RIM instruction |
| 161 | 162 | static UINT8 ROP(void) |
| 162 | 163 | { |
| 164 | I.STATUS = 0xa2; // instruction fetch | |
| 163 | 165 | return cpu_readop(I.PC.w.l++); |
| 164 | 166 | } |
| 165 | 167 | |
| r3232 | r3233 | |
| 180 | 182 | |
| 181 | 183 | static UINT8 RM(UINT32 a) |
| 182 | 184 | { |
| 185 | I.STATUS = 0x82; // memory read | |
| 183 | 186 | return program_read_byte_8le(a); |
| 184 | 187 | } |
| 185 | 188 | |
| 186 | 189 | static void WM(UINT32 a, UINT8 v) |
| 187 | 190 | { |
| 191 | I.STATUS = 0x00; // memory write | |
| 188 | 192 | program_write_byte_8le(a, v); |
| 189 | 193 | } |
| 190 | 194 | |
| r3232 | r3233 | |
| 684 | 688 | case 0x76: i8085_ICount -= (I.cputype) ? 5 : 7; /* HLT */ |
| 685 | 689 | I.PC.w.l--; |
| 686 | 690 | I.HALT = 1; |
| 691 | I.STATUS = 0x8a; // halt acknowledge | |
| 687 | 692 | if (i8085_ICount > 0) i8085_ICount = 0; |
| 688 | 693 | break; |
| 689 | 694 | case 0x77: i8085_ICount -= 7; /* MOV M,A */ |
| r3232 | r3233 | |
| 1216 | 1221 | M_RST(7); |
| 1217 | 1222 | break; |
| 1218 | 1223 | } |
| 1224 | /* For 8080 NF flag is not used but bit is always set */ | |
| 1225 | if(!I.cputype ) { | |
| 1226 | I.AF.b.l = I.AF.b.l | NF; | |
| 1227 | } | |
| 1219 | 1228 | } |
| 1220 | 1229 | |
| 1221 | 1230 | static void Interrupt(void) |
| r3232 | r3233 | |
| 1225 | 1234 | { |
| 1226 | 1235 | I.PC.w.l++; /* skip HALT instr */ |
| 1227 | 1236 | I.HALT = 0; |
| 1237 | I.STATUS = 0x26; // int ack while halt | |
| 1238 | } else { | |
| 1239 | I.STATUS = 0x23; // int ack | |
| 1228 | 1240 | } |
| 1229 | 1241 | //AT |
| 1230 | 1242 | I.IREQ &= ~I.ISRV; // remove serviced IRQ flag |
| r3232 | r3233 | |
| 1367 | 1379 | state_save_register_item("i8085", index, I.INTR); |
| 1368 | 1380 | state_save_register_item("i8085", index, I.IRQ2); |
| 1369 | 1381 | state_save_register_item("i8085", index, I.IRQ1); |
| 1382 | state_save_register_item("i8085", index, I.STATUS); | |
| 1370 | 1383 | state_save_register_item_array("i8085", index, I.irq_state); |
| 1371 | 1384 | } |
| 1372 | 1385 | |
| r3232 | r3233 | |
| 1601 | 1614 | state_save_register_item("i8080", index, I.INTR); |
| 1602 | 1615 | state_save_register_item("i8080", index, I.IRQ2); |
| 1603 | 1616 | state_save_register_item("i8080", index, I.IRQ1); |
| 1617 | state_save_register_item("i8080", index, I.STATUS); | |
| 1604 | 1618 | state_save_register_item_array("i8080", index, I.irq_state); |
| 1605 | 1619 | } |
| 1606 | 1620 | |
| r3232 | r3233 | |
| 1657 | 1671 | case CPUINFO_INT_REGISTER + I8085_IREQ: I.IREQ = info->i; break; |
| 1658 | 1672 | case CPUINFO_INT_REGISTER + I8085_ISRV: I.ISRV = info->i; break; |
| 1659 | 1673 | case CPUINFO_INT_REGISTER + I8085_VECTOR: I.INTR = info->i; break; |
| 1674 | case CPUINFO_INT_REGISTER + I8085_STATUS: I.STATUS = info->i; break; | |
| 1660 | 1675 | |
| 1661 | 1676 | case CPUINFO_INT_I8085_SID: if (info->i) I.IM |= IM_SID; else I.IM &= ~IM_SID; break; |
| 1662 | 1677 | |
| r3232 | r3233 | |
| 1719 | 1734 | case CPUINFO_INT_REGISTER + I8085_IREQ: info->i = I.IREQ; break; |
| 1720 | 1735 | case CPUINFO_INT_REGISTER + I8085_ISRV: info->i = I.ISRV; break; |
| 1721 | 1736 | case CPUINFO_INT_REGISTER + I8085_VECTOR: info->i = I.INTR; break; |
| 1737 | case CPUINFO_INT_REGISTER + I8085_STATUS: info->i = I.STATUS; break; | |
| 1722 | 1738 | |
| 1723 | 1739 | /* --- the following bits of info are returned as pointers to data or functions --- */ |
| 1724 | 1740 | case CPUINFO_PTR_SET_INFO: info->setinfo = i8085_set_info; break; |
| r3232 | r3233 | |
| 1762 | 1778 | case CPUINFO_STR_REGISTER + I8085_IREQ: sprintf(info->s, "IREQ:%02X", I.IREQ); break; |
| 1763 | 1779 | case CPUINFO_STR_REGISTER + I8085_ISRV: sprintf(info->s, "ISRV:%02X", I.ISRV); break; |
| 1764 | 1780 | case CPUINFO_STR_REGISTER + I8085_VECTOR: sprintf(info->s, "VEC:%02X", I.INTR); break; |
| 1781 | case CPUINFO_STR_REGISTER + I8085_STATUS: sprintf(info->s, "SW:%02X", I.STATUS); break; | |
| 1765 | 1782 | } |
| 1766 | 1783 | } |
| 1767 | 1784 |
| r3232 | r3233 | |
|---|---|---|
| 4037 | 4037 | |
| 4038 | 4038 | static void log_register_list(drcuml_state *drcuml, const char *string, const UINT32 *reglist, const UINT32 *regnostarlist) |
| 4039 | 4039 | { |
| 4040 | static const char *crtext[4] = { "lt", "gt", "eq", "so" }; | |
| 4040 | static const char *const crtext[4] = { "lt", "gt", "eq", "so" }; | |
| 4041 | 4041 | int count = 0; |
| 4042 | 4042 | int regnum; |
| 4043 | 4043 | int crnum; |
| r3232 | r3233 | |
|---|---|---|
| 132 | 132 | address &= ~0x07; |
| 133 | 133 | } |
| 134 | 134 | |
| 135 | result = (UINT32 *) memory_get_op_ptr(cpu_getactivecpu(), address, 0); | |
| 135 | result = (UINT32 *) memory_get_op_ptr(Machine, cpu_getactivecpu(), address, 0); | |
| 136 | 136 | if (result) |
| 137 | 137 | result += offset; |
| 138 | 138 | return result; |
| r3232 | r3233 | |
|---|---|---|
| 239 | 239 | static const UINT64 size_to_mask[] = { 0, 0xff, 0xffff, 0, 0xffffffff, 0, 0, 0, U64(0xffffffffffffffff) }; |
| 240 | 240 | |
| 241 | 241 | /* register mapping tables */ |
| 242 | static UINT8 int_register_map[DRCUML_REG_I_END - DRCUML_REG_I0] = | |
| 242 | static const UINT8 int_register_map[DRCUML_REG_I_END - DRCUML_REG_I0] = | |
| 243 | 243 | { |
| 244 | 244 | REG_EBX, REG_ESI, REG_EDI, REG_EBP |
| 245 | 245 | }; |
| r3232 | r3233 | |
| 249 | 249 | static UINT32 flags_unmap[0x20]; |
| 250 | 250 | |
| 251 | 251 | /* condition mapping table */ |
| 252 | static UINT8 condition_map[DRCUML_COND_MAX - DRCUML_COND_Z] = | |
| 252 | static const UINT8 condition_map[DRCUML_COND_MAX - DRCUML_COND_Z] = | |
| 253 | 253 | { |
| 254 | 254 | COND_Z, /* DRCUML_COND_Z = 0x80, requires Z */ |
| 255 | 255 | COND_NZ, /* DRCUML_COND_NZ, requires Z */ |
| r3232 | r3233 | |
|---|---|---|
| 565 | 565 | tag and index |
| 566 | 566 | -------------------------------------------------*/ |
| 567 | 567 | |
| 568 | sound_stream *stream_find_by_tag(void *streamtag, int streamindex) | |
| 568 | sound_stream *stream_find_by_tag(running_machine *machine, void *streamtag, int streamindex) | |
| 569 | 569 | { |
| 570 | streams_private *strdata = | |
| 570 | streams_private *strdata = machine->streams_data; | |
| 571 | 571 | sound_stream *stream; |
| 572 | 572 | |
| 573 | 573 | /* scan the list looking for the nth stream that matches the tag */ |
| r3232 | r3233 | |
|---|---|---|
| 15 | 15 | #include "rendfont.h" |
| 16 | 16 | #include "rendutil.h" |
| 17 | 17 | #include "uigfx.h" |
| 18 | #include "deprecat.h" | |
| 19 | 18 | |
| 20 | 19 | |
| 21 | 20 | |
| r3232 | r3233 | |
| 84 | 83 | |
| 85 | 84 | /* graphics set handling */ |
| 86 | 85 | static void gfxset_handle_keys(running_machine *machine, ui_gfx_state *state, int xcells, int ycells); |
| 87 | static void gfxset_draw_item(const gfx_element *gfx, int index, bitmap_t *bitmap, int dstx, int dsty, int color, int rotate); | |
| 88 | static void gfxset_update_bitmap(ui_gfx_state *state, int xcells, int ycells, gfx_element *gfx); | |
| 86 | static void gfxset_draw_item(running_machine *machine, const gfx_element *gfx, int index, bitmap_t *bitmap, int dstx, int dsty, int color, int rotate); | |
| 87 | static void gfxset_update_bitmap(running_machine *machine, ui_gfx_state *state, int xcells, int ycells, gfx_element *gfx); | |
| 89 | 88 | static void gfxset_handler(running_machine *machine, ui_gfx_state *state); |
| 90 | 89 | |
| 91 | 90 | /* tilemap handling */ |
| 92 | 91 | static void tilemap_handle_keys(running_machine *machine, ui_gfx_state *state, int viswidth, int visheight); |
| 93 | static void tilemap_update_bitmap(ui_gfx_state *state, int width, int height); | |
| 92 | static void tilemap_update_bitmap(running_machine *machine, ui_gfx_state *state, int width, int height); | |
| 94 | 93 | static void tilemap_handler(running_machine *machine, ui_gfx_state *state); |
| 95 | 94 | |
| 96 | 95 | |
| r3232 | r3233 | |
| 570 | 569 | } |
| 571 | 570 | |
| 572 | 571 | /* update the bitmap */ |
| 573 | gfxset_update_bitmap(state, xcells, ycells, gfx); | |
| 572 | gfxset_update_bitmap(machine, state, xcells, ycells, gfx); | |
| 574 | 573 | |
| 575 | 574 | /* add the final quad */ |
| 576 | 575 | render_ui_add_quad(boxbounds.x0 + 6.0f * chwidth, boxbounds.y0 + 3.5f * chheight, |
| r3232 | r3233 | |
| 681 | 680 | graphics view bitmap |
| 682 | 681 | -------------------------------------------------*/ |
| 683 | 682 | |
| 684 | static void gfxset_update_bitmap(ui_gfx_state *state, int xcells, int ycells, gfx_element *gfx) | |
| 683 | static void gfxset_update_bitmap(running_machine *machine, ui_gfx_state *state, int xcells, int ycells, gfx_element *gfx) | |
| 685 | 684 | { |
| 686 | 685 | int set = state->gfxset.set; |
| 687 | 686 | int cellxpix, cellypix; |
| r3232 | r3233 | |
| 737 | 736 | |
| 738 | 737 | /* only render if there is data */ |
| 739 | 738 | if (index < gfx->total_elements) |
| 740 | gfxset_draw_item(gfx, index, state->bitmap, cellbounds.min_x, cellbounds.min_y, state->gfxset.color[set], state->gfxset.rotate[set]); | |
| 739 | gfxset_draw_item(machine, gfx, index, state->bitmap, cellbounds.min_x, cellbounds.min_y, state->gfxset.color[set], state->gfxset.rotate[set]); | |
| 741 | 740 | |
| 742 | 741 | /* otherwise, fill with transparency */ |
| 743 | 742 | else |
| r3232 | r3233 | |
| 762 | 761 | the view |
| 763 | 762 | -------------------------------------------------*/ |
| 764 | 763 | |
| 765 | static void gfxset_draw_item(const gfx_element *gfx, int index, bitmap_t *bitmap, int dstx, int dsty, int color, int rotate) | |
| 764 | static void gfxset_draw_item(running_machine *machine, const gfx_element *gfx, int index, bitmap_t *bitmap, int dstx, int dsty, int color, int rotate) | |
| 766 | 765 | { |
| 767 | 766 | static const pen_t default_palette[] = |
| 768 | 767 | { |
| r3232 | r3233 | |
| 771 | 770 | }; |
| 772 | 771 | int width = (rotate & ORIENTATION_SWAP_XY) ? gfx->height : gfx->width; |
| 773 | 772 | int height = (rotate & ORIENTATION_SWAP_XY) ? gfx->width : gfx->height; |
| 774 | const rgb_t *palette = ( | |
| 773 | const rgb_t *palette = (machine->config->total_colors != 0) ? palette_entry_list_raw(machine->palette) : NULL; | |
| 775 | 774 | UINT32 rowpixels = bitmap->rowpixels; |
| 776 | 775 | UINT32 palette_mask = ~0; |
| 777 | 776 | int x, y; |
| r3232 | r3233 | |
| 931 | 930 | } |
| 932 | 931 | |
| 933 | 932 | /* update the bitmap */ |
| 934 | tilemap_update_bitmap(state, mapboxwidth / pixelscale, mapboxheight / pixelscale); | |
| 933 | tilemap_update_bitmap(machine, state, mapboxwidth / pixelscale, mapboxheight / pixelscale); | |
| 935 | 934 | |
| 936 | 935 | /* add the final quad */ |
| 937 | 936 | render_ui_add_quad(mapboxbounds.x0, mapboxbounds.y0, |
| r3232 | r3233 | |
| 1032 | 1031 | for the tilemap view |
| 1033 | 1032 | -------------------------------------------------*/ |
| 1034 | 1033 | |
| 1035 | static void tilemap_update_bitmap(ui_gfx_state *state, int width, int height) | |
| 1034 | static void tilemap_update_bitmap(running_machine *machine, ui_gfx_state *state, int width, int height) | |
| 1036 | 1035 | { |
| 1037 | bitmap_format screen_format = video_screen_get_format( | |
| 1036 | bitmap_format screen_format = video_screen_get_format(machine->primary_screen); | |
| 1038 | 1037 | int screen_texformat; |
| 1039 | 1038 | |
| 1040 | 1039 | /* convert the screen format to a texture format */ |
| r3232 | r3233 | |
|---|---|---|
| 78 | 78 | /* ----- stream information and control ----- */ |
| 79 | 79 | |
| 80 | 80 | /* find a stream using a tag and index */ |
| 81 | sound_stream *stream_find_by_tag(void *streamtag, int streamindex); | |
| 81 | sound_stream *stream_find_by_tag(running_machine *machine, void *streamtag, int streamindex); | |
| 82 | 82 | |
| 83 | 83 | /* return the number of inputs for a given stream */ |
| 84 | 84 | int stream_get_inputs(sound_stream *stream); |
| r3232 | r3233 | |
|---|---|---|
| 839 | 839 | state_save_register_item(unique_tag, 0, cdp1869->toneamp); |
| 840 | 840 | state_save_register_item(unique_tag, 0, cdp1869->wnfreq); |
| 841 | 841 | state_save_register_item(unique_tag, 0, cdp1869->wnamp); |
| 842 | ||
| 843 | return DEVICE_START_OK; | |
| 842 | 844 | } |
| 843 | 845 | |
| 844 | 846 | static DEVICE_SET_INFO( cdp1869 ) |
| r3232 | r3233 | |
|---|---|---|
| 4616 | 4616 | |
| 4617 | 4617 | /* register for save states */ |
| 4618 | 4618 | init_save_state(device); |
| 4619 | ||
| 4620 | return DEVICE_START_OK; | |
| 4619 | 4621 | } |
| 4620 | 4622 | |
| 4621 | 4623 |
| r3232 | r3233 | |
|---|---|---|
| 675 | 675 | |
| 676 | 676 | |
| 677 | 677 | /* device interface */ |
| 678 | static v | |
| 678 | static dev | |
| 679 | 679 | { |
| 680 | 680 | mc6845_t *mc6845 = get_safe_token(device); |
| 681 | 681 | char unique_tag[30]; |
| r3232 | r3233 | |
| 746 | 746 | state_save_register_item(unique_tag, 0, mc6845->light_pen_latched); |
| 747 | 747 | state_save_register_item(unique_tag, 0, mc6845->cursor_state); |
| 748 | 748 | state_save_register_item(unique_tag, 0, mc6845->cursor_blink_count); |
| 749 | ||
| 750 | return DEVICE_START_OK; | |
| 749 | 751 | } |
| 750 | 752 | |
| 751 | 753 | static DEVICE_START( mc6845 ) |
| 752 | 754 | { |
| 753 | common_start(device, TYPE_MC6845); | |
| 755 | return common_start(device, TYPE_MC6845); | |
| 754 | 756 | } |
| 755 | 757 | |
| 756 | 758 | static DEVICE_START( mc6845_1 ) |
| 757 | 759 | { |
| 758 | common_start(device, TYPE_MC6845_1); | |
| 760 | return common_start(device, TYPE_MC6845_1); | |
| 759 | 761 | } |
| 760 | 762 | |
| 761 | 763 | static DEVICE_START( c6545_1 ) |
| 762 | 764 | { |
| 763 | common_start(device, TYPE_C6545_1); | |
| 765 | return common_start(device, TYPE_C6545_1); | |
| 764 | 766 | } |
| 765 | 767 | |
| 766 | 768 | static DEVICE_START( r6545_1 ) |
| 767 | 769 | { |
| 768 | common_start(device, TYPE_R6545_1); | |
| 770 | return common_start(device, TYPE_R6545_1); | |
| 769 | 771 | } |
| 770 | 772 | |
| 771 | 773 | static DEVICE_START( h46505 ) |
| 772 | 774 | { |
| 773 | common_start(device, TYPE_H46505); | |
| 775 | return common_start(device, TYPE_H46505); | |
| 774 | 776 | } |
| 775 | 777 | |
| 776 | 778 | static DEVICE_START( hd6845 ) |
| 777 | 779 | { |
| 778 | common_start(device, TYPE_HD6845); | |
| 780 | return common_start(device, TYPE_HD6845); | |
| 779 | 781 | } |
| 780 | 782 | |
| 781 | 783 | static DEVICE_START( sy6545_1 ) |
| 782 | 784 | { |
| 783 | common_start(device, TYPE_SY6545_1); | |
| 785 | return common_start(device, TYPE_SY6545_1); | |
| 784 | 786 | } |
| 785 | 787 | |
| 786 | 788 |
| r3232 | r3233 | |
|---|---|---|
| 357 | 357 | the XML output |
| 358 | 358 | -------------------------------------------------*/ |
| 359 | 359 | |
| 360 | static void print_game_rom(FILE *out, const game_driver *game) | |
| 360 | static void print_game_rom(FILE *out, const game_driver *game, const machine_config *config) | |
| 361 | 361 | { |
| 362 | 362 | const game_driver *clone_of = driver_get_clone(game); |
| 363 | 363 | int rom_type; |
| 364 | 364 | |
| 365 | /* if no roms, just exit early */ | |
| 366 | if (game->rom == NULL) | |
| 367 | return; | |
| 368 | ||
| 369 | 365 | /* iterate over 3 different ROM "types": BIOS, ROMs, DISKs */ |
| 370 | 366 | for (rom_type = 0; rom_type < 3; rom_type++) |
| 371 | 367 | { |
| 368 | const rom_source *source; | |
| 372 | 369 | const rom_entry *region; |
| 373 | 370 | |
| 374 | /* iterate first through regions */ | |
| 375 | for (region = rom_first_region(game); region != NULL; region = rom_next_region(region)) | |
| 376 | { | |
| 377 | int is_disk = ROMREGION_ISDISKDATA(region); | |
| 378 | const rom_entry *rom; | |
| 379 | ||
| 380 | /* disk regions only work for disks */ | |
| 381 | if ((is_disk && rom_type != 2) || (!is_disk && rom_type == 2)) | |
| 382 | continue; | |
| 383 | ||
| 384 | /* iterate through ROM entries */ | |
| 385 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 371 | /* iterate over ROM sources: first the game, then any devices */ | |
| 372 | for (source = rom_first_source(game, config); source != NULL; source = rom_next_source(game, config, source)) | |
| 373 | for (region = rom_first_region(game, source); region != NULL; region = rom_next_region(region)) | |
| 386 | 374 | { |
| 387 | int is_bios = ROM_GETBIOSFLAGS(rom); | |
| 388 | const char *name = ROM_GETNAME(rom); | |
| 389 | int offset = ROM_GETOFFSET(rom); | |
| 390 | const rom_entry *parent_rom = NULL; | |
| 391 | const rom_entry *chunk; | |
| 392 | char bios_name[100]; | |
| 393 | int length; | |
| 375 | int is_disk = ROMREGION_ISDISKDATA(region); | |
| 376 | const rom_entry *rom; | |
| 394 | 377 | |
| 395 | /* BIOS ROMs only apply to bioses */ | |
| 396 | if ((is_bios && rom_type != 0) || (!is_bios && rom_type == 0)) | |
| 378 | /* disk regions only work for disks */ | |
| 379 | if ((is_disk && rom_type != 2) || (!is_disk && rom_type == 2)) | |
| 397 | 380 | continue; |
| 398 | 381 | |
| 399 | /* compute the total length of all chunks */ | |
| 400 | length = 0; | |
| 401 | for (chunk = rom_first_chunk(rom); chunk; chunk = rom_next_chunk(chunk)) | |
| 402 | length += ROM_GETLENGTH(chunk); | |
| 403 | ||
| 404 | /* if we have a valid ROM and we are a clone, see if we can find the parent ROM */ | |
| 405 | if (!ROM_NOGOODDUMP(rom) && clone_of != NULL) | |
| 382 | /* iterate through ROM entries */ | |
| 383 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 406 | 384 | { |
| 407 | const rom_entry *pregion, *prom; | |
| 385 | int is_bios = ROM_GETBIOSFLAGS(rom); | |
| 386 | const char *name = ROM_GETNAME(rom); | |
| 387 | int offset = ROM_GETOFFSET(rom); | |
| 388 | const rom_entry *parent_rom = NULL; | |
| 389 | const rom_entry *chunk; | |
| 390 | char bios_name[100]; | |
| 391 | int length; | |
| 408 | 392 | |
| 409 | /* scan the clone_of ROM for a matching ROM entry */ | |
| 410 | for (pregion = rom_first_region(clone_of); pregion != NULL; pregion = rom_next_region(pregion)) | |
| 411 | for (prom = rom_first_file(pregion); prom != NULL; prom = rom_next_file(prom)) | |
| 412 | if (hash_data_is_equal(ROM_GETHASHDATA(rom), ROM_GETHASHDATA(prom), 0)) | |
| 393 | /* BIOS ROMs only apply to bioses */ | |
| 394 | if ((is_bios && rom_type != 0) || (!is_bios && rom_type == 0)) | |
| 395 | continue; | |
| 396 | ||
| 397 | /* compute the total length of all chunks */ | |
| 398 | length = 0; | |
| 399 | for (chunk = rom_first_chunk(rom); chunk; chunk = rom_next_chunk(chunk)) | |
| 400 | length += ROM_GETLENGTH(chunk); | |
| 401 | ||
| 402 | /* if we have a valid ROM and we are a clone, see if we can find the parent ROM */ | |
| 403 | if (!ROM_NOGOODDUMP(rom) && clone_of != NULL) | |
| 404 | { | |
| 405 | const rom_entry *pregion, *prom; | |
| 406 | ||
| 407 | /* scan the clone_of ROM for a matching ROM entry */ | |
| 408 | for (pregion = rom_first_region(clone_of, NULL); pregion != NULL; pregion = rom_next_region(pregion)) | |
| 409 | for (prom = rom_first_file(pregion); prom != NULL; prom = rom_next_file(prom)) | |
| 410 | if (hash_data_is_equal(ROM_GETHASHDATA(rom), ROM_GETHASHDATA(prom), 0)) | |
| 411 | { | |
| 412 | parent_rom = prom; | |
| 413 | break; | |
| 414 | } | |
| 415 | } | |
| 416 | ||
| 417 | /* scan for a BIOS name */ | |
| 418 | bios_name[0] = 0; | |
| 419 | if (!is_disk && is_bios) | |
| 420 | { | |
| 421 | const rom_entry *brom; | |
| 422 | ||
| 423 | /* scan backwards through the ROM entries */ | |
| 424 | for (brom = rom - 1; brom != game->rom; brom--) | |
| 425 | if (ROMENTRY_ISSYSTEM_BIOS(brom)) | |
| 413 | 426 | { |
| 414 | | |
| 427 | s | |
| 415 | 428 | break; |
| 416 | 429 | } |
| 417 | } | |
| 430 | } | |
| 418 | 431 | |
| 419 | /* scan for a BIOS name */ | |
| 420 | bios_name[0] = 0; | |
| 421 | if (!is_disk && is_bios) | |
| 422 | { | |
| 423 | const rom_entry *brom; | |
| 432 | /* opening tag */ | |
| 433 | if (!is_disk) | |
| 434 | fprintf(out, "\t\t<rom"); | |
| 435 | else | |
| 436 | fprintf(out, "\t\t<disk"); | |
| 424 | 437 | |
| 425 | /* scan backwards through the ROM entries */ | |
| 426 | for (brom = rom - 1; brom != game->rom; brom--) | |
| 427 | if (ROMENTRY_ISSYSTEM_BIOS(brom)) | |
| 428 | { | |
| 429 | strcpy(bios_name, ROM_GETNAME(brom)); | |
| 430 | break; | |
| 431 | } | |
| 432 | } | |
| 438 | /* add name, merge, bios, and size tags */ | |
| 439 | if (name != NULL && name[0] != 0) | |
| 440 | fprintf(out, " name=\"%s\"", xml_normalize_string(name)); | |
| 441 | if (parent_rom != NULL) | |
| 442 | fprintf(out, " merge=\"%s\"", xml_normalize_string(ROM_GETNAME(parent_rom))); | |
| 443 | if (bios_name[0] != 0) | |
| 444 | fprintf(out, " bios=\"%s\"", xml_normalize_string(bios_name)); | |
| 445 | if (!is_disk) | |
| 446 | fprintf(out, " size=\"%d\"", length); | |
| 433 | 447 | |
| 434 | /* opening tag */ | |
| 435 | if (!is_disk) | |
| 436 | fprintf(out, "\t\t<rom"); | |
| 437 | else | |
| 438 | fprintf(out, "\t\t<disk"); | |
| 448 | /* dump checksum information only if there is a known dump */ | |
| 449 | if (!hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 450 | { | |
| 451 | char checksum[HASH_BUF_SIZE]; | |
| 452 | int hashtype; | |
| 439 | 453 | |
| 440 | /* add name, merge, bios, and size tags */ | |
| 441 | if (name != NULL && name[0] != 0) | |
| 442 | fprintf(out, " name=\"%s\"", xml_normalize_string(name)); | |
| 443 | if (parent_rom != NULL) | |
| 444 | fprintf(out, " merge=\"%s\"", xml_normalize_string(ROM_GETNAME(parent_rom))); | |
| 445 | if (bios_name[0] != 0) | |
| 446 | fprintf(out, " bios=\"%s\"", xml_normalize_string(bios_name)); | |
| 447 | if (!is_disk) | |
| 448 | fprintf(out, " size=\"%d\"", length); | |
| 454 | /* iterate over hash function types and print out their values */ | |
| 455 | for (hashtype = 0; hashtype < HASH_NUM_FUNCTIONS; hashtype++) | |
| 456 | if (hash_data_extract_printable_checksum(ROM_GETHASHDATA(rom), 1 << hashtype, checksum)) | |
| 457 | fprintf(out, " %s=\"%s\"", hash_function_name(1 << hashtype), checksum); | |
| 458 | } | |
| 449 | 459 | |
| 450 | /* dump checksum information only if there is a known dump */ | |
| 451 | if (!hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 452 | { | |
| 453 | char checksum[HASH_BUF_SIZE]; | |
| 454 | int hashtype; | |
| 460 | /* append a region name */ | |
| 461 | fprintf(out, " region=\"%s\"", ROMREGION_GETTAG(region)); | |
| 455 | 462 | |
| 456 | /* iterate over hash function types and print out their values */ | |
| 457 | for (hashtype = 0; hashtype < HASH_NUM_FUNCTIONS; hashtype++) | |
| 458 | if (hash_data_extract_printable_checksum(ROM_GETHASHDATA(rom), 1 << hashtype, checksum)) | |
| 459 | fprintf(out, " %s=\"%s\"", hash_function_name(1 << hashtype), checksum); | |
| 460 | } | |
| 463 | /* add nodump/baddump flags */ | |
| 464 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 465 | fprintf(out, " status=\"nodump\""); | |
| 466 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP)) | |
| 467 | fprintf(out, " status=\"baddump\""); | |
| 461 | 468 | |
| 462 | /* append a region name */ | |
| 463 | fprintf(out, " region=\"%s\"", ROMREGION_GETTAG(region)); | |
| 469 | /* for non-disk entries, print dispose flag and offset */ | |
| 470 | if (!is_disk) | |
| 471 | { | |
| 472 | if (ROMREGION_GETFLAGS(region) & ROMREGION_DISPOSE) | |
| 473 | fprintf(out, " dispose=\"yes\""); | |
| 474 | fprintf(out, " offset=\"%x\"", offset); | |
| 475 | } | |
| 464 | 476 | |
| 465 | /* add nodump/baddump flags */ | |
| 466 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_NO_DUMP)) | |
| 467 | fprintf(out, " status=\"nodump\""); | |
| 468 | if (hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP)) | |
| 469 | fprintf(out, " status=\"baddump\""); | |
| 470 | ||
| 471 | /* for non-disk entries, print dispose flag and offset */ | |
| 472 | if (!is_disk) | |
| 473 | { | |
| 474 | if (ROMREGION_GETFLAGS(region) & ROMREGION_DISPOSE) | |
| 475 | fprintf(out, " dispose=\"yes\""); | |
| 476 | fprintf(out, " offset=\"%x\"", offset); | |
| 477 | /* for disk entries, add the disk index */ | |
| 478 | else | |
| 479 | fprintf(out, " index=\"%x\"", DISK_GETINDEX(rom)); | |
| 480 | fprintf(out, "/>\n"); | |
| 477 | 481 | } |
| 478 | ||
| 479 | /* for disk entries, add the disk index */ | |
| 480 | else | |
| 481 | fprintf(out, " index=\"%x\"", DISK_GETINDEX(rom)); | |
| 482 | fprintf(out, "/>\n"); | |
| 483 | 482 | } |
| 484 | } | |
| 485 | 483 | } |
| 486 | 484 | } |
| 487 | 485 | |
| r3232 | r3233 | |
| 843 | 841 | |
| 844 | 842 | /* now print various additional information */ |
| 845 | 843 | print_game_bios(out, game); |
| 846 | print_game_rom(out, game); | |
| 844 | print_game_rom(out, game, config); | |
| 847 | 845 | print_game_sample(out, game, config); |
| 848 | 846 | print_game_chips(out, game, config); |
| 849 | 847 | print_game_display(out, game, config); |
| r3232 | r3233 | |
|---|---|---|
| 47 | 47 | render_target * current_mouse_target; |
| 48 | 48 | INT32 current_mouse_x; |
| 49 | 49 | INT32 current_mouse_y; |
| 50 | int current_mouse_down; | |
| 50 | 51 | |
| 51 | 52 | /* popped states; ring buffer of ui_events */ |
| 52 | 53 | ui_event events[EVENT_QUEUE_SIZE]; |
| r3232 | r3233 | |
| 143 | 144 | } |
| 144 | 145 | break; |
| 145 | 146 | |
| 147 | case UI_EVENT_MOUSE_DOWN: | |
| 148 | uidata->current_mouse_down = TRUE; | |
| 149 | break; | |
| 150 | ||
| 151 | case UI_EVENT_MOUSE_UP: | |
| 152 | uidata->current_mouse_down = FALSE; | |
| 153 | break; | |
| 154 | ||
| 146 | 155 | default: |
| 147 | 156 | /* do nothing */ |
| 148 | 157 | break; |
| r3232 | r3233 | |
| 207 | 216 | location of the mouse |
| 208 | 217 | -------------------------------------------------*/ |
| 209 | 218 | |
| 210 | render_target *ui_input_find_mouse(running_machine *machine, INT32 *x, INT32 *y) | |
| 219 | render_target *ui_input_find_mouse(running_machine *machine, INT32 *x, INT32 *y, int *button) | |
| 211 | 220 | { |
| 212 | 221 | ui_input_private *uidata = machine->ui_input_data; |
| 213 | 222 | if (x != NULL) |
| 214 | 223 | *x = uidata->current_mouse_x; |
| 215 | 224 | if (y != NULL) |
| 216 | 225 | *y = uidata->current_mouse_y; |
| 226 | if (button != NULL) | |
| 227 | *button = uidata->current_mouse_down; | |
| 217 | 228 | return uidata->current_mouse_target; |
| 218 | 229 | } |
| 219 | 230 |
| r3232 | r3233 | |
|---|---|---|
| 87 | 87 | timers |
| 88 | 88 | -------------------------------------------------*/ |
| 89 | 89 | |
| 90 | static void on_vblank(const device_config *screen, int vblank_state) | |
| 90 | static void on_vblank(const device_config *screen, void *param, int vblank_state) | |
| 91 | 91 | { |
| 92 | 92 | /* VBLANK starting */ |
| 93 | 93 | if (vblank_state && watchdog_enabled) |
| r3232 | r3233 | |
| 121 | 121 | |
| 122 | 122 | /* register a VBLANK callback for the primary screen */ |
| 123 | 123 | if (machine->primary_screen != NULL) |
| 124 | video_screen_register_vblank_callback(machine->primary_screen, on_vblank); | |
| 124 | video_screen_register_vblank_callback(machine->primary_screen, on_vblank, NULL); | |
| 125 | 125 | } |
| 126 | 126 | |
| 127 | 127 | /* timer-based watchdog? */ |
| r3232 | r3233 | |
|---|---|---|
| 28 | 28 | UI_EVENT_NONE, |
| 29 | 29 | UI_EVENT_MOUSE_MOVE, |
| 30 | 30 | UI_EVENT_MOUSE_LEAVE, |
| 31 | UI_EVENT_MOUSE_CLICK, | |
| 31 | UI_EVENT_MOUSE_DOWN, | |
| 32 | UI_EVENT_MOUSE_UP, | |
| 32 | 33 | UI_EVENT_MOUSE_DOUBLE_CLICK, |
| 33 | 34 | UI_EVENT_CHAR |
| 34 | 35 | }; |
| r3232 | r3233 | |
| 72 | 73 | void ui_input_reset(running_machine *machine); |
| 73 | 74 | |
| 74 | 75 | /* retrieves the current location of the mouse */ |
| 75 | render_target *ui_input_find_mouse(running_machine *machine, INT32 *x, INT32 *y); | |
| 76 | render_target *ui_input_find_mouse(running_machine *machine, INT32 *x, INT32 *y, int *button); | |
| 76 | 77 | |
| 77 | 78 | |
| 78 | 79 | |
| r3232 | r3233 | |
| 122 | 123 | |
| 123 | 124 | |
| 124 | 125 | /*------------------------------------------------- |
| 125 | ui_input_push_mouse_click_event - pushes a mouse | |
| 126 | click event to the specified render_target | |
| 126 | ui_input_push_mouse_down_event - pushes a mouse | |
| 127 | down event to the specified render_target | |
| 127 | 128 | -------------------------------------------------*/ |
| 128 | 129 | |
| 129 | INLINE void ui_input_push_mouse_ | |
| 130 | INLINE void ui_input_push_mouse_down | |
| 130 | 131 | { |
| 131 | 132 | ui_event event = { UI_EVENT_NONE }; |
| 132 | event.event_type = UI_EVENT_MOUSE_ | |
| 133 | event.event_type = UI_EVENT_MOUSE_DOWN | |
| 133 | 134 | event.target = target; |
| 134 | 135 | event.mouse_x = x; |
| 135 | 136 | event.mouse_y = y; |
| r3232 | r3233 | |
| 138 | 139 | |
| 139 | 140 | |
| 140 | 141 | /*------------------------------------------------- |
| 142 | ui_input_push_mouse_down_event - pushes a mouse | |
| 143 | down event to the specified render_target | |
| 144 | -------------------------------------------------*/ | |
| 145 | ||
| 146 | INLINE void ui_input_push_mouse_up_event(running_machine *machine, render_target *target, INT32 x, INT32 y) | |
| 147 | { | |
| 148 | ui_event event = { UI_EVENT_NONE }; | |
| 149 | event.event_type = UI_EVENT_MOUSE_UP; | |
| 150 | event.target = target; | |
| 151 | event.mouse_x = x; | |
| 152 | event.mouse_y = y; | |
| 153 | ui_input_push_event(machine, event); | |
| 154 | } | |
| 155 | ||
| 156 | ||
| 157 | /*------------------------------------------------- | |
| 141 | 158 | ui_input_push_mouse_double_click_event - pushes |
| 142 | 159 | a mouse double-click event to the specified |
| 143 | 160 | render_target |
| r3232 | r3233 | |
|---|---|---|
| 15 | 15 | #include "uiinput.h" |
| 16 | 16 | #include "uimenu.h" |
| 17 | 17 | #include "audit.h" |
| 18 | #include "deprecat.h" | |
| 19 | 18 | #include "eminline.h" |
| 20 | 19 | |
| 21 | 20 | #ifdef MESS |
| r3232 | r3233 | |
| 240 | 239 | static void ui_menu_exit(running_machine *machine); |
| 241 | 240 | |
| 242 | 241 | /* internal menu processing */ |
| 243 | static void ui_menu_draw(ui_menu *menu, int customonly); | |
| 242 | static void ui_menu_draw(running_machine *machine, ui_menu *menu, int customonly); | |
| 244 | 243 | static void ui_menu_draw_text_box(ui_menu *menu); |
| 245 | 244 | static void ui_menu_handle_events(ui_menu *menu); |
| 246 | 245 | static void ui_menu_handle_keys(ui_menu *menu, UINT32 flags); |
| r3232 | r3233 | |
| 569 | 568 | and returning any interesting events |
| 570 | 569 | -------------------------------------------------*/ |
| 571 | 570 | |
| 572 | const ui_menu_event *ui_menu_process(ui_menu *menu, UINT32 flags) | |
| 571 | const ui_menu_event *ui_menu_process(running_machine *machine, ui_menu *menu, UINT32 flags) | |
| 573 | 572 | { |
| 574 | 573 | /* reset the event */ |
| 575 | 574 | menu->event.iptkey = IPT_INVALID; |
| r3232 | r3233 | |
| 581 | 580 | if (menu->numitems > 1 && (menu->item[0].flags & MENU_FLAG_MULTILINE) != 0) |
| 582 | 581 | ui_menu_draw_text_box(menu); |
| 583 | 582 | else |
| 584 | ui_menu_draw(menu, (flags & UI_MENU_PROCESS_CUSTOM_ONLY) != 0); | |
| 583 | ui_menu_draw(machine, menu, (flags & UI_MENU_PROCESS_CUSTOM_ONLY) != 0); | |
| 585 | 584 | |
| 586 | 585 | /* process input */ |
| 587 | 586 | if (!(flags & UI_MENU_PROCESS_NOKEYS)) |
| r3232 | r3233 | |
| 721 | 720 | ui_menu_draw - draw a menu |
| 722 | 721 | -------------------------------------------------*/ |
| 723 | 722 | |
| 724 | static void ui_menu_draw(ui_menu *menu, int customonly) | |
| 723 | static void ui_menu_draw(running_machine *machine, ui_menu *menu, int customonly) | |
| 725 | 724 | { |
| 726 | 725 | float line_height = ui_get_line_height(); |
| 727 | 726 | float lr_arrow_width = 0.4f * line_height * render_get_ui_aspect(); |
| r3232 | r3233 | |
| 737 | 736 | int visible_lines; |
| 738 | 737 | int top_line; |
| 739 | 738 | int itemnum, linenum; |
| 740 | int mouse_hit; | |
| 739 | int mouse_hit, mouse_button; | |
| 741 | 740 | render_target *mouse_target; |
| 742 | 741 | INT32 mouse_target_x, mouse_target_y; |
| 743 | 742 | float mouse_x = -1, mouse_y = -1; |
| r3232 | r3233 | |
| 811 | 810 | |
| 812 | 811 | /* locate mouse */ |
| 813 | 812 | mouse_hit = FALSE; |
| 813 | mouse_button = FALSE; | |
| 814 | 814 | if (!customonly) |
| 815 | 815 | { |
| 816 | mouse_target = ui_input_find_mouse( | |
| 816 | mouse_target = ui_input_find_mouse(machine, &mouse_target_x, &mouse_target_y, &mouse_button); | |
| 817 | 817 | if (mouse_target != NULL) |
| 818 | 818 | if (render_target_map_point_container(mouse_target, mouse_target_x, mouse_target_y, render_container_get_ui(), &mouse_x, &mouse_y)) |
| 819 | 819 | mouse_hit = TRUE; |
| r3232 | r3233 | |
| 847 | 847 | } |
| 848 | 848 | |
| 849 | 849 | /* else if the mouse is over this item, draw with a different background */ |
| 850 | else if (menu->hover | |
| 850 | else if (itemnum == menu->hover | |
| 851 | 851 | { |
| 852 | 852 | fgcolor = mouseover_fgcolor; |
| 853 | 853 | bgcolor = mouseover_bgcolor; |
| r3232 | r3233 | |
| 1067 | 1067 | switch (event.event_type) |
| 1068 | 1068 | { |
| 1069 | 1069 | /* if we are hovering over a valid item, select it with a single click */ |
| 1070 | case UI_EVENT_MOUSE_ | |
| 1070 | case UI_EVENT_MOUSE_DOWN | |
| 1071 | 1071 | if (menu->hover >= 0 && menu->hover < menu->numitems) |
| 1072 | 1072 | menu->selected = menu->hover; |
| 1073 | 1073 | else if (menu->hover == -2) |
| r3232 | r3233 | |
| 1358 | 1358 | select menu to be visible and inescapable |
| 1359 | 1359 | -------------------------------------------------*/ |
| 1360 | 1360 | |
| 1361 | void ui_menu_force_game_select( | |
| 1361 | void ui_menu_force_game_select(running_machine *machine) | |
| 1362 | 1362 | { |
| 1363 | 1363 | char *gamename = (char *)options_get_string(mame_options(), OPTION_GAMENAME); |
| 1364 | 1364 | |
| 1365 | 1365 | /* reset the menu stack */ |
| 1366 | ui_menu_stack_reset( | |
| 1366 | ui_menu_stack_reset(machine); | |
| 1367 | 1367 | |
| 1368 | 1368 | /* add the quit entry followed by the game select entry */ |
| 1369 | ui_menu_stack_push(ui_menu_alloc(Machine, menu_quit_game, NULL)); | |
| 1370 | ui_menu_stack_push(ui_menu_alloc(Machine, menu_select_game, gamename)); | |
| 1369 | ui_menu_stack_push(ui_menu_alloc(machine, menu_quit_game, NULL)); | |
| 1370 | ui_menu_stack_push(ui_menu_alloc(machine, menu_select_game, gamename)); | |
| 1371 | 1371 | |
| 1372 | 1372 | /* force the menus on */ |
| 1373 | 1373 | ui_show_menu(); |
| 1374 | 1374 | |
| 1375 | 1375 | /* make sure MAME is paused */ |
| 1376 | mame_pause( | |
| 1376 | mame_pause(machine, TRUE); | |
| 1377 | 1377 | } |
| 1378 | 1378 | |
| 1379 | 1379 | |
| r3232 | r3233 | |
| 1413 | 1413 | menu_main_populate(machine, menu, state); |
| 1414 | 1414 | |
| 1415 | 1415 | /* process the menu */ |
| 1416 | event = ui_menu_process(menu, 0); | |
| 1416 | event = ui_menu_process(machine, menu, 0); | |
| 1417 | 1417 | if (event != NULL && event->iptkey == IPT_UI_SELECT) |
| 1418 | 1418 | ui_menu_stack_push(ui_menu_alloc(machine, event->itemref, NULL)); |
| 1419 | 1419 | } |
| r3232 | r3233 | |
| 1506 | 1506 | menu_input_groups_populate(machine, menu, state); |
| 1507 | 1507 | |
| 1508 | 1508 | /* process the menu */ |
| 1509 | event = ui_menu_process(menu, 0); | |
| 1509 | event = ui_menu_process(machine, menu, 0); | |
| 1510 | 1510 | if (event != NULL && event->iptkey == IPT_UI_SELECT) |
| 1511 | 1511 | ui_menu_stack_push(ui_menu_alloc(machine, menu_input_general, event->itemref)); |
| 1512 | 1512 | } |
| r3232 | r3233 | |
| 1706 | 1706 | } |
| 1707 | 1707 | |
| 1708 | 1708 | /* process the menu */ |
| 1709 | event = ui_menu_process(menu, (menustate->pollingitem != NULL) ? UI_MENU_PROCESS_NOKEYS : 0); | |
| 1709 | event = ui_menu_process(machine, menu, (menustate->pollingitem != NULL) ? UI_MENU_PROCESS_NOKEYS : 0); | |
| 1710 | 1710 | |
| 1711 | 1711 | /* if we are polling, handle as a special case */ |
| 1712 | 1712 | if (menustate->pollingitem != NULL) |
| r3232 | r3233 | |
| 1933 | 1933 | menu_settings_populate(machine, menu, menustate, type); |
| 1934 | 1934 | |
| 1935 | 1935 | /* process the menu */ |
| 1936 | event = ui_menu_process(menu, 0); | |
| 1936 | event = ui_menu_process(machine, menu, 0); | |
| 1937 | 1937 | |
| 1938 | 1938 | /* handle events */ |
| 1939 | 1939 | if (event != NULL && event->itemref != NULL) |
| r3232 | r3233 | |
| 2174 | 2174 | menu_analog_populate(machine, menu); |
| 2175 | 2175 | |
| 2176 | 2176 | /* process the menu */ |
| 2177 | event = ui_menu_process(menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2177 | event = ui_menu_process(machine, menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2178 | 2178 | |
| 2179 | 2179 | /* handle events */ |
| 2180 | 2180 | if (event != NULL && event->itemref != NULL) |
| r3232 | r3233 | |
| 2365 | 2365 | } |
| 2366 | 2366 | |
| 2367 | 2367 | /* process the menu */ |
| 2368 | ui_menu_process(menu, 0); | |
| 2368 | ui_menu_process(machine, menu, 0); | |
| 2369 | 2369 | } |
| 2370 | 2370 | #endif |
| 2371 | 2371 | |
| r3232 | r3233 | |
| 2432 | 2432 | } |
| 2433 | 2433 | |
| 2434 | 2434 | /* process the menu */ |
| 2435 | ui_menu_process(menu, 0); | |
| 2435 | ui_menu_process(machine, menu, 0); | |
| 2436 | 2436 | } |
| 2437 | 2437 | |
| 2438 | 2438 | |
| r3232 | r3233 | |
| 2449 | 2449 | menu_cheat_populate(machine, menu); |
| 2450 | 2450 | |
| 2451 | 2451 | /* process the menu */ |
| 2452 | event = ui_menu_process(menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2452 | event = ui_menu_process(machine, menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2453 | 2453 | |
| 2454 | 2454 | /* handle events */ |
| 2455 | 2455 | if (event != NULL && event->itemref != NULL) |
| r3232 | r3233 | |
| 2473 | 2473 | { |
| 2474 | 2474 | switch (event->iptkey) |
| 2475 | 2475 | { |
| 2476 | /* if selected, | |
| 2476 | /* if selected, | |
| 2477 | 2477 | case IPT_UI_SELECT: |
| 2478 | changed = cheat_activate(machine, event->itemref); | |
| 2479 | break; | |
| 2480 | ||
| 2481 | /* if cleared, reset to default value */ | |
| 2482 | case IPT_UI_CLEAR: | |
| 2478 | 2483 | changed = cheat_select_default_state(machine, event->itemref); |
| 2479 | changed |= cheat_activate(machine, event->itemref); | |
| 2480 | 2484 | break; |
| 2481 | 2485 | |
| 2482 | 2486 | /* left decrements */ |
| r3232 | r3233 | |
| 2544 | 2548 | menu_memory_card_populate(machine, menu, *cardnum); |
| 2545 | 2549 | |
| 2546 | 2550 | /* process the menu */ |
| 2547 | event = ui_menu_process(menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2551 | event = ui_menu_process(machine, menu, UI_MENU_PROCESS_LR_REPEAT); | |
| 2548 | 2552 | |
| 2549 | 2553 | /* if something was selected, act on it */ |
| 2550 | 2554 | if (event != NULL && event->itemref != NULL) |
| r3232 | r3233 | |
| 2649 | 2653 | menu_sliders_populate(machine, menu); |
| 2650 | 2654 | |
| 2651 | 2655 | /* process the menu */ |
| 2652 | event = ui_menu_process(menu, UI_MENU_PROCESS_LR_REPEAT | (*hidden ? UI_MENU_PROCESS_CUSTOM_ONLY : 0)); | |
| 2656 | event = ui_menu_process(machine, menu, UI_MENU_PROCESS_LR_REPEAT | (*hidden ? UI_MENU_PROCESS_CUSTOM_ONLY : 0)); | |
| 2653 | 2657 | if (event != NULL) |
| 2654 | 2658 | { |
| 2655 | 2659 | /* handle keys if there is a valid item selected */ |
| r3232 | r3233 | |
| 2845 | 2849 | menu_video_targets_populate(machine, menu); |
| 2846 | 2850 | |
| 2847 | 2851 | /* process the menu */ |
| 2848 | event = ui_menu_process(menu, 0); | |
| 2852 | event = ui_menu_process(machine, menu, 0); | |
| 2849 | 2853 | if (event != NULL && event->iptkey == IPT_UI_SELECT) |
| 2850 | 2854 | ui_menu_stack_push(ui_menu_alloc(machine, menu_video_options, event->itemref)); |
| 2851 | 2855 | } |
| r3232 | r3233 | |
| 2893 | 2897 | menu_video_options_populate(machine, menu, target); |
| 2894 | 2898 | |
| 2895 | 2899 | /* process the menu */ |
| 2896 | event = ui_menu_process(menu, 0); | |
| 2900 | event = ui_menu_process(machine, menu, 0); | |
| 2897 | 2901 | if (event != NULL && event->itemref != NULL) |
| 2898 | 2902 | { |
| 2899 | 2903 | switch ((FPTR)event->itemref) |
| r3232 | r3233 | |
| 3044 | 3048 | ui_input_pressed(machine, IPT_UI_PAUSE); |
| 3045 | 3049 | |
| 3046 | 3050 | /* process the menu */ |
| 3047 | event = ui_menu_process(menu, 0); | |
| 3051 | event = ui_menu_process(machine, menu, 0); | |
| 3048 | 3052 | if (event != NULL && event->itemref != NULL) |
| 3049 | 3053 | { |
| 3050 | 3054 | /* reset the error on any future event */ |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | FUNCTION PROTOTYPES |
| 23 | 23 | ***************************************************************************/ |
| 24 | 24 | |
| 25 | static int audit_one_rom(core_options *options, const rom_entry *rom, const game_driver *gamedrv, UINT32 validation, audit_record *record); | |
| 25 | static int audit_one_rom(core_options *options, const rom_entry *rom, const char *regiontag, const game_driver *gamedrv, UINT32 validation, audit_record *record); | |
| 26 | 26 | static int audit_one_disk(core_options *options, const rom_entry *rom, const game_driver *gamedrv, UINT32 validation, audit_record *record); |
| 27 | 27 | static int rom_used_by_parent(const game_driver *gamedrv, const rom_entry *romentry, const game_driver **parent); |
| 28 | 28 | |
| r3232 | r3233 | |
| 56 | 56 | |
| 57 | 57 | int audit_images(core_options *options, const game_driver *gamedrv, UINT32 validation, audit_record **audit) |
| 58 | 58 | { |
| 59 | machine_config *config = machine_config_alloc(gamedrv->machine_config); | |
| 59 | 60 | const rom_entry *region, *rom; |
| 61 | const rom_source *source; | |
| 60 | 62 | audit_record *record; |
| 61 | 63 | int foundany = FALSE; |
| 62 | 64 | int allshared = TRUE; |
| r3232 | r3233 | |
| 64 | 66 | |
| 65 | 67 | /* determine the number of records we will generate */ |
| 66 | 68 | records = 0; |
| 67 | for (region = rom_first_region(gamedrv); region != NULL; region = rom_next_region(region)) | |
| 68 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 69 | if (ROMREGION_ISROMDATA(region) || ROMREGION_ISDISKDATA(region)) | |
| 70 | { | |
| 71 | if (allshared && !rom_used_by_parent(gamedrv, rom, NULL)) | |
| 72 | allshared = FALSE; | |
| 73 | records++; | |
| 74 | } | |
| 69 | for (source = rom_first_source(gamedrv, config); source != NULL; source = rom_next_source(gamedrv, config, source)) | |
| 70 | { | |
| 71 | int source_is_gamedrv = rom_source_is_gamedrv(gamedrv, source); | |
| 72 | for (region = rom_first_region(gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 73 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 74 | if (ROMREGION_ISROMDATA(region) || ROMREGION_ISDISKDATA(region)) | |
| 75 | { | |
| 76 | if (source_is_gamedrv && allshared && !rom_used_by_parent(gamedrv, rom, NULL)) | |
| 77 | allshared = FALSE; | |
| 78 | records++; | |
| 79 | } | |
| 80 | } | |
| 75 | 81 | |
| 76 | 82 | if (records > 0) |
| 77 | 83 | { |
| r3232 | r3233 | |
| 80 | 86 | memset(*audit, 0, sizeof(**audit) * records); |
| 81 | 87 | record = *audit; |
| 82 | 88 | |
| 83 | /* iterate over regions and ROMs */ | |
| 84 | for (region = rom_first_region(gamedrv); region; region = rom_next_region(region)) | |
| 85 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 89 | /* iterate over ROM sources and regions */ | |
| 90 | for (source = rom_first_source(gamedrv, config); source != NULL; source = rom_next_source(gamedrv, config, source)) | |
| 91 | { | |
| 92 | int source_is_gamedrv = rom_source_is_gamedrv(gamedrv, source); | |
| 93 | for (region = rom_first_region(gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 86 | 94 | { |
| 87 | int shared = rom_used_by_parent(gamedrv, rom, NULL); | |
| 88 | ||
| 89 | /* audit a file */ | |
| 90 | if (ROMREGION_ISROMDATA(region)) | |
| 95 | const char *regiontag = ROMREGION_ISLOADBYNAME(region) ? ROM_GETNAME(region) : NULL; | |
| 96 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 91 | 97 | { |
| 92 | if (audit_one_rom(options, rom, gamedrv, validation, record++) && (!shared || allshared)) | |
| 93 | foundany = TRUE; | |
| 94 | } | |
| 98 | int shared = rom_used_by_parent(gamedrv, rom, NULL); | |
| 95 | 99 | |
| 96 | /* audit a disk */ | |
| 97 | else if (ROMREGION_ISDISKDATA(region)) | |
| 98 | { | |
| 99 | if (audit_one_disk(options, rom, gamedrv, validation, record++) && (!shared || allshared)) | |
| 100 | foundany = TRUE; | |
| 100 | /* audit a file */ | |
| 101 | if (ROMREGION_ISROMDATA(region)) | |
| 102 | { | |
| 103 | if (audit_one_rom(options, rom, regiontag, gamedrv, validation, record++) && source_is_gamedrv && (!shared || allshared)) | |
| 104 | foundany = TRUE; | |
| 105 | } | |
| 106 | ||
| 107 | /* audit a disk */ | |
| 108 | else if (ROMREGION_ISDISKDATA(region)) | |
| 109 | { | |
| 110 | if (audit_one_disk(options, rom, gamedrv, validation, record++) && source_is_gamedrv && (!shared || allshared)) | |
| 111 | foundany = TRUE; | |
| 112 | } | |
| 101 | 113 | } |
| 102 | 114 | } |
| 103 | 115 | |
| 104 | /* if we found nothing, we don't have the set at all */ | |
| 105 | if (!foundany) | |
| 106 | { | |
| 107 | free(*audit); | |
| 108 | *audit = NULL; | |
| 109 | records = 0; | |
| 116 | /* if we found nothing, we don't have the set at all */ | |
| 117 | if (rom_source_is_gamedrv(gamedrv, source) && !foundany) | |
| 118 | { | |
| 119 | free(*audit); | |
| 120 | *audit = NULL; | |
| 121 | records = 0; | |
| 122 | break; | |
| 123 | } | |
| 110 | 124 | } |
| 111 | 125 | } |
| 126 | ||
| 127 | machine_config_free(config); | |
| 112 | 128 | return records; |
| 113 | 129 | } |
| 114 | 130 | |
| r3232 | r3233 | |
| 310 | 326 | audit_one_rom - validate a single ROM entry |
| 311 | 327 | -------------------------------------------------*/ |
| 312 | 328 | |
| 313 | static int audit_one_rom(core_options *options, const rom_entry *rom, const game_driver *gamedrv, UINT32 validation, audit_record *record) | |
| 329 | static int audit_one_rom(core_options *options, const rom_entry *rom, const char *regiontag, const game_driver *gamedrv, UINT32 validation, audit_record *record) | |
| 314 | 330 | { |
| 315 | 331 | const game_driver *drv; |
| 316 | 332 | const rom_entry *chunk; |
| r3232 | r3233 | |
| 322 | 338 | record->type = AUDIT_FILE_ROM; |
| 323 | 339 | record->name = ROM_GETNAME(rom); |
| 324 | 340 | record->exphash = ROM_GETHASHDATA(rom); |
| 341 | record->length = 0; | |
| 325 | 342 | |
| 326 | 343 | /* compute the expected length by summing the chunks */ |
| 327 | 344 | for (chunk = rom_first_chunk(rom); chunk; chunk = rom_next_chunk(chunk)) |
| r3232 | r3233 | |
| 357 | 374 | } |
| 358 | 375 | } |
| 359 | 376 | |
| 377 | /* if not found, check the region as a backup */ | |
| 378 | if (record->length == 0 && regiontag != NULL) | |
| 379 | { | |
| 380 | file_error filerr; | |
| 381 | mame_file *file; | |
| 382 | astring *fname; | |
| 383 | ||
| 384 | /* open the file if we can */ | |
| 385 | fname = astring_assemble_3(astring_alloc(), regiontag, PATH_SEPARATOR, ROM_GETNAME(rom)); | |
| 386 | if (has_crc) | |
| 387 | filerr = mame_fopen_crc_options(options, SEARCHPATH_ROM, astring_c(fname), crc, OPEN_FLAG_READ, &file); | |
| 388 | else | |
| 389 | filerr = mame_fopen_options(options, SEARCHPATH_ROM, astring_c(fname), OPEN_FLAG_READ, &file); | |
| 390 | astring_free(fname); | |
| 391 | ||
| 392 | /* if we got it, extract the hash and length */ | |
| 393 | if (filerr == FILERR_NONE) | |
| 394 | { | |
| 395 | hash_data_copy(record->hash, mame_fhash(file, validation)); | |
| 396 | record->length = (UINT32)mame_fsize(file); | |
| 397 | mame_fclose(file); | |
| 398 | } | |
| 399 | } | |
| 400 | ||
| 360 | 401 | /* if we failed to find the file, set the appropriate status */ |
| 361 | if ( | |
| 402 | if ( | |
| 362 | 403 | { |
| 363 | 404 | const game_driver *parent; |
| 364 | 405 | |
| r3232 | r3233 | |
| 496 | 537 | const rom_entry *rom; |
| 497 | 538 | |
| 498 | 539 | /* see if the parent has the same ROM or not */ |
| 499 | for (region = rom_first_region(drv); region; region = rom_next_region(region)) | |
| 540 | for (region = rom_first_region(drv, NULL); region; region = rom_next_region(region)) | |
| 500 | 541 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) |
| 501 | 542 | if (hash_data_is_equal(ROM_GETHASHDATA(rom), hash, 0)) |
| 502 | 543 | { |
| r3232 | r3233 | |
|---|---|---|
| 79 | 79 | |
| 80 | 80 | /* screen specific VBLANK callbacks */ |
| 81 | 81 | vblank_state_changed_func vblank_callback[MAX_VBLANK_CALLBACKS]; /* the array of callbacks */ |
| 82 | void * vblank_callback_param[MAX_VBLANK_CALLBACKS]; /* array of parameters */ | |
| 82 | 83 | }; |
| 83 | 84 | |
| 84 | 85 | |
| r3232 | r3233 | |
| 1140 | 1141 | VBLANK callback for a specific screen |
| 1141 | 1142 | -------------------------------------------------*/ |
| 1142 | 1143 | |
| 1143 | void video_screen_register_vblank_callback(const device_config *screen, vblank_state_changed_func vblank_callback) | |
| 1144 | void video_screen_register_vblank_callback(const device_config *screen, vblank_state_changed_func vblank_callback, void *param) | |
| 1144 | 1145 | { |
| 1146 | screen_state *state = get_safe_token(screen); | |
| 1145 | 1147 | int i, found; |
| 1146 | screen_state *state = get_safe_token(screen); | |
| 1147 | 1148 | |
| 1148 | 1149 | /* validate arguments */ |
| 1149 | 1150 | assert(vblank_callback != NULL); |
| r3232 | r3233 | |
| 1164 | 1165 | |
| 1165 | 1166 | /* if not found, register and increment count */ |
| 1166 | 1167 | if (!found) |
| 1168 | { | |
| 1167 | 1169 | state->vblank_callback[i] = vblank_callback; |
| 1170 | state->vblank_callback_param[i] = param; | |
| 1171 | } | |
| 1168 | 1172 | } |
| 1169 | 1173 | |
| 1170 | 1174 | |
| r3232 | r3233 | |
| 1264 | 1268 | state_save_register_item(unique_tag, 0, state->vblank_end_time.attoseconds); |
| 1265 | 1269 | state_save_register_item(unique_tag, 0, state->frame_number); |
| 1266 | 1270 | state_save_register_postload(device->machine, video_screen_postload, (void *)device); |
| 1271 | ||
| 1272 | return DEVICE_START_OK; | |
| 1267 | 1273 | } |
| 1268 | 1274 | |
| 1269 | 1275 | |
| r3232 | r3233 | |
| 1366 | 1372 | |
| 1367 | 1373 | /* call the screen specific callbacks */ |
| 1368 | 1374 | for (i = 0; state->vblank_callback[i] != NULL; i++) |
| 1369 | (*state->vblank_callback[i])(screen, TRUE); | |
| 1375 | (*state->vblank_callback[i])(screen, state->vblank_callback_param[i], TRUE); | |
| 1370 | 1376 | |
| 1371 | 1377 | /* if this is the primary screen and we need to update now */ |
| 1372 | 1378 | if (screen == machine->primary_screen && !(machine->config->video_attributes & VIDEO_UPDATE_AFTER_VBLANK)) |
| r3232 | r3233 | |
| 1396 | 1402 | |
| 1397 | 1403 | /* call the screen specific callbacks */ |
| 1398 | 1404 | for (i = 0; state->vblank_callback[i] != NULL; i++) |
| 1399 | (*state->vblank_callback[i])(screen, FALSE); | |
| 1405 | (*state->vblank_callback[i])(screen, state->vblank_callback_param[i], FALSE); | |
| 1400 | 1406 | |
| 1401 | 1407 | /* if this is the primary screen and we need to update now */ |
| 1402 | 1408 | if (screen == machine->primary_screen && (machine->config->video_attributes & VIDEO_UPDATE_AFTER_VBLANK)) |
| r3232 | r3233 | |
|---|---|---|
| 103 | 103 | void ui_menu_item_append(ui_menu *menu, const char *text, const char *subtext, UINT32 flags, void *ref); |
| 104 | 104 | |
| 105 | 105 | /* process a menu, drawing it and returning any interesting events */ |
| 106 | const ui_menu_event *ui_menu_process(ui_menu *menu, UINT32 flags); | |
| 106 | const ui_menu_event *ui_menu_process(running_machine *machine, ui_menu *menu, UINT32 flags); | |
| 107 | 107 | |
| 108 | 108 | /* configure the menu for custom rendering */ |
| 109 | 109 | void ui_menu_set_custom_render(ui_menu *menu, ui_menu_custom_func custom, float top, float bottom); |
| r3232 | r3233 | |
| 147 | 147 | UINT32 ui_slider_ui_handler(running_machine *machine, UINT32 state); |
| 148 | 148 | |
| 149 | 149 | /* force game select menu */ |
| 150 | void ui_menu_force_game_select( | |
| 150 | void ui_menu_force_game_select(running_machine *machine); | |
| 151 | 151 | int ui_menu_is_force_game_select(void); |
| 152 | 152 | |
| 153 | 153 |
| r3232 | r3233 | |
|---|---|---|
| 372 | 372 | static void memory_init_cpudata(running_machine *machine); |
| 373 | 373 | static void memory_init_preflight(running_machine *machine); |
| 374 | 374 | static void memory_init_populate(running_machine *machine); |
| 375 | static void space_map_range_private(addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name); | |
| 376 | static void space_map_range(addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name); | |
| 375 | static void space_map_range_private(running_machine *machine, addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name); | |
| 376 | static void space_map_range(running_machine *machine, addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name); | |
| 377 | 377 | static void bank_assign_static(int banknum, int cpunum, int spacenum, read_or_write readorwrite, offs_t bytestart, offs_t byteend); |
| 378 | 378 | static genf *bank_assign_dynamic(int cpunum, int spacenum, read_or_write readorwrite, offs_t bytestart, offs_t byteend); |
| 379 | 379 | static UINT8 table_assign_handler(handler_data *table, void *object, genf *handler, const char *handler_name, offs_t bytestart, offs_t byteend, offs_t bytemask); |
| r3232 | r3233 | |
| 779 | 779 | memory_set_context - set the memory context |
| 780 | 780 | -------------------------------------------------*/ |
| 781 | 781 | |
| 782 | void memory_set_context(int activecpu) | |
| 782 | void memory_set_context(running_machine *machine, int activecpu) | |
| 783 | 783 | { |
| 784 | 784 | addrspace_data *space; |
| 785 | 785 | |
| r3232 | r3233 | |
| 796 | 796 | /* program address space */ |
| 797 | 797 | space = &cpudata[activecpu].space[ADDRESS_SPACE_PROGRAM]; |
| 798 | 798 | active_address_space[ADDRESS_SPACE_PROGRAM].bytemask = space->bytemask; |
| 799 | active_address_space[ADDRESS_SPACE_PROGRAM].readlookup = ((Machine->debug_flags & DEBUG_FLAG_WPR_PROGRAM) != 0) ? wptable : space->read.table; | |
| 800 | active_address_space[ADDRESS_SPACE_PROGRAM].writelookup = ((Machine->debug_flags & DEBUG_FLAG_WPW_PROGRAM) != 0) ? wptable : space->write.table; | |
| 799 | active_address_space[ADDRESS_SPACE_PROGRAM].readlookup = ((machine->debug_flags & DEBUG_FLAG_WPR_PROGRAM) != 0) ? wptable : space->read.table; | |
| 800 | active_address_space[ADDRESS_SPACE_PROGRAM].writelookup = ((machine->debug_flags & DEBUG_FLAG_WPW_PROGRAM) != 0) ? wptable : space->write.table; | |
| 801 | 801 | active_address_space[ADDRESS_SPACE_PROGRAM].readhandlers = space->read.handlers; |
| 802 | 802 | active_address_space[ADDRESS_SPACE_PROGRAM].writehandlers = space->write.handlers; |
| 803 | 803 | active_address_space[ADDRESS_SPACE_PROGRAM].accessors = space->accessors; |
| r3232 | r3233 | |
| 807 | 807 | { |
| 808 | 808 | space = &cpudata[activecpu].space[ADDRESS_SPACE_DATA]; |
| 809 | 809 | active_address_space[ADDRESS_SPACE_DATA].bytemask = space->bytemask; |
| 810 | active_address_space[ADDRESS_SPACE_DATA].readlookup = ((Machine->debug_flags & DEBUG_FLAG_WPR_DATA) != 0) ? wptable : space->read.table; | |
| 811 | active_address_space[ADDRESS_SPACE_DATA].writelookup = ((Machine->debug_flags & DEBUG_FLAG_WPW_DATA) != 0) ? wptable : space->write.table; | |
| 810 | active_address_space[ADDRESS_SPACE_DATA].readlookup = ((machine->debug_flags & DEBUG_FLAG_WPR_DATA) != 0) ? wptable : space->read.table; | |
| 811 | active_address_space[ADDRESS_SPACE_DATA].writelookup = ((machine->debug_flags & DEBUG_FLAG_WPW_DATA) != 0) ? wptable : space->write.table; | |
| 812 | 812 | active_address_space[ADDRESS_SPACE_DATA].readhandlers = space->read.handlers; |
| 813 | 813 | active_address_space[ADDRESS_SPACE_DATA].writehandlers = space->write.handlers; |
| 814 | 814 | active_address_space[ADDRESS_SPACE_DATA].accessors = space->accessors; |
| r3232 | r3233 | |
| 819 | 819 | { |
| 820 | 820 | space = &cpudata[activecpu].space[ADDRESS_SPACE_IO]; |
| 821 | 821 | active_address_space[ADDRESS_SPACE_IO].bytemask = space->bytemask; |
| 822 | active_address_space[ADDRESS_SPACE_IO].readlookup = ((Machine->debug_flags & DEBUG_FLAG_WPR_IO) != 0) ? wptable : space->read.table; | |
| 823 | active_address_space[ADDRESS_SPACE_IO].writelookup = ((Machine->debug_flags & DEBUG_FLAG_WPW_IO) != 0) ? wptable : space->write.table; | |
| 822 | active_address_space[ADDRESS_SPACE_IO].readlookup = ((machine->debug_flags & DEBUG_FLAG_WPR_IO) != 0) ? wptable : space->read.table; | |
| 823 | active_address_space[ADDRESS_SPACE_IO].writelookup = ((machine->debug_flags & DEBUG_FLAG_WPW_IO) != 0) ? wptable : space->write.table; | |
| 824 | 824 | active_address_space[ADDRESS_SPACE_IO].readhandlers = space->read.handlers; |
| 825 | 825 | active_address_space[ADDRESS_SPACE_IO].writehandlers = space->write.handlers; |
| 826 | 826 | active_address_space[ADDRESS_SPACE_IO].accessors = space->accessors; |
| r3232 | r3233 | |
| 861 | 861 | map = malloc_or_die(sizeof(*map)); |
| 862 | 862 | memset(map, 0, sizeof(*map)); |
| 863 | 863 | |
| 864 | /* start by constructing the internal CPU map */ | |
| 865 | if (internal_map != NULL) | |
| 866 | address_map_detokenize(map, driver, internal_map); | |
| 867 | ||
| 868 | 864 | /* construct the standard map */ |
| 869 | 865 | if (config->cpu[cpunum].address_map[spacenum][0] != NULL) |
| 870 | 866 | address_map_detokenize(map, driver, config->cpu[cpunum].address_map[spacenum][0]); |
| 871 | 867 | if (config->cpu[cpunum].address_map[spacenum][1] != NULL) |
| 872 | 868 | address_map_detokenize(map, driver, config->cpu[cpunum].address_map[spacenum][1]); |
| 873 | 869 | |
| 870 | /* append the internal CPU map (last so it can be overridden) */ | |
| 871 | if (internal_map != NULL) | |
| 872 | address_map_detokenize(map, driver, internal_map); | |
| 873 | ||
| 874 | 874 | return map; |
| 875 | 875 | } |
| 876 | 876 | |
| r3232 | r3233 | |
| 1288 | 1288 | CPU and offset |
| 1289 | 1289 | -------------------------------------------------*/ |
| 1290 | 1290 | |
| 1291 | void *memory_get_op_ptr(int cpunum, offs_t byteaddress, int arg) | |
| 1291 | void *memory_get_op_ptr(running_machine *machine, int cpunum, offs_t byteaddress, int arg) | |
| 1292 | 1292 | { |
| 1293 | 1293 | addrspace_data *space = &cpudata[cpunum].space[ADDRESS_SPACE_PROGRAM]; |
| 1294 | 1294 | offs_t byteoffset; |
| r3232 | r3233 | |
| 1302 | 1302 | opbase_data saved_opbase = opbase; |
| 1303 | 1303 | |
| 1304 | 1304 | /* query the handler */ |
| 1305 | offs_t new_byteaddress = (*cpudata[cpunum].opbase_handler)( | |
| 1305 | offs_t new_byteaddress = (*cpudata[cpunum].opbase_handler)(machine, byteaddress, &opbase); | |
| 1306 | 1306 | |
| 1307 | 1307 | /* if it returns ~0, we use whatever data the handler set */ |
| 1308 | 1308 | if (new_byteaddress == ~0) |
| r3232 | r3233 | |
| 1502 | 1502 | if (rhandler >= STATIC_COUNT || whandler >= STATIC_COUNT) |
| 1503 | 1503 | fatalerror("fatal: can only use static banks with memory_install_handler()"); |
| 1504 | 1504 | if (rhandler != 0) |
| 1505 | space_map_range(space, ROW_READ, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)rhandler, machine, rhandler_name); | |
| 1505 | space_map_range(machine, space, ROW_READ, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)rhandler, machine, rhandler_name); | |
| 1506 | 1506 | if (whandler != 0) |
| 1507 | space_map_range(space, ROW_WRITE, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)whandler, machine, whandler_name); | |
| 1507 | space_map_range(machine, space, ROW_WRITE, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)whandler, machine, whandler_name); | |
| 1508 | 1508 | mem_dump(); |
| 1509 | 1509 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1510 | 1510 | } |
| r3232 | r3233 | |
| 1513 | 1513 | { |
| 1514 | 1514 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1515 | 1515 | if (rhandler != NULL) |
| 1516 | space_map_range(space, ROW_READ, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1516 | space_map_range(machine, space, ROW_READ, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1517 | 1517 | if (whandler != NULL) |
| 1518 | space_map_range(space, ROW_WRITE, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1518 | space_map_range(machine, space, ROW_WRITE, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1519 | 1519 | mem_dump(); |
| 1520 | 1520 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1521 | 1521 | } |
| r3232 | r3233 | |
| 1524 | 1524 | { |
| 1525 | 1525 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1526 | 1526 | if (rhandler != NULL) |
| 1527 | space_map_range(space, ROW_READ, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1527 | space_map_range(machine, space, ROW_READ, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1528 | 1528 | if (whandler != NULL) |
| 1529 | space_map_range(space, ROW_WRITE, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1529 | space_map_range(machine, space, ROW_WRITE, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1530 | 1530 | mem_dump(); |
| 1531 | 1531 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1532 | 1532 | } |
| r3232 | r3233 | |
| 1535 | 1535 | { |
| 1536 | 1536 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1537 | 1537 | if (rhandler != NULL) |
| 1538 | space_map_range(space, ROW_READ, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1538 | space_map_range(machine, space, ROW_READ, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1539 | 1539 | if (whandler != NULL) |
| 1540 | space_map_range(space, ROW_WRITE, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1540 | space_map_range(machine, space, ROW_WRITE, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1541 | 1541 | mem_dump(); |
| 1542 | 1542 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1543 | 1543 | } |
| r3232 | r3233 | |
| 1546 | 1546 | { |
| 1547 | 1547 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1548 | 1548 | if (rhandler != NULL) |
| 1549 | space_map_range(space, ROW_READ, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1549 | space_map_range(machine, space, ROW_READ, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, machine, rhandler_name); | |
| 1550 | 1550 | if (whandler != NULL) |
| 1551 | space_map_range(space, ROW_WRITE, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1551 | space_map_range(machine, space, ROW_WRITE, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, machine, whandler_name); | |
| 1552 | 1552 | mem_dump(); |
| 1553 | 1553 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1554 | 1554 | } |
| r3232 | r3233 | |
| 1566 | 1566 | if (rhandler >= STATIC_COUNT || whandler >= STATIC_COUNT) |
| 1567 | 1567 | fatalerror("fatal: can only use static banks with memory_install_device_handler()"); |
| 1568 | 1568 | if (rhandler != 0) |
| 1569 | space_map_range(space, ROW_READ, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)rhandler, (void *)device, rhandler_name); | |
| 1569 | space_map_range(device->machine, space, ROW_READ, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)rhandler, (void *)device, rhandler_name); | |
| 1570 | 1570 | if (whandler != 0) |
| 1571 | space_map_range(space, ROW_WRITE, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)whandler, (void *)device, whandler_name); | |
| 1571 | space_map_range(device->machine, space, ROW_WRITE, space->dbits, 0, addrstart, addrend, addrmask, addrmirror, (genf *)(FPTR)whandler, (void *)device, whandler_name); | |
| 1572 | 1572 | mem_dump(); |
| 1573 | 1573 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1574 | 1574 | } |
| r3232 | r3233 | |
| 1577 | 1577 | { |
| 1578 | 1578 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1579 | 1579 | if (rhandler != NULL) |
| 1580 | space_map_range(space, ROW_READ, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1580 | space_map_range(device->machine, space, ROW_READ, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1581 | 1581 | if (whandler != NULL) |
| 1582 | space_map_range(space, ROW_WRITE, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1582 | space_map_range(device->machine, space, ROW_WRITE, 8, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1583 | 1583 | mem_dump(); |
| 1584 | 1584 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1585 | 1585 | } |
| r3232 | r3233 | |
| 1588 | 1588 | { |
| 1589 | 1589 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1590 | 1590 | if (rhandler != NULL) |
| 1591 | space_map_range(space, ROW_READ, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1591 | space_map_range(device->machine, space, ROW_READ, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1592 | 1592 | if (whandler != NULL) |
| 1593 | space_map_range(space, ROW_WRITE, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1593 | space_map_range(device->machine, space, ROW_WRITE, 16, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1594 | 1594 | mem_dump(); |
| 1595 | 1595 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1596 | 1596 | } |
| r3232 | r3233 | |
| 1599 | 1599 | { |
| 1600 | 1600 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1601 | 1601 | if (rhandler != NULL) |
| 1602 | space_map_range(space, ROW_READ, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1602 | space_map_range(device->machine, space, ROW_READ, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1603 | 1603 | if (whandler != NULL) |
| 1604 | space_map_range(space, ROW_WRITE, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1604 | space_map_range(device->machine, space, ROW_WRITE, 32, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1605 | 1605 | mem_dump(); |
| 1606 | 1606 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1607 | 1607 | } |
| r3232 | r3233 | |
| 1610 | 1610 | { |
| 1611 | 1611 | addrspace_data *space = &cpudata[cpunum].space[spacenum]; |
| 1612 | 1612 | if (rhandler != NULL) |
| 1613 | space_map_range(space, ROW_READ, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1613 | space_map_range(device->machine, space, ROW_READ, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)rhandler, (void *)device, rhandler_name); | |
| 1614 | 1614 | if (whandler != NULL) |
| 1615 | space_map_range(space, ROW_WRITE, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1615 | space_map_range(device->machine, space, ROW_WRITE, 64, 0, addrstart, addrend, addrmask, addrmirror, (genf *)whandler, (void *)device, whandler_name); | |
| 1616 | 1616 | mem_dump(); |
| 1617 | 1617 | return memory_find_base(cpunum, spacenum, ADDR2BYTE(space, addrstart)); |
| 1618 | 1618 | } |
| r3232 | r3233 | |
| 1856 | 1856 | if (object == NULL) |
| 1857 | 1857 | fatalerror("Unidentified object in memory map: type=%s tag=%s\n", devtype_name(entry->read_devtype), entry->read_devtag); |
| 1858 | 1858 | } |
| 1859 | space_map_range_private(space, ROW_READ, bits, entry->read_mask, entry->addrstart, entry->addrend, entry->addrmask, entry->addrmirror, rhandler.generic, object, entry->read_name); | |
| 1859 | space_map_range_private(machine, space, ROW_READ, bits, entry->read_mask, entry->addrstart, entry->addrend, entry->addrmask, entry->addrmirror, rhandler.generic, object, entry->read_name); | |
| 1860 | 1860 | } |
| 1861 | 1861 | |
| 1862 | 1862 | /* install the write handler if present */ |
| r3232 | r3233 | |
| 1870 | 1870 | if (object == NULL) |
| 1871 | 1871 | fatalerror("Unidentified object in memory map: type=%s tag=%s\n", devtype_name(entry->write_devtype), entry->write_devtag); |
| 1872 | 1872 | } |
| 1873 | space_map_range_private(space, ROW_WRITE, bits, entry->write_mask, entry->addrstart, entry->addrend, entry->addrmask, entry->addrmirror, whandler.generic, object, entry->write_name); | |
| 1873 | space_map_range_private(machine, space, ROW_WRITE, bits, entry->write_mask, entry->addrstart, entry->addrend, entry->addrmask, entry->addrmirror, whandler.generic, object, entry->write_name); | |
| 1874 | 1874 | } |
| 1875 | 1875 | } |
| 1876 | 1876 | } |
| r3232 | r3233 | |
| 1885 | 1885 | banks to dynamically assigned banks |
| 1886 | 1886 | -------------------------------------------------*/ |
| 1887 | 1887 | |
| 1888 | static void space_map_range_private(addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name) | |
| 1888 | static void space_map_range_private(running_machine *machine, addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name) | |
| 1889 | 1889 | { |
| 1890 | 1890 | /* translate ROM to RAM/UNMAP here */ |
| 1891 | 1891 | if (HANDLER_IS_ROM(handler)) |
| r3232 | r3233 | |
| 1909 | 1909 | } |
| 1910 | 1910 | |
| 1911 | 1911 | /* then do a normal installation */ |
| 1912 | space_map_range(space, readorwrite, handlerbits, handlerunitmask, addrstart, addrend, addrmask, addrmirror, handler, object, handler_name); | |
| 1912 | space_map_range(machine, space, readorwrite, handlerbits, handlerunitmask, addrstart, addrend, addrmask, addrmirror, handler, object, handler_name); | |
| 1913 | 1913 | } |
| 1914 | 1914 | |
| 1915 | 1915 | |
| r3232 | r3233 | |
| 1919 | 1919 | space |
| 1920 | 1920 | -------------------------------------------------*/ |
| 1921 | 1921 | |
| 1922 | static void space_map_range(addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name) | |
| 1922 | static void space_map_range(running_machine *machine, addrspace_data *space, read_or_write readorwrite, int handlerbits, int handlerunitmask, offs_t addrstart, offs_t addrend, offs_t addrmask, offs_t addrmirror, genf *handler, void *object, const char *handler_name) | |
| 1923 | 1923 | { |
| 1924 | 1924 | table_data *tabledata = (readorwrite == ROW_WRITE) ? &space->write : &space->read; |
| 1925 | 1925 | offs_t bytestart, byteend, bytemask, bytemirror; |
| r3232 | r3233 | |
| 1960 | 1960 | |
| 1961 | 1961 | /* if this is being installed to a live CPU, update the context */ |
| 1962 | 1962 | if (space->cpunum == cur_context) |
| 1963 | memory_set_context(cur_context); | |
| 1963 | memory_set_context(machine, cur_context); | |
| 1964 | 1964 | } |
| 1965 | 1965 | |
| 1966 | 1966 | |
| r3232 | r3233 | |
| 3003 | 3003 | watchpoint memory handlers |
| 3004 | 3004 | -------------------------------------------------*/ |
| 3005 | 3005 | |
| 3006 | INLINE UINT8 watchpoint_read8(int spacenum, offs_t address) | |
| 3006 | INLINE UINT8 watchpoint_read8(running_machine *machine, int spacenum, offs_t address) | |
| 3007 | 3007 | { |
| 3008 | 3008 | UINT8 result; |
| 3009 | debug_cpu_memory_read_hook( | |
| 3009 | debug_cpu_memory_read_hook(machine, cur_context, spacenum, address, 0xff); | |
| 3010 | 3010 | active_address_space[spacenum].readlookup = cpudata[cur_context].space[spacenum].read.table; |
| 3011 | 3011 | result = read_byte_generic(spacenum, address); |
| 3012 | 3012 | active_address_space[spacenum].readlookup = wptable; |
| 3013 | 3013 | return result; |
| 3014 | 3014 | } |
| 3015 | 3015 | |
| 3016 | INLINE UINT16 watchpoint_read16(int spacenum, offs_t address, UINT16 mem_mask) | |
| 3016 | INLINE UINT16 watchpoint_read16(running_machine *machine, int spacenum, offs_t address, UINT16 mem_mask) | |
| 3017 | 3017 | { |
| 3018 | 3018 | UINT16 result; |
| 3019 | debug_cpu_memory_read_hook( | |
| 3019 | debug_cpu_memory_read_hook(machine, cur_context, spacenum, address << 1, mem_mask); | |
| 3020 | 3020 | active_address_space[spacenum].readlookup = cpudata[cur_context].space[spacenum].read.table; |
| 3021 | 3021 | result = read_word_generic(spacenum, address << 1, mem_mask); |
| 3022 | 3022 | active_address_space[spacenum].readlookup = wptable; |
| 3023 | 3023 | return result; |
| 3024 | 3024 | } |
| 3025 | 3025 | |
| 3026 | INLINE UINT32 watchpoint_read32(int spacenum, offs_t address, UINT32 mem_mask) | |
| 3026 | INLINE UINT32 watchpoint_read32(running_machine *machine, int spacenum, offs_t address, UINT32 mem_mask) | |
| 3027 | 3027 | { |
| 3028 | 3028 | UINT32 result; |
| 3029 | debug_cpu_memory_read_hook( | |
| 3029 | debug_cpu_memory_read_hook(machine, cur_context, spacenum, address << 2, mem_mask); | |
| 3030 | 3030 | active_address_space[spacenum].readlookup = cpudata[cur_context].space[spacenum].read.table; |
| 3031 | 3031 | result = read_dword_generic(spacenum, address << 2, mem_mask); |
| 3032 | 3032 | active_address_space[spacenum].readlookup = wptable; |
| 3033 | 3033 | return result; |
| 3034 | 3034 | } |
| 3035 | 3035 | |
| 3036 | INLINE UINT64 watchpoint_read64(int spacenum, offs_t address, UINT64 mem_mask) | |
| 3036 | INLINE UINT64 watchpoint_read64(running_machine *machine, int spacenum, offs_t address, UINT64 mem_mask) | |
| 3037 | 3037 | { |
| 3038 | 3038 | UINT64 result; |
| 3039 | debug_cpu_memory_read_hook( | |
| 3039 | debug_cpu_memory_read_hook(machine, cur_context, spacenum, address << 3, mem_mask); | |
| 3040 | 3040 | active_address_space[spacenum].readlookup = cpudata[cur_context].space[spacenum].read.table; |
| 3041 | 3041 | result = read_qword_generic(spacenum, address << 3, mem_mask); |
| 3042 | 3042 | active_address_space[spacenum].readlookup = wptable; |
| 3043 | 3043 | return result; |
| 3044 | 3044 | } |
| 3045 | 3045 | |
| 3046 | INLINE void watchpoint_write8(int spacenum, offs_t address, UINT8 data) | |
| 3046 | INLINE void watchpoint_write8(running_machine *machine, int spacenum, offs_t address, UINT8 data) | |
| 3047 | 3047 | { |
| 3048 | debug_cpu_memory_write_hook( | |
| 3048 | debug_cpu_memory_write_hook(machine, cur_context, spacenum, address, data, 0xff); | |
| 3049 | 3049 | active_address_space[spacenum].writelookup = cpudata[cur_context].space[spacenum].write.table; |
| 3050 | 3050 | write_byte_generic(spacenum, address, data); |
| 3051 | 3051 | active_address_space[spacenum].writelookup = wptable; |
| 3052 | 3052 | } |
| 3053 | 3053 | |
| 3054 | INLINE void watchpoint_write16(int spacenum, offs_t address, UINT16 data, UINT16 mem_mask) | |
| 3054 | INLINE void watchpoint_write16(running_machine *machine, int spacenum, offs_t address, UINT16 data, UINT16 mem_mask) | |
| 3055 | 3055 | { |
| 3056 | debug_cpu_memory_write_hook( | |
| 3056 | debug_cpu_memory_write_hook(machine, cur_context, spacenum, address << 1, data, mem_mask); | |
| 3057 | 3057 | active_address_space[spacenum].writelookup = cpudata[cur_context].space[spacenum].write.table; |
| 3058 | 3058 | write_word_generic(spacenum, address << 1, data, mem_mask); |
| 3059 | 3059 | active_address_space[spacenum].writelookup = wptable; |
| 3060 | 3060 | } |
| 3061 | 3061 | |
| 3062 | INLINE void watchpoint_write32(int spacenum, offs_t address, UINT32 data, UINT32 mem_mask) | |
| 3062 | INLINE void watchpoint_write32(running_machine *machine, int spacenum, offs_t address, UINT32 data, UINT32 mem_mask) | |
| 3063 | 3063 | { |
| 3064 | debug_cpu_memory_write_hook( | |
| 3064 | debug_cpu_memory_write_hook(machine, cur_context, spacenum, address << 2, data, mem_mask); | |
| 3065 | 3065 | active_address_space[spacenum].writelookup = cpudata[cur_context].space[spacenum].write.table; |
| 3066 | 3066 | write_dword_generic(spacenum, address << 2, data, mem_mask); |
| 3067 | 3067 | active_address_space[spacenum].writelookup = wptable; |
| 3068 | 3068 | } |
| 3069 | 3069 | |
| 3070 | INLINE void watchpoint_write64(int spacenum, offs_t address, UINT64 data, UINT64 mem_mask) | |
| 3070 | INLINE void watchpoint_write64(running_machine *machine, int spacenum, offs_t address, UINT64 data, UINT64 mem_mask) | |
| 3071 | 3071 | { |
| 3072 | debug_cpu_memory_write_hook( | |
| 3072 | debug_cpu_memory_write_hook(machine, cur_context, spacenum, address << 3, data, mem_mask); | |
| 3073 | 3073 | active_address_space[spacenum].writelookup = cpudata[cur_context].space[spacenum].write.table; |
| 3074 | 3074 | write_qword_generic(spacenum, address << 3, data, mem_mask); |
| 3075 | 3075 | active_address_space[spacenum].writelookup = wptable; |
| 3076 | 3076 | } |
| 3077 | 3077 | |
| 3078 | static READ8_HANDLER( mrh8_watchpoint_program ) { return watchpoint_read8 (ADDRESS_SPACE_PROGRAM, offset); } | |
| 3079 | static READ16_HANDLER( mrh16_watchpoint_program ) { return watchpoint_read16(ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3080 | static READ32_HANDLER( mrh32_watchpoint_program ) { return watchpoint_read32(ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3081 | static READ64_HANDLER( mrh64_watchpoint_program ) { return watchpoint_read64(ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3078 | static READ8_HANDLER( mrh8_watchpoint_program ) { return watchpoint_read8 (machine, ADDRESS_SPACE_PROGRAM, offset); } | |
| 3079 | static READ16_HANDLER( mrh16_watchpoint_program ) { return watchpoint_read16(machine, ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3080 | static READ32_HANDLER( mrh32_watchpoint_program ) { return watchpoint_read32(machine, ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3081 | static READ64_HANDLER( mrh64_watchpoint_program ) { return watchpoint_read64(machine, ADDRESS_SPACE_PROGRAM, offset, mem_mask); } | |
| 3082 | 3082 | |
| 3083 | static WRITE8_HANDLER( mwh8_watchpoint_program ) { watchpoint_write8 (ADDRESS_SPACE_PROGRAM, offset, data); } | |
| 3084 | static WRITE16_HANDLER( mwh16_watchpoint_program ) { watchpoint_write16(ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3085 | static WRITE32_HANDLER( mwh32_watchpoint_program ) { watchpoint_write32(ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3086 | static WRITE64_HANDLER( mwh64_watchpoint_program ) { watchpoint_write64(ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3083 | static WRITE8_HANDLER( mwh8_watchpoint_program ) { watchpoint_write8 (machine, ADDRESS_SPACE_PROGRAM, offset, data); } | |
| 3084 | static WRITE16_HANDLER( mwh16_watchpoint_program ) { watchpoint_write16(machine, ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3085 | static WRITE32_HANDLER( mwh32_watchpoint_program ) { watchpoint_write32(machine, ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3086 | static WRITE64_HANDLER( mwh64_watchpoint_program ) { watchpoint_write64(machine, ADDRESS_SPACE_PROGRAM, offset, data, mem_mask); } | |
| 3087 | 3087 | |
| 3088 | static READ8_HANDLER( mrh8_watchpoint_data ) { return watchpoint_read8 (ADDRESS_SPACE_DATA, offset); } | |
| 3089 | static READ16_HANDLER( mrh16_watchpoint_data ) { return watchpoint_read16(ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3090 | static READ32_HANDLER( mrh32_watchpoint_data ) { return watchpoint_read32(ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3091 | static READ64_HANDLER( mrh64_watchpoint_data ) { return watchpoint_read64(ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3088 | static READ8_HANDLER( mrh8_watchpoint_data ) { return watchpoint_read8 (machine, ADDRESS_SPACE_DATA, offset); } | |
| 3089 | static READ16_HANDLER( mrh16_watchpoint_data ) { return watchpoint_read16(machine, ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3090 | static READ32_HANDLER( mrh32_watchpoint_data ) { return watchpoint_read32(machine, ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3091 | static READ64_HANDLER( mrh64_watchpoint_data ) { return watchpoint_read64(machine, ADDRESS_SPACE_DATA, offset, mem_mask); } | |
| 3092 | 3092 | |
| 3093 | static WRITE8_HANDLER( mwh8_watchpoint_data ) { watchpoint_write8 (ADDRESS_SPACE_DATA, offset, data); } | |
| 3094 | static WRITE16_HANDLER( mwh16_watchpoint_data ) { watchpoint_write16(ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3095 | static WRITE32_HANDLER( mwh32_watchpoint_data ) { watchpoint_write32(ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3096 | static WRITE64_HANDLER( mwh64_watchpoint_data ) { watchpoint_write64(ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3093 | static WRITE8_HANDLER( mwh8_watchpoint_data ) { watchpoint_write8 (machine, ADDRESS_SPACE_DATA, offset, data); } | |
| 3094 | static WRITE16_HANDLER( mwh16_watchpoint_data ) { watchpoint_write16(machine, ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3095 | static WRITE32_HANDLER( mwh32_watchpoint_data ) { watchpoint_write32(machine, ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3096 | static WRITE64_HANDLER( mwh64_watchpoint_data ) { watchpoint_write64(machine, ADDRESS_SPACE_DATA, offset, data, mem_mask); } | |
| 3097 | 3097 | |
| 3098 | static READ8_HANDLER( mrh8_watchpoint_io ) { return watchpoint_read8 (ADDRESS_SPACE_IO, offset); } | |
| 3099 | static READ16_HANDLER( mrh16_watchpoint_io ) { return watchpoint_read16(ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3100 | static READ32_HANDLER( mrh32_watchpoint_io ) { return watchpoint_read32(ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3101 | static READ64_HANDLER( mrh64_watchpoint_io ) { return watchpoint_read64(ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3098 | static READ8_HANDLER( mrh8_watchpoint_io ) { return watchpoint_read8 (machine, ADDRESS_SPACE_IO, offset); } | |
| 3099 | static READ16_HANDLER( mrh16_watchpoint_io ) { return watchpoint_read16(machine, ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3100 | static READ32_HANDLER( mrh32_watchpoint_io ) { return watchpoint_read32(machine, ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3101 | static READ64_HANDLER( mrh64_watchpoint_io ) { return watchpoint_read64(machine, ADDRESS_SPACE_IO, offset, mem_mask); } | |
| 3102 | 3102 | |
| 3103 | static WRITE8_HANDLER( mwh8_watchpoint_io ) { watchpoint_write8 (ADDRESS_SPACE_IO, offset, data); } | |
| 3104 | static WRITE16_HANDLER( mwh16_watchpoint_io ) { watchpoint_write16(ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3105 | static WRITE32_HANDLER( mwh32_watchpoint_io ) { watchpoint_write32(ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3106 | static WRITE64_HANDLER( mwh64_watchpoint_io ) { watchpoint_write64(ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3103 | static WRITE8_HANDLER( mwh8_watchpoint_io ) { watchpoint_write8 (machine, ADDRESS_SPACE_IO, offset, data); } | |
| 3104 | static WRITE16_HANDLER( mwh16_watchpoint_io ) { watchpoint_write16(machine, ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3105 | static WRITE32_HANDLER( mwh32_watchpoint_io ) { watchpoint_write32(machine, ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3106 | static WRITE64_HANDLER( mwh64_watchpoint_io ) { watchpoint_write64(machine, ADDRESS_SPACE_IO, offset, data, mem_mask); } | |
| 3107 | 3107 | |
| 3108 | 3108 | |
| 3109 | 3109 | /*------------------------------------------------- |
| r3232 | r3233 | |
|---|---|---|
| 87 | 87 | in the VBLANK state |
| 88 | 88 | -------------------------------------------------*/ |
| 89 | 89 | |
| 90 | typedef void (*vblank_state_changed_func)(const device_config *device, int vblank_state); | |
| 90 | typedef void (*vblank_state_changed_func)(const device_config *device, void *param, int vblank_state); | |
| 91 | 91 | |
| 92 | 92 | |
| 93 | 93 | |
| r3232 | r3233 | |
| 209 | 209 | UINT64 video_screen_get_frame_number(const device_config *screen); |
| 210 | 210 | |
| 211 | 211 | /* registers a VBLANK callback for the given screen */ |
| 212 | void video_screen_register_vblank_callback(const device_config *screen, vblank_state_changed_func vblank_callback); | |
| 212 | void video_screen_register_vblank_callback(const device_config *screen, vblank_state_changed_func vblank_callback, void *param); | |
| 213 | 213 | |
| 214 | 214 | |
| 215 | 215 | /* ----- video screen device interface ----- */ |
| r3232 | r3233 | |
|---|---|---|
| 833 | 833 | void memory_init(running_machine *machine); |
| 834 | 834 | |
| 835 | 835 | /* set the current memory context */ |
| 836 | void memory_set_context(int activecpu); | |
| 836 | void memory_set_context(running_machine *machine, int activecpu); | |
| 837 | 837 | |
| 838 | 838 | /* get a pointer to the set of memory accessor functions based on the address space, |
| 839 | 839 | databus width, and endianness */ |
| r3232 | r3233 | |
| 870 | 870 | /* return a base pointer to memory */ |
| 871 | 871 | void * memory_get_read_ptr(int cpunum, int spacenum, offs_t byteaddress); |
| 872 | 872 | void * memory_get_write_ptr(int cpunum, int spacenum, offs_t byteaddress); |
| 873 | void * memory_get_op_ptr(int cpunum, offs_t byteaddress, int arg); | |
| 873 | void * memory_get_op_ptr(running_machine *machine, int cpunum, offs_t byteaddress, int arg); | |
| 874 | 874 | |
| 875 | 875 | /* memory banking */ |
| 876 | 876 | void memory_configure_bank(int banknum, int startentry, int numentries, void *base, offs_t stride); |
| r3232 | r3233 | |
|---|---|---|
| 552 | 552 | if (started_empty && options_get_string(mame_options(), OPTION_GAMENAME)[0] != 0) |
| 553 | 553 | { |
| 554 | 554 | options_set_string(mame_options(), OPTION_GAMENAME, "", OPTION_PRIORITY_CMDLINE); |
| 555 | ui_menu_force_game_select(); | |
| 555 | ui_menu_force_game_select(machine); | |
| 556 | 556 | } |
| 557 | 557 | |
| 558 | 558 | /* otherwise, exit for real */ |
| r3232 | r3233 | |
| 1145 | 1145 | } |
| 1146 | 1146 | |
| 1147 | 1147 | |
| 1148 | void CLIB_DECL fatalerror_exitcode(int exitcode, const char *text, ...) | |
| 1148 | void CLIB_DECL fatalerror_exitcode(running_machine *machine, int exitcode, const char *text, ...) | |
| 1149 | 1149 | { |
| 1150 | running_machine *machine = Machine; | |
| 1151 | 1150 | va_list arg; |
| 1152 | 1151 | |
| 1153 | 1152 | /* dump to the buffer; assume no one writes >2k lines this way */ |
| r3232 | r3233 | |
| 1539 | 1538 | |
| 1540 | 1539 | /* first load ROMs, then populate memory, and finally initialize CPUs */ |
| 1541 | 1540 | /* these operations must proceed in this order */ |
| 1542 | rom_init(machine | |
| 1541 | rom_init(machine | |
| 1543 | 1542 | memory_init(machine); |
| 1544 | 1543 | cpuexec_init(machine); |
| 1545 | 1544 | watchdog_init(machine); |
| r3232 | r3233 | |
| 1647 | 1646 | |
| 1648 | 1647 | /* set the global time to the current time */ |
| 1649 | 1648 | /* this allows 0-time queued callbacks to run before any CPUs execute */ |
| 1650 | timer_set_global_time(timer_get_time()); | |
| 1649 | timer_set_global_time(machine, timer_get_time()); | |
| 1651 | 1650 | } |
| 1652 | 1651 | |
| 1653 | 1652 | |
| r3232 | r3233 | |
| 1734 | 1733 | |
| 1735 | 1734 | /* write the default tag */ |
| 1736 | 1735 | state_save_push_tag(0); |
| 1737 | state_save_save_continue(); | |
| 1736 | state_save_save_continue(machine); | |
| 1738 | 1737 | state_save_pop_tag(); |
| 1739 | 1738 | |
| 1740 | 1739 | /* loop over CPUs */ |
| r3232 | r3233 | |
| 1747 | 1746 | |
| 1748 | 1747 | /* save the CPU data */ |
| 1749 | 1748 | state_save_push_tag(cpunum + 1); |
| 1750 | state_save_save_continue(); | |
| 1749 | state_save_save_continue(machine); | |
| 1751 | 1750 | state_save_pop_tag(); |
| 1752 | 1751 | |
| 1753 | 1752 | cpuintrf_pop_context(); |
| 1754 | 1753 | } |
| 1755 | 1754 | |
| 1756 | 1755 | /* finish and close */ |
| 1757 | state_save_save_finish(); | |
| 1756 | state_save_save_finish(machine); | |
| 1758 | 1757 | mame_fclose(file); |
| 1759 | 1758 | |
| 1760 | 1759 | /* pop a warning if the game doesn't support saves */ |
| r3232 | r3233 | |
| 1816 | 1815 | |
| 1817 | 1816 | /* read tag 0 */ |
| 1818 | 1817 | state_save_push_tag(0); |
| 1819 | state_save_load_continue(); | |
| 1818 | state_save_load_continue(machine); | |
| 1820 | 1819 | state_save_pop_tag(); |
| 1821 | 1820 | |
| 1822 | 1821 | /* loop over CPUs */ |
| r3232 | r3233 | |
| 1829 | 1828 | |
| 1830 | 1829 | /* load the CPU data */ |
| 1831 | 1830 | state_save_push_tag(cpunum + 1); |
| 1832 | state_save_load_continue(); | |
| 1831 | state_save_load_continue(machine); | |
| 1833 | 1832 | state_save_pop_tag(); |
| 1834 | 1833 | |
| 1835 | 1834 | /* make sure banking is set */ |
| r3232 | r3233 | |
|---|---|---|
| 98 | 98 | #include "profiler.h" |
| 99 | 99 | #include "inputseq.h" |
| 100 | 100 | #include "ui.h" |
| 101 | #include "uiinput.h" | |
| 101 | 102 | #include <ctype.h> |
| 102 | 103 | #include <time.h> |
| 103 | 104 | #include <stdarg.h> |
| r3232 | r3233 | |
| 480 | 481 | static void frame_update(running_machine *machine); |
| 481 | 482 | static void frame_update_digital_joysticks(running_machine *machine); |
| 482 | 483 | static void frame_update_analog_field(analog_field_state *analog); |
| 483 | static int frame_get_digital_field_state(const input_field_config *field); | |
| 484 | static int frame_get_digital_field_state(const input_field_config *field, int mouse_down); | |
| 484 | 485 | |
| 485 | 486 | /* port configuration helpers */ |
| 486 | 487 | static input_port_config *port_config_detokenize(input_port_config *listhead, const input_port_token *ipt, char *errorbuf, int errorbuflen); |
| r3232 | r3233 | |
| 789 | 790 | } |
| 790 | 791 | |
| 791 | 792 | |
| 793 | /*------------------------------------------------- | |
| 794 | input_field_by_tag_and_mask - return a pointer | |
| 795 | to the first field that intersects the given | |
| 796 | mask on the tagged port | |
| 797 | -------------------------------------------------*/ | |
| 792 | 798 | |
| 799 | const input_field_config *input_field_by_tag_and_mask(const input_port_config *portlist, const char *tag, input_port_value mask) | |
| 800 | { | |
| 801 | const input_port_config *port = input_port_by_tag(portlist, tag); | |
| 802 | const input_field_config *field; | |
| 803 | ||
| 804 | /* if we got the port, look for the field */ | |
| 805 | if (port != NULL) | |
| 806 | for (field = port->fieldlist; field != NULL; field = field->next) | |
| 807 | if ((field->mask & mask) != 0) | |
| 808 | return field; | |
| 809 | ||
| 810 | return NULL; | |
| 811 | } | |
| 812 | ||
| 813 | ||
| 814 | ||
| 793 | 815 | /*************************************************************************** |
| 794 | 816 | ACCESSORS FOR INPUT FIELDS |
| 795 | 817 | ***************************************************************************/ |
| r3232 | r3233 | |
| 1984 | 2006 | static void frame_update(running_machine *machine) |
| 1985 | 2007 | { |
| 1986 | 2008 | input_port_private *portdata = machine->input_port_data; |
| 2009 | const input_field_config *mouse_field = NULL; | |
| 1987 | 2010 | int ui_visible = ui_is_menu_active(); |
| 1988 | 2011 | attotime curtime = timer_get_time(); |
| 1989 | 2012 | const input_port_config *port; |
| 2013 | render_target *mouse_target; | |
| 2014 | INT32 mouse_target_x; | |
| 2015 | INT32 mouse_target_y; | |
| 2016 | int mouse_button; | |
| 1990 | 2017 | |
| 1991 | 2018 | profiler_mark(PROFILER_INPUT); |
| 1992 | 2019 | |
| r3232 | r3233 | |
| 2004 | 2031 | /* compute default values for all the ports */ |
| 2005 | 2032 | input_port_update_defaults(machine); |
| 2006 | 2033 | |
| 2034 | /* perform the mouse hit test */ | |
| 2035 | mouse_target = ui_input_find_mouse(machine, &mouse_target_x, &mouse_target_y, &mouse_button); | |
| 2036 | if (mouse_button) | |
| 2037 | { | |
| 2038 | const char *tag = NULL; | |
| 2039 | input_port_value mask; | |
| 2040 | if (render_target_map_point_input(mouse_target, mouse_target_x, mouse_target_y, &tag, &mask, NULL, NULL)) | |
| 2041 | mouse_field = input_field_by_tag_and_mask(machine->portconfig, tag, mask); | |
| 2042 | } | |
| 2043 | ||
| 2007 | 2044 | /* loop over all input ports */ |
| 2008 | 2045 | for (port = machine->portconfig; port != NULL; port = port->next) |
| 2009 | 2046 | { |
| r3232 | r3233 | |
| 2028 | 2065 | frame_update_analog_field(field->state->analog); |
| 2029 | 2066 | |
| 2030 | 2067 | /* handle non-analog types, but only when the UI isn't visible */ |
| 2031 | else if (!ui_visible && frame_get_digital_field_state(field)) | |
| 2068 | else if (!ui_visible && frame_get_digital_field_state(field, field == mouse_field)) | |
| 2032 | 2069 | port->state->digital |= field->mask; |
| 2033 | 2070 | } |
| 2034 | 2071 | |
| r3232 | r3233 | |
| 2298 | 2335 | of a digital field |
| 2299 | 2336 | -------------------------------------------------*/ |
| 2300 | 2337 | |
| 2301 | static int frame_get_digital_field_state(const input_field_config *field) | |
| 2338 | static int frame_get_digital_field_state(const input_field_config *field, int mouse_down) | |
| 2302 | 2339 | { |
| 2303 | int curstate = input_seq_pressed(input_field_seq(field, SEQ_TYPE_STANDARD)); | |
| 2340 | int curstate = mouse_down || input_seq_pressed(input_field_seq(field, SEQ_TYPE_STANDARD)); | |
| 2304 | 2341 | int changed = FALSE; |
| 2305 | 2342 | |
| 2306 | 2343 | /* if the state changed, look for switch down/switch up */ |
| r3232 | r3233 | |
| 2351 | 2388 | curstate = FALSE; |
| 2352 | 2389 | |
| 2353 | 2390 | /* additional logic to restrict digital joysticks */ |
| 2354 | if (curstate && field->state->joystick != NULL && field->way != 16) | |
| 2391 | if (curstate && !mouse_down && field->state->joystick != NULL && field->way != 16) | |
| 2355 | 2392 | { |
| 2356 | 2393 | UINT8 mask = (field->way == 4) ? field->state->joystick->current4way : field->state->joystick->current; |
| 2357 | 2394 | if (!(mask & (1 << field->state->joydir))) |
| r3232 | r3233 | |
|---|---|---|
| 107 | 107 | device->class = devtype_get_info_int(type, DEVINFO_INT_CLASS); |
| 108 | 108 | device->static_config = NULL; |
| 109 | 109 | device->inline_config = (configlen == 0) ? NULL : (device->tag + strlen(tag) + 1); |
| 110 | device->started = FALSE; | |
| 110 | 111 | device->token = NULL; |
| 111 | 112 | device->machine = NULL; |
| 113 | device->region = NULL; | |
| 114 | device->regionbytes = 0; | |
| 112 | 115 | strcpy(device->tag, tag); |
| 113 | 116 | |
| 114 | 117 | /* reset the inline_config to 0 */ |
| r3232 | r3233 | |
| 450 | 453 | void device_list_start(running_machine *machine) |
| 451 | 454 | { |
| 452 | 455 | device_config *device; |
| 456 | int numstarted = 0; | |
| 457 | int devcount = 0; | |
| 453 | 458 | |
| 454 | 459 | assert(machine != NULL); |
| 455 | 460 | |
| r3232 | r3233 | |
| 457 | 462 | add_reset_callback(machine, device_list_reset); |
| 458 | 463 | add_exit_callback(machine, device_list_stop); |
| 459 | 464 | |
| 460 | /* iterate over devices and | |
| 465 | /* iterate over devices and | |
| 461 | 466 | for (device = (device_config *)machine->config->devicelist; device != NULL; device = device->next) |
| 462 | 467 | { |
| 463 | 468 | UINT32 tokenlen; |
| 464 | 469 | |
| 470 | assert(!device->started); | |
| 465 | 471 | assert(device->token == NULL); |
| 466 | 472 | assert(device->type != NULL); |
| 467 | 473 | assert(device->start != NULL); |
| 468 | 474 | |
| 475 | devcount++; | |
| 476 | ||
| 469 | 477 | /* get the size of the token data */ |
| 470 | 478 | tokenlen = (UINT32)devtype_get_info_int(device->type, DEVINFO_INT_TOKEN_BYTES); |
| 471 | 479 | if (tokenlen == 0) |
| r3232 | r3233 | |
| 479 | 487 | device->machine = machine; |
| 480 | 488 | device->region = memory_region(machine, device->tag); |
| 481 | 489 | device->regionbytes = memory_region_length(machine, device->tag); |
| 490 | } | |
| 482 | 491 | |
| 483 | /* call the start function */ | |
| 484 | (*device->start)(device); | |
| 492 | /* iterate until we've started everything */ | |
| 493 | while (numstarted < devcount) | |
| 494 | { | |
| 495 | int prevstarted = numstarted; | |
| 496 | numstarted = 0; | |
| 497 | ||
| 498 | /* iterate over devices and start them */ | |
| 499 | for (device = (device_config *)machine->config->devicelist; device != NULL; device = device->next) | |
| 500 | { | |
| 501 | if (!device->started && (*device->start)(device) == DEVICE_START_OK) | |
| 502 | device->started = TRUE; | |
| 503 | numstarted += device->started; | |
| 504 | } | |
| 505 | ||
| 506 | /* if we didn't start anything new, we're in trouble */ | |
| 507 | if (numstarted == prevstarted) | |
| 508 | fatalerror("Circular dependency in device startup; unable to start %d/%d devices\n", devcount - numstarted, devcount); | |
| 485 | 509 | } |
| 486 | 510 | } |
| 487 | 511 | |
| r3232 | r3233 | |
| 703 | 727 | deviceinfo info; |
| 704 | 728 | |
| 705 | 729 | assert(device != NULL); |
| 706 | assert(device->token != NULL); | |
| 707 | 730 | assert(device->type != NULL); |
| 708 | 731 | assert(state >= DEVINFO_PTR_FIRST && state <= DEVINFO_PTR_LAST); |
| 709 | 732 | |
| r3232 | r3233 | |
| 776 | 799 | deviceinfo info; |
| 777 | 800 | |
| 778 | 801 | assert(device != NULL); |
| 779 | assert(device->token != NULL); | |
| 780 | 802 | assert(device->type != NULL); |
| 781 | 803 | assert(state >= DEVINFO_STR_FIRST && state <= DEVINFO_STR_LAST); |
| 782 | 804 |
| r3232 | r3233 | |
|---|---|---|
| 339 | 339 | timer = timer_alloc( timekeeper_tick, c ); |
| 340 | 340 | duration = ATTOTIME_IN_SEC(1); |
| 341 | 341 | timer_adjust_periodic( timer, duration, 0, duration ); |
| 342 | ||
| 343 | return DEVICE_START_OK; | |
| 342 | 344 | } |
| 343 | 345 | |
| 344 | 346 | static DEVICE_START(m48t02) |
| r3232 | r3233 | |
| 357 | 359 | c->offset_flags = -1; |
| 358 | 360 | c->size = 0x800; |
| 359 | 361 | |
| 360 | DEVICE_START_CALL( timekeeper ); | |
| 362 | return DEVICE_START_CALL( timekeeper ); | |
| 361 | 363 | } |
| 362 | 364 | |
| 363 | 365 | static DEVICE_START(m48t35) |
| r3232 | r3233 | |
| 376 | 378 | c->offset_flags = -1; |
| 377 | 379 | c->size = 0x8000; |
| 378 | 380 | |
| 379 | DEVICE_START_CALL( timekeeper ); | |
| 381 | return DEVICE_START_CALL( timekeeper ); | |
| 380 | 382 | } |
| 381 | 383 | |
| 382 | 384 | static DEVICE_START(m48t58) |
| r3232 | r3233 | |
| 395 | 397 | c->offset_flags = -1; |
| 396 | 398 | c->size = 0x2000; |
| 397 | 399 | |
| 398 | DEVICE_START_CALL( timekeeper ); | |
| 400 | return DEVICE_START_CALL( timekeeper ); | |
| 399 | 401 | } |
| 400 | 402 | |
| 401 | 403 | static DEVICE_START(mk48t08) |
| r3232 | r3233 | |
| 414 | 416 | c->offset_flags = 0x1ff0; |
| 415 | 417 | c->size = 0x2000; |
| 416 | 418 | |
| 417 | DEVICE_START_CALL( timekeeper ); | |
| 419 | return DEVICE_START_CALL( timekeeper ); | |
| 418 | 420 | } |
| 419 | 421 | |
| 420 | 422 | /*------------------------------------------------- |
| r3232 | r3233 | |
|---|---|---|
| 1756 | 1756 | |
| 1757 | 1757 | state_save_register_item(unique_tag, 0, ide->master_password_enable); |
| 1758 | 1758 | state_save_register_item(unique_tag, 0, ide->user_password_enable); |
| 1759 | ||
| 1760 | return DEVICE_START_OK; | |
| 1759 | 1761 | } |
| 1760 | 1762 | |
| 1761 | 1763 |
| r3232 | r3233 | |
|---|---|---|
| 586 | 586 | state_save_register_item(unique_tag, 0, duart68681->channel[1].tx_data); |
| 587 | 587 | state_save_register_item(unique_tag, 0, duart68681->channel[1].tx_ready); |
| 588 | 588 | |
| 589 | return DEVICE_START_OK; | |
| 589 | 590 | } |
| 590 | 591 | |
| 591 | 592 | /*------------------------------------------------- |
| r3232 | r3233 | |
|---|---|---|
| 467 | 467 | |
| 468 | 468 | state_save_register_item(unique_tag, 0, riot->timershift); |
| 469 | 469 | state_save_register_item(unique_tag, 0, riot->timerstate); |
| 470 | ||
| 471 | return DEVICE_START_OK; | |
| 470 | 472 | } |
| 471 | 473 | |
| 472 | 474 |
| r3232 | r3233 | |
|---|---|---|
| 10 | 10 | *************************************************************************/ |
| 11 | 11 | |
| 12 | 12 | #include "ldcore.h" |
| 13 | #include "cpu/mcs48/mcs48.h" | |
| 13 | 14 | |
| 14 | 15 | |
| 15 | 16 | |
| r3232 | r3233 | |
| 17 | 18 | DEBUGGING |
| 18 | 19 | ***************************************************************************/ |
| 19 | 20 | |
| 21 | #define EMULATE_PR8210_ROM 0 | |
| 22 | ||
| 20 | 23 | #define PRINTF_COMMANDS 1 |
| 21 | 24 | #define CMDPRINTF(x) do { if (PRINTF_COMMANDS) mame_printf_debug x; } while (0) |
| 22 | 25 | |
| r3232 | r3233 | |
| 29 | 32 | /* Player-specific states */ |
| 30 | 33 | enum |
| 31 | 34 | { |
| 32 | LDSTATE_STEPPING_BY_PARAMETER = LDSTATE_OTHER | |
| 35 | LDSTATE_STEPPING_BY_PARAMETER = LDSTATE_OTHER, | |
| 36 | LDSTATE_STEPPING_BY_PARAMETER_PAUSED | |
| 33 | 37 | }; |
| 34 | 38 | |
| 35 | 39 | /* Pioneer PR-8210 specific information */ |
| r3232 | r3233 | |
| 69 | 73 | UINT8 cmdcnt; /* counter for multi-byte command */ |
| 70 | 74 | UINT8 cmdbytes[3]; /* storage for multi-byte command */ |
| 71 | 75 | void (*cmd_ack_callback)(void); /* callback to clear game command write flag */ |
| 76 | ||
| 77 | /* low-level emulation data */ | |
| 78 | int cpunum; | |
| 79 | UINT8 pia[0x100]; | |
| 80 | UINT8 vsync; | |
| 81 | UINT8 porta; | |
| 82 | UINT8 portb; | |
| 83 | UINT8 pia_porta; | |
| 84 | UINT8 pia_portb; | |
| 72 | 85 | }; |
| 73 | 86 | |
| 74 | 87 | |
| r3232 | r3233 | |
| 81 | 94 | static void pr8210_soft_reset(laserdisc_state *ld); |
| 82 | 95 | static void pr8210_update_squelch(laserdisc_state *ld); |
| 83 | 96 | static int pr8210_switch_state(laserdisc_state *ld, UINT8 newstate, INT32 stateparam); |
| 97 | static INT32 pr8210_hle_update(laserdisc_state *ld, const vbi_metadata *vbi, int fieldnum, attotime curtime); | |
| 98 | #if (EMULATE_PR8210_ROM) | |
| 99 | static void pr8210_vsync(laserdisc_state *ld); | |
| 84 | 100 | static INT32 pr8210_update(laserdisc_state *ld, const vbi_metadata *vbi, int fieldnum, attotime curtime); |
| 85 | static void pr8210_command(laserdisc_state *ld); | |
| 101 | #else | |
| 102 | static void pr8210_hle_command(laserdisc_state *ld); | |
| 103 | #endif | |
| 86 | 104 | static void pr8210_control_w(laserdisc_state *ld, UINT8 prev, UINT8 data); |
| 87 | 105 | |
| 88 | 106 | static void simutrek_init(laserdisc_state *ld); |
| r3232 | r3233 | |
| 92 | 110 | |
| 93 | 111 | |
| 94 | 112 | /*************************************************************************** |
| 113 | ROM AND MACHINE INTERFACES | |
| 114 | ***************************************************************************/ | |
| 115 | ||
| 116 | MACHINE_DRIVER_EXTERN( pr8210 ); | |
| 117 | ||
| 118 | #if EMULATE_PR8210_ROM | |
| 119 | ROM_START( pr8210 ) | |
| 120 | ROM_REGION( 0x800, "pr8210", ROMREGION_LOADBYNAME ) | |
| 121 | ROM_LOAD( "pr-8210_mcu_ud6005a.bin", 0x000, 0x800, CRC(120fa83b) SHA1(b514326ca1f52d6d89056868f9d17eabd4e3f31d) ) | |
| 122 | ROM_END | |
| 123 | #endif | |
| 124 | ||
| 125 | ||
| 126 | ||
| 127 | /*************************************************************************** | |
| 95 | 128 | INTERFACES |
| 96 | 129 | ***************************************************************************/ |
| 97 | 130 | |
| r3232 | r3233 | |
| 100 | 133 | LASERDISC_TYPE_PIONEER_PR8210, /* type of the player */ |
| 101 | 134 | sizeof(ldplayer_data), /* size of the state */ |
| 102 | 135 | "Pioneer PR-8210", /* name of the player */ |
| 136 | #if EMULATE_PR8210_ROM | |
| 137 | rom_pr8210, /* pointer to ROM region information */ | |
| 138 | machine_config_pr8210, /* pointer to machine configuration */ | |
| 103 | 139 | pr8210_init, /* initialization callback */ |
| 140 | pr8210_vsync, /* vsync callback */ | |
| 104 | 141 | pr8210_update, /* update callback */ |
| 142 | #else | |
| 143 | NULL, /* pointer to ROM region information */ | |
| 144 | NULL, /* pointer to machine configuration */ | |
| 145 | pr8210_init, /* initialization callback */ | |
| 146 | NULL, /* vsync callback */ | |
| 147 | pr8210_hle_update, /* update callback */ | |
| 148 | #endif | |
| 105 | 149 | NULL, /* parallel data write */ |
| 106 | 150 | { /* single line write: */ |
| 107 | 151 | NULL, /* LASERDISC_LINE_ENTER */ |
| r3232 | r3233 | |
| 122 | 166 | LASERDISC_TYPE_SIMUTREK_SPECIAL, /* type of the player */ |
| 123 | 167 | sizeof(ldplayer_data), /* size of the state */ |
| 124 | 168 | "Simutrek Modified PR-8210", /* name of the player */ |
| 169 | NULL, /* pointer to ROM region information */ | |
| 170 | NULL, /* pointer to machine configuration */ | |
| 125 | 171 | simutrek_init, /* initialization callback */ |
| 126 | pr8210_update, /* update callback */ | |
| 172 | NULL, /* vsync callback */ | |
| 173 | pr8210_hle_update, /* update callback */ | |
| 127 | 174 | simutrek_data_w, /* parallel data write */ |
| 128 | 175 | { /* single line write: */ |
| 129 | 176 | NULL, /* LASERDISC_LINE_ENTER */ |
| r3232 | r3233 | |
| 141 | 188 | |
| 142 | 189 | |
| 143 | 190 | /*************************************************************************** |
| 144 | | |
| 191 | | |
| 145 | 192 | ***************************************************************************/ |
| 146 | 193 | |
| 147 | 194 | /*------------------------------------------------- |
| r3232 | r3233 | |
| 156 | 203 | } |
| 157 | 204 | |
| 158 | 205 | |
| 206 | /*------------------------------------------------- | |
| 207 | requires_state_save - returns TRUE if the | |
| 208 | given state will return to the previous | |
| 209 | state when done | |
| 210 | -------------------------------------------------*/ | |
| 159 | 211 | |
| 212 | INLINE void update_audio_squelch(laserdisc_state *ld) | |
| 213 | { | |
| 214 | ldplayer_data *player = ld->player; | |
| 215 | ldcore_set_audio_squelch(ld, (player->porta & 0x40) || !(player->pia_portb & 0x01), (player->porta & 0x40) || !(player->pia_portb & 0x02)); | |
| 216 | } | |
| 217 | ||
| 218 | ||
| 219 | ||
| 220 | ||
| 160 | 221 | /*************************************************************************** |
| 161 | 222 | PIONEER PR-8210 IMPLEMENTATION |
| 162 | 223 | ***************************************************************************/ |
| r3232 | r3233 | |
| 168 | 229 | |
| 169 | 230 | static void pr8210_init(laserdisc_state *ld) |
| 170 | 231 | { |
| 232 | astring *tempstring = astring_alloc(); | |
| 233 | ||
| 234 | /* find our CPU */ | |
| 235 | astring_printf(tempstring, "%s:%s", ld->device->tag, "pr8210"); | |
| 236 | ld->player->cpunum = mame_find_cpu_index(ld->device->machine, astring_c(tempstring)); | |
| 237 | astring_free(tempstring); | |
| 238 | ||
| 171 | 239 | /* do a soft reset */ |
| 172 | 240 | pr8210_soft_reset(ld); |
| 173 | 241 | } |
| r3232 | r3233 | |
| 247 | 315 | |
| 248 | 316 | /* Simutrek: stepping by parameter with explicit audio squelch controls */ |
| 249 | 317 | case LDSTATE_STEPPING_BY_PARAMETER: |
| 318 | case LDSTATE_STEPPING_BY_PARAMETER_PAUSED: | |
| 250 | 319 | ldcore_set_video_squelch(ld, FALSE); |
| 251 | 320 | break; |
| 252 | 321 | } |
| r3232 | r3233 | |
| 306 | 375 | |
| 307 | 376 | |
| 308 | 377 | /*------------------------------------------------- |
| 378 | pr8210_vsync - Start of VSYNC callback | |
| 379 | -------------------------------------------------*/ | |
| 380 | ||
| 381 | #if (EMULATE_PR8210_ROM) | |
| 382 | static TIMER_CALLBACK( vsync_off ) | |
| 383 | { | |
| 384 | ldplayer_data *player = ptr; | |
| 385 | player->vsync = FALSE; | |
| 386 | } | |
| 387 | ||
| 388 | static void pr8210_vsync(laserdisc_state *ld) | |
| 389 | { | |
| 390 | ldplayer_data *player = ld->player; | |
| 391 | player->vsync = TRUE; | |
| 392 | timer_set(attotime_mul(video_screen_get_scan_period(ld->screen), 4), player, 0, vsync_off); | |
| 393 | } | |
| 394 | #endif | |
| 395 | ||
| 396 | ||
| 397 | /*------------------------------------------------- | |
| 309 | 398 | pr8210_update - Pioneer PR-8210-specific |
| 310 | update callback | |
| 399 | update callback when using a ROM | |
| 311 | 400 | -------------------------------------------------*/ |
| 312 | 401 | |
| 402 | #if (EMULATE_PR8210_ROM) | |
| 403 | ||
| 313 | 404 | static INT32 pr8210_update(laserdisc_state *ld, const vbi_metadata *vbi, int fieldnum, attotime curtime) |
| 314 | 405 | { |
| 406 | ldplayer_data *player = ld->player; | |
| 407 | UINT8 focus_on = !(player->porta & 0x08); | |
| 408 | UINT8 laser_on = !(player->portb & 0x01); | |
| 409 | UINT8 spdl_on = !(player->porta & 0x10); | |
| 410 | INT32 advanceby = 0; | |
| 411 | int frame, chapter; | |
| 412 | ||
| 413 | /* update PIA registers based on vbi code */ | |
| 414 | frame = frame_from_metadata(vbi); | |
| 415 | chapter = chapter_from_metadata(vbi); | |
| 416 | if (focus_on && laser_on && !(player->pia[0x80] & 1)) | |
| 417 | { | |
| 418 | if (frame == FRAME_LEAD_IN) | |
| 419 | player->pia[0xc0] = 0x10; /* or 0x12 */ | |
| 420 | else if (frame == FRAME_LEAD_OUT) | |
| 421 | player->pia[0xc0] = 0x11; | |
| 422 | else if (frame != FRAME_NOT_PRESENT) | |
| 423 | { | |
| 424 | player->pia[0xc0] = 0x02; /* bit 0x02 must be set for forward scanning to work */ | |
| 425 | player->pia[0x22] = 0xf0 | ((frame / 10000) % 10); | |
| 426 | player->pia[0x23] = 0xf0 | ((frame / 1000) % 10); | |
| 427 | player->pia[0x24] = 0xf0 | ((frame / 100) % 10); | |
| 428 | player->pia[0x25] = 0xf0 | ((frame / 10) % 10); | |
| 429 | player->pia[0x26] = 0xf0 | ((frame / 1) % 10); | |
| 430 | printf("Frame:%05d\n", frame); | |
| 431 | } | |
| 432 | else if (chapter != CHAPTER_NOT_PRESENT) | |
| 433 | { | |
| 434 | player->pia[0xc0] = 0x13; | |
| 435 | player->pia[0x20] = 0xf0 | ((chapter / 10) % 10); | |
| 436 | player->pia[0x21] = 0xf0 | ((chapter / 1) % 10); | |
| 437 | } | |
| 438 | // else | |
| 439 | // player->pia[0xc0] = 0x00; | |
| 440 | } | |
| 441 | player->pia[0xc0] |= 12;//4;//fieldnum << 2; | |
| 442 | ||
| 443 | if (spdl_on) | |
| 444 | advanceby = fieldnum; | |
| 445 | ||
| 446 | /* update overlay */ | |
| 447 | if ((player->pia[0x80] & 1) || player->framedisplay) | |
| 448 | { | |
| 449 | char buffer[16] = { 0 }; | |
| 450 | int i; | |
| 451 | for (i = 0; i < 15; i++) | |
| 452 | { | |
| 453 | UINT8 c = player->pia[0x22 + i]; | |
| 454 | if (c >= 0xf0 && c <= 0xf9) | |
| 455 | c = '0' + (c - 0xf0); | |
| 456 | else if (c < 0x20 || c > 0x7f) | |
| 457 | c = '?'; | |
| 458 | buffer[i] = c; | |
| 459 | } | |
| 460 | popmessage("%s", buffer); | |
| 461 | } | |
| 462 | player->framedisplay = 0; | |
| 463 | ||
| 464 | if (advanceby != 0) | |
| 465 | printf("Advancing by %d\n", advanceby); | |
| 466 | return advanceby; | |
| 467 | } | |
| 468 | #endif | |
| 469 | ||
| 470 | ||
| 471 | /*------------------------------------------------- | |
| 472 | pr8210_hle_update - Pioneer PR-8210-specific | |
| 473 | update callback when using HLE | |
| 474 | -------------------------------------------------*/ | |
| 475 | ||
| 476 | static INT32 pr8210_hle_update(laserdisc_state *ld, const vbi_metadata *vbi, int fieldnum, attotime curtime) | |
| 477 | { | |
| 315 | 478 | ldplayer_state newstate; |
| 316 | 479 | INT32 advanceby = 0; |
| 317 | 480 | int frame; |
| r3232 | r3233 | |
| 369 | 532 | { |
| 370 | 533 | /* note that we switch directly to PAUSED as we are not looking for frames */ |
| 371 | 534 | advanceby = ld->state.param; |
| 372 | pr8210_switch_state(ld, LDSTATE_PAUSED, 0); | |
| 535 | pr8210_switch_state(ld, LDSTATE_STEPPING_BY_PARAMETER_PAUSED, 0); | |
| 373 | 536 | } |
| 374 | 537 | break; |
| 538 | ||
| 539 | case LDSTATE_STEPPING_BY_PARAMETER_PAUSED: | |
| 540 | /* generic pause behavior */ | |
| 541 | ld->state.state = LDSTATE_PAUSED; | |
| 542 | advanceby = ldcore_generic_update(ld, vbi, fieldnum, curtime, &newstate); | |
| 543 | if (newstate.state != LDSTATE_PAUSED) | |
| 544 | pr8210_switch_state(ld, newstate.state, newstate.param); | |
| 545 | else | |
| 546 | ld->state.state = LDSTATE_STEPPING_BY_PARAMETER_PAUSED; | |
| 547 | break; | |
| 375 | 548 | } |
| 376 | 549 | |
| 377 | 550 | return advanceby; |
| 378 | 551 | } |
| 379 | 552 | |
| 380 | 553 | |
| 554 | ||
| 381 | 555 | /*------------------------------------------------- |
| 382 | pr8210_command - Pioneer PR-8210-specific | |
| 556 | pr8210_hle_command - Pioneer PR-8210-specific | |
| 383 | 557 | command processing |
| 384 | 558 | -------------------------------------------------*/ |
| 385 | 559 | |
| 386 | static void pr8210_command(laserdisc_state *ld) | |
| 560 | #if (!EMULATE_PR8210_ROM) | |
| 561 | static void pr8210_hle_command(laserdisc_state *ld) | |
| 387 | 562 | { |
| 388 | 563 | ldplayer_data *player = ld->player; |
| 389 | 564 | UINT8 cmd = player->lastcommand; |
| r3232 | r3233 | |
| 526 | 701 | break; |
| 527 | 702 | } |
| 528 | 703 | } |
| 704 | #endif | |
| 529 | 705 | |
| 530 | 706 | |
| 531 | 707 | /*------------------------------------------------- |
| r3232 | r3233 | |
| 576 | 752 | |
| 577 | 753 | //printf("New command = %02X (last=%02X)\n", newcommand, player->lastcommand); |
| 578 | 754 | |
| 755 | #if EMULATE_PR8210_ROM | |
| 756 | printf("Command = %02X\n", newcommand); | |
| 757 | // player->pia_porta = BITSWAP8(newcommand, 4,3,2,1,0,5,6,7); | |
| 758 | player->pia_porta = BITSWAP8(newcommand, 0,1,2,3,4,5,6,7); | |
| 759 | #else | |
| 579 | 760 | /* if we got a double command, act on it */ |
| 580 | 761 | if (newcommand == player->lastcommand) |
| 581 | 762 | { |
| 582 | pr8210_command(ld); | |
| 763 | pr8210_hle_command(ld); | |
| 583 | 764 | player->lastcommand = 0; |
| 584 | 765 | } |
| 585 | 766 | else |
| 586 | 767 | player->lastcommand = newcommand; |
| 768 | #endif | |
| 587 | 769 | } |
| 588 | 770 | } |
| 589 | 771 | } |
| r3232 | r3233 | |
| 702 | 884 | void simutrek_set_audio_squelch(const device_config *device, int state) |
| 703 | 885 | { |
| 704 | 886 | laserdisc_state *ld = ldcore_get_safe_token(device); |
| 705 | int squelch = (state != ASSERT_LINE); | |
| 706 | ldcore_set_audio_squelch(ld, squelch, squelch); | |
| 887 | int squelch = (state == 0); | |
| 888 | if (squelch) | |
| 889 | ldcore_set_audio_squelch(ld, squelch, squelch); | |
| 890 | else | |
| 891 | ldcore_set_audio_squelch(ld, squelch, squelch); | |
| 707 | 892 | } |
| 708 | 893 | |
| 709 | 894 | |
| r3232 | r3233 | |
| 720 | 905 | |
| 721 | 906 | player->cmd_ack_callback = callback; |
| 722 | 907 | } |
| 908 | ||
| 909 | ||
| 910 | ||
| 911 | /*************************************************************************** | |
| 912 | RE-IMPLEMENTATION USING ACTUAL ROMS | |
| 913 | ***************************************************************************/ | |
| 914 | ||
| 915 | /************************************* | |
| 916 | * | |
| 917 | * Test PR-8210 ROM emulation | |
| 918 | * | |
| 919 | *************************************/ | |
| 920 | ||
| 921 | static laserdisc_state *find_pr8210(running_machine *machine) | |
| 922 | { | |
| 923 | return ldcore_get_safe_token(device_list_first(machine->config->devicelist, LASERDISC)); | |
| 924 | } | |
| 925 | ||
| 926 | ||
| 927 | static READ8_HANDLER( pr8210_pia_r ) | |
| 928 | { | |
| 929 | laserdisc_state *ld = find_pr8210(machine); | |
| 930 | ldplayer_data *player = ld->player; | |
| 931 | UINT8 result = player->pia[offset]; | |
| 932 | switch (offset) | |
| 933 | { | |
| 934 | case 0x22: | |
| 935 | case 0x23: | |
| 936 | case 0x24: | |
| 937 | case 0x25: | |
| 938 | case 0x26: | |
| 939 | case 0x27: | |
| 940 | case 0xc0: | |
| 941 | case 0xe0: | |
| 942 | break; | |
| 943 | ||
| 944 | case 0xa0: | |
| 945 | // printf("%03X:pia_r(%02X) = %02X\n", activecpu_get_pc(), offset, player->pia_porta); | |
| 946 | result = player->pia_porta; | |
| 947 | // player->pia_porta = 0; | |
| 948 | break; | |
| 949 | ||
| 950 | default: | |
| 951 | printf("%03X:pia_r(%02X)\n", activecpu_get_pc(), offset); | |
| 952 | break; | |
| 953 | } | |
| 954 | return result; | |
| 955 | } | |
| 956 | ||
| 957 | static WRITE8_HANDLER( pr8210_pia_w ) | |
| 958 | { | |
| 959 | /* | |
| 960 | $22-26 (R) = read and copied to memory $23-27 | |
| 961 | $23 (R) = something compared against $F4 | |
| 962 | $22-26 (W) = SRCH. text | |
| 963 | $27-2B (W) = FRAME/CHAP. text | |
| 964 | $2C-30 (W) = frame or chapter number | |
| 965 | $40 (W) = $CF at initialization, tracked by ($78) | |
| 966 | $60 (W) = port B output, tracked by ($77) | |
| 967 | $80 = n/c | |
| 968 | $40 = (out) LED3 | |
| 969 | $20 = (out) LED2 | |
| 970 | $10 = (out) LED1 | |
| 971 | 123 -> LHL = Play | |
| 972 | -> HLL = Slow fwd | |
| 973 | -> LLL = Slow rev | |
| 974 | -> HHL = Still | |
| 975 | -> LLH = Pause | |
| 976 | -> HHH = all off | |
| 977 | $08 = (out) CAV LED | |
| 978 | $04 = (out) CLV LED | |
| 979 | $02 = (out) A2 LED/AUDIO 2 | |
| 980 | $01 = (out) A1 LED/AUDIO 1 | |
| 981 | $80 (W) = 0 or 1 | |
| 982 | $A0 (R) = port A input | |
| 983 | $C0 (R) = stored to ($2E) | |
| 984 | $E0 (R) = stored to ($2F) | |
| 985 | */ | |
| 986 | laserdisc_state *ld = find_pr8210(machine); | |
| 987 | ldplayer_data *player = ld->player; | |
| 988 | if (player->pia[offset] != data) | |
| 989 | { | |
| 990 | switch (offset) | |
| 991 | { | |
| 992 | case 0x40: | |
| 993 | if (!(data & 0x02) && (player->pia[offset] & 0x02)) | |
| 994 | player->framedisplay = 1; | |
| 995 | printf("%03X:pia_w(%02X) = %02X\n", activecpu_get_pc(), offset, data); | |
| 996 | break; | |
| 997 | ||
| 998 | case 0x60: | |
| 999 | printf("%03X:pia_w(%02X) = %02X (PORT B LEDS:", activecpu_get_pc(), offset, data); | |
| 1000 | output_set_value("pr8210_audio1", (data & 0x01) != 0); | |
| 1001 | output_set_value("pr8210_audio2", (data & 0x02) != 0); | |
| 1002 | output_set_value("pr8210_clv", (data & 0x04) != 0); | |
| 1003 | output_set_value("pr8210_cav", (data & 0x08) != 0); | |
| 1004 | output_set_value("pr8210_led1", (data & 0x10) == 0); | |
| 1005 | output_set_value("pr8210_led2", (data & 0x20) == 0); | |
| 1006 | output_set_value("pr8210_led3", (data & 0x40) == 0); | |
| 1007 | if (!(data & 0x80)) printf(" ???"); | |
| 1008 | printf(")\n"); | |
| 1009 | player->pia_portb = data; | |
| 1010 | update_audio_squelch(ld); | |
| 1011 | break; | |
| 1012 | ||
| 1013 | default: | |
| 1014 | printf("%03X:pia_w(%02X) = %02X\n", activecpu_get_pc(), offset, data); | |
| 1015 | break; | |
| 1016 | } | |
| 1017 | player->pia[offset] = data; | |
| 1018 | } | |
| 1019 | } | |
| 1020 | ||
| 1021 | static READ8_HANDLER( pr8210_bus_r ) | |
| 1022 | { | |
| 1023 | /* | |
| 1024 | $80 = n/c | |
| 1025 | $40 = (in) slider pot interrupt source (slider position limit detector, inside and outside) | |
| 1026 | $20 = n/c | |
| 1027 | $10 = (in) /FOCUS LOCK | |
| 1028 | $08 = (in) /SPDL LOCK | |
| 1029 | $04 = (in) SIZE 8/12 | |
| 1030 | $02 = (in) FG via op-amp (spindle motor stop detector) | |
| 1031 | $01 = (in) SLOW TIMER OUT | |
| 1032 | */ | |
| 1033 | laserdisc_state *ld = find_pr8210(machine); | |
| 1034 | ldplayer_data *player = ld->player; | |
| 1035 | slider_position sliderpos = ldcore_get_slider_position(ld); | |
| 1036 | UINT8 focus_on = !(player->porta & 0x08); | |
| 1037 | UINT8 spdl_on = !(player->porta & 0x10); | |
| 1038 | UINT8 result = 0x00; | |
| 1039 | ||
| 1040 | /* bus bit 6: slider position limit detector, inside and outside */ | |
| 1041 | if (sliderpos != SLIDER_MINIMUM && sliderpos != SLIDER_MAXIMUM) | |
| 1042 | result |= 0x40; | |
| 1043 | ||
| 1044 | /* bus bit 4: /FOCUS LOCK */ | |
| 1045 | if (!focus_on) | |
| 1046 | result |= 0x10; | |
| 1047 | ||
| 1048 | /* bus bit 3: /SPDL LOCK */ | |
| 1049 | if (!spdl_on) | |
| 1050 | result |= 0x08; | |
| 1051 | ||
| 1052 | /* bus bit 1: spindle motor stop detector */ | |
| 1053 | if (!spdl_on) | |
| 1054 | result |= 0x02; | |
| 1055 | ||
| 1056 | /* loop at beginning waits for $40=0, $02=1 */ | |
| 1057 | return result; | |
| 1058 | } | |
| 1059 | ||
| 1060 | static WRITE8_HANDLER( pr8210_porta_w ) | |
| 1061 | { | |
| 1062 | /* | |
| 1063 | $80 = (out) SCAN C (F/R) | |
| 1064 | $40 = (out) AUDIO SQ | |
| 1065 | $20 = (out) VIDEO SQ | |
| 1066 | $10 = (out) /SPDL ON | |
| 1067 | $08 = (out) /FOCUS ON | |
| 1068 | $04 = (out) SCAN B (L/H) | |
| 1069 | $02 = (out) SCAN A (/SCAN) | |
| 1070 | $01 = (out) JUMP TRG (jump back trigger, clock on high->low) | |
| 1071 | */ | |
| 1072 | laserdisc_state *ld = find_pr8210(machine); | |
| 1073 | ldplayer_data *player = ld->player; | |
| 1074 | if ((data & 0xfe) != (player->porta & 0xfe)) | |
| 1075 | { | |
| 1076 | int direction = (data & 0x80) ? 1 : -1; | |
| 1077 | ||
| 1078 | printf("%03X:porta_w = %02X", activecpu_get_pc(), data); | |
| 1079 | if (!(data & 0x01) && (player->porta & 0x01)) | |
| 1080 | ldcore_advance_slider(ld, direction); | |
| 1081 | if (!(data & 0x02)) | |
| 1082 | printf(" SCAN:%c:%c", (data & 0x80) ? 'F' : 'R', (data & 0x04) ? 'L' : 'H'); | |
| 1083 | if (!(data & 0x08)) printf(" /FOCUSON"); | |
| 1084 | if (!(data & 0x10)) printf(" /SPDLON"); | |
| 1085 | if (data & 0x20) printf(" VIDEOSQ"); | |
| 1086 | if (data & 0x40) printf(" AUDIOSQ"); | |
| 1087 | printf("\n"); | |
| 1088 | player->porta = data; | |
| 1089 | ||
| 1090 | ldcore_set_video_squelch(ld, (data & 0x20) != 0); | |
| 1091 | update_audio_squelch(ld); | |
| 1092 | if (!(data & 0x02)) | |
| 1093 | { | |
| 1094 | int delta = (data & 0x04) ? PR8210_SCAN_SPEED : PR8210_SEEK_FAST_SPEED; | |
| 1095 | ldcore_set_slider_speed(ld, delta * direction); | |
| 1096 | } | |
| 1097 | else | |
| 1098 | ldcore_set_slider_speed(ld, 0); | |
| 1099 | } | |
| 1100 | } | |
| 1101 | ||
| 1102 | static WRITE8_HANDLER( pr8210_portb_w ) | |
| 1103 | { | |
| 1104 | /* | |
| 1105 | $80 = (out) /CS on PIA | |
| 1106 | $40 = (out) 0 to self-generate IRQ | |
| 1107 | $20 = (out) SLOW TRG | |
| 1108 | $10 = (out) STANDBY LED | |
| 1109 | $08 = (out) TP2 | |
| 1110 | $04 = (out) TP1 | |
| 1111 | $02 = (out) ??? | |
| 1112 | $01 = (out) LASER ON | |
| 1113 | */ | |
| 1114 | laserdisc_state *ld = find_pr8210(machine); | |
| 1115 | ldplayer_data *player = ld->player; | |
| 1116 | cpunum_set_input_line(machine, player->cpunum, 0, (data & 0x40) ? CLEAR_LINE : ASSERT_LINE); | |
| 1117 | if ((data & 0x7f) != (player->portb & 0x7f)) | |
| 1118 | { | |
| 1119 | printf("%03X:portb_w = %02X", activecpu_get_pc(), data); | |
| 1120 | if (!(data & 0x01)) printf(" LASERON"); | |
| 1121 | if (!(data & 0x02)) printf(" ???"); | |
| 1122 | if (!(data & 0x04)) printf(" TP1"); | |
| 1123 | if (!(data & 0x08)) printf(" TP2"); | |
| 1124 | output_set_value("pr8210_standby", !(data & 0x10)); | |
| 1125 | if (!(data & 0x20)) printf(" SLOWTRG"); | |
| 1126 | if (!(data & 0x40)) printf(" IRQGEN"); | |
| 1127 | // if (data & 0x80) printf(" PIASEL"); | |
| 1128 | printf("\n"); | |
| 1129 | player->portb = data; | |
| 1130 | } | |
| 1131 | } | |
| 1132 | ||
| 1133 | ||
| 1134 | static READ8_HANDLER( pr8210_t0_r ) | |
| 1135 | { | |
| 1136 | /* returns VSYNC state */ | |
| 1137 | laserdisc_state *ld = find_pr8210(machine); | |
| 1138 | return !ld->player->vsync; | |
| 1139 | } | |
| 1140 | ||
| 1141 | ||
| 1142 | static READ8_HANDLER( pr8210_t1_r ) | |
| 1143 | { | |
| 1144 | /* must return 1 or else it tries to jump to an external ROM */ | |
| 1145 | return 1; | |
| 1146 | } | |
| 1147 | ||
| 1148 | ||
| 1149 | static ADDRESS_MAP_START( pr8210_map, ADDRESS_SPACE_PROGRAM, 8 ) | |
| 1150 | AM_RANGE(0x000, 0x7ff) AM_ROM | |
| 1151 | ADDRESS_MAP_END | |
| 1152 | ||
| 1153 | ||
| 1154 | static ADDRESS_MAP_START( pr8210_portmap, ADDRESS_SPACE_IO, 8 ) | |
| 1155 | AM_RANGE(0x00, 0xff) AM_READWRITE(pr8210_pia_r, pr8210_pia_w) | |
| 1156 | AM_RANGE(MCS48_PORT_BUS, MCS48_PORT_BUS) AM_READ(pr8210_bus_r) | |
| 1157 | AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1) AM_WRITE(pr8210_porta_w) | |
| 1158 | AM_RANGE(MCS48_PORT_P2, MCS48_PORT_P2) AM_WRITE(pr8210_portb_w) | |
| 1159 | AM_RANGE(MCS48_PORT_T0, MCS48_PORT_T0) AM_READ(pr8210_t0_r) | |
| 1160 | AM_RANGE(MCS48_PORT_T1, MCS48_PORT_T1) AM_READ(pr8210_t1_r) | |
| 1161 | ADDRESS_MAP_END | |
| 1162 | ||
| 1163 | ||
| 1164 | MACHINE_DRIVER_START( pr8210 ) | |
| 1165 | MDRV_CPU_ADD("pr8210", I8049, XTAL_4_41MHz) | |
| 1166 | MDRV_CPU_PROGRAM_MAP(pr8210_map,0) | |
| 1167 | MDRV_CPU_IO_MAP(pr8210_portmap,0) | |
| 1168 | MACHINE_DRIVER_END |
| r3232 | r3233 | |
|---|---|---|
| 447 | 447 | state_save_register_item(unique_tag, 0, z80dma->is_read); |
| 448 | 448 | state_save_register_item(unique_tag, 0, z80dma->cur_cycle); |
| 449 | 449 | state_save_register_item(unique_tag, 0, z80dma->latch); |
| 450 | ||
| 451 | return DEVICE_START_OK; | |
| 450 | 452 | } |
| 451 | 453 | |
| 452 | 454 |
| r3232 | r3233 | |
|---|---|---|
| 537 | 537 | state_save_register_item_array(unique_tag, 0, ppi8255->out_mask); |
| 538 | 538 | state_save_register_item_array(unique_tag, 0, ppi8255->read); |
| 539 | 539 | state_save_register_item_array(unique_tag, 0, ppi8255->latch); |
| 540 | ||
| 541 | return DEVICE_START_OK; | |
| 540 | 542 | } |
| 541 | 543 | |
| 542 | 544 |
| r3232 | r3233 | |
|---|---|---|
| 539 | 539 | state_save_register_item_array(unique_tag, 0, smc->tx); |
| 540 | 540 | state_save_register_item(unique_tag, 0, smc->sent); |
| 541 | 541 | state_save_register_item(unique_tag, 0, smc->recd); |
| 542 | ||
| 543 | return DEVICE_START_OK; | |
| 542 | 544 | } |
| 543 | 545 | |
| 544 | 546 |
| r3232 | r3233 | |
|---|---|---|
| 389 | 389 | state_save_register_item(unique_tag, 0, dma8257->drq); |
| 390 | 390 | state_save_register_item(unique_tag, 0, dma8257->status); |
| 391 | 391 | |
| 392 | return DEVICE_START_OK; | |
| 392 | 393 | } |
| 393 | 394 | |
| 394 | 395 |
| r3232 | r3233 | |
|---|---|---|
| 153 | 153 | msm6242->reg[1] = 0; |
| 154 | 154 | msm6242->reg[2] = 0; |
| 155 | 155 | memset(&msm6242->hold_time, 0, sizeof(mame_system_time)); |
| 156 | ||
| 157 | return DEVICE_START_OK; | |
| 156 | 158 | } |
| 157 | 159 | |
| 158 | 160 |
| r3232 | r3233 | |
|---|---|---|
| 1963 | 1963 | |
| 1964 | 1964 | /* register callbacks */ |
| 1965 | 1965 | config_register(device->machine, "laserdisc", configuration_load, configuration_save); |
| 1966 | ||
| 1967 | return DEVICE_START_OK; | |
| 1966 | 1968 | } |
| 1967 | 1969 | |
| 1968 | 1970 |
| r3232 | r3233 | |
|---|---|---|
| 372 | 372 | pic8259_t *pic8259 = get_safe_token(device); |
| 373 | 373 | |
| 374 | 374 | pic8259->intf = device->static_config; |
| 375 | ||
| 376 | return DEVICE_START_OK; | |
| 375 | 377 | } |
| 376 | 378 | |
| 377 | 379 |
| r3232 | r3233 | |
|---|---|---|
| 29 | 29 | LASERDISC_TYPE_PIONEER_PR8210, /* Pioneer PR-8210 / LD-V1100 */ |
| 30 | 30 | LASERDISC_TYPE_SIMUTREK_SPECIAL, /* Pioneer PR-8210 with mods */ |
| 31 | 31 | LASERDISC_TYPE_PIONEER_LDV1000, /* Pioneer LD-V1000 */ |
| 32 | LASERDISC_TYPE_PHILLIPS_22VP931, /* Phillips 22VP931 */ | |
| 32 | 33 | LASERDISC_TYPE_PHILLIPS_22VP932, /* Phillips 22VP932 (PAL) */ |
| 33 | 34 | LASERDISC_TYPE_SONY_LDP1450 /* Sony LDP-1450 */ |
| 34 | 35 | }; |
| r3232 | r3233 | |
| 71 | 72 | { |
| 72 | 73 | UINT32 type; |
| 73 | 74 | laserdisc_audio_func audio; |
| 74 | ||
| 75 | /* rendering information */ | |
| 75 | const char * sound; | |
| 76 | 76 | const char * screen; |
| 77 | 77 | |
| 78 | 78 | /* overlay information */ |
| r3232 | r3233 | |
| 89 | 89 | DEVICE CONFIGURATION MACROS |
| 90 | 90 | ***************************************************************************/ |
| 91 | 91 | |
| 92 | #define MDRV_LASERDISC_ADD(_tag, _type) \ | |
| 92 | #define MDRV_LASERDISC_ADD(_tag, _type, _screen, _sound) \ | |
| 93 | 93 | MDRV_DEVICE_ADD(_tag, LASERDISC) \ |
| 94 | MDRV_DEVICE_CONFIG_DATA32(laserdisc_config, type, LASERDISC_TYPE_##_type) | |
| 94 | MDRV_DEVICE_CONFIG_DATA32(laserdisc_config, type, LASERDISC_TYPE_##_type) \ | |
| 95 | MDRV_DEVICE_CONFIG_DATAPTR(laserdisc_config, screen, _screen) \ | |
| 96 | MDRV_DEVICE_CONFIG_DATAPTR(laserdisc_config, sound, _sound) \ | |
| 95 | 97 | |
| 96 | 98 | #define MDRV_LASERDISC_AUDIO(_func) \ |
| 97 | 99 | MDRV_DEVICE_CONFIG_DATAPTR(laserdisc_config, audio, _func) |
| 98 | 100 | |
| 99 | #define MDRV_LASERDISC_SCREEN(_tag) \ | |
| 100 | MDRV_DEVICE_CONFIG_DATAPTR(laserdisc_config, screen, _tag) | |
| 101 | ||
| 102 | 101 | #define MDRV_LASERDISC_OVERLAY(_update, _width, _height, _format) \ |
| 103 | 102 | MDRV_DEVICE_CONFIG_DATAPTR(laserdisc_config, overupdate, video_update_##_update) \ |
| 104 | 103 | MDRV_DEVICE_CONFIG_DATA32(laserdisc_config, overwidth, _width) \ |
| r3232 | r3233 | |
| 158 | 157 | |
| 159 | 158 | /* ----- core control and status ----- */ |
| 160 | 159 | |
| 161 | /* call this once per field (i.e., 59.94 times/second for NTSC) */ | |
| 162 | void laserdisc_vsync(const device_config *device); | |
| 163 | ||
| 164 | 160 | /* get a bitmap for the current frame (and the frame number) */ |
| 165 | 161 | UINT32 laserdisc_get_video(const device_config *device, bitmap_t **bitmap); |
| 166 | 162 |
| r3232 | r3233 | |
|---|---|---|
| 33 | 33 | |
| 34 | 34 | /* we simulate extra lead-in and lead-out tracks */ |
| 35 | 35 | #define VIRTUAL_LEAD_IN_TRACKS 200 |
| 36 | #define MAX_TOTAL_TRACKS 54000 | |
| 36 | 37 | #define VIRTUAL_LEAD_OUT_TRACKS 200 |
| 37 | 38 | |
| 38 | 39 | |
| r3232 | r3233 | |
| 50 | 51 | |
| 51 | 52 | /* disc parameters */ |
| 52 | 53 | chd_file * disc; /* handle to the disc itself */ |
| 54 | int width; /* width of video */ | |
| 55 | int height; /* height of video */ | |
| 56 | UINT32 fps_times_1million; /* frame rate of video */ | |
| 57 | int samplerate; /* audio samplerate */ | |
| 58 | UINT8 readpending; /* true if a read is pending */ | |
| 59 | UINT32 chdtracks; /* number of tracks in the CHD */ | |
| 53 | 60 | av_codec_decompress_config avconfig; /* decompression configuration */ |
| 54 | UINT8 readpending; /* true if a read is pending */ | |
| 55 | UINT32 maxtrack; /* maximum track number */ | |
| 56 | 61 | |
| 57 | 62 | /* core states */ |
| 58 | 63 | UINT8 audiosquelch; /* audio squelch state: bit 0 = audio 1, bit 1 = audio 2 */ |
| 59 | 64 | UINT8 videosquelch; /* video squelch state: bit 0 = on/off */ |
| 60 | 65 | UINT8 fieldnum; /* field number (0 or 1) */ |
| 61 | INT32 curtrack; /* current track */ | |
| 66 | INT32 curtrack; /* current track at this end of this vsync */ | |
| 67 | UINT32 maxtrack; /* maximum track number */ | |
| 68 | attoseconds_t attospertrack; /* attoseconds per track, or 0 if not moving */ | |
| 69 | attotime sliderupdate; /* time of last slider update */ | |
| 62 | 70 | |
| 63 | 71 | /* video data */ |
| 64 | 72 | bitmap_t * videoframe[3]; /* currently cached frames */ |
| r3232 | r3233 | |
| 77 | 85 | UINT32 audiocursamples; /* current samples this track */ |
| 78 | 86 | UINT32 audiomaxsamples; /* maximum samples per track */ |
| 79 | 87 | int audiocustom; /* custom sound index */ |
| 80 | int samplerate; /* playback samplerate */ | |
| 81 | 88 | |
| 82 | 89 | /* metadata */ |
| 83 | 90 | vbi_metadata metadata[2]; /* metadata parsed from the stream, for each field */ |
| r3232 | r3233 | |
| 261 | 268 | |
| 262 | 269 | |
| 263 | 270 | /*------------------------------------------------- |
| 264 | audio_channel_active - return TRUE if the | |
| 265 | given audio channel should be output | |
| 271 | update_audio - update the audio stream to the | |
| 272 | current time | |
| 266 | 273 | -------------------------------------------------*/ |
| 267 | 274 | |
| 268 | INLINE i | |
| 275 | INLINE void | |
| 269 | 276 | { |
| 270 | return (~ldcore->audiosquelch >> channel) & 1; | |
| 277 | if (ldcore->audiocustom != -1) | |
| 278 | { | |
| 279 | sound_token *token = custom_get_token(ldcore->audiocustom); | |
| 280 | stream_update(token->stream); | |
| 281 | } | |
| 271 | 282 | } |
| 272 | 283 | |
| 273 | 284 | |
| 274 | 285 | /*------------------------------------------------- |
| 275 | video_active - return TRUE if the video should | |
| 276 | be output | |
| 286 | add_and_clamp_track - add a delta to the | |
| 287 | current track and clamp to minimum/maximum | |
| 288 | values | |
| 277 | 289 | -------------------------------------------------*/ |
| 278 | 290 | |
| 279 | INLINE | |
| 291 | INLINE | |
| 280 | 292 | { |
| 281 | return !ldcore->videosquelch; | |
| 282 | } | |
| 283 | ||
| 284 | ||
| 285 | /*------------------------------------------------- | |
| 286 | add_to_current_track - add a value to the | |
| 287 | current track, stopping if we hit the min or | |
| 288 | max | |
| 289 | -------------------------------------------------*/ | |
| 290 | ||
| 291 | INLINE int add_to_current_track(ldcore_data *ldcore, INT32 delta) | |
| 292 | { | |
| 293 | 293 | ldcore->curtrack += delta; |
| 294 | if (ldcore->curtrack < 1) | |
| 295 | { | |
| 296 | ldcore->curtrack = 1; | |
| 297 | return TRUE; | |
| 298 | } | |
| 299 | else if (ldcore->curtrack >= ldcore->maxtrack - 1) | |
| 300 | { | |
| 301 | ldcore->curtrack = ldcore->maxtrack - 1; | |
| 302 | return TRUE; | |
| 303 | } | |
| 304 | return FALSE; | |
| 294 | ldcore->curtrack = MAX(ldcore->curtrack, 1); | |
| 295 | ldcore->curtrack = MIN(ldcore->curtrack, ldcore->maxtrack - 1); | |
| 305 | 296 | } |
| 306 | 297 | |
| 307 | 298 | |
| r3232 | r3233 | |
| 335 | 326 | ***************************************************************************/ |
| 336 | 327 | |
| 337 | 328 | /*------------------------------------------------- |
| 338 | laserdisc_vsync - call this once per field | |
| 339 | on the VSYNC signal | |
| 329 | update_slider_pos - based on the current | |
| 330 | speed and elapsed time, update the current | |
| 331 | track position | |
| 340 | 332 | -------------------------------------------------*/ |
| 341 | 333 | |
| 342 | void | |
| 334 | static void update_slider | |
| 343 | 335 | { |
| 336 | /* if not moving, update to now */ | |
| 337 | if (ldcore->attospertrack == 0) | |
| 338 | ldcore->sliderupdate = curtime; | |
| 339 | ||
| 340 | /* otherwise, compute the number of tracks covered */ | |
| 341 | else | |
| 342 | { | |
| 343 | attoseconds_t delta = attotime_to_attoseconds(attotime_sub(curtime, ldcore->sliderupdate)); | |
| 344 | INT32 tracks_covered; | |
| 345 | ||
| 346 | /* determine how many tracks we covered and advance */ | |
| 347 | if (ldcore->attospertrack >= 0) | |
| 348 | { | |
| 349 | tracks_covered = delta / ldcore->attospertrack; | |
| 350 | add_and_clamp_track(ldcore, tracks_covered); | |
| 351 | if (tracks_covered != 0) | |
| 352 | ldcore->sliderupdate = attotime_add_attoseconds(ldcore->sliderupdate, tracks_covered * ldcore->attospertrack); | |
| 353 | } | |
| 354 | else | |
| 355 | { | |
| 356 | tracks_covered = delta / -ldcore->attospertrack; | |
| 357 | add_and_clamp_track(ldcore, -tracks_covered); | |
| 358 | if (tracks_covered != 0) | |
| 359 | ldcore->sliderupdate = attotime_add_attoseconds(ldcore->sliderupdate, tracks_covered * -ldcore->attospertrack); | |
| 360 | } | |
| 361 | } | |
| 362 | } | |
| 363 | ||
| 364 | ||
| 365 | /*------------------------------------------------- | |
| 366 | vblank_state_changed - called on each state | |
| 367 | change of the VBLANK signal | |
| 368 | -------------------------------------------------*/ | |
| 369 | ||
| 370 | static void vblank_state_changed(const device_config *screen, void *param, int vblank_state) | |
| 371 | { | |
| 372 | const device_config *device = param; | |
| 344 | 373 | laserdisc_state *ld = get_safe_token(device); |
| 345 | 374 | ldcore_data *ldcore = ld->core; |
| 375 | attotime curtime = timer_get_time(); | |
| 346 | 376 | |
| 377 | /* update current track based on slider speed */ | |
| 378 | update_slider_pos(ldcore, curtime); | |
| 379 | ||
| 380 | /* on rising edge, call the player-specific VSYNC function */ | |
| 381 | if (vblank_state) | |
| 382 | { | |
| 383 | if (ldcore->intf.vsync != NULL) | |
| 384 | (*ldcore->intf.vsync)(ld); | |
| 385 | return; | |
| 386 | } | |
| 387 | ||
| 388 | /* on falling edge, do the bulk of the processing */ | |
| 347 | 389 | /* wait for previous read and decode to finish */ |
| 348 | 390 | process_track_data(device); |
| 349 | 391 | |
| 350 | 392 | /* update the state */ |
| 351 | 393 | if (ldcore->intf.update != NULL) |
| 352 | { | |
| 353 | INT32 advanceby = (*ldcore->intf.update)(ld, &ldcore->metadata[ldcore->fieldnum], ldcore->fieldnum, timer_get_time()); | |
| 354 | add_to_current_track(ldcore, advanceby); | |
| 355 | } | |
| 394 | add_and_clamp_track(ldcore, (*ldcore->intf.update)(ld, &ldcore->metadata[ldcore->fieldnum], ldcore->fieldnum, curtime)); | |
| 356 | 395 | |
| 357 | 396 | /* flush any audio before we read more */ |
| 358 | if (ldcore->audiocustom != -1) | |
| 359 | { | |
| 360 | sound_token *token = custom_get_token(ldcore->audiocustom); | |
| 361 | stream_update(token->stream); | |
| 362 | } | |
| 397 | update_audio(ldcore); | |
| 363 | 398 | |
| 364 | 399 | /* start reading the track data for the next round */ |
| 365 | 400 | ldcore->fieldnum ^= 1; |
| r3232 | r3233 | |
| 481 | 516 | frameindex = (frameindex + ARRAY_LENGTH(ldcore->videofields) - 1) % ARRAY_LENGTH(ldcore->videofields); |
| 482 | 517 | |
| 483 | 518 | /* if no video present, return the empty frame */ |
| 484 | if ( | |
| 519 | if (ldcore->videosqu | |
| 485 | 520 | { |
| 486 | 521 | *bitmap = ldcore->emptyframe; |
| 487 | 522 | return 0; |
| r3232 | r3233 | |
| 506 | 541 | int field = ldcore->fieldnum ^ 1; |
| 507 | 542 | |
| 508 | 543 | /* if no video present, return */ |
| 509 | if ( | |
| 544 | if (ldcore->videosqu | |
| 510 | 545 | return 0; |
| 511 | 546 | |
| 512 | 547 | switch (code) |
| r3232 | r3233 | |
| 551 | 586 | |
| 552 | 587 | void ldcore_set_audio_squelch(laserdisc_state *ld, UINT8 squelchleft, UINT8 squelchright) |
| 553 | 588 | { |
| 589 | update_audio(ld->core); | |
| 554 | 590 | ld->core->audiosquelch = (squelchleft ? 1 : 0) | (squelchright ? 2 : 0); |
| 555 | 591 | } |
| 556 | 592 | |
| r3232 | r3233 | |
| 566 | 602 | } |
| 567 | 603 | |
| 568 | 604 | |
| 605 | /*------------------------------------------------- | |
| 606 | ldcore_set_slider_speed - dynamically change | |
| 607 | the slider speed | |
| 608 | -------------------------------------------------*/ | |
| 569 | 609 | |
| 610 | void ldcore_set_slider_speed(laserdisc_state *ld, INT32 tracks_per_vsync) | |
| 611 | { | |
| 612 | ldcore_data *ldcore = ld->core; | |
| 613 | attotime vsyncperiod = video_screen_get_frame_period(ld->screen); | |
| 614 | ||
| 615 | update_slider_pos(ldcore, timer_get_time()); | |
| 616 | ||
| 617 | /* if 0, set the time to 0 */ | |
| 618 | if (tracks_per_vsync == 0) | |
| 619 | ldcore->attospertrack = 0; | |
| 620 | ||
| 621 | /* positive values store positive times */ | |
| 622 | else if (tracks_per_vsync > 0) | |
| 623 | ldcore->attospertrack = attotime_to_attoseconds(attotime_div(vsyncperiod, tracks_per_vsync)); | |
| 624 | ||
| 625 | /* negative values store negative times */ | |
| 626 | else | |
| 627 | ldcore->attospertrack = -attotime_to_attoseconds(attotime_div(vsyncperiod, -tracks_per_vsync)); | |
| 628 | ||
| 629 | printf("Slider speed = %d\n", tracks_per_vsync); | |
| 630 | } | |
| 631 | ||
| 632 | ||
| 633 | /*------------------------------------------------- | |
| 634 | ldcore_advance_slider - advance the slider by | |
| 635 | a certain number of tracks | |
| 636 | -------------------------------------------------*/ | |
| 637 | ||
| 638 | void ldcore_advance_slider(laserdisc_state *ld, INT32 numtracks) | |
| 639 | { | |
| 640 | ldcore_data *ldcore = ld->core; | |
| 641 | ||
| 642 | update_slider_pos(ldcore, timer_get_time()); | |
| 643 | add_and_clamp_track(ldcore, numtracks); | |
| 644 | printf("Advance by %d\n", numtracks); | |
| 645 | } | |
| 646 | ||
| 647 | ||
| 648 | /*------------------------------------------------- | |
| 649 | ldcore_get_slider_position - get the current | |
| 650 | slider position | |
| 651 | -------------------------------------------------*/ | |
| 652 | ||
| 653 | slider_position ldcore_get_slider_position(laserdisc_state *ld) | |
| 654 | { | |
| 655 | ldcore_data *ldcore = ld->core; | |
| 656 | ||
| 657 | /* update the slider position first */ | |
| 658 | update_slider_pos(ldcore, timer_get_time()); | |
| 659 | ||
| 660 | /* return the status */ | |
| 661 | if (ldcore->curtrack == 1) | |
| 662 | return SLIDER_MINIMUM; | |
| 663 | else if (ldcore->curtrack < VIRTUAL_LEAD_IN_TRACKS) | |
| 664 | return SLIDER_VIRTUAL_LEADIN; | |
| 665 | else if (ldcore->curtrack < VIRTUAL_LEAD_IN_TRACKS + ldcore->chdtracks) | |
| 666 | return SLIDER_CHD; | |
| 667 | else if (ldcore->curtrack < VIRTUAL_LEAD_IN_TRACKS + MAX_TOTAL_TRACKS) | |
| 668 | return SLIDER_OUTSIDE_CHD; | |
| 669 | else if (ldcore->curtrack < ldcore->maxtrack - 1) | |
| 670 | return SLIDER_VIRTUAL_LEADOUT; | |
| 671 | else | |
| 672 | return SLIDER_MAXIMUM; | |
| 673 | } | |
| 674 | ||
| 675 | ||
| 676 | ||
| 570 | 677 | /*************************************************************************** |
| 571 | 678 | GENERIC HELPER FUNCTIONS |
| 572 | 679 | ***************************************************************************/ |
| r3232 | r3233 | |
| 792 | 899 | ldcore->avconfig.maxsamples = ldcore->audiomaxsamples; |
| 793 | 900 | ldcore->avconfig.actsamples = &ldcore->audiocursamples; |
| 794 | 901 | ldcore->audiocursamples = 0; |
| 795 | if (!audio_channel_active(ldcore, 0)) | |
| 796 | ldcore->avconfig.audio[0] = NULL; | |
| 797 | if (!audio_channel_active(ldcore, 1)) | |
| 798 | ldcore->avconfig.audio[1] = NULL; | |
| 799 | 902 | |
| 800 | 903 | /* configure the codec and then read */ |
| 801 | 904 | if (ldcore->disc != NULL) |
| r3232 | r3233 | |
| 803 | 906 | err = chd_codec_config(ldcore->disc, AV_CODEC_DECOMPRESS_CONFIG, &ldcore->avconfig); |
| 804 | 907 | if (err == CHDERR_NONE) |
| 805 | 908 | { |
| 806 | INT32 maxtrack = chd_get_header(ldcore->disc)->totalhunks / 2; | |
| 807 | 909 | INT32 chdtrack = tracknum - 1 - VIRTUAL_LEAD_IN_TRACKS; |
| 808 | 910 | |
| 809 | 911 | /* clamp the track */ |
| 810 | 912 | chdtrack = MAX(chdtrack, 0); |
| 811 | chdtrack = MIN(chdtrack, | |
| 913 | chdtrack = MIN(chdtrack, ldcore->chdtracks - 1); | |
| 812 | 914 | err = chd_read_async(ldcore->disc, chdtrack * 2 + fieldnum, NULL); |
| 813 | 915 | ldcore->readpending = TRUE; |
| 814 | 916 | } |
| r3232 | r3233 | |
| 1005 | 1107 | ldcore_data *ldcore = ld->core; |
| 1006 | 1108 | stream_sample_t *dst0 = outputs[0]; |
| 1007 | 1109 | stream_sample_t *dst1 = outputs[1]; |
| 1110 | INT16 leftand, rightand; | |
| 1008 | 1111 | int samples_avail = 0; |
| 1009 | 1112 | |
| 1113 | /* compute AND values based on the squelch */ | |
| 1114 | leftand = (ldcore->audiosquelch & 1) ? 0x0000 : 0xffff; | |
| 1115 | rightand = (ldcore->audiosquelch & 2) ? 0x0000 : 0xffff; | |
| 1116 | ||
| 1010 | 1117 | /* see if we have enough samples to fill the buffer; if not, drop out */ |
| 1011 | 1118 | if (ld != NULL) |
| 1012 | 1119 | { |
| r3232 | r3233 | |
| 1032 | 1139 | /* copy samples, clearing behind us as we go */ |
| 1033 | 1140 | while (sampout != ldcore->audiobufin && samples-- > 0) |
| 1034 | 1141 | { |
| 1035 | *dst0++ = buffer0[sampout]; | |
| 1036 | *dst1++ = buffer1[sampout]; | |
| 1142 | *dst0++ = buffer0[sampout] & leftand; | |
| 1143 | *dst1++ = buffer1[sampout] & rightand; | |
| 1037 | 1144 | buffer0[sampout] = 0; |
| 1038 | 1145 | buffer1[sampout] = 0; |
| 1039 | 1146 | sampout++; |
| r3232 | r3233 | |
| 1046 | 1153 | if (samples > 0) |
| 1047 | 1154 | { |
| 1048 | 1155 | int sampout = (ldcore->audiobufout == 0) ? ldcore->audiobufsize - 1 : ldcore->audiobufout - 1; |
| 1049 | stream_sample_t fill0 = buffer0[sampout]; | |
| 1050 | stream_sample_t fill1 = buffer1[sampout]; | |
| 1156 | stream_sample_t fill0 = buffer0[sampout] & leftand; | |
| 1157 | stream_sample_t fill1 = buffer1[sampout] & rightand; | |
| 1051 | 1158 | |
| 1052 | 1159 | while (samples-- > 0) |
| 1053 | 1160 | { |
| r3232 | r3233 | |
| 1308 | 1415 | |
| 1309 | 1416 | |
| 1310 | 1417 | /*************************************************************************** |
| 1311 | | |
| 1418 | | |
| 1312 | 1419 | ***************************************************************************/ |
| 1313 | 1420 | |
| 1314 | 1421 | /*------------------------------------------------- |
| 1315 | device start callback | |
| 1422 | init_disc - initialize the state of the | |
| 1423 | CHD disc | |
| 1316 | 1424 | -------------------------------------------------*/ |
| 1317 | 1425 | |
| 1318 | static | |
| 1426 | static void init_disc | |
| 1319 | 1427 | { |
| 1320 | int fps = 30, fpsfrac = 0, width = 720, height = 240, interlaced = 1, channels = 2, rate = 44100; | |
| 1321 | const laserdisc_config *config = device->inline_config; | |
| 1322 | 1428 | laserdisc_state *ld = get_safe_token(device); |
| 1323 | UINT32 fps_times_1million; | |
| 1324 | ldcore_data *ldcore; | |
| 1325 | char metadata[256]; | |
| 1326 | int sndnum, index; | |
| 1327 | int statesize; | |
| 1429 | ldcore_data *ldcore = ld->core; | |
| 1328 | 1430 | chd_error err; |
| 1329 | 1431 | |
| 1330 | /* save a copy of the device pointer */ | |
| 1331 | ld->device = device; | |
| 1332 | ||
| 1333 | /* allocate memory for the core state */ | |
| 1334 | ld->core = auto_malloc(sizeof(*ld->core)); | |
| 1335 | memset(ld->core, 0, sizeof(*ld->core)); | |
| 1336 | ldcore = ld->core; | |
| 1337 | ||
| 1338 | /* determine the maximum player-specific state size and allocate it */ | |
| 1339 | statesize = 0; | |
| 1340 | for (index = 0; index < ARRAY_LENGTH(player_interfaces); index++) | |
| 1341 | statesize = MAX(statesize, player_interfaces[index]->statesize); | |
| 1342 | ld->player = auto_malloc(statesize); | |
| 1343 | memset(ld->player, 0, statesize); | |
| 1344 | ||
| 1345 | /* copy config data to the live state */ | |
| 1346 | ldcore->config = *config; | |
| 1347 | if (ldcore->config.overclip.max_x == ldcore->config.overclip.min_x || ldcore->config.overclip.max_y == ldcore->config.overclip.min_y) | |
| 1348 | { | |
| 1349 | ldcore->config.overclip.min_x = ldcore->config.overclip.min_y = 0; | |
| 1350 | ldcore->config.overclip.max_x = ldcore->config.overwidth - 1; | |
| 1351 | ldcore->config.overclip.max_y = ldcore->config.overheight - 1; | |
| 1352 | } | |
| 1353 | if (ldcore->config.overscalex == 0) | |
| 1354 | ldcore->config.overscalex = 1.0f; | |
| 1355 | if (ldcore->config.overscaley == 0) | |
| 1356 | ldcore->config.overscaley = 1.0f; | |
| 1357 | ||
| 1358 | 1432 | /* find the disc */ |
| 1359 | 1433 | ldcore->disc = get_disk_handle(device->tag); |
| 1360 | ldcore->audiocustom = 0; | |
| 1361 | for (sndnum = 0; sndnum < MAX_SOUND; sndnum++) | |
| 1362 | { | |
| 1363 | if (device->machine->config->sound[sndnum].tag != NULL && strcmp(device->machine->config->sound[sndnum].tag, device->tag) == 0) | |
| 1364 | break; | |
| 1365 | if (device->machine->config->sound[sndnum].type == SOUND_CUSTOM) | |
| 1366 | ldcore->audiocustom++; | |
| 1367 | } | |
| 1368 | if (sndnum == MAX_SOUND) | |
| 1369 | ldcore->audiocustom = -1; | |
| 1370 | 1434 | |
| 1435 | /* set default parameters */ | |
| 1436 | ldcore->width = 720; | |
| 1437 | ldcore->height = 240; | |
| 1438 | ldcore->fps_times_1million = 59940000; | |
| 1439 | ldcore->samplerate = 48000; | |
| 1440 | ||
| 1371 | 1441 | /* get the disc metadata and extract the ld */ |
| 1442 | ldcore->chdtracks = 0; | |
| 1443 | ldcore->maxtrack = VIRTUAL_LEAD_IN_TRACKS + MAX_TOTAL_TRACKS + VIRTUAL_LEAD_OUT_TRACKS; | |
| 1372 | 1444 | if (ldcore->disc != NULL) |
| 1373 | 1445 | { |
| 1446 | int fps, fpsfrac, interlaced, channels; | |
| 1447 | char metadata[256]; | |
| 1448 | ||
| 1374 | 1449 | /* require the A/V codec */ |
| 1375 | 1450 | if (chd_get_header(ldcore->disc)->compression != CHDCOMPRESSION_AV) |
| 1376 | 1451 | fatalerror("Laserdisc video must be compressed with the A/V codec!"); |
| 1377 | 1452 | |
| 1378 | /* read | |
| 1453 | /* read | |
| 1379 | 1454 | err = chd_get_metadata(ldcore->disc, AV_METADATA_TAG, 0, metadata, sizeof(metadata), NULL, NULL); |
| 1380 | 1455 | if (err != CHDERR_NONE) |
| 1381 | 1456 | fatalerror("Non-A/V CHD file specified"); |
| 1382 | if (sscanf(metadata, AV_METADATA_FORMAT, &fps, &fpsfrac, &width, &height, &interlaced, &channels, &rate) != 7) | |
| 1457 | ||
| 1458 | /* extract the metadata */ | |
| 1459 | if (sscanf(metadata, AV_METADATA_FORMAT, &fps, &fpsfrac, &ldcore->width, &ldcore->height, &interlaced, &channels, &ldcore->samplerate) != 7) | |
| 1383 | 1460 | fatalerror("Invalid metadata in CHD file"); |
| 1461 | else | |
| 1462 | ldcore->fps_times_1million = fps * 1000000 + fpsfrac; | |
| 1384 | 1463 | |
| 1385 | 1464 | /* require interlaced video */ |
| 1386 | 1465 | if (!interlaced) |
| 1387 | 1466 | fatalerror("Laserdisc video must be interlaced!"); |
| 1388 | 1467 | |
| 1389 | 1468 | /* determine the maximum track and allocate a frame buffer */ |
| 1390 | ldcore-> | |
| 1469 | ldcore->chdtracks = chd_get_header(ldcore->disc)->totalhunks / 2; | |
| 1391 | 1470 | } |
| 1392 | else | |
| 1393 | ldcore->maxtrack = 54000; | |
| 1394 | ldcore->maxtrack += VIRTUAL_LEAD_IN_TRACKS + VIRTUAL_LEAD_OUT_TRACKS; | |
| 1471 | ldcore->maxtrack = MAX(ldcore->maxtrack, VIRTUAL_LEAD_IN_TRACKS + VIRTUAL_LEAD_OUT_TRACKS + ldcore->chdtracks); | |
| 1472 | } | |
| 1395 | 1473 | |
| 1474 | ||
| 1475 | /*------------------------------------------------- | |
| 1476 | init_video - initialize the state of the | |
| 1477 | video rendering | |
| 1478 | -------------------------------------------------*/ | |
| 1479 | ||
| 1480 | static void init_video(const device_config *device) | |
| 1481 | { | |
| 1482 | laserdisc_state *ld = get_safe_token(device); | |
| 1483 | ldcore_data *ldcore = ld->core; | |
| 1484 | int index; | |
| 1485 | ||
| 1486 | /* register for VBLANK callbacks */ | |
| 1487 | video_screen_register_vblank_callback(ld->screen, vblank_state_changed, (void *)device); | |
| 1488 | ||
| 1396 | 1489 | /* allocate video frames */ |
| 1397 | 1490 | for (index = 0; index < ARRAY_LENGTH(ldcore->videofields); index++) |
| 1398 | 1491 | { |
| 1399 | 1492 | /* first allocate a YUY16 bitmap at 2x the height */ |
| 1400 | ldcore->videoframe[index] = auto_bitmap_alloc(width, height * 2, BITMAP_FORMAT_YUY16); | |
| 1493 | ldcore->videoframe[index] = auto_bitmap_alloc(ldcore->width, ldcore->height * 2, BITMAP_FORMAT_YUY16); | |
| 1401 | 1494 | fillbitmap_yuy16(ldcore->videoframe[index], 40, 109, 240); |
| 1402 | 1495 | |
| 1403 | 1496 | /* make a copy of the bitmap that clips out the VBI and horizontal blanking areas */ |
| r3232 | r3233 | |
| 1409 | 1502 | } |
| 1410 | 1503 | |
| 1411 | 1504 | /* allocate an empty frame of the same size */ |
| 1412 | ldcore->emptyframe = auto_bitmap_alloc(width, height * 2, BITMAP_FORMAT_YUY16); | |
| 1505 | ldcore->emptyframe = auto_bitmap_alloc(ldcore->width, ldcore->height * 2, BITMAP_FORMAT_YUY16); | |
| 1413 | 1506 | fillbitmap_yuy16(ldcore->emptyframe, 0, 128, 128); |
| 1414 | 1507 | |
| 1415 | /* allocate audio buffers */ | |
| 1416 | fps_times_1million = fps * 1000000 + fpsfrac; | |
| 1417 | ldcore->audiomaxsamples = ((UINT64)rate * 1000000 + fps_times_1million - 1) / fps_times_1million; | |
| 1418 | ldcore->audiobufsize = ldcore->audiomaxsamples * 4; | |
| 1419 | ldcore->audiobuffer[0] = auto_malloc(ldcore->audiobufsize * sizeof(ldcore->audiobuffer[0][0])); | |
| 1420 | ldcore->audiobuffer[1] = auto_malloc(ldcore->audiobufsize * sizeof(ldcore->audiobuffer[1][0])); | |
| 1421 | ldcore->samplerate = rate; | |
| 1422 | ||
| 1423 | 1508 | /* allocate texture for rendering */ |
| 1424 | 1509 | ldcore->videoenable = TRUE; |
| 1425 | 1510 | ldcore->videotex = render_texture_alloc(NULL, NULL); |
| r3232 | r3233 | |
| 1436 | 1521 | if (ldcore->overtex == NULL) |
| 1437 | 1522 | fatalerror("Out of memory allocating overlay texture"); |
| 1438 | 1523 | } |
| 1524 | } | |
| 1439 | 1525 | |
| 1526 | ||
| 1527 | /*------------------------------------------------- | |
| 1528 | init_audio - initialize the state of the | |
| 1529 | audio rendering | |
| 1530 | -------------------------------------------------*/ | |
| 1531 | ||
| 1532 | static void init_audio(const device_config *device) | |
| 1533 | { | |
| 1534 | laserdisc_state *ld = get_safe_token(device); | |
| 1535 | ldcore_data *ldcore = ld->core; | |
| 1536 | int sndnum; | |
| 1537 | ||
| 1538 | /* find the custom audio */ | |
| 1539 | ldcore->audiocustom = 0; | |
| 1540 | for (sndnum = 0; sndnum < MAX_SOUND; sndnum++) | |
| 1541 | { | |
| 1542 | if (device->machine->config->sound[sndnum].tag != NULL && strcmp(device->machine->config->sound[sndnum].tag, ldcore->config.sound) == 0) | |
| 1543 | break; | |
| 1544 | if (device->machine->config->sound[sndnum].type == SOUND_CUSTOM) | |
| 1545 | ldcore->audiocustom++; | |
| 1546 | } | |
| 1547 | if (sndnum == MAX_SOUND) | |
| 1548 | ldcore->audiocustom = -1; | |
| 1549 | ||
| 1550 | /* allocate audio buffers */ | |
| 1551 | ldcore->audiomaxsamples = ((UINT64)ldcore->samplerate * 1000000 + ldcore->fps_times_1million - 1) / ldcore->fps_times_1million; | |
| 1552 | ldcore->audiobufsize = ldcore->audiomaxsamples * 4; | |
| 1553 | ldcore->audiobuffer[0] = auto_malloc(ldcore->audiobufsize * sizeof(ldcore->audiobuffer[0][0])); | |
| 1554 | ldcore->audiobuffer[1] = auto_malloc(ldcore->audiobufsize * sizeof(ldcore->audiobuffer[1][0])); | |
| 1555 | } | |
| 1556 | ||
| 1557 | ||
| 1558 | ||
| 1559 | /*************************************************************************** | |
| 1560 | DEVICE INTERFACE | |
| 1561 | ***************************************************************************/ | |
| 1562 | ||
| 1563 | /*------------------------------------------------- | |
| 1564 | device start callback | |
| 1565 | -------------------------------------------------*/ | |
| 1566 | ||
| 1567 | static DEVICE_START( laserdisc ) | |
| 1568 | { | |
| 1569 | const laserdisc_config *config = device->inline_config; | |
| 1570 | laserdisc_state *ld = get_safe_token(device); | |
| 1571 | ldcore_data *ldcore; | |
| 1572 | int statesize; | |
| 1573 | int index; | |
| 1574 | ||
| 1575 | /* ensure that our screen is started first */ | |
| 1576 | ld->screen = devtag_get_device(device->machine, VIDEO_SCREEN, config->screen); | |
| 1577 | assert(ld->screen != NULL); | |
| 1578 | if (!ld->screen->started) | |
| 1579 | return DEVICE_START_MISSING_DEPENDENCY; | |
| 1580 | ||
| 1581 | /* save a copy of the device pointer */ | |
| 1582 | ld->device = device; | |
| 1583 | ||
| 1584 | /* allocate memory for the core state */ | |
| 1585 | ld->core = auto_malloc(sizeof(*ld->core)); | |
| 1586 | memset(ld->core, 0, sizeof(*ld->core)); | |
| 1587 | ldcore = ld->core; | |
| 1588 | ||
| 1589 | /* determine the maximum player-specific state size and allocate it */ | |
| 1590 | statesize = 0; | |
| 1591 | for (index = 0; index < ARRAY_LENGTH(player_interfaces); index++) | |
| 1592 | statesize = MAX(statesize, player_interfaces[index]->statesize); | |
| 1593 | ld->player = auto_malloc(statesize); | |
| 1594 | memset(ld->player, 0, statesize); | |
| 1595 | ||
| 1596 | /* copy config data to the live state */ | |
| 1597 | ldcore->config = *config; | |
| 1598 | if (ldcore->config.overclip.max_x == ldcore->config.overclip.min_x || ldcore->config.overclip.max_y == ldcore->config.overclip.min_y) | |
| 1599 | { | |
| 1600 | ldcore->config.overclip.min_x = ldcore->config.overclip.min_y = 0; | |
| 1601 | ldcore->config.overclip.max_x = ldcore->config.overwidth - 1; | |
| 1602 | ldcore->config.overclip.max_y = ldcore->config.overheight - 1; | |
| 1603 | } | |
| 1604 | if (ldcore->config.overscalex == 0) | |
| 1605 | ldcore->config.overscalex = 1.0f; | |
| 1606 | if (ldcore->config.overscaley == 0) | |
| 1607 | ldcore->config.overscaley = 1.0f; | |
| 1608 | ||
| 1609 | /* initialize the various pieces */ | |
| 1610 | init_disc(device); | |
| 1611 | init_video(device); | |
| 1612 | init_audio(device); | |
| 1613 | ||
| 1440 | 1614 | /* register callbacks */ |
| 1441 | 1615 | config_register(device->machine, "laserdisc", configuration_load, configuration_save); |
| 1616 | ||
| 1617 | return DEVICE_START_OK; | |
| 1442 | 1618 | } |
| 1443 | 1619 | |
| 1444 | 1620 | |
| r3232 | r3233 | |
| 1470 | 1646 | static DEVICE_RESET( laserdisc ) |
| 1471 | 1647 | { |
| 1472 | 1648 | laserdisc_state *ld = get_safe_token(device); |
| 1649 | attotime curtime = timer_get_time(); | |
| 1473 | 1650 | ldcore_data *ldcore = ld->core; |
| 1474 | 1651 | int pltype, line; |
| 1475 | 1652 | |
| r3232 | r3233 | |
| 1490 | 1667 | } |
| 1491 | 1668 | |
| 1492 | 1669 | /* set up the general ld */ |
| 1670 | ldcore->audiosquelch = 3; | |
| 1493 | 1671 | ldcore->videosquelch = 1; |
| 1494 | ldcore->audiosquelch = 3; | |
| 1672 | ldcore->fieldnum = 0; | |
| 1673 | ldcore->curtrack = 1; | |
| 1674 | ldcore->attospertrack = 0; | |
| 1675 | ldcore->sliderupdate = curtime; | |
| 1495 | 1676 | |
| 1496 | /* default to track 1 */ | |
| 1497 | ldcore->curtrack = 1; | |
| 1677 | /* reset metadata */ | |
| 1498 | 1678 | ldcore->last_frame = 0; |
| 1499 | 1679 | ldcore->last_chapter = 0; |
| 1500 | 1680 | |
| r3232 | r3233 | |
| 1538 | 1718 | DEVICE_GET_INFO( laserdisc ) |
| 1539 | 1719 | { |
| 1540 | 1720 | const laserdisc_config *config = NULL; |
| 1721 | const ldplayer_interface *intf = NULL; | |
| 1541 | 1722 | int pltype; |
| 1542 | 1723 | |
| 1543 | 1724 | /* if we have a device, figure out where our config lives */ |
| 1544 | 1725 | if (device != NULL) |
| 1545 | 1726 | { |
| 1546 | 1727 | laserdisc_state *ld = device->token; |
| 1547 | config = (ld == NULL || ld->core == NULL) ? device->inline_config : &ld->core->config; | |
| 1728 | config = device->inline_config; | |
| 1729 | if (ld != NULL && ld->core != NULL) | |
| 1730 | { | |
| 1731 | config = &ld->core->config; | |
| 1732 | intf = &ld->core->intf; | |
| 1733 | } | |
| 1548 | 1734 | } |
| 1549 | 1735 | |
| 1736 | /* if we don't have an interface, but we have a config, look up the interface */ | |
| 1737 | if (intf == NULL && config != NULL) | |
| 1738 | for (pltype = 0; pltype < ARRAY_LENGTH(player_interfaces); pltype++) | |
| 1739 | if (player_interfaces[pltype]->type == config->type) | |
| 1740 | { | |
| 1741 | intf = player_interfaces[pltype]; | |
| 1742 | break; | |
| 1743 | } | |
| 1744 | ||
| 1550 | 1745 | switch (state) |
| 1551 | 1746 | { |
| 1552 | 1747 | /* --- the following bits of info are returned as 64-bit signed integers --- */ |
| r3232 | r3233 | |
| 1555 | 1750 | case DEVINFO_INT_CLASS: info->i = DEVICE_CLASS_VIDEO; break; |
| 1556 | 1751 | case LDINFO_INT_TYPE: info->i = config->type; break; |
| 1557 | 1752 | |
| 1753 | /* --- the following bits of info are returned as pointers --- */ | |
| 1754 | case DEVINFO_PTR_ROM_REGION: info->romregion = (intf != NULL) ? intf->romregion : NULL; break; | |
| 1755 | case DEVINFO_PTR_MACHINE_CONFIG: info->machine_config = (intf != NULL) ? intf->machine_config : NULL; break; | |
| 1756 | ||
| 1558 | 1757 | /* --- the following bits of info are returned as pointers to data or functions --- */ |
| 1559 | 1758 | case DEVINFO_FCT_SET_INFO: info->set_info = DEVICE_SET_INFO_NAME(laserdisc); break; |
| 1560 | 1759 | case DEVINFO_FCT_START: info->start = DEVICE_START_NAME(laserdisc); break; |
| r3232 | r3233 | |
| 1562 | 1761 | case DEVINFO_FCT_RESET: info->reset = DEVICE_RESET_NAME(laserdisc); break; |
| 1563 | 1762 | |
| 1564 | 1763 | /* --- the following bits of info are returned as NULL-terminated strings --- */ |
| 1565 | case DEVINFO_STR_NAME: | |
| 1566 | info->s = "Unknown Laserdisc Player"; | |
| 1567 | for (pltype = 0; pltype < ARRAY_LENGTH(player_interfaces); pltype++) | |
| 1568 | if (player_interfaces[pltype]->type == config->type) | |
| 1569 | info->s = player_interfaces[pltype]->name; | |
| 1570 | break; | |
| 1571 | case DEVINFO_STR_FAMILY: info->s = "Laserdisc Player"; break; | |
| 1572 | case DEVINFO_STR_VERSION: info->s = "1.0"; break; | |
| 1573 | case DEVINFO_STR_SOURCE_FILE: info->s = __FILE__; break; | |
| 1764 | case DEVINFO_STR_NAME: info->s = (intf != NULL) ? intf->name : "Unknown Laserdisc Player"; break; | |
| 1765 | case DEVINFO_STR_FAMILY: info->s = "Laserdisc Player"; break; | |
| 1766 | case DEVINFO_STR_VERSION: info->s = "1.0"; break; | |
| 1767 | case DEVINFO_STR_SOURCE_FILE: info->s = __FILE__; break; | |
| 1574 | 1768 | case DEVINFO_STR_CREDITS: info->s = "Copyright Nicola Salmoria and the MAME Team"; break; |
| 1575 | 1769 | } |
| 1576 | 1770 | } |
| r3232 | r3233 | |
|---|---|---|
| 55 | 55 | LDSTATE_OTHER /* other states start here */ |
| 56 | 56 | }; |
| 57 | 57 | |
| 58 | ||
| 59 | /* slider position */ | |
| 60 | enum _slider_position | |
| 61 | { | |
| 62 | SLIDER_MINIMUM, /* at the minimum value */ | |
| 63 | SLIDER_VIRTUAL_LEADIN, /* within the virtual lead-in area */ | |
| 64 | SLIDER_CHD, /* within the boundaries of the CHD */ | |
| 65 | SLIDER_OUTSIDE_CHD, /* outside of the CHD area but before the virtual lead-out area */ | |
| 66 | SLIDER_VIRTUAL_LEADOUT, /* within the virtual lead-out area */ | |
| 67 | SLIDER_MAXIMUM /* at the maximum value */ | |
| 68 | }; | |
| 69 | typedef enum _slider_position slider_position; | |
| 70 | ||
| 71 | ||
| 58 | 72 | /* special frame and chapter numbers from VBI conversion */ |
| 59 | 73 | #define FRAME_NOT_PRESENT -2 /* no frame number information present */ |
| 60 | 74 | #define FRAME_LEAD_IN -1 /* lead-in code detected */ |
| r3232 | r3233 | |
| 109 | 123 | struct _laserdisc_state |
| 110 | 124 | { |
| 111 | 125 | const device_config * device; /* pointer to owning device */ |
| 126 | const device_config * screen; /* pointer to the screen device */ | |
| 112 | 127 | ldcore_data * core; /* private core data */ |
| 113 | 128 | ldplayer_data * player; /* private player data */ |
| 114 | 129 | |
| r3232 | r3233 | |
| 119 | 134 | |
| 120 | 135 | /* player-specific callbacks */ |
| 121 | 136 | typedef void (*laserdisc_init_func)(laserdisc_state *ld); |
| 137 | typedef void (*laserdisc_vsync_func)(laserdisc_state *ld); | |
| 122 | 138 | typedef INT32 (*laserdisc_update_func)(laserdisc_state *ld, const vbi_metadata *vbi, int fieldnum, attotime curtime); |
| 123 | 139 | typedef void (*laserdisc_w_func)(laserdisc_state *ld, UINT8 prev, UINT8 new); |
| 124 | 140 | typedef UINT8 (*laserdisc_r_func)(laserdisc_state *ld); |
| r3232 | r3233 | |
| 131 | 147 | int type; /* type of the player */ |
| 132 | 148 | size_t statesize; /* size of the state */ |
| 133 | 149 | const char * name; /* name of the player */ |
| 150 | const rom_entry * romregion; /* pointer to ROM region information */ | |
| 151 | const machine_config_token *machine_config; /* pointer to machine configuration */ | |
| 134 | 152 | laserdisc_init_func init; /* initialization callback */ |
| 135 | laserdisc_update_func update; /* update callback */ | |
| 153 | laserdisc_vsync_func vsync; /* vsync begin callback */ | |
| 154 | laserdisc_update_func update; /* update callback (vblank end) */ | |
| 136 | 155 | laserdisc_w_func writedata; /* parallel data write */ |
| 137 | 156 | laserdisc_w_func writeline[LASERDISC_INPUT_LINES]; /* single line write */ |
| 138 | 157 | laserdisc_r_func readdata; /* parallel data read */ |
| r3232 | r3233 | |
| 171 | 190 | /* set the video squelch state */ |
| 172 | 191 | void ldcore_set_video_squelch(laserdisc_state *ld, UINT8 squelch); |
| 173 | 192 | |
| 193 | /* dynamically change the slider speed */ | |
| 194 | void ldcore_set_slider_speed(laserdisc_state *ld, INT32 tracks_per_vsync); | |
| 174 | 195 | |
| 196 | /* advance the slider by a certain number of tracks */ | |
| 197 | void ldcore_advance_slider(laserdisc_state *ld, INT32 numtracks); | |
| 175 | 198 | |
| 199 | /* get the current slider position */ | |
| 200 | slider_position ldcore_get_slider_position(laserdisc_state *ld); | |
| 201 | ||
| 202 | ||
| 203 | ||
| 176 | 204 | /* ----- generic implementations ----- */ |
| 177 | 205 | |
| 178 | 206 | /* generically update in a way that works for most situations */ |
| r3232 | r3233 | |
|---|---|---|
| 156 | 156 | state_save_register_item( unique_tag, 0, c->a9_12v ); |
| 157 | 157 | state_save_register_item( unique_tag, 0, c->oe_12v ); |
| 158 | 158 | state_save_register_item( unique_tag, 0, c->last_write ); |
| 159 | ||
| 160 | return DEVICE_START_OK; | |
| 159 | 161 | } |
| 160 | 162 | |
| 161 | 163 | /*------------------------------------------------- |
| r3232 | r3233 | |
|---|---|---|
| 223 | 223 | state_save_combine_module_and_tag(unique_tag, "latch8", device->tag); |
| 224 | 224 | |
| 225 | 225 | state_save_register_item(unique_tag, 0, latch8->value); |
| 226 | ||
| 227 | return DEVICE_START_OK; | |
| 226 | 228 | } |
| 227 | 229 | |
| 228 | 230 |
| r3232 | r3233 | |
|---|---|---|
| 395 | 395 | dma8237_t *dma8237 = get_safe_token(device); |
| 396 | 396 | |
| 397 | 397 | dma8237->intf = device->static_config; |
| 398 | ||
| 399 | return DEVICE_START_OK; | |
| 398 | 400 | } |
| 399 | 401 | |
| 400 | 402 |
| r3232 | r3233 | |
|---|---|---|
| 156 | 156 | state_save_register_item(unique_tag, 0, cdp1852->next_data); |
| 157 | 157 | state_save_register_item(unique_tag, 0, cdp1852->sr); |
| 158 | 158 | state_save_register_item(unique_tag, 0, cdp1852->next_sr); |
| 159 | ||
| 160 | return DEVICE_START_OK; | |
| 159 | 161 | } |
| 160 | 162 | |
| 161 | 163 | static DEVICE_RESET( cdp1852 ) |
| r3232 | r3233 | |
|---|---|---|
| 1044 | 1044 | } |
| 1045 | 1045 | |
| 1046 | 1046 | |
| 1047 | static v | |
| 1047 | static dev | |
| 1048 | 1048 | pit8253_t *pit8253 = get_safe_token(device); |
| 1049 | 1049 | char unique_tag[30]; |
| 1050 | 1050 | int timerno; |
| r3232 | r3233 | |
| 1087 | 1087 | state_save_register_item(unique_tag, timerno, timer->programmed); |
| 1088 | 1088 | state_save_register_item(unique_tag, timerno, timer->clock); |
| 1089 | 1089 | } |
| 1090 | ||
| 1091 | return DEVICE_START_OK; | |
| 1090 | 1092 | } |
| 1091 | 1093 | |
| 1092 | 1094 | |
| 1093 | 1095 | static DEVICE_START( pit8253 ) { |
| 1094 | common_start( device, TYPE_PIT8253 ); | |
| 1096 | return common_start( device, TYPE_PIT8253 ); | |
| 1095 | 1097 | } |
| 1096 | 1098 | |
| 1097 | 1099 | |
| 1098 | 1100 | static DEVICE_START( pit8254 ) { |
| 1099 | common_start( device, TYPE_PIT8254 ); | |
| 1101 | return common_start( device, TYPE_PIT8254 ); | |
| 1100 | 1102 | } |
| 1101 | 1103 | |
| 1102 | 1104 |
| r3232 | r3233 | |
|---|---|---|
| 99 | 99 | LASERDISC_TYPE_PIONEER_LDV1000, /* type of the player */ |
| 100 | 100 | sizeof(ldplayer_data), /* size of the state */ |
| 101 | 101 | "Pioneer LD-V1000", /* name of the player */ |
| 102 | NULL, /* pointer to ROM region information */ | |
| 103 | NULL, /* pointer to machine configuration */ | |
| 102 | 104 | ldv1000_init, /* initialization callback */ |
| 105 | NULL, /* vsync callback */ | |
| 103 | 106 | ldv1000_update, /* update callback */ |
| 104 | 107 | ldv1000_data_w, /* parallel data write */ |
| 105 | 108 | { /* single line write: */ |
| r3232 | r3233 | |
|---|---|---|
| 947 | 947 | /* return the config that matches the given tag */ |
| 948 | 948 | const input_port_config *input_port_by_index(const input_port_config *portlist, int index); |
| 949 | 949 | |
| 950 | /* return the field that matches the given tag and mask */ | |
| 951 | const input_field_config *input_field_by_tag_and_mask(const input_port_config *portlist, const char *tag, input_port_value mask); | |
| 950 | 952 | |
| 951 | 953 | |
| 954 | ||
| 952 | 955 | /* ----- accessors for input types ----- */ |
| 953 | 956 | |
| 954 | 957 | /* return TRUE if the given type represents an analog control */ |
| r3232 | r3233 | |
|---|---|---|
| 37 | 37 | typedef enum _device_class device_class; |
| 38 | 38 | |
| 39 | 39 | |
| 40 | /* device start results */ | |
| 41 | enum _device_start_err | |
| 42 | { | |
| 43 | DEVICE_START_OK = 0, /* everything is fine */ | |
| 44 | DEVICE_START_MISSING_DEPENDENCY /* at least one device we depend on is not yet started */ | |
| 45 | }; | |
| 46 | typedef enum _device_start_err device_start_err; | |
| 47 | ||
| 48 | ||
| 40 | 49 | /* useful in device_list functions for scanning through all devices */ |
| 41 | 50 | #define DEVICE_TYPE_WILDCARD NULL |
| 42 | 51 | |
| r3232 | r3233 | |
| 58 | 67 | DEVINFO_PTR_FIRST = 0x10000, |
| 59 | 68 | |
| 60 | 69 | DEVINFO_PTR_ROM_REGION = DEVINFO_PTR_FIRST, /* R/O: pointer to device-specific ROM region */ |
| 70 | DEVINFO_PTR_MACHINE_CONFIG, /* R/O: pointer to device-specific machine config */ | |
| 61 | 71 | |
| 62 | 72 | DEVINFO_PTR_DEVICE_SPECIFIC = 0x18000, /* R/W: device-specific values start here */ |
| 63 | 73 | DEVINFO_PTR_LAST = 0x1ffff, |
| r3232 | r3233 | |
| 103 | 113 | #define DEVICE_SET_INFO_CALL(name) DEVICE_SET_INFO_NAME(name)(device, state, info) |
| 104 | 114 | |
| 105 | 115 | #define DEVICE_START_NAME(name) device_start_##name |
| 106 | #define DEVICE_START(name) v | |
| 116 | #define DEVICE_START(name) dev | |
| 107 | 117 | #define DEVICE_START_CALL(name) DEVICE_START_NAME(name)(device) |
| 108 | 118 | |
| 109 | 119 | #define DEVICE_STOP_NAME(name) device_stop_##name |
| r3232 | r3233 | |
| 136 | 146 | /* device interface function types */ |
| 137 | 147 | typedef void (*device_get_info_func)(const device_config *device, UINT32 state, deviceinfo *info); |
| 138 | 148 | typedef void (*device_set_info_func)(const device_config *device, UINT32 state, const deviceinfo *info); |
| 139 | typedef v | |
| 149 | typedef dev | |
| 140 | 150 | typedef void (*device_stop_func)(const device_config *device); |
| 141 | 151 | typedef void (*device_reset_func)(const device_config *device); |
| 142 | 152 | typedef void (*device_nvram_func)(const device_config *device, mame_file *file, int read_or_write); |
| r3232 | r3233 | |
| 162 | 172 | device_validity_check_func validity_check; /* DEVINFO_FCT_VALIDITY_CHECK */ |
| 163 | 173 | device_nvram_func nvram; /* DEVINFO_FCT_NVRAM */ |
| 164 | 174 | const rom_entry * romregion; /* DEVINFO_PTR_ROM_REGION */ |
| 175 | const union _machine_config_token *machine_config;/* DEVINFO_PTR_MACHINE_CONFIG */ | |
| 165 | 176 | }; |
| 166 | 177 | |
| 167 | 178 | |
| r3232 | r3233 | |
| 179 | 190 | const void * static_config; /* static device configuration */ |
| 180 | 191 | void * inline_config; /* inline device configuration */ |
| 181 | 192 | |
| 182 | /* these four fields are only valid if the device is live */ | |
| 193 | /* these fields are only valid if the device is live */ | |
| 194 | UINT8 started; /* TRUE if the start function has succeeded */ | |
| 183 | 195 | void * token; /* token if device is live */ |
| 184 | 196 | running_machine * machine; /* machine if device is live */ |
| 185 | 197 | UINT8 * region; /* pointer to region with the device's tag, or NULL */ |
| r3232 | r3233 | |
|---|---|---|
| 10 | 10 | ***************************************************************************/ |
| 11 | 11 | |
| 12 | 12 | #include "driver.h" |
| 13 | #include "deprecat.h" | |
| 13 | 14 | |
| 14 | 15 | |
| 15 | 16 | |
| r3232 | r3233 | |
| 910 | 911 | * |
| 911 | 912 | *************************************/ |
| 912 | 913 | |
| 913 | INLINE void set_cpu_context(int cpunum) | |
| 914 | INLINE void set_cpu_context(running_machine *machine, int cpunum) | |
| 914 | 915 | { |
| 915 | 916 | int newfamily = cpu[cpunum].family; |
| 916 | 917 | int oldcontext = cpu_active_context[newfamily]; |
| r3232 | r3233 | |
| 921 | 922 | |
| 922 | 923 | /* swap memory spaces */ |
| 923 | 924 | activecpu = cpunum; |
| 924 | memory_set_context(cpunum); | |
| 925 | memory_set_context(machine, cpunum); | |
| 925 | 926 | |
| 926 | 927 | /* if the new CPU's context is not swapped in, do it now */ |
| 927 | 928 | if (oldcontext != cpunum) |
| r3232 | r3233 | |
| 946 | 947 | |
| 947 | 948 | /* do the rest only if this isn't the activecpu */ |
| 948 | 949 | if (cpunum != activecpu && cpunum != -1) |
| 949 | set_cpu_context(cpunum); | |
| 950 | set_cpu_context(Machine, cpunum); | |
| 950 | 951 | |
| 951 | 952 | /* this is now the active CPU */ |
| 952 | 953 | activecpu = cpunum; |
| r3232 | r3233 | |
| 960 | 961 | |
| 961 | 962 | /* do the rest only if this isn't the activecpu */ |
| 962 | 963 | if (cpunum != activecpu && cpunum != -1) |
| 963 | set_cpu_context(cpunum); | |
| 964 | set_cpu_context(Machine, cpunum); | |
| 964 | 965 | |
| 965 | 966 | /* this is now the active CPU */ |
| 966 | 967 | activecpu = cpunum; |
| r3232 | r3233 | |
|---|---|---|
| 332 | 332 | } |
| 333 | 333 | |
| 334 | 334 | /* update the global time */ |
| 335 | timer_set_global_time(target); | |
| 335 | timer_set_global_time(machine, target); | |
| 336 | 336 | } |
| 337 | 337 | |
| 338 | 338 | |
| r3232 | r3233 | |
| 765 | 765 | for this screen |
| 766 | 766 | -------------------------------------------------*/ |
| 767 | 767 | |
| 768 | static void on_vblank(const device_config *device, int vblank_state) | |
| 768 | static void on_vblank(const device_config *device, void *param, int vblank_state) | |
| 769 | 769 | { |
| 770 | 770 | /* VBLANK starting */ |
| 771 | 771 | if (vblank_state) |
| r3232 | r3233 | |
| 971 | 971 | |
| 972 | 972 | assert(screen != NULL); |
| 973 | 973 | |
| 974 | video_screen_register_vblank_callback(screen, on_vblank); | |
| 974 | video_screen_register_vblank_callback(screen, on_vblank, NULL); | |
| 975 | 975 | } |
| 976 | 976 | |
| 977 | 977 | /* periodic interrupts */ |
| r3232 | r3233 | |
|---|---|---|
| 290 | 290 | |
| 291 | 291 | /* Used by assert(), so definition here instead of mame.h */ |
| 292 | 292 | DECL_NORETURN void CLIB_DECL fatalerror(const char *text, ...) ATTR_PRINTF(1,2) ATTR_NORETURN; |
| 293 | DECL_NORETURN void CLIB_DECL fatalerror_exitcode(int exitcode, const char *text, ...) ATTR_PRINTF( | |
| 293 | DECL_NORETURN void CLIB_DECL fatalerror_exitcode(running_machine *machine, int exitcode, const char *text, ...) ATTR_PRINTF( | |
| 294 | 294 | |
| 295 | 295 | |
| 296 | 296 |
| r3232 | r3233 | |
|---|---|---|
| 54 | 54 | |
| 55 | 55 | ***************************************************************************/ |
| 56 | 56 | |
| 57 | #include <ctype.h> | |
| 57 | 58 | #include "render.h" |
| 58 | 59 | #include "rendfont.h" |
| 59 | 60 | #include "rendlay.h" |
| r3232 | r3233 | |
| 223 | 224 | } |
| 224 | 225 | |
| 225 | 226 | |
| 226 | /*------------------------------------------------- | |
| 227 | view_has_art - true if a render_view contains | |
| 228 | any non-screen elements | |
| 229 | -------------------------------------------------*/ | |
| 230 | 227 | |
| 231 | #ifdef UNUSED_FUNCTION | |
| 232 | INLINE int view_has_art(layout_view *view) | |
| 233 | { | |
| 234 | return (view->itemlist[ITEM_LAYER_BACKDROP] != 0 || | |
| 235 | view->itemlist[ITEM_LAYER_OVERLAY] != 0 || | |
| 236 | view->itemlist[ITEM_LAYER_BEZEL] != 0); | |
| 237 | } | |
| 238 | #endif | |
| 239 | ||
| 240 | ||
| 241 | 228 | /*************************************************************************** |
| 242 | 229 | LAYOUT VIEWS |
| 243 | 230 | ***************************************************************************/ |
| r3232 | r3233 | |
| 1451 | 1438 | const char *string = xml_get_attribute_string_with_subst(node, attribute, NULL); |
| 1452 | 1439 | int value; |
| 1453 | 1440 | |
| 1454 | if ( | |
| 1441 | if ( | |
| 1455 | 1442 | return defvalue; |
| 1456 | return value; | |
| 1443 | if (string[0] == '$') | |
| 1444 | return (sscanf(&string[1], "%X", &value) == 1) ? value : defvalue; | |
| 1445 | if (string[0] == '0' && string[1] == 'x') | |
| 1446 | return (sscanf(&string[2], "%X", &value) == 1) ? value : defvalue; | |
| 1447 | if (string[0] == '#') | |
| 1448 | return (sscanf(&string[1], "%d", &value) == 1) ? value : defvalue; | |
| 1449 | return (sscanf(&string[0], "%d", &value) == 1) ? value : defvalue; | |
| 1457 | 1450 | } |
| 1458 | 1451 | |
| 1459 | 1452 | |
| r3232 | r3233 | |
| 1558 | 1551 | *viewnext = view; |
| 1559 | 1552 | viewnext = &view->next; |
| 1560 | 1553 | } |
| 1554 | ||
| 1561 | 1555 | xml_file_free(rootnode); |
| 1562 | 1556 | return file; |
| 1563 | 1557 | |
| r3232 | r3233 | |
| 1821 | 1815 | item = malloc_or_die(sizeof(*item)); |
| 1822 | 1816 | memset(item, 0, sizeof(*item)); |
| 1823 | 1817 | |
| 1824 | /* allocate a copy of the name */ | |
| 1825 | item->name = copy_string(xml_get_attribute_string_with_subst(itemnode, "name", "")); | |
| 1818 | /* allocate a copy of the output name */ | |
| 1819 | item->output_name = copy_string(xml_get_attribute_string_with_subst(itemnode, "name", "")); | |
| 1826 | 1820 | |
| 1821 | /* allocate a copy of the input tag */ | |
| 1822 | item->input_tag = copy_string(xml_get_attribute_string_with_subst(itemnode, "inputtag", "")); | |
| 1823 | ||
| 1827 | 1824 | /* find the associated element */ |
| 1828 | 1825 | name = xml_get_attribute_string_with_subst(itemnode, "element", NULL); |
| 1829 | 1826 | if (name != NULL) |
| r3232 | r3233 | |
| 1843 | 1840 | |
| 1844 | 1841 | /* fetch common data */ |
| 1845 | 1842 | item->index = xml_get_attribute_int_with_subst(itemnode, "index", -1); |
| 1846 | if (item->name[0] != 0 && item->element != 0) | |
| 1847 | output_set_value(item->name, item->element->defstate); | |
| 1843 | item->input_mask = xml_get_attribute_int_with_subst(itemnode, "inputmask", 0); | |
| 1844 | if (item->output_name[0] != 0 && item->element != 0) | |
| 1845 | output_set_value(item->output_name, item->element->defstate); | |
| 1848 | 1846 | if (load_bounds(xml_get_sibling(itemnode->child, "bounds"), &item->rawbounds)) |
| 1849 | 1847 | goto error; |
| 1850 | 1848 | if (load_color(xml_get_sibling(itemnode->child, "color"), &item->color)) |
| r3232 | r3233 | |
| 1867 | 1865 | return item; |
| 1868 | 1866 | |
| 1869 | 1867 | error: |
| 1870 | if (item->name != NULL) | |
| 1871 | free((void *)item->name); | |
| 1868 | if (item->output_name != NULL) | |
| 1869 | free((void *)item->output_name); | |
| 1870 | if (item->input_tag != NULL) | |
| 1871 | free((void *)item->input_tag); | |
| 1872 | 1872 | free(item); |
| 1873 | 1873 | return NULL; |
| 1874 | 1874 | } |
| r3232 | r3233 | |
| 2075 | 2075 | { |
| 2076 | 2076 | view_item *temp = view->itemlist[layer]; |
| 2077 | 2077 | view->itemlist[layer] = temp->next; |
| 2078 | if (temp->name != NULL) | |
| 2079 | free((void *)temp->name); | |
| 2078 | if (temp->output_name != NULL) | |
| 2079 | free((void *)temp->output_name); | |
| 2080 | if (temp->input_tag != NULL) | |
| 2081 | free((void *)temp->input_tag); | |
| 2080 | 2082 | free(temp); |
| 2081 | 2083 | } |
| 2082 | 2084 |
| r3232 | r3233 | |
|---|---|---|
| 120 | 120 | { |
| 121 | 121 | view_item * next; /* link to next item */ |
| 122 | 122 | layout_element * element; /* pointer to the associated element (non-screens only) */ |
| 123 | const char * name; /* name of this item */ | |
| 123 | const char * output_name; /* name of this item */ | |
| 124 | const char * input_tag; /* input tag of this item */ | |
| 125 | UINT32 input_mask; /* input mask of this item */ | |
| 124 | 126 | int index; /* index for this item (screens only) */ |
| 125 | 127 | int orientation; /* orientation of this item */ |
| 126 | 128 | render_bounds bounds; /* bounds of the item */ |
| r3232 | r3233 | |
|---|---|---|
| 30 | 30 | C352_FLG_KEYOFF = 0x2000, // Keyoff |
| 31 | 31 | C352_FLG_LOOPTRG = 0x1000, // Loop Trigger |
| 32 | 32 | C352_FLG_LOOPHIST = 0x0800, // Loop History |
| 33 | C352_FLG_FM = 0x0400, // Frequency Modulation | |
| 33 | C352_FLG_FM = 0x0400, // Frequency Modulation | |
| 34 | 34 | C352_FLG_PHASERL = 0x0200, // Rear Left invert phase 180 degrees |
| 35 | 35 | C352_FLG_PHASEFL = 0x0100, // Front Left invert phase 180 degrees |
| 36 | 36 | C352_FLG_PHASEFR = 0x0080, // invert phase 180 degrees (e.g. flip sign of sample) |
| r3232 | r3233 | |
| 74 | 74 | UINT32 c352_rom_length; |
| 75 | 75 | int sample_rate_base; |
| 76 | 76 | |
| 77 | INT16 level_table[256]; | |
| 78 | ||
| 79 | 77 | long channel_l[2048*2]; |
| 80 | 78 | long channel_r[2048*2]; |
| 81 | 79 | long channel_l2[2048*2]; |
| r3232 | r3233 | |
| 535 | 533 | state_save_register_item(cname, sndindex, info->c352_ch[i].current_addr); |
| 536 | 534 | state_save_register_item(cname, sndindex, info->c352_ch[i].pos); |
| 537 | 535 | } |
| 538 | ||
| 539 | for (i = 0; i < 256; i++) | |
| 540 | { | |
| 541 | double max_level = 255.0; | |
| 542 | ||
| 543 | info->level_table[255-i] = (int) (pow (10.0, (double) i / 256.0 * -20.0 / 20.0) * max_level); | |
| 544 | } | |
| 545 | 536 | } |
| 546 | 537 | |
| 547 | 538 | static void *c352_start(const char *tag, int sndindex, int clock, const void *config) |
| r3232 | r3233 | |
|---|---|---|
| 1209 | 1209 | |
| 1210 | 1210 | /* draw the profiler if visible */ |
| 1211 | 1211 | if (show_profiler) |
| 1212 | ui_draw_text_full(profiler_get_text(), 0.0f, 0.0f, 1.0f, JUSTIFY_LEFT, WRAP_WORD, DRAW_OPAQUE, ARGB_WHITE, ARGB_BLACK, NULL, NULL); | |
| 1212 | ui_draw_text_full(profiler_get_text(machine), 0.0f, 0.0f, 1.0f, JUSTIFY_LEFT, WRAP_WORD, DRAW_OPAQUE, ARGB_WHITE, ARGB_BLACK, NULL, NULL); | |
| 1213 | 1213 | |
| 1214 | 1214 | /* if we're single-stepping, pause now */ |
| 1215 | 1215 | if (single_step) |
| r3232 | r3233 | |
| 1476 | 1476 | tailptr = &(*tailptr)->next; |
| 1477 | 1477 | |
| 1478 | 1478 | /* add per-channel volume */ |
| 1479 | numitems = sound_get_user_gain_count(); | |
| 1479 | numitems = sound_get_user_gain_count(machine); | |
| 1480 | 1480 | for (item = 0; item < numitems; item++) |
| 1481 | 1481 | { |
| 1482 | 1482 | INT32 maxval = 2000; |
| 1483 | INT32 defval = sound_get_default_gain(item) * 1000.0f + 0.5f; | |
| 1483 | INT32 defval = sound_get_default_gain(machine, item) * 1000.0f + 0.5f; | |
| 1484 | 1484 | |
| 1485 | 1485 | if (defval > 1000) |
| 1486 | 1486 | maxval = 2 * defval; |
| 1487 | 1487 | |
| 1488 | astring_printf(string, "%s Volume", sound_get_user_gain_name(item)); | |
| 1488 | astring_printf(string, "%s Volume", sound_get_user_gain_name(machine, item)); | |
| 1489 | 1489 | *tailptr = slider_alloc(astring_c(string), 0, defval, maxval, 20, slider_mixervol, (void *)(FPTR)item); |
| 1490 | 1490 | tailptr = &(*tailptr)->next; |
| 1491 | 1491 | } |
| r3232 | r3233 | |
| 1641 | 1641 | { |
| 1642 | 1642 | int which = (FPTR)arg; |
| 1643 | 1643 | if (newval != SLIDER_NOCHANGE) |
| 1644 | sound_set_user_gain(which, (float)newval * 0.001f); | |
| 1644 | sound_set_user_gain(machine, which, (float)newval * 0.001f); | |
| 1645 | 1645 | if (string != NULL) |
| 1646 | astring_printf(string, "%4.2f", sound_get_user_gain(which)); | |
| 1647 | return floor(sound_get_user_gain(which) * 1000.0f + 0.5f); | |
| 1646 | astring_printf(string, "%4.2f", sound_get_user_gain(machine, which)); | |
| 1647 | return floor(sound_get_user_gain(machine, which) * 1000.0f + 0.5f); | |
| 1648 | 1648 | } |
| 1649 | 1649 | |
| 1650 | 1650 |
| r3232 | r3233 | |
|---|---|---|
| 121 | 121 | ***************************************************************************/ |
| 122 | 122 | |
| 123 | 123 | static void crosshair_exit(running_machine *machine); |
| 124 | static void animate(const device_config *device, int vblank_state); | |
| 124 | static void animate(const device_config *device, void *param, int vblank_state); | |
| 125 | 125 | |
| 126 | 126 | |
| 127 | 127 | /*************************************************************************** |
| r3232 | r3233 | |
| 212 | 212 | |
| 213 | 213 | /* register the animation callback */ |
| 214 | 214 | if (machine->primary_screen != NULL) |
| 215 | video_screen_register_vblank_callback(machine->primary_screen, animate); | |
| 215 | video_screen_register_vblank_callback(machine->primary_screen, animate, NULL); | |
| 216 | 216 | } |
| 217 | 217 | |
| 218 | 218 | |
| r3232 | r3233 | |
| 272 | 272 | animate - animates the crosshair once a frame |
| 273 | 273 | -------------------------------------------------*/ |
| 274 | 274 | |
| 275 | static void animate(const device_config *device, int vblank_state) | |
| 275 | static void animate(const device_config *device, void *param, int vblank_state) | |
| 276 | 276 | { |
| 277 | 277 | int player; |
| 278 | 278 |
| r3232 | r3233 | |
|---|---|---|
| 12 | 12 | #include "osdepend.h" |
| 13 | 13 | #include "driver.h" |
| 14 | 14 | #include "profiler.h" |
| 15 | #include "deprecat.h" | |
| 16 | 15 | |
| 17 | 16 | |
| 18 | 17 | /* in usrintf.c */ |
| r3232 | r3233 | |
| 98 | 97 | } |
| 99 | 98 | } |
| 100 | 99 | |
| 101 | const char *profiler_get_text( | |
| 100 | const char *profiler_get_text(running_machine *machine) | |
| 102 | 101 | { |
| 103 | 102 | int i,j; |
| 104 | 103 | UINT64 total,normalize; |
| r3232 | r3233 | |
| 174 | 173 | } |
| 175 | 174 | if (computed || showdelay[i]) |
| 176 | 175 | { |
| 177 | if (computed) showdelay[i] = ATTOSECONDS_TO_HZ(video_screen_get_frame_period( | |
| 176 | if (computed) showdelay[i] = ATTOSECONDS_TO_HZ(video_screen_get_frame_period(machine->primary_screen).attoseconds); | |
| 178 | 177 | showdelay[i]--; |
| 179 | 178 | |
| 180 | 179 | if (i < PROFILER_PROFILER) |
| r3232 | r3233 | |
|---|---|---|
| 73 | 73 | /* functions called by usrintf.c */ |
| 74 | 74 | void profiler_start(void); |
| 75 | 75 | void profiler_stop(void); |
| 76 | const char *profiler_get_text( | |
| 76 | const char *profiler_get_text(running_machine *machine); | |
| 77 | 77 | #else |
| 78 | 78 | #define profiler_mark(type) |
| 79 | 79 | |
| 80 | 80 | #define profiler_start() |
| 81 | 81 | #define profiler_stop() |
| 82 | #define profiler_get_text() "" | |
| 82 | #define profiler_get_text(machine) "" | |
| 83 | 83 | #endif |
| 84 | 84 | |
| 85 | 85 |
| r3232 | r3233 | |
|---|---|---|
| 14 | 14 | #include "streams.h" |
| 15 | 15 | #include "config.h" |
| 16 | 16 | #include "profiler.h" |
| 17 | #include "deprecat.h" | |
| 18 | 17 | #include "sound/wavwrite.h" |
| 19 | 18 | |
| 20 | 19 | |
| r3232 | r3233 | |
| 117 | 116 | static void sound_load(running_machine *machine, int config_type, xml_data_node *parentnode); |
| 118 | 117 | static void sound_save(running_machine *machine, int config_type, xml_data_node *parentnode); |
| 119 | 118 | static TIMER_CALLBACK( sound_update ); |
| 120 | static void start_sound_chips(void); | |
| 121 | static void route_sound(void); | |
| 119 | static void start_sound_chips(running_machine *machine); | |
| 120 | static void route_sound(running_machine *machine); | |
| 122 | 121 | static void mixer_update(void *param, stream_sample_t **inputs, stream_sample_t **buffer, int length); |
| 123 | 122 | static STATE_POSTLOAD( mixer_postload ); |
| 124 | 123 | |
| r3232 | r3233 | |
| 147 | 146 | find_speaker_by_tag - find a tagged speaker |
| 148 | 147 | -------------------------------------------------*/ |
| 149 | 148 | |
| 150 | INLINE speaker_info *find_speaker_by_tag(const char *tag) | |
| 149 | INLINE speaker_info *find_speaker_by_tag(running_machine *machine, const char *tag) | |
| 151 | 150 | { |
| 152 | const device_config *speaker = device_list_find_by_tag( | |
| 151 | const device_config *speaker = device_list_find_by_tag(machine->config->devicelist, SPEAKER_OUTPUT, tag); | |
| 153 | 152 | return (speaker == NULL) ? NULL : speaker->token; |
| 154 | 153 | } |
| 155 | 154 | |
| r3232 | r3233 | |
| 207 | 206 | |
| 208 | 207 | /* now start up the sound chips and tag their streams */ |
| 209 | 208 | VPRINTF(("start_sound_chips\n")); |
| 210 | start_sound_chips(); | |
| 209 | start_sound_chips(machine); | |
| 211 | 210 | |
| 212 | 211 | /* finally, do all the routing */ |
| 213 | 212 | VPRINTF(("route_sound\n")); |
| 214 | route_sound(); | |
| 213 | route_sound(machine); | |
| 215 | 214 | |
| 216 | 215 | /* open the output WAV file if specified */ |
| 217 | 216 | filename = options_get_string(mame_options(), OPTION_WAVWRITE); |
| r3232 | r3233 | |
| 264 | 263 | and initialize them |
| 265 | 264 | -------------------------------------------------*/ |
| 266 | 265 | |
| 267 | static void start_sound_chips( | |
| 266 | static void start_sound_chips(running_machine *machine) | |
| 268 | 267 | { |
| 269 | 268 | int sndnum; |
| 270 | 269 | |
| r3232 | r3233 | |
| 274 | 273 | /* start up all the sound chips */ |
| 275 | 274 | for (sndnum = 0; sndnum < MAX_SOUND; sndnum++) |
| 276 | 275 | { |
| 277 | const sound_config *msound = & | |
| 276 | const sound_config *msound = &machine->config->sound[sndnum]; | |
| 278 | 277 | sound_info *info; |
| 279 | 278 | int num_regs; |
| 280 | 279 | int index; |
| r3232 | r3233 | |
| 294 | 293 | /* start the chip, tagging all its streams */ |
| 295 | 294 | VPRINTF(("sndnum = %d -- sound_type = %d\n", sndnum, msound->type)); |
| 296 | 295 | num_regs = state_save_get_reg_count(); |
| 297 | streams_set_tag( | |
| 296 | streams_set_tag(machine, info); | |
| 298 | 297 | if (sndintrf_init_sound(sndnum, msound->tag, msound->type, msound->clock, msound->config) != 0) |
| 299 | 298 | fatalerror("Sound chip #%d (%s) failed to initialize!", sndnum, sndnum_name(sndnum)); |
| 300 | 299 | |
| r3232 | r3233 | |
| 303 | 302 | if (num_regs == 0) |
| 304 | 303 | { |
| 305 | 304 | logerror("Sound chip #%d (%s) did not register any state to save!\n", sndnum, sndnum_name(sndnum)); |
| 306 | if ( | |
| 305 | if (machine->gamedrv->flags & GAME_SUPPORTS_SAVE) | |
| 307 | 306 | fatalerror("Sound chip #%d (%s) did not register any state to save!", sndnum, sndnum_name(sndnum)); |
| 308 | 307 | } |
| 309 | 308 | |
| r3232 | r3233 | |
| 311 | 310 | VPRINTF(("Counting outputs\n")); |
| 312 | 311 | for (index = 0; ; index++) |
| 313 | 312 | { |
| 314 | sound_stream *stream = stream_find_by_tag(info, index); | |
| 313 | sound_stream *stream = stream_find_by_tag(machine, info, index); | |
| 315 | 314 | if (!stream) |
| 316 | 315 | break; |
| 317 | 316 | info->outputs += stream_get_outputs(stream); |
| r3232 | r3233 | |
| 329 | 328 | info->outputs = 0; |
| 330 | 329 | for (index = 0; ; index++) |
| 331 | 330 | { |
| 332 | sound_stream *stream = stream_find_by_tag(info, index); | |
| 331 | sound_stream *stream = stream_find_by_tag(machine, info, index); | |
| 333 | 332 | int outputs, outputnum; |
| 334 | 333 | |
| 335 | 334 | if (!stream) |
| r3232 | r3233 | |
| 354 | 353 | inputs |
| 355 | 354 | -------------------------------------------------*/ |
| 356 | 355 | |
| 357 | static void route_sound( | |
| 356 | static void route_sound(running_machine *machine) | |
| 358 | 357 | { |
| 359 | 358 | int sndnum, routenum, outputnum; |
| 360 | 359 | const device_config *curspeak; |
| r3232 | r3233 | |
| 372 | 371 | sound_info *sound; |
| 373 | 372 | |
| 374 | 373 | /* find the target */ |
| 375 | speaker = find_speaker_by_tag(mroute->target); | |
| 374 | speaker = find_speaker_by_tag(machine, mroute->target); | |
| 376 | 375 | sound = find_sound_by_tag(mroute->target); |
| 377 | 376 | |
| 378 | 377 | /* if neither found, it's fatal */ |
| r3232 | r3233 | |
| 391 | 390 | } |
| 392 | 391 | |
| 393 | 392 | /* now allocate the mixers and input data */ |
| 394 | streams_set_tag(Machine, NULL); | |
| 395 | for (curspeak = speaker_output_first(Machine->config); curspeak != NULL; curspeak = speaker_output_next(curspeak)) | |
| 393 | streams_set_tag(machine, NULL); | |
| 394 | for (curspeak = speaker_output_first(machine->config); curspeak != NULL; curspeak = speaker_output_next(curspeak)) | |
| 396 | 395 | { |
| 397 | 396 | speaker_info *info = curspeak->token; |
| 398 | 397 | if (info->inputs != 0) |
| 399 | 398 | { |
| 400 | info->mixer_stream = stream_create(info->inputs, 1, Machine->sample_rate, info, mixer_update); | |
| 401 | state_save_register_postload(Machine, mixer_postload, info->mixer_stream); | |
| 399 | info->mixer_stream = stream_create(info->inputs, 1, machine->sample_rate, info, mixer_update); | |
| 400 | state_save_register_postload(machine, mixer_postload, info->mixer_stream); | |
| 402 | 401 | info->input = auto_malloc(info->inputs * sizeof(*info->input)); |
| 403 | 402 | info->inputs = 0; |
| 404 | 403 | } |
| r3232 | r3233 | |
| 419 | 418 | sound_info *sound; |
| 420 | 419 | |
| 421 | 420 | /* find the target */ |
| 422 | speaker = find_speaker_by_tag(mroute->target); | |
| 421 | speaker = find_speaker_by_tag(machine, mroute->target); | |
| 423 | 422 | sound = find_sound_by_tag(mroute->target); |
| 424 | 423 | |
| 425 | 424 | /* if it's a speaker, set the input */ |
| r3232 | r3233 | |
| 437 | 436 | namebuf[0] = '\0'; |
| 438 | 437 | |
| 439 | 438 | /* speaker name, if more than one speaker */ |
| 440 | if (speaker_output_count( | |
| 439 | if (speaker_output_count(machine->config) > 1) | |
| 441 | 440 | sprintf(namebuf, "%sSpeaker '%s': ", namebuf, speaker->tag); |
| 442 | 441 | |
| 443 | 442 | /* device name */ |
| r3232 | r3233 | |
| 600 | 599 | { |
| 601 | 600 | float defvol = xml_get_attribute_float(channelnode, "defvol", -1000.0); |
| 602 | 601 | float newvol = xml_get_attribute_float(channelnode, "newvol", -1000.0); |
| 603 | if (fabs(defvol - sound_get_default_gain(mixernum)) < 1e-6 && newvol != -1000.0) | |
| 604 | sound_set_user_gain(mixernum, newvol); | |
| 602 | if (fabs(defvol - sound_get_default_gain(machine, mixernum)) < 1e-6 && newvol != -1000.0) | |
| 603 | sound_set_user_gain(machine, mixernum, newvol); | |
| 605 | 604 | } |
| 606 | 605 | } |
| 607 | 606 | } |
| r3232 | r3233 | |
| 624 | 623 | if (parentnode != NULL) |
| 625 | 624 | for (mixernum = 0; mixernum < MAX_MIXER_CHANNELS; mixernum++) |
| 626 | 625 | { |
| 627 | float defvol = sound_get_default_gain(mixernum); | |
| 628 | float newvol = sound_get_user_gain(mixernum); | |
| 626 | float defvol = sound_get_default_gain(machine, mixernum); | |
| 627 | float newvol = sound_get_user_gain(machine, mixernum); | |
| 629 | 628 | |
| 630 | 629 | if (defvol != newvol) |
| 631 | 630 | { |
| r3232 | r3233 | |
| 822 | 821 | /* copy in all the relevant info */ |
| 823 | 822 | info->speaker = device->inline_config; |
| 824 | 823 | info->tag = device->tag; |
| 824 | ||
| 825 | return DEVICE_START_OK; | |
| 825 | 826 | } |
| 826 | 827 | |
| 827 | 828 | |
| r3232 | r3233 | |
| 924 | 925 | a particular input |
| 925 | 926 | -------------------------------------------------*/ |
| 926 | 927 | |
| 927 | INLINE speaker_info *index_to_input(int index, int *input) | |
| 928 | INLINE speaker_info *index_to_input(running_machine *machine, int index, int *input) | |
| 928 | 929 | { |
| 929 | 930 | const device_config *curspeak; |
| 930 | 931 | int count = 0; |
| 931 | 932 | |
| 932 | 933 | /* scan through the speakers until we find the indexed input */ |
| 933 | for (curspeak = speaker_output_first( | |
| 934 | for (curspeak = speaker_output_first(machine->config); curspeak != NULL; curspeak = speaker_output_next(curspeak)) | |
| 934 | 935 | { |
| 935 | 936 | speaker_info *info = curspeak->token; |
| 936 | 937 | if (index < count + info->inputs) |
| r3232 | r3233 | |
| 951 | 952 | of user-controllable gain parameters |
| 952 | 953 | -------------------------------------------------*/ |
| 953 | 954 | |
| 954 | int sound_get_user_gain_count( | |
| 955 | int sound_get_user_gain_count(running_machine *machine) | |
| 955 | 956 | { |
| 956 | 957 | const device_config *curspeak; |
| 957 | 958 | int count = 0; |
| 958 | 959 | |
| 959 | 960 | /* count up the number of speaker inputs */ |
| 960 | for (curspeak = speaker_output_first( | |
| 961 | for (curspeak = speaker_output_first(machine->config); curspeak != NULL; curspeak = speaker_output_next(curspeak)) | |
| 961 | 962 | { |
| 962 | 963 | speaker_info *info = curspeak->token; |
| 963 | 964 | count += info->inputs; |
| r3232 | r3233 | |
| 971 | 972 | value |
| 972 | 973 | -------------------------------------------------*/ |
| 973 | 974 | |
| 974 | void sound_set_user_gain(int index, float gain) | |
| 975 | void sound_set_user_gain(running_machine *machine, int index, float gain) | |
| 975 | 976 | { |
| 976 | 977 | int inputnum; |
| 977 | speaker_info *spk = index_to_input(index, &inputnum); | |
| 978 | speaker_info *spk = index_to_input(machine, index, &inputnum); | |
| 978 | 979 | |
| 979 | 980 | if (spk != NULL) |
| 980 | 981 | { |
| r3232 | r3233 | |
| 989 | 990 | value |
| 990 | 991 | -------------------------------------------------*/ |
| 991 | 992 | |
| 992 | float sound_get_user_gain(int index) | |
| 993 | float sound_get_user_gain(running_machine *machine, int index) | |
| 993 | 994 | { |
| 994 | 995 | int inputnum; |
| 995 | speaker_info *spk = index_to_input(index, &inputnum); | |
| 996 | speaker_info *spk = index_to_input(machine, index, &inputnum); | |
| 996 | 997 | return (spk != NULL) ? spk->input[inputnum].gain : 0; |
| 997 | 998 | } |
| 998 | 999 | |
| r3232 | r3233 | |
| 1002 | 1003 | gain of the nth user value |
| 1003 | 1004 | -------------------------------------------------*/ |
| 1004 | 1005 | |
| 1005 | float sound_get_default_gain(int index) | |
| 1006 | float sound_get_default_gain(running_machine *machine, int index) | |
| 1006 | 1007 | { |
| 1007 | 1008 | int inputnum; |
| 1008 | speaker_info *spk = index_to_input(index, &inputnum); | |
| 1009 | speaker_info *spk = index_to_input(machine, index, &inputnum); | |
| 1009 | 1010 | return (spk != NULL) ? spk->input[inputnum].default_gain : 0; |
| 1010 | 1011 | } |
| 1011 | 1012 | |
| r3232 | r3233 | |
| 1015 | 1016 | of the nth user value |
| 1016 | 1017 | -------------------------------------------------*/ |
| 1017 | 1018 | |
| 1018 | const char *sound_get_user_gain_name(int index) | |
| 1019 | const char *sound_get_user_gain_name(running_machine *machine, int index) | |
| 1019 | 1020 | { |
| 1020 | 1021 | int inputnum; |
| 1021 | speaker_info *spk = index_to_input(index, &inputnum); | |
| 1022 | speaker_info *spk = index_to_input(machine, index, &inputnum); | |
| 1022 | 1023 | return (spk != NULL) ? spk->input[inputnum].name : NULL; |
| 1023 | 1024 | } |
| 1024 | 1025 |
| r3232 | r3233 | |
|---|---|---|
| 88 | 88 | void sound_global_enable(int enable); |
| 89 | 89 | |
| 90 | 90 | /* user gain controls on speaker inputs for mixing */ |
| 91 | int sound_get_user_gain_count(void); | |
| 92 | void sound_set_user_gain(int index, float gain); | |
| 93 | float sound_get_user_gain(int index); | |
| 94 | float sound_get_default_gain(int index); | |
| 95 | const char *sound_get_user_gain_name(int index); | |
| 91 | int sound_get_user_gain_count(running_machine *machine); | |
| 92 | void sound_set_user_gain(running_machine *machine, int index, float gain); | |
| 93 | float sound_get_user_gain(running_machine *machine, int index); | |
| 94 | float sound_get_default_gain(running_machine *machine, int index); | |
| 95 | const char *sound_get_user_gain_name(running_machine *machine, int index); | |
| 96 | 96 | |
| 97 | 97 | /* misc helpers */ |
| 98 | 98 | int sound_find_sndnum_by_tag(const char *tag); |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | #include "mame.h" |
| 23 | 23 | #include "emuopts.h" |
| 24 | 24 | #include "profiler.h" |
| 25 | #include "deprecat.h" | |
| 26 | 25 | |
| 27 | 26 | |
| 28 | 27 | |
| r3232 | r3233 | |
| 82 | 81 | /* a single input device */ |
| 83 | 82 | struct _input_device |
| 84 | 83 | { |
| 84 | running_machine * machine; /* machine we are attached to */ | |
| 85 | 85 | astring * name; /* string name of device */ |
| 86 | 86 | input_device_class devclass; /* class of this device */ |
| 87 | 87 | int devindex; /* device index of this device */ |
| r3232 | r3233 | |
| 719 | 719 | input_device_add - add a new input device |
| 720 | 720 | -------------------------------------------------*/ |
| 721 | 721 | |
| 722 | input_device *input_device_add(input_device_class devclass, const char *name, void *internal) | |
| 722 | input_device *input_device_add(running_machine *machine, input_device_class devclass, const char *name, void *internal) | |
| 723 | 723 | { |
| 724 | 724 | input_device_list *devlist = &device_list[devclass]; |
| 725 | 725 | input_device *device; |
| 726 | 726 | |
| 727 | assert_always(mame_get_phase( | |
| 727 | assert_always(mame_get_phase(machine) == MAME_PHASE_INIT, "Can only call input_device_add at init time!"); | |
| 728 | 728 | assert(name != NULL); |
| 729 | 729 | assert(devclass != DEVICE_CLASS_INVALID && devclass < DEVICE_CLASS_MAXIMUM); |
| 730 | 730 | |
| r3232 | r3233 | |
| 734 | 734 | memset(device, 0, sizeof(*device)); |
| 735 | 735 | |
| 736 | 736 | /* fill in the data */ |
| 737 | device->machine = machine; | |
| 737 | 738 | device->name = astring_cpyc(auto_astring_alloc(), name); |
| 738 | 739 | device->devclass = devclass; |
| 739 | 740 | device->devindex = devlist->count - 1; |
| r3232 | r3233 | |
| 761 | 762 | input_device_item *item; |
| 762 | 763 | input_item_id itemid_std = itemid; |
| 763 | 764 | |
| 764 | assert_always(mame_get_phase( | |
| 765 | assert_always(mame_get_phase(device->machine) == MAME_PHASE_INIT, "Can only call input_device_item_add at init time!"); | |
| 765 | 766 | assert(name != NULL); |
| 766 | 767 | assert(itemid > ITEM_ID_INVALID && itemid < ITEM_ID_MAXIMUM); |
| 767 | 768 | assert(getstate != NULL); |
| r3232 | r3233 | |
|---|---|---|
| 592 | 592 | /* ----- OSD configuration and access ----- */ |
| 593 | 593 | |
| 594 | 594 | /* add a new input device */ |
| 595 | input_device *input_device_add(input_device_class devclass, const char *name, void *internal); | |
| 595 | input_device *input_device_add(running_machine *machine, input_device_class devclass, const char *name, void *internal); | |
| 596 | 596 | |
| 597 | 597 | /* add a new item to an input device */ |
| 598 | 598 | void input_device_item_add(input_device *device, const char *name, void *internal, input_item_id itemid, item_get_state_func getstate); |
| r3232 | r3233 | |
|---|---|---|
| 1606 | 1606 | if (item->element != NULL) |
| 1607 | 1607 | { |
| 1608 | 1608 | int state = 0; |
| 1609 | if (item->name[0] != '\0') | |
| 1610 | state = output_get_value(item->name); | |
| 1611 | ||
| 1609 | if (item->output_name[0] != 0) | |
| 1610 | state = output_get_value(item->output_name); | |
| 1611 | else if (item->input_tag[0] != 0) | |
| 1612 | { | |
| 1613 | const input_field_config *field = input_field_by_tag_and_mask(Machine->portconfig, item->input_tag, item->input_mask); | |
| 1614 | if (field != NULL) | |
| 1615 | state = ((input_port_read_safe(Machine, item->input_tag, 0) ^ field->defvalue) & item->input_mask) ? 1 : 0; | |
| 1616 | } | |
| 1612 | 1617 | add_element_primitives(target, &target->primlist[listnum], &item_xform, item->element, state, blendmode); |
| 1613 | 1618 | } |
| 1614 | 1619 | else |
| r3232 | r3233 | |
| 1673 | 1678 | logic for mapping points |
| 1674 | 1679 | -------------------------------------------------*/ |
| 1675 | 1680 | |
| 1676 | static int render_target_map_point_internal(render_target *target, INT32 target_x, INT32 target_y, | |
| 1677 | render_container *container, const char *input_tag, UINT32 input_mask, float *mapped_x, float *mapped_y) | |
| 1681 | static int render_target_map_point_internal(render_target *target, INT32 target_x, INT32 target_y, render_container *container, float *mapped_x, float *mapped_y, view_item **mapped_item) | |
| 1678 | 1682 | { |
| 1683 | float target_fx, target_fy; | |
| 1684 | view_item *item; | |
| 1679 | 1685 | int layernum; |
| 1680 | view_item *item; | |
| 1681 | float target_fx, target_fy; | |
| 1682 | 1686 | float dummy; |
| 1683 | int hit; | |
| 1684 | 1687 | |
| 1685 | 1688 | /* sanity check */ |
| 1686 | 1689 | if (mapped_x == NULL) |
| r3232 | r3233 | |
| 1688 | 1691 | if (mapped_y == NULL) |
| 1689 | 1692 | mapped_y = &dummy; |
| 1690 | 1693 | |
| 1694 | /* default to point not mapped */ | |
| 1695 | *mapped_x = -1.0; | |
| 1696 | *mapped_y = -1.0; | |
| 1697 | ||
| 1691 | 1698 | /* convert target coordinates to float */ |
| 1692 | 1699 | target_fx = (float)target_x / target->width; |
| 1693 | 1700 | target_fy = (float)target_y / target->height; |
| 1694 | 1701 | |
| 1702 | /* explicitly check for the UI container */ | |
| 1695 | 1703 | if (container != NULL && container == ui_container) |
| 1696 | 1704 | { |
| 1697 | 1705 | /* this hit test went against the UI container */ |
| r3232 | r3233 | |
| 1700 | 1708 | /* this point was successfully mapped */ |
| 1701 | 1709 | *mapped_x = target_fx; |
| 1702 | 1710 | *mapped_y = target_fy; |
| 1711 | *mapped_item = NULL; | |
| 1703 | 1712 | return TRUE; |
| 1704 | 1713 | } |
| 1714 | return FALSE; | |
| 1705 | 1715 | } |
| 1706 | else | |
| 1716 | ||
| 1717 | /* loop through each layer */ | |
| 1718 | for (layernum = 0; layernum < ITEM_LAYER_MAX; layernum++) | |
| 1707 | 1719 | { |
| 1708 | /* loop through each layer */ | |
| 1709 | for (layernum = 0; layernum < ITEM_LAYER_MAX; layernum++) | |
| 1720 | int layer = get_layer_and_blendmode(target->curview, layernum, NULL); | |
| 1721 | if (target->curview->layenabled[layer]) | |
| 1710 | 1722 | { |
| 1711 | int layer = get_layer_and_blendmode(target->curview, layernum, NULL); | |
| 1712 | if (target->curview->layenabled[layer]) | |
| 1723 | /* iterate over items in the layer */ | |
| 1724 | for (item = target->curview->itemlist[layer]; item != NULL; item = item->next) | |
| 1713 | 1725 | { |
| 1714 | /* iterate over items in the layer */ | |
| 1715 | for (item = target->curview->itemlist[layer]; item != NULL; item = item->next) | |
| 1726 | int checkit; | |
| 1727 | ||
| 1728 | /* if we're looking for a particular container, verify that we have the right one */ | |
| 1729 | if (container != NULL) | |
| 1730 | checkit = (item->element == NULL && container == get_screen_container_by_index(item->index)); | |
| 1731 | ||
| 1732 | /* otherwise, assume we're looking for an input */ | |
| 1733 | else | |
| 1734 | checkit = (item->input_tag[0] != 0); | |
| 1735 | ||
| 1736 | /* this target is worth looking at; now check the point */ | |
| 1737 | if (checkit && target_fx >= item->bounds.x0 && target_fx < item->bounds.x1 && target_fy >= item->bounds.y0 && target_fy < item->bounds.y1) | |
| 1716 | 1738 | { |
| 1717 | /* perform the hit test */ | |
| 1718 | if (item->element == NULL && container != NULL) | |
| 1719 | hit = (container == get_screen_container_by_index(item->index)); | |
| 1720 | else | |
| 1721 | hit = FALSE; | |
| 1722 | ||
| 1723 | /* is this item the container in which we are interested? */ | |
| 1724 | if (hit) | |
| 1725 | { | |
| 1726 | /* this target contains the specified container; now check the point */ | |
| 1727 | if (target_fx >= item->bounds.x0 && target_fx < item->bounds.x1 && target_fy >= item->bounds.y0 && target_fy < item->bounds.y1) | |
| 1728 | { | |
| 1729 | /* point successfully mapped */ | |
| 1730 | *mapped_x = (target_fx - item->bounds.x0) / (item->bounds.x1 - item->bounds.x0); | |
| 1731 | *mapped_y = (target_fy - item->bounds.y0) / (item->bounds.y1 - item->bounds.y0); | |
| 1732 | return TRUE; | |
| 1733 | } | |
| 1734 | } | |
| 1739 | /* point successfully mapped */ | |
| 1740 | *mapped_x = (target_fx - item->bounds.x0) / (item->bounds.x1 - item->bounds.x0); | |
| 1741 | *mapped_y = (target_fy - item->bounds.y0) / (item->bounds.y1 - item->bounds.y0); | |
| 1742 | *mapped_item = item; | |
| 1743 | return TRUE; | |
| 1735 | 1744 | } |
| 1736 | 1745 | } |
| 1737 | 1746 | } |
| 1738 | 1747 | } |
| 1739 | ||
| 1740 | /* point not mapped */ | |
| 1741 | *mapped_x = -1.0; | |
| 1742 | *mapped_y = -1.0; | |
| 1743 | 1748 | return FALSE; |
| 1744 | 1749 | } |
| 1745 | 1750 | |
| r3232 | r3233 | |
| 1752 | 1757 | |
| 1753 | 1758 | int render_target_map_point_container(render_target *target, INT32 target_x, INT32 target_y, render_container *container, float *container_x, float *container_y) |
| 1754 | 1759 | { |
| 1755 | return render_target_map_point_internal(target, target_x, target_y, container, NULL, 0, container_x, container_y); | |
| 1760 | view_item *item; | |
| 1761 | return render_target_map_point_internal(target, target_x, target_y, container, container_x, container_y, &item); | |
| 1756 | 1762 | } |
| 1757 | 1763 | |
| 1758 | 1764 | |
| 1759 | 1765 | /*------------------------------------------------- |
| 1766 | render_target_map_point_input - attempts to map | |
| 1767 | a point on the specified render_target to the | |
| 1768 | specified container, if possible | |
| 1769 | -------------------------------------------------*/ | |
| 1770 | ||
| 1771 | int render_target_map_point_input(render_target *target, INT32 target_x, INT32 target_y, const char **input_tag, UINT32 *input_mask, float *input_x, float *input_y) | |
| 1772 | { | |
| 1773 | view_item *item = NULL; | |
| 1774 | int result; | |
| 1775 | ||
| 1776 | result = render_target_map_point_internal(target, target_x, target_y, NULL, input_x, input_y, &item); | |
| 1777 | if (result && item != NULL) | |
| 1778 | { | |
| 1779 | *input_tag = item->input_tag; | |
| 1780 | *input_mask = item->input_mask; | |
| 1781 | } | |
| 1782 | return result; | |
| 1783 | } | |
| 1784 | ||
| 1785 | ||
| 1786 | /*------------------------------------------------- | |
| 1760 | 1787 | load_layout_files - load layout files for a |
| 1761 | 1788 | given render target |
| 1762 | 1789 | -------------------------------------------------*/ |
| r3232 | r3233 | |
|---|---|---|
| 446 | 446 | for (drvindex = 0; drivers[drvindex]; drvindex++) |
| 447 | 447 | if (mame_strwildcmp(gamename, drivers[drvindex]->name) == 0) |
| 448 | 448 | { |
| 449 | machine_config *config = machine_config_alloc(drivers[drvindex]->machine_config); | |
| 449 | 450 | const rom_entry *region, *rom; |
| 451 | const rom_source *source; | |
| 450 | 452 | |
| 451 | /* iterate over regions, and then ROMs within the region */ | |
| 452 | for (region = rom_first_region(drivers[drvindex]); region; region = rom_next_region(region)) | |
| 453 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 454 | { | |
| 455 | char hashbuf[HASH_BUF_SIZE]; | |
| 453 | /* iterate over sources, regions, and then ROMs within the region */ | |
| 454 | for (source = rom_first_source(drivers[drvindex], config); source != NULL; source = rom_next_source(drivers[drvindex], config, source)) | |
| 455 | for (region = rom_first_region(drivers[drvindex], source); region; region = rom_next_region(region)) | |
| 456 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 457 | { | |
| 458 | char hashbuf[HASH_BUF_SIZE]; | |
| 456 | 459 | |
| 457 | /* if we have a CRC, display it */ | |
| 458 | if (hash_data_extract_printable_checksum(ROM_GETHASHDATA(rom), HASH_CRC, hashbuf)) | |
| 459 | mame_printf_info("%s %-12s %s\n", hashbuf, ROM_GETNAME(rom), drivers[drvindex]->description); | |
| 460 | } | |
| 460 | /* if we have a CRC, display it */ | |
| 461 | if (hash_data_extract_printable_checksum(ROM_GETHASHDATA(rom), HASH_CRC, hashbuf)) | |
| 462 | mame_printf_info("%s %-12s %s\n", hashbuf, ROM_GETNAME(rom), drivers[drvindex]->description); | |
| 463 | } | |
| 461 | 464 | |
| 462 | 465 | count++; |
| 466 | machine_config_free(config); | |
| 463 | 467 | } |
| 464 | 468 | |
| 465 | 469 | /* return an error if none found */ |
| r3232 | r3233 | |
| 962 | 966 | /* iterate over drivers */ |
| 963 | 967 | for (drvindex = 0; drivers[drvindex]; drvindex++) |
| 964 | 968 | { |
| 969 | machine_config *config = machine_config_alloc(drivers[drvindex]->machine_config); | |
| 965 | 970 | const rom_entry *region, *rom; |
| 971 | const rom_source *source; | |
| 966 | 972 | |
| 967 | /* iterate over regions and files within the region */ | |
| 968 | for (region = rom_first_region(drivers[drvindex]); region; region = rom_next_region(region)) | |
| 969 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 970 | if (hash_data_is_equal(hash, ROM_GETHASHDATA(rom), 0)) | |
| 971 | { | |
| 972 | int baddump = hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP); | |
| 973 | /* iterate over sources, regions and files within the region */ | |
| 974 | for (source = rom_first_source(drivers[drvindex], config); source != NULL; source = rom_next_source(drivers[drvindex], config, source)) | |
| 975 | for (region = rom_first_region(drivers[drvindex], source); region; region = rom_next_region(region)) | |
| 976 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 977 | if (hash_data_is_equal(hash, ROM_GETHASHDATA(rom), 0)) | |
| 978 | { | |
| 979 | int baddump = hash_data_has_info(ROM_GETHASHDATA(rom), HASH_INFO_BAD_DUMP); | |
| 973 | 980 | |
| 974 | /* output information about the match */ | |
| 975 | if (*found != 0) | |
| 976 | mame_printf_info(" "); | |
| 977 | mame_printf_info("= %s%-20s %s\n", baddump ? "(BAD) " : "", ROM_GETNAME(rom), drivers[drvindex]->description); | |
| 978 | (*found)++; | |
| 979 | } | |
| 981 | /* output information about the match */ | |
| 982 | if (*found != 0) | |
| 983 | mame_printf_info(" "); | |
| 984 | mame_printf_info("= %s%-20s %s\n", baddump ? "(BAD) " : "", ROM_GETNAME(rom), drivers[drvindex]->description); | |
| 985 | (*found)++; | |
| 986 | } | |
| 987 | ||
| 988 | machine_config_free(config); | |
| 980 | 989 | } |
| 981 | 990 | } |
| r3232 | r3233 | |
|---|---|---|
| 655 | 655 | current tag |
| 656 | 656 | -------------------------------------------------*/ |
| 657 | 657 | |
| 658 | void state_save_save_continue( | |
| 658 | void state_save_save_continue(running_machine *machine) | |
| 659 | 659 | { |
| 660 | 660 | ss_entry *entry; |
| 661 | 661 | ss_func *func; |
| r3232 | r3233 | |
| 671 | 671 | if (func->tag == ss_current_tag) |
| 672 | 672 | { |
| 673 | 673 | count++; |
| 674 | (*func->func.presave)( | |
| 674 | (*func->func.presave)(machine, func->param); | |
| 675 | 675 | } |
| 676 | 676 | LOG((" %d functions called\n", count)); |
| 677 | 677 | |
| r3232 | r3233 | |
| 693 | 693 | file by writing the header and closing |
| 694 | 694 | -------------------------------------------------*/ |
| 695 | 695 | |
| 696 | void state_save_save_finish( | |
| 696 | void state_save_save_finish(running_machine *machine) | |
| 697 | 697 | { |
| 698 | 698 | UINT32 signature; |
| 699 | 699 | UINT8 flags = 0; |
| r3232 | r3233 | |
| 710 | 710 | ss_dump_array[8] = SAVE_VERSION; |
| 711 | 711 | ss_dump_array[9] = flags; |
| 712 | 712 | memset(ss_dump_array+0xa, 0, 10); |
| 713 | strcpy((char *)ss_dump_array+0xa, | |
| 713 | strcpy((char *)ss_dump_array+0xa, machine->gamedrv->name); | |
| 714 | 714 | |
| 715 | 715 | /* copy in the signature */ |
| 716 | 716 | signature = get_signature(); |
| r3232 | r3233 | |
| 768 | 768 | the current tag |
| 769 | 769 | -------------------------------------------------*/ |
| 770 | 770 | |
| 771 | void state_save_load_continue( | |
| 771 | void state_save_load_continue(running_machine *machine) | |
| 772 | 772 | { |
| 773 | 773 | ss_entry *entry; |
| 774 | 774 | ss_func *func; |
| r3232 | r3233 | |
| 801 | 801 | if (func->tag == ss_current_tag) |
| 802 | 802 | { |
| 803 | 803 | count++; |
| 804 | (*func->func.postload)( | |
| 804 | (*func->func.postload)(machine, func->param); | |
| 805 | 805 | } |
| 806 | 806 | LOG((" %d functions called\n", count)); |
| 807 | 807 | } |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | #include "driver.h" |
| 14 | 14 | #include "profiler.h" |
| 15 | 15 | #include "pool.h" |
| 16 | #include "deprecat.h" | |
| 17 | 16 | |
| 18 | 17 | |
| 19 | 18 | /*************************************************************************** |
| r3232 | r3233 | |
| 328 | 327 | time; this is also where we fire the timers |
| 329 | 328 | -------------------------------------------------*/ |
| 330 | 329 | |
| 331 | void timer_set_global_time(attotime newbase) | |
| 330 | void timer_set_global_time(running_machine *machine, attotime newbase) | |
| 332 | 331 | { |
| 333 | 332 | emu_timer *timer; |
| 334 | 333 | |
| r3232 | r3233 | |
| 357 | 356 | { |
| 358 | 357 | LOG(("Timer %s:%d[%s] fired (expire=%s)\n", timer->file, timer->line, timer->func, attotime_string(timer->expire, 9))); |
| 359 | 358 | profiler_mark(PROFILER_TIMER_CALLBACK); |
| 360 | (*timer->callback)( | |
| 359 | (*timer->callback)(machine, timer->ptr, timer->param); | |
| 361 | 360 | profiler_mark(PROFILER_END); |
| 362 | 361 | } |
| 363 | 362 | |
| r3232 | r3233 | |
| 1071 | 1070 | fatalerror("Unknown timer device type"); |
| 1072 | 1071 | break; |
| 1073 | 1072 | } |
| 1073 | ||
| 1074 | return DEVICE_START_OK; | |
| 1074 | 1075 | } |
| 1075 | 1076 | |
| 1076 | 1077 |
| r3232 | r3233 | |
|---|---|---|
| 18 | 18 | FUNCTION PROTOTYPES |
| 19 | 19 | ***************************************************************************/ |
| 20 | 20 | |
| 21 | static void machine_config_detokenize(machine_config *config, const machine_config_token *tokens); | |
| 21 | static void machine_config_detokenize(machine_config *config, const machine_config_token *tokens, const char *tagprefix, int depth); | |
| 22 | 22 | |
| 23 | 23 | |
| 24 | 24 | |
| 25 | 25 | /*************************************************************************** |
| 26 | INLINE FUNCTIONS | |
| 27 | ***************************************************************************/ | |
| 28 | ||
| 29 | /*------------------------------------------------- | |
| 30 | create_tag - create a combined tag, | |
| 31 | allocating strings as necessary | |
| 32 | -------------------------------------------------*/ | |
| 33 | ||
| 34 | INLINE const char *create_tag(astring *result, const char *prefix, const char *tag) | |
| 35 | { | |
| 36 | if (prefix != NULL && prefix[0] != 0) | |
| 37 | astring_printf(result, "%s:%s", prefix, tag); | |
| 38 | else | |
| 39 | astring_cpyc(result, tag); | |
| 40 | return astring_c(result); | |
| 41 | } | |
| 42 | ||
| 43 | ||
| 44 | ||
| 45 | /*************************************************************************** | |
| 26 | 46 | MACHINE CONFIGURATIONS |
| 27 | 47 | ***************************************************************************/ |
| 28 | 48 | |
| r3232 | r3233 | |
| 41 | 61 | memset(config, 0, sizeof(*config)); |
| 42 | 62 | |
| 43 | 63 | /* parse tokens into the config */ |
| 44 | machine_config_detokenize(config, tokens); | |
| 64 | machine_config_detokenize(config, tokens, "", 0); | |
| 45 | 65 | return config; |
| 46 | 66 | } |
| 47 | 67 | |
| r3232 | r3233 | |
| 53 | 73 | |
| 54 | 74 | void machine_config_free(machine_config *config) |
| 55 | 75 | { |
| 76 | int cpunum, soundnum; | |
| 77 | ||
| 56 | 78 | /* release the device list */ |
| 57 | 79 | while (config->devicelist != NULL) |
| 58 | 80 | device_list_remove(&config->devicelist, config->devicelist->type, config->devicelist->tag); |
| 59 | 81 | |
| 82 | /* release the strings */ | |
| 83 | for (cpunum = 0; cpunum < ARRAY_LENGTH(config->cputag); cpunum++) | |
| 84 | if (config->cputag[cpunum] != NULL) | |
| 85 | astring_free(config->cputag[cpunum]); | |
| 86 | for (soundnum = 0; soundnum < ARRAY_LENGTH(config->soundtag); soundnum++) | |
| 87 | if (config->soundtag[soundnum] != NULL) | |
| 88 | astring_free(config->soundtag[soundnum]); | |
| 89 | ||
| 60 | 90 | /* release the configuration itself */ |
| 61 | 91 | free(config); |
| 62 | 92 | } |
| 63 | 93 | |
| 64 | 94 | |
| 65 | ||
| 66 | ||
| 67 | 95 | /*------------------------------------------------- |
| 68 | machine_config_add_cpu - add a CPU during machine | |
| 69 | driver expansion | |
| 96 | cpu_add - add a CPU during machine driver | |
| 97 | expansion | |
| 70 | 98 | -------------------------------------------------*/ |
| 71 | 99 | |
| 72 | cpu_config * | |
| 100 | static cpu_config * | |
| 73 | 101 | { |
| 74 | 102 | int cpunum; |
| 75 | 103 | |
| 76 | 104 | for (cpunum = 0; cpunum < MAX_CPU; cpunum++) |
| 77 | 105 | if (machine->cpu[cpunum].type == CPU_DUMMY) |
| 78 | 106 | { |
| 79 | machine->cpu[cpunum].tag = tag; | |
| 107 | if (machine->cputag[cpunum] == NULL) | |
| 108 | machine->cputag[cpunum] = astring_alloc(); | |
| 109 | astring_cpyc(machine->cputag[cpunum], tag); | |
| 110 | machine->cpu[cpunum].tag = astring_c(machine->cputag[cpunum]); | |
| 80 | 111 | machine->cpu[cpunum].type = type; |
| 81 | 112 | machine->cpu[cpunum].clock = cpuclock; |
| 82 | 113 | return &machine->cpu[cpunum]; |
| r3232 | r3233 | |
| 88 | 119 | |
| 89 | 120 | |
| 90 | 121 | /*------------------------------------------------- |
| 91 | machine_config_find_cpu - find a tagged CPU during | |
| 92 | machine driver expansion | |
| 122 | cpu_find - find a tagged CPU during machine | |
| 123 | driver expansion | |
| 93 | 124 | -------------------------------------------------*/ |
| 94 | 125 | |
| 95 | cpu_config * | |
| 126 | static cpu_config * | |
| 96 | 127 | { |
| 97 | 128 | int cpunum; |
| 98 | 129 | |
| r3232 | r3233 | |
| 106 | 137 | |
| 107 | 138 | |
| 108 | 139 | /*------------------------------------------------- |
| 109 | machine_config_remove_cpu - remove a tagged CPU | |
| 110 | during machine driver expansion | |
| 140 | cpu_remove - remove a tagged CPU during | |
| 141 | machine driver expansion | |
| 111 | 142 | -------------------------------------------------*/ |
| 112 | 143 | |
| 113 | void | |
| 144 | static void | |
| 114 | 145 | { |
| 115 | 146 | int cpunum; |
| 116 | 147 | |
| 117 | 148 | for (cpunum = 0; cpunum < MAX_CPU; cpunum++) |
| 118 | 149 | if (machine->cpu[cpunum].tag && strcmp(machine->cpu[cpunum].tag, tag) == 0) |
| 119 | 150 | { |
| 151 | if (machine->cputag[cpunum] != NULL) | |
| 152 | astring_free(machine->cputag[cpunum]); | |
| 120 | 153 | memmove(&machine->cpu[cpunum], &machine->cpu[cpunum + 1], sizeof(machine->cpu[0]) * (MAX_CPU - cpunum - 1)); |
| 154 | memmove(&machine->cputag[cpunum], &machine->cputag[cpunum + 1], sizeof(machine->cputag[0]) * (MAX_CPU - cpunum - 1)); | |
| 121 | 155 | memset(&machine->cpu[MAX_CPU - 1], 0, sizeof(machine->cpu[0])); |
| 156 | memset(&machine->cputag[MAX_CPU - 1], 0, sizeof(machine->cputag[0])); | |
| 122 | 157 | return; |
| 123 | 158 | } |
| 124 | 159 | |
| r3232 | r3233 | |
| 127 | 162 | |
| 128 | 163 | |
| 129 | 164 | /*------------------------------------------------- |
| 130 | | |
| 165 | s | |
| 131 | 166 | machine driver expansion |
| 132 | 167 | -------------------------------------------------*/ |
| 133 | 168 | |
| 134 | sound_config * | |
| 169 | static sound_config *s | |
| 135 | 170 | { |
| 136 | 171 | int soundnum; |
| 137 | 172 | |
| 138 | 173 | for (soundnum = 0; soundnum < MAX_SOUND; soundnum++) |
| 139 | 174 | if (machine->sound[soundnum].type == SOUND_DUMMY) |
| 140 | 175 | { |
| 141 | machine->sound[soundnum].tag = tag; | |
| 176 | if (machine->soundtag[soundnum] == NULL) | |
| 177 | machine->soundtag[soundnum] = astring_alloc(); | |
| 178 | astring_cpyc(machine->soundtag[soundnum], tag); | |
| 179 | machine->sound[soundnum].tag = astring_c(machine->soundtag[soundnum]); | |
| 142 | 180 | machine->sound[soundnum].type = type; |
| 143 | 181 | machine->sound[soundnum].clock = clock; |
| 144 | 182 | machine->sound[soundnum].config = NULL; |
| r3232 | r3233 | |
| 152 | 190 | |
| 153 | 191 | |
| 154 | 192 | /*------------------------------------------------- |
| 155 | machine_config_find_sound - find a tagged sound | |
| 156 | system during machine driver expansion | |
| 193 | sound_find - find a tagged sound system during | |
| 194 | machine driver expansion | |
| 157 | 195 | -------------------------------------------------*/ |
| 158 | 196 | |
| 159 | sound_config * | |
| 197 | static sound_config *s | |
| 160 | 198 | { |
| 161 | 199 | int soundnum; |
| 162 | 200 | |
| r3232 | r3233 | |
| 170 | 208 | |
| 171 | 209 | |
| 172 | 210 | /*------------------------------------------------- |
| 173 | machine_config_remove_sound - remove a tagged sound | |
| 174 | system during machine driver expansion | |
| 211 | sound_remove - remove a tagged sound system | |
| 212 | during machine driver expansion | |
| 175 | 213 | -------------------------------------------------*/ |
| 176 | 214 | |
| 177 | void | |
| 215 | static void s | |
| 178 | 216 | { |
| 179 | 217 | int soundnum; |
| 180 | 218 | |
| 181 | 219 | for (soundnum = 0; soundnum < MAX_SOUND; soundnum++) |
| 182 | 220 | if (machine->sound[soundnum].tag && strcmp(machine->sound[soundnum].tag, tag) == 0) |
| 183 | 221 | { |
| 222 | if (machine->soundtag[soundnum] != NULL) | |
| 223 | astring_free(machine->soundtag[soundnum]); | |
| 184 | 224 | memmove(&machine->sound[soundnum], &machine->sound[soundnum + 1], sizeof(machine->sound[0]) * (MAX_SOUND - soundnum - 1)); |
| 225 | memmove(&machine->soundtag[soundnum], &machine->soundtag[soundnum + 1], sizeof(machine->soundtag[0]) * (MAX_SOUND - soundnum - 1)); | |
| 185 | 226 | memset(&machine->sound[MAX_SOUND - 1], 0, sizeof(machine->sound[0])); |
| 227 | memset(&machine->soundtag[MAX_SOUND - 1], 0, sizeof(machine->soundtag[0])); | |
| 186 | 228 | return; |
| 187 | 229 | } |
| 188 | 230 | |
| r3232 | r3233 | |
| 195 | 237 | machine config |
| 196 | 238 | -------------------------------------------------*/ |
| 197 | 239 | |
| 198 | static void machine_config_detokenize(machine_config *config, const machine_config_token *tokens) | |
| 240 | static void machine_config_detokenize(machine_config *config, const machine_config_token *tokens, const char *tagprefix, int depth) | |
| 199 | 241 | { |
| 200 | 242 | UINT32 entrytype = MCONFIG_TOKEN_INVALID; |
| 243 | astring *tempstring = astring_alloc(); | |
| 201 | 244 | device_config *device = NULL; |
| 245 | sound_config *sound = NULL; | |
| 202 | 246 | cpu_config *cpu = NULL; |
| 203 | sound_config *sound = NULL; | |
| 204 | 247 | |
| 205 | 248 | /* loop over tokens until we hit the end */ |
| 206 | 249 | while (entrytype != MCONFIG_TOKEN_END) |
| 207 | 250 | { |
| 251 | int size, offset, type, bits, in, out; | |
| 252 | UINT32 data32, clock, gain; | |
| 208 | 253 | device_type devtype; |
| 209 | 254 | const char *tag; |
| 210 | int size, offset, type, bits, in, out; | |
| 211 | UINT32 data32, clock, gain; | |
| 212 | 255 | UINT64 data64; |
| 213 | 256 | |
| 214 | 257 | /* unpack the token from the first entry */ |
| r3232 | r3233 | |
| 221 | 264 | |
| 222 | 265 | /* including */ |
| 223 | 266 | case MCONFIG_TOKEN_INCLUDE: |
| 224 | machine_config_detokenize(config, TOKEN_GET_PTR(tokens, tokenptr)); | |
| 267 | machine_config_detokenize(config, TOKEN_GET_PTR(tokens, tokenptr), tagprefix, depth + 1); | |
| 225 | 268 | break; |
| 226 | 269 | |
| 227 | 270 | /* device management */ |
| 228 | 271 | case MCONFIG_TOKEN_DEVICE_ADD: |
| 229 | 272 | devtype = TOKEN_GET_PTR(tokens, devtype); |
| 230 | 273 | tag = TOKEN_GET_STRING(tokens); |
| 231 | device = device_list_add(&config->devicelist, devtype, tag); | |
| 274 | device = device_list_add(&config->devicelist, devtype, create_tag(tempstring, tagprefix, tag)); | |
| 232 | 275 | break; |
| 233 | 276 | |
| 234 | 277 | case MCONFIG_TOKEN_DEVICE_REMOVE: |
| 235 | 278 | devtype = TOKEN_GET_PTR(tokens, devtype); |
| 236 | 279 | tag = TOKEN_GET_STRING(tokens); |
| 237 | device_list_remove(&config->devicelist, devtype, tag); | |
| 280 | device_list_remove(&config->devicelist, devtype, create_tag(tempstring, tagprefix, tag)); | |
| 238 | 281 | device = NULL; |
| 239 | 282 | break; |
| 240 | 283 | |
| 241 | 284 | case MCONFIG_TOKEN_DEVICE_MODIFY: |
| 242 | 285 | devtype = TOKEN_GET_PTR(tokens, devtype); |
| 243 | 286 | tag = TOKEN_GET_STRING(tokens); |
| 244 | device = (device_config *)device_list_find_by_tag(config->devicelist, devtype, tag); | |
| 287 | device = (device_config *)device_list_find_by_tag(config->devicelist, devtype, create_tag(tempstring, tagprefix, tag)); | |
| 245 | 288 | if (device == NULL) |
| 246 | fatalerror("Unable to find device: type=%s tag=%s\n", devtype_name(devtype), | |
| 289 | fatalerror("Unable to find device: type=%s tag=%s\n", devtype_name(devtype), | |
| 247 | 290 | break; |
| 248 | 291 | |
| 249 | 292 | case MCONFIG_TOKEN_DEVICE_CONFIG: |
| r3232 | r3233 | |
| 308 | 351 | TOKEN_UNGET_UINT32(tokens); |
| 309 | 352 | TOKEN_GET_UINT64_UNPACK3(tokens, entrytype, 8, type, 24, clock, 32); |
| 310 | 353 | tag = TOKEN_GET_STRING(tokens); |
| 311 | cpu = | |
| 354 | cpu = | |
| 312 | 355 | break; |
| 313 | 356 | |
| 314 | 357 | case MCONFIG_TOKEN_CPU_MODIFY: |
| 315 | 358 | tag = TOKEN_GET_STRING(tokens); |
| 316 | cpu = | |
| 359 | cpu = | |
| 317 | 360 | break; |
| 318 | 361 | |
| 319 | 362 | case MCONFIG_TOKEN_CPU_REMOVE: |
| 320 | 363 | tag = TOKEN_GET_STRING(tokens); |
| 321 | | |
| 364 | | |
| 322 | 365 | cpu = NULL; |
| 323 | 366 | break; |
| 324 | 367 | |
| r3232 | r3233 | |
| 326 | 369 | TOKEN_UNGET_UINT32(tokens); |
| 327 | 370 | TOKEN_GET_UINT64_UNPACK3(tokens, entrytype, 8, type, 24, clock, 32); |
| 328 | 371 | tag = TOKEN_GET_STRING(tokens); |
| 329 | cpu = | |
| 372 | cpu = | |
| 330 | 373 | if (cpu == NULL) |
| 331 | fatalerror("Unable to find CPU: tag=%s\n", | |
| 374 | fatalerror("Unable to find CPU: tag=%s\n", | |
| 332 | 375 | cpu->type = type; |
| 333 | 376 | cpu->clock = clock; |
| 334 | 377 | break; |
| r3232 | r3233 | |
| 479 | 522 | TOKEN_UNGET_UINT32(tokens); |
| 480 | 523 | TOKEN_GET_UINT64_UNPACK3(tokens, entrytype, 8, type, 24, clock, 32); |
| 481 | 524 | tag = TOKEN_GET_STRING(tokens); |
| 482 | sound = | |
| 525 | sound = sou | |
| 483 | 526 | break; |
| 484 | 527 | |
| 485 | 528 | case MCONFIG_TOKEN_SOUND_REMOVE: |
| 486 | | |
| 529 | s | |
| 487 | 530 | break; |
| 488 | 531 | |
| 489 | 532 | case MCONFIG_TOKEN_SOUND_MODIFY: |
| 490 | 533 | tag = TOKEN_GET_STRING(tokens); |
| 491 | sound = | |
| 534 | sound = s | |
| 492 | 535 | if (sound == NULL) |
| 493 | fatalerror("Unable to find sound: tag=%s\n", | |
| 536 | fatalerror("Unable to find sound: tag=%s\n", | |
| 494 | 537 | sound->routes = 0; |
| 495 | 538 | break; |
| 496 | 539 | |
| r3232 | r3233 | |
| 503 | 546 | TOKEN_UNGET_UINT32(tokens); |
| 504 | 547 | TOKEN_GET_UINT64_UNPACK3(tokens, entrytype, 8, type, 24, clock, 32); |
| 505 | 548 | tag = TOKEN_GET_STRING(tokens); |
| 506 | sound = | |
| 549 | sound = s | |
| 507 | 550 | if (sound == NULL) |
| 508 | fatalerror("Unable to find sound: tag=%s\n", | |
| 551 | fatalerror("Unable to find sound: tag=%s\n", | |
| 509 | 552 | sound->type = type; |
| 510 | 553 | sound->clock = clock; |
| 511 | 554 | sound->config = NULL; |
| r3232 | r3233 | |
| 528 | 571 | break; |
| 529 | 572 | } |
| 530 | 573 | } |
| 574 | ||
| 575 | /* if we are the outermost level, process any device-specific machine configurations */ | |
| 576 | if (depth == 0) | |
| 577 | for (device = config->devicelist; device != NULL; device = device->next) | |
| 578 | { | |
| 579 | tokens = device_get_info_ptr(device, DEVINFO_PTR_MACHINE_CONFIG); | |
| 580 | if (tokens != NULL) | |
| 581 | machine_config_detokenize(config, tokens, create_tag(tempstring, tagprefix, device->tag), depth + 1); | |
| 582 | } | |
| 583 | ||
| 584 | astring_free(tempstring); | |
| 531 | 585 | } |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | |
| 14 | 14 | <mamecheat version="1"> |
| 15 | 15 | <cheat desc="blah"> |
| 16 | <parameter min="minval(0)" max="maxval(numitems)" step="stepval(1)" | |
| 16 | <parameter min="minval(0)" max="maxval(numitems)" step="stepval(1)" | |
| 17 | 17 | <item value="itemval(previtemval|minval+stepval)">text</item> |
| 18 | 18 | ... |
| 19 | 19 | </parameter> |
| r3232 | r3233 | |
| 110 | 110 | int maxformat; /* format of maximum value */ |
| 111 | 111 | UINT64 stepval; /* step value */ |
| 112 | 112 | int stepformat; /* format of step value */ |
| 113 | UINT64 defval; /* default value */ | |
| 114 | int defformat; /* format of default value */ | |
| 115 | 113 | UINT64 value; /* live value of the parameter */ |
| 116 | 114 | char valuestring[32]; /* small space for a value string */ |
| 117 | 115 | parameter_item * itemlist; /* list of items */ |
| r3232 | r3233 | |
| 394 | 392 | /* if we have a value parameter, compute it */ |
| 395 | 393 | else if (cheat->parameter->itemlist == NULL) |
| 396 | 394 | { |
| 397 | if (state | |
| 395 | if (cheat->state | |
| 398 | 396 | { |
| 399 | sprintf(cheat->parameter->valuestring, "%d", (UINT32)cheat->parameter->value); | |
| 400 | *state = cheat->parameter->valuestring; | |
| 397 | if (state != NULL) | |
| 398 | *state = "Off"; | |
| 399 | if (flags != NULL) | |
| 400 | *flags = MENU_FLAG_RIGHT_ARROW; | |
| 401 | 401 | } |
| 402 | | |
| 402 | e | |
| 403 | 403 | { |
| 404 | *flags = 0; | |
| 405 | if (cheat->parameter->value > cheat->parameter->minval) | |
| 406 | *flags |= MENU_FLAG_LEFT_ARROW; | |
| 407 | if (cheat->parameter->value < cheat->parameter->maxval) | |
| 408 | *flags |= MENU_FLAG_RIGHT_ARROW; | |
| 404 | if (state != NULL) | |
| 405 | { | |
| 406 | sprintf(cheat->parameter->valuestring, "%d", (UINT32)cheat->parameter->value); | |
| 407 | *state = cheat->parameter->valuestring; | |
| 408 | } | |
| 409 | if (flags != NULL) | |
| 410 | { | |
| 411 | *flags = MENU_FLAG_LEFT_ARROW; | |
| 412 | if (cheat->parameter->value < cheat->parameter->maxval) | |
| 413 | *flags |= MENU_FLAG_RIGHT_ARROW; | |
| 414 | } | |
| 409 | 415 | } |
| 410 | 416 | } |
| 411 | 417 | |
| 412 | 418 | /* if we have an item list, pick the index */ |
| 413 | 419 | else |
| 414 | 420 | { |
| 415 | parameter_item *item, *prev = NULL; | |
| 416 | ||
| 417 | for (item = cheat->parameter->itemlist; item != NULL; prev = item, item = item->next) | |
| 418 | if (item->value == cheat->parameter->value) | |
| 419 | break; | |
| 420 | if (state != NULL) | |
| 421 | *state = (item != NULL) ? astring_c(item->text) : "??Invalid??"; | |
| 422 | if (flags != NULL) | |
| 421 | if (cheat->state == SCRIPT_STATE_OFF) | |
| 423 | 422 | { |
| 424 | *flags = 0; | |
| 425 | if (item == NULL || prev != NULL) | |
| 426 | *flags |= MENU_FLAG_LEFT_ARROW; | |
| 427 | if (item == NULL || item->next != NULL) | |
| 428 | *flags |= MENU_FLAG_RIGHT_ARROW; | |
| 423 | if (state != NULL) | |
| 424 | *state = "Off"; | |
| 425 | if (flags != NULL) | |
| 426 | *flags = MENU_FLAG_RIGHT_ARROW; | |
| 429 | 427 | } |
| 428 | else | |
| 429 | { | |
| 430 | parameter_item *item = NULL, *prev = NULL; | |
| 431 | ||
| 432 | for (item = cheat->parameter->itemlist; item != NULL; prev = item, item = item->next) | |
| 433 | if (item->value == cheat->parameter->value) | |
| 434 | break; | |
| 435 | if (state != NULL) | |
| 436 | *state = (item != NULL) ? astring_c(item->text) : "??Invalid??"; | |
| 437 | if (flags != NULL) | |
| 438 | { | |
| 439 | *flags = MENU_FLAG_LEFT_ARROW; | |
| 440 | if (item == NULL || item->next != NULL) | |
| 441 | *flags |= MENU_FLAG_RIGHT_ARROW; | |
| 442 | } | |
| 443 | } | |
| 430 | 444 | } |
| 431 | 445 | |
| 432 | 446 | /* return a pointer to this item */ |
| r3232 | r3233 | |
| 473 | 487 | ; |
| 474 | 488 | |
| 475 | 489 | /* if we have no parameter, it's just on/off; default to off */ |
| 476 | else | |
| 490 | else | |
| 477 | 491 | { |
| 478 | 492 | if (cheat->state != SCRIPT_STATE_OFF) |
| 479 | 493 | { |
| r3232 | r3233 | |
| 482 | 496 | changed = TRUE; |
| 483 | 497 | } |
| 484 | 498 | } |
| 485 | ||
| 486 | /* if we have a value parameter, fall back to the default */ | |
| 487 | else | |
| 488 | { | |
| 489 | if (cheat->parameter->value != cheat->parameter->defval) | |
| 490 | { | |
| 491 | cheat->parameter->value = cheat->parameter->defval; | |
| 492 | changed = TRUE; | |
| 493 | } | |
| 494 | } | |
| 495 | 499 | return changed; |
| 496 | 500 | } |
| 497 | 501 | |
| r3232 | r3233 | |
| 534 | 538 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_CHANGE); |
| 535 | 539 | changed = TRUE; |
| 536 | 540 | } |
| 541 | else if (cheat->state != SCRIPT_STATE_OFF) | |
| 542 | { | |
| 543 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_OFF); | |
| 544 | cheat->state = SCRIPT_STATE_OFF; | |
| 545 | changed = TRUE; | |
| 546 | } | |
| 537 | 547 | } |
| 538 | 548 | |
| 539 | 549 | /* if we have an item list, pick the index */ |
| r3232 | r3233 | |
| 546 | 556 | break; |
| 547 | 557 | if (prev != NULL) |
| 548 | 558 | { |
| 559 | if (cheat->state == SCRIPT_STATE_OFF) | |
| 560 | { | |
| 561 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_ON); | |
| 562 | cheat->state = SCRIPT_STATE_RUN; | |
| 563 | } | |
| 549 | 564 | cheat->parameter->value = prev->value; |
| 550 | 565 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_CHANGE); |
| 551 | 566 | changed = TRUE; |
| 552 | 567 | } |
| 568 | else if (cheat->state != SCRIPT_STATE_OFF) | |
| 569 | { | |
| 570 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_OFF); | |
| 571 | cheat->state = SCRIPT_STATE_OFF; | |
| 572 | changed = TRUE; | |
| 573 | } | |
| 553 | 574 | } |
| 554 | 575 | return changed; |
| 555 | 576 | } |
| r3232 | r3233 | |
| 584 | 605 | /* if we have a value parameter, compute it */ |
| 585 | 606 | else if (cheat->parameter->itemlist == NULL) |
| 586 | 607 | { |
| 587 | if (cheat-> | |
| 608 | if (cheat->sta | |
| 588 | 609 | { |
| 610 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_ON); | |
| 611 | cheat->state = SCRIPT_STATE_RUN; | |
| 612 | cheat->parameter->value = cheat->parameter->minval; | |
| 613 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_CHANGE); | |
| 614 | changed = TRUE; | |
| 615 | } | |
| 616 | else if (cheat->parameter->value < cheat->parameter->maxval) | |
| 617 | { | |
| 589 | 618 | if (cheat->parameter->value > cheat->parameter->maxval - cheat->parameter->stepval) |
| 590 | 619 | cheat->parameter->value = cheat->parameter->maxval; |
| 591 | 620 | else |
| r3232 | r3233 | |
| 600 | 629 | { |
| 601 | 630 | parameter_item *item; |
| 602 | 631 | |
| 603 | for (item = cheat->parameter->itemlist; item != NULL; item = item->next) | |
| 604 | if (item->value == cheat->parameter->value) | |
| 605 | break; | |
| 606 | if (item->next != NULL) | |
| 632 | if (cheat->state == SCRIPT_STATE_OFF) | |
| 607 | 633 | { |
| 608 | cheat->parameter->value = item->next->value; | |
| 634 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_ON); | |
| 635 | cheat->state = SCRIPT_STATE_RUN; | |
| 636 | cheat->parameter->value = cheat->parameter->itemlist->value; | |
| 609 | 637 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_CHANGE); |
| 610 | 638 | changed = TRUE; |
| 611 | 639 | } |
| 640 | else | |
| 641 | { | |
| 642 | for (item = cheat->parameter->itemlist; item != NULL; item = item->next) | |
| 643 | if (item->value == cheat->parameter->value) | |
| 644 | break; | |
| 645 | if (item->next != NULL) | |
| 646 | { | |
| 647 | cheat->parameter->value = item->next->value; | |
| 648 | cheat_execute_script(cheatinfo, cheat, SCRIPT_STATE_CHANGE); | |
| 649 | changed = TRUE; | |
| 650 | } | |
| 651 | } | |
| 612 | 652 | } |
| 613 | 653 | return changed; |
| 614 | 654 | } |
| r3232 | r3233 | |
| 973 | 1013 | } |
| 974 | 1014 | |
| 975 | 1015 | /* set the initial state */ |
| 976 | cheat->state = | |
| 1016 | cheat->state = | |
| 977 | 1017 | return cheat; |
| 978 | 1018 | |
| 979 | 1019 | error: |
| r3232 | r3233 | |
| 1078 | 1118 | param->maxformat = xml_get_attribute_int_format(paramnode, "max"); |
| 1079 | 1119 | param->stepval = xml_get_attribute_int(paramnode, "step", 1); |
| 1080 | 1120 | param->stepformat = xml_get_attribute_int_format(paramnode, "step"); |
| 1081 | param->defval = xml_get_attribute_int(paramnode, "default", param->minval); | |
| 1082 | param->defformat = xml_get_attribute_int_format(paramnode, "default"); | |
| 1083 | 1121 | |
| 1084 | 1122 | /* iterate over items */ |
| 1085 | 1123 | itemtailptr = ¶m->itemlist; |
| r3232 | r3233 | |
| 1116 | 1154 | itemtailptr = &curitem->next; |
| 1117 | 1155 | } |
| 1118 | 1156 | |
| 1119 | /* if no default, pick the minimum */ | |
| 1120 | if (xml_get_attribute_string(paramnode, "default", NULL) == NULL) | |
| 1121 | param->defval = (param->itemlist != NULL) ? param->itemlist->value : param->minval; | |
| 1122 | param->value = param->defval; | |
| 1157 | /* start at the minimum */ | |
| 1158 | param->value = param->minval; | |
| 1123 | 1159 | |
| 1124 | 1160 | return param; |
| 1125 | 1161 | |
| r3232 | r3233 | |
| 1150 | 1186 | mame_fprintf(cheatfile, " max=\"%s\"", format_int(string, param->maxval, param->maxformat)); |
| 1151 | 1187 | if (param->stepval != 1) |
| 1152 | 1188 | mame_fprintf(cheatfile, " step=\"%s\"", format_int(string, param->stepval, param->stepformat)); |
| 1153 | mame_fprintf(cheatfile, " default=\"%s\"", format_int(string, param->defval, param->defformat)); | |
| 1154 | 1189 | mame_fprintf(cheatfile, "/>\n"); |
| 1155 | 1190 | } |
| 1156 | 1191 | |
| r3232 | r3233 | |
| 1159 | 1194 | { |
| 1160 | 1195 | const parameter_item *curitem; |
| 1161 | 1196 | |
| 1162 | mame_fprintf(cheatfile, " default=\"%s\">\n", format_int(string, param->defval, param->defformat)); | |
| 1163 | 1197 | for (curitem = param->itemlist; curitem != NULL; curitem = curitem->next) |
| 1164 | 1198 | mame_fprintf(cheatfile, "\t\t\t<item value=\"%s\">%s</item>\n", format_int(string, curitem->value, curitem->valformat), astring_c(curitem->text)); |
| 1165 | 1199 | mame_fprintf(cheatfile, "\t\t</parameter>\n"); |
| r3232 | r3233 | |
|---|---|---|
| 410 | 410 | /* attempts to map a point on the specified render_target to the specified container, if possible */ |
| 411 | 411 | int render_target_map_point_container(render_target *target, INT32 target_x, INT32 target_y, render_container *container, float *container_x, float *container_y); |
| 412 | 412 | |
| 413 | /* attempts to map a point on the specified render_target to the specified container, if possible */ | |
| 414 | int render_target_map_point_input(render_target *target, INT32 target_x, INT32 target_y, const char **input_tag, UINT32 *input_mask, float *input_x, float *input_y); | |
| 413 | 415 | |
| 414 | 416 | |
| 417 | ||
| 415 | 418 | /* ----- render texture management ----- */ |
| 416 | 419 | |
| 417 | 420 | /* allocate a new texture */ |
| r3232 | r3233 | |
|---|---|---|
| 112 | 112 | void state_save_push_tag(int tag); |
| 113 | 113 | void state_save_pop_tag(void); |
| 114 | 114 | |
| 115 | void state_save_save_continue(void); | |
| 116 | void state_save_load_continue(void); | |
| 115 | void state_save_save_continue(running_machine *machine); | |
| 116 | void state_save_load_continue(running_machine *machine); | |
| 117 | 117 | |
| 118 | void state_save_save_finish( | |
| 118 | void state_save_save_finish(running_machine *machine); | |
| 119 | 119 | void state_save_load_finish(void); |
| 120 | 120 | |
| 121 | 121 | /* Helper function for creating a unique name */ |
| r3232 | r3233 | |
|---|---|---|
| 170 | 170 | attotime timer_next_fire_time(void); |
| 171 | 171 | |
| 172 | 172 | /* adjust the global time; this is also where we fire the timers */ |
| 173 | void timer_set_global_time(attotime newbase); | |
| 173 | void timer_set_global_time(running_machine *machine, attotime newbase); | |
| 174 | 174 | |
| 175 | 175 | |
| 176 | 176 |
| r3232 | r3233 | |
|---|---|---|
| 55 | 55 | typedef struct _region_entry region_entry; |
| 56 | 56 | struct _region_entry |
| 57 | 57 | { |
| 58 | | |
| 58 | a | |
| 59 | 59 | UINT32 length; |
| 60 | 60 | }; |
| 61 | 61 | |
| r3232 | r3233 | |
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | |
| 154 | /*------------------------------------------------- | |
| 155 | validate_tag - ensure that the given tag | |
| 156 | meets the general requirements | |
| 157 | -------------------------------------------------*/ | |
| 154 | 158 | |
| 159 | INLINE int validate_tag(const game_driver *driver, const char *object, const char *tag) | |
| 160 | { | |
| 161 | const char *validchars = "abcdefghijklmnopqrstuvwxyz0123456789_.:"; | |
| 162 | const char *begin = strrchr(tag, ':'); | |
| 163 | const char *p; | |
| 164 | int error = FALSE; | |
| 165 | ||
| 166 | for (p = tag; *p != 0; p++) | |
| 167 | { | |
| 168 | if (*p != tolower(*p)) | |
| 169 | { | |
| 170 | mame_printf_error("%s: %s has %s with tag '%s' containing upper-case characters\n", driver->source_file, driver->name, object, tag); | |
| 171 | error = TRUE; | |
| 172 | break; | |
| 173 | } | |
| 174 | if (*p == ' ') | |
| 175 | { | |
| 176 | mame_printf_error("%s: %s has %s with tag '%s' containing spaces\n", driver->source_file, driver->name, object, tag); | |
| 177 | error = TRUE; | |
| 178 | break; | |
| 179 | } | |
| 180 | if (strchr(validchars, *p) == NULL) | |
| 181 | { | |
| 182 | mame_printf_error("%s: %s has %s with tag '%s' containing invalid character '%c'\n", driver->source_file, driver->name, object, tag, *p); | |
| 183 | error = TRUE; | |
| 184 | break; | |
| 185 | } | |
| 186 | } | |
| 187 | ||
| 188 | if (begin == NULL) | |
| 189 | begin = tag; | |
| 190 | else | |
| 191 | begin += 1; | |
| 192 | ||
| 193 | if (strlen(begin) == 0) | |
| 194 | { | |
| 195 | mame_printf_error("%s: %s has %s with 0-length tag\n", driver->source_file, driver->name, object); | |
| 196 | error = TRUE; | |
| 197 | } | |
| 198 | if (strlen(begin) > MAX_TAG_LENGTH) | |
| 199 | { | |
| 200 | mame_printf_error("%s: %s has %s with tag '%s' > %d characters\n", driver->source_file, driver->name, object, tag, MAX_TAG_LENGTH); | |
| 201 | error = TRUE; | |
| 202 | } | |
| 203 | ||
| 204 | return error; | |
| 205 | } | |
| 206 | ||
| 207 | ||
| 208 | ||
| 155 | 209 | /*************************************************************************** |
| 156 | 210 | QUARK TABLES |
| 157 | 211 | ***************************************************************************/ |
| r3232 | r3233 | |
| 504 | 558 | static int validate_roms(int drivnum, const machine_config *config, region_info *rgninfo) |
| 505 | 559 | { |
| 506 | 560 | const game_driver *driver = drivers[drivnum]; |
| 507 | | |
| 561 | i | |
| 508 | 562 | const char *last_name = "???"; |
| 563 | region_entry *currgn = NULL; | |
| 564 | int items_since_region = 1; | |
| 565 | const rom_source *source; | |
| 509 | 566 | int error = FALSE; |
| 510 | int items_since_region = 1; | |
| 511 | int bios_flags = 0, last_bios = 0; | |
| 512 | region_entry *currgn = NULL; | |
| 513 | 567 | |
| 514 | /* reset region info */ | |
| 515 | memset(rgninfo, 0, sizeof(*rgninfo)); | |
| 568 | /* iterate, starting with the driver's ROMs and continuing with device ROMs */ | |
| 569 | for (source = rom_first_source(driver, config); source != NULL; source = rom_next_source(driver, config, source)) | |
| 570 | { | |
| 571 | const rom_entry *romp; | |
| 516 | 572 | |
| 517 | /* scan the ROM entries */ | |
| 518 | for (romp = driver->rom; romp && !ROMENTRY_ISEND(romp); romp++) | |
| 519 | { | |
| 520 | /* if this is a region, make sure it's valid, and record the length */ | |
| 521 | if (ROMENTRY_ISREGION(romp)) | |
| 573 | /* scan the ROM entries */ | |
| 574 | for (romp = rom_first_region(driver, source); !ROMENTRY_ISEND(romp); romp++) | |
| 522 | 575 | { |
| 523 | const char *region = ROMREGION_GETTAG(romp); | |
| 576 | /* if this is a region, make sure it's valid, and record the length */ | |
| 577 | if (ROMENTRY_ISREGION(romp)) | |
| 578 | { | |
| 579 | const char *regiontag = ROMREGION_GETTAG(romp); | |
| 524 | 580 | |
| 525 | /* if we haven't seen any items since the last region, print a warning */ | |
| 526 | if (items_since_region == 0) | |
| 527 | mame_printf_warning("%s: %s has empty ROM region (warning)\n", driver->source_file, driver->name); | |
| 528 | items_since_region = (ROMREGION_ISERASE(romp) || ROMREGION_ISDISPOSE(romp) || ROMREGION_ISDISKDATA(romp)) ? 1 : 0; | |
| 529 | currgn = NULL; | |
| 581 | /* if we haven't seen any items since the last region, print a warning */ | |
| 582 | if (items_since_region == 0) | |
| 583 | mame_printf_warning("%s: %s has empty ROM region (warning)\n", driver->source_file, driver->name); | |
| 584 | items_since_region = (ROMREGION_ISERASE(romp) || ROMREGION_ISDISPOSE(romp) || ROMREGION_ISDISKDATA(romp)) ? 1 : 0; | |
| 585 | currgn = NULL; | |
| 530 | 586 | |
| 531 | /* check for an invalid tag */ | |
| 532 | if (region == NULL || region[0] == 0) | |
| 533 | { | |
| 534 | mame_printf_error("%s: %s has duplicate ROM_REGION tag \"%s\"\n", driver->source_file, driver->name, region); | |
| 535 | error = TRUE; | |
| 536 | } | |
| 587 | /* check for a valid tag */ | |
| 588 | if (regiontag == NULL) | |
| 589 | { | |
| 590 | mame_printf_error("%s: %s has NULL ROM_REGION tag\n", driver->source_file, driver->name); | |
| 591 | error = TRUE; | |
| 592 | } | |
| 537 | 593 | |
| 538 | /* find any empty entry, checking for duplicates */ | |
| 539 | else | |
| 540 | { | |
| 541 | int rgnnum; | |
| 594 | /* load by name entries must be 8 characters or less */ | |
| 595 | else if (ROMREGION_ISLOADBYNAME(romp) && strlen(regiontag) > 8) | |
| 596 | { | |
| 597 | mame_printf_error("%s: %s has load-by-name region \"%s\" with name >8 characters\n", driver->source_file, driver->name, regiontag); | |
| 598 | error = TRUE; | |
| 599 | } | |
| 542 | 600 | |
| 543 | /* iterate over all regions found so far */ | |
| 544 | for (rgnnum = 0; rgnnum < ARRAY_LENGTH(rgninfo->entries); rgnnum++) | |
| 601 | /* find any empty entry, checking for duplicates */ | |
| 602 | else | |
| 545 | 603 | { |
| 546 | /* stop when we hit an empty */ | |
| 547 | if (rgninfo->entries[rgnnum].tag == NULL) | |
| 604 | astring *fulltag = rom_region_name(astring_alloc(), driver, source, romp); | |
| 605 | int rgnnum; | |
| 606 | ||
| 607 | /* iterate over all regions found so far */ | |
| 608 | for (rgnnum = 0; rgnnum < ARRAY_LENGTH(rgninfo->entries); rgnnum++) | |
| 548 | 609 | { |
| 549 | currgn = &rgninfo->entries[rgnnum]; | |
| 550 | currgn->tag = region; | |
| 551 | currgn->length = ROMREGION_GETLENGTH(romp); | |
| 552 | break; | |
| 553 | } | |
| 610 | /* stop when we hit an empty */ | |
| 611 | if (rgninfo->entries[rgnnum].tag == NULL) | |
| 612 | { | |
| 613 | currgn = &rgninfo->entries[rgnnum]; | |
| 614 | currgn->tag = fulltag; | |
| 615 | currgn->length = ROMREGION_GETLENGTH(romp); | |
| 616 | break; | |
| 617 | } | |
| 554 | 618 | |
| 555 | /* fail if we hit a duplicate */ | |
| 556 | if (strcmp(rgninfo->entries[rgnnum].tag, region) == 0) | |
| 557 | { | |
| 558 | mame_printf_error("%s: %s has duplicate ROM_REGION type \"%s\"\n", driver->source_file, driver->name, region); | |
| 559 | error = TRUE; | |
| 560 | break; | |
| 619 | /* fail if we hit a duplicate */ | |
| 620 | if (astring_cmp(fulltag, rgninfo->entries[rgnnum].tag) == 0) | |
| 621 | { | |
| 622 | mame_printf_error("%s: %s has duplicate ROM_REGION tag \"%s\"\n", driver->source_file, driver->name, astring_c(fulltag)); | |
| 623 | error = TRUE; | |
| 624 | astring_free(fulltag); | |
| 625 | break; | |
| 626 | } | |
| 561 | 627 | } |
| 562 | 628 | } |
| 629 | ||
| 630 | /* validate the region tag */ | |
| 631 | error |= validate_tag(driver, "region", regiontag); | |
| 563 | 632 | } |
| 564 | } | |
| 565 | 633 | |
| 566 | /* If this is a system bios, make sure it is using the next available bios number */ | |
| 567 | else if (ROMENTRY_ISSYSTEM_BIOS(romp)) | |
| 568 | { | |
| 569 | bios_flags = ROM_GETBIOSFLAGS(romp); | |
| 570 | if (last_bios+1 != bios_flags) | |
| 634 | /* If this is a system bios, make sure it is using the next available bios number */ | |
| 635 | else if (ROMENTRY_ISSYSTEM_BIOS(romp)) | |
| 571 | 636 | { |
| 572 | const char *name = ROM_GETNAME(romp); | |
| 573 | mame_printf_error("%s: %s has non-sequential bios %s\n", driver->source_file, driver->name, name); | |
| 574 | error = TRUE; | |
| 637 | bios_flags = ROM_GETBIOSFLAGS(romp); | |
| 638 | if (last_bios+1 != bios_flags) | |
| 639 | { | |
| 640 | const char *name = ROM_GETNAME(romp); | |
| 641 | mame_printf_error("%s: %s has non-sequential bios %s\n", driver->source_file, driver->name, name); | |
| 642 | error = TRUE; | |
| 643 | } | |
| 644 | last_bios = bios_flags; | |
| 575 | 645 | } |
| 576 | last_bios = bios_flags; | |
| 577 | } | |
| 578 | 646 | |
| 579 | /* if this is a file, make sure it is properly formatted */ | |
| 580 | else if (ROMENTRY_ISFILE(romp)) | |
| 581 | { | |
| 582 | const char *hash; | |
| 583 | const char *s; | |
| 647 | /* if this is a file, make sure it is properly formatted */ | |
| 648 | else if (ROMENTRY_ISFILE(romp)) | |
| 649 | { | |
| 650 | const char *hash; | |
| 651 | const char *s; | |
| 584 | 652 | |
| 585 | items_since_region++; | |
| 653 | items_since_region++; | |
| 586 | 654 | |
| 587 | /* track the last filename we found */ | |
| 588 | last_name = ROM_GETNAME(romp); | |
| 655 | /* track the last filename we found */ | |
| 656 | last_name = ROM_GETNAME(romp); | |
| 589 | 657 | |
| 590 | /* make sure it's all lowercase */ | |
| 591 | for (s = last_name; *s; s++) | |
| 592 | if (tolower(*s) != *s) | |
| 658 | /* make sure it's all lowercase */ | |
| 659 | for (s = last_name; *s; s++) | |
| 660 | if (tolower(*s) != *s) | |
| 661 | { | |
| 662 | mame_printf_error("%s: %s has upper case ROM name %s\n", driver->source_file, driver->name, last_name); | |
| 663 | error = TRUE; | |
| 664 | break; | |
| 665 | } | |
| 666 | ||
| 667 | /* if this is a bios rom, make sure it has the same flags as the last system bios entry */ | |
| 668 | /* bios_flags = ROM_GETBIOSFLAGS(romp); | |
| 669 | if (bios_flags != 0) | |
| 670 | { | |
| 671 | if (bios_flags != last_bios) | |
| 672 | { | |
| 673 | mame_printf_error("%s: %s has bios rom name %s without preceding matching system bios definition\n", driver->source_file, driver->name, last_name); | |
| 674 | error = TRUE; | |
| 675 | } | |
| 676 | }*/ | |
| 677 | ||
| 678 | /* make sure the has is valid */ | |
| 679 | hash = ROM_GETHASHDATA(romp); | |
| 680 | if (!hash_verify_string(hash)) | |
| 593 | 681 | { |
| 594 | mame_printf_error("%s: %s has | |
| 682 | mame_printf_error("%s: rom '%s' has an | |
| 595 | 683 | error = TRUE; |
| 596 | break; | |
| 597 | 684 | } |
| 685 | } | |
| 598 | 686 | |
| 599 | /* if this is a bios rom, make sure it has the same flags as the last system bios entry */ | |
| 600 | bios_flags = ROM_GETBIOSFLAGS(romp); | |
| 601 | if (bios_flags != 0) | |
| 687 | /* for any non-region ending entries, make sure they don't extend past the end */ | |
| 688 | if (!ROMENTRY_ISREGIONEND(romp) && currgn != NULL) | |
| 602 | 689 | { |
| 603 | if (bios_flags != last_bios) | |
| 690 | items_since_region++; | |
| 691 | ||
| 692 | if (ROM_GETOFFSET(romp) + ROM_GETLENGTH(romp) > currgn->length) | |
| 604 | 693 | { |
| 605 | mame_printf_error("%s: %s has | |
| 694 | mame_printf_error("%s: %s has ROM | |
| 606 | 695 | error = TRUE; |
| 607 | 696 | } |
| 608 | 697 | } |
| 609 | ||
| 610 | /* make sure the has is valid */ | |
| 611 | hash = ROM_GETHASHDATA(romp); | |
| 612 | if (!hash_verify_string(hash)) | |
| 613 | { | |
| 614 | mame_printf_error("%s: rom '%s' has an invalid hash string '%s'\n", driver->name, last_name, hash); | |
| 615 | error = TRUE; | |
| 616 | } | |
| 617 | 698 | } |
| 618 | 699 | |
| 619 | /* for any non-region ending entries, make sure they don't extend past the end */ | |
| 620 | if (!ROMENTRY_ISREGIONEND(romp) && currgn != NULL) | |
| 621 | { | |
| 622 | items_since_region++; | |
| 623 | ||
| 624 | if (ROM_GETOFFSET(romp) + ROM_GETLENGTH(romp) > currgn->length) | |
| 625 | { | |
| 626 | mame_printf_error("%s: %s has ROM %s extending past the defined memory region\n", driver->source_file, driver->name, last_name); | |
| 627 | error = TRUE; | |
| 628 | } | |
| 629 | } | |
| 700 | /* final check for empty regions */ | |
| 701 | if (items_since_region == 0) | |
| 702 | mame_printf_warning("%s: %s has empty ROM region (warning)\n", driver->source_file, driver->name); | |
| 630 | 703 | } |
| 631 | 704 | |
| 632 | /* final check for empty regions */ | |
| 633 | if (items_since_region == 0) | |
| 634 | mame_printf_warning("%s: %s has empty ROM region (warning)\n", driver->source_file, driver->name); | |
| 635 | ||
| 636 | 705 | return error; |
| 637 | 706 | } |
| 638 | 707 | |
| r3232 | r3233 | |
| 660 | 729 | continue; |
| 661 | 730 | |
| 662 | 731 | /* check for valid tag */ |
| 663 | if (cpu->tag == NULL | |
| 732 | if (cpu->tag == NULL | |
| 664 | 733 | { |
| 665 | mame_printf_error("%s: %s has NULL | |
| 734 | mame_printf_error("%s: %s has NULL | |
| 666 | 735 | error = TRUE; |
| 667 | 736 | } |
| 668 | 737 | |
| r3232 | r3233 | |
| 677 | 746 | } |
| 678 | 747 | } |
| 679 | 748 | |
| 749 | /* validate the CPU tag */ | |
| 750 | error |= validate_tag(driver, "CPU", cpu->tag); | |
| 751 | ||
| 680 | 752 | /* checks to see if this driver is using a dummy CPU */ |
| 681 | 753 | if (cputype_get_interface(cpu->type)->get_info == dummy_get_info) |
| 682 | 754 | { |
| r3232 | r3233 | |
| 788 | 860 | } |
| 789 | 861 | |
| 790 | 862 | /* if we hit a match, check against the length */ |
| 791 | if (strcmp(rgninfo->entries[rgnnum].tag, entry->region) == 0) | |
| 863 | if (astring_cmpc(rgninfo->entries[rgnnum].tag, entry->region) == 0) | |
| 792 | 864 | { |
| 793 | 865 | offs_t length = rgninfo->entries[rgnnum].length; |
| 794 | 866 | if (entry->rgnoffs + (byteend - bytestart + 1) > length) |
| r3232 | r3233 | |
| 987 | 1059 | } |
| 988 | 1060 | |
| 989 | 1061 | /* if we hit a match, check against the length */ |
| 990 | if (strcmp(rgninfo->entries[rgnnum].tag, region) == 0) | |
| 1062 | if (astring_cmpc(rgninfo->entries[rgnnum].tag, region) == 0) | |
| 991 | 1063 | { |
| 992 | 1064 | /* if we have a valid region, and we're not using auto-sizing, check the decode against the region length */ |
| 993 | 1065 | if (!IS_FRAC(total)) |
| r3232 | r3233 | |
| 1475 | 1547 | error = TRUE; |
| 1476 | 1548 | } |
| 1477 | 1549 | |
| 1550 | /* validate the sound tag */ | |
| 1551 | error |= validate_tag(driver, "sound", config->sound[sndnum].tag); | |
| 1552 | ||
| 1478 | 1553 | /* loop over all the routes */ |
| 1479 | 1554 | for (routenum = 0; routenum < config->sound[sndnum].routes; routenum++) |
| 1480 | 1555 | { |
| r3232 | r3233 | |
| 1520 | 1595 | for (device = device_list_first(config->devicelist, DEVICE_TYPE_WILDCARD); device != NULL; device = device_list_next(device, DEVICE_TYPE_WILDCARD)) |
| 1521 | 1596 | { |
| 1522 | 1597 | device_validity_check_func validity_check = (device_validity_check_func) device_get_info_fct(device, DEVINFO_FCT_VALIDITY_CHECK); |
| 1523 | if (validity_check != NULL) | |
| 1524 | { | |
| 1525 | if ((*validity_check)(driver, device)) | |
| 1526 | error = TRUE; | |
| 1527 | } | |
| 1598 | ||
| 1599 | /* validate the device tag */ | |
| 1600 | error |= validate_tag(driver, device_get_info_string(device, DEVINFO_STR_NAME), device->tag); | |
| 1601 | ||
| 1602 | /* call the device-specific validity check */ | |
| 1603 | if (validity_check != NULL && (*validity_check)(driver, device)) | |
| 1604 | error = TRUE; | |
| 1528 | 1605 | } |
| 1529 | 1606 | return error; |
| 1530 | 1607 | } |
| r3232 | r3233 | |
| 1604 | 1681 | const input_port_config *portlist = NULL; |
| 1605 | 1682 | machine_config *config; |
| 1606 | 1683 | region_info rgninfo; |
| 1684 | int rgnnum; | |
| 1607 | 1685 | |
| 1608 | /* ASG -- trying this for a while to see if submission failures increase */ | |
| 1609 | #if 1 | |
| 1610 | 1686 | /* non-debug builds only care about games in the same driver */ |
| 1611 | 1687 | if (curdriver != NULL && strcmp(curdriver->source_file, driver->source_file) != 0) |
| 1612 | 1688 | continue; |
| 1613 | ||
| 1689 | memset(&rgn | |
| 1614 | 1690 | |
| 1615 | 1691 | /* expand the machine driver */ |
| 1616 | 1692 | expansion -= osd_profiling_ticks(); |
| r3232 | r3233 | |
| 1657 | 1733 | error = validate_devices(drivnum, config) || error; |
| 1658 | 1734 | device_checks += osd_profiling_ticks(); |
| 1659 | 1735 | |
| 1736 | for (rgnnum = 0; rgnnum < ARRAY_LENGTH(rgninfo.entries); rgnnum++) | |
| 1737 | if (rgninfo.entries[rgnnum].tag != NULL) | |
| 1738 | astring_free(rgninfo.entries[rgnnum].tag); | |
| 1660 | 1739 | if (portlist != NULL) |
| 1661 | 1740 | input_port_config_free(portlist); |
| 1662 | 1741 | machine_config_free(config); |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | CONSTANTS |
| 23 | 23 | ***************************************************************************/ |
| 24 | 24 | |
| 25 | /* by convention, tags should all lowercase and this length or less */ | |
| 26 | #define MAX_TAG_LENGTH 15 | |
| 27 | ||
| 28 | ||
| 25 | 29 | /* token types */ |
| 26 | 30 | enum |
| 27 | 31 | { |
| r3232 | r3233 | |
| 120 | 124 | UINT32 driver_data_size; /* amount of memory needed for driver_data */ |
| 121 | 125 | |
| 122 | 126 | cpu_config cpu[MAX_CPU]; /* array of CPUs in the system */ |
| 127 | astring * cputag[MAX_CPU]; /* allocated strings for each CPU tag */ | |
| 123 | 128 | UINT32 cpu_slices_per_frame; /* number of times to interleave execution per frame */ |
| 124 | 129 | INT32 watchdog_vblank_count; /* number of VBLANKs until the watchdog kills us */ |
| 125 | 130 | attotime watchdog_time; /* length of time until the watchdog kills us */ |
| r3232 | r3233 | |
| 142 | 147 | video_update_func video_update; /* video update callback */ |
| 143 | 148 | |
| 144 | 149 | sound_config sound[MAX_SOUND]; /* array of sound chips in the system */ |
| 150 | astring * soundtag[MAX_SOUND]; /* allocated strings for each sound tag */ | |
| 145 | 151 | |
| 146 | 152 | sound_start_func sound_start; /* one-time sound start callback */ |
| 147 | 153 | sound_reset_func sound_reset; /* sound reset callback */ |
| r3232 | r3233 | |
| 462 | 468 | void machine_config_free(machine_config *config); |
| 463 | 469 | |
| 464 | 470 | |
| 465 | ||
| 466 | ||
| 467 | ||
| 468 | cpu_config *machine_config_add_cpu(machine_config *machine, const char *tag, cpu_type type, int cpuclock); | |
| 469 | cpu_config *machine_config_find_cpu(machine_config *machine, const char *tag); | |
| 470 | void machine_config_remove_cpu(machine_config *machine, const char *tag); | |
| 471 | ||
| 472 | sound_config *machine_config_add_sound(machine_config *machine, const char *tag, sound_type type, int clock); | |
| 473 | sound_config *machine_config_find_sound(machine_config *machine, const char *tag); | |
| 474 | void machine_config_remove_sound(machine_config *machine, const char *tag); | |
| 475 | ||
| 476 | ||
| 477 | 471 | #endif /* __MCONFIG_H__ */ |
| r3232 | r3233 | |
|---|---|---|
| 22 | 22 | static MACHINE_START( empty ) |
| 23 | 23 | { |
| 24 | 24 | /* force the UI to show the game select screen */ |
| 25 | ui_menu_force_game_select(); | |
| 25 | ui_menu_force_game_select(machine); | |
| 26 | 26 | } |
| 27 | 27 | |
| 28 | 28 |
| r3232 | r3233 | |
|---|---|---|
| 16 | 16 | #include "harddisk.h" |
| 17 | 17 | #include "config.h" |
| 18 | 18 | #include "ui.h" |
| 19 | #include "deprecat.h" | |
| 20 | 19 | |
| 21 | 20 | |
| 22 | 21 | #define LOG_LOAD 0 |
| r3232 | r3233 | |
| 100 | 99 | ***************************************************************************/ |
| 101 | 100 | |
| 102 | 101 | /*------------------------------------------------- |
| 102 | rom_source_is_gamedrv - return TRUE if the | |
| 103 | given rom_source refers to the game driver | |
| 104 | itself | |
| 105 | -------------------------------------------------*/ | |
| 106 | ||
| 107 | int rom_source_is_gamedrv(const game_driver *drv, const rom_source *source) | |
| 108 | { | |
| 109 | return ((const game_driver *)source == drv); | |
| 110 | } | |
| 111 | ||
| 112 | ||
| 113 | /*------------------------------------------------- | |
| 114 | rom_first_source - return pointer to first ROM | |
| 115 | source | |
| 116 | -------------------------------------------------*/ | |
| 117 | ||
| 118 | const rom_source *rom_first_source(const game_driver *drv, const machine_config *config) | |
| 119 | { | |
| 120 | const device_config *device; | |
| 121 | ||
| 122 | /* if the driver has a ROM pointer, that's what we want */ | |
| 123 | if (drv->rom != NULL) | |
| 124 | return (rom_source *)drv; | |
| 125 | ||
| 126 | /* otherwise, look through devices */ | |
| 127 | if (config != NULL) | |
| 128 | for (device = config->devicelist; device != NULL; device = device->next) | |
| 129 | { | |
| 130 | const rom_entry *devromp = device_get_info_ptr(device, DEVINFO_PTR_ROM_REGION); | |
| 131 | if (devromp != NULL) | |
| 132 | return (rom_source *)device; | |
| 133 | } | |
| 134 | return NULL; | |
| 135 | } | |
| 136 | ||
| 137 | ||
| 138 | /*------------------------------------------------- | |
| 139 | rom_next_source - return pointer to next ROM | |
| 140 | source | |
| 141 | -------------------------------------------------*/ | |
| 142 | ||
| 143 | const rom_source *rom_next_source(const game_driver *drv, const machine_config *config, const rom_source *previous) | |
| 144 | { | |
| 145 | const device_config *device; | |
| 146 | ||
| 147 | /* if the previous was the driver, we want the first device */ | |
| 148 | if (rom_source_is_gamedrv(drv, previous)) | |
| 149 | device = (config != NULL) ? config->devicelist : NULL; | |
| 150 | else | |
| 151 | device = ((const device_config *)previous)->next; | |
| 152 | ||
| 153 | /* look for further devices with ROM definitions */ | |
| 154 | for ( ; device != NULL; device = device->next) | |
| 155 | { | |
| 156 | const rom_entry *devromp = device_get_info_ptr(device, DEVINFO_PTR_ROM_REGION); | |
| 157 | if (devromp != NULL) | |
| 158 | return (rom_source *)device; | |
| 159 | } | |
| 160 | return NULL; | |
| 161 | } | |
| 162 | ||
| 163 | ||
| 164 | /*------------------------------------------------- | |
| 103 | 165 | rom_first_region - return pointer to first ROM |
| 104 | 166 | region |
| 105 | 167 | -------------------------------------------------*/ |
| 106 | 168 | |
| 107 | const rom_entry *rom_first_region(const game_driver *drv) | |
| 169 | const rom_entry *rom_first_region(const game_driver *drv, const rom_source *source) | |
| 108 | 170 | { |
| 109 | return (drv->rom != NULL && !ROMENTRY_ISEND(drv->rom)) ? drv->rom : NULL; | |
| 171 | const rom_entry *romp; | |
| 172 | ||
| 173 | if (source == NULL || rom_source_is_gamedrv(drv, source)) | |
| 174 | romp = drv->rom; | |
| 175 | else | |
| 176 | romp = device_get_info_ptr((const device_config *)source, DEVINFO_PTR_ROM_REGION); | |
| 177 | ||
| 178 | return (romp != NULL && !ROMENTRY_ISEND(romp)) ? romp : NULL; | |
| 110 | 179 | } |
| 111 | 180 | |
| 112 | 181 | |
| r3232 | r3233 | |
| 176 | 245 | |
| 177 | 246 | |
| 178 | 247 | /*------------------------------------------------- |
| 248 | rom_region_name - return the appropriate name | |
| 249 | for a rom region | |
| 250 | -------------------------------------------------*/ | |
| 251 | ||
| 252 | astring *rom_region_name(astring *result, const game_driver *drv, const rom_source *source, const rom_entry *romp) | |
| 253 | { | |
| 254 | if (rom_source_is_gamedrv(drv, source)) | |
| 255 | astring_cpyc(result, ROMREGION_GETTAG(romp)); | |
| 256 | else | |
| 257 | { | |
| 258 | const device_config *device = (const device_config *)source; | |
| 259 | astring_printf(result, "%s:%s", device->tag, ROMREGION_GETTAG(romp)); | |
| 260 | } | |
| 261 | return result; | |
| 262 | } | |
| 263 | ||
| 264 | ||
| 265 | /*------------------------------------------------- | |
| 179 | 266 | debugload - log data to a file |
| 180 | 267 | -------------------------------------------------*/ |
| 181 | 268 | |
| r3232 | r3233 | |
| 247 | 334 | that will need to be loaded |
| 248 | 335 | -------------------------------------------------*/ |
| 249 | 336 | |
| 250 | static int count_roms( | |
| 337 | static int count_roms( | |
| 251 | 338 | { |
| 252 | 339 | const rom_entry *region, *rom; |
| 340 | const rom_source *source; | |
| 253 | 341 | int count = 0; |
| 254 | 342 | |
| 255 | 343 | /* loop over regions, then over files */ |
| 256 | for (region = romp; region; region = rom_next_region(region)) | |
| 257 | for (rom = rom_first_file(region); rom; rom = rom_next_file(rom)) | |
| 258 | { | |
| 259 | int bios_flags = ROM_GETBIOSFLAGS(rom); | |
| 260 | if (!bios_flags || (bios_flags == system_bios)) /* alternate bios sets */ | |
| 261 | count++; | |
| 262 | } | |
| 344 | for (source = rom_first_source(machine->gamedrv, machine->config); source != NULL; source = rom_next_source(machine->gamedrv, machine->config, source)) | |
| 345 | for (region = rom_first_region(machine->gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 346 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 347 | { | |
| 348 | int bios_flags = ROM_GETBIOSFLAGS(rom); | |
| 349 | if (!bios_flags || (bios_flags == system_bios)) /* alternate bios sets */ | |
| 350 | count++; | |
| 351 | } | |
| 263 | 352 | |
| 264 | 353 | /* return the total count */ |
| 265 | 354 | return count; |
| r3232 | r3233 | |
| 271 | 360 | random data |
| 272 | 361 | -------------------------------------------------*/ |
| 273 | 362 | |
| 274 | static void fill_random(UINT8 *base, UINT32 length) | |
| 363 | static void fill_random(running_machine *machine, UINT8 *base, UINT32 length) | |
| 275 | 364 | { |
| 276 | 365 | while (length--) |
| 277 | *base++ = mame_rand( | |
| 366 | *base++ = mame_rand(machine); | |
| 278 | 367 | } |
| 279 | 368 | |
| 280 | 369 | |
| r3232 | r3233 | |
| 412 | 501 | messages about ROM loading to the user |
| 413 | 502 | -------------------------------------------------*/ |
| 414 | 503 | |
| 415 | static void display_loading_rom_message(const char *name, rom_load_data *romdata) | |
| 504 | static void display_loading_rom_message(running_machine *machine, const char *name, rom_load_data *romdata) | |
| 416 | 505 | { |
| 417 | 506 | char buffer[200]; |
| 418 | 507 | |
| r3232 | r3233 | |
| 421 | 510 | else |
| 422 | 511 | sprintf(buffer, "Loading Complete"); |
| 423 | 512 | |
| 424 | ui_set_startup_text( | |
| 513 | ui_set_startup_text(machine, buffer, FALSE); | |
| 425 | 514 | } |
| 426 | 515 | |
| 427 | 516 | |
| r3232 | r3233 | |
| 430 | 519 | results of ROM loading |
| 431 | 520 | -------------------------------------------------*/ |
| 432 | 521 | |
| 433 | static void display_rom_load_results(rom_load_data *romdata) | |
| 522 | static void display_rom_load_results(running_machine *machine, rom_load_data *romdata) | |
| 434 | 523 | { |
| 435 | 524 | /* final status display */ |
| 436 | display_loading_rom_message(NULL, romdata); | |
| 525 | display_loading_rom_message(machine, NULL, romdata); | |
| 437 | 526 | |
| 438 | 527 | /* if we had errors, they are fatal */ |
| 439 | 528 | if (romdata->errors != 0) |
| r3232 | r3233 | |
| 441 | 530 | const char *rgntag, *nextrgntag; |
| 442 | 531 | |
| 443 | 532 | /* clean up any regions */ |
| 444 | for (rgntag = memory_region_next( | |
| 533 | for (rgntag = memory_region_next(machine, NULL); rgntag != NULL; rgntag = nextrgntag) | |
| 445 | 534 | { |
| 446 | nextrgntag = memory_region_next(Machine, rgntag); | |
| 447 | memory_region_free(Machine, rgntag); | |
| 535 | nextrgntag = memory_region_next(machine, rgntag); | |
| 536 | memory_region_free(machine, rgntag); | |
| 448 | 537 | } |
| 449 | 538 | |
| 450 | 539 | /* create the error message and exit fatally */ |
| 451 | 540 | strcat(romdata->errorbuf, "ERROR: required files are missing, the "GAMENOUN" cannot be run."); |
| 452 | fatalerror_exitcode(MAMERR_MISSING_FILES, "%s", romdata->errorbuf); | |
| 541 | fatalerror_exitcode(machine, MAMERR_MISSING_FILES, "%s", romdata->errorbuf); | |
| 453 | 542 | } |
| 454 | 543 | |
| 455 | 544 | /* if we had warnings, output them, but continue */ |
| r3232 | r3233 | |
| 510 | 599 | up the parent and loading by checksum |
| 511 | 600 | -------------------------------------------------*/ |
| 512 | 601 | |
| 513 | static int open_rom_file(rom_load_data *romdata, const rom_entry *romp) | |
| 602 | static int open_rom_file(running_machine *machine, rom_load_data *romdata, const char *regiontag, const rom_entry *romp) | |
| 514 | 603 | { |
| 515 | 604 | file_error filerr = FILERR_NOT_FOUND; |
| 516 | 605 | const game_driver *drv; |
| 606 | int has_crc = FALSE; | |
| 607 | UINT8 crcbytes[4]; | |
| 608 | UINT32 crc = 0; | |
| 517 | 609 | |
| 610 | /* update status display */ | |
| 518 | 611 | ++romdata->romsloaded; |
| 612 | display_loading_rom_message(machine, ROM_GETNAME(romp), romdata); | |
| 519 | 613 | |
| 520 | /* update status display */ | |
| 521 | display_loading_rom_message(ROM_GETNAME(romp), romdata); | |
| 614 | /* extract CRC to use for searching */ | |
| 615 | has_crc = hash_data_extract_binary_checksum(ROM_GETHASHDATA(romp), HASH_CRC, crcbytes); | |
| 616 | if (has_crc) | |
| 617 | crc = (crcbytes[0] << 24) | (crcbytes[1] << 16) | (crcbytes[2] << 8) | crcbytes[3]; | |
| 522 | 618 | |
| 523 | /* | |
| 619 | /* attempt reading up the chain through the parents. It automatically also | |
| 524 | 620 | attempts any kind of load by checksum supported by the archives. */ |
| 525 | 621 | romdata->file = NULL; |
| 526 | for (drv = Machine->gamedrv; !romdata->file && drv; drv = driver_get_clone(drv)) | |
| 527 | if (drv->name && *drv->name) | |
| 622 | for (drv = machine->gamedrv; romdata->file == NULL && drv != NULL; drv = driver_get_clone(drv)) | |
| 623 | if (drv->name != NULL && *drv->name != 0) | |
| 528 | 624 | { |
| 529 | UINT8 crcs[4]; | |
| 530 | astring *fname; | |
| 531 | ||
| 532 | fname = astring_assemble_3(astring_alloc(), drv->name, PATH_SEPARATOR, ROM_GETNAME(romp)); | |
| 533 | if (hash_data_extract_binary_checksum(ROM_GETHASHDATA(romp), HASH_CRC, crcs)) | |
| 534 | { | |
| 535 | UINT32 crc = (crcs[0] << 24) | (crcs[1] << 16) | (crcs[2] << 8) | crcs[3]; | |
| 625 | astring *fname = astring_assemble_3(astring_alloc(), drv->name, PATH_SEPARATOR, ROM_GETNAME(romp)); | |
| 626 | if (has_crc) | |
| 536 | 627 | filerr = mame_fopen_crc(SEARCHPATH_ROM, astring_c(fname), crc, OPEN_FLAG_READ, &romdata->file); |
| 537 | } | |
| 538 | 628 | else |
| 539 | 629 | filerr = mame_fopen(SEARCHPATH_ROM, astring_c(fname), OPEN_FLAG_READ, &romdata->file); |
| 540 | 630 | astring_free(fname); |
| 541 | 631 | } |
| 542 | 632 | |
| 633 | /* if the region is load by name, load the ROM from there */ | |
| 634 | if (regiontag != NULL) | |
| 635 | { | |
| 636 | astring *fname = astring_assemble_3(astring_alloc(), regiontag, PATH_SEPARATOR, ROM_GETNAME(romp)); | |
| 637 | if (has_crc) | |
| 638 | filerr = mame_fopen_crc(SEARCHPATH_ROM, astring_c(fname), crc, OPEN_FLAG_READ, &romdata->file); | |
| 639 | else | |
| 640 | filerr = mame_fopen(SEARCHPATH_ROM, astring_c(fname), OPEN_FLAG_READ, &romdata->file); | |
| 641 | astring_free(fname); | |
| 642 | } | |
| 643 | ||
| 543 | 644 | /* return the result */ |
| 544 | 645 | return (filerr == FILERR_NONE); |
| 545 | 646 | } |
| r3232 | r3233 | |
| 550 | 651 | random data for a NULL file |
| 551 | 652 | -------------------------------------------------*/ |
| 552 | 653 | |
| 553 | static int rom_fread(rom_load_data *romdata, UINT8 *buffer, int length) | |
| 654 | static int rom_fread(running_machine *machine, rom_load_data *romdata, UINT8 *buffer, int length) | |
| 554 | 655 | { |
| 555 | 656 | /* files just pass through */ |
| 556 | 657 | if (romdata->file) |
| r3232 | r3233 | |
| 558 | 659 | |
| 559 | 660 | /* otherwise, fill with randomness */ |
| 560 | 661 | else |
| 561 | fill_random(buffer, length); | |
| 662 | fill_random(machine, buffer, length); | |
| 562 | 663 | |
| 563 | 664 | return length; |
| 564 | 665 | } |
| r3232 | r3233 | |
| 569 | 670 | entry |
| 570 | 671 | -------------------------------------------------*/ |
| 571 | 672 | |
| 572 | static int read_rom_data(rom_load_data *romdata, const rom_entry *romp) | |
| 673 | static int read_rom_data(running_machine *machine, rom_load_data *romdata, const rom_entry *romp) | |
| 573 | 674 | { |
| 574 | 675 | int datashift = ROM_GETBITSHIFT(romp); |
| 575 | 676 | int datamask = ((1 << ROM_GETBITWIDTH(romp)) - 1) << datashift; |
| r3232 | r3233 | |
| 597 | 698 | |
| 598 | 699 | /* special case for simple loads */ |
| 599 | 700 | if (datamask == 0xff && (groupsize == 1 || !reversed) && skip == 0) |
| 600 | return rom_fread(romdata, base, numbytes); | |
| 701 | return rom_fread(machine, romdata, base, numbytes); | |
| 601 | 702 | |
| 602 | 703 | /* chunky reads for complex loads */ |
| 603 | 704 | skip += groupsize; |
| r3232 | r3233 | |
| 609 | 710 | |
| 610 | 711 | /* read as much as we can */ |
| 611 | 712 | LOG((" Reading %X bytes into buffer\n", bytesleft)); |
| 612 | if (rom_fread(romdata, romdata->tempbuf, bytesleft) != bytesleft) | |
| 713 | if (rom_fread(machine, romdata, romdata->tempbuf, bytesleft) != bytesleft) | |
| 613 | 714 | return 0; |
| 614 | 715 | numbytes -= bytesleft; |
| 615 | 716 | |
| r3232 | r3233 | |
| 700 | 801 | copy_rom_data - copy a region of ROM space |
| 701 | 802 | -------------------------------------------------*/ |
| 702 | 803 | |
| 703 | static void copy_rom_data(rom_load_data *romdata, const rom_entry *romp) | |
| 804 | static void copy_rom_data(running_machine *machine, rom_load_data *romdata, const rom_entry *romp) | |
| 704 | 805 | { |
| 705 | 806 | UINT8 *base = romdata->regionbase + ROM_GETOFFSET(romp); |
| 706 | 807 | const char *srcrgntag = ROM_GETNAME(romp); |
| r3232 | r3233 | |
| 717 | 818 | fatalerror("Error in RomModule definition: COPY has an invalid length\n"); |
| 718 | 819 | |
| 719 | 820 | /* make sure the source was valid */ |
| 720 | srcbase = memory_region( | |
| 821 | srcbase = memory_region(machine, srcrgntag); | |
| 721 | 822 | if (srcbase == NULL) |
| 722 | 823 | fatalerror("Error in RomModule definition: COPY from an invalid region\n"); |
| 723 | 824 | |
| 724 | 825 | /* make sure we find within the region space */ |
| 725 | if (srcoffs + numbytes > memory_region_length( | |
| 826 | if (srcoffs + numbytes > memory_region_length(machine, srcrgntag)) | |
| 726 | 827 | fatalerror("Error in RomModule definition: COPY out of source memory region space\n"); |
| 727 | 828 | |
| 728 | 829 | /* fill the data */ |
| r3232 | r3233 | |
| 735 | 836 | for a region |
| 736 | 837 | -------------------------------------------------*/ |
| 737 | 838 | |
| 738 | static void process_rom_entries(rom_load_data *romdata, const rom_entry *romp) | |
| 839 | static void process_rom_entries(running_machine *machine, rom_load_data *romdata, const char *regiontag, const rom_entry *romp) | |
| 739 | 840 | { |
| 740 | 841 | UINT32 lastflags = 0; |
| 741 | 842 | |
| r3232 | r3233 | |
| 760 | 861 | |
| 761 | 862 | /* handle copies */ |
| 762 | 863 | else if (ROMENTRY_ISCOPY(romp)) |
| 763 | copy_rom_data(romdata, romp++); | |
| 864 | copy_rom_data(machine, romdata, romp++); | |
| 764 | 865 | |
| 765 | 866 | /* handle files */ |
| 766 | 867 | else if (ROMENTRY_ISFILE(romp)) |
| r3232 | r3233 | |
| 773 | 874 | |
| 774 | 875 | /* open the file */ |
| 775 | 876 | LOG(("Opening ROM file: %s\n", ROM_GETNAME(romp))); |
| 776 | if (!open_rom_file(romdata, romp)) | |
| 877 | if (!open_rom_file(machine, romdata, regiontag, romp)) | |
| 777 | 878 | handle_missing_file(romdata, romp); |
| 778 | 879 | |
| 779 | 880 | /* loop until we run out of reloads */ |
| r3232 | r3233 | |
| 795 | 896 | |
| 796 | 897 | /* attempt to read using the modified entry */ |
| 797 | 898 | if (!ROMENTRY_ISIGNORE(&modified_romp)) |
| 798 | readresult = read_rom_data(romdata, &modified_romp); | |
| 899 | readresult = read_rom_data(machine, romdata, &modified_romp); | |
| 799 | 900 | } |
| 800 | 901 | while (ROMENTRY_ISCONTINUE(romp) || ROMENTRY_ISIGNORE(romp)); |
| 801 | 902 | |
| r3232 | r3233 | |
| 856 | 957 | { |
| 857 | 958 | const game_driver *drv, *searchdrv; |
| 858 | 959 | const rom_entry *region, *rom; |
| 960 | const rom_source *source; | |
| 859 | 961 | file_error filerr; |
| 860 | 962 | chd_error err; |
| 861 | 963 | |
| r3232 | r3233 | |
| 889 | 991 | /* otherwise, look at our parents for a CHD with an identical checksum */ |
| 890 | 992 | /* and try to open that */ |
| 891 | 993 | for (drv = gamedrv; drv != NULL; drv = driver_get_clone(drv)) |
| 892 | for (region = rom_first_region(drv); region != NULL; region = rom_next_region(region)) | |
| 893 | if (ROMREGION_ISDISKDATA(region)) | |
| 894 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 994 | for (source = rom_first_source(drv, NULL); source != NULL; source = rom_next_source(drv, NULL, source)) | |
| 995 | for (region = rom_first_region(drv, source); region != NULL; region = rom_next_region(region)) | |
| 996 | if (ROMREGION_ISDISKDATA(region)) | |
| 997 | for (rom = rom_first_file(region); rom != NULL; rom = rom_next_file(rom)) | |
| 895 | 998 | |
| 896 | /* look for a differing name but with the same hash data */ | |
| 897 | if (strcmp(ROM_GETNAME(romp), ROM_GETNAME(rom)) != 0 && | |
| 898 | hash_data_is_equal(ROM_GETHASHDATA(romp), ROM_GETHASHDATA(rom), 0)) | |
| 899 | { | |
| 900 | /* attempt to open the properly named file, scanning up through parent directories */ | |
| 901 | filerr = FILERR_NOT_FOUND; | |
| 902 | for (searchdrv = drv; searchdrv != NULL && filerr != FILERR_NONE; searchdrv = driver_get_clone(searchdrv)) | |
| 999 | /* look for a differing name but with the same hash data */ | |
| 1000 | if (strcmp(ROM_GETNAME(romp), ROM_GETNAME(rom)) != 0 && | |
| 1001 | hash_data_is_equal(ROM_GETHASHDATA(romp), ROM_GETHASHDATA(rom), 0)) | |
| 903 | 1002 | { |
| 904 | astring *fname = astring_assemble_4(astring_alloc(), searchdrv->name, PATH_SEPARATOR, ROM_GETNAME(rom), ".chd"); | |
| 905 | filerr = mame_fopen_options(options, SEARCHPATH_IMAGE, astring_c(fname), OPEN_FLAG_READ, image_file); | |
| 906 | astring_free(fname); | |
| 907 | } | |
| 1003 | /* attempt to open the properly named file, scanning up through parent directories */ | |
| 1004 | filerr = FILERR_NOT_FOUND; | |
| 1005 | for (searchdrv = drv; searchdrv != NULL && filerr != FILERR_NONE; searchdrv = driver_get_clone(searchdrv)) | |
| 1006 | { | |
| 1007 | astring *fname = astring_assemble_4(astring_alloc(), searchdrv->name, PATH_SEPARATOR, ROM_GETNAME(rom), ".chd"); | |
| 1008 | filerr = mame_fopen_options(options, SEARCHPATH_IMAGE, astring_c(fname), OPEN_FLAG_READ, image_file); | |
| 1009 | astring_free(fname); | |
| 1010 | } | |
| 908 | 1011 | |
| 909 | /* did the file open succeed? */ | |
| 910 | if (filerr == FILERR_NONE) | |
| 911 | { | |
| 912 | /* try to open the CHD */ | |
| 913 | err = chd_open_file(mame_core_file(*image_file), CHD_OPEN_READ, NULL, image_chd); | |
| 914 | if (err == CHDERR_NONE) | |
| 915 | return err; | |
| 1012 | /* did the file open succeed? */ | |
| 1013 | if (filerr == FILERR_NONE) | |
| 1014 | { | |
| 1015 | /* try to open the CHD */ | |
| 1016 | err = chd_open_file(mame_core_file(*image_file), CHD_OPEN_READ, NULL, image_chd); | |
| 1017 | if (err == CHDERR_NONE) | |
| 1018 | return err; | |
| 916 | 1019 | |
| 917 | /* close the file on failure */ | |
| 918 | mame_fclose(*image_file); | |
| 919 | *image_file = NULL; | |
| 1020 | /* close the file on failure */ | |
| 1021 | mame_fclose(*image_file); | |
| 1022 | *image_file = NULL; | |
| 1023 | } | |
| 920 | 1024 | } |
| 921 | } | |
| 922 | 1025 | |
| 923 | 1026 | return err; |
| 924 | 1027 | } |
| r3232 | r3233 | |
| 978 | 1081 | for a region |
| 979 | 1082 | -------------------------------------------------*/ |
| 980 | 1083 | |
| 981 | static void process_disk_entries(rom_load_data *romdata, const char *regiontag, const rom_entry *romp) | |
| 1084 | static void process_disk_entries(running_machine *machine, rom_load_data *romdata, const char *regiontag, const rom_entry *romp) | |
| 982 | 1085 | { |
| 983 | 1086 | astring *filename = astring_alloc(); |
| 984 | 1087 | |
| r3232 | r3233 | |
| 1001 | 1104 | |
| 1002 | 1105 | /* first open the source drive */ |
| 1003 | 1106 | LOG(("Opening disk image: %s\n", astring_c(filename))); |
| 1004 | err = open_disk_image( | |
| 1107 | err = open_disk_image(machine->gamedrv, romp, &chd.origfile, &chd.origchd); | |
| 1005 | 1108 | if (err != CHDERR_NONE) |
| 1006 | 1109 | { |
| 1007 | 1110 | if (err == CHDERR_FILE_NOT_FOUND) |
| r3232 | r3233 | |
| 1040 | 1143 | if (!DISK_ISREADONLY(romp)) |
| 1041 | 1144 | { |
| 1042 | 1145 | /* try to open or create the diff */ |
| 1043 | err = open_disk_diff( | |
| 1146 | err = open_disk_diff(machine->gamedrv, romp, chd.origchd, &chd.difffile, &chd.diffchd); | |
| 1044 | 1147 | if (err != CHDERR_NONE) |
| 1045 | 1148 | { |
| 1046 | 1149 | sprintf(&romdata->errorbuf[strlen(romdata->errorbuf)], "%s DIFF CHD ERROR: %s\n", astring_c(filename), chd_error_string(err)); |
| r3232 | r3233 | |
| 1097 | 1200 | |
| 1098 | 1201 | |
| 1099 | 1202 | /*------------------------------------------------- |
| 1203 | process_region_list - process a region list | |
| 1204 | -------------------------------------------------*/ | |
| 1205 | ||
| 1206 | static void process_region_list(running_machine *machine, rom_load_data *romdata) | |
| 1207 | { | |
| 1208 | astring *regiontag = astring_alloc(); | |
| 1209 | const rom_source *source; | |
| 1210 | const rom_entry *region; | |
| 1211 | ||
| 1212 | /* loop until we hit the end */ | |
| 1213 | for (source = rom_first_source(machine->gamedrv, machine->config); source != NULL; source = rom_next_source(machine->gamedrv, machine->config, source)) | |
| 1214 | for (region = rom_first_region(machine->gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 1215 | { | |
| 1216 | UINT32 regionlength = ROMREGION_GETLENGTH(region); | |
| 1217 | UINT32 regionflags = ROMREGION_GETFLAGS(region); | |
| 1218 | ||
| 1219 | rom_region_name(regiontag, machine->gamedrv, source, region); | |
| 1220 | LOG(("Processing region \"%s\" (length=%X)\n", astring_c(regiontag), regionlength)); | |
| 1221 | ||
| 1222 | /* the first entry must be a region */ | |
| 1223 | assert(ROMENTRY_ISREGION(region)); | |
| 1224 | ||
| 1225 | /* if this is a CPU region, override with the CPU width and endianness */ | |
| 1226 | if (mame_find_cpu_index(machine, astring_c(regiontag)) >= 0) | |
| 1227 | regionflags = normalize_flags_for_cpu(machine, regionflags, astring_c(regiontag)); | |
| 1228 | ||
| 1229 | /* remember the base and length */ | |
| 1230 | romdata->regionbase = memory_region_alloc(machine, astring_c(regiontag), regionlength, regionflags); | |
| 1231 | romdata->regionlength = regionlength; | |
| 1232 | LOG(("Allocated %X bytes @ %p\n", romdata->regionlength, romdata->regionbase)); | |
| 1233 | ||
| 1234 | /* clear the region if it's requested */ | |
| 1235 | if (ROMREGION_ISERASE(region)) | |
| 1236 | memset(romdata->regionbase, ROMREGION_GETERASEVAL(region), romdata->regionlength); | |
| 1237 | ||
| 1238 | /* or if it's sufficiently small (<= 4MB) */ | |
| 1239 | else if (romdata->regionlength <= 0x400000) | |
| 1240 | memset(romdata->regionbase, 0, romdata->regionlength); | |
| 1241 | ||
| 1242 | #ifdef MAME_DEBUG | |
| 1243 | /* if we're debugging, fill region with random data to catch errors */ | |
| 1244 | else | |
| 1245 | fill_random(machine, romdata->regionbase, romdata->regionlength); | |
| 1246 | #endif | |
| 1247 | ||
| 1248 | /* now process the entries in the region */ | |
| 1249 | if (ROMREGION_ISROMDATA(region)) | |
| 1250 | process_rom_entries(machine, romdata, ROMREGION_ISLOADBYNAME(region) ? ROMREGION_GETTAG(region) : NULL, region + 1); | |
| 1251 | else if (ROMREGION_ISDISKDATA(region)) | |
| 1252 | process_disk_entries(machine, romdata, ROMREGION_GETTAG(region), region + 1); | |
| 1253 | } | |
| 1254 | ||
| 1255 | /* now go back and post-process all the regions */ | |
| 1256 | for (source = rom_first_source(machine->gamedrv, machine->config); source != NULL; source = rom_next_source(machine->gamedrv, machine->config, source)) | |
| 1257 | for (region = rom_first_region(machine->gamedrv, source); region != NULL; region = rom_next_region(region)) | |
| 1258 | region_post_process(machine, romdata, ROMREGION_GETTAG(region)); | |
| 1259 | ||
| 1260 | astring_free(regiontag); | |
| 1261 | } | |
| 1262 | ||
| 1263 | ||
| 1264 | /*------------------------------------------------- | |
| 1100 | 1265 | rom_init - new, more flexible ROM |
| 1101 | 1266 | loading system |
| 1102 | 1267 | -------------------------------------------------*/ |
| 1103 | 1268 | |
| 1104 | void rom_init(running_machine *machine | |
| 1269 | void rom_init(running_machine *machine | |
| 1105 | 1270 | { |
| 1106 | 1271 | static rom_load_data romdata; |
| 1107 | const rom_entry *region; | |
| 1108 | 1272 | |
| 1109 | /* if no roms, bail */ | |
| 1110 | if (romp == NULL) | |
| 1111 | return; | |
| 1112 | ||
| 1113 | 1273 | /* make sure we get called back on the way out */ |
| 1114 | 1274 | add_exit_callback(machine, rom_exit); |
| 1115 | 1275 | |
| r3232 | r3233 | |
| 1117 | 1277 | memset(&romdata, 0, sizeof(romdata)); |
| 1118 | 1278 | |
| 1119 | 1279 | /* determine the correct biosset to load based on OPTION_BIOS string */ |
| 1120 | system_bios = determine_bios_rom(&romdata, rom | |
| 1280 | system_bios = determine_bios_rom(&romdata, machine->gamedrv->rom | |
| 1121 | 1281 | |
| 1122 | romdata.romstotal = count_roms(romp); | |
| 1282 | /* count the total number of ROMs */ | |
| 1283 | romdata.romstotal = count_roms(machine); | |
| 1123 | 1284 | |
| 1124 | 1285 | /* reset the disk list */ |
| 1125 | 1286 | chd_list = NULL; |
| 1126 | 1287 | chd_list_tailptr = &chd_list; |
| 1127 | 1288 | |
| 1128 | /* loop until we hit the end */ | |
| 1129 | for (region = romp; region; region = rom_next_region(region)) | |
| 1130 | { | |
| 1131 | UINT32 regionlength = ROMREGION_GETLENGTH(region); | |
| 1132 | UINT32 regionflags = ROMREGION_GETFLAGS(region); | |
| 1133 | const char *regiontag = ROMREGION_GETTAG(region); | |
| 1289 | /* process the ROM entries we were passed */ | |
| 1290 | process_region_list(machine, &romdata); | |
| 1134 | 1291 | |
| 1135 | LOG(("Processing region \"%s\" (length=%X)\n", regiontag, regionlength)); | |
| 1136 | ||
| 1137 | /* the first entry must be a region */ | |
| 1138 | assert(ROMENTRY_ISREGION(region)); | |
| 1139 | ||
| 1140 | /* if this is a CPU region, override with the CPU width and endianness */ | |
| 1141 | if (mame_find_cpu_index(machine, regiontag) >= 0) | |
| 1142 | regionflags = normalize_flags_for_cpu(machine, regionflags, regiontag); | |
| 1143 | ||
| 1144 | /* remember the base and length */ | |
| 1145 | romdata.regionbase = memory_region_alloc(machine, regiontag, regionlength, regionflags); | |
| 1146 | romdata.regionlength = regionlength; | |
| 1147 | LOG(("Allocated %X bytes @ %p\n", romdata.regionlength, romdata.regionbase)); | |
| 1148 | ||
| 1149 | /* clear the region if it's requested */ | |
| 1150 | if (ROMREGION_ISERASE(region)) | |
| 1151 | memset(romdata.regionbase, ROMREGION_GETERASEVAL(region), romdata.regionlength); | |
| 1152 | ||
| 1153 | /* or if it's sufficiently small (<= 4MB) */ | |
| 1154 | else if (romdata.regionlength <= 0x400000) | |
| 1155 | memset(romdata.regionbase, 0, romdata.regionlength); | |
| 1156 | ||
| 1157 | #ifdef MAME_DEBUG | |
| 1158 | /* if we're debugging, fill region with random data to catch errors */ | |
| 1159 | else | |
| 1160 | fill_random(romdata.regionbase, romdata.regionlength); | |
| 1161 | #endif | |
| 1162 | ||
| 1163 | /* now process the entries in the region */ | |
| 1164 | if (ROMREGION_ISROMDATA(region)) | |
| 1165 | process_rom_entries(&romdata, region + 1); | |
| 1166 | else if (ROMREGION_ISDISKDATA(region)) | |
| 1167 | process_disk_entries(&romdata, regiontag, region + 1); | |
| 1168 | } | |
| 1169 | ||
| 1170 | /* now go back and post-process all the regions */ | |
| 1171 | for (region = romp; region != NULL; region = rom_next_region(region)) | |
| 1172 | region_post_process(machine, &romdata, ROMREGION_GETTAG(region)); | |
| 1173 | ||
| 1174 | 1292 | /* display the results and exit */ |
| 1175 | 1293 | total_rom_load_warnings = romdata.warnings; |
| 1176 | 1294 | |
| 1177 | display_rom_load_results(&romdata); | |
| 1295 | display_rom_load_results(machine, &romdata); | |
| 1178 | 1296 | } |
| 1179 | 1297 | |
| 1180 | 1298 |
| r3232 | r3233 | |
|---|---|---|
| 135 | 135 | /*------------------------------------------------- |
| 136 | 136 | core_fopen_ram_internal - open a RAM-based buffer |
| 137 | 137 | for file-like access, possibly copying the data, |
| 138 | ||
| 138 | and return an error code | |
| 139 | 139 | -------------------------------------------------*/ |
| 140 | 140 | |
| 141 | 141 | static file_error core_fopen_ram_internal(const void *data, size_t length, int copy_buffer, UINT32 openflags, core_file **file) |
| r3232 | r3233 | |
|---|---|---|
| 313 | 313 | } |
| 314 | 314 | |
| 315 | 315 | /* process the menu */ |
| 316 | ui_menu_process(menu, 0); | |
| 316 | ui_menu_process(machine, menu, 0); | |
| 317 | 317 | } |
| 318 | 318 | |
| 319 | 319 | |
| r3232 | r3233 | |
| 408 | 408 | } |
| 409 | 409 | |
| 410 | 410 | /* process the menu */ |
| 411 | event = ui_menu_process(menu, 0); | |
| 411 | event = ui_menu_process(machine, menu, 0); | |
| 412 | 412 | |
| 413 | 413 | if (event != NULL) |
| 414 | 414 | { |
| r3232 | r3233 | |
|---|---|---|
| 35 | 35 | |
| 36 | 36 | |
| 37 | 37 | |
| 38 | static void ram_init(const game_driver *gamedrv) | |
| 38 | static void ram_init(running_machine *machine, const game_driver *gamedrv) | |
| 39 | 39 | { |
| 40 | 40 | int i; |
| 41 | 41 | char buffer[1024]; |
| r3232 | r3233 | |
| 50 | 50 | specified_ram = ram_parse_string(ramsize_string); |
| 51 | 51 | if (specified_ram == 0) |
| 52 | 52 | { |
| 53 | fatalerror_exitcode(MAMERR_DEVICE, "Cannot recognize the RAM option %s\n", ramsize_string); | |
| 53 | fatalerror_exitcode(machine, MAMERR_DEVICE, "Cannot recognize the RAM option %s\n", ramsize_string); | |
| 54 | 54 | } |
| 55 | 55 | |
| 56 | 56 | /* is this option actually valid? */ |
| r3232 | r3233 | |
| 63 | 63 | if (opt_count == 0) |
| 64 | 64 | { |
| 65 | 65 | /* this driver doesn't support RAM configurations */ |
| 66 | fatalerror_exitcode(MAMERR_DEVICE, "Driver '%s' does not support RAM configurations\n", gamedrv->name); | |
| 66 | fatalerror_exitcode(machine, MAMERR_DEVICE, "Driver '%s' does not support RAM configurations\n", gamedrv->name); | |
| 67 | 67 | } |
| 68 | 68 | else |
| 69 | 69 | { |
| r3232 | r3233 | |
| 73 | 73 | for (i = 0; i < opt_count; i++) |
| 74 | 74 | s += sprintf(s, "%s%s", i ? " or " : "", ram_string(buffer2, ram_option(gamedrv, i))); |
| 75 | 75 | s += sprintf(s, ")\n"); |
| 76 | fatalerror_exitcode(MAMERR_DEVICE, "%s", buffer); | |
| 76 | fatalerror_exitcode(machine, MAMERR_DEVICE, "%s", buffer); | |
| 77 | 77 | } |
| 78 | 78 | } |
| 79 | 79 | mess_ram_size = specified_ram; |
| r3232 | r3233 | |
| 115 | 115 | mess_devices_setup((machine_config *) machine->config, machine->gamedrv); |
| 116 | 116 | |
| 117 | 117 | /* initialize RAM code */ |
| 118 | ram_init(machine->gamedrv); | |
| 118 | ram_init(machine, machine->gamedrv); | |
| 119 | 119 | } |
| 120 | 120 | |
| 121 | 121 | |
| r3232 | r3233 | |
| 152 | 152 | /* did the image load fail? */ |
| 153 | 153 | if (result) |
| 154 | 154 | { |
| 155 | fatalerror_exitcode(MAMERR_DEVICE, "Device %s load (%s) failed: %s\n", | |
| 155 | fatalerror_exitcode(machine, MAMERR_DEVICE, "Device %s load (%s) failed: %s\n", | |
| 156 | 156 | info.name, |
| 157 | 157 | osd_basename((char *) image_name), |
| 158 | 158 | image_error(image)); |
| r3232 | r3233 | |
| 163 | 163 | /* no image... must this device be loaded? */ |
| 164 | 164 | if (info.must_be_loaded) |
| 165 | 165 | { |
| 166 | fatalerror_exitcode(MAMERR_DEVICE, "Driver requires that device \"%s\" must have an image to load\n", info.instance_name); | |
| 166 | fatalerror_exitcode(machine, MAMERR_DEVICE, "Driver requires that device \"%s\" must have an image to load\n", info.instance_name); | |
| 167 | 167 | } |
| 168 | 168 | } |
| 169 | 169 | } |
| r3232 | r3233 | |
|---|---|---|
| 190 | 190 | menu_tape_control_populate(machine, menu, state); |
| 191 | 191 | |
| 192 | 192 | /* process the menu */ |
| 193 | event = ui_menu_process(menu, 0); | |
| 193 | event = ui_menu_process(machine, menu, 0); | |
| 194 | 194 | if (event != NULL) |
| 195 | 195 | { |
| 196 | 196 | switch(event->iptkey) |
| r3232 | r3233 | |
|---|---|---|
| 162 | 162 | state_save_register_item(unique_tag, 0, lmc1992->fader_lf); |
| 163 | 163 | state_save_register_item(unique_tag, 0, lmc1992->fader_rr); |
| 164 | 164 | state_save_register_item(unique_tag, 0, lmc1992->fader_lr); |
| 165 | return DEVICE_START_OK; | |
| 165 | 166 | } |
| 166 | 167 | |
| 167 | 168 | static DEVICE_SET_INFO( lmc1992 ) |
| r3232 | r3233 | |
|---|---|---|
| 132 | 132 | static int NoScreen = 0; |
| 133 | 133 | |
| 134 | 134 | /* Debugging commands and handlers. */ |
| 135 | static void | |
| 135 | static void | |
| 136 | 136 | static void RegLog(int offset, int data); |
| 137 | static void FillScreen(int ref, int params, const char *param[]); | |
| 138 | static void ScreenBox(int ref, int params, const char *param[]); | |
| 139 | static void VidToggle(int ref, int params, const char *param[]); | |
| 140 | static void ShowVidLimits(int ref, int params, const char *param[]); | |
| 141 | static void SetClkMax(int ref, int params, const char *param[]); | |
| 137 | static void execute_beta_vid_fill(running_machine *machine, int ref, int params, const char *param[]); | |
| 138 | static void execute_beta_vid_box(running_machine *machine, int ref, int params, const char *param[]); | |
| 139 | static void execute_beta_vid(running_machine *machine, int ref, int params, const char *param[]); | |
| 140 | static void execute_beta_vid_limits(running_machine *machine, int ref, int params, const char *param[]); | |
| 141 | static void execute_beta_vid_clkmax(running_machine *machine, int ref, int params, const char *param[]); | |
| 142 | 142 | |
| 143 | 143 | static bitmap_t *bit; |
| 144 | 144 | static int MinAddr = 0xFFFF; |
| r3232 | r3233 | |
| 326 | 326 | /* setup debug commands */ |
| 327 | 327 | if (machine->debug_flags & DEBUG_FLAG_ENABLED) |
| 328 | 328 | { |
| 329 | debug_console_register_command("beta_vid_log", CMDFLAG_NONE, 0, 0, 0,ToggleRegLog); | |
| 330 | debug_console_register_command("beta_vid_fill", CMDFLAG_NONE, 0, 0, 0,FillScreen); | |
| 331 | debug_console_register_command("beta_vid_box", CMDFLAG_NONE, 0, 0, 5,ScreenBox); | |
| 332 | debug_console_register_command("beta_vid", CMDFLAG_NONE, 0, 0, 0,VidToggle); | |
| 333 | debug_console_register_command("beta_vid_limits", CMDFLAG_NONE, 0, 0, 0,ShowVidLimits); | |
| 334 | debug_console_register_command("beta_vid_clkmax", CMDFLAG_NONE, 0, 0, 1,SetClkMax); | |
| 329 | debug_console_register_command(machine, "beta_vid_log", CMDFLAG_NONE, 0, 0, 0, execute_beta_vid_log); | |
| 330 | debug_console_register_command(machine, "beta_vid_fill", CMDFLAG_NONE, 0, 0, 0, execute_beta_vid_fill); | |
| 331 | debug_console_register_command(machine, "beta_vid_box", CMDFLAG_NONE, 0, 0, 5, execute_beta_vid_box); | |
| 332 | debug_console_register_command(machine, "beta_vid", CMDFLAG_NONE, 0, 0, 0, execute_beta_vid); | |
| 333 | debug_console_register_command(machine, "beta_vid_limits", CMDFLAG_NONE, 0, 0, 0, execute_beta_vid_limits); | |
| 334 | debug_console_register_command(machine, "beta_vid_clkmax", CMDFLAG_NONE, 0, 0, 1, execute_beta_vid_clkmax); | |
| 335 | 335 | } |
| 336 | 336 | LogRegWrites=0; |
| 337 | 337 | } |
| r3232 | r3233 | |
| 725 | 725 | * |
| 726 | 726 | *************************************/ |
| 727 | 727 | |
| 728 | static void | |
| 728 | static void | |
| 729 | 729 | { |
| 730 | 730 | LogRegWrites=!LogRegWrites; |
| 731 | 731 | |
| r3232 | r3233 | |
| 761 | 761 | debug_console_printf("6845 write Reg %s Addr=%3d Data=%3d ($%2.2X) \n",RegName,VidAddr,data,data); |
| 762 | 762 | } |
| 763 | 763 | |
| 764 | static void | |
| 764 | static void execute_beta_vid_fill( | |
| 765 | 765 | { |
| 766 | 766 | int x; |
| 767 | 767 | |
| r3232 | r3233 | |
| 772 | 772 | NoScreen=1; |
| 773 | 773 | } |
| 774 | 774 | |
| 775 | static void | |
| 775 | static void execute_beta_vid_box(running_machine *machine, int ref, int params, const char *param[]) | |
| 776 | 776 | { |
| 777 | 777 | int x,y; |
| 778 | 778 | |
| r3232 | r3233 | |
| 797 | 797 | } |
| 798 | 798 | |
| 799 | 799 | |
| 800 | static void | |
| 800 | static void execute_beta_vid(running_machine *machine, int ref, int params, const char *param[]) | |
| 801 | 801 | { |
| 802 | 802 | NoScreen=!NoScreen; |
| 803 | 803 | } |
| 804 | 804 | |
| 805 | static void | |
| 805 | static void execute_beta_vid_limits(running_machine *machine, int ref, int params, const char *param[]) | |
| 806 | 806 | { |
| 807 | 807 | debug_console_printf("Min X =$%4X, Max X =$%4X\n",MinX,MaxX); |
| 808 | 808 | debug_console_printf("Min Y =$%4X, Max Y =$%4X\n",MinY,MaxY); |
| r3232 | r3233 | |
| 818 | 818 | debug_console_printf("Gfx4/Text\n"); |
| 819 | 819 | } |
| 820 | 820 | |
| 821 | static void | |
| 821 | static void | |
| 822 | 822 | { |
| 823 | 823 | if(params>0) sscanf(param[0],"%d",&ClkMax); |
| 824 | 824 | } |
| r3232 | r3233 | |
|---|---|---|
| 536 | 536 | |
| 537 | 537 | state_save_register_item(unique_tag, 0, i8275->burst_space_code); |
| 538 | 538 | state_save_register_item(unique_tag, 0, i8275->burst_count_code); |
| 539 | return DEVICE_START_OK; | |
| 539 | 540 | } |
| 540 | 541 | |
| 541 | 542 | static DEVICE_RESET( i8275 ) |
| r3232 | r3233 | |
|---|---|---|
| 1673 | 1673 | *************************************/ |
| 1674 | 1674 | |
| 1675 | 1675 | |
| 1676 | static void execute_dumpscanline(int ref, int params, const char **param) | |
| 1676 | static void execute_m6847_dumpscanline(running_machine *machine, int ref, int params, const char **param) | |
| 1677 | 1677 | { |
| 1678 | 1678 | int i; |
| 1679 | 1679 | int beamx = get_beamx() / 8; |
| r3232 | r3233 | |
| 1915 | 1915 | |
| 1916 | 1916 | /* setup debug commands */ |
| 1917 | 1917 | if (machine->debug_flags & DEBUG_FLAG_ENABLED) |
| 1918 | debug_console_register_command("m6847_dumpscanline", CMDFLAG_NONE, 0, 0, 0, execute_dumpscanline); | |
| 1918 | debug_console_register_command(machine, "m6847_dumpscanline", CMDFLAG_NONE, 0, 0, 0, execute_m6847_dumpscanline); | |
| 1919 | 1919 | } |
| 1920 | 1920 | |
| 1921 | 1921 |
| r3232 | r3233 | |
|---|---|---|
| 772 | 772 | static DEVICE_START( crtc_ega ) |
| 773 | 773 | { |
| 774 | 774 | common_start(device, TYPE_CRTC_EGA); |
| 775 | return DEVICE_START_OK; | |
| 775 | 776 | } |
| 776 | 777 | |
| 777 | 778 |
| r3232 | r3233 | |
|---|---|---|
| 269 | 269 | state_save_register_item(unique_tag, 0, zx8301->flash); |
| 270 | 270 | state_save_register_item(unique_tag, 0, zx8301->vsync); |
| 271 | 271 | state_save_register_item(unique_tag, 0, zx8301->vda); |
| 272 | return DEVICE_START_OK; | |
| 272 | 273 | } |
| 273 | 274 | |
| 274 | 275 | static DEVICE_RESET( zx8301 ) |
| r3232 | r3233 | |
|---|---|---|
| 379 | 379 | |
| 380 | 380 | state_save_register_item(unique_tag, 0, msm6255->cursor); |
| 381 | 381 | state_save_register_item(unique_tag, 0, msm6255->frame); |
| 382 | return DEVICE_START_OK; | |
| 382 | 383 | } |
| 383 | 384 | |
| 384 | 385 | static DEVICE_RESET( msm6255 ) |
| r3232 | r3233 | |
|---|---|---|
| 398 | 398 | state_save_register_item(unique_tag, 0, cdp1864->incr); |
| 399 | 399 | |
| 400 | 400 | state_save_register_bitmap(unique_tag, 0, "cdp1864->bitmap", cdp1864->bitmap); |
| 401 | return DEVICE_START_OK; | |
| 401 | 402 | } |
| 402 | 403 | |
| 403 | 404 | static DEVICE_RESET( cdp1864 ) |
| r3232 | r3233 | |
|---|---|---|
| 139 | 139 | state_save_register_item(unique_tag, 0, dl1416->cursor_enable); |
| 140 | 140 | state_save_register_item(unique_tag, 0, dl1416->write_enable); |
| 141 | 141 | state_save_register_item_array(unique_tag, 0, dl1416->cursor_ram); |
| 142 | return DEVICE_START_OK; | |
| 142 | 143 | } |
| 143 | 144 | |
| 144 | 145 |
| r3232 | r3233 | |
|---|---|---|
| 218 | 218 | state_save_register_item(unique_tag, 0, cdp1861->disp); |
| 219 | 219 | state_save_register_item(unique_tag, 0, cdp1861->dmaout); |
| 220 | 220 | state_save_register_bitmap(unique_tag, 0, "cdp1861->bitmap", cdp1861->bitmap); |
| 221 | return DEVICE_START_OK; | |
| 221 | 222 | } |
| 222 | 223 | |
| 223 | 224 | static DEVICE_RESET( cdp1861 ) |
| r3232 | r3233 | |
|---|---|---|
| 182 | 182 | |
| 183 | 183 | static DEVICE_START(mess_device) |
| 184 | 184 | { |
| 185 | device_start_err err = DEVICE_START_OK; | |
| 186 | ||
| 185 | 187 | mess_device_config *mess_device = (mess_device_config *) device->inline_config; |
| 186 | 188 | mess_device_token *token = (mess_device_token *) device->token; |
| 187 | 189 | device_start_func inner_start; |
| r3232 | r3233 | |
| 192 | 194 | /* if present, invoke the start handler */ |
| 193 | 195 | inner_start = (device_start_func) mess_device_get_info_fct(&mess_device->io_device.devclass, MESS_DEVINFO_PTR_START); |
| 194 | 196 | if (inner_start != NULL) |
| 195 | (*inner_start)(device); | |
| 197 | err = (*inner_start)(device); | |
| 198 | ||
| 199 | return err; | |
| 196 | 200 | } |
| 197 | 201 | |
| 198 | 202 |
| r3232 | r3233 | |
|---|---|---|
| 90 | 90 | |
| 91 | 91 | /* Debugging commands and handlers. */ |
| 92 | 92 | static offs_t dgnbeta_dasm_override(char *buffer, offs_t pc, const UINT8 *oprom, const UINT8 *opram); |
| 93 | static void ToggleDatLog(int ref, int params, const char *param[]); | |
| 94 | static void DumpKeys(int ref, int params, const char *param[]); | |
| 93 | static void execute_beta_dat_log(running_machine *machine, int ref, int params, const char *param[]); | |
| 94 | static void execute_beta_key_dump(running_machine *machine, int ref, int params, const char *param[]); | |
| 95 | 95 | |
| 96 | 96 | /* Debugging variables */ |
| 97 | 97 | static int LogDatWrites; |
| r3232 | r3233 | |
| 1080 | 1080 | /* setup debug commands */ |
| 1081 | 1081 | if (machine->debug_flags & DEBUG_FLAG_ENABLED) |
| 1082 | 1082 | { |
| 1083 | debug_console_register_command("beta_dat_log", CMDFLAG_NONE, 0, 0, 0,ToggleDatLog); | |
| 1084 | debug_console_register_command("beta_key_dump", CMDFLAG_NONE, 0, 0, 0,DumpKeys); | |
| 1083 | debug_console_register_command(machine, "beta_dat_log", CMDFLAG_NONE, 0, 0, 0, execute_beta_dat_log); | |
| 1084 | debug_console_register_command(machine, "beta_key_dump", CMDFLAG_NONE, 0, 0, 0, execute_beta_key_dump); | |
| 1085 | 1085 | } |
| 1086 | 1086 | LogDatWrites=0; |
| 1087 | 1087 | } |
| r3232 | r3233 | |
| 1260 | 1260 | return result; |
| 1261 | 1261 | } |
| 1262 | 1262 | |
| 1263 | static void | |
| 1263 | static void | |
| 1264 | 1264 | { |
| 1265 | 1265 | LogDatWrites=!LogDatWrites; |
| 1266 | 1266 | |
| 1267 | 1267 | debug_console_printf("DAT register write info set : %d\n",LogDatWrites); |
| 1268 | 1268 | } |
| 1269 | 1269 | |
| 1270 | static void | |
| 1270 | static void execut | |
| 1271 | 1271 | { |
| 1272 | 1272 | int Idx; |
| 1273 | 1273 |
| r3232 | r3233 | |
|---|---|---|
| 373 | 373 | |
| 374 | 374 | DEVICE_START( pdp1_tape ) |
| 375 | 375 | { |
| 376 | return DEVICE_START_OK; | |
| 376 | 377 | } |
| 377 | 378 | |
| 378 | 379 |
| r3232 | r3233 | |
|---|---|---|
| 643 | 643 | static DEVICE_START(oldfdc) |
| 644 | 644 | { |
| 645 | 645 | applefdc_start(device, APPLEFDC_APPLE2); |
| 646 | return DEVICE_START_OK; | |
| 646 | 647 | } |
| 647 | 648 | |
| 648 | 649 | |
| r3232 | r3233 | |
| 676 | 677 | static DEVICE_START(iwm) |
| 677 | 678 | { |
| 678 | 679 | applefdc_start(device, APPLEFDC_IWM); |
| 680 | return DEVICE_START_OK; | |
| 679 | 681 | } |
| 680 | 682 | |
| 681 | 683 | |
| r3232 | r3233 | |
| 709 | 711 | static DEVICE_START(swim) |
| 710 | 712 | { |
| 711 | 713 | applefdc_start(device, APPLEFDC_SWIM); |
| 714 | return DEVICE_START_OK; | |
| 712 | 715 | } |
| 713 | 716 | |
| 714 | 717 |
| r3232 | r3233 | |
|---|---|---|
| 96 | 96 | { |
| 97 | 97 | token->slot_device = NULL; |
| 98 | 98 | } |
| 99 | return DEVICE_START_OK; | |
| 99 | 100 | } |
| 100 | 101 | |
| 101 | 102 |
| r3232 | r3233 | |
|---|---|---|
| 1080 | 1080 | static DEVICE_START( hp48_port ) |
| 1081 | 1081 | { |
| 1082 | 1082 | hp48_unfill_port( device ); |
| 1083 | return DEVICE_START_OK; | |
| 1083 | 1084 | } |
| 1084 | 1085 | |
| 1085 | 1086 | DEVICE_GET_INFO( hp48_port ) |
| r3232 | r3233 | |
|---|---|---|
| 76 | 76 | |
| 77 | 77 | static DEVICE_START(mockingboard) |
| 78 | 78 | { |
| 79 | return DEVICE_START_OK; | |
| 79 | 80 | } |
| 80 | 81 | |
| 81 | 82 |
| r3232 | r3233 | |
|---|---|---|
| 440 | 440 | #if NCR5380_DEVICE_CONVERSION |
| 441 | 441 | static DEVICE_START( ncr5380 ) |
| 442 | 442 | { |
| 443 | return DEVICE_START_OK; | |
| 443 | 444 | } |
| 444 | 445 | |
| 445 | 446 |
| r3232 | r3233 | |
|---|---|---|
| 35 | 35 | DEVICE_START(d88image_floppy) |
| 36 | 36 | { |
| 37 | 37 | floppy_drive_init(device, &d88image_floppy_interface); |
| 38 | return DEVICE_START_OK; | |
| 38 | 39 | } |
| 39 | 40 | |
| 40 | 41 | /* attempt to insert a disk into the drive specified with id */ |
| r3232 | r3233 | |
|---|---|---|
| 1400 | 1400 | |
| 1401 | 1401 | DEVICE_START( pokemini_cart ) |
| 1402 | 1402 | { |
| 1403 | return DEVICE_START_OK; | |
| 1403 | 1404 | } |
| 1404 | 1405 | |
| 1405 | 1406 | DEVICE_IMAGE_LOAD( pokemini_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 1405 | 1405 | CartType = 0; |
| 1406 | 1406 | ROMMask = 0; |
| 1407 | 1407 | RAMMask = 0; |
| 1408 | return DEVICE_START_OK; | |
| 1408 | 1409 | } |
| 1409 | 1410 | |
| 1410 | 1411 | DEVICE_IMAGE_LOAD(gb_cart) |
| r3232 | r3233 | |
|---|---|---|
| 593 | 593 | DEVICE_START( gamecom_cart ) |
| 594 | 594 | { |
| 595 | 595 | internal_ram = sm8500_internal_ram(); |
| 596 | return DEVICE_START_OK; | |
| 596 | 597 | } |
| 597 | 598 | |
| 598 | 599 | DEVICE_IMAGE_LOAD( gamecom_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 64 | 64 | state_save_register_item(unique_tag, 0, ins8154->mdr); |
| 65 | 65 | state_save_register_item(unique_tag, 0, ins8154->odra); |
| 66 | 66 | state_save_register_item(unique_tag, 0, ins8154->odrb); |
| 67 | return DEVICE_START_OK; | |
| 67 | 68 | } |
| 68 | 69 | |
| 69 | 70 |
| r3232 | r3233 | |
|---|---|---|
| 120 | 120 | smartmedia[id].pagereg = NULL; |
| 121 | 121 | smartmedia[id].id[0] = smartmedia[id].id[1] = 0; |
| 122 | 122 | smartmedia[id].mp_opcode = 0; |
| 123 | return DEVICE_START_OK; | |
| 123 | 124 | } |
| 124 | 125 | |
| 125 | 126 | /* |
| r3232 | r3233 | |
|---|---|---|
| 29 | 29 | MACHINE_START( advision ) |
| 30 | 30 | { |
| 31 | 31 | /* configure EA banking */ |
| 32 | memory_configure_bank(MCS48_INTERNAL_ROMBANK, 0, 1, memory_region(machine, "bios"), 0); | |
| 33 | memory_configure_bank(MCS48_INTERNAL_ROMBANK, 1, 1, memory_region(machine, "main"), 0); | |
| 32 | memory_configure_bank(1, 0, 1, memory_region(machine, "bios"), 0); | |
| 33 | memory_configure_bank(1, 1, 1, memory_region(machine, "main"), 0); | |
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | MACHINE_RESET( advision ) |
| r3232 | r3233 | |
|---|---|---|
| 639 | 639 | { |
| 640 | 640 | int id = image_index_in_device(device); |
| 641 | 641 | memset(&serial_devices[id], 0, sizeof(serial_devices[id])); |
| 642 | return DEVICE_START_OK; | |
| 642 | 643 | } |
| 643 | 644 | |
| 644 | 645 | DEVICE_IMAGE_LOAD(serial_device) |
| r3232 | r3233 | |
|---|---|---|
| 208 | 208 | serial_device_setup( device, 2400, 7, 2, SERIAL_PARITY_NONE ); /* default */ |
| 209 | 209 | serial_device_set_protocol( device, SERIAL_PROTOCOL_NONE ); |
| 210 | 210 | serial_device_set_transmit_state( device, 1 ); |
| 211 | return DEVICE_START_OK; | |
| 211 | 212 | } |
| 212 | 213 | |
| 213 | 214 |
| r3232 | r3233 | |
|---|---|---|
| 324 | 324 | state_save_register_item(unique_tag, 0, cdp1871->next_da); |
| 325 | 325 | state_save_register_item(unique_tag, 0, cdp1871->rpt); |
| 326 | 326 | state_save_register_item(unique_tag, 0, cdp1871->next_rpt); |
| 327 | return DEVICE_START_OK; | |
| 327 | 328 | } |
| 328 | 329 | |
| 329 | 330 | static DEVICE_SET_INFO( cdp1871 ) |
| r3232 | r3233 | |
|---|---|---|
| 66 | 66 | { |
| 67 | 67 | scc8530_t *scc = get_token(device); |
| 68 | 68 | memset(scc, 0, sizeof(*scc)); |
| 69 | return DEVICE_START_OK; | |
| 69 | 70 | } |
| 70 | 71 | |
| 71 | 72 |
| r3232 | r3233 | |
|---|---|---|
| 200 | 200 | |
| 201 | 201 | DEVICE_START( tx0_tape ) |
| 202 | 202 | { |
| 203 | return DEVICE_START_OK; | |
| 203 | 204 | } |
| 204 | 205 | |
| 205 | 206 | |
| r3232 | r3233 | |
| 557 | 558 | DEVICE_START( tx0_magtape ) |
| 558 | 559 | { |
| 559 | 560 | magtape.img = device; |
| 561 | return DEVICE_START_OK; | |
| 560 | 562 | } |
| 561 | 563 | |
| 562 | 564 | /* |
| r3232 | r3233 | |
|---|---|---|
| 552 | 552 | { |
| 553 | 553 | DBG_LOG (1, "switching to z80", |
| 554 | 554 | ("active %d\n",cpu_getactivecpu()) ); |
| 555 | memory_set_context(0); | |
| 555 | memory_set_context(machine, 0); | |
| 556 | 556 | c128_bankswitch_z80(machine); |
| 557 | memory_set_context(1); | |
| 557 | memory_set_context(machine, 1); | |
| 558 | 558 | cpunum_set_input_line(machine, 0, INPUT_LINE_HALT, CLEAR_LINE); |
| 559 | 559 | cpunum_set_input_line(machine, 1, INPUT_LINE_HALT, ASSERT_LINE); |
| 560 | 560 | } |
| r3232 | r3233 | |
| 562 | 562 | { |
| 563 | 563 | DBG_LOG (1, "switching to m6502", |
| 564 | 564 | ("active %d\n",cpu_getactivecpu()) ); |
| 565 | memory_set_context(1); | |
| 565 | memory_set_context(machine, 1); | |
| 566 | 566 | c128_bankswitch_128(machine, reset); |
| 567 | memory_set_context(0); | |
| 567 | memory_set_context(machine, 0); | |
| 568 | 568 | cpunum_set_input_line(machine, 0, INPUT_LINE_HALT, ASSERT_LINE); |
| 569 | 569 | cpunum_set_input_line(machine, 1, INPUT_LINE_HALT, CLEAR_LINE); |
| 570 | 570 |
| r3232 | r3233 | |
|---|---|---|
| 89 | 89 | static DEVICE_START(apple2_langcard) |
| 90 | 90 | { |
| 91 | 91 | /* nothing to do */ |
| 92 | return DEVICE_START_OK; | |
| 92 | 93 | } |
| 93 | 94 | |
| 94 | 95 |
| r3232 | r3233 | |
|---|---|---|
| 1087 | 1087 | { |
| 1088 | 1088 | /* TODO - THIS DOES NOT MULTITASK BETWEEN ORIC BASICDSKs AND MFM DISKS */ |
| 1089 | 1089 | floppy_drive_init(device, NULL); |
| 1090 | return DEVICE_START_OK; | |
| 1090 | 1091 | } |
| 1091 | 1092 | |
| 1092 | 1093 |
| r3232 | r3233 | |
|---|---|---|
| 1448 | 1448 | state_save_register_item(unique_tag, 0, mc68901->rxtx_stop); |
| 1449 | 1449 | state_save_register_item(unique_tag, 0, mc68901->rsr_read); |
| 1450 | 1450 | state_save_register_item(unique_tag, 0, mc68901->next_rsr); |
| 1451 | return DEVICE_START_OK; | |
| 1451 | 1452 | } |
| 1452 | 1453 | |
| 1453 | 1454 | static DEVICE_RESET( mc68901 ) |
| r3232 | r3233 | |
|---|---|---|
| 95 | 95 | fdc_side = 1; |
| 96 | 96 | fdc_step = 1; |
| 97 | 97 | fdc_rdy = 0; |
| 98 | return DEVICE_START_OK; | |
| 98 | 99 | } |
| 99 | 100 | |
| 100 | 101 | static void check_extended_image( int id ) |
| r3232 | r3233 | |
|---|---|---|
| 223 | 223 | /* defaults for PAL bios without cart */ |
| 224 | 224 | a7800_cart_type = 0; |
| 225 | 225 | a7800_stick_type = 1; |
| 226 | return DEVICE_START_OK; | |
| 226 | 227 | } |
| 227 | 228 | |
| 228 | 229 | DEVICE_IMAGE_LOAD( a7800_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 759 | 759 | |
| 760 | 760 | /* Initially set the vdp to not use sms compatibility mode for GG */ |
| 761 | 761 | sms_set_ggsmsmode( 0 ); |
| 762 | return DEVICE_START_OK; | |
| 762 | 763 | } |
| 763 | 764 | |
| 764 | 765 | DEVICE_IMAGE_LOAD( sms_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 665 | 665 | { |
| 666 | 666 | ti85_free_serial_data_memory(device->machine); |
| 667 | 667 | ti85_receive_serial (NULL,0); |
| 668 | return DEVICE_START_OK; | |
| 668 | 669 | } |
| 669 | 670 | |
| 670 | 671 | DEVICE_IMAGE_LOAD( ti85_serial ) |
| r3232 | r3233 | |
|---|---|---|
| 113 | 113 | { |
| 114 | 114 | pcart = NULL; |
| 115 | 115 | pcart_rom_size = 0; |
| 116 | return DEVICE_START_OK; | |
| 116 | 117 | } |
| 117 | 118 | |
| 118 | 119 | DEVICE_IMAGE_LOAD( svi318_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 1281 | 1281 | rtc.minute = 0; |
| 1282 | 1282 | rtc.second = 0; |
| 1283 | 1283 | rtc.setting = 0xFF; |
| 1284 | return DEVICE_START_OK; | |
| 1284 | 1285 | } |
| 1285 | 1286 | |
| 1286 | 1287 | DEVICE_IMAGE_LOAD(wswan_cart) |
| r3232 | r3233 | |
|---|---|---|
| 53 | 53 | sasi->status_port = 0x00; |
| 54 | 54 | sasi->phase = SASI_PHASE_BUSFREE; |
| 55 | 55 | hd.current_block = 0; |
| 56 | return DEVICE_START_OK; | |
| 56 | 57 | } |
| 57 | 58 | |
| 58 | 59 | DEVICE_IMAGE_CREATE( sasihd ) |
| r3232 | r3233 | |
|---|---|---|
| 97 | 97 | /* card ram NULL */ |
| 98 | 98 | nc_card_ram = NULL; |
| 99 | 99 | nc_card_size = 0; |
| 100 | return DEVICE_START_OK; | |
| 100 | 101 | } |
| 101 | 102 | |
| 102 | 103 | /* load pcmcia card */ |
| r3232 | r3233 | |
|---|---|---|
| 565 | 565 | |
| 566 | 566 | nes_fds.sides = 0; |
| 567 | 567 | nes_fds.data = NULL; |
| 568 | return DEVICE_START_OK; | |
| 568 | 569 | } |
| 569 | 570 | |
| 570 | 571 |
| r3232 | r3233 | |
|---|---|---|
| 120 | 120 | t->wp = 1; |
| 121 | 121 | t->bot = 0; |
| 122 | 122 | t->eot = 0; |
| 123 | return DEVICE_START_OK; | |
| 123 | 124 | } |
| 124 | 125 | |
| 125 | 126 | /*DEVICE_STOP( ti990_tape ) |
| r3232 | r3233 | |
|---|---|---|
| 165 | 165 | state_save_register_item(unique_tag, 0, adc080x->sar); |
| 166 | 166 | state_save_register_item(unique_tag, 0, adc080x->cycle); |
| 167 | 167 | state_save_register_item(unique_tag, 0, adc080x->bit); |
| 168 | return DEVICE_START_OK; | |
| 168 | 169 | } |
| 169 | 170 | |
| 170 | 171 | static DEVICE_SET_INFO( adc080x ) |
| r3232 | r3233 | |
|---|---|---|
| 111 | 111 | int id = image_index_in_device(device); |
| 112 | 112 | if (id == 0) |
| 113 | 113 | cbm_drive_open(); /* boy these C64 drivers are butt ugly */ |
| 114 | return DEVICE_START_OK; | |
| 114 | 115 | } |
| 115 | 116 | |
| 116 | 117 | static DEVICE_STOP( cbm_drive ) |
| r3232 | r3233 | |
|---|---|---|
| 158 | 158 | // const ay31015_config *config = get_config(device); |
| 159 | 159 | |
| 160 | 160 | ay = get_token(device); |
| 161 | return DEVICE_START_OK; | |
| 161 | 162 | } |
| 162 | 163 | #endif |
| 163 | 164 |
| r3232 | r3233 | |
|---|---|---|
| 657 | 657 | vc20_rom_4000 = NULL; |
| 658 | 658 | vc20_rom_6000 = NULL; |
| 659 | 659 | vc20_rom_a000 = NULL; |
| 660 | return DEVICE_START_OK; | |
| 660 | 661 | } |
| 661 | 662 | |
| 662 | 663 | DEVICE_IMAGE_LOAD(vic20_cart) |
| r3232 | r3233 | |
|---|---|---|
| 216 | 216 | state_save_register_item(unique_tag, 0, e0516->dio); |
| 217 | 217 | |
| 218 | 218 | state_save_register_item_array(unique_tag, 0, e0516->reg); |
| 219 | return DEVICE_START_OK; | |
| 219 | 220 | } |
| 220 | 221 | |
| 221 | 222 | static DEVICE_SET_INFO( e0516 ) |
| r3232 | r3233 | |
|---|---|---|
| 388 | 388 | /* assume keyboard is absent */ |
| 389 | 389 | memory[0x7000<<1] = 0xff; |
| 390 | 390 | memory[(0x7000<<1)+1] = 0xff; |
| 391 | return DEVICE_START_OK; | |
| 391 | 392 | } |
| 392 | 393 | |
| 393 | 394 | DEVICE_IMAGE_LOAD( intv_cart ) |
| r3232 | r3233 | |
|---|---|---|
| 547 | 547 | static DEVICE_START( ins8250 ) |
| 548 | 548 | { |
| 549 | 549 | common_start( device, TYPE_INS8250 ); |
| 550 | return DEVICE_START_OK; | |
| 550 | 551 | } |
| 551 | 552 | |
| 552 | 553 | |
| 553 | 554 | static DEVICE_START( ins8250a ) |
| 554 | 555 | { |
| 555 | 556 | common_start( device, TYPE_INS8250A ); |
| 557 | return DEVICE_START_OK; | |
| 556 | 558 | } |
| 557 | 559 | |
| 558 | 560 | |
| 559 | 561 | static DEVICE_START( ns16450 ) |
| 560 | 562 | { |
| 561 | 563 | common_start( device, TYPE_NS16450 ); |
| 564 | return DEVICE_START_OK; | |
| 562 | 565 | } |
| 563 | 566 | |
| 564 | 567 | |
| 565 | 568 | static DEVICE_START( ns16550 ) |
| 566 | 569 | { |
| 567 | 570 | common_start( device, TYPE_NS16550 ); |
| 571 | return DEVICE_START_OK; | |
| 568 | 572 | } |
| 569 | 573 | |
| 570 | 574 | |
| 571 | 575 | static DEVICE_START( ns16550a ) |
| 572 | 576 | { |
| 573 | 577 | common_start( device, TYPE_NS16550A ); |
| 578 | return DEVICE_START_OK; | |
| 574 | 579 | } |
| 575 | 580 | |
| 576 | 581 | |
| 577 | 582 | static DEVICE_START( pc16550d ) |
| 578 | 583 | { |
| 579 | 584 | common_start( device, TYPE_PC16550D ); |
| 585 | return DEVICE_START_OK; | |
| 580 | 586 | } |
| 581 | 587 | |
| 582 | 588 |
| r3232 | r3233 | |
|---|---|---|
| 637 | 637 | |
| 638 | 638 | state_save_register_item(unique_tag, 0, zx8302->mdv_motor); |
| 639 | 639 | state_save_register_item_array(unique_tag, 0, zx8302->mdv_offset); |
| 640 | return DEVICE_START_OK; | |
| 640 | 641 | } |
| 641 | 642 | |
| 642 | 643 | static DEVICE_RESET( zx8302 ) |
| r3232 | r3233 | |
|---|---|---|
| 1354 | 1354 | cbm_c64_game = -1; |
| 1355 | 1355 | cbm_c64_exrom = -1; |
| 1356 | 1356 | } |
| 1357 | return DEVICE_START_OK; | |
| 1357 | 1358 | } |
| 1358 | 1359 | |
| 1359 | 1360 | /* Hardware Types for C64 carts */ |
| r3232 | r3233 | |
|---|---|---|
| 27 | 27 | dmac->reg[x].niv = 0x0f; // defaults? |
| 28 | 28 | dmac->reg[x].eiv = 0x0f; |
| 29 | 29 | } |
| 30 | return DEVICE_START_OK; | |
| 30 | 31 | } |
| 31 | 32 | |
| 32 | 33 | int hd63450_read(const device_config* device, int offset, UINT16 mem_mask) |
| r3232 | r3233 | |
|---|---|---|
| 472 | 472 | { |
| 473 | 473 | int id = image_index_in_device(device); |
| 474 | 474 | cartridge_pages[id] = (UINT16 *) (memory_region(device->machine, "main") + offset_cart + (id * 0x2000)); |
| 475 | return DEVICE_START_OK; | |
| 475 | 476 | } |
| 476 | 477 | |
| 477 | 478 | /* |
| r3232 | r3233 | |
|---|---|---|
| 391 | 391 | $(MESSOBJ)/jupiter.a \ |
| 392 | 392 | $(MESSOBJ)/kaypro.a \ |
| 393 | 393 | $(MESSOBJ)/kim1.a \ |
| 394 | $(MESSOBJ)/pk8020.a \ | |
| 395 | 394 | $(MESSOBJ)/luxor.a \ |
| 396 | 395 | $(MESSOBJ)/lviv.a \ |
| 397 | 396 | $(MESSOBJ)/lynx.a \ |
| r3232 | r3233 | |
| 418 | 417 | $(MESSOBJ)/pcshare.a \ |
| 419 | 418 | $(MESSOBJ)/pdp1.a \ |
| 420 | 419 | $(MESSOBJ)/pel.a \ |
| 420 | $(MESSOBJ)/pk8020.a \ | |
| 421 | 421 | $(MESSOBJ)/pmd85.a \ |
| 422 | $(MESSOBJ)/pp01.a \ | |
| 422 | 423 | $(MESSOBJ)/primo.a \ |
| 423 | $(MESSOBJ)/pp01.a \ | |
| 424 | 424 | $(MESSOBJ)/radio.a \ |
| 425 | 425 | $(MESSOBJ)/rca.a \ |
| 426 | 426 | $(MESSOBJ)/rockwell.a \ |
| r3232 | r3233 | |
|---|---|---|
| 274 | 274 | harddisk->config = device->static_config; |
| 275 | 275 | harddisk->chd = NULL; |
| 276 | 276 | harddisk->hard_disk_handle = NULL; |
| 277 | return DEVICE_START_OK; | |
| 277 | 278 | } |
| 278 | 279 | |
| 279 | 280 | |
| r3232 | r3233 | |
| 334 | 335 | /* ide_controller_init_custom(which_bus, intf, NULL); */ |
| 335 | 336 | #endif |
| 336 | 337 | |
| 337 | DEVICE_START_CALL(mess_hd); | |
| 338 | return DEVICE_START_CALL(mess_hd); | |
| 338 | 339 | } |
| 339 | 340 | |
| 340 | 341 |
| r3232 | r3233 | |
|---|---|---|
| 238 | 238 | cassette->config = device->static_config; |
| 239 | 239 | cassette->cassette = NULL; |
| 240 | 240 | cassette->state = cassette->config->default_state; |
| 241 | return DEVICE_START_OK; | |
| 241 | 242 | } |
| 242 | 243 | |
| 243 | 244 |
| r3232 | r3233 | |
|---|---|---|
| 11 | 11 | |
| 12 | 12 | static DEVICE_START(microdrv) |
| 13 | 13 | { |
| 14 | return DEVICE_START_OK; | |
| 14 | 15 | } |
| 15 | 16 | |
| 16 | 17 | DEVICE_GET_INFO(microdrv) |
| r3232 | r3233 | |
|---|---|---|
| 300 | 300 | state->conf = (xmodem_config*) device->static_config; |
| 301 | 301 | state->machine = device->machine; |
| 302 | 302 | state->timer = timer_alloc( xmodem_nak_cb, state ); |
| 303 | return DEVICE_START_OK; | |
| 303 | 304 | } |
| 304 | 305 | |
| 305 | 306 | static DEVICE_RESET( xmodem ) |
| r3232 | r3233 | |
|---|---|---|
| 636 | 636 | state->machine = device->machine; |
| 637 | 637 | state->resend = timer_alloc( kermit_resend_cb, state ); |
| 638 | 638 | kermit_reset( state ); |
| 639 | return DEVICE_START_OK; | |
| 639 | 640 | } |
| 640 | 641 | |
| 641 | 642 | static DEVICE_RESET( kermit ) |
| r3232 | r3233 | |
|---|---|---|
| 116 | 116 | |
| 117 | 117 | static int process_cartridge(const device_config *image, const device_config *file) |
| 118 | 118 | { |
| 119 | const rom_source *source; | |
| 119 | 120 | const rom_entry *romrgn, *roment; |
| 120 | 121 | int position = 0, result; |
| 121 | 122 | |
| 122 | romrgn = rom_first_region(image->machine->gamedrv); | |
| 123 | while(romrgn) | |
| 123 | for (source = rom_first_source(image->machine->gamedrv, image->machine->config); source != NULL; source = rom_next_source(image->machine->gamedrv, image->machine->config, source)) | |
| 124 | 124 | { |
| 125 | roment = romrgn + 1; | |
| 126 | while(!ROMENTRY_ISREGIONEND(roment)) | |
| 125 | for (romrgn = rom_first_region(image->machine->gamedrv, source); romrgn != NULL; romrgn = rom_next_region(romrgn)) | |
| 127 | 126 | { |
| 128 | if (is_cart_roment(roment)) | |
| 127 | roment = romrgn + 1; | |
| 128 | while(!ROMENTRY_ISREGIONEND(roment)) | |
| 129 | 129 | { |
| 130 | parse_rom_name(roment, &position, NULL); | |
| 131 | if (position == image_index_in_device(image)) | |
| 130 | if (is_cart_roment(roment)) | |
| 132 | 131 | { |
| 133 | result = load_cartridge(image->machine, romrgn, roment, file); | |
| 134 | if (!result) | |
| 135 | return result; | |
| 132 | parse_rom_name(roment, &position, NULL); | |
| 133 | if (position == image_index_in_device(image)) | |
| 134 | { | |
| 135 | result = load_cartridge(image->machine, romrgn, roment, file); | |
| 136 | if (!result) | |
| 137 | return result; | |
| 138 | } | |
| 136 | 139 | } |
| 140 | roment++; | |
| 137 | 141 | } |
| 138 | roment++; | |
| 139 | 142 | } |
| 140 | romrgn = rom_next_region(romrgn); | |
| 141 | 143 | } |
| 142 | 144 | return INIT_PASS; |
| 143 | 145 | } |
| r3232 | r3233 | |
| 147 | 149 | static DEVICE_START( cartslot_specified ) |
| 148 | 150 | { |
| 149 | 151 | process_cartridge(device, NULL); |
| 152 | return DEVICE_START_OK; | |
| 150 | 153 | } |
| 151 | 154 | |
| 152 | 155 | static DEVICE_IMAGE_LOAD( cartslot_specified ) |
| r3232 | r3233 | |
| 163 | 166 | |
| 164 | 167 | void cartslot_device_getinfo(const mess_device_class *devclass, UINT32 state, union devinfo *info) |
| 165 | 168 | { |
| 169 | const game_driver *gamedrv = devclass->gamedrv; | |
| 170 | machine_config *config = machine_config_alloc(gamedrv->machine_config); | |
| 171 | const rom_source *source; | |
| 166 | 172 | const rom_entry *romrgn, *roment; |
| 167 | 173 | int position, count = 0, must_be_loaded = 0; |
| 168 | 174 | const char *file_extensions = "bin"; |
| 169 | 175 | UINT32 flags; |
| 170 | 176 | |
| 171 | 177 | /* try to find ROM_CART_LOADs in the ROM declaration */ |
| 172 | romrgn = rom_first_region(devclass->gamedrv); | |
| 173 | while(romrgn != NULL) | |
| 178 | for (source = rom_first_source(gamedrv, config); source != NULL; source = rom_next_source(gamedrv, config, source)) | |
| 174 | 179 | { |
| 175 | roment = romrgn + 1; | |
| 176 | while(!ROMENTRY_ISREGIONEND(roment)) | |
| 180 | for (romrgn = rom_first_region(gamedrv, source); romrgn != NULL; romrgn = rom_next_region(romrgn)) | |
| 177 | 181 | { |
| 178 | if (is_cart_roment(roment) && !parse_rom_name(roment, &position, &file_extensions)) | |
| 182 | roment = romrgn + 1; | |
| 183 | while(!ROMENTRY_ISREGIONEND(roment)) | |
| 179 | 184 | { |
| 180 | flags = ROM_GETFLAGS(roment); | |
| 185 | if (is_cart_roment(roment) && !parse_rom_name(roment, &position, &file_extensions)) | |
| 186 | { | |
| 187 | flags = ROM_GETFLAGS(roment); | |
| 181 | 188 | |
| 182 | /* reject any unsupported flags */ | |
| 183 | if (flags & (ROM_GROUPMASK | ROM_SKIPMASK | ROM_REVERSEMASK | |
| 184 | | ROM_BITWIDTHMASK | ROM_BITSHIFTMASK | |
| 185 | | ROM_INHERITFLAGSMASK)) | |
| 186 | { | |
| 187 | fatalerror("Unsupported ROM cart flags 0x%08X", flags); | |
| 189 | /* reject any unsupported flags */ | |
| 190 | if (flags & (ROM_GROUPMASK | ROM_SKIPMASK | ROM_REVERSEMASK | |
| 191 | | ROM_BITWIDTHMASK | ROM_BITSHIFTMASK | |
| 192 | | ROM_INHERITFLAGSMASK)) | |
| 193 | { | |
| 194 | fatalerror("Unsupported ROM cart flags 0x%08X", flags); | |
| 195 | } | |
| 196 | ||
| 197 | count = MAX(position + 1, count); | |
| 198 | must_be_loaded = (flags & ROM_OPTIONAL) ? 0 : 1; | |
| 188 | 199 | } |
| 189 | ||
| 190 | count = MAX(position + 1, count); | |
| 191 | must_be_loaded = (flags & ROM_OPTIONAL) ? 0 : 1; | |
| 200 | roment++; | |
| 192 | 201 | } |
| 193 | roment++; | |
| 194 | 202 | } |
| 195 | romrgn = rom_next_region(romrgn); | |
| 196 | 203 | } |
| 197 | 204 | |
| 198 | 205 | switch(state) |
| r3232 | r3233 | |
| 219 | 226 | strcpy(info->s, file_extensions); |
| 220 | 227 | break; |
| 221 | 228 | } |
| 229 | machine_config_free(config); | |
| 222 | 230 | } |
| r3232 | r3233 | |
|---|---|---|
| 138 | 138 | dev_cdrom_t *cdrom = get_safe_token( device ); |
| 139 | 139 | |
| 140 | 140 | cdrom->cdrom_handle = NULL; |
| 141 | return DEVICE_START_OK; | |
| 141 | 142 | } |
| 142 | 143 | |
| 143 | 144 |
| r3232 | r3233 | |
|---|---|---|
| 261 | 261 | { |
| 262 | 262 | image_alloctag(device, FLOPPY_TAG, sizeof(mess_flopimg)); |
| 263 | 263 | floppy_drive_init(device, &mess_floppy_interface); |
| 264 | return DEVICE_START_OK; | |
| 264 | 265 | } |
| 265 | 266 | |
| 266 | 267 |
| r3232 | r3233 | |
|---|---|---|
| 74 | 74 | static DEVICE_START( dsk_floppy ) |
| 75 | 75 | { |
| 76 | 76 | floppy_drive_init(device, NULL); |
| 77 | return DEVICE_START_OK; | |
| 77 | 78 | } |
| 78 | 79 | |
| 79 | 80 |
| r3232 | r3233 | |
|---|---|---|
| 284 | 284 | |
| 285 | 285 | parent_init = (device_start_func) mess_device_get_info_fct(&parent_devclass, MESS_DEVINFO_PTR_START); |
| 286 | 286 | parent_init(device); |
| 287 | return DEVICE_START_OK; | |
| 287 | 288 | } |
| 288 | 289 | |
| 289 | 290 |
| r3232 | r3233 | |
|---|---|---|
| 87 | 87 | DEVICE_START( basicdsk_floppy ) |
| 88 | 88 | { |
| 89 | 89 | floppy_drive_init(device, &basicdsk_floppy_interface); |
| 90 | return DEVICE_START_OK; | |
| 90 | 91 | } |
| 91 | 92 | |
| 92 | 93 | /* attempt to insert a disk into the drive specified with id */ |
| r3232 | r3233 | |
|---|---|---|
| 48 | 48 | |
| 49 | 49 | static DEVICE_START(printer) |
| 50 | 50 | { |
| 51 | return DEVICE_START_OK; | |
| 51 | 52 | } |
| 52 | 53 | |
| 53 | 54 |
| r3232 | r3233 | |
|---|---|---|
| 96 | 96 | { |
| 97 | 97 | vhd_info *vhd = get_safe_token(device); |
| 98 | 98 | vhd->status = VHDSTATUS_NO_VHD_ATTACHED; |
| 99 | return DEVICE_START_OK; | |
| 99 | 100 | } |
| 100 | 101 | |
| 101 | 102 |
| r3232 | r3233 | |
|---|---|---|
| 93 | 93 | bi->value = config->initial_value; |
| 94 | 94 | bi->timeout_timer = timer_alloc(bitbanger_overthreshhold, (void *) device); |
| 95 | 95 | bi->over_threshhold = 1; |
| 96 | return DEVICE_START_OK; | |
| 96 | 97 | } |
| 97 | 98 | |
| 98 | 99 |
| r3232 | r3233 | |
|---|---|---|
| 105 | 105 | |
| 106 | 106 | /* locate the load function */ |
| 107 | 107 | token->load = (snapquick_load_func) device_get_info_fct(device, DEVINFO_FCT_SNAPSHOT_QUICKLOAD_LOAD); |
| 108 | return DEVICE_START_OK; | |
| 108 | 109 | } |
| 109 | 110 | |
| 110 | 111 |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | #include "inptport.h" |
| 14 | 14 | #include "mame.h" |
| 15 | 15 | |
| 16 | #include "deprecat.h" | |
| 17 | 16 | #include "debug/debugcon.h" |
| 18 | 17 | |
| 19 | 18 | |
| r3232 | r3233 | |
| 634 | 633 | |
| 635 | 634 | |
| 636 | 635 | /* Debugging commands and handlers. */ |
| 637 | static void execute_input(int ref, int params, const char *param[]); | |
| 638 | static void execute_dumpkbd(int ref, int params, const char *param[]); | |
| 636 | static void execute_input(running_machine *machine, int ref, int params, const char *param[]); | |
| 637 | static void execute_dumpkbd(running_machine *machine, int ref, int params, const char *param[]); | |
| 639 | 638 | |
| 640 | 639 | |
| 641 | 640 | |
| r3232 | r3233 | |
| 669 | 668 | |
| 670 | 669 | if (machine->debug_flags & DEBUG_FLAG_ENABLED) |
| 671 | 670 | { |
| 672 | debug_console_register_command("input", CMDFLAG_NONE, 0, 1, 1, execute_input); | |
| 673 | debug_console_register_command("dumpkbd", CMDFLAG_NONE, 0, 0, 1, execute_dumpkbd); | |
| 671 | debug_console_register_command(machine, "input", CMDFLAG_NONE, 0, 1, 1, execute_input); | |
| 672 | debug_console_register_command(machine, "dumpkbd", CMDFLAG_NONE, 0, 0, 1, execute_dumpkbd); | |
| 674 | 673 | } |
| 675 | 674 | |
| 676 | 675 | /* posting keys directly only makes sense for a computer */ |
| r3232 | r3233 | |
| 1511 | 1510 | natural keyboard input |
| 1512 | 1511 | -------------------------------------------------*/ |
| 1513 | 1512 | |
| 1514 | static void execute_input(int ref, int params, const char *param[]) | |
| 1513 | static void execute_input(running_machine *machine, int ref, int params, const char *param[]) | |
| 1515 | 1514 | { |
| 1516 | inputx_post_coded( | |
| 1515 | inputx_post_coded(machine, param[0]); | |
| 1517 | 1516 | } |
| 1518 | 1517 | |
| 1519 | 1518 | |
| r3232 | r3233 | |
| 1523 | 1522 | keyboard codes |
| 1524 | 1523 | -------------------------------------------------*/ |
| 1525 | 1524 | |
| 1526 | static void execute_dumpkbd(int ref, int params, const char *param[]) | |
| 1525 | static void execute_dumpkbd(running_machine *machine, int ref, int params, const char *param[]) | |
| 1527 | 1526 | { |
| 1528 | 1527 | const char *filename; |
| 1529 | 1528 | FILE *file = NULL; |
| r3232 | r3233 | |
|---|---|---|
| 238 | 238 | menu_confirm_save_as_populate(machine, menu, state); |
| 239 | 239 | |
| 240 | 240 | /* process the menu */ |
| 241 | event = ui_menu_process(menu, 0); | |
| 241 | event = ui_menu_process(machine, menu, 0); | |
| 242 | 242 | |
| 243 | 243 | /* process the event */ |
| 244 | 244 | if ((event != NULL) && (event->iptkey == IPT_UI_SELECT)) |
| r3232 | r3233 | |
| 445 | 445 | else |
| 446 | 446 | { |
| 447 | 447 | /* process the menu */ |
| 448 | event = ui_menu_process(menu, 0); | |
| 448 | event = ui_menu_process(machine, menu, 0); | |
| 449 | 449 | } |
| 450 | 450 | |
| 451 | 451 | /* process the event */ |
| r3232 | r3233 | |
| 787 | 787 | } |
| 788 | 788 | |
| 789 | 789 | /* process the menu */ |
| 790 | event = ui_menu_process(menu, 0); | |
| 790 | event = ui_menu_process(machine, menu, 0); | |
| 791 | 791 | if (event != NULL && event->itemref != NULL) |
| 792 | 792 | { |
| 793 | 793 | /* handle selections */ |
| r3232 | r3233 | |
| 961 | 961 | menustate->selected_device = (const device_config *) ui_menu_get_selection(menu); |
| 962 | 962 | |
| 963 | 963 | /* process the menu */ |
| 964 | event = ui_menu_process(menu, 0); | |
| 964 | event = ui_menu_process(machine, menu, 0); | |
| 965 | 965 | if (event != NULL && event->iptkey == IPT_UI_SELECT) |
| 966 | 966 | { |
| 967 | 967 | menustate->selected_device = (const device_config *) event->itemref; |
| r3232 | r3233 | |
|---|---|---|
| 787 | 787 | thom_qdd_compute_map(); |
| 788 | 788 | thom_floppy_reset( thom_floppy_drive_of_image( device ) ); |
| 789 | 789 | floppy_drive_init( device, &thom_floppy_interface ); |
| 790 | return DEVICE_START_OK; | |
| 790 | 791 | } |
| 791 | 792 | |
| 792 | 793 |
| r3232 | r3233 | |
|---|---|---|
| 619 | 619 | { |
| 620 | 620 | |
| 621 | 621 | cursor_field = get_field(my_cursor->rawbounds.x0,my_cursor->rawbounds.y0, MOUSE_MOVE); |
| 622 | if ( strcmp((char *)cursor_field.piece, "0") && (strcmp((char *)cursor_field.piece, EMP)) && strcmp(my_cursor->name, (char *)cursor_field.piece ) ) | |
| 622 | if ( strcmp((char *)cursor_field.piece, "0") && (strcmp((char *)cursor_field.piece, EMP)) && strcmp(my_cursor->output_name, (char *)cursor_field.piece ) ) | |
| 623 | 623 | { |
| 624 | 624 | update_board(my_target,cursor_field, 0); |
| 625 | 625 | |
| r3232 | r3233 | |
| 639 | 639 | save_y = my_cursor->rawbounds.y0; |
| 640 | 640 | |
| 641 | 641 | cursor_field = get_field(my_cursor->rawbounds.x0,my_cursor->rawbounds.y0, MOUSE_MOVE); |
| 642 | if ( strcmp((char *)cursor_field.piece, "0") && strcmp(my_cursor->name, "CURSOR_1") ) | |
| 642 | if ( strcmp((char *)cursor_field.piece, "0") && strcmp(my_cursor->output_name, "CURSOR_1") ) | |
| 643 | 643 | { |
| 644 | 644 | |
| 645 | 645 | // Put piece back to board |
| 646 | 646 | // |
| 647 | strcpy((char *)cursor_field.piece, (char *)my_cursor->name); | |
| 647 | strcpy((char *)cursor_field.piece, (char *)my_cursor->output_name); | |
| 648 | 648 | update_board(my_target,cursor_field, 1); |
| 649 | 649 | my_cursor->color.a = 1; |
| 650 | 650 | |
| r3232 | r3233 | |
| 704 | 704 | |
| 705 | 705 | // change cursor to piece |
| 706 | 706 | // |
| 707 | piece = get_non_set_pieces(my_cursor->name); | |
| 707 | piece = get_non_set_pieces(my_cursor->output_name); | |
| 708 | 708 | |
| 709 | 709 | if (strcmp(piece,NO_PIECE)) |
| 710 | 710 | { |
| r3232 | r3233 | |
| 1028 | 1028 | |
| 1029 | 1029 | for (; cur_view != NULL; cur_view = cur_view->next) |
| 1030 | 1030 | { |
| 1031 | if (!strcmp(cur_view->name, v_name)) | |
| 1031 | if (!strcmp(cur_view->output_name, v_name)) | |
| 1032 | 1032 | { |
| 1033 | 1033 | return (cur_view); |
| 1034 | 1034 | } |
| r3232 | r3233 | |
|---|---|---|
| 25 | 25 | /* Memory Maps */ |
| 26 | 26 | |
| 27 | 27 | static ADDRESS_MAP_START( program_map, ADDRESS_SPACE_PROGRAM, 8 ) |
| 28 | AM_RANGE(0x0000, 0x03ff) AM_ROMBANK( | |
| 28 | AM_RANGE(0x0000, 0x03ff) AM_ROMBANK(1 | |
| 29 | 29 | AM_RANGE(0x0400, 0x0fff) AM_ROM |
| 30 | 30 | ADDRESS_MAP_END |
| 31 | 31 |
| r3232 | r3233 | |
|---|---|---|
| 171 | 171 | |
| 172 | 172 | static DEVICE_START( apexc_tape ) |
| 173 | 173 | { |
| 174 | return DEVICE_START_OK; | |
| 174 | 175 | } |
| 175 | 176 | |
| 176 | 177 |
| r3232 | r3233 | |
|---|---|---|
| 542 | 542 | static DEVICE_START( a2600_cart ) |
| 543 | 543 | { |
| 544 | 544 | banking_mode = 0xFF; |
| 545 | return DEVICE_START_OK; | |
| 545 | 546 | } |
| 546 | 547 | |
| 547 | 548 |
| r3232 | r3233 | |
|---|---|---|
| 64 | 64 | |
| 65 | 65 | static DEVICE_START(gamepock_cart) { |
| 66 | 66 | memory_set_bankptr( 1, memory_region(device->machine, "user1" ) ); |
| 67 | return DEVICE_START_OK; | |
| 67 | 68 | } |
| 68 | 69 | |
| 69 | 70 | static DEVICE_IMAGE_LOAD(gamepock_cart) { |
| r3232 | r3233 | |
|---|---|---|
| 13 | 13 | LDPSRC = $(SRC)/ldplayer |
| 14 | 14 | LDPOBJ = $(OBJ)/ldplayer |
| 15 | 15 | |
| 16 | LAYOUT = $(LDPOBJ)/layout | |
| 17 | ||
| 16 | 18 | OBJDIRS += \ |
| 17 | 19 | $(LDPOBJ) \ |
| 20 | $(LAYOUT) \ | |
| 18 | 21 | |
| 19 | 22 | |
| 20 | 23 | |
| r3232 | r3233 | |
| 42 | 45 | DRVLIBS = \ |
| 43 | 46 | $(LDPOBJ)/ldpdriv.o \ |
| 44 | 47 | $(LDPOBJ)/ldplayer.o \ |
| 48 | ||
| 49 | ||
| 50 | #------------------------------------------------- | |
| 51 | # layout dependencies | |
| 52 | #------------------------------------------------- | |
| 53 | ||
| 54 | $(LDPOBJ)/ldplayer.o: $(LAYOUT)/pr8210.lh \ |
| r0 | r3233 | |
|---|---|---|
| 1 | <?xml version="1.0"?> | |
| 2 | <mamelayout version="2"> | |
| 3 | <element name="audio1" defstate="0"> | |
| 4 | <text string="AUDIO1" state="0"> | |
| 5 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 6 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 7 | </text> | |
| 8 | <text string="AUDIO1" state="1"> | |
| 9 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 10 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 11 | </text> | |
| 12 | </element> | |
| 13 | ||
| 14 | <element name="audio2" defstate="0"> | |
| 15 | <text string="AUDIO2" state="0"> | |
| 16 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 17 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 18 | </text> | |
| 19 | <text string="AUDIO2" state="1"> | |
| 20 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 21 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 22 | </text> | |
| 23 | </element> | |
| 24 | ||
| 25 | <element name="clv" defstate="0"> | |
| 26 | <text string="CLV" state="0"> | |
| 27 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 28 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 29 | </text> | |
| 30 | <text string="CLV" state="1"> | |
| 31 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 32 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 33 | </text> | |
| 34 | </element> | |
| 35 | ||
| 36 | <element name="cav" defstate="0"> | |
| 37 | <text string="CAV" state="0"> | |
| 38 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 39 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 40 | </text> | |
| 41 | <text string="CAV" state="1"> | |
| 42 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 43 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 44 | </text> | |
| 45 | </element> | |
| 46 | ||
| 47 | <element name="led1" defstate="0"> | |
| 48 | <text string="LED1" state="0"> | |
| 49 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 50 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 51 | </text> | |
| 52 | <text string="LED1" state="1"> | |
| 53 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 54 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 55 | </text> | |
| 56 | </element> | |
| 57 | ||
| 58 | <element name="led2" defstate="0"> | |
| 59 | <text string="LED2" state="0"> | |
| 60 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 61 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 62 | </text> | |
| 63 | <text string="LED2" state="1"> | |
| 64 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 65 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 66 | </text> | |
| 67 | </element> | |
| 68 | ||
| 69 | <element name="led3" defstate="0"> | |
| 70 | <text string="LED3" state="0"> | |
| 71 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 72 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 73 | </text> | |
| 74 | <text string="LED3" state="1"> | |
| 75 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 76 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 77 | </text> | |
| 78 | </element> | |
| 79 | ||
| 80 | <element name="standby" defstate="0"> | |
| 81 | <text string="STANDBY" state="0"> | |
| 82 | <color red="0.1" green="0.1" blue="0.1" /> | |
| 83 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 84 | </text> | |
| 85 | <text string="STANDBY" state="1"> | |
| 86 | <color red="1.0" green="1.0" blue="1.0" /> | |
| 87 | <bounds x="0" y="0.1" width="1" height="0.8" /> | |
| 88 | </text> | |
| 89 | </element> | |
| 90 | ||
| 91 | ||
| 92 | <view name="Lamps"> | |
| 93 | <screen index="0"> | |
| 94 | <bounds left="0" top="0" right="4" bottom="3" /> | |
| 95 | </screen> | |
| 96 | <bezel name="pr8210_standby" element="standby"> | |
| 97 | <bounds x="0" y="3.1" width="0.4" height="0.1" /> | |
| 98 | </bezel> | |
| 99 | <bezel name="pr8210_clv" element="clv"> | |
| 100 | <bounds x="0.5" y="3.1" width="0.4" height="0.1" /> | |
| 101 | </bezel> | |
| 102 | <bezel name="pr8210_cav" element="cav"> | |
| 103 | <bounds x="1.0" y="3.1" width="0.4" height="0.1" /> | |
| 104 | </bezel> | |
| 105 | <bezel name="pr8210_audio1" element="audio1"> | |
| 106 | <bounds x="1.5" y="3.1" width="0.4" height="0.1" /> | |
| 107 | </bezel> | |
| 108 | <bezel name="pr8210_audio2" element="audio2"> | |
| 109 | <bounds x="2.0" y="3.1" width="0.4" height="0.1" /> | |
| 110 | </bezel> | |
| 111 | <bezel name="pr8210_led1" element="led1"> | |
| 112 | <bounds x="2.5" y="3.1" width="0.4" height="0.1" /> | |
| 113 | </bezel> | |
| 114 | <bezel name="pr8210_led2" element="led2"> | |
| 115 | <bounds x="3.0" y="3.1" width="0.4" height="0.1" /> | |
| 116 | </bezel> | |
| 117 | <bezel name="pr8210_led3" element="led3"> | |
| 118 | <bounds x="3.5" y="3.1" width="0.4" height="0.1" /> | |
| 119 | </bezel> | |
| 120 | </view> | |
| 121 | </mamelayout> |
| r3232 | r3233 | |
|---|---|---|
| 15 | 15 | #include "machine/laserdsc.h" |
| 16 | 16 | #include <ctype.h> |
| 17 | 17 | |
| 18 | #include "pr8210.lh" | |
| 18 | 19 | |
| 19 | #define TEST_PR8210_ROM 0 | |
| 20 | 20 | |
| 21 | 21 | |
| 22 | ||
| 23 | 22 | /************************************* |
| 24 | 23 | * |
| 25 | 24 | * Constants |
| r3232 | r3233 | |
| 63 | 62 | static UINT8 playing; |
| 64 | 63 | static UINT8 displaying; |
| 65 | 64 | |
| 66 | static UINT8 pr8210_last_was_number; | |
| 67 | 65 | static emu_timer *pr8210_bit_timer; |
| 68 | 66 | static UINT32 pr8210_command_buffer_in, pr8210_command_buffer_out; |
| 69 | 67 | static UINT8 pr8210_command_buffer[10]; |
| 70 | 68 | |
| 71 | 69 | static void (*execute_command)(const device_config *laserdisc, int command); |
| 72 | 70 | |
| 73 | #if TEST_PR8210_ROM | |
| 74 | 71 | |
| 75 | static UINT8 pia[0x100]; | |
| 76 | static UINT8 pr8210_porta; | |
| 77 | static UINT8 pr8210_portb; | |
| 78 | static UINT8 pr8210_pia_porta; | |
| 79 | static UINT8 pr8210_pia_portb; | |
| 80 | 72 | |
| 81 | #endif | |
| 82 | ||
| 83 | ||
| 84 | ||
| 85 | 73 | /************************************* |
| 86 | 74 | * |
| 87 | 75 | * Timers and sync |
| r3232 | r3233 | |
| 152 | 140 | |
| 153 | 141 | /* handle commands */ |
| 154 | 142 | if (!param) |
| 155 | { | |
| 156 | 143 | process_commands(laserdisc); |
| 157 | 144 | |
| 158 | /* update the laserdisc */ | |
| 159 | laserdisc_vsync(laserdisc); | |
| 160 | } | |
| 161 | ||
| 162 | 145 | /* set a timer to go off on the next VBLANK */ |
| 163 | 146 | vblank_scanline = video_screen_get_visible_area(machine->primary_screen)->max_y + 1; |
| 164 | 147 | target = video_screen_get_time_until_pos(machine->primary_screen, vblank_scanline, 0); |
| r3232 | r3233 | |
| 241 | 224 | else if (bitsleft == 0 && pr8210_command_buffer_in != pr8210_command_buffer_out) |
| 242 | 225 | { |
| 243 | 226 | data = pr8210_command_buffer[pr8210_command_buffer_out++ % ARRAY_LENGTH(pr8210_command_buffer)]; |
| 244 | #if TEST_PR8210_ROM | |
| 245 | pr8210_pia_porta = BITSWAP8(data, 0,1,2,3,4,5,6,7); | |
| 246 | #else | |
| 247 | 227 | bitsleft = 12; |
| 248 | #endif | |
| 249 | 228 | } |
| 250 | 229 | timer_adjust_oneshot(pr8210_bit_timer, duration, (bitsleft << 16) | data); |
| 251 | 230 | } |
| r3232 | r3233 | |
| 269 | 248 | static void pr8210_execute(const device_config *laserdisc, int command) |
| 270 | 249 | { |
| 271 | 250 | static const UINT8 digits[10] = { 0x01, 0x11, 0x09, 0x19, 0x05, 0x15, 0x0d, 0x1d, 0x03, 0x13 }; |
| 272 | int prev_was_number = pr8210_last_was_number; | |
| 273 | 251 | |
| 274 | pr8210_last_was_number = FALSE; | |
| 275 | 252 | switch (command) |
| 276 | 253 | { |
| 277 | 254 | case CMD_SCAN_REVERSE: |
| r3232 | r3233 | |
| 311 | 288 | break; |
| 312 | 289 | |
| 313 | 290 | case CMD_DISPLAY_ON: |
| 314 | // pr8210_add_command(digits[1]); | |
| 315 | // pr8210_add_command(0xf1); | |
| 316 | break; | |
| 317 | ||
| 318 | 291 | case CMD_DISPLAY_OFF: |
| 319 | // pr8210_add_command(digits[0]); | |
| 320 | // pr8210_add_command(0xf1); | |
| 292 | pr8210_add_command(0x0b); | |
| 321 | 293 | break; |
| 322 | 294 | |
| 323 | 295 | case CMD_0: |
| r3232 | r3233 | |
| 330 | 302 | case CMD_7: |
| 331 | 303 | case CMD_8: |
| 332 | 304 | case CMD_9: |
| 333 | if (!prev_was_number) | |
| 334 | pr8210_add_command(0x1a); | |
| 335 | 305 | pr8210_add_command(digits[command - CMD_0]); |
| 336 | pr8210_last_was_number = TRUE; | |
| 337 | 306 | break; |
| 338 | 307 | |
| 339 | 308 | case CMD_SEARCH: |
| r3232 | r3233 | |
| 449 | 418 | |
| 450 | 419 | /************************************* |
| 451 | 420 | * |
| 452 | * Test PR-8210 ROM emulation | |
| 453 | * | |
| 454 | *************************************/ | |
| 455 | ||
| 456 | #if TEST_PR8210_ROM | |
| 457 | ||
| 458 | static READ8_HANDLER( pr8210_pia_r ) | |
| 459 | { | |
| 460 | UINT8 result = pia[offset]; | |
| 461 | switch (offset) | |
| 462 | { | |
| 463 | case 0xa0: | |
| 464 | // printf("%03X:pia_r(%02X) = %02X\n", activecpu_get_pc(), offset, pr8210_pia_porta); | |
| 465 | result = pr8210_pia_porta; | |
| 466 | pr8210_pia_porta = 0; | |
| 467 | break; | |
| 468 | ||
| 469 | default: | |
| 470 | printf("%03X:pia_r(%02X)\n", activecpu_get_pc(), offset); | |
| 471 | break; | |
| 472 | } | |
| 473 | return result; | |
| 474 | } | |
| 475 | ||
| 476 | static WRITE8_HANDLER( pr8210_pia_w ) | |
| 477 | { | |
| 478 | /* | |
| 479 | $22-26 (R) = read and copied to memory $23-27 | |
| 480 | $23 (R) = something compared against $F4 | |
| 481 | $22-26 (W) = SRCH. text | |
| 482 | $27-2B (W) = FRAME/CHAP. text | |
| 483 | $2C-30 (W) = frame or chapter number | |
| 484 | $40 (W) = $CF at initialization, tracked by ($78) | |
| 485 | $60 (W) = port B output, tracked by ($77) | |
| 486 | $80 = n/c | |
| 487 | $40 = (out) LED3 | |
| 488 | $20 = (out) LED2 | |
| 489 | $10 = (out) LED1 | |
| 490 | 123 -> LHL = Play | |
| 491 | -> HLL = Slow fwd | |
| 492 | -> LLL = Slow rev | |
| 493 | -> HHL = Still | |
| 494 | -> LLH = Pause | |
| 495 | -> HHH = all off | |
| 496 | $08 = (out) CAV LED | |
| 497 | $04 = (out) CLV LED | |
| 498 | $02 = (out) A2 LED/AUDIO 2 | |
| 499 | $01 = (out) A1 LED/AUDIO 1 | |
| 500 | $80 (W) = 0 or 1 | |
| 501 | $A0 (R) = port A input | |
| 502 | $C0 (R) = stored to ($2E) | |
| 503 | $E0 (R) = stored to ($2F) | |
| 504 | */ | |
| 505 | if (pia[offset] != data) | |
| 506 | { | |
| 507 | switch (offset) | |
| 508 | { | |
| 509 | case 0x60: | |
| 510 | printf("%03X:pia_w(%02X) = %02X (PORT B LEDS:", activecpu_get_pc(), offset, data); | |
| 511 | if (!(data & 0x01)) printf(" AUDIO1"); | |
| 512 | if (!(data & 0x02)) printf(" AUDIO2"); | |
| 513 | if (!(data & 0x04)) printf(" CLV"); | |
| 514 | if (!(data & 0x08)) printf(" CAV"); | |
| 515 | printf(" LED123=%c%c%c", (data & 0x10) ? 'H' : 'L', (data & 0x20) ? 'H' : 'L', (data & 0x40) ? 'H' : 'L'); | |
| 516 | if (!(data & 0x80)) printf(" ???"); | |
| 517 | printf(")\n"); | |
| 518 | pr8210_pia_portb = data; | |
| 519 | break; | |
| 520 | ||
| 521 | default: | |
| 522 | printf("%03X:pia_w(%02X) = %02X\n", activecpu_get_pc(), offset, data); | |
| 523 | break; | |
| 524 | } | |
| 525 | pia[offset] = data; | |
| 526 | } | |
| 527 | } | |
| 528 | ||
| 529 | static READ8_HANDLER( pr8210_bus_r ) | |
| 530 | { | |
| 531 | /* | |
| 532 | $80 = n/c | |
| 533 | $40 = (in) slide pot interrupt source (slider position limit detector, inside and outside) | |
| 534 | $20 = n/c | |
| 535 | $10 = (in) /FOCUS LOCK | |
| 536 | $08 = (in) /SPDL LOCK | |
| 537 | $04 = (in) SIZE 8/12 | |
| 538 | $02 = (in) FG via op-amp (spindle motor stop detector) | |
| 539 | $01 = (in) SLOW TIMER OUT | |
| 540 | */ | |
| 541 | offs_t pc = activecpu_get_pc(); | |
| 542 | if (pc != 0x11c) | |
| 543 | printf("%03X:bus_r\n", pc); | |
| 544 | ||
| 545 | /* loop at beginning waits for $40=0, $02=1 */ | |
| 546 | return 0xff & ~0x40 & ~0x04; | |
| 547 | } | |
| 548 | ||
| 549 | static WRITE8_HANDLER( pr8210_porta_w ) | |
| 550 | { | |
| 551 | /* | |
| 552 | $80 = (out) SCAN C (F/R) | |
| 553 | $40 = (out) AUDIO SQ | |
| 554 | $20 = (out) VIDEO SQ | |
| 555 | $10 = (out) /SPDL ON | |
| 556 | $08 = (out) /FOCUS ON | |
| 557 | $04 = (out) SCAN B (L/H) | |
| 558 | $02 = (out) SCAN A (/SCAN) | |
| 559 | $01 = (out) JUMP TRG (jump back trigger, clock on high->low) | |
| 560 | */ | |
| 561 | if (data != pr8210_porta) | |
| 562 | { | |
| 563 | printf("%03X:porta_w = %02X", activecpu_get_pc(), data); | |
| 564 | if (!(data & 0x01)) printf(" JUMPTRG"); | |
| 565 | if (!(data & 0x02)) | |
| 566 | { | |
| 567 | printf(" SCAN:%c:%c", (data & 0x80) ? 'F' : 'R', (data & 0x04) ? 'L' : 'H'); | |
| 568 | } | |
| 569 | if (!(data & 0x08)) printf(" /FOCUSON"); | |
| 570 | if (!(data & 0x10)) printf(" /SPDLON"); | |
| 571 | if (data & 0x20) printf(" VIDEOSQ"); | |
| 572 | if (data & 0x40) printf(" AUDIOSQ"); | |
| 573 | printf("\n"); | |
| 574 | pr8210_porta = data; | |
| 575 | } | |
| 576 | } | |
| 577 | ||
| 578 | static WRITE8_HANDLER( pr8210_portb_w ) | |
| 579 | { | |
| 580 | /* | |
| 581 | $80 = (out) /CS on PIA | |
| 582 | $40 = (out) 0 to self-generate IRQ | |
| 583 | $20 = (out) SLOW TRG | |
| 584 | $10 = (out) STANDBY LED | |
| 585 | $08 = (out) TP2 | |
| 586 | $04 = (out) TP1 | |
| 587 | $02 = (out) ??? | |
| 588 | $01 = (out) LASER ON | |
| 589 | */ | |
| 590 | cputag_set_input_line(machine, "pr8210", 0, (data & 0x40) ? CLEAR_LINE : ASSERT_LINE); | |
| 591 | if ((data & 0x7f) != (pr8210_portb & 0x7f)) | |
| 592 | { | |
| 593 | printf("%03X:portb_w = %02X", activecpu_get_pc(), data); | |
| 594 | if (!(data & 0x01)) printf(" LASERON"); | |
| 595 | if (!(data & 0x02)) printf(" ???"); | |
| 596 | if (!(data & 0x04)) printf(" TP1"); | |
| 597 | if (!(data & 0x08)) printf(" TP2"); | |
| 598 | if (!(data & 0x10)) printf(" STANDBYLED"); | |
| 599 | if (!(data & 0x20)) printf(" SLOWTRG"); | |
| 600 | if (!(data & 0x40)) printf(" IRQGEN"); | |
| 601 | // if (data & 0x80) printf(" PIASEL"); | |
| 602 | printf("\n"); | |
| 603 | pr8210_portb = data; | |
| 604 | } | |
| 605 | } | |
| 606 | ||
| 607 | ||
| 608 | static ADDRESS_MAP_START( pr8210_portmap, ADDRESS_SPACE_IO, 8 ) | |
| 609 | AM_RANGE(0x00, 0xff) AM_READWRITE(pr8210_pia_r, pr8210_pia_w) | |
| 610 | AM_RANGE(MCS48_PORT_BUS, MCS48_PORT_BUS) AM_READ(pr8210_bus_r) | |
| 611 | AM_RANGE(MCS48_PORT_P1, MCS48_PORT_P1) AM_WRITE(pr8210_porta_w) | |
| 612 | AM_RANGE(MCS48_PORT_P2, MCS48_PORT_P2) AM_WRITE(pr8210_portb_w) | |
| 613 | ADDRESS_MAP_END | |
| 614 | ||
| 615 | #endif | |
| 616 | ||
| 617 | ||
| 618 | ||
| 619 | /************************************* | |
| 620 | * | |
| 621 | 421 | * Machine drivers |
| 622 | 422 | * |
| 623 | 423 | *************************************/ |
| r3232 | r3233 | |
| 630 | 430 | /* audio hardware */ |
| 631 | 431 | MDRV_SPEAKER_STANDARD_STEREO("left", "right") |
| 632 | 432 | |
| 633 | MDRV_SOUND_ADD("l | |
| 433 | MDRV_SOUND_ADD("l | |
| 634 | 434 | MDRV_SOUND_CONFIG(laserdisc_custom_interface) |
| 635 | 435 | MDRV_SOUND_ROUTE(0, "left", 1.0) |
| 636 | 436 | MDRV_SOUND_ROUTE(1, "right", 1.0) |
| r3232 | r3233 | |
| 645 | 445 | |
| 646 | 446 | static MACHINE_DRIVER_START( ldv1000 ) |
| 647 | 447 | MDRV_IMPORT_FROM(ldplayer_ntsc) |
| 648 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000) | |
| 448 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_LDV1000, "main", "ldsound") | |
| 649 | 449 | MACHINE_DRIVER_END |
| 650 | 450 | |
| 651 | 451 | |
| r3232 | r3233 | |
| 653 | 453 | MDRV_IMPORT_FROM(ldplayer_ntsc) |
| 654 | 454 | MDRV_MACHINE_START(pr8210) |
| 655 | 455 | MDRV_MACHINE_RESET(pr8210) |
| 656 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210) | |
| 657 | ||
| 658 | #if TEST_PR8210_ROM | |
| 659 | MDRV_CPU_ADD("pr8210", I8049, XTAL_4_41MHz) | |
| 660 | MDRV_CPU_IO_MAP(pr8210_portmap,0) | |
| 661 | #endif | |
| 456 | MDRV_LASERDISC_ADD("laserdisc", PIONEER_PR8210, "main", "ldsound") | |
| 662 | 457 | MACHINE_DRIVER_END |
| 663 | 458 | |
| 664 | 459 | |
| r3232 | r3233 | |
| 676 | 471 | |
| 677 | 472 | ROM_START( pr8210 ) |
| 678 | 473 | DISK_REGION( "laserdisc" ) |
| 679 | ||
| 680 | #if TEST_PR8210_ROM | |
| 681 | ROM_REGION( 0x800, "pr8210", 0 ) | |
| 682 | ROM_LOAD( "pr-8210_mcu_ud6005a.bin", 0x000, 0x800, CRC(120fa83b) SHA1(b514326ca1f52d6d89056868f9d17eabd4e3f31d) ) | |
| 683 | #endif | |
| 684 | 474 | ROM_END |
| 685 | 475 | |
| 686 | 476 | |
| r3232 | r3233 | |
| 766 | 556 | *************************************/ |
| 767 | 557 | |
| 768 | 558 | GAME( 2008, ldv1000, 0, ldv1000, ldplayer, ldv1000, ROT0, "MAME", "Pioneer LDV-1000 Simulator", 0 ) |
| 769 | GAME( 2008, pr8210, 0, pr8210, ldplayer, pr8210, ROT0, "MAME", "Pioneer PR-8210 Simulator", 0 ) | |
| 559 | GAMEL( 2008, pr8210, 0, pr8210, ldplayer, pr8210, ROT0, "MAME", "Pioneer PR-8210 Simulator", 0, layout_pr8210 ) |
| r3232 | r3233 | |
|---|---|---|
| 140 | 140 | |
| 141 | 141 | Source Changes: |
| 142 | 142 | ---------------- |
| 143 | - The core is based on MAME 0.127u | |
| 143 | - The core is based on MAME 0.127u3. This incorporates all features of the | |
| 144 | 144 | update to this core. [MAME team] |
| 145 | 145 | |
| 146 | 146 | - Refactored ZIP path code out of src/mess/image.c, made more testable. [Nate |
| Previous | 15994 Revisions | Next |