From: Toni Wilen Date: Fri, 23 Sep 2022 17:35:32 +0000 (+0300) Subject: A1000 memory power up pattern X-Git-Tag: 41000~139 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=d0619219a6877d59a58de13517244fdc02dc0f6c;p=francis%2Fwinuae.git A1000 memory power up pattern --- diff --git a/memory.cpp b/memory.cpp index 86a17350..ff8f14fd 100644 --- a/memory.cpp +++ b/memory.cpp @@ -2625,7 +2625,7 @@ static void fillpattern(addrbank *ab) } } } - } else if (currprefs.cs_memorypatternfill) { + } else if (currprefs.cs_memorypatternfill && !currprefs.cs_dipagnus) { // OCS Agnus has swapped row and column compared to ECS and AGA. uae_u16 fillval = 0; for (int fillbank = 0; fillbank < ab->allocated_size / 256; fillbank++) { @@ -2635,6 +2635,19 @@ static void fillpattern(addrbank *ab) *((uae_u16 *)(ab->baseaddr + fillbank * 256 + fillrow)) = fillval; } } + } else if (currprefs.cs_memorypatternfill) { + // A1000 + uae_u16 fillval = 0; + for (int fillbank = 0; fillbank < ab->allocated_size / 512; fillbank++) { + fillval = ~fillval; + for (int fillrow = 0; fillrow < 512; fillrow += 2) { + // Chip emulated: Generic 4256. 16 * 512x1. + *((uae_u16 *)(ab->baseaddr + fillbank * 512 + fillrow)) = fillval; + if (((fillrow >> 1) & 15) == 15) { + fillval = ~fillval; + } + } + } } else { memset(ab->baseaddr, 0, ab->allocated_size); }