单片机
返回首页

来认识一下S5PV210 的VBPDE和VFPDE

2024-12-19 来源:elecfans

在代码中有


 


// VIDTCON0

#define VBPDE(n)            (((n-1)&0xff)<<24)

#define VBPD(n)             (((n-1)&0xff)<<16)

#define VFPD(n)             (((n-1)&0xff)<<8)

#define VSPW(n)             (((n-1)&0xff)<<0)



// VIDTCON1

#define VFPDE(n)            (((n-1)&0xff)<<24)

#define HBPD(n)             (((n-1)&0xff)<<16)

#define HFPD(n)             (((n-1)&0xff)<<8)

#define HSPW(n)             (((n-1)&0xff)<<0)



// VIDTCON2

#define LINEVAL(n)          (((n-1)&0x7ff)<<11)

#define HOZVAL(n)           (((n-1)&0x7ff)<<0)

 


 


 


#ifdef CONFIG_FB_S3C_LTE480WV

.width = 480,

.height = 272,

.bpp = 16,

.freq = 60,


.timing = {

.h_fp = 2, //HFPD_Value = 2

.h_bp = 2, //HBPD_Value = 2

.h_sw = 41,//HSPW_Value = 41;

.v_fp = 2, //VFPD_Value = 2

.v_fpe = 1, 

.v_bp = 2, //VBPD_Value = 2

.v_bpe = 1,

.v_sw = 10,

},

.polarity = {

.rise_vclk = 0,

.inv_hsync = 1,

.inv_vsync = 1,

.inv_vden = 0,

},

#endif


里面的


v_fpe和h_bpe 是啥玩意呢?

在代码中有

int s3cfb_set_timing(struct s3cfb_global *ctrl)

{

struct s3cfb_lcd_timing *time;

u32 cfg;


time = &ctrl->lcd->timing;

cfg = 0;


cfg |= S3C_VIDTCON0_VBPDE(time->v_bpe - 1);

cfg |= S3C_VIDTCON0_VBPD(time->v_bp - 1);

cfg |= S3C_VIDTCON0_VFPD(time->v_fp - 1);

cfg |= S3C_VIDTCON0_VSPW(time->v_sw - 1);


writel(cfg, ctrl->regs + S3C_VIDTCON0);


cfg = 0;


cfg |= S3C_VIDTCON1_VFPDE(time->v_fpe - 1);

cfg |= S3C_VIDTCON1_HBPD(time->h_bp - 1);

cfg |= S3C_VIDTCON1_HFPD(time->h_fp - 1);

cfg |= S3C_VIDTCON1_HSPW(time->h_sw - 1);


writel(cfg, ctrl->regs + S3C_VIDTCON1);


return 0;

}

在手册有如下说明:

 


VBPDE  [31:24]  Vertical back porch specifies the number of inactive lines at the 

start of a frame after vertical synchronization period. (Only for even

field of YVU interface) 

VFPDE  [31:24]  Vertical front porch specifies the number of inactive lines at the end 

of a frame before vertical synchronization period. (Only for the even

field of YVU interface). 

Only for the even field of YVU interface 这个是啥意思?我在wince的VGA 1440*900 1280*720 1280*1024 当中根本没有设置这个

v_fpe和h_bpe,也就是默认就是0.在android下就有这玩意。


进入单片机查看更多内容>>
相关视频
  • 【TI MSPM0 应用实战】智能小车+工业角度编码器+血氧仪+烟雾探测器!硬核参考设计详解!

  • 2022 Digi-Key KOL 系列: 你见过1GHz主频的单片机吗?Teensy 4.1开发板介绍

  • TI 新一代 C2000™ 微控制器:全方位助力伺服及马达驱动应用

  • MSP430电容触摸技术 - 防水Demo演示

  • 直播回放: Microchip Timberwolf™ 音频处理器在线研讨会

  • 基于灵动MM32W0系列MCU的指夹血氧仪控制及OTA升级应用方案分享

精选电路图
  • 1瓦线性调频增强器

  • 家用电器遥控器

  • 12V 转 28V DC-DC 变换器(基于 LM2585)

  • 红外开关

  • DS1669数字电位器

  • HA1377 桥式放大器 BCL 电容 17W(汽车音频)

    相关电子头条文章