Jump to content
Sign in to follow this  
vol

PAL or NTSC?

Recommended Posts

Is there an easy way to distinguish a PAL (European) system from NTSC  (American)?  It seems the VDP can't provide this information.

Share this post


Link to post
Share on other sites

Well, as Force Command is able to give that information by typing the sysinfo command (which gives TMS9929A PAL on my system), it must be possible. So I guess you can either ask it's author (Jedimatt42) and/or research his source at Github.

 

  • Like 1

Share this post


Link to post
Share on other sites
54 minutes ago, vol said:

Is there an easy way to distinguish a PAL (European) system from NTSC  (American)?  It seems the VDP can't provide this information.

Sure, count the number of interrupts. You can set the interrupt hook at 83C4, use a loop and check how many interrupts have occurred at the end of the loop. NTSC has 60 interrupts per second, PAL has 50.

 

If you don't have the hardware, you can check it e.g. in MAME when you run the drivers ti99_4ae vs. ti99_4a.

Edited by mizapf
  • Like 1

Share this post


Link to post
Share on other sites
1 hour ago, mizapf said:

Sure, count the number of interrupts. You can set the interrupt hook at 83C4, use a loop and check how many interrupts have occurred at the end of the loop. NTSC has 60 interrupts per second, PAL has 50.

 

If you don't have the hardware, you can check it e.g. in MAME when you run the drivers ti99_4ae vs. ti99_4a.

It sounds like a joke.  We need interrupts to get timings and you ask to use timings to count interrupts. :) I seek rather a ROM byte sequence which allows us to distinguish NTSC from PAL.  IMHO there were only several revisions of main ROM...

Share this post


Link to post
Share on other sites
45 minutes ago, vol said:

It sounds like a joke.  We need interrupts to get timings and you ask to use timings to count interrupts. :) I seek rather a ROM byte sequence which allows us to distinguish NTSC from PAL.  IMHO there were only several revisions of main ROM...

I've just checked PAL and NTSC ROMs.  Surprisingly they are identical!  So there is no an easy way to find out what system is used. :(

Edited by vol

Share this post


Link to post
Share on other sites
2 hours ago, vol said:

It sounds like a joke.  We need interrupts to get timings and you ask to use timings to count interrupts. :) I seek rather a ROM byte sequence which allows us to distinguish NTSC from PAL.  IMHO there were only several revisions of main ROM...

No, seriously, we only have two possibilities: 50 Hz or 60 Hz; this is all you need to find out. From there you can calculate any timing factors as needed.

 

Not sure whether you followed or found the discussions already; the 50Hz vs. 60Hz issue has been mentioned several times on this forum. None of the classic games actually checked for timing, which is why the games run visibly slower on European consoles.

Edited by mizapf
  • Like 3

Share this post


Link to post
Share on other sites

On many systems, the CPU and the VDP are derived from the same clock, so counting cycles is not necessarily reliable, but the TI clocks are distinct, so it's the only way. It's not that nobody thought to look at the ROMs for the last 40 years. ;)

 

  • Like 3

Share this post


Link to post
Share on other sites
On 4/6/2021 at 5:21 PM, vol said:

It sounds like a joke.  We need interrupts to get timings and you ask to use timings to count interrupts. :) 

No, it's not a joke. As indicated in other responses, the CPU in the TI 99/4A is running from one frequency. It's the same in all consoles. The VDP is running from a different frequency, and that's different for PAL and VDP. Thus you can compare the two, by running a certain number of loops (per CPU frequency) and count the number of interrupts that occurs (per VDP frequency) during these loops. A PAL console will run through 5/6 as many interupts as a NTSC console will.

  • Like 4

Share this post


Link to post
Share on other sites
On 4/9/2021 at 11:22 AM, apersson850 said:

No, it's not a joke. As indicated in other responses, the CPU in the TI 99/4A is running from one frequency. It's the same in all consoles. The VDP is running from a different frequency, and that's different for PAL and VDP. Thus you can compare the two, by running a certain number of loops (per CPU frequency) and count the number of interrupts that occurs (per VDP frequency) during these loops. A PAL console will run through 5/6 as many interupts as a NTSC console will.

Let me explain my thoughts about this idea.  I have written code which implemented a simple stopwatch.  I just counted number of interrupts and then divided this number by 60.  It works fine for an NTSC system but for a PAL system we need a different divider, we need 50 instead of 60.  So I sought an easy way to distinguish a PAL system from an NTSC.  I also uses more complex code which uses the TI99/4A timer and is PAL/NTSC independent.  So when I got an idea to make even more complex code to detect PAL or NTSC it sounds for me like a joke. :)

