From ffaa627820897e70e0ee66d27951820acc3b21ba Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Mon, 31 Jul 2017 22:13:45 -0400 Subject: [PATCH] Fixed frame restart when there is no adjustment period. --- Components/6845/CRTC6845.hpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/Components/6845/CRTC6845.hpp b/Components/6845/CRTC6845.hpp index c074794c5..f4c7aba7f 100644 --- a/Components/6845/CRTC6845.hpp +++ b/Components/6845/CRTC6845.hpp @@ -98,7 +98,12 @@ template class CRTC6845 { // check for entry into the overflow area if(line_counter_ == registers_[4]) { - is_in_adjustment_period_ = true; + if(registers_[5]) { + is_in_adjustment_period_ = true; + } else { + line_address_ = (uint16_t)((registers_[12] << 8) | registers_[13]); + bus_state_.refresh_address = line_address_; + } bus_state_.row_address = 0; line_counter_ = 0; } @@ -108,7 +113,7 @@ template class CRTC6845 { } } - bus_state_.display_enable = line_is_visible_ && line_is_visible_; + bus_state_.display_enable = character_is_visible_ && line_is_visible_; bus_handler_.perform_bus_cycle(bus_state_); } }