Z81    - a ZX81 emulator for VGA PCs running Linux
xz81   - a ZX81 emulator for X
Z81txt - a text-mode ZX81 emulator for the Linux console

Z80 emulation from `xz80', copyright (C) 1994 Ian Collier.
ZX81 support and VGA/X/text front-ends (C) 1995-1997 Russell Marks.


This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or (at
your option) any later version.

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.


`zx81.rom' is a copy of the ZX81's 8K ROM and is (C) 1981 Amstrad plc.
It is used and reproduced with permission.


Roadmap
-------

The COPYING file contains a copy of the GPL described above.

ChangeLog describes differences between all versions.


Description
-----------

`z81' is a Sinclair ZX81 (also known as the Timex TS1000) emulator. It
uses svgalib. It supports most programs and games, with the big
exceptions being games using interrupt handlers. It supports the
pseudo-hi-res mode. It saves and loads programs in Xtender's .P
format, but should be able to load the Atari emulator's .81 format
files. (It works on the ones I've tried, but I haven't tried many.)

`xz81' is a version of `z81' for X. A few fairly trivial features are
missing (like the help screen), but aside from that it's all there.
This version should work on non-Linux systems, though it needs some
features like setitimer() and sigaction() which will presumably be
absent on some machines/OSes. xz81 is only known to work on 1-bit and
8-bit displays, and very probably won't work on others. But overall,
if xz80 works, xz81 probably will. Sorry about the name, which is
easily confused with `xz80', but given the original being called Z81,
I couldn't do too much about this.

`z81txt' is a text-mode version. It still requires raw keyboard mode
and writes to the screen `directly' using /dev/vcsa0, so it will only
run on a Linux console. But, it'll run on all Linux PCs - those with
MDA/Herc/CGA/EGA display cards, as well as VGA ones, though obviously
z81 is preferable if you have VGA. :-) (This is installed setuid root,
as non-root users usually can't write to /dev/vcsa0. Don't worry about
this unduly - it throws away root privs straight after the open(),
which is the first thing it does. Think of it as working like a
text-mode svgalib (if that makes sense).) You probably need Linux 1.2
or better for z81txt to work. If you don't have /dev/vcsa0 for
whatever reason, do `mknod /dev/vcsa0 c 7 128' as root to create it.


Installation
------------

Check/edit the Makefile first - if you're compiling the X version, you
may need to change XROOT, for example.

Then, on non-Linux systems, or if you only want the X version, do
`make xz81;make install'. That should compile/install only the X
version.

If you have a Linux box with VGA, do (as root) `make;make install'.
That should compile all the versions, and install them in
/usr/local/bin. (If you don't have X, substitute `make z81 z81txt' for
the first `make'.)

If you have a Linux box without VGA, do (again as root) `make
z81txt;make install'. This avoids the need to have X or svgalib on
your system, and only compiles and installs z81txt. However, if you
use X (I know there's a server that supports Herc cards, for example),
xz81 is *much* better. You may want to compile that instead.

If you compile z81 or z81txt you'll need my rawkey library - a
precompiled ELF copy is included here.

`z80.c' will take a while to compile (two minutes on my dx2-66). Don't
worry about this, it's simply because of the mind-bending (and fast)
way IMC's Z80 emulator works.

Be sure to read the man page. Z81 is a quick hack, so you'd better
know all about the gotchas before running it. :-)


About `tetris.p', `tetrishr.p' and `tetris1k.p'
-----------------------------------------------

A while back I wrote a few tetris clones, one boring ordinary one, one
`hi-res' one, and a 1k version. I've bundled them with Z81 - give 'em
a go, and see what you think. See `tetris.txt' for details.
`tetrishr.p' is probably a good way of testing if an emulator supports
the pseudo-hi-res mode. (It even has a little screen that tells you if
it's not working. :-))

They're public domain, so you can do whatever you want with them. I'd
appreciate it if you could distribute `tetris.txt' along with them,
though. Source is in `tetris-src.tar.gz'.

And before anybody asks, yes, tetrishr REALLY DOES work on a real
ZX81! Honest!

Some ZX81-related utils are included in tetris-src.tar.gz - these are
zx81send, which transfers a .P file to a real ZX81; and bin2p, which
converts a binary m/c program into a self-running .P file.


About `zx81sml.gif' and `zx81big.gif'
-------------------------------------

These are higher-res versions of `zx81kybd.pgm' used as the help
screen in Z81. `zx81sml.gif' is at about 640x480 resolution, and
`zx81big.gif' is 1-bit mono but very large - about 4000x2000. The
latter should be suitable for printing; it's probably easier to
consult a printed version than an on-screen one. The original Corel
Draw file I drew (from which these are derived), `zx81.cdr', is also
included here (gzipped). All three files are public domain,
use/modify/distribute them as you wish.

[A note to those it may concern - why didn't I include a PostScript
version? Because I don't like the way PS output from CDraw has a
copyright notice embedded in it. At the very least, this means I
couldn't make the PS output public domain.]


About `xz81.xpm'
----------------

This is a slightly nicer colour version of xz81's `built-in' mono
icon. If you're using xz81 and your window manager supports loading
XPMs from files to use as icons (fvwm does, for example), then you
might want to use it instead of the default icon.

Note that it isn't installed anywhere by `make install', so you'll
have to deal with it yourself.


History etc.
------------

I decided to write a ZX81 emulator on August 27th 1995, having got a
bit tired of having to run dosemu to use Xtender, which aside from
being for DOS, and being shareware, is a good emulator. (sigh)

Thanks to the GNU GPL, I could use Ian Collier's Z80 emulator from
xz80, a ZX Spectrum emulator for X, and replace the X and Spectrum
support code with that for svgalib/rawkey and the ZX81. (I wrote
z81txt and xz81 later.) And here I am writing the README the following
evening. This is an argument for free software. :-)

I give Ian the main author credit for Z81, as the Z80 emulation is
much harder to do than emulating the ZX81's hardware and patching the
ROM for save/load etc. However, any correspondence regarding Z81
should be to me, as Ian hasn't had anything else to do with it and,
being more of a speccy fan (I think), may not appreciate being hassled
by those of the ZX81 persuasion. :-)


While I'm unlikely to do much (if any) hacking on Z81/Z81txt/xz81 in
future - I only did it/them to see if I *could*, as much as anything -
feel free to try and prod me into making it better, if you want. :-)

A better idea might be for someone else to take over development of
Z81 etc., especially as I'm no longer on the net. I wouldn't mind too
much if such a person were only interested in hacking on the X
version, as long as Z81/Z81txt were still available (separately if
need be). Anyway, if you're interested in taking over Z81, contact me.


Contacting me
-------------

No email address at the moment I'm afraid. :-(

Postal address:
		Russell Marks,
		3 Rapley Close,
		Camberley,
		Surrey,
		GU15 4ER,
		United Kingdom.

If you insist on abbreviating my name, please use "R. J. Marks".


Share and enjoy! 

-Rus.
