
                               Got A TT?

                                   **

         Got Microprose Formula 1 Grand Prix or other ST Game?

                                  ****

                  Can't get the two to work together?

                                   **

  Then this program is for you! TTGAMES is a program which allows SOME 
ST only games to work on a TT. The only game I know this works for sure 
with is Microprose F1 Grand Prix - the speed of this on a TT is amazing.

  This program is PUBLIC DOMAIN. This means that you can distribute the 
program freely provided you include this document unaltered with every 
copy.

  The author makes no warranties of any kind with respect to this 
document or the TTGAMES program. USE IT AT ENTIRELY YOUR OWN RISK!!

          Developed by:  Jon Marshall
                         28 Holbrook Road
                         Stratford
                         London E15 3EA

          TT & F1 GP provided by: Steven Elkins

Operating instructions
~~~~~~~~~~~~~~~~~~~~~~
  1) Format a blank disk. The number of sides and sectors per track does 
not matter (only the boot sector is used).

  2) Run TTGAMES. Insert the blank disk - NOT A GAME DISK - in drive A 
or B and select the appropriate button. TTGAMES will now write a special 
bootsector on the disk, you have no need to run TTGAMES again.

  3) Place the disk in Drive A and reboot. You will see a screen with 
the following options:

          1: Alter PMASK registers?
          2: 68030 cache on?
          3: Alter new stack pointers?

  which default to YES, NO and YES respectively. The meaning of these 
options are explained later for the sadists among you. The options can 
be toggled by pressing 1, 2 or 3. Press SPACE when finished.

  4) Insert your game disk and press a key.


  The default setup should is about the most STish I can make your TT. 
If this setup does not work with your game then the chances are that you 
will never get the game to work.

  NOTE 1: There is no guarantee that TTGAMES will make an ST game work 
on your TT. In fact the odds are against it. Do NOT by a game on the off 
chance that this program might work - you will probably end up 25 quid 
out of pocket!

  NOTE 2: This program only works with games that boot from the 
bootsector, which is about 98% of current commercial games available for 
the ST.

Extra Speed in F1 Grand Prix
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  TT users will be aware the their machine has a built in cache to speed 
up processing. Some ST orientated software is incompatible with the 
cache because of this extra speed. In particular with F1 Grand Prix, the 
machine will not wait long enough for a disk to start rotating at the 
correct speed before reading information from the disk - this leads to 
garbage being read in.

  There is however a solution for owners of 2 disk drives! The TT will 
always ask both its internal and external drives to spin together. F1 GP 
will always check the internal drive for information before the 
external. In the time when F1 GP is requesting information from drive A, 
drive B will have reached its correct speed. To get the cache to work 
with F1 GP, and therefore blister around Silverstone at an unbelievable 
speed, follow these steps;

     1) Ensure that your external drive is connected.
     2) Insert the disk with your TTGAMES bootsector on in your internal 
drive and reboot.
     3) Press '2' to turn the cache on, followed by SPACE.
     4) Insert F1 GP disk 2 in drive A and press a key.
     5) Whenever F1 GP asks for a disk, ensure it is in DRIVE B.

  NOTE: I do not think you will be able to save games from F1 GP when 
using this technique.

Explanation of what TTGAMES does
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  There are quite a number of reasons why ST Games are incompatible with 
TT machines. A few of the reasons, and what TTGAMES can do to try and 
solve the problems are listed below;

     Write to protected memory: The 68030 CPU is designed to allow 
multi-tasking. It is essential in a multi-tasking system that if one task 
(program) crashes any other tasks, including the operating system, do 
not crash as a consequence. One way to prevent this is to stop programs 
from writing to areas where other programs or vital data are kept. Most 
games like to take over the entire memory which the 68030 is instructed 
not to allow. This results in a the game crashing.
          Solution: TTGAMES can clear protected memory registers. (Option 
1)

     Self modifying code: The 68030 can keep sections of a program on 
the chip in a cache. If however if a program modifies itself, which 
games tend to do to try and prevent hacking, then the memory onboard the 
cache becomes invalid - but the 68030 doesn't realise this and so tries 
to execute invalid code.
          Solution: Turn the cache off. (Option 2)

     DMA Access timings: The STs and TTs are connected to a number of 
devices which run at a slower speed than the CPU. Programs which access 
these devices (such as the hard and floppy disks) tend to put small 
loops in their code to slow the processor down a bit. While the loops 
are fine on an 8MHz ST, on a 32MHz TT they don't slow the processor 
enough so silly things start happening - like trying to read from a 
floppy disk before the disk is spinning at the correct speed, etc.
          Solution: None for 99.999% of games, use Drive B on F1 GP.

     Disk copy-protection: Disk copy-protections tend to be very 
machine-dependant. If you change the machine the protection thinks 
you're trying to run a copy. 
          Solution: None.

     RTE instructions: On a 68000 it is possible to put your processor 
into a known state by putting information on stack and performing an 
RTE. On a 68000 this requires 6 bytes of information but on a 68030 this 
can require more than 20. If the code uses this method then the 68030 
will remove more information from the stack than is expected, thus 
causing the game to belly-up.
          Solution: None.

     New stacks: There are a few new stack pointers on the 68030. I am 
not sure if they can cause any incompatibilities but TTGAMES can move 
these stacks to a safe place in memory (Option 3).


Note to software developers!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  The dreaded PC range has an enourmous selection of processors, 
coprocessors, operating speeds and machine timings -  yet games on the 
PC manage to run accross the majority of the range.

  With the TT selling in the dozens, Mega STEs available every other 
Wednesday, increasing numbers of hardware accelerator cards being sold 
and the much rumoured Atari Falcon rumoured to have a rumoured 16MHz 
68030 processor installed it is vital that you, yes YOU the ST software 
developer, start writing code that is a little more portable.

  It would have taken Microprose not more than a dozen instructions and 
5 minutes to make F1 GP TT compatible and they probably would have earnt 
a bit of extra dosh from it. Let that be a lesson to you!


Jon M, 5th August 1992.
