EJTAG parallel flash programming utility
Copyright (c) 2005-2006, Dmitry Pankratov <dmitry@pankratov.net>
All rights reserved.

GiveIO driver Copyright (c) by Dale Roberts
 
------------------------------------------------------------------------
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
   notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
   notice, this list of conditions and the following disclaimer in the
   documentation and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products
   derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
------------------------------------------------------------------------

SYNOPSIS
	EJFlasher is a flash programming utility that works with MIPS-based targets and allows
	to program flash memory	chip using EJTAG interface and a special download cable.
	Currently the NEC UPD611xx CPUs are supported.

	System requirements:
		- Windows 9x/NT/2K/XP/2003
		- GiveIO system driver installed for NT-based systems (included in the package)
		- PC parallel port
		- Download cable compatible with ByteBlaster II. One could be purchased or soldered using public
		  schematic downloadable from www.altera.com

BRIEF USAGE NOTES
	Before starting EJFlasher make sure the giveio.sys driver is installed using supplied script.
	Set the correct flash base address (typically 0x1FC00000) and port number (0x378).
	Press "Detect Device" button to run communication and device tests.
	Select the appropriate command from the list of commands:
	- "Read To File" to read the specified region of the flash memory or RAM to the file.
	  To read RAM block, set base address to 0 and start address to the required value.
	- "Program Flash" to write the file to the flash memory started from the specified address.
	- "Erase Flash" to erase the specified region of the flash memory.
	Press the "Start" button to run the selected command.
	The following flash chips are supported: AMD- and Intel- compatible.
	
	Although this utility allows reading/writing of any region of the flash memory,
	it is recommended to use it only to recover the primary boot loader and to use the documented
	communication protocols for further downloading (for example, through serial connection).

TROUBLESHOOTING COMMON PROBLEMS
	- If cable detection fails, check the parallel port number in the BIOS settings. Set it to ECP mode.
	  Check the electrical cable pinout according to the ByteBlaster spec.
	  To ignore cable detection errors and continue anyway, check the 'Ignore cable errors' checkbox.
	- If the target device cannot be initialized, make sure it is plugged into the power source and the cable
	  is connected to the device in the right way.
	- If no flash is detected, try the different flash base address. If it still does not work, please send
	  the complete debug-level log file to the author.
	
CONTACT
	For any questions, bug reports and suggestions please use the following e-mail:
	Dmitry Pankratov <dmitry@pankratov.net>
	
CHANGELOG
    1.0 beta 8
    	- added possibility of reading any target address, not only flash memory
    	- fixed startup problems with Win9x
    1.0 beta 7
    	- minor interface fixes
    	- reduced the executable file size
    	- compiled with the native Unicode support (to resolve some file name issues)
    	- added giveio installer
    1.0 beta 6
    	- added basic support for UPD61110/12 processors
    	- fixed a bug with some AMD-compatible flashes that do not accept 0xFF CFI_CMD_READ_ARRAY1 command
    	- fixed a bug with file dialogs under Win9x
    	- fixed a bug with source files bigger than the flash size
    	- fixed a bug with non-ANSI file names
    	- added possibility of flash erasing
    	- changed the dialog controls layout
    1.0 beta 5
    	- no user-visible changes; internal optimizations & code rearrangement
    	- some minor GUI adjustments
    1.0 beta 4
        - added target CPU detection
    	- added support for 61115-based devices
    	- added automatic renaming of destination file if it already exists
	1.0 beta 3
		- fixed Intel detection bug where device id was always 0
	1.0 beta 2
		- added transfer speed logging
	1.0 beta 1
		- initial release
