V an H Blanking interupts - timings @ 50hz

GFA, ASM, STOS, ...

Moderators: exxos, simonsunnyboy, Mug UK, Zorro 2, Moderator Team

aag
Atari freak
Atari freak
Posts: 50
Joined: Wed May 09, 2007 9:20 pm
Location: West Yorkshire, UK
Contact:

V an H Blanking interupts - timings @ 50hz

Postby aag » Sat Jan 17, 2009 9:20 pm

Hi

Not sure if this is the correct place(?), but this is more of a theoretical question.

(I'm still wading from the docs @ http://dev-docs.atariforge.org/ - and the useful articles in the ANTIC magazine (which also seems to have lots of other usefil stuff also ):-

http://www.atarimagazines.com/v5n1/68000exceptions.html
http://www.atarimagazines.com/v5n2/Exce ... rupts.html
http://www.atarimagazines.com/v5n3/Exce ... rupts.html

Anyway, what I'm confused about is the ST video mode/timings. According to the SC1425 Manual - the "line frequency" of the monitor is 15625 hz - which is the same as PAL TVs.

The ST didn't use inerlaced mode - and this article http://www.retroleum.co.uk/PALTVtimingandvoltages.html has a good description of non-interlaced images.

Given that you can also make a Monitor -> Scart lead into an RGB TV, http://lipas.uwasa.fi/~f76998/video/modes/ - gives a PAL overview. This tallies with the other doc - saying you have 312.5 lines/field.

This article on full screen progamming http://www.tcs.informatik.uni-muenchen. ... screen.txt, also mentions the VBL interupt at 313.

Everyting seems to tally so far.

What I'm confused about is, the PAL article says you have 288 active lines, + 25 for the vertical retrace = 313.

Yet the full screen article, says you have 277 lines. Whats happened to the missing 11 lines?

Reason for asking is, does the the verticle interupt fine after (277 * (1/15625)) secs OR (288 * (1/15625)) ?

I also guess that any interupt then has either 25 * (1/15625) or ((25+11) * 1/15625) secs to execute in?

As regards horizontal interupts

15625 hz = 64 us / line. The PAL spec says "Line-blanking interval (µs) 12±0.3" (The first 4 microseconds of a scan line are taken up by the horizontal sync signal and following on are 8 microseconds of what is known as the "back porch")

So you have 52 us of active screen (which may not all be visible on screen due to under/over scan). I guess when the horizontal interupts fires, you code has 12us to do its stuff?


Thanks

AAG

User avatar
Greenious
Hardware Guru
Hardware Guru
Posts: 1160
Joined: Sat Apr 24, 2004 5:39 pm
Location: Sweden

Re: V an H Blanking interupts - timings @ 50hz

Postby Greenious » Sun Jan 18, 2009 1:21 am

aag wrote: Not sure if this is the correct place(?), but this is more of a theoretical question.

No, this was more of a coding question, so I moved your message, no harm done.

Anyway, what I'm confused about is the ST video mode/timings. According to the SC1425 Manual - the "line frequency" of the monitor is 15625 hz - which is the same as PAL TVs.

Well, the ST outputs either NTSC or PAL, depending on if it was sold in US or Europe.

The ST didn't use inerlaced mode - and this article http://www.retroleum.co.uk/PALTVtimingandvoltages.html has a good description of non-interlaced images.

Correct.

What I'm confused about is, the PAL article says you have 288 active lines, + 25 for the vertical retrace = 313.

Yet the full screen article, says you have 277 lines. Whats happened to the missing 11 lines?

They are invisible. Ie above and below the visible area of the monitor/TV.

And it is actually 312,5 lines if you want to be precise.

Reason for asking is, does the the verticle interupt fine after (277 * (1/15625)) secs OR (288 * (1/15625)) ?

I also guess that any interupt then has either 25 * (1/15625) or ((25+11) * 1/15625) secs to execute in?


If we talk PAL (50Hz), you have 8.000.000/50 = 160.000 clockcycles in one VBL to execute stuff.

One scanline is always 512 clockcycles. 160.000/312.5=512.

As regards horizontal interupts

15625 hz = 64 us / line. The PAL spec says "Line-blanking interval (µs) 12±0.3" (The first 4 microseconds of a scan line are taken up by the horizontal sync signal and following on are 8 microseconds of what is known as the "back porch")

So you have 52 us of active screen (which may not all be visible on screen due to under/over scan). I guess when the horizontal interupts fires, you code has 12us to do its stuff?


Well, I don't quite follow you here....
Updated my guides as of june 28th, 2016. Check'em out and feedback!
viewtopic.php?t=5040

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sun Jan 18, 2009 5:21 pm

According to some sites, infos Atari ST in PAL mode works little non standard - it generates 313 hor. lines in each V scan. and not 312.5 as should be by PAL standard. Probably just a simplificationi of puc. generation. It is the reason why it has no true interlaced mode. However, on most of TVs, or especially when capture with some TV card, you will see interlaced picture. Because syncro circuits will correct scanning/timing so, that even and odd lines will not align.

Anyway, I think that someone should do simple test for gettening exact Vertical refresh rate - by using 200Hz system timer for instance, and counting V blanks some time. Couple minuts will give pretty accurate result... I will do it...

Horizontal blank: there is much more than 12 microS for code in H-blank. Code can run fine while line is scanned. Must not run only when no pixel generation happens (inactive screen).

aag
Atari freak
Atari freak
Posts: 50
Joined: Wed May 09, 2007 9:20 pm
Location: West Yorkshire, UK
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby aag » Mon Jan 19, 2009 9:51 pm

Horizontal Interupt
I assumed that for the likes of Spectrum 512 etc, you'd get the interupt when the video had finished ouputting the visable area (the 52us) - giving you the "blanking time" to reset pallets etc BEFORE the next line was scanned (ie the 8 us). Although after re-reading the full scren programming article, I guess thats not the case & I need to read up on the "shifter".

That article also says

You should know that one VBL (50 Hz) consists of 160000 clock-cycles (one scanline consists of 512 clock-cycles).


1 scan line = 512 cycle = 512 * (1/ (8 * 1000 * 1000)) = 64 us = The pal standar for "active video" + the blanking time.

The following is where I'm confused.

No 1

313 lines * 512 = 160256 cycles - not the 160000 .

ALSO since Vrefesh * TotalLines = Horizntal Freq then

Vrefresh = 15625 / 313 = 49.920.. hz.
Taking the 8MHZ clock/refesh gives, 8.000.000/49.920 = (again) the 160256 cycles


No 2

313 lines - 25 for blanking = 288 lines.
Not all of these lines woul be visible on a TV, BUT should be on an monitor (eg SC1435) - since you have the "pots" on the back to adjust various bits. What do we think the max no of lines is that the St was able to generate? (The 277 lines mentioned in the article then says lower down that

The first line is needed for synchronisation...


So is 276 the real max no of lines?


Thanks

User avatar
Desty
Atari God
Atari God
Posts: 1948
Joined: Thu Apr 01, 2004 2:36 pm
Location: 53 21N 6 18W
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby Desty » Mon Jan 19, 2009 11:16 pm

aag wrote: That article also says

You should know that one VBL (50 Hz) consists of 160000 clock-cycles (one scanline consists of 512 clock-cycles).


1 scan line = 512 cycle = 512 * (1/ (8 * 1000 * 1000)) = 64 us = The pal standar for "active video" + the blanking time.

The following is where I'm confused.

No 1

313 lines * 512 = 160256 cycles - not the 160000 .

Well, Greenious said above that it's 312.5 lines, not 313. So it's either really 312.5 lines -> 160000 cycles or 313 lines -> 160256 cycles depending on which number you believe.
tá'n poc ar buile!

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Tue Jan 20, 2009 1:49 am

aag wrote:Anyway, what I'm confused about is the ST video mode/timings.


Forget everything you read about PAL (or NTSC). The ST, as most early computers and consoles does not output a standard PAL signal. The video output is conceptually the same, but the timing doesn't even attempt to be close to the standard. The main timing, horizontal and vertical frequency are close enough to the standard, so that any TV or monitor used at the time (purely analog) would sync. But otherwise the standard is not followed strictly.

You can't do any strict math between PAL standard and ST timing, math would not compute. And it is not exacly 50 or 60 Hz, or 64 useconds, it is just approx and not exactly the same on all models. From the point of view of the programmer, you only care that each scan line has 508/512 cycles, and each frame has 262/313 lines on 60/50 Hz mode respectively.

As regards horizontal interupts


I'm afraid it seems you are completely lost regarding interrupts. Interrupts has nothing to do with porch time, and they are not used for Spectrum 512 effects.

Not all of these lines woul be visible on a TV, BUT should be on an monitor (eg SC1435)...


No, a monitor would typically display more data than a TV, but no analog display could display all of them.

What do we think the max no of lines is that the St was able to generate? (The 277 lines mentioned in the article ...


You are mixing oranges with apples. 277 is the max number of scan lines that the ST can be "fooled" (in overscan mode) to display active data from RAM. It has no direct relation with the total number of lines generated, and/or actually seen in the TV/Monitor.

The first line is needed for synchronisation... So is 276 the real max no of lines?


Hmm, I'm afraid a complete answer would be very long. You are trying to understand the details of some very advanced techniques, while I'm not sure you understand yet the fundamentals.

User avatar
Nyh
Atari God
Atari God
Posts: 1496
Joined: Tue Oct 12, 2004 2:25 pm
Location: Netherlands

Re: V an H Blanking interupts - timings @ 50hz

Postby Nyh » Tue Jan 20, 2009 10:07 am

aag wrote:What I'm confused about is, the PAL article says you have 288 active lines, + 25 for the vertical retrace = 313.

Yet the full screen article, says you have 277 lines. Whats happened to the missing 11 lines?

In those 11 lines the shifter doesn't read data from memory so they don't count for full screen programming. But you cab display colors in those lines by changing color register 0: move.w #$700,$ffff8240.w. By doing this you can use the full 288 visible lines of the screen like I do in my raster demo: http://files.dhs.nu/files_demo/rasters.zip

aag wrote:Reason for asking is, does the the verticle interupt fine after (277 * (1/15625)) secs OR (288 * (1/15625)) ?

I also guess that any interupt then has either 25 * (1/15625) or ((25+11) * 1/15625) secs to execute in?

As regards horizontal interupts

15625 hz = 64 us / line. The PAL spec says "Line-blanking interval (µs) 12±0.3" (The first 4 microseconds of a scan line are taken up by the horizontal sync signal and following on are 8 microseconds of what is known as the "back porch")

So you have 52 us of active screen (which may not all be visible on screen due to under/over scan). I guess when the horizontal interupts fires, you code has 12us to do its stuff?

The correct way to talk about timing of the Atari ST is in clock cycles. All the video timing is derived from the 8 MHz master clock. One scan line is 512 clock cycles, one vbl is 160256 clock cycles (at 50 Hz).

With fullscreen programming and for Spectrum 512 effects you don't use scan line interrupts for synchronization because the are not exact enough. Most fullscreen demo's loose sync during the VBL and have to resynchronize in the first scan line with active data. But if you stay in sync (like I do in my raster demo) there is no need for a resync.

Hans Wessels

aag
Atari freak
Atari freak
Posts: 50
Joined: Wed May 09, 2007 9:20 pm
Location: West Yorkshire, UK
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby aag » Tue Jan 20, 2009 7:52 pm

Thanks for the replies. I thought I had an understanding of the crt analogue signals and was trying to "work backwards".

I found this article which seems to explain things from a hardware point of view :-

http://alive.atari.org/alive9/ovrscn1.php

Thanks again

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Tue Jan 20, 2009 8:14 pm

I made testings with SW made quickly, only for this purpose. Needed to kill 200Hz timer to get accurate H-line counts.
Results are according to infos on many sites: in PAL mode ST(E) generates exactly 313 lines in every V-blank. Or 626 lines in one TV frame. It is the reason for troubles with some new (digital) TVs, TV cards. Standard line count by PAL is 625. In NTSC mode it generates 263 lines.

Then I measured duration of 3000 V-blanks with 200Hz timer. Measuring should be very accurate as 200Hz timer has own crystal (at MFP) and it is same in all machines (2.4576 MHz) as I know. Mega STE has slightly faster V-scan and Mega ST slightly slower. But difference from standard 50Hz is always less than 1 promile. Same in NTSC mode. Reason is of course that system clock is delivered from not exactly 32MHz in ST(E) - exact freq. varies in diverse Atari models. All this small deviations are irrelevant (unless you programm some very special demo where using MFP too).
So, please don't refer more to 312.5 lines. It is not matter of believing - but testing, measuring. Maybe Greeny just talked about TV standard, not ST ?

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Wed Jan 21, 2009 1:14 pm

Some vertical refresh rates:

stevfreq.png


STE: PAL: 50.050 Hz Monochrome: 71.471 Hz
Mega ST : PAL: 49.983 Hz Monochrome: 71.477 Hz
Mega STE: PAL: 50.054 Hz Monochrome: 71.471 Hz
Falcon: PAL: 50.054 Hz VGA: 59.940 Hz

Last cypher is not accurate (it would need longer measuring time than 1 min) .

Proggy for measuring is here: http://ppera.07x.net/atari/astopensw.php
You do not have the required permissions to view the files attached to this post.

User avatar
Greenious
Hardware Guru
Hardware Guru
Posts: 1160
Joined: Sat Apr 24, 2004 5:39 pm
Location: Sweden

Re: V an H Blanking interupts - timings @ 50hz

Postby Greenious » Sat Jan 24, 2009 2:09 am

ppera wrote: Maybe Greeny just talked about TV standard, not ST ?


:) Not everything i say is 100% accurate. Even though most things I do comment is pretty darn close to spot on. :D

I did my fair share of dabbling in he demoscene when I was young, had a few excellent teachers and a lot of what I learned, even though accurate enough for what we were doing, is not always 100% correct.

Anyway, I am, as always, impressed by the boardmembers ability to provide 100% accuracy, aswell as flattered over the fact that some people obviously have enough confidence in me that they question their own facts just because what I said wasn't 100% accurate.

However, when it comes to Horizontal Scanlines, I do stick with my 312.5 lines, because I was once shown the entire image atari outputs on a specially modded monitor, and saw the last line flicker around halfway across the monitor.

And I want you all to know that I really love you, respect you and I am not at all offended by you hinting that I'm not mr. 100%. :) And even if you did prove me completey wrong, I am not the one holding a grudge, so keep corrcting me!

Keep up the good work chaps! :D
Updated my guides as of june 28th, 2016. Check'em out and feedback!
viewtopic.php?t=5040

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Sat Jan 24, 2009 3:25 am

Greenious wrote:
ppera wrote: Maybe Greeny just talked about TV standard, not ST ?

:) Not everything i say is 100% accurate. Even though most things I do comment is pretty darn close to spot on. :D


Don't worry. Actually Ppera was wrong for a couple of years until, I'm glad to see now, he finally came to agree with the rest of us that the ST video signal is not interlaced.

However, when it comes to Horizontal Scanlines, I do stick with my 312.5 lines, because I was once shown the entire image atari outputs on a specially modded monitor, and saw the last line flicker around halfway across the monitor.


I'm not sure what exactly was the reason for that effect, but it can't be 312.5 for a very simple reason. Odd number of scan lines per full frame (two fields) vs. even number, is (almost) the definition of interlaced vs. non-interlaced. If you agree the ST signal is not interlaced, then it must have an integer number of scan lines.

Besides, Hans knows exactly what he is talking about, because his demo depends on this (he counts cycles across frame). And if you still have doubts, then hook a scope to Vsync & Hsync signals :)

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sat Jan 24, 2009 11:42 am

