trunk/src/mame/video/taitoic.c
| r23922 | r23923 | |
| 2379 | 2379 | /* */ |
| 2380 | 2380 | /***************************************************************************/ |
| 2381 | 2381 | |
| 2382 | | struct tc0280grd_state |
| 2383 | | { |
| 2384 | | UINT16 * ram; |
| 2382 | #define TC0280GRD_RAM_SIZE 0x2000 |
| 2385 | 2383 | |
| 2386 | | tilemap_t *tilemap; |
| 2384 | const device_type TC0280GRD = &device_creator<tc0280grd_device>; |
| 2387 | 2385 | |
| 2388 | | UINT16 ctrl[8]; |
| 2389 | | int gfxnum, base_color; |
| 2390 | | }; |
| 2386 | tc0280grd_device::tc0280grd_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 2387 | : device_t(mconfig, TC0280GRD, "Taito TC0280GRD & TC0430GRW", tag, owner, clock, "tc0280grd", __FILE__) |
| 2388 | { |
| 2389 | } |
| 2391 | 2390 | |
| 2392 | | #define TC0280GRD_RAM_SIZE 0x2000 |
| 2391 | //------------------------------------------------- |
| 2392 | // device_config_complete - perform any |
| 2393 | // operations now that the configuration is |
| 2394 | // complete |
| 2395 | //------------------------------------------------- |
| 2393 | 2396 | |
| 2394 | | /***************************************************************************** |
| 2395 | | INLINE FUNCTIONS |
| 2396 | | *****************************************************************************/ |
| 2397 | void tc0280grd_device::device_config_complete() |
| 2398 | { |
| 2399 | // inherit a copy of the static data |
| 2400 | const tc0280grd_interface *intf = reinterpret_cast<const tc0280grd_interface *>(static_config()); |
| 2401 | if (intf != NULL) |
| 2402 | *static_cast<tc0280grd_interface *>(this) = *intf; |
| 2403 | |
| 2404 | // or initialize to defaults if none provided |
| 2405 | else |
| 2406 | { |
| 2407 | } |
| 2408 | } |
| 2397 | 2409 | |
| 2398 | | INLINE tc0280grd_state *tc0280grd_get_safe_token( device_t *device ) |
| 2410 | //------------------------------------------------- |
| 2411 | // device_start - device-specific startup |
| 2412 | //------------------------------------------------- |
| 2413 | |
| 2414 | void tc0280grd_device::device_start() |
| 2399 | 2415 | { |
| 2400 | | assert(device != NULL); |
| 2401 | | assert((device->type() == TC0280GRD) || (device->type() == TC0430GRW)); |
| 2416 | m_tilemap = &machine().tilemap().create(tilemap_get_info_delegate(FUNC(tc0280grd_device::tc0280grd_get_tile_info),this), TILEMAP_SCAN_ROWS, 8, 8, 64, 64); |
| 2417 | m_tilemap->set_transparent_pen(0); |
| 2402 | 2418 | |
| 2403 | | return (tc0280grd_state *)downcast<tc0280grd_device *>(device)->token(); |
| 2419 | m_ram = auto_alloc_array(machine(), UINT16, TC0280GRD_RAM_SIZE / 2); |
| 2420 | |
| 2421 | save_pointer(NAME(m_ram), TC0280GRD_RAM_SIZE / 2); |
| 2422 | save_item(NAME(m_ctrl)); |
| 2404 | 2423 | } |
| 2405 | 2424 | |
| 2406 | | INLINE const tc0280grd_interface *tc0280grd_get_interface( device_t *device ) |
| 2425 | //------------------------------------------------- |
| 2426 | // device_reset - device-specific reset |
| 2427 | //------------------------------------------------- |
| 2428 | |
| 2429 | void tc0280grd_device::device_reset() |
| 2407 | 2430 | { |
| 2408 | | assert(device != NULL); |
| 2409 | | assert((device->type() == TC0280GRD) || (device->type() == TC0430GRW)); |
| 2410 | | return (const tc0280grd_interface *) device->static_config(); |
| 2431 | int i; |
| 2432 | |
| 2433 | for (i = 0; i < 8; i++) |
| 2434 | m_ctrl[i] = 0; |
| 2411 | 2435 | } |
| 2412 | 2436 | |
| 2413 | 2437 | /***************************************************************************** |
| r23922 | r23923 | |
| 2416 | 2440 | |
| 2417 | 2441 | TILE_GET_INFO_MEMBER(tc0280grd_device::tc0280grd_get_tile_info) |
| 2418 | 2442 | { |
| 2419 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(this); |
| 2420 | | int attr = tc0280grd->ram[tile_index]; |
| 2443 | int attr = m_ram[tile_index]; |
| 2421 | 2444 | SET_TILE_INFO_MEMBER( |
| 2422 | | tc0280grd->gfxnum, |
| 2445 | m_gfxnum, |
| 2423 | 2446 | attr & 0x3fff, |
| 2424 | | ((attr & 0xc000) >> 14) + tc0280grd->base_color, |
| 2447 | ((attr & 0xc000) >> 14) + m_base_color, |
| 2425 | 2448 | 0); |
| 2426 | 2449 | } |
| 2427 | 2450 | |
| 2428 | | READ16_DEVICE_HANDLER( tc0280grd_word_r ) |
| 2451 | READ16_MEMBER( tc0280grd_device::tc0280grd_word_r ) |
| 2429 | 2452 | { |
| 2430 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(device); |
| 2431 | | return tc0280grd->ram[offset]; |
| 2453 | return m_ram[offset]; |
| 2432 | 2454 | } |
| 2433 | 2455 | |
| 2434 | | WRITE16_DEVICE_HANDLER( tc0280grd_word_w ) |
| 2456 | WRITE16_MEMBER( tc0280grd_device::tc0280grd_word_w ) |
| 2435 | 2457 | { |
| 2436 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(device); |
| 2437 | | COMBINE_DATA(&tc0280grd->ram[offset]); |
| 2438 | | tc0280grd->tilemap->mark_tile_dirty(offset); |
| 2458 | COMBINE_DATA(&m_ram[offset]); |
| 2459 | m_tilemap->mark_tile_dirty(offset); |
| 2439 | 2460 | } |
| 2440 | 2461 | |
| 2441 | | WRITE16_DEVICE_HANDLER( tc0280grd_ctrl_word_w ) |
| 2462 | WRITE16_MEMBER( tc0280grd_device::tc0280grd_ctrl_word_w ) |
| 2442 | 2463 | { |
| 2443 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(device); |
| 2444 | | COMBINE_DATA(&tc0280grd->ctrl[offset]); |
| 2464 | COMBINE_DATA(&m_ctrl[offset]); |
| 2445 | 2465 | } |
| 2446 | 2466 | |
| 2447 | | READ16_DEVICE_HANDLER( tc0430grw_word_r ) |
| 2467 | READ16_MEMBER( tc0280grd_device::tc0430grw_word_r ) |
| 2448 | 2468 | { |
| 2449 | | return tc0280grd_word_r(device, space, offset, mem_mask); |
| 2469 | return tc0280grd_word_r(space, offset, mem_mask); |
| 2450 | 2470 | } |
| 2451 | 2471 | |
| 2452 | | WRITE16_DEVICE_HANDLER( tc0430grw_word_w ) |
| 2472 | WRITE16_MEMBER( tc0280grd_device::tc0430grw_word_w ) |
| 2453 | 2473 | { |
| 2454 | | tc0280grd_word_w(device, space, offset, data, mem_mask); |
| 2474 | tc0280grd_word_w(space, offset, data, mem_mask); |
| 2455 | 2475 | } |
| 2456 | 2476 | |
| 2457 | | WRITE16_DEVICE_HANDLER( tc0430grw_ctrl_word_w ) |
| 2477 | WRITE16_MEMBER( tc0280grd_device::tc0430grw_ctrl_word_w ) |
| 2458 | 2478 | { |
| 2459 | | tc0280grd_ctrl_word_w(device, space, offset, data, mem_mask); |
| 2479 | tc0280grd_ctrl_word_w(space, offset, data, mem_mask); |
| 2460 | 2480 | } |
| 2461 | 2481 | |
| 2462 | | void tc0280grd_tilemap_update( device_t *device, int base_color ) |
| 2482 | void tc0280grd_device::tc0280grd_tilemap_update( int base_color ) |
| 2463 | 2483 | { |
| 2464 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(device); |
| 2465 | | if (tc0280grd->base_color != base_color) |
| 2484 | if (m_base_color != base_color) |
| 2466 | 2485 | { |
| 2467 | | tc0280grd->base_color = base_color; |
| 2468 | | tc0280grd->tilemap->mark_all_dirty(); |
| 2486 | m_base_color = base_color; |
| 2487 | m_tilemap->mark_all_dirty(); |
| 2469 | 2488 | } |
| 2470 | 2489 | } |
| 2471 | 2490 | |
| 2472 | | void tc0430grw_tilemap_update( device_t *device, int base_color ) |
| 2491 | void tc0280grd_device::tc0430grw_tilemap_update( int base_color ) |
| 2473 | 2492 | { |
| 2474 | | tc0280grd_tilemap_update(device, base_color); |
| 2493 | tc0280grd_tilemap_update(base_color); |
| 2475 | 2494 | } |
| 2476 | 2495 | |
| 2477 | | static void zoom_draw( device_t *device, bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority, int xmultiply ) |
| 2496 | void tc0280grd_device::zoom_draw( bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority, int xmultiply ) |
| 2478 | 2497 | { |
| 2479 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(device); |
| 2480 | 2498 | UINT32 startx, starty; |
| 2481 | 2499 | int incxx, incxy, incyx, incyy; |
| 2482 | 2500 | |
| 2483 | 2501 | /* 24-bit signed */ |
| 2484 | | startx = ((tc0280grd->ctrl[0] & 0xff) << 16) + tc0280grd->ctrl[1]; |
| 2502 | startx = ((m_ctrl[0] & 0xff) << 16) + m_ctrl[1]; |
| 2485 | 2503 | |
| 2486 | 2504 | if (startx & 0x800000) |
| 2487 | 2505 | startx -= 0x1000000; |
| 2488 | 2506 | |
| 2489 | | incxx = (INT16)tc0280grd->ctrl[2]; |
| 2507 | incxx = (INT16)m_ctrl[2]; |
| 2490 | 2508 | incxx *= xmultiply; |
| 2491 | | incyx = (INT16)tc0280grd->ctrl[3]; |
| 2509 | incyx = (INT16)m_ctrl[3]; |
| 2492 | 2510 | |
| 2493 | 2511 | /* 24-bit signed */ |
| 2494 | | starty = ((tc0280grd->ctrl[4] & 0xff) << 16) + tc0280grd->ctrl[5]; |
| 2512 | starty = ((m_ctrl[4] & 0xff) << 16) + m_ctrl[5]; |
| 2495 | 2513 | |
| 2496 | 2514 | if (starty & 0x800000) |
| 2497 | 2515 | starty -= 0x1000000; |
| 2498 | 2516 | |
| 2499 | | incxy = (INT16)tc0280grd->ctrl[6]; |
| 2517 | incxy = (INT16)m_ctrl[6]; |
| 2500 | 2518 | incxy *= xmultiply; |
| 2501 | | incyy = (INT16)tc0280grd->ctrl[7]; |
| 2519 | incyy = (INT16)m_ctrl[7]; |
| 2502 | 2520 | |
| 2503 | 2521 | startx -= xoffset * incxx + yoffset * incyx; |
| 2504 | 2522 | starty -= xoffset * incxy + yoffset * incyy; |
| 2505 | 2523 | |
| 2506 | | tc0280grd->tilemap->draw_roz(bitmap, cliprect, startx << 4, starty << 4, |
| 2524 | m_tilemap->draw_roz(bitmap, cliprect, startx << 4, starty << 4, |
| 2507 | 2525 | incxx << 4, incxy << 4, incyx << 4, incyy << 4, |
| 2508 | 2526 | 1, /* copy with wraparound */ |
| 2509 | 2527 | 0, priority); |
| 2510 | 2528 | } |
| 2511 | 2529 | |
| 2512 | | void tc0280grd_zoom_draw( device_t *device, bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority ) |
| 2530 | void tc0280grd_device::tc0280grd_zoom_draw( bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority ) |
| 2513 | 2531 | { |
| 2514 | | zoom_draw(device, bitmap, cliprect, xoffset, yoffset, priority, 2); |
| 2532 | zoom_draw(bitmap, cliprect, xoffset, yoffset, priority, 2); |
| 2515 | 2533 | } |
| 2516 | 2534 | |
| 2517 | | void tc0430grw_zoom_draw( device_t *device, bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority ) |
| 2535 | void tc0280grd_device::tc0430grw_zoom_draw( bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority ) |
| 2518 | 2536 | { |
| 2519 | | zoom_draw(device, bitmap, cliprect, xoffset, yoffset, priority, 1); |
| 2537 | zoom_draw(bitmap, cliprect, xoffset, yoffset, priority, 1); |
| 2520 | 2538 | } |
| 2521 | 2539 | |
| 2522 | | const device_type TC0280GRD = &device_creator<tc0280grd_device>; |
| 2523 | 2540 | |
| 2524 | | tc0280grd_device::tc0280grd_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 2525 | | : device_t(mconfig, TC0280GRD, "Taito TC0280GRD & TC0430GRW", tag, owner, clock, "tc0280grd", __FILE__) |
| 2541 | /***************************************************************************/ |
| 2542 | /* */ |
| 2543 | /* TC0360PRI */ |
| 2544 | /* */ |
| 2545 | /***************************************************************************/ |
| 2546 | |
| 2547 | |
| 2548 | |
| 2549 | const device_type TC0360PRI = &device_creator<tc0360pri_device>; |
| 2550 | |
| 2551 | tc0360pri_device::tc0360pri_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 2552 | : device_t(mconfig, TC0360PRI, "Taito TC0360PRI", tag, owner, clock, "tc0360pri", __FILE__) |
| 2526 | 2553 | { |
| 2527 | | m_token = global_alloc_clear(tc0280grd_state); |
| 2528 | 2554 | } |
| 2529 | 2555 | |
| 2530 | 2556 | //------------------------------------------------- |
| r23922 | r23923 | |
| 2533 | 2559 | // complete |
| 2534 | 2560 | //------------------------------------------------- |
| 2535 | 2561 | |
| 2536 | | void tc0280grd_device::device_config_complete() |
| 2562 | void tc0360pri_device::device_config_complete() |
| 2537 | 2563 | { |
| 2538 | 2564 | } |
| 2539 | 2565 | |
| r23922 | r23923 | |
| 2541 | 2567 | // device_start - device-specific startup |
| 2542 | 2568 | //------------------------------------------------- |
| 2543 | 2569 | |
| 2544 | | void tc0280grd_device::device_start() |
| 2570 | void tc0360pri_device::device_start() |
| 2545 | 2571 | { |
| 2546 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(this); |
| 2547 | | const tc0280grd_interface *intf = tc0280grd_get_interface(this); |
| 2548 | | |
| 2549 | | tc0280grd->gfxnum = intf->gfxnum; |
| 2550 | | |
| 2551 | | tc0280grd->tilemap = &machine().tilemap().create(tilemap_get_info_delegate(FUNC(tc0280grd_device::tc0280grd_get_tile_info),this), TILEMAP_SCAN_ROWS, 8, 8, 64, 64); |
| 2552 | | tc0280grd->tilemap->set_transparent_pen(0); |
| 2553 | | |
| 2554 | | tc0280grd->ram = auto_alloc_array(machine(), UINT16, TC0280GRD_RAM_SIZE / 2); |
| 2555 | | |
| 2556 | | save_pointer(NAME(tc0280grd->ram), TC0280GRD_RAM_SIZE / 2); |
| 2557 | | save_item(NAME(tc0280grd->ctrl)); |
| 2572 | save_item(NAME(m_regs)); |
| 2558 | 2573 | } |
| 2559 | 2574 | |
| 2560 | 2575 | //------------------------------------------------- |
| 2561 | 2576 | // device_reset - device-specific reset |
| 2562 | 2577 | //------------------------------------------------- |
| 2563 | 2578 | |
| 2564 | | void tc0280grd_device::device_reset() |
| 2579 | void tc0360pri_device::device_reset() |
| 2565 | 2580 | { |
| 2566 | | tc0280grd_state *tc0280grd = tc0280grd_get_safe_token(this); |
| 2567 | | int i; |
| 2581 | int i; |
| 2568 | 2582 | |
| 2569 | | for (i = 0; i < 8; i++) |
| 2570 | | tc0280grd->ctrl[i] = 0; |
| 2583 | for (i = 0; i < 16; i++) |
| 2584 | m_regs[i] = 0; |
| 2571 | 2585 | } |
| 2572 | 2586 | |
| 2573 | 2587 | |
| 2574 | | /***************************************************************************/ |
| 2575 | | /* */ |
| 2576 | | /* TC0360PRI */ |
| 2577 | | /* */ |
| 2578 | | /***************************************************************************/ |
| 2579 | | |
| 2580 | | struct tc0360pri_state |
| 2581 | | { |
| 2582 | | UINT8 regs[16]; |
| 2583 | | }; |
| 2584 | | |
| 2585 | 2588 | /***************************************************************************** |
| 2586 | | INLINE FUNCTIONS |
| 2587 | | *****************************************************************************/ |
| 2588 | | |
| 2589 | | INLINE tc0360pri_state *tc0360pri_get_safe_token( device_t *device ) |
| 2590 | | { |
| 2591 | | assert(device != NULL); |
| 2592 | | assert(device->type() == TC0360PRI); |
| 2593 | | |
| 2594 | | return (tc0360pri_state *)downcast<tc0360pri_device *>(device)->token(); |
| 2595 | | } |
| 2596 | | |
| 2597 | | /***************************************************************************** |
| 2598 | 2589 | DEVICE HANDLERS |
| 2599 | 2590 | *****************************************************************************/ |
| 2600 | 2591 | |
| 2601 | | WRITE8_DEVICE_HANDLER( tc0360pri_w ) |
| 2592 | WRITE8_MEMBER( tc0360pri_device::write ) |
| 2602 | 2593 | { |
| 2603 | | tc0360pri_state *tc0360pri = tc0360pri_get_safe_token(device); |
| 2604 | | tc0360pri->regs[offset] = data; |
| 2594 | m_regs[offset] = data; |
| 2605 | 2595 | |
| 2606 | 2596 | if (offset >= 0x0a) |
| 2607 | 2597 | popmessage("write %02x to unused TC0360PRI reg %x", data, offset); |
| 2608 | 2598 | #if 0 |
| 2609 | | #define regs tc0360pri->regs |
| 2599 | #define regs m_regs |
| 2610 | 2600 | popmessage("%02x %02x %02x %02x %02x %02x %02x %02x %02x %02x", |
| 2611 | 2601 | regs[0x00], regs[0x01], regs[0x02], regs[0x03], |
| 2612 | 2602 | regs[0x04], regs[0x05], regs[0x06], regs[0x07], |
| r23922 | r23923 | |
| 2614 | 2604 | #endif |
| 2615 | 2605 | } |
| 2616 | 2606 | |
| 2617 | | READ8_DEVICE_HANDLER( tc0360pri_r ) |
| 2607 | READ8_MEMBER( tc0360pri_device::read ) |
| 2618 | 2608 | { |
| 2619 | | tc0360pri_state *tc0360pri = tc0360pri_get_safe_token(device); |
| 2620 | | return tc0360pri->regs[offset]; |
| 2609 | return m_regs[offset]; |
| 2621 | 2610 | } |
| 2622 | 2611 | |
| 2623 | | /***************************************************************************** |
| 2624 | | DEVICE INTERFACE |
| 2625 | | *****************************************************************************/ |
| 2626 | 2612 | |
| 2627 | | static DEVICE_START( tc0360pri ) |
| 2628 | | { |
| 2629 | | tc0360pri_state *tc0360pri = tc0360pri_get_safe_token(device); |
| 2630 | | device->save_item(NAME(tc0360pri->regs)); |
| 2631 | | } |
| 2632 | 2613 | |
| 2633 | | static DEVICE_RESET( tc0360pri ) |
| 2634 | | { |
| 2635 | | tc0360pri_state *tc0360pri = tc0360pri_get_safe_token(device); |
| 2636 | | int i; |
| 2637 | | |
| 2638 | | for (i = 0; i < 16; i++) |
| 2639 | | tc0360pri->regs[i] = 0; |
| 2640 | | |
| 2641 | | } |
| 2642 | | |
| 2643 | | const device_type TC0360PRI = &device_creator<tc0360pri_device>; |
| 2644 | | |
| 2645 | | tc0360pri_device::tc0360pri_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) |
| 2646 | | : device_t(mconfig, TC0360PRI, "Taito TC0360PRI", tag, owner, clock, "tc0360pri", __FILE__) |
| 2647 | | { |
| 2648 | | m_token = global_alloc_clear(tc0360pri_state); |
| 2649 | | } |
| 2650 | | |
| 2651 | | //------------------------------------------------- |
| 2652 | | // device_config_complete - perform any |
| 2653 | | // operations now that the configuration is |
| 2654 | | // complete |
| 2655 | | //------------------------------------------------- |
| 2656 | | |
| 2657 | | void tc0360pri_device::device_config_complete() |
| 2658 | | { |
| 2659 | | } |
| 2660 | | |
| 2661 | | //------------------------------------------------- |
| 2662 | | // device_start - device-specific startup |
| 2663 | | //------------------------------------------------- |
| 2664 | | |
| 2665 | | void tc0360pri_device::device_start() |
| 2666 | | { |
| 2667 | | DEVICE_START_NAME( tc0360pri )(this); |
| 2668 | | } |
| 2669 | | |
| 2670 | | //------------------------------------------------- |
| 2671 | | // device_reset - device-specific reset |
| 2672 | | //------------------------------------------------- |
| 2673 | | |
| 2674 | | void tc0360pri_device::device_reset() |
| 2675 | | { |
| 2676 | | DEVICE_RESET_NAME( tc0360pri )(this); |
| 2677 | | } |
| 2678 | | |
| 2679 | 2614 | /***************************************************************************/ |
| 2680 | 2615 | /* */ |
| 2681 | 2616 | /* TC0480SCP */ |
trunk/src/mame/video/taitoic.h
| r23922 | r23923 | |
| 63 | 63 | |
| 64 | 64 | struct tc0280grd_interface |
| 65 | 65 | { |
| 66 | | int gfxnum; |
| 66 | int m_gfxnum; |
| 67 | 67 | }; |
| 68 | 68 | |
| 69 | 69 | |
| r23922 | r23923 | |
| 101 | 101 | }; |
| 102 | 102 | |
| 103 | 103 | class pc080sn_device : public device_t, |
| 104 | | pc080sn_interface |
| 104 | public pc080sn_interface |
| 105 | 105 | { |
| 106 | 106 | public: |
| 107 | 107 | pc080sn_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| r23922 | r23923 | |
| 154 | 154 | extern const device_type PC080SN; |
| 155 | 155 | |
| 156 | 156 | class pc090oj_device : public device_t, |
| 157 | | public pc090oj_interface |
| 157 | public pc090oj_interface |
| 158 | 158 | { |
| 159 | 159 | public: |
| 160 | 160 | pc090oj_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| r23922 | r23923 | |
| 194 | 194 | extern const device_type PC090OJ; |
| 195 | 195 | |
| 196 | 196 | class tc0080vco_device : public device_t, |
| 197 | | public tc0080vco_interface |
| 197 | public tc0080vco_interface |
| 198 | 198 | { |
| 199 | 199 | public: |
| 200 | 200 | tc0080vco_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| r23922 | r23923 | |
| 257 | 257 | extern const device_type TC0080VCO; |
| 258 | 258 | |
| 259 | 259 | class tc0100scn_device : public device_t, |
| 260 | | public tc0100scn_interface |
| 260 | public tc0100scn_interface |
| 261 | 261 | { |
| 262 | 262 | public: |
| 263 | 263 | tc0100scn_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| r23922 | r23923 | |
| 347 | 347 | |
| 348 | 348 | extern const device_type TC0100SCN; |
| 349 | 349 | |
| 350 | | class tc0280grd_device : public device_t |
| 350 | class tc0280grd_device : public device_t, |
| 351 | public tc0280grd_interface |
| 351 | 352 | { |
| 352 | 353 | public: |
| 353 | 354 | tc0280grd_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 354 | | ~tc0280grd_device() { global_free(m_token); } |
| 355 | ~tc0280grd_device() {} |
| 356 | |
| 357 | DECLARE_READ16_MEMBER( tc0280grd_word_r ); |
| 358 | DECLARE_WRITE16_MEMBER( tc0280grd_word_w ); |
| 359 | DECLARE_WRITE16_MEMBER( tc0280grd_ctrl_word_w ); |
| 360 | void tc0280grd_tilemap_update(int base_color); |
| 361 | void tc0280grd_zoom_draw(bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority); |
| 355 | 362 | |
| 356 | | // access to legacy token |
| 357 | | void *token() const { assert(m_token != NULL); return m_token; } |
| 363 | DECLARE_READ16_MEMBER( tc0430grw_word_r ); |
| 364 | DECLARE_WRITE16_MEMBER( tc0430grw_word_w ); |
| 365 | DECLARE_WRITE16_MEMBER( tc0430grw_ctrl_word_w ); |
| 366 | void tc0430grw_tilemap_update(int base_color); |
| 367 | void tc0430grw_zoom_draw(bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority); |
| 368 | |
| 358 | 369 | protected: |
| 359 | 370 | // device-level overrides |
| 360 | 371 | virtual void device_config_complete(); |
| 361 | 372 | virtual void device_start(); |
| 362 | 373 | virtual void device_reset(); |
| 374 | |
| 363 | 375 | private: |
| 364 | 376 | // internal state |
| 365 | | void *m_token; |
| 377 | UINT16 * m_ram; |
| 366 | 378 | |
| 379 | tilemap_t *m_tilemap; |
| 380 | |
| 381 | UINT16 m_ctrl[8]; |
| 382 | int m_base_color; |
| 383 | |
| 367 | 384 | TILE_GET_INFO_MEMBER(tc0280grd_get_tile_info); |
| 385 | void zoom_draw( bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority, int xmultiply ); |
| 368 | 386 | }; |
| 369 | 387 | |
| 370 | 388 | extern const device_type TC0280GRD; |
| 371 | 389 | |
| 372 | 390 | #define TC0430GRW TC0280GRD |
| 391 | |
| 373 | 392 | class tc0360pri_device : public device_t |
| 374 | 393 | { |
| 375 | 394 | public: |
| 376 | 395 | tc0360pri_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 377 | | ~tc0360pri_device() { global_free(m_token); } |
| 396 | ~tc0360pri_device() {} |
| 378 | 397 | |
| 379 | | // access to legacy token |
| 380 | | void *token() const { assert(m_token != NULL); return m_token; } |
| 398 | DECLARE_WRITE8_MEMBER( write ); |
| 399 | DECLARE_READ8_MEMBER( read ); |
| 400 | |
| 381 | 401 | protected: |
| 382 | 402 | // device-level overrides |
| 383 | 403 | virtual void device_config_complete(); |
| 384 | 404 | virtual void device_start(); |
| 385 | 405 | virtual void device_reset(); |
| 406 | |
| 386 | 407 | private: |
| 387 | 408 | // internal state |
| 388 | | void *m_token; |
| 409 | UINT8 m_regs[16]; |
| 389 | 410 | }; |
| 390 | 411 | |
| 391 | 412 | extern const device_type TC0360PRI; |
| r23922 | r23923 | |
| 535 | 556 | ***************************************************************************/ |
| 536 | 557 | |
| 537 | 558 | |
| 538 | | /** TC0280GRD & TC0430GRW **/ |
| 539 | | DECLARE_READ16_DEVICE_HANDLER( tc0280grd_word_r ); |
| 540 | | DECLARE_WRITE16_DEVICE_HANDLER( tc0280grd_word_w ); |
| 541 | | DECLARE_WRITE16_DEVICE_HANDLER( tc0280grd_ctrl_word_w ); |
| 542 | | void tc0280grd_tilemap_update(device_t *device, int base_color); |
| 543 | | void tc0280grd_zoom_draw(device_t *device, bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority); |
| 544 | | |
| 545 | | DECLARE_READ16_DEVICE_HANDLER( tc0430grw_word_r ); |
| 546 | | DECLARE_WRITE16_DEVICE_HANDLER( tc0430grw_word_w ); |
| 547 | | DECLARE_WRITE16_DEVICE_HANDLER( tc0430grw_ctrl_word_w ); |
| 548 | | void tc0430grw_tilemap_update(device_t *device, int base_color); |
| 549 | | void tc0430grw_zoom_draw(device_t *device, bitmap_ind16 &bitmap, const rectangle &cliprect, int xoffset, int yoffset, UINT32 priority); |
| 550 | | |
| 551 | | |
| 552 | | /** TC0360PRI **/ |
| 553 | | DECLARE_WRITE8_DEVICE_HANDLER( tc0360pri_w ); |
| 554 | | DECLARE_READ8_DEVICE_HANDLER( tc0360pri_r ); |
| 555 | | |
| 556 | | |
| 557 | 559 | /** TC0480SCP **/ |
| 558 | 560 | /* When writing a driver, pass zero for the text and flip offsets initially: |
| 559 | 561 | then tweak them once you have the 4 bg layer positions correct. Col_base |
trunk/src/mame/video/taito_f2.c
| r23922 | r23923 | |
| 1025 | 1025 | layer[0] = m_tc0100scn->bottomlayer(); |
| 1026 | 1026 | layer[1] = layer[0] ^ 1; |
| 1027 | 1027 | layer[2] = 2; |
| 1028 | | m_tilepri[layer[0]] = tc0360pri_r(m_tc0360pri, space, 5) & 0x0f; |
| 1029 | | m_tilepri[layer[1]] = tc0360pri_r(m_tc0360pri, space, 5) >> 4; |
| 1030 | | m_tilepri[layer[2]] = tc0360pri_r(m_tc0360pri, space, 4) >> 4; |
| 1028 | m_tilepri[layer[0]] = m_tc0360pri->read(space, 5) & 0x0f; |
| 1029 | m_tilepri[layer[1]] = m_tc0360pri->read(space, 5) >> 4; |
| 1030 | m_tilepri[layer[2]] = m_tc0360pri->read(space, 4) >> 4; |
| 1031 | 1031 | |
| 1032 | | m_spritepri[0] = tc0360pri_r(m_tc0360pri, space, 6) & 0x0f; |
| 1033 | | m_spritepri[1] = tc0360pri_r(m_tc0360pri, space, 6) >> 4; |
| 1034 | | m_spritepri[2] = tc0360pri_r(m_tc0360pri, space, 7) & 0x0f; |
| 1035 | | m_spritepri[3] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; |
| 1032 | m_spritepri[0] = m_tc0360pri->read(space, 6) & 0x0f; |
| 1033 | m_spritepri[1] = m_tc0360pri->read(space, 6) >> 4; |
| 1034 | m_spritepri[2] = m_tc0360pri->read(space, 7) & 0x0f; |
| 1035 | m_spritepri[3] = m_tc0360pri->read(space, 7) >> 4; |
| 1036 | 1036 | |
| 1037 | | m_spriteblendmode = tc0360pri_r(m_tc0360pri, space, 0) & 0xc0; |
| 1037 | m_spriteblendmode = m_tc0360pri->read(space, 0) & 0xc0; |
| 1038 | 1038 | |
| 1039 | 1039 | machine().priority_bitmap.fill(0, cliprect); |
| 1040 | 1040 | bitmap.fill(0, cliprect); /* wrong color? */ |
| r23922 | r23923 | |
| 1052 | 1052 | void taitof2_state::draw_roz_layer( bitmap_ind16 &bitmap, const rectangle &cliprect, UINT32 priority) |
| 1053 | 1053 | { |
| 1054 | 1054 | if (m_tc0280grd != NULL) |
| 1055 | | tc0280grd_zoom_draw(m_tc0280grd, bitmap, cliprect, m_pivot_xdisp, m_pivot_ydisp, priority); |
| 1055 | m_tc0280grd->tc0280grd_zoom_draw(bitmap, cliprect, m_pivot_xdisp, m_pivot_ydisp, priority); |
| 1056 | 1056 | |
| 1057 | 1057 | if (m_tc0430grw != NULL) |
| 1058 | | tc0430grw_zoom_draw(m_tc0430grw, bitmap, cliprect, m_pivot_xdisp, m_pivot_ydisp, priority); |
| 1058 | m_tc0430grw->tc0430grw_zoom_draw(bitmap, cliprect, m_pivot_xdisp, m_pivot_ydisp, priority); |
| 1059 | 1059 | } |
| 1060 | 1060 | |
| 1061 | 1061 | UINT32 taitof2_state::screen_update_taitof2_pri_roz(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) |
| r23922 | r23923 | |
| 1066 | 1066 | int layer[3]; |
| 1067 | 1067 | int drawn; |
| 1068 | 1068 | int i,j; |
| 1069 | | int roz_base_color = (tc0360pri_r(m_tc0360pri, space, 1) & 0x3f) << 2; |
| 1069 | int roz_base_color = (m_tc0360pri->read(space, 1) & 0x3f) << 2; |
| 1070 | 1070 | |
| 1071 | 1071 | taitof2_handle_sprite_buffering(); |
| 1072 | 1072 | |
| 1073 | 1073 | if (m_tc0280grd != NULL) |
| 1074 | | tc0280grd_tilemap_update(m_tc0280grd, roz_base_color); |
| 1074 | m_tc0280grd->tc0280grd_tilemap_update(roz_base_color); |
| 1075 | 1075 | |
| 1076 | 1076 | if (m_tc0430grw != NULL) |
| 1077 | | tc0430grw_tilemap_update(m_tc0430grw, roz_base_color); |
| 1077 | m_tc0430grw->tc0430grw_tilemap_update(roz_base_color); |
| 1078 | 1078 | |
| 1079 | 1079 | m_tc0100scn->tilemap_update(); |
| 1080 | 1080 | |
| 1081 | | rozpri = (tc0360pri_r(m_tc0360pri, space, 1) & 0xc0) >> 6; |
| 1082 | | rozpri = (tc0360pri_r(m_tc0360pri, space, 8 + rozpri / 2) >> 4 * (rozpri & 1)) & 0x0f; |
| 1081 | rozpri = (m_tc0360pri->read(space, 1) & 0xc0) >> 6; |
| 1082 | rozpri = (m_tc0360pri->read(space, 8 + rozpri / 2) >> 4 * (rozpri & 1)) & 0x0f; |
| 1083 | 1083 | |
| 1084 | 1084 | layer[0] = m_tc0100scn->bottomlayer(); |
| 1085 | 1085 | layer[1] = layer[0] ^ 1; |
| 1086 | 1086 | layer[2] = 2; |
| 1087 | 1087 | |
| 1088 | | tilepri[layer[0]] = tc0360pri_r(m_tc0360pri, space, 5) & 0x0f; |
| 1089 | | tilepri[layer[1]] = tc0360pri_r(m_tc0360pri, space, 5) >> 4; |
| 1090 | | tilepri[layer[2]] = tc0360pri_r(m_tc0360pri, space, 4) >> 4; |
| 1088 | tilepri[layer[0]] = m_tc0360pri->read(space, 5) & 0x0f; |
| 1089 | tilepri[layer[1]] = m_tc0360pri->read(space, 5) >> 4; |
| 1090 | tilepri[layer[2]] = m_tc0360pri->read(space, 4) >> 4; |
| 1091 | 1091 | |
| 1092 | | m_spritepri[0] = tc0360pri_r(m_tc0360pri, space, 6) & 0x0f; |
| 1093 | | m_spritepri[1] = tc0360pri_r(m_tc0360pri, space, 6) >> 4; |
| 1094 | | m_spritepri[2] = tc0360pri_r(m_tc0360pri, space, 7) & 0x0f; |
| 1095 | | m_spritepri[3] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; |
| 1092 | m_spritepri[0] = m_tc0360pri->read(space, 6) & 0x0f; |
| 1093 | m_spritepri[1] = m_tc0360pri->read(space, 6) >> 4; |
| 1094 | m_spritepri[2] = m_tc0360pri->read(space, 7) & 0x0f; |
| 1095 | m_spritepri[3] = m_tc0360pri->read(space, 7) >> 4; |
| 1096 | 1096 | |
| 1097 | | m_spriteblendmode = tc0360pri_r(m_tc0360pri, space, 0) & 0xc0; |
| 1097 | m_spriteblendmode = m_tc0360pri->read(space, 0) & 0xc0; |
| 1098 | 1098 | |
| 1099 | 1099 | machine().priority_bitmap.fill(0, cliprect); |
| 1100 | 1100 | bitmap.fill(0, cliprect); /* wrong color? */ |
| r23922 | r23923 | |
| 1143 | 1143 | layer[0][0] = m_tc0100scn_1->bottomlayer(); |
| 1144 | 1144 | layer[0][1] = layer[0][0] ^ 1; |
| 1145 | 1145 | layer[0][2] = 2; |
| 1146 | | tilepri[0][layer[0][0]] = tc0360pri_r(m_tc0360pri, space, 5) & 0x0f; |
| 1147 | | tilepri[0][layer[0][1]] = tc0360pri_r(m_tc0360pri, space, 5) >> 4; |
| 1148 | | tilepri[0][layer[0][2]] = tc0360pri_r(m_tc0360pri, space, 4) >> 4; |
| 1146 | tilepri[0][layer[0][0]] = m_tc0360pri->read(space, 5) & 0x0f; |
| 1147 | tilepri[0][layer[0][1]] = m_tc0360pri->read(space, 5) >> 4; |
| 1148 | tilepri[0][layer[0][2]] = m_tc0360pri->read(space, 4) >> 4; |
| 1149 | 1149 | |
| 1150 | 1150 | layer[1][0] = m_tc0100scn_2->bottomlayer(); |
| 1151 | 1151 | layer[1][1] = layer[1][0] ^ 1; |
| 1152 | 1152 | layer[1][2] = 2; |
| 1153 | | tilepri[1][layer[1][0]] = tc0360pri_r(m_tc0360pri, space, 9) & 0x0f; |
| 1154 | | tilepri[1][layer[1][1]] = tc0360pri_r(m_tc0360pri, space, 9) >> 4; |
| 1155 | | tilepri[1][layer[1][2]] = tc0360pri_r(m_tc0360pri, space, 8) >> 4; |
| 1153 | tilepri[1][layer[1][0]] = m_tc0360pri->read(space, 9) & 0x0f; |
| 1154 | tilepri[1][layer[1][1]] = m_tc0360pri->read(space, 9) >> 4; |
| 1155 | tilepri[1][layer[1][2]] = m_tc0360pri->read(space, 8) >> 4; |
| 1156 | 1156 | |
| 1157 | | spritepri[0] = tc0360pri_r(m_tc0360pri, space, 6) & 0x0f; |
| 1158 | | spritepri[1] = tc0360pri_r(m_tc0360pri, space, 6) >> 4; |
| 1159 | | spritepri[2] = tc0360pri_r(m_tc0360pri, space, 7) & 0x0f; |
| 1160 | | spritepri[3] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; |
| 1157 | spritepri[0] = m_tc0360pri->read(space, 6) & 0x0f; |
| 1158 | spritepri[1] = m_tc0360pri->read(space, 6) >> 4; |
| 1159 | spritepri[2] = m_tc0360pri->read(space, 7) & 0x0f; |
| 1160 | spritepri[3] = m_tc0360pri->read(space, 7) >> 4; |
| 1161 | 1161 | |
| 1162 | 1162 | machine().priority_bitmap.fill(0, cliprect); |
| 1163 | 1163 | bitmap.fill(0, cliprect); /* wrong color? */ |
| r23922 | r23923 | |
| 1287 | 1287 | invlayer[layer[2]] = 2; |
| 1288 | 1288 | invlayer[layer[3]] = 3; |
| 1289 | 1289 | |
| 1290 | | m_tilepri[invlayer[0]] = tc0360pri_r(m_tc0360pri, space, 4) & 0x0f; /* bg0 */ |
| 1291 | | m_tilepri[invlayer[1]] = tc0360pri_r(m_tc0360pri, space, 4) >> 4; /* bg1 */ |
| 1292 | | m_tilepri[invlayer[2]] = tc0360pri_r(m_tc0360pri, space, 5) & 0x0f; /* bg2 */ |
| 1293 | | m_tilepri[invlayer[3]] = tc0360pri_r(m_tc0360pri, space, 5) >> 4; /* bg3 */ |
| 1294 | | m_tilepri[4] = tc0360pri_r(m_tc0360pri, space, 9) & 0x0f; /* fg (text layer) */ |
| 1290 | m_tilepri[invlayer[0]] = m_tc0360pri->read(space, 4) & 0x0f; /* bg0 */ |
| 1291 | m_tilepri[invlayer[1]] = m_tc0360pri->read(space, 4) >> 4; /* bg1 */ |
| 1292 | m_tilepri[invlayer[2]] = m_tc0360pri->read(space, 5) & 0x0f; /* bg2 */ |
| 1293 | m_tilepri[invlayer[3]] = m_tc0360pri->read(space, 5) >> 4; /* bg3 */ |
| 1294 | m_tilepri[4] = m_tc0360pri->read(space, 9) & 0x0f; /* fg (text layer) */ |
| 1295 | 1295 | |
| 1296 | | m_spritepri[0] = tc0360pri_r(m_tc0360pri, space, 6) & 0x0f; |
| 1297 | | m_spritepri[1] = tc0360pri_r(m_tc0360pri, space, 6) >> 4; |
| 1298 | | m_spritepri[2] = tc0360pri_r(m_tc0360pri, space, 7) & 0x0f; |
| 1299 | | m_spritepri[3] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; |
| 1296 | m_spritepri[0] = m_tc0360pri->read(space, 6) & 0x0f; |
| 1297 | m_spritepri[1] = m_tc0360pri->read(space, 6) >> 4; |
| 1298 | m_spritepri[2] = m_tc0360pri->read(space, 7) & 0x0f; |
| 1299 | m_spritepri[3] = m_tc0360pri->read(space, 7) >> 4; |
| 1300 | 1300 | |
| 1301 | | m_spriteblendmode = tc0360pri_r(m_tc0360pri, space, 0) & 0xc0; |
| 1301 | m_spriteblendmode = m_tc0360pri->read(space, 0) & 0xc0; |
| 1302 | 1302 | |
| 1303 | 1303 | machine().priority_bitmap.fill(0, cliprect); |
| 1304 | 1304 | bitmap.fill(0, cliprect); |
| r23922 | r23923 | |
| 1335 | 1335 | layer[3] = (priority & 0x000f) >> 0; /* tells us which is top */ |
| 1336 | 1336 | layer[4] = 4; /* text layer always over bg layers */ |
| 1337 | 1337 | |
| 1338 | | tilepri[0] = tc0360pri_r(m_tc0360pri, space, 4) >> 4; /* bg0 */ |
| 1339 | | tilepri[1] = tc0360pri_r(m_tc0360pri, space, 5) & 0x0f; /* bg1 */ |
| 1340 | | tilepri[2] = tc0360pri_r(m_tc0360pri, space, 5) >> 4; /* bg2 */ |
| 1341 | | tilepri[3] = tc0360pri_r(m_tc0360pri, space, 4) & 0x0f; /* bg3 */ |
| 1338 | tilepri[0] = m_tc0360pri->read(space, 4) >> 4; /* bg0 */ |
| 1339 | tilepri[1] = m_tc0360pri->read(space, 5) & 0x0f; /* bg1 */ |
| 1340 | tilepri[2] = m_tc0360pri->read(space, 5) >> 4; /* bg2 */ |
| 1341 | tilepri[3] = m_tc0360pri->read(space, 4) & 0x0f; /* bg3 */ |
| 1342 | 1342 | |
| 1343 | 1343 | /* we actually assume text layer is on top of everything anyway, but FWIW... */ |
| 1344 | | tilepri[layer[4]] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; /* fg (text layer) */ |
| 1344 | tilepri[layer[4]] = m_tc0360pri->read(space, 7) >> 4; /* fg (text layer) */ |
| 1345 | 1345 | |
| 1346 | | spritepri[0] = tc0360pri_r(m_tc0360pri, space, 6) & 0x0f; |
| 1347 | | spritepri[1] = tc0360pri_r(m_tc0360pri, space, 6) >> 4; |
| 1348 | | spritepri[2] = tc0360pri_r(m_tc0360pri, space, 7) & 0x0f; |
| 1349 | | spritepri[3] = tc0360pri_r(m_tc0360pri, space, 7) >> 4; |
| 1346 | spritepri[0] = m_tc0360pri->read(space, 6) & 0x0f; |
| 1347 | spritepri[1] = m_tc0360pri->read(space, 6) >> 4; |
| 1348 | spritepri[2] = m_tc0360pri->read(space, 7) & 0x0f; |
| 1349 | spritepri[3] = m_tc0360pri->read(space, 7) >> 4; |
| 1350 | 1350 | |
| 1351 | 1351 | machine().priority_bitmap.fill(0, cliprect); |
| 1352 | 1352 | bitmap.fill(0, cliprect); |
trunk/src/mame/drivers/taito_f2.c
| r23922 | r23923 | |
| 710 | 710 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 711 | 711 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 712 | 712 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 713 | | AM_RANGE(0xa00000, 0xa01fff) AM_DEVREADWRITE_LEGACY("tc0280grd", tc0280grd_word_r, tc0280grd_word_w) /* ROZ tilemap */ |
| 714 | | AM_RANGE(0xa02000, 0xa0200f) AM_DEVWRITE_LEGACY("tc0280grd", tc0280grd_ctrl_word_w) |
| 715 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 713 | AM_RANGE(0xa00000, 0xa01fff) AM_DEVREADWRITE("tc0280grd", tc0280grd_device, tc0280grd_word_r, tc0280grd_word_w) /* ROZ tilemap */ |
| 714 | AM_RANGE(0xa02000, 0xa0200f) AM_DEVWRITE("tc0280grd", tc0280grd_device, tc0280grd_ctrl_word_w) |
| 715 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 716 | 716 | ADDRESS_MAP_END |
| 717 | 717 | |
| 718 | 718 | static ADDRESS_MAP_START( megab_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 723 | 723 | AM_RANGE(0x180000, 0x180fff) AM_READWRITE(cchip2_word_r, cchip2_word_w) AM_SHARE("cchip2_ram") |
| 724 | 724 | AM_RANGE(0x200000, 0x20ffff) AM_RAM |
| 725 | 725 | AM_RANGE(0x300000, 0x301fff) AM_RAM_WRITE(paletteram_RRRRGGGGBBBBxxxx_word_w) AM_SHARE("paletteram") |
| 726 | | AM_RANGE(0x400000, 0x40001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 726 | AM_RANGE(0x400000, 0x40001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 727 | 727 | AM_RANGE(0x600000, 0x60ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 728 | 728 | AM_RANGE(0x610000, 0x61ffff) AM_RAM /* unused? */ |
| 729 | 729 | AM_RANGE(0x620000, 0x62000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| r23922 | r23923 | |
| 742 | 742 | AM_RANGE(0x500000, 0x50ffff) AM_DEVREADWRITE("tc0100scn_2", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 743 | 743 | AM_RANGE(0x520000, 0x52000f) AM_DEVREADWRITE("tc0100scn_2", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 744 | 744 | AM_RANGE(0x600000, 0x60ffff) AM_RAM AM_SHARE("spriteram") |
| 745 | | AM_RANGE(0x800000, 0x80001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) |
| 745 | AM_RANGE(0x800000, 0x80001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0xff00) |
| 746 | 746 | ADDRESS_MAP_END |
| 747 | 747 | |
| 748 | 748 | static ADDRESS_MAP_START( cameltry_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 756 | 756 | AM_RANGE(0x800000, 0x813fff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 757 | 757 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 758 | 758 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 759 | | AM_RANGE(0xa00000, 0xa01fff) AM_DEVREADWRITE_LEGACY("tc0280grd", tc0280grd_word_r, tc0280grd_word_w) /* ROZ tilemap */ |
| 760 | | AM_RANGE(0xa02000, 0xa0200f) AM_DEVWRITE_LEGACY("tc0280grd", tc0280grd_ctrl_word_w) |
| 761 | | AM_RANGE(0xd00000, 0xd0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 759 | AM_RANGE(0xa00000, 0xa01fff) AM_DEVREADWRITE("tc0280grd", tc0280grd_device, tc0280grd_word_r, tc0280grd_word_w) /* ROZ tilemap */ |
| 760 | AM_RANGE(0xa02000, 0xa0200f) AM_DEVWRITE("tc0280grd", tc0280grd_device, tc0280grd_ctrl_word_w) |
| 761 | AM_RANGE(0xd00000, 0xd0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 762 | 762 | ADDRESS_MAP_END |
| 763 | 763 | |
| 764 | 764 | static ADDRESS_MAP_START( qtorimon_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 784 | 784 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 785 | 785 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 786 | 786 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 787 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 787 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 788 | 788 | ADDRESS_MAP_END |
| 789 | 789 | |
| 790 | 790 | static ADDRESS_MAP_START( quizhq_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 832 | 832 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 833 | 833 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 834 | 834 | // AM_RANGE(0xa00000, 0xa00001) AM_WRITENOP /* ?? */ |
| 835 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 835 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 836 | 836 | ADDRESS_MAP_END |
| 837 | 837 | |
| 838 | 838 | static ADDRESS_MAP_START( growl_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 855 | 855 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 856 | 856 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 857 | 857 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 858 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 858 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 859 | 859 | ADDRESS_MAP_END |
| 860 | 860 | |
| 861 | 861 | static ADDRESS_MAP_START( mjnquest_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 883 | 883 | AM_RANGE(0x300000, 0x30000f) AM_WRITE(taitof2_spritebank_w) /* updated at $a6e, off irq5 */ |
| 884 | 884 | AM_RANGE(0x400000, 0x40ffff) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_word_r, tc0480scp_word_w) /* tilemaps */ |
| 885 | 885 | AM_RANGE(0x430000, 0x43002f) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_ctrl_word_r, tc0480scp_ctrl_word_w) |
| 886 | | AM_RANGE(0x500000, 0x50001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* 500002 written like a watchdog?! */ |
| 886 | AM_RANGE(0x500000, 0x50001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* 500002 written like a watchdog?! */ |
| 887 | 887 | AM_RANGE(0x600000, 0x601fff) AM_RAM_WRITE(paletteram_RRRRGGGGBBBBxxxx_word_w) AM_SHARE("paletteram") |
| 888 | 888 | AM_RANGE(0x700006, 0x700007) AM_WRITE(taitof2_4p_coin_word_w) |
| 889 | 889 | AM_RANGE(0x700000, 0x700001) AM_READ_PORT("DSWA") |
| r23922 | r23923 | |
| 909 | 909 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 910 | 910 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 911 | 911 | AM_RANGE(0xa20000, 0xa20001) AM_WRITE(koshien_spritebank_w) |
| 912 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) |
| 912 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0xff00) |
| 913 | 913 | ADDRESS_MAP_END |
| 914 | 914 | |
| 915 | 915 | static ADDRESS_MAP_START( yuyugogo_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 939 | 939 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 940 | 940 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 941 | 941 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 942 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* b00002 written like a watchdog?! */ |
| 942 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* b00002 written like a watchdog?! */ |
| 943 | 943 | ADDRESS_MAP_END |
| 944 | 944 | |
| 945 | 945 | static ADDRESS_MAP_START( solfigtr_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 960 | 960 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 961 | 961 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 962 | 962 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 963 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 963 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 964 | 964 | ADDRESS_MAP_END |
| 965 | 965 | |
| 966 | 966 | static ADDRESS_MAP_START( qzquest_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 980 | 980 | AM_RANGE(0x200000, 0x200001) AM_DEVWRITE8("tc0140syt", tc0140syt_device, tc0140syt_port_w, 0xff00) |
| 981 | 981 | AM_RANGE(0x200002, 0x200003) AM_DEVREADWRITE8("tc0140syt", tc0140syt_device, tc0140syt_comm_r, tc0140syt_comm_w, 0xff00) |
| 982 | 982 | AM_RANGE(0x300000, 0x30ffff) AM_RAM |
| 983 | | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE_LEGACY("tc0430grw", tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 984 | | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE_LEGACY("tc0430grw", tc0430grw_ctrl_word_w) |
| 983 | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE("tc0430grw", tc0280grd_device, tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 984 | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE("tc0430grw", tc0280grd_device, tc0430grw_ctrl_word_w) |
| 985 | 985 | // AM_RANGE(0x500000, 0x500001) AM_WRITENOP /* ??? */ |
| 986 | 986 | AM_RANGE(0x600000, 0x603fff) AM_WRITE(taitof2_sprite_extension_w) AM_SHARE("sprite_ext") |
| 987 | 987 | AM_RANGE(0x700000, 0x701fff) AM_RAM_WRITE(paletteram_xRRRRRGGGGGBBBBB_word_w) AM_SHARE("paletteram") |
| 988 | 988 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 989 | 989 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 990 | 990 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 991 | | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) |
| 991 | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0xff00) |
| 992 | 992 | AM_RANGE(0xb00000, 0xb0000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 993 | 993 | ADDRESS_MAP_END |
| 994 | 994 | |
| r23922 | r23923 | |
| 999 | 999 | // AM_RANGE(0x42000c, 0x42000f) AM_WRITENOP /* zeroed */ |
| 1000 | 1000 | AM_RANGE(0x500000, 0x50ffff) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_word_r, tc0480scp_word_w) /* tilemaps */ |
| 1001 | 1001 | AM_RANGE(0x530000, 0x53002f) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_ctrl_word_r, tc0480scp_ctrl_word_w) |
| 1002 | | AM_RANGE(0x600000, 0x60001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) |
| 1002 | AM_RANGE(0x600000, 0x60001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) |
| 1003 | 1003 | AM_RANGE(0x700000, 0x703fff) AM_RAM_WRITE(paletteram_RRRRGGGGBBBBxxxx_word_w) AM_SHARE("paletteram") |
| 1004 | 1004 | AM_RANGE(0x800000, 0x80000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_wordswap_r, halfword_wordswap_w) |
| 1005 | 1005 | AM_RANGE(0x900000, 0x900001) AM_DEVWRITE8("tc0140syt", tc0140syt_device, tc0140syt_port_w, 0xff00) |
| r23922 | r23923 | |
| 1046 | 1046 | AM_RANGE(0x400000, 0x40ffff) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_word_r, tc0480scp_word_w) /* tilemaps */ |
| 1047 | 1047 | // AM_RANGE(0x42000c, 0x42000f) AM_WRITENOP /* zeroed */ |
| 1048 | 1048 | AM_RANGE(0x430000, 0x43002f) AM_DEVREADWRITE_LEGACY("tc0480scp", tc0480scp_ctrl_word_r, tc0480scp_ctrl_word_w) |
| 1049 | | AM_RANGE(0x500000, 0x50001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* uses 500002 like a watchdog !? */ |
| 1049 | AM_RANGE(0x500000, 0x50001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* uses 500002 like a watchdog !? */ |
| 1050 | 1050 | AM_RANGE(0x600000, 0x601fff) AM_RAM_WRITE(paletteram_RRRRGGGGBBBBxxxx_word_w) AM_SHARE("paletteram") |
| 1051 | 1051 | AM_RANGE(0x700000, 0x700001) AM_READ_PORT("DSWA") |
| 1052 | 1052 | AM_RANGE(0x700002, 0x700003) AM_READ_PORT("DSWB") |
| r23922 | r23923 | |
| 1065 | 1065 | AM_RANGE(0x400000, 0x400fff) AM_WRITE(taitof2_sprite_extension_w) AM_SHARE("sprite_ext") |
| 1066 | 1066 | AM_RANGE(0x500000, 0x501fff) AM_RAM_WRITE(paletteram_RRRRGGGGBBBBxxxx_word_w) AM_SHARE("paletteram") |
| 1067 | 1067 | AM_RANGE(0x600000, 0x60ffff) AM_RAM |
| 1068 | | AM_RANGE(0x700000, 0x70001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 1068 | AM_RANGE(0x700000, 0x70001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 1069 | 1069 | AM_RANGE(0x800000, 0x80ffff) AM_RAM AM_SHARE("spriteram") |
| 1070 | 1070 | AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 1071 | 1071 | AM_RANGE(0x920000, 0x92000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| r23922 | r23923 | |
| 1085 | 1085 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 1086 | 1086 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 1087 | 1087 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 1088 | | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 1088 | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 1089 | 1089 | AM_RANGE(0xb00000, 0xb0000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 1090 | 1090 | ADDRESS_MAP_END |
| 1091 | 1091 | |
| r23922 | r23923 | |
| 1102 | 1102 | AM_RANGE(0x900000, 0x90ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 1103 | 1103 | AM_RANGE(0x920000, 0x92000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 1104 | 1104 | AM_RANGE(0xa00000, 0xa0000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 1105 | | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 1105 | AM_RANGE(0xb00000, 0xb0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 1106 | 1106 | ADDRESS_MAP_END |
| 1107 | 1107 | |
| 1108 | 1108 | static ADDRESS_MAP_START( qcrayon2_map, AS_PROGRAM, 16, taitof2_state ) |
| r23922 | r23923 | |
| 1114 | 1114 | AM_RANGE(0x520000, 0x52000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 1115 | 1115 | AM_RANGE(0x600000, 0x67ffff) AM_ROM AM_REGION("extra", 0) /* extra data rom */ |
| 1116 | 1116 | AM_RANGE(0x700000, 0x70000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 1117 | | AM_RANGE(0x900000, 0x90001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0x00ff) /* ?? */ |
| 1117 | AM_RANGE(0x900000, 0x90001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0x00ff) /* ?? */ |
| 1118 | 1118 | AM_RANGE(0xa00000, 0xa00001) AM_DEVWRITE8("tc0140syt", tc0140syt_device, tc0140syt_port_w, 0xff00) |
| 1119 | 1119 | AM_RANGE(0xa00002, 0xa00003) AM_DEVREADWRITE8("tc0140syt", tc0140syt_device, tc0140syt_comm_r, tc0140syt_comm_w, 0xff00) |
| 1120 | 1120 | AM_RANGE(0xb00000, 0xb017ff) AM_WRITE(taitof2_sprite_extension_w) AM_SHARE("sprite_ext") |
| r23922 | r23923 | |
| 1125 | 1125 | AM_RANGE(0x200000, 0x200001) AM_DEVWRITE8("tc0140syt", tc0140syt_device, tc0140syt_port_w, 0xff00) |
| 1126 | 1126 | AM_RANGE(0x200002, 0x200003) AM_DEVREADWRITE8("tc0140syt", tc0140syt_device, tc0140syt_comm_r, tc0140syt_comm_w, 0xff00) |
| 1127 | 1127 | AM_RANGE(0x300000, 0x30ffff) AM_RAM |
| 1128 | | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE_LEGACY("tc0430grw", tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 1129 | | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE_LEGACY("tc0430grw", tc0430grw_ctrl_word_w) |
| 1128 | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE("tc0430grw", tc0280grd_device, tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 1129 | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE("tc0430grw", tc0280grd_device, tc0430grw_ctrl_word_w) |
| 1130 | 1130 | AM_RANGE(0x700000, 0x701fff) AM_RAM_WRITE(paletteram_xRRRRRGGGGGBBBBB_word_w) AM_SHARE("paletteram") |
| 1131 | 1131 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 1132 | 1132 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 1133 | 1133 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 1134 | | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) |
| 1134 | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0xff00) |
| 1135 | 1135 | AM_RANGE(0xb00000, 0xb0000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 1136 | 1136 | AM_RANGE(0xb00018, 0xb00019) AM_READ_PORT("PADDLE1") |
| 1137 | 1137 | AM_RANGE(0xb0001a, 0xb0001b) AM_READ_PORT("PADDLE2") |
| r23922 | r23923 | |
| 1142 | 1142 | AM_RANGE(0x000000, 0x0fffff) AM_ROM |
| 1143 | 1143 | AM_RANGE(0x200000, 0x200003) AM_READNOP AM_WRITE(driveout_sound_command_w) |
| 1144 | 1144 | AM_RANGE(0x300000, 0x30ffff) AM_RAM |
| 1145 | | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE_LEGACY("tc0430grw", tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 1146 | | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE_LEGACY("tc0430grw", tc0430grw_ctrl_word_w) |
| 1145 | AM_RANGE(0x400000, 0x401fff) AM_DEVREADWRITE("tc0430grw", tc0280grd_device, tc0430grw_word_r, tc0430grw_word_w) /* ROZ tilemap */ |
| 1146 | AM_RANGE(0x402000, 0x40200f) AM_DEVWRITE("tc0430grw", tc0280grd_device, tc0430grw_ctrl_word_w) |
| 1147 | 1147 | AM_RANGE(0x700000, 0x701fff) AM_RAM_WRITE(paletteram_xRRRRRGGGGGBBBBB_word_w) AM_SHARE("paletteram") |
| 1148 | 1148 | AM_RANGE(0x800000, 0x80ffff) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, word_r, word_w) /* tilemaps */ |
| 1149 | 1149 | AM_RANGE(0x820000, 0x82000f) AM_DEVREADWRITE("tc0100scn", tc0100scn_device, ctrl_word_r, ctrl_word_w) |
| 1150 | 1150 | AM_RANGE(0x900000, 0x90ffff) AM_RAM AM_SHARE("spriteram") |
| 1151 | | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8_LEGACY("tc0360pri", tc0360pri_w, 0xff00) |
| 1151 | AM_RANGE(0xa00000, 0xa0001f) AM_DEVWRITE8("tc0360pri", tc0360pri_device, write, 0xff00) |
| 1152 | 1152 | AM_RANGE(0xb00000, 0xb0000f) AM_DEVREADWRITE("tc0510nio", tc0510nio_device, halfword_r, halfword_w) |
| 1153 | 1153 | AM_RANGE(0xb00018, 0xb00019) AM_READ_PORT("PADDLE1") |
| 1154 | 1154 | AM_RANGE(0xb0001a, 0xb0001b) AM_READ_PORT("PADDLE2") |
| r23922 | r23923 | |
| 3102 | 3102 | MCFG_SCREEN_UPDATE_DRIVER(taitof2_state, screen_update_taitof2_pri_roz) |
| 3103 | 3103 | |
| 3104 | 3104 | MCFG_TC0100SCN_ADD("tc0100scn", dondokod_tc0100scn_intf) |
| 3105 | | MCFG_TC0430GRW_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3105 | MCFG_TC0280GRD_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3106 | 3106 | MCFG_TC0360PRI_ADD("tc0360pri") |
| 3107 | 3107 | MACHINE_CONFIG_END |
| 3108 | 3108 | |
| r23922 | r23923 | |
| 3155 | 3155 | MCFG_SCREEN_UPDATE_DRIVER(taitof2_state, screen_update_taitof2_pri_roz) |
| 3156 | 3156 | |
| 3157 | 3157 | MCFG_TC0100SCN_ADD("tc0100scn", dondokod_tc0100scn_intf) |
| 3158 | | MCFG_TC0430GRW_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3158 | MCFG_TC0280GRD_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3159 | 3159 | MCFG_TC0360PRI_ADD("tc0360pri") |
| 3160 | 3160 | MACHINE_CONFIG_END |
| 3161 | 3161 | |
| r23922 | r23923 | |
| 3604 | 3604 | MCFG_VIDEO_START_OVERRIDE(taitof2_state,taitof2_dondokod) |
| 3605 | 3605 | |
| 3606 | 3606 | MCFG_TC0100SCN_ADD("tc0100scn", dondokod_tc0100scn_intf) |
| 3607 | | MCFG_TC0430GRW_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3607 | MCFG_TC0280GRD_ADD("tc0280grd", taitof2_tc0280grd_intf) |
| 3608 | 3608 | MCFG_TC0360PRI_ADD("tc0360pri") |
| 3609 | 3609 | |
| 3610 | 3610 | /* sound hardware */ |