mirror of
https://github.com/holub/mame
synced 2025-05-19 20:29:09 +03:00
Stop the internal timer if DTR is high and there is no character being received as neither the transmit or receive will do anything anyway. The default is for the internal divider to be disabled so if the chip wasn't initialised then the timer would be running at the full rate of the xtal. (nw)
This commit is contained in:
parent
82a53e9745
commit
fbc648ce50
@ -240,7 +240,15 @@ void mos6551_device::update_divider()
|
||||
m_tx_internal_clock = true;
|
||||
|
||||
m_divide = 16;
|
||||
scale = (double) 1 / scale;
|
||||
|
||||
if (!m_dtr || m_rx_state != STATE_START)
|
||||
{
|
||||
scale = (double) 1 / scale;
|
||||
}
|
||||
else
|
||||
{
|
||||
scale = 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -355,6 +363,8 @@ void mos6551_device::write_command(UINT8 data)
|
||||
m_tx_output = OUTPUT_MARK;
|
||||
output_txd(1);
|
||||
}
|
||||
|
||||
update_divider();
|
||||
}
|
||||
|
||||
READ8_MEMBER( mos6551_device::read )
|
||||
@ -629,6 +639,11 @@ WRITE_LINE_MEMBER(mos6551_device::receiver_clock)
|
||||
}
|
||||
|
||||
m_rx_state = STATE_START;
|
||||
|
||||
if (m_dtr)
|
||||
{
|
||||
update_divider();
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user