I think that is always good to check things on different ways . All facts were suggesting that it is 2x313 lines when talking about one full tv frame. What i did with simple SW confirms it .
Now some speculation: what Greeny says about seeing flickering last line proves nothing because you see result of processed syncing and not what really came out from st . This leads us little further about question what is interlaced video. My answer is that interlaced video is what is visible on monitor as interlaced. Even if ST generates not interlaced signal by TV standards it is usually visible as interlaced on most of TVs because syncro circuits will correct timing. According to what is told here, by some TVs it may be that even and odd lines almost overlap, but it is not common. Saying that ST generates progressive 50 fps video with 200 lines is maybe correct but in practice you just never connect it to such monitor as they exists not in public. We connect STs to TVs which work in interlaced mode so we will have usually interlaced pic what is proven by my eyes looking at many different televisions, monitors, and some photos.
Last edited by ppera on Sat Jan 24, 2009 6:08 pm, edited 1 time in total.

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sat Jan 24, 2009 11:52 am

ijor wrote:,
Don't worry. Actually Ppera was wrong for a couple of years until, I'm glad to see now, he finally came to agree with the rest of us that the ST video signal is not interlaced.

I did not talk about scanlines, their count etc. Just talked that I see interlaced picture on televisions. For further see reply above. (and below) .
Last edited by ppera on Sat Jan 24, 2009 6:10 pm, edited 1 time in total.

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sat Jan 24, 2009 5:39 pm

