NAME
       nc100d - an Amstrad NC100/NC200 emulator for DOS


SYNOPSIS
       nc100d [-2hmp] [-r rate] [file_to_boot.bin]


DESCRIPTION

       nc100d is an Amstrad NC100 and NC200 emulator for MS-DOS. It
       supports both the ROM software and ZCN, my free CP/M-like OS.
       ZCN is available from http://rus.members.beeb.net/zcn.html or
       ftp://ftp.ibiblio.org/pub/packages/zcn/.

       (If you're new to nc100d and wondering how to get it going, see
       the SETTING UP NC100D section below.)


OPTIONS

       -2     emulate an NC200 rather than an NC100.

       -h     gives help on command line options.

       -m     modify `colour' key messages in (real) ROM (no effect
              when using the builtin ROM), to make them more
              understandable when using nc100d. For example, "YELLOW
              & RED" is changed to "INSERT & LEFT". This doesn't yet
              work when emulating an NC200.

       -p     use the builtin PD ROM even if nc100.rom is present. Can
              be useful when booting a file. This ROM doesn't yet
              support the NC200, and will probably lead to a crash of
              the emulated machine if enabled when using `-2'.

       -r     specifies how often the screen is redrawn, measured in
              (10ms) interrupts. A value of 2 would redraw every 20ms
              (50 times per second), 4 would redraw every 40ms, etc.
              The default value is 5, and the lowest allowed 2.

       file_to_boot.bin
              specifies a file to be loaded into memory  at  100h
              and  booted.  This  only  works if you're using the
              builtin PD ROM (you get an error message if not).


THE EMULATED NC100

       Most aspects of the NC100 are emulated, including context-
       saving, memory cards, and the parallel (printer) port. The only
       real omissions are sound support (no big deal, it's only ever
       used for beeps :-)), and serial I/O support.

       You'll probably want to disable  auto-power-off,  as  this
       isn't really what you want when running an emulator. :-)

       The emulated NC100 runs at 4.606MHz, and only uses as much CPU
       time as it needs to do this. If it can't run in real-time
       (likely on 486s, for example), then it slows down interrupts to
       match so that the emulated NC100 won't be affected. (However,
       the real-time clock always reports real time, so clock programs
       may act oddly at slow speeds.)

       The parallel (printer) port is emulated in a quite
       straightforward fashion. If the NC100 outputs anything to the
       printer, this output is appended (verbatim) to the file
       printout.dat (see the FILES section), which is created if it
       doesn't already exist. Note that if you're printing from the
       ROM software's word processor and have the `Simple' printer
       type selected, printout is sometimes preceded by a NUL (zero)
       byte. But this doesn't seem to be a bug in nc100d - that NUL
       really is being sent to the printer! So watch out for that when
       treating the output as a plain text file.


NC200 SUPPORT

       As with the NC100, the memory card and parallel port are
       supported (and in the same way). The clock chip emulation is a
       little simplistic, but it seems to work fine with the ROM
       software. The main omissions are support for the disk drive,
       and for the backlight. :-)


