exynos: Move common smdk5420 things to common file
[platform/kernel/u-boot.git] / include / video_ad7176.h
1 /*
2  * (C) Copyright 2000
3  * Paolo Scaffardi, AIRVENT SAM s.p.a - RIMINI(ITALY), arsenio@tin.it
4  *
5  * SPDX-License-Identifier:     GPL-2.0+
6  */
7
8 #ifndef _VIDEO_AD7176_H_
9 #define _VIDEO_AD7176_H_
10
11 #define VIDEO_ENCODER_NAME      "Analog Devices AD7176"
12
13 #define VIDEO_ENCODER_I2C_RATE  100000  /* Max rate is 100 kHz          */
14 #define VIDEO_ENCODER_CB_Y_CR_Y         /* Use CB Y CR Y format...      */
15
16 #define VIDEO_MODE_YUYV         /* The only mode supported by this encoder */
17 #undef  VIDEO_MODE_RGB
18 #define VIDEO_MODE_BPP          16
19
20 #ifdef  VIDEO_MODE_PAL
21 #define VIDEO_ACTIVE_COLS       720
22 #define VIDEO_ACTIVE_ROWS       576
23 #define VIDEO_VISIBLE_COLS      640
24 #define VIDEO_VISIBLE_ROWS      480
25 #endif
26
27 #ifdef  VIDEO_MODE_NTSC
28 #define VIDEO_ACTIVE_COLS       720
29 #define VIDEO_ACTIVE_ROWS       525
30 #define VIDEO_VISIBLE_COLS      640
31 #define VIDEO_VISIBLE_ROWS      400
32 #endif
33
34 static unsigned char video_encoder_data[] = {
35 #ifdef VIDEO_MODE_NTSC
36                                         0x04, /* Mode Register 0        */
37 #ifdef VIDEO_DEBUG_COLORBARS
38                                         0x82,
39 #else
40                                         0x02, /* Mode Register 1        */
41 #endif  /* VIDEO_DEBUG_COLORBARS */
42                                         0x16, /* Subcarrier Freq 0      */
43                                         0x7c, /* Subcarrier Freq 1      */
44                                         0xf0, /* Subcarrier Freq 2      */
45                                         0x21, /* Subcarrier Freq 3      */
46                                         0x00, /* Subcarrier phase       */
47                                         0x02, /* Timing Register 0      */
48                                         0x00, /* Extended Captioning 0  */
49                                         0x00, /* Extended Captioning 1  */
50                                         0x00, /* Closed Captioning 0    */
51                                         0x00, /* Closed Captioning 1    */
52                                         0x00, /* Timing Register 1      */
53                                         0x08, /* Mode Register 2        */
54                                         0x00, /* Pedestal Register 0    */
55                                         0x00, /* Pedestal Register 1    */
56                                         0x00, /* Pedestal Register 2    */
57                                         0x00, /* Pedestal Register 3    */
58                                         0x00  /* Mode Register 3        */
59
60 #endif  /* VIDEO_MODE_NTSC */
61
62 #ifdef VIDEO_MODE_PAL
63                                         0x05, /* Mode Register 0        */
64 #ifdef VIDEO_DEBUG_COLORBARS
65                                         0x82,
66 #else
67                                         0x02, /* Mode Register 1 (2)    */
68 #endif  /* VIDEO_DEBUG_COLORBARS */
69                                         0xcb, /* Subcarrier Freq 0      */
70                                         0x8a, /* Subcarrier Freq 1      */
71                                         0x09, /* Subcarrier Freq 2      */
72                                         0x2a, /* Subcarrier Freq 3      */
73                                         0x00, /* Subcarrier phase       */
74                                         0x0a, /* Timing Register 0 (a)  */
75                                         0x00, /* Extended Captioning 0  */
76                                         0x00, /* Extended Captioning 1  */
77                                         0x00, /* Closed Captioning 0    */
78                                         0x00, /* Closed Captioning 1    */
79                                         0x00, /* Timing Register 1      */
80                                         0x08, /* Mode Register 2 (8)    */
81                                         0x00, /* Pedestal Register 0    */
82                                         0x00, /* Pedestal Register 1    */
83                                         0x00, /* Pedestal Register 2    */
84                                         0x00, /* Pedestal Register 3    */
85                                         0x00  /* Mode Register 3        */
86 #endif  /* VIDEO_MODE_PAL */
87 } ;
88
89 #endif  /* _VIDEO_AD7176_H_ */