Yet another argument for discussion about interlaced nature of ST's video: capturing high-res from ST in color mode, with TV card. Obviously, it has 400 horizontal lines. It is actually special mono-emulator, where we have all 400 horizontal lines displayed and visible. It is achieved by alternating video buffer at each V-blank. Actually, such mono-emulator requires 3 video buffers - one where SW writes mono display data. Then in V-blank we convert it for medium-res and write in 2 buffers, interlaced.
This mono-emulator (adaptation) was not really usable because of terrible flicker, but is good for demonstrating that ST can produce interlaced video. And it looked same on my TV - all 400 lines were visible.

What I want to point is that beeing interlaced or not interlaced depends mostly from used monitor. Saying that ST has progressive video of 50 fps and vertical res. of 200 sounds not good for me. Did anyone used it on monitor which displays picture in that way ?
You do not have the required permissions to view the files attached to this post.

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Sun Jan 25, 2009 2:04 am

ppera wrote:I did not talk about scanlines, their count etc. Just talked that I see interlaced picture on televisions.


Of course that you didn't just claimed about what you see on TVs. You claimed (and in a very heated way) that the ST outputs an interlaced video signal, and such things as the ST altering VSYNC between both fields.

Even if ST generates not interlaced signal by TV standards it is usually visible as interlaced on most of TVs because syncro circuits will correct timing.


