Esempio n. 1
0
static void LCD_bl_close(__u32 sel)
{
    __u32 tmp;
    __lcd_panel_init_para_t para;

	LCD_get_init_para(&para);
/*
// GPIO_O_1_EN-BL, PA5 set to 0
    tmp = sys_get_wvalue(para.base_pioc + 0x10);
    tmp &= 0xffffffdf;//clear bit5
    sys_put_wvalue(para.base_pioc+0x10, tmp);
    
    tmp = sys_get_wvalue(para.base_pioc+0x00);
    tmp &= 0xff8fffff;
    sys_put_wvalue(para.base_pioc+0x00,tmp | (1<<20));//bit22:20, 1:output

    tmp = sys_get_wvalue(para.base_pioc + 0x10);
    tmp &= 0xffffffdf;//clear bit5
    sys_put_wvalue(para.base_pioc+0x10, tmp);
*/

// PWM disable
    tmp = sys_get_wvalue(para.base_ccmu+0xe0);
    tmp &= (~(1<<4));
    sys_put_wvalue(para.base_ccmu+0xe0,tmp);    
}
Esempio n. 2
0
////////////////////////////////////////   back light   ////////////////////////////////////////////////////////////////////
static void LCD_bl_open(__u32 sel)
{
    __u32 tmp;
	__lcd_panel_init_para_t para;

	LCD_get_init_para(&para);

// PWM enable
    tmp = sys_get_wvalue(para.base_ccmu+0xe0);
    tmp |= (1<<4);
    sys_put_wvalue(para.base_ccmu+0xe0,tmp);

// GPIO_O_1_EN-BL, PA5 set to 1
/*
    tmp = sys_get_wvalue(para.base_pioc + 0x10);
    tmp |= 0x00000020;//set bit5
    sys_put_wvalue(para.base_pioc+0x10, tmp);
    
    tmp = sys_get_wvalue(para.base_pioc+0x00);
    tmp &= 0xff8fffff;
    sys_put_wvalue(para.base_pioc+0x00,tmp | (1<<20));//bit22:20, 1:output

    tmp = sys_get_wvalue(para.base_pioc + 0x10);
    tmp |= 0x00000020;//set bit5
    sys_put_wvalue(para.base_pioc+0x10, tmp);
    */
}
Esempio n. 3
0
static void LCD_power_off(__u32 sel)//0 active
{
	__lcd_panel_init_para_t para;

	LCD_get_init_para(&para);
	para.power_off(sel);
}
Esempio n. 4
0
static void LCD_bl_close(__u32 sel)
{
    __u32 tmp;
    __lcd_panel_init_para_t para;

	LCD_get_init_para(&para);
	
    tmp = sys_get_wvalue(para.base_timer+0xa0);
    tmp &= (~(1<<4));
    sys_put_wvalue(para.base_timer+0xa0,tmp);
}
Esempio n. 5
0
static void LCD_power_off(__u32 sel)//PH27,0 active
{
	__u32 tmp = 0;
	__lcd_panel_init_para_t para;

	LCD_get_init_para(&para);

// LCD-PWR, PH27 set to 1
    tmp = sys_get_wvalue(para.base_pioc + 0x10c);
    tmp |= 0x08000000;//set bit27
    sys_put_wvalue(para.base_pioc+0x10c, tmp);
    
    tmp = sys_get_wvalue(para.base_pioc+0x108);
    tmp &= 0xffff8fff;
    sys_put_wvalue(para.base_pioc+0x108,tmp | (1<<12));//bit18:16, 1:output

    tmp = sys_get_wvalue(para.base_pioc + 0x10c);
    tmp |= 0x08000000;//set bit27
    sys_put_wvalue(para.base_pioc+0x10c, tmp);
}