mirror of
https://github.com/TomHarte/CLK.git
synced 2024-11-26 08:49:37 +00:00
Okay, so the 1540 doesn't toggle the actual attention line. I don't know what it does yet but this helps.
This commit is contained in:
parent
1baf21827c
commit
dcb86a027a
@ -72,6 +72,5 @@ void Machine::set_rom(const uint8_t *rom)
|
||||
|
||||
void Machine::mos6522_did_change_interrupt_status(void *mos6522)
|
||||
{
|
||||
printf("?");
|
||||
set_irq_line(_serialPortVIA->get_interrupt_line() || _driveVIA.get_interrupt_line());
|
||||
}
|
||||
|
@ -34,7 +34,7 @@ class SerialPortVIA: public MOS::MOS6522<SerialPortVIA>, public MOS::MOS6522IRQD
|
||||
if(port) {
|
||||
std::shared_ptr<::Commodore::Serial::Port> serialPort = _serialPort.lock();
|
||||
if(serialPort) {
|
||||
serialPort->set_output(::Commodore::Serial::Line::Attention, !(value&0x10));
|
||||
// serialPort->set_output(::Commodore::Serial::Line::Attention, !(value&0x10));
|
||||
serialPort->set_output(::Commodore::Serial::Line::Clock, !(value&0x08));
|
||||
serialPort->set_output(::Commodore::Serial::Line::Data, !(value&0x02));
|
||||
}
|
||||
@ -52,7 +52,7 @@ class SerialPortVIA: public MOS::MOS6522<SerialPortVIA>, public MOS::MOS6522IRQD
|
||||
case ::Commodore::Serial::Line::Clock: _portB = (_portB & ~0x04) | (value ? 0x00 : 0x04); break;
|
||||
case ::Commodore::Serial::Line::Attention:
|
||||
_portB = (_portB & ~0x80) | (value ? 0 : 0x80);
|
||||
set_control_line_input(Port::A, Line::One, !value); // truth here is active low; the 6522 takes true to be high
|
||||
set_control_line_input(Port::A, Line::One, !value); // truth here is active low; my 6522 takes true to be high
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -94,7 +94,8 @@ class UserPortVIA: public MOS::MOS6522<UserPortVIA>, public MOS::MOS6522IRQDeleg
|
||||
void set_port_output(Port port, uint8_t value, uint8_t mask) {
|
||||
if(!port) {
|
||||
std::shared_ptr<::Commodore::Serial::Port> serialPort = _serialPort.lock();
|
||||
if(serialPort) serialPort->set_output(::Commodore::Serial::Line::Attention, !(value&0x80));
|
||||
if(serialPort)
|
||||
serialPort->set_output(::Commodore::Serial::Line::Attention, !(value&0x80));
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user