No, most displays won't interlace, certainly no old analog display (as the monitor in the ST era) will.

Things are completely different with newer digital displays. But older displays were very dumb, they would display whatever they receive at the SYNC signals. If the SYNC signals are for an interlaced display, they will interlace, otherwise they will not. There is no way they could automagically interlace.

How can a simple display re-interlace a non-interlaced signal? How can it know which field goes above and which one goes below?

Saying that ST generates progressive 50 fps video with 200 lines is maybe correct but in practice you just never connect it to such monitor as they exists not in public.


They of course exist. Every old analog TV and all ST compatible monitors, are exactly that. They can display 240p (200 ST lines), or 480i. And I say old analog TV, because newer digital displays are pickier and some won't accept the ST video signal.

Yet another argument for discussion about interlaced nature of ST's video: capturing high-res from ST in color mode, with TV card. Obviously, it has 400 horizontal lines. It is actually special mono-emulator, where we have all 400 horizontal lines displayed and visible. It is achieved by alternating video buffer at each V-blank.
...
This mono-emulator (adaptation) was not really usable because of terrible flicker, but is good for demonstrating that ST can produce interlaced video.


This has nothing at all to do with interlaced (at least not with an analog display). All you are doing is displaying a fast animation of both "halves" of the high-rez screen. The eye will blend both and would percieve them as a single screen, getting somewhat the effect of high-rez. The same technique was used in 8-bit computers and even in the 2600. It was used also for many other effects, including increasing the color palette or the horizontal resolution. You can even, if you want, do similar effects with a modern CRT VGA monitor.

