ronnie
2022-10-14 1504bb53e29d3d46222c0b3ea994fc494b48e153
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
///*****************************************
//  Copyright (C) 2009-2019
//  ITE Tech. Inc. All Rights Reserved
//  Proprietary and Confidential
///*****************************************
//   @file   <config.h>
//   @author Jau-Chih.Tseng@ite.com.tw
//   @date   2019/01/03
//   @fileversion: ITE_HDMITX_SAMPLE_3.27
//******************************************/
#ifndef _CONFIG_H_
#define _CONFIG_H_
//#pragma message("config.h")
 
#ifdef EXTERN_HDCPROM
//#pragma message("Defined EXTERN_HDCPROM")
#endif // EXTERN_HDCPROM
 
#define SUPPORT_EDID
//#define SUPPORT_HDCP
#define SUPPORT_SHA
//#define SUPPORT_AUDIO_MONITOR
#define AudioOutDelayCnt 250
 
// #define SUPPORT_CEC
 
 
//////////////////////////////////////////////////////////////////////////////////////////
// Video Configuration
//////////////////////////////////////////////////////////////////////////////////////////
// 2010/01/26 added a option to disable HDCP.
#define SUPPORT_OUTPUTYUV
#define SUPPORT_OUTPUTRGB
// #define DISABLE_HDMITX_CSC
 
#define SUPPORT_INPUTRGB
#define SUPPORT_INPUTYUV444
#define SUPPORT_INPUTYUV422
// #define SUPPORT_SYNCEMBEDDED
// #define SUPPORT_DEGEN
#define NON_SEQUENTIAL_YCBCR422
 
 
 
#define INPUT_COLOR_MODE F_MODE_RGB444
//#define INPUT_COLOR_MODE F_MODE_YUV422
//#define INPUT_COLOR_MODE F_MODE_YUV444
 
#define INPUT_COLOR_DEPTH 24
// #define INPUT_COLOR_DEPTH 30
// #define INPUT_COLOR_DEPTH 36
 
//#define OUTPUT_COLOR_MODE F_MODE_YUV422
#define OUTPUT_COLOR_MODE F_MODE_YUV444
//#define OUTPUT_COLOR_MODE F_MODE_RGB444
 
//#define OUTPUT_3D_MODE Frame_Pcaking
//#define OUTPUT_3D_MODE Top_and_Botton
//#define OUTPUT_3D_MODE Side_by_Side
 
// #define INV_INPUT_ACLK
// #define INV_INPUT_PCLK
#ifdef USING_IT66120
   //#pragma message("Defined Using IT66120")
   #define SUPPORT_SYNCEMBEDDED
#endif
 
#ifdef SUPPORT_SYNCEMBEDDED
   #ifndef USING_IT66120
   // #define INPUT_SIGNAL_TYPE (T_MODE_SYNCEMB)                 // 16 bit sync embedded
   // #define INPUT_SIGNAL_TYPE (T_MODE_SYNCEMB | T_MODE_CCIR656) // 8 bit sync embedded
   #define INPUT_SIGNAL_TYPE (T_MODE_SYNCEMB|T_MODE_INDDR|T_MODE_PCLKDIV2) // 16 bit sync embedded DDR
   // #define INPUT_SIGNAL_TYPE (T_MODE_SYNCEMB|T_MODE_INDDR)      // 8  bit sync embedded DDR
   #else
       #define INPUT_SIGNAL_TYPE (T_MODE_SYNCEMB | T_MODE_CCIR656) // 8 bit sync embedded
   #endif
 
   #define SUPPORT_INPUTYUV422
   #ifdef INPUT_COLOR_MODE
   #undef INPUT_COLOR_MODE
   #endif // INPUT_COLOR_MODE
   #define INPUT_COLOR_MODE F_MODE_YUV422
#else
   //#pragma message ("Defined seperated sync.")
   #define INPUT_SIGNAL_TYPE 0 // 24 bit sync seperate
   //#define INPUT_SIGNAL_TYPE ( T_MODE_DEGEN )
   //#define INPUT_SIGNAL_TYPE ( T_MODE_INDDR)
   //#define INPUT_SIGNAL_TYPE ( T_MODE_SYNCEMB)
   //#define INPUT_SIGNAL_TYPE ( T_MODE_CCIR656 | T_MODE_SYNCEMB )
#endif
 
 
#if defined(SUPPORT_INPUTYUV444) || defined(SUPPORT_INPUTYUV422)
#define SUPPORT_INPUTYUV
#endif
 
#ifdef SUPPORT_SYNCEMBEDDED
//#pragma message("defined SUPPORT_SYNCEMBEDDED for Sync Embedded timing input or CCIR656 input.")
#endif
 
 
//////////////////////////////////////////////////////////////////////////////////////////
// Audio Configuration
//////////////////////////////////////////////////////////////////////////////////////////
 
// #define SUPPORT_HBR_AUDIO
#define USE_SPDIF_CHSTAT
#ifndef SUPPORT_HBR_AUDIO
   #define INPUT_SAMPLE_FREQ AUDFS_48KHz
   #define INPUT_SAMPLE_FREQ_HZ 48000L
   #define OUTPUT_CHANNEL 2 // 3 // 4 // 5//6 //7 //8
 
   #define CNOFIG_INPUT_AUDIO_TYPE T_AUDIO_LPCM
   // #define CNOFIG_INPUT_AUDIO_TYPE T_AUDIO_NLPCM
   #define CONFIG_INPUT_AUDIO_INTERFACE I2S
   // #define CONFIG_INPUT_AUDIO_INTERFACE SPDIF
   // #define CONFIG_INPUT_AUDIO_INTERFACE TDM
 
   // #define I2S_FORMAT 0x00 // 24bit I2S audio
   #define I2S_FORMAT 0x01 // 32bit I2S audio
   // #define I2S_FORMAT 0x02 // 24bit I2S audio, right justify
   // #define I2S_FORMAT 0x03 // 32bit I2S audio, right justify
 
#else // SUPPORT_HBR_AUDIO
 
   #define INPUT_SAMPLE_FREQ AUDFS_768KHz
   #define INPUT_SAMPLE_FREQ_HZ 768000L
   #define OUTPUT_CHANNEL 8
   #define CNOFIG_INPUT_AUDIO_TYPE T_AUDIO_HBR
   #define CONFIG_INPUT_AUDIO_INTERFACE FALSE // I2S
   // #define CONFIG_INPUT_AUDIO_INTERFACE TRUE // SPDIF
   #define I2S_FORMAT 0x47 // 32bit audio
#endif
 
 
 
//////////////////////////////////////////////////////////////////////////////////////////
// Audio Monitor Configuration
//////////////////////////////////////////////////////////////////////////////////////////
 
// #define HDMITX_AUTO_MONITOR_INPUT
// #define HDMITX_INPUT_INFO
 
#ifdef HDMITX_AUTO_MONITOR_INPUT
#define HDMITX_INPUT_INFO
#endif
 
//////////////////////////////////////////////////////////////////////////////////////////
// Reduce Source Clock Jitter
//////////////////////////////////////////////////////////////////////////////////////////
// #define REDUCE_HDMITX_SRC_JITTER
#endif