Previous 199869 Revisions Next

r33956 Friday 19th December, 2014 at 17:02:36 UTC by Scott Stone
MZ-2500: Fixed floppy drive reverse behaviour, allows Laydock to get farther [Takeda Toshiya, Angelo Salese]
[src/mess/drivers]mz2500.c

trunk/src/mess/drivers/mz2500.c
r242467r242468
11831183WRITE8_MEMBER(mz2500_state::mz2500_fdc_w)
11841184{
11851185   mb8877_device *fdc = machine().device<mb8877_device>("mb8877a");
1186
1186   UINT8 drivenum;
11871187   switch(offset+0xdc)
11881188   {
11891189      case 0xdc:
1190         fdc->set_drive(data & 3);
1191         floppy_get_device(machine(), data & 3)->floppy_mon_w((data & 0x80) ? CLEAR_LINE : ASSERT_LINE);
1192         floppy_get_device(machine(), data & 3)->floppy_drive_set_ready_state(1,0);
1190         drivenum = (data & 3) ^ m_fdc_reverse;
1191         fdc->set_drive(drivenum);
1192         floppy_get_device(machine(), drivenum)->floppy_mon_w((data & 0x80) ? CLEAR_LINE : ASSERT_LINE);
1193         floppy_get_device(machine(), drivenum)->floppy_drive_set_ready_state(1,0);
11931194         break;
11941195      case 0xdd:
11951196         fdc->set_side((data & 1));
r242467r242468
12671268READ8_MEMBER(mz2500_state::mz2500_wd17xx_r)
12681269{
12691270   mb8877_device *fdc = machine().device<mb8877_device>("mb8877a");
1270   return fdc->read(space, offset) ^ m_fdc_reverse;
1271   return fdc->read(space, offset) ^ 0xff;
12711272}
12721273
12731274WRITE8_MEMBER(mz2500_state::mz2500_wd17xx_w)
12741275{
12751276   mb8877_device *fdc = machine().device<mb8877_device>("mb8877a");
1276   fdc->write(space, offset, data ^ m_fdc_reverse);
1277   fdc->write(space, offset, data ^ 0xff);
12771278}
12781279
12791280READ8_MEMBER(mz2500_state::mz2500_bplane_latch_r)
r242467r242468
19821983   ---- --x- floppy reverse bit (controls wd17xx bits in command registers)
19831984   */
19841985
1985   m_fdc_reverse = (data & 2) ? 0x00 : 0xff;
1986   m_fdc_reverse = data & 2;
19861987   m_pal_select = (data & 4) ? 1 : 0;
19871988
19881989   m_ym_porta = data;


Previous 199869 Revisions Next


© 1997-2024 The MAME Team