src/mess/devices/ti99cart.c
| r8246 | r8247 | |
| 30 | 30 | /* PCB device associated to this cartridge. If NULL, the slot is empty. */ |
| 31 | 31 | running_device *pcb; |
| 32 | 32 | |
| 33 | | /* GROM buffer size. */ |
| 34 | | int grom_size; |
| 35 | | |
| 36 | | /* ROM page. */ |
| 37 | | int rom_page; |
| 38 | | /* RAM page. */ |
| 39 | | int ram_page; |
| 40 | | |
| 41 | | /* ROM buffer size. All banks have equal sizes. */ |
| 42 | | int rom_size; |
| 43 | | /* RAM buffer size. All banks have equal sizes. */ |
| 44 | | int ram_size; |
| 45 | | |
| 46 | | /* pointer to GROM data. */ |
| 47 | | UINT8 *grom_ptr; |
| 48 | | |
| 49 | | /* GROM buffered data output. */ |
| 50 | | /* UINT8 grom_buffer; */ /* Now handled by the multicart system. */ |
| 51 | | |
| 52 | | /* ROM buffer. We are using this for both 16 bit (99/4a) and 8 bit |
| 53 | | (99/8) access. */ |
| 54 | | void *rom_ptr; |
| 55 | | |
| 56 | | /* ROM buffer for the second bank of paged cartridges. Other cartridges |
| 57 | | usually store their ROM in one large file. */ |
| 58 | | void *rom2_ptr; |
| 59 | | |
| 60 | | /* RAM buffer. The persistence service is done by the cartridge system. |
| 61 | | The RAM space is a consecutive space; all banks are in one buffer. */ |
| 62 | | void *ram_ptr; |
| 33 | /* GROM buffer size. */ |
| 34 | int grom_size; |
| 35 | |
| 36 | /* ROM page. */ |
| 37 | int rom_page; |
| 38 | /* RAM page. */ |
| 39 | int ram_page; |
| 40 | |
| 41 | /* ROM buffer size. All banks have equal sizes. */ |
| 42 | int rom_size; |
| 43 | /* RAM buffer size. All banks have equal sizes. */ |
| 44 | int ram_size; |
| 45 | |
| 46 | /* pointer to GROM data. */ |
| 47 | UINT8 *grom_ptr; |
| 48 | |
| 49 | /* GROM buffered data output. */ |
| 50 | /* UINT8 grom_buffer; */ /* Now handled by the multicart system. */ |
| 51 | |
| 52 | /* ROM buffer. We are using this for both 16 bit (99/4a) and 8 bit |
| 53 | (99/8) access. */ |
| 54 | void *rom_ptr; |
| 55 | |
| 56 | /* ROM buffer for the second bank of paged cartridges. Other cartridges |
| 57 | usually store their ROM in one large file. */ |
| 58 | void *rom2_ptr; |
| 59 | |
| 60 | /* RAM buffer. The persistence service is done by the cartridge system. |
| 61 | The RAM space is a consecutive space; all banks are in one buffer. */ |
| 62 | void *ram_ptr; |
| 63 | 63 | }; |
| 64 | 64 | typedef struct _cartridge_t cartridge_t; |
| 65 | 65 | |
| r8246 | r8247 | |
| 405 | 405 | value = 0; |
| 406 | 406 | //printf("Empty socket at address G(%d)>%04x\n", slot, cartslots->grom_address); |
| 407 | 407 | } |
| 408 | | // printf("GROM address (cart) = %04x, reply = %02x\n", cartslots->grom_address, value); |
| 409 | | /* The program counter wraps at each GROM chip size (8K), |
| 410 | | so 0x5fff + 1 = 0x4000. */ |
| 411 | | cartslots->grom_address = ((cartslots->grom_address + 1) & 0x1FFF) | (cartslots->grom_address & 0xE000); |
| 408 | } |
| 409 | // printf("GROM address (cart) = %04x, reply = %02x\n", cartslots->grom_address, value); |
| 410 | /* The program counter wraps at each GROM chip size (8K), */ |
| 411 | /* so 0x5fff + 1 = 0x4000. */ |
| 412 | /* The address must be increased even if there is no cartridge slot */ |
| 413 | cartslots->grom_address = ((cartslots->grom_address + 1) & 0x1FFF) | (cartslots->grom_address & 0xE000); |
| 414 | |
| 415 | /* Reset the read and write address flipflops. */ |
| 416 | cartslots->raddr_LSB = cartslots->waddr_LSB = FALSE; |
| 412 | 417 | |
| 413 | | /* Reset the read and write address flipflops. */ |
| 414 | | cartslots->raddr_LSB = cartslots->waddr_LSB = FALSE; |
| 415 | | } |
| 416 | 418 | return value; |
| 417 | 419 | } |
| 418 | 420 | |
| r8246 | r8247 | |
| 1621 | 1623 | if (data != 0) |
| 1622 | 1624 | { |
| 1623 | 1625 | cartridge->rom_page = (offset-1)/2; |
| 1624 | | printf("Setting bit %4x of CRU base >0800\n", offset); |
| 1626 | // printf("Setting bit %4x of CRU base >0800\n", offset); |
| 1625 | 1627 | } |
| 1626 | 1628 | } |
| 1627 | 1629 | // printf("setting rompage to %d\n", cartridge->rom_page); |
src/mess/machine/99_hsgpl.c
| r8246 | r8247 | |
| 1 | 1 | /* |
| 2 | 2 | SNUG HSGPL card emulation. |
| 3 | | |
| 4 | 3 | Raphael Nabet, 2003. |
| 5 | 4 | */ |
| 6 | 5 | |
| r8246 | r8247 | |
| 89 | 88 | UINT16 addr; |
| 90 | 89 | char raddr_LSB, waddr_LSB; |
| 91 | 90 | |
| 91 | /* Holds the current GROM base */ |
| 92 | 92 | int cur_port; |
| 93 | 93 | |
| 94 | /* Holds the current ROM6 bank */ |
| 94 | 95 | int cur_bank; |
| 95 | 96 | |
| 97 | /* Latches the setting of the 16 CRU bits. Also contains the */ |
| 98 | /* current DSR bank (PG0...) */ |
| 96 | 99 | int cru_reg; |
| 97 | | |
| 98 | | int is_image_writable; |
| 99 | 100 | } hsgpl; |
| 100 | 101 | |
| 101 | 102 | enum |
| r8246 | r8247 | |
| 103 | 104 | cr_grmena = 0x0002, |
| 104 | 105 | cr_bnkinh = 0x0004, |
| 105 | 106 | cr_pg = 0x01f8, |
| 106 | | cr_pg_mask = 0x3f, |
| 107 | | cr_pg_shift= 3, |
| 107 | cr_pg_mask = 0x3f, |
| 108 | cr_pg_shift= 3, |
| 108 | 109 | cr_crdena = 0x0200, |
| 109 | | cr_crdena_bit = 9, |
| 110 | cr_crdena_bit = 9, |
| 110 | 111 | cr_wriena = 0x0400, |
| 111 | 112 | cr_scena = 0x0800, |
| 112 | 113 | cr_ledena = 0x1000, |
| r8246 | r8247 | |
| 140 | 141 | UINT8 version; |
| 141 | 142 | UINT8 *rgn; |
| 142 | 143 | |
| 143 | | |
| 144 | 144 | /* version flag */ |
| 145 | 145 | if (mame_fread(file, & version, 1) != 1) |
| 146 | 146 | return 1; |
| r8246 | r8247 | |
| 176 | 176 | { |
| 177 | 177 | UINT8 version; |
| 178 | 178 | |
| 179 | | |
| 180 | 179 | /* version flag */ |
| 181 | 180 | version = 0; |
| 182 | 181 | if (mame_fwrite(file, & version, 1) != 1) |
| r8246 | r8247 | |
| 211 | 210 | |
| 212 | 211 | |
| 213 | 212 | |
| 214 | | int ti99_hsgpl_load_memcard(running_machine *machine) |
| 213 | int ti99_hsgpl_load_flashroms(running_machine *machine, const char *name) |
| 215 | 214 | { |
| 216 | 215 | file_error filerr; |
| 217 | 216 | mame_file *file; |
| 218 | 217 | |
| 219 | | filerr = mame_fopen(SEARCHPATH_MEMCARD, "hsgpl.nv", OPEN_FLAG_READ, &file); |
| 218 | filerr = mame_fopen(SEARCHPATH_NVRAM, name, OPEN_FLAG_READ, &file); |
| 220 | 219 | if (filerr != FILERR_NONE) |
| 221 | | return /*1*/0; |
| 220 | return 0; |
| 222 | 221 | if (ti99_hsgpl_file_load(machine, file)) |
| 223 | 222 | { |
| 224 | 223 | mame_fclose(file); |
| r8246 | r8247 | |
| 229 | 228 | return 0; |
| 230 | 229 | } |
| 231 | 230 | |
| 232 | | int ti99_hsgpl_save_memcard(running_machine *machine) |
| 231 | int ti99_hsgpl_save_flashroms(running_machine *machine, const char *name) |
| 233 | 232 | { |
| 234 | 233 | file_error filerr; |
| 235 | 234 | mame_file *file; |
| 236 | 235 | |
| 237 | 236 | if (ti99_hsgpl_get_dirty_flag()) |
| 238 | 237 | { |
| 239 | | filerr = mame_fopen(SEARCHPATH_MEMCARD, "hsgpl.nv", OPEN_FLAG_WRITE, &file); |
| 238 | filerr = mame_fopen(SEARCHPATH_NVRAM, name, |
| 239 | OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS, &file); |
| 240 | |
| 240 | 241 | if (filerr != FILERR_NONE) |
| 241 | 242 | return 1; |
| 242 | 243 | if (ti99_hsgpl_file_save(file)) |
| r8246 | r8247 | |
| 281 | 282 | hsgpl.cur_port = 0; |
| 282 | 283 | hsgpl.cur_bank = 0; |
| 283 | 284 | hsgpl.cru_reg = 0; |
| 284 | | ti99_set_hsgpl_crdena(/*0*/1); |
| 285 | 285 | |
| 286 | | ti99_peb_set_card_handlers(0x1b00, & hsgpl_handlers); |
| 286 | /* Card is enabled on startup. */ |
| 287 | ti99_set_hsgpl_crdena(1); |
| 288 | |
| 289 | ti99_peb_set_card_handlers(0x1b00, &hsgpl_handlers); |
| 287 | 290 | } |
| 288 | 291 | |
| 289 | 292 | |
| r8246 | r8247 | |
| 298 | 301 | hsgpl.cru_reg |= 1 << offset; |
| 299 | 302 | else |
| 300 | 303 | hsgpl.cru_reg &= ~ (1 << offset); |
| 301 | | |
| 304 | |
| 302 | 305 | if (offset == cr_crdena_bit) |
| 303 | 306 | ti99_set_hsgpl_crdena(data); |
| 304 | 307 | } |
| 305 | 308 | |
| 306 | 309 | /* |
| 307 | | read a byte in hsgpl DSR space |
| 310 | read a byte in hsgpl DSR space (4000-5fff) |
| 308 | 311 | */ |
| 309 | 312 | static READ8_HANDLER(hsgpl_dsr_r) |
| 310 | 313 | { |
| r8246 | r8247 | |
| 398 | 401 | |
| 399 | 402 | case 32: |
| 400 | 403 | case 33: |
| 401 | | /* This has been verified */ |
| 404 | /* GRAM access */ |
| 402 | 405 | reply = hsgpl.GRAM_ptr[hsgpl.addr + 0x10000*(port-32)]; |
| 403 | 406 | break; |
| 404 | 407 | |
| 405 | 408 | case 48: |
| 406 | | case 49: /* this mirror is mistakenly used by the hsgpl DSR */ |
| 407 | | /* This has been verified. */ |
| 409 | case 49: |
| 410 | /* RAM6 access */ |
| 408 | 411 | reply = hsgpl.RAM6_ptr[hsgpl.addr]; |
| 409 | 412 | break; |
| 410 | 413 | |
| r8246 | r8247 | |
| 432 | 435 | { |
| 433 | 436 | int port; |
| 434 | 437 | |
| 435 | | |
| 436 | 438 | //activecpu_adjust_icount(-4); |
| 437 | 439 | |
| 438 | 440 | port = hsgpl.cur_port = (offset & 0x1FE) >> 1; |
| r8246 | r8247 | |
| 444 | 446 | if (hsgpl.waddr_LSB) |
| 445 | 447 | { |
| 446 | 448 | hsgpl.addr = (hsgpl.addr & 0xFF00) | ((data >> 8) & 0xFF); |
| 447 | | |
| 448 | 449 | hsgpl.waddr_LSB = FALSE; |
| 449 | 450 | } |
| 450 | 451 | else |
| r8246 | r8247 | |
| 514 | 515 | |
| 515 | 516 | case 32: |
| 516 | 517 | case 33: |
| 517 | | /* This has been verified */ |
| 518 | /* GRAM access */ |
| 518 | 519 | hsgpl.GRAM_ptr[hsgpl.addr + 0x10000*(port-32)] = data; |
| 519 | 520 | break; |
| 520 | 521 | |
| 521 | 522 | case 48: |
| 522 | | case 49: /* this mirror is mistakenly used by the hsgpl DSR */ |
| 523 | | /* This has been verified. */ |
| 523 | case 49: |
| 524 | /* RAM6 access */ |
| 524 | 525 | hsgpl.RAM6_ptr[hsgpl.addr] = data; |
| 525 | 526 | break; |
| 526 | 527 | |
src/mess/machine/ti99_4x.c
| r8246 | r8247 | |
| 119 | 119 | static char has_handset; |
| 120 | 120 | /* TRUE if hsgpl card present */ |
| 121 | 121 | static char has_hsgpl; |
| 122 | static char hsgpl_flash_mode; |
| 123 | |
| 122 | 124 | /* TRUE if mechatronics mouse present */ |
| 123 | 125 | static char has_mecmouse; |
| 124 | 126 | /* TRUE if usb-sm card present */ |
| r8246 | r8247 | |
| 423 | 425 | ti99_common_init(machine, 0); |
| 424 | 426 | } |
| 425 | 427 | |
| 428 | MACHINE_START( ti99_4p ) |
| 429 | { |
| 430 | UINT8* mem = memory_region(machine, "maincpu"); |
| 431 | |
| 432 | /* Set up system ROM and scratch pad pointers. Must be set up here */ |
| 433 | /* so that the system can successfully reset (otherwise the reset */ |
| 434 | /* vector would be missing in 0x0000). */ |
| 435 | memory_set_bankptr(machine, "bank1", mem + offset_rom0_4p); /* system ROM */ |
| 436 | memory_set_bankptr(machine, "bank2", mem + offset_sram_4p); /* scratch pad */ |
| 437 | memory_set_bankptr(machine, "bank11", mem + offset_dram_4p); /* extra RAM for debugger */ |
| 438 | |
| 439 | ti99_peb_init(); |
| 440 | ti99_floppy_controllers_init_all(machine); |
| 441 | ti99_ide_init(machine); |
| 442 | ti99_hsgpl_init(machine); |
| 443 | ti99_usbsm_init(machine); |
| 444 | } |
| 445 | |
| 426 | 446 | void ti99_common_init(running_machine *machine, const TMS9928a_interface *gfxparm) |
| 427 | 447 | { |
| 428 | 448 | if (gfxparm != 0) |
| r8246 | r8247 | |
| 474 | 494 | memory_set_bankptr(machine, "bank1", memory_region(machine, "maincpu") + offset_sram); |
| 475 | 495 | } |
| 476 | 496 | |
| 477 | | #if 0 |
| 478 | | if (ti99_model != model_99_4p) |
| 479 | | { |
| 480 | | if (ti99_model == model_99_8) |
| 481 | | current_page_ptr_8 = cartridge_pages_8[0]; |
| 482 | | else |
| 483 | | current_page_ptr = cartridge_pages[0]; |
| 484 | | } |
| 485 | | #endif |
| 486 | | |
| 487 | 497 | if (!has_evpc) TMS9928A_reset(); |
| 488 | 498 | else v9938_reset(0); |
| 489 | 499 | |
| r8246 | r8247 | |
| 522 | 532 | if (ti99_model == model_99_4p) |
| 523 | 533 | has_hsgpl = TRUE; |
| 524 | 534 | else |
| 525 | | has_hsgpl = input_port_read(machine, "EXTCARD") & EXT_HSGPL; |
| 535 | has_hsgpl = input_port_read(machine, "EXTCARD") & (EXT_HSGPL_ON | EXT_HSGPL_FLASH); |
| 526 | 536 | |
| 537 | hsgpl_flash_mode = input_port_read(machine, "EXTCARD") & EXT_HSGPL_FLASH; |
| 538 | |
| 527 | 539 | has_usb_sm = input_port_read(machine, "HDCTRL") & HD_USB; |
| 528 | 540 | has_pcode = input_port_read(machine, "EXTCARD") & EXT_PCODE; |
| 529 | 541 | |
| r8246 | r8247 | |
| 603 | 615 | break; |
| 604 | 616 | } |
| 605 | 617 | |
| 606 | | if (has_ide) { |
| 618 | if (has_ide) |
| 607 | 619 | ti99_ide_reset(machine, ti99_model == model_99_8); |
| 608 | | } |
| 609 | 620 | |
| 610 | | if (has_hsgpl) { |
| 621 | if (has_hsgpl) |
| 611 | 622 | ti99_hsgpl_reset(machine); |
| 612 | | ti99_hsgpl_load_memcard(machine); |
| 613 | | } |
| 614 | 623 | else |
| 615 | 624 | hsgpl_crdena = 0; |
| 616 | 625 | |
| r8246 | r8247 | |
| 643 | 652 | } |
| 644 | 653 | #endif |
| 645 | 654 | |
| 655 | NVRAM_HANDLER( ti99 ) |
| 656 | { |
| 657 | const char *filename; |
| 658 | |
| 659 | /* We may have different HSGPL settings for 80 column and traditional */ |
| 660 | /* 40 column display. For convenience, we use two different nvram files. */ |
| 661 | if (has_evpc) |
| 662 | filename = "hsgpl80.nv"; |
| 663 | else |
| 664 | filename = "hsgpl40.nv"; |
| 665 | |
| 666 | if ((ti99_model == model_99_4p) || (input_port_read(machine, "EXTCARD") & (EXT_HSGPL_ON | EXT_HSGPL_FLASH))) |
| 667 | { |
| 668 | if (read_or_write==0) |
| 669 | { |
| 670 | ti99_hsgpl_load_flashroms(machine, filename); |
| 671 | } |
| 672 | else |
| 673 | { |
| 674 | ti99_hsgpl_save_flashroms(machine, filename); |
| 675 | } |
| 676 | } |
| 677 | } |
| 646 | 678 | |
| 679 | INPUT_CHANGED( hsgpl_changed ) |
| 680 | { |
| 681 | hsgpl_flash_mode = newval & EXT_HSGPL_FLASH; |
| 682 | } |
| 683 | |
| 647 | 684 | /* |
| 648 | 685 | video initialization. |
| 649 | 686 | */ |
| 650 | 687 | VIDEO_START( ti99_4ev ) |
| 651 | 688 | { |
| 652 | 689 | VIDEO_START_CALL(generic_bitmapped); |
| 653 | | v9938_init(machine, 0, machine->primary_screen, machine->generic.tmpbitmap, MODEL_V9938, 0x20000, tms9901_set_int2); /* v38 with 128 kb of video RAM */ |
| 690 | v9938_init(machine, 0, machine->primary_screen, machine->generic.tmpbitmap, |
| 691 | MODEL_V9938, 0x20000, tms9901_set_int2); /* v38 with 128 kb of video RAM */ |
| 654 | 692 | } |
| 655 | 693 | |
| 656 | 694 | /* |
| r8246 | r8247 | |
| 683 | 721 | /* |
| 684 | 722 | Backdoor function that is called by hsgpl, so that the machine code knows |
| 685 | 723 | whether hsgpl or console GROMs are active |
| 724 | Called from 99_hsgpl.c |
| 686 | 725 | */ |
| 687 | 726 | void ti99_set_hsgpl_crdena(int data) |
| 688 | 727 | { |
| r8246 | r8247 | |
| 720 | 759 | } |
| 721 | 760 | |
| 722 | 761 | /* |
| 762 | Cartridge space (>6000->7FFF). This is usually connected to the cartridge |
| 763 | port, but is also used by the HSGPL. So we need to check this here and then |
| 764 | delegate to the respective component. |
| 765 | */ |
| 766 | READ16_HANDLER ( ti99_cart_r ) |
| 767 | { |
| 768 | if (hsgpl_crdena && !hsgpl_flash_mode) |
| 769 | /* hsgpl is enabled */ |
| 770 | return ti99_hsgpl_rom6_r(space, offset, mem_mask); |
| 771 | return ti99_multicart_r(cartslots, offset, mem_mask); |
| 772 | } |
| 773 | |
| 774 | /* |
| 775 | Cartridge space (>6000->7FFF). This is usually connected to the cartridge |
| 776 | port, but is also used by the HSGPL. So we need to check this here and then |
| 777 | delegate to the respective component. |
| 778 | */ |
| 779 | WRITE16_HANDLER ( ti99_cart_w ) |
| 780 | { |
| 781 | ti99_multicart_w(cartslots, offset, data, mem_mask); |
| 782 | if (hsgpl_crdena && !hsgpl_flash_mode) |
| 783 | /* hsgpl is enabled */ |
| 784 | ti99_hsgpl_rom6_w(space, offset, data, mem_mask); |
| 785 | } |
| 786 | |
| 787 | /* |
| 723 | 788 | 99/4p cartridge space: mapped either to internal ROM6 or to HSGPL. |
| 724 | 789 | */ |
| 725 | 790 | READ16_HANDLER ( ti99_4p_cart_r ) |
| r8246 | r8247 | |
| 730 | 795 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); |
| 731 | 796 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 732 | 797 | |
| 733 | | if (hsgpl_crdena) |
| 798 | if (hsgpl_crdena && !hsgpl_flash_mode) |
| 734 | 799 | /* hsgpl is enabled */ |
| 735 | 800 | return ti99_hsgpl_rom6_r(space, offset, mem_mask); |
| 736 | 801 | |
| r8246 | r8247 | |
| 748 | 813 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); |
| 749 | 814 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 750 | 815 | |
| 751 | | if (hsgpl_crdena) |
| 816 | if (hsgpl_crdena && !hsgpl_flash_mode) |
| 752 | 817 | /* hsgpl is enabled */ |
| 753 | 818 | ti99_hsgpl_rom6_w(space, offset, data, mem_mask); |
| 754 | 819 | } |
| r8246 | r8247 | |
| 944 | 1009 | /* Get next value, put it in buffer. Note that the GROM */ |
| 945 | 1010 | /* wraps at 8K boundaries. */ |
| 946 | 1011 | console_GROMs.buf = console_GROMs.data_ptr[console_GROMs.addr]; |
| 947 | | // printf("GROM address (cons) = %04x, offset = %04x, reply = %02x\n", console_GROMs.addr, offset, reply); |
| 948 | 1012 | } |
| 949 | 1013 | |
| 950 | 1014 | /* The address pointer in the cartridge system is updated by this */ |
| r8246 | r8247 | |
| 999 | 1063 | /* it's not clear whether this has unwanted side effects. */ |
| 1000 | 1064 | |
| 1001 | 1065 | if (offset & 1) |
| 1002 | | { /* Read GROM address |
| 1003 | | We only have one GROM program counter for the console GROMs |
| 1004 | | and all cartridge GROMs in all banks(!). Hardware |
| 1005 | | implementations must take this into account as well. Thus, |
| 1006 | | we use a structure here in the console, rather than separate |
| 1007 | | counters in each GROM chip. */ |
| 1066 | { /* Read GROM address */ |
| 1067 | /* We only have one GROM program counter for the console */ |
| 1068 | /* GROMs and all cartridge GROMs in all banks(!). Hardware */ |
| 1069 | /* implementations must take this into account as well. Thus, */ |
| 1070 | /* we use a structure here in the console, rather than */ |
| 1071 | /* separate counters in each GROM chip. */ |
| 1008 | 1072 | |
| 1009 | | /* We call the cartridge system here, but we ignore the |
| 1010 | | value. This is done to sync the flags. */ |
| 1073 | /* We call the cartridge system here, but we ignore the */ |
| 1074 | /* value. This is done to sync the flags. */ |
| 1011 | 1075 | replycart = ti99_cartridge_grom_r(cartslots, (offset<<1))<<8; |
| 1012 | 1076 | |
| 1013 | | /* When reading, reset the hi/lo flag byte for writing. |
| 1014 | | TODO: Verify this with a real machine. */ |
| 1077 | /* When reading, reset the hi/lo flag byte for writing. */ |
| 1078 | /* TODO: Verify this with a real machine. */ |
| 1015 | 1079 | console_GROMs.waddr_LSB = FALSE; |
| 1016 | 1080 | |
| 1017 | | /* Address reading is done in two steps; first, the high byte |
| 1018 | | is transferred, then the low byte. */ |
| 1081 | /* Address reading is done in two steps; first, the high byte */ |
| 1082 | /* is transferred, then the low byte. */ |
| 1019 | 1083 | if (console_GROMs.raddr_LSB) |
| 1020 | 1084 | { |
| 1021 | 1085 | /* second pass */ |
| r8246 | r8247 | |
| 1034 | 1098 | else |
| 1035 | 1099 | { |
| 1036 | 1100 | /* Read GROM data */ |
| 1037 | | /* Note that we shift the GROM port address to accomodate for |
| 1038 | | 8-bit and 16-bit systems. */ |
| 1101 | /* Note that we shift the GROM port address to accomodate for */ |
| 1102 | /* 8-bit and 16-bit systems. */ |
| 1039 | 1103 | reply = ((UINT16)GROM_dataread(offset<<1)) << 8; |
| 1040 | 1104 | } |
| 1041 | 1105 | |
| 1042 | 1106 | if (hsgpl_crdena) |
| 1043 | | /* hsgpl buffers are stronger than console GROM buffers */ |
| 1044 | | reply = ti99_hsgpl_gpl_r(space, offset, mem_mask); |
| 1107 | { |
| 1108 | /* We must prevent the HSGPL to override the console GROMs */ |
| 1109 | /* when it is not yet set up - or the console will get stuck */ |
| 1110 | /* in a black screen. The "flash mode" allows to read GROMs */ |
| 1111 | /* only in higher banks; writing is enabled for all banks. */ |
| 1112 | int bank = (offset>>1)&0xff; |
| 1113 | if (!hsgpl_flash_mode || (bank>=16)) |
| 1114 | { |
| 1115 | /* hsgpl buffers always override console GROM buffers */ |
| 1116 | reply = ti99_hsgpl_gpl_r(space, offset, mem_mask); |
| 1117 | } |
| 1118 | } |
| 1045 | 1119 | |
| 1046 | 1120 | return reply; |
| 1047 | 1121 | } |
| r8246 | r8247 | |
| 1062 | 1136 | /* see comments above */ |
| 1063 | 1137 | console_GROMs.raddr_LSB = FALSE; |
| 1064 | 1138 | |
| 1065 | | /* Implements the internal flipflop. |
| 1066 | | The Editor/Assembler manuals says that the current address |
| 1067 | | plus one is returned. This effect is properly emulated |
| 1068 | | as we are using a read-ahead buffer. |
| 1069 | | */ |
| 1139 | /* Implements the internal flipflop. */ |
| 1140 | /* The Editor/Assembler manuals says that the current address */ |
| 1141 | /* plus one is returned. This effect is properly emulated */ |
| 1142 | /* by using a read-ahead buffer. */ |
| 1070 | 1143 | if (console_GROMs.waddr_LSB) |
| 1071 | 1144 | { |
| 1072 | 1145 | /* Accept low byte (2nd write) */ |
| 1073 | 1146 | console_GROMs.addr = (console_GROMs.addr & 0xFF00) | ((data >> 8) & 0xFF); |
| 1074 | | |
| 1075 | | /* Setting the address causes a new read, putting the |
| 1076 | | value into the buffer. We don't need the value here. */ |
| 1147 | /* Setting the address causes a new read, putting the */ |
| 1148 | /* value into the buffer. We don't need the value here. */ |
| 1077 | 1149 | GROM_dataread(offset<<1); |
| 1078 | 1150 | console_GROMs.waddr_LSB = FALSE; |
| 1079 | 1151 | } |
| r8246 | r8247 | |
| 1088 | 1160 | { |
| 1089 | 1161 | /* write GROM data */ |
| 1090 | 1162 | /* the console GROMs are always affected */ |
| 1091 | | /* BTW, console GROMs are never GRAMs, therefore there is no |
| 1092 | | need to actually write anything, so we just read ahead |
| 1093 | | TODO: There could be cartridges with GRAM, so this must be |
| 1094 | | fixed. |
| 1095 | | */ |
| 1163 | /* BTW, console GROMs are never GRAMs, therefore there is no */ |
| 1164 | /* need to actually write anything, so we just read ahead */ |
| 1165 | /* TODO: There could be cartridges with GRAM, so this must be */ |
| 1166 | /* fixed. */ |
| 1096 | 1167 | GROM_dataread(offset<<1); |
| 1097 | 1168 | console_GROMs.raddr_LSB = console_GROMs.waddr_LSB = FALSE; |
| 1098 | 1169 | } |
| 1099 | 1170 | |
| 1100 | 1171 | if (hsgpl_crdena) |
| 1172 | { |
| 1173 | /* If the HSGPL card is used, we always attempt to write to */ |
| 1174 | /* its memory, even in flash mode. Writing does no harm to */ |
| 1175 | /* the internal GROMs. */ |
| 1101 | 1176 | ti99_hsgpl_gpl_w(space, offset, data, mem_mask); |
| 1177 | } |
| 1102 | 1178 | } |
| 1103 | 1179 | |
| 1104 | 1180 | /* |
| r8246 | r8247 | |
| 1177 | 1253 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); /* HSGPL is located on 8-bit bus? */ |
| 1178 | 1254 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 1179 | 1255 | |
| 1180 | | return /*hsgpl_crdena ?*/ ti99_hsgpl_gpl_r(space, offset, mem_mask) /*: 0*/; |
| 1256 | return hsgpl_crdena? ti99_hsgpl_gpl_r(space, offset, mem_mask) : 0; |
| 1181 | 1257 | } |
| 1182 | 1258 | |
| 1183 | 1259 | /* |
| r8246 | r8247 | |
| 1188 | 1264 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); /* HSGPL is located on 8-bit bus? */ |
| 1189 | 1265 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 1190 | 1266 | |
| 1191 | | /*if (hsgpl_crdena)*/ |
| 1192 | | ti99_hsgpl_gpl_w(space, offset, data, mem_mask); |
| 1267 | if (hsgpl_crdena) |
| 1268 | ti99_hsgpl_gpl_w(space, offset, data, mem_mask); |
| 1193 | 1269 | } |
| 1194 | 1270 | |
| 1195 | 1271 | |
| r8246 | r8247 | |
| 2118 | 2194 | answer = 4; /* on systems without handset, the pin is pulled up to avoid spurious interrupts */ |
| 2119 | 2195 | |
| 2120 | 2196 | /* we don't take CS2 into account, as CS2 is a write-only unit */ |
| 2121 | | if ( ti99_model != model_99_8 ) |
| 2197 | if ( (ti99_model != model_99_8) && (ti99_model != model_99_4p)) |
| 2122 | 2198 | { |
| 2123 | 2199 | if (cassette_input(devtag_get_device(device->machine, "cassette1")) > 0) |
| 2124 | 2200 | answer |= 8; |
| r8246 | r8247 | |
| 2265 | 2341 | { |
| 2266 | 2342 | running_device *img; |
| 2267 | 2343 | |
| 2268 | | if ( ti99_model != model_99_8 ) |
| 2344 | if ( (ti99_model != model_99_8) && (ti99_model != model_99_4p)) |
| 2269 | 2345 | { |
| 2270 | 2346 | img = devtag_get_device(device->machine, (offset-6 ) ? "cassette2" : "cassette1" ); |
| 2271 | 2347 | } |
| r8246 | r8247 | |
| 2295 | 2371 | */ |
| 2296 | 2372 | static WRITE8_DEVICE_HANDLER( ti99_CS_output ) |
| 2297 | 2373 | { |
| 2298 | | if (ti99_model != model_99_8) /* 99/8 only has one tape port!!! */ |
| 2374 | if ((ti99_model != model_99_8) && (ti99_model != model_99_4p)) /* 99/8 only has one tape port!!! */ |
| 2299 | 2375 | { |
| 2300 | 2376 | cassette_output(devtag_get_device(device->machine, "cassette1"), data ? +1 : -1); |
| 2301 | 2377 | cassette_output(devtag_get_device(device->machine, "cassette2"), data ? +1 : -1); |
| r8246 | r8247 | |
| 2485 | 2561 | { |
| 2486 | 2562 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); |
| 2487 | 2563 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 2488 | | |
| 2489 | 2564 | COMBINE_DATA(xRAM_ptr + offset); |
| 2490 | 2565 | } |
| 2491 | 2566 | |
| r8246 | r8247 | |
| 2494 | 2569 | { |
| 2495 | 2570 | cpu_adjust_icount(devtag_get_device(space->machine, "maincpu"),-4); |
| 2496 | 2571 | // cpu_spinuntil_time(space->machine->firstcpu, ATTOTIME_IN_USEC(6)); |
| 2497 | | |
| 2498 | 2572 | return xRAM_ptr[offset+0x1000]; |
| 2499 | 2573 | } |
| 2500 | 2574 | |
src/mess/drivers/ti99_4p.c
| r8246 | r8247 | |
| 39 | 39 | #include "emu.h" |
| 40 | 40 | #include "deprecat.h" |
| 41 | 41 | #include "cpu/tms9900/tms9900.h" |
| 42 | #include "sound/wave.h" |
| 42 | 43 | #include "sound/dac.h" |
| 43 | 44 | #include "sound/sn76496.h" |
| 44 | 45 | #include "sound/tms5220.h" |
| r8246 | r8247 | |
| 120 | 121 | PORT_START( "HDCTRL" ) |
| 121 | 122 | PORT_CONFNAME( 0x03, 0x00, "HD controller" ) |
| 122 | 123 | PORT_CONFSETTING( 0x00, DEF_STR( None ) ) |
| 123 | | PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 124 | // PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 124 | 125 | // PORT_CONFSETTING( 0x02, "WHTech SCSI Controller" ) |
| 125 | 126 | PORT_CONFNAME( 0x08, 0x00, "USB-SM card" ) |
| 126 | 127 | PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) |
| r8246 | r8247 | |
| 289 | 290 | MDRV_CPU_IO_MAP(cru_map) |
| 290 | 291 | MDRV_CPU_VBLANK_INT_HACK(ti99_4ev_hblank_interrupt, 263) /* 262.5 in 60Hz, 312.5 in 50Hz */ |
| 291 | 292 | |
| 293 | MDRV_MACHINE_START( ti99_4p ) |
| 292 | 294 | MDRV_MACHINE_RESET( ti99 ) |
| 293 | 295 | |
| 296 | /* For HSGPL */ |
| 297 | MDRV_NVRAM_HANDLER( ti99 ) |
| 298 | |
| 294 | 299 | /* video hardware */ |
| 295 | 300 | MDRV_SCREEN_ADD("screen", RASTER) |
| 296 | 301 | MDRV_SCREEN_REFRESH_RATE(60) /* or 50Hz */ |
| r8246 | r8247 | |
| 309 | 314 | MDRV_SPEAKER_STANDARD_MONO("mono") |
| 310 | 315 | MDRV_SOUND_ADD("dac", DAC, 0) |
| 311 | 316 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 312 | | // MDRV_SOUND_WAVE_ADD("wave", "cassette") |
| 313 | | // MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 317 | MDRV_SOUND_WAVE_ADD("wave", "cassette") |
| 318 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 314 | 319 | MDRV_SOUND_ADD("sn76496", SN76496, 3579545) /* 3.579545 MHz */ |
| 315 | 320 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.75) |
| 316 | 321 | MDRV_SOUND_ADD("tmc0285", TMC0285, 680000L) |
| r8246 | r8247 | |
| 318 | 323 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 319 | 324 | |
| 320 | 325 | /* devices */ |
| 321 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) /* FIXME */ |
| 326 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 327 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 322 | 328 | |
| 323 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 329 | MDRV_CASSETTE_ADD( "cassette", default_cassette_config ) |
| 324 | 330 | |
| 325 | | /* MDRV_CASSETTE_ADD( "cassette", default_cassette_config ) */ |
| 326 | | |
| 327 | 331 | /* tms9901 */ |
| 328 | 332 | MDRV_TMS9901_ADD("tms9901", tms9901reset_param_ti99_4x) |
| 329 | 333 | |
src/mess/drivers/ti99_4x.c
| r8246 | r8247 | |
| 55 | 55 | AM_RANGE(0x0000, 0x1fff) AM_ROM /*system ROM*/ |
| 56 | 56 | AM_RANGE(0x2000, 0x3fff) AM_READWRITE(ti99_nop_8_r, ti99_nop_8_w) /*lower 8kb of RAM extension - installed dynamically*/ |
| 57 | 57 | AM_RANGE(0x4000, 0x5fff) AM_READWRITE(ti99_4x_peb_r, ti99_4x_peb_w) /*DSR ROM space*/ |
| 58 | | // AM_RANGE(0x6000, 0x7fff) AM_READWRITE(ti99_cart_r, ti99_cart_w) /*cartridge memory*/ |
| 59 | | AM_RANGE(0x6000, 0x7fff) AM_DEVREADWRITE("ti99_multicart", ti99_multicart_r, ti99_multicart_w) |
| 58 | AM_RANGE(0x6000, 0x7fff) AM_READWRITE(ti99_cart_r, ti99_cart_w) /*cartridge memory*/ |
| 59 | // AM_RANGE(0x6000, 0x7fff) AM_DEVREADWRITE("ti99_multicart", ti99_multicart_r, ti99_multicart_w) |
| 60 | 60 | AM_RANGE(0x8000, 0x80ff) AM_MIRROR(0x0300) AM_RAMBANK("bank1") /*RAM PAD, mirrored 4 times*/ |
| 61 | 61 | AM_RANGE(0x8400, 0x87ff) AM_READWRITE(ti99_nop_8_r, ti99_wsnd_w) /*soundchip write*/ |
| 62 | 62 | AM_RANGE(0x8800, 0x8bff) AM_READWRITE(ti99_rvdp_r, ti99_nop_8_w) /*vdp read*/ |
| r8246 | r8247 | |
| 70 | 70 | |
| 71 | 71 | static ADDRESS_MAP_START(memmap_4ev, ADDRESS_SPACE_PROGRAM, 16) |
| 72 | 72 | ADDRESS_MAP_GLOBAL_MASK(0xffff) |
| 73 | | AM_RANGE(0x0000, 0x1fff) AM_ROM /*system ROM*/ |
| 73 | AM_RANGE(0x0000, 0x1fff) AM_ROM /*system ROM*/ |
| 74 | 74 | AM_RANGE(0x2000, 0x3fff) AM_READWRITE(ti99_nop_8_r, ti99_nop_8_w) /*lower 8kb of RAM extension - installed dynamically*/ |
| 75 | 75 | AM_RANGE(0x4000, 0x5fff) AM_READWRITE(ti99_4x_peb_r, ti99_4x_peb_w) /*DSR ROM space*/ |
| 76 | | AM_RANGE(0x6000, 0x7fff) AM_DEVREADWRITE("ti99_multicart", ti99_multicart_r, ti99_multicart_w) |
| 76 | AM_RANGE(0x6000, 0x7fff) AM_READWRITE(ti99_cart_r, ti99_cart_w) /*cartridge memory*/ |
| 77 | // AM_RANGE(0x6000, 0x7fff) AM_DEVREADWRITE("ti99_multicart", ti99_multicart_r, ti99_multicart_w) |
| 77 | 78 | AM_RANGE(0x8000, 0x80ff) AM_MIRROR(0x0300) AM_RAMBANK("bank1") /*RAM PAD, mirrored 4 times*/ |
| 78 | 79 | AM_RANGE(0x8400, 0x87ff) AM_READWRITE(ti99_nop_8_r, ti99_wsnd_w) /*soundchip write*/ |
| 79 | 80 | AM_RANGE(0x8800, 0x8bff) AM_READWRITE(ti99_rv38_r, ti99_nop_8_w) /*vdp read*/ |
| r8246 | r8247 | |
| 132 | 133 | PORT_START( "HDCTRL" ) |
| 133 | 134 | PORT_CONFNAME( 0x03, 0x00, "HD controller" ) |
| 134 | 135 | PORT_CONFSETTING( 0x00, DEF_STR( None ) ) |
| 135 | | PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 136 | // PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 136 | 137 | // PORT_CONFSETTING( 0x02, "WHTech SCSI Controller" ) |
| 137 | 138 | PORT_CONFNAME( 0x04, 0x00, "USB-SM card" ) |
| 138 | 139 | PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) |
| r8246 | r8247 | |
| 143 | 144 | PORT_CONFSETTING( 0x00, DEF_STR( None ) ) |
| 144 | 145 | PORT_CONFSETTING( 0x01, "TI RS-232 card" ) |
| 145 | 146 | |
| 147 | /* Flash setting is used to flash an empty HSGPL DSR ROM */ |
| 146 | 148 | PORT_START( "EXTCARD" ) |
| 147 | | PORT_CONFNAME( 0x01, 0x00, "HSGPL extension" ) |
| 149 | PORT_CONFNAME( 0x03, 0x00, "HSGPL extension" ) PORT_CHANGED( hsgpl_changed, NULL) |
| 148 | 150 | PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) |
| 149 | | PORT_CONFSETTING( 0x01, DEF_STR( On ) ) |
| 150 | | PORT_CONFNAME( 0x02, 0x00, "P-Code card" ) |
| 151 | PORT_CONFSETTING( 0x01, "Flash" ) |
| 152 | PORT_CONFSETTING( 0x02, DEF_STR( On ) ) |
| 153 | PORT_CONFNAME( 0x04, 0x00, "P-Code card" ) |
| 151 | 154 | PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) |
| 152 | | PORT_CONFSETTING( 0x02, DEF_STR( On ) ) |
| 155 | PORT_CONFSETTING( 0x04, DEF_STR( On ) ) |
| 153 | 156 | |
| 154 | 157 | PORT_START( "HCI" ) |
| 155 | 158 | PORT_CONFNAME( 0x01, 0x00, "Mouse support" ) |
| r8246 | r8247 | |
| 303 | 306 | PORT_START( "HDCTRL" ) |
| 304 | 307 | PORT_CONFNAME( 0x03, 0x00, "HD controller" ) |
| 305 | 308 | PORT_CONFSETTING( 0x00, DEF_STR( None ) ) |
| 306 | | PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 309 | // PORT_CONFSETTING( 0x01, "Nouspikel IDE Controller" ) |
| 307 | 310 | // PORT_CONFSETTING( 0x02, "WHTech SCSI Controller" ) |
| 308 | 311 | PORT_CONFNAME( 0x08, 0x00, "USB-SM card" ) |
| 309 | 312 | PORT_CONFSETTING( 0x00, DEF_STR( Off ) ) |
| r8246 | r8247 | |
| 682 | 685 | MDRV_MACHINE_START( ti99_4_60hz ) |
| 683 | 686 | MDRV_MACHINE_RESET( ti99 ) |
| 684 | 687 | |
| 688 | /* For HSGPL */ |
| 689 | MDRV_NVRAM_HANDLER( ti99 ) |
| 690 | |
| 685 | 691 | /* video hardware */ |
| 686 | 692 | MDRV_IMPORT_FROM(tms9928a) |
| 687 | 693 | MDRV_SCREEN_MODIFY("screen") |
| r8246 | r8247 | |
| 702 | 708 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.50) |
| 703 | 709 | |
| 704 | 710 | /* devices */ |
| 705 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) /* FIXME */ |
| 706 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 711 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 712 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 707 | 713 | |
| 708 | 714 | MDRV_CASSETTE_ADD( "cassette1", default_cassette_config ) |
| 709 | 715 | MDRV_CASSETTE_ADD( "cassette2", default_cassette_config ) |
| r8246 | r8247 | |
| 738 | 744 | MDRV_MACHINE_START( ti99_4_50hz ) |
| 739 | 745 | MDRV_MACHINE_RESET( ti99 ) |
| 740 | 746 | |
| 747 | /* For HSGPL */ |
| 748 | MDRV_NVRAM_HANDLER( ti99 ) |
| 749 | |
| 741 | 750 | /* video hardware */ |
| 742 | 751 | MDRV_IMPORT_FROM(tms9928a) |
| 743 | 752 | MDRV_SCREEN_MODIFY("screen") |
| r8246 | r8247 | |
| 756 | 765 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 757 | 766 | |
| 758 | 767 | /* devices */ |
| 759 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) /* FIXME */ |
| 760 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 768 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 769 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 761 | 770 | |
| 762 | 771 | MDRV_CASSETTE_ADD( "cassette1", default_cassette_config ) |
| 763 | 772 | MDRV_CASSETTE_ADD( "cassette2", default_cassette_config ) |
| r8246 | r8247 | |
| 792 | 801 | MDRV_MACHINE_START( ti99_4a_60hz ) |
| 793 | 802 | MDRV_MACHINE_RESET( ti99 ) |
| 794 | 803 | |
| 804 | /* For HSGPL */ |
| 805 | MDRV_NVRAM_HANDLER( ti99 ) |
| 806 | |
| 795 | 807 | /* video hardware */ |
| 796 | 808 | MDRV_IMPORT_FROM(tms9928a) |
| 797 | 809 | MDRV_SCREEN_MODIFY("screen") |
| r8246 | r8247 | |
| 810 | 822 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 811 | 823 | |
| 812 | 824 | /* devices */ |
| 813 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) /* FIXME */ |
| 814 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 825 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 826 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 815 | 827 | |
| 816 | 828 | MDRV_CASSETTE_ADD( "cassette1", default_cassette_config ) |
| 817 | 829 | MDRV_CASSETTE_ADD( "cassette2", default_cassette_config ) |
| r8246 | r8247 | |
| 848 | 860 | MDRV_MACHINE_START( ti99_4a_50hz ) |
| 849 | 861 | MDRV_MACHINE_RESET( ti99 ) |
| 850 | 862 | |
| 863 | /* For HSGPL */ |
| 864 | MDRV_NVRAM_HANDLER( ti99 ) |
| 865 | |
| 851 | 866 | /* video hardware */ |
| 852 | 867 | MDRV_IMPORT_FROM(tms9928a) |
| 853 | 868 | MDRV_SCREEN_MODIFY("screen") |
| r8246 | r8247 | |
| 866 | 881 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 867 | 882 | |
| 868 | 883 | /* devices */ |
| 869 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 870 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 884 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 885 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 871 | 886 | |
| 872 | 887 | MDRV_CASSETTE_ADD( "cassette1", default_cassette_config ) |
| 873 | 888 | MDRV_CASSETTE_ADD( "cassette2", default_cassette_config ) |
| r8246 | r8247 | |
| 903 | 918 | MDRV_MACHINE_START( ti99_4ev_60hz ) |
| 904 | 919 | MDRV_MACHINE_RESET( ti99 ) |
| 905 | 920 | |
| 921 | /* For HSGPL */ |
| 922 | MDRV_NVRAM_HANDLER( ti99 ) |
| 923 | |
| 906 | 924 | /* video hardware */ |
| 907 | 925 | MDRV_SCREEN_ADD("screen", RASTER) |
| 908 | 926 | MDRV_SCREEN_REFRESH_RATE(60) /* or 50Hz */ |
| r8246 | r8247 | |
| 929 | 947 | MDRV_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.20) |
| 930 | 948 | |
| 931 | 949 | /* devices */ |
| 932 | | MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) /* FIXME */ |
| 933 | | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) |
| 950 | /* MDRV_IDE_CONTROLLER_ADD( "ide", ti99_ide_interrupt ) |
| 951 | MDRV_RTC65271_ADD("ide_rtc", ti99_clk_interrupt_callback) */ |
| 934 | 952 | |
| 935 | 953 | MDRV_CASSETTE_ADD( "cassette1", default_cassette_config ) |
| 936 | 954 | MDRV_CASSETTE_ADD( "cassette2", default_cassette_config ) |