From d66b7f61b8ab12c0d365749ab0b2118ffec9021b Mon Sep 17 00:00:00 2001 From: alyosha-tas Date: Sat, 29 Jul 2017 19:36:36 -0400 Subject: [PATCH] A7800Hawk: small cleanup --- .../Consoles/Atari/A7800Hawk/A7800Hawk.IEmulator.cs | 1 - .../Consoles/Atari/A7800Hawk/A7800Hawk.IMemoryDomains.cs | 9 +++------ .../Consoles/Atari/A7800Hawk/A7800Hawk.cs | 2 -- .../Consoles/Atari/A7800Hawk/A7800HawkControllerDeck.cs | 1 - .../Consoles/Atari/A7800Hawk/M6532.cs | 1 - .../Consoles/Atari/A7800Hawk/Maria.cs | 2 -- .../Consoles/Atari/A7800Hawk/MemoryMap.cs | 2 +- 7 files changed, 4 insertions(+), 14 deletions(-) diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IEmulator.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IEmulator.cs index 669564dc88..fd9d6691b6 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IEmulator.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IEmulator.cs @@ -279,7 +279,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk { return 0x80; } - } public int Frame => _frame; diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IMemoryDomains.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IMemoryDomains.cs index a3a2523ddb..ce29d7ba3f 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IMemoryDomains.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.IMemoryDomains.cs @@ -48,24 +48,21 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk MemoryDomain.Endian.Little, addr => RAM[addr+0x840], (addr, value) => RAM[addr+0x840] = value, - 1 - ), + 1), new MemoryDomainDelegate( "Ram Block 1", 0xC0, MemoryDomain.Endian.Little, addr => RAM[addr+0x940], (addr, value) => RAM[addr+0x940] = value, - 1 - ), + 1), new MemoryDomainDelegate( "System Bus", 0X10000, MemoryDomain.Endian.Little, addr => PeekSystemBus(addr), (addr, value) => PokeSystemBus(addr, value), - 1 - ) + 1) }; MemoryDomains = new MemoryDomainList(domains); diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.cs index 0ffa92e67d..296378a96a 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800Hawk.cs @@ -76,7 +76,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk _settings = (A7800Settings)settings ?? new A7800Settings(); _syncSettings = (A7800SyncSettings)syncSettings ?? new A7800SyncSettings(); - _controllerDeck = new A7800HawkControllerDeck(_syncSettings.Port1, _syncSettings.Port2); byte[] highscoreBios = comm.CoreFileProvider.GetFirmware("A78", "Bios_HSC", false, "Some functions may not work without the high score BIOS."); @@ -173,7 +172,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk { s_mapper = "0"; } - } else { diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800HawkControllerDeck.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800HawkControllerDeck.cs index 3d9d21dd23..7c761c65b2 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800HawkControllerDeck.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/A7800HawkControllerDeck.cs @@ -137,5 +137,4 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk public static string DefaultControllerName => typeof(StandardController).DisplayName(); } - } diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/M6532.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/M6532.cs index 6ead2370e3..50798c8fbc 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/M6532.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/M6532.cs @@ -6,7 +6,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk // Emulates the M6532 RIOT Chip public class M6532 { - public A7800Hawk Core { get; set; } public byte _ddRa = 0x00; diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/Maria.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/Maria.cs index b0bda9ad97..f36aa4fffd 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/Maria.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/Maria.cs @@ -124,7 +124,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk Core.tia._hsyncCnt = 0; Core.cpu.RDY = true; } - } // "The end of vblank is made up of a DMA startup plus a long shut down" @@ -284,7 +283,6 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk scanline_buffer[pixel] = _palette[Core.Maria_regs[0x00]]; } - // send buffer to the video buffer _vidbuffer[(scanline - 21) * 320 + pixel] = scanline_buffer[pixel]; diff --git a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/MemoryMap.cs b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/MemoryMap.cs index bc1d31ed44..553613d004 100644 --- a/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/MemoryMap.cs +++ b/BizHawk.Emulation.Cores/Consoles/Atari/A7800Hawk/MemoryMap.cs @@ -46,7 +46,7 @@ namespace BizHawk.Emulation.Cores.Atari.A7800Hawk } else { - return 0xFF; // TODO: What if Maria is off? + return 0x80; // TODO: What if Maria is off? } } else if ((addr & 0xFF80) == 0x280)