-6840ptm: Undid previous changes other than the addition of logmacro. Should fix reported regression in ginganin, nw

This commit is contained in:
MooglyGuy 2020-02-04 17:20:29 +01:00
parent bc1a3cdfbe
commit 21004f0213
3 changed files with 2 additions and 10 deletions

View File

@ -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
//-------------------------------------------------

View File

@ -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

View File

@ -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);