Re: [hatari-devel] Sync byte on Falcon |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
- To: hatari-devel@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [hatari-devel] Sync byte on Falcon
- From: Thomas Huth <th.huth@xxxxxxxxx>
- Date: Sun, 19 Nov 2023 17:04:37 +0000
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.de; s=2017; t=1700413479; bh=6DYZQ/9oz7dlAiThKWJ+QIluxs2SKpnm1weENlKb2sI=; h=Date:From:To:Subject:Message-ID:MIME-Version: Content-Transfer-Encoding:From; b=W4o9D9ASCgGlsvcSU4I+HX8N+IgECERbZT0zAfQKlJwJb/3/JWW/+MRuEJAo3oP1K RqG/UUaR1Np9RnckDjCFKMZ+qqbpN3ppzv8hbSy1hmOzkIOu946Mq68zjdgTd0Wbsp bFMQALOOuDRuyy5XQiIiKX5VRFgBEBKsKLj2MVwI4Y3H+aY99+vjaLpkxhgDrlabem XFkjplvOxc+peABG1PWCw89bSPvDvySKaXrPzeEhnDkaSfPqgW8xpEB5U8s3XyG+O1 DfNEZ6psgY0UwtlVcgs4pdQWcKplm7wBdaht3E1wvv972Jdhut/+xiehyPOzgZ7SQO UqwdZiW5PzMqg==
Am Sat, 18 Nov 2023 14:46:08 -0500
schrieb "Roger Burrows" <anodyne@xxxxxxxxxxxx>:
> On 18 Nov 2023 at 7:43, Thomas Huth wrote:
>
> > Am Wed, 15 Nov 2023 22:35:42 -0500
> > schrieb "Roger Burrows" <anodyne@xxxxxxxxxxxx>:
> > > The following results were all gathered using TOS 4.04.l
> > >
> > > With both an RGB monitor and plain old VGA, reading 0xff820a on my Falcon
> > > returns 0x00, which indicates 60Hz. Looking at the Hatari source
> > > (VIDEL_SyncMode_WriteByte() in Hatari 2.3.0), if there isn't a mono monitor
> > > connected, whenever you write to 0xff820a, Hatari kindly ORs it with 0x02,
> > > which is then always returned to a program reading that byte.
> > >
> > > I think Hatari is clearly wrong: bit 1 on a Falcon means exactly the same as
> > it
> > > does on an ST(e) and should be handled in a similar fashion.
> >
> > Ok, that really sounds like the documentation (and thus Hatari) was wrong.
> >
> > I can change the source code in Hatari, but I'd like to have a better
> > understanding how this register really behaves.
> >
> > So if you've got some spare minutes, could you write a little test program
> > that:
> >
> > - Reads ff820a to back up the original value
> > - Write 0xfc to ff820a and read back the value from the register
> > - Write 0x02 to ff820a and read back the value from the register
> > - Write 0x01 to ff820a and read back the value from the register
> > - Restore the original value to the register
> > - Print out the three values that have been read back after altering the
> > register
> >
> > and then run it with your RGB monitor (or let me know if you want me to
> > write such a program instead).
>
> OK, values returned are 0x00, 0x02, 0x01 respectively.
Great, thanks for testing! So the upper bits are hard-wired to zero, and
the lower two bits can be changed, indeed. Changed in Hatari now
accordingly:
https://git.tuxfamily.org/hatari/hatari.git/commit/?id=96d7e168b8a79d9c0add5308e17ad89e952b1071
HTH,
Thomas