You might get a good stable, non flickering, high-rez screen when using a video capture or a digital display. A digital device (display or capture) can and sometimes does re-interlace. Some modern LCD-TVs even have a flicker-fixer.

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sun Jan 25, 2009 10:51 am

ijor wrote:Of course that you didn't just claimed about what you see on TVs. You claimed (and in a very heated way) that the ST outputs an interlaced video signal, and such things as the ST altering VSYNC between both fields.
...
No, most displays won't interlace, certainly no old analog display (as the monitor in the ST era) will.
...
Things are completely different with newer digital displays. But older displays were very dumb, they would display whatever they receive at the SYNC signals. If the SYNC signals are for an interlaced display, they will interlace, otherwise they will not. There is no way they could automagically interlace...
How can a simple display re-interlace a non-interlaced signal? How can it know which field goes above and which one goes below?..
They of course exist. Every old analog TV and all ST compatible monitors, are exactly that. They can display 240p (200 ST lines), or 480i. And I say old analog TV, because newer digital displays are pickier and some won't accept the ST video signal...
This has nothing at all to do with interlaced (at least not with an analog display). All you are doing is displaying a fast animation of both "halves" of the high-rez screen. The eye will blend both and would percieve them as a single screen, getting somewhat the effect of high-rez. The same technique was used in 8-bit computers and even in the 2600. It was used also for many other effects, including increasing the color palette or the horizontal resolution. You can even, if you want, do similar effects with a modern CRT VGA monitor.


