		       ApplePC v2.52
		     by David Ellsworth
	(based on Randy Spurlock's Apl2Emu version 1)


This documentation file is under construction. If there is something
you think is missing and should be added, please tell me.


New versions of ApplePC be found in the primary site:

ftp://users.aol.com/davidells/ApplePC/


The site for ApplePC used to be:

ftp://robot.asimov.net/pub/apple_II/emulators/applepc/


If you would like to be added to a mailing list for new versions,
please email me.


Send questions/comments/suggestions/bug reports to:

David Ellsworth
davidells@aol.com


Minimum Requirements

	80386 processor
	VGA card
	330K of free RAM


Keys during Apple execution

     Ins/L.Alt	Button 1 (Open Apple)
     Del/R.Alt	Button 2 (Closed Apple)

	F3	Toggle color blurring
	F4	Toggle green monochrome
	F5	Toggle two-page view (not available in green monochrome mode)
	F7	Toggle delay/turbo mode (preserves delay value)
	F8	Toggle cycle counting
	F9	Enter debugger
	F10	Enter control panel
   Ctrl-Break	Ctrl-Reset
	Pad-	Increase speed
	Pad+	Decrease speed

	The cursor keys on the numeric keypad control the joystick
	in Keyboard Mode. The normal cursor keys also control the
	joystick if NumLock is on. Otherwise, they function as the
	Apple's cursor keys.


Keys in debugger

	Esc	Exit debugger
	R	Display registers
	Ctrl-R	Edit registers
	L	Unassemble (List)
	Ctrl-L  Unassemble at a different address
	D	Dump memory
	Ctrl-D	Dump memory at a different address
	G	Single step
	Ctrl-G	Set program counter
	I	Trigger a memory read
	O	Trigger a memory write
	W or E	Edit byte(s) in memory (E=read bank, W=write bank)
		Use [space] to go to the next byte,
		[Esc] to cancel changes to the current byte,
		and [Enter] to finish the memory edit
	F9	Flip between debugger and Apple screens
	F10	Switch to control panel


Keyboard problems

	If ApplePC is run under Windows, the keyboard LED setting
	routine will not currently work. This problem may also occur
	in other multitasking environments. As a temporary fix, I
	disabled the routine. To enable it, use the command line
	parameter 'K'; e.g., start up ApplePC with the line "APPLE K".


File chooser

	To use this (for example when loading a disk image) press the
	Tab key when prompted for a file name. If you did not type
	anything, a listing of files with the default extension will
	appear. If you did type something, it will be used as a mask
	for the directory listing (for example *.NIB).

	The maximum number of files and directories that can be
	displayed at once is 1170. If there are more, the list
	will be truncated.


Extended Memory

	ApplePC emulates extended memory (above 128K) in //e and //c
	modes. Upon startup, it allocates all remaining conventional
	memory to be used as extended memory. Usually it will be
	able to allocate five auxiliary banks (320K) for a total of
	384K of RAM.

	Writing a byte to C071 or C073 sets the auxiliary memory bank.
	All subsequent accesses to auxiliary memory will be directed
	to that bank. However, accesses to auxiliary memory through
	C001 and C055 will always go to bank 00.


Disk images

	Disk images can be in either Dos Order (143360) format or
	Nibble (232960) format. ApplePC will autodetect the format
	according to the file size.

	When inputting the filename of a disk to be inserted, if an
	extension is ommitted, it will be DSK.


Hard disk images

	ApplePC emulates dual 32 Mb hard drives in slot 7. Since
	this could cause a possible conflict in //c mode, there is
	an option to disable it.

	The default extension for hard disk images is HDV.

	A hard disk will format to 32 Mb, but its image will not
	initially take up 32 Mb. It will automatically expand as
	files are copied to it.

	Since the hard drive is in slot 7, it is the default boot
	drive. If it is empty, the Apple will boot from slot 6.
	In //c mode, however, slot 7 will not boot by default. You
	will have to type PR#7 from BASIC.

	To create a hard disk image, type the following from the
	DOS prompt (replace <filename> with the name you want):

		debug <filename>.hdv
		w
		q

	What you'll actually see will look somewhat like this:

		C:\APPLEPC>debug <filename>.hdv
		File not found
		-w
		Writing 00000 bytes
		-q

		C:\APPLEPC>

	This will create a zero byte file that you can then format
	with a program such as Copy II Plus.


Apple mode

	If a program does not work in Apple //c mode, try running it
	in Apple //e mode. (Examples: Karateka and Drol).

	Also, certain programs are designed for the Apple ][+. If a
	program switches to 80 column mode but prints text with spaces
	in between each character, switch to ][+ mode (Example: Wizardry).
	Also switch to this mode if a program flips the whole screen
	back and forth one pixel in hires graphics, making it extremely
	slow (Example: PacMan).

	ApplePC defaults to //c mode. If APPLE2C.ROM is not found,
	it will try to load APPLE2E.ROM and switch to //e mode. If
	it can't find this either, it will try to load APPLE2.ROM
	and switch to ][+ mode. If ApplePC can't find any ROM files,
	it will quit.

	ApplePC works with both its own and AppleWin's APPLE2E.ROM
	and APPLE2.ROM.


Loading and Saving the State

	In ApplePC, you can save and load the exact state of the
	emulator. This is useful to instantly start a program that
	takes a long time to load. It also helps when you get stuck
	in a game -- if you die, just load the last state and
	continue!

	The state image "APPLE.IMG" will be loaded at startup if
	it exists.

	ApplePC will prompt you for a file name when you load or
	save a state. The default extension is IMG. ApplePC will
	remember the name of the last state you accessed.

	For an explanation of the image format, please read the
	companion file "IMG-FMT.DOC".


Cycle counting

	Cycle counting allows precise timing to be emulated. This
	can be used for at least two purposes: accurate Disk II
	and joystick emulation. So far, it is only used for
	accurate joystick emulation.

	Without cycle counting, you must set the joystick center
	according to the program you are using. With it, the
	joystick effectively auto-calibrates (you should leave it
	centered at 7F,7F). Some programs require cycle counting to
	work properly with the joystick. One example is Spy vs. Spy.

	Why not always emulate cycle counting, you ask? It slows
	down the emulator slightly. However, on fast computers
	this should not be a problem.


Apple mouse

	ApplePC emulates a mouse in //c mode. When the joystick is in
	"Mouse motion" mode, the mouse emulation will be temporarily
	disabled to prevent conflict.

	Here are some examples of programs that have mouse support:
	Dragon Wars, Ogre, and Blazing Paddles.


Mockingboard

	ApplePC emulates the Mockingboard through any Adlib compatible
	sound card (all Soundblaster compatibles are Adlib compatible).

	One and a half (1.5) Mockingboards are emulated, for a total of
	9 voices. The mockingboards are "perched" in slots 4 and 5. The
	one in slot 4 has 6 voices. The one in slot 5 has 3 voices. This
	is because the Adlib card has only 9 channels.

	The Mockingboard(s) are not emulated in //c mode. Again, this is
	because the Apple //c is not expandable. You will need to use
	//e mode.

	Noise is emulated, but envelopes are not yet emulated.
	Mockingboard timer interrupts always happen at 30 Hz.

	The Mockingboard plays music with a square wave, but the Adlib
	card does not support this waveform. ApplePC currently uses this
	waveform instead:

		  _      _
		 / |    / |
		/__|___/__|___



	Since I do not have access to either a real Mockingboard or
	extremely detailed information on it, the emulation is not
	100% accurate.

	So far, I have successfully tested the Mockingboard emulation in:
	* Mockingboard Master Disk
	* Ultima IV
	* Ultima V
	* SkyFox
	* Music Contruction Set
	* Adventure Construction Set


Serial IO

	Two serial ports are emulated. They are in slots 1 and 2.

	Slot 1 is redirected to STDOUT. To use this, start up with

		APPLE > filename

	  All output from slot 1 will be appended to <filename>. In
	  effect, you will be printing to a file.

	  <filename> does not have to be an actual file. It can be
	  a device; to print directly to the printer, startup with

		APPLE > PRN

	  as PRN is the printer device under DOS.

	  Note:	Input is not redirected from STDIN. Instead, dump a
		text file to the keyboard ([T] in control panel).

		ApplePC emulates a serial printer, but the output
		can be redirected to a parallel printer.

	Slot 2 can be redirected to COM1, COM2, COM3, or COM4. It
	fully emulates a Super Serial Card.


Known bugs/flaws (to be fixed)

	The serial interrupt code is buggy. Files almost never transfer
	properly (at least on my system) and it sometimes hangs or
	spontaneously reboots.

	Sometimes, attempting to load a disk image will freeze ApplePC
	with an "Abort, Retry, Ignore, Fail" message (it will not
	accept keyboard input because ApplePC redirects the keyboard
	interrupt). In specific, the errors include "Drive not ready"
	and "Sharing violation". To fix this, I will need to write
	an Int 24h handler.

	Disk II emulation is not 100% authentic.

	Apple ][+ mode is not 100% authentic. It should not have
	lowercase, and should emulate a 6502 processor (not a 65C02).

	Programs that do not work under ApplePC: (UV=unverified)
	* World Championship Karate
	(I think there are others, but I haven't listed them here yet.)


Features to be added later (this is a partial list)

	A better Tab file chooser
	Keyboard re-mapping
	A wide variety of command line parameters
	Display of more status on the right side of the screen
	A better user interface
	A much better debugger
	Use of EMS to emulate memory above 128K

	Better Mockingboard emulation
	Clock chip emulation
	UniDisk (800K) support
	Slow (rotating) disk drive mode
	Mouse support in //e mode

	Faster video mode switching
	Non-blurry color mode (as seen on RGB monitors)
	Amber monochrome
	Adjustable tint/tone/color/hue

	Anything else that is requested
