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

📄 tw2834_def.h

📁 TW2834的驱动程序设计。包括各个寄存器标准值设计。对于理解TW2834与ITU656非常有帮助
💻 H
📖 第 1 页 / 共 2 页
字号:
#define SET_BIT(x,y)        ((x) |= (y))
#define CLEAR_BIT(x,y)      ((x) &= ~(y))
#define CHKBIT_SET(x,y)     (((x)&(y)) == (y))
#define CHKBIT_CLR(x,y)     (((x)&(y)) == 0)


/*******************************************************************************
*                      Page0 initialize table description                      *
*******************************************************************************/

/****************************       NTSC        *******************************/
unsigned char   tbl_ntsc_page0_common[] = {
                            /*          CH1         CH2         CH3         CH4         */
    0x00,0xc4,0xe5,0x1a,    /*...       0x00~0x03   0x40~0x43   0x80~0x83   0xc0~0xc3   */
    0xd0,0x1a,0xd0,0x88,    /*...       0x04~0x07   0x44~0x47   0x84~0x87   0xc4~0xc7   */
    0x20,0x06,0xf0,0x06,    /*...       0x08~0x0b   0x48~0x4b   0x88~0x8b   0xc8~0xcb   */
    0xf0,0x00,0xd2,0x80,    /*...       0x0c~0x0f   0x4c~0x4f   0x8c~0x8f   0xcc~0xcf   */
    0x80,0x80,0x82,0x1f,    /*...       0x10~0x13   0x50~0x53   0x90~0x93   0xd0~0xd3   */
    0x00,0x00,0x00,0x00,    /*...       0x14~0x17   0x54~0x57   0x94~0x97   0xd4~0xd7   */
    0x7f,0xff,0x7f,0xff,    /*...       0x18~0x1b   0x58~0x5b   0x98~0x9b   0xd8~0xdb   */
    0x7f,0xff,0x7f,0xff,    /*...       0x1c~0x1f   0x5c~0x5f   0x9c~0x9f   0xdc~0xdf   */
    0x07,0x07,0x00,0x11     /*...       0x20~0x23   0x60~0x63   0xa0~0xa3   0xe0~0xe3   */
};

unsigned char   tbl_ntsc_page0_sfr1[] = {
    0x00,0x00,0x00,0x00,    /*... 0x38~0x3b  */
    0x80,0x80,0x82,0x82     /*... 0x3c~0x3f  */
};

unsigned char   tbl_ntsc_page0_sfr2[] = {
    0xa0,0x00,0x00,0x00,    /*... 0x78~0x7b     ... 0x78:0x80->0xa0 on 050222 */
    0x08,0x00,0x00,0x00     /*... 0x7c~0x7f     ... 0x7c:0x08->0x0f on 050218 */
};

unsigned char   tbl_ntsc_page0_sfr3[] = {
    0x05,0x00,0x00,0x00,    /*... 0xb8~0xbb */
    0x00,0x00,0x00,0x00     /*... 0xbc~0xbf */
};

unsigned char   tbl_ntsc_page0_sfr4[] = {
    0x0a,0x40,0x3c,0x10,    /*... 0xf8~0xfb */
    0x00,0x00,0x08,0x00     /*... 0xfc~0xff */
};

/*******************************        PAL     *******************************/
unsigned char   tbl_pal_page0_common[] = {
                            /*      CH1         CH2         CH3         CH4             */
    0x00,0x84,0xa5,0x22,    /*...       0x00~0x03   0x40~0x43   0x80~0x83   0xc0~0xc3   */
    0xd0,0x22,0xd0,0x88,    /*...       0x04~0x07   0x44~0x47   0x84~0x87   0xc4~0xc7   */
    0x20,0x05,0x20,0x05,    /*...       0x08~0x0b   0x48~0x4b   0x88~0x8b   0xc8~0xcb   */
    0x20,0x0a,0xd2,0x80,    /*...       0x0c~0x0f   0x4c~0x4f   0x8c~0x8f   0xcc~0xcf   */
    0x80,0x80,0x80,0x2f,    /*...       0x10~0x13   0x50~0x53   0x90~0x93   0xd0~0xd3   */
    0x00,0x00,0x00,0x00,    /*...       0x14~0x17   0x54~0x57   0x94~0x97   0xd4~0xd7   */
    0x7f,0xff,0x7f,0xff,    /*...       0x18~0x1b   0x58~0x5b   0x98~0x9b   0xd8~0xdb   */
    0x7f,0xff,0x7f,0xff,    /*...       0x1c~0x1f   0x5c~0x5f   0x9c~0x9f   0xdc~0xdf   */
    0x0f,0x0f,0x00,0x11     /*...       0x20~0x23   0x60~0x63   0xa0~0xa3   0xe0~0xe3   */
};