SETTING UP NC100D

       This section covers setting up for NC100 emulation; for NC200
       details, see NC200 SETUP.

       The first thing to do is run `makememc' to make a 1024k memory
       card image. You don't have to do this, but the NC is generally
       a lot nicer to use with a memory card. Besides which, you need
       one to run ZCN. ;-)

       Having got that out of the way, there are three main ways to
       use nc100d - using ZCN with the builtin PD ROM, using ZCN with
       the Amstrad ROM, or using the ROM software with the Amstrad
       ROM.

   ZCN with the builtin ROM

       Just run it with (e.g.) `nc100d zcn.bin', where zcn.bin is from
       the bin directory in the ZCN distribution. (Note that zcn.bin
       is read as a normal file from the current DOS drive/directory,
       not from the memory card image!) This boots ZCN. If you use F10
       to exit (which saves context), you shouldn't need to run it
       with `zcn.bin' specified again unless you want to cold-boot.

       Once you've booted ZCN for the first time, go through
       doc/zcn.txt in the ZCN distribution. You'll probably want to
       skip most of the installation stuff. `Installation epilogue' is
       a good place to stop skipping. For reference, your `memory
       card' is 1024k, and you'll want to format drives a:, b:, c: and
       d:.

       To transfer files to/from the memory card image, use
       `zcntools'. See zcntools.txt for details. If you're running in
       a multi-tasking environment like Windows, you should be sure
       to exit any running nc100d before using zcntools.

       Note that anything in ZCN which requires the Amstrad ROM is
       bound to have problems with the builtin ROM (see below).

   ZCN with the Amstrad ROM

       There are some limited benefits to running ZCN with the real
       ROM - if you want bbcbas, bbcmin, calc, runrom, spell, or
       spellwd to work, you must use the real ROM. Most of them will
       crash horribly without it.

       Just make sure you stick with one ROM or the other - the
       context-saving works slightly differently with each. If you
       really want to switch ROMs, then (for a builtin to Amstrad ROM
       switch) delete nc100.ram (usually in c:\nc100d), or (for an
       Amstrad to builtin ROM switch) cold-boot as described above.

       As for how to set it up, things are rather more complicated
       than with the builtin ROM, but here's a guide:

       First, boot ZCN with (e.g.) `nc100d -p zcn.bin'. Then make the
       memory card bootable with `sys a:'. Now quit the emulator,
       remove any nc100.ram (since we're about to switch ROMs), and
       make sure that the nc100.rom you transferred with romdump (if
       you haven't done that yet, do it now :-)) is in the right
       drive/directory, usually c:\nc100d.

       Now do plain `nc100d' (i.e. no args); you should get the ROM
       software's main menu screen. Do `Function-X' (by doing
       Insert-X, using Insert like a shift key), which should finally
       boot ZCN. Quit with F10, and that should save context so you
       won't have to do the `Function-X' next time.

       Yep, sure is easy when you know how (cough, splutter). :-)

   ROM software with the Amstrad ROM

       This is easy enough - just get the 256k of ROM across from your
       NC100 with romdump (this takes a while...) as
       c:\nc100d\nc100.rom, then run nc100d. The only problem is,
       there's no direct way to transfer files to/from the ROM
       software. (You could print files to get them out, which does
       work, but isn't that great and only transfers files one way.)

       If you're prepared to run ZCN, at least for file transfer, you
       could use its `runrom' and `rrxfer' programs to transfer files
       to the ROM OS. This would be painfully indirect, but should
       work.


NC200 SETUP

       The only option with the NC200, for now at least, is to get a
       copy of the NC200 ROM and run that. You could do this with
       romdump - if it supported the '200, which it doesn't yet. :-)
       So I'll gloss over that, but once you have the ROM move it to
       c:\nc100d\nc200.rom, then run nc100d with the `-2' option.

       The same problem applies as with the ROM OS on the NC100 -
       transferring files to/from the machine isn't easy. The nicest
       way to do this would probably be via an emulated floppy, but I
       don't know how likely I am to implement that...


KEYS AND KEY MAPPING

       F10    quit nc100d by causing an NMI, just like pressing the
              power on/off button on a real NC100. I recommend you use
              this to exit.

       F5     does the same as F10 (for `compatibility' with previous
              versions).

       F8     quit nc100d by just stopping dead. This doesn't cause an
              NMI, and the RAM isn't saved. Useful if the emulated NC
              crashes, as in that case an NMI may not be enough to
              exit.

       Page Up
              switch to 320x200 mode, and show the leftmost
              320x64/128.

       Page Down
              the same, but show the rightmost 320x64/128.

       End    return to the normal display (640x480).

       (Page Up/Page Down/End can take a while to switch between modes,
       especially when running under Windows.)

       Those keys which also exist on the NC100 are mapped as-is,
       with other mapped keys being:

       Alt    emulated as Symbol

       Backspace
              emulated as `<-Del'

       Delete emulated as `Del->'

       `      emulated as Menu

       Esc    emulated as Stop

       Insert
              emulated as Function (it's odd, but I ran out of keys
              :-))

       No other keys are mapped. Some of the mappings probably assume
       a UK keyboard layout, I'm afraid, and some keys may be
       inaccessible on other layouts.


FILES
       The files mentioned below are assumed to be in c:\nc100d by
       default, but their location can be changed by setting the
       NC100D_HOME environment variable to the preferred path.

       c:\nc100d\nc100.rom
              this should be a copy of Amstrad's NC100 ROM. If not
              present, a builtin PD ROM is used instead; this is only
              capable of running ZCN, though.

       c:\nc100d\nc100.ram
              the NC100's RAM. This is saved when the ROM turns off
              the emulated NC100. If this is not present when the
              emulator starts up, blank RAM is used instead.

       c:\nc100d\nc100.crd
              the PCMCIA memory card image. If not present, no card is
              present in the emulated NC100. The size should be a
              multiple of 16k, and it should be no larger than 1024k.
              (You can use `makememc' to make a blank 1024k memory
              card image.)

       c:\nc100d\printout.dat
              if the emulated NC100 prints anything, it's appended to
              this file (which is created if not already present).

       c:\nc100d\nc200.*
              when running in NC200 mode, the various files which
              start with `nc100' are no longer used; instead,
              `nc200'-prefixed filenames are used, such as nc200.crd.
              These files remain in c:\nc100d, though (confusingly
              :-)).

BUGS
       None known.

SEE ALSO
       zcntools.txt, makememc.txt

       doc/zcn.txt in the ZCN distribution.

AUTHOR
       Ian Collier wrote the Z80 emulation; I lifted it from his
       `xz80' Spectrum emulator.

       Russell Marks (russell.marks@ntlworld.com) wrote the rest,
       including the NC100/NC200 emulation.
