summaryrefslogtreecommitdiffstatshomepage
path: root/src/mame/audio/cmi01a.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mame/audio/cmi01a.cpp')
-rw-r--r--src/mame/audio/cmi01a.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/mame/audio/cmi01a.cpp b/src/mame/audio/cmi01a.cpp
index 2f733ed72f7..5d734c6f1e7 100644
--- a/src/mame/audio/cmi01a.cpp
+++ b/src/mame/audio/cmi01a.cpp
@@ -48,8 +48,7 @@ void cmi01a_device::device_add_mconfig(machine_config &config)
m_pia[1]->irqa_handler().set("cmi01a_irq", FUNC(input_merger_device::in_w<2>));
m_pia[1]->irqb_handler().set("cmi01a_irq", FUNC(input_merger_device::in_w<3>));
- PTM6840(config, m_ptm, 2000000); // ptm_cmi01a_config
- m_ptm->set_external_clocks(250000, 500000, 500000);
+ PTM6840(config, m_ptm, DERIVED_CLOCK(1, 1)); // ptm_cmi01a_config
m_ptm->o1_callback().set(FUNC(cmi01a_device::ptm_o1));
m_ptm->irq_callback().set("cmi01a_irq", FUNC(input_merger_device::in_w<4>));
@@ -93,6 +92,8 @@ void cmi01a_device::device_start()
m_zx_timer->adjust(attotime::never);
m_stream = stream_alloc(0, 1, 44100);
+
+ m_ptm->set_external_clocks(clock() / 8, clock() / 4, clock() / 4);
}
void cmi01a_device::device_reset()
@@ -118,7 +119,7 @@ void cmi01a_device::device_reset()
WRITE_LINE_MEMBER( cmi01a_device::pia_0_ca2_w )
{
- // upate_stream()
+ // update_stream()
if (!state)
{
m_segment_cnt = 0x4000 | ((m_pia[0]->a_output() & 0x7f) << 7);
@@ -350,7 +351,7 @@ void cmi01a_device::write(offs_t offset, uint8_t data)
int a1 = (m_ptm->get_output_state(0) && BIT(offset, 3)) || (!BIT(offset, 3) && BIT(offset, 2));
int a2 = BIT(offset, 1);
- //printf("CH%d PTM W: [%x] = %02x\n", m_channel, (a2 << 2) | (a1 << 1) | a0, data);
+ //osd_printf_debug("CH%d PTM W: [%x] = %02x\n", m_channel, (a2 << 2) | (a1 << 1) | a0, data);
m_ptm->write((a2 << 2) | (a1 << 1) | a0, data);
break;
}
@@ -408,7 +409,7 @@ uint8_t cmi01a_device::read(offs_t offset)
data = m_ptm->read((a2 << 2) | (a1 << 1) | a0);
- //printf("CH%d PTM R: [%x] %02x\n", m_channel, (a2 << 2) | (a1 << 1) | a0, data);
+ //osd_printf_debug("CH%d PTM R: [%x] %02x\n", m_channel, (a2 << 2) | (a1 << 1) | a0, data);
break;
}