unsigned char   tbl_pal_page0_sfr1[] = {
    0x00,0x00,0x00,0x00,    /*... 0x38~0x3b */
    0x90,0x90,0x82,0x82     /*... 0x3c~0x3f */
};

unsigned char   tbl_pal_page0_sfr2[] = {
    0xa0,0x00,0x00,0x00,    /*... 0x78~0x7b */
    0x0f,0x00,0x00,0x00     /*... 0x7c~0x7f    ... 0x7c:0x08->0x0f on 050218 */
};

unsigned char   tbl_pal_page0_sfr3[] = {
    0x05,0x00,0x00,0x00,    /*... 0xb8~0xbb */
    0x00,0x00,0x00,0x00     /*... 0xbc~0xbf */
};

unsigned char   tbl_pal_page0_sfr4[] = {
    0x0c,0x40,0x3c,0x10,    /*... 0xf8~0xfb */
    0xf0,0x00,0x08,0x00     /*... 0xfc~0xff */
};


/*********************        4 Pb / 4 Rec      *******************************/
unsigned char   tbl_page0_4pb_en[] = {
    0x39,0xe4,
    0x3b,0x01
};

unsigned char   tbl_page0_4pb_dis[] = {
    0x39,0x00,
    0x3b,0x00
};

/*******************************************************************************
*                      Page1 initialize table description                      *
*******************************************************************************/
unsigned char   tbl_page1_4pb_en[] = {
    0x55,0x80,
    0xbb,0x0b,
    0x8c,0x00,
    0x8d,0x8a,
    0x8e,0x00       /*... test needed */
};

unsigned char   tbl_page1_4pb_dis[] = {
    0x55,0x84,
    0xbb,0x00,
    0x8c,0x08,
    0x8d,0x44,
    0x8e,0x00
};

unsigned char   tbl_page1_x_com[] = {
/*  00   01   02   03   04   05   06   07       08   09   0A   0B   0C   0D   0E   0F */
    0x00,0x00,0xa0,0x40,0x80,0x00,0x00,    0x00,0x00,0x00,0xd7,0x23,0x2d,0x1e,0xa7
};

/*... function mode, dec path, many property & recall for each channel*/
unsigned char   tbl_page1_x_ch_nrml[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x80,0x00,0x00,0x02,0x00,0x00,0x90,0x00,    0x81,0x00,0x00,0x02,0x00,0x00,0x11,0x00,    /*...  0x10   enable channel */
    0x82,0x00,0x00,0x02,0x00,0x00,0x12,0x00,    0x83,0x00,0x00,0x02,0x00,0x00,0x13,0x00,    /*...  0x20   enable channel */
};

/********************       NTSC        *********************/

/*... PICHL, PICHR, PICVT, PICVB for each channel*/
unsigned char   tbl_ntsc_page1_x_pic_quad[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x00,0x5a,0x00,0x3c,0x5a,0xb4,0x00,0x3c,    0x00,0x5a,0x3c,0x78,0x5a,0xb4,0x3c,0x78 /*...  0x30 */
};

/*... Dummy Channel Boundary for each channel*/
unsigned char   tbl_ntsc_page1_dumy[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x78,0xb4,0x28,0x50,0x00,0x3c,0x50,0x78,    0x3c,0x78,0x50,0x78,0x78,0xb4,0x50,0x78 /*...  0x40 */
};

/*********************       PAL         **********************/

/*... PICHL, PICHR, PICVT, PICVB for each channel*/
unsigned char   tbl_pal_page1_x_pic_quad[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x00,0x5a,0x00,0x48,0x5a,0xb4,0x00,0x48,    0x00,0x5a,0x48,0x90,0x5a,0xb4,0x48,0x90 /*...  0x30 */
};

/*... Dummy Channel Boundary for each channel*/
unsigned char   tbl_pal_page1_dumy[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x78,0xb4,0x30,0x60,0x00,0x3c,0x60,0x90,    0x3c,0x78,0x60,0x90,0x78,0xb4,0x60,0x90 /*...  0x40 */
};

/******************************************************************************/

unsigned char   tbl_page1_y_com[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x00,0x00,0x00,0xa0,0x00,0x84,0x00,0x03,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xa7 /*...  0x50 */
};