Share this post


Link to post
Share on other sites
45 minutes ago, xahmol said:

You could of course also let the user select PAL or NTSC.

Unfortunately those terms will be meaningless to many users ...   ;-(

Share this post


Link to post
Share on other sites
48 minutes ago, Stuart said:

Unfortunately those terms will be meaningless to many users ...   ;-(

Are you sure? Every single serious Commodore user knows exactly if he (or sometimes she) has a PAL or NTSC.

 

And for the TI: I am pretty sure that the ones having a PAL would know, so you could just say to the user if you don’t know, use NTSC. Also, the target group of people still using the TI and know how to get new software from it from here probably is significantly more knowledgable than the generic home computer owner of the past would be.

 

And if it is a simple toggle, a user can just try both and see what gives best results.

Edited by xahmol
  • Like 1

Share this post


Link to post
Share on other sites

I knew about PAL since I was 12 years old, because I always had this box between the console and the TV set. 🙂

  • Like 1
  • Haha 1

Share this post


Link to post
Share on other sites
Just now, mizapf said:

I knew about PAL since I was 12 years old, because I always had this box between the console and the TV set. 🙂

Same here 😉and know that even as a kid I was making fun of Never The Same Color.....

  • Like 2

Share this post


Link to post
Share on other sites

But that reminded here: instruction to the user is simple. If you have this between console and TV you have PAL....😉

675C9450-E9C4-453D-A32A-0D33526600ED.jpeg

Edited by xahmol
  • Like 2

Share this post


Link to post
Share on other sites
47 minutes ago, xahmol said:

Same here 😉and know that even as a kid I was making fun of Never The Same Color.....

Yes, but as I learned on this forum, we completely missed the blinking stars in Parsec and other NTSC art-ifacts.

  • Like 2

Share this post


Link to post
Share on other sites
2 hours ago, Stuart said:

Unfortunately those terms will be meaningless to many users ...   ;-(

Then rephrase it.

"Is your TV a flickery mess? If yes, press P. If no, press N."

  • Like 2
  • Haha 1

Share this post


Link to post
Share on other sites

I do not know if I understand good the main question because I read some complicate replies on this 😛 
Anyway, talking of real TI99 consoles, the PAL TI99 has a 6pin DIN connector for the video output and the NTSC ones have a 5pin DIN connector instead.
But maybe I have misunderstanding the question.

Share this post


Link to post
Share on other sites
11 minutes ago, ti99iuc said:
But maybe I have misunderstanding the question.

Original question was how to detect from software.

  • Thanks 1

Share this post


Link to post
Share on other sites
9 hours ago, vol said:

Let me explain my thoughts about this idea.  I have written code which implemented a simple stopwatch.  I just counted number of interrupts and then divided this number by 60.  It works fine for an NTSC system but for a PAL system we need a different divider, we need 50 instead of 60.  So I sought an easy way to distinguish a PAL system from an NTSC.  I also uses more complex code which uses the TI99/4A timer and is PAL/NTSC independent.  So when I got an idea to make even more complex code to detect PAL or NTSC it sounds for me like a joke. :)

OK, I can understand you thought it was a catch 22, since at first glance, it looks like you need to know the interrupt frequency to be able to determine it.

But you get the principle now, don't you? If you do a loop where you count until you get, say, 50 interrupts, and count every turn through that loop, you will have made a few more loops in one second than in 0.83 seconds.

Share this post


Link to post
Share on other sites
12 hours ago, Stuart said:

Unfortunately those terms will be meaningless to many users ...   ;-(

Yeah, I don't think that's true. Especially PAL users tend to know, due to the slower play speed.

  • Like 1

Share this post


Link to post
Share on other sites
On 4/9/2021 at 10:22 AM, apersson850 said:

No, it's not a joke.

It would be a joke if a stopwatch app had to ask the user how fast their clock was, so a simple timing loop is a much better solution than asking for NTSC vs PAL.

Share this post


Link to post
Share on other sites

Here is my Extended Basic program that I posted a while ago: It says whether you are using 50 Hz or 60 Hz. (Not a joke.)

 

10 CALL SPRITE(#1,42,8,96,1,0,10)
20 A=0
30 CALL POSITION(#1,X,Y)
40 A=A+1
50 IF Y<20 THEN 30
60 IF A>15 THEN PRINT "PAL/50 Hz" ELSE PRINT "NTSC/60 Hz"

  • Like 3

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...