Jump to content

Photo

TI-99/4A Timing Captures


8 replies to this topic

#1 Tursi OFFLINE  

Tursi

    Quadrunner

  • 5,243 posts
  • HarmlessLion
  • Location:BUR

Posted Sat Jun 30, 2018 11:23 PM

With my cart finally working, I was finally able to run my own video conversions on hardware, where they are a bit slower than I'd like (roughly 10% slower than they should be). Since I've known for a long time that Classic99 is missing "something" in its timing, I've always meant to get back to the logic analyzer someday and start measuring performance.

Someday was today.

This Google doc captures my tests and analysis. I was interested in verifying memory access cycles, particularly for previously unknown (to me) peripherals like the sound chip. (Spoiler - it's slower than GROM...) This will allow me to improve the accuracy of Classic99's timing so I can tune my video player to run correctly on hardware.

Specifically I measured read and write to:

- 16 bit RAM
- 8 bit RAM
- VDP
- Sound
- Speech
- GROM Address
- GROM Data

https://docs.google....kVJitHrRKoH4VAo

If you'd like to look at the actual captures, you can use the LogicPort software in demo mode (http://www.pctestinstruments.com/) and open the attached files.

Attached File  TI_Access_Timing_LogicPort.zip   60.31KB   12 downloads

Enjoy!

#2 jedimatt42 OFFLINE  

jedimatt42

    Stargunner

  • 1,807 posts
  • Location:Beaverton, OR

Posted Sun Jul 1, 2018 12:11 AM

Wow! Thanks for capturing all that... That is going in the study guide. :)  

 

So, if I understand what you documented correctly, 'Clock' in the diagrams is the PH1 input on the 9900? 

 

-M@



#3 Asmusr OFFLINE  

Asmusr

    River Patroller

  • 2,874 posts
  • Location:Denmark

Posted Sun Jul 1, 2018 12:59 AM

That is very helpful. Thank you.



#4 acadiel OFFLINE  

acadiel

    Stargunner

  • 1,425 posts
  • www.hexbus.com
  • Location:USA

Posted Sun Jul 1, 2018 8:13 AM

That's a very tedious labor of love, Tursi. Thanks for sharing it with everyone!

Sent from my moto g(6) using Tapatalk

#5 OLD CS1 OFFLINE  

OLD CS1

    Technomancer

  • 5,511 posts
  • Technology Samurai
  • Location:Tallahassee, FL

Posted Sun Jul 1, 2018 11:59 AM

That's a very tedious labor of love, Tursi. Thanks for sharing it with everyone!

Sent from my moto g(6) using Tapatalk

 

Once again, more evidence that "love" and "insanity" are very closely related ;)



#6 philipj OFFLINE  

philipj

    Moonsweeper

  • 495 posts
  • Location:Birmingham, Alabama

Posted Sun Jul 1, 2018 12:06 PM

I found a TI-99/4a at a local thrift store still in the box for $32 a few month back, it was in good shape, I hated to walk away from it so now I'm a TI owner... Been doing online research on it ever since... This will be very helpful; thanks Tursi.



#7 Tursi OFFLINE  

Tursi

    Quadrunner

  • Topic Starter
  • 5,243 posts
  • HarmlessLion
  • Location:BUR

Posted Sun Jul 1, 2018 12:28 PM

Wow! Thanks for capturing all that... That is going in the study guide. :)  
 
So, if I understand what you documented correctly, 'Clock' in the diagrams is the PH1 input on the 9900?


Sorry about that, yes. I changed my clock measurement a lot of times to try and make the signals line up better, and when I finally settled I forgot to update the docs. I've fixed that.

... it might actually be PHI2. I went back and forth a number of times... I guess to that end don't put too much stock into the exact phase -- I was after counts. (It's definitely not 3 or 4.) It's all disconnected now and since I didn't update the docs, that makes me doubt this morning.

#8 FarmerPotato OFFLINE  

FarmerPotato

    Chopper Commander

  • 110 posts
  • Location:Austin, TX

Posted Mon Jul 2, 2018 10:33 AM

Thanks for verifying these timings. I was especially interested in what you observed for the sound chip.

 

One detail some might want elaborated: When the sound chip SN76489 takes READY low for 32 of its cycles, those are counted at 3.579MHz, or the equivalent of 26.76 cpu cycles at 3 MHz.

 

Tursi recorded 27 cycles, and I guess sometimes plus one?



#9 Tursi OFFLINE  

Tursi

    Quadrunner

  • Topic Starter
  • 5,243 posts
  • HarmlessLion
  • Location:BUR

Posted Mon Jul 2, 2018 5:39 PM

One detail some might want elaborated: When the sound chip SN76489 takes READY low for 32 of its cycles, those are counted at 3.579MHz, or the equivalent of 26.76 cpu cycles at 3 MHz.
Tursi recorded 27 cycles, and I guess sometimes plus one?


Ahhh.. that's where the difference came from. Forgot about the clock rate there to the sound chip.

The CPU can't have half of a cycle of HOLD, so I'd expect the 26.76 to usually round up. I can see it sometimes missing the hold point and maybe making 26 cycles, but I don't think 28?

Many signals don't line up nicely with the clock, and worse is that the CPU clock and the VDP-derived clocks are completely unsynchronized. This sometimes made counting tricky and so I looked at a number of cycles to see how consistent it was.

I didn't worry about a single CPU cycle difference overall, since the potential CPU clock speed between two different consoles is greater than the slip of one cycle in 30. (The datasheet allows a tolerance of +/-5% on the clock, and I've measured consoles at both extremes. Conversely the VDP clock, which generates the sound and GROM clocks, has a much tighter tolerance in order to generate video correctly.)

I suppose this technically means that for access to the sound chip and GROMs, you might see differences of +/-5% depending on the console. The console I tested on was measured very close to 3MHz (IIRC it was showing around 3,000,100 Hz. I only remember because I was surprised how close it was.)

All told, though, it is one person's measurements of one system. It's not fact unless someone reproduces it. ;)




0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users