"Video Timing" Parameter?

A forum about the Hatari ST/STE emulator - the current version is v2.0.0

Moderators: simonsunnyboy, thothy, Moderator Team

siriushardware
Captain Atari
Captain Atari
Posts: 342
Joined: Thu Aug 21, 2014 7:55 pm
Location: UK

"Video Timing" Parameter?

Postby siriushardware » Tue Dec 06, 2016 7:59 pm

In the "System" submenu under the F12 setup menu of Hatari - the screen where you define the machine type and a few other parameters, there is a 'Video Timing" option which can be set to either'Random' or "Wakestate" = 1 through to 4. I can't remember noticing this option pre-Hatari V2, so I assume (perhaps incorrectly) that this is something which is new in Hatari V2.

What is the purpose of this setting?

Under what circumstances would we choose to set it to WS=1, or WS=4, or strangest of all, 'Random'?

Also in the new SDL2 options section of of 'Hatari Screen Options' it would be good to have an 'aspect ratio lock' checkbox so that if, in windowed mode, we drag the window bigger and smaller, the emulated screen will maintain the correct Atari aspect ratio (4:3?) whenever the user alters the X width or Y height or both at the same by dragging one side or one corner of the window.

(So if you pull the window wider, the window also becomes proportionately taller to keep the aspect ratio correct. If you pull the window narrower, the height also decreases to maintain the window at the correct aspect).

User avatar
troed
Atari God
Atari God
Posts: 1171
Joined: Mon Apr 30, 2012 6:20 pm
Location: Sweden

Re: "Video Timing" Parameter?

Postby troed » Tue Dec 06, 2016 8:53 pm

Info on wakestates here: http://www.atari-wiki.com/index.php/ST_STE_Scanlines

tl;dr: It's a quirk of the real hardware that affects demo coding and Hatari is the first emulator to capture them "all".

siriushardware
Captain Atari
Captain Atari
Posts: 342
Joined: Thu Aug 21, 2014 7:55 pm
Location: UK

Re: "Video Timing" Parameter?

Postby siriushardware » Tue Dec 06, 2016 11:53 pm

Troed, thanks for that link. I see that article was mostly written up by you, thanks for doing that. Although most of it goes way over my head, I understand that the essence of it is this:

On the ST, when it starts up, the CPU timing and Glue timing can be offset by any one of four degrees of separation. Once up and running, this timing offset remains constant.

Any software (i.e., demo) looking to use timing tricks on the ST therefore has to be aware of and compensate for any of these four possible timing offsets so that the software will still work regardless of which timing offset is present.

The Wakestate and 'Random' Video Timing settings are there so that anyone attempting to write new software using timing tricks can do so on Hatari because it can now emulate these timing quirks which were previously unique to real ST hardware: The user can either force one particular offset or make the offset random, to check that their software will work on a real ST no matter which of the possible offset timings the real hardware starts up in.

These special modes are only present when the machine selected is 'ST' because on other hardware such as the STe, the timings are hardware locked together and there is no offset to allow for / compensate for.

Is that a reasonable summary?

User avatar
npomarede
Atari God
Atari God
Posts: 1116
Joined: Sat Dec 01, 2007 7:38 pm
Location: France

Re: "Video Timing" Parameter?

Postby npomarede » Wed Dec 07, 2016 9:36 am

More than reasonable, it's a very good summary :)

Nicolas

User avatar
troed
Atari God
Atari God
Posts: 1171
Joined: Mon Apr 30, 2012 6:20 pm
Location: Sweden

Re: "Video Timing" Parameter?

Postby troed » Wed Dec 07, 2016 10:07 am

siriushardware wrote:Is that a reasonable summary?


Top notch! - maybe that explanation should even be reused somewhere :D

If you want to see the effects of it - start Swedish New Year demo 1 and select the TCB screen in WS2. Then do the same in any other wakestate. Note the position of the disting TCB logo during the "tv snow".

Other demos also exhibit these bugs/quirks, I think Nicolas knows one with different effects for three different wakestates IIRC.

/Troed

User avatar
npomarede
Atari God
Atari God
Posts: 1116
Joined: Sat Dec 01, 2007 7:38 pm
Location: France

Re: "Video Timing" Parameter?

Postby npomarede » Wed Dec 07, 2016 10:34 am

troed wrote:Other demos also exhibit these bugs/quirks, I think Nicolas knows one with different effects for three different wakestates IIRC.
/Troed

Yes, this is "The Musical Wonders 1990" demo by Offbeat http://pouet.net/prod.php?which=13917 , which holds the record for having 3 different behaviour depending on WS :) (left/right/bottom borders will be removed or not)

Nicolas


Social Media

     

Return to “Hatari”

Who is online

Users browsing this forum: No registered users and 1 guest