
ATORIC 0.4
----------

(ATari shrinks to ORIC, version 0.4)
Yet another ORIC emulator for the ATARI ST/TT/Falcon computers..

ATORIC tries to emulate the good old ORIC-1 and ORIC-ATMOS computers
that were quite successful in 1983..1985 (but totally unsuccessful
 compared to the C64 - why??)



What's new in version 0.4?
--------------------------

* HIRES windowing - programs that use control chars to display HIRES graphics
  for parts of the screen work now.
* Extended display: the 6 pixel chars of ORIC text mode can be displayed
  either in 6 of the 8 pixels of the Atari screen (traditionally) or
  fill the 8 pixels (new). Switching is done with the numpad 6 and 8 keys.
* the ROM file is editable by ATORICNF.TTP . Now ATORIC could run even with
  the ORIC_ATM.ROM or ORIC1.ROM file ..

What's new in version 0.3?
--------------------------

* Overscan screen mode for Atari ST
* Monochrome monitor support for Atari ST (colors are missing, and
   not emulated by gray-shades..)
* A different way of detecting cassette interface routines - now
  done by illegal opcodes instead of observing $304/$30D actions
* some rudimentary timer support should make more games work

What's new in version 0.2?
--------------------------

* removed some bugs from the tape routines -> multiple files will
  now load
* low level keyboard emulation (without SHIFT,CTRL status), so
  keys will be recognized by many games
* some minor speed improvements (but no breakthrough!)
* For FALCON030 machines with RGB monitors, there is a overscan
  option to allow flicker-free screen display
* ORIC_CH.ROM is no longer needed..
* interrupt rate closer to 100 Hz - at least most sounds should now be
  played at original speed :-)

IMPORTANT
---------

BEFORE you'll start the emulator, please read this text to its
end! Otherwise, you probably won't have fun with ATORIC..


1.What is an ORIC?
------------------

The ORIC-1/ATMOS computers had the following hardware features:
- CPU:   1.0 MHz 6502
- RAM:   64 kByte, 48kByte usable without external hardware
- ROM:   16 kByte
- Video: 240*224 pixels at 8 colors+flash attribute
         (40 chars at 28 lines or 240*200 pixel + 3 text lines)
- AY-8912-3 or similar soundchip: 3 voices+noise
- built-in loudspeaker
- Parallel printer port (Centronics compatible)
- expansion port for disc drives etc.
- cassette recorder interface at 2400 baud
- TV modulator

Well, that's really no good description of the ORIC..
Imagine: A little box, just plug the power jack in,
         type "EXPLODE"+Return, and listen..
There is much more information available in the INTERNET,
just look out for "the oric page" or similar terms..


2. What are all those files good for?
-------------------------------------

The ATORIC package includes several files:
* ORIC.ROM
  this file is generated by YOU! You have to copy either the
  ORIC1.ROM or the ORIC_ATM.ROM to ORIC.ROM so that the emulator
  knows which ORIC it is :-)
* README.TXT
  this description
* LIESMICH.TXT
  a description in German language
* ATORICNF.TTP
  the configuration program. Use with care!!
* ORIC020.PRG and ORIC_ST.PRG
  the two versions for 68020 or better CPU and the ST (68000) version
  REALLY make sure that you use the right version!!



3. How good is ATORIC at present time?
--------------------------------------

Not very good. I wrote it because there were no other ORIC emulators
for the ATARI around, and I want to see all my earlier computers be
emulated on my Falcon030. The main problems:
* The 6502 emulator runs quite stable, but
  - speed is low: You'll need at least a TT to get about the original speed!
    Some speed measurements:
    FALCON030, 68030, 16MHz: about 40% of the ORIC speed
    ATARI ST, 68000, 8MHz: about 12% of the ORIC speed
    And, the screen emulator was set at those tests to its
    minimum of 1 ORIC text line/VBL, means about 2 full pictures
    per second.
    The 6502 emulator is not as fast as the legendary C64 emulator
    of Dr. Uwe Seimet, but it runs on 68020 and better CPUs..
    It is REALLY not easy to program a fast 6502 emulator on the 68k
    because of the totally different concept of the CPUs - so I decided
    to write a slow one :-)
    There are certainly bugs left especially in the BCD emulation but
    who cares about BCD mode..
