// define the parameter ram struct

/* The flash start address in memory space*/
#define FlashStartAddress 	0
/* The size of all flash */
#define FlashSize			1
/* The address of this time to operate*/
#define CurrentSAddress		2
/* The length(bytes) od this time to operate*/
#define CurrentLength       3
/* The Flash type include company, type*/
#define FlashType			4
/* port size of flash such as 8,16,32*/
#define PortSize			5
/* Command will be executed, such as programming or erase*/
#define Command				6
/* Error report after flash programming*/
#define ErrorInfos   7 
/* The Error address that occor error*/
#define ErrorAddress		8
/* Chip count of flash such as 1,2,4*/
#define ChipCount			9



// Flash Port size define
#define Port8               0
#define Port16              1
#define Port32              2

// Error type define
#define ExecOK				0
#define EreaseError			1
#define BlankCError			2
#define ProgError			3
#define VerifyError			4
#define TypeError			5
#define OnRUN				0x5555AAAA
#define NoSupport			0xFFFFFFFF

// Operation Command define
#define Erasing				0
#define Programming			1
#define Verifying			2

// type define
typedef	char			BYTE;
typedef unsigned char 	UBYTE;
typedef	short			HWORD;
typedef	unsigned short	UHWORD;
typedef	long			WORD;
typedef unsigned long 	UWORD;
typedef unsigned char 	BOOL;

typedef	volatile char			VBYTE;
typedef volatile unsigned char 	VUBYTE;
typedef	volatile short			VHWORD;
typedef	volatile unsigned short	VUHWORD;
typedef	volatile long			VWORD;
typedef volatile unsigned long 	VUWORD;
typedef volatile unsigned char 	VBOOL;
