trunk/src/mess/machine/snescart.c
| r21703 | r21704 | |
| 643 | 643 | DEVICE_IMAGE_LOAD_MEMBER( snes_state,snes_cart ) |
| 644 | 644 | { |
| 645 | 645 | int supported_type = 1; |
| 646 | | int has_bsx_slot = 0;//, st_bios = 0; |
| 646 | int has_bsx_slot = 0, st_bios = 0; |
| 647 | 647 | UINT32 offset, int_header_offs; |
| 648 | 648 | UINT8 *ROM = memregion("cart")->base(); |
| 649 | 649 | |
| r21703 | r21704 | |
| 684 | 684 | if (ROM[int_header_offs + 0x1a] == 0x33 || ROM[int_header_offs + 0x1a] == 0xff) |
| 685 | 685 | { |
| 686 | 686 | // BS-X Flash Cart |
| 687 | mame_printf_error("This is a game with BS-X slot: MESS does not support these yet, sorry.\n"); |
| 687 | 688 | m_cart[0].mode = SNES_MODE_BSX; |
| 688 | 689 | } |
| 689 | 690 | } |
| r21703 | r21704 | |
| 706 | 707 | // If there is a BS-X connector, detect if it is the Base Cart or a compatible slotted cart |
| 707 | 708 | if (has_bsx_slot) |
| 708 | 709 | { |
| 710 | mame_printf_error("This is a game with BS-X slot: MESS does not support these yet, sorry.\n"); |
| 709 | 711 | if (!memcmp(ROM + int_header_offs, "Satellaview BS-X ", 21)) |
| 710 | 712 | { |
| 711 | 713 | //BS-X Base Cart |
| 712 | | m_cart[0].mode = SNES_MODE_BSX; |
| 714 | m_cart[0].mode = SNES_MODE_20; //SNES_MODE_BSX; |
| 713 | 715 | // handle RAM |
| 714 | 716 | } |
| 715 | 717 | else |
| 716 | 718 | { |
| 717 | | m_cart[0].mode = (int_header_offs ==0x007fc0) ? SNES_MODE_BSLO : SNES_MODE_BSHI; |
| 719 | m_cart[0].mode = (int_header_offs == 0x007fc0) ? SNES_MODE_20 : SNES_MODE_21; //SNES_MODE_BSLO : SNES_MODE_BSHI; |
| 718 | 720 | // handle RAM? |
| 719 | 721 | } |
| 720 | 722 | } |
| r21703 | r21704 | |
| 723 | 725 | if (!memcmp(ROM, "BANDAI SFC-ADX", 14)) |
| 724 | 726 | { |
| 725 | 727 | m_cart[0].mode = SNES_MODE_ST; |
| 726 | | //if (!memcmp(ROM + 16, "SFC-ADX BACKUP", 14)) |
| 727 | | //st_bios = 1; |
| 728 | if (!memcmp(ROM + 16, "SFC-ADX BACKUP", 14)) |
| 729 | st_bios = 1; |
| 728 | 730 | } |
| 731 | if (st_bios) |
| 732 | mame_printf_error("This is the Sufami Turbo base cart. MESS does not fully support this game in snes/snespal yet, sorry.\nYou might want to try the snesst driver.\n"); |
| 733 | else if (m_cart[0].mode == SNES_MODE_ST) |
| 734 | { |
| 735 | mame_printf_error("This is a Sufami Turbo data cart and cannot be loaded for snes/snespal in MESS.\n"); |
| 736 | mame_printf_error("Please use snesst driver to load it, instead.\n"); |
| 737 | return IMAGE_INIT_FAIL; |
| 738 | } |
| 729 | 739 | |
| 740 | |
| 730 | 741 | if (SNES_CART_DEBUG) mame_printf_error("mode %d\n", m_cart[0].mode); |
| 731 | 742 | |
| 732 | 743 | /* Detect special chips */ |