⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 hw_tx06d69.c

📁 RK27驱动
💻 C
字号:
/******************************************************************/
/*   Copyright (C) 2007 ROCK-CHIPS FUZHOU . All Rights Reserved.  */
/*******************************************************************
File	:  hw_TX06D69.c
Desc	:  TX06D69寄存器初始化
		  
Author	:  nzy
Date	: 
Notes	: 

$Log	: 
*********************************************************************/

#include "hw_include.h"
#include "hw_TX06D69.h"


#if(LCDPANEL == RGBIF_TX06D69)

/*---------------------------------------------------------
Name  :  TX06D69_IICClk
Desc  :  
Params:  
Return:
Author:  nzy
Date  :  
-----------------------------------------------------------*/
void TX06D69_IICClk(void)
{
 	iic_scl_low;
	Delay2us;
	iic_scl_high;
	Delay2us;
}


/*---------------------------------------------------------
Name  :  TX06D69_IICWrite
Desc  :  
Params:  
Return:
Author:  nzy
Date  :  
-----------------------------------------------------------*/
void TX06D69_IICWrite(UINT16 reg, UINT16 data)
{
	UINT32 i;
	Delay2us;
	iic_set_sda_out;
	iic_set_scl_out;
	iic_set_scen_out;
	iic_scen_high;
	Delay2us;
	iic_scen_low;
	iic_sda_low;
	
	iic_scl_low;
	for(i = 0; i < 7; i++)//reg
	{
		if(reg &(1<<(6-i)))
			iic_sda_high;
		else
			iic_sda_low;
        TX06D69_IICClk();  
	}
	
	iic_sda_low;//write
    TX06D69_IICClk();
	iic_sda_high;//highz
    TX06D69_IICClk();
	
	for(i = 0; i < 8; i++)//data
	{
		if(data &(1<<(7-i)))
			iic_sda_high;
		else
			iic_sda_low;
        TX06D69_IICClk();
	}
	iic_scl_low;
	iic_sda_low;
	Delay2us;
}


/*---------------------------------------------------------
Name  :  TX06D69_PowerOnInit
Desc  :  
Params:  
Return:
Author:  nzy
Date  :  
-----------------------------------------------------------*/
void TX06D69_PowerOnInit(void)
{
        //=====================
	TX06D69_IICWrite(0x00, 0x01);		//复位开启电源
	TX06D69_IICWrite(0x01, 0x23);		//方向设定
	TX06D69_IICWrite(0x02, 0x01);
	TX06D69_IICWrite(0x03, 0x1C);		//H_BP=240
	TX06D69_IICWrite(0x04, 0x00);		//VBP=12
	TX06D69_IICWrite(0x05, 0x02);
	TX06D69_IICWrite(0x06, 0x00);

	TX06D69_IICWrite(0x30, 0x18);
	TX06D69_IICWrite(0x48, 0x11);
	
	TX06D69_IICWrite(0x40, 0x23);
	TX06D69_IICWrite(0x41, 0x30);
	TX06D69_IICWrite(0x42, 0x43);
	TX06D69_IICWrite(0x43, 0x23);
	TX06D69_IICWrite(0x44, 0x02);
	TX06D69_IICWrite(0x45, 0x42);
	TX06D69_IICWrite(0x46, 0x44);
	TX06D69_IICWrite(0x47, 0x14);
	TX06D69_IICWrite(0x48, 0x01);
//*****************************************************************
	iic_scen_high;	
}

#endif
   

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -