
		    SG.EXE -- The "Sounds Good" Emulator
		 (C) 1997 Michael Cuddy, Fen's Ende Software
		 -------------------------------------------

	      This emulator has been voluntarily rated TV/MA ;-)
			
			
    What is this?
    -------------

	It's an audio-only emulator for the Bally/Midway "Sounds Good" (SG)
	and "Cheap Squeak Deluxe" (CSD) boards.
	
	The "Sounds Good" board was first used in "Rampage" and later 
	used in games like "Xenophobe".  I've been told that it is
	not used in "Arch Rivals" and "Pigskin". There may be other games
	it _was_ used in, but I don't know of any.  If you know, 
	PLEASE contact me!
	
	Currently, this emulator supports the following versions of the
	CSD/SG boards:
	
		* SpyHunter's CSD -- plays the in-game music
		* Rampage SG -- plays all sfx
		* Xenophobe SG -- plays all sfx
		
	I wrote this emulator to have an easy platform to debug verify 
	the CPU core and the functionality of the audio board before
	I integrate this code into my KEM -- The Killer Emulator 
	(http://www.fensende.com/kem), which currently emulates about 20 
	different Bally/Midway MCR games as well as a few others.
	
    So, what do I do with it?
    -------------------------

	First: make sure that you have a copy of DOS4GW.EXE in a 
	directory in your %PATH%, or in the same directory as SG.EXE.
	
	NOTE:
	    If you do not have a copy of DOS4GW.EXE, you can download 
	    it from my KEM page, and from many other sites on the 
	    net.  It is a freely re-distributable runtime package 
	    for extending DOS to 32 bits.
	
	Next: get the roms for one or more of the supported games.
	The roms should be named thusly:
	    
	    Spy Hunter: (4 x 8KB roms)
		CSD_U17B.U17, CSD_U18D.U18, CSD_U7A.U7, CSD_U8C.U8
	    
	    Rampage: (4 x 32KB roms)
		RAMP_U17.SND, RAMP_U18.SND, RAMP_U7.SND, RAMP_U8.SND
		
	    Xenophobe: (4 x 64K roms)
		XENO_SND.U17, XENO_SND.U18, XENO_SND.U7, XENO_SND.U8
	
	*(*(*(*(*(*(*(*(*(*(*(*(*(*(*(*( )*)*)*)*)*)*)*)*)*)*)*)*)*)*)*)*
	I WILL NOT GIVE OUT THESE ROMS, I WILL NOT GIVE POINTERS TO THE
	ROMS: THE ROMS REMAIN THE ORIGINAL AUTHOR'S COPYRIGHT.  THEY
	CONTAIN COPRIGHTED SOFTWARE, AND USING THEM WITH THIS EMULATOR
	MAY CONSTITUTE A COPYRIGHT VIOLATION.
	
	IF YOU SEND ME E-MAIL ASKING FOR ROMS, OR WHERE ROMS CAN BE 
	DOWLOADED FROM THE NET, I WILL SILENTLY FILE YOUR E-MAIL IN 
	THE BIT-BUCKET.
	*(*(*(*(*(*(*(*(*(*(*(*(*(*(*(*( )*)*)*)*)*)*)*)*)*)*)*)*)*)*)*)*
	
	There, with that out of the way, and the roms in the same 
	directory as SG.EXE, launch the emulator:
	
	    Rampage:
		C:\SGEMU> SG.EXE r
	
	    Xenophobe:
		C:\SGEMU> SG.EXE x
	
	    Spy Hunter:
		C:\SGEMU> SG.EXE s
		
	If everything is in order, you'll get a prompt asking you to 
	press any key.  If you do not get the press any key prompt, 
	something is wrong with your rom images.
	
	There are two options that you can specify to the emulator:
	
		-s <sample_rate>
	
	This option changes the rate at which data is sent to the 
	audio card.  The higher the sample rate, the higher the
	pitch of the audio output from the emulator.  Each of the
	boards is currently calibrated to an approxiate value;
	if you have access to a real machine and want to play 
	around with this value to adjust the pitch to be correct,
	Please let me know what value works best.
	
		-u <update_rate>
		
	This controls how often the 68000 emulator is called upon
	to fill up a buffer full of audio data.  the lower this 
	number, the more work the 68000 has to do at one shot, but
	the more efficient it can be at getting it's work done.
	Lowering this number past 20 is not advised, since it can
	take a long time for commands to respond when it's that 
	low.  However, if you are getting a high error count, (E= on 
	the display) lowering this value this can help lower the
	error count.
	
	Lowering this number also makes the osciliscope display 
	less pretty.
	
    Now that it's running how to I make it SING!
    --------------------------------------------
	
	In a real machine, each of these boards is connected to the
	main game cpu by an I/O port by which the main CPU can send
	numeric commands to the board.  Rampage, for example supports
	quite a few different commands, but SpyHunter only supports 4.
	
	To simulate sending these commands to the SG or CSD board,
	you type a HEXIDECIMAL number on the keyboard and press enter.
	
	You can also type 'n' or 'p' to increment or decrement the 
	command number.
	
	The screen will tell you which command numbers are valid for
	each board.
	
        Usually, pressing the space bar will shut off all sound from the 
	board.
	
	If that doesn't work, try pressing 'z' to reset the board.
	
	Follow the on-screen prompts for other things to do with the 
	emulator (Whee!).
	
	The numbers on the left indicate some internal status of the
	emulator: the "T=" is the number of ticks (approximately 60 / sec)
	and the "E=" is the error count; this inidicates the number of times
	that the 68000 emulation was not able to fill up the soundblaster's
	DMA buffer before the soundblaster needed more information.
	This number will start out at 2 - 3 because of startup overhead, 
	but if the error count keeps going up, it means that your machine
	is not powerful enough to run the emulation.  Sorry; the 68000
	is a mean machine, and SSK (the 68000 kernel used in SG.EXE) is 
	a bitchin' fast emulator .... but there's only so much we can do ;-)
	
	"Oh, my God ... they've killed Kenny! ... You BASTARDS!"
	
	To get out of the emulator, press ESC.
	
    Thanks:
    -------
    
    	Special Thanks to:  
	
	* Neill Corlett (Two "L"'s, Two "T"s ...) for the 
	    STARSCREAM/K 68000 core used in this emulator; 
	    it's one of the fastest (if not _the_ fastest) 
	    68000 emulators out there. 
	    
	* Neil Bradley (One "L", No "T"'s, "E" before "I" ;-): 
	   For help with some stupid ASM questions.
	   
	* Kurt Mahan for loaning me his Rampage schematics
	
        * The emulation community for supporting KEM ...
	
    Contacting The Author
    ---------------------
    
	You want me? You got me:  
		
		E-Mail:	 mcuddy@FensEnde.com
		WEB:     http://www.fensende.com/Users/mcuddy
		KEM:     http://www.fensende.com/kem/
		IRC:	 Pryankstr on #EFNet; I hang out in 
		   	 #mamegames and #emu
			 
		SnailMail:
			 Michael Cuddy
			 166 Warwick St.
			 Redwood City, CA, 94062
			 
    Revision History
    ----------------
    
    09/23/1997 -- Version 0.1 -- First Release
    		First public release; kick the tires, kiddies.
		
    09/24/1997 -- Version 0.2 -- Second Release
		    * Spy Hunter works fully now.
		    * Added -u and -s switches.
		    * Added idle display and report
		
    Notes
    -----
    
    	RAMPAGE:
		sounds 00 - 10 are "utility commands"; they are for turning
		off other commands (the looping ones), and used for 
		diagnostics.
		
		Rampage supports up to 2 commands playing at the same time,
		but uses it's own twisted internal logic to decide which 
		commands have precidence over which other commands.
		
		If the emulator seems to hang (i.e.: won't accept commands)
		you'll have to reset the emulator ('z').
		
	XENOPHOBE:
		There are a few commands which will loop forever.  I assume
		that it's a CPU emulator bug that doesn't let them finish.
		Just reset the emulator (z) if this happens.
		
	SPY HUNTER:
		has a limited palette of commands; they are:
			00 = play the "death theme"
			01 = start the main theme
			02 = play the first bit of the main theme, once.
			03 = stop all output.
	OTHER:
	    Watch "South Park" on Comedy Central!