/*... function mode, dec path, many property & recall for each channel*/
unsigned char   tbl_page1_y_ch_nrml_pic_quad[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x80,0x00,0x00,0x81,0x00,0x00,0x82,0x00,    0x00,0x83,0x00,0x00,0x00,0xe4,0x00,0x00 /*...  0x60  enable channel */
};

/*... popup & position control for Cascade or Path Overlay*/
unsigned char   tbl_page1_cas_popup[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x00,0x00,0x01,0x00,0x00,0x00,0x00,0x00,    0x04,0xff,0x00,0x00,0x00,0x00           /*... 0x70 */
};

/********************       NTSC        *********************/
unsigned char   tbl_ntsc_page1_enc[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F*/
    0x77,0x50,0x54,0x01,0x80,0x10,0x00,0x0d,    0x20,0x09,0xaa,0x00,0x08,0x44,0x00   /* ... 0x80 ~ 0x8e*/
};

/******************       PAL         ***********************/
unsigned char   tbl_pal_page1_enc[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x77,0x50,0x54,0x01,0x80,0x10,0x00,0x0d,    0x20,0x4c,0xaa,0x00,0x08,0x44,0x00   /* ... 0x80 ~ 0x8e*/
};

/******************************************************************************/
unsigned char   tbl_page1_channel_id_ctrl[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x50,0xc0,0x00,0x1f,0xe7,0xeb,0x10,0x00,    0x00,0xd0,0x00,0x1f,0xe7,0x80,0x00,0x00  /*...  0xc0 ~ 0xcd*/
};

unsigned char   tbl_page1_channel_id_data_x[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0x01,0x23,0x45,0x67,0x89,0xab,0xcd,0xef,    0x5a,0xa5,0x5a,0xa5,0x5a,0xa5,0x5a,0xa5  /*...  0xd0 ~ 0xdf*/
};

unsigned char   tbl_page1_channel_id_data_y[] = {
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0xa5,0x5a,0xa5,0x5a,0xa5,0x5a,0xa5,0x5a,    0xfe,0xdc,0xba,0x98,0x76,0x54,0x32,0x10  /*...  0xe0 ~ 0xef*/
};

/*******************************************************************************
*                      Page2 initialize table description                      *
*******************************************************************************/

unsigned char   tbl_page2_cur_3d_box[] = {      // 96 EA
/*  00   01   02   03   04   05   06   07        08   09   0A   0B   0C   0D   0E   0F */
    0xb0,0x00,0x00,0x00,0x01,0x10,0x32,0x54,    0x76,0x98,0xba,0xdc,0xfe,0x00,0x00,0x00,    /*...  0x00 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    /*...  0x10 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    /*...  0x20 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    /*...  0x30 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    /*...  0x40 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00     /*...  0x50 */
};


unsigned char   tbl_ntsc_page2_ary_box[] = {            /* 32 EA   */
    0x84,0x4c,0x01,0x0a,    0x00,0x09,0xfb,0x00,        /* 0x60 ~  */
    0x84,0x4c,0x5b,0x0a,    0x00,0x09,0xfb,0x00,        /* 0x68 ~  */
    0x84,0x4c,0x01,0x0a,    0x3c,0x09,0xfb,0x00,        /* 0x70 ~  */
    0x84,0x4c,0x5b,0x0a,    0x3c,0x09,0xfb,0x00         /* 0x78 ~  */
};

unsigned char   tbl_pal_page2_ary_box[] = {             /* 32 EA   */
    0x84,0x4c,0x01,0x0a,    0x00,0x0b,0xfb,0x00,        /* 0x60 ~  */
    0x84,0x4c,0x5b,0x0a,    0x00,0x0b,0xfb,0x00,        /* 0x68 ~  */
    0x84,0x4c,0x01,0x0a,    0x48,0x0b,0xfb,0x00,        /* 0x70 ~  */
    0x84,0x4c,0x5b,0x0a,    0x48,0x0b,0xfb,0x00         /* 0x78 ~  */
};

unsigned char   tbl_page2_motn_sens[] = {               /* 6 EA           */
    0x17,0x08,0x6a,0x07,0x00,0x24                       /*... 0x80 ~ 0x85 */
};

unsigned char   tbl_page2_motn_mask[] = {               // 24 EA          */
                                  0x00,0x00,            //... 0x86 ~ 0x87 */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,            //... 0x88 ~ 0x8f */
    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,            //... 0x90 ~ 0x97 */
    0x00,0x00,0x00,0x00,0x00,0x00                       //... 0x98 ~ 0x9d */
};


#endif

⌨️ 快捷键说明

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