trunk/src/mess/machine/nes_nxrom.c
r27519 | r27520 | |
556 | 556 | |
557 | 557 | iNES: mapper 218 |
558 | 558 | |
559 | | In MESS: Not Supported. |
| 559 | In MESS: Supported. |
560 | 560 | |
561 | 561 | -------------------------------------------------*/ |
562 | 562 | |
563 | 563 | WRITE8_MEMBER(nes_nochr_device::chr_w) |
564 | 564 | { |
565 | | int bank = offset >> 10; |
566 | | m_nt_access[bank & 0x03][offset & 0x3ff] = data; |
| 565 | int mirr = get_mirroring(); |
| 566 | if (mirr == PPU_MIRROR_HIGH) |
| 567 | m_ciram[offset & 0x3ff + 0x000] = data; |
| 568 | else if (mirr == PPU_MIRROR_LOW) |
| 569 | m_ciram[offset & 0x3ff + 0x400] = data; |
| 570 | else |
| 571 | m_ciram[offset & 0x7ff] = data; // not sure here, since there is no software to test... |
567 | 572 | } |
568 | 573 | |
569 | 574 | READ8_MEMBER(nes_nochr_device::chr_r) |
570 | 575 | { |
571 | | int bank = offset >> 10; |
572 | | return m_nt_access[bank & 0x03][offset & 0x3ff]; |
| 576 | int mirr = get_mirroring(); |
| 577 | if (mirr == PPU_MIRROR_HIGH) |
| 578 | return m_ciram[offset & 0x3ff + 0x000]; |
| 579 | else if (mirr == PPU_MIRROR_LOW) |
| 580 | return m_ciram[offset & 0x3ff + 0x400]; |
| 581 | else |
| 582 | return m_ciram[offset & 0x7ff]; // not sure here, since there is no software to test... |
573 | 583 | } |