mirror of
https://github.com/TomHarte/CLK.git
synced 2024-12-26 09:29:45 +00:00
Simplifies the test for resetting the ZX80/81 line counter.
This commit is contained in:
parent
ac4948c4b1
commit
eecea93b3b
@ -124,14 +124,12 @@ template<bool is_zx81> class ConcreteMachine:
|
||||
bool is_opcode_read = false;
|
||||
switch(cycle.operation) {
|
||||
case CPU::Z80::PartialMachineCycle::Output:
|
||||
if(!(address & 2)) nmi_is_enabled_ = false;
|
||||
if(!(address & 1)) nmi_is_enabled_ = is_zx81_;
|
||||
if(!nmi_is_enabled_) {
|
||||
// Line counter reset is held low while vsync is active; simulate that lazily by performing
|
||||
// an instant reset upon the transition from active to inactive.
|
||||
if(vsync_) line_counter_ = 0;
|
||||
line_counter_ = 0;
|
||||
set_vsync(false);
|
||||
}
|
||||
if(!(address & 2)) nmi_is_enabled_ = false;
|
||||
if(!(address & 1)) nmi_is_enabled_ = is_zx81_;
|
||||
|
||||
// The below emulates the ZonX AY expansion device.
|
||||
if(is_zx81) {
|
||||
|
Loading…
Reference in New Issue
Block a user