*****************************************************
SETTINGS FOR BF537 EZ-KIT AND MICRON MI350 SENSOR
*****************************************************

-----------------------------------------------------
EZ-KIT SWITCH/JUMPER SETTINGS:
-----------------------------------------------------

SW1: all off
SW2: 1=off 2=off 3=off 4=on
SW3: all off
SW4: all off
SW5: on if pushbuttons are used, off otherwise
SW6: on if flash is used, off otherwise
SW7: 1=on 2=on 3=on 4=on 5=on 6=off 7=off 8=off
SW8: 1=on 2=on 3=off 4=off 5=off 6=off

SW16 = 1 for flash boot
	
JP3.1/2
JP5.1/2
JP6 DNP
JP8 DNP
JP9 DNP
JP12 DNP

-----------------------------------------------------
AV-EXT POPULATED JUMPERS:
-----------------------------------------------------

JP1 DNP
JP2.1/2
JP3.5/7, JP3.6/8
JP4.7/8
JP5 1/2
JP6.3/5, JP6.4/6
JP7 DNP
JP8 DNP
JP9.3/5, JP9.4/6
JP10 DNP

-----------------------------------------------------
MI350 IMAGE FORMAT:
-----------------------------------------------------

Hor Pixels: 720
Ver Pixels: 480
Format: Grayscale
Bits per pixel: 10

-----------------------------------------------------
MI350 BASIC CONFIGURATION:
-----------------------------------------------------

Hardware:
---------
SW2 = CRT
SW3 = 2/3

Software:
---------
SCCB Write Address:	0xB8
SCCB Read Address:	0xB9

Note: If using BF537 TWI interface, use address 0x5C (0xB8>>1)

Reg  =  Value
-------------
0x0D = 0x0030
0x0F = 0x0011
0x10 = 0x0040
0x15 = 0x7F32
0x1C = 0x0002
0x20 = 0x01D1
0x2B = 0x0003
0x32 = 0x001A
0x70 = 0x0004
0xAF = 0x0003
0x73 = 0x02F7
0xC2 = 0x0040
0x31 = 0x001F
0x33 = 0x0012
0x01 = 0x0001
0x02 = 0x0004
0x03 = 0x01E0
0x04 = 0x0280
0x05 = 0x01B8
0x06 = 0x0208
0xBD = 0x0040
0xA5 = 0x0037
0xBE = 0x003F
0x35 = 0x0003

-----------------------------------------------------
SAMPLE BF537 BASIC REGISTER CONFIGURATION:
-----------------------------------------------------

//If not using system services and drivers:

// SDRAM setup
	tempReg = *pEBIU_SDSTAT;
	tempReg = tempReg & SDRS;
		
	//SDRS is bit 8 of EBIU_SDSTAT register.
	//If SDRS (bit 8) is set (tempReg reads value 8),
	//then SDRAM registers haven't been initialized 
	//yet and needs to be configured.
	 
	if (tempReg == 8)
	{
	
		*pEBIU_SDRRC = 0x03a3;		// SDRAM Refresh Rate Control Register
		*pEBIU_SDBCTL = 0x0025;		// SDRAM Memory Bank Control Register
		*pEBIU_SDGCTL = 0x0491998d;	// SDRAM Memory Global Control Register
	}

// Port setup
	*pTIMER0_CONFIG |= 0x40;
	*pTIMER1_CONFIG |= 0x40; 
	*pTIMER2_CONFIG |= 0x40;
	
	*pPORTFIO_INEN |= 0x8380; // input enable
	*pPORTGIO_INEN |= 0x00FF;

	*pPORT_MUX &= 0xF1FF; // for use of PPI upper data byte
	*pPORT_MUX |= 0x0100; // for use of PPI_FS3
	
	*pPORTF_FER |= 0x8380; // for use of PPI_CLK and PPI_FS1,2,3
	*pPORTG_FER |= 0x000F;
	*pPORTG_FER |= 0x00F0; // for use of PPI upper data byte
	
-----------------------------------------------------
PART REVISIONS:
-----------------------------------------------------

These configurations apply to:
- BF537 Rev. 0.2 or higher
- AV-Extender card Rev. 1.2
- Micron MI350 Headboard Rev. 2
- Micron MT9v022 Sensor Rev. 2