Here is what I wrote in former discussion about it: "And I didn't said that it must have total 625 lines. I said that timing of V-sync may be different in 2 fields. It means that we have 626 lines total, and it is why ST sucks when capturing. "

So, I really don't see about what you talk, Ijor. I was just upset because of ridiculous claims about overlapping of even and odd lines on televisions "because you can not see it good on small displays" - something like that. Truth is that it is good visible on every decent TV with good focus.

So, after we all agreed about 626 lines (except Greeny) we could move further, and asking someone with equipment that check is 2 V-sync pulse in one frame same. Aly could do it with her logic analyzer.( I expect that they will be same. )

I don't know how Atari color monitor displayed it, as I never looked it closer. But I attached Atari on several TVs, on many via RGB connection, and never got overlapped even and odd lines. In some cases it was just partial overlap, but not much.

Displays (TVs) from ST era were not dumb. In that era usage of complex cyncro chips was common. And that chips were in some cases partially digital. Before you reply again something, just to remind that I worked as TV servicer in that time.
And we had even digital TV, ITT brand in eighties, based mostly on 80xx microcontroller.

If both V-sync pulse is same, or it is not standard, display don't know which field is odd or even. But it is irrelevant, you will still have interlaced picture, maybe with reversed field order (what exactly happens sometimes with TV card and ST).

