summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author Curt Coder <curtcoder@mail.com>2015-05-21 22:13:31 +0300
committer Curt Coder <curtcoder@mail.com>2015-05-21 22:13:59 +0300
commitca20ed2004f7612216c7e240122e84c4c18e3d2c (patch)
tree5d5689dc1ca6baf10bc5a9eb6b23d8e18084fe1c /src
parent13389141ee5d44bec2e21299d518152dbcc605ee (diff)
(MESS) c8050: Fixed disk access. (nw)
Diffstat (limited to 'src')
-rw-r--r--src/emu/bus/ieee488/c2040.c6
-rw-r--r--src/emu/bus/ieee488/c8050.c9
-rw-r--r--src/emu/machine/mos6530n.c12
3 files changed, 16 insertions, 11 deletions
diff --git a/src/emu/bus/ieee488/c2040.c b/src/emu/bus/ieee488/c2040.c
index ccb149a4943..b9112f85408 100644
--- a/src/emu/bus/ieee488/c2040.c
+++ b/src/emu/bus/ieee488/c2040.c
@@ -474,11 +474,11 @@ static MACHINE_CONFIG_FRAGMENT( c2040 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c2040_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_16MHz/16)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c2040_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds0_w))
MCFG_MOS6530n_OUT_PB2_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds1_w))
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c2040_fdc_t, wps_r))
MCFG_DEVICE_ADD(FDC_TAG, C2040_FDC, XTAL_16MHz)
@@ -532,12 +532,12 @@ static MACHINE_CONFIG_FRAGMENT( c3040 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c2040_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_16MHz/16)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c2040_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds0_w))
MCFG_MOS6530n_OUT_PB2_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds1_w))
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c2040_fdc_t, wps_r))
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C2040_FDC, XTAL_16MHz)
MCFG_C2040_SYNC_CALLBACK(DEVWRITELINE(M6530_TAG, mos6530_t, pb6_w))
@@ -590,12 +590,12 @@ static MACHINE_CONFIG_FRAGMENT( c4040 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c2040_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_16MHz/16)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c2040_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds0_w))
MCFG_MOS6530n_OUT_PB2_CB(DEVWRITELINE(FDC_TAG, c2040_fdc_t, ds1_w))
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c2040_fdc_t, wps_r))
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C2040_FDC, XTAL_16MHz)
MCFG_C2040_SYNC_CALLBACK(DEVWRITELINE(M6530_TAG, mos6530_t, pb6_w))
diff --git a/src/emu/bus/ieee488/c8050.c b/src/emu/bus/ieee488/c8050.c
index 7211a834bdc..7848fd3d601 100644
--- a/src/emu/bus/ieee488/c8050.c
+++ b/src/emu/bus/ieee488/c8050.c
@@ -550,12 +550,13 @@ static MACHINE_CONFIG_FRAGMENT( c8050 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c8050_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_12MHz/12)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c8050_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds0_w))
MCFG_MOS6530n_OUT_PB2_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds1_w))
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c8050_fdc_t, wps_r))
+ MCFG_MOS6530n_IN_PB6_CB(VCC) // SINGLE SIDED
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C8050_FDC, XTAL_12MHz/2)
MCFG_C8050_SYNC_CALLBACK(DEVWRITELINE(M6522_TAG, via6522_device, write_pb7))
@@ -609,7 +610,6 @@ static MACHINE_CONFIG_FRAGMENT( c8250 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c8050_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_12MHz/12)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c8050_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds0_w))
@@ -617,6 +617,7 @@ static MACHINE_CONFIG_FRAGMENT( c8250 )
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c8050_fdc_t, wps_r))
MCFG_MOS6530n_OUT_PB4_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, odd_hd_w))
MCFG_MOS6530n_IN_PB6_CB(GND) // DOUBLE SIDED
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C8050_FDC, XTAL_12MHz/2)
MCFG_C8050_SYNC_CALLBACK(DEVWRITELINE(M6522_TAG, via6522_device, write_pb7))
@@ -670,7 +671,6 @@ static MACHINE_CONFIG_FRAGMENT( c8250lp )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c8050_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_12MHz/12)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c8050_fdc_t, write))
MCFG_MOS6530n_OUT_PB0_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, drv_sel_w))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds0_w))
@@ -678,6 +678,7 @@ static MACHINE_CONFIG_FRAGMENT( c8250lp )
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c8050_fdc_t, wps_r))
MCFG_MOS6530n_OUT_PB4_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, odd_hd_w))
MCFG_MOS6530n_IN_PB6_CB(GND) // DOUBLE SIDED
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C8050_FDC, XTAL_12MHz/2)
MCFG_C8050_SYNC_CALLBACK(DEVWRITELINE(M6522_TAG, via6522_device, write_pb7))
@@ -731,13 +732,13 @@ static MACHINE_CONFIG_FRAGMENT( sfd1001 )
MCFG_VIA6522_CB2_HANDLER(DEVWRITELINE(FDC_TAG, c8050_fdc_t, rw_sel_w))
MCFG_DEVICE_ADD(M6530_TAG, MOS6530n, XTAL_12MHz/12)
- MCFG_MOS6530n_IRQ_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_MOS6530n_OUT_PA_CB(DEVWRITE8(FDC_TAG, c8050_fdc_t, write))
MCFG_MOS6530n_OUT_PB1_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds0_w))
MCFG_MOS6530n_OUT_PB2_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, ds1_w))
MCFG_MOS6530n_IN_PB3_CB(DEVREADLINE(FDC_TAG, c8050_fdc_t, wps_r))
MCFG_MOS6530n_OUT_PB4_CB(DEVWRITELINE(FDC_TAG, c8050_fdc_t, odd_hd_w))
MCFG_MOS6530n_IN_PB6_CB(GND) // DOUBLE SIDED
+ MCFG_MOS6530n_OUT_PB7_CB(INPUTLINE(M6504_TAG, M6502_IRQ_LINE))
MCFG_DEVICE_ADD(FDC_TAG, C8050_FDC, XTAL_12MHz/2)
MCFG_C8050_SYNC_CALLBACK(DEVWRITELINE(M6522_TAG, via6522_device, write_pb7))
diff --git a/src/emu/machine/mos6530n.c b/src/emu/machine/mos6530n.c
index 1c1be27638f..564969f957e 100644
--- a/src/emu/machine/mos6530n.c
+++ b/src/emu/machine/mos6530n.c
@@ -92,8 +92,8 @@ mos6530_t::mos6530_t(const machine_config &mconfig, const char *tag, device_t *o
m_out_pb5_cb(*this),
m_out_pb6_cb(*this),
m_out_pb7_cb(*this),
- m_pa_in(0),
- m_pb_in(0)
+ m_pa_in(0xff),
+ m_pb_in(0xff)
{
cur_live.tm = attotime::never;
cur_live.state = IDLE;
@@ -226,8 +226,12 @@ void mos6530_t::update_pb()
if (m_ie)
{
- data &= ~IRQ_TIMER;
- data |= m_irq ? 0x00 : IRQ_TIMER;
+ if (m_irq) {
+ data |= IRQ_TIMER;
+ } else {
+ data &= ~IRQ_TIMER;
+ }
+
m_irq_cb(m_irq ? ASSERT_LINE : CLEAR_LINE);
}