Re: [hatari-devel] HDDriver issues with WinUAE CPU core (and with EmuTOS) -> RAM detection issue

[ Thread Index | Date Index | More Archives ]

Le 11/01/2015 05:42, Roger Burrows a écrit :
On 11 Jan 2015 at 1:58, Eero Tamminen wrote:

VDI screen memory needs to reside in Atari RAM so that
it can be written.  If it's larger than normal ST screen,
space must be done for it.  stMemory.c:
         /* Set memory size, adjust for extra VDI screens if needed.
          * Note: TOS seems to set phys_top-0x8000 as the screen base
          * address - so we have to move phys_top down in VDI resolution
          * mode, although there is more "physical" ST RAM available. */
         screensize = VDIWidth * VDIHeight / 8 * VDIPlanes;
         /* Use 32 kiB in normal screen mode or when the screen size is
smaller than 32 kiB */
         if (!bUseVDIRes || screensize < 0x8000)
                 screensize = 0x8000;
         /* mem top - upper end of user memory (right before the screen
          * Note: memtop / phystop must be dividable by 512, or TOS crashes
         memtop = (STRamEnd - screensize) & 0xfffffe00;
         STMemory_WriteLong(0x436, memtop);
         /* phys top - This must be memtop + 0x8000 to make TOS happy */
         STMemory_WriteLong(0x42e, memtop+0x8000);

This is pretty bogus for a TT or a Falcon ... and I believe this issue was
related to running TOS 3.06, so must have been TT emulation ...


I agree, I saw this part of the code too, and I think something must be wrong when using VDI (maybe screensize should be rounded to something else, a multiple of 0x8000 ?) Note that it bugs even if no TT ram is added and only 512 KB RAM, so looks really like a resolution problem and screen size values in VDI.

But I don't know VDI that much, someone with more knowledge should have a look at this.


Mail converted by MHonArc 2.6.19+