                   ------------------------------------------------------------------------------------------------
                                                GrandDog(UGRA) Device Drivers
                     Installing Guide for Windows 98/ME/2K/XP/Server 2003/Vista/XP x64/Server 2003 x64/Vista x64
                     /Windows 7 (x86/x64)/Windows server 2008 (x86/x64)/Windows 8 (x86/x64)/Windows Server 2012
                   ------------------------------------------------------------------------------------------------

                                               Copyright (C) 2012, SafeNet China Ltd.

GrandDog device dirver for Windows 98/ME/2K/XP/Server 2003/Vista/XP x64/Server 2003 x64/Vista x64 
/Windows 7 (x86/x64)/Windows server 2008 (x86/x64)/Windows 8 (x86/x64) and Windows Server 2012 should be installed 
if you proteced application with Hardware Dog is running at Windows 98/ME/2K/XP/Server 2003/Vista/XP x64/Server 2003 x64/Vista x64 
/Windows 7 (x86/x64)/Windows server 2008 (x86/x64)/Windows 8 (x86/x64) and Windows Server 2012 system.

We provide the dynamic link library "GrandDogSetup.dll". This library exports three interfaces.
These interface is "Install", "Uninstall" and "CheckVersion".

===========
FileList:
===========

  readme-eng.txt     			this document
  Doginst.exe				The program of driver's installation or uninstall
  GrandDogSetup.dll	 		The dynamic link library of driver's installation and uninstall
  Delphi<dir> 				The sample of calling GrandDogSetup.dll with Delphi
  VB<dir> 				The sample of calling GrandDogSetup.dll with Visual Basic
  VC<dir> 				The sample of calling GrandDogSetup.dll with Visual C++

GrandDogSetup.dll is a 32-bit Windows DLL, you may use it to develop your own SETUP program in
your application's SETUP process. 



If you want to install the dog's driver, you can call the function Install in the DLL.
  int PASCAL Install(int iFlag);
  Parameter:
  		1 Install USB dog driver
  		2 Install Parallel dog driver(not support in this version)
  		3 Install USB and Parallel dog driver
  Return value should be 0 if success, other return values are error codes.


If you want to uninstall the dog's driver,you can call the function Uninstall in the Dll.
  int PASCAL Uninstall(int iFlag);
  Parameter
  		1 Uninstall USB dog driver
  		2 Uninstall Parallel dog driver(not support in this version)
  		3 Uninstall USB and Parallel dog driver
  Return value should be 0 if success, other return values are error codes.


If you want to check the information of driver's version, you can call the function CheckVersion in the Dll.
  unsigned long PASCAL CheckVersion(BOOL bShowMessageBox,
					int* piUsbVerStatus,
					int* piParVerStatus);
  Parameter:
		bShowMessageBox =TRUE	display the version message box
		bShowMessageBox =FALSE  not display the version message box
		piUsbVerStatus	the pointer which is used to store the status of USB driver
		piParVerStatus	the pointer which is used to store the status of Parallel driver(reserved for later)

  Return value should be 0 if success, other return values are error codes.
  If the functions succeeds, 
		*piUsbVerStatus=0 means that not find the USB driver
		*piUsbVerStatus=1 means that find the same version of USB driver
		*piUsbVerStatus=2 means that find the older version of USB driver
		*piUsbVerStatus=3 means that find the newer version of USB driver

There are demo programs in the subdirectory of delphi/vb/vc, which show how to call GrandDogSetup.DLL to 
install device drivers. You may refer the samples to write your own installing program.  

-------------------------------------------
Appendix : Error code for GrandDogSetup.dll
-------------------------------------------
E_RC_MAPPING_SYSTEM_LIBRARY_FUNCTION (0xA8162001)	Error in mapping system library function
E_RC_LOAD_SYSTEM_LIBRARY	     (0xA8162002)	Error in loading system library
E_RC_FIND_USB_DOG_DEVICE	     (0xA8162003)	No USB dog device is found
E_RC_UPDATE_USB_DOG		     (0xA8162004)	Update USB dog driver failed 
E_RC_OPERATING_SYSTEM		     (0xA8162005)	The operating system which is not supported
E_RC_NO_PARALLEL_PORT_OR_DISABLED    (0xA8162006)	There is no parallel port or the parallel port is disabled
E_RC_REMOVE_FILE_FAILED    	     (0xA8162007)	Remove file failed 
E_RC_OPEN_DRIVER_SERVICE_FAILED	     (0xA8162008)	Open driver service failed
E_RC_START_DRIVER_SERVICE_FAILED     (0xA8162009)	Start driver service failed
E_RC_COPY_FILE_FAILED		     (0xA816200A)	Copy file failed
E_RC_OPERATE_REGISTRY_FAILED         (0xA816200B)	Operate registery failed
E_RC_NOT_ADMINISTRATOR               (0xA816200C)	You are not administrator

========
Caution
========
 1. Before you install (or uninstall) the GrandDog's driver, you should close the applation which is using GrandDog.





