wd_fdc: fixes to get BetaDisk work without patches

This commit is contained in:
MetalliC 2015-05-30 18:16:17 +03:00
parent 0afa682456
commit 99855c456f
3 changed files with 5 additions and 9 deletions

View File

@ -747,6 +747,7 @@ void wd_fdc_t::write_track_continue()
if (TRACE_STATE) logerror("%s: DATA_LOAD_WAIT_DONE\n", tag());
if(drq) {
status |= S_LOST;
drop_drq();
command_end();
return;
}
@ -904,11 +905,13 @@ void wd_fdc_t::interrupt_start()
if(!(command & 0x0f)) {
intrq_cond = 0;
} else if ((command & 0x0f) > 8) { // assume I_IMM is set only if condition equal to 8 but not more than, Spectrum's BetaDisk require this
intrq_cond = 0;
} else {
intrq_cond = (intrq_cond & I_IMM) | (command & 0x0f);
}
if(intrq_cond & I_IMM) {
if(command & I_IMM) {
intrq = true;
if(!intrq_cb.isnull())
intrq_cb(intrq);

View File

@ -322,8 +322,6 @@ ROM_START(scorpio)
ROMX_LOAD("scorp2.rom", 0x018000, 0x4000, CRC(fd0d3ce1) SHA1(07783ee295274d8ff15d935bfd787c8ac1d54900), ROM_BIOS(7))
ROMX_LOAD("scorp3.rom", 0x01c000, 0x4000, CRC(1fe1d003) SHA1(33703e97cc93b7edfcc0334b64233cf81b7930db), ROM_BIOS(7))
ROM_FILL( 0x1fe47, 1, 0x3e) // patch TR-DOS bug
ROM_REGION(0x01000, "keyboard", 0)
ROM_LOAD( "scrpkey.rom", 0x0000, 0x1000, CRC(e938a510) SHA1(2753993c97ff0fc6cff26ed792929abc1288dc6f))

View File

@ -11,7 +11,7 @@
*********************************************************************/
/*
BUGS:
- due to original firmware bug random commands can be sent to FDC instead of SEEK, current WD FDC emulation cant handle this correctly, use patch fix for now
- due to original firmware bug random commands can be sent to FDC instead of SEEK
*/
#include "emu.h"
@ -268,11 +268,6 @@ ROM_START( beta_disk )
//Default for now
ROM_LOAD( "trd503.rom", 0x00000, 0x4000, CRC(10751aba) SHA1(21695e3f2a8f796386ce66eea8a246b0ac44810c))
// TR-DOS rom have a bug - semi-random commands sent to FDC instead of SEEK command sometimes
// however it works OK on real hardware but does not using our WD FDC emulation, both legacy and modern
// this patch fixes original bug
ROM_FILL( 0x3e47, 1, 0x3e)
ROM_END