summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author MooglyGuy <therealmogminer@gmail.com>2020-02-04 17:20:29 +0100
committer MooglyGuy <therealmogminer@gmail.com>2020-02-04 17:20:43 +0100
commit21004f0213246e75f092c5da0b5e4d6f4721180c (patch)
treef74b94034f3fcefee3092f4509df542c77e53aba
parentbc1a3cdfbe673680ff91661da661126fc208cc9f (diff)
-6840ptm: Undid previous changes other than the addition of logmacro. Should fix reported regression in ginganin, nw
-rw-r--r--src/devices/machine/6840ptm.cpp7
-rw-r--r--src/devices/machine/6840ptm.h1
-rw-r--r--src/mame/audio/cmi01a.cpp4
3 files changed, 2 insertions, 10 deletions
diff --git a/src/devices/machine/6840ptm.cpp b/src/devices/machine/6840ptm.cpp
index b271fd7cede..44aee43aaf2 100644
--- a/src/devices/machine/6840ptm.cpp
+++ b/src/devices/machine/6840ptm.cpp
@@ -524,7 +524,6 @@ void ptm6840_device::write(offs_t offset, uint8_t data)
{
// Output cleared
m_out_cb[idx](0);
- m_output[idx] = 0;
}
// Reset?
@@ -692,12 +691,6 @@ void ptm6840_device::set_clock(int idx, int state)
}
-int ptm6840_device::get_output_state(int counter)
-{
- assert(counter < 3);
- return m_output[counter];
-}
-
//-------------------------------------------------
// set_ext_clock - set external clock frequency
//-------------------------------------------------
diff --git a/src/devices/machine/6840ptm.h b/src/devices/machine/6840ptm.h
index f1e209f9d4c..c1adcbfde13 100644
--- a/src/devices/machine/6840ptm.h
+++ b/src/devices/machine/6840ptm.h
@@ -33,7 +33,6 @@ public:
auto o3_callback() { return m_out_cb[2].bind(); }
auto irq_callback() { return m_irq_cb.bind(); }
- int get_output_state(int counter);
int status(int clock) const { return m_enabled[clock]; } // get whether timer is enabled
int irq_state() const { return m_irq; } // get IRQ state
uint16_t count(int counter) const { return compute_counter(counter); } // get counter value
diff --git a/src/mame/audio/cmi01a.cpp b/src/mame/audio/cmi01a.cpp
index 5d734c6f1e7..3b291255382 100644
--- a/src/mame/audio/cmi01a.cpp
+++ b/src/mame/audio/cmi01a.cpp
@@ -183,7 +183,7 @@ void cmi01a_device::zx_timer_cb()
if (m_zx_flag == 0)
{
/* Low to high transition - clock flip flop */
- int op = m_ptm->get_output_state(0);
+ int op = m_ptm_o1;
/* Set /ZCINT */
if (op != m_zx_ff)
@@ -348,7 +348,7 @@ void cmi01a_device::write(offs_t offset, uint8_t data)
{
/* PTM addressing is a little funky */
int a0 = offset & 1;
- int a1 = (m_ptm->get_output_state(0) && BIT(offset, 3)) || (!BIT(offset, 3) && BIT(offset, 2));
+ int a1 = (m_ptm_o1 && BIT(offset, 3)) || (!BIT(offset, 3) && BIT(offset, 2));
int a2 = BIT(offset, 1);
//osd_printf_debug("CH%d PTM W: [%x] = %02x\n", m_channel, (a2 << 2) | (a1 << 1) | a0, data);