* The screen emulator displays colors and attributes, but
  - speed is awful low: Only 3.6% or 7% of the ORIC screen are
    converted during a 1/50 sec vertical blank interrupt on a ST;
    so changes are displayed somewhat delayed..
  - for the Atari ST, only the LOW-REZ resolution (320*200) is supported;
    the awful flickering of every seventh pixel line shows that these
    lines have to display the contents of two ORIC pixel lines..
    The TT and Falcon can be used in their VGA-LOW mode (320*256) without
    that flickering.
  - no mixed HIRES and TEXT display are allowed. The BASIC commands HIRES
    and TEXT work, but not the ESCape codes for "windowing" HIRES lines..
* CLOAD and CSAVE work with the ROMs supplied (write on disc, of course),
  so you can save (PLEASE USE A FILENAME!!) and load
  ORIC files in the "standard ORIC tape format"; but
  - no disc station emulation is done up to now (I don't have such
     an expensive thing and absolutely don't know how it works)
  - some programs (not many) use their own LOAD and SAVE routines - 
    there will very probably be some problems.
* direct hardware access can lead to VERY STRANGE reactions of the
  emulator - it tries to supply the ROM routines only. So, if you have
  problems with joystick access etc., tell me - I'll try to improve
  ATORIC in that direction. 
* the keyboard is not fully supported via the hardware access - keys are
  directly written into the $2DF variable (and there is a low level 
  emulation but without special keys (no SHIFT, no CTRL, no FCT)).

Well, what works?
* BASIC programming.
* many machine programs - e.g. the ROMs are NOT patched, the only patches 
  are done at hardware accesses or in the 0..$500 memory region.
  An exception is the cassette interface - there are two patches
  for CLOAD and CSAVE; so, if there is an unknown ROM version,
  ATORIC will complain..
* graphics
* sound
* printing (there are some extra chars due to CLOAD/CSAVE hardware
   accesses - but I usually print to a file, so I can delete these
   chars easily)
* load and save programs
* even some games. ORICINVD e.g. really works (but is totally unplayable
   on my standard Falcon030 - too slow screen refresh!)

4. Getting started
------------------

First, make sure what CPU is in your Atari:
* ST, STe, MEGA ST, MEGA STe and similar machines usually contain
  the 68000 CPU. If there is an enhanced CPU inside, you'll certainly
  know about that :-)
* The 68010 CPU could cause some problems; try to use the 68020 version
  of ATORIC..
* The PAK68/2 brings the 68020 CPU..
* TT, Falcon, PAK68/3 normally contain the 68030 CPU
* The high-end Ataris use a 68040 or 68060 CPU
* PC emulators usually simulate the 68000 CPU;
  only some JANUS boards use a 68020. But there are rumours that
  some very enthusiastic programmers will try to emulate the 68030 CPU..
* MagiCMac runs on MACs with 68030 or better; if the MAC has a PowerPC,
  a 68LC040 is emulated.

Only the Ataris or Emulators with the 68000 should run the ORIC_ST.PRG,
ALL OTHER machines have to use the ORIC020.PRG!!


Now, start the
ATORICNF.TTP program with the name of the ATORIC emulator (e.g.ORIC020.PRG)
carefully set all the parameters:
P - the printer file (e.g. ORIC.PRT, C:\TEMP\ORICPRT.TXT, PRN:)
A - a filename that is searched for at startup of ATORIC:
    It contains some BASIC commands executed at the first startup;
    so you could create your automatic ORIC..
    (e.g.: ORIC.KBD)
    this file could contain the following lines:
    PRINT FRE(0);" bytes REALLY free!"
    'WELCOME TO ATORIC
