| Previous | 199869 Revisions | Next |
| r22720 Thursday 9th May, 2013 at 12:41:18 UTC by smf |
|---|
| finished modernizing timekeeper [smf] |
| [src/emu/machine] | timekpr.c timekpr.h |
| [src/mame/drivers] | cdi.c cobra.c cps1.c hornet.c itech32.c ksys573.c midzeus.c multfish.c nwk-tr.c slapshot.c tomcat.c vegas.c viper.c |
| [src/mame/includes] | cps1.h midzeus.h |
| r22719 | r22720 | |
|---|---|---|
| 352 | 352 | } |
| 353 | 353 | } |
| 354 | 354 | |
| 355 | ||
| 355 | WRITE8_MEMBER( timekeeper_device::write ) | |
| 356 | 356 | { |
| 357 | 357 | if( offset == m_offset_control ) |
| 358 | 358 | { |
| r22719 | r22720 | |
| 375 | 375 | m_data[ offset ] = data; |
| 376 | 376 | } |
| 377 | 377 | |
| 378 | ||
| 378 | READ8_MEMBER( timekeeper_device::read ) | |
| 379 | 379 | { |
| 380 | 380 | UINT8 result = m_data[ offset ]; |
| 381 | 381 | if( offset == m_offset_date && type() == M48T58 ) |
| r22719 | r22720 | |
| 433 | 433 | { |
| 434 | 434 | file.write( m_data, m_size ); |
| 435 | 435 | } |
| 436 | ||
| 437 | ||
| 438 | ||
| 439 | /*************************************************************************** | |
| 440 | TRAMPOLINES | |
| 441 | ***************************************************************************/ | |
| 442 | ||
| 443 | WRITE8_DEVICE_HANDLER( timekeeper_w ) { downcast<timekeeper_device *>(device)->write(offset, data); } | |
| 444 | READ8_DEVICE_HANDLER( timekeeper_r ) { return downcast<timekeeper_device*>(device)->read(offset); } |
| r22719 | r22720 | |
|---|---|---|
| 64 | 64 | timekeeper_device(const machine_config &mconfig, device_type type, const char *name, const char *tag, device_t *owner, UINT32 clock); |
| 65 | 65 | |
| 66 | 66 | public: |
| 67 | void write(UINT16 offset, UINT8 data); | |
| 68 | UINT8 read(UINT16 offset); | |
| 67 | DECLARE_WRITE8_MEMBER( write ); | |
| 68 | DECLARE_READ8_MEMBER( read ); | |
| 69 | 69 | |
| 70 | 70 | protected: |
| 71 | 71 | // device-level overrides |
| r22719 | r22720 | |
| 147 | 147 | extern const device_type M48T58; |
| 148 | 148 | extern const device_type MK48T08; |
| 149 | 149 | |
| 150 | ||
| 151 | ||
| 152 | //************************************************************************** | |
| 153 | // READ/WRITE HANDLERS | |
| 154 | //************************************************************************** | |
| 155 | ||
| 156 | DECLARE_WRITE8_DEVICE_HANDLER( timekeeper_w ); | |
| 157 | DECLARE_READ8_DEVICE_HANDLER( timekeeper_r ); | |
| 158 | ||
| 159 | 150 | #endif // __TIMEKPR_H__ |
| r22719 | r22720 | |
|---|---|---|
| 31 | 31 | #include "cpu/pic16c5x/pic16c5x.h" |
| 32 | 32 | #include "includes/midzeus.h" |
| 33 | 33 | #include "machine/midwayic.h" |
| 34 | #include "machine/timekpr.h" | |
| 35 | 34 | #include "audio/dcs.h" |
| 36 | 35 | #include "machine/nvram.h" |
| 37 | 36 | |
| r22719 | r22720 | |
| 153 | 152 | |
| 154 | 153 | READ32_MEMBER(midzeus_state::zeus2_timekeeper_r) |
| 155 | 154 | { |
| 156 | device_t *device = machine().device("m48t35"); | |
| 157 | return timekeeper_r(device, space, offset) | 0xffffff00; | |
| 155 | return m_m48t35->read(space, offset, 0xff) | 0xffffff00; | |
| 158 | 156 | } |
| 159 | 157 | |
| 160 | ||
| 161 | 158 | WRITE32_MEMBER(midzeus_state::zeus2_timekeeper_w) |
| 162 | 159 | { |
| 163 | device_t *device = machine().device("m48t35"); | |
| 164 | 160 | if (bitlatch[2] && !cmos_protected) |
| 165 | | |
| 161 | m_m48t35->write(space, offset, data, 0xff); | |
| 166 | 162 | else |
| 167 | 163 | logerror("%s:zeus2_timekeeper_w with bitlatch[2] = %d, cmos_protected = %d\n", machine().describe_context(), bitlatch[2], cmos_protected); |
| 168 | 164 | cmos_protected = TRUE; |
| r22719 | r22720 | |
|---|---|---|
| 1996 | 1996 | AM_RANGE(0x78280000, 0x7828000f) AM_MIRROR(0x80000000) AM_NOP // ??? |
| 1997 | 1997 | AM_RANGE(0x78300000, 0x7830000f) AM_MIRROR(0x80000000) AM_READWRITE(sub_psac2_r, sub_psac2_w) // PSAC |
| 1998 | 1998 | AM_RANGE(0x7e000000, 0x7e000003) AM_MIRROR(0x80000000) AM_READWRITE(sub_unk7e_r, sub_debug_w) |
| 1999 | AM_RANGE(0x7e040000, 0x7e041fff) AM_MIRROR(0x80000000) AM_DEVREADWRITE8 | |
| 1999 | AM_RANGE(0x7e040000, 0x7e041fff) AM_MIRROR(0x80000000) AM_DEVREADWRITE8("m48t58", timekeeper_device, read, write, 0xffffffff) /* M48T58Y RTC/NVRAM */ | |
| 2000 | 2000 | AM_RANGE(0x7e180000, 0x7e180003) AM_MIRROR(0x80000000) AM_READWRITE(sub_unk1_r, sub_unk1_w) // TMS57002? |
| 2001 | 2001 | AM_RANGE(0x7e200000, 0x7e200003) AM_MIRROR(0x80000000) AM_READWRITE(sub_config_r, sub_config_w) |
| 2002 | 2002 | AM_RANGE(0x7e280000, 0x7e28ffff) AM_MIRROR(0x80000000) AM_NOP // LANC |
| r22719 | r22720 | |
|---|---|---|
| 618 | 618 | if (state->m_cmos_unlocked) |
| 619 | 619 | { |
| 620 | 620 | if ((mem_mask & 0x000000ff) != 0) |
| 621 | state->m_timekeeper->write(offset * 4 + 0, data >> 0); | |
| 621 | state->m_timekeeper->write(space, offset * 4 + 0, data >> 0, 0xff); | |
| 622 | 622 | if ((mem_mask & 0x0000ff00) != 0) |
| 623 | state->m_timekeeper->write(offset * 4 + 1, data >> 8); | |
| 623 | state->m_timekeeper->write(space, offset * 4 + 1, data >> 8, 0xff); | |
| 624 | 624 | if ((mem_mask & 0x00ff0000) != 0) |
| 625 | state->m_timekeeper->write(offset * 4 + 2, data >> 16); | |
| 625 | state->m_timekeeper->write(space, offset * 4 + 2, data >> 16, 0xff); | |
| 626 | 626 | if ((mem_mask & 0xff000000) != 0) |
| 627 | state->m_timekeeper->write(offset * 4 + 3, data >> 24); | |
| 627 | state->m_timekeeper->write(space, offset * 4 + 3, data >> 24, 0xff); | |
| 628 | 628 | if (offset*4 >= 0x7ff0) |
| 629 | 629 | if (LOG_TIMEKEEPER) logerror("timekeeper_w(%04X & %08X) = %08X\n", offset*4, mem_mask, data); |
| 630 | 630 | state->m_cmos_unlocked = 0; |
| r22719 | r22720 | |
| 639 | 639 | vegas_state *state = space.machine().driver_data<vegas_state>(); |
| 640 | 640 | UINT32 result = 0xffffffff; |
| 641 | 641 | if ((mem_mask & 0x000000ff) != 0) |
| 642 | result = (result & ~0x000000ff) | (state->m_timekeeper->read(offset * 4 + 0) << 0); | |
| 642 | result = (result & ~0x000000ff) | (state->m_timekeeper->read(space, offset * 4 + 0, 0xff) << 0); | |
| 643 | 643 | if ((mem_mask & 0x0000ff00) != 0) |
| 644 | result = (result & ~0x0000ff00) | (state->m_timekeeper->read(offset * 4 + 1) << 8); | |
| 644 | result = (result & ~0x0000ff00) | (state->m_timekeeper->read(space, offset * 4 + 1, 0xff) << 8); | |
| 645 | 645 | if ((mem_mask & 0x00ff0000) != 0) |
| 646 | result = (result & ~0x00ff0000) | (state->m_timekeeper->read(offset * 4 + 2) << 16); | |
| 646 | result = (result & ~0x00ff0000) | (state->m_timekeeper->read(space, offset * 4 + 2, 0xff) << 16); | |
| 647 | 647 | if ((mem_mask & 0xff000000) != 0) |
| 648 | result = (result & ~0xff000000) | (state->m_timekeeper->read(offset * 4 + 3) << 24); | |
| 648 | result = (result & ~0xff000000) | (state->m_timekeeper->read(space, offset * 4 + 3, 0xff) << 24); | |
| 649 | 649 | if (offset*4 >= 0x7ff0) |
| 650 | 650 | if (LOG_TIMEKEEPER) logerror("timekeeper_r(%04X & %08X) = %08X\n", offset*4, mem_mask, result); |
| 651 | 651 | return result; |
| r22719 | r22720 | |
|---|---|---|
| 283 | 283 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_word_r, tc0480scp_word_w) /* tilemaps */ |
| 284 | 284 | AM_RANGE(0x830000, 0x83002f) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_ctrl_word_r, tc0480scp_ctrl_word_w) |
| 285 | 285 | AM_RANGE(0x900000, 0x907fff) AM_READWRITE(color_ram_word_r, color_ram_word_w) AM_SHARE("color_ram") /* 8bpg palette */ |
| 286 | AM_RANGE(0xa00000, 0xa03fff) AM_DEVREADWRITE8 | |
| 286 | AM_RANGE(0xa00000, 0xa03fff) AM_DEVREADWRITE8("mk48t08", timekeeper_device, read, write, 0xff00) /* nvram (only low bytes used) */ | |
| 287 | 287 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) /* priority chip */ |
| 288 | 288 | AM_RANGE(0xc00000, 0xc0000f) AM_DEVREADWRITE_LEGACY("tc0640fio", tc0640fio_halfword_byteswap_r, tc0640fio_halfword_byteswap_w) |
| 289 | 289 | AM_RANGE(0xc00020, 0xc0002f) AM_READ(slapshot_service_input_r) /* service mirror */ |
| r22719 | r22720 | |
| 298 | 298 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_word_r, tc0480scp_word_w) /* tilemaps */ |
| 299 | 299 | AM_RANGE(0x830000, 0x83002f) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_ctrl_word_r, tc0480scp_ctrl_word_w) |
| 300 | 300 | AM_RANGE(0x900000, 0x907fff) AM_READWRITE(color_ram_word_r, color_ram_word_w) AM_SHARE("color_ram") /* 8bpg palette */ |
| 301 | AM_RANGE(0xa00000, 0xa03fff) AM_DEVREADWRITE8 | |
| 301 | AM_RANGE(0xa00000, 0xa03fff) AM_DEVREADWRITE8("mk48t08", timekeeper_device, read, write, 0xff00) /* nvram (only low bytes used) */ | |
| 302 | 302 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) /* priority chip */ |
| 303 | 303 | AM_RANGE(0xc00000, 0xc0000f) AM_DEVREADWRITE_LEGACY("tc0640fio", tc0640fio_halfword_byteswap_r, tc0640fio_halfword_byteswap_w) |
| 304 | 304 | AM_RANGE(0xc00020, 0xc0002f) AM_READ(slapshot_service_input_r) /* service mirror */ |
| r22719 | r22720 | |
|---|---|---|
| 185 | 185 | public: |
| 186 | 186 | multfish_state(const machine_config &mconfig, device_type type, const char *tag) |
| 187 | 187 | : driver_device(mconfig, type, tag), |
| 188 | m_maincpu(*this, "maincpu") { } | |
| 188 | m_maincpu(*this, "maincpu"), | |
| 189 | m_m48t35(*this, "m48t35" ) | |
| 190 | { | |
| 191 | } | |
| 189 | 192 | |
| 190 | 193 | /* Video related */ |
| 191 | 194 | |
| r22719 | r22720 | |
| 248 | 251 | virtual void machine_start(); |
| 249 | 252 | virtual void machine_reset(); |
| 250 | 253 | virtual void video_start(); |
| 251 | DECLARE_MACHINE_RESET(island2a); | |
| 252 | 254 | UINT32 screen_update_multfish(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); |
| 253 | 255 | required_device<cpu_device> m_maincpu; |
| 256 | required_device<timekeeper_device> m_m48t35; | |
| 254 | 257 | }; |
| 255 | 258 | |
| 256 | 259 | TILE_GET_INFO_MEMBER(multfish_state::get_multfish_tile_info) |
| r22719 | r22720 | |
| 377 | 380 | |
| 378 | 381 | READ8_MEMBER(multfish_state::multfish_timekeeper_r) |
| 379 | 382 | { |
| 380 | device_t *device = machine().device("m48t35"); | |
| 381 | return timekeeper_r(device, space, offset + 0x6000); | |
| 383 | return m_m48t35->read(space, offset + 0x6000, 0xff); | |
| 382 | 384 | } |
| 383 | 385 | |
| 384 | 386 | WRITE8_MEMBER(multfish_state::multfish_timekeeper_w) |
| 385 | 387 | { |
| 386 | device_t *device = machine().device("m48t35"); | |
| 387 | timekeeper_w(device, space, offset + 0x6000, data); | |
| 388 | m_m48t35->write(space, offset + 0x6000, data, 0xff); | |
| 388 | 389 | } |
| 389 | 390 | |
| 390 | 391 | READ8_MEMBER(multfish_state::bankedram_r) |
| 391 | 392 | { |
| 392 | 393 | if ((m_rambk & 0x80) == 0x00) |
| 393 | 394 | { |
| 394 | return | |
| 395 | return m_m48t35->read(space, offset + 0x2000*(m_rambk & 0x03), 0xff); | |
| 395 | 396 | } |
| 396 | 397 | else |
| 397 | 398 | { |
| r22719 | r22720 | |
| 404 | 405 | { |
| 405 | 406 | if ((m_rambk & 0x80) == 0x00) |
| 406 | 407 | { |
| 407 | | |
| 408 | m_m48t35->write(space, offset + 0x2000*(m_rambk & 0x03), data, 0xff); | |
| 408 | 409 | } |
| 409 | 410 | else |
| 410 | 411 | { |
| r22719 | r22720 | |
| 1155 | 1156 | MCFG_CPU_IO_MAP(rollfr_portmap) |
| 1156 | 1157 | MACHINE_CONFIG_END |
| 1157 | 1158 | |
| 1158 | MACHINE_RESET_MEMBER(multfish_state,island2a) | |
| 1159 | { | |
| 1160 | multfish_state::machine_reset(); | |
| 1161 | 1159 | |
| 1162 | // this set needs preprogrammed data in timekeeper | |
| 1163 | timekeeper_w(machine().device("m48t35"), generic_space(), 0x2003 , 0x01); | |
| 1164 | timekeeper_w(machine().device("m48t35"), generic_space(), 0x4003 , 0x02); | |
| 1165 | } | |
| 1166 | static MACHINE_CONFIG_DERIVED( island2a, multfish ) | |
| 1167 | 1160 | |
| 1168 | /* basic machine hardware */ | |
| 1169 | MCFG_MACHINE_RESET_OVERRIDE(multfish_state, island2a ) | |
| 1170 | MACHINE_CONFIG_END | |
| 1171 | ||
| 1172 | ||
| 1173 | ||
| 1174 | 1161 | /* Rom Naming note: |
| 1175 | 1162 | |
| 1176 | 1163 | The GFX ROMs do not have labels, for clarity we name |
| r22719 | r22720 | |
| 4552 | 4539 | ROM_LOAD( "island2.006", 0x180000, 0x80000, CRC(55e285d9) SHA1(ba58963441c65220700cd8057e6afe3f5f8faa4f) ) |
| 4553 | 4540 | ROM_LOAD( "island2.007", 0x280000, 0x80000, CRC(edd72be6) SHA1(fb1e63f59e8565c23ae43630fa572fbc022c878f) ) |
| 4554 | 4541 | ROM_LOAD( "island2.008", 0x380000, 0x80000, CRC(c336d608) SHA1(55391183c6d95ecea81354efa70641350860d1f5) ) |
| 4542 | ||
| 4543 | ROM_REGION( 0x8000, "m48t35", 0 ) | |
| 4544 | ROM_LOAD( "m48t35", 0x000000, 0x08000, CRC(c8ec9973) SHA1(7973189d9b380ca2591d3ef3b80446410f7a8ed8) ) | |
| 4555 | 4545 | ROM_END |
| 4556 | 4546 | |
| 4557 | 4547 | ROM_START( island2b ) // 060529 bank F9, changed version text to 070205, skip some start tests |
| r22719 | r22720 | |
| 5277 | 5267 | GAME( 2005, islandb, island_parent, multfish, multfish, multfish_state, customl, ROT0, "bootleg", "Island (bootleg, 050713, VIDEO GAME-1 OS01)", GAME_SUPPORTS_SAVE ) // custom alteras, modified graphics, many texts changed, changed version text to "VIDEO GAME-1 OS01" |
| 5278 | 5268 | GAME( 2005, islandc, island_parent, multfish, multfish, multfish_state, customl, ROT0, "bootleg", "Island (bootleg, 050713, LOTOS OS01)", GAME_SUPPORTS_SAVE ) // custom alteras, modified graphics, many texts changed, changed version text to "LOTOS OS01" |
| 5279 | 5269 | |
| 5280 | GAME( 2006, island2a, island2_parent, is | |
| 5270 | GAME( 2006, island2a, island2_parent, multfish, multfish, driver_device, 0, ROT0, "bootleg", "Island 2 (bootleg, 060529, banking address hack)", GAME_SUPPORTS_SAVE ) // bank F9 (not standart, game not work) | |
| 5281 | 5271 | GAME( 2006, island2b, island2_parent, multfish, multfish, driver_device, 0, ROT0, "bootleg", "Island 2 (bootleg, 060529, banking address hack, changed version text)", GAME_SUPPORTS_SAVE ) // bank F9, changed version text to 070205, skip some start tests |
| 5282 | 5272 | GAME( 2006, island2c, island2_parent, multfish, multfish, driver_device, 0, ROT0, "bootleg", "Island 2 (bootleg, 060529, LOTTOGAME (I))", GAME_SUPPORTS_SAVE ) // bank F9, modified graphics, changed version text to "MDS_is_the_best_ LOTTOGAME (I)" |
| 5283 | 5273 | GAME( 2006, island2_3a, island2_parent, multfish, multfish, driver_device, 0, ROT0, "bootleg", "Island 2 (bootleg, 061218, VIDEO GAME-1 OS2-01)", GAME_SUPPORTS_SAVE ) // bank F9, modified graphics, changed version text to "VIDEO GAME-1 OS2-01" |
| r22719 | r22720 | |
|---|---|---|
| 545 | 545 | AM_RANGE(0x780c0000, 0x780c0003) AM_READWRITE_LEGACY(cgboard_dsp_comm_r_ppc, cgboard_dsp_comm_w_ppc) |
| 546 | 546 | AM_RANGE(0x7d000000, 0x7d00ffff) AM_READ(sysreg_r) |
| 547 | 547 | AM_RANGE(0x7d010000, 0x7d01ffff) AM_WRITE(sysreg_w) |
| 548 | AM_RANGE(0x7d020000, 0x7d021fff) AM_DEVREADWRITE8 | |
| 548 | AM_RANGE(0x7d020000, 0x7d021fff) AM_DEVREADWRITE8("m48t58", timekeeper_device, read, write, 0xffffffff) /* M48T58Y RTC/NVRAM */ | |
| 549 | 549 | AM_RANGE(0x7d030000, 0x7d030007) AM_DEVREAD_LEGACY("k056800", k056800_host_r) |
| 550 | 550 | AM_RANGE(0x7d030000, 0x7d030007) AM_DEVWRITE_LEGACY("k056800", k056800_host_w) |
| 551 | 551 | AM_RANGE(0x7d030008, 0x7d03000f) AM_DEVWRITE_LEGACY("k056800", k056800_host_w) |
| r22719 | r22720 | |
|---|---|---|
| 4258 | 4258 | |
| 4259 | 4259 | void itech32_state::install_timekeeper() |
| 4260 | 4260 | { |
| 4261 | device_t *device = machine().device("m48t02"); | |
| 4262 | m_maincpu->space(AS_PROGRAM).install_legacy_readwrite_handler(*device, 0x681000, 0x6817ff, FUNC(timekeeper_r), FUNC(timekeeper_w), 0xffffffff); | |
| 4261 | timekeeper_device *m48t02 = machine().device<timekeeper_device>("m48t02"); | |
| 4262 | m_maincpu->space(AS_PROGRAM).install_readwrite_handler(0x681000, 0x6817ff, read8_delegate(FUNC(timekeeper_device::read), m48t02), write8_delegate(FUNC(timekeeper_device::write), m48t02), 0xffffffff); | |
| 4263 | 4263 | } |
| 4264 | 4264 | |
| 4265 | 4265 | DRIVER_INIT_MEMBER(itech32_state,wcbowlt) |
| r22719 | r22720 | |
|---|---|---|
| 657 | 657 | AM_RANGE(0x780c0000, 0x780c0003) AM_READWRITE_LEGACY(cgboard_dsp_comm_r_ppc, cgboard_dsp_comm_w_ppc) |
| 658 | 658 | AM_RANGE(0x7d000000, 0x7d00ffff) AM_READ8(sysreg_r, 0xffffffff) |
| 659 | 659 | AM_RANGE(0x7d010000, 0x7d01ffff) AM_WRITE8(sysreg_w, 0xffffffff) |
| 660 | AM_RANGE(0x7d020000, 0x7d021fff) AM_DEVREADWRITE8 | |
| 660 | AM_RANGE(0x7d020000, 0x7d021fff) AM_DEVREADWRITE8("m48t58", timekeeper_device, read, write, 0xffffffff) /* M48T58Y RTC/NVRAM */ | |
| 661 | 661 | AM_RANGE(0x7d030000, 0x7d030007) AM_DEVREADWRITE_LEGACY("k056800", k056800_host_r, k056800_host_w) |
| 662 | 662 | AM_RANGE(0x7d042000, 0x7d043fff) AM_RAM /* COMM BOARD 0 */ |
| 663 | 663 | AM_RANGE(0x7d044000, 0x7d044007) AM_READ(comm0_unk_r) |
| r22719 | r22720 | |
|---|---|---|
| 306 | 306 | AM_RANGE(0x800000, 0x803fff) AM_RAM AM_SHARE("vectorram") |
| 307 | 307 | AM_RANGE(0xffa000, 0xffbfff) AM_READWRITE(tomcat_shared_ram_r, tomcat_shared_ram_w) |
| 308 | 308 | AM_RANGE(0xffc000, 0xffcfff) AM_RAM |
| 309 | AM_RANGE(0xffd000, 0xffdfff) AM_DEVREADWRITE8 | |
| 309 | AM_RANGE(0xffd000, 0xffdfff) AM_DEVREADWRITE8("m48t02", timekeeper_device, read, write, 0xff00) | |
| 310 | 310 | AM_RANGE(0xffd000, 0xffdfff) AM_READWRITE8(tomcat_nvram_r, tomcat_nvram_w, 0x00ff) |
| 311 | 311 | ADDRESS_MAP_END |
| 312 | 312 |
| r22719 | r22720 | |
|---|---|---|
| 1919 | 1919 | AM_RANGE(0xffe00000, 0xffe00007) AM_READ(e00000_r) |
| 1920 | 1920 | AM_RANGE(0xffe00008, 0xffe0000f) AM_READWRITE(e00008_r, e00008_w) |
| 1921 | 1921 | AM_RANGE(0xffe10000, 0xffe10007) AM_READ(unk1_r) |
| 1922 | AM_RANGE(0xffe30000, 0xffe31fff) AM_DEVREADWRITE8 | |
| 1922 | AM_RANGE(0xffe30000, 0xffe31fff) AM_DEVREADWRITE8("m48t58", timekeeper_device, read, write, U64(0xffffffffffffffff)) | |
| 1923 | 1923 | AM_RANGE(0xffe40000, 0xffe4000f) AM_NOP |
| 1924 | 1924 | AM_RANGE(0xffe50000, 0xffe50007) AM_WRITE(unk2_w) |
| 1925 | 1925 | AM_RANGE(0xffe70000, 0xffe7000f) AM_READWRITE(e70000_r, e70000_w) |
| r22719 | r22720 | |
|---|---|---|
| 244 | 244 | #include "sound/okim6295.h" |
| 245 | 245 | #include "sound/qsound.h" |
| 246 | 246 | #include "sound/msm5205.h" |
| 247 | #include "machine/timekpr.h" | |
| 248 | 247 | #include "machine/kabuki.h" |
| 249 | 248 | #include "includes/cps1.h" /* External CPS1 definitions */ |
| 250 | 249 | |
| r22719 | r22720 | |
| 10921 | 10920 | UINT16 result = 0xffff; |
| 10922 | 10921 | |
| 10923 | 10922 | if (ACCESSING_BITS_0_7) |
| 10924 | result = (result & ~0x00ff) | | |
| 10923 | result = (result & ~0x00ff) | m_m48t35->read(space, offset, 0xff); | |
| 10925 | 10924 | if (ACCESSING_BITS_8_15) |
| 10926 | 10925 | result = (result & ~0xff00) | (m_mainram[offset] & 0xff00); |
| 10927 | 10926 | |
| r22719 | r22720 | |
| 10933 | 10932 | COMBINE_DATA(&m_mainram[offset]); |
| 10934 | 10933 | |
| 10935 | 10934 | if (ACCESSING_BITS_0_7) |
| 10936 | | |
| 10935 | m_m48t35->write(space, offset, data & 0xff, 0xff); | |
| 10937 | 10936 | } |
| 10938 | 10937 | |
| 10939 | 10938 | DRIVER_INIT_MEMBER(cps_state, ganbare) |
| r22719 | r22720 | |
|---|---|---|
| 65 | 65 | AM_RANGE(0x00303c00, 0x00303fff) AM_DEVREADWRITE("cdic", cdicdic_device, regs_r, regs_w) |
| 66 | 66 | AM_RANGE(0x00310000, 0x00317fff) AM_DEVREADWRITE("slave", cdislave_device, slave_r, slave_w) |
| 67 | 67 | //AM_RANGE(0x00318000, 0x0031ffff) AM_NOP |
| 68 | AM_RANGE(0x00320000, 0x00323fff) AM_DEVREADWRITE8 | |
| 68 | AM_RANGE(0x00320000, 0x00323fff) AM_DEVREADWRITE8("mk48t08", timekeeper_device, read, write, 0xff00) /* nvram (only low bytes used) */ | |
| 69 | 69 | AM_RANGE(0x00400000, 0x0047ffff) AM_ROM AM_REGION("maincpu", 0) |
| 70 | 70 | AM_RANGE(0x004fffe0, 0x004fffff) AM_DEVREADWRITE("mcd212", mcd212_device, regs_r, regs_w) |
| 71 | 71 | //AM_RANGE(0x00500000, 0x0057ffff) AM_RAM |
| r22719 | r22720 | |
|---|---|---|
| 1380 | 1380 | AM_RANGE(0x1f500000, 0x1f500003) AM_READWRITE(control_r, control_w ) // Konami can't make a game without a "control" register. |
| 1381 | 1381 | AM_RANGE(0x1f560000, 0x1f560003) AM_WRITE(atapi_reset_w ) |
| 1382 | 1382 | AM_RANGE(0x1f5c0000, 0x1f5c0003) AM_WRITENOP // watchdog? |
| 1383 | AM_RANGE(0x1f620000, 0x1f623fff) AM_DEVREADWRITE8 | |
| 1383 | AM_RANGE(0x1f620000, 0x1f623fff) AM_DEVREADWRITE8("m48t58", timekeeper_device, read, write, 0x00ff00ff) | |
| 1384 | 1384 | AM_RANGE(0x1f680000, 0x1f68001f) AM_READWRITE(mb89371_r, mb89371_w) |
| 1385 | 1385 | AM_RANGE(0x1f6a0000, 0x1f6a0003) AM_READWRITE(security_r, security_w ) |
| 1386 | 1386 | ADDRESS_MAP_END |
| r22719 | r22720 | |
|---|---|---|
| 6 | 6 | |
| 7 | 7 | #define MIDZEUS_VIDEO_CLOCK XTAL_66_6667MHz |
| 8 | 8 | |
| 9 | #include "machine/timekpr.h" | |
| 10 | ||
| 9 | 11 | class midzeus_state : public driver_device |
| 10 | 12 | { |
| 11 | 13 | public: |
| r22719 | r22720 | |
| 16 | 18 | m_linkram(*this, "linkram"), |
| 17 | 19 | m_tms32031_control(*this, "tms32031_ctl"), |
| 18 | 20 | m_zeusbase(*this, "zeusbase") , |
| 21 | m_m48t35(*this, "m48t35"), | |
| 19 | 22 | m_maincpu(*this, "maincpu") { } |
| 20 | 23 | |
| 21 | 24 | required_shared_ptr<UINT32> m_nvram; |
| r22719 | r22720 | |
| 23 | 26 | optional_shared_ptr<UINT32> m_linkram; |
| 24 | 27 | required_shared_ptr<UINT32> m_tms32031_control; |
| 25 | 28 | required_shared_ptr<UINT32> m_zeusbase; |
| 29 | optional_device<timekeeper_device> m_m48t35; | |
| 26 | 30 | |
| 27 | 31 | DECLARE_WRITE32_MEMBER(cmos_w); |
| 28 | 32 | DECLARE_READ32_MEMBER(cmos_r); |
| r22719 | r22720 | |
|---|---|---|
| 4 | 4 | #include "sound/msm5205.h" |
| 5 | 5 | #include "sound/qsound.h" |
| 6 | 6 | #include "sound/okim6295.h" |
| 7 | #include "machine/timekpr.h" | |
| 7 | 8 | |
| 8 | 9 | struct gfx_range |
| 9 | 10 | { |
| r22719 | r22720 | |
| 77 | 78 | m_output(*this, "output"), |
| 78 | 79 | m_maincpu(*this, "maincpu"), |
| 79 | 80 | m_audiocpu(*this, "audiocpu"), |
| 80 | m_oki(*this, "oki") | |
| 81 | m_oki(*this, "oki"), | |
| 82 | m_m48t35(*this,"m48t35") | |
| 81 | 83 | { } |
| 82 | 84 | |
| 83 | 85 | /* memory pointers */ |
| r22719 | r22720 | |
| 167 | 169 | required_device<cpu_device> m_maincpu; |
| 168 | 170 | optional_device<cpu_device> m_audiocpu; |
| 169 | 171 | optional_device<okim6295_device> m_oki; |
| 172 | optional_device<m48t35_device> m_m48t35; | |
| 170 | 173 | msm5205_device *m_msm_1; // fcrash |
| 171 | 174 | msm5205_device *m_msm_2; // fcrash |
| 172 | 175 | DECLARE_READ16_MEMBER(cps1_hack_dsw_r); |
| Previous | 199869 Revisions | Next |