| Previous | 15994 Revisions | Next |
| r6354 Tuesday 10th November, 2009 at 21:59:00 UTC by Barry Rodewald |
|---|
| [FMTOWNS] Various updates: * Implemented VRAM page selection * Implemented FDC IRQ mask * Added FDC disk density select * Implemented TVRAM selection and display * Re-worked VRAM to read/write correctly in low memory. High memory mirror is now correct, and allows the startup logo to display correctly on the Marty/Car Marty. * Fixed ANK CG ROM enable. |
| [src/mess/drivers] | fmtowns.c |
| r6353 | r6354 | |
|---|---|---|
| 22 | 22 | |
| 23 | 23 | 16/5/09: Skeleton driver. |
| 24 | 24 | |
| 25 | Issues: | |
| 25 | Issues: | |
| 26 | 26 | |
| 27 | 27 | */ |
| 28 | 28 | |
| r6353 | r6354 | |
| 50 | 50 | * 0x00b0-bf: DMA controller 2 (uPD71071) |
| 51 | 51 | * 0x0200-0f: Floppy controller (MB8877A) |
| 52 | 52 | * 0x0400 : Video / CRTC (unknown) |
| 53 | * 0x0404 : | |
| 53 | * 0x0404 : D | |
| 54 | 54 | * 0x0440-5f: Video / CRTC (unknown) |
| 55 | 55 | * 0x0480 RW: bit 1 = disable BIOS ROM |
| 56 | * 0x04c0-cf: CD-ROM controller (unknown | |
| 56 | * 0x04c0-cf: CD-ROM controller (unknown | |
| 57 | 57 | * 0x04d5 : Sound mute |
| 58 | 58 | * 0x04d8 : YM3438 control port A / status |
| 59 | 59 | * 0x04da : YM3438 data port A / status |
| r6353 | r6354 | |
| 135 | 135 | static UINT8* towns_txtvram; |
| 136 | 136 | static UINT8 towns_vram_wplane; |
| 137 | 137 | static UINT8 towns_vram_rplane; |
| 138 | static UINT8 towns_vram_page_sel; | |
| 138 | 139 | static UINT8 towns_palette_select; |
| 139 | 140 | static UINT8 towns_palette_r[256]; |
| 140 | 141 | static UINT8 towns_palette_g[256]; |
| r6353 | r6354 | |
| 144 | 145 | static UINT8 towns_kanji_code_h; |
| 145 | 146 | static UINT8 towns_kanji_code_l; |
| 146 | 147 | static int towns_selected_drive; |
| 148 | static UINT8 towns_fdc_irq6mask; | |
| 147 | 149 | static UINT8* towns_serial_rom; |
| 148 | 150 | static int towns_srom_position; |
| 149 | 151 | static UINT8 towns_srom_clk; |
| r6353 | r6354 | |
| 155 | 157 | static UINT8 towns_timer_mask; |
| 156 | 158 | static UINT8 towns_crtc_mix; |
| 157 | 159 | static UINT16 towns_machine_id; // default is 0x0101 |
| 160 | static UINT8 towns_kb_status; | |
| 161 | static UINT8 towns_kb_irq1_enable; | |
| 162 | static UINT8 towns_kb_output; // key output | |
| 163 | static UINT8 towns_crtc_sel; // selected CRTC register | |
| 164 | static UINT16 towns_crtc_reg[32]; | |
| 165 | static UINT8 towns_tvram_enable; | |
| 158 | 166 | |
| 159 | ||
| 160 | 167 | static void towns_update_video_banks(const address_space* space); |
| 161 | 168 | static PIC8259_SET_INT_LINE( towns_pic_irq ); |
| 162 | 169 | |
| r6353 | r6354 | |
| 342 | 349 | * Floppy Disc Controller (MB8877A) |
| 343 | 350 | */ |
| 344 | 351 | |
| 352 | static WRITE_LINE_DEVICE_HANDLER( towns_mb8877a_irq_w ) | |
| 353 | { | |
| 354 | if(towns_fdc_irq6mask == 0) | |
| 355 | state = 0; | |
| 356 | pic8259_set_irq_line(device,6,state); // IRQ6 = FDC | |
| 357 | } | |
| 358 | ||
| 345 | 359 | static WRITE_LINE_DEVICE_HANDLER( towns_mb8877a_drq_w ) |
| 346 | 360 | { |
| 347 | 361 | upd71071_dmarq(device, state, 0); |
| r6353 | r6354 | |
| 373 | 387 | default: |
| 374 | 388 | logerror("FDC: read from invalid or unimplemented register %02x\n",offset); |
| 375 | 389 | } |
| 376 | return 0x | |
| 390 | return 0xff; | |
| 377 | 391 | } |
| 378 | 392 | |
| 379 | 393 | static WRITE8_HANDLER(towns_floppy_w) |
| r6353 | r6354 | |
| 401 | 415 | break; |
| 402 | 416 | case 0x08: |
| 403 | 417 | // bit 5 - CLKSEL |
| 404 | if( | |
| 418 | if( | |
| 405 | 419 | { |
| 406 | if(towns_selected_drive != 0 && towns_selected_drive < 2) | |
| 407 | { | |
| 408 | floppy_drive_set_motor_state(floppy_get_device(space->machine, towns_selected_drive-1), data & 0x10); | |
| 409 | floppy_drive_set_ready_state(floppy_get_device(space->machine, towns_selected_drive-1), data & 0x10,0); | |
| 410 | } | |
| 420 | floppy_drive_set_motor_state(floppy_get_device(space->machine, towns_selected_drive-1), data & 0x10); | |
| 421 | floppy_drive_set_ready_state(floppy_get_device(space->machine, towns_selected_drive-1), data & 0x10,0); | |
| 411 | 422 | } |
| 412 | 423 | wd17xx_set_side(fdc,(data & 0x04)>>2); |
| 413 | // bit 1 - DDEN | |
| 414 | // bit 0 - IRQMSK | |
| 424 | wd17xx_set_density(fdc,(data & 0x02)>>1); | |
| 425 | towns_fdc_irq6mask = data & 0x01; | |
| 415 | 426 | logerror("FDC: write %02x to offset 0x08\n",data); |
| 416 | 427 | break; |
| 417 | 428 | case 0x0c: // drive select |
| r6353 | r6354 | |
| 456 | 467 | wd17xx_data_w(fdc,0,data); |
| 457 | 468 | } |
| 458 | 469 | |
| 470 | /* | |
| 471 | * port 0x440-0x443 - CRTC | |
| 472 | * 0x440 = register select | |
| 473 | * 0x442/3 = register data (16-bit) | |
| 474 | * | |
| 475 | */ | |
| 459 | 476 | static READ8_HANDLER(towns_video_440_r) |
| 460 | 477 | { |
| 461 | logerror("VID: read port %04x\n",offset+0x440); | |
| 478 | switch(offset) | |
| 479 | { | |
| 480 | case 0x00: | |
| 481 | return towns_crtc_sel; | |
| 482 | case 0x02: | |
| 483 | logerror("CRTC: reading register %i (0x442) [%04x]\n",towns_crtc_sel,towns_crtc_reg[towns_crtc_sel]); | |
| 484 | return towns_crtc_reg[towns_crtc_sel] & 0x00ff; | |
| 485 | case 0x03: | |
| 486 | logerror("CRTC: reading register %i (0x443) [%04x]\n",towns_crtc_sel,towns_crtc_reg[towns_crtc_sel]); | |
| 487 | return (towns_crtc_reg[towns_crtc_sel] & 0xff00) >> 8; | |
| 488 | default: | |
| 489 | logerror("VID: read port %04x\n",offset+0x440); | |
| 490 | } | |
| 462 | 491 | return 0x00; |
| 463 | 492 | } |
| 464 | 493 | |
| 465 | 494 | static WRITE8_HANDLER(towns_video_440_w) |
| 466 | 495 | { |
| 467 | logerror("VID: wrote 0x%02x to port %04x\n",data,offset+0x440); | |
| 496 | switch(offset) | |
| 497 | { | |
| 498 | case 0x00: | |
| 499 | towns_crtc_sel = data; | |
| 500 | break; | |
| 501 | case 0x02: | |
| 502 | logerror("CRTC: writing register %i (0x442) [%02x]\n",towns_crtc_sel,data); | |
| 503 | towns_crtc_reg[towns_crtc_sel] = | |
| 504 | (towns_crtc_reg[towns_crtc_sel] & 0xff00) | data; | |
| 505 | break; | |
| 506 | case 0x03: | |
| 507 | logerror("CRTC: writing register %i (0x443) [%02x]\n",towns_crtc_sel,data); | |
| 508 | towns_crtc_reg[towns_crtc_sel] = | |
| 509 | (towns_crtc_reg[towns_crtc_sel] & 0x00ff) | (data << 8); | |
| 510 | break; | |
| 511 | default: | |
| 512 | logerror("VID: wrote 0x%02x to port %04x\n",data,offset+0x440); | |
| 513 | } | |
| 468 | 514 | } |
| 469 | 515 | |
| 470 | 516 | static READ8_HANDLER(towns_video_5c8_r) |
| 471 | 517 | { |
| 472 | 518 | logerror("VID: read port %04x\n",offset+0x5c8); |
| 519 | switch(offset) | |
| 520 | { | |
| 521 | case 0x00: // 0x5c8 - disable TVRAM? | |
| 522 | if(towns_tvram_enable != 0) | |
| 523 | { | |
| 524 | towns_tvram_enable = 0; | |
| 525 | return 0x80; | |
| 526 | } | |
| 527 | else | |
| 528 | return 0x00; | |
| 529 | } | |
| 473 | 530 | return 0x00; |
| 474 | 531 | } |
| 475 | 532 | |
| 476 | 533 | static WRITE8_HANDLER(towns_video_5c8_w) |
| 477 | 534 | { |
| 535 | const device_config* dev = devtag_get_device(space->machine,"pic8259_slave"); | |
| 536 | switch(offset) | |
| 537 | { | |
| 538 | case 0x02: // 0x5ca - VSync clear? | |
| 539 | pic8259_set_irq_line(dev,3,0); | |
| 540 | break; | |
| 541 | } | |
| 478 | 542 | logerror("VID: wrote 0x%02x to port %04x\n",data,offset+0x5c8); |
| 479 | 543 | } |
| 480 | 544 | |
| r6353 | r6354 | |
| 540 | 604 | logerror("VID: wrote 0x%02x to port %04x\n",data,offset+0xfd90); |
| 541 | 605 | } |
| 542 | 606 | |
| 607 | /* | |
| 608 | * Port 0x600-0x607 - Keyboard controller (8042 MCU) | |
| 609 | * | |
| 610 | */ | |
| 543 | 611 | static READ8_HANDLER(towns_keyboard_r) |
| 544 | 612 | { |
| 545 | logerror("KB: read offset %02x\n",offset); | |
| 613 | switch(offset) | |
| 614 | { | |
| 615 | case 0: // scancode output | |
| 616 | logerror("KB: read keyboard output port, returning %02x\n",towns_kb_output); | |
| 617 | towns_kb_status &= ~0x01; | |
| 618 | return towns_kb_output; | |
| 619 | case 1: // status | |
| 620 | logerror("KB: read status port, returning %02x\n",towns_kb_status); | |
| 621 | return towns_kb_status; | |
| 622 | default: | |
| 623 | logerror("KB: read offset %02x\n",offset); | |
| 624 | } | |
| 546 | 625 | return 0x00; |
| 547 | 626 | } |
| 548 | 627 | |
| 549 | 628 | static WRITE8_HANDLER(towns_keyboard_w) |
| 550 | 629 | { |
| 551 | logerror("KB: wrote 0x%02x to offset %02x\n",data,offset); | |
| 630 | const device_config* dev = devtag_get_device(space->machine,"pic8259_master"); | |
| 631 | ||
| 632 | switch(offset) | |
| 633 | { | |
| 634 | case 0: // command input | |
| 635 | towns_kb_status &= ~0x08; | |
| 636 | towns_kb_status |= 0x01; | |
| 637 | break; | |
| 638 | case 1: // control | |
| 639 | towns_kb_status |= 0x08; | |
| 640 | break; | |
| 641 | case 2: // IRQ1 enable | |
| 642 | towns_kb_irq1_enable = data & 0x01; | |
| 643 | pic8259_set_irq_line(dev,1,1); | |
| 644 | pic8259_set_irq_line(dev,1,0); | |
| 645 | break; | |
| 646 | default: | |
| 647 | logerror("KB: wrote 0x%02x to offset %02x\n",data,offset); | |
| 648 | } | |
| 552 | 649 | } |
| 553 | 650 | |
| 554 | 651 | /* |
| r6353 | r6354 | |
| 673 | 770 | towns_cmos[offset] = data; |
| 674 | 771 | } |
| 675 | 772 | |
| 773 | static READ8_HANDLER( towns_gfx_r ) | |
| 774 | { | |
| 775 | if(towns_mainmem_enable != 0) | |
| 776 | return messram_get_ptr(devtag_get_device(space->machine, "messram"))[offset+0xc0000]; | |
| 777 | ||
| 778 | if(towns_vram_page_sel != 0) | |
| 779 | offset += 0x20000; | |
| 780 | ||
| 781 | return 0; | |
| 782 | } | |
| 783 | ||
| 676 | 784 | static WRITE8_HANDLER( towns_gfx_w ) |
| 677 | 785 | { |
| 678 | 786 | if(towns_mainmem_enable != 0) |
| r6353 | r6354 | |
| 680 | 788 | messram_get_ptr(devtag_get_device(space->machine, "messram"))[offset+0xc0000] = data; |
| 681 | 789 | return; |
| 682 | 790 | } |
| 791 | offset = offset << 2; | |
| 792 | if(towns_vram_page_sel != 0) | |
| 793 | offset += 0x20000; | |
| 794 | if(towns_vram_wplane & 0x08) | |
| 795 | { | |
| 796 | towns_gfxvram[offset] &= ~0x88; | |
| 797 | towns_gfxvram[offset] |= ((data & 0x80) >> 4) | ((data & 0x40) << 1); | |
| 798 | towns_gfxvram[offset + 1] &= ~0x88; | |
| 799 | towns_gfxvram[offset + 1] |= ((data & 0x20) >> 2) | ((data & 0x10) << 3); | |
| 800 | towns_gfxvram[offset + 2] &= ~0x88; | |
| 801 | towns_gfxvram[offset + 2] |= ((data & 0x08)) | ((data & 0x04) << 5); | |
| 802 | towns_gfxvram[offset + 3] &= ~0x88; | |
| 803 | towns_gfxvram[offset + 3] |= ((data & 0x02) << 2) | ((data & 0x01) << 7); | |
| 804 | } | |
| 805 | if(towns_vram_wplane & 0x04) | |
| 806 | { | |
| 807 | towns_gfxvram[offset] &= ~0x44; | |
| 808 | towns_gfxvram[offset] |= ((data & 0x80) >> 5) | ((data & 0x40)); | |
| 809 | towns_gfxvram[offset + 1] &= ~0x44; | |
| 810 | towns_gfxvram[offset + 1] |= ((data & 0x20) >> 3) | ((data & 0x10) << 2); | |
| 811 | towns_gfxvram[offset + 2] &= ~0x44; | |
| 812 | towns_gfxvram[offset + 2] |= ((data & 0x08) >> 1) | ((data & 0x04) << 4); | |
| 813 | towns_gfxvram[offset + 3] &= ~0x44; | |
| 814 | towns_gfxvram[offset + 3] |= ((data & 0x02) << 1) | ((data & 0x01) << 6); | |
| 815 | } | |
| 816 | if(towns_vram_wplane & 0x02) | |
| 817 | { | |
| 818 | towns_gfxvram[offset] &= ~0x22; | |
| 819 | towns_gfxvram[offset] |= ((data & 0x80) >> 6) | ((data & 0x40) >> 1); | |
| 820 | towns_gfxvram[offset + 1] &= ~0x22; | |
| 821 | towns_gfxvram[offset + 1] |= ((data & 0x20) >> 4) | ((data & 0x10) << 1); | |
| 822 | towns_gfxvram[offset + 2] &= ~0x22; | |
| 823 | towns_gfxvram[offset + 2] |= ((data & 0x08) >> 2) | ((data & 0x04) << 3); | |
| 824 | towns_gfxvram[offset + 3] &= ~0x22; | |
| 825 | towns_gfxvram[offset + 3] |= ((data & 0x02)) | ((data & 0x01) << 5); | |
| 826 | } | |
| 683 | 827 | if(towns_vram_wplane & 0x01) |
| 684 | towns_gfxvram[offset] = data; | |
| 685 | if(towns_vram_wplane & 0x02) | |
| 686 | towns_gfxvram[offset + 0x8000] = data; | |
| 687 | if(towns_vram_wplane & 0x04) | |
| 688 | towns_gfxvram[offset + 0x10000] = data; | |
| 689 | if(towns_vram_wplane & 0x08) | |
| 690 | towns_gfxvram[offset + 0x18000] = data; | |
| 828 | { | |
| 829 | towns_gfxvram[offset] &= ~0x11; | |
| 830 | towns_gfxvram[offset] |= ((data & 0x80) >> 7) | ((data & 0x40) >> 2); | |
| 831 | towns_gfxvram[offset + 1] &= ~0x11; | |
| 832 | towns_gfxvram[offset + 1] |= ((data & 0x20) >> 5) | ((data & 0x10)); | |
| 833 | towns_gfxvram[offset + 2] &= ~0x11; | |
| 834 | towns_gfxvram[offset + 2] |= ((data & 0x08) >> 3) | ((data & 0x04) << 2); | |
| 835 | towns_gfxvram[offset + 3] &= ~0x11; | |
| 836 | towns_gfxvram[offset + 3] |= ((data & 0x02) >> 1) | ((data & 0x01) << 4); | |
| 837 | } | |
| 691 | 838 | } |
| 692 | 839 | |
| 693 | 840 | static READ8_HANDLER( towns_video_cff80_r ) |
| r6353 | r6354 | |
| 702 | 849 | return towns_crtc_mix; |
| 703 | 850 | case 0x01: // read/write plane select (bit 0-3 write, bit 6-7 read) |
| 704 | 851 | return ((towns_vram_rplane << 6) & 0xc0) | towns_vram_wplane; |
| 852 | case 0x03: // VRAM page select (bit 5) | |
| 853 | if(towns_vram_page_sel != 0) | |
| 854 | return 0x10; | |
| 855 | else | |
| 856 | return 0x00; | |
| 705 | 857 | case 0x16: // Kanji character data |
| 706 | 858 | return ROM[(towns_kanji_offset << 1) + 0x180000]; |
| 707 | 859 | case 0x17: // Kanji character data |
| r6353 | r6354 | |
| 737 | 889 | towns_update_video_banks(space); |
| 738 | 890 | logerror("VGA: VRAM wplane select = 0x%02x\n",towns_vram_wplane); |
| 739 | 891 | break; |
| 892 | case 0x03: // VRAM page select (bit 5) | |
| 893 | towns_vram_page_sel = data & 0x10; | |
| 894 | break; | |
| 740 | 895 | case 0x14: // Kanji offset (high) |
| 741 | 896 | towns_kanji_code_h = data & 0x7f; |
| 742 | 897 | break; |
| r6353 | r6354 | |
| 768 | 923 | } |
| 769 | 924 | break; |
| 770 | 925 | case 0x19: // ANK CG ROM |
| 771 | towns_ankcg_enable = data & 0x0 | |
| 926 | towns_ankcg_enable = data & 0x0 | |
| 772 | 927 | towns_update_video_banks(space); |
| 773 | 928 | break; |
| 774 | 929 | default: |
| r6353 | r6354 | |
| 784 | 939 | { |
| 785 | 940 | ROM = memory_region(space->machine,"user"); |
| 786 | 941 | |
| 787 | memory_set_bankptr(space->machine,1,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc0000); | |
| 788 | memory_set_bankptr(space->machine,2,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc8000); | |
| 789 | memory_set_bankptr(space->machine,3,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc9000); | |
| 790 | memory_set_bankptr(space->machine,4,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca000); | |
| 791 | memory_set_bankptr(space->machine,5,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca000); | |
| 792 | memory_set_bankptr(space->machine,10,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca800); | |
| 942 | // memory_set_bankptr(space->machine,1,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc0000); | |
| 943 | // memory_set_bankptr(space->machine,2,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc8000); | |
| 944 | // memory_set_bankptr(space->machine,3,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc9000); | |
| 945 | // memory_set_bankptr(space->machine,4,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca000); | |
| 946 | // memory_set_bankptr(space->machine,5,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca000); | |
| 947 | // memory_set_bankptr(space->machine,10,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca800); | |
| 793 | 948 | memory_set_bankptr(space->machine,6,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xcb000); |
| 794 | 949 | memory_set_bankptr(space->machine,7,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xcb000); |
| 795 | 950 | memory_set_bankptr(space->machine,8,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xcc000); |
| r6353 | r6354 | |
| 804 | 959 | { |
| 805 | 960 | ROM = memory_region(space->machine,"user"); |
| 806 | 961 | |
| 807 | memory_set_bankptr(space->machine,1,towns_gfxvram+(towns_vram_rplane*0x8000)); | |
| 808 | memory_set_bankptr(space->machine,2,towns_txtvram); | |
| 809 | memory_set_bankptr(space->machine,3,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc9000); | |
| 810 | if(towns_ankcg_enable == 0) | |
| 811 | memory_set_bankptr(space->machine,4,ROM+0x180000+0x3d000); // ANK CG 8x8 | |
| 812 | else | |
| 813 | memory_set_bankptr(space->machine,4,towns_txtvram+0x2000); | |
| 814 | memory_set_bankptr(space->machine,5,towns_txtvram+0x2000); | |
| 815 | memory_set_bankptr(space->machine,10,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca800); | |
| 816 | if(towns_ankcg_enable == 0) | |
| 962 | // memory_set_bankptr(space->machine,1,towns_gfxvram+(towns_vram_rplane*0x8000)); | |
| 963 | // memory_set_bankptr(space->machine,2,towns_txtvram); | |
| 964 | // memory_set_bankptr(space->machine,3,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xc9000); | |
| 965 | // if(towns_ankcg_enable != 0) | |
| 966 | // memory_set_bankptr(space->machine,4,ROM+0x180000+0x3d000); // ANK CG 8x8 | |
| 967 | // else | |
| 968 | // memory_set_bankptr(space->machine,4,towns_txtvram+0x2000); | |
| 969 | // memory_set_bankptr(space->machine,5,towns_txtvram+0x2000); | |
| 970 | // memory_set_bankptr(space->machine,10,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xca800); | |
| 971 | if(towns_ankcg_enable != 0) | |
| 817 | 972 | memory_set_bankptr(space->machine,6,ROM+0x180000+0x3d800); // ANK CG 8x16 |
| 818 | 973 | else |
| 819 | 974 | memory_set_bankptr(space->machine,6,messram_get_ptr(devtag_get_device(space->machine, "messram"))+0xcb000); |
| r6353 | r6354 | |
| 864 | 1019 | |
| 865 | 1020 | static READ32_HANDLER( towns_video_404_r ) |
| 866 | 1021 | { |
| 867 | if(towns_mainmem_enable != 0) | |
| 868 | return 0x00000080; | |
| 869 | ||
| 1022 | if(ACCESSING_BITS_0_7) | |
| 1023 | { | |
| 1024 | if(towns_mainmem_enable != 0) | |
| 1025 | return 0x00000080; | |
| 1026 | } | |
| 870 | 1027 | return 0; |
| 871 | 1028 | } |
| 872 | 1029 | |
| r6353 | r6354 | |
| 908 | 1065 | } |
| 909 | 1066 | } |
| 910 | 1067 | |
| 1068 | ||
| 1069 | /* | |
| 1070 | * Sprite RAM, low memory | |
| 1071 | * Writing to 0xc8xxx or 0xcaxxx activates TVRAM mode | |
| 1072 | * Writing to I/O port 0x5c8 disables TVRAM mode | |
| 1073 | * (bit 7 returns high is TVRAM mode was previously active) | |
| 1074 | * | |
| 1075 | * In TVRAM mode: | |
| 1076 | * 0xc8000-0xc8fff: ASCII text (2 bytes each: ISO646 code, then attribute) | |
| 1077 | * 0xca000-0xcafff: JIS code | |
| 1078 | */ | |
| 1079 | static READ8_HANDLER(towns_spriteram_low_r) | |
| 1080 | { | |
| 1081 | UINT8* RAM = messram_get_ptr(devtag_get_device(space->machine, "messram")); | |
| 1082 | UINT8* ROM = memory_region(space->machine,"user"); | |
| 1083 | ||
| 1084 | if(offset < 0x1000) | |
| 1085 | { // 0xc8000-0xc8fff | |
| 1086 | if(towns_mainmem_enable == 0) | |
| 1087 | return towns_txtvram[offset]; | |
| 1088 | else | |
| 1089 | return RAM[offset + 0xc8000]; | |
| 1090 | } | |
| 1091 | if(offset >= 0x1000 && offset < 0x2000) | |
| 1092 | { // 0xc9000-0xc9fff | |
| 1093 | return RAM[offset + 0xc9000]; | |
| 1094 | } | |
| 1095 | if(offset >= 0x2000 && offset < 0x3000) | |
| 1096 | { // 0xca000-0xcafff | |
| 1097 | if(towns_mainmem_enable == 0) | |
| 1098 | { | |
| 1099 | if(towns_ankcg_enable != 0 && offset < 0x2800) | |
| 1100 | return ROM[0x180000 + 0x3d000 + (offset-0x2000)]; | |
| 1101 | return towns_txtvram[offset]; | |
| 1102 | } | |
| 1103 | else | |
| 1104 | return RAM[offset + 0xca000]; | |
| 1105 | } | |
| 1106 | return 0x00; | |
| 1107 | } | |
| 1108 | ||
| 1109 | static WRITE8_HANDLER(towns_spriteram_low_w) | |
| 1110 | { | |
| 1111 | UINT8* RAM = messram_get_ptr(devtag_get_device(space->machine, "messram")); | |
| 1112 | if(offset < 0x1000) | |
| 1113 | { // 0xc8000-0xc8fff | |
| 1114 | towns_tvram_enable = 1; | |
| 1115 | if(towns_mainmem_enable == 0) | |
| 1116 | towns_txtvram[offset] = data; | |
| 1117 | else | |
| 1118 | RAM[offset + 0xc8000] = data; | |
| 1119 | } | |
| 1120 | if(offset >= 0x1000 && offset < 0x2000) | |
| 1121 | { | |
| 1122 | RAM[offset + 0xc9000] = data; | |
| 1123 | } | |
| 1124 | if(offset >= 0x2000 && offset < 0x3000) | |
| 1125 | { // 0xca000-0xcafff | |
| 1126 | towns_tvram_enable = 1; | |
| 1127 | if(towns_mainmem_enable == 0) | |
| 1128 | towns_txtvram[offset] = data; | |
| 1129 | else | |
| 1130 | RAM[offset + 0xca000] = data; | |
| 1131 | } | |
| 1132 | } | |
| 1133 | ||
| 1134 | ||
| 911 | 1135 | /* CMOS RTC |
| 912 | 1136 | * 0x70: Data port |
| 913 | 1137 | * 0x80: Register select |
| r6353 | r6354 | |
| 1013 | 1237 | static PIC8259_SET_INT_LINE( towns_pic_irq ) |
| 1014 | 1238 | { |
| 1015 | 1239 | cputag_set_input_line(device->machine,"maincpu",0,interrupt ? HOLD_LINE : CLEAR_LINE); |
| 1016 | logerror("PIC#1: set IRQ line to %i\n",interrupt); | |
| 1240 | // logerror("PIC#1: set IRQ line to %i\n",interrupt); | |
| 1017 | 1241 | } |
| 1018 | 1242 | |
| 1019 | 1243 | static PIC8259_SET_INT_LINE( towns_slave_pic_irq ) |
| r6353 | r6354 | |
| 1021 | 1245 | const device_config* dev = devtag_get_device(device->machine,"pic8259_master"); |
| 1022 | 1246 | |
| 1023 | 1247 | pic8259_set_irq_line(dev,7,interrupt); |
| 1024 | logerror("PIC#2: set IRQ line to %i\n",interrupt); | |
| 1248 | // logerror("PIC#2: set IRQ line to %i\n",interrupt); | |
| 1025 | 1249 | } |
| 1026 | 1250 | |
| 1027 | 1251 | static PIT8253_OUTPUT_CHANGED( towns_pit_out0_changed ) |
| r6353 | r6354 | |
| 1036 | 1260 | |
| 1037 | 1261 | static PIT8253_OUTPUT_CHANGED( towns_pit_out1_changed ) |
| 1038 | 1262 | { |
| 1039 | const device_config* dev = devtag_get_device(device->machine,"pic8259_master"); | |
| 1263 | // const device_config* dev = devtag_get_device(device->machine,"pic8259_master"); | |
| 1040 | 1264 | |
| 1041 | 1265 | if(towns_timer_mask & 0x02) |
| 1042 | 1266 | { |
| 1043 | pic8259_set_irq_line(dev,0,state); | |
| 1267 | // pic8259_set_irq_line(dev,0,state); | |
| 1044 | 1268 | } |
| 1045 | 1269 | } |
| 1046 | 1270 | |
| r6353 | r6354 | |
| 1048 | 1272 | // memory map based on FM-Towns/Bochs (Bochs modified to emulate the FM-Towns) |
| 1049 | 1273 | // may not be (and probably is not) correct |
| 1050 | 1274 | AM_RANGE(0x00000000, 0x000bffff) AM_RAM |
| 1051 | AM_RANGE(0x000c0000, 0x000c7fff) AM_READ(SMH_BANK(1)) | |
| 1052 | AM_RANGE(0x000c0000, 0x000c7fff) AM_WRITE8(towns_gfx_w,0xffffffff) | |
| 1275 | AM_RANGE(0x000c0000, 0x000c7fff) AM_READWRITE8(towns_gfx_r,towns_gfx_w,0xffffffff) | |
| 1276 | // AM_RANGE(0x000c8000, 0x000c8fff) AM_READWRITE(SMH_BANK(2),SMH_BANK(2)) | |
| 1277 | // AM_RANGE(0x000c9000, 0x000c9fff) AM_READWRITE(SMH_BANK(3),SMH_BANK(3)) | |
| 1278 | // AM_RANGE(0x000ca000, 0x000ca7ff) AM_READWRITE(SMH_BANK(4),SMH_BANK(5)) | |
| 1279 | // AM_RANGE(0x000ca800, 0x000cafff) AM_READWRITE(SMH_BANK(10),SMH_BANK(10)) | |
| 1280 | AM_RANGE(0x000c8000, 0x000cafff) AM_READWRITE8(towns_spriteram_low_r,towns_spriteram_low_w,0xffffffff) | |
| 1281 | AM_RANGE(0x000cb000, 0x000cbfff) AM_READWRITE(SMH_BANK(6),SMH_BANK(7)) | |
| 1282 | AM_RANGE(0x000cc000, 0x000cff7f) AM_READWRITE(SMH_BANK(8),SMH_BANK(8)) | |
| 1283 | AM_RANGE(0x000cff80, 0x000cffff) AM_READWRITE8(towns_video_cff80_r,towns_video_cff80_w,0xffffffff) | |
| 1284 | AM_RANGE(0x000d0000, 0x000d7fff) AM_RAM | |
| 1285 | AM_RANGE(0x000d8000, 0x000d9fff) AM_READWRITE8(towns_cmos_low_r,towns_cmos_low_w,0xffffffff) // CMOS? RAM | |
| 1286 | AM_RANGE(0x000da000, 0x000effff) AM_RAM //READWRITE(SMH_BANK(11),SMH_BANK(11)) | |
| 1287 | AM_RANGE(0x000f0000, 0x000f7fff) AM_RAM //READWRITE(SMH_BANK(12),SMH_BANK(12)) | |
| 1288 | AM_RANGE(0x000f8000, 0x000fffff) AM_READWRITE(SMH_BANK(11),SMH_BANK(12)) | |
| 1289 | AM_RANGE(0x00100000, 0x005fffff) AM_RAM // some extra RAM - seems to be needed to boot | |
| 1290 | AM_RANGE(0x80000000, 0x8003ffff) AM_READWRITE8(towns_gfx_high_r,towns_gfx_high_w,0xffffffff) AM_MIRROR(0x1c0000) // VRAM | |
| 1291 | AM_RANGE(0x81000000, 0x8101ffff) AM_RAM // Sprite RAM | |
| 1292 | AM_RANGE(0xc2000000, 0xc207ffff) AM_ROM AM_REGION("user",0x000000) // OS ROM | |
| 1293 | AM_RANGE(0xc2080000, 0xc20fffff) AM_ROM AM_REGION("user",0x100000) // DIC ROM | |
| 1294 | AM_RANGE(0xc2100000, 0xc213ffff) AM_ROM AM_REGION("user",0x180000) // FONT ROM | |
| 1295 | AM_RANGE(0xc2140000, 0xc2141fff) AM_READWRITE8(towns_cmos_r,towns_cmos_w,0xffffffff) // CMOS (mirror?) | |
| 1296 | AM_RANGE(0xc2180000, 0xc21fffff) AM_ROM AM_REGION("user",0x080000) // F20 ROM | |
| 1297 | AM_RANGE(0xc2200000, 0xc2200fff) AM_NOP // WAVE RAM | |
| 1298 | AM_RANGE(0xfffc0000, 0xffffffff) AM_ROM AM_REGION("user",0x200000) // SYSTEM ROM | |
| 1299 | ADDRESS_MAP_END | |
| 1300 | ||
| 1301 | static ADDRESS_MAP_START(marty_mem, ADDRESS_SPACE_PROGRAM, 32) | |
| 1302 | AM_RANGE(0x00000000, 0x000bffff) AM_RAM | |
| 1303 | AM_RANGE(0x000c0000, 0x000c7fff) AM_READWRITE8(towns_gfx_r,towns_gfx_w,0xffffffff) | |
| 1053 | 1304 | AM_RANGE(0x000c8000, 0x000c8fff) AM_READWRITE(SMH_BANK(2),SMH_BANK(2)) |
| 1054 | 1305 | AM_RANGE(0x000c9000, 0x000c9fff) AM_READWRITE(SMH_BANK(3),SMH_BANK(3)) |
| 1055 | 1306 | AM_RANGE(0x000ca000, 0x000ca7ff) AM_READWRITE(SMH_BANK(4),SMH_BANK(5)) |
| r6353 | r6354 | |
| 1063 | 1314 | AM_RANGE(0x000f0000, 0x000f7fff) AM_RAM //READWRITE(SMH_BANK(12),SMH_BANK(12)) |
| 1064 | 1315 | AM_RANGE(0x000f8000, 0x000fffff) AM_READWRITE(SMH_BANK(11),SMH_BANK(12)) |
| 1065 | 1316 | AM_RANGE(0x00100000, 0x005fffff) AM_RAM // some extra RAM - seems to be needed to boot |
| 1317 | AM_RANGE(0x00600000, 0x0067ffff) AM_ROM AM_REGION("user",0x000000) // OS | |
| 1318 | AM_RANGE(0x00680000, 0x0087ffff) AM_ROM AM_REGION("user",0x280000) // EX ROM | |
| 1319 | AM_RANGE(0x00a00000, 0x00a3ffff) AM_READWRITE8(towns_gfx_high_r,towns_gfx_high_w,0xffffffff) AM_MIRROR(0x1c0000) // VRAM | |
| 1320 | AM_RANGE(0x00e80000, 0x00efffff) AM_ROM AM_REGION("user",0x100000) // DIC ROM | |
| 1321 | AM_RANGE(0x00f00000, 0x00f7ffff) AM_ROM AM_REGION("user",0x180000) // FONT | |
| 1322 | AM_RANGE(0x00fc0000, 0x00ffffff) AM_ROM AM_REGION("user",0x200000) // SYSTEM ROM | |
| 1066 | 1323 | AM_RANGE(0x80000000, 0x8003ffff) AM_READWRITE8(towns_gfx_high_r,towns_gfx_high_w,0xffffffff) AM_MIRROR(0x1c0000) // VRAM |
| 1067 | 1324 | AM_RANGE(0x81000000, 0x8101ffff) AM_RAM // Sprite RAM |
| 1068 | 1325 | AM_RANGE(0xc2000000, 0xc207ffff) AM_ROM AM_REGION("user",0x000000) // OS ROM |
| r6353 | r6354 | |
| 1132 | 1389 | static INPUT_PORTS_START( towns ) |
| 1133 | 1390 | INPUT_PORTS_END |
| 1134 | 1391 | |
| 1392 | static INTERRUPT_GEN( towns_vsync_irq ) | |
| 1393 | { | |
| 1394 | const device_config* dev = devtag_get_device(device->machine,"pic8259_slave"); | |
| 1395 | pic8259_set_irq_line(dev,3,1); // IRQ11 = VSync | |
| 1396 | } | |
| 1397 | ||
| 1135 | 1398 | static DRIVER_INIT( towns ) |
| 1136 | 1399 | { |
| 1137 | 1400 | towns_vram = auto_alloc_array(machine,UINT32,0x20000); |
| 1138 | 1401 | towns_cmos = auto_alloc_array(machine,UINT8,0x2000); |
| 1139 | 1402 | towns_gfxvram = auto_alloc_array(machine,UINT8,0x40000); |
| 1140 | towns_txtvram = auto_alloc_array(machine,UINT8,0x | |
| 1403 | towns_txtvram = auto_alloc_array(machine,UINT8,0x20000); | |
| 1141 | 1404 | towns_serial_rom = auto_alloc_array(machine,UINT8,256/8); |
| 1142 | 1405 | towns_init_serial_rom(machine); |
| 1143 | 1406 | towns_init_rtc(); |
| r6353 | r6354 | |
| 1162 | 1425 | towns_ram_enable = 0x00; |
| 1163 | 1426 | towns_update_video_banks(cpu_get_address_space(cputag_get_cpu(machine,"maincpu"),ADDRESS_SPACE_PROGRAM)); |
| 1164 | 1427 | towns_vram_wplane = 0x00; |
| 1428 | towns_kb_status = 0x18; | |
| 1429 | towns_kb_irq1_enable = 0; | |
| 1165 | 1430 | timer_adjust_periodic(towns_rtc_timer,attotime_zero,0,ATTOTIME_IN_HZ(1)); |
| 1166 | 1431 | } |
| 1167 | 1432 | |
| r6353 | r6354 | |
| 1172 | 1437 | static VIDEO_UPDATE( towns ) |
| 1173 | 1438 | { |
| 1174 | 1439 | int x,y; |
| 1175 | UINT8 dat1,dat2,dat3,dat4; | |
| 1176 | int bit; | |
| 1177 | 1440 | UINT8 colour; |
| 1178 | ||
| 1441 | UINT8 row; // JIS row number | |
| 1442 | UINT16 code; | |
| 1443 | int off = 0; | |
| 1444 | ||
| 1445 | if(towns_vram_page_sel != 0) | |
| 1446 | off = 0x20000; | |
| 1179 | 1447 | for(y=0;y<480;y++) |
| 1180 | 1448 | { |
| 1181 | for(x=0;x<640;x++) | |
| 1449 | // off = 0x50 * y; | |
| 1450 | for(x=0;x<640;x+=2) | |
| 1182 | 1451 | { |
| 1183 | bit = 7 - (x & 0x07); | |
| 1184 | dat1 = towns_gfxvram[(x/8) + (y*0x50)]; | |
| 1185 | dat2 = towns_gfxvram[(x/8) + (y*0x50) + 0x8000]; | |
| 1186 | dat3 = towns_gfxvram[(x/8) + (y*0x50) + 0x10000]; | |
| 1187 | dat4 = towns_gfxvram[(x/8) + (y*0x50) + 0x18000]; | |
| 1188 | colour = (dat1 & (1 << bit) ? 1 : 0) | |
| 1189 | | (dat2 & (1 << bit) ? 2 : 0) | |
| 1190 | | (dat3 & (1 << bit) ? 4 : 0) | |
| 1191 | | (dat4 & (1 << bit) ? 8 : 0); | |
| 1452 | colour = towns_gfxvram[off] >> 4; | |
| 1453 | *BITMAP_ADDR32(bitmap,y,x+1) = | |
| 1454 | (towns_palette_r[colour] << 16) | |
| 1455 | | (towns_palette_g[colour] << 8) | |
| 1456 | | (towns_palette_b[colour]); | |
| 1457 | colour = towns_gfxvram[off] & 0x0f; | |
| 1192 | 1458 | *BITMAP_ADDR32(bitmap,y,x) = |
| 1193 | 1459 | (towns_palette_r[colour] << 16) |
| 1194 | 1460 | | (towns_palette_g[colour] << 8) |
| 1195 | 1461 | | (towns_palette_b[colour]); |
| 1462 | off++; | |
| 1196 | 1463 | } |
| 1464 | } | |
| 1465 | ||
| 1466 | // draw text layer | |
| 1467 | if(towns_tvram_enable != 0) | |
| 1468 | { | |
| 1469 | for(y=0;y<40;y++) | |
| 1470 | { | |
| 1471 | off = 160 * y; | |
| 1472 | for(x=0;x<80;x++) | |
| 1473 | { | |
| 1474 | colour = towns_txtvram[off+1] & 0x0f; | |
| 1475 | if((towns_txtvram[off+1] & 0xc0) != 0) | |
| 1476 | { // double width | |
| 1477 | // TODO: work out exactly how these map to the font ROM | |
| 1478 | // Numbers are tiles 0x70-0x79 | |
| 1479 | // lowercase characters are from tile 0x160 | |
| 1480 | // uppercase characters are from tile 0x260 | |
| 1481 | if(towns_txtvram[off+1] & 0x40) | |
| 1482 | { | |
| 1483 | row = (towns_txtvram[off+0x2000] - 32); | |
| 1484 | code = 0; | |
| 1485 | if(row <= 8) | |
| 1486 | { | |
| 1487 | code = (row & 0x07) * 0x20; | |
| 1488 | code += ((towns_txtvram[off+0x2001]-32) & 0x1f) | |
| 1489 | | (((towns_txtvram[off+0x2001]-32) & 0x40) << 2) | |
| 1490 | | (((towns_txtvram[off+0x2001]-32) & 0x20) << 4); | |
| 1491 | } | |
| 1492 | if(row >= 16) // Kanji | |
| 1493 | { | |
| 1494 | code = 0x400; | |
| 1495 | code += ((towns_txtvram[off+0x2001]) & 0x1f) | |
| 1496 | + (((towns_txtvram[off+0x2001]-32) & 0x60) << 4) | |
| 1497 | + ((row & 0x0f) << 5) | |
| 1498 | + (((row-16) & 0x70) * 0x60); | |
| 1499 | } | |
| 1500 | drawgfx_transpen_raw(bitmap,cliprect,screen->machine->gfx[1],code, | |
| 1501 | (towns_palette_r[colour] << 16) | |
| 1502 | | (towns_palette_g[colour] << 8) | |
| 1503 | | (towns_palette_b[colour]), | |
| 1504 | 0,0,x*8,y*16,0); | |
| 1505 | } | |
| 1506 | } | |
| 1507 | else | |
| 1508 | { | |
| 1509 | drawgfx_transpen_raw(bitmap,cliprect,screen->machine->gfx[0],towns_txtvram[off], | |
| 1510 | (towns_palette_r[colour] << 16) | |
| 1511 | | (towns_palette_g[colour] << 8) | |
| 1512 | | (towns_palette_b[colour]), | |
| 1513 | 0,0,x*8,y*16,0); | |
| 1514 | } | |
| 1515 | off += 2; | |
| 1516 | } | |
| 1517 | } | |
| 1197 | 1518 | } |
| 1198 | ||
| 1519 | ||
| 1199 | 1520 | return 0; |
| 1200 | 1521 | } |
| 1201 | 1522 | |
| r6353 | r6354 | |
| 1230 | 1551 | |
| 1231 | 1552 | static const wd17xx_interface towns_mb8877a_interface = |
| 1232 | 1553 | { |
| 1233 | DEVCB_ | |
| 1554 | DEVCB_DEVICE_LINE("pic8259_master",towns_mb8877a_irq_w), | |
| 1234 | 1555 | DEVCB_DEVICE_LINE("dma_1", towns_mb8877a_drq_w), |
| 1235 | {FLOPPY_0,FLOPPY_1, | |
| 1556 | {FLOPPY_0,FLOPPY_1,0 | |
| 1236 | 1557 | }; |
| 1237 | 1558 | |
| 1238 | 1559 | static FLOPPY_OPTIONS_START( towns ) |
| r6353 | r6354 | |
| 1265 | 1586 | }; |
| 1266 | 1587 | |
| 1267 | 1588 | // for debugging |
| 1268 | static const gfx_layout | |
| 1589 | static const gfx_layout fnt_chars_16x16 = | |
| 1269 | 1590 | { |
| 1270 | 1591 | 16,16, |
| 1271 | 1592 | RGN_FRAC(1,1), |
| r6353 | r6354 | |
| 1276 | 1597 | 16*16 |
| 1277 | 1598 | }; |
| 1278 | 1599 | |
| 1600 | static const gfx_layout text_chars = | |
| 1601 | { | |
| 1602 | 8,16, | |
| 1603 | RGN_FRAC(1,1), | |
| 1604 | 1, | |
| 1605 | { 0 }, | |
| 1606 | { 0, 1, 2, 3, 4, 5, 6, 7, }, | |
| 1607 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8 ,8*8, 9*8, 10*8, 11*8, 12*8, 13*8, 14*8, 15*8 }, | |
| 1608 | 8*16 | |
| 1609 | }; | |
| 1610 | ||
| 1279 | 1611 | /* decoded for debugging purpose, this will be nuked in the end... */ |
| 1280 | 1612 | static GFXDECODE_START( towns ) |
| 1281 | GFXDECODE_ENTRY( "user", 0x180000, x1_chars_16x16, 0, 0x100 ) //needs to be checked when the ROM will be redumped | |
| 1613 | GFXDECODE_ENTRY( "user", 0x180000 + 0x3d800, text_chars, 0, 16 ) | |
| 1614 | GFXDECODE_ENTRY( "user", 0x180000, fnt_chars_16x16, 0, 16 ) | |
| 1282 | 1615 | GFXDECODE_END |
| 1283 | 1616 | |
| 1284 | 1617 | static MACHINE_DRIVER_START( towns ) |
| r6353 | r6354 | |
| 1286 | 1619 | MDRV_CPU_ADD("maincpu",I386, 16000000) |
| 1287 | 1620 | MDRV_CPU_PROGRAM_MAP(towns_mem) |
| 1288 | 1621 | MDRV_CPU_IO_MAP(towns_io) |
| 1622 | MDRV_CPU_VBLANK_INT("screen", towns_vsync_irq) | |
| 1289 | 1623 | |
| 1290 | 1624 | MDRV_MACHINE_RESET(towns) |
| 1291 | 1625 | |
| r6353 | r6354 | |
| 1293 | 1627 | MDRV_SCREEN_ADD("screen", RASTER) |
| 1294 | 1628 | MDRV_SCREEN_REFRESH_RATE(60) |
| 1295 | 1629 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ |
| 1630 | ||
| 1296 | 1631 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_RGB32) |
| 1297 | 1632 | MDRV_SCREEN_SIZE(640, 480) |
| 1298 | 1633 | MDRV_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1) |
| r6353 | r6354 | |
| 1327 | 1662 | MDRV_RAM_DEFAULT_SIZE("6M") |
| 1328 | 1663 | MACHINE_DRIVER_END |
| 1329 | 1664 | |
| 1665 | static MACHINE_DRIVER_START( marty ) | |
| 1666 | MDRV_IMPORT_FROM(towns) | |
| 1667 | ||
| 1668 | MDRV_CPU_REPLACE("maincpu",I386, 16000000) | |
| 1669 | MDRV_CPU_PROGRAM_MAP(marty_mem) | |
| 1670 | MDRV_CPU_IO_MAP(towns_io) | |
| 1671 | MACHINE_DRIVER_END | |
| 1672 | ||
| 1330 | 1673 | /* ROM definitions */ |
| 1331 | 1674 | ROM_START( fmtowns ) |
| 1332 | 1675 | ROM_REGION32_LE( 0x280000, "user", 0) |
| r6353 | r6354 | |
| 1347 | 1690 | ROM_END |
| 1348 | 1691 | |
| 1349 | 1692 | ROM_START( fmtmarty ) |
| 1350 | ROM_REGION32_LE( 0x400000, "user", 0) | |
| 1351 | ROM_LOAD("mrom.m36", 0x000000, 0x200000, CRC(9c0c060c) SHA1(5721c5f9657c570638352fa9acac57fa8d0b94bd) ) | |
| 1352 | ROM_LOAD("mrom.m37", 0x200000, 0x180000, CRC(fb66bb56) SHA1(e273b5fa618373bdf7536495cd53c8aac1cce9a5) ) | |
| 1693 | ROM_REGION32_LE( 0x480000, "user", 0) | |
| 1694 | ROM_LOAD("mrom.m36", 0x000000, 0x080000, CRC(9c0c060c) SHA1(5721c5f9657c570638352fa9acac57fa8d0b94bd) ) | |
| 1695 | ROM_CONTINUE(0x280000,0x180000) | |
| 1696 | ROM_LOAD("mrom.m37", 0x400000, 0x080000, CRC(fb66bb56) SHA1(e273b5fa618373bdf7536495cd53c8aac1cce9a5) ) | |
| 1697 | ROM_CONTINUE(0x80000,0x100000) | |
| 1353 | 1698 | ROM_CONTINUE(0x180000,0x40000) |
| 1354 | 1699 | ROM_CONTINUE(0x200000,0x40000) |
| 1355 | 1700 | ROM_END |
| r6353 | r6354 | |
| 1373 | 1718 | /* YEAR NAME PARENT COMPAT MACHINE INPUT INIT CONFIG COMPANY FULLNAME FLAGS */ |
| 1374 | 1719 | COMP( 1989, fmtowns, 0, 0, towns, towns, towns, 0, "Fujitsu", "FM-Towns", GAME_NOT_WORKING) |
| 1375 | 1720 | COMP( 1989, fmtownsa, fmtowns, 0, towns, towns, towns, 0, "Fujitsu", "FM-Towns (alternate)", GAME_NOT_WORKING) |
| 1376 | CONS( 1993, fmtmarty, 0, 0, towns, towns, marty, 0, "Fujitsu", "FM-Towns Marty", GAME_NOT_WORKING) | |
| 1377 | CONS( 1994, carmarty, fmtmarty, 0, towns, towns, towns, 0, "Fujitsu", "FM-Towns Car Marty", GAME_NOT_WORKING) | |
| 1721 | CONS( 1993, fmtmarty, 0, 0, marty, towns, marty, 0, "Fujitsu", "FM-Towns Marty", GAME_NOT_WORKING) | |
| 1722 | CONS( 1994, carmarty, fmtmarty, 0, marty, towns, towns, 0, "Fujitsu", "FM-Towns Car Marty", GAME_NOT_WORKING) | |
| 1378 | 1723 |
| Previous | 15994 Revisions | Next |