Previous 15994 Revisions Next

r5402 Tuesday 11th August, 2009 at 10:23:32 UTC by Barry Rodewald
[PCW] Set geometry for second disk drive, and set a delay for the upd765 Recalibrate function if the drive head is already on track 0, which stops CP/M from locking up when no disk is in a drive.
[src/mess/drivers]pcw.c
[src/mess/machine]nec765.c

src/mess/machine/nec765.c
r5401r5402
504504         )
505505      {
506506         /* seek completed */
507         nec765_seek_complete(device);
507//         nec765_seek_complete(device);
508         // delay for the time of 1 step, the PCW does not like immediate recalibrates
509         nec765_setup_timed_int(device,1);
508510      }
509511      else
510512      {
src/mess/drivers/pcw.c
r5401r5402
402402   pcw_banks[offset] = data;
403403
404404   pcw_update_mem(space->machine, offset, data);
405   //popmessage("RAM Banks: %02x %02x %02x %02x",pcw_banks[0],pcw_banks[1],pcw_banks[2],pcw_banks[3]);
405406}
406407
407408static WRITE8_HANDLER(pcw_bank_force_selection_w)
r5401r5402
456457      /* reboot */
457458      case 1:
458459      {
460         cputag_set_input_line(space->machine, "maincpu", INPUT_LINE_RESET, PULSE_LINE);
459461         popmessage("SYS: Reboot");
460462      }
461463      break;
r5401r5402
595597   /* from Jacob Nevins docs */
596598   UINT8 ret = pcw_get_sys_status(space->machine);
597599   
598   LOG(("SYS: Status port returning %02x\n",ret));
600//   LOG(("SYS: Status port returning %02x\n",ret));
599601   return ret;
600602}
601603
r5401r5402
766768{
767769   fdc_interrupt_code = 2;
768770   floppy_drive_set_geometry(image_from_devtype_and_index(machine, IO_FLOPPY, 0), FLOPPY_DRIVE_DS_80);
771   floppy_drive_set_geometry(image_from_devtype_and_index(machine, IO_FLOPPY, 1), FLOPPY_DRIVE_DS_80);
769772}
770773
771774static MACHINE_RESET( pcw )
r5401r5402
773776   /* ram paging is actually undefined at power-on */
774777   pcw_bank_force = 0x00;
775778   
776   pcw_banks[0] = 0x00;
777   pcw_banks[1] = 0x01;
778   pcw_banks[2] = 0x02;
779   pcw_banks[3] = 0x03;
779   pcw_banks[0] = 0x80;
780   pcw_banks[1] = 0x81;
781   pcw_banks[2] = 0x82;
782   pcw_banks[3] = 0x83;
780783
781784   pcw_update_mem(machine, 0, pcw_banks[0]);
782785   pcw_update_mem(machine, 1, pcw_banks[1]);

Previous 15994 Revisions Next


© 1998-2018 The MESS Team