O - how many ORIC text lines should be displayed during about 1/50 second.
    This is a very critical value; for the standard ST it should be set
    to 1. Faster machines can handle higher values; if the value is too
    high, the "6502" will be extremely slow, or the ATARI crashes!
    Falcon (68030, 16MHz): 2..4, even 1 is sometimes recommended..
D - delay between 6502 instructions. This is important only for real
    power users: If the 6502 runs too fast, you can set down this
    value. Standard is 1000, that means: every 1000 instructions of
    the 6502, emulator checks are done (time-consuming!).
F - Falcon support. Set this to 1 only if you are using a FALCON030!
C - change to ST-LOW. Set this to 1 if you use your non-Falcon computer
    in ST-MID resolution and want th start ATORIC from that resolution.
U - use only standard ST resolutions. Set to 1 if you are using an
    Atari ST or STe.
    Else, if your computer supports the 320*256 VGA 16 color mode, set
    it to 0 (for a much better displayed ORIC screen!)
B - Bottom screen overscan. Works for Atari ST and Falcon (at least
    tested on my machines - in PAL and NTSC modes)
    This will avoid the problem to reduce 224 to 200 raster lines and
    so will give a flicker-free picture. Problems with most Atari-
    emulators and some monitors are quite probable..

5. What now?
------------

Currently, there are no tools for getting programs on the Atari from
real ORIC tapes. There are some tools for IBM compatibles or Lin*X
for that. Well, some tape files can be found in the ORIC archives..

I think that there could be a cheap and easy solution by connecting
ORIC and ATARI via the cassette interface of the Oric and the printer port
of the Atari.. But it will take some hours until it will work..
This will also be an easy way to get programs from disc back to your
real Oric, if you don't have a Oric disc drive like me..

Enjoy your "ORIC", have fun!


Especially for the FALCON030 owners: Connect your Falcon to a real TV,
set input and output sound level to maximum, loudspeaker to ON,
start ATORIC and type in "EXPLODE"..


Christian Peppermueller
Ebrardstr. 23
D-91054 Erlangen
Germany
e-mail: Christian.Peppermueller@rzmail.uni-erlangen.de


6. Thanks
---------

Many thanks are going to:
* Dr. Uwe Seimet who published his C64 emulator (written in 1987 for the
   Atari ST). He had an excellent idea that speeds up the 6502
  emulation considerably:
  - each of the 256 opcode emulation program is in a seperate 256 byte
    region. To emulate a 6502 opcode, simply jump to 256*opcode (+offset)!
    On 68000, this is made by patching into the jump code,
    for 68020+, a "legal" lsl.w #8,d0 is used for the "*256" operation
    (instruction caches don't like self-modifying code)
* Mr. DBug (Mike) who gave me some very good tips for improving the
  speed of the screen emulator
* Fabrice Franc`es for writing EUPHORIC, the really excellent ORIC
  emulator on the PC. Impressed by its speed, I started to program
  ATORIC - and got the slowest ORIC ever seen :-(
* The various people who created the amazing ORIC PAGES on the WWW
* Alexios Chouchoulas for his help to get ATORIC on the net (via his
   great FTP server!)
* Steffen Scharfe for his article in ST Computer 4/1992 (ST overscan)


A very short listing of some interesting ORIC internet resources:

WWW:
----
http://www.ensica.fr/oric/oric_english.html
http://www.ensica.fr/~frances/                                   # ORIC pages and EUPHORIC
http://ourworld.compuserve.com/homepages/laurentch/internet.htm  # a good link page
http://wwwperso.hol.fr/~mpointie/                                # DBug of NeXT - cool!

ftp:
----
ftp://ftp.tardis.ed.ac.uk/users/alexios/Oric   # the great ftp server of Alexios