It is true that ST generates not true interlaced video. But it means not that we see not interlaced picture on televsions. And it is where you are wrong, Ijor. Your conclusion is based on some theory and maybe on some experiences (but I'm not sure that you can determine is pic interlaced by looking on).

What you wrote in last paragraph about blending lines is again just theory, and disrespect of others writings, experiences. If I said that all 400 line were visible on TV, it was so, and there was no blending. Picture flickered in way, that lines jumped up-down. In case of blending it would not jump, just flash. Not to mention (what I already talked) that picture with every second line dark is very ugly, and it is 'visible from airplane' .
I used mono-emulator with SW blending, btw. Or other way was to show only half of hi-res screen, and it scrolled up-down when mouse went out from visible area.

So much from me about this. I will not discuss it until getting some V-sync pulse test results.

User avatar
alexh
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 2579
Joined: Wed Oct 20, 2004 1:52 pm
Location: UK - Oxford
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby alexh » Sun Jan 25, 2009 2:09 pm

I've got a video protocol analyser here. I'll dig it out and try it with Atari ST. (I said I would do it last time we had this argument and never did)

But I KNOW that other computers of that generation and earlier do NOT drive alternating field values via their H&V sync.

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Sun Jan 25, 2009 6:16 pm

alexh wrote:I've got a video protocol analyser here. I'll dig it out and try it with Atari ST. (I said I would do it last time we had this argument and never did)
But I KNOW that other computers of that generation and earlier do NOT drive alternating field values via their H&V sync.


Go on with it :D
I mean, it will not convict some people about how ST's video is aligned on TVs, but we will know is video signal at least trying little to be more standard. In any case, there is no any way that you can detect by SW on Atari ST in which field you are.
In my video player proggy there is option to change (swap) field order exactly because of this - as video playbacks at 25 fps, ST shows every frame 2x. But if it starts with wrong field we have interlace, as one field is from previous frame, and other from current. It works simple - by just waiting one V-blank when activated.

User avatar
alexh
Fuji Shaped Bastard
Fuji Shaped Bastard
Posts: 2579
Joined: Wed Oct 20, 2004 1:52 pm
Location: UK - Oxford
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby alexh » Sun Jan 25, 2009 8:07 pm

ppera wrote:In my video player proggy there is option to change (swap) field order exactly because of this - as video playbacks at 25 fps, ST shows every frame 2x. But if it starts with wrong field we have interlace, as one field is from previous frame, and other from current. It works simple - by just waiting one V-blank when activated.

In my Video player proggy there is a de-interlace option to Named "old video games" or something.

DScaler

That always got me best results with MegaSTe connected to PC via composite.

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Mon Jan 26, 2009 1:59 am

Capture from the ST HSYNC and VSYNC signals:
FullTrace.png

FullFrame.png

Vsync1.png

Vscyn2.png

Vsync3.png
You do not have the required permissions to view the files attached to this post.

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Mon Jan 26, 2009 2:01 am

ppera wrote:Here is what I wrote in former discussion about it: "And I didn't said that it must have total 625 lines. I said that timing of V-sync may be different in 2 fields. It means that we have 626 lines total, and it is why ST sucks when capturing. " So, I really don't see about what you talk, Ijor.


I didn't say you claimed anything about the number of lines. I said you claimed that the ST outputs an interlaced video signal. Let's see some extracts about what you said then:

ppera wrote:Sorry folks, but you are talking some very funny things.
Atari ST works in color mode always in interlaced mode. We may even say that it works in 'true interlace' mode. Why? Because it is standard way how TVs work.
...
You talk about that ' I know that ST has not interlaced video'...
Actually, it is first time that I hear something like it. And I will believe first to my eyes, not to what I read here or on some Wiki sites and similar.
...
'... Other 'tricks' use an even number of lines (with slightly different picture rates as a consequence if the line duration is unchanged) producing a non-interlaced picture with 312 or 313 lines and a repetition rate of about 50 Hz.'

This is what ijor talks about, although on site no mention about blank lines. I'm sure that it is not case by ST. It can't be such crap


It looks to me you are definitely talking about the ST video output, and not just about how it is displayed on a TV or monitor.

I don't know how Atari color monitor displayed it, as I never looked it closer...
Displays (TVs) from ST era were not dumb. In that era usage of complex cyncro chips was common. And that chips were in some cases partially digital. And we had even digital TV, ITT brand in eighties, based mostly on 80xx microcontroller.


So you are now claiming that most displays at the time were digital ?! Don't you think it would be a good idea to chek an Atari color monitor. The schematics of the SC1224 are available online, and I don't see any complex digital logic.

If both V-sync pulse is same, or it is not standard, display don't know which field is odd or even. But it is irrelevant, you will still have interlaced picture, maybe with reversed field order (what exactly happens sometimes with TV card and ST).


Then why you never see a reversed field order on old analog displays? If fields are reversed then any animation at 50/60 fps, or on any rate non-multiple of two frames for that matter, will produce distorsion in the vertical movement.

I know that most ST games use 25 fps, but some games and demos do 50 fps. Plus other computers, including the STe and some 8-bit ones, have vertical hardware scroll or vertical sprites. You never see reversed fields on those when using an old analog display.

A modern device, be it a capture card, LCD display, or even some modern CRTs do of course digital processing. And here they do sometimes force an interlaced display producing sometimes a reversed order of the fields.

Your conclusion is based on some theory and maybe on some experiences (but I'm not sure that you can determine is pic interlaced by looking on). What you wrote in last paragraph about blending lines is again just theory, and disrespect of others writings, experiences.


Sorry, but I think it is exactly the other way around. It is you the only one that claims (or claimed) that the ST outputs an interlaced video, and that old analog displays would still interlace a non-interlaced signal. Everybody else, and every reference claims the contrary. Alexh asked video experts in his job. Check other vintage computer forums if you want, this is not specific or unique to the ST. All the older console and computers used the same 240p video.

Not to mention (what I already talked) that picture with every second line dark is very ugly, and it is 'visible from airplane' .


It is again your subjective impression. Do you know that some scan-doublers for vintage computers specifically emulate that effect? Do you know that some emulators are now implementing (or trying to) exactly that? Problem is that is not trivial, the dark alternating lines on an old display are thinner and not 100% sharp, as you would get with simple "emulation" of this effect on a modern monitor.

I will not discuss it until getting some V-sync pulse test results.


I made some tests for you above. Hope it is now clear that the ST outputs a plain non-interlaced signal.

ijor
Hardware Guru
Hardware Guru
Posts: 3095
Joined: Sat May 29, 2004 7:52 pm
Contact:

Re: V an H Blanking interupts - timings @ 50hz

Postby ijor » Mon Jan 26, 2009 4:54 am

ppera wrote:Not to mention (what I already talked) that picture with every second line dark is very ugly, and it is 'visible from airplane' .


I think I know why you think that way.

Please, Pera, read the following with an "open mind". Please, consider that may be, perhaps, there is a small chance that you are wrong and all your conclusions were wrong from the start. If you are not going to read the following with an "open mind", then it might be better to ignore this message completely.

You said in the "old" thread:

ppera wrote:That ST has so limited video signal can't be true. Much older and cheaper machines had correct PAL video - for instance Sinclair Spectrum.
...
Second: I know exactly how looks when odd and even lines are on same place on screen. I made UVY-RGB converter for ZX Spectrum some 12 years ago ( http://www.ppest.org/zx/uvyrgb.htm ), and now it has contact error - when it arrives I get blank lines - every second. But it is so visible ( from airplane, can say) and is so ugly that no way that ST sends such picture to TV/monitor.


So you were saying that the Spectrum generates interlaced video. I was curious and made a bit googling. All the references I found claim the contrary, that the Spectrum generates non-interlaced video.

I'm not nearly an expert on the Spectrum. I didn't find a comprehensive description of the hardware or schematics. I have no Spectrum to make any tests. But again, all the references I found (which weren't too many) including Wiki (which yes, it is wrong many times), claim that it is non-interlaced. And it makes a lot of sense to me. It would be very unusual, and pretty much useless, for a vintage home-computer to generate interlaced video.

Now, if you take a non-interlaced signal, and blank every other line, then of course that the effect would be visible from the moon. This is completely different that when the lines on the "other field" (and only in the other field) are blank.

Once again, I'm in now way certain about the Spectrum video. But if you were wrong all the time about the Spectrum interlacing, then this might explain all your reasoning.

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Mon Jan 26, 2009 3:48 pm

Thanx God, finally we have some sync pulse captures... It could be done earlier, for sure.
So, I was wrong in the beginning of discussion, when assumed that interlaced (or correct even/odd aligned) picture on most of (Color televisions in mid of eighties) is result of Ataris somehow standard timed signal. But real problems in discussion were about how TV picture looks. And there discussion went in wrong way. Because of mentioned ridiculous claims about blank lines and similar. One thing is sure - Sinclair Spectrum has (little) different timing than Atari ST. It has no overlapped even/odd on most of televisions too.
Only reasonable conclusion, considering Atari's picture on TVs is that syncro circuits correct timing. And I did not say that most of TVs were digital in ST era. Read it again. Just talked about complex sync. chips. Actually, I don't remember how STs pic looked on some old, tube B/W TV. And such TVs had usually unsharp pic, so hard to see line align.
Reversed field order is visible on analogue displays, but in special cases. You will not see interlace, except if source is progressive video. Because by regular interlaced TV signal time diff. is always 1/50 sec. Only that fields are in wrong order, so what should be lower is upper - but it means nothing, as they are mutually good placed.
I remember that sometimes some movies (progressive video, at 25 fps by PAL) were broadcasted so (with reversed fields), and it was very visible on television. And above is answer why you not see it when looking 50 fps demos.
Game Nebulus can have such error, as is with true 25 fps. And if it starts in wrong phase, you will have big interlace (visible on TV too). I even have some video captures with it on my site: http://ppera.07x.net/atari/stvid.php

ppera

Re: V an H Blanking interupts - timings @ 50hz

Postby ppera » Mon Jan 26, 2009 4:05 pm

ijor wrote:You said in the "old" thread:......
So you were saying that the Spectrum generates interlaced video. I was curious and made a bit googling. All the references I found claim the contrary, that the Spectrum generates non-interlaced video....


This is problem with you Ijor - you make wrong conclusions. I talked about it just to show how overlapped even/odd lines are very good visible. Btw. It may be one of TV failures - even/odd overlapping, when syncro circuit has some error. Rare failure, but I encountered it couple times.
With 'open-mind' I see that I talked: about 'correct video' , in meaning that it had good picture on common home televisions.
Is that video 'true interlaced' by some professional standards was not my concern. What matters is what we have as result - on display. I posted here in forum some photos, but they are now lost. On them is fine visible intelaced picture. And it was that by one TV it was partial overlap, by other exactly correct positioning.
As I said couple times, is video interlaced or not depends mostly from display. As display is that, who does line placements.

I expect that Ijor, if want to continue this discussion post here some photos of overlapped even/odd lines on some monitor.
I believe that it was so by some. I say it because 'every second line dark' is exactly what happens when even/odd overlaps.
(Is video interlaced or not affects not speed of vertical scan.)

Finally, I hope that all we could learn something from this.


Social Media

     

Return to “Coding”

Who is online

Users browsing this forum: No registered users and 3 guests