diff --git a/Components/6560/6560.cpp b/Components/6560/6560.cpp index 29054d0d6..2e2ed8917 100644 --- a/Components/6560/6560.cpp +++ b/Components/6560/6560.cpp @@ -83,7 +83,7 @@ void MOS6560::set_register(int address, uint8_t value) case 0x3: _number_of_rows = (value >> 1)&0x3f; - _wide_characters = !!(value&0x01); + _tall_characters = !!(value&0x01); break; case 0x5: @@ -151,7 +151,7 @@ uint16_t MOS6560::get_address() if(_row_counter >= 0) { _row_counter++; - if(_row_counter == _number_of_rows*8) _row_counter = -1; + if(_row_counter == _number_of_rows*(_tall_characters ? 16 : 8)) _row_counter = -1; } else if(_vertical_counter == _first_row_location * 2) { @@ -166,7 +166,7 @@ uint16_t MOS6560::get_address() if(_column_counter == _number_of_columns*2) { _column_counter = -1; - if((_row_counter&7) == 7) + if((_row_counter&(_tall_characters ? 15 : 7)) == (_tall_characters ? 15 : 7)) { _video_matrix_line_address_counter = _video_matrix_address_counter; } @@ -226,7 +226,7 @@ uint16_t MOS6560::get_address() */ if(_column_counter&1) { - return _character_cell_start_address + (_character_code*8) + (_row_counter&7); + return _character_cell_start_address + (_character_code*(_tall_characters ? 16 : 8)) + (_row_counter&(_tall_characters ? 15 : 7)); } else { diff --git a/Components/6560/6560.hpp b/Components/6560/6560.hpp index 21a7da4f3..be8f856df 100644 --- a/Components/6560/6560.hpp +++ b/Components/6560/6560.hpp @@ -27,7 +27,7 @@ class MOS6560 { private: std::unique_ptr _crt; - bool _interlaced, _wide_characters; + bool _interlaced, _tall_characters; uint8_t _first_column_location, _first_row_location; uint8_t _number_of_columns, _number_of_rows; uint16_t _character_cell_start_address, _video_matrix_start_address;