src/memory/mappers/sxrom.cc
/*
 * Reloads the CHR bank selections from the CHR registers using the currently
 * selected bank switching mode in the control register.
 */
Reloads the CHR bank selections from the CHR registers using the currently
selected bank switching mode in the control register.
Reloads the CHR bank selections from the CHR registers using the currently selected bank switching mode in the control register .
void Sxrom::UpdateChrBanks(void) {
  if (control_reg_ & FLAG_CHR_MODE) {
    chr_bank_a_ = chr_a_reg_ & chr_bank_mask_;
    chr_bank_b_ = chr_b_reg_ & chr_bank_mask_;
  } else {
    chr_bank_a_ = chr_a_reg_ & chr_bank_mask_ & (~1U);
    chr_bank_b_ = chr_bank_a_ | 1U;
  }
  return;
}
void Sxrom :: UpdateChrBanks ( void ) { if ( control_reg_ & FLAG_CHR_MODE ) { chr_bank_a_ = chr_a_reg_ & chr_bank_mask_ ; chr_bank_b_ = chr_b_reg_ & chr_bank_mask_ ; } else { chr_bank_a_ = chr_a_reg_ & chr_bank_mask_ & ( ~ 1U ) ; chr_bank_b_ = chr_bank_a_ | 1U ; } return ; }
Reloads the CHR bank selections from the CHR registers using the currently
 selected bank switching mode in the control register.
Reloads the CHR bank selections from the CHR registers using the currently selected bank switching mode in the control register .
// Update the CHR bank selection using the high bit of the control register. // 4KB bank mode. // 8KB bank mode.