初始化阶段:
1.确定8个物理量,设置相应寄存器
2.开辟一段内存 --->合法首地址 + 内存空间的大小
3.将内存锁定到DMA通道
3.将内存锁定到DMA通道
LCD面板基本内容
1.物理特性 ---> 分辨率
2.尺寸
3.扫描方式 --->扫描硬件模块的移动方式,不断定位、偏移 ---> 垂直扫描/水平扫描
1)单扫 技术要求比较低
2)双扫 提高扫描速度 (需要解决同步问题)
3)多扫 1/4 1/8 (需要解决同步问题)
1.物理特性 ---> 分辨率
2.尺寸
3.扫描方式 --->扫描硬件模块的移动方式,不断定位、偏移 ---> 垂直扫描/水平扫描
1)单扫 技术要求比较低
2)双扫 提高扫描速度 (需要解决同步问题)
3)多扫 1/4 1/8 (需要解决同步问题)
4.显示模式
1BPP 每个像素点需要依赖两个位 锁定像素点后会判断参考电压 1个位来保存驱动电压 ---> 只有两种显示模式,要么是全亮的,要么是全黑的
2BPP 四级灰度,用两个位来描述参考电压
4BPP
16BPP
24BPP 2的24次方灰度
1BPP 每个像素点需要依赖两个位 锁定像素点后会判断参考电压 1个位来保存驱动电压 ---> 只有两种显示模式,要么是全亮的,要么是全黑的
2BPP 四级灰度,用两个位来描述参考电压
4BPP
16BPP
24BPP 2的24次方灰度
HSYNC 行同步信号
VSYNC 帧同步信号,用来决定行是否已经结束
VDEN (DE使能信号)
VCLK (DCLK)
VSYNC 帧同步信号,用来决定行是否已经结束
VDEN (DE使能信号)
VCLK (DCLK)
每来一个周期画一个像素
每来一个周期画一行
每来一个周期画一帧
每来一个周期画一行
每来一个周期画一帧
HSYNC --> VSYNC --> VDEN --> VCLK
S5PV210.h头文件
#define rVIC0VECTADDR16 (*(volatile unsigned long*) 0xf2000140)
#define rVIC0VECTADDR25 (*(volatile unsigned long*) 0xf2000164)
#define rVIC2VECTADDR23 (*(volatile unsigned long*) 0xf220015C)
//------GPIO------
#define rGPD0CON (*(volatile unsigned long *)0xE02000A0)
#define rGPD0DAT (*(volatile unsigned long *)0xE02000A4)
#define rGPE0CON (*(volatile unsigned long *)0xE02000E0)
#define rGPE0DAT (*(volatile unsigned long *)0xE02000E4)
#define rGPF0CON (*(volatile unsigned long *)0xE0200120)
#define rGPF1CON (*(volatile unsigned long *)0xE0200140)
#define rGPF2CON (*(volatile unsigned long *)0xE0200160)
#define rGPF3CON (*(volatile unsigned long *)0xE0200180)
#define rGPH2CON (*(volatile unsigned long *) 0xE0200C40)
#define rGPH2DAT (*(volatile unsigned long *) 0xE0200C44)
#define rGPH3CON (*(volatile unsigned long *) 0xE0200C60)
#define rGPJ2CON (*(volatile unsigned long *) 0xE0200280)
#define rGPJ2DAT (*(volatile unsigned long *) 0xE0200284)
#define rGPJ2PUD (*(volatile unsigned long *) 0xE0200288)
#define rGPH3CON (*(volatile unsigned long *) 0xE0200C60)
#define rGPH3DAT (*(volatile unsigned long *) 0xE0200C64)
#define rGPH3PUD (*(volatile unsigned long *) 0xE0200C68)
#define rEXT_INT_0_CON ( *((volatile unsigned long *)0xE0200E00) )
#define rEXT_INT_1_CON ( *((volatile unsigned long *)0xE0200E04) )
#define rEXT_INT_2_CON ( *((volatile unsigned long *)0xE0200E08) )
#define rEXT_INT_3_CON ( *((volatile unsigned long *)0xE0200E0C) )
#define rEXT_INT_0_MASK ( *((volatile unsigned long *)0xE0200F00) )
#define rEXT_INT_1_MASK ( *((volatile unsigned long *)0xE0200F04) )
#define rEXT_INT_2_MASK ( *((volatile unsigned long *)0xE0200F08) )
#define rEXT_INT_3_MASK ( *((volatile unsigned long *)0xE0200F0C) )
#define rEXT_INT_0_PEND ( *((volatile unsigned long *)0xE0200F40) )
#define rEXT_INT_1_PEND ( *((volatile unsigned long *)0xE0200F44) )
#define rEXT_INT_2_PEND ( *((volatile unsigned long *)0xE0200F48) )
#define rEXT_INT_3_PEND ( *((volatile unsigned long *)0xE0200F4C) )
//------- exception ------
#define _Exception_Vector 0xD0037400
#define pExcRESET ( *((volatile unsigned long *)(_Exception_Vector + 0x0)) )
#define pExcUNDEF ( *((volatile unsigned long *)(_Exception_Vector + 0x4)) )
#define pExcSWI ( *((volatile unsigned long *)(_Exception_Vector + 0x8)) )
#define pExcPABORT ( *((volatile unsigned long *)(_Exception_Vector + 0xc)) )
#define pExcDABORT ( *((volatile unsigned long *)(_Exception_Vector + 0x10)) )
#define pExcRESERVED ( *((volatile unsigned long *)(_Exception_Vector + 0x14)) )
#define pExcIRQ ( *((volatile unsigned long *)(_Exception_Vector &#