Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Comparing VIC-types: 65-cycle-NTSC vs. 63-cycle-PAL
2020-11-05 02:37
Copyfault

Registered: Dec 2001
Posts: 466
Comparing VIC-types: 65-cycle-NTSC vs. 63-cycle-PAL

While experimenting with NTSC-fixing a PAL-based routine for a gfx-mode, I stumbled across an oddity I cannot believe it's true.

Let's consider the following setup: raster IRQ on line $2f, all sprites active, timer configured s.t. it can be used for dejittering and that it gives a unique value for each cycle postion in every rasterline (this is usually the case when using a timer for dejittering).

According to the mighty VIC-article, a PAL-line is build up like this:
cycle# 00000000011111..............555556666
cycle# 12345678901234..............567890123
VIC-op [sprfetch]-XXX[free/badline]XXX[sprf]

The VIC-article also offers a cycle sheet for NTSC:
cycle# 00000000011111..............55555666666
cycle# 12345678901234..............56789012345
VIC-op [sprfetch]-XXX[free/badline]--XXX[sprf]

So the two additional cycles are placed right before the VIC-overtake-cycles for the sprite-fetches start.

Now with the timer we could step through all these cycle positions and check which timer value is read. For this purpose I wrote a little test program: Timercompare NTSC vs. PAL.

To my big surprise, I was not able to reach cycle-position 56 with the timer. Also, after a badline, I only get one value; delaying another cycle makes me read the timer value of cycle position 10 (which I always thought is blocked by a sprite fetch).

Could it be the VIC-article is wrong? Vice gave the same results as a real 65-cycle-NTSC-C64 (Thanks to Groepaz for testing!).

The values I get with my test prog suggest that on 65-cycle-NTSC-machines, the VIC-operations are distributed slightly different, i.e. like this:
cycle# 00000000011111..............55555666666
cycle# 12345678901234..............56789012345
VIC-op [spfetch]--XXX[free/badline]-XXX[sprft]


Maybe this is known already, but for me this was a big surprise so I post it here.

It would be really cool if some NTSC-users ran the test program linked above and share the values that are filled in $0d00..$0d7f.


Or I am completely missing a point and did something wrong in my test prog. But in this case I'd really like to be enlightened how the values can be explained;)
2020-11-05 08:29
Krill

Registered: Apr 2002
Posts: 2839
Can confirm: https://csdb.dk/forums/?roomid=11&topicid=128036#139185

(But i still have only a 64-cycle NTSC machine.)
2020-11-05 09:26
hedning

Registered: Mar 2009
Posts: 4595
WTF is wrong here.

2020-11-05 16:26
Copyfault

Registered: Dec 2001
Posts: 466
Quoting Krill
Can confirm: https://csdb.dk/forums/?roomid=11&topicid=128036#139185

(But i still have only a 64-cycle NTSC machine.)
Thanks for the pointer! Was not aware that this thread also contains a discussion of how the VIC-cycles behave on NTSC machines.

So it seems that THE VIC-article is not correct. Still can't believe it, that article was the ultimate guide for anything about VIC for me... up to now, that is;)

Quoting hedning
WTF is wrong here.
(image left out)
Oh, this looks odd indeed. Could you tell me what kind of setup you have that gives this result? Especially the missing numbers in the upper rows are not as it should be. Or is it "just" some $D8xx-colours accidentally set to dark blue (I refrained from initialising $d8xx)? Hope we can sort this out...
2020-11-05 17:27
hedning

Registered: Mar 2009
Posts: 4595
Quote: Quoting Krill
Can confirm: https://csdb.dk/forums/?roomid=11&topicid=128036#139185

(But i still have only a 64-cycle NTSC machine.)
Thanks for the pointer! Was not aware that this thread also contains a discussion of how the VIC-cycles behave on NTSC machines.

So it seems that THE VIC-article is not correct. Still can't believe it, that article was the ultimate guide for anything about VIC for me... up to now, that is;)

Quoting hedning
WTF is wrong here.
(image left out)
Oh, this looks odd indeed. Could you tell me what kind of setup you have that gives this result? Especially the missing numbers in the upper rows are not as it should be. Or is it "just" some $D8xx-colours accidentally set to dark blue (I refrained from initialising $d8xx)? Hope we can sort this out...


C64 breadbin NTSC, 1983 ASSY 250407. Will test it on my C64C NTSC machine as well later on. will open that one and look what ASSY it is. Both passed C64 diagnostics without errors.
2020-11-05 17:36
Krill

Registered: Apr 2002
Posts: 2839
Quoting Copyfault
Or is it "just" some $D8xx-colours accidentally set to dark blue (I refrained from initialising $d8xx)?
With such an old machine, definitely quite likely. Older ROM revisions set char colours to background colour when clearing the screen. Can quickly be found out using a cartridge monitor, of course.
2020-11-05 17:38
Krill

Registered: Apr 2002
Posts: 2839
Quoting Copyfault
So it seems that THE VIC-article is not correct. Still can't believe it, that article was the ultimate guide for anything about VIC for me... up to now, that is;)
Not the only error or outdated knowledge it has, but it actually only needs a new revision. =)
2020-11-05 18:07
chatGPZ

Registered: Dec 2001
Posts: 11114
don't forget to send patches/updates to https://sourceforge.net/p/vice-emu/code/HEAD/tree/techdocs/VICI..
2020-11-05 18:23
Krill

Registered: Apr 2002
Posts: 2839
Quoting Groepaz
don't forget to send patches/updates to https://sourceforge.net/p/vice-emu/code/HEAD/tree/techdocs/VICI..
Haven't considered this before, tbh. I think many parts need pretty thorough edits and more explanation, first and foremest to make it more accessible and lower the entry bar considerably.
2020-11-05 19:24
chatGPZ

Registered: Dec 2001
Posts: 11114
go ahead :)
2020-11-05 21:12
Silver Dream !

Registered: Nov 2005
Posts: 107
Quoting Copyfault

Could it be the VIC-article is wrong? Vice gave the same results


Let's quickly check it with a different method

https://dl.dropboxusercontent.com/s/hjjfdl15cu983dj/6567R8timin..

This is 6567R8 there.
 
... 10 posts hidden. Click here to view all posts....
 
Previous - 1 | 2 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
Acidchild/Padua
Mythus/Delysid
alwyz/udi
Guests online: 114
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Wonderland XIV  (9.6)
9 Bromance  (9.6)
10 Memento Mori  (9.6)
Top onefile Demos
1 It's More Fun to Com..  (9.7)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 TRSAC, Gabber & Pebe..  (9.5)
6 Rainbow Connection  (9.5)
7 Onscreen 5k  (9.5)
8 Wafer Demo  (9.5)
9 Dawnfall V1.1  (9.5)
10 Quadrants  (9.5)
Top Groups
1 Oxyron  (9.3)
2 Nostalgia  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top Musicians
1 Rob Hubbard  (9.7)
2 Jeroen Tel  (9.6)
3 Stinsen  (9.6)
4 Mutetus  (9.6)
5 Linus  (9.6